/* tenuewine.com: Noir with one grey (docs/agent/design-system.md). Colours by role, Inter only,
   sizes in rem so the browser's text size scales everything. Built pages: scripts/site/build.py. */

@font-face { font-family: "Inter"; font-weight: 200; font-display: swap; src: url("/assets/fonts/Inter-ExtraLight.otf") format("opentype"); }
@font-face { font-family: "Inter"; font-weight: 300; font-display: swap; src: url("/assets/fonts/Inter-Light.otf") format("opentype"); }
@font-face { font-family: "Inter"; font-weight: 400; font-display: swap; src: url("/assets/fonts/Inter-Regular.otf") format("opentype"); }
@font-face { font-family: "Inter"; font-weight: 500; font-display: swap; src: url("/assets/fonts/Inter-Medium.otf") format("opentype"); }

:root {
  --background: #0B0B0B;
  --surface: #151515;
  --hairline: #262626;
  --text: #F2F0EC;
  --secondary: #9A9995;
  --accent: #CDB98F;
  --outline: rgba(242, 240, 236, 0.42);   /* control outlines, 3:1 */
  --wine-glow: rgba(110, 22, 42, 0.32);    /* a deep red's glow, capped so grey text keeps 4.5:1 */
  color-scheme: dark;
}

* { box-sizing: border-box; }

html {
  background: var(--background);
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(60rem 36rem at 50% -8rem, var(--wine-glow), transparent 70%),
    var(--background);
  color: var(--text);
  font-family: "Inter", system-ui, -apple-system, sans-serif;
  font-size: 1.0625rem;          /* 17 */
  font-weight: 400;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  font-feature-settings: "cv11", "ss01";
  overflow-x: hidden;
}

.wrap { width: 100%; max-width: 44rem; margin: 0 auto; padding: 0 1.25rem; }

a { color: var(--text); text-decoration: underline; text-decoration-color: var(--outline); text-underline-offset: 0.2em; }
a:hover { text-decoration-color: var(--text); }
a:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }

/* Header: the wordmark once, then three quiet links. */
.top { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 4.5rem; }
.wm {
  display: inline-flex; align-items: center; min-height: 2.75rem;
  font-size: 0.9375rem; font-weight: 300; letter-spacing: 0.32em; line-height: 1;
  color: var(--secondary); text-decoration: none;
}
.wm b { font-weight: 400; color: var(--text); }
nav { display: flex; flex-wrap: wrap; justify-content: flex-end; }
nav a {
  display: inline-flex; align-items: center; min-height: 2.75rem; padding: 0 0.625rem;
  font-size: 0.9375rem; color: var(--secondary); text-decoration: none;
}
nav a:hover, nav a[aria-current="page"] { color: var(--text); }
nav a[aria-current="page"] { text-decoration: underline; text-decoration-color: var(--outline); text-underline-offset: 0.45em; }
nav a:last-child { padding-right: 0; }

/* Front page */
.hero { padding: 4.5rem 0 1rem; }
h1 {
  margin: 0;
  font-weight: 200;
  font-size: clamp(2.75rem, 9vw, 4rem);   /* 44 to 64: the thinnest weight only this big */
  line-height: 1.04;
  letter-spacing: -0.03em;
  text-wrap: balance;
}
.lead { margin: 1.5rem 0 0; max-width: 34rem; font-size: 1.1875rem; color: var(--secondary); }
.lead a { color: var(--text); }
.status {
  display: inline-flex; align-items: center; gap: 0.625rem; margin: 2rem 0 0;
  font-size: 0.75rem; font-weight: 500; letter-spacing: 0.16em; text-transform: uppercase; color: var(--secondary);
}
.status::before { content: ""; width: 0.5rem; height: 0.5rem; border-radius: 50%; background: var(--accent); }

