/* ============================================================
   Design Tokens — overrides common-theme.css :root defaults
   RULE: :root block + body + :lang(ar) ONLY.
         No element selectors, no transitions, no !important.
         Radius/shadow flow into common-theme automatically.
   Load AFTER common-theme.css
   ============================================================ */

:root {
  /* ── Typography ──────────────────────────────────────────── */
  --bs-body-font-family:
    "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI",
    "Helvetica Neue", "Be Vietnam Pro", Roboto,
    Helvetica, Arial, sans-serif;
  --header-font: var(--bs-body-font-family);
  --s-tabular-font: var(--bs-body-font-family);
  --bs-body-font-size: 15px;
  --bs-body-font-weight: 400;
  --bs-body-line-height: 1.6;
  --s-letter-tight: -0.014em;

  /* ── Icons — FA7 Pro Light (outline appearance) ──────────── */
  --s-icon-font: "Font Awesome 7 Pro";
  --s-icon-solid: 300;
  --s-tool-icon-size: 1.2rem;

  /* ── Shape — Apple-style generous radius ─────────────────── */
  --bs-border-radius:      10px;
  --bs-border-radius-sm:    7px;
  --bs-border-radius-lg:   14px;
  --bs-border-radius-xl:   18px;
  --bs-border-radius-2xl:  24px;
  --bs-border-radius-pill: 999px;
  --bs-card-border-radius: 16px;

  /* ── Spacing ─────────────────────────────────────────────── */
  --s-col-gap:  0.85rem;
  --s-row-gap:  1.25rem;
  --bs-gutter-x: 1.5rem;

  /* ── Input sizing ────────────────────────────────────────── */
  --s-input-padding-v:    0.45rem;
  --s-input-line-height:  1.5rem;
  --s-input-inner-height: 2.35rem;

  /* ── Sidebar dimensions ──────────────────────────────────── */
  --s-sidebar-pane-width: 264px;
  --s-topbar-h:           58px;

  /* ── Animation ───────────────────────────────────────────── */
  --s-transition:      0.2s ease;
  --s-transition-slow: 0.35s ease;

  /* ── Shadows (Apple-style layered) ───────────────────────── */
  --s-shadow-xs: 0 1px 2px rgba(15,23,42,0.05);
  --s-shadow-sm: 0 4px 12px rgba(15,23,42,0.05), 0 1px 3px rgba(15,23,42,0.03);
  --s-shadow-md: 0 10px 28px rgba(15,23,42,0.06), 0 2px 8px rgba(15,23,42,0.04);
  --s-shadow-lg: 0 18px 44px rgba(15,23,42,0.08), 0 4px 12px rgba(15,23,42,0.05);
  --s-shadow-xl: 0 32px 70px rgba(15,23,42,0.10), 0 8px 24px rgba(15,23,42,0.06);
}

/* ── Font smoothing ─────────────────────────────────────────── */
body {
  font-family: var(--bs-body-font-family);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

/* Apple-style tight tracking on headings / titles */
h1, h2, h3, h4, h5,
.s-form-title, .card-title, .login-title,
.title-text {
  letter-spacing: var(--s-letter-tight);
}

/* Tabular figures for data so columns don't shift */
.s-DataGrid, .slick-cell, .s-dashboard-card-sm h3, table {
  font-variant-numeric: tabular-nums;
}

/* ── Arabic bilingual ───────────────────────────────────────── */
/* Cairo was never shipped to /fonts (404s on Cairo-*.woff2). Use the system
   Arabic-capable fonts that ship with Windows/macOS instead. Re-add "Cairo"
   here (and its @font-face + woff2 files in fonts.css) if it's ever bundled. */
:lang(ar),
[dir="rtl"] {
  font-family: "Segoe UI", Tahoma, var(--bs-body-font-family);
}

/* ── Force FA7 Pro Light (weight 300) for all icon classes ──── */
/* .fas/.fa-solid default to 900; override so all icons are thin */
.fa,
.fas, .fa-solid,
.far, .fa-regular,
.fab, .fa-brands {
  font-weight: 300;
}
