/* Molinazzo - design tokens, direction A "Heritage & stream" (D-015).
   brand-stylist, 2026-10-30. Load fonts.css first, then this file.

   CONTRAST (WCAG 2.x relative luminance; AA = 4.5:1 body, 3:1 large text >= 24px / 18.66px bold)
   Allowed TEXT pairs, light theme:
     --c-ink     #2A2521 on --c-bg      #F3EDE2  13.01  AAA  (body)
     --c-ink     #2A2521 on --c-surface #D9CAAF   9.40  AAA
     --c-primary #2E5A66 on --c-bg               6.51  AA   (links, buttons outline)
     --c-primary #2E5A66 on --c-surface          4.70  AA
     --c-accent  #A4502E on --c-bg               4.79  AA   (accent links, highlights)
     --c-moss    #55653F on --c-bg               5.43  AA
     --c-muted   #6B5546 on --c-bg               5.98  AA   (captions, meta)
     --c-bg      #F3EDE2 on --c-primary          6.51  AA   (primary button label)
     --c-bg      #F3EDE2 on --c-ink             13.01  AAA  (footer, AI label chip)
     --c-bg      #F3EDE2 on --c-accent           4.79  AA
     --c-bg      #F3EDE2 on --c-moss             5.43  AA
   NOT for text: --c-accent on --c-surface (3.46 - large text only), --c-muted on --c-surface (4.32 - large only),
                 --c-surface / --c-rule anywhere as text colour (surfaces, rules, borders only).
   Allowed TEXT pairs, dark theme (bg #1C1916 / surface #28231F):
     ink #F3EDE2 15.02 / 13.35 AAA · primary #9CC7D1 9.59 / 8.52 AAA · accent #E59A74 7.67 / 6.82 AA+
     moss #AFC08E 8.96 / 7.96 AAA · muted #C4B4A2 8.66 / 7.70 AAA · on-primary #1C1916 on #9CC7D1 9.59 AAA
   Rule #4A4038 is decorative only (1.73:1). */

:root {
  color-scheme: light dark;

  /* ---- palette: named (fixed, theme-independent) ---- */
  --lime-plaster:   #F3EDE2;
  --sandstone:      #D9CAAF;
  --millstone-ink:  #2A2521;
  --curone-water:   #2E5A66;
  --terracotta-roof:#A4502E;
  --woodland-moss:  #55653F;
  --chestnut-shade: #6B5546;
  --curone-light:   #9CC7D1;   /* water on dark grounds (used by the symbol in dark mode) */

  /* ---- palette: semantic (light) ---- */
  --c-bg:          var(--lime-plaster);
  --c-surface:     var(--sandstone);      /* cards, bands - surface only */
  --c-surface-2:   #EAE1D1;               /* subtle panel between bg and surface */
  --c-ink:         var(--millstone-ink);  /* body text, headings */
  --c-muted:       var(--chestnut-shade); /* captions, meta */
  --c-primary:     var(--curone-water);   /* links, primary buttons, focus ring */
  --c-primary-hover:#234650;
  --c-on-primary:  var(--lime-plaster);
  --c-accent:      var(--terracotta-roof);
  --c-moss:        var(--woodland-moss);
  --c-rule:        var(--sandstone);      /* hairlines and borders */
  --c-focus:       var(--curone-water);
  --c-label-bg:    rgba(42, 37, 33, .82); /* AI-concept label chip over images */
  --c-label-ink:   var(--lime-plaster);
  --c-strip-bg:    var(--millstone-ink);  /* AI label as a solid strip under narrow images: plaster on ink 13.01 */
  --c-strip-ink:   var(--lime-plaster);

  /* ---- typography ---- */
  --font-display: "Cormorant Garamond", "Cormorant", Garamond, "EB Garamond", "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", Georgia, serif;
  --font-text:    "Libre Franklin", "Franklin Gothic", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;

  --fw-text: 400;  --fw-text-medium: 500;  --fw-text-strong: 600;
  --fw-display: 500;  --fw-display-strong: 600;

  /* fluid scale, 360px -> 1280px viewport. Cormorant runs small: display sizes are set larger. */
  --fs-xs:   0.8125rem;                                  /* 13px  labels, AI chip */
  --fs-sm:   0.9375rem;                                  /* 15px  captions, meta */
  --fs-base: 1.0625rem;                                  /* 17px  body (Libre Franklin) */
  --fs-lg:   clamp(1.125rem, 1.05rem + 0.35vw, 1.3125rem);  /* 18–21 lead */
  --fs-h4:   clamp(1.375rem, 1.25rem + 0.5vw, 1.625rem);    /* 22–26 serif */
  --fs-h3:   clamp(1.625rem, 1.4rem + 0.9vw, 2.125rem);     /* 26–34 */
  --fs-h2:   clamp(2rem, 1.6rem + 1.7vw, 3rem);             /* 32–48 */
  --fs-h1:   clamp(2.625rem, 1.9rem + 3.1vw, 4.5rem);       /* 42–72 */
  --fs-display: clamp(3rem, 2rem + 4.4vw, 5.75rem);         /* 48–92 hero */

  --lh-tight: 1.08;   /* display serif */
  --lh-heading: 1.18;
  --lh-body: 1.6;
  --tracking-caps: 0.14em;   /* small tracked capitals, e.g. "VALLE DEL CURONE" */
  --measure: 66ch;

  /* ---- spacing (4px base) ---- */
  --space-1: 0.25rem;  --space-2: 0.5rem;  --space-3: 0.75rem; --space-4: 1rem;
  --space-5: 1.5rem;   --space-6: 2rem;    --space-7: 3rem;    --space-8: 4rem;
  --space-9: 6rem;     --space-10: 8rem;
  --gutter: clamp(1rem, 0.5rem + 2.5vw, 2.5rem);
  --section: clamp(3rem, 2rem + 5vw, 7rem);
  --container: 72rem;

  /* ---- radius, borders, shadow, motion ---- */
  --radius-sm: 2px;   /* buttons, chips - editorial, nearly square */
  --radius-md: 4px;   /* cards, images */
  --radius-lg: 8px;
  --radius-pill: 999px;
  --border: 1px solid var(--c-rule);
  --shadow-1: 0 1px 2px rgba(42, 37, 33, .08), 0 4px 16px rgba(42, 37, 33, .06);
  --focus-ring: 0 0 0 3px var(--c-bg), 0 0 0 5px var(--c-focus);
  --ease: cubic-bezier(.2, .6, .2, 1);
  --dur: 180ms;
}

@media (prefers-color-scheme: dark) {
  :root {
    --c-bg:          #1C1916;  /* wet millstone */
    --c-surface:     #28231F;
    --c-surface-2:   #221E1A;
    --c-ink:         #F3EDE2;
    --c-muted:       #C4B4A2;
    --c-primary:     #9CC7D1;
    --c-primary-hover:#B9DAE1;
    --c-on-primary:  #1C1916;
    --c-accent:      #E59A74;
    --c-moss:        #AFC08E;
    --c-rule:        #4A4038;
    --c-focus:       #9CC7D1;
    --c-label-bg:    rgba(20, 17, 15, .82);
    --c-label-ink:   #F3EDE2;
    --c-strip-bg:    #322B26;  /* #F3EDE2 on #322B26 about 11.9:1 */
    --c-strip-ink:   #F3EDE2;
    --shadow-1: 0 1px 2px rgba(0, 0, 0, .4), 0 4px 16px rgba(0, 0, 0, .3);
  }
}

@media (prefers-reduced-motion: reduce) {
  :root { --dur: 0ms; }
}
