/* Shared design tokens across all tools (Fyluro, Oxys, thanosam.com). */

:root {
  /* Follow the OS theme by default; theme.js overrides this via data-theme. */
  color-scheme: light dark;

  /* Typography: native Apple system fonts (SF Pro and SF Mono on macOS). */
  --font-sans: -apple-system, BlinkMacSystemFont, "SF Pro Text", "SF Pro Display",
    system-ui, "Segoe UI", Roboto, sans-serif;
  --font-mono: ui-monospace, "SF Mono", SFMono-Regular, Menlo, Monaco,
    Consolas, monospace;

  /* Type scale */
  --text-xs: 0.75rem;
  --text-sm: 0.875rem;
  --text-base: 1rem;
  --text-lg: 1.125rem;
  --text-xl: 1.375rem;
  --text-2xl: 1.875rem;
  --text-3xl: clamp(2.125rem, 4.5vw, 3.125rem);

  --leading-tight: 1.15;
  --leading-snug: 1.35;
  --leading-normal: 1.6;

  /* Spacing scale */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.5rem;
  --space-6: 2rem;
  --space-7: 3rem;
  --space-8: 4.5rem;

  /* Radii */
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 14px;
  --radius-pill: 999px;

  /* Layout */
  --container-max: 1020px;
  --container-pad: clamp(1rem, 4vw, 2rem);

  /* Shared neutral colors: light-dark(light value, dark value) */
  --bg: light-dark(#fbfbfa, #111214);
  --bg-elevated: light-dark(#ffffff, #181a1d);
  --bg-subtle: light-dark(#f2f2ef, #202327);

  --border: light-dark(#e3e3de, #2a2e33);
  --border-strong: light-dark(#cbcBc4, #3d434b);

  --text: light-dark(#18181b, #f4f4f5);
  --text-muted: light-dark(#52525b, #a1a1aa);
  --text-subtle: light-dark(#71717a, #8b8b94);

  /* Fallback accent (overridden by static/tool/tool.css) */
  --accent: light-dark(#27272a, #e4e4e7);
  --accent-hover: light-dark(#18181b, #ffffff);
  --accent-soft: light-dark(rgba(39, 39, 42, 0.1), rgba(228, 228, 231, 0.14));
  --accent-ink: light-dark(#ffffff, #111214);

  /* Shadows */
  --shadow-sm: light-dark(
    0 1px 2px rgba(0, 0, 0, 0.05),
    0 1px 2px rgba(0, 0, 0, 0.35)
  );
}

:root[data-theme="light"] {
  color-scheme: light;
}

:root[data-theme="dark"] {
  color-scheme: dark;
}
