/* =====================================================================
   Domus – design tokens (DM-021, 2026-11-21)
   The single source of colours and fonts for Domus and its modes.
   Look: "European board game" – warm cardboard, paper cards with a
   pressed edge, wooden tokens in the players' colours.
   No hex colour may appear outside this file (AGENTS.md rule 9).
   ===================================================================== */

:root {
  /* ---------- Cardboard and ink ---------- */
  --d-bg:          #F4EFE6;   /* the table: warm cardboard */
  --d-card:        #FFFDF9;   /* paper card */
  --d-card-alt:    #FBF7EE;   /* quieter card: track, ribbons */
  --d-edge:        #E4DAC8;   /* card border, rules */
  --d-edge-deep:   #D6C9B4;   /* pressed bottom edge of cards and chips */
  --d-chip:        #F7F2E8;   /* secondary buttons */
  --d-chip-hover:  #EFE7D8;
  --d-ink:         #2B241D;   /* text, scores – 13.5:1 on --d-bg */
  --d-ink-muted:   #5F5345;   /* labels – 6.5:1 on --d-bg, 7.4:1 on --d-card */
  --d-track:       #E5DBC9;   /* empty rail of the track, empty bolt */
  --d-backdrop:    rgb(43 36 29 / 0.5);

  /* ---------- Accent: the app itself (main button, barrel, links) ----------
     Never offered as a player colour, so "terracotta" always means the app, not a person. */
  --d-accent:        #B04C2D;  /* white text 5.4:1 */
  --d-accent-hover:  #BC5634;
  --d-accent-edge:   #8A3A20;
  --d-accent-soft:   #F6E3DB;  /* barrel badge background; --d-accent-ink on it 6.3:1 */
  --d-accent-ink:    #8F3B20;
  --d-on-accent:     #FFFDF9;

  /* ---------- Meaning ---------- */
  --d-bad:        #A3261F;     /* penalties, minus – 6.9:1 on --d-card */
  --d-bad-soft:   #F8E4E1;
  --d-good:       #2E6B45;     /* win, made bid – 6.2:1 on --d-card */
  --d-good-soft:  #E4F0E7;
  --d-gold:       #B7791F;     /* leader, trophies (with dark ink text on --d-gold-soft) */
  --d-gold-soft:  #FAEFD6;

  /* ---------- Player colours: wooden tokens ----------
     Chosen per profile. Lightness differs as well as hue, so they stay apart for colour-blind eyes.
     *-on is the text colour on the token. */
  --p-blue:    #34547A;  --p-blue-on:    #FFFFFF;
  --p-green:   #3F7350;  --p-green-on:   #FFFFFF;
  --p-yellow:  #E0A526;  --p-yellow-on:  #2B241D;
  --p-red:     #C23B3B;  --p-red-on:     #FFFFFF;
  --p-black:   #3A3A3A;  --p-black-on:   #FFFFFF;
  --p-plum:    #7A4B7A;  --p-plum-on:    #FFFFFF;
  --p-teal:    #2B7C82;  --p-teal-on:    #FFFFFF;
  --p-pink:    #D9809A;  --p-pink-on:    #2B241D;

  /* ---------- Type ---------- */
  --font-display: "Playfair Display", Georgia, "Times New Roman", serif; /* headings and scores; has Cyrillic */
  --font-ui:      "Inter", -apple-system, "Segoe UI", Roboto, sans-serif;

  --text-score:    3.25rem;  /* 52px – the score on the table screen, readable across the table */
  --text-score-sm: 2.25rem;  /* 36px – scores in 2x2 boards */
  --text-h1:       1.625rem; /* 26px */
  --text-h2:       1.25rem;  /* 20px */
  --text-body:     1rem;     /* 16px */
  --text-label:    0.8125rem;/* 13px – the smallest text in the app */

  /* ---------- Shape ---------- */
  --r-card: 16px;
  --r-chip: 12px;
  --r-pill: 999px;
  --tap:    48px;             /* minimal height of anything tappable */
  --gap:    12px;
  --pad:    16px;
}
