/* PayoutMath design tokens
   Aesthetic: utilitarian/editorial — Bloomberg terminal meets GOV.UK Design System.
   Trust through restraint. No web fonts. Monospace for numbers. */

:root {
  /* Colours */
  --bg: #FAFAF7;
  --surface: #FFFFFF;
  --ink: #1A1A1A;
  --ink-2: #5A5A5A;
  --ink-3: #8A8A85;
  --accent: #2D5A3D;
  --accent-tint: #E8EFE9;
  --accent-strong: #1F4029;
  --positive: #1B5E2A;
  --negative: #A02020;
  --warn: #B8860B;
  --rule: #E5E5E0;
  --rule-strong: #1A1A1A;

  /* Type stacks — system only, no web fonts */
  --font-body: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;

  /* Sizes */
  --fs-xs: 0.8125rem;   /* 13px */
  --fs-sm: 0.9375rem;   /* 15px */
  --fs-base: 1rem;      /* 16px */
  --fs-md: 1.125rem;    /* 18px */
  --fs-lg: 1.375rem;    /* 22px */
  --fs-xl: 1.75rem;     /* 28px */
  --fs-xxl: 2.25rem;    /* 36px */

  /* Spacing — 8px base */
  --s-1: 0.25rem;
  --s-2: 0.5rem;
  --s-3: 0.75rem;
  --s-4: 1rem;
  --s-5: 1.5rem;
  --s-6: 2rem;
  --s-7: 3rem;
  --s-8: 4rem;

  /* Layout */
  --content-w: 44rem;   /* 704px — calc-tool comfortable max */
  --wide-w: 60rem;      /* hub home etc */
}

/* Reset */
*, *::before, *::after {
  box-sizing: border-box;
}
html, body, h1, h2, h3, h4, p, ul, ol, dl, figure, blockquote {
  margin: 0;
  padding: 0;
}
html {
  font-size: 100%;
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}
body {
  font-family: var(--font-body);
  font-size: var(--fs-base);
  line-height: 1.55;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* Layout primitives */
.wrap {
  max-width: var(--content-w);
  margin-inline: auto;
  padding-inline: var(--s-4);
}
.wrap-wide {
  max-width: var(--wide-w);
  margin-inline: auto;
  padding-inline: var(--s-4);
}

/* Typography */
h1, h2, h3, h4 {
  line-height: 1.2;
  letter-spacing: -0.01em;
  font-weight: 700;
}
h1 {
  font-size: var(--fs-xxl);
  letter-spacing: -0.02em;
}
h2 {
  font-size: var(--fs-xl);
  margin-top: var(--s-7);
  margin-bottom: var(--s-4);
}
h3 {
  font-size: var(--fs-lg);
  margin-top: var(--s-5);
  margin-bottom: var(--s-3);
}
h4 {
  font-size: var(--fs-md);
  margin-top: var(--s-4);
  margin-bottom: var(--s-2);
}
p {
  margin-bottom: var(--s-4);
  max-width: 38rem;
}
a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 2px;
  text-decoration-thickness: 1px;
}
a:hover {
  color: var(--accent-strong);
  text-decoration-thickness: 2px;
}
a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 1px;
}

/* Numbers — the character of the site */
.num, code, kbd, samp, pre {
  font-family: var(--font-mono);
  font-feature-settings: "tnum" 1, "zero" 1;
}
.num {
  font-variant-numeric: tabular-nums;
}
.num--pos { color: var(--positive); }
.num--neg { color: var(--negative); }

/* Header */
.site-header {
  border-bottom: 1px solid var(--rule);
  background: var(--surface);
}
.site-header__inner {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--s-4);
  padding-block: var(--s-4);
}
.site-header__brand {
  font-weight: 800;
  font-size: var(--fs-md);
  letter-spacing: -0.02em;
  color: var(--ink);
  text-decoration: none;
}
.site-header__brand::before {
  content: "£";
  color: var(--accent);
  margin-right: 0.15em;
  font-family: var(--font-mono);
}
.site-header__nav {
  display: flex;
  gap: var(--s-4);
  font-size: var(--fs-sm);
}
.site-header__nav a {
  color: var(--ink-2);
  text-decoration: none;
}
.site-header__nav a:hover { color: var(--accent); }

/* Hero / page intro */
.hero {
  padding-block: var(--s-7) var(--s-5);
}
.hero__eyebrow {
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-bottom: var(--s-2);
}
.hero__lede {
  font-size: var(--fs-md);
  color: var(--ink-2);
  max-width: 38rem;
  margin-top: var(--s-3);
}

