/* LedgerTouch calculators: page and panel styles only.
   Tokens, fonts, masthead and footer come from /site.css, which the
   transparency pages share, so every non-blog page carries one header.

   Colour is the brand's own: navy and blue for pay, the editorial gold for
   tax traps, and a deep green for property and investments. Each group sets
   --tone / --tone-soft / --tone-deep, and everything inside picks them up. */

.tone-blue  { --tone: #365f9f; --tone-soft: #e9f0fa; --tone-deep: #132a60; }
.tone-gold  { --tone: #8f6528; --tone-soft: #f7f0e3; --tone-deep: #5a3e14; }
.tone-green { --tone: #2c6a52; --tone-soft: #e7f3ed; --tone-deep: #17463a; }

/* ── Page frame ── */
.wrap { max-width: calc(var(--page, 1248px) + 2 * var(--gutter, 24px)); margin: 0 auto; padding: 32px var(--gutter, 24px) 72px; }
.crumbs {
  margin: 0 0 18px;
  font-family: var(--sans);
  font-size: 11.2px;
  font-weight: 700;
  letter-spacing: .01em;
  text-transform: none;
  color: var(--ed-mute);
}
.crumbs a { color: inherit; text-decoration: none; }
.crumbs a:hover { color: var(--ed-terra); }
.crumbs span { margin: 0 8px; opacity: .6; }

h1 {
  margin: 0;
  font-size: clamp(30px, 4.2vw, 46px);
  font-weight: 600;
  line-height: 1;
  letter-spacing: -.03em;
}
h2 { margin: 44px 0 12px; font-size: 21.6px; font-weight: 700; letter-spacing: -.02em; line-height: 1.3; }
.wrap > p, .wrap > ul:not(.calc-hub):not(.calc-more) { max-width: 680px; }
/* Body copy matches an article paragraph (Bricolage, 16px, 1.75); the serif
   lede face read as a different site next to the blog. */
.wrap > p {
  margin: 0 0 16px;
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.75;
  color: var(--ed-ink-2);
}
.wrap > ul { padding-left: 20px; font-family: var(--sans); font-size: 16px; line-height: 1.7; color: var(--ed-ink-2); }
.wrap > ul li { margin: 6px 0; }
.wrap > p.calc-checked, .wrap > p.calc-disclaimer {
  font-family: var(--sans);
  font-size: 13.5px;
  line-height: 1.55;
  color: var(--ed-mute);
}
.wrap > p.calc-checked { margin: 10px 0 28px; }
.wrap > p.calc-disclaimer { margin-top: 44px; padding-top: 16px; border-top: 1px solid var(--ed-rule-soft); }
.standfirst {
  margin: 14px 0 0;
  max-width: 720px;
  font-family: var(--sans);
  font-size: 18px;
  line-height: 1.5;
}

/* ── Calculator page header band ── */
.calc-head {
  background:
    radial-gradient(900px 300px at 85% 0%, color-mix(in srgb, var(--tone) 16%, transparent), transparent 70%),
    var(--tone-soft);
  border-bottom: 1px solid color-mix(in srgb, var(--tone) 22%, transparent);
}
.calc-head__inner { max-width: 1120px; margin: 0 auto; padding: 32px 24px 28px; }
.calc-head__title { display: flex; align-items: center; gap: 14px; }
.calc-head__icon {
  flex: none;
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  color: #fff;
  background: linear-gradient(145deg, var(--tone), var(--tone-deep));
  box-shadow: 0 6px 18px color-mix(in srgb, var(--tone) 30%, transparent);
}
.calc-head__icon .calc-icon { width: 28px; height: 28px; }
.calc-head__lede { margin: 12px 0 0; font-family: var(--sans); font-size: 18px; line-height: 1.5; color: var(--ed-ink-2); }
.calc-meta {
  display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px;
  margin: 16px 0 0;
  font-family: var(--mono); font-size: 11px; letter-spacing: .01em; text-transform: none;
  color: var(--tone-deep, var(--ed-ink));
}
.calc-meta i { font-style: normal; opacity: .45; }
.calc-chips { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; margin: 18px 0 0; padding: 0; }
.calc-chips li {
  padding: 6px 10px;
  font-family: var(--mono);
  font-size: 10.5px;
  letter-spacing: .01em;
  text-transform: none;
  color: var(--tone-deep, var(--ed-ink));
  background: rgba(255, 255, 255, .75);
  border: 1px solid color-mix(in srgb, var(--tone, #365f9f) 25%, transparent);
}
.calc-chips li em { font-style: normal; opacity: .7; }

/* ── Calculator panel ── */
.calc {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  margin: 0 0 8px;
  background: #fff;
  border: 1px solid var(--ed-rule-soft);
  border-top: 3px solid var(--tone);
  box-shadow: 0 1px 2px rgba(19, 42, 96, .05), 0 18px 40px rgba(19, 42, 96, .08);
}
.calc-form {
  display: grid;
  gap: 14px;
  align-content: start;
  padding: 24px;
  background: var(--ed-paper);
  border-right: 1px solid var(--ed-rule-soft);
}
.calc-form__title, .calc-hero__label {
  margin: 0;
  font-family: var(--mono);
  font-size: 10.5px;
  letter-spacing: .1em;
  text-transform: none;
}
.calc-form__title { color: var(--tone); }
.calc-field { display: grid; gap: 6px; font-size: 14px; font-weight: 600; }
.calc-field[hidden] { display: none; }
.calc-field small { font-weight: 400; font-size: 12.5px; line-height: 1.45; color: var(--ed-mute); }
.calc-field input,
.calc-field select {
  width: 100%;
  min-height: 44px;
  padding: 10px 12px;
  font: inherit;
  font-size: 16px;
  font-weight: 500;
  color: var(--ed-ink);
  background: #fff;
  border: 1px solid var(--ed-rule);
  border-radius: 0;
  transition: border-color .15s, box-shadow .15s;
}
.calc-field input[type="text"] { font-family: var(--mono); letter-spacing: .01em; text-transform: none; }
.calc-field input:hover, .calc-field select:hover { border-color: var(--tone); }
.calc-field input:focus,
.calc-field select:focus { outline: none; border-color: var(--tone); box-shadow: 0 0 0 3px color-mix(in srgb, var(--tone) 22%, transparent); }
.calc-prefix { display: flex; }
.calc-prefix b {
  display: flex;
  align-items: center;
  padding: 0 12px;
  font-weight: 600;
  color: var(--tone-deep);
  background: var(--tone-soft);
  border: 1px solid var(--ed-rule);
  border-right: 0;
}
.calc-check { grid-template-columns: auto 1fr; align-items: center; column-gap: 10px; }
.calc-check input { width: 20px; height: 20px; min-height: 0; margin: 0; accent-color: var(--tone); }
.calc-check small { grid-column: 2; }
.calc-moreopts { border-top: 1px dashed var(--ed-rule); padding-top: 12px; }
.calc-moreopts summary { cursor: pointer; font-weight: 600; font-size: 14px; color: var(--tone); list-style: none; }
.calc-moreopts summary::-webkit-details-marker { display: none; }
.calc-moreopts summary::before { content: "+"; display: inline-block; width: 18px; font-weight: 700; }
.calc-moreopts[open] summary::before { content: "\2212"; }
.calc-moreopts__body { display: grid; gap: 14px; margin-top: 14px; }

.calc-result { padding: 24px; align-self: start; display: grid; gap: 16px; min-width: 0; }
.calc-hero {
  display: grid;
  gap: 6px;
  padding: 20px 22px;
  color: #fff;
  background:
    radial-gradient(420px 160px at 100% 0%, rgba(255, 255, 255, .14), transparent 70%),
    linear-gradient(135deg, var(--tone-deep), var(--tone));
}
.calc-hero__label { color: rgba(255, 255, 255, .8); }
.calc-hero__value {
  font-size: clamp(34px, 4.4vw, 46px);
  font-weight: 700;
  line-height: 1;
  letter-spacing: -.03em;
  font-variant-numeric: tabular-nums;
}
.calc-hero__sub { font-size: 14px; color: rgba(255, 255, 255, .9); }

.calc-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin: 0; }
.calc-stats div { padding: 10px 12px; background: var(--tone-soft); border-left: 3px solid var(--tone); min-width: 0; }
.calc-stats dt { font-family: var(--mono); font-size: 9.5px; letter-spacing: .01em; text-transform: none; color: var(--ed-mute); }
.calc-stats dd { margin: 4px 0 0; font-size: 17px; font-weight: 700; color: var(--tone-deep); font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }

/* Stacked bar: take-home green, tax navy, NI blue, pension gold, loans sky. */
.t1 { --seg: #2c6a52; } .t2 { --seg: #132a60; } .t3 { --seg: #4f7cc0; }
.t4 { --seg: #c99a4e; } .t5 { --seg: #9cc0ea; } .t6 { --seg: #8a96ab; }
.calc-bar { margin: 0; }
.calc-bar figcaption { margin-bottom: 8px; font-family: var(--mono); font-size: 10.5px; letter-spacing: .01em; text-transform: none; color: var(--ed-mute); }
.calc-bar__track { display: flex; height: 16px; overflow: hidden; background: var(--ed-paper-2); }
.calc-bar__seg { background: var(--seg); transition: width .35s ease; }
.calc-bar__seg + .calc-bar__seg { box-shadow: inset 2px 0 0 #fff; }
.calc-bar__legend { list-style: none; display: flex; flex-wrap: wrap; gap: 6px 16px; margin: 10px 0 0; padding: 0; font-size: 13px; }
.calc-bar__legend li { display: inline-flex; align-items: center; gap: 6px; }
.calc-bar__legend i { width: 10px; height: 10px; background: var(--seg); }
.calc-bar__legend b { font-weight: 600; color: var(--ed-mute); }

.calc-table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; margin: 0; font-size: 14.5px; }
.calc-table caption {
  text-align: left;
  padding-bottom: 8px;
  font-family: var(--mono);
  font-size: 10.5px;
  letter-spacing: .01em;
  text-transform: none;
  color: var(--ed-mute);
}
.calc-table th, .calc-table td {
  padding: 8px 0;
  border-bottom: 1px solid var(--ed-rule-soft);
  text-align: left;
  font-weight: 400;
  vertical-align: top;
}
.calc-table td { text-align: right; padding-left: 12px; white-space: nowrap; }
.calc-table thead th { font-family: var(--mono); font-size: 10px; letter-spacing: .01em; text-transform: none; color: var(--ed-mute); text-align: right; border-bottom: 1px solid var(--ed-rule); }
.calc-table thead th:first-child { text-align: left; }
.calc-table .calc-total th, .calc-table .calc-total td { font-weight: 700; color: var(--tone-deep, var(--ed-ink)); border-top: 1px solid var(--ed-ink); background: var(--tone-soft, transparent); }
.calc-table .calc-total th { padding-left: 8px; }
.calc-table .calc-total td:last-child { padding-right: 8px; }
.calc-ok, .calc-bad { display: inline-block; margin-left: 6px; padding: 1px 6px; font-size: 11px; font-weight: 700; text-transform: none; letter-spacing: .01em; }
.calc-ok { color: #17463a; background: #dcefe5; }
.calc-bad { color: #8a2a1c; background: #fbe3df; }
.calc-note { margin: 0; font-size: 13.5px; line-height: 1.55; color: var(--ed-ink-2); }
.calc-note--warn { padding: 10px 12px; color: #5a3e14; background: #f7f0e3; border-left: 3px solid #8f6528; }

/* ── Below the calculator: folded explanations beside related reading ── */
.calc-below { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: 32px; margin-top: 40px; align-items: start; }
.calc-folds { display: grid; gap: 10px; }
.calc-fold { background: #fff; border: 1px solid var(--ed-rule-soft); }
.calc-fold summary {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 18px; cursor: pointer; list-style: none;
  font-size: 16px; font-weight: 700; letter-spacing: -.01em;
}
.calc-fold summary::-webkit-details-marker { display: none; }
.calc-fold summary::after {
  content: ""; width: 9px; height: 9px; margin-right: 4px;
  border-right: 2px solid var(--tone); border-bottom: 2px solid var(--tone);
  margin-top: -4px; transform: rotate(45deg); transition: transform .2s ease;
}
.calc-fold[open] summary::after { margin-top: 4px; transform: rotate(-135deg); }
.calc-fold summary:hover { color: var(--tone-deep); }
.calc-fold__body { padding: 0 18px 18px; border-top: 1px solid var(--ed-rule-soft); }
.calc-fold__body p { margin: 14px 0 0; font-family: var(--sans); font-size: 16px; line-height: 1.75; color: var(--ed-ink-2); }
.calc-fold__body .calc-table { margin: 18px 0 0; }
.calc-sources { margin: 14px 0 0; padding-left: 18px; font-size: 15px; line-height: 1.5; }
.calc-sources li { margin: 6px 0; }
.calc-sources a { color: var(--ed-ink); }

.calc-related-wrap h2 { margin: 0 0 12px; font-size: 16px; }
.calc-related { list-style: none; margin: 0; padding: 0 !important; display: grid; gap: 8px; }
.calc-related li { margin: 0 !important; }
.calc-related a {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 12px 14px; font-size: 14.5px; font-weight: 600; line-height: 1.35;
  color: var(--ed-ink); text-decoration: none;
  background: var(--tone-soft); border-left: 3px solid var(--tone);
  transition: background .15s;
}
.calc-related a:hover { background: color-mix(in srgb, var(--tone) 14%, #fff); }
.calc-arrow { flex: none; color: var(--tone); transition: transform .15s ease; }
a:hover > .calc-arrow { transform: translateX(3px); }

/* ── More calculators (bottom of each page) ── */
.calc-more { list-style: none; padding: 0 !important; display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 8px; }
.calc-more li { margin: 0 !important; }
.calc-more a {
  display: flex; align-items: center; gap: 10px; padding: 10px 12px;
  color: var(--ed-ink); text-decoration: none; font-family: var(--sans); font-weight: 600; font-size: 14px;
  background: #fff; border: 1px solid var(--ed-rule-soft);
}
.calc-more a .calc-icon { flex: none; width: 20px; height: 20px; color: var(--tone); }
.calc-more a:hover { border-color: var(--tone); color: var(--tone-deep); }

/* ── Hub ── */
.hub-hero {
  color: #fff;
  background:
    radial-gradient(700px 320px at 90% 10%, rgba(169, 201, 240, .28), transparent 70%),
    radial-gradient(500px 260px at 0% 100%, rgba(217, 184, 119, .22), transparent 70%),
    linear-gradient(135deg, #132a60, #1d3f86);
}
.hub-hero__inner { max-width: 1120px; margin: 0 auto; padding: 36px 24px 34px; }
.hub-hero .crumbs { color: rgba(255, 255, 255, .7); }
.hub-hero .crumbs a:hover { color: #fff; }
.hub-hero h1 { color: #fff; font-size: clamp(34px, 5vw, 56px); }
.hub-hero .standfirst { color: rgba(255, 255, 255, .92); }
.hub-hero .calc-meta { color: rgba(255, 255, 255, .78); }
.hub-hero .calc-chips li { color: #fff; background: rgba(255, 255, 255, .1); border-color: rgba(255, 255, 255, .25); }

.hub-group { margin-top: 40px; }
.hub-group:first-child { margin-top: 8px; }
.hub-group__head {
  display: flex; align-items: center; gap: 10px;
  margin: 0 0 14px; font-size: 13px; font-family: var(--mono); font-weight: 500;
  letter-spacing: .1em; text-transform: none; color: var(--tone-deep);
}
.hub-group__head::before { content: ""; width: 22px; height: 3px; background: var(--tone); }
.calc-hub { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 12px; }
.calc-hub li { margin: 0; }
.calc-hub a {
  display: flex; align-items: center; gap: 16px;
  height: 100%; padding: 18px 18px 18px 16px;
  color: var(--ed-ink); text-decoration: none;
  background: #fff;
  border: 1px solid var(--ed-rule-soft);
  box-shadow: 0 1px 2px rgba(19, 42, 96, .04);
  transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}
.calc-hub a:hover { transform: translateY(-2px); border-color: color-mix(in srgb, var(--tone) 40%, transparent); box-shadow: 0 14px 30px rgba(19, 42, 96, .1); }
.calc-hub__icon {
  flex: none; display: grid; place-items: center; width: 48px; height: 48px;
  color: #fff; background: linear-gradient(145deg, var(--tone), var(--tone-deep));
  box-shadow: 0 6px 14px color-mix(in srgb, var(--tone) 28%, transparent);
}
.calc-hub__text { display: grid; gap: 3px; flex: 1; min-width: 0; }
.calc-hub strong { font-size: 17px; font-weight: 700; letter-spacing: -.01em; }
.calc-hub__desc { font-size: 14px; line-height: 1.4; color: var(--ed-mute); }
.calc-hub .calc-arrow { opacity: .5; }
.calc-hub a:hover .calc-arrow { opacity: 1; }

@media (prefers-reduced-motion: reduce) {
  .calc-hub a, .calc-bar__seg, .calc-fold summary::after, .calc-arrow { transition: none; }
}
@media (max-width: 860px) {
  .calc { grid-template-columns: 1fr; }
  .calc-form { border-right: 0; border-bottom: 1px solid var(--ed-rule-soft); }
  .calc-below { grid-template-columns: 1fr; gap: 28px; }
}
@media (max-width: 640px) {
  .wrap { padding: 24px 16px 56px; }
  .calc-head__inner, .hub-hero__inner { padding: 24px 16px; }
  .calc-head__icon { width: 44px; height: 44px; }
  .standfirst, .calc-head__lede { font-size: 18px; }
  .calc-hub { grid-template-columns: 1fr; }
  .wrap > p { font-size: 18px; }
  .calc-form, .calc-result { padding: 16px; }
  .calc-stats { grid-template-columns: 1fr 1fr; }
  .calc-hero__value { font-size: 36px; }
}

/* ── Salary after tax pages ── */
.salary-facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px 24px; margin-top: 32px; }
.salary-facts section { padding: 20px 22px; background: #fff; border: 1px solid var(--ed-rule-soft); border-top: 3px solid var(--tone); }
.salary-facts h2 { margin: 0 0 12px; font-size: 17px; }
.salary-facts .calc-note { margin-top: 12px; }
.salary-list { margin: 10px 0 0; padding-left: 18px; font-size: 13.5px; line-height: 1.55; color: var(--ed-ink-2); }
.salary-list li { margin: 6px 0; }
.wrap > .salary-hub { max-width: 820px; margin: 8px 0 0; }
.salary-hub th a { color: var(--ed-ink); font-weight: 600; }
@media (max-width: 860px) { .salary-facts { grid-template-columns: 1fr; } }
.hub-salaries { display: flex; flex-wrap: wrap; gap: 8px; margin: 0; }
.hub-salaries a { padding: 8px 14px; font-weight: 600; font-size: 14px; color: var(--tone-deep); text-decoration: none; background: #fff; border: 1px solid var(--ed-rule-soft); }
.hub-salaries a:hover { border-color: var(--tone); }

/* ── Salary links and FAQ (calculator pages) ── */
.calc-salaries { margin-top: 40px; }
.calc-salaries h2 { margin: 0 0 12px; font-size: 16px; }
.calc-salaries ul { list-style: none; margin: 0; padding: 0 !important; display: flex; flex-wrap: wrap; gap: 8px; }
.calc-salaries li { margin: 0 !important; }
.calc-salaries a {
  display: inline-block; padding: 8px 12px; font-family: var(--sans); font-size: 14px; font-weight: 600;
  color: var(--ed-ink); text-decoration: none; background: #fff; border: 1px solid var(--ed-rule-soft);
}
.calc-salaries a:hover { border-color: var(--tone, var(--ed-ink)); }
.calc-faq { margin-top: 40px; max-width: 760px; }
.calc-faq h2 { margin: 0 0 8px; font-size: 22px; }
.calc-faq__item { padding: 16px 0; border-top: 1px solid var(--ed-rule-soft); }
.calc-faq__item h3 { margin: 0; font-family: var(--sans); font-size: 17px; font-weight: 600; line-height: 1.35; color: var(--ed-ink); }
.calc-faq__item p { margin: 6px 0 0; font-family: var(--sans); font-size: 16px; line-height: 1.6; color: var(--ed-ink-2); }

/* ── Take-home by area ── */
.area-table { margin-top: 40px; }
.area-table h2 { font-size: 22px; margin: 0 0 8px; }
.area-table input[type="search"] { margin-left: 8px; padding: 8px 10px; font: inherit; font-size: 15px; border: 1px solid var(--ed-rule); min-width: 240px; }
.area-scroll { max-height: 640px; overflow: auto; border: 1px solid var(--ed-rule-soft); margin-top: 12px; }
.area-scroll thead th { position: sticky; top: 0; background: #fff; z-index: 1; }
.area-scroll button[data-sort] { all: unset; cursor: pointer; text-decoration: underline dotted; }
.area-scroll tbody th { text-align: left; font-weight: 600; }
.area-scroll td:nth-child(3) { text-align: left; }
.area-scroll td:first-child { width: 3.5em; padding-right: 14px; text-align: right; color: var(--ed-mute); }

/* ── Design refresh, 2026-11-14 ── */
.calc-head__lede { font-size: 19px; line-height: 1.5; }
.wrap > p { font-size: 17.5px; }
.wrap > ul { font-size: 17px; }
.calc-fold__body p { font-size: 16.5px; }
.calc-meta { font-size: 12.5px; letter-spacing: .02em; text-transform: none; font-weight: 500; }
.calc-form__title, .calc-hero__label { font-size: 12px; font-weight: 600; letter-spacing: .01em; }
.calc { border-radius: 12px; overflow: clip; }
.calc-field input, .calc-field select { border-radius: 8px; }
.calc-field input[type="text"] { font-family: var(--sans); letter-spacing: .02em; }
.calc-fold { border-radius: 12px; }
/* The result stays in view while a long form is edited. */
@media (min-width: 900px) {
  .calc-result { position: sticky; top: 84px; }
}
.crumbs, .crumbs a { font-size: 13px; letter-spacing: 0; text-transform: none; font-weight: 500; }

/* ══ Match the editorial site, 2026-11-14 ══
   Calculators had their own look: tinted gradient header with an icon tile,
   a navy hub banner, three group colours and tracked capitals. They now use
   the article page's header, one brand blue, and the site's card style. */
.tone-blue, .tone-gold, .tone-green { --tone: #365f9f; --tone-soft: #eef4fb; --tone-deep: #16243c; }

.calc-head, .hub-hero {
  color: var(--ed-ink);
  background: #fff;
  border-bottom: 1px solid var(--ed-rule-soft);
}
.calc-head__inner, .hub-hero__inner { padding: 44px 24px 32px; }
.calc-head__icon { display: none; }
.calc-head h1, .hub-hero h1 {
  color: var(--ed-ink);
  font-variation-settings: "wdth" 100, "opsz" 32;
  font-weight: 700;
  font-size: clamp(32px, 3.6vw, 46px);
  line-height: 1.02;
  letter-spacing: -.03em;
}
.calc-head__lede, .hub-hero .standfirst { margin-top: 14px; max-width: 680px; color: var(--ed-ink-2); font-size: 18.5px; line-height: 1.5; }
.calc-meta, .hub-hero .calc-meta { margin-top: 14px; color: var(--ed-mute); font-size: 13.5px; font-weight: 500; letter-spacing: 0; text-transform: none; }
.hub-hero .crumbs, .hub-hero .crumbs a, .calc-head .crumbs, .calc-head .crumbs a { color: var(--ed-mute); }
.hub-hero .crumbs a:hover, .calc-head .crumbs a:hover { color: var(--ed-terra); }
.hub-hero .calc-chips li { color: var(--ed-ink-2); background: var(--ed-paper); border-color: var(--ed-rule-soft); }

/* Panel: the site's card — hairline, 12px radius, soft shadow. */
.calc {
  border: 1px solid var(--ed-rule-soft);
  border-top: 1px solid var(--ed-rule-soft);
  border-radius: 12px;
  box-shadow: 0 1px 2px rgba(19, 42, 96, .04), 0 10px 30px rgba(19, 42, 96, .06);
}
.calc-form { background: #f9fbfe; }
.calc-hero { border-radius: 10px; background: var(--ed-ink); }
.calc-stats div { border-left: 0; border-radius: 8px; background: var(--ed-paper-2); }
.calc-stats dd { color: var(--ed-ink); }

/* Every small label in sentence case, same size and weight as the articles'. */
.calc-form__title, .calc-hero__label, .calc-stats dt, .calc-bar figcaption,
.calc-table caption, .calc-table thead th, .calc-fold summary, .calc-chips li {
  font-family: var(--sans);
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: 0;
  text-transform: none;
}
.calc-form__title { color: var(--ed-ink); font-size: 14px; }
.calc-hero__label { color: rgba(255, 255, 255, .78); }
.calc-fold summary { font-size: 15px; }

/* Hub cards and links. */
.calc-hub a { border-radius: 12px; }
.calc-hub a:hover { transform: none; border-color: var(--ed-rule); box-shadow: 0 10px 26px rgba(19, 42, 96, .08); }
.calc-hub__icon { border-radius: 10px; color: var(--ed-terra); background: var(--ed-paper-2); box-shadow: none; }
.hub-group__head { font-size: 13px; font-weight: 700; letter-spacing: 0; text-transform: none; color: var(--ed-ink); }
.calc-more a, .calc-salaries a, .calc-related a, .calc-fold { border-radius: 8px; }
.calc-related a { border-left: 0; background: var(--ed-paper); }

/* ══ Sidebar layout, 2026-11-14 ══
   Catalogue on the left (sticky, scrolls on its own), page on the right.
   Fills the dead space either side of the old centred column and makes the
   other 30 tools one click away. */
.calc-shell {
  display: grid;
  grid-template-columns: 252px minmax(0, 1fr);
  max-width: 1440px;
  margin: 0 auto;
}
.calc-side {
  position: sticky;
  top: 64px;
  align-self: start;
  max-height: calc(100vh - 64px);
  overflow-y: auto;
  padding: 28px 18px 40px var(--gutter);
  border-right: 1px solid var(--ed-rule-soft);
  scrollbar-width: thin;
}
.calc-side ul { margin: 0; padding: 0; list-style: none; }
.calc-side__all {
  display: block; margin: 0 0 10px; padding: 10px 12px; border-radius: 8px;
  background: var(--ed-ink); color: #fff; font-size: 14.5px; font-weight: 600; text-decoration: none;
}
.calc-side__all:hover { background: var(--ed-terra-deep); color: #fff; }
.calc-side__all.is-current { background: var(--ed-terra-deep); }
.calc-side__group { margin: 20px 0 6px; padding: 0 12px; font-size: 12.5px; font-weight: 700; color: var(--ed-mute); }
.calc-side a:not(.calc-side__all) {
  display: block; padding: 7px 12px; border-radius: 8px;
  color: var(--ed-ink-2); font-size: 14.5px; line-height: 1.3; text-decoration: none;
  transition: background-color .15s ease, color .15s ease;
}
.calc-side a:not(.calc-side__all):hover { background: var(--ed-paper-2); color: var(--ed-ink); }
.calc-side a[aria-current="page"] { background: var(--ed-paper-2); color: var(--ed-ink); font-weight: 600; box-shadow: inset 3px 0 0 var(--ed-terra); }

.calc-main { min-width: 0; }
.calc-main .calc-head__inner,
.calc-main .hub-hero__inner,
.calc-main .wrap { max-width: 1100px; margin: 0; padding-left: 44px; padding-right: 44px; }
.calc-main .calc-head__inner, .calc-main .hub-hero__inner { padding-top: 36px; }
/* The sidebar already lists every calculator. */
.calc-main h2:has(+ .calc-more), .calc-main .calc-more:not(.calc-related-wrap .calc-more) { display: none; }

/* Hub: search, then title-only tiles. */
.hub-search { margin: 0 0 8px; }
.hub-search input {
  width: 100%; min-height: 50px; padding: 0 16px;
  border: 1px solid var(--ed-rule); border-radius: 10px; background: #fff;
  font: inherit; font-size: 16px; color: var(--ed-ink);
}
.hub-search input:focus { outline: none; border-color: var(--ed-terra); box-shadow: 0 0 0 3px rgba(54, 95, 159, .2); }
.calc-hub { grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)) !important; gap: 10px; }
.calc-hub a { min-height: 66px; padding: 12px 14px; gap: 12px; align-items: center; }
.calc-hub strong { font-size: 15.5px; font-weight: 600; }
.calc-hub__icon { width: 40px; height: 40px; }
.calc-hub__icon .calc-icon { width: 21px; height: 21px; }
.hub-group { margin-top: 28px; }
.hub-group__head { margin: 0 0 12px; font-size: 15px; }
.hub-group__head::before { display: none; }

@media (max-width: 1000px) {
  .calc-shell { grid-template-columns: 1fr; }
  .calc-side { display: none; }
  .calc-main .calc-head__inner, .calc-main .hub-hero__inner, .calc-main .wrap { padding-left: var(--gutter); padding-right: var(--gutter); }
  .calc-main h2:has(+ .calc-more), .calc-main .calc-more { display: revert; }
}
/* Titles stand alone; the meta line carries tax year and checks. Salary pages keep their lede, which is the answer itself. */
.calc-head:not(.salary-head) .calc-head__lede, .hub-hero .standfirst { display: none; }
.calc-main .wrap { max-width: 1160px; }

/* Sidebar, round 2: a tinted card with icons, a filter and a count. */
.calc-side { padding: 24px 16px 40px var(--gutter); border-right: 0; }
.calc-side__card { padding: 12px; background: var(--ed-paper); border: 1px solid var(--ed-rule-soft); border-radius: 14px; }
.calc-side__all { display: flex; justify-content: space-between; align-items: center; margin: 0 0 10px; }
.calc-side__count { min-width: 26px; padding: 2px 8px; border-radius: 999px; background: rgba(255,255,255,.18); font-size: 12.5px; text-align: center; }
.calc-side__q { width: 100%; min-height: 38px; margin: 0 0 4px; padding: 0 12px; border: 1px solid var(--ed-rule-soft); border-radius: 8px; background: #fff; font: inherit; font-size: 14px; color: var(--ed-ink); }
.calc-side__q:focus { outline: none; border-color: var(--ed-terra); }
.calc-side__group { margin: 16px 0 4px; padding: 0 8px; font-size: 12px; font-weight: 700; letter-spacing: .02em; color: var(--ed-mute); }
.calc-side a:not(.calc-side__all) { display: flex; align-items: center; gap: 10px; padding: 6px 8px; font-size: 14px; }
.calc-side__ic { flex: none; display: grid; place-items: center; width: 28px; height: 28px; border-radius: 7px; background: #fff; color: var(--ed-terra); border: 1px solid var(--ed-rule-soft); }
.calc-side__ic .calc-icon { width: 16px; height: 16px; }
.calc-side a:not(.calc-side__all):hover { background: #fff; }
.calc-side a[aria-current="page"] { background: #fff; box-shadow: 0 1px 2px rgba(19,42,96,.06), inset 3px 0 0 var(--ed-terra); }
.calc-side a[aria-current="page"] .calc-side__ic { background: var(--ed-terra); color: #fff; border-color: var(--ed-terra); }
/* Same 1200px column as the rest of the site. */
.calc-shell { max-width: calc(1136px + 2 * var(--gutter)); padding: 0 var(--gutter); }
.calc-side { padding-left: 0; }
.calc-main .calc-head__inner, .calc-main .hub-hero__inner, .calc-main .wrap { padding-left: 36px; padding-right: 0; max-width: none; }
@media (max-width: 1000px) { .calc-shell { padding: 0; } .calc-main .calc-head__inner, .calc-main .hub-hero__inner, .calc-main .wrap { padding-left: var(--gutter); padding-right: var(--gutter); } }

/* ══ Trust, explanation and key figures, 2026-11-16 ══
   "How it works" and the sources were folded away in accordions, which hid
   the explanation from readers and made the citations look like an
   afterthought. They are now plain sections beside a trust card that says
   when the rates were checked, when they are due again, and how many
   hand-worked tests guard them. */
.calc-explain { display: grid; gap: 28px; min-width: 0; }
.calc-section { padding: 22px 24px; background: #fff; border: 1px solid var(--ed-rule-soft); border-radius: 12px; box-shadow: 0 1px 2px rgba(19, 42, 96, .04); }
.calc-section h2 { margin: 0 0 10px; font-size: 20px; letter-spacing: -.02em; }
.calc-section > p { margin: 12px 0 0; font-family: var(--sans); font-size: 16px; line-height: 1.75; color: var(--ed-ink-2); }
.calc-section .calc-table { margin: 16px 0 0; }
.calc-section .calc-sources { margin: 10px 0 0; }
.calc-section .calc-note { margin-top: 14px; font-family: var(--sans); font-size: 13px; color: var(--ed-mute); }
.calc-steps { margin: 14px 0 0; padding-left: 22px; font-family: var(--sans); font-size: 16px; line-height: 1.7; color: var(--ed-ink-2); }
.calc-steps li { margin: 8px 0; padding-left: 4px; }
.calc-steps strong { font-family: var(--sans); font-size: 15px; color: var(--ed-ink); }
.calc-kf { margin: 6px 0 0; display: grid; gap: 0; }
.calc-kf > div { display: grid; grid-template-columns: minmax(150px, 2fr) minmax(0, 5fr); gap: 4px 20px; padding: 10px 0; border-top: 1px solid var(--ed-rule-soft); }
.calc-kf > div:first-child { border-top: 0; }
.calc-kf dt { margin: 0; font-family: var(--sans); font-size: 14px; font-weight: 600; line-height: 1.4; color: var(--ed-ink); }
.calc-kf dd { margin: 0; font-family: var(--sans); font-size: 14.5px; line-height: 1.5; color: var(--ed-ink-2); font-variant-numeric: tabular-nums; }
.calc-aside { display: grid; gap: 24px; align-content: start; min-width: 0; }
.calc-aside .calc-related-wrap h2 { margin-top: 0; }
.calc-trust { padding: 18px 20px; background: var(--ed-paper); border: 1px solid var(--ed-rule-soft); border-radius: 12px; }
.calc-trust h2 { margin: 0 0 10px; font-size: 16px; letter-spacing: -.01em; }
.calc-trust ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 10px; }
.calc-trust li { position: relative; padding-left: 24px; font-family: var(--sans); font-size: 13.5px; line-height: 1.5; color: var(--ed-ink-2); }
.calc-trust li::before { content: ""; position: absolute; left: 0; top: 4px; width: 14px; height: 14px; border-radius: 50%; background: var(--ed-terra); box-shadow: inset 0 0 0 3px #fff, 0 0 0 1px var(--ed-terra); }
.calc-trust strong { color: var(--ed-ink); font-weight: 600; }
.calc-trust a { color: var(--ed-ink); }
.calc-trust__more { display: inline-flex; align-items: center; gap: 6px; margin-top: 14px; font-family: var(--sans); font-size: 14px; font-weight: 600; color: var(--ed-terra-deep) !important; text-decoration: none; }
.calc-trust__more:hover { color: var(--ed-terra) !important; }
.calc-trust__more .calc-arrow { width: 16px; height: 16px; }
.hub-intro { max-width: 760px; margin: 0 0 20px; font-family: var(--sans); font-size: 16.5px; line-height: 1.65; color: var(--ed-ink-2); }
.hub-below { margin-top: 36px; }
.hub-below .calc-section { align-self: start; }
.method h2 { margin-top: 36px; font-size: 24px; }
.method .method-table { margin: 16px 0 0; font-size: 14px; }
.method .method-table th, .method .method-table td { text-align: left; white-space: normal; vertical-align: top; }
.method .method-table tbody th { font-weight: 600; }
.method .method-table td a { color: var(--ed-ink); }
.method .method-table time { white-space: nowrap; }
.calc-side__group + ul + .calc-side__group { margin-top: 16px; }
@media (max-width: 640px) {
  .calc-section { padding: 18px 16px; }
  .calc-kf > div { grid-template-columns: 1fr; gap: 2px; }
  .method .method-table { font-size: 13px; }
  .area-scroll, .method .method-table { display: block; overflow-x: auto; }
}

/* ══ Neutral surfaces and a quieter catalogue, 2026-11-16 ══
   Three things made the calculators look like a different site from the
   articles: blue-tinted fills on the form, the stat tiles and the sidebar
   card; a sidebar that floated as a boxed widget with its own icon tiles;
   and a stripe of saturated bar colours. Articles are white, ink and
   hairlines. The calculators now are too, with the brand blue kept for
   links, focus and one accent. */
.tone-blue, .tone-gold, .tone-green { --tone: #365f9f; --tone-soft: #f5f6f8; --tone-deep: #16243c; }
:root { --calc-neutral: #f6f7f9; --calc-neutral-2: #eef0f3; }

/* Page header: same spacing as the article masthead, no band. */
.calc-head, .hub-hero { border-bottom: 0; }
.calc-main .calc-head__inner, .calc-main .hub-hero__inner { padding-top: 40px; padding-bottom: 8px; }
.calc-main .wrap { padding-top: 16px; }
.calc-meta, .hub-hero .calc-meta { margin-top: 12px; }

/* The panel: white, one hairline, no inner tint. */
.calc { box-shadow: 0 1px 2px rgba(19, 42, 96, .04); }
.calc-form { background: #fff; border-right: 1px solid var(--ed-rule-soft); }
.calc-field input, .calc-field select { border-color: var(--ed-rule); background: #fff; }
.calc-field input:focus, .calc-field select:focus { border-color: var(--ed-terra); box-shadow: 0 0 0 3px rgba(54, 95, 159, .18); outline: none; }
.calc-prefix b { background: var(--calc-neutral); color: var(--ed-mute); border-color: var(--ed-rule); }
.calc-moreopts summary { color: var(--ed-terra); }
.calc-stats div { background: var(--calc-neutral); }
.calc-table .calc-total th, .calc-table .calc-total td { background: var(--calc-neutral); }
.calc-note--warn { background: #fbf7ee; color: #5a3e14; border-left-color: #b98a3a; }
/* Bars: ink for the thing you keep, greys for what goes. */
.t1 { --seg: #16243c; } .t2 { --seg: #5b6b85; } .t3 { --seg: #8f9db3; } .t4 { --seg: #b98a3a; } .t5 { --seg: #c3cbd8; } .t6 { --seg: #dde2ea; }
.calc-bar__seg + .calc-bar__seg { box-shadow: inset 2px 0 0 #fff; }
.calc-related a { background: var(--calc-neutral); }
.calc-trust { background: var(--calc-neutral); }
.calc-section, .calc-fold { box-shadow: none; }

/* Sidebar: a plain list under a heading, aligned with the page title. */
.calc-side { top: 64px; padding: 40px 24px 40px 0; }
.calc-side__card { padding: 0; background: transparent; border: 0; border-radius: 0; }
.calc-side__all {
  display: flex; justify-content: space-between; align-items: center;
  margin: 0 0 10px; padding: 0 0 12px; border-radius: 0; border-bottom: 2px solid var(--ed-ink);
  background: transparent; color: var(--ed-ink); font-size: 15px; font-weight: 700; letter-spacing: -.01em;
}
.calc-side__all:hover, .calc-side__all.is-current { background: transparent; color: var(--ed-ink); }
.calc-side__all:hover span:first-child { color: var(--ed-terra); }
.calc-side__count { min-width: 24px; padding: 2px 7px; background: var(--calc-neutral-2); color: var(--ed-mute); font-size: 12px; font-weight: 600; }
.calc-side__q { min-height: 36px; margin: 0 0 6px; padding: 0 10px; border: 1px solid var(--ed-rule); border-radius: 8px; font-size: 13.5px; }
.calc-side__group { margin: 18px 0 4px; padding: 0; font-size: 12px; font-weight: 700; letter-spacing: .01em; color: var(--ed-mute); }
.calc-side a:not(.calc-side__all) { padding: 6px 8px 6px 10px; margin-left: -10px; border-radius: 8px; color: var(--ed-ink-2); font-size: 14px; gap: 9px; }
.calc-side__ic { width: 22px; height: 22px; border: 0; border-radius: 6px; background: transparent; color: var(--ed-mute); }
.calc-side__ic .calc-icon { width: 16px; height: 16px; }
.calc-side a:not(.calc-side__all):hover { background: var(--calc-neutral); color: var(--ed-ink); }
.calc-side a:not(.calc-side__all):hover .calc-side__ic { color: var(--ed-terra); }
.calc-side a[aria-current="page"] { background: var(--calc-neutral); color: var(--ed-ink); font-weight: 600; box-shadow: inset 3px 0 0 var(--ed-ink); }
.calc-side a[aria-current="page"] .calc-side__ic { background: transparent; color: var(--ed-ink); border: 0; }
.calc-side__group + ul + .calc-side__group { margin-top: 18px; }
@media (min-width: 1001px) {
  .calc-shell { grid-template-columns: 236px minmax(0, 1fr); }
  .calc-main .calc-head__inner, .calc-main .hub-hero__inner, .calc-main .wrap { padding-left: 40px; }
}
@media (max-width: 1000px) {
  .calc-main .calc-head__inner, .calc-main .hub-hero__inner { padding-top: 28px; }
}

/* Hub tiles and footers of each page: neutral. */
.calc-hub__icon { background: var(--calc-neutral); color: var(--ed-ink); }
.calc-hub a:hover .calc-hub__icon { color: var(--ed-terra); }
.calc-more a .calc-icon { color: var(--ed-mute); }
.hub-salaries a, .calc-salaries a { color: var(--ed-ink); }
.calc-kf dt { color: var(--ed-ink); }

/* ══ Share, cite, alerts and the tracker card, 2026-11-16 ══ */
.calc-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 12px; margin: 14px 0 0; }
.calc-action {
  display: inline-flex; align-items: center; gap: 8px; min-height: 40px; padding: 0 14px;
  border: 1px solid var(--ed-rule); border-radius: 8px; background: #fff; color: var(--ed-ink);
  font: inherit; font-size: 14px; font-weight: 600; cursor: pointer; transition: background-color .15s ease, border-color .15s ease;
}
.calc-action:hover { background: var(--calc-neutral); border-color: var(--ed-ink); }
.calc-action svg { color: var(--ed-mute); }
.calc-action--primary { background: var(--ed-ink); border-color: var(--ed-ink); color: #fff; }
.calc-action--primary:hover { background: var(--ed-terra-deep); }
.calc-alert { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 6px 8px; align-items: center; margin-left: auto; min-width: min(100%, 420px); }
.calc-alert input { min-height: 40px; padding: 0 12px; border: 1px solid var(--ed-rule); border-radius: 8px; font: inherit; font-size: 14px; color: var(--ed-ink); background: #fff; }
.calc-alert input:focus { outline: none; border-color: var(--ed-terra); box-shadow: 0 0 0 3px rgba(54, 95, 159, .18); }
.calc-alert small { grid-column: 1 / -1; font-size: 12px; line-height: 1.4; color: var(--ed-mute); }
.calc-app { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 16px; align-items: center; margin: 24px 0 0; padding: 16px 20px; background: var(--calc-neutral); border: 1px solid var(--ed-rule-soft); border-radius: 12px; }
.calc-app__icon { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 10px; background: #fff; color: var(--ed-terra); border: 1px solid var(--ed-rule-soft); }
.calc-app strong { display: block; font-size: 15px; }
.calc-app p { margin: 2px 0 0; font-size: 13.5px; line-height: 1.5; color: var(--ed-ink-2); }
.calc-app__cta { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; font-size: 14px; font-weight: 600; color: var(--ed-ink); text-decoration: none; }
.calc-app__cta:hover { color: var(--ed-terra); }
/* Press and data section on the area page. */
.press { margin-top: 40px; }
.press__grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; margin-top: 12px; }
.press__card { padding: 18px 20px; background: #fff; border: 1px solid var(--ed-rule-soft); border-radius: 12px; }
.press__card h3 { margin: 0 0 6px; font-size: 16px; }
.press__card p { margin: 0; font-size: 14px; line-height: 1.5; color: var(--ed-ink-2); }
.press__card a.calc-action { margin-top: 12px; }
.press__chart { margin: 16px 0 0; }
.press__chart img { width: 100%; height: auto; border: 1px solid var(--ed-rule-soft); border-radius: 12px; }
.press__chart figcaption { margin-top: 8px; font-size: 13px; color: var(--ed-mute); }
.firms-form { display: grid; gap: 12px; max-width: 560px; margin-top: 16px; }
.firms-form label { display: grid; gap: 6px; font-size: 14px; font-weight: 600; }
.firms-form input, .firms-form select, .firms-form textarea { min-height: 44px; padding: 10px 12px; border: 1px solid var(--ed-rule); border-radius: 8px; font: inherit; font-size: 15px; color: var(--ed-ink); background: #fff; }
.firms-form textarea { min-height: 96px; resize: vertical; }
.firms-form small { font-size: 13px; color: var(--ed-mute); }
@media (max-width: 640px) {
  .calc-alert { margin-left: 0; min-width: 100%; }
  .calc-app { grid-template-columns: auto minmax(0, 1fr); }
  .calc-app__cta { grid-column: 2; }
}

/* ══ Give the pages some life, 2026-11-16 ══
   Neutral stayed; what was missing was contrast and rhythm: a header band,
   the icon tile back in ink, a deeper hero, accents on section titles, and
   pictures on the related reading. */
.calc-head, .hub-hero { background: linear-gradient(180deg, #f6f7f9 0%, #ffffff 100%); border-bottom: 1px solid var(--ed-rule-soft); }
.calc-head__icon { display: grid; width: 48px; height: 48px; border-radius: 12px; background: var(--ed-ink); color: #fff; box-shadow: 0 8px 20px rgba(22, 36, 60, .18); }
.calc-head__icon .calc-icon { width: 24px; height: 24px; }
.calc-head__title { gap: 16px; }
.calc-main .calc-head__inner { padding-bottom: 28px; }
.calc-meta { font-weight: 600; }
.calc-meta i { opacity: .35; }
.calc-hero { background: linear-gradient(135deg, #16243c 0%, #1f3a6e 100%); box-shadow: 0 12px 28px rgba(22, 36, 60, .18); }
.calc-hero__value { letter-spacing: -.03em; }
.calc-stats div { border: 1px solid var(--ed-rule-soft); background: #fff; }
.calc-stats dd { font-size: 20px; }
.calc-form { background: linear-gradient(180deg, #fafbfc, #ffffff); }
.calc-form__title { display: flex; align-items: center; gap: 8px; }
.calc-form__title::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--ed-ink); }
.calc-section { position: relative; }
.calc-section h2 { display: flex; align-items: center; gap: 10px; }
.calc-section h2::before { content: ""; flex: none; width: 4px; height: 20px; border-radius: 2px; background: var(--ed-ink); }
.calc-facts h2::before { background: var(--ed-terra); }
.calc-kf > div:hover { background: #fafbfc; }
.calc-related a { display: grid; grid-template-columns: 72px 1fr auto; align-items: center; gap: 12px; padding: 10px 12px 10px 10px; background: #fff; border: 1px solid var(--ed-rule-soft); }
.calc-related a:hover { border-color: var(--ed-ink); background: #fff; }
.calc-related__thumb { width: 72px; height: 44px; border-radius: 6px; object-fit: cover; background: var(--calc-neutral-2); }
.calc-related a.no-thumb { grid-template-columns: 1fr auto; }
.calc-faq__item h3 { position: relative; padding-left: 18px; }
.calc-faq__item h3::before { content: "Q"; position: absolute; left: 0; top: 1px; font-size: 12px; font-weight: 800; color: var(--ed-terra); }
.calc-trust { background: linear-gradient(180deg, #f6f7f9, #eef0f3); }
.hub-hero { padding-bottom: 0; }
.calc-hub a { box-shadow: 0 1px 2px rgba(19, 42, 96, .04); }
.calc-hub a:hover { box-shadow: 0 12px 28px rgba(19, 42, 96, .1); transform: translateY(-1px); }
.calc-hub__icon { background: var(--ed-ink); color: #fff; }
.hub-group__head { display: flex; align-items: center; gap: 10px; font-size: 15px; }
.hub-group__head::before { content: ""; display: block; width: 4px; height: 18px; border-radius: 2px; background: var(--ed-ink); }
.calc-disclaimer { font-size: 13px; }
@media (prefers-reduced-motion: reduce) { .calc-hub a:hover { transform: none; } }

/* Ad slot (renders only when CALC_AD_SLOT is set in the build): reserves its
   height so a late creative never moves the result. */
.ad-slot { position: relative; margin: 20px 0 0; min-height: 280px; display: flex; align-items: center; justify-content: center; background: var(--ed-paper); border-radius: 8px; }
.ad-slot ins { width: 100%; }
.ad-slot__label { position: absolute; top: 6px; left: 10px; font-size: 10px; letter-spacing: .08em; text-transform: uppercase; color: var(--ed-mute); }

/* ═══ BBC layout for calculator, salary and hub pages, 2026-11-18 ═══
   Grey ground; the page is one main column with a right rail, as a BBC
   article or tool page; the left sidebar is gone. */
body:has(.calc-shell--bb) { background: var(--bb-ground); }
.calc-shell--bb { display: block !important; max-width: none !important; padding: 0 !important; grid-template-columns: none !important; }
.calc-shell--bb .calc-main { max-width: none; padding: 0; }
.calc-shell--bb .wrap { padding-top: 0; }

/* Title block in the main column, no band behind it. */
.calc-head--bb { background: none !important; border: 0 !important; padding: 24px 0 18px !important; margin: 0 !important; box-shadow: none !important; }
.calc-head--bb::before, .calc-head--bb::after { content: none !important; }
.calc-head--bb .crumbs { margin: 0 0 12px; font-size: 13px; font-weight: 500; color: var(--bb-mute); }
.calc-head--bb .crumbs a { color: var(--bb-mute); }
.calc-head--bb h1 { margin: 0; font-size: clamp(30px, 3.6vw, 42px); line-height: 1.08; font-weight: 800; letter-spacing: -.025em; color: var(--bb-ink); }
.calc-head--bb .calc-head__title { display: flex; align-items: center; gap: 14px; }
.calc-head--bb .calc-head__icon { flex: none; display: grid; place-items: center; width: 52px; height: 52px; background: var(--bb-ink); color: #fff; border-radius: 0; }
.calc-head--bb .calc-head__lede { margin: 12px 0 0; max-width: 720px; font-size: 17px; line-height: 1.5; color: #3d4a60; }
.calc-head--bb .calc-meta { margin-top: 12px; font-family: var(--sans); font-size: 13px; color: var(--bb-mute); }

/* Main column + right rail. */
.calc-layout { display: grid; grid-template-columns: minmax(0, 1fr) 312px; gap: 0 48px; align-items: start; }
.calc-layout__main { min-width: 0; }
.calc-layout__main > .calc { margin-top: 0; background: #fff; border-radius: 0; box-shadow: none; border: 0; }
.calc-layout__main .calc-explain { margin-top: 32px; display: grid; gap: 16px; }
.calc-layout__main .calc-section, .calc-layout__main .calc-faq, .calc-layout__main .calc-salaries, .calc-layout__main .calc-app { background: #fff; border: 0 !important; border-radius: 0 !important; box-shadow: none !important; padding: 24px 28px; }
.calc-layout__main .calc-faq, .calc-layout__main .calc-salaries { margin-top: 16px; }
.calc-layout__main .calc-actions { margin-top: 12px; }
.calc-layout__main .calc-disclaimer { margin-top: 24px; border-top: 1px solid var(--bb-line); }
.calc-rail { display: grid; gap: 28px; position: sticky; top: 16px; padding-top: 24px; }
.calc-rail__head { margin: 0 0 10px !important; font-size: 19px !important; line-height: 1.2; font-weight: 700; color: var(--bb-ink); }
.calc-rail__list { display: grid; gap: 10px; margin: 0; padding: 0; list-style: none; }
.calc-rail__list li { margin: 0; }
.calc-rail__text { display: flex; flex-direction: column; gap: 6px; padding: 12px; background: #fff; color: var(--bb-ink); text-decoration: none; }
.calc-rail__text strong { font-size: 15px; line-height: 1.3; }
.calc-rail__text span { font-size: 13px; line-height: 1.4; color: var(--bb-mute); }
.calc-rail__text:hover strong, .calc-rail__pic:hover strong { text-decoration: underline; text-underline-offset: 3px; }
.calc-rail__pic { display: block; background: #fff; color: var(--bb-ink); text-decoration: none; }
.calc-rail__pic img { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; }
.calc-rail__pic strong { display: block; padding: 10px 12px 14px; font-size: 15px; line-height: 1.3; }
.calc-rail .calc-trust { margin: 0; background: #fff; border: 0 !important; border-radius: 0 !important; box-shadow: none !important; }

/* Calculator cards: hub groups and the All calculators grid. */
.cc-grid { display: grid !important; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--bb-gap); margin: 0 !important; padding: 0 !important; list-style: none; max-width: none !important; }
.cc-grid li { margin: 0 !important; }
.cc-card { display: flex; gap: 12px; align-items: flex-start; height: 100%; box-sizing: border-box; padding: 16px; background: #fff; color: var(--bb-ink); text-decoration: none; }
.cc-card__icon { flex: none; display: grid; place-items: center; width: 40px; height: 40px; background: var(--bb-ink); color: #fff; }
.cc-card__icon .calc-icon { width: 22px; height: 22px; }
.cc-card__text { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.cc-card__text strong { font-size: 15.5px; line-height: 1.3; }
.cc-card__text span { font-size: 13.5px; line-height: 1.4; color: var(--bb-mute); }
.cc-card:hover strong { text-decoration: underline; text-underline-offset: 3px; }
.cc-grid--compact { grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 10px; }
.cc-grid--compact .cc-card { padding: 12px; align-items: center; }
.cc-grid--compact .cc-card__icon { width: 32px; height: 32px; }
.cc-grid--compact .cc-card__text strong { font-size: 14px; }
.cc-all { margin-top: 48px; padding-top: 8px; }
.cc-all__group { margin: 20px 0 10px !important; font-size: 15px !important; font-weight: 700; color: var(--bb-mute); }

/* Hub: Bitesize-style tiles, then a card grid per group. */
.hub-page .calc-head--bb h1 { font-size: clamp(32px, 4vw, 46px); }
.hub-tiles { display: grid !important; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--bb-gap); margin: 8px 0 0 !important; padding: 0 !important; list-style: none; max-width: none !important; }
.hub-tiles li { margin: 0 !important; }
.hub-tile { display: flex; flex-direction: column; gap: 8px; height: 100%; box-sizing: border-box; padding: 20px; background: var(--bb-ink); color: #fff !important; text-decoration: none; }
.hub-tile__icon { display: grid; place-items: center; width: 48px; height: 48px; background: rgba(255, 255, 255, .12); color: #fff; }
.hub-tile strong { margin-top: 18px; font-size: 19px; line-height: 1.2; }
.hub-tile span:last-child { font-size: 13.5px; color: rgba(255, 255, 255, .78); }
.hub-tile:hover strong { text-decoration: underline; text-underline-offset: 3px; }
.hub-page .hub-search { margin: 24px 0 0 !important; max-width: 640px !important; }
.hub-page .hub-search input { width: 100%; min-height: 48px; padding: 0 16px; border: 2px solid var(--bb-ink); border-radius: 0; font: inherit; font-size: 16px; background: #fff; color: var(--bb-ink); box-sizing: border-box; }
.hub-page .hub-intro { margin: 12px 0 0 !important; font-size: 14.5px !important; color: var(--bb-mute) !important; }
.hub-page .hub-group { margin: 40px 0 0; padding: 0; background: none; border: 0; }
.hub-page .hub-salaries { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 !important; max-width: none !important; }
.hub-page .hub-salaries a { display: inline-flex; align-items: center; min-height: 40px; padding: 0 14px; background: #fff; color: var(--bb-ink); font-family: var(--sans); font-size: 14.5px; font-weight: 600; text-decoration: none; }
.hub-page .hub-salaries a:hover { text-decoration: underline; }
.hub-page .hub-below, .hub-page .calc-faq { margin-top: 32px; background: #fff; padding: 24px 28px; border: 0 !important; border-radius: 0 !important; box-shadow: none !important; }

@media (max-width: 1100px) {
  .calc-layout { grid-template-columns: minmax(0, 1fr) 260px; gap: 0 32px; }
  .cc-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .cc-grid--compact { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
  .calc-layout { grid-template-columns: 1fr; }
  .calc-rail { position: static; padding-top: 32px; }
  .hub-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cc-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cc-grid--compact { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 560px) {
  .cc-grid, .cc-grid--compact { grid-template-columns: 1fr; }
  .calc-layout__main .calc-section, .calc-layout__main .calc-faq, .calc-layout__main .calc-salaries { padding: 18px 16px; }
  .hub-tile strong { margin-top: 8px; font-size: 17px; }
}
/* The page column lines up with the band and masthead: 1248px plus gutters. */
.calc-shell--bb .calc-main .wrap { max-width: calc(var(--page, 1248px) + 2 * var(--gutter, 24px)) !important; margin: 0 auto !important; padding: 0 var(--gutter, 24px) 64px !important; box-sizing: border-box; }
.calc-shell--bb .calc-faq, .calc-shell--bb .calc-salaries { max-width: none !important; }
.hub-page .hub-below { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 32px; align-items: start; }
.hub-page .hub-below .calc-section, .hub-page .hub-below .calc-trust { margin: 0; padding: 0; background: none; border: 0 !important; box-shadow: none !important; }
@media (max-width: 900px) { .hub-page .hub-below { grid-template-columns: 1fr; } }
/* Salary, area, methodology and firms pages keep their own header markup;
   on the BBC shell it sits on the grey ground, aligned to the band. */
.calc-shell--bb .calc-main > .calc-head, .calc-shell--bb .calc-main > .hub-hero { background: none !important; border: 0 !important; box-shadow: none !important; padding: 24px 0 12px !important; margin: 0 !important; }
.calc-shell--bb .calc-main > .calc-head::before, .calc-shell--bb .calc-main > .calc-head::after, .calc-shell--bb .calc-main > .hub-hero::before, .calc-shell--bb .calc-main > .hub-hero::after { content: none !important; }
.calc-shell--bb .calc-main .calc-head__inner, .calc-shell--bb .calc-main .hub-hero__inner { max-width: calc(var(--page, 1248px) + 2 * var(--gutter, 24px)) !important; margin: 0 auto !important; padding: 0 var(--gutter, 24px) !important; box-sizing: border-box; }
.calc-shell--bb .calc-main > .calc-head h1, .calc-shell--bb .calc-main > .hub-hero h1 { font-size: clamp(30px, 3.6vw, 42px); line-height: 1.08; font-weight: 800; letter-spacing: -.025em; color: var(--bb-ink); }
.calc-shell--bb .calc-main > .calc-head .crumbs, .calc-shell--bb .calc-main > .hub-hero .crumbs { font-size: 13px; font-weight: 500; color: var(--bb-mute); }
.calc-shell--bb .calc-main > .calc-head .calc-head__icon { background: var(--bb-ink); color: #fff; border-radius: 0; }
.calc-shell--bb .calc-main .calc, .calc-shell--bb .calc-main .calc-section, .calc-shell--bb .calc-main .calc-table-wrap { border-radius: 0 !important; }
/* A wide rate table inside an explanation scrolls rather than widening the page. */
.calc-layout__main .calc-section { overflow-x: auto; }

/* Rail: Follow LedgerTouch. Ink buttons on the grey ground (design rule). */
.calc-follow { padding: 16px; background: #fff; }
.calc-follow p { margin: 0 0 12px; font-size: 14px; line-height: 1.45; color: var(--bb-mute); }
.calc-follow__list { display: grid; gap: 8px; margin: 0; padding: 0; list-style: none; }
.calc-follow__list li { margin: 0; }
.calc-follow__btn { display: flex; align-items: center; gap: 10px; min-height: 44px; padding: 0 14px; background: var(--bb-ink, #16243c); color: #fff !important; font-weight: 700; font-size: 14.5px; text-decoration: none !important; }
.calc-follow__btn:hover { background: #24375a; }
.calc-follow__btn:focus-visible { outline: 2px solid var(--bb-ink, #16243c); outline-offset: 2px; }
.calc-follow__btn svg { flex: none; }
