/* FAQ Carousel Styles */
.faq-carousel-section {
    padding: 100px 0;
    overflow: hidden;
    /* Hide overflow for carousel */
    background: #f8fafc;
    /* Light background for the section */
}

.faq-header-container {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 3rem;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
    padding: 0 2rem;
}

.faq-carousel-wrapper {
    width: 100%;
    /* overflow-x: auto;  Custom scroll handling via JS/CSS transform */
    display: flex;
    justify-content: center;
    /* Center the active card */
    padding: 2rem 0;
}

.faq-track {
    display: flex;
    gap: 2rem;
    transition: transform 0.5s cubic-bezier(0.25, 1, 0.5, 1);
    /* Ensure track is wide enough */
}

.faq-card {
    flex: 0 0 320px;
    /* Fixed width for cards */
    height: 420px;
    background: #ffffff;
    border-radius: 24px;
    padding: 2.5rem;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    /* Text at bottom by default */
    transition: all 0.5s cubic-bezier(0.25, 1, 0.5, 1);
    cursor: pointer;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    border: 1px solid transparent;
    position: relative;
    overflow: hidden;
}

/* Active State - Expanded and Green */
.faq-card.active {
    flex: 0 0 380px;
    /* Slightly wider */
    background: var(--color-primary, #84CC16);
    color: #ffffff;
    justify-content: center;
    /* Center content vertically */
    transform: scale(1.05);
    box-shadow: 0 20px 40px rgba(132, 204, 22, 0.3);
    border-color: rgba(255, 255, 255, 0.2);
}

.faq-card:not(.active) {
    background: #e2e8f0;
    /* Light gray for inactive */
    color: #475569;
}

.faq-card:not(.active):hover {
    background: #cbd5e1;
}


/* Content Styling */
.faq-question {
    font-family: var(--font-primary, sans-serif);
    font-size: 1.5rem;
    font-weight: 600;
    line-height: 1.3;
    margin-bottom: 0;
    transition: all 0.3s ease;
}

.faq-card.active .faq-question {
    margin-bottom: 1.5rem;
    /* Space for answer */
    font-size: 1.75rem;
}

.faq-answer {
    font-size: 1rem;
    line-height: 1.6;
    opacity: 0;
    height: 0;
    overflow: hidden;
    transform: translateY(20px);
    transition: all 0.5s ease;
}

.faq-card.active .faq-answer {
    opacity: 1;
    height: auto;
    transform: translateY(0);
}

/* Navigation Buttons */
.faq-nav-btn {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: 1px solid #cbd5e1;
    background: white;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
    color: #0f172a;
}

.faq-nav-btn:hover {
    background: #f1f5f9;
    border-color: #94a3b8;
}

.faq-nav-group {
    display: flex;
    gap: 1rem;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .faq-track {
        flex-direction: row;
        overflow-x: auto;
        padding-bottom: 20px;
        scroll-snap-type: x mandatory;
        gap: 1rem;
        width: 100%;
        transform: none !important;
        /* Disable JS transform on mobile, use native scroll */
    }

    .faq-carousel-wrapper {
        display: block;
        padding: 0;
    }

    .faq-card {
        flex: 0 0 85vw;
        /* Full width minus spacing */
        height: 380px;
        scroll-snap-align: center;
    }

    .faq-card.active {
        flex: 0 0 85vw;
        transform: none;
    }

    .faq-header-container {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
}