/* ============================================================
   SERVICES PAGE — services.css
   ============================================================ */



/* ============================================================
   HORIZONTAL SCROLL GALLERY (Six Solutions)
   ============================================================ */

.srv-horiz-section {
    position: relative;
    overflow: hidden;
    background: #F6F6F6;
    padding: 0;
}

.srv-horiz-container {
    width: 100%;
    /* Remove padding to allow images to touch edges if desired, or keep some padding */
    padding-right: 0;
    padding-left: 0;
    margin-right: auto;
    margin-left: auto;
}

.horiz-gallery-wrapper {
    display: flex;
    flex-wrap: nowrap;
    position: relative;
    height: 100vh; /* Make it full height for pinning */
    align-items: center; /* Center the strip vertically */
}

.horiz-gallery-strip {
    display: flex;
    flex-wrap: nowrap;
    will-change: transform;
    position: relative;
    height: 100%; /* Take full height of wrapper to center content */
    align-items: center;
}

.project-wrap {
    width: 28vw; /* Adjust width as needed for desktop */
    min-width: 280px;
    max-width: 420px;
    padding: 1.5rem;
    box-sizing: content-box;
    position: relative;
    transition: transform 0.3s ease;
}

.project-wrap:hover {
    transform: translateY(-10px);
}

.project-wrap img {
    width: 100%;
    aspect-ratio: 4/3; /* or 1/1 like CodePen, but 4/3 is better for these images */
    object-fit: cover;
    border-radius: 16px;
    box-shadow: 0 16px 40px rgba(0,0,0,0.15); /* lightened shadow for white bg */
    display: block;
}

/* ── Content Overlay on Cards ────────────────────────────────── */
.project-content {
    position: absolute;
    bottom: 1.5rem; /* match padding */
    left: 1.5rem;
    right: 1.5rem;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.95) 0%, rgba(0, 0, 0, 0.8) 50%, rgba(0, 0, 0, 0.4) 80%, transparent 100%);
    padding: 3rem 1.5rem 1.5rem;
    border-bottom-left-radius: 16px;
    border-bottom-right-radius: 16px;
    color: #fff;
    pointer-events: none; /* Let clicks pass through to the link */
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}

.project-content h3 {
    font-size: 1.35rem;
    font-weight: 700;
    margin: 0 0 0.5rem;
    color: #fff;
    text-shadow: 0 2px 4px rgba(0,0,0,0.6);
}

.project-content p {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.95);
    margin: 0 0 1rem;
    line-height: 1.5;
    text-shadow: 0 1px 3px rgba(0,0,0,0.6);
}

/* Make the whole card clickable */
.project-wrap > a {
    display: block;
    width: 100%;
    height: 100%;
    text-decoration: none;
    position: relative;
}

/* CTA link styling inside overlay */
.project-cta {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: #c084fc;
    pointer-events: auto; /* clickable */
    transition: gap 0.2s ease, color 0.2s ease;
}

.project-wrap > a:hover .project-cta {
    gap: 0.75rem;
    color: #fff;
}

.project-cta svg {
    width: 16px;
    height: 16px;
    transition: transform 0.2s ease;
}

/* ── Heading block at the start of scroll ────────────────────── */
.horiz-intro {
    width: 45vw;
    min-width: 350px;
    max-width: 500px;
    padding: 0 4rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    color: #1f2937; /* Dark text for white bg */
}

.horiz-intro .eyebrow {
    margin-bottom: 1rem;
    /* Inherit display: inline-flex from global .eyebrow */
}

.horiz-intro h2 {
    font-size: clamp(1.6rem, 3vw, 2.2rem);
    font-weight: 700;
    line-height: 1.2;
    margin: 0 0 0.75rem;
    color: var(--color-heading);
}

.horiz-intro p {
    font-size: 1.0625rem;
    color: var(--color-body);
    line-height: 1.75;
    margin: 0;
}

/* ── Responsive ≤768px: Native Horizontal Scroll ───────────────── */
@media (max-width: 768px) {
    .horiz-gallery-wrapper {
        height: auto;
        display: block;
    }
    
    .horiz-gallery-strip {
        display: flex;
        flex-direction: row;
        height: auto;
        padding: 4rem 1.5rem;
        gap: 1.5rem;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        scroll-padding-inline: 1.5rem;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none; /* Hide scrollbar Firefox */
    }
    
    .horiz-gallery-strip::-webkit-scrollbar {
        display: none; /* Hide scrollbar Chrome/Safari/Edge */
    }

    .horiz-intro {
        width: 85vw;
        min-width: 300px;
        padding: 0;
        text-align: left;
        scroll-snap-align: start;
        flex-shrink: 0;
    }

    .project-wrap {
        width: 85vw;
        min-width: 280px;
        max-width: 100%;
        padding: 0;
        scroll-snap-align: start;
        flex-shrink: 0;
    }

    .horiz-final-cta {
        padding: 0 1.5rem !important;
        scroll-snap-align: start;
        flex-shrink: 0;
    }

    .project-wrap:hover {
        transform: none; /* disable hover translation on mobile */
    }

    .project-content {
        bottom: 0;
        left: 0;
        right: 0;
    }
}