.arc { margin: 3.5rem auto 2.5rem; max-width: 26rem; }
.arc svg { display: block; width: 100%; height: auto; overflow: visible; }
.arc .life { fill: none; stroke: var(--secondary); stroke-opacity: 0.55; stroke-width: 1.5; }
.arc .ticks { fill: none; stroke: var(--secondary); stroke-opacity: 0.5; stroke-width: 1; }
.arc .gold { fill: none; stroke: var(--accent); stroke-width: 7; stroke-linecap: butt; }
.arc .gold-glow { fill: none; stroke: var(--accent); stroke-opacity: 0.45; stroke-width: 9; }
.arc .now { fill: var(--text); }
.arc text { font-family: "Inter", system-ui, sans-serif; fill: var(--text); }
.arc .arc-label { font-size: 9px; font-weight: 500; letter-spacing: 1.8px; fill: var(--secondary); }
.arc .arc-year { font-size: 38px; font-weight: 200; letter-spacing: -1px; }
.arc .arc-until { font-size: 11px; fill: var(--secondary); }

.rows { list-style: none; margin: 0; padding: 0; }
.rows li { padding: 1.75rem 0; border-top: 1px solid var(--hairline); }
.rows li:last-child { border-bottom: 1px solid var(--hairline); }
.rows h2 { margin: 0; font-size: 1.375rem; font-weight: 300; line-height: 1.3; }
.rows p { margin: 0.5rem 0 0; color: var(--secondary); }

/* Text pages: help and the privacy policy */
.doc { padding: 3.5rem 0 0; }
.doc h1 { font-size: clamp(2.125rem, 7vw, 2.75rem); }   /* 34 to 44 */
.doc h2 { margin: 3rem 0 0.75rem; font-size: 1.375rem; font-weight: 300; line-height: 1.3; }
.doc p, .doc li { max-width: 38rem; }
.doc p { margin: 0 0 1rem; }
.doc ul { margin: 0 0 1rem; padding-left: 1.25rem; }
.doc li { margin: 0 0 0.5rem; }
.doc li::marker { color: var(--secondary); }
.doc strong { font-weight: 500; }
.policy h1 + p { margin-top: 1rem; color: var(--secondary); font-size: 0.9375rem; }

table { width: 100%; margin: 0.5rem 0 1.5rem; border-collapse: collapse; font-size: 0.9375rem; }
th {
  text-align: left; vertical-align: bottom; padding: 0 1rem 0.625rem 0;
  font-size: 0.75rem; font-weight: 500; letter-spacing: 0.12em; text-transform: uppercase; color: var(--secondary);
  border-bottom: 1px solid var(--hairline);
}
td { vertical-align: top; padding: 0.875rem 1rem 0.875rem 0; border-bottom: 1px solid var(--hairline); }
td:first-child { font-weight: 500; }

mark.todo { background: rgba(205, 185, 143, 0.16); color: var(--accent); border-radius: 4px; padding: 0 0.25em; }
.draft {
  margin: 2rem 0 0; padding: 0.875rem 1.125rem;
  border: 1px solid var(--accent); border-radius: 14px; color: var(--accent); font-size: 0.9375rem;
}

footer.wrap { margin-top: 6rem; padding-bottom: 3rem; color: var(--secondary); font-size: 0.9375rem; }
.foot { padding-top: 2rem; border-top: 1px solid var(--hairline); }
footer p { margin: 0 0 0.5rem; }
footer .fine { margin-top: 1.25rem; }
footer a { display: inline-block; padding: 0.625rem 0; margin: -0.625rem 0; }   /* 44pt tall targets in a line of text */

/* Phones: tables become one block per row, each cell under its column's name. */
@media (max-width: 40rem) {
  .hero { padding-top: 3rem; }
  table, thead, tbody, tr, td { display: block; }
  thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  tr { padding: 1rem 0; border-bottom: 1px solid var(--hairline); }
  td { padding: 0.25rem 0; border: 0; }
  td::before {
    content: attr(data-label); display: block;
    font-size: 0.75rem; font-weight: 500; letter-spacing: 0.12em; text-transform: uppercase; color: var(--secondary);
  }
}

@media (prefers-reduced-motion: reduce) { * { scroll-behavior: auto; } }
