/* ==========================================================================
   Cenex pages: shared stylesheet
   Mirrors cenex.au/css/styles.css (tokens, nav, page header, section
   headers, cards, footer) so these pages can be dropped into the live site.
   On cenex.au itself, use the site's own styles.css and keep only the
   component rules marked "NEW" below (tables, callouts, steps, bars).
   ========================================================================== */

/* ---------- 1. Tokens (values taken from cenex.au :root) ---------- */
:root {
  --accent: #2bcbba;          /* cenex.au --color-accent */
  --accent-dark: #24a89b;     /* --color-accent-dark */
  --accent-light: #5fd9cd;    /* --color-accent-light */
  --accent-glow: rgba(43, 203, 186, 0.3);
  --accent-ink: #177e74;      /* NEW: teal for small text and links on white (4.5:1+) */
  --amber: #b7790e;           /* Cenex v4 brand amber: used for P90 */
  --brick: #b0453a;           /* risk events (shared with Quantik) */

  --bg: #ffffff;
  --bg-alt: #f5f5f5;          /* --color-gray-100 */
  --surface: #ffffff;
  --ink: #0a0a0a;             /* --text-primary (cenex.au uses #000) */
  --body: #5c5c5c;            /* --text-body (#666 on cenex.au) */
  --muted: #737373;
  --line: #e5e5e5;            /* --color-gray-200 */
  --line-soft: rgba(0, 0, 0, 0.06);
  --nav-bg: rgba(255, 255, 255, 0.95);
  --card-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  --card-shadow-hover: 0 8px 24px rgba(0, 0, 0, 0.12), 0 0 20px var(--accent-glow);

  --dark-900: #0a0a0a;        /* page header and footer surface */
  --dark-800: #1a1a1a;

  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --container: 1280px;
  --pad-y: clamp(3rem, 8vw, 6rem);
  --pad-x: clamp(1rem, 4vw, 2.5rem);
  --radius-lg: 0.75rem;
  --radius-xl: 1rem;
  --radius-2xl: 1.5rem;
  --ease: 280ms cubic-bezier(0.4, 0, 0.2, 1);
  color-scheme: light;
}

/* Dark: follow the OS unless the page is forced light, and honour data-theme="dark" */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0a0a0a; --bg-alt: #121212; --surface: #161616;
    --ink: #ffffff; --body: #b5b5b5; --muted: #8f8f8f;
    --line: #2a2a2a; --line-soft: rgba(255, 255, 255, 0.06);
    --nav-bg: rgba(10, 10, 10, 0.92);
    --accent-ink: #5fd9cd; --amber: #e0a63a; --brick: #e07a6e;
    --card-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
    --card-shadow-hover: 0 8px 24px rgba(0, 0, 0, 0.5), 0 0 20px rgba(43, 203, 186, 0.2);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0a0a0a; --bg-alt: #121212; --surface: #161616;
  --ink: #ffffff; --body: #b5b5b5; --muted: #8f8f8f;
  --line: #2a2a2a; --line-soft: rgba(255, 255, 255, 0.06);
  --nav-bg: rgba(10, 10, 10, 0.92);
  --accent-ink: #5fd9cd; --amber: #e0a63a; --brick: #e07a6e;
  --card-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
  --card-shadow-hover: 0 8px 24px rgba(0, 0, 0, 0.5), 0 0 20px rgba(43, 203, 186, 0.2);
  color-scheme: dark;
}

