/* Services Grid */
.services-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    margin-top: 0;
}

@media (min-width: 768px) {
    .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    /* First item spans 2 cols on tablet */
    .services-grid> :first-child {
        grid-column: 1 / -1;
    }
}

@media (min-width: 1024px) {
    .services-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    /* Onepage Website Card (First Item) */
    .services-grid> :first-child {
        grid-column: 1 / -1;
        /* Span full width */
        display: flex;
        /* Ensure it stays flex */
        flex-direction: row;
        /* Horizontal layout for the big card */
        align-items: center;
        gap: 3rem;
        padding: 3rem;
        min-height: 250px;
        /* Give it some prominence */
    }

    .services-grid> :first-child .service-icon-wrapper {
        /* Remove scale to avoid clipping issues */
        margin-right: 2rem;
        flex-shrink: 0;
        /* Prevent shrinking */
    }

    .services-grid> :first-child .service-icon {
        width: 100px;
        /* Explicitly larger */
        height: 100px;
    }


    .services-grid> :first-child .service-title {
        font-size: 2rem;
        /* Bigger title */
        margin-bottom: 0.5rem;
    }

    .services-grid> :first-child p {
        font-size: 1.1rem;
        max-width: 600px;
    }
}

.service-card {
    background: var(--card-bg);
    padding: 2.5rem 2rem;
    border-radius: 16px;
    position: relative;
    z-index: 1;
    border: 1px solid rgba(255, 255, 255, 0.05);
    /* Fallback */
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    transition: all 0.7s ease;
    /* Slow fade effect */
    backdrop-filter: blur(12px);
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
    overflow: hidden;
}

/* Gradient Border Effect via Pseudo-element */
.service-card::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 16px;
    padding: 2px;
    /* Border width */
    background: linear-gradient(45deg, rgba(255, 255, 255, 0.1), transparent, rgba(255, 255, 255, 0.05));
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask-composite: exclude;
    pointer-events: none;
    transition: all 0.7s ease;
}

.service-card:hover {
    transform: translateY(-3px) scale(1.01);
    /* Very subtle lift */
    background: rgba(30, 41, 59, 1);
    /* Fade to solid */
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.4), 0 0 20px rgba(139, 92, 246, 0.15);
    /* Soft glow */
    border-color: rgba(139, 92, 246, 0.4);
}

.service-card:hover::before {
    background: var(--accent-gradient);
    opacity: 1;
}

.service-icon-wrapper {
    position: relative;
    overflow: hidden;
    transition: transform 0.4s ease;
    /* Transform only, color on svg */
    color: #a78bfa;
    /* Default purple */
    filter: drop-shadow(0 0 8px rgba(139, 92, 246, 0.4));
}

.service-card:hover .service-icon-wrapper {
    /* Color handled by SVG stroke */
    transform: scale(1.1);
    filter: drop-shadow(0 0 15px rgba(139, 92, 246, 0.6));
}

.service-icon {
    width: 60px;
    height: 60px;
    stroke: currentColor;
    transition: stroke 0.4s ease;
}

/* Apply Gradient Stroke on Hover */
.service-card:hover .service-icon {
    stroke: url(#brand-gradient);
    /* Reference the SVG Def */
    color: #fff;
    /* Fallback */
}

.service-title {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
}