:root { 
    --faq-primary: #2a6de9;
}

/* Container */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Wrapper */
.faq-wrapper {
    padding: 40px 0;
}

/* Header */
.faq-header {
    text-align: center;
    margin-bottom: 35px;
    color: #070063;
    max-width: 1200px;
}

.faq-header h1 {
    font-size: 40px;
    font-weight: 700;
    margin-bottom: 12px;
}

.faq-slogan {
    font-size: 18px;
    color: #555;
    max-width: 1400px;
    margin: 0 auto;
    line-height: 1.7;
    white-space: nowrap;
}

/* On small screens allow normal wrapping */
@media (max-width: 768px) {
    .faq-slogan {
        white-space: normal;
    }
}

/* ================= STICKY ================= */

.faq-sticky-outer {
    position: sticky;
    top: 90px;
    z-index: 100;
    background: transparent;
    padding: 15px 0;
    transition: 0.3s ease;
}

.faq-sticky-outer.sticky-active {
    background: #fff;
    border-bottom: 1px solid #eee;
}

/* ================= DESKTOP CATEGORY ================= */

.faq-menu {
    display: flex;
    gap: 35px;
    overflow-x: auto;
    white-space: nowrap;              /* prevent wrap */
}

.faq-link {
    text-decoration: none;
    font-size: 17px;
    font-weight: 500;
    color: #777;
    white-space: nowrap;              /* single line */
    transition: 0.3s ease;
}

/* Hover + Active same style */
.faq-link:hover,
.faq-link.active {
    color: var(--faq-primary);
    font-weight: 700;
}

/* Active underline when section reached */
.faq-link.active {
    border-bottom: 2px solid var(--faq-primary);
    padding-bottom: 4px;
}

/* ================= MOBILE DROPDOWN ================= */

.faq-mobile-menu {
    display: none;
}

.mobile-toggle {
    width: 100%;
    padding: 12px;
    font-size: 16px;
    font-weight: 600;
    border: 1px solid #ddd;
    background: #f3f3f3;
    cursor: pointer;
    border-radius: 6px;
}

.mobile-category-list {
    display: none;
    margin-top: 5px;
    border: 1px solid #ddd;
    border-radius: 6px;
    background: #fff;
}

.mobile-category-list a {
    display: block;
    padding: 10px;
    text-decoration: none;
    color: #333;
    transition: 0.3s ease;
}

.mobile-category-list a:hover,
.mobile-category-list a.active {
    color: var(--faq-primary);
    font-weight: 700;
}

/* ================= SEARCH ================= */

.faq-search-wrapper {
    margin-top: 15px;
}

.search-box {
    position: relative;
}

#faqSearch {
    width: 100%;
    padding: 10px 40px 10px 14px;
    border: 1px solid #ddd;
    border-radius: 6px;
}

.search-clear {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 18px;
    cursor: pointer;
    display: none;
    color: #888;
}

/* ================= FAQ SECTION ================= */

.faq-category-section {
    margin: 70px 0;
    scroll-margin-top: 160px; /* important for mobile offset */
}

.category-title {
    font-size: 24px;
    margin-bottom: 20px;
    color: #070063;
    font-weight: bold;
}

/* Card */
.faq-item {
    border: 1px solid #e5e5e5;
    border-radius: 8px;
    padding: 16px;
    margin-bottom: 15px;
    background: #fff;
    transition: border 0.3s ease, box-shadow 0.3s ease;
}


.faq-item:hover {
    border-color: var(--faq-primary);
}


.faq-item.active {
    border: 2px solid var(--faq-primary);
}

.faq-question {
    display: flex;
    justify-content: space-between;
    cursor: pointer;
    font-weight: 600;
}

.faq-answer {
    display: none;
    margin-top: 10px;
    color: #444;
}

.faq-item.active .faq-answer {
    display: block;
}

/* ================= MOBILE ================= */