/* ---------- 2. Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 6rem; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 1rem;
  line-height: 1.65;
  color: var(--body);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img, svg { max-width: 100%; height: auto; }
a { color: var(--accent-ink); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4 { color: var(--ink); margin: 0; line-height: 1.15; }
p { margin: 0 0 1rem; }
strong { color: var(--ink); font-weight: 600; }
code { font-family: 'JetBrains Mono', Consolas, monospace; font-size: 0.875em; background: var(--bg-alt); border: 1px solid var(--line); border-radius: 4px; padding: 0.05em 0.35em; }
.container { max-width: var(--container); margin: 0 auto; padding: 0 var(--pad-x); }
.container--narrow { max-width: 960px; }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 1rem; top: 1rem; z-index: 2000; background: var(--accent); color: #000; padding: 0.5rem 1rem; border-radius: 6px; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* ---------- 3. Navigation (cenex.au .nav) ---------- */
.nav {
  position: fixed; inset: 0 0 auto 0; z-index: 1000;
  background: var(--nav-bg);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.nav__container {
  display: flex; align-items: center; justify-content: space-between;
  height: 5rem; max-width: var(--container); margin: 0 auto; padding: 0 var(--pad-x);
}
.nav__logo img { display: block; height: 28px; width: auto; }
.nav__logo-dark { display: none !important; }
:root[data-theme="dark"] .nav__logo-light { display: none !important; }
:root[data-theme="dark"] .nav__logo-dark { display: block !important; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .nav__logo-light { display: none !important; }
  :root:not([data-theme="light"]) .nav__logo-dark { display: block !important; }
}
.nav__menu { display: flex; align-items: center; gap: 2rem; }
.nav__link {
  font-size: 0.875rem; font-weight: 600; letter-spacing: 0.02em;
  color: var(--body); padding: 0.5rem 0; position: relative; background: none; border: 0; font-family: inherit; cursor: pointer;
}
.nav__link:hover { color: var(--ink); text-decoration: none; }
.nav__link--active { color: var(--ink); }
.nav__link--active::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: var(--accent); }
.nav__dropdown { position: relative; }
.nav__dropdown-menu {
  position: absolute; top: 100%; left: -1rem; min-width: 14rem; padding: 0.5rem;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.12);
  opacity: 0; visibility: hidden; transform: translateY(6px); transition: all 200ms ease;
}
.nav__dropdown:hover .nav__dropdown-menu, .nav__dropdown:focus-within .nav__dropdown-menu { opacity: 1; visibility: visible; transform: none; }
.nav__dropdown-link { display: block; padding: 0.55rem 0.75rem; border-radius: 6px; font-size: 0.875rem; color: var(--body); }
.nav__dropdown-link:hover { background: var(--bg-alt); color: var(--ink); text-decoration: none; }
.nav__dropdown-link small { display: block; color: var(--muted); font-size: 0.75rem; }
.theme-toggle {
  width: 2.25rem; height: 2.25rem; display: inline-grid; place-items: center;
  border: 1px solid var(--line); border-radius: 0.6rem; background: var(--surface); color: var(--ink); cursor: pointer;
}
.theme-toggle svg { width: 18px; height: 18px; }
.theme-toggle .sun { display: none; }
:root[data-theme="dark"] .theme-toggle .sun { display: block; }
:root[data-theme="dark"] .theme-toggle .moon { display: none; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme-toggle .sun { display: block; }
  :root:not([data-theme="light"]) .theme-toggle .moon { display: none; }
}
.nav__toggle { display: none; width: 2.5rem; height: 2.5rem; border: 0; background: none; cursor: pointer; padding: 0.5rem; }
.nav__toggle span { display: block; height: 2px; background: var(--ink); margin: 5px 0; border-radius: 2px; }

@media (max-width: 960px) {
  .nav__toggle { display: block; }
  .nav__menu {
    position: absolute; top: 100%; left: 0; right: 0; height: calc(100vh - 5rem); height: calc(100dvh - 5rem); /* absolute: .nav's backdrop-filter makes it the containing block */
    flex-direction: column; align-items: stretch; gap: 0;
    padding: 1rem var(--pad-x) 2rem; background: var(--bg); overflow-y: auto;
    display: none;
  }
  .nav--open .nav__menu { display: flex; }
  .nav__link { display: block; padding: 0.9rem 0; border-bottom: 1px solid var(--line); font-size: 1rem; }
  .nav__link--active::after { display: none; }
  .nav__dropdown-menu { position: static; opacity: 1; visibility: visible; transform: none; box-shadow: none; border: 0; padding: 0 0 0.5rem 1rem; background: none; }
  .theme-toggle { margin-top: 1rem; }
}

