/* ============================================================================
   Templeton × The Cabinet — design system
   One language across landing, app, and Mai analytics.
   - Brand skin: Templeton oxblood, ink, editorial serif + clean sans
   - Restraint (Apple/Option A): whitespace as the design, one accent, pill buttons,
     flat color, no UI shadows (only imagery + analytics cards get shadow)
   - Analytics (Steep/Option B): 24px soft-shadow data cards, oxblood warm + slate cool
   NOTE: exact oxblood hex + display/body families are confirmed against templetonbc.com;
   the scrape refines these tokens in one place.
   ============================================================================ */

:root {
  /* color — oxblood is the single warm accent; use it as punctuation, never a flood */
  --oxblood: #aa273d;        /* real brand red, sampled from the TBC logo */
  --oxblood-deep: #8c1f30;
  --oxblood-tint: #f7ebed;
  --ink: #161513;            /* text/wordmark — never pure black */
  --canvas: #ffffff;
  --fog: #f7f7f8;            /* warm fog: alternating sections / app chrome */
  --hairline: #e3e1dc;
  --muted: #6b6258;          /* secondary text */
  --slate: #4a6b8a;          /* the one cool accent — data-viz ONLY */
  --slate-tint: #eef2f6;
  --charcoal: #28282a;       /* their dark-section tone */
  --stone: #d5d3c8;          /* their one warm neutral */
  --cream: #f4f2ec;          /* warm canvas drawn from the stone */
  --good: #3f7d5a;
  --warn: #b07a2c;

  /* type */
  /* Their real type is Minerva Modern (serif) + Futura PT (Typekit); these are the
     Google-loadable near-twins, plus Inter for data-dense app/Mai surfaces. */
  --font-display: "Cormorant Garamond", "Spectral", Georgia, "Times New Roman", serif;
  --font-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  --font-eyebrow: "Jost", "Futura", "Century Gothic", var(--font-sans);

  /* spacing scale */
  --s1: 4px; --s2: 8px; --s3: 12px; --s4: 16px; --s5: 24px;
  --s6: 32px; --s7: 48px; --s8: 64px; --s9: 96px; --s10: 128px;

  /* radii — limited: 8px UI, full pill buttons, 24px analytics cards */
  --r-ui: 8px;
  --r-pill: 999px;
  --r-card: 24px;

  /* analytics 3-layer soft shadow */
  --shadow-card: 0 0 0 1px rgba(22,21,19,.06), 0 12px 28px -12px rgba(22,21,19,.18), 0 2px 6px -2px rgba(22,21,19,.10);
  --shadow-img: 0 24px 60px -24px rgba(22,21,19,.45);

  --maxw: 1200px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 17px;
  line-height: 1.5;
  letter-spacing: -0.01em;
  color: var(--ink);
  background: var(--canvas);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; display: block; }
a { color: var(--oxblood); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ---- typography ---------------------------------------------------------- */
.display, h1.display { font-family: var(--font-display); font-weight: 600; line-height: 1.02; }
.h-hero { font-family: var(--font-display); font-weight: 600; font-size: clamp(40px, 7vw, 84px);
          letter-spacing: -0.03em; line-height: 1.0; }
.h1 { font-family: var(--font-display); font-weight: 600; font-size: clamp(32px, 4.5vw, 56px);
      letter-spacing: -0.025em; line-height: 1.05; }
.h2 { font-family: var(--font-display); font-weight: 600; font-size: clamp(24px, 3vw, 36px);
      letter-spacing: -0.02em; }
.eyebrow { font-family: var(--font-eyebrow); font-weight: 500; font-size: 12px; letter-spacing: .22em;
           text-transform: uppercase; color: var(--muted); }
.lead { font-size: clamp(18px, 2vw, 22px); color: var(--muted); line-height: 1.45; }
.muted { color: var(--muted); }
.num { font-family: var(--font-display); font-weight: 600; letter-spacing: -0.02em;
       font-variant-numeric: tabular-nums; }
.mono { font-variant-numeric: tabular-nums; }
.accent { color: var(--oxblood); }

/* ---- buttons (pill) ------------------------------------------------------ */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-family: var(--font-sans); font-weight: 500; font-size: 15px; letter-spacing: -0.01em;
  padding: 13px 24px; border-radius: var(--r-pill); border: 1px solid transparent;
  cursor: pointer; transition: transform .12s ease, background .15s ease, box-shadow .15s ease;
  white-space: nowrap; }
.btn:hover { text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--oxblood); color: #fff; }
.btn-primary:hover { background: var(--oxblood-deep); }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--hairline); }
.btn-ghost:hover { border-color: var(--ink); }
.btn-quiet { background: transparent; color: var(--ink); padding: 12px 8px; }
.btn-lg { padding: 16px 30px; font-size: 16px; }
.btn:disabled { opacity: .5; cursor: not-allowed; }

/* ---- inputs -------------------------------------------------------------- */
.field { display: block; width: 100%; padding: 13px 15px; font-size: 16px; font-family: var(--font-sans);
  color: var(--ink); background: #fff; border: 1px solid var(--hairline); border-radius: var(--r-ui);
  transition: border-color .15s ease, box-shadow .15s ease; }
.field:focus { outline: none; border-color: var(--oxblood); box-shadow: 0 0 0 3px var(--oxblood-tint); }
.label { display: block; font-size: 13px; font-weight: 500; color: var(--muted); margin: 0 0 6px; }

/* ---- layout helpers ------------------------------------------------------ */
.wrap { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }
.section { padding: var(--s9) 0; }
.row { display: flex; gap: var(--s5); }
.col { display: flex; flex-direction: column; }
.between { justify-content: space-between; }
.center { align-items: center; }
.grid { display: grid; gap: var(--s5); }
.hide { display: none !important; }
.divider { height: 1px; background: var(--hairline); border: 0; margin: 0; }

/* ---- cards --------------------------------------------------------------- */
.card { background: #fff; border: 1px solid var(--hairline); border-radius: var(--r-ui); }
.data-card { background: #fff; border-radius: var(--r-card); box-shadow: var(--shadow-card); padding: var(--s6); }

/* ---- pills / badges ------------------------------------------------------ */
.tag { display: inline-flex; align-items: center; gap: 6px; padding: 4px 11px; border-radius: var(--r-pill);
  font-size: 12px; font-weight: 500; letter-spacing: .01em; background: var(--fog); color: var(--muted); }
.tag-co { background: var(--oxblood-tint); color: var(--oxblood-deep); }
.tag-clean { background: #eef5f0; color: var(--good); }
.tag-exception { background: #fbf3e6; color: var(--warn); }

/* ---- brand marks --------------------------------------------------------- */
.cabinet-mark { font-family: var(--font-display); font-size: 12px; letter-spacing: .16em;
  text-transform: uppercase; color: var(--muted); }
.cabinet-mark b { color: var(--ink); font-weight: 600; }

/* ---- confidence meter ---------------------------------------------------- */
.meter { height: 6px; border-radius: 999px; background: var(--hairline); overflow: hidden; }
.meter > span { display: block; height: 100%; background: var(--oxblood); border-radius: 999px; }

@media (max-width: 820px) {
  .row { flex-direction: column; }
  .section { padding: var(--s8) 0; }
}