@media (max-width: 991px) {

    .faq-menu {
        display: none;
    }

    .faq-mobile-menu {
        display: block;
        margin-bottom: 10px;
    }

    .faq-sticky-outer {
        top: 80px;
    }
}

/* Only desktop sticky white background */
@media (max-width: 991px) {
    .faq-sticky-outer.sticky-active {
        background: transparent;
        border-bottom: none;
    }

}

/* ================= MOBILE & TABLET RESPONSIVE IMPROVEMENTS ================= */

@media (max-width: 991px) {

    /* Reduce wrapper vertical spacing */
    .faq-wrapper {
        padding: 2px 0;   /* top & bottom 2px only */
    }

    /* Reduce container vertical spacing */
    .container {
        padding-top: 2px;
        padding-bottom: 2px;
    }

    /* Adjust main title size for mobile/tablet */
    .faq-header h1 {
        font-size: 26px;   /* Standard mobile readable size */
        line-height: 1.3;
    }

    /* Adjust slogan text */
    .faq-slogan {
        font-size: 15px;
        line-height: 1.6;
    }

    /* Reduce category title size */
    .category-title {
        font-size: 20px;
    }
}


/* Extra small devices (small mobiles) */
@media (max-width: 576px) {

    .faq-header h1 {
        font-size: 22px;
    }

    .faq-slogan {
        font-size: 14px;
    }

    .category-title {
        font-size: 18px;
    }

    .container {
        padding-top: 1px;
        padding-bottom: 1px;
    }
}

@media (max-width: 991px) {

    .faq-wrapper {
        padding: 20px 0;
    }

    .faq-header {
        margin-bottom: 10px;
    }

    .faq-sticky-outer {
        padding: 6px 0;
    }

    .faq-category-section {
        margin: 25px 0;
    }

}

@media (max-width: 576px) {

    .faq-wrapper {
        padding: 16px 0;
    }

    .faq-header {
        margin-bottom: 8px;
    }

    .faq-header h1 {
        font-size: 22px;
        line-height: 1.3;
    }

    .faq-slogan {
        font-size: 14px;
        margin-bottom: 6px;
    }

    .faq-sticky-outer {
        padding: 5px 0;
    }

    .faq-category-section {
        margin: 18px 0;
    }
}

@media (max-width: 400px) {

    .faq-wrapper {
        padding: 12px 0;
    }

    .faq-header h1 {
        font-size: 20px;
    }

    .faq-slogan {
        font-size: 13px;
    }

    .faq-category-section {
        margin: 15px 0;
    }

    .faq-sticky-outer {
        padding: 4px 0;
    }
}

/* ============================= */
/* FAQ GLOBAL EMPTY MESSAGE */
/* ============================= */

.faq-empty-global {
    text-align: center;
    padding: 60px 20px;
    margin: 60px 0;
    background: #f8f9ff;
    border: 1px dashed var(--faq-primary);
    border-radius: 12px;
}

.faq-empty-global h3 {
    font-size: 22px;
    margin-bottom: 10px;
    color: var(--faq-primary);
}

.faq-empty-global p {
    font-size: 16px;
    color: #555;
}

/* FAQ Contact CTA */
    .faq-contact-inner {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    text-align: center;
}

.faq-contact-title {
    font-size: clamp(22px, 3vw, 32px); /* Responsive standard size */
    font-weight: 700;
    color: #0f2a3c;
    margin-bottom: 25px;
    line-height: 1.3;
}

.faq-contact-button {
    display: inline-block;
    background: linear-gradient(90deg, #280b92, #3b53bd);
    color: #ffffff;
    padding: 12px 28px;
    border-radius: 40px;
    font-weight: 600;
    text-decoration: none;
    font-size: 14px;
    letter-spacing: 0.5px;
    transition: 0.3s ease;
}

.faq-contact-button:hover {
    opacity: 0.9;
}

/* Mobile & Tablet */
@media (max-width: 1024px) {
    .faq-contact-inner {
        align-items: center;
        text-align: center;
    }
}