/*
 * AeroBook design tokens (docs/20 §2) — static defaults, shipped with the
 * plugin. A school that never opens «هویت بصری» in settings gets exactly
 * these values. Aero_Theme::render_css_vars() (includes/class-aero-theme.php)
 * prints an inline :root override block AFTER this file in the page <head>
 * (same specificity, later wins) for whichever of the 4 brand inputs a
 * school actually customized — everything else here still applies.
 *
 * Every color/radius/shadow/spacing value in this plugin's own templates
 * must be one of these variables, never a literal hex/px value written
 * again in a template (docs/20 §1 principle 1) — grep -rn "#[0-9a-fA-F]{6}"
 * across templates/ and admin/ should only ever match this file.
 */

/*
 * The panel font (--aero-font below). Declared here, once: until 0.6.63 the
 * font was named in the design system but only the booking page ever loaded
 * it, so every other panel page fell back to the system font.
 */
@font-face {
  font-family: 'IRANSans';
  src: url('../fonts/IRANSansWeb.woff2') format('woff2');
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}

:root {
  /* --- Brand (school-configurable, 4 inputs) --- */
  --aero-brand: #6C5CE7;
  --aero-brand-2: #00D9A6;
  --aero-accent: #FF7A45;
  --aero-sidebar-bg: #1A1B3A;
  /* Sidebar highlight (active item, hover wash, glow, role caption) — the mockup's sky blue; independent of the brand colour on purpose, it sits on the dark sidebar. */
  --aero-sidebar-accent: #38BDF8;

  /* --- Brand scale, derived from --aero-brand (Aero_Theme::render_css_vars() recomputes on override) --- */
  --aero-brand-50: #F3F2FD;
  --aero-brand-100: #E7E4FB;
  --aero-brand-200: #C7C1F6;
  --aero-brand-300: #A399F0;
  --aero-brand-400: #7768E9;
  --aero-brand-500: #6C5CE7;
  --aero-brand-600: #311DC8;
  --aero-brand-700: #26179C;
  --aero-brand-800: #1D1278;
  --aero-brand-900: #140C50;
  --aero-brand-contrast: #FFFFFF;
  --aero-sidebar-contrast: #FFFFFF;

  /* --- Fixed semantic (never school-configurable — status meaning must stay universal) --- */
  --aero-success: #12B76A;
  --aero-warning: #F79009;
  --aero-danger: #F04438;
  --aero-info: #0BA5EC;

  /* --- Surfaces --- */
  --aero-bg: #F7F8FC;
  --aero-surface: #FFFFFF;
  /* Neutral (slate) text / line / wash for forms, tags and captions — not brand-tinted, so grey stays grey whatever the school's brand colour is. */
  --aero-ink: #1E293B;
  --aero-ink-muted: #64748B;
  --aero-line: #E2E8F0;
  --aero-wash: #F1F5F9;
  --aero-glass-bg: rgba(255, 255, 255, .72);
  --aero-glass-border: rgba(255, 255, 255, .45);
  --aero-glass-blur: 16px;

  /* --- Type / shape / motion --- */
  --aero-font: 'IRANSans', system-ui, sans-serif;
  --aero-radius-sm: 8px;
  --aero-radius: 14px;
  --aero-radius-lg: 20px;
  --aero-shadow-sm: 0 1px 3px rgba(16, 24, 40, .06);
  --aero-shadow: 0 4px 16px rgba(16, 24, 40, .08);
  --aero-shadow-lg: 0 12px 32px rgba(16, 24, 40, .12);
  --aero-transition: 180ms cubic-bezier(.4, 0, .2, 1);
}

/*
 * Dark mode: a token override block, not a second stylesheet (docs/20 §2) —
 * every component rule in aerobook-design.css keeps working unmodified,
 * it just reads different variable values.
 *
 * Opt-in only (<html data-theme="dark">), no longer automatic. It used to
 * follow the visitor's OS/browser `prefers-color-scheme`, which turned the
 * whole panel black for any new visitor, incognito window or logged-out
 * page on a device set to dark mode (Dara's report, 2026-09-18 — she wants
 * the normal light/white look everywhere unless dark is explicitly chosen;
 * nothing in the plugin sets that attribute today, so light is now always
 * the default).
 */
:root[data-theme="dark"] {
  --aero-bg: #0F1222;
  --aero-surface: #1A1D33;
  --aero-ink: #E2E8F0;
  --aero-ink-muted: #94A3B8;
  --aero-line: #2B2F4A;
  --aero-wash: #23264A;
  --aero-glass-bg: rgba(26, 29, 51, .72);
  --aero-glass-border: rgba(255, 255, 255, .12);
  --aero-shadow-sm: 0 1px 3px rgba(0, 0, 0, .24);
  --aero-shadow: 0 4px 16px rgba(0, 0, 0, .32);
  --aero-shadow-lg: 0 12px 32px rgba(0, 0, 0, .4);
}
