/*
================================================
   🎨 iphycs.ir — استایل جامع
   Physics Education Theme
   Author: iphycs
================================================
*/


/* =========================================================
   ۱) متغیرهای اصلی
========================================================= */

:root {
    --primary-color: #1a2a4a;
    --primary-hover: #0f1d33;
    --navy: #1e3152;
    --orange: #f97316;
    --orange-hover: #ea580c;
    --orange-light: #fff7ed;
    --bg-light: #f8fafc;
    --text-dark: #111827;
    --text-gray: #64748b;
    --border-light: #e5e7eb;
    --shadow-light: 0 10px 30px rgba(0, 0, 0, 0.06);
    --white: #ffffff;
}


/* =========================================================
   ۲) Reset و تنظیمات پایه
========================================================= */

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    width: 100%;
    overflow-x: hidden;
}

body {
    margin: 0;
    padding: 0;
    width: 100%;
    font-family: Tahoma, Arial, sans-serif;
    direction: rtl;
    background: #ffffff;
    color: var(--text-dark);
    line-height: 1.7;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}


/* =========================================================
   ۳) Header + Mobile Menu
========================================================= */

.site-header {
    width: 100%;
    padding: 12px 40px;
    background: #ffffff;
    border-bottom: 1px solid #f1f1f1;
    position: sticky;
    top: 0;
    z-index: 999;
}

.site-header .header-inner {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    position: relative;
    width: 100%;
}

/* لوگو */
.site-header .logo {
    display: flex;
    align-items: center;
    flex-shrink: 0;
    order: 1;
}

.site-header .site-logo img {
    display: block;
    width: 100px;
    height: auto;
    max-width: 100%;
}

/* منو */
.site-header .main-menu {
    flex: 1;
    display: flex;
    justify-content: center;
}

.site-header .main-menu ul.menu {
    margin: 0;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    list-style: none;
    gap: 28px;
}

.site-header .main-menu ul.menu li {
    margin: 0;
    padding: 0;
    list-style: none;
}

.site-header .main-menu ul.menu li a {
    display: block;
    color: var(--text-dark);
    font-size: 15px;
    font-weight: 500;
    white-space: nowrap;
    transition: color 0.2s ease;
    padding: 6px 0;
}

.site-header .main-menu ul.menu li a:hover {
    color: var(--orange);
}

/* دکمه همبرگری (مخفی در دسکتاپ) */
.menu-toggle {
    display: none;
    width: 42px;
    height: 42px;
    background: transparent;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    cursor: pointer;
    padding: 0;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
    transition: 0.2s;
    flex-shrink: 0;
    order: 3;
}

.menu-toggle:hover {
    border-color: var(--orange);
    background: var(--orange-light);
}

.menu-toggle-bar {
    display: block;
    width: 20px;
    height: 2px;
    background: var(--text-dark);
    border-radius: 2px;
    transition: 0.3s;
    transform-origin: center;
}

.menu-toggle.is-open .menu-toggle-bar:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.menu-toggle.is-open .menu-toggle-bar:nth-child(2) {
    opacity: 0;
}

.menu-toggle.is-open .menu-toggle-bar:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/* سبد خرید */
.site-header .header-cart {
    position: relative;
    width: 42px;
    height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-dark);
    text-decoration: none;
    flex-shrink: 0;
    order: 2;
    transition: 0.2s;
}

.site-header .header-cart:hover {
    color: var(--orange);
}

.site-header .header-cart-icon {
    width: 34px;
    height: 34px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.site-header .header-cart-icon svg {
    width: 28px;
    height: 28px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.site-header .header-cart-count {
    position: absolute;
    top: 2px;
    right: 1px;
    min-width: 19px;
    height: 19px;
    padding: 0 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    background: var(--orange);
    color: #ffffff;
    border-radius: 50%;
    font-size: 10px;
    font-weight: bold;
    line-height: 1;
}

/* اورلی منو */
.menu-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.55);
    z-index: 998;
    opacity: 0;
    transition: opacity 0.3s;
}

.menu-overlay.is-visible {
    display: block;
    opacity: 1;
}


/* =========================================================
   ۴) Hero
========================================================= */

.hero {
    width: 100%;
    max-width: 1200px;
    min-height: 240px;
    margin: 25px auto 40px;
    padding: 55px 30px;
    background: var(--bg-light);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.hero h1 {
    margin: 0 0 15px;
    color: var(--text-dark);
    font-size: 42px;
    line-height: 1.4;
    font-weight: 700;
}

.hero p {
    margin: 0;
    color: var(--text-gray);
    font-size: 20px;
    line-height: 1.8;
}


/* =========================================================
   ۵) بنر تخفیف
========================================================= */

.discount-banner {
    width: 100%;
    max-width: 1200px;
    margin: 25px auto 0;
    padding: 0 20px;
}


/* =========================================================
   ۶) کارت‌های صفحه اصلی (۶ کارت فیزیک دهم/یازدهم/...)
   ساختار: section.grades > .chapter-grid > .card
========================================================= */

section.grades {
    display: block;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    box-sizing: border-box;
}

section.grades .chapter-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 25px;
    width: 100%;
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

section.grades .chapter-grid .card {
    width: 100%;
    min-width: 0;
    height: 260px;
    min-height: 260px;
    box-sizing: border-box;
    padding: 30px 20px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;

    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-top: 8px solid var(--primary-color);
    border-radius: 20px;
    box-shadow: 0 10px 35px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
}

section.grades .chapter-grid .card h2 {
    font-size: 24px;
    font-weight: 700;
    color: var(--text-dark);
    margin: 0 0 12px;
    background: transparent;
}

section.grades .chapter-grid .card p {
    font-size: 15px;
    color: var(--text-gray);
    line-height: 1.8;
    margin: 0 0 10px;
}

section.grades .chapter-grid .card a {
    display: inline-block;
    margin-top: 15px;
    padding: 11px 24px;
    background: var(--orange);
    color: #ffffff;
    border-radius: 40px;
    font-size: 15px;
    font-weight: 700;
    white-space: nowrap;
    transition: 0.3s;
}

section.grades .chapter-grid .card a:hover {
    background: var(--orange-hover);
    transform: translateY(-3px);
}

/* هاور کارت: پس‌زمینه سورمه‌ای */
section.grades .chapter-grid .card:hover {
    transform: translateY(-8px);
    background-color: var(--primary-color);
    color: #ffffff;
    border-color: var(--primary-color);
    box-shadow: 0 20px 40px rgba(26, 42, 74, 0.2);
}

section.grades .chapter-grid .card:hover h2,
section.grades .chapter-grid .card:hover p,
section.grades .chapter-grid .card:hover h2 a {
    color: #ffffff;
}

section.grades .chapter-grid .card:hover a {
    background: #ffffff;
    color: var(--primary-color);
}

/* کارت AI */
section.grades .chapter-grid .card.ai-card {
    border-top-color: #8b5cf6;
}

section.grades .chapter-grid .card.ai-card:hover {
    border-top-color: var(--primary-color);
}


/* =========================================================
   ۷) صفحات شبیه‌سازی و دسته‌بندی
========================================================= */

.simulations-page,
.category-page,
.simulation-page {
    width: 100%;
    max-width: 1200px;
    margin: 40px auto;
    padding: 0 20px;
}

.category-page h1,
.simulations-page h1,
.simulation-page h1 {
    margin: 0 0 35px;
    padding: 10px 0 30px;
    background: transparent;
    font-size: 36px;
    text-align: center;
    color: var(--text-dark);
}

.simulation-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
}

.simulation-grid .card {
    border-top: 6px solid var(--primary-color);
    min-height: 220px;
    padding: 25px 20px;
    background: #ffffff;
    border-radius: 20px;
    border-bottom: 1px solid #e5e7eb;
    border-left: 1px solid #e5e7eb;
    border-right: 1px solid #e5e7eb;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.06);
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    transition: all 0.3s ease;
}

.simulation-grid .card:hover {
    background: var(--primary-color);
    color: #ffffff;
    transform: translateY(-8px);
}

.simulation-grid .card h2,
.simulation-grid .card h3 {
    font-size: 19px;
    margin: 0 0 12px;
    color: var(--text-dark);
}

.simulation-grid .card p {
    color: var(--text-gray);
    font-size: 14px;
    line-height: 1.8;
    margin: 0 0 18px;
}

.simulation-grid .card a,
.simulation-link {
    display: inline-block;
    background: var(--orange);
    color: #ffffff;
    padding: 10px 25px;
    border-radius: 30px;
    font-weight: bold;
    font-size: 14px;
    transition: 0.3s;
}

.simulation-grid .card a:hover,
.simulation-link:hover {
    background: var(--orange-hover);
    transform: translateY(-3px);
}

.simulation-grid .card:hover h2,
.simulation-grid .card:hover h3,
.simulation-grid .card:hover p {
    color: #ffffff;
}

.simulation-grid .card:hover a {
    background: #ffffff;
    color: var(--primary-color);
}

/* دکمه شبیه‌سازی در single */
.simulation-box {
    background: #ffffff;
    border-radius: 25px;
    padding: 40px;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
}