/* Trust line — last verified, source URL */
.trust-line {
  margin-top: var(--s-4);
  padding: var(--s-3) var(--s-4);
  background: var(--accent-tint);
  border-left: 3px solid var(--accent);
  font-size: var(--fs-sm);
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-2) var(--s-4);
}
.trust-line__label {
  color: var(--ink-2);
}
.trust-line__value {
  font-family: var(--font-mono);
  color: var(--ink);
}

/* Calc form */
.calc {
  margin-block: var(--s-6);
  padding: var(--s-5);
  background: var(--surface);
  border: 1px solid var(--rule);
}
.calc__legend {
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-3);
  padding: 0 var(--s-2);
  margin-left: -var(--s-2);
}
.field {
  margin-block: var(--s-4);
}
.field__label {
  display: block;
  font-weight: 600;
  margin-bottom: var(--s-1);
  font-size: var(--fs-sm);
}
.field__help {
  font-size: var(--fs-xs);
  color: var(--ink-2);
  margin-bottom: var(--s-2);
}
.field__input,
.field__select {
  width: 100%;
  padding: var(--s-3);
  font-size: var(--fs-base);
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  border: 1px solid var(--rule-strong);
  background: var(--bg);
  color: var(--ink);
  border-radius: 0;
  -webkit-appearance: none;
  appearance: none;
}
.field__input:focus,
.field__select:focus {
  outline: 2px solid var(--accent);
  outline-offset: 0;
  border-color: var(--accent);
}
.field__select {
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'><path d='M1 1l5 5 5-5' fill='none' stroke='%231A1A1A' stroke-width='1.5'/></svg>");
  background-repeat: no-repeat;
  background-position: right var(--s-3) center;
  background-size: 12px 8px;
  padding-right: var(--s-7);
}
.field__prefix {
  display: flex;
  align-items: stretch;
  border: 1px solid var(--rule-strong);
}
.field__prefix-symbol {
  display: flex;
  align-items: center;
  padding: 0 var(--s-3);
  background: var(--bg);
  border-right: 1px solid var(--rule);
  font-family: var(--font-mono);
  color: var(--ink-2);
}
.field__prefix .field__input {
  border: 0;
  flex: 1;
}
.field__prefix:focus-within {
  outline: 2px solid var(--accent);
  outline-offset: 0;
}
.field--toggle {
  display: flex;
  align-items: center;
  gap: var(--s-3);
}
.field--toggle .field__label {
  margin: 0;
  flex: 1;
}

