.smart-faq-box {
    --faq-accent: #2563eb; /* آبی ملایم فقط برای آیکون و بورد */
    --faq-border: #e5e7eb;
    --faq-text-main: #111827;
    --faq-text-muted: #4b5563;
    --faq-bg-item: #ffffff;

    max-width: 800px;
    margin: 40px auto;
    padding: 0 15px;
    direction: rtl !important; /* راست‌چین برای زبان فارسی */
}

.smart-faq-title {
    font-size: 24px;
    font-weight: 800;
    color: var(--faq-text-main);
    margin-bottom: 25px;
    text-align: right;
}

.smart-faq-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.smart-faq-item {
    background: var(--faq-bg-item) !important;
    border: 1px solid var(--faq-border) !important;
    border-radius: 12px;
    transition: all 0.3s ease;
    overflow: hidden;
    box-shadow: 0 2px 4px rgba(0,0,0,0.02);
}

/* اصلاح چیدمان: متن راست، آیکون چپ */
.smart-faq-trigger {
    display: flex !important;
    flex-direction: row !important; /* اطمینان از چیدمان ردیفی */
    align-items: center;
    justify-content: space-between;
    width: 100% !important;
    padding: 20px 24px !important;
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    cursor: pointer;
    gap: 15px;
    outline: none !important;
}

.smart-faq-trigger-text {
    flex: 1;
    font-size: 16px;
    font-weight: 700;
    color: var(--faq-text-main) !important;
    line-height: 1.6;
    text-align: right; /* متن سوال کاملاً راست‌چین */
    order: 1; /* اولویت نمایش در RTL (سمت راست) */
}

/* آیکون دایره‌ای ظریف */
.smart-faq-trigger-icon {
    position: relative;
    width: 26px;
    height: 26px;
    flex-shrink: 0;
    background: #f1f5f9;
    border-radius: 50%;
    transition: all 0.3s ease;
    border: 1px solid var(--faq-border);
    order: 2; /* قرارگیری در سمت چپ نسبت به متن در حالت RTL */
}

.smart-faq-item:hover {
    border-color: var(--faq-accent) !important;
}

.smart-faq-trigger-icon::before,
.smart-faq-trigger-icon::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 10px;
    height: 2px;
    background: #64748b;
    transform: translate(-50%, -50%);
    transition: all 0.3s ease;
}

.smart-faq-trigger-icon::after {
    transform: translate(-50%, -50%) rotate(90deg);
}

/* استایل حالت باز */
.smart-faq-item.is-open {
    border-color: var(--faq-accent) !important;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}

.smart-faq-item.is-open .smart-faq-trigger-icon {
    background: var(--faq-accent);
    border-color: var(--faq-accent);
}

.smart-faq-item.is-open .smart-faq-trigger-icon::before {
    background: #ffffff;
}

.smart-faq-item.is-open .smart-faq-trigger-icon::after {
    opacity: 0;
    transform: translate(-50%, -50%) rotate(0deg);
}

/* متن پاسخ */
.smart-faq-panel {
    display: grid;
    grid-template-rows: 0fr;
    transition: grid-template-rows 0.3s ease-out;
}

.smart-faq-item.is-open .smart-faq-panel {
    grid-template-rows: 1fr;
}

.smart-faq-panel-inner {
    overflow: hidden;
    padding: 0 24px;
    color: var(--faq-text-muted);
    font-size: 15px;
    line-height: 1.8;
    text-align: right;
}

.smart-faq-item.is-open .smart-faq-panel-inner {
    padding-bottom: 20px;
    padding-top: 10px;
}

/* جداکننده داخلی */
.smart-faq-panel-inner::before {
    content: "";
    display: block;
    height: 1px;
    margin-bottom: 15px;
    background: #f1f5f9;
}

@media (max-width: 640px) {
    .smart-faq-trigger {
        padding: 16px 18px !important;
    }
    .smart-faq-trigger-text {
        font-size: 15px;
    }
}