/* ---------- 4. Page header (cenex.au .page-header, always dark) ---------- */
.page-header {
  position: relative; overflow: hidden;
  padding: calc(5rem + clamp(3rem, 8vw, 5rem)) 0 clamp(3rem, 8vw, 5rem);
  background: var(--dark-900); color: #fff;
  border-bottom: 1px solid #1f1f1f;
}
.page-header::before { /* faint grid, as on cenex.au risk header */
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image: linear-gradient(rgba(255,255,255,0.035) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,0.035) 1px, transparent 1px);
  background-size: 48px 48px;
  -webkit-mask-image: linear-gradient(180deg, transparent, #000 30%, #000 70%, transparent);
  mask-image: linear-gradient(180deg, transparent, #000 30%, #000 70%, transparent);
}
.page-header .container { position: relative; }
.breadcrumb { font-size: 0.8125rem; font-weight: 500; color: #a3a3a3; margin-bottom: 2rem; }
.breadcrumb a { color: #a3a3a3; }
.breadcrumb a:hover { color: #fff; }
.breadcrumb__sep { margin: 0 0.4rem; }
.breadcrumb__current { color: var(--accent); }
.eyebrow {
  display: inline-flex; align-items: center; gap: 0.75rem;
  font-size: 0.75rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.22em;
  color: var(--accent-ink); margin-bottom: 1.25rem;
}
.eyebrow::before { content: ""; width: 2.5rem; height: 1px; background: currentColor; }
.page-header .eyebrow { color: var(--accent); margin-bottom: 1.5rem; }
.page-header__title { font-size: clamp(2.4rem, 5.5vw, 4.5rem); font-weight: 800; letter-spacing: -0.03em; line-height: 1.05; color: #fff; margin-bottom: 1.5rem; }
.page-header__description { font-size: clamp(1.05rem, 1.5vw, 1.2rem); color: #c4c4c4; max-width: 46rem; margin: 0; }
.page-header__meta { margin-top: 2rem; display: flex; flex-wrap: wrap; gap: 0.75rem; }
.chip { display: inline-flex; align-items: center; gap: 0.4rem; font-size: 0.8125rem; font-weight: 600; color: #e5e5e5; border: 1px solid #2f2f2f; background: #141414; border-radius: 999px; padding: 0.35rem 0.85rem; }
.chip::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }

/* S-curve strip in the header (NEW, static SVG) */
.header-strip { position: relative; margin-top: 3rem; border-top: 1px solid #1f1f1f; padding-top: 1.25rem; }
.header-strip svg { display: block; width: 100%; height: 120px; }
.header-strip__labels { display: flex; justify-content: space-between; font-size: 0.75rem; font-weight: 600; color: #8f8f8f; letter-spacing: 0.08em; text-transform: uppercase; }

/* ---------- 5. Sections ---------- */
.section { padding: var(--pad-y) 0; }
.section--alt { background: var(--bg-alt); }
.section-header { max-width: 52rem; margin-bottom: 3rem; }
.section-header--center { text-align: center; margin-left: auto; margin-right: auto; }
.section-header--center .eyebrow::after { content: ""; width: 2.5rem; height: 1px; background: currentColor; }
.section-header__title { font-size: clamp(1.9rem, 3.8vw, 3rem); font-weight: 800; letter-spacing: -0.025em; line-height: 1.1; margin-bottom: 1.25rem; }
.section-header__description { font-size: clamp(1.0625rem, 1.5vw, 1.125rem); margin: 0; }
.lede { font-size: 1.125rem; }
.prose { max-width: 52rem; }
.prose h3 { font-size: 1.35rem; font-weight: 700; margin: 2.25rem 0 0.75rem; letter-spacing: -0.01em; }
.prose ul, .prose ol { padding-left: 1.25rem; margin: 0 0 1.25rem; }
.prose li { margin-bottom: 0.4rem; }
.num { font-variant-numeric: tabular-nums; white-space: nowrap; }

/* ---------- 6. Cards (cenex.au .service-card look) ---------- */
.grid { display: grid; gap: 1.5rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); }
.grid--2 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); }
.card {
  position: relative; overflow: hidden;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-2xl);
  padding: 2rem; box-shadow: var(--card-shadow);
  transition: transform var(--ease), box-shadow var(--ease), border-color var(--ease);
}
a.card { display: block; color: inherit; }
a.card:hover, .card--hover:hover { transform: translateY(-6px); box-shadow: var(--card-shadow-hover); border-color: rgba(43, 203, 186, 0.45); text-decoration: none; }
.card::after { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 3px; background: linear-gradient(90deg, var(--accent), var(--accent-dark)); transform: scaleX(0); transform-origin: left; transition: transform var(--ease); }
a.card:hover::after, .card--hover:hover::after { transform: scaleX(1); }
.card__num { display: block; font-size: 0.8125rem; font-weight: 700; color: var(--accent-ink); letter-spacing: 0.08em; margin-bottom: 0.75rem; }
.card__title { font-size: 1.2rem; font-weight: 700; margin-bottom: 0.6rem; letter-spacing: -0.01em; }
.card p:last-child { margin-bottom: 0; }
.card__more { display: inline-block; margin-top: 1rem; font-size: 0.875rem; font-weight: 600; color: var(--accent-ink); }
.card--dark { background: var(--dark-900); border-color: #222; color: #c4c4c4; }
.card--dark .card__title, .card--dark strong { color: #fff; }

/* ---------- 7. Tables (NEW; cenex v4 report style: dark head, teal rule) ---------- */
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; margin: 1.5rem 0 2rem; border: 1px solid var(--line); border-radius: var(--radius-xl); background: var(--surface); }
table { width: 100%; border-collapse: collapse; font-size: 0.9375rem; }
caption { caption-side: bottom; text-align: left; font-size: 0.8125rem; color: var(--muted); padding: 0.75rem 1rem; }
thead th { background: var(--dark-900); color: #fff; font-size: 0.75rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; text-align: left; padding: 0.85rem 1rem; border-bottom: 2px solid var(--accent); vertical-align: bottom; }
:root[data-theme="dark"] thead th { background: #1c1c1c; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) thead th { background: #1c1c1c; } }
tbody th, tbody td { padding: 0.8rem 1rem; border-top: 1px solid var(--line); text-align: left; vertical-align: top; }
tbody th { color: var(--ink); font-weight: 600; }
tbody tr:nth-child(even) { background: var(--line-soft); }
td.r, th.r { text-align: right; }
.tag { display: inline-block; font-size: 0.75rem; font-weight: 700; padding: 0.1rem 0.5rem; border-radius: 999px; border: 1px solid var(--line); color: var(--body); white-space: nowrap; }
.tag--p90 { color: var(--amber); border-color: currentColor; }
.tag--teal { color: var(--accent-ink); border-color: currentColor; }

/* ---------- 8. Callouts and checks (NEW) ---------- */
.callout { border-left: 3px solid var(--accent); background: var(--bg-alt); border-radius: 0 var(--radius-lg) var(--radius-lg) 0; padding: 1.1rem 1.25rem; margin: 1.5rem 0; }
.section--alt .callout { background: var(--surface); }
.callout p:last-child { margin: 0; }
.callout__title { display: block; font-size: 0.75rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.14em; color: var(--accent-ink); margin-bottom: 0.4rem; }
.callout--warn { border-left-color: var(--amber); }
.callout--warn .callout__title { color: var(--amber); }
.formula { font-family: 'JetBrains Mono', Consolas, monospace; font-size: 0.95rem; color: var(--ink); background: var(--bg-alt); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 1rem 1.25rem; margin: 1.25rem 0; overflow-x: auto; white-space: pre; }
.check { display: inline-block; font-size: 0.75rem; font-weight: 700; color: var(--amber); background: rgba(183, 121, 14, 0.1); border-radius: 4px; padding: 0 0.35rem; white-space: nowrap; }
.placeholder { outline: 2px dashed var(--amber); outline-offset: 3px; }

/* ---------- 9. Stats, bars and steps (NEW) ---------- */
.stats { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr)); margin: 2rem 0; }
.stat { border: 1px solid var(--line); border-radius: var(--radius-xl); padding: 1.25rem; background: var(--surface); }
.stat__label { display: block; font-size: 0.75rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.12em; color: var(--muted); }
.stat__value { display: block; font-size: 1.75rem; font-weight: 800; color: var(--ink); letter-spacing: -0.02em; margin: 0.25rem 0; font-variant-numeric: tabular-nums; }
.stat__note { font-size: 0.8125rem; color: var(--muted); }
.stat--p90 .stat__value { color: var(--amber); }
.stat--teal .stat__value { color: var(--accent-ink); }

.bars { margin: 1.5rem 0; display: grid; gap: 0.6rem; }
.bar { display: grid; grid-template-columns: minmax(7rem, 10rem) 1fr; align-items: center; gap: 0.75rem; font-size: 0.875rem; }
.bar__label { color: var(--ink); font-weight: 600; }
.bar__track { position: relative; height: 1.9rem; background: var(--bg-alt); border-radius: 6px; overflow: hidden; }
.section--alt .bar__track { background: var(--surface); border: 1px solid var(--line); }
.bar__fill { height: 100%; background: linear-gradient(90deg, var(--accent-dark), var(--accent)); border-radius: 6px; display: flex; align-items: center; justify-content: flex-end; padding-right: 0.5rem; font-size: 0.8125rem; font-weight: 700; color: #04211e; white-space: nowrap; }
.bar__fill--p90 { background: linear-gradient(90deg, #a06a0c, #d8982a); color: #1f1400; }
.bar__fill--muted { background: #9a9a9a; color: #111; }
@media (max-width: 520px) { .bar { grid-template-columns: 1fr; gap: 0.3rem; } }

.steps { counter-reset: step; display: grid; gap: 1.25rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 230px), 1fr)); }
.step { position: relative; border-top: 2px solid var(--accent); padding-top: 1.25rem; }
.step::before { counter-increment: step; content: "0" counter(step); display: block; font-size: 0.8125rem; font-weight: 800; color: var(--accent-ink); letter-spacing: 0.1em; margin-bottom: 0.5rem; }
.step h3 { font-size: 1.1rem; font-weight: 700; margin-bottom: 0.5rem; }
.step p { font-size: 0.9375rem; margin: 0; }

.toc { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 0; padding: 0; list-style: none; }
.toc a { display: inline-block; font-size: 0.8125rem; font-weight: 600; color: var(--body); border: 1px solid var(--line); border-radius: 999px; padding: 0.35rem 0.85rem; background: var(--surface); }
.toc a:hover { color: var(--ink); border-color: var(--accent); text-decoration: none; }
.toc-bar { border-bottom: 1px solid var(--line); background: var(--bg); padding: 1.25rem 0; }

details.faq { border-top: 1px solid var(--line); padding: 1.1rem 0; }
details.faq:last-of-type { border-bottom: 1px solid var(--line); }
details.faq summary { cursor: pointer; font-weight: 700; color: var(--ink); font-size: 1.05rem; list-style: none; display: flex; justify-content: space-between; gap: 1rem; }
details.faq summary::-webkit-details-marker { display: none; }
details.faq summary::after { content: "+"; color: var(--accent-ink); font-weight: 400; font-size: 1.4rem; line-height: 1; }
details.faq[open] summary::after { content: "−"; }
details.faq p { margin: 0.75rem 0 0; }

/* ---------- 10. Buttons and CTA (cenex.au .btn) ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem; padding: 1rem 2rem; font-size: 1rem; font-weight: 600; line-height: 1; border: 2px solid transparent; border-radius: var(--radius-lg); cursor: pointer; transition: all 200ms ease; white-space: nowrap; font-family: inherit; }
.btn:hover { text-decoration: none; transform: translateY(-2px); }
.btn--primary { background: var(--accent); border-color: var(--accent); color: #000; }
.btn--primary:hover { box-shadow: 0 8px 24px rgba(43, 203, 186, 0.25); }
.btn--ghost { border-color: currentColor; color: var(--ink); background: transparent; }
.page-header .btn--ghost, .cta .btn--ghost { color: #fff; }
.btn-row { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 2rem; }
@media (max-width: 420px) { .btn { white-space: normal; width: 100%; } }

.cta { background: var(--dark-900); color: #c4c4c4; text-align: center; padding: var(--pad-y) 0; position: relative; overflow: hidden; }
.cta::before { content: ""; position: absolute; left: 50%; top: -40%; width: 60rem; height: 60rem; transform: translateX(-50%); background: radial-gradient(circle, rgba(43, 203, 186, 0.14), transparent 60%); pointer-events: none; }
.cta .container { position: relative; }
.cta h2 { color: #fff; font-size: clamp(1.8rem, 3.5vw, 2.6rem); font-weight: 800; letter-spacing: -0.02em; margin-bottom: 1rem; }
.cta p { max-width: 40rem; margin: 0 auto; }
.cta .btn-row { justify-content: center; }

/* Product hand-off band (NEW: used where Cenex points to the Synthetik product site) */
.product-band { display: grid; grid-template-columns: auto 1fr auto; gap: 1.5rem; align-items: center; border: 1px solid var(--line); border-radius: var(--radius-2xl); padding: 1.5rem 2rem; background: var(--surface); }
.product-band img { height: 40px; width: auto; display: block; }
.product-band__dark { display: none; }
:root[data-theme="dark"] .product-band__light { display: none; }
:root[data-theme="dark"] .product-band__dark { display: block; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .product-band__light { display: none; }
  :root:not([data-theme="light"]) .product-band__dark { display: block; }
}
.product-band p { margin: 0; font-size: 0.9375rem; }
@media (max-width: 760px) { .product-band { grid-template-columns: 1fr; padding: 1.5rem; } }

/* ---------- 11. Footer (cenex.au .footer) ---------- */
.footer { background: var(--dark-900); color: rgba(255, 255, 255, 0.6); padding-top: 5rem; border-top: 1px solid #1f1f1f; }
.footer__grid { display: grid; grid-template-columns: 2fr repeat(4, 1fr); gap: 2.5rem; padding-bottom: 4rem; border-bottom: 1px solid rgba(255, 255, 255, 0.08); }
.footer__brand img { height: 28px; width: auto; margin-bottom: 1.25rem; }
.footer__brand p { font-size: 0.875rem; max-width: 22rem; }
.footer__title { color: #fff; font-size: 0.875rem; font-weight: 700; margin-bottom: 1rem; letter-spacing: 0.02em; }
.footer__links { display: grid; gap: 0.6rem; }
.footer__links a { font-size: 0.875rem; color: rgba(255, 255, 255, 0.6); }
.footer__links a:hover { color: var(--accent); text-decoration: none; }
.footer__bottom { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 1rem 1.5rem; padding: 1.5rem 0; font-size: 0.8125rem; }
.footer__bottom a { color: rgba(255, 255, 255, 0.6); }
.footer__family { display: flex; flex-wrap: wrap; gap: 0.5rem 1.25rem; align-items: center; }
.footer__family span { color: rgba(255, 255, 255, 0.4); }
@media (max-width: 1024px) { .footer__grid { grid-template-columns: 1fr 1fr; } .footer__brand { grid-column: 1 / -1; } }
@media (max-width: 520px) { .footer__grid { grid-template-columns: 1fr; } }

/* ---------- 12. Draft banner (remove on publish) ---------- */
.draft-banner { position: fixed; left: 0; right: 0; bottom: 0; z-index: 1001; background: #d8982a; color: #1f1400; font-size: 0.8125rem; font-weight: 600; text-align: center; padding: 0.4rem var(--pad-x); }
body { padding-bottom: 2rem; }

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition: none !important; animation: none !important; } }
@media print { .nav, .footer, .cta, .draft-banner, .toc-bar { display: none; } .page-header { padding-top: 2rem; } }

/* Wide tables scroll sideways inside their frame on phones instead of squashing */
@media (max-width: 760px) {
  .table-wrap--wide table { min-width: 720px; }
  .table-wrap table th[scope="row"] { white-space: nowrap; }
}