/* Result block */
.result {
  margin-block: var(--s-5);
  padding: var(--s-5);
  background: var(--ink);
  color: #FAFAF7;
  font-family: var(--font-mono);
}
.result__row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding-block: var(--s-2);
  border-bottom: 1px solid #2A2A2A;
  gap: var(--s-3);
}
.result__row:last-child {
  border-bottom: 0;
}
.result__row--total {
  margin-top: var(--s-2);
  padding-top: var(--s-3);
  border-top: 2px solid #FAFAF7;
  border-bottom: 0;
  font-size: var(--fs-md);
  font-weight: 700;
}
.result__label {
  color: #BBBBB5;
  font-size: var(--fs-sm);
}
.result__row--total .result__label {
  color: #FAFAF7;
}
.result__value {
  font-variant-numeric: tabular-nums;
  text-align: right;
}
.result__value--pos { color: #6FCF87; }
.result__value--neg { color: #FF7A7A; }

/* Section break */
.rule {
  border: 0;
  border-top: 1px solid var(--rule);
  margin-block: var(--s-6);
}

/* FAQs */
.faq {
  border-top: 1px solid var(--rule);
  padding-block: var(--s-4);
}
.faq__q {
  font-weight: 700;
  font-size: var(--fs-md);
  margin-bottom: var(--s-2);
  cursor: pointer;
  list-style: none;
}
.faq__q::-webkit-details-marker { display: none; }
.faq__q::before {
  content: "+";
  font-family: var(--font-mono);
  color: var(--accent);
  margin-right: var(--s-2);
  display: inline-block;
  width: 1ch;
}
details[open] > .faq__q::before {
  content: "−";
}
.faq__a { color: var(--ink-2); }

/* Worked example */
.example {
  background: var(--accent-tint);
  border-left: 3px solid var(--accent);
  padding: var(--s-4) var(--s-5);
  margin-block: var(--s-5);
}
.example__title {
  font-weight: 700;
  margin-bottom: var(--s-2);
}
.example__inputs {
  font-family: var(--font-mono);
  font-size: var(--fs-sm);
  color: var(--ink-2);
  margin-bottom: var(--s-3);
}

/* Common mistakes / limitations callout */
.callout {
  border: 1px solid var(--rule-strong);
  padding: var(--s-4);
  margin-block: var(--s-5);
}
.callout__title {
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: var(--s-2);
}
.callout--mistakes .callout__title { color: var(--negative); }
.callout--limits .callout__title { color: var(--ink-2); }

/* Related calcs */
.related {
  border-top: 2px solid var(--rule-strong);
  padding-top: var(--s-5);
  margin-top: var(--s-7);
}
.related__list {
  list-style: none;
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--s-3);
}
@media (min-width: 36rem) {
  .related__list { grid-template-columns: 1fr 1fr; }
}
.related__item {
  border: 1px solid var(--rule);
  padding: var(--s-3) var(--s-4);
  background: var(--surface);
}
.related__item a {
  text-decoration: none;
  font-weight: 600;
  color: var(--ink);
}
.related__item a:hover { color: var(--accent); }
.related__item p {
  font-size: var(--fs-sm);
  color: var(--ink-2);
  margin: 0;
  margin-top: var(--s-1);
}

/* Footer */
.site-footer {
  margin-top: var(--s-8);
  border-top: 1px solid var(--rule);
  background: var(--surface);
}
.site-footer__inner {
  padding-block: var(--s-6);
  display: grid;
  gap: var(--s-5);
}
@media (min-width: 36rem) {
  .site-footer__inner { grid-template-columns: 2fr 1fr 1fr; }
}
.site-footer h3 {
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: var(--s-2);
  color: var(--ink-3);
}
.site-footer ul { list-style: none; }
.site-footer li { padding-block: var(--s-1); font-size: var(--fs-sm); }
.site-footer__legal {
  border-top: 1px solid var(--rule);
  padding-block: var(--s-4);
  font-size: var(--fs-xs);
  color: var(--ink-3);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: var(--s-3);
}

/* Author byline */
.byline {
  margin-top: var(--s-5);
  padding: var(--s-4);
  background: var(--bg);
  border: 1px dashed var(--rule);
  font-size: var(--fs-sm);
  color: var(--ink-2);
}

/* Print */
@media print {
  .site-header__nav, .site-footer, .related, .calc__submit { display: none; }
  body { background: white; color: black; }
  .result { background: white; color: black; border: 2px solid black; }
  .result__label { color: #333; }
  a { color: black; text-decoration: underline; }
  .trust-line { background: white; border-color: black; }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
  }
  html { scroll-behavior: auto; }
}

/* Skip link */
.skip-link {
  position: absolute;
  top: -100px;
  left: 0;
  background: var(--ink);
  color: var(--bg);
  padding: var(--s-3);
  z-index: 100;
}
.skip-link:focus { top: 0; }

/* ============================================================
   Utility classes — replaces inline style="..." attributes
   added during Phase 4 audit cleanup. Lets the build run with
   strict CSP (no 'unsafe-inline' for styles).
   ============================================================ */

/* Typography utilities */
.t-meta      { color: var(--ink-3); font-size: var(--fs-xs); }
.t-secondary { color: var(--ink-2); font-size: var(--fs-sm); max-width: 32rem; }
.t-caption   { font-size: var(--fs-xs); color: var(--ink-3); }
.t-mono-meta { font-family: var(--font-mono); font-size: var(--fs-xs); color: var(--ink-3); margin-top: var(--s-3); }
.t-mono-label {
  font-family: var(--font-mono); font-size: var(--fs-xs);
  letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-3);
}
.t-lede      { font-size: var(--fs-lg); max-width: 36rem; }

/* Layout utilities */
.fieldset-reset { border: 0; padding: 0; }
.checkbox-large { width: 1.25rem; height: 1.25rem; }
.list-bulleted  { padding-left: var(--s-5); }
.list-bulleted li { margin-bottom: var(--s-2); }

/* Notice block (used by noscript / inline notes) */
.notice {
  background: var(--accent-tint);
  padding: var(--s-3);
  margin-top: var(--s-4);
  font-size: var(--fs-sm);
  border-radius: 4px;
}

/* Hero (homepage) */
.hero { padding-block: var(--s-8) var(--s-6); }
.hero h1 { font-size: clamp(2.25rem, 5vw, 3.25rem); max-width: 22ch; }
.hero__highlight { color: var(--accent); font-family: var(--font-mono); }

