/* ---------------------------------------------------------------
   Design tokens — the only place colours / spacing / type are defined.
   Never hard-code a hex value or a magic number outside this file.
   Palette reference: the Canva travel booklet — warm paper, ink line
   work, a single vermilion seal accent, sakura + sea as supporting hues.
   --------------------------------------------------------------- */
:root {
  /* paper & ink */
  --c-paper:        #faf7f1;
  --c-paper-raised: #fffdf9;
  --c-paper-sunk:   #f2ece0;
  --c-rule:         #e4dccc;
  --c-rule-strong:  #cdc2ad;
  --c-ink:          #1e1c19;
  --c-ink-soft:     #55504a;
  --c-ink-faint:    #8d8578;

  /* accents */
  --c-seal:         #b4452f;   /* 朱印紅 — primary accent, use sparingly */
  --c-seal-wash:    #f4e3dd;
  --c-sakura:       #d98ca3;
  --c-sea:          #456b7b;
  --c-pine:         #5a7055;
  --c-gold:         #b9985c;

  /* feedback */
  --c-ok:           #4d7a52;
  --c-warn:         #9a6a1f;
  --c-danger:       #a93b2c;

  /* type */
  --f-display: "Noto Serif TC", "Songti TC", serif;
  --f-body:    "Noto Sans TC", "PingFang TC", system-ui, sans-serif;
  --f-hand:    "Caveat", "Noto Serif TC", cursive;
  --f-mono:    "IBM Plex Mono", ui-monospace, "SFMono-Regular", monospace;

  --fs-xs:   0.75rem;
  --fs-sm:   0.8125rem;
  --fs-base: 0.9375rem;
  --fs-md:   1.0625rem;
  --fs-lg:   1.375rem;
  --fs-xl:   1.875rem;
  --fs-2xl:  2.5rem;
  --fs-3xl:  3.5rem;

  --lh-tight: 1.25;
  --lh-base:  1.75;

  /* 中文標題的字距 — 旅遊書封面那種「企 鵝 班 旅 行」的疏朗感 */
  --ls-title:  0.22em;
  --ls-label:  0.14em;

  /* spacing — 4px base */
  --s-1: 0.25rem;
  --s-2: 0.5rem;
  --s-3: 0.75rem;
  --s-4: 1rem;
  --s-5: 1.5rem;
  --s-6: 2rem;
  --s-7: 3rem;
  --s-8: 4rem;
  --s-9: 6rem;

  /* shape */
  --r-sm: 3px;
  --r-md: 6px;
  --r-lg: 12px;
  --r-pill: 999px;

  /* elevation — paper never floats far off the desk */
  --e-1: 0 1px 2px rgb(30 28 25 / 0.04), 0 1px 1px rgb(30 28 25 / 0.03);
  --e-2: 0 2px 6px rgb(30 28 25 / 0.06), 0 1px 2px rgb(30 28 25 / 0.04);
  --e-3: 0 8px 28px rgb(30 28 25 / 0.10), 0 2px 6px rgb(30 28 25 / 0.05);

  /* layout */
  --w-rail: 248px;
  --w-page: 980px;
  --w-prose: 62ch;

  /* motion */
  --t-fast: 120ms ease;
  --t-base: 200ms cubic-bezier(.2, .7, .3, 1);

  /* 方格紙底紋的格寬 */
  --grid-cell: 22px;
}

@media (prefers-reduced-motion: reduce) {
  :root { --t-fast: 1ms; --t-base: 1ms; }
}