.simulation-button {
    display: inline-block;
    background: var(--orange);
    color: #ffffff;
    padding: 14px 40px;
    border-radius: 35px;
    font-size: 18px;
    text-decoration: none;
    transition: 0.3s;
}

.simulation-button:hover {
    background: var(--orange-hover);
}


/* =========================================================
   ۸) بخش اساتید (صفحه اصلی)
   ساختار: .teachers > .teacher-list > .teacher-card
========================================================= */

.teachers {
    width: 100%;
    max-width: 1200px;
    margin: 80px auto 40px;
    padding: 40px 30px;
    background: var(--bg-light);
    border-radius: 25px;
    box-sizing: border-box;
}

.teachers-title {
    width: 100%;
    margin-bottom: 30px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.teachers-title h2 {
    font-size: 32px;
    margin: 0;
}

.teacher-filter-toggle {
    border: none;
    background: #e2e8f0;
    padding: 10px 20px;
    border-radius: 10px;
    font-family: inherit;
    cursor: pointer;
    font-size: 15px;
    font-weight: bold;
    transition: 0.2s;
}

.teacher-filter-toggle:hover {
    background: #cbd5e1;
}

/* محفظه فیلتر */
.teacher-filter-wrapper {
    display: none;
    margin-bottom: 30px;
}

.teacher-filter-wrapper.is-open {
    display: block;
}

.teacher-filter {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px 30px;
    padding: 30px;
    background: #ffffff;
    border-radius: 20px;
    box-shadow: var(--shadow-light);
    border: 1px solid #f0f0f0;
}

.filter-item label {
    display: block;
    margin-bottom: 6px;
    font-weight: bold;
    font-size: 14px;
    color: var(--text-dark);
}

.filter-item input,
.filter-item select {
    width: 100%;
    padding: 12px;
    border: 1px solid #d1d5db;
    border-radius: 10px;
    font-family: inherit;
    background: #ffffff;
    transition: 0.2s;
}

.filter-item input:focus,
.filter-item select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(26, 42, 74, 0.1);
}

.filter-actions {
    grid-column: span 2;
    display: flex;
    align-items: center;
    gap: 15px;
    margin-top: 15px;
}

.teacher-filter-submit {
    flex: 1;
    padding: 14px;
    border: none;
    border-radius: 12px;
    background: var(--primary-color);
    color: #ffffff;
    font-family: inherit;
    font-weight: bold;
    cursor: pointer;
    transition: 0.2s;
}

.teacher-filter-submit:hover {
    background: var(--primary-hover);
}

.teacher-filter-reset {
    padding: 14px 25px;
    border-radius: 12px;
    background: #f1f5f9;
    color: var(--text-dark);
    text-decoration: none;
    font-weight: bold;
    transition: 0.2s;
}

.teacher-filter-reset:hover {
    background: #e2e8f0;
}

/* شبکه کارت‌های اساتید */
.teacher-list {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 25px;
}

.teacher-card {
    background: #ffffff;
    padding: 25px 15px;
    border-radius: 20px;
    text-align: center;
    box-shadow: var(--shadow-light);
    border: 1px solid #f1f5f9;
    transition: 0.3s;
}

.teacher-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.08);
}

.teacher-image img {
    width: 120px;
    height: 120px;
    object-fit: cover;
    border-radius: 50%;
    margin: 0 auto 15px;
}

.teacher-card h3 {
    margin: 15px 0 10px;
    font-size: 18px;
}

.teacher-card p {
    margin: 8px 0;
    color: var(--text-gray);
    font-size: 14px;
}

.teacher-card > a {
    display: inline-block;
    margin-top: 15px;
    padding: 10px 20px;
    border-radius: 30px;
    background: var(--bg-light);
    color: var(--text-dark);
    font-size: 14px;
    font-weight: bold;
    transition: 0.2s;
}

.teacher-card > a:hover {
    background: var(--primary-color);
    color: #ffffff;
}

.no-teacher {
    padding: 40px;
    text-align: center;
    grid-column: 1 / -1;
    color: var(--text-gray);
}


/* =========================================================
   ۹) صفحه پروفایل استاد (single-teacher)
========================================================= */

.teacher-profile-page {
    max-width: 1100px;
    margin: 60px auto;
    padding: 0 20px;
    direction: rtl;
}

.teacher-profile-header {
    text-align: center;
    margin-bottom: 30px;
}

.teacher-avatar {
    display: inline-block;
    border-radius: 50%;
    overflow: hidden;
    border: 6px solid var(--orange);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    width: 220px;
    height: 220px;
}

.teacher-avatar-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.teacher-name {
    font-size: 38px;
    font-weight: 700;
    color: var(--text-dark);
    margin-top: 20px;
    position: relative;
}

.teacher-name::after {
    content: '';
    display: block;
    width: 80px;
    height: 4px;
    background: var(--primary-color);
    margin: 12px auto 0;
    border-radius: 4px;
}

.teacher-info-row {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px 40px;
    background: var(--bg-light);
    padding: 25px 30px;
    border-radius: 20px;
    margin-bottom: 40px;
    border-right: 6px solid var(--orange);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.04);
}

.info-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    min-width: 100px;
}

.info-label {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-gray);
    letter-spacing: 0.5px;
    margin-bottom: 4px;
    text-transform: uppercase;
}

.info-value {
    font-size: 20px;
    font-weight: 700;
    color: var(--text-dark);
    background: #ffffff;
    padding: 4px 18px;
    border-radius: 30px;
    border: 1px solid #e5e7eb;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.03);
}

.teacher-bio {
    background: #ffffff;
    border-radius: 24px;
    padding: 35px 40px;
    margin-bottom: 50px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.06);
    border-top: 6px solid var(--primary-color);
}

.teacher-bio h2 {
    font-size: 28px;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 20px;
    position: relative;
    padding-right: 20px;
}

.teacher-bio h2::before {
    content: '';
    position: absolute;
    right: 0;
    top: 0;
    width: 6px;
    height: 100%;
    background: var(--orange);
    border-radius: 6px;
}

.bio-content {
    font-size: 17px;
    line-height: 2;
    color: #334155;
}

/* دوره‌ها و جزوه‌های استاد */
.teacher-content-columns {
    width: 100%;
    max-width: 1050px;
    margin: 35px auto 60px;
    padding: 0 15px;
    box-sizing: border-box;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 28px;
    align-items: start;
}

.teacher-courses-section,
.teacher-notes-section {
    width: 100%;
    min-width: 0;
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

.teacher-section-title {
    margin: 0 0 18px;
    padding-right: 12px;
    font-size: 22px;
    line-height: 1.5;
    font-weight: 800;
    color: var(--text-dark);
    border-right: 4px solid var(--orange);
}

.teacher-courses-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 18px;
}

.course-card {
    width: 100%;
    margin: 0;
    padding: 0 0 16px;
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 5px 18px rgba(15, 23, 42, 0.07);
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    transition: all 0.3s ease;
}

.course-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.08);
    border-color: var(--orange);
}

.course-thumb {
    width: 100%;
    height: 155px;
    overflow: hidden;
    background: var(--bg-light);
}

.course-thumb img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
}

.course-card h3 {
    margin: 14px 16px 12px;
    font-size: 17px;
    line-height: 1.6;
    font-weight: 800;
}

.course-card h3 a {
    color: var(--text-dark);
    text-decoration: none;
    transition: 0.2s;
}

.course-card h3 a:hover {
    color: var(--orange);
}

.course-btn {
    display: block;
    margin: 0 16px;
    padding: 10px 15px;
    background: var(--primary-color);
    color: #ffffff;
    border-radius: 11px;
    text-align: center;
    text-decoration: none;
    font-size: 13px;
    font-weight: 700;
    transition: 0.2s;
}

.course-btn:hover {
    background: var(--orange);
}

/* جزوه‌ها */
.teacher-notes-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 18px;
}

.teacher-note-card {
    width: 100%;
    margin: 0;
    padding: 18px;
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-top: 4px solid var(--orange);
    border-radius: 17px;
    box-shadow: 0 5px 18px rgba(15, 23, 42, 0.06);
    box-sizing: border-box;
}

.teacher-note-icon {
    width: 42px;
    height: 42px;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--orange-light);
    border-radius: 11px;
    font-size: 21px;
}

.teacher-note-card h3 {
    margin: 0 0 9px;
    font-size: 17px;
    line-height: 1.6;
    font-weight: 800;
    color: var(--text-dark);
}

.teacher-note-meta,
.teacher-note-chapter {
    margin-bottom: 6px;
    font-size: 13px;
    line-height: 1.7;
    color: #4b5563;
}

.teacher-note-access {
    margin: 10px 0 13px;
    font-size: 13px;
    font-weight: 700;
}

.note-free {
    color: #16a34a;
}

.note-paid {
    color: #ea580c;
}

.teacher-note-button {
    display: block;
    width: 100%;
    padding: 10px 12px;
    box-sizing: border-box;
    background: var(--primary-color);
    color: #ffffff;
    border-radius: 11px;
    text-align: center;
    text-decoration: none;
    font-size: 13px;
    font-weight: 700;
    transition: 0.2s;
}