/* Hub search bar wrapper */
.hub-search { margin-block: var(--s-6); position: relative; }
.hub-search__input {
  font-family: var(--font-body);
  font-size: var(--fs-md);
  padding: var(--s-4);
}

/* Affiliate disclosure aside */
.affiliate {
  margin-top: var(--s-6);
  padding: var(--s-4);
  border: 1px solid var(--rule);
  background: var(--surface);
}
.affiliate__disclosure {
  color: var(--ink-3);
  display: block;
  margin-bottom: var(--s-2);
}

/* Section headings inside cards */
.card-h2 { margin-top: 0; }

/* Hub page section classes */
.hub-search input {
  font-family: var(--font-body);
  font-size: var(--fs-md);
  padding: var(--s-4);
}
.hub-section { margin-block: var(--s-7); }
.hub-section__h2 {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--s-3);
  margin-top: 0;
}
.hub-section__count {
  font-family: var(--font-mono);
  font-size: var(--fs-sm);
  color: var(--ink-3);
  font-weight: 400;
}
.hub-section__description {
  color: var(--ink-2);
  max-width: 40rem;
  margin-bottom: var(--s-4);
}
.list-unstyled { list-style: none; padding-left: 0; }

/* Trust line — homepage manifesto block */
.trust-line {
  margin-block: var(--s-8);
  padding: var(--s-6);
  border: 2px solid var(--rule-strong);
  background: var(--surface);
}
.trust-line__h2 { margin-top: var(--s-2); }
.trust-line__grid {
  display: grid;
  gap: var(--s-5);
  grid-template-columns: 1fr;
  margin-top: var(--s-4);
}
@media (min-width: 700px) {
  .trust-line__grid { grid-template-columns: repeat(3, 1fr); }
}
.trust-line__h3 {
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: var(--s-2);
}
.trust-line__p { margin: 0; color: var(--ink-2); }

/* Contact page email display */
.contact-email {
  font-family: var(--font-mono);
  font-size: var(--fs-lg);
  margin-block: var(--s-5);
}

/* ─────────────────────────────────────────────
   Glossary page
   ───────────────────────────────────────────── */
.glossary-list { margin-top: var(--s-6); }

.glossary-letter {
  border-top: 1px solid var(--border);
  padding-top: var(--s-5);
  margin-top: var(--s-6);
}
.glossary-letter:first-child {
  border-top: none;
  padding-top: 0;
  margin-top: 0;
}

.glossary-letter__heading {
  font-family: var(--font-mono);
  font-size: var(--fs-2xl);
  font-weight: 700;
  color: var(--accent);
  letter-spacing: -0.02em;
  margin: 0 0 var(--s-4) 0;
}

.glossary-term {
  padding: var(--s-4) 0;
  border-bottom: 1px solid var(--border);
}
.glossary-term:last-child { border-bottom: none; }

.glossary-term h3 {
  font-size: var(--fs-lg);
  font-weight: 700;
  color: var(--ink);
  margin: 0 0 var(--s-2) 0;
}

.glossary-term__short {
  font-weight: 600;
  color: var(--ink);
  margin: 0 0 var(--s-2) 0;
}

.glossary-term p {
  color: var(--ink-2);
  margin: 0 0 var(--s-2) 0;
  line-height: 1.6;
}

.glossary-term .t-caption a {
  color: var(--accent);
}

/* ─────────────────────────────────────────────
   Glossary auto-link styling
   ───────────────────────────────────────────── */
.glossary-link {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px dotted var(--accent);
  cursor: help;
}
.glossary-link:hover {
  color: var(--accent);
  border-bottom-style: solid;
}

/* ─────────────────────────────────────────────
   Amazon Associates affiliate panel
   ───────────────────────────────────────────── */
