/* Roselli design tokens, v1.2 (2026-11-22). Source of truth: guide-roselli.md.
   Palette: Rosso Festival, Gesso, Nero, plus two support neutrals (Pietra, Calce) and white for text on red.
   Font paths are relative to this file (css/). Originals served unmodified; WOFF2 is a format conversion only. */

@font-face {
  font-family: "Tenor Sans";
  src: url("../fonts/TenorSans-Regular.woff2") format("woff2"),
       url("../fonts/TenorSans-Regular.ttf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Newsreader";
  src: url("../fonts/Newsreader-VariableFont.woff2") format("woff2"),
       url("../fonts/Newsreader-VariableFont.ttf") format("truetype");
  font-weight: 200 800;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Newsreader";
  src: url("../fonts/Newsreader-Italic-VariableFont.woff2") format("woff2"),
       url("../fonts/Newsreader-Italic-VariableFont.ttf") format("truetype");
  font-weight: 200 800;
  font-style: italic;
  font-display: swap;
}

:root {
  /* Brand colours */
  --rs-red: #E0101E;        /* Rosso Festival: fields, buttons, rings, underlines. Not for small text on Gesso (4.45:1). */
  --rs-gesso: #F7F3EC;      /* Gesso: page background (light) / text (dark) */
  --rs-nero: #151313;       /* Nero: text (light) / page background (dark) */
  /* Support neutrals */
  --rs-pietra: #6B645D;     /* Pietra: secondary text on Gesso/white (5.27:1 / 5.82:1) */
  --rs-calce: #E6DFD3;      /* Calce: rules, input borders, quiet surfaces on light; secondary text on Nero (13.98:1) */
  --rs-white: #FFFFFF;      /* text on red (4.93:1) */

  /* Semantic (light theme default) */
  --color-bg: var(--rs-gesso);
  --color-surface: var(--rs-white);
  --color-surface-quiet: var(--rs-calce);
  --color-text: var(--rs-nero);
  --color-text-muted: var(--rs-pietra);
  --color-line: var(--rs-calce);
  --color-line-strong: var(--rs-nero);
  --color-accent: var(--rs-red);
  --color-on-accent: var(--rs-white);
  --color-link: var(--rs-nero);
  --color-link-underline: var(--rs-red);
  --color-focus: var(--rs-nero);
  --color-field: var(--rs-red);       /* hero / poster field */
  --color-on-field: var(--rs-white);
  --color-ring-on-field: var(--rs-nero);

  /* Type */
  --font-display: "Tenor Sans", "Gill Sans", "Optima", sans-serif;
  --font-body: "Newsreader", "Iowan Old Style", Georgia, serif;
  --text-xs: 0.75rem;    /* 12 */
  --text-sm: 0.875rem;   /* 14 */
  --text-base: 1.125rem; /* 18 body */
  --text-md: 1.375rem;   /* 22 */
  --text-lg: 1.75rem;    /* 28 */
  --text-motto: 2rem;    /* 32 — Fons novitatis, secondary, not a headline */
  --text-xl: 2.25rem;    /* 36 */
  --text-2xl: 3rem;      /* 48 */
  --text-3xl: 4rem;      /* 64 */
  --text-4xl: 5.5rem;    /* 88 */
  --leading-tight: 1.1;
  --leading-snug: 1.3;
  --leading-body: 1.6;
  --tracking-caps: 0.22em;   /* Tenor Sans uppercase labels and nav */
  --tracking-display: 0.01em;

  /* Space (4 px base) */
  --space-1: 4px; --space-2: 8px; --space-3: 12px; --space-4: 16px; --space-5: 24px;
  --space-6: 32px; --space-7: 48px; --space-8: 64px; --space-9: 96px; --space-10: 128px;
  --measure: 68ch;
  --content-max: 1200px;
  --gutter: clamp(20px, 5vw, 64px);

  /* Shape: poster corners are square by default */
  --radius-0: 0;
  --radius-sm: 2px;
  --radius-round: 999px;
  --border-1: 1px;
  --border-2: 2px;

  /* Shadows: used sparingly (menus, dialogs only) */
  --shadow-none: none;
  --shadow-1: 0 1px 2px rgba(21, 19, 19, 0.08);
  --shadow-2: 0 8px 24px rgba(21, 19, 19, 0.12);

  /* Motion */
  --duration-fast: 120ms;
  --duration-base: 200ms;
  --ease: cubic-bezier(0.2, 0, 0, 1);

  /* Logo */
  --logo-wordmark-min-width: 96px;
  --logo-tile-min: 16px;
  --logo-lockup-motto-min-width: 240px; /* motto 18 px */
  --logo-lockup-line-min-width: 330px;  /* line 18 px */
  --logo-lockup-full-min-width: 360px;  /* line 18 px, motto ~27 px */
}

[data-theme="dark"] {
  --color-bg: var(--rs-nero);
  --color-surface: #211E1E;              /* Nero lifted 4% for cards */
  --color-surface-quiet: #2A2626;
  --color-text: var(--rs-gesso);
  --color-text-muted: var(--rs-calce);
  --color-line: rgba(247, 243, 236, 0.18);
  --color-line-strong: var(--rs-gesso);
  --color-link: var(--rs-gesso);
  --color-focus: var(--rs-gesso);
}
