/* ============================================
   COMITARI - PREMIUM SERVICES SHOWCASE
   A cinematic layout for high-end RH services
   Optimisé par Improved Agency
   ============================================ */

.services-showcase-section {
    padding: var(--space-4xl) 0;
    background: #0f172a;
    color: white;
    position: relative;
    overflow: hidden;
}

.showcase-bg-glow {
    position: absolute;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, var(--primary-blue-glow) 0%, transparent 70%);
    filter: blur(80px);
    opacity: 0.2;
    pointer-events: none;
    transition: all 1.2s cubic-bezier(0.23, 1, 0.32, 1);
    z-index: 1;
}

.showcase-container {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: var(--space-4xl);
    align-items: flex-start;
    /* Logic: align to start to avoid jumping if height changes */
    position: relative;
    z-index: 2;
}

/* Left Content - Master View */
.showcase-master {
    position: relative;
    min-height: 550px;
    /* Increased for better stability */
    display: flex;
    flex-direction: column;
    justify-content: center;
    transition: height 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.showcase-content-item {
    position: absolute;
    top: 50%;
    /* Center vertically within the set min-height */
    left: 0;
    right: 0;
    transform: translateY(-50%) translateY(30px);
    opacity: 0;
    visibility: hidden;
    transition: all 0.7s cubic-bezier(0.23, 1, 0.32, 1);
    pointer-events: none;
}

.showcase-content-item.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(-50%) translateY(0);
    pointer-events: auto;
}

.showcase-icon-large {
    width: 100px;
    height: 100px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: var(--space-xl);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: var(--secondary-green);
    box-shadow: 0 10px 30px -5px rgba(0, 0, 0, 0.3);
}

.showcase-title {
    font-size: clamp(2.5rem, 5vw, 3.8rem);
    font-weight: 800;
    margin-bottom: var(--space-lg);
    line-height: 1.05;
    background: linear-gradient(135deg, #ffffff 0%, #cbd5e1 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: -0.02em;
}

.showcase-description {
    font-size: 1.2rem;
    color: #94a3b8;
    margin-bottom: var(--space-2xl);
    line-height: 1.7;
    max-width: 600px;
}

.showcase-features-list {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-md) var(--space-xl);
    margin-bottom: var(--space-2xl);
    list-style: none;
    padding: 0;
}

.showcase-features-list li {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.05rem;
    color: #e2e8f0;
    padding: 8px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.showcase-features-list li span {
    color: var(--secondary-green);
    font-weight: bold;
    font-size: 1.2rem;
}

/* Right Navigation - Selection List */
.showcase-nav {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.showcase-nav-item {
    padding: 1.5rem;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    gap: 1.25rem;
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(5px);
}

.showcase-nav-item:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.1);
    transform: translateX(5px);
}

.showcase-nav-item.active {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(55, 142, 86, 0.3);
    transform: translateX(12px);
    box-shadow: 0 10px 20px -5px rgba(0, 0, 0, 0.2);
}

.showcase-nav-item::after {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background: var(--secondary-green);
    transform: scaleY(0);
    transition: transform 0.4s ease;
}

.showcase-nav-item.active::after {
    transform: scaleY(1);
}

.nav-item-icon {
    width: 44px;
    height: 44px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
    font-size: 0.9rem;
    color: #64748b;
    transition: all 0.4s ease;
}

.showcase-nav-item.active .nav-item-icon {
    background: var(--secondary-green);
    border-color: var(--secondary-green);
    color: white;
    box-shadow: 0 0 15px rgba(55, 142, 86, 0.4);
}

.nav-item-text h4 {
    font-size: 1.15rem;
    font-weight: 600;
    margin-bottom: 0.2rem;
    color: #e2e8f0;
    transition: color 0.4s ease;
}

.nav-item-text p {
    font-size: 0.85rem;
    color: #64748b;
    margin: 0;
}

.showcase-nav-item.active .nav-item-text h4 {
    color: white;
}

/* Progress Bar on Nav Item */
.nav-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 2px;
    background: rgba(255, 255, 255, 0.05);
    width: 100%;
}

.nav-progress-fill {
    height: 100%;
    background: var(--secondary-green);
    width: 0%;
}

.showcase-nav-item.active .nav-progress-fill {
    animation: progressFill 6s linear forwards;
}

@keyframes progressFill {
    from {
        width: 0%;
    }

    to {
        width: 100%;
    }
}

/* Mobile Responsive */
@media (max-width: 1024px) {
    .showcase-container {
        grid-template-columns: 1fr;
        gap: var(--space-2xl);
    }

    .showcase-master {
        min-height: 450px;
        text-align: center;
    }

    .showcase-content-item {
        display: flex;
        flex-direction: column;
        align-items: center;
        transform: translateY(0) translateY(20px);
    }

    .showcase-content-item.active {
        transform: translateY(0);
        position: relative;
        /* Switch to relative on mobile for flow */
        top: 0;
    }

    .showcase-icon-large {
        width: 80px;
        height: 80px;
        margin: 0 auto 1.5rem;
    }

    .showcase-features-list {
        grid-template-columns: 1fr;
        max-width: 400px;
        margin-left: auto;
        margin-right: auto;
    }

    .showcase-nav {
        flex-direction: row;
        overflow-x: auto;
        padding-bottom: 1rem;
        scroll-snap-type: x mandatory;
        gap: 0.75rem;
        -webkit-overflow-scrolling: touch;
    }

    .showcase-nav-item {
        flex: 0 0 260px;
        scroll-snap-align: center;
        padding: 1rem;
    }

    .showcase-nav-item.active {
        transform: none;
    }
}