/* =========================================================
   Eno Analytics — design system
   Flat, minimalist, academic. Off-white palette.
   ========================================================= */

:root {
  /* Palette */
  --off-white:   #EFEFEF;   /* page background (brand off-white) */
  --paper:       #FAFAFA;   /* raised surfaces / cards */
  --ink:         #1C1C1C;   /* primary text */
  --muted:       #565B57;   /* secondary text */
  --faint:       #8A8A88;   /* captions, meta */
  --line:        #DCDCDA;   /* hairline borders */
  --line-strong: #C9C9C6;
  --accent:      #2F533C;   /* brand green */
  --accent-deep: #24402E;
  --accent-soft: #E5ECE7;   /* accent tint background */

  /* Type */
  --serif: Georgia, "Times New Roman", "Iowan Old Style", serif;
  --sans:  "Helvetica Neue", Arial, system-ui, -apple-system, sans-serif;

  /* Rhythm */
  --maxw: 1080px;
  --gutter: clamp(20px, 5vw, 48px);
  --radius: 2px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--off-white);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* ---------- Layout ---------- */
.container { max-width: var(--maxw); margin: 0 auto; padding: 0 var(--gutter); }
.section { padding: clamp(56px, 9vw, 104px) 0; }
.section--tight { padding: clamp(40px, 6vw, 64px) 0; }
.divider { height: 1px; background: var(--line); border: 0; margin: 0; }

/* ---------- Typography ---------- */
h1, h2, h3, h4 { font-family: var(--serif); font-weight: 600; color: var(--ink); line-height: 1.2; margin: 0 0 .5em; letter-spacing: -0.01em; }
h1 { font-size: clamp(2.1rem, 4.6vw, 3.3rem); }
h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); }
h3 { font-size: 1.25rem; }
h4 { font-size: 1.02rem; }
p { margin: 0 0 1.1em; }
a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-deep); text-decoration: underline; text-underline-offset: 3px; }

.eyebrow {
  font-family: var(--sans);
  font-size: .74rem;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 700;
  margin: 0 0 1rem;
}
.lead { font-size: clamp(1.05rem, 1.6vw, 1.25rem); color: var(--muted); max-width: 62ch; }
.measure { max-width: 68ch; }
.muted { color: var(--muted); }
.faint { color: var(--faint); font-size: .85rem; }

/* ---------- Header / nav ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(247,245,239,0.88);
  backdrop-filter: saturate(140%) blur(8px);
  border-bottom: 1px solid var(--line);
}
.nav { display: flex; align-items: center; justify-content: space-between; height: 68px; }
.brand { display: flex; align-items: center; gap: 12px; font-family: var(--serif); font-size: 1.25rem; font-weight: 600; color: var(--ink); letter-spacing: -0.01em; }
.brand:hover { text-decoration: none; color: var(--ink); }
.brand .mark { width: 26px; height: 26px; flex: 0 0 auto; }
.nav-links { display: flex; gap: 30px; align-items: center; }
.nav-links a { font-family: var(--sans); font-size: .93rem; color: var(--muted); letter-spacing: .01em; }
.nav-links a:hover { color: var(--ink); text-decoration: none; }
.nav-links a.active { color: var(--ink); }
.nav-toggle { display: none; background: none; border: 0; font-size: 1.4rem; cursor: pointer; color: var(--ink); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block; font-family: var(--sans); font-size: .93rem; font-weight: 600;
  padding: 12px 22px; border-radius: var(--radius); border: 1px solid var(--accent);
  background: var(--accent); color: #fff; cursor: pointer; transition: background .15s, border-color .15s;
}
.btn:hover { background: var(--accent-deep); border-color: var(--accent-deep); color: #fff; text-decoration: none; }
.btn--ghost { background: transparent; color: var(--accent); }
.btn--ghost:hover { background: var(--accent-soft); color: var(--accent-deep); }
.btn-row { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 1.6rem; }

/* ---------- Hero ---------- */
.hero { padding: clamp(64px, 11vw, 128px) 0 clamp(48px, 8vw, 88px); }
.hero .eyebrow { animation: none; }
.hero h1 { max-width: 16ch; }
.hero .lead { margin-top: 1.1rem; }

/* ---------- Grid ---------- */
.grid { display: grid; gap: clamp(20px, 3vw, 32px); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }

/* ---------- Cards ---------- */
.card {
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
  padding: clamp(24px, 3vw, 34px); transition: border-color .15s, transform .15s;
}
.card--link:hover { border-color: var(--line-strong); transform: translateY(-2px); }
.card h3 { margin-bottom: .4em; }
.card .kicker { font-size: .72rem; letter-spacing: .16em; text-transform: uppercase; color: var(--accent); font-weight: 700; margin-bottom: .8rem; }
.card p:last-child { margin-bottom: 0; }
.card-num { font-family: var(--serif); font-size: 2.2rem; color: var(--accent); line-height: 1; }

/* Feature list */
.feature-list { list-style: none; padding: 0; margin: 0; }
.feature-list li { padding: 14px 0; border-top: 1px solid var(--line); display: flex; gap: 14px; }
.feature-list li:last-child { border-bottom: 1px solid var(--line); }
.feature-list .n { font-family: var(--serif); color: var(--accent); font-size: .95rem; flex: 0 0 24px; }

