/* ============================================================
   FIREADER — Design System (base.css)
   GitHub Dark palette + JetBrains Mono
   ============================================================ */

/* ── Google Fonts ─────────────────────────────────────────── */
@import url('https://fonts.googleapis.com/css2?family=JetBrains+Mono:ital,wght@0,300;0,400;0,500;0,600;0,700;1,400&family=Inter:wght@300;400;500;600&display=swap');

/* ── Design Tokens ────────────────────────────────────────── */
:root {
  /* Background */
  --bg-canvas:    #070b0e;
  --bg-default:   #0d1318;
  --bg-subtle:    #131b22;
  --bg-hover:     #1a2630;
  --bg-overlay:   rgba(7, 11, 14, 0.92);

  /* Borders */
  --border:       #233842;
  --border-light: #17262d;

  /* Text */
  --text-primary:  #7ab0c2;
  --text-secondary:#507d8c;
  --text-muted:    #385c68;
  --text-line-num: #2d4a54;

  /* Syntax Colors */
  --syn-tag:     #5f8a9e;   /* @tags → muted slate */
  --syn-str:     #4b8587;   /* strings → tealish */
  --syn-num:     #a08f73;   /* numbers → faded tan */
  --syn-name:    #8cb8c9;   /* proper nouns → brighter cyan */
  --syn-kw:      #9ecea4;   /* keywords */
  --syn-comment: #355a66;   /* comments → dim cyan */
  --syn-muted:   #2d4a54;   /* parentheticals → dark */

  /* Accent */
  --accent:      #528b9c;
  --accent-dim:  #345f6e;
  --accent-glow: rgba(82, 139, 156, 0.15);

  /* Fonts */
  --font-mono: 'JetBrains Mono', 'Fira Code', 'Cascadia Code', Consolas, 'PingFang SC', 'Microsoft YaHei', 'Noto Sans CJK SC', monospace;
  --font-ui:   'Inter', system-ui, -apple-system, sans-serif;

  /* Layout */
  --header-h:   48px;
  --tab-h:      34px;
  --status-h:   22px;
  --nav-h:      60px;
  --gutter-w:   48px;

  /* Motion */
  --ease-out:   cubic-bezier(0.16, 1, 0.3, 1);
  --dur-fast:   150ms;
  --dur-mid:    250ms;
  --dur-slow:   400ms;

  /* Safe areas */
  --sai-top:    env(safe-area-inset-top, 0px);
  --sai-bottom: env(safe-area-inset-bottom, 0px);
}

/* ── Reset ────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  font-size: 14px;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  font-family: var(--font-mono);
  background: var(--bg-canvas);
  color: var(--text-primary);
  overflow: hidden;
  height: 100vh;
  height: 100dvh;
  user-select: none;
  -webkit-user-select: none;
  -webkit-tap-highlight-color: transparent;
}

button {
  font-family: var(--font-mono);
  background: none;
  border: none;
  cursor: pointer;
  color: inherit;
  padding: 0;
}

input {
  font-family: var(--font-mono);
  background: none;
  border: none;
  outline: none;
  color: var(--text-primary);
}

/* ── Scrollbar ────────────────────────────────────────────── */
::-webkit-scrollbar              { width: 4px; height: 4px; }
::-webkit-scrollbar-track        { background: transparent; }
::-webkit-scrollbar-thumb        { background: var(--border); border-radius: 0; }
::-webkit-scrollbar-thumb:hover  { background: var(--text-muted); }
