/* ─────────────────────────────────────────────────────────────────
   TRION Advisory · Design System
   ───────────────────────────────────────────────────────────────── */

:root {
  --bg:             #F7F5F0;   /* milky warm white */
  --bg-elev:        #FFFFFF;   /* cards, panels */
  --bg-muted:       #EFECE3;   /* alternating section */
  --text:           #1A1A1A;   /* primary type */
  --text-muted:     #5A5A55;   /* secondary type */
  --text-subtle:    #8A877F;   /* tertiary type, labels */
  --accent:         #0B2545;   /* deep oxford, links and CTA */
  --accent-hover:   #13315C;
  --hairline:       #E3DFD2;
  --hairline-strong:#CDC8B7;
  --max:            1200px;
}

* { box-sizing: border-box; }

html { background: var(--bg); -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }

body {
  margin: 0;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  font-weight: 400;
  font-size: 16px;
  line-height: 1.55;
  color: var(--text);
  background: var(--bg);
  font-feature-settings: 'cv11', 'ss01';
}

::selection { background: var(--accent); color: var(--bg); }

img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; }

/* ── Typography ─────────────────────────────────────────────────── */

.serif { font-family: 'Source Serif 4', 'Source Serif Pro', Georgia, serif; }

.h-display {
  font-family: 'Source Serif 4', Georgia, serif;
  font-weight: 400;
  font-size: clamp(2.5rem, 5.5vw, 4.75rem);
  line-height: 1.04;
  letter-spacing: -0.018em;
  color: var(--text);
}

.h-section {
  font-family: 'Source Serif 4', Georgia, serif;
  font-weight: 400;
  font-size: clamp(1.875rem, 3.6vw, 2.75rem);
  line-height: 1.08;
  letter-spacing: -0.015em;
  color: var(--text);
}

.h-sub {
  font-family: 'Source Serif 4', Georgia, serif;
  font-weight: 500;
  font-size: 1.375rem;
  line-height: 1.25;
  letter-spacing: -0.005em;
  color: var(--text);
}

.eyebrow {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-subtle);
}

.lead {
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--text-muted);
  font-weight: 400;
}

.body-sm { font-size: 0.9375rem; line-height: 1.6; color: var(--text-muted); }
.body-xs { font-size: 0.8125rem; line-height: 1.55; color: var(--text-subtle); }

/* ── Layout primitives ──────────────────────────────────────────── */

.container { max-width: var(--max); margin: 0 auto; padding: 0 1.5rem; }
@media (min-width: 768px) { .container { padding: 0 2.5rem; } }

.section { padding: 6rem 0; }
@media (min-width: 1024px) { .section { padding: 8rem 0; } }
.section-tight { padding: 4rem 0; }

.hairline { border: 0; height: 1px; background: var(--hairline); margin: 0; }

/* ── Navigation ─────────────────────────────────────────────────── */

.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 50;
  background: rgba(247, 245, 240, 0.88);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color 240ms ease, background 240ms ease;
}
.nav.scrolled {
  border-bottom-color: var(--hairline);
  background: rgba(247, 245, 240, 0.96);
}
.nav-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 1.1rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
}
@media (min-width: 768px) { .nav-inner { padding: 1.1rem 2.5rem; } }

.brand {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  font-size: 0.9375rem;
  font-weight: 600;
  letter-spacing: -0.005em;
  color: var(--text);
}
.brand img { height: 22px; width: 22px; }
.brand-divider { color: var(--hairline-strong); margin: 0 0.1rem; }
.brand-mark { font-family: 'Source Serif 4', Georgia, serif; font-weight: 500; font-size: 1.05rem; letter-spacing: 0.01em; }

.nav-links {
  display: none;
  align-items: center;
  gap: 2.25rem;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-muted);
}
@media (min-width: 900px) { .nav-links { display: flex; } }
.nav-links a { transition: color 180ms; }
.nav-links a:hover { color: var(--text); }
.nav-links a.active { color: var(--text); }