.affiliate-picks {
  margin: 3rem auto 1rem;
  padding: 1.5rem 1.25rem;
  background: var(--accent-tint);
  border-left: 3px solid var(--accent);
  border-radius: 6px;
  max-width: 100%;
}
.affiliate-picks__heading {
  margin: 0 0 0.5rem;
  font-size: 1.25rem;
  color: var(--accent-strong);
}
.affiliate-picks__intro {
  margin: 0 0 1rem;
  font-size: 0.95rem;
  line-height: 1.5;
  color: var(--accent-strong);
}
.affiliate-picks__list {
  list-style: none;
  padding: 0;
  margin: 0 0 1rem;
  display: grid;
  gap: 0.75rem;
}
.affiliate-picks__item {
  background: var(--surface);
  border-radius: 4px;
  padding: 0.75rem 1rem;
  border: 1px solid rgba(45,90,61,0.15);
}
.affiliate-picks__item a {
  display: block;
  color: var(--accent-strong);
  text-decoration: none;
}
.affiliate-picks__item a:hover {
  color: var(--accent);
}
.affiliate-picks__item-title {
  display: block;
  font-weight: 600;
  font-size: 1rem;
  margin-bottom: 0.15rem;
}
.affiliate-picks__item-title::after {
  content: " ↗";
  font-size: 0.8em;
  opacity: 0.7;
}
.affiliate-picks__item-desc {
  display: block;
  font-size: 0.875rem;
  line-height: 1.45;
  color: #555;
}
.affiliate-picks__disclosure {
  font-size: 0.8rem;
  color: #666;
  margin: 0;
  font-style: italic;
}
.affiliate-picks__disclosure a {
  color: inherit;
  text-decoration: underline;
}
@media (min-width: 720px) {
  .affiliate-picks__list {
    grid-template-columns: repeat(2, 1fr);
  }
}


/* ═══════════════════════════════════════════════════════════════════
   PAYOUTMATH UK — NAVY / ORANGE RESKIN
   Appended to tokens.eadd3f8f.css — overrides original green theme.
   Inspired by 247QuickTools visual style: dark navy + orange accent.
   ═══════════════════════════════════════════════════════════════════ */

/* ── 1. COLOUR TOKENS ─────────────────────────────────────────────── */
:root {
  /* Navy/orange palette replacing forest green */
  --accent:        #E8630A;   /* orange — CTAs, links, accents */
  --accent-tint:   #FEF3EC;   /* pale orange tint for panels */
  --accent-strong: #C0500A;   /* darker orange for hover */

  --navy:          #0F1B2D;   /* deep navy — header, footer, hero */
  --navy-mid:      #162236;   /* slightly lighter navy for hover states */
  --navy-card:     #1A2B40;   /* card headers on homepage */
  --navy-border:   #263548;   /* border on dark surfaces */

  --bg:            #F4F6FA;   /* page background — cool off-white */
  --surface:       #FFFFFF;   /* cards, panels */
  --ink:           #0F1B2D;   /* primary text (navy) */
  --ink-2:         #4A5568;   /* secondary text */
  --ink-3:         #8A9AB0;   /* tertiary / placeholder */
  --rule:          #DDE3EC;   /* subtle dividers */
  --rule-strong:   #0F1B2D;   /* strong dividers */
  --positive:      #1A7A3C;
  --negative:      #C0392B;
  --warn:          #B8730A;
}

/* ── 2. GLOBAL BODY ───────────────────────────────────────────────── */
body {
  background: var(--bg);
  color: var(--ink);
}

/* ── 3. HEADER ────────────────────────────────────────────────────── */
.site-header {
  background: var(--navy);
  border-bottom: none;
  box-shadow: 0 2px 8px rgba(0,0,0,0.25);
}

.site-header__brand {
  color: #FFFFFF;
  font-weight: 700;
  font-size: 1.25rem;
  text-decoration: none;
  letter-spacing: -0.01em;
}
.site-header__brand:hover {
  color: var(--accent);
}

/* Subtle orange dot / accent on brand name */
.site-header__brand::before {
  content: "";
  display: inline-block;
  width: 8px;
  height: 8px;
  background: var(--accent);
  border-radius: 50%;
  margin-right: 6px;
  vertical-align: middle;
  position: relative;
  top: -1px;
}

.site-header__nav a {
  color: #BDC8D8;
  font-size: 0.9375rem;
  text-decoration: none;
  transition: color 0.15s;
}
.site-header__nav a:hover {
  color: #FFFFFF;
}

/* ── 4. SKIP LINK ─────────────────────────────────────────────────── */
.skip-link:focus {
  background: var(--accent);
  color: #fff;
  outline: none;
}

/* ── 5. HERO ──────────────────────────────────────────────────────── */
.hero {
  background: var(--navy);
  color: #FFFFFF;
  padding-block: 3rem 2.5rem;
  margin-bottom: 0;
}

/* Homepage hero gets extra breathing room */
.wrap-wide > .hero {
  margin-inline: calc(-1 * var(--s-4));
  padding-inline: var(--s-4);
  margin-bottom: var(--s-6);
}

.hero__eyebrow {
  color: var(--accent);
  opacity: 1;
}

.hero h1,
.hero .hero__highlight {
  color: #FFFFFF;
}

.hero__highlight {
  color: var(--accent);
}

.hero__lede {
  color: #BDC8D8;
}

