/* استایل کلی صفحه – فونت، رنگ پس‌زمینه، ... */
:where(.bd-article-content) *, :where(.bd-article-content), :where(.bd-article-content) *::before, :where(.bd-article-content)::before, :where(.bd-article-content) *::after, :where(.bd-article-content)::after{
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

:where(.bd-article-content){
    font-size: 16px;
}

:where(.bd-article-content){
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: #f4f5f9;
    color: #222;
    line-height: 1.6;
}

/* کانتینر اصلی */
:where(.bd-article-content) .app-container, :where(.bd-article-content).app-container{
    max-width: 960px;
    margin: 0 auto;
    padding: 1rem;
}

/* هدر */
:where(.bd-article-content) .app-header, :where(.bd-article-content).app-header{
    text-align: center;
    margin-bottom: 1.5rem;
}

:where(.bd-article-content) .app-header h1, :where(.bd-article-content).app-header h1{
    font-size: 1.8rem;
    margin-bottom: 0.5rem;
    color: #1f3c88;
}

:where(.bd-article-content) .subtitle, :where(.bd-article-content).subtitle{
    font-size: 0.95rem;
    color: #555;
}

/* بخش info */
:where(.bd-article-content) .info-section, :where(.bd-article-content).info-section{
    background: #ffffff;
    border-radius: 8px;
    padding: 1rem 1.2rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    margin-bottom: 1.2rem;
}

:where(.bd-article-content) .info-section h2, :where(.bd-article-content).info-section h2{
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
    color: #1f3c88;
}

:where(.bd-article-content) .info-section ul, :where(.bd-article-content).info-section ul{
    list-style: disc;
    padding-left: 1.25rem;
}

:where(.bd-article-content) .info-section li, :where(.bd-article-content).info-section li{
    margin-bottom: 0.35rem;
}

/* فرم آزمون */
:where(.bd-article-content) .test-form, :where(.bd-article-content).test-form{
    background: #ffffff;
    border-radius: 8px;
    padding: 1rem 1.2rem 1.4rem;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.07);
}

/* سؤال‌ها */
:where(.bd-article-content) .question-block, :where(.bd-article-content).question-block{
    border-bottom: 1px solid #e3e5ee;
    padding: 0.75rem 0;
}

:where(.bd-article-content) .question-block:last-child, :where(.bd-article-content).question-block:last-child{
    border-bottom: none;
}

:where(.bd-article-content) .question-header, :where(.bd-article-content).question-header{
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 0.4rem;
}

:where(.bd-article-content) .question-title, :where(.bd-article-content).question-title{
    font-weight: 600;
    margin-bottom: 0.2rem;
}

:where(.bd-article-content) .question-meta, :where(.bd-article-content).question-meta{
    font-size: 0.75rem;
    color: #777;
}

:where(.bd-article-content) .question-text, :where(.bd-article-content).question-text{
    margin: 0.25rem 0 0.5rem;
}

/* گزینه‌ها – چهارگزینه‌ای */
:where(.bd-article-content) .options, :where(.bd-article-content).options{
    margin-top: 0.3rem;
}

:where(.bd-article-content) .option-item, :where(.bd-article-content).option-item{
    display: flex;
    align-items: center;
    margin-bottom: 0.25rem;
}

:where(.bd-article-content) .option-item input[type="radio"], :where(.bd-article-content).option-item input[type="radio"]{
    margin-right: 0.4rem;
}

/* جای‌خالی */
:where(.bd-article-content) .gap-input, :where(.bd-article-content).gap-input{
    width: 100%;
    max-width: 260px;
    padding: 0.35rem 0.5rem;
    border-radius: 4px;
    border: 1px solid #cfd3e6;
    font-size: 0.95rem;
}

/* دکمه‌ها */
:where(.bd-article-content) .form-actions, :where(.bd-article-content).form-actions{
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 1.2rem;
    justify-content: flex-end;
}

:where(.bd-article-content) .primary-btn, :where(.bd-article-content).primary-btn, :where(.bd-article-content) .secondary-btn, :where(.bd-article-content).secondary-btn{
    cursor: pointer;
    border-radius: 999px;
    border: none;
    padding: 0.5rem 1.2rem;
    font-size: 0.95rem;
    transition: all 0.2s ease;
}

:where(.bd-article-content) .primary-btn, :where(.bd-article-content).primary-btn{
    background: #1f3c88;
    color: #fff;
}

:where(.bd-article-content) .primary-btn:hover, :where(.bd-article-content).primary-btn:hover{
    background: #1a326f;
}

:where(.bd-article-content) .secondary-btn, :where(.bd-article-content).secondary-btn{
    background: #e4e7f5;
    color: #1f3c88;
}

:where(.bd-article-content) .secondary-btn:hover, :where(.bd-article-content).secondary-btn:hover{
    background: #d1d7f2;
}

