/**
 * iVisualStudio — @ui-design-system & @mobile-design Tokens
 * Built for iOS OLED displays, 44pt/48pt Fitts' Law touch targets, and SF Pro / SF Mono Dynamic Type.
 * Semantic aliases (docs/DESIGN-PLAN.md §7) are var() references only — no hex is added here.
 */
:root {
  /* OLED & Machined Obsidian Surfaces (Battery-Conscious Dark Default) */
  --ide-bg-oled-true: #000000;
  --ide-bg-canvas: #05080E;
  --ide-bg-chassis: #0A0F18;
  --ide-bg-elevated: #111926;
  --ide-bg-thumb-bar: #131E2E;

  /* Semantic Inks (measured on #05080E: primary ~18.8:1, secondary ~8.9:1 — AA/AAA;
     muted ~4.2:1 — decorative use only, not body text) */
  --ide-ink-primary: #F4F9FD;
  --ide-ink-secondary: #9BB0C5;
  --ide-ink-muted: #64748B;

  /* Brand & IDE Signals */
  --ide-signal-azure: #38BDF8;
  --ide-signal-vscode: #007ACC;
  --ide-signal-cyan: #14F1D9;
  --ide-signal-emerald: #34D399;
  --ide-signal-violet: #A855F7;
  --ide-signal-amber: #FBBF24;
  --ide-signal-coral: #FC6D26;

  /* Semantic aliases (docs/DESIGN-PLAN.md §7 — adopted 2026-12-01, zero-drift rule) */
  --ide-surface-editor: var(--ide-bg-oled-true);
  --ide-surface-chrome: var(--ide-bg-canvas);
  --ide-surface-sheet: var(--ide-bg-elevated);
  --ide-surface-key: var(--ide-bg-thumb-bar);
  --ide-role-accent: var(--ide-signal-azure);
  --ide-role-live: var(--ide-signal-cyan);
  --ide-role-pass: var(--ide-signal-emerald);
  --ide-role-fail: var(--ide-signal-coral);
  --ide-role-warn: var(--ide-signal-amber);
  --ide-role-ai: var(--ide-signal-violet);
  --ide-role-legacy: var(--ide-signal-vscode);
  --ide-text-primary: var(--ide-ink-primary);
  --ide-text-secondary: var(--ide-ink-secondary);
  --ide-text-disabled: var(--ide-ink-muted);
  --ide-border-subtle: rgba(155, 176, 197, 0.18);
  --ide-border-strong: rgba(155, 176, 197, 0.28);

  /* Pocket Code Radii & Row Rhythm (ios/iDE/IDETheme.swift) */
  --ide-radius-tile: 12px;
  --ide-radius-card: 14px;
  --ide-radius-group: 18px;
  --ide-size-tile: 40px;
  --ide-size-row: 68px;
  --ide-size-button: 54px;

  /* iOS HIG Touch & Safe-Area Ergonomics (@mobile-design) */
  --ide-hit-min-ios: 44px;
  --ide-hit-recommended: 48px;
  --ide-hit-gap-min: 8px;
  --ide-safe-top-island: 59px;
  --ide-safe-bottom-home: 34px;

  /* 8pt Spatial Grid (@ui-design-system) */
  --ide-space-1: 4px;
  --ide-space-2: 8px;
  --ide-space-3: 12px;
  --ide-space-4: 16px;
  --ide-space-6: 24px;
  --ide-space-8: 32px;

  /* iOS Dynamic Type Scale (SF Pro & SF Mono) */
  --ide-font-sans: "SF Pro Text", "SF Pro Display", -apple-system, BlinkMacSystemFont, sans-serif;
  --ide-font-mono: "SF Mono", "JetBrains Mono", ui-monospace, Menlo, monospace;
  --ide-type-large-title: 34px;
  --ide-type-title-1: 28px;
  --ide-type-title-2: 22px;
  --ide-type-headline: 17px;
  --ide-type-body: 17px;
  --ide-type-code: 13.5px;
  --ide-type-caption: 12px;

  /* Fixed line boxes (DESIGN.md §3 — the 30/16-row arithmetic depends on these) */
  --ide-type-code-leading: 22px;
  --ide-type-body-leading: 24px;
  --ide-type-caption-leading: 16px;

  /* Display tracking (DESIGN.md §3 — track-tight on the two display sizes only) */
  --ide-type-large-title-tracking: -0.022em;
  --ide-type-title-1-tracking: -0.015em;
}
