/* ═══════════════════════════════════════════════════════════════
   MyOstad Platform — Design System v3.1
   Academic Authority × Modern Social × Persian-First
   ─────────────────────────────────────────────────────────────
   فونت‌ها، متغیرها، ریست، تایپوگرافی، کامپوننت‌های پایه
   ═══════════════════════════════════════════════════════════════ */

@import url('https://fonts.googleapis.com/css2?family=Vazirmatn:wght@100;200;300;400;500;600;700;800;900&display=swap');
@import url('https://fonts.googleapis.com/css2?family=DM+Serif+Display:ital@0;1&display=swap');

/* ══════════════════════════════════════════════════════════════
   ۱. CSS Variables — Dark Theme (پیش‌فرض)
   ══════════════════════════════════════════════════════════════ */
:root {
  /* ── Palette Core ─────────────────────────────────────── */
  --navy-950:   #050c1a;
  --navy-900:   #0a1628;
  --navy-800:   #0f2044;
  --navy-700:   #1a3060;
  --navy-600:   #1e3a8a;
  --navy-500:   #2563eb;
  --navy-400:   #3b82f6;
  --navy-300:   #60a5fa;

  --gold-600:   #b8860b;
  --gold-500:   #d4a017;
  --gold-400:   #e8b84b;
  --gold-300:   #f5cc6a;
  --gold-200:   #fce89a;
  --gold-100:   #fff8dc;
  --gold-glow:  rgba(212, 160, 23, 0.25);

  --cream-100:  #fefdf8;
  --cream-200:  #faf8f0;
  --cream-300:  #f5f1e0;

  /* ── Surface Layers ───────────────────────────────────── */
  --surface-0:  rgba(255,255,255,0.02);
  --surface-1:  rgba(255,255,255,0.05);
  --surface-2:  rgba(255,255,255,0.09);
  --surface-3:  rgba(255,255,255,0.14);
  --surface-4:  rgba(255,255,255,0.20);

  /* ── Borders ──────────────────────────────────────────── */
  --border-subtle:  rgba(255,255,255,0.07);
  --border-mid:     rgba(255,255,255,0.13);
  --border-strong:  rgba(255,255,255,0.22);
  --border-focus:   rgba(59,130,246,0.6);

  /* ── Status Colors ────────────────────────────────────── */
  --success:      #10b981;
  --success-dim:  rgba(16,185,129,0.15);
  --warning:      #f59e0b;
  --warning-dim:  rgba(245,158,11,0.15);
  --danger:       #ef4444;
  --danger-dim:   rgba(239,68,68,0.12);
  --info:         #06b6d4;
  --info-dim:     rgba(6,182,212,0.12);

  /* ── Typography ───────────────────────────────────────── */
  --font-fa:   'Vazirmatn', system-ui, sans-serif;
  --font-en:   'DM Serif Display', Georgia, serif;
  --font-mono: 'Courier New', monospace;

  /* ── Spacing Scale ────────────────────────────────────── */
  --sp-1:  4px;   --sp-2:  8px;   --sp-3:  12px;  --sp-4:  16px;
  --sp-5:  20px;  --sp-6:  24px;  --sp-7:  28px;  --sp-8:  32px;
  --sp-10: 40px;  --sp-12: 48px;  --sp-16: 64px;  --sp-20: 80px;

  /* ── Border Radius ────────────────────────────────────── */
  --r-xs:   4px;   --r-sm:   8px;   --r-md:   14px;
  --r-lg:   20px;  --r-xl:   28px;  --r-2xl:  40px;
  --r-full: 9999px;

  /* ── Shadows ──────────────────────────────────────────── */
  --shadow-xs:   0 1px 4px rgba(0,0,0,0.2);
  --shadow-sm:   0 2px 10px rgba(0,0,0,0.28);
  --shadow-md:   0 4px 28px rgba(0,0,0,0.38);
  --shadow-lg:   0 8px 48px rgba(0,0,0,0.48);
  --shadow-xl:   0 16px 64px rgba(0,0,0,0.56);
  --shadow-gold: 0 4px 28px rgba(212,160,23,0.32);
  --shadow-blue: 0 4px 28px rgba(59,130,246,0.32);
  --shadow-inner: inset 0 1px 0 rgba(255,255,255,0.08);

  /* ── Glass ────────────────────────────────────────────── */
  --glass-bg:       rgba(10, 22, 40, 0.80);
  --glass-bg-light: rgba(255,255,255,0.06);
  --glass-border:   rgba(255,255,255,0.10);
  --glass-blur:     blur(24px);
  --glass-sat:      saturate(1.4);

  /* ── Z-index Stack ────────────────────────────────────── */
  --z-base:    1;
  --z-card:    10;
  --z-sticky:  100;
  --z-drawer:  800;
  --z-modal:   1000;
  --z-toast:   2000;
  --z-fab:     500;

  /* ── Transitions ──────────────────────────────────────── */
  --ease-out:    cubic-bezier(0.22, 1, 0.36, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --ease-in:     cubic-bezier(0.4, 0, 1, 1);
  --ease-smooth: cubic-bezier(0.4, 0, 0.2, 1);
  --dur-fast:    140ms;
  --dur-mid:     260ms;
  --dur-slow:    420ms;
  --dur-xslow:   600ms;

  /* ── Layout ───────────────────────────────────────────── */
  --max-app:    560px;
  --nav-h:      68px;
  --fab-h:      80px;
}

/* ── Light Theme ────────────────────────────────────────────── */
[data-theme="light"] {
  --navy-950:   #f0f5ff;
  --navy-900:   #e4ecff;
  --navy-800:   #cddaf8;
  --surface-0:  rgba(15,32,68,0.02);
  --surface-1:  rgba(15,32,68,0.04);
  --surface-2:  rgba(15,32,68,0.07);
  --surface-3:  rgba(15,32,68,0.12);
  --border-subtle: rgba(15,32,68,0.07);
  --border-mid:    rgba(15,32,68,0.13);
  --border-strong: rgba(15,32,68,0.22);
  --glass-bg:    rgba(255,255,255,0.88);
  --glass-border: rgba(15,32,68,0.10);
  --text-primary: rgba(10,22,50,0.95);
  --text-secondary: rgba(10,22,50,0.65);
}

/* ── Light Mode: Body & Global Text ── */
[data-theme="light"] body {
  color: rgba(10,22,50,0.92);
  background: #f0f5ff;
}
[data-theme="light"] .text-muted { color: rgba(10,22,50,0.52); }
[data-theme="light"] .text-dim   { color: rgba(10,22,50,0.38); }

/* ── Light Mode: Header ── */
[data-theme="light"] .mo-header {
  background: rgba(240,245,255,0.92);
  border-bottom-color: rgba(15,32,68,0.10);
}
[data-theme="light"] .mo-header__brand-name,
[data-theme="light"] .mo-header .mo-icon-btn {
  color: rgba(10,22,50,0.88);
}

/* ── Light Mode: Bottom Action Bar ── */
[data-theme="light"] .mo-bottom-bar {
  background: rgba(240,245,255,0.95);
  border-color: rgba(15,32,68,0.12);
  box-shadow: 0 8px 32px rgba(15,32,68,0.12), 0 2px 8px rgba(15,32,68,0.08);
}
[data-theme="light"] .mo-bottom-bar__item { color: rgba(10,22,50,0.55); }
[data-theme="light"] .mo-bottom-bar__item--active { color: rgba(10,22,50,0.92); }
[data-theme="light"] .mo-bottom-bar__item--active .mo-bottom-bar__label { color: var(--gold-500, #b47d0a); }
[data-theme="light"] .mo-bottom-bar::before { background: linear-gradient(90deg, transparent, rgba(15,32,68,0.08), transparent); }

/* ── Light Mode: Sidebar ── */
[data-theme="light"] .mo-sidebar {
  background: rgba(230,238,255,0.98);
  border-color: rgba(15,32,68,0.10);
}
[data-theme="light"] .mo-sidebar__item { color: rgba(10,22,50,0.75); }
[data-theme="light"] .mo-sidebar__item:hover { background: rgba(15,32,68,0.06); }
[data-theme="light"] .mo-sidebar__item.active { background: rgba(37,99,235,0.10); color: #1d4ed8; }

/* ── Light Mode: Cards & Posts ── */
[data-theme="light"] .mo-post-card,
[data-theme="light"] .mo-card {
  background: rgba(255,255,255,0.85);
  border-color: rgba(15,32,68,0.09);
  color: rgba(10,22,50,0.88);
}
[data-theme="light"] .mo-post-card__meta,
[data-theme="light"] .mo-post-card__time { color: rgba(10,22,50,0.45); }
[data-theme="light"] .mo-post-card__actions button { color: rgba(10,22,50,0.52); }
[data-theme="light"] .mo-post-card__actions button:hover { color: rgba(10,22,50,0.85); }

/* ── Light Mode: Feed empty state ── */
[data-theme="light"] .mo-empty-state__title,
[data-theme="light"] .mo-empty-state__desc { color: rgba(10,22,50,0.75); }

/* ── Light Mode: Theme toggle button ── */
[data-theme="light"] .mo-theme-toggle-icon--moon { display: block; }
[data-theme="light"] .mo-theme-toggle-icon--sun  { display: none; }
[data-theme="dark"]  .mo-theme-toggle-icon--moon { display: none; }
[data-theme="dark"]  .mo-theme-toggle-icon--sun  { display: block; }

/* ══════════════════════════════════════════════════════════════
   ۲. Reset & Base
   ══════════════════════════════════════════════════════════════ */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0; padding: 0;
  -webkit-tap-highlight-color: transparent;
}

html {
  direction: rtl;
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  font-family: var(--font-fa);
  background: var(--navy-950);
  color: #fff;
  min-height: 100dvh;
  overflow-x: hidden;
  line-height: 1.65;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img, video { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
input, textarea, select { font-family: inherit; }

[dir="ltr"], [lang="en"] { direction: ltr; font-family: var(--font-en); }

/* ── فونت فارسی برای همه عناصر داخل باکس‌ها ── */
.mo-card, .mo-post-card, .mo-modal, .mo-settings-page,
.mo-sidebar, .mo-bottom-bar, .mo-header,
.mo-form-field, .mo-input, .mo-auth-modal__sheet,
.mo-view, [class*="mo-"], button, input, textarea, select, label, span, p, h1, h2, h3, h4, h5 {
  font-family: var(--font-fa, 'Vazirmatn', system-ui, sans-serif) !important;
}

/* ── Light Theme: همه متن‌ها داخل اپ ── */
[data-theme="light"] {
  color: rgba(10,22,50,0.92);
}
[data-theme="light"] .mo-view,
[data-theme="light"] .mo-card,
[data-theme="light"] .mo-post-card,
[data-theme="light"] .mo-sidebar,
[data-theme="light"] .mo-settings-page,
[data-theme="light"] .mo-settings-row__label,
[data-theme="light"] .mo-auth-modal__sheet {
  color: rgba(10,22,50,0.92);
  background: var(--navy-950, #f0f5ff);
}
[data-theme="light"] .mo-input {
  background: rgba(15,32,68,0.05);
  color: rgba(10,22,50,0.92);
  border-color: rgba(15,32,68,0.16);
}
[data-theme="light"] .mo-input::placeholder { color: rgba(10,22,50,0.38); }

/* ── مهتابی/لایت مود برای shell عمومی ── */
[data-theme="light"] .mo-public-shell {
  background: #f0f5ff;
  color: rgba(10,22,50,0.92);
}
[data-theme="light"] .mo-pub-header {
  background: rgba(240,245,255,0.92);
}
[data-theme="light"] .mo-pub-post {
  background: rgba(15,32,68,0.04);
  border-color: rgba(15,32,68,0.1);
  color: rgba(10,22,50,0.92);
}

/* ══════════════════════════════════════════════════════════════
   ۳. Typography Scale
   ══════════════════════════════════════════════════════════════ */
.display-xl { font-size: clamp(2.4rem, 8vw, 4.5rem); font-weight: 900; line-height: 1.08; letter-spacing: -0.03em; }
.display-lg { font-size: clamp(1.9rem, 6vw, 3rem);   font-weight: 800; line-height: 1.13; letter-spacing: -0.02em; }
.display-md { font-size: clamp(1.4rem, 4vw, 2rem);   font-weight: 700; line-height: 1.2; }
.heading-lg { font-size: 1.375rem; font-weight: 700; line-height: 1.3; }
.heading-md { font-size: 1.125rem; font-weight: 600; line-height: 1.35; }
.heading-sm { font-size: 1rem;     font-weight: 600; line-height: 1.4; }
.body-lg    { font-size: 1rem;     line-height: 1.7; }
.body-md    { font-size: 0.9375rem;line-height: 1.65; }
.body-sm    { font-size: 0.875rem; line-height: 1.6; }
.caption    { font-size: 0.75rem;  opacity: 0.6; line-height: 1.5; }
.label      { font-size: 0.8125rem;font-weight: 600; letter-spacing: 0.01em; }
.overline   { font-size: 0.6875rem;font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; }

/* Color Utilities */
.text-gold      { color: var(--gold-400); }
.text-gold-300  { color: var(--gold-300); }
.text-blue      { color: var(--navy-400); }
.text-blue-300  { color: var(--navy-300); }
.text-success   { color: var(--success); }
.text-danger    { color: var(--danger); }
.text-warning   { color: var(--warning); }
.text-muted     { color: rgba(255,255,255,0.55); }
.text-dim       { color: rgba(255,255,255,0.38); }
.text-white     { color: #fff; }

/* ══════════════════════════════════════════════════════════════
   ۴. Glass & Card Surfaces
   ══════════════════════════════════════════════════════════════ */
.glass {
  background: var(--glass-bg);
  backdrop-filter: var(--glass-blur) var(--glass-sat);
  -webkit-backdrop-filter: var(--glass-blur) var(--glass-sat);
  border: 1px solid var(--glass-border);
}

.card {
  background: var(--surface-1);
  border: 1px solid var(--border-subtle);
  border-radius: var(--r-lg);
  overflow: hidden;
  transition:
    border-color var(--dur-mid) var(--ease-out),
    box-shadow   var(--dur-mid) var(--ease-out),
    transform    var(--dur-mid) var(--ease-out);
}

.card:hover {
  border-color: var(--border-mid);
  box-shadow: var(--shadow-md);
}

.card-interactive:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.card--elevated  { background: var(--surface-2); border-color: var(--border-mid); }
.card--pressed   { background: var(--surface-3); }

.card--gold {
  border-color: rgba(212,160,23,0.28);
  background: linear-gradient(135deg, rgba(212,160,23,0.07) 0%, var(--surface-1) 100%);
}

.card--blue {
  border-color: rgba(59,130,246,0.25);
  background: linear-gradient(135deg, rgba(59,130,246,0.07) 0%, var(--surface-1) 100%);
}

.card--success {
  border-color: rgba(16,185,129,0.28);
  background: linear-gradient(135deg, rgba(16,185,129,0.07) 0%, var(--surface-1) 100%);
}

/* ══════════════════════════════════════════════════════════════
   ۵. Buttons
   ══════════════════════════════════════════════════════════════ */
.mo-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--sp-2);
  padding: 0 var(--sp-6);
  height: 48px;
  border: none;
  border-radius: var(--r-full);
  font-family: var(--font-fa);
  font-size: 0.9375rem;
  font-weight: 700;
  cursor: pointer;
  transition: all var(--dur-fast) var(--ease-out);
  position: relative;
  overflow: hidden;
  white-space: nowrap;
  user-select: none;
  text-decoration: none;
  letter-spacing: 0.01em;
}

/* Ripple effect */
.mo-btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(255,255,255,0.1) 0%, transparent 100%);
  opacity: 1;
  pointer-events: none;
}

.mo-btn::after {
  content: '';
  position: absolute;
  inset: 0;
  background: white;
  opacity: 0;
  transition: opacity var(--dur-fast);
}

.mo-btn:active::after { opacity: 0.07; }

/* Primary */
.mo-btn--primary {
  background: linear-gradient(145deg, var(--navy-400) 0%, var(--navy-600) 100%);
  color: #fff;
  box-shadow: var(--shadow-blue), var(--shadow-inner);
}
.mo-btn--primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(59,130,246,0.48), var(--shadow-inner);
}
.mo-btn--primary:active { transform: translateY(0); }

/* Gold — CTA اصلی */
.mo-btn--gold {
  background: linear-gradient(145deg, var(--gold-300) 0%, var(--gold-500) 100%);
  color: var(--navy-900);
  font-weight: 800;
  box-shadow: var(--shadow-gold), var(--shadow-inner);
}
.mo-btn--gold:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(212,160,23,0.5), var(--shadow-inner);
}
.mo-btn--gold:active { transform: translateY(0); }

/* Ghost */
.mo-btn--ghost {
  background: var(--surface-1);
  border: 1px solid var(--border-mid);
  color: rgba(255,255,255,0.85);
}
.mo-btn--ghost:hover {
  background: var(--surface-2);
  border-color: var(--border-strong);
  color: #fff;
}

/* Success */
.mo-btn--success {
  background: linear-gradient(145deg, #34d399, var(--success));
  color: #fff;
  box-shadow: 0 4px 20px rgba(16,185,129,0.35);
}

/* Danger */
.mo-btn--danger {
  background: var(--danger-dim);
  border: 1px solid rgba(239,68,68,0.3);
  color: #fca5a5;
}
.mo-btn--danger:hover { background: rgba(239,68,68,0.22); }

/* Sizes */
.mo-btn--xs  { height: 30px; padding: 0 var(--sp-3); font-size: 0.75rem; }
.mo-btn--sm  { height: 36px; padding: 0 var(--sp-4); font-size: 0.8125rem; }
.mo-btn--lg  { height: 56px; padding: 0 var(--sp-8); font-size: 1rem; }
.mo-btn--xl  { height: 64px; padding: 0 var(--sp-10); font-size: 1.0625rem; letter-spacing: 0.02em; }
.mo-btn--full { width: 100%; }
.mo-btn-icon       { width: 44px; height: 44px; padding: 0; border-radius: var(--r-md); flex-shrink: 0; }
.mo-btn-icon-round { width: 44px; height: 44px; padding: 0; border-radius: var(--r-full); flex-shrink: 0; }
.mo-btn-icon-sm    { width: 36px; height: 36px; padding: 0; border-radius: var(--r-md); flex-shrink: 0; }

.mo-btn:disabled {
  opacity: 0.38;
  cursor: not-allowed;
  transform: none !important;
  box-shadow: none !important;
}

/* Loading spinner */
.mo-btn.loading { pointer-events: none; }
.mo-btn.loading .mo-btn-text { opacity: 0; }
.mo-btn.loading::after  { content: none; }
.mo-btn.loading::before {
  content: '';
  position: absolute;
  width: 20px; height: 20px;
  border: 2.5px solid rgba(255,255,255,0.25);
  border-top-color: currentColor;
  border-radius: 50%;
  animation: spin 0.65s linear infinite;
  background: none;
  inset: unset;
  opacity: 1;
}

/* ══════════════════════════════════════════════════════════════
   ۶. Form Elements
   ══════════════════════════════════════════════════════════════ */
.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-label {
  font-size: 0.875rem;
  font-weight: 600;
  color: rgba(255,255,255,0.75);
  display: flex;
  align-items: center;
  gap: var(--sp-2);
}

.form-required { color: var(--danger); font-size: 0.8125rem; }

.input-wrap {
  position: relative;
  display: flex;
  align-items: center;
}

.input-wrap .input-icon {
  position: absolute;
  right: var(--sp-4);
  color: rgba(255,255,255,0.35);
  width: 20px; height: 20px;
  pointer-events: none;
  transition: color var(--dur-fast) var(--ease-out);
  flex-shrink: 0;
}

.input-wrap:has(.form-input:focus) .input-icon {
  color: var(--navy-400);
}

.form-input {
  width: 100%;
  height: 52px;
  padding: 0 var(--sp-5);
  padding-right: 48px;
  background: var(--surface-1);
  border: 1.5px solid var(--border-subtle);
  border-radius: var(--r-md);
  color: #fff;
  font-family: var(--font-fa);
  font-size: 0.9375rem;
  outline: none;
  transition: all var(--dur-fast) var(--ease-out);
  text-align: right;
  direction: rtl;
  -webkit-appearance: none;
}

.form-input::placeholder { color: rgba(255,255,255,0.28); }

.form-input:focus {
  background: var(--surface-2);
  border-color: var(--navy-400);
  box-shadow: 0 0 0 3px rgba(59,130,246,0.16);
}

.form-input.error {
  border-color: var(--danger);
  box-shadow: 0 0 0 3px rgba(239,68,68,0.13);
}

.form-input.success {
  border-color: var(--success);
  box-shadow: 0 0 0 3px rgba(16,185,129,0.13);
}

.form-hint {
  font-size: 0.8125rem;
  color: rgba(255,255,255,0.42);
  line-height: 1.5;
}

.form-error {
  font-size: 0.8125rem;
  color: #fca5a5;
  display: flex;
  align-items: center;
  gap: var(--sp-1);
}

/* Textarea */
.form-textarea {
  resize: vertical;
  min-height: 100px;
  height: auto;
  padding: var(--sp-3) var(--sp-5);
  padding-right: 48px;
  line-height: 1.6;
}

/* Select */
select.form-input {
  cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 20 20' fill='rgba(255,255,255,0.4)' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath fill-rule='evenodd' d='M5.293 7.293a1 1 0 011.414 0L10 10.586l3.293-3.293a1 1 0 111.414 1.414l-4 4a1 1 0 01-1.414 0l-4-4a1 1 0 010-1.414z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: left 12px center;
  background-size: 20px;
  padding-left: 40px;
}

/* OTP Grid */
.otp-grid {
  display: flex;
  flex-direction: row-reverse;
  gap: var(--sp-3);
  justify-content: center;
}

.otp-cell {
  width: 54px; height: 62px;
  background: var(--surface-1);
  border: 1.5px solid var(--border-subtle);
  border-radius: var(--r-md);
  color: #fff;
  font-size: 1.5rem;
  font-weight: 800;
  text-align: center;
  outline: none;
  transition: all var(--dur-fast) var(--ease-out);
  caret-color: var(--gold-400);
  font-family: var(--font-fa);
  -webkit-appearance: none;
  letter-spacing: 0;
}

.otp-cell:focus {
  border-color: var(--gold-400);
  box-shadow: 0 0 0 3px var(--gold-glow);
  background: var(--surface-2);
}

.otp-cell.filled {
  border-color: var(--success);
  background: rgba(16,185,129,0.07);
  color: #6ee7b7;
}

/* ══════════════════════════════════════════════════════════════
   ۷. Avatar
   ══════════════════════════════════════════════════════════════ */
.avatar {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--r-full);
  overflow: hidden;
  flex-shrink: 0;
  background: linear-gradient(135deg, var(--navy-700), var(--navy-600));
  font-weight: 800;
  text-transform: uppercase;
  color: rgba(255,255,255,0.9);
  font-family: var(--font-fa);
  letter-spacing: 0;
}

.avatar img { width: 100%; height: 100%; object-fit: cover; }

.avatar--2xs { width: 22px; height: 22px; font-size: 0.5rem; }
.avatar--xs  { width: 28px; height: 28px; font-size: 0.625rem; }
.avatar--sm  { width: 36px; height: 36px; font-size: 0.75rem; }
.avatar--md  { width: 44px; height: 44px; font-size: 0.875rem; }
.avatar--lg  { width: 56px; height: 56px; font-size: 1rem; }
.avatar--xl  { width: 80px; height: 80px; font-size: 1.375rem; }
.avatar--2xl { width: 108px;height: 108px;font-size: 1.875rem; }

.avatar-dot {
  position: absolute;
  bottom: 1px; left: 1px;
  width: 11px; height: 11px;
  background: var(--success);
  border: 2px solid var(--navy-900);
  border-radius: var(--r-full);
  box-shadow: 0 0 0 2px rgba(16,185,129,0.3);
}

.avatar-story-ring {
  padding: 2.5px;
  background: linear-gradient(135deg, var(--gold-400), var(--navy-500), var(--gold-400));
  background-size: 200% 200%;
  animation: gradient-shift 3s ease infinite;
  border-radius: var(--r-full);
  display: inline-block;
}

.avatar-story-ring .avatar {
  border: 2.5px solid var(--navy-900);
}

/* ══════════════════════════════════════════════════════════════
   ۸. Badges & Chips
   ══════════════════════════════════════════════════════════════ */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 10px;
  border-radius: var(--r-full);
  font-size: 0.75rem;
  font-weight: 700;
  white-space: nowrap;
  letter-spacing: 0.01em;
}

