/* ============================================================
   TERRA3000 theme: the engineering-drawing sheet.
   Re-tuned from the taste "tech" direction. Every value is named
   after the site: asphalt, graphite, concrete, survey red.
   Load after foundation.css. Dark remap sits under @media screen
   so print always resolves the light sheet.
   Check: python3 /workspace/skills/taste/scripts/check_contrast.py src/css/theme.css
   ============================================================ */

@font-face {
  font-family: "Archivo"; font-style: normal; font-display: swap;
  font-weight: 100 900; font-stretch: 62% 125%;
  src: url("../fonts/archivo-latin-standard-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Archivo"; font-style: normal; font-display: swap;
  font-weight: 100 900; font-stretch: 62% 125%;
  src: url("../fonts/archivo-latin-ext-standard-normal.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face { font-family: "IBM Plex Mono"; font-style: normal; font-display: swap; font-weight: 400; src: url("../fonts/ibm-plex-mono-latin-400-normal.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "IBM Plex Mono"; font-style: normal; font-display: swap; font-weight: 400; src: url("../fonts/ibm-plex-mono-latin-ext-400-normal.woff2") format("woff2"); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "IBM Plex Mono"; font-style: normal; font-display: swap; font-weight: 500; src: url("../fonts/ibm-plex-mono-latin-500-normal.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "IBM Plex Mono"; font-style: normal; font-display: swap; font-weight: 500; src: url("../fonts/ibm-plex-mono-latin-ext-500-normal.woff2") format("woff2"); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "IBM Plex Mono"; font-style: normal; font-display: swap; font-weight: 600; src: url("../fonts/ibm-plex-mono-latin-600-normal.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "IBM Plex Mono"; font-style: normal; font-display: swap; font-weight: 600; src: url("../fonts/ibm-plex-mono-latin-ext-600-normal.woff2") format("woff2"); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }

:root {
  --font-display: "Archivo", "Arial Narrow", "Helvetica Neue", Arial, sans-serif;
  --font-body: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;
  --w-display: 820;
  --stretch-display: 72%;
  --tr-display: -0.01em;
  --tr-h2: -0.005em;
  --lh-display: 0.92;
  --fs-display: clamp(2.7rem, 1.6rem + 4vw, 5.4rem);
  --fs-h2: clamp(2.2rem, 1.2rem + 4vw, 5rem);
  --radius: 2px;
  --radius-sm: 2px;
  --radius-button: 2px;
  --case-eyebrow: uppercase;
  --tr-eyebrow: 0.1em;
  /* sheet: drawing paper and concrete */
  --bg: #ffffff;
  --surface: #ffffff;
  --surface-2: #f3f2f0;
  /* ink: drawing ink, logo grey */
  --ink: #111111;
  --muted-strong: #2f2f2f;
  --muted: #4d4d4d;
  --line: #e2e0dc;
  --line-strong: #bdbab4;
  /* asphalt band */
  --ink-field: #0b0b0b;
  --on-ink: #f3f2f0;
  --on-ink-muted: #aeaba6;
  /* survey red, from the TERRASALES mark */
  --accent: #e4283f;
  --accent-fill: #d41f37;
  --accent-on-fill: #ffffff;
  --accent-text: #c81e34;
  --accent-soft: #fbe9eb;
  --field-1: #f3f2f0;
  --field-1-ink: #111111;
  --field-2: #c81e34;
  --field-2-ink: #ffffff;
  --field-3: #0b0b0b;
  --field-3-ink: #f3f2f0;
  /* drawing extras: grid, hatch, soil layers; only TERRA3000 is red */
  --grid: rgba(17, 17, 17, 0.06);
  --grid-strong: rgba(17, 17, 17, 0.11);
  --hatch: rgba(17, 17, 17, 0.28);
  --layer-1: #2b2b2b;
  --layer-2: #575654;
  --layer-3: #8d8b87;
  --layer-4: #b9b6b0;
  --layer-5: #d9d6d0;
  --subgrade: #e9e6e0;
  --terra: #e4283f;
  --terra-ink: #ffffff;
  --map-land: #e7e5e1;
  --map-land-hi: #d6d3cd;
  --map-sea: #f7f6f4;
  --map-edge: #ffffff;
  --dim: #c81e34;
  color-scheme: light dark;
}

@media screen and (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0b0b0b;
    --surface: #161616;
    --surface-2: #1a1a1a;
    --ink: #f3f2f0;
    --muted-strong: #d2cfca;
    --muted: #a6a39e;
    --line: rgba(243, 242, 240, 0.1);
    --line-strong: rgba(243, 242, 240, 0.24);
    --ink-field: #161616;
    --on-ink: #f3f2f0;
    --on-ink-muted: #aeaba6;
    --accent: #ff4d5e;
    --accent-fill: #d41f37;
    --accent-on-fill: #ffffff;
    --accent-text: #ff4d5e;
    --accent-soft: rgba(255, 77, 94, 0.14);
    --field-1: #1a1a1a;
    --field-1-ink: #f3f2f0;
    --field-2: #c81e34;
    --field-2-ink: #ffffff;
    --field-3: #f3f2f0;
    --field-3-ink: #111111;
    --grid: rgba(243, 242, 240, 0.05);
    --grid-strong: rgba(243, 242, 240, 0.1);
    --hatch: rgba(243, 242, 240, 0.3);
    --layer-1: #e9e6e0;
    --layer-2: #b4b1ab;
    --layer-3: #85827d;
    --layer-4: #5c5a57;
    --layer-5: #3d3c3a;
    --subgrade: #262524;
    --terra: #e4283f;
    --terra-ink: #ffffff;
    --map-land: #232322;
    --map-land-hi: #333230;
    --map-sea: #0f0f0f;
    --map-edge: #0b0b0b;
    --dim: #ff4d5e;
  }
}
@media screen {
  :root[data-theme="dark"] {
    --bg: #0b0b0b;
    --surface: #161616;
    --surface-2: #1a1a1a;
    --ink: #f3f2f0;
    --muted-strong: #d2cfca;
    --muted: #a6a39e;
    --line: rgba(243, 242, 240, 0.1);
    --line-strong: rgba(243, 242, 240, 0.24);
    --ink-field: #161616;
    --on-ink: #f3f2f0;
    --on-ink-muted: #aeaba6;
    --accent: #ff4d5e;
    --accent-fill: #d41f37;
    --accent-on-fill: #ffffff;
    --accent-text: #ff4d5e;
    --accent-soft: rgba(255, 77, 94, 0.14);
    --field-1: #1a1a1a;
    --field-1-ink: #f3f2f0;
    --field-2: #c81e34;
    --field-2-ink: #ffffff;
    --field-3: #f3f2f0;
    --field-3-ink: #111111;
    --grid: rgba(243, 242, 240, 0.05);
    --grid-strong: rgba(243, 242, 240, 0.1);
    --hatch: rgba(243, 242, 240, 0.3);
    --layer-1: #e9e6e0;
    --layer-2: #b4b1ab;
    --layer-3: #85827d;
    --layer-4: #5c5a57;
    --layer-5: #3d3c3a;
    --subgrade: #262524;
    --terra: #e4283f;
    --terra-ink: #ffffff;
    --map-land: #232322;
    --map-land-hi: #333230;
    --map-sea: #0f0f0f;
    --map-edge: #0b0b0b;
    --dim: #ff4d5e;
  }
  :root[data-theme="light"] { color-scheme: light; }
  :root[data-theme="dark"] { color-scheme: dark; }
}

/* signature: condensed heavy display, mono for labels and figures */
.display, .h2 { font-stretch: var(--stretch-display); text-transform: uppercase; }
.eyebrow, .label, .facts strong { font-family: var(--font-mono); }
.eyebrow, .label { font-weight: 500; }

/* Film hero: the site footage runs under an asphalt sheet in both themes,
   so the hero keeps the dark ink whatever the page theme is. Screen only:
   print resolves the light sheet without the film. */
@media screen {
  .hero-film {
    --bg: #0b0b0b;
    --ink: #f3f2f0;
    --muted-strong: #d2cfca;
    --muted: #a6a39e;
    --line: rgba(243, 242, 240, 0.1);
    --line-strong: rgba(243, 242, 240, 0.3);
    --accent: #ff4d5e;
    --accent-text: #ff4d5e;
    --grid: rgba(243, 242, 240, 0.04);
    --grid-strong: rgba(243, 242, 240, 0.08);
    --hatch: rgba(243, 242, 240, 0.3);
    --dim: #ff4d5e;
    color-scheme: dark;
  }
}