/* ── Buttons ────────────────────────────────────────────────────── */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.005em;
  padding: 0.8rem 1.35rem;
  transition: all 200ms ease;
  white-space: nowrap;
}
.btn-primary { background: var(--accent); color: var(--bg); }
.btn-primary:hover { background: var(--accent-hover); }
.btn-ghost { color: var(--text); border: 1px solid var(--hairline-strong); background: transparent; }
.btn-ghost:hover { border-color: var(--text); background: var(--bg-elev); }
.btn-text { color: var(--text); padding: 0; border-bottom: 1px solid var(--hairline-strong); transition: border-color 200ms; padding-bottom: 2px; }
.btn-text:hover { border-bottom-color: var(--accent); }
.btn .arrow { transition: transform 240ms ease; }
.btn:hover .arrow { transform: translateX(2px); }

/* ── Cards / Tiles ──────────────────────────────────────────────── */

.tile {
  display: block;
  padding: 2.25rem 0 2rem;
  border-top: 1px solid var(--hairline);
  transition: border-color 240ms ease;
}
.tile:hover { border-top-color: var(--text); }
.tile-num { font-size: 11px; letter-spacing: 0.2em; color: var(--text-subtle); font-weight: 500; }
.tile-title { margin-top: 0.875rem; font-family: 'Source Serif 4', Georgia, serif; font-weight: 400; font-size: 1.75rem; line-height: 1.15; letter-spacing: -0.012em; color: var(--text); }
.tile-body { margin-top: 0.875rem; font-size: 0.9375rem; line-height: 1.6; color: var(--text-muted); max-width: 36rem; }
.tile-cta { margin-top: 1.25rem; display: inline-flex; align-items: center; gap: 0.4rem; font-size: 13px; font-weight: 500; color: var(--text); border-bottom: 1px solid transparent; padding-bottom: 1px; transition: border-color 240ms; }
.tile:hover .tile-cta { border-bottom-color: var(--text); }

.panel {
  background: var(--bg-elev);
  border: 1px solid var(--hairline);
  padding: 2rem;
}

/* ── Insight card ───────────────────────────────────────────────── */

.insight {
  display: block;
  padding: 2rem 0;
  border-top: 1px solid var(--hairline);
  transition: border-color 240ms;
}
.insight:hover { border-top-color: var(--text); }
.insight-meta { font-size: 11px; letter-spacing: 0.18em; text-transform: uppercase; color: var(--text-subtle); font-weight: 500; }
.insight-title { margin-top: 0.75rem; font-family: 'Source Serif 4', Georgia, serif; font-weight: 400; font-size: 1.5rem; line-height: 1.2; letter-spacing: -0.01em; color: var(--text); }
.insight-abstract { margin-top: 0.75rem; font-size: 0.9375rem; line-height: 1.6; color: var(--text-muted); max-width: 38rem; }
.insight-byline { margin-top: 1rem; font-size: 12px; color: var(--text-subtle); }

/* ── Reveal on scroll ───────────────────────────────────────────── */

.reveal { opacity: 0; transform: translateY(10px); transition: opacity 900ms cubic-bezier(0.16,1,0.3,1), transform 900ms cubic-bezier(0.16,1,0.3,1); }
.reveal.in { opacity: 1; transform: none; }
.reveal-1 { transition-delay: 60ms; }
.reveal-2 { transition-delay: 120ms; }
.reveal-3 { transition-delay: 180ms; }

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  * { animation: none !important; transition: none !important; }
}

/* ── Footer ─────────────────────────────────────────────────────── */

.footer { background: var(--bg-muted); border-top: 1px solid var(--hairline); padding: 5rem 0 2.5rem; }
.footer-grid { display: grid; gap: 3rem; grid-template-columns: 1fr; }
@media (min-width: 768px) { .footer-grid { grid-template-columns: 1.6fr repeat(3, 1fr); gap: 2.5rem; } }
.footer h4 { font-size: 11px; font-weight: 600; letter-spacing: 0.2em; text-transform: uppercase; color: var(--text-subtle); margin: 0 0 1.25rem; }
.footer ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 0.65rem; }
.footer ul a { font-size: 14px; color: var(--text-muted); transition: color 180ms; }
.footer ul a:hover { color: var(--text); }
.footer-bar { margin-top: 4rem; padding-top: 1.75rem; border-top: 1px solid var(--hairline); display: flex; flex-direction: column; gap: 1rem; justify-content: space-between; align-items: flex-start; font-size: 12.5px; color: var(--text-subtle); }
@media (min-width: 768px) { .footer-bar { flex-direction: row; align-items: center; } }
.footer-meta { display: flex; gap: 1.5rem; }
.footer-meta a { color: var(--text-muted); transition: color 180ms; }
.footer-meta a:hover { color: var(--text); }