/* Split section */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(28px, 5vw, 64px); align-items: start; }
.split--label { grid-template-columns: 220px 1fr; }
.split .label-col .eyebrow { margin-top: .3rem; }

/* Stat band */
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.stat { background: var(--paper); padding: 28px clamp(18px,2.5vw,30px); }
.stat .big { font-family: var(--serif); font-size: clamp(1.9rem, 3.4vw, 2.6rem); color: var(--ink); line-height: 1; }
.stat .cap { font-size: .82rem; color: var(--muted); margin-top: .5rem; }

/* Tint block */
.tint { background: var(--accent-soft); }
.ink-block { background: var(--accent-deep); color: #EAF0EE; }
.ink-block h2, .ink-block h3 { color: #fff; }
.ink-block .lead, .ink-block p { color: #C9D6D2; }
.ink-block a { color: #fff; text-decoration: underline; text-underline-offset: 3px; }
.ink-block .btn { background: #fff; color: var(--accent-deep); border-color: #fff; }
.ink-block .btn:hover { background: #EAF0EE; }

/* ---------- Sample / report styles ---------- */
.report { background: var(--paper); }
.report-header { border-bottom: 2px solid var(--ink); padding-bottom: 1.2rem; margin-bottom: 2rem; }
.report table { width: 100%; border-collapse: collapse; font-size: .92rem; margin: 1.4rem 0; }
.report th, .report td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); }
.report thead th { border-bottom: 2px solid var(--line-strong); font-family: var(--sans); font-size: .74rem; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.report td.num, .report th.num { text-align: right; font-variant-numeric: tabular-nums; }
.report tbody tr:hover { background: var(--off-white); }
figure { margin: 1.8rem 0; }
figcaption { font-size: .82rem; color: var(--faint); margin-top: .6rem; }
.callout { border-left: 3px solid var(--accent); background: var(--accent-soft); padding: 16px 20px; margin: 1.6rem 0; border-radius: 0 var(--radius) var(--radius) 0; }
.callout p:last-child { margin-bottom: 0; }
.tag { display: inline-block; font-size: .72rem; letter-spacing: .08em; text-transform: uppercase; color: var(--accent); background: var(--accent-soft); padding: 3px 10px; border-radius: 20px; font-weight: 700; }

.toc { font-size: .9rem; }
.toc a { color: var(--muted); display: block; padding: 5px 0; border-bottom: 1px solid var(--line); }
.toc a:hover { color: var(--accent); text-decoration: none; }

/* ---------- Contact ---------- */
.field { margin-bottom: 18px; }
.field label { display: block; font-size: .82rem; font-weight: 600; color: var(--muted); margin-bottom: 6px; letter-spacing: .02em; }
.field input, .field textarea, .field select {
  width: 100%; padding: 11px 13px; font-family: var(--sans); font-size: .95rem; color: var(--ink);
  background: var(--paper); border: 1px solid var(--line-strong); border-radius: var(--radius);
}
.field input:focus, .field textarea:focus, .field select:focus { outline: 2px solid var(--accent); outline-offset: 0; border-color: var(--accent); }
.field textarea { min-height: 130px; resize: vertical; }

/* ---------- Footer ---------- */
.site-footer { background: var(--paper); border-top: 1px solid var(--line); padding: 54px 0 40px; margin-top: 0; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 40px; }
.footer-grid h4 { font-family: var(--sans); font-size: .74rem; letter-spacing: .14em; text-transform: uppercase; color: var(--faint); margin-bottom: 1rem; }
.footer-grid a { display: block; color: var(--muted); font-size: .92rem; padding: 4px 0; }
.footer-grid a:hover { color: var(--accent); text-decoration: none; }
.footer-bottom { border-top: 1px solid var(--line); margin-top: 40px; padding-top: 22px; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; font-size: .82rem; color: var(--faint); }

/* ---------- Utilities ---------- */
.center { text-align: center; }
.mt-0 { margin-top: 0; } .mb-0 { margin-bottom: 0; }
.stack > * + * { margin-top: 1rem; }
.badge-row { display: flex; gap: 10px; flex-wrap: wrap; margin: 1.2rem 0; }

/* ---------- Responsive ---------- */
@media (max-width: 860px) {
  .grid-3 { grid-template-columns: 1fr 1fr; }
  .split, .split--label { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 720px) {
  /* Let wide data tables scroll within their own box instead of pushing the page */
  .report table { display: block; width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; white-space: nowrap; }
  .report thead th, .report td { white-space: nowrap; }
}
@media (max-width: 640px) {
  body { font-size: 16px; }
  .nav-links { display: none; }
  .nav-links.open { display: flex; position: absolute; top: 68px; left: 0; right: 0; flex-direction: column; gap: 0; background: var(--off-white); border-bottom: 1px solid var(--line); padding: 8px var(--gutter) 16px; }
  .nav-links.open a { padding: 12px 0; border-bottom: 1px solid var(--line); }
  .nav-toggle { display: block; }
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
  .stats { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
}