/* Trust line inside hero */
.hero .trust-line {
  background: rgba(255,255,255,0.06);
  border-left-color: var(--accent);
  color: #BDC8D8;
}

/* ── 6. CALC FORM ─────────────────────────────────────────────────── */
.calc {
  background: var(--surface);
  border: 1px solid var(--rule);
  border-top: 3px solid var(--accent);
  box-shadow: 0 2px 12px rgba(15,27,45,0.08);
}

.calc__legend {
  color: var(--accent);
}

.field__input,
.field__select {
  background: #FAFBFD;
  border-color: var(--rule);
  color: var(--ink);
}

.field__input:focus,
.field__select:focus {
  outline-color: var(--accent);
  border-color: var(--accent);
}

.field__prefix-symbol {
  background: #F4F6FA;
  border-right-color: var(--rule);
  color: var(--ink-2);
}

/* Checkbox styling */
.checkbox-large {
  accent-color: var(--accent);
}

/* ── 7. RESULT PANEL ──────────────────────────────────────────────── */
.result {
  background: var(--navy);
  border-top: 3px solid var(--accent);
}

.result__row {
  border-bottom-color: var(--navy-border);
}

.result__row--total {
  border-top-color: var(--accent);
}

.result__label {
  color: #8A9AB0;
}

/* ── 8. TRUST LINE ────────────────────────────────────────────────── */
.trust-line {
  background: var(--accent-tint);
  border-left-color: var(--accent);
}

.trust-line__label {
  color: var(--ink-2);
}

/* ── 9. HOMEPAGE HUB ──────────────────────────────────────────────── */
/* Section headings */
.hub-section__h2 {
  color: var(--navy);
  border-bottom: 2px solid var(--accent);
  padding-bottom: 0.5rem;
}

.hub-section__count {
  background: var(--accent);
  color: #FFFFFF;
  border-radius: 999px;
  padding: 0.1em 0.6em;
  font-size: 0.8125rem;
}

/* Calculator list items on hub */
.related__item a {
  color: var(--accent-strong);
  font-weight: 600;
}
.related__item a:hover {
  color: var(--accent);
}

/* Hub search */
.hub-search__input:focus {
  outline-color: var(--accent);
  border-color: var(--accent);
}

/* ── 10. RELATED NAV ──────────────────────────────────────────────── */
.related {
  border-top-color: var(--rule);
}

.card-h2 {
  color: var(--navy);
}

/* ── 11. FAQ ──────────────────────────────────────────────────────── */
.faq__q::before {
  color: var(--accent);
}

/* ── 12. EXAMPLE / CALLOUT BLOCKS ─────────────────────────────────── */
.example {
  background: var(--accent-tint);
  border-left-color: var(--accent);
}

.callout {
  border-color: var(--rule);
  border-left: 3px solid var(--accent);
}

/* ── 13. AFFILIATE PANELS ─────────────────────────────────────────── */
.affiliate-picks {
  background: var(--accent-tint);
  border-left-color: var(--accent);
}

.affiliate-picks__heading {
  color: var(--navy);
}

.affiliate-picks__intro {
  color: var(--ink-2);
}

.affiliate-picks__item {
  border-color: rgba(232,99,10,0.15);
}

.affiliate-picks__item a {
  color: var(--navy);
}
.affiliate-picks__item a:hover {
  color: var(--accent);
}

.affiliate-picks__item-title {
  color: var(--accent-strong);
}

.affiliate-picks__disclosure {
  color: var(--ink-3);
}

/* ── 14. FOOTER ───────────────────────────────────────────────────── */
.site-footer {
  background: var(--navy);
  border-top: none;
  color: #BDC8D8;
  margin-top: var(--s-8);
}

.site-footer h3 {
  color: #FFFFFF;
}

.site-footer p {
  color: #8A9AB0;
}

.site-footer a {
  color: #BDC8D8;
}
.site-footer a:hover {
  color: var(--accent);
}

/* ── 15. BUTTONS & COPY BUTTONS ───────────────────────────────────── */
button,
.btn {
  background: var(--accent);
  color: #FFFFFF;
  border: none;
  cursor: pointer;
}
button:hover,
.btn:hover {
  background: var(--accent-strong);
}

/* Result copy button */
.result .copy-btn,
.copy-btn {
  background: var(--accent);
  color: #fff;
  border: none;
}
.copy-btn:hover {
  background: var(--accent-strong);
}

/* ── 16. LINKS ────────────────────────────────────────────────────── */
a {
  color: var(--accent);
}
a:hover {
  color: var(--accent-strong);
}