.teacher-note-button:hover {
    background: var(--orange);
}

.no-courses,
.teacher-no-notes {
    margin: 0;
    padding: 22px 15px;
    background: var(--bg-light);
    border: 1px solid #e5e7eb;
    border-radius: 15px;
    text-align: center;
    color: var(--text-gray);
    font-size: 14px;
}


/* =========================================================
   ۱۰) صفحه اساتید (teachers page)
========================================================= */

.teachers-page {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 50px 20px 80px;
    box-sizing: border-box;
    direction: rtl;
}

.teachers-page-header {
    text-align: center;
    margin-bottom: 35px;
}

.teachers-page-header h1 {
    margin: 0 0 10px;
    font-size: 34px;
    font-weight: 800;
    color: var(--text-dark);
}

.teachers-page-header p {
    margin: 0;
    color: var(--text-gray);
    font-size: 16px;
}

.teachers-filter-section {
    margin-bottom: 45px;
}

.teachers-filter-toggle {
    display: block;
    margin: 0 auto 18px;
    padding: 12px 24px;
    border: 0;
    border-radius: 12px;
    background: var(--orange);
    color: #ffffff;
    font-family: inherit;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    transition: 0.25s ease;
}

.teachers-filter-toggle:hover {
    background: var(--orange-hover);
    transform: translateY(-1px);
}

.teachers-filter-box {
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 20px;
    padding: 25px;
    box-shadow: 0 8px 25px rgba(15, 23, 42, 0.06);
    box-sizing: border-box;
}

.teachers-filter-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
}

.teacher-filter-item {
    display: flex;
    flex-direction: column;
    gap: 7px;
}

.teacher-filter-item label {
    font-size: 14px;
    font-weight: 700;
    color: #374151;
}

.teacher-filter-item input,
.teacher-filter-item select {
    width: 100%;
    height: 46px;
    padding: 0 13px;
    border: 1px solid #d1d5db;
    border-radius: 11px;
    background: #f9fafb;
    color: var(--text-dark);
    font-family: inherit;
    font-size: 14px;
    outline: none;
    box-sizing: border-box;
    transition: 0.2s ease;
}

.teacher-filter-item input:focus,
.teacher-filter-item select:focus {
    border-color: var(--orange);
    background: #ffffff;
    box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.10);
}

.teachers-filter-actions {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-top: 22px;
    flex-wrap: wrap;
}

.teachers-filter-submit {
    min-width: 170px;
    height: 46px;
    padding: 0 22px;
    border: 0;
    border-radius: 11px;
    background: var(--orange);
    color: #ffffff;
    font-family: inherit;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    transition: 0.25s ease;
}

.teachers-filter-submit:hover {
    background: var(--orange-hover);
}

.teachers-filter-reset {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 130px;
    height: 46px;
    padding: 0 18px;
    border-radius: 11px;
    background: #f3f4f6;
    color: #374151;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    box-sizing: border-box;
    transition: 0.25s ease;
}

.teachers-filter-reset:hover {
    background: #e5e7eb;
    color: var(--text-dark);
}

.teachers-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 25px;
}

/* کارت استاد در صفحه اساتید */
.teachers-page .teacher-card {
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-top: 5px solid var(--orange);
    border-radius: 22px;
    overflow: hidden;
    box-shadow: 0 8px 25px rgba(15, 23, 42, 0.06);
    padding: 0;
    text-align: right;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.teachers-page .teacher-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(15, 23, 42, 0.11);
}

.teacher-card-image {
    width: 100%;
    height: 250px;
    overflow: hidden;
    background: var(--bg-light);
}

.teacher-card-image a {
    display: block;
    width: 100%;
    height: 100%;
}

.teacher-card-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.35s ease;
}

.teacher-card:hover .teacher-card-img {
    transform: scale(1.04);
}

.teacher-card-content {
    padding: 22px;
}

.teacher-card-name {
    margin: 0 0 18px;
    font-size: 20px;
    font-weight: 800;
    line-height: 1.5;
}

.teacher-card-name a {
    color: var(--text-dark);
    text-decoration: none;
    transition: color 0.2s ease;
}

.teacher-card-name a:hover {
    color: var(--orange);
}

.teacher-card-info {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
    color: #4b5563;
    font-size: 14px;
    line-height: 1.7;
}

.teacher-card-info span {
    width: 26px;
    height: 26px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    background: var(--orange-light);
    border-radius: 8px;
    font-size: 14px;
}

.teacher-card-button {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 44px;
    margin-top: 20px;
    border-radius: 11px;
    background: var(--text-dark);
    color: #ffffff;
    text-decoration: none;
    font-size: 14px;
    font-weight: 700;
    box-sizing: border-box;
    transition: 0.25s ease;
}

.teacher-card-button:hover {
    background: var(--orange);
    color: #ffffff;
}

.teachers-no-result {
    padding: 45px 20px;
    text-align: center;
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 20px;
    color: var(--text-gray);
}


/* =========================================================
   ۱۱) دستیار هوش مصنوعی (AI Solver)
========================================================= */

.ai-solver-box {
    max-width: 1100px;
    margin: 60px auto;
    padding: 40px;
    background: #ffffff;
    border-radius: 30px;
    box-shadow: var(--shadow-light);
    direction: rtl;
}

.ai-solver-box h1 {
    text-align: center;
    font-size: 38px;
    margin-bottom: 30px;
}

.ai-intro {
    background: #fff7ef;
    border-radius: 25px;
    padding: 30px;
    margin-bottom: 35px;
    line-height: 2;
    border-right: 5px solid var(--orange);
}

.ai-intro ul {
    padding-right: 25px;
    margin-top: 10px;
}

.ai-intro li {
    margin: 5px 0;
}

#physics-question {
    width: 100%;
    height: 180px;
    border: 1px solid #ddd;
    border-radius: 20px;
    padding: 20px;
    font-family: inherit;
    font-size: 18px;
    resize: vertical;
}

.ai-upload {
    margin: 20px 0;
}

#question-image {
    margin-top: 10px;
}

#start-ai {
    background: var(--orange);
    color: #ffffff;
    border: none;
    padding: 15px 40px;
    border-radius: 30px;
    font-size: 18px;
    cursor: pointer;
    font-weight: bold;
    transition: 0.3s;
    margin-top: 10px;
}

#start-ai:hover {
    background: var(--orange-hover);
}

.ai-result {
    margin-top: 40px;
    background: #fafafa;
    padding: 30px;
    border-radius: 25px;
    border-right: 5px solid var(--orange);
    line-height: 2;
}

/* فرمول‌های MathJax */
#ai-response {
    direction: rtl;
    text-align: right;
}

#ai-response mjx-container {
    direction: ltr;
    unicode-bidi: isolate;
}

#ai-response mjx-container[display="true"] {
    display: block;
    text-align: center;
    direction: ltr;
}

.math-inline {
    direction: ltr;
    unicode-bidi: isolate;
    display: inline-block;
    white-space: nowrap;
}

.math-display {
    direction: ltr;
    unicode-bidi: isolate;
    text-align: center;
    margin: 15px 0;
}

/* کنترل‌های AI */
#ai-controls {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 20px;
}

.ai-control-button {
    border: none;
    border-radius: 10px;
    padding: 11px 20px;
    cursor: pointer;
    font-family: inherit;
    font-size: 14px;
    background: var(--orange);
    color: #ffffff;
    transition: 0.2s;
}

.ai-control-button:hover {
    opacity: 0.9;
}

.ai-control-button.hint {
    background: #f59e0b;
}

.ai-control-button.full {
    background: var(--text-dark);
}

.ai-control-button.previous {
    background: #e5e7eb;
    color: var(--text-dark);
}

.ai-step-number {
    font-size: 13px;
    color: var(--orange);
    margin-bottom: 8px;
}

.ai-step-title {
    margin: 0 0 15px;
    font-size: 20px;
}

.ai-step-content {
    line-height: 2;
}

.ai-hint {
    margin-top: 15px;
    padding: 12px 15px;
    border-radius: 10px;
    background: var(--orange-light);
    line-height: 1.8;
}

.ai-full-section {
    margin-bottom: 25px;
}

.ai-full-section h4 {
    margin-bottom: 8px;
}

/* پیش‌نمایش تصویر AI */
.image-preview {
    margin-top: 15px;
    padding: 12px;
    background: var(--bg-light);
    border: 1px solid #e5e7eb;
    border-radius: 15px;
    text-align: center;
}

.image-preview img {
    display: block;
    max-width: 100%;
    max-height: 350px;
    margin: 0 auto 12px;
    border-radius: 12px;
    object-fit: contain;
}

#remove-image {
    border: none;
    background: #fee2e2;
    color: #b91c1c;
    padding: 8px 16px;
    border-radius: 8px;
    cursor: pointer;
    font-family: inherit;
}

#remove-image:hover {
    background: #fecaca;
}


/* =========================================================
   ۱۲) ووکامرس — همه صفحات
========================================================= */

