/* ثيم لوحة التحكم — نفس ألوان الموقع (Apple: أبيض/رمادي فاتح + أزرق واحد، وليلي حقيقي).
   يُحمَّل آخِرًا في كل صفحات اللوحة فيعيد تعريف متغيّرات كل صفحة دون تكرار الأنماط. */
@import url('https://fonts.googleapis.com/css2?family=IBM+Plex+Sans+Arabic:wght@300;400;600;700&family=Inter:wght@400;600;700&display=swap');

:root {
  --acc: #0066cc; --acc-rgb: 0, 102, 204; --on-acc: #ffffff; --ov: 0, 0, 0;
  --t-bg: #f5f5f7; --t-card: #ffffff; --t-raise: #ffffff; --t-field: #ececf0; --t-field2: #d9d9de;
  --t-text: #1d1d1f; --t-mut: #6e6e73; --t-line: rgba(0, 0, 0, .1);
  color-scheme: light;
}
:root[data-theme="dark"] {
  --acc: #0a84ff; --acc-rgb: 10, 132, 255; --on-acc: #ffffff; --ov: 255, 255, 255;
  --t-bg: #000000; --t-card: #1d1d1f; --t-raise: #1d1d1f; --t-field: #2a2a2c; --t-field2: #3a3a3c;
  --t-text: #f5f5f7; --t-mut: #a1a1a6; --t-line: rgba(255, 255, 255, .12);
  color-scheme: dark;
}
:root, :root[data-theme="dark"] {
  /* admin.css (اللوحة الرئيسية) */
  --gold: var(--acc); --gold-light: color-mix(in srgb, var(--acc) 70%, white); --gold-dark: color-mix(in srgb, var(--acc) 78%, black);
  --dark: var(--t-bg); --dark2: var(--t-card); --dark3: var(--t-raise); --dark4: var(--t-field); --dark5: var(--t-field2);
  --text: var(--t-text); --text-muted: var(--t-mut);
  /* الخدمات والعملاء */
  --bg: var(--t-bg); --c1: var(--t-card); --c2: var(--t-field); --c3: var(--t-field2); --mut: var(--t-mut); --line: var(--t-line);
  /* المقالات */
  --bg2: var(--t-card); --bg3: var(--t-field); --muted: var(--t-mut);
  --blue: var(--acc);
  --green: #1f9d55; --red: #d92d20; --amber: #c77700;
  --radius: 14px;
}
:root[data-theme="dark"] { --green: #30d158; --red: #ff453a; --amber: #ff9f0a; }

html, body { background: var(--t-bg); color: var(--t-text); }
body { font-family: 'Inter', 'IBM Plex Sans Arabic', 'Tajawal', system-ui, -apple-system, sans-serif !important; }
button, input, select, textarea { font-family: inherit; }
input, textarea, select { color: var(--t-text); }
::placeholder { color: var(--t-mut); opacity: .8; }

/* بطاقات وأسطح: حدّ خفيف بدل الظلال الثقيلة */
.card, .modal-box, .modal > div, .stat-card, .kpi, .item { box-shadow: none; }
/* الأزرار الأساسية: أزرق واحد بلا تدرّج ذهبي */
.add-btn, .save-btn, .btn-gold, .btn-primary { background: var(--acc) !important; color: var(--on-acc) !important; }
.btn-blue { background: var(--acc); color: var(--on-acc); }
/* الشريط الجانبي والسفلي */
.sidebar { background: var(--t-card); border-color: var(--t-line); }
.mnav, .pg-mnav { background: color-mix(in srgb, var(--t-card) 88%, transparent) !important; border-top-color: var(--t-line) !important; }
.mtab.active, .pg-mnav a.on { color: var(--acc) !important; background: rgba(var(--acc-rgb), .12) !important; }
.mtab, .pg-mnav a { color: var(--t-mut) !important; }
.nav-item.active { color: var(--acc); background: rgba(var(--acc-rgb), .12); }