/* Subtle dot-grid background texture */
.srv-sol-bg-dot {
    position: absolute;
    inset: 0;
    background-image:
        radial-gradient(circle, rgba(78, 26, 101, 0.06) 1px, transparent 1px);
    background-size: 32px 32px;
    pointer-events: none;
    z-index: 0;
}

/* Section Header */
.srv-sol-header {
    text-align: center;
    max-width: 660px;
    margin: 0 auto 4rem;
    position: relative;
    z-index: 1;
}

.srv-sol-h2 {
    font-size: clamp(1.75rem, 3.5vw, 2.5rem);
    font-weight: 800;
    color: var(--color-heading);
    line-height: 1.2;
    margin-bottom: 1rem;
    letter-spacing: -0.02em;
}

.srv-sol-sub {
    font-size: 1.0625rem;
    color: var(--color-body);
    line-height: 1.75;
}

/* ─── Services Grid ─────────────────────────────────────────── */
.srv-sol-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.75rem;
    position: relative;
    z-index: 1;
}

/* ─── Service Card ───────────────────────────────────────────── */
.srv-card {
    display: flex;
    flex-direction: column;
    background: #fff;
    border: 1px solid rgba(78, 26, 101, 0.1);
    border-radius: 20px;
    padding: 2rem 2rem 1.75rem;
    box-shadow: 0 2px 16px rgba(78, 26, 101, 0.06);
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
    position: relative;
    overflow: hidden;
}

.srv-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--gradient-primary);
    opacity: 0;
    transition: opacity 0.25s ease;
    border-radius: 20px 20px 0 0;
}

.srv-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 16px 48px rgba(78, 26, 101, 0.14);
    border-color: rgba(78, 26, 101, 0.25);
}

.srv-card:hover::before {
    opacity: 1;
}

/* ─── Card Image ─────────────────────────────────────────────── */
.srv-card-img-link {
    display: block;
    text-decoration: none;
}

.srv-card-img-wrap {
    position: relative;
    overflow: hidden;
    border-radius: 14px 14px 0 0;
    margin: -2rem -2rem 0; /* bleed to card edges */
    height: 200px;
    background: #1a0524;
}

.srv-card-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease;
}

.srv-card:hover .srv-card-img {
    transform: scale(1.05);
}

.srv-card-img-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to bottom,
        rgba(78, 26, 101, 0.15) 0%,
        rgba(26, 5, 36, 0.55) 100%
    );
    z-index: 1;
    transition: opacity 0.3s ease;
}

.srv-card:hover .srv-card-img-overlay {
    opacity: 0.75;
}

/* Floating icon badge over the image */
.srv-card-badge {
    position: absolute;
    bottom: -20px;
    left: 1.5rem;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: var(--gradient-primary);
    color: #fff;
    box-shadow: 0 4px 14px rgba(78, 26, 101, 0.4);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.srv-card-badge svg {
    width: 22px;
    height: 22px;
}

.srv-card:hover .srv-card-badge {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(78, 26, 101, 0.5);
}

/* ─── Card Body ──────────────────────────────────────────────── */
.srv-card-body {
    display: flex;
    flex-direction: column;
    flex: 1;
    padding-top: 1.75rem; /* space for the floating badge */
}

.srv-card-h3 {
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--color-heading);
    margin-bottom: 0.75rem;
    line-height: 1.3;
}

.srv-card-desc {
    font-size: 0.9375rem;
    color: var(--color-body);
    line-height: 1.7;
    flex: 1;
    margin-bottom: 1.5rem;
}

/* ─── Card CTA Link ──────────────────────────────────────────── */
.srv-card-cta {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-family: var(--font-primary);
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--color-primary);
    text-decoration: none;
    transition: gap 0.2s ease, color 0.2s ease;
    margin-top: auto;
}

.srv-card-cta svg {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    transition: transform 0.2s ease;
}

.srv-card-cta:hover {
    color: #4E1A65;
    gap: 0.65rem;
}

.srv-card-cta:hover svg {
    transform: translateX(3px);
}

/* ─── Section Footer CTA ─────────────────────────────────────── */
.srv-sol-footer-cta {
    text-align: center;
    margin-top: 4rem;
}

/* ─── Responsive ─────────────────────────────────────────────── */
@media (max-width: 1024px) {
    .srv-sol-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 640px) {
    .srv-solutions-section {
        padding: 4rem 0 3.5rem;
    }

    .srv-sol-grid {
        grid-template-columns: 1fr;
        gap: 1.25rem;
    }

    .srv-card {
        padding: 1.5rem;
    }

    .srv-sol-h2 {
        font-size: 1.625rem;
    }
}