.woocommerce {
    direction: rtl;
    width: 100%;
}

.woocommerce-page .site-main {
    width: 100%;
}

.woocommerce h1,
.woocommerce h2 {
    text-align: center;
    font-size: 36px;
    margin-bottom: 40px;
    color: var(--text-dark);
}

/* فرم‌های ورود و ثبت‌نام ووکامرس */
.woocommerce form.login,
.woocommerce form.register {
    max-width: 420px;
    margin: 30px auto;
    padding: 35px;
    border-radius: 20px;
    background: #ffffff;
    box-shadow: var(--shadow-light);
    border: 1px solid var(--border-light);
}

.woocommerce input.input-text {
    width: 100%;
    height: 48px;
    padding: 10px 15px;
    border-radius: 12px;
    border: 1px solid #d1d5db;
}

.woocommerce label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
}

.woocommerce button.button,
.woocommerce input.button,
.woocommerce a.button {
    background: var(--orange);
    color: #ffffff;
    border-radius: 30px;
    padding: 14px 25px;
    border: none;
    font-weight: bold;
    transition: 0.2s;
    cursor: pointer;
}

.woocommerce button.button:hover,
.woocommerce input.button:hover,
.woocommerce a.button:hover {
    background: var(--orange-hover);
    color: #ffffff;
}

/* سبد خرید */
.woocommerce-cart table.shop_table {
    background: #ffffff;
    border-radius: 25px;
    overflow: hidden;
    border: none;
    box-shadow: var(--shadow-light);
}

.woocommerce-cart table.shop_table td,
.woocommerce-cart table.shop_table th {
    padding: 20px;
    border-bottom: 1px solid #eee;
}

.woocommerce-cart .product-name a {
    color: var(--text-dark);
    font-weight: bold;
    font-size: 18px;
}

.woocommerce-cart .product-thumbnail img {
    width: 80px;
    border-radius: 12px;
}

.woocommerce-cart .cart_totals {
    background: #ffffff;
    padding: 35px;
    border-radius: 25px;
    box-shadow: var(--shadow-light);
    margin-top: 30px;
}

.woocommerce-cart a.checkout-button,
.woocommerce-checkout #place_order {
    background: var(--orange);
    color: #ffffff;
    border-radius: 30px;
    padding: 16px;
    font-size: 18px;
    text-align: center;
    width: 100%;
    border: none;
    font-weight: bold;
}

.woocommerce-cart a.checkout-button:hover,
.woocommerce-checkout #place_order:hover {
    background: var(--orange-hover);
}

/* تسویه حساب */
.woocommerce-checkout form.checkout {
    background: #ffffff;
    padding: 40px;
    border-radius: 30px;
    box-shadow: var(--shadow-light);
}

.woocommerce-checkout h3 {
    font-size: 26px;
    margin-bottom: 25px;
    color: var(--text-dark);
}

.woocommerce-checkout .form-row-first,
.woocommerce-checkout .form-row-last {
    width: 48%;
    float: right;
    margin-right: 2%;
}

.woocommerce-checkout .form-row-first {
    clear: right;
}

/* انتخاب پایه اشتراک */
.iphycs-grade-box {
    max-width: 450px;
    margin: 20px auto;
    padding: 20px 25px;
    background: var(--bg-light);
    border-radius: 15px;
    border: 1px solid var(--border-light);
    direction: rtl;
    text-align: right;
}

.iphycs-grade-box h3 {
    font-size: 24px;
    margin-bottom: 25px;
}

.iphycs-grade-box label {
    display: inline-block;
    margin: 5px 10px;
    padding: 8px 15px;
    background: #ffffff;
    border-radius: 10px;
    border: 1px solid #ddd;
    cursor: pointer;
    transition: 0.2s;
}

.iphycs-grade-box label:hover {
    background: var(--orange-light);
}

.iphycs-grade-box input[type="checkbox"] {
    width: 20px;
    height: 20px;
    accent-color: var(--orange);
}

/* حذف تصویر محصول */
.woocommerce-product-gallery {
    display: none;
}

.woocommerce div.product div.summary {
    width: 100%;
    float: none;
}

/* پیام‌های ووکامرس */
.woocommerce-message,
.woocommerce-info,
.woocommerce-error {
    border-radius: 20px;
    padding: 20px;
    margin-bottom: 30px;
}

/* صفحه حساب کاربری */
.woocommerce-account .woocommerce {
    max-width: 1200px;
    width: 90%;
    margin: 0 auto 80px;
    display: grid;
    gap: 20px;
    direction: rtl;
}

.woocommerce-account .woocommerce-MyAccount-navigation-wrapper {
    display: grid;
    grid-template-columns: 260px 1fr;
    gap: 40px;
    direction: rtl;
}

.woocommerce-account .woocommerce-MyAccount-navigation {
    background: #ffffff;
    border-radius: 20px;
    overflow: hidden;
    border: 1px solid #eeeeee;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    align-self: start;
}

.woocommerce-account .woocommerce-MyAccount-navigation ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

.woocommerce-account .woocommerce-MyAccount-navigation li {
    border-bottom: 1px solid #eeeeee;
}

.woocommerce-account .woocommerce-MyAccount-navigation li:last-child {
    border-bottom: none;
}

.woocommerce-account .woocommerce-MyAccount-navigation a {
    display: block;
    padding: 20px 25px;
    font-size: 16px;
    font-weight: 600;
    color: var(--primary-color);
    text-decoration: none;
    transition: 0.2s;
}

.woocommerce-account .woocommerce-MyAccount-navigation a:hover {
    background: var(--bg-light);
}

.woocommerce-account .woocommerce-MyAccount-navigation li.is-active a {
    background: var(--orange);
    color: #ffffff;
}

.woocommerce-account .woocommerce-MyAccount-content {
    background: #ffffff;
    border-radius: 20px;
    border: 1px solid #eeeeee;
    padding: 40px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    font-size: 14px;
    line-height: 2;
    color: #333;
    min-width: 0;
}

.woocommerce-account .woocommerce-MyAccount-content a {
    color: var(--orange);
}

/* صفحه تسویه بلوکی */
body.page-id-19 .wc-block-checkout {
    max-width: 1250px;
    padding: 20px;
    margin: 50px auto;
}

body.page-id-19 .wc-block-components-checkout-step,
body.page-id-19 .wc-block-components-order-summary {
    background: #ffffff;
    border-radius: 25px;
    padding: 30px;
    border: 1px solid #f1f5f9;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.06);
}

body.page-id-19 .wc-block-components-checkout-step__heading {
    font-size: 24px;
    font-weight: 700;
    color: var(--text-dark);
}

body.page-id-19 .wc-block-components-checkout-step {
    margin-bottom: 25px;
}

body.page-id-19 .wc-block-components-text-input input,
body.page-id-19 .wc-block-components-combobox-control input {
    height: 55px;
    border-radius: 14px;
    background: #ffffff;
}

body.page-id-19 .wc-block-components-checkout-place-order-button {
    background: var(--orange);
    border-radius: 15px;
    padding: 18px;
    font-size: 18px;
    font-weight: bold;
}


/* =========================================================
   ۱۳) فوتر
========================================================= */

.site-footer {
    width: 100%;
    margin-top: 70px;
    padding: 25px 20px;
    border-top: 1px solid #eeeeee;
    text-align: center;
    color: #9ca3af;
    font-size: 13px;
}


/* =========================================================
   ۱۴) دکمه شناور
========================================================= */

.floating-button {
    position: fixed;
    left: 25px;
    bottom: 25px;
    width: 70px;
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #ffffff;
    border: 1px solid #dddddd;
    border-radius: 50%;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    z-index: 9999;
}


/* =========================================================
   ۱۵) ریسپانسیو — تبلت (۹۰۰px)
========================================================= */

