.modern-faq-wrapper {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 25px 15px 60px 15px;
    direction: rtl;
    text-align: right;
    box-sizing: border-box;
    /* جلوگیری از بالا پریدن فوتر در مانیتورهای بزرگ */
    min-height: 85vh;
    display: flex;
    flex-direction: column;
}

/* ------------------- تب‌های ناوبری (دارک و طلایی) ------------------- */
.faq-tabs-nav {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
    margin-bottom: 45px;
}

.faq-tab-btn {
    background: #2fbeaa;
    color: #e2e8f0;
    border: 1px solid rgba(210, 160, 56, 0.25);
    padding: 12px 22px;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    outline: none;
    box-shadow: 0 4px 12px rgba(2, 3, 27, 0.15);
}

.faq-tab-btn i {
    color: #fff;
    font-size: 15px;
    transition: transform 0.3s ease;
}

.faq-tab-btn:hover {
    background: #2fbeaa;
    border-color: #27ab99;
    transform: translateY(-2px);
    color: #ffffff;
}

.faq-tab-btn.active {
    background: linear-gradient(135deg, #efbc33 0%, #D2A038 100%);
    color: #fff;
    border-color: #efbc33;
    box-shadow: 0 6px 18px rgba(239, 188, 51, 0.35);
}

.faq-tab-btn.active i {
    color: #fff;
}

/* ------------------- محتوای تب‌ها ------------------- */
.faq-tabs-content {
    flex-grow: 1;
    width: 100%;
}

.faq-tab-pane {
    display: none;
    animation: faqFadeIn 0.4s ease forwards;
}

.faq-tab-pane.active {
    display: block;
}

@keyframes faqFadeIn {
    from {
        opacity: 0;
        transform: translateY(8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.faq-accordion-group {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

/* ------------------- آیتم‌های آکاردئون (سفید و شفاف) ------------------- */
.faq-item {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.faq-item:hover {
    border-color: #efbc33;
    box-shadow: 0 4px 15px rgba(239, 188, 51, 0.15);
}

.faq-item.open {
    border-color: #D2A038;
    background: #ffffff;
    box-shadow: 0 6px 20px rgba(2, 3, 27, 0.08);
}

/* عنوان پرسش */
.faq-question {
    padding: 18px 22px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    user-select: none;
    gap: 15px;
    text-align: right;
    background: #ffffff;
}

.faq-question h3 {
    margin: 0;
    font-size: 15px;
    font-weight: 700;
    color: #0f172a;
    line-height: 1.6;
    text-align: right;
    transition: color 0.3s ease;
}

.faq-item.open .faq-question h3 {
    color: #b48116; /* رنگ طلایی خوانا روی پس‌زمینه سفید */
}

/* آیکون وضعیت */
.faq-icon {
    width: 32px;
    height: 32px;
    min-width: 32px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #64748b;
    font-size: 13px;
    transition: all 0.35s ease;
}

.faq-item.open .faq-icon {
    transform: rotate(180deg);
    background: #efbc33;
    border-color: #efbc33;
    color: #02031B;
}

/* پاسخ */
.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s cubic-bezier(0, 1, 0, 1);
    background: #ffffff;
}

.faq-answer-inner {
    padding: 0 22px 20px 22px;
    border-top: 1px solid #f1f5f9;
    margin-top: 4px;
    padding-top: 15px;
}

.faq-answer-inner p {
    margin: 0;
    font-size: 14px;
    line-height: 1.9;
    color: #334155;
    text-align: justify; /* تراز خطوط به صورت کاملاً منظم */
    text-justify: inter-word;
}

.faq-answer-inner a {
    color: #b48116;
    text-decoration: underline;
    text-underline-offset: 4px;
    font-weight: 600;
    transition: color 0.2s ease;
}

.faq-answer-inner a:hover {
    color: #02031B;
}

/* ------------------- حالت واکنش‌گرا (موبایل و تبلت) ------------------- */
@media (max-width: 768px) {
    .modern-faq-wrapper {
        width: 92%; /* عرض استاندارد و جمع‌وجور روی موبایل */
        padding: 15px 0 40px 0;
        min-height: 80vh;
    }

    .faq-tabs-nav {
        gap: 8px;
        margin-bottom: 20px;
    }

    .faq-tab-btn {
        width: 100%;
        justify-content: flex-start;
        padding: 12px 16px;
        font-size: 13px;
    }

    .faq-question {
        padding: 14px 16px;
    }

    .faq-question h3 {
        font-size: 13.5px;
    }

    .faq-icon {
        width: 28px;
        height: 28px;
        min-width: 28px;
        font-size: 11px;
    }

    .faq-answer-inner {
        padding: 0 16px 16px 16px;
    }

    .faq-answer-inner p {
        font-size: 13px;
        line-height: 1.85;
    }
}