:where(.bd-article-content) .primary-btn.outlined, :where(.bd-article-content).primary-btn.outlined{
    background: #fff;
    color: #1f3c88;
    border: 1px solid #1f3c88;
}

/* بخش نتیجه – Popup */
:where(.bd-article-content) .result-section, :where(.bd-article-content).result-section{
    position: fixed;
    inset: 0;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding-top: 5vh;
    z-index: 1001;
}

:where(.bd-article-content) .result-card, :where(.bd-article-content).result-card{
    background: #ffffff;
    border-radius: 10px;
    max-width: 520px;
    width: 92%;
    padding: 1.4rem 1.6rem 1.4rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.18);
}

:where(.bd-article-content) .result-card h2, :where(.bd-article-content).result-card h2{
    margin-bottom: 0.8rem;
    color: #1f3c88;
}

:where(.bd-article-content) .score-text, :where(.bd-article-content).score-text{
    font-size: 1.1rem;
    margin-bottom: 0.4rem;
}

:where(.bd-article-content) .pass-fail-text, :where(.bd-article-content).pass-fail-text{
    font-weight: 600;
    margin-bottom: 0.8rem;
}

:where(.bd-article-content) .pass, :where(.bd-article-content).pass{
    color: #0a7c3b;
}

:where(.bd-article-content) .fail, :where(.bd-article-content).fail{
    color: #c0392b;
}

/* تحلیل جزئی */
:where(.bd-article-content) .detailed-feedback, :where(.bd-article-content).detailed-feedback{
    background: #f5f7ff;
    border-radius: 8px;
    padding: 0.7rem 0.8rem;
    font-size: 0.9rem;
    margin-bottom: 0.9rem;
}

:where(.bd-article-content) .detailed-feedback h3, :where(.bd-article-content).detailed-feedback h3{
    font-size: 1rem;
    margin-bottom: 0.4rem;
    color: #1f3c88;
}

:where(.bd-article-content) .feedback-item, :where(.bd-article-content).feedback-item{
    margin-bottom: 0.35rem;
}

/* Overlay – پس‌زمینه تار */
:where(.bd-article-content) .overlay, :where(.bd-article-content).overlay{
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.45);
    z-index: 1000;
}

/* حالت مخفی */
:where(.bd-article-content) .hidden, :where(.bd-article-content).hidden{
    display: none !important;
}

/* فوتر */
:where(.bd-article-content) .app-footer, :where(.bd-article-content).app-footer{
    text-align: center;
    font-size: 0.8rem;
    color: #777;
    margin-top: 1rem;
    padding-bottom: 0.5rem;
}

/* واکنش‌گرا (Responsive) */
@media (max-width: 600px) {
    :where(.bd-article-content) .app-header h1, :where(.bd-article-content).app-header h1{
        font-size: 1.4rem;
    }
    :where(.bd-article-content) .result-card, :where(.bd-article-content).result-card{
        padding: 1.1rem 1.2rem;
    }
    :where(.bd-article-content) .form-actions, :where(.bd-article-content).form-actions{
        justify-content: center;
    }
}
/* کارت هر سؤال */
:where(.bd-article-content) .question-card, :where(.bd-article-content).question-card{
    background: #ffffff;
    border-radius: 8px;
    padding: 16px 18px;
    margin-bottom: 16px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06);
}

/* شماره سؤال */
:where(.bd-article-content) .question-number, :where(.bd-article-content).question-number{
    font-size: 0.9rem;
    color: #666;
    margin-bottom: 4px;
}

/* متن سؤال */
:where(.bd-article-content) .question-text, :where(.bd-article-content).question-text{
    font-size: 1rem;
    line-height: 1.5;
    margin-bottom: 10px;
}

/* ظرف گزینه‌ها / جواب */
:where(.bd-article-content) .answer-wrapper, :where(.bd-article-content).answer-wrapper{
    margin-top: 6px;
}

/* هر گزینه‌ی چهارگزینه‌ای در یک خط جدا */
:where(.bd-article-content) .option-label, :where(.bd-article-content).option-label{
    display: block;              /* مهم‌ترین خط */
    margin-bottom: 6px;
    font-size: 0.95rem;
    cursor: pointer;
}

/* فاصله‌ی کوچک بین دایره‌ی رادیویی و متن */
:where(.bd-article-content) .option-label input[type="radio"], :where(.bd-article-content).option-label input[type="radio"]{
    margin-right: 6px;
}

/* فیلدهای متنی (input-type=text) */
:where(.bd-article-content) .text-input, :where(.bd-article-content).text-input{
    width: 100%;
    max-width: 320px;
    padding: 6px 8px;
    font-size: 0.95rem;
    border: 1px solid #ccc;
    border-radius: 4px;
}

/* فاصله‌ی آخرین گزینه با پایین کارت سؤال */
:where(.bd-article-content) .answer-wrapper .option-label:last-child, :where(.bd-article-content).answer-wrapper .option-label:last-child{
    margin-bottom: 2px;
}