@media (max-width: 900px) {

    /* هدر موبایل */
    .site-header {
        padding: 12px 18px;
    }

    .site-header .header-inner {
        gap: 12px;
    }

    /* دکمه همبرگری نمایش داده می‌شه */
    .menu-toggle {
        display: flex;
    }

    /* منو تبدیل به Drawer از سمت راست */
    .site-header .main-menu {
        position: fixed;
        top: 0;
        right: -320px;
        width: 300px;
        max-width: 85vw;
        height: 100vh;
        background: #ffffff;
        box-shadow: -8px 0 30px rgba(15, 23, 42, 0.15);
        z-index: 999;
        padding: 25px 0;
        overflow-y: auto;
        transition: right 0.35s cubic-bezier(0.16, 1, 0.3, 1);
        display: block;
        flex: none;
        justify-content: flex-start;
    }

    .site-header .main-menu.is-open {
        right: 0;
    }

    .site-header .main-menu ul.menu {
        display: block;
        width: 100%;
        padding: 0;
        margin: 0;
    }

    .site-header .main-menu ul.menu li {
        display: block;
        width: 100%;
        border-bottom: 1px solid #f1f5f9;
    }

    .site-header .main-menu ul.menu li:last-child {
        border-bottom: none;
    }

    .site-header .main-menu ul.menu li a {
        display: flex;
        align-items: center;
        padding: 16px 25px;
        font-size: 15px;
        font-weight: 600;
        color: var(--text-dark);
        transition: 0.2s;
    }

    .site-header .main-menu ul.menu li a:hover {
        background: var(--orange-light);
        color: var(--orange);
        padding-right: 30px;
    }

    .site-header .site-logo img {
        width: 80px;
    }

    .site-header .logo {
        order: 1;
        flex: 1;
    }

    .site-header .header-cart {
        order: 2;
    }

    .menu-toggle {
        order: 3;
    }

    body.menu-is-open {
        overflow: hidden;
    }

    /* Hero */
    .hero {
        margin-top: 20px;
        padding: 45px 25px;
    }

    .hero h1 {
        font-size: 34px;
    }

    .hero p {
        font-size: 18px;
    }

    /* کارت‌ها */
    section.grades .chapter-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 20px;
    }

    /* اساتید */
    .teacher-list {
        grid-template-columns: repeat(2, 1fr);
    }

    .teacher-filter {
        grid-template-columns: 1fr;
    }

    .filter-actions {
        grid-column: span 1;
        flex-direction: column;
    }

    /* شبیه‌سازی */
    .simulation-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    /* اساتید page */
    .teachers-filter-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .teachers-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }

    .teacher-card-image {
        height: 230px;
    }

    /* پروفایل استاد */
    .teacher-avatar {
        width: 150px;
        height: 150px;
        border-width: 4px;
    }

    .teacher-name {
        font-size: 28px;
    }

    .teacher-info-row {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
        padding: 20px;
    }

    .info-item {
        flex-direction: row;
        justify-content: space-between;
        border-bottom: 1px solid #e5e7eb;
        padding-bottom: 8px;
    }

    .info-item:last-child {
        border-bottom: none;
    }

    .info-label {
        font-size: 13px;
    }

    .info-value {
        font-size: 16px;
        padding: 2px 14px;
    }

    .teacher-bio {
        padding: 20px;
    }

    /* ووکامرس */
    .woocommerce-account .woocommerce-MyAccount-navigation-wrapper {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .woocommerce-account .woocommerce-MyAccount-content {
        padding: 25px;
    }

    .woocommerce-checkout .col2-set,
    .woocommerce-checkout #order_review {
        width: 100%;
        float: none;
    }
}


/* =========================================================
   ۱۶) ریسپانسیو — موبایل (۶۰۰px)
========================================================= */

@media (max-width: 600px) {

    /* هدر */
    .site-header {
        padding: 10px 14px;
    }

    .site-header .site-logo img {
        width: 70px;
    }

    .menu-toggle {
        width: 38px;
        height: 38px;
    }

    .menu-toggle-bar {
        width: 18px;
    }

    .header-cart {
        width: 38px;
        height: 38px;
    }

    .header-cart-icon svg {
        width: 24px;
        height: 24px;
    }

    .site-header .main-menu {
        width: 280px;
    }

    .site-header .main-menu ul.menu li a {
        font-size: 14px;
        padding: 15px 20px;
    }

    /* Hero */
    .hero {
        min-height: 210px;
        padding: 35px 15px;
    }

    .hero h1 {
        font-size: 28px;
        line-height: 1.5;
        margin-bottom: 12px;
    }

    .hero p {
        font-size: 16px;
    }

    /* کارت‌های صفحه اول — ۲ تا در ردیف */
    section.grades {
        padding: 0 12px;
        margin: 0 auto;
    }

    section.grades .chapter-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 15px;
    }

    section.grades .chapter-grid .card {
        height: 210px;
        min-height: 210px;
        padding: 20px 10px;
    }

    section.grades .chapter-grid .card h2 {
        font-size: 17px;
        line-height: 1.6;
        margin-bottom: 8px;
    }

    section.grades .chapter-grid .card p {
        font-size: 11px;
        line-height: 1.7;
        margin-bottom: 8px;
    }

    section.grades .chapter-grid .card a {
        font-size: 11px;
        padding: 8px 12px;
        margin-top: 8px;
    }

    /* اساتید صفحه اصلی — ۲ تا در ردیف */
    .teachers {
        width: calc(100% - 24px);
        padding: 25px 12px;
        margin: 40px auto 30px;
        border-radius: 20px;
    }

    .teachers-title {
        margin-bottom: 20px;
    }

    .teachers-title h2 {
        font-size: 22px;
    }

    .teacher-list {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 12px;
    }

    .teacher-card {
        padding: 18px 8px;
    }

    .teacher-image img {
        width: 75px;
        height: 75px;
    }

    .teacher-card h3 {
        font-size: 14px;
        margin: 5px 0 8px;
    }

    .teacher-card p {
        font-size: 10px;
        margin: 4px 0;
    }

    .teacher-card > a {
        font-size: 9px;
        padding: 7px 9px;
    }

    /* صفحه فصل و شبیه‌سازی */
    .category-page,
    .simulations-page,
    .simulation-page {
        padding: 25px 12px;
    }

    .category-page h1,
    .simulations-page h1 {
        font-size: 27px;
        line-height: 1.6;
        margin-bottom: 25px;
    }

    .simulation-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .simulation-grid .card {
        min-height: 220px;
        padding: 25px 10px;
    }

    .simulation-grid .card h2,
    .simulation-grid .card h3 {
        font-size: 14px;
        line-height: 1.7;
    }

    .simulation-grid .card p {
        font-size: 10px;
    }

    .simulation-grid .card a,
    .simulation-button {
        font-size: 11px;
        padding: 8px 12px;
        width: 90%;
        max-width: 180px;
        text-align: center;
    }

    /* صفحه اساتید */
    .teachers-page {
        padding: 30px 14px 50px;
    }

    .teachers-page-header h1 {
        font-size: 28px;
    }

    .teachers-page-header p {
        font-size: 14px;
    }

    .teachers-filter-box {
        padding: 18px;
        border-radius: 16px;
    }

    .teachers-filter-grid {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    .teachers-filter-actions {
        flex-direction: column;
    }

    .teachers-filter-submit,
    .teachers-filter-reset {
        width: 100%;
    }

    .teachers-grid {
        grid-template-columns: 1fr;
        gap: 18px;
    }

    .teacher-card-image {
        height: 260px;
    }

    .teacher-card-content {
        padding: 20px;
    }

    .teacher-card-name {
        font-size: 19px;
    }

    /* پروفایل استاد */
    .teacher-content-columns {
        grid-template-columns: 1fr;
        gap: 35px;
        max-width: 600px;
        padding: 0 15px;
    }

    .teacher-section-title {
        font-size: 20px;
    }

    .teacher-avatar {
        width: 120px;
        height: 120px;
    }

    .teacher-name {
        font-size: 24px;
    }

    /* ووکامرس */
    .woocommerce h1,
    .woocommerce h2 {
        font-size: 26px;
        margin-bottom: 25px;
    }

    .woocommerce-account .woocommerce {
        width: 95%;
    }

    /* فوتر */
    .site-footer {
        margin-top: 40px;
        padding: 20px 10px;
        font-size: 11px;
    }

    /* دکمه شناور */
    .floating-button {
        width: 60px;
        height: 60px;
        left: 15px;
        bottom: 15px;
    }
}


/* =========================================================
   ۱۷) ریسپانسیو — موبایل خیلی کوچک (۳۸۰px)
========================================================= */

@media (max-width: 380px) {

    .site-logo img {
        width: 65px;
    }

    section.grades {
        padding: 0 8px;
    }

    section.grades .chapter-grid {
        gap: 10px;
    }

    section.grades .chapter-grid .card {
        height: 195px;
        min-height: 195px;
        padding: 15px 7px;
    }

    section.grades .chapter-grid .card h2 {
        font-size: 15px;
    }

    section.grades .chapter-grid .card p {
        font-size: 10px;
    }

    section.grades .chapter-grid .card a {
        font-size: 10px;
        padding: 7px 9px;
    }

    .teachers {
        padding: 20px 8px;
    }

    .teacher-list {
        gap: 8px;
    }

    .teacher-card {
        padding: 15px 5px;
    }

    .teacher-image img {
        width: 65px;
        height: 65px;
    }

    .teacher-card h3 {
        font-size: 13px;
    }

    .teacher-content-columns {
        padding: 0 12px;
    }

    .teacher-section-title {
        font-size: 19px;
    }

    .course-thumb {
        height: 135px;
    }
}
/* =========================================================
   FIX — صفحه شبیه‌سازی‌ها (taxonomy-simulation_category)
========================================================= */

/* شبکه شبیه‌سازی‌ها */
.category-page .simulation-grid,
.simulations-page .simulation-grid {
    display: grid !important;
    grid-template-columns: repeat(4, 1fr) !important;
    gap: 30px !important;
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    box-sizing: border-box !important;
}