/* ── Forms ──────────────────────────────────────────────────────── */

label { display: block; font-size: 11px; font-weight: 600; letter-spacing: 0.16em; text-transform: uppercase; color: var(--text-subtle); margin-bottom: 0.5rem; }
input, select, textarea {
  width: 100%;
  font: inherit;
  font-size: 15px;
  color: var(--text);
  background: var(--bg-elev);
  border: 1px solid var(--hairline-strong);
  padding: 0.75rem 0.9rem;
  border-radius: 0;
  transition: border-color 180ms, box-shadow 180ms;
}
input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(11, 37, 69, 0.08);
}
textarea { resize: vertical; min-height: 120px; }

/* ── Utility ────────────────────────────────────────────────────── */

.grid { display: grid; gap: 2.5rem; }
.grid-2 { grid-template-columns: 1fr; }
.grid-3 { grid-template-columns: 1fr; }
.grid-4 { grid-template-columns: 1fr; }
@media (min-width: 768px) {
  .grid-2 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(3, 1fr); }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 1024px) {
  .grid-4 { grid-template-columns: repeat(4, 1fr); }
}

.split { display: grid; gap: 3rem; grid-template-columns: 1fr; }
@media (min-width: 900px) { .split { grid-template-columns: 1fr 2fr; gap: 4rem; } }
.split-even { display: grid; gap: 3rem; grid-template-columns: 1fr; }
@media (min-width: 900px) { .split-even { grid-template-columns: 1fr 1fr; gap: 4rem; } }

.industries-strip { display: flex; flex-wrap: wrap; gap: 2.5rem; row-gap: 0.875rem; font-family: 'Source Serif 4', Georgia, serif; font-weight: 400; font-size: 1.05rem; color: var(--text); }
.industries-strip span { color: var(--hairline-strong); }

.pull-quote { font-family: 'Source Serif 4', Georgia, serif; font-weight: 400; font-size: clamp(1.5rem, 2.6vw, 2.1rem); line-height: 1.3; letter-spacing: -0.008em; color: var(--text); max-width: 48rem; }
.pull-byline { margin-top: 1.5rem; font-size: 12px; letter-spacing: 0.18em; text-transform: uppercase; color: var(--text-subtle); font-weight: 500; }

section { scroll-margin-top: 80px; }

/* ─────────────────────────────────────────────────────────────────
   Article / reading layout
   ───────────────────────────────────────────────────────────────── */

.article-header { padding: 9rem 0 4rem; }
.article-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 0.75rem; font-size: 11px; font-weight: 600; letter-spacing: 0.2em; text-transform: uppercase; color: var(--text-subtle); }
.article-meta .dot { color: var(--hairline-strong); }
.article-meta a { color: var(--text-subtle); transition: color 180ms; }
.article-meta a:hover { color: var(--text); }

.article-title {
  font-family: 'Source Serif 4', Georgia, serif;
  font-weight: 400;
  font-size: clamp(2.25rem, 4.8vw, 4rem);
  line-height: 1.06;
  letter-spacing: -0.018em;
  color: var(--text);
  margin: 1.5rem 0 0;
  max-width: 24ch;
}

.article-dek {
  font-family: 'Source Serif 4', Georgia, serif;
  font-style: italic;
  font-weight: 400;
  font-size: clamp(1.25rem, 2vw, 1.625rem);
  line-height: 1.4;
  color: var(--text-muted);
  margin: 2rem 0 0;
  max-width: 44rem;
}

.article-byline { margin-top: 2.5rem; padding-top: 1.5rem; border-top: 1px solid var(--hairline); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1rem; font-size: 13px; color: var(--text-muted); }
.article-byline strong { color: var(--text); font-weight: 500; }