/* Override: links inside body prose should use navy not orange */
.wrap p a,
.wrap li a,
.wrap h2 a,
section.wrap a {
  color: var(--accent);
  text-decoration: underline;
}
section.wrap a:hover {
  color: var(--accent-strong);
}

/* ── 17. GLOSSARY ─────────────────────────────────────────────────── */
.glossary-link {
  border-bottom-color: var(--accent);
  color: inherit;
}
.glossary-link:hover {
  color: var(--accent);
}

/* ── 18. HERO STAT BAR (homepage) ─────────────────────────────────── */
/* If the homepage has a stats row, style it */
.hero-stats,
.stat-bar {
  background: var(--navy-mid);
  color: #BDC8D8;
  border-top: 1px solid var(--navy-border);
}

/* ── 19. CHANGELOG / TABLE ────────────────────────────────────────── */
table th {
  background: var(--navy);
  color: #FFFFFF;
}
table tr:nth-child(even) {
  background: #F9FAFC;
}

/* ── 20. MOBILE NAV / RESPONSIVE ──────────────────────────────────── */
@media (max-width: 640px) {
  .hero {
    padding-block: 2rem 1.75rem;
  }
  .site-header__brand {
    font-size: 1.125rem;
  }
}


/* ── HERO FULL-BLEED FIX ─────────────────────────────────────────── */
/* Both .wrap > .hero and .wrap-wide > .hero need to break out of
   their container to span full viewport width.
   Technique: negative margins equal to container padding + overflow. */
#main {
  overflow-x: hidden; /* needed for the bleed trick */
}

.wrap > .hero,
.wrap-wide > .hero {
  margin-left: calc(-1 * var(--s-4));
  margin-right: calc(-1 * var(--s-4));
  padding-left: var(--s-4);
  padding-right: var(--s-4);
  /* For narrower .wrap pages, also pull out horizontally */
  margin-top: calc(-1 * var(--s-7));
}

@media (min-width: 44rem) {
  .wrap > .hero {
    margin-left: calc(-50vw + 50%);
    margin-right: calc(-50vw + 50%);
    padding-left: calc(50vw - 50% + var(--s-4));
    padding-right: calc(50vw - 50% + var(--s-4));
  }
}

/* ── 21. SCROLLBAR (optional, Webkit) ─────────────────────────────── */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--navy-border); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--accent); }

/* ── 22. HUB CARD POLISH ─────────────────────────────────────────── */
/* Make homepage calculator cards feel like 247QuickTools' card style */
.related__item {
  border: 1px solid var(--rule);
  border-top: 3px solid transparent;
  background: var(--surface);
  transition: border-color 0.15s, box-shadow 0.15s, transform 0.1s;
  cursor: pointer;
}
.related__item:hover {
  border-top-color: var(--accent);
  box-shadow: 0 4px 16px rgba(15,27,45,0.10);
  transform: translateY(-1px);
}

/* Hub section headings — bigger presence */
.hub-section {
  margin-block: var(--s-6);
}
.hub-section__h2 {
  font-size: 1.125rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-family: var(--font-mono);
  border-bottom-width: 2px;
  margin-bottom: var(--s-4);
  padding-bottom: var(--s-3);
}

/* Hub search — orange focus, bigger feel */
.hub-search__input,
.hub-search input {
  border: 2px solid var(--rule);
  background: var(--surface);
  transition: border-color 0.15s, box-shadow 0.15s;
  box-shadow: 0 2px 8px rgba(15,27,45,0.06);
}
.hub-search__input:focus,
.hub-search input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(232,99,10,0.12);
}

/* ── 23. CALC FORM REFINEMENTS ────────────────────────────────────── */
.calc {
  border-radius: 2px;
}
.field__input,
.field__select {
  border-radius: 2px;
  transition: border-color 0.15s;
}

/* ── 24. RESULT PANEL REFINEMENTS ─────────────────────────────────── */
.result {
  border-radius: 2px;
}

/* ── 25. TRUST LINE COLOURS ON DARK HERO ──────────────────────────── */
.hero .trust-line {
  background: rgba(255,255,255,0.06);
  border-left-color: var(--accent);
}
.hero .trust-line a {
  color: #BDC8D8;
}
.hero .trust-line a:hover {
  color: var(--accent);
}
.hero .trust-line__label {
  color: #8A9AB0;
}
.hero .trust-line__value {
  color: #FFFFFF;
}

/* ── 26. FAQ REFINEMENTS ──────────────────────────────────────────── */
.faq__item {
  border-top: 1px solid var(--rule);
}
.faq__item[open] > .faq__q {
  color: var(--accent-strong);
}