/* خود کارت‌ها */
.category-page .simulation-grid .card,
.simulations-page .simulation-grid .card {
    display: flex !important;
    flex-direction: column !important;
    justify-content: center !important;
    align-items: center !important;
    text-align: center !important;

    background: #ffffff !important;
    border-radius: 20px !important;
    border: 1px solid #e5e7eb !important;
    border-top: 6px solid var(--primary-color) !important;

    padding: 25px 20px !important;
    min-height: 220px !important;

    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.06) !important;
    transition: all 0.3s ease !important;
    box-sizing: border-box !important;
    width: 100% !important;
}

/* عنوان کارت */
.category-page .simulation-grid .card h2,
.simulations-page .simulation-grid .card h2 {
    font-size: 19px !important;
    color: var(--text-dark) !important;
    margin: 0 0 12px !important;
    line-height: 1.7 !important;
}

/* توضیح کارت */
.category-page .simulation-grid .card p,
.simulations-page .simulation-grid .card p {
    color: var(--text-gray) !important;
    font-size: 14px !important;
    line-height: 1.8 !important;
    margin: 0 0 18px !important;
}

/* دکمه */
.category-page .simulation-grid .card .simulation-link,
.simulations-page .simulation-grid .card .simulation-link {
    display: inline-block !important;
    background: var(--orange) !important;
    color: #ffffff !important;
    padding: 10px 25px !important;
    border-radius: 30px !important;
    font-weight: bold !important;
    font-size: 14px !important;
    text-decoration: none !important;
    transition: 0.3s !important;
    margin-top: auto !important;
}

.category-page .simulation-grid .card .simulation-link:hover,
.simulations-page .simulation-grid .card .simulation-link:hover {
    background: var(--orange-hover) !important;
    transform: translateY(-3px) !important;
}

/* هاور کارت */
.category-page .simulation-grid .card:hover,
.simulations-page .simulation-grid .card:hover {
    background: var(--primary-color) !important;
    transform: translateY(-8px) !important;
    box-shadow: 0 20px 40px rgba(26, 42, 74, 0.2) !important;
}

.category-page .simulation-grid .card:hover h2,
.category-page .simulation-grid .card:hover p {
    color: #ffffff !important;
}

.category-page .simulation-grid .card:hover .simulation-link,
.simulations-page .simulation-grid .card:hover .simulation-link {
    background: #ffffff !important;
    color: var(--primary-color) !important;
}

/* --- موبایل: یک کارت در ردیف --- */
@media (max-width: 900px) {

    .category-page .simulation-grid,
    .simulations-page .simulation-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 20px !important;
    }
}

@media (max-width: 600px) {

    .category-page .simulation-grid,
    .simulations-page .simulation-grid {
        grid-template-columns: 1fr !important;
        gap: 15px !important;
    }

    .category-page .simulation-grid .card,
    .simulations-page .simulation-grid .card {
        min-height: 180px !important;
        padding: 20px 15px !important;
    }

    .category-page .simulation-grid .card h2,
    .simulations-page .simulation-grid .card h2 {
        font-size: 16px !important;
    }

    .category-page .simulation-grid .card p,
    .simulations-page .simulation-grid .card p {
        font-size: 12px !important;
    }
}
/* =========================================================
   صفحه شبیه‌سازی‌ها — simulations-page
========================================================= */

.simulations-page {
    width: 100%;
    max-width: 1200px;
    margin: 40px auto;
    padding: 0 20px;
    box-sizing: border-box;
}

.simulations-page h1 {
    text-align: center;
    font-size: 38px;
    color: var(--text-dark);
    margin: 0 0 45px;
    background: transparent;
    padding: 0;
}

/* شبکه کارت‌ها */
.simulations-page .simulation-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 25px;
    width: 100%;
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* خود کارت */
.simulations-page .simulation-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;

    width: 100%;
    min-width: 0;
    min-height: 300px;

    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-top: 6px solid var(--primary-color);
    border-radius: 20px;

    padding: 28px 20px;

    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.06);
    transition: all 0.3s ease;
    box-sizing: border-box;
    overflow: hidden;
}

.simulations-page .simulation-card:hover {
    transform: translateY(-8px);
    background: var(--primary-color);
    border-color: var(--primary-color);
    box-shadow: 0 20px 40px rgba(26, 42, 74, 0.2);
}

/* عنوان */
.simulations-page .simulation-card h2 {
    font-size: 18px;
    line-height: 1.6;
    font-weight: 700;
    margin: 0 0 15px;
    color: var(--text-dark);
}

.simulations-page .simulation-card h2 a {
    color: inherit;
    text-decoration: none;
    transition: color 0.2s;
}

/* توضیح */
.simulations-page .simulation-card p {
    font-size: 13px;
    line-height: 1.9;
    color: var(--text-gray);
    margin: 0 0 20px;
    flex: 1;
}

/* دکمه */
.simulations-page .simulation-card > a {
    display: inline-block;
    background: var(--orange);
    color: #ffffff;
    padding: 10px 22px;
    border-radius: 30px;
    font-size: 13px;
    font-weight: 700;
    text-decoration: none;
    transition: 0.3s;
    margin-top: auto;
    white-space: nowrap;
}

.simulations-page .simulation-card > a:hover {
    background: var(--orange-hover);
    transform: translateY(-2px);
}

/* هاور کارت — متن‌ها سفید */
.simulations-page .simulation-card:hover h2,
.simulations-page .simulation-card:hover h2 a,
.simulations-page .simulation-card:hover p {
    color: #ffffff;
}

.simulations-page .simulation-card:hover > a {
    background: #ffffff;
    color: var(--primary-color);
}

.simulations-page .simulation-card:hover > a:hover {
    background: var(--orange);
    color: #ffffff;
}

/* =========================================================
   موبایل
========================================================= */

@media (max-width: 900px) {

    .simulations-page .simulation-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 18px;
    }

    .simulations-page .simulation-card {
        min-height: 260px;
        padding: 22px 15px;
    }

    .simulations-page .simulation-card h2 {
        font-size: 16px;
    }

    .simulations-page .simulation-card p {
        font-size: 12px;
    }
}

@media (max-width: 600px) {

    .simulations-page {
        padding: 0 12px;
        margin: 30px auto;
    }

    .simulations-page h1 {
        font-size: 26px;
        margin-bottom: 30px;
    }

    .simulations-page .simulation-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .simulations-page .simulation-card {
        min-height: 200px;
        padding: 20px 15px;
    }

    .simulations-page .simulation-card h2 {
        font-size: 15px;
        margin-bottom: 10px;
    }

    .simulations-page .simulation-card p {
        font-size: 12px;
        margin-bottom: 15px;
    }

    .simulations-page .simulation-card > a {
        padding: 9px 20px;
        font-size: 12px;
    }
}
/* =========================================================
   FIX — یکسان‌سازی نوار بالای کارت معلم هوشمند
========================================================= */

section.grades .chapter-grid .card.ai-card,
section.grades .chapter-grid .card.ai-card:hover {
    border-top-color: var(--primary-color) !important;
}

/* اگه کلاس دیگه‌ای هم هست */
.card.ai-card,
.card.ai-card:hover {
    border-top-color: var(--primary-color) !important;
}
/* =========================================================
   Header Layout — لوگو + سبد چپ ، منو راست
========================================================= */

/* هدر */
.site-header {
    width: 100%;
    padding: 12px 40px;
    background: #fff;
    border-bottom: 1px solid #f1f1f1;
    position: sticky;
    top: 0;
    z-index: 999;
    box-sizing: border-box;
}

/* ردیف داخلی */
.site-header .header-inner {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 25px;
    box-sizing: border-box;
}

/* ============================================
   ۱) لوگو — اول (سمت چپ)
============================================ */
.site-header .logo {
    order: 1;
    flex-shrink: 0;
    display: flex;
    align-items: center;
}

.site-header .site-logo img {
    display: block;
    width: 100px;
    height: auto;
}

/* ============================================
   ۲) سبد خرید — بلافاصله بعد از لوگو
============================================ */
.site-header .header-actions {
    order: 2;
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.site-header .header-cart {
    position: relative;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #111827;
    text-decoration: none;
    transition: color 0.2s;
}

.site-header .header-cart:hover {
    color: #f97316;
}

.site-header .header-cart svg {
    width: 26px;
    height: 26px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.site-header .header-cart-count {
    position: absolute;
    top: 0;
    right: 0;
    min-width: 18px;
    height: 18px;
    padding: 0 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f97316;
    color: #fff;
    border-radius: 50%;
    font-size: 10px;
    font-weight: bold;
}

/* دکمه همبرگری — مخفی در دسکتاپ */
.site-header .menu-toggle {
    display: none;
}

/* ============================================
   ۳) منو — آخرین آیتم (سمت راست)
============================================ */
.site-header .main-menu {
    order: 3;
    margin-left: auto;              /* ← هل به راست */
    display: flex;
    direction: rtl;
}

.site-header .main-menu ul.menu {
    margin: 0;
    padding: 0;
    display: flex;
    align-items: center;
    gap: 28px;
    list-style: none;
}

.site-header .main-menu ul.menu li {
    margin: 0;
    padding: 0;
    list-style: none;
}

.site-header .main-menu ul.menu li a {
    display: block;
    color: #111827;
    font-size: 15px;
    font-weight: 500;
    white-space: nowrap;
    text-decoration: none;
    padding: 6px 0;
    transition: color 0.2s;
}

.site-header .main-menu ul.menu li a:hover {
    color: #f97316;
}

/* ============================================
   اورلی
============================================ */
.menu-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.55);
    z-index: 998;
    opacity: 0;
    transition: opacity 0.3s;
}

