/**
 * FAQ Page Styles — Figma-exact two-column redesign
 * Category sidebar, search bar, grouped accordion sections, mobile bottom sheet
 */

/* ==========================================
   SECTION 1 — FAQ MAIN CONTAINER & TITLE
   ========================================== */

.faq-main {
    padding: 0 150px;
    padding-top: 48px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 48px;
    height: calc(100vh - 100px);
    overflow: hidden;
}

.faq-header {
    display: flex;
    flex-direction: column;
    gap: 20px;
    width: 100%;
    flex-shrink: 0;
}

.faq-title {
    font-family: 'Canela Text', Georgia, serif;
    font-size: 64px;
    font-weight: 400;
    line-height: 73px;
    color: #2D1F1F;
    text-transform: capitalize;
    margin: 0;
}

.faq-subtitle {
    font-family: 'Inter', sans-serif;
    font-size: 16px;
    font-weight: 400;
    line-height: 20px;
    color: #666666;
    margin: 0;
}

/* ==========================================
   SECTION 2 — TWO-COLUMN LAYOUT
   ========================================== */

.faq-columns {
    display: flex;
    gap: 48px;
    width: 100%;
    flex: 1;
    min-height: 0;
    overflow: hidden;
}

.faq-sidebar {
    width: 431px;
    flex-shrink: 0;
    overflow-y: auto;
}

.faq-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 24px;
    min-width: 0;
    min-height: 0;
}

.faq-sections {
    flex: 1;
    overflow-y: auto;
    padding-bottom: 48px;
}

/* ==========================================
   SECTION 3 — SIDEBAR CATEGORY NAVIGATION
   ========================================== */

.faq-sidebar-nav {
    border: 1px solid #E0DCD3;
    border-radius: 20px;
    overflow: hidden;
}

.faq-sidebar-item {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    padding: 12px 20px;
    height: 48px;
    border-bottom: 1px solid #E0DCD3;
    cursor: pointer;
    font-family: 'Inter', sans-serif;
    font-size: 16px;
    font-weight: 500;
    color: rgba(45, 31, 31, 0.7);
    background: #fff;
    box-sizing: border-box;
    transition: all 0.2s ease;
    user-select: none;
}

.faq-sidebar-item:last-child {
    border-bottom: none;
}

.faq-sidebar-item:hover {
    color: #2D1F1F;
}

.faq-sidebar-item.active {
    font-weight: 600;
    color: #2D1F1F;
    border-bottom: 2px solid #2D1F1F;
}

.faq-sidebar-item svg {
    flex-shrink: 0;
    width: 20px;
    height: 20px;
}

/* ==========================================
   SECTION 4 — SEARCH BAR
   ========================================== */

/* Search bar inside faq-content (desktop) */
.faq-search-wrap {
    flex-shrink: 0;
    background: #fff;
    padding-bottom: 4px;
}

/* Search bar inside faq-header (mobile sticky) — hidden on desktop */
.faq-search-wrap--header {
    display: none;
    position: static;
    padding-bottom: 0;
}

@media (max-width: 767px) {
    .faq-search-wrap--header {
        display: block;
    }
    .faq-content > .faq-search-wrap {
        display: none;
    }
}

.faq-search {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 12px;
    border: 1px solid rgba(45, 31, 31, 0.1);
    border-radius: 8px;
    padding: 8px 12px;
    height: 48px;
    box-sizing: border-box;
}

.faq-search svg {
    flex-shrink: 0;
    width: 24px;
    height: 24px;
}

.faq-search input {
    border: none;
    outline: none;
    flex: 1;
    font-family: 'Inter', sans-serif;
    font-size: 14px;
    font-weight: 600;
    color: #2D1F1F;
    background: transparent;
}

.faq-search input::placeholder {
    color: rgba(26, 26, 26, 0.4);
}

/* ==========================================
   SECTION 5 — FAQ SECTIONS & ITEMS
   ========================================== */

.faq-sections {
    display: flex;
    flex-direction: column;
    gap: 48px;
}