/* ── 27. ABOUT / GUIDE PAGE PROSE ─────────────────────────────────── */
.wrap h2 {
  color: var(--navy);
  border-bottom: 1px solid var(--rule);
  padding-bottom: 0.4rem;
  margin-top: 2rem;
}

/* ── 28. AFFILIATE PANEL BUTTON STYLE ─────────────────────────────── */
.affiliate-picks__item-title::after {
  color: var(--accent);
}

/* ── 29. PRODUCT SNIPPETS / OFFER SCHEMA VISIBLE TREATMENT ────────── */
/* The yellow Product snippets in GSC = price/offer schema on calc pages.
   Style the visible Offer info if shown */
.offer-price {
  color: var(--accent);
  font-weight: 700;
}

/* ── 30. PAGE TRANSITIONS / FOCUS RING ────────────────────────────── */
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* ── 31. AMZ CARD SKIN v3 ──────────────────────────────────────────── */
.amz-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(180px,1fr));gap:14px;margin:20px 0;}
.amz-card{background:linear-gradient(160deg,#fff,#fdf9f2);border:1px solid #f0d9b0;border-radius:12px;padding:14px;display:flex;flex-direction:column;gap:8px;transition:transform .15s,box-shadow .15s,border-color .15s;}
.amz-card:hover{transform:translateY(-3px);border-color:#ff9900;box-shadow:0 8px 20px rgba(255,153,0,.22);}
.amz-badge{align-self:flex-start;background:#232f3e;color:#ff9900;font-weight:700;font-size:.68rem;letter-spacing:.06em;padding:3px 8px;border-radius:4px;}
.amz-title{font-weight:700;line-height:1.3;font-size:.9rem;}
.amz-desc{font-size:.82rem;color:var(--text-secondary,#666);line-height:1.4;}
.amz-cta{margin-top:auto;display:block;text-align:center;font-weight:700;color:#111;background:linear-gradient(180deg,#ffd814,#ff9900);border-radius:8px;padding:10px 12px;text-decoration:none;font-size:.88rem;}
.amz-cta:hover{background:linear-gradient(180deg,#f7ca00,#e8890c);color:#111;}
.amz-inline{color:#b45309;text-decoration:underline;text-decoration-color:#f59e0b;text-underline-offset:2px;font-weight:600;}
.amz-section{margin:28px 0;}
.amz-section-heading{font-size:1rem;font-weight:700;margin-bottom:4px;}
.amz-disclosure-inline{font-size:.75rem;color:var(--text-secondary,#888);margin-bottom:10px;}

/* ── 32. COOKIE CONSENT BANNER ─────────────────────────────────────── */
#cookie-banner{display:none;position:fixed;bottom:0;left:0;right:0;background:#1a1a1a;color:#fff;padding:14px 20px;z-index:9999;font-size:.85rem;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:10px;}
#cookie-banner p{margin:0;max-width:700px;}
#cookie-banner a{color:#ff9900;}
.cookie-btns{display:flex;gap:8px;}
.cookie-btn-accept{background:#ff9900;color:#000;border:none;padding:8px 16px;border-radius:4px;cursor:pointer;font-weight:700;font-size:.85rem;}
.cookie-btn-decline{background:transparent;color:#fff;border:1px solid #fff;padding:8px 16px;border-radius:4px;cursor:pointer;font-size:.85rem;}

/* ── 33. RELATED TOOLS FOOTER SECTION ──────────────────────────────── */
.footer-related{border-top:1px solid rgba(255,255,255,.1);margin-top:24px;padding-top:18px;}
.footer-related h3{font-size:.85rem;text-transform:uppercase;letter-spacing:.06em;opacity:.6;margin-bottom:10px;}
.footer-related ul{list-style:none;margin:0;padding:0;display:flex;flex-wrap:wrap;gap:8px 18px;}
.footer-related ul li a{font-size:.85rem;opacity:.8;}
.footer-related ul li a:hover{opacity:1;}

/* ── 34. PILL STRIP ─────────────────────────────────────────────────── */
.pill-strip{display:flex;flex-wrap:wrap;gap:8px;margin:12px 0 20px;}
.pill-strip a{display:inline-block;padding:5px 12px;border:1px solid #f0d9b0;border-radius:20px;font-size:.8rem;font-weight:600;color:#b45309;text-decoration:none;background:#fdf9f2;}
.pill-strip a:hover{border-color:#ff9900;background:#fff8ed;}