.menu-overlay.is-visible {
    display: block;
    opacity: 1;
}


/* =========================================================
   موبایل — منو تبدیل به Drawer زیبا
========================================================= */

@media (max-width: 900px) {

    .site-header {
        padding: 12px 18px;
    }

    .site-header .header-inner {
        gap: 12px;
    }

    /* نمایش دکمه همبرگری */
    .site-header .menu-toggle {
        display: flex;
        width: 40px;
        height: 40px;
        background: transparent;
        border: 1px solid #e5e7eb;
        border-radius: 10px;
        cursor: pointer;
        padding: 0;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 5px;
        transition: 0.2s;
        flex-shrink: 0;
        order: 4;                       /* بعد از سبد */
    }

    .site-header .menu-toggle:hover {
        border-color: #f97316;
        background: #fff7ed;
    }

    .site-header .menu-toggle-bar {
        display: block;
        width: 20px;
        height: 2px;
        background: #111827;
        border-radius: 2px;
        transition: 0.3s;
        transform-origin: center;
    }

    /* تبدیل به X وقتی بازه */
    .site-header .menu-toggle.is-open .menu-toggle-bar:nth-child(1) {
        transform: translateY(7px) rotate(45deg);
    }

    .site-header .menu-toggle.is-open .menu-toggle-bar:nth-child(2) {
        opacity: 0;
    }

    .site-header .menu-toggle.is-open .menu-toggle-bar:nth-child(3) {
        transform: translateY(-7px) rotate(-45deg);
    }

    /* ========================================
       منو → Drawer از سمت راست
    ======================================== */
    .site-header .main-menu {
        position: fixed;
        top: 0;
        right: -320px;
        width: 300px;
        max-width: 85vw;
        height: 100vh;
        background: #ffffff;
        box-shadow: -10px 0 40px rgba(15, 23, 42, 0.18);
        z-index: 1000;
        padding: 30px 0;
        overflow-y: auto;
        transition: right 0.35s cubic-bezier(0.16, 1, 0.3, 1);
        display: block;
        flex: none;
        margin-left: 0;
        direction: rtl;
        box-sizing: border-box;
    }

    .site-header .main-menu.is-open {
        right: 0;
    }

    /* سربرگ Drawer */
    .site-header .main-menu::before {
        content: "منو";
        display: block;
        padding: 0 25px 20px;
        font-size: 20px;
        font-weight: 800;
        color: #1e3152;
        border-bottom: 2px solid #f97316;
        margin-bottom: 15px;
    }

    /* آیتم‌های منو */
    .site-header .main-menu ul.menu {
        display: block;
        width: 100%;
        padding: 0;
        margin: 0;
    }

    .site-header .main-menu ul.menu li {
        display: block;
        width: 100%;
        border-bottom: 1px solid #f1f5f9;
    }

    .site-header .main-menu ul.menu li:last-child {
        border-bottom: none;
    }

    .site-header .main-menu ul.menu li a {
        display: flex;
        align-items: center;
        padding: 16px 25px;
        font-size: 15px;
        font-weight: 600;
        color: #111827;
        border-radius: 0;
        position: relative;
        transition: 0.2s;
    }

    /* آیکون فلش کوچیک سمت چپ هر آیتم */
    .site-header .main-menu ul.menu li a::before {
        content: "←";
        position: absolute;
        left: 20px;
        top: 50%;
        transform: translateY(-50%);
        color: #f97316;
        font-size: 16px;
        opacity: 0;
        transition: 0.2s;
    }

    .site-header .main-menu ul.menu li a:hover {
        background: #fff7ed;
        color: #f97316;
        padding-right: 32px;
    }

    .site-header .main-menu ul.menu li a:hover::before {
        opacity: 1;
    }

    /* لوگو کوچیک‌تر در موبایل */
    .site-header .site-logo img {
        width: 75px;
    }

    /* جلوگیری از اسکرول صفحه وقتی منو بازه */
    body.menu-is-open {
        overflow: hidden;
    }
}


/* =========================================================
   موبایل کوچیک — ۵۰۰px
========================================================= */

@media (max-width: 500px) {

    .site-header {
        padding: 10px 14px;
    }

    .site-header .site-logo img {
        width: 65px;
    }

    .site-header .header-cart {
        width: 36px;
        height: 36px;
    }

    .site-header .header-cart svg {
        width: 22px;
        height: 22px;
    }

    .site-header .menu-toggle {
        width: 36px;
        height: 36px;
    }

    .site-header .menu-toggle-bar {
        width: 18px;
    }

    .site-header .main-menu {
        width: 280px;
    }

    .site-header .main-menu ul.menu li a {
        font-size: 14px;
        padding: 15px 20px;
    }
}
/* =========================================================
   Header — چیدمان: لوگو+سبد چپ ، منو راست
========================================================= */

.site-header {
    width: 100%;
    padding: 12px 40px;
    background: #fff;
    border-bottom: 1px solid #f1f1f1;
    position: sticky;
    top: 0;
    z-index: 999;
    box-sizing: border-box;
}

.site-header .header-inner {
    max-width: 1400px;
    margin: 0 auto;

    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;

    /* 🔑 جهت LTR → لوگو از چپ شروع می‌شه */
    direction: ltr;

    box-sizing: border-box;
}

/* لوگو + سبد → چپ */
.site-header .logo {
    display: flex;
    align-items: center;
    gap: 15px;
    order: 1;
    flex-shrink: 0;
}

.site-header .site-logo img {
    display: block;
    width: 100px;
    height: auto;
}

/* منو → راست */
.site-header .main-menu {
    order: 2;
    display: flex;
    direction: rtl;
    margin: 0;
}

.site-header .main-menu ul.menu {
    margin: 0;
    padding: 0;
    display: flex;
    align-items: center;
    gap: 28px;
    list-style: none;
}

.site-header .main-menu ul.menu li {
    margin: 0;
    padding: 0;
    list-style: none;
}

.site-header .main-menu ul.menu li a {
    display: block;
    color: #111827;
    font-size: 15px;
    font-weight: 500;
    white-space: nowrap;
    text-decoration: none;
    padding: 6px 0;
    transition: color 0.2s;
}

.site-header .main-menu ul.menu li a:hover {
    color: #f97316;
}
/* =========================================================
   Header — چیدمان نهایی: [لوگو] [سبد]     [منو]
========================================================= */

.site-header {
    width: 100%;
    padding: 12px 40px;
    background: #fff;
    border-bottom: 1px solid #f1f1f1;
    position: sticky;
    top: 0;
    z-index: 999;
    box-sizing: border-box;
}

.site-header .header-inner {
    max-width: 1400px;
    margin: 0 auto;

    display: flex;
    align-items: center;

    /* 🔑 جهت LTR → از چپ شروع می‌کنه */
    direction: ltr;

    gap: 15px;

    box-sizing: border-box;
}

/* ============================================
   ۱) لوگو — چپ
============================================ */
.site-header .logo {
    order: 1;
    flex-shrink: 0;
    display: flex;
    align-items: center;
}

.site-header .site-logo img {
    display: block;
    width: 100px;
    height: auto;
}