.article-body { max-width: 40rem; margin: 0 auto; padding: 4rem 0 6rem; }
.article-body p, .article-body ul, .article-body ol, .article-body blockquote { font-size: 1.0625rem; line-height: 1.7; color: var(--text); margin: 0 0 1.5rem; }
.article-body h2 {
  font-family: 'Source Serif 4', Georgia, serif;
  font-weight: 500;
  font-size: 1.625rem;
  line-height: 1.2;
  letter-spacing: -0.012em;
  margin: 3.5rem 0 1.25rem;
  color: var(--text);
}
.article-body h3 {
  font-family: 'Inter', system-ui, sans-serif;
  font-weight: 600;
  font-size: 1rem;
  line-height: 1.4;
  letter-spacing: -0.005em;
  margin: 2.25rem 0 0.75rem;
  color: var(--text);
}
.article-body ul, .article-body ol { padding-left: 1.25rem; }
.article-body li { margin-bottom: 0.5rem; }
.article-body a { color: var(--text); border-bottom: 1px solid var(--hairline-strong); transition: border-color 200ms; }
.article-body a:hover { border-bottom-color: var(--accent); }
.article-body em { font-family: 'Source Serif 4', Georgia, serif; font-style: italic; }
.article-body strong { font-weight: 600; color: var(--text); }

.article-body blockquote {
  font-family: 'Source Serif 4', Georgia, serif;
  font-style: italic;
  font-weight: 400;
  font-size: 1.5rem;
  line-height: 1.4;
  color: var(--text);
  border-left: 2px solid var(--accent);
  padding: 0.25rem 0 0.25rem 1.5rem;
  margin: 2.5rem 0;
  max-width: 36rem;
}

.article-body .footnotes { margin-top: 3.5rem; padding-top: 1.5rem; border-top: 1px solid var(--hairline); font-size: 0.875rem; color: var(--text-muted); }
.article-body .footnotes p { font-size: 0.875rem; line-height: 1.55; margin: 0 0 0.6rem; }

.article-aside {
  border-top: 1px solid var(--hairline);
  border-bottom: 1px solid var(--hairline);
  margin: 2.5rem 0;
  padding: 1.5rem 0;
  font-size: 0.9375rem;
  color: var(--text-muted);
  line-height: 1.6;
}
.article-aside .label { display: block; font-size: 11px; font-weight: 600; letter-spacing: 0.18em; text-transform: uppercase; color: var(--text-subtle); margin-bottom: 0.4rem; }

/* ── Conversion block ─────────────────────────────────────────── */

.conversion {
  background: var(--accent);
  color: var(--bg);
  padding: 4rem 0;
}
.conversion .container > div { max-width: 40rem; margin: 0 auto; }
.conversion .eyebrow { color: rgba(247, 245, 240, 0.55); }
.conversion h3 {
  font-family: 'Source Serif 4', Georgia, serif;
  font-weight: 400;
  font-size: clamp(1.75rem, 3vw, 2.25rem);
  line-height: 1.15;
  letter-spacing: -0.012em;
  color: var(--bg);
  margin: 1rem 0 1.25rem;
}
.conversion p { font-size: 1.0625rem; line-height: 1.6; color: rgba(247, 245, 240, 0.85); margin: 0 0 1rem; }
.conversion .btn-primary { background: var(--bg); color: var(--accent); margin-top: 1.5rem; }
.conversion .btn-primary:hover { background: white; }
.conversion .btn-ghost { color: var(--bg); border-color: rgba(247, 245, 240, 0.3); background: transparent; }
.conversion .btn-ghost:hover { border-color: var(--bg); background: rgba(247, 245, 240, 0.05); }

/* ── Related insights ─────────────────────────────────────────── */

.related-grid { display: grid; gap: 2rem; grid-template-columns: 1fr; }
@media (min-width: 768px) { .related-grid { grid-template-columns: 1fr 1fr; } }

.related-card { display: block; padding: 2rem 0; border-top: 1px solid var(--hairline); transition: border-color 240ms; }
.related-card:hover { border-top-color: var(--text); }
.related-card .meta { font-size: 11px; letter-spacing: 0.18em; text-transform: uppercase; color: var(--text-subtle); font-weight: 500; }
.related-card .title { margin-top: 0.75rem; font-family: 'Source Serif 4', Georgia, serif; font-weight: 400; font-size: 1.375rem; line-height: 1.22; letter-spacing: -0.008em; color: var(--text); }
.related-card .cue { margin-top: 1rem; display: inline-flex; align-items: center; gap: 0.4rem; font-size: 12.5px; font-weight: 500; color: var(--text); border-bottom: 1px solid transparent; padding-bottom: 1px; transition: border-color 240ms; }
.related-card:hover .cue { border-bottom-color: var(--text); }
