
/* ===== Design Tokens ===== */
:root {
  /* Surface */
  --bg: #f6f7fb;
  --panel: #ffffff;
  --panel-soft: #fcfdff;
  --line: #e3e7ef;
  --line-strong: #cbd5e1;

  /* Text */
  --text: #1f2937;
  --muted: #5b6472;            /* WCAG AA on white: 7.0:1 (上げた) */
  --muted-strong: #475569;

  /* Brand / status */
  --primary: #2563eb;
  --primary-soft: #dbeafe;
  --success: #166534;
  --success-soft: #dcfce7;
  --danger: #b91c1c;
  --danger-soft: #fee2e2;
  --warning: #92400e;
  --warning-soft: #fef3c7;

  /* Effects */
  --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.04);
  --shadow: 0 4px 14px rgba(15, 23, 42, 0.06);
  --shadow-strong: 0 10px 28px rgba(15, 23, 42, 0.12);
  --radius: 16px;
  --radius-sm: 10px;

  /* Type scale */
  --fs-display: 2.4rem;
  --fs-hero: 1.85rem;
  --fs-h1: 1.55rem;
  --fs-h2: 1.1rem;
  --fs-body: 1rem;
  --fs-small: 0.875rem;
  --fs-meta: 0.8rem;

  /* Motion */
  --t-fast: 120ms;
  --t-base: 200ms;
}

/* ===== Dark mode ===== */
@media (prefers-color-scheme: dark) {
  :root[data-theme="auto"], :root:not([data-theme]) {
    --bg: #0f172a;
    --panel: #1e293b;
    --panel-soft: #243049;
    --line: #334155;
    --line-strong: #475569;
    --text: #e2e8f0;
    --muted: #cbd5e1;
    --muted-strong: #e2e8f0;
    --primary: #60a5fa;
    --primary-soft: #1e3a8a;
    --success: #4ade80;
    --success-soft: #064e3b;
    --danger: #f87171;
    --danger-soft: #7f1d1d;
    --warning: #fbbf24;
    --warning-soft: #78350f;
    --shadow: 0 4px 14px rgba(0, 0, 0, 0.4);
    --shadow-strong: 0 10px 28px rgba(0, 0, 0, 0.55);
  }
}
:root[data-theme="dark"] {
  --bg: #0f172a;
  --panel: #1e293b;
  --panel-soft: #243049;
  --line: #334155;
  --line-strong: #475569;
  --text: #e2e8f0;
  --muted: #cbd5e1;
  --muted-strong: #e2e8f0;
  --primary: #60a5fa;
  --primary-soft: #1e3a8a;
  --success: #4ade80;
  --success-soft: #064e3b;
  --danger: #f87171;
  --danger-soft: #7f1d1d;
  --warning: #fbbf24;
  --warning-soft: #78350f;
  --shadow: 0 4px 14px rgba(0, 0, 0, 0.4);
  --shadow-strong: 0 10px 28px rgba(0, 0, 0, 0.55);
}

/* ===== Reset ===== */
* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Hiragino Sans",
               "Yu Gothic UI", "Meiryo", sans-serif;
  font-feature-settings: "palt";
  background: var(--bg);
  color: var(--text);
  font-size: var(--fs-body);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
.tabular-num { font-variant-numeric: tabular-nums; }
a { color: inherit; text-decoration: none; }