/* ============================================
   ۲) سبد خرید + همبرگری — کنار لوگو
============================================ */
.site-header .header-actions {
    order: 2;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.site-header .header-cart {
    position: relative;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #111827;
    text-decoration: none;
    transition: color 0.2s;
}

.site-header .header-cart:hover {
    color: #f97316;
}

.site-header .header-cart svg {
    width: 26px;
    height: 26px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.site-header .header-cart-count {
    position: absolute;
    top: 0;
    right: 0;
    min-width: 18px;
    height: 18px;
    padding: 0 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f97316;
    color: #fff;
    border-radius: 50%;
    font-size: 10px;
    font-weight: bold;
}

/* دکمه همبرگری — مخفی در دسکتاپ */
.site-header .menu-toggle {
    display: none;
}

/* ============================================
   ۳) منو — راست (آخرین آیتم)
============================================ */
.site-header .main-menu {
    order: 3;

    /* 🔑 این کلید ماجراست: هل به راست */
    margin-left: auto;

    display: flex;
    direction: rtl;
}

.site-header .main-menu ul.menu {
    margin: 0;
    padding: 0;
    display: flex;
    align-items: center;
    gap: 28px;
    list-style: none;
}

.site-header .main-menu ul.menu li {
    margin: 0;
    padding: 0;
    list-style: none;
}

.site-header .main-menu ul.menu li a {
    display: block;
    color: #111827;
    font-size: 15px;
    font-weight: 500;
    white-space: nowrap;
    text-decoration: none;
    padding: 6px 0;
    transition: color 0.2s;
}

.site-header .main-menu ul.menu li a:hover {
    color: #f97316;
}
/* =========================================================
   ⚡ IPHYCS Header OVERRIDE — همه‌ی کدهای قبلی رو بی‌اثر می‌کنه
   این کد رو آخرین چیز توی style.css بذار
========================================================= */

/* ---------- هدر پایه ---------- */

body .site-header {
    width: 100% !important;
    padding: 12px 20px !important;
    margin: 0 !important;
    background: #fff !important;
    border-bottom: 1px solid #f1f1f1 !important;
    position: sticky !important;
    top: 0 !important;
    z-index: 9999 !important;
    box-sizing: border-box !important;
    display: block !important;
}

body .site-header .header-inner {
    width: 100% !important;
    max-width: 1400px !important;
    margin: 0 auto !important;
    padding: 0 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    direction: ltr !important;
    gap: 15px !important;
    box-sizing: border-box !important;
}

/* ---------- ۱) لوگو (چپ) ---------- */

body .site-header .logo {
    order: 1 !important;
    flex: 0 0 auto !important;
    display: flex !important;
    align-items: center !important;
    margin: 0 !important;
    padding: 0 !important;
}

body .site-header .site-logo {
    display: block !important;
    margin: 0 !important;
    padding: 0 !important;
}

body .site-header .site-logo img {
    display: block !important;
    width: 100px !important;
    max-width: 100% !important;
    height: auto !important;
    margin: 0 !important;
    padding: 0 !important;
}

/* ---------- ۲) سبد خرید + همبرگری (کنار لوگو) ---------- */

body .site-header .header-actions {
    order: 2 !important;
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
    margin: 0 !important;
    padding: 0 !important;
    flex: 0 0 auto !important;
}

body .site-header .header-cart {
    position: relative !important;
    width: 42px !important;
    height: 42px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    color: #111827 !important;
    text-decoration: none !important;
    margin: 0 !important;
    padding: 0 !important;
    transition: color 0.2s !important;
    background: transparent !important;
    border: none !important;
}

body .site-header .header-cart:hover {
    color: #f97316 !important;
}

body .site-header .header-cart-icon {
    width: 34px !important;
    height: 34px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}

body .site-header .header-cart svg,
body .site-header .header-cart-icon svg {
    width: 26px !important;
    height: 26px !important;
    fill: none !important;
    stroke: currentColor !important;
    stroke-width: 1.8 !important;
    stroke-linecap: round !important;
    stroke-linejoin: round !important;
}

body .site-header .header-cart-count {
    position: absolute !important;
    top: 0 !important;
    right: 0 !important;
    min-width: 18px !important;
    height: 18px !important;
    padding: 0 4px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    background: #f97316 !important;
    color: #fff !important;
    border-radius: 50% !important;
    font-size: 10px !important;
    font-weight: bold !important;
    line-height: 1 !important;
    box-sizing: border-box !important;
}

/* ---------- ۳) منو (راست) ---------- */

body .site-header .main-menu {
    order: 3 !important;
    margin-left: auto !important;
    margin-right: 0 !important;
    display: flex !important;
    direction: rtl !important;
    flex: 0 0 auto !important;
    padding: 0 !important;
}

body .site-header .main-menu ul.menu {
    margin: 0 !important;
    padding: 0 !important;
    display: flex !important;
    align-items: center !important;
    gap: 24px !important;
    list-style: none !important;
}

body .site-header .main-menu ul.menu li {
    margin: 0 !important;
    padding: 0 !important;
    list-style: none !important;
}

body .site-header .main-menu ul.menu li a {
    display: block !important;
    color: #111827 !important;
    font-size: 15px !important;
    font-weight: 500 !important;
    white-space: nowrap !important;
    text-decoration: none !important;
    padding: 6px 0 !important;
    margin: 0 !important;
    background: transparent !important;
    border: none !important;
    border-radius: 0 !important;
    transition: color 0.2s !important;
    line-height: 1.5 !important;
}

body .site-header .main-menu ul.menu li a:hover {
    color: #f97316 !important;
    background: transparent !important;
}

/* ---------- دکمه همبرگری ---------- */

body .site-header .menu-toggle {
    display: none !important;
    width: 42px !important;
    height: 42px !important;
    background: transparent !important;
    border: 1px solid #e5e7eb !important;
    border-radius: 10px !important;
    cursor: pointer !important;
    padding: 0 !important;
    margin: 0 !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 5px !important;
    transition: 0.2s !important;
    flex-shrink: 0 !important;
    box-sizing: border-box !important;
}

body .site-header .menu-toggle:hover {
    border-color: #f97316 !important;
    background: #fff7ed !important;
}

body .site-header .menu-toggle-bar {
    display: block !important;
    width: 20px !important;
    height: 2px !important;
    background: #111827 !important;
    border-radius: 2px !important;
    transition: 0.3s !important;
    transform-origin: center !important;
}

body .site-header .menu-toggle.is-open .menu-toggle-bar:nth-child(1) {
    transform: translateY(7px) rotate(45deg) !important;
}

body .site-header .menu-toggle.is-open .menu-toggle-bar:nth-child(2) {
    opacity: 0 !important;
}

body .site-header .menu-toggle.is-open .menu-toggle-bar:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg) !important;
}

/* ---------- اورلی ---------- */

body .menu-overlay {
    display: none !important;
    position: fixed !important;
    inset: 0 !important;
    background: rgba(15, 23, 42, 0.55) !important;
    z-index: 9998 !important;
    opacity: 0 !important;
    transition: opacity 0.3s !important;
}

body .menu-overlay.is-visible {
    display: block !important;
    opacity: 1 !important;
}


/* =========================================================
   موبایل — کمتر از ۹۰۰px
========================================================= */

@media (max-width: 900px) {

    body .site-header {
        padding: 12px 15px !important;
    }

    body .site-header .header-inner {
        gap: 10px !important;
    }

    /* نمایش دکمه همبرگری */
    body .site-header .menu-toggle {
        display: flex !important;
    }

    /* لوگو کوچیک‌تر */
    body .site-header .site-logo img {
        width: 80px !important;
    }

    /* ==========================================
       منو → Drawer از سمت راست
    ========================================== */

    body .site-header .main-menu {
        position: fixed !important;
        top: 0 !important;
        right: -320px !important;
        left: auto !important;
        width: 300px !important;
        max-width: 85vw !important;
        height: 100vh !important;
        background: #ffffff !important;
        box-shadow: -10px 0 40px rgba(15, 23, 42, 0.18) !important;
        z-index: 9999 !important;
        padding: 25px 0 !important;
        margin: 0 !important;
        overflow-y: auto !important;
        overflow-x: hidden !important;
        transition: right 0.35s cubic-bezier(0.16, 1, 0.3, 1) !important;
        display: block !important;
        flex: none !important;
        direction: rtl !important;
        box-sizing: border-box !important;
    }

    body .site-header .main-menu.is-open {
        right: 0 !important;
    }

    /* ==========================================
       آیتم‌های منو — حتماً نمایش داده بشن
    ========================================== */

    body .site-header .main-menu ul.menu {
        display: block !important;
        width: 100% !important;
        max-width: 100% !important;
        padding: 0 !important;
        margin: 0 !important;
        list-style: none !important;
        flex-direction: column !important;
        gap: 0 !important;
    }

    body .site-header .main-menu ul.menu li {
        display: block !important;
        width: 100% !important;
        margin: 0 !important;
        padding: 0 !important;
        border-bottom: 1px solid #f1f5f9 !important;
        list-style: none !important;
    }

    body .site-header .main-menu ul.menu li:last-child {
        border-bottom: none !important;
    }

    body .site-header .main-menu ul.menu li a {
        display: block !important;
        width: 100% !important;
        padding: 16px 25px !important;
        font-size: 15px !important;
        font-weight: 600 !important;
        color: #111827 !important;
        text-align: right !important;
        text-decoration: none !important;
        background: transparent !important;
        border: none !important;
        box-sizing: border-box !important;
        transition: 0.2s !important;
        line-height: 1.6 !important;
    }

    body .site-header .main-menu ul.menu li a:hover {
        background: #fff7ed !important;
        color: #f97316 !important;
        padding-right: 32px !important;
    }

    /* جلوگیری از اسکرول وقتی منو بازه */
    body.menu-is-open {
        overflow: hidden !important;
    }
}


/* =========================================================
   موبایل کوچیک — کمتر از ۵۰۰px
========================================================= */

@media (max-width: 500px) {

    body .site-header {
        padding: 10px 12px !important;
    }

    body .site-header .site-logo img {
        width: 70px !important;
    }

    body .site-header .header-cart {
        width: 38px !important;
        height: 38px !important;
    }

    body .site-header .header-cart svg,
    body .site-header .header-cart-icon svg {
        width: 22px !important;
        height: 22px !important;
    }

    body .site-header .menu-toggle {
        width: 38px !important;
        height: 38px !important;
    }

    body .site-header .menu-toggle-bar {
        width: 18px !important;
    }

    body .site-header .main-menu {
        width: 280px !important;
    }

    body .site-header .main-menu ul.menu li a {
        font-size: 14px !important;
        padding: 15px 20px !important;
    }
}