.badge-blue    { background: rgba(59,130,246,0.14);  color: var(--navy-300);  border: 1px solid rgba(59,130,246,0.22); }
.badge-gold    { background: rgba(212,160,23,0.14);  color: var(--gold-300);  border: 1px solid rgba(212,160,23,0.25); }
.badge-green   { background: rgba(16,185,129,0.14);  color: #6ee7b7;          border: 1px solid rgba(16,185,129,0.22); }
.badge-red     { background: rgba(239,68,68,0.14);   color: #fca5a5;          border: 1px solid rgba(239,68,68,0.20); }
.badge-purple  { background: rgba(139,92,246,0.14);  color: #c4b5fd;          border: 1px solid rgba(139,92,246,0.22); }
.badge-ghost   { background: var(--surface-1);       color: rgba(255,255,255,0.65); border: 1px solid var(--border-subtle); }
.badge-outline { background: transparent;            color: rgba(255,255,255,0.7);  border: 1px solid var(--border-mid); }

/* Verified Tick */
.tick-verified {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px; height: 18px;
  background: var(--navy-500);
  border-radius: var(--r-full);
  flex-shrink: 0;
}
.tick-verified svg {
  width: 10px; height: 10px;
  stroke: white;
  stroke-width: 2.5;
  fill: none;
}
.tick-gold   { background: linear-gradient(135deg, var(--gold-400), var(--gold-500)); }
.tick-green  { background: linear-gradient(135deg, var(--success), #059669); }

/* ══════════════════════════════════════════════════════════════
   ۹. Skeleton Loader
   ══════════════════════════════════════════════════════════════ */
.skeleton {
  background: linear-gradient(
    100deg,
    var(--surface-1) 25%,
    var(--surface-3) 50%,
    var(--surface-1) 75%
  );
  background-size: 200% 100%;
  animation: shimmer 1.6s ease-in-out infinite;
  border-radius: var(--r-sm);
}

/* ══════════════════════════════════════════════════════════════
   ۱۰. Tab Bar
   ══════════════════════════════════════════════════════════════ */
.tab-bar {
  display: flex;
  background: var(--surface-0);
  border-bottom: 1px solid var(--border-subtle);
  position: sticky;
  top: var(--nav-h);
  z-index: 50;
  overflow-x: auto;
  scrollbar-width: none;
}

.tab-bar::-webkit-scrollbar { display: none; }

.tab-item {
  flex: 1;
  padding: var(--sp-3) var(--sp-4);
  text-align: center;
  font-size: 0.875rem;
  font-weight: 500;
  color: rgba(255,255,255,0.45);
  cursor: pointer;
  border-bottom: 2px solid transparent;
  transition: all var(--dur-fast) var(--ease-out);
  user-select: none;
  white-space: nowrap;
  position: relative;
}

.tab-item.active {
  color: white;
  border-bottom-color: var(--gold-400);
  font-weight: 700;
}

.tab-item-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 18px; height: 18px;
  background: var(--danger);
  border-radius: var(--r-full);
  font-size: 0.625rem;
  font-weight: 800;
  color: white;
  padding: 0 4px;
  margin-right: 4px;
  vertical-align: middle;
}

/* ══════════════════════════════════════════════════════════════
   ۱۱. Divider
   ══════════════════════════════════════════════════════════════ */
.divider {
  height: 1px;
  background: var(--border-subtle);
  margin: var(--sp-4) 0;
}

.divider-text {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  font-size: 0.8125rem;
  color: rgba(255,255,255,0.38);
}
.divider-text::before, .divider-text::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border-subtle);
}

/* ══════════════════════════════════════════════════════════════
   ۱۲. Toast / Snackbar
   ══════════════════════════════════════════════════════════════ */
.toast-container {
  position: fixed;
  top: var(--sp-5);
  left: 50%;
  transform: translateX(-50%);
  z-index: var(--z-toast);
  display: flex;
  flex-direction: column;
  gap: var(--sp-2);
  pointer-events: none;
  width: min(calc(100vw - 32px), 380px);
}

.toast {
  padding: var(--sp-3) var(--sp-4);
  border-radius: var(--r-md);
  font-size: 0.875rem;
  font-weight: 600;
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid var(--border-mid);
  box-shadow: var(--shadow-xl);
  pointer-events: all;
  animation:
    toast-in  var(--dur-mid) var(--ease-spring),
    toast-out var(--dur-mid) var(--ease-in) 3.2s forwards;
  display: flex;
  align-items: center;
  gap: var(--sp-3);
}

.toast-success { background: rgba(16,185,129,0.92);  border-color: rgba(16,185,129,0.4); }
.toast-error   { background: rgba(239,68,68,0.92);   border-color: rgba(239,68,68,0.4); }
.toast-info    { background: rgba(37,99,235,0.92);   border-color: rgba(59,130,246,0.4); }
.toast-warning { background: rgba(245,158,11,0.92);  border-color: rgba(245,158,11,0.4); }

/* ══════════════════════════════════════════════════════════════
   ۱۳. Switch / Toggle
   ══════════════════════════════════════════════════════════════ */
.switch {
  position: relative;
  display: inline-block;
  width: 48px;
  height: 26px;
  flex-shrink: 0;
}
.switch input { opacity: 0; width: 0; height: 0; position: absolute; }
.switch-track {
  position: absolute;
  inset: 0;
  border-radius: var(--r-full);
  background: var(--surface-3);
  border: 1px solid var(--border-mid);
  transition: background var(--dur-fast) var(--ease-out);
  cursor: pointer;
}
.switch-track::after {
  content: '';
  position: absolute;
  left: 3px; top: 50%;
  transform: translateY(-50%);
  width: 20px; height: 20px;
  border-radius: var(--r-full);
  background: rgba(255,255,255,0.6);
  transition: all var(--dur-fast) var(--ease-spring);
  box-shadow: 0 1px 4px rgba(0,0,0,0.3);
}
.switch input:checked ~ .switch-track {
  background: var(--navy-500);
  border-color: var(--navy-500);
}
.switch input:checked ~ .switch-track::after {
  left: calc(100% - 23px);
  background: white;
}

/* ══════════════════════════════════════════════════════════════
   ۱۴. Progress / Meter
   ══════════════════════════════════════════════════════════════ */
.progress-bar {
  height: 6px;
  background: var(--surface-2);
  border-radius: var(--r-full);
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  border-radius: var(--r-full);
  transition: width 0.7s var(--ease-out);
}

.progress-fill-blue  { background: linear-gradient(90deg, var(--navy-400), var(--navy-500)); }
.progress-fill-gold  { background: linear-gradient(90deg, var(--gold-300), var(--gold-500)); }
.progress-fill-green { background: linear-gradient(90deg, #34d399, var(--success)); }
.progress-fill-multi { background: linear-gradient(90deg, var(--danger), var(--warning), var(--success)); }

/* ══════════════════════════════════════════════════════════════
   ۱۵. Animations & Keyframes
   ══════════════════════════════════════════════════════════════ */
@keyframes spin          { to { transform: rotate(360deg); } }
@keyframes spin-ccw      { to { transform: rotate(-360deg); } }

@keyframes shimmer {
  0%   { background-position: -200% 0; }
  100% { background-position:  200% 0; }
}

@keyframes gradient-shift {
  0%, 100% { background-position: 0%   50%; }
  50%       { background-position: 100% 50%; }
}

@keyframes toast-in {
  from { opacity: 0; transform: translateY(-14px) scale(0.94); }
  to   { opacity: 1; transform: translateY(0)    scale(1); }
}

@keyframes toast-out {
  from { opacity: 1; transform: translateY(0); }
  to   { opacity: 0; transform: translateY(-10px); }
}

@keyframes fade-up {
  from { opacity: 0; transform: translateY(22px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes fade-in   { from { opacity: 0; } to { opacity: 1; } }

@keyframes scale-in {
  from { opacity: 0; transform: scale(0.90); }
  to   { opacity: 1; transform: scale(1); }
}

@keyframes slide-up  { from { transform: translateY(100%); } to { transform: translateY(0); } }

@keyframes pulse-ring {
  0%   { box-shadow: 0 0 0 0   rgba(212,160,23,0.45); }
  70%  { box-shadow: 0 0 0 14px rgba(212,160,23,0); }
  100% { box-shadow: 0 0 0 0   rgba(212,160,23,0); }
}

@keyframes pulse-blue {
  0%   { box-shadow: 0 0 0 0   rgba(59,130,246,0.45); }
  70%  { box-shadow: 0 0 0 12px rgba(59,130,246,0); }
  100% { box-shadow: 0 0 0 0   rgba(59,130,246,0); }
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50%       { transform: translateY(-10px); }
}

@keyframes waveform {
  from { height: 4px; }
  to   { height: 20px; }
}

/* Animation Classes */
.anim-fade-up    { animation: fade-up   var(--dur-slow) var(--ease-out)    both; }
.anim-fade-in    { animation: fade-in   var(--dur-mid)  var(--ease-out)    both; }
.anim-scale-in   { animation: scale-in  var(--dur-mid)  var(--ease-spring) both; }
.anim-float      { animation: float     4s ease-in-out infinite; }

/* Staggered reveals */
.stagger > * { animation: fade-up var(--dur-slow) var(--ease-out) both; }
.stagger > *:nth-child(1) { animation-delay:   0ms; }
.stagger > *:nth-child(2) { animation-delay:  70ms; }
.stagger > *:nth-child(3) { animation-delay: 140ms; }
.stagger > *:nth-child(4) { animation-delay: 210ms; }
.stagger > *:nth-child(5) { animation-delay: 280ms; }
.stagger > *:nth-child(6) { animation-delay: 350ms; }
.stagger > *:nth-child(7) { animation-delay: 420ms; }

/* ══════════════════════════════════════════════════════════════
   ۱۶. Scrollbar
   ══════════════════════════════════════════════════════════════ */
::-webkit-scrollbar          { width: 4px; height: 4px; }
::-webkit-scrollbar-track    { background: transparent; }
::-webkit-scrollbar-thumb    { background: var(--border-mid); border-radius: var(--r-full); }
::-webkit-scrollbar-thumb:hover { background: var(--border-strong); }

/* ══════════════════════════════════════════════════════════════
   ۱۷. Focus
   ══════════════════════════════════════════════════════════════ */
:focus-visible {
  outline: 2px solid var(--navy-400);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ══════════════════════════════════════════════════════════════
   ۱۸. Utilities
   ══════════════════════════════════════════════════════════════ */
/* Display */
.flex       { display: flex; }
.grid       { display: grid; }
.block      { display: block; }
.inline     { display: inline; }
.hidden     { display: none !important; }
.invisible  { visibility: hidden; }

/* Flex helpers */
.flex-col      { flex-direction: column; }
.flex-wrap     { flex-wrap: wrap; }
.flex-1        { flex: 1; }
.flex-none     { flex: none; }
.items-center  { align-items: center; }
.items-start   { align-items: flex-start; }
.items-end     { align-items: flex-end; }
.items-stretch { align-items: stretch; }
.justify-between { justify-content: space-between; }
.justify-center  { justify-content: center; }
.justify-end     { justify-content: flex-end; }
.justify-start   { justify-content: flex-start; }

/* Gap */
.gap-1 { gap: 4px; } .gap-2 { gap: 8px; }  .gap-3 { gap: 12px; }
.gap-4 { gap: 16px;} .gap-5 { gap: 20px; } .gap-6 { gap: 24px; }

/* Sizing */
.w-full { width: 100%; } .h-full { height: 100%; }
.min-w-0 { min-width: 0; }

/* Padding */
.p-3  { padding: 12px; } .p-4  { padding: 16px; }
.p-5  { padding: 20px; } .p-6  { padding: 24px; }
.px-4 { padding-left: 16px; padding-right: 16px; }
.px-5 { padding-left: 20px; padding-right: 20px; }
.py-3 { padding-top: 12px;  padding-bottom: 12px; }
.py-4 { padding-top: 16px;  padding-bottom: 16px; }

/* Margin */
.mt-1 { margin-top: 4px; }  .mt-2 { margin-top: 8px; }
.mt-3 { margin-top: 12px; } .mt-4 { margin-top: 16px; }
.mt-5 { margin-top: 20px; } .mt-6 { margin-top: 24px; }
.mt-8 { margin-top: 32px; }
.mb-2 { margin-bottom: 8px; }  .mb-4 { margin-bottom: 16px; }
.mb-6 { margin-bottom: 24px; }
.mx-auto { margin-left: auto; margin-right: auto; }

/* Text */
.text-center { text-align: center; }
.text-right  { text-align: right; }
.text-left   { text-align: left; }
.font-bold   { font-weight: 700; }
.font-medium { font-weight: 500; }
.truncate    { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.line-clamp-2 { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.line-clamp-3 { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }

/* Position */
.relative { position: relative; }
.absolute { position: absolute; }
.sticky   { position: sticky; }
.fixed    { position: fixed; }

/* Misc */
.overflow-hidden  { overflow: hidden; }
.overflow-x-auto  { overflow-x: auto; }
.cursor-pointer   { cursor: pointer; }
.select-none      { user-select: none; }
.pointer-events-none { pointer-events: none; }
.opacity-0        { opacity: 0; }
.opacity-50       { opacity: 0.5; }

.rounded-full { border-radius: var(--r-full); }
.rounded-xl   { border-radius: var(--r-xl); }
.rounded-lg   { border-radius: var(--r-lg); }
.rounded-md   { border-radius: var(--r-md); }

.no-scrollbar            { scrollbar-width: none; }
.no-scrollbar::-webkit-scrollbar { display: none; }

/* ═══════════════════════════════════════════════════════════════
   🎨 THEME COLOR PALETTE — سیستم رنگ هارمونیک
   تم پایه: آبی آموزشی + طلایی (gold)
   رنگ‌های ثانوی: بک‌گراند و accent تغییر می‌کنند
   هر دو حالت دارک (آفتابی) و لایت (مهتابی) پوشش کامل دارند
   ═══════════════════════════════════════════════════════════════ */

/* ── Base defaults (blue + gold — تم پایه) ── */
:root {
  --primary:       #2563eb;
  --primary-light: #3b82f6;
  --primary-deep:  #1d4ed8;
  --primary-alpha: rgba(37,99,235,0.12);
  --primary-glow:  rgba(37,99,235,0.28);
  /* gold همیشه accent اصلیه */
  --accent:        #d4a017;
  --accent-light:  #e8b84b;
  --accent-glow:   rgba(212,160,23,0.28);
  /* بک‌گراند: از navy-950 ارث می‌برد */
  --bg-tint:       rgba(37,99,235,0.04);
  --bg-sidebar:    rgba(10,22,40,0.98);
}

/* ══════════════════════════════════════════════
   ۸ رنگ تم — با هارمونی کامل
   هر تم: primary + background tint + glow
   ══════════════════════════════════════════════ */

/* 1. Blue — آبی آموزشی (پیش‌فرض) */
[data-color="blue"] {
  --primary:       #2563eb;
  --primary-light: #3b82f6;
  --primary-deep:  #1d4ed8;
  --primary-alpha: rgba(37,99,235,0.12);
  --primary-glow:  rgba(37,99,235,0.30);
  --bg-tint:       rgba(37,99,235,0.04);
  --bg-sidebar:    rgba(8,18,42,0.98);
  --navy-500: #2563eb; --navy-400: #3b82f6; --navy-600: #1d4ed8;
}

/* 2. Indigo — نیلی */
[data-color="indigo"] {
  --primary:       #4f46e5;
  --primary-light: #6366f1;
  --primary-deep:  #4338ca;
  --primary-alpha: rgba(79,70,229,0.12);
  --primary-glow:  rgba(79,70,229,0.28);
  --bg-tint:       rgba(79,70,229,0.04);
  --bg-sidebar:    rgba(12,10,42,0.98);
  --navy-500: #4f46e5; --navy-400: #6366f1; --navy-600: #4338ca;
}

/* 3. Purple — بنفش */
[data-color="purple"] {
  --primary:       #7c3aed;
  --primary-light: #8b5cf6;
  --primary-deep:  #6d28d9;
  --primary-alpha: rgba(124,58,237,0.12);
  --primary-glow:  rgba(124,58,237,0.28);
  --bg-tint:       rgba(124,58,237,0.04);
  --bg-sidebar:    rgba(18,8,36,0.98);
  --navy-500: #7c3aed; --navy-400: #8b5cf6; --navy-600: #6d28d9;
}

/* 4. Rose — گلبهی */
[data-color="rose"] {
  --primary:       #e11d48;
  --primary-light: #f43f5e;
  --primary-deep:  #be123c;
  --primary-alpha: rgba(225,29,72,0.12);
  --primary-glow:  rgba(225,29,72,0.25);
  --bg-tint:       rgba(225,29,72,0.04);
  --bg-sidebar:    rgba(28,6,14,0.98);
  --navy-500: #e11d48; --navy-400: #f43f5e; --navy-600: #be123c;
}

/* 5. Teal — فیروزه‌ای */
[data-color="teal"] {
  --primary:       #0d9488;
  --primary-light: #14b8a6;
  --primary-deep:  #0f766e;
  --primary-alpha: rgba(13,148,136,0.12);
  --primary-glow:  rgba(13,148,136,0.28);
  --bg-tint:       rgba(13,148,136,0.04);
  --bg-sidebar:    rgba(4,22,20,0.98);
  --navy-500: #0d9488; --navy-400: #14b8a6; --navy-600: #0f766e;
}

/* 6. Green — سبز */
[data-color="green"] {
  --primary:       #16a34a;
  --primary-light: #22c55e;
  --primary-deep:  #15803d;
  --primary-alpha: rgba(22,163,74,0.12);
  --primary-glow:  rgba(22,163,74,0.28);
  --bg-tint:       rgba(22,163,74,0.04);
  --bg-sidebar:    rgba(4,20,10,0.98);
  --navy-500: #16a34a; --navy-400: #22c55e; --navy-600: #15803d;
}

/* 7. Amber — کهربایی (جایگزین بهتر برای pink) */
[data-color="pink"] {
  --primary:       #d97706;
  --primary-light: #f59e0b;
  --primary-deep:  #b45309;
  --primary-alpha: rgba(217,119,6,0.12);
  --primary-glow:  rgba(217,119,6,0.28);
  --bg-tint:       rgba(217,119,6,0.04);
  --bg-sidebar:    rgba(24,16,4,0.98);
  --navy-500: #d97706; --navy-400: #f59e0b; --navy-600: #b45309;
}

/* 8. Crimson — قرمز کلاسیک */
[data-color="orange"] {
  --primary:       #dc2626;
  --primary-light: #ef4444;
  --primary-deep:  #b91c1c;
  --primary-alpha: rgba(220,38,38,0.12);
  --primary-glow:  rgba(220,38,38,0.25);
  --bg-tint:       rgba(220,38,38,0.04);
  --bg-sidebar:    rgba(24,6,6,0.98);
  --navy-500: #dc2626; --navy-400: #ef4444; --navy-600: #b91c1c;
}

/* ══════════════════════════════════════════════
   پنل انتخاب رنگ — Color Picker
   ══════════════════════════════════════════════ */
.mo-color-picker {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  padding: 4px 0;
}
.mo-color-swatch {
  width: 34px; height: 34px;
  border-radius: 50%;
  cursor: pointer;
  border: 2.5px solid transparent;
  outline: none;
  box-shadow: 0 2px 6px rgba(0,0,0,0.25);
  transition: transform 0.18s var(--ease-spring, cubic-bezier(0.34,1.56,0.64,1)), border-color 0.15s;
  position: relative;
  flex-shrink: 0;
}
.mo-color-swatch:hover { transform: scale(1.16); box-shadow: 0 4px 14px rgba(0,0,0,0.35); }
.mo-color-swatch.is-active {
  border-color: white;
  box-shadow: 0 0 0 2px rgba(255,255,255,0.45), 0 4px 14px rgba(0,0,0,0.35);
  transform: scale(1.18);
}
[data-theme="light"] .mo-color-swatch.is-active {
  border-color: rgba(10,22,50,0.75);
  box-shadow: 0 0 0 2px rgba(10,22,50,0.22), 0 4px 14px rgba(0,0,0,0.18);
}
.mo-color-swatch::after {
  content: '✓';
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 900;
  color: white;
  opacity: 0; transition: opacity 0.18s;
}
.mo-color-swatch.is-active::after { opacity: 1; }

/* ══════════════════════════════════════════════
   [THEME COLOR] — پوشش کامل همه المان‌ها
   ══════════════════════════════════════════════ */

/* ── دکمه‌های primary: از رنگ تم + طلا در حالت پیش‌فرض ── */
.mo-btn--primary,
#mo-editor-submit,
#mo-story-submit,
#mo-cc-submit,
#mo-cp-send {
  background: linear-gradient(135deg, var(--primary, #2563eb), var(--primary-deep, #1d4ed8));
  color: white;
  box-shadow: 0 4px 16px var(--primary-glow, rgba(37,99,235,0.28));
}

/* ── دکمه gold (طلایی اصلی همیشه طلاست) ── */
.mo-btn--gold {
  background: linear-gradient(135deg, var(--gold-300, #f5cc6a), var(--gold-500, #d4a017)) !important;
  color: var(--navy-950, #050c1a) !important;
  box-shadow: 0 4px 16px rgba(212,160,23,0.35) !important;
}

/* ── FAB center post button — طلایی همیشه ── */
.mo-bottom-bar__post-btn {
  background: linear-gradient(145deg, var(--gold-300, #f5cc6a), var(--gold-500, #d4a017)) !important;
  box-shadow: 0 6px 20px rgba(212,160,23,0.45), 0 0 0 4px rgba(212,160,23,0.12) !important;
}
.mo-bottom-bar__post-btn:hover {
  box-shadow: 0 10px 30px rgba(212,160,23,0.55), 0 0 0 6px rgba(212,160,23,0.16) !important;
}

/* ── bottom bar active indicator: از رنگ تم ── */
.mo-bottom-bar__item--active .mo-bottom-bar__icon::after {
  background: var(--primary-light, #3b82f6) !important;
  box-shadow: 0 0 10px var(--primary-glow, rgba(59,130,246,0.5)) !important;
}
.mo-bottom-bar__item--active .mo-bottom-bar__label {
  color: var(--primary-light, #3b82f6) !important;
}
.mo-bottom-bar__item--active .mo-bottom-bar__icon { color: var(--primary-light, #3b82f6) !important; }

/* ── active states: از رنگ تم ── */
.mo-reaction-btn.is-active { color: var(--primary-light, #3b82f6) !important; }
.mo-bookmark-btn.is-active { color: var(--gold-400, #e8b84b) !important; }

/* ── tabs active ── */
.mo-tab.active {
  border-bottom-color: var(--primary, #2563eb) !important;
  color: var(--primary-light, #3b82f6) !important;
}

/* ── بک‌گراند sidebar با tint رنگ تم ── */
.mo-sidebar__panel {
  background: linear-gradient(180deg, var(--bg-sidebar, rgba(10,22,40,0.98)) 0%, var(--navy-950, #050c1a) 100%) !important;
}

/* ── orb پس‌زمینه با رنگ تم ── */
.mo-sidebar__overlay {
  background-image: radial-gradient(ellipse at 20% 30%, var(--primary-glow, rgba(37,99,235,0.08)) 0%, transparent 60%),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.75' numOctaves='4' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='300' height='300' filter='url(%23n)' opacity='0.04'/%3E%3C/svg%3E") !important;
}

/* ── verified badge و active items: از رنگ تم ── */
.mo-verified-badge { background: var(--primary, #2563eb) !important; }
.mo-sidebar__item.active { background: rgba(var(--primary, 37,99,235), 0.10) !important; color: white !important; }
.mo-sidebar__item.active::before {
  background: linear-gradient(to bottom, var(--accent-light, #e8b84b), var(--primary-light, #3b82f6)) !important;
}

/* ── links ── */
a[data-color], .mo-settings-row--link:hover { color: var(--primary-light, #3b82f6); }

/* ── story add button locked state ── */
.mo-story-add__circle--locked {
  border-style: dotted !important;
  border-color: var(--gold-400, #e8b84b) !important;
  color: var(--gold-400, #e8b84b) !important;
  opacity: 0.8;
}

/* ══════════════════════════════════════════════
   Light Mode (مهتابی) — بک‌گراند با tint رنگ تم
   ══════════════════════════════════════════════ */
[data-theme="light"] .mo-bottom-bar__item--active .mo-bottom-bar__label {
  color: var(--primary, #2563eb) !important;
}
[data-theme="light"] .mo-bottom-bar__item--active .mo-bottom-bar__icon { color: var(--primary, #2563eb) !important; }
[data-theme="light"] .mo-tab.active { border-bottom-color: var(--primary, #2563eb) !important; color: var(--primary, #2563eb) !important; }
[data-theme="light"] .mo-reaction-btn.is-active { color: var(--primary, #2563eb) !important; }
[data-theme="light"] .mo-verified-badge { background: var(--primary, #2563eb) !important; }