.faq-section-group {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.faq-section-title {
    font-family: 'Inter', sans-serif;
    font-size: 24px;
    font-weight: 600;
    line-height: 29px;
    text-transform: uppercase;
    color: #2D1F1F;
    letter-spacing: -0.02em;
    margin: 0;
}

.faq-items-container {
    background: #E0DCD3;
    /* border: 1px solid #E0DCD3; */
    border-radius: 16px;
    padding: 1px;
    display: flex;
    flex-direction: column;
    gap: 1px;
    overflow: hidden;
}

.faq-item {
    background: #fff;
    padding: 24px;
    display: flex;
    flex-direction: column;
}

.faq-item:first-child {
    border-radius: 15px 15px 0 0;
}

.faq-item:last-child {
    border-radius: 0 0 15px 15px;
}

.faq-item:only-child {
    border-radius: 15px;
}

.faq-question {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 24px;
    width: 100%;
    background: none;
    border: none;
    cursor: pointer;
    font-family: 'Inter', sans-serif;
    font-size: 20px;
    font-weight: 600;
    color: #2D1F1F;
    text-transform: capitalize;
    text-align: left;
    padding: 0;
    line-height: 24px;
}

.faq-question-text {
    flex: 1;
}

.faq-chevron {
    width: 24px;
    height: 24px;
    flex-shrink: 0;
    transition: transform 0.3s ease;
}

.faq-item.active .faq-chevron {
    transform: rotate(180deg);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease;
}

.faq-item.active .faq-answer {
    max-height: 600px;
}

.faq-answer-inner {
    padding-top: 16px;
}

.faq-answer p {
    font-family: 'Inter', sans-serif;
    font-size: 16px;
    font-weight: 400;
    line-height: 20px;
    color: #2D1F1F;
    margin: 0;
    max-width: 751px;
}

.faq-answer p + p {
    margin-top: 12px;
}

/* Hidden sections/items during search */
.faq-section-group.faq-hidden,
.faq-item.faq-hidden {
    display: none;
}

/* No results empty state */
.faq-no-results {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 80px 24px;
    gap: 8px;
}

.faq-no-results-title {
    font-family: 'Inter', sans-serif;
    font-size: 20px;
    font-weight: 600;
    color: #2D1F1F;
    margin: 0;
}

.faq-no-results-text {
    font-family: 'Inter', sans-serif;
    font-size: 14px;
    font-weight: 400;
    line-height: 20px;
    color: #666666;
    margin: 0;
    max-width: 320px;
}

/* ==========================================
   SECTION 6 — MOBILE BOTTOM SHEET
   ========================================== */

.faq-mobile-bar {
    position: fixed;
    bottom: 20px;
    left: 16px;
    right: 16px;
    z-index: 10000;
    border: 1px solid #E0DCD3;
    border-radius: 8px;
    background: #fff;
    padding: 12px 16px;
    display: none;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
}

.faq-mobile-bar-label {
    font-family: 'Inter', sans-serif;
    font-size: 14px;
    font-weight: 600;
    color: #2D1F1F;
}

.faq-mobile-bar svg {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

.faq-mobile-bar-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: rgba(45, 31, 31, 0.1);
    border-radius: 0 0 7px 7px;
    overflow: hidden;
}

.faq-mobile-bar-progress-fill {
    height: 100%;
    background: #2D1F1F;
    width: 0%;
    transition: width 0.3s ease;
}

.faq-mobile-overlay {
    position: fixed;
    inset: 0;
    z-index: 200;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    display: none;
    align-items: center;
    justify-content: center;
    padding: 24px;
}

.faq-mobile-overlay.active {
    display: flex;
}

.faq-mobile-overlay-card {
    background: #fff;
    border: 1px solid #E0DCD3;
    border-radius: 20px;
    overflow: hidden;
    width: 100%;
    max-width: 400px;
    max-height: 70vh;
    overflow-y: auto;
}

.faq-mobile-overlay-item {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    padding: 12px 20px;
    min-height: 48px;
    height: auto;
    border-bottom: 1px solid #E0DCD3;
    cursor: pointer;
    font-family: 'Inter', sans-serif;
    font-size: 16px;
    font-weight: 500;
    color: rgba(45, 31, 31, 0.7);
    background: #fff;
    box-sizing: border-box;
    transition: all 0.2s ease;
}

.faq-mobile-overlay-item:last-child {
    border-bottom: none;
}

.faq-mobile-overlay-item.active {
    font-weight: 600;
    color: #2D1F1F;
    pointer-events: none;
}

.faq-mobile-overlay-item.active svg {
    display: none;
}

.faq-mobile-overlay-item svg {
    flex-shrink: 0;
    width: 20px;
    height: 20px;
}

/* ==========================================
   SECTION 7 — FAQ PAGE CONTACT FORM OVERRIDES
   ========================================== */

.faq-page-body .contact-form-section {
    background: #2D1F1F;
    padding: 96px 0;
}

.faq-page-body .contact-form-inner {
    max-width: 1620px;
    margin: 0 auto;
    padding: 0 150px;
}

/* ==========================================
   RESPONSIVE — MOBILE (max-width: 767px)
   ========================================== */

@media (max-width: 767px) {
    .faq-main {
        padding: 48px 24px 24px;
        height: auto;
        overflow: visible;
    }

    .faq-header {
        position: sticky;
        top: 54px;
        z-index: 11;
        background: #fff;
        padding-top: 12px;
        padding-bottom: 12px;
    }

    .faq-columns {
        overflow: visible;
        flex: none;
    }

    .faq-content {
        overflow-y: visible;
        padding-bottom: 0;
    }

    .faq-sections {
        overflow-y: visible;
        padding-bottom: 0;
    }

    .faq-title {
        font-size: 32px;
        line-height: 36px;
    }

    .faq-subtitle {
        font-size: 14px;
        line-height: 24px;
    }

    .faq-columns {
        flex-direction: column;
        gap: 24px;
    }

    .faq-sidebar {
        display: none;
    }

    .faq-mobile-bar {
        display: flex;
    }

    .faq-section-title {
        font-size: 20px;
        line-height: 28px;
    }

    .faq-item {
        padding: 20px;
    }

    .faq-question {
        font-size: 16px;
        line-height: 24px;
        gap: 16px;
    }

    .faq-answer p {
        font-size: 14px;
        line-height: 24px;
    }

    /* Contact form mobile overrides */
    .faq-page-body .contact-form-section {
        padding: 48px 0;
    }

    .faq-page-body .contact-form-inner {
        padding: 0 24px;
        flex-direction: column;
        gap: 48px;
    }

    .faq-page-body .contact-form-intro h2 {
        font-size: 32px;
        line-height: 36px;
    }

    .faq-page-body .contact-form-intro-text p {
        font-size: 14px;
        line-height: 24px;
    }

    .faq-page-body .contact-form-wrapper {
        flex: none;
        width: 100%;
    }

    .faq-page-body .contact-form-wrapper .wpcf7-form {
        grid-template-columns: 1fr;
        gap: 8px;
    }

    .faq-page-body .contact-form-wrapper textarea {
        height: 132px;
    }

    .faq-page-body .contact-bottom-row {
        flex-direction: column;
        gap: 24px;
    }

    .faq-page-body .contact-toggle {
        width: 100%;
    }

    .faq-page-body .contact-toggle-pill {
        flex: 1 1 auto;
        text-align: center;
    }

    .faq-page-body .contact-submit-custom {
        width: 100%;
    }
}
