/* LIVING — TOKEN
   Generato da tokens.json con genera-tokens-css.py. Non modificarlo a mano: cambia tokens.json
   e rigeneralo, altrimenti il design system e i moduli raccontano due verità diverse.

   In un modulo Base44 va incollato PRIMA di bundle.css: bundle.css usa queste variabili e non le
   definisce, quindi da solo rende testo invisibile nel tema scuro e spaziature sbagliate.

   Il tema scuro è il fallback: vale sempre tranne quando sull'<html> c'è data-theme="light".
   È la stessa regola che usa bundle.css, e cambiarla qui sfalserebbe i due file.
   24 token comuni, 32 nel tema chiaro, 32 nello scuro. */

/* Tema chiaro e misure che non cambiano con il tema */
:root{
  --bg: #ffffff;
  --surface: #ffffff;
  --sunk: #f1f5f9;
  --ink: #1d1f26;
  --muted: #6c727f;
  --line: #e2e4e9;
  --line-strong: #c5cdd7;
  --accent: #00703c;
  --on-accent: #ffffff;
  --accent-soft: #eaf7f0;
  --accent-text: #00531e;
  --green: #00703c;
  --green-soft: #eaf7f0;
  --green-text: #00531e;
  --yellow: #fac600;
  --yellow-soft: #fcf0cc;
  --yellow-text: #6e5600;
  --crit: #d32f2f;
  --crit-soft: #fdecec;
  --warn: #975a00;
  --warn-soft: #fbf0da;
  --info: #3a7487;
  --info-soft: #e7f1f4;
  --sec-bordo: #cfe6d8;
  --sec-testo: #00531e;
  --dev: #1c73b6;
  --dev-2: #06467a;
  --dev-acc: #5ac9d1;
  --dev-soft: #e3f0fa;
  --dev-text: #06467a;
  --shadow: 0 1px 2px rgba(18,22,32,0.05), 0 10px 28px rgba(18,22,32,0.12);
  --ombra-pri: 0 8px 18px -10px rgba(15,117,53,0.85);
  --marchio-verde: #00723d;
  --marchio-nero: #010203;
  --logo-gradiente-da: #00723f;
  --logo-gradiente-a: #fbb818;
  --slide-ink: #1a1a1a;
  --slide-muted: #6b6b6b;
  --slide-superficie: #f4f7f5;
  --slide-verde-tenue: #dcefe2;
  --slide-ambra: #b57a00;
  --r: 14px;
  --r-md: 12px;
  --r-sm: 10px;
  --pill: 9999px;
  --space-1: 4px;
  --space-2: 6px;
  --space-3: 8px;
  --space-4: 10px;
  --space-5: 12px;
  --space-6: 14px;
  --space-7: 16px;
  --space-8: 18px;
  --space-9: 24px;
  --space-10: 28px;
  --disabilitato: 0.55;
}

/* Tema scuro — fallback, come in bundle.css */
:root:not([data-theme="light"]){
  --bg: #0f1419;
  --surface: #1a1f26;
  --sunk: #232932;
  --ink: #fafafa;
  --muted: #9ca3af;
  --line: #2a2f37;
  --line-strong: #353b45;
  --accent: #fac600;
  --on-accent: #000000;
  --accent-soft: rgba(250,198,0,0.14);
  --accent-text: #fac600;
  --green: #2db87a;
  --green-soft: #13301f;
  --green-text: #7dd8a9;
  --yellow: #fac600;
  --yellow-soft: #3a3008;
  --yellow-text: #ffdf73;
  --crit: #f47a70;
  --crit-soft: #3b1816;
  --warn: #f0b44c;
  --warn-soft: #36270b;
  --info: #8cc3d3;
  --info-soft: #16262c;
  --sec-bordo: #4a4010;
  --sec-testo: #ffdf73;
  --dev: #3f8fd0;
  --dev-2: #1c73b6;
  --dev-acc: #5ac9d1;
  --dev-soft: rgba(28,115,182,0.18);
  --dev-text: #8cc3d3;
  --shadow: 0 1px 2px rgba(0,0,0,0.4), 0 10px 28px rgba(0,0,0,0.45);
  --ombra-pri: 0 8px 18px -10px rgba(250,198,0,0.7);
}

/* Tema scuro dichiarato esplicitamente */
:root[data-theme="dark"]{
  --bg: #0f1419;
  --surface: #1a1f26;
  --sunk: #232932;
  --ink: #fafafa;
  --muted: #9ca3af;
  --line: #2a2f37;
  --line-strong: #353b45;
  --accent: #fac600;
  --on-accent: #000000;
  --accent-soft: rgba(250,198,0,0.14);
  --accent-text: #fac600;
  --green: #2db87a;
  --green-soft: #13301f;
  --green-text: #7dd8a9;
  --yellow: #fac600;
  --yellow-soft: #3a3008;
  --yellow-text: #ffdf73;
  --crit: #f47a70;
  --crit-soft: #3b1816;
  --warn: #f0b44c;
  --warn-soft: #36270b;
  --info: #8cc3d3;
  --info-soft: #16262c;
  --sec-bordo: #4a4010;
  --sec-testo: #ffdf73;
  --dev: #3f8fd0;
  --dev-2: #1c73b6;
  --dev-acc: #5ac9d1;
  --dev-soft: rgba(28,115,182,0.18);
  --dev-text: #8cc3d3;
  --shadow: 0 1px 2px rgba(0,0,0,0.4), 0 10px 28px rgba(0,0,0,0.45);
  --ombra-pri: 0 8px 18px -10px rgba(250,198,0,0.7);
}

