/* McSherry Tech site styles (website v5). Visual design follows the McSherry Tech brand guidelines v1.0
   (29 October 2026): Deep Charcoal #121820, Premium Gold #F5B335 for accents only (never text on white),
   Pure White, Light Grey #CACACA, and Arial. Neutral greys between them are derived for text and rules. */

:root {
  --brand-navy: #121820;
  --brand-gold: #F5B335;
  --brand-gold-ink: #121820;
  --brand-paper: #F5F5F5;
  --brand-gray: #5C6169;
  --white: #FFFFFF;
  --surface: #FFFFFF;
  --paper: #F5F5F5;
  --ink: #121820;
  --text: #121820;
  --muted: #5C6169;
  --steel: #5C6169;
  --rule: #DEDEDE;
  --rule-strong: #8A8A8A;
  --brass: #F5B335;
  --brass-dark: #121820;
  --brass-light: #F5B335;
  --focus: #121820;
  --error: #A3261B;
  --ok: #1F6B45;
  --btn-bg: #121820;
  --btn-fg: #FFFFFF;
  --btn-hover: #2A313B;
  --band-dark: #121820;
  --core: #121820;
  --note-bg: #FEF7E7;
  --note-border: #F2D08A;
  --header-shadow: rgba(18, 24, 32, 0.08);
  --bar: #F5B335;
  --card-shadow: 0 1px 2px rgba(18, 24, 32, 0.04), 0 12px 32px -18px rgba(18, 24, 32, 0.28);
  --skyline: url("/assets/art/towers-light.svg");
  --grid-line: rgba(18, 24, 32, 0.045);
  color-scheme: light;
  --serif: Arial, Helvetica, sans-serif;
  --sans: Arial, Helvetica, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
  --wrap: 1140px;
  --measure: 68ch;
  --gutter: clamp(16px, 4vw, 40px);
  --radius: 6px;
}

/* Dark theme: follows the system setting unless the visitor picks a theme with the toggle */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
  --surface: #121820;
  --paper: #1A212B;
  --ink: #FFFFFF;
  --text: #E1E3E6;
  --muted: #A9ADB3;
  --steel: #CACACA;
  --rule: #2A313B;
  --rule-strong: #5C6169;
  --brass: #F5B335;
  --brass-dark: #F5B335;
  --brass-light: #F5B335;
  --focus: #F5B335;
  --error: #FF8B7B;
  --ok: #6FD0A0;
  --btn-bg: #F5B335;
  --btn-fg: #121820;
  --btn-hover: #F7C45E;
  --band-dark: #0B0F14;
  --core: #E1E3E6;
  --note-bg: #2B2414;
  --note-border: #7A5E1F;
  --header-shadow: rgba(0, 0, 0, 0.45);
  --bar: #F5B335;
  --card-shadow: 0 1px 2px rgba(0, 0, 0, 0.3), 0 16px 36px -20px rgba(0, 0, 0, 0.8);
  --skyline: url("/assets/art/towers-dark.svg");
  --grid-line: rgba(255, 255, 255, 0.04);
  color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --surface: #121820;
  --paper: #1A212B;
  --ink: #FFFFFF;
  --text: #E1E3E6;
  --muted: #A9ADB3;
  --steel: #CACACA;
  --rule: #2A313B;
  --rule-strong: #5C6169;
  --brass: #F5B335;
  --brass-dark: #F5B335;
  --brass-light: #F5B335;
  --focus: #F5B335;
  --error: #FF8B7B;
  --ok: #6FD0A0;
  --btn-bg: #F5B335;
  --btn-fg: #121820;
  --btn-hover: #F7C45E;
  --band-dark: #0B0F14;
  --core: #E1E3E6;
  --note-bg: #2B2414;
  --note-border: #7A5E1F;
  --header-shadow: rgba(0, 0, 0, 0.45);
  --bar: #F5B335;
  --card-shadow: 0 1px 2px rgba(0, 0, 0, 0.3), 0 16px 36px -20px rgba(0, 0, 0, 0.8);
  --skyline: url("/assets/art/towers-dark.svg");
  --grid-line: rgba(255, 255, 255, 0.04);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--surface);
  color: var(--text);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.6;
}

img, svg { max-width: 100%; height: auto; }

h1, h2, h3, h4 {
  font-family: var(--serif);
  color: var(--ink);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.015em;
  margin: 0 0 0.5em;
  text-wrap: balance;
}
h1 { font-size: clamp(2.1rem, 1.6rem + 2.2vw, 3.1rem); line-height: 1.08; }
h2 { font-size: clamp(1.55rem, 1.35rem + 0.8vw, 1.95rem); margin-top: 0; }
h3 { font-size: 1.3rem; line-height: 1.25; }
h4 { font-size: 1.1rem; }

p, ul, ol, dl, table, figure, blockquote { margin: 0 0 1.1em; }
ul, ol { padding-left: 1.3em; }
li { margin-bottom: 0.4em; }
li::marker { color: var(--steel); }

a {
  color: var(--ink);
  text-decoration-line: underline;
  text-decoration-color: var(--brass);
  text-decoration-thickness: 1.5px;
  text-underline-offset: 3px;
}
a:hover { text-decoration-color: var(--ink); }

:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
  border-radius: 2px;
}

strong { font-weight: 650; color: var(--ink); }
code, kbd, pre { font-family: var(--mono); font-size: 0.88em; }
code { background: var(--paper); border: 1px solid var(--rule); border-radius: 3px; padding: 0.05em 0.35em; overflow-wrap: anywhere; }
pre { background: var(--paper); border: 1px solid var(--rule); border-radius: var(--radius); padding: 1em; overflow-x: auto; }
pre code { background: none; border: 0; padding: 0; }

hr { border: 0; border-top: 1px solid var(--rule); margin: 2.5rem 0; }

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  overflow: hidden; clip: rect(0 0 0 0);
  white-space: nowrap; border: 0; padding: 0; margin: -1px;
}

.skip-link {
  position: absolute; left: 12px; top: -48px;
  background: var(--band-dark); color: var(--white);
  padding: 10px 14px; border-radius: var(--radius); z-index: 100;
  text-decoration: none;
}
.skip-link:focus { top: 12px; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }
.measure { max-width: var(--measure); }

/* ---------- Header ---------- */

.site-header {
  background: var(--surface);
  border-bottom: 1px solid var(--rule);
  position: relative;
  z-index: 20;
}
.site-header .wrap {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px; min-height: 90px;
}
.brand { display: inline-flex; align-items: center; text-decoration: none; flex-shrink: 0; margin-right: auto; }
.brand .logo-dark { display: none; }
:root[data-theme="dark"] .brand .logo-light { display: none; }
:root[data-theme="dark"] .brand .logo-dark { display: block; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .brand .logo-light { display: none; }
  :root:not([data-theme="light"]) .brand .logo-dark { display: block; }
}
.site-nav { order: 2; }
.theme-toggle {
  order: 3; flex-shrink: 0;
  display: inline-flex; align-items: center; justify-content: center;
  width: 40px; height: 40px; padding: 0;
  color: var(--ink); background: none;
  border: 1px solid var(--rule-strong); border-radius: var(--radius); cursor: pointer;
}
.theme-toggle:hover { background: var(--paper); }
.theme-toggle svg { width: 20px; height: 20px; }
.theme-toggle .icon-sun { display: none; }
:root[data-theme="dark"] .theme-toggle .icon-sun { display: block; }
:root[data-theme="dark"] .theme-toggle .icon-moon { display: none; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme-toggle .icon-sun { display: block; }
  :root:not([data-theme="light"]) .theme-toggle .icon-moon { display: none; }
}
.no-js .theme-toggle { display: none; }
.brand { padding: 14px 0; }
.brand img { display: block; width: 320px; height: auto; } /* brand guidelines v1.0: horizontal logo at least 320 px wide on screen */

.nav-toggle {
  display: none; order: 4;
  font: inherit; font-weight: 600; font-size: 0.95rem;
  color: var(--ink); background: none;
  border: 1px solid var(--rule-strong); border-radius: var(--radius);
  padding: 8px 14px; cursor: pointer;
}

.site-nav ul {
  list-style: none; margin: 0; padding: 0;
  display: flex; align-items: center; gap: 4px;
}
.site-nav li { margin: 0; }
.site-nav a {
  display: block; padding: 8px 12px;
  color: var(--ink); text-decoration: none; font-weight: 500; font-size: 0.98rem;
  border-radius: var(--radius);
}
.site-nav a:hover { background: var(--paper); }
.site-nav a[aria-current="page"] {
  text-decoration: underline; text-decoration-color: var(--brass);
  text-decoration-thickness: 2px; text-underline-offset: 8px;
}
.site-nav .nav-cta { margin-left: 10px; }
.site-nav .nav-cta a { background: var(--btn-bg); color: var(--btn-fg); padding: 9px 16px; font-weight: 600; }
.site-nav .nav-cta a:hover { background: var(--btn-hover); }

@media (max-width: 1180px) {
  .nav-toggle { display: inline-block; }
  .site-nav { display: none; position: absolute; left: 0; right: 0; top: 100%; background: var(--surface); border-bottom: 1px solid var(--rule); box-shadow: 0 12px 24px var(--header-shadow); }
  .site-nav.is-open { display: block; }
  .site-nav ul { flex-direction: column; align-items: stretch; padding: 8px var(--gutter) 20px; gap: 0; }
  .site-nav a { padding: 12px 4px; border-bottom: 1px solid var(--rule); border-radius: 0; }
  .site-nav .nav-cta { margin: 16px 0 0; }
  .site-nav .nav-cta a { text-align: center; border-radius: var(--radius); border-bottom: 0; }
  .no-js .site-nav { display: block; position: static; box-shadow: none; border: 0; }
  .no-js .nav-toggle { display: none; }
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-block;
  font: inherit; font-weight: 600; font-size: 1rem; line-height: 1.2;
  text-align: center; text-decoration: none;
  padding: 14px 22px;
  border-radius: var(--radius);
  border: 2px solid var(--btn-bg);
  background: var(--btn-bg); color: var(--btn-fg);
  cursor: pointer;
}
.btn:hover { background: var(--btn-hover); border-color: var(--btn-hover); }
.btn-secondary { background: transparent; color: var(--ink); }
.btn-secondary:hover { background: var(--paper); border-color: var(--ink); }
.btn[disabled] { opacity: 0.6; cursor: progress; }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; margin: 1.6em 0 0; }
.btn-row:first-child { margin-top: 0; }

.on-dark { --focus: #F5B335; color: #E1E3E6; }
.on-dark h2, .on-dark h3, .on-dark strong { color: var(--white); }
.on-dark a { color: var(--white); text-decoration-color: #F5B335; }
.on-dark .btn { background: #F5B335; color: #121820; border-color: #F5B335; }
.on-dark .btn:hover { background: #FFFFFF; border-color: #FFFFFF; }
.on-dark .btn-secondary { background: transparent; color: var(--white); border-color: rgba(255, 255, 255, 0.55); }
.on-dark .btn-secondary:hover { background: rgba(255, 255, 255, 0.08); border-color: var(--white); }

/* ---------- Sections ---------- */

main { display: block; }
.section { padding: clamp(48px, 7vw, 88px) 0; }
.section + .section { padding-top: 0; }
.band { background: var(--paper); border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); }
.band + .section, .section + .band { padding-top: clamp(48px, 7vw, 88px); }
.band + .band { border-top: 0; }

.section-head { max-width: var(--measure); margin-bottom: 2rem; }
.section-head p { color: var(--muted); font-size: 1.08rem; margin-bottom: 0; }

.lede { font-size: clamp(1.12rem, 1.04rem + 0.35vw, 1.28rem); line-height: 1.55; color: var(--text); max-width: 62ch; }

/* The brass rule under each page title echoes the bar on the nameplate */
.titled { position: relative; padding-bottom: 0.55em; margin-bottom: 0.55em; }
.titled::after {
  content: ""; position: absolute; left: 0; bottom: 0;
  width: 64px; height: 4px; background: var(--brass);
}

/* ---------- Page heads ---------- */

.page-head { padding: clamp(44px, 6vw, 80px) 0 clamp(32px, 4vw, 52px); }
.page-head .lede { margin-bottom: 0; }
.page-head .btn-row { margin-top: 1.8em; }
.crumb { font-size: 0.95rem; margin: 0 0 1.2rem; color: var(--muted); }
.crumb a { color: var(--muted); }

/* ---------- Home hero ---------- */

.hero { padding: clamp(48px, 7vw, 96px) 0 clamp(48px, 6vw, 80px); }
.hero .wrap { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr); gap: clamp(32px, 5vw, 72px); align-items: center; }
.hero h1 { font-size: clamp(2.3rem, 1.6rem + 3vw, 3.6rem); max-width: 18ch; }
.hero .lede { margin-bottom: 0; }
@media (max-width: 860px) { .hero .wrap { grid-template-columns: 1fr; } }

/* ---------- Rating plate: label/value facts, like a server's rating plate ---------- */

.plate {
  border: 1px solid var(--rule-strong);
  border-top: 4px solid var(--bar);
  border-radius: var(--radius);
  background: var(--surface);
  padding: 22px 24px 20px;
}
.plate-title { font-family: var(--serif); font-weight: 600; font-size: 1.05rem; color: var(--ink); margin: 0 0 14px; }
.facts { display: grid; grid-template-columns: max-content 1fr; gap: 0; margin: 0; }
.facts dt, .facts dd { margin: 0; padding: 9px 0; border-top: 1px solid var(--rule); }
.facts dt { color: var(--muted); font-size: 0.92rem; padding-right: 18px; }
.facts dd { color: var(--ink); font-weight: 500; }
.facts dt:first-of-type, .facts dt:first-of-type + dd { border-top: 0; }
.offers.three .facts { grid-template-columns: 1fr; }
.offers.three .facts dt { padding-bottom: 2px; }
.offers.three .facts dd { border-top: 0; padding-top: 0; }

/* ---------- Core grid figure ---------- */

.cores { margin: 0; }
.cores-cpu { display: grid; grid-template-columns: 64px 1fr; align-items: center; gap: 12px; margin-bottom: 10px; }
.cores-cpu-label { font-size: 0.85rem; color: var(--muted); }
.cores-cells { display: grid; grid-template-columns: repeat(16, minmax(0, 1fr)); gap: 4px; }
.core { aspect-ratio: 1; border-radius: 2px; background: var(--core); }
.core.is-billed {
  background: repeating-linear-gradient(135deg, transparent 0 3px, rgba(245, 179, 53, 0.6) 3px 4.5px);
  box-shadow: inset 0 0 0 1.5px var(--brass);
}
.cores-legend { display: flex; flex-wrap: wrap; gap: 8px 22px; list-style: none; padding: 0; margin: 16px 0 0; font-size: 0.9rem; color: var(--muted); }
.cores-legend li { display: flex; align-items: center; gap: 8px; margin: 0; }
.cores-legend .core { width: 14px; display: inline-block; }
.cores-sum { font-family: var(--serif); font-size: 1.35rem; line-height: 1.3; color: var(--ink); margin: 18px 0 0; }
.cores-note { font-size: 0.9rem; color: var(--muted); margin: 6px 0 0; }

/* ---------- Offers ---------- */

.offers { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(20px, 3vw, 36px); }
@media (max-width: 820px) { .offers { grid-template-columns: 1fr; } }
.offers.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 1080px) { .offers.three { grid-template-columns: 1fr; } }
.offer .kicker { font-size: 0.8rem; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--brass-dark); margin-bottom: 0.5em; }
.offer h3 { font-size: 1.45rem; margin-bottom: 0.4em; }
.offer .for { color: var(--muted); }
.offer ul { margin-bottom: 1.2em; }
.offer .terms { font-weight: 600; color: var(--ink); margin-bottom: 0.4em; }
.offer .note { font-size: 0.93rem; color: var(--muted); }
.offer .btn-row { margin-top: 1.2em; }
.plate.offer { padding: 26px 28px 28px; display: flex; flex-direction: column; }
.plate.offer .btn-row { margin-top: auto; padding-top: 0.6em; }

/* ---------- Steps (a real sequence) ---------- */

.steps { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(20px, 3vw, 40px); counter-reset: step; }
.steps li { counter-increment: step; margin: 0; padding-top: 16px; border-top: 2px solid var(--ink); }
.steps li::before { content: counter(step); display: block; font-family: var(--serif); font-weight: 600; font-size: 2rem; line-height: 1; color: var(--brass-dark); margin-bottom: 10px; }
.steps h3 { font-size: 1.2rem; margin-bottom: 0.35em; }
.steps p { margin: 0; color: var(--text); }
@media (max-width: 760px) { .steps { grid-template-columns: 1fr; } }

.timeline { list-style: none; padding: 0; margin: 0 0 1.1em; }
.timeline li { display: grid; grid-template-columns: 9rem 1fr; gap: 16px; padding: 14px 0; border-top: 1px solid var(--rule); margin: 0; }
.timeline li:last-child { border-bottom: 1px solid var(--rule); }
.timeline .when { font-family: var(--serif); font-weight: 600; color: var(--ink); }
@media (max-width: 560px) { .timeline li { grid-template-columns: 1fr; gap: 2px; } }

/* ---------- Principles ---------- */

.principles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(20px, 3vw, 40px); }
.principles h3 { font-size: 1.15rem; margin-bottom: 0.35em; }
.principles p { margin: 0; }
@media (max-width: 760px) { .principles { grid-template-columns: 1fr; } }
.principles.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (max-width: 760px) { .principles.two { grid-template-columns: 1fr; } }

/* ---------- Prose and tables ---------- */

.prose { max-width: var(--measure); }
.prose h2 { margin-top: 2.2em; }
.prose h3 { margin-top: 1.8em; }
.prose > :first-child { margin-top: 0; }

.table-wrap { overflow-x: auto; margin: 0 0 1.4em; -webkit-overflow-scrolling: touch; }
table { border-collapse: collapse; width: 100%; font-size: 0.97rem; }
th, td { text-align: left; vertical-align: top; padding: 11px 14px 11px 0; border-bottom: 1px solid var(--rule); }
th { font-weight: 600; color: var(--ink); border-bottom: 2px solid var(--ink); font-size: 0.92rem; }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; padding-right: 0; padding-left: 14px; }
tfoot td { font-weight: 650; color: var(--ink); border-bottom: 0; border-top: 2px solid var(--ink); }
table.compact th, table.compact td { padding-right: 10px; }

.qa { max-width: var(--measure); }
.qa h3 { font-family: var(--sans); font-size: 1.05rem; font-weight: 650; letter-spacing: 0; margin: 1.6em 0 0.35em; }
.qa h3:first-child { margin-top: 0; }
.qa p { margin-bottom: 0; }

.aside-note { border-left: 3px solid var(--brass); padding: 4px 0 4px 18px; color: var(--text); max-width: var(--measure); }

/* ---------- Two-column layouts ---------- */

.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(28px, 5vw, 64px); align-items: start; }
.split-wide { grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); }
@media (max-width: 860px) { .split, .split-wide { grid-template-columns: 1fr; } }

/* ---------- Posts list ---------- */

.post-list { list-style: none; padding: 0; margin: 0; }
.post-list li { margin: 0; padding: 20px 0; border-top: 1px solid var(--rule); }
.post-list li:last-child { border-bottom: 1px solid var(--rule); }
.post-list h3 { font-size: 1.22rem; margin: 0 0 0.3em; }
.post-list h3 a { text-decoration: none; }
.post-list h3 a:hover { text-decoration: underline; text-decoration-color: var(--brass); }
.post-list p { margin: 0; color: var(--muted); max-width: var(--measure); }
.post-list .meta { font-size: 0.9rem; color: var(--muted); margin-top: 6px; }

.hubs { display: grid; gap: clamp(40px, 6vw, 64px); }
.hub { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.6fr); gap: clamp(20px, 4vw, 56px); }
.hub-head h2 { margin-bottom: 0.35em; }
.hub-head p { color: var(--muted); margin-bottom: 0.8em; }
.hub-head .paired { font-size: 0.95rem; color: var(--text); }
@media (max-width: 860px) { .hub { grid-template-columns: 1fr; } }
.hub-index { list-style: none; display: flex; flex-wrap: wrap; gap: 8px 22px; padding: 0; margin: 1.4rem 0 0; }
.hub-index li { margin: 0; }

/* ---------- Resources ---------- */

.resource { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px 32px; padding: 28px 0; border-top: 1px solid var(--rule); }
.resource:last-of-type { border-bottom: 1px solid var(--rule); }
.resource h2 { font-size: 1.45rem; margin-bottom: 0.25em; }
.resource .status { font-size: 0.92rem; color: var(--brass-dark); font-weight: 600; margin-bottom: 0.6em; }
.resource .status.soon { color: var(--muted); }
.resource p { max-width: 62ch; }
.resource .for { color: var(--muted); font-size: 0.97rem; margin-bottom: 0; }
.resource .actions { align-self: start; padding-top: 6px; }
@media (max-width: 720px) { .resource { grid-template-columns: 1fr; } .resource .actions { padding-top: 10px; } }
.resource details { grid-column: 1 / -1; }
.resource summary { cursor: pointer; font-weight: 600; color: var(--ink); display: inline-block; padding: 10px 16px; border: 2px solid var(--ink); border-radius: var(--radius); list-style: none; }
.resource summary::-webkit-details-marker { display: none; }
.resource details[open] summary { background: var(--paper); }
.resource details .signup { margin-top: 16px; max-width: 560px; }

/* ---------- Forms ---------- */

.form-panel { background: var(--surface); border: 1px solid var(--rule-strong); border-top: 4px solid var(--bar); border-radius: var(--radius); padding: clamp(22px, 3vw, 32px); }
.form-panel h2, .form-panel h3 { margin-bottom: 0.4em; }
.field { margin-bottom: 18px; }
.field label, .field legend { display: block; font-weight: 600; color: var(--ink); margin-bottom: 6px; font-size: 0.98rem; }
.field .req { color: var(--brass-dark); }
.field .help { display: block; font-size: 0.9rem; color: var(--muted); margin: -2px 0 6px; }
input[type="text"], input[type="email"], input[type="number"], select, textarea {
  width: 100%;
  font: inherit; font-size: 1rem; color: var(--text);
  background: var(--surface);
  border: 1px solid var(--rule-strong); border-radius: var(--radius);
  padding: 11px 12px;
  min-height: 46px;
}
textarea { min-height: 140px; resize: vertical; }
input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 3px solid var(--focus); outline-offset: 0; border-color: var(--ink); }
input[aria-invalid="true"], select[aria-invalid="true"], textarea[aria-invalid="true"] { border-color: var(--error); }
.field-error { display: block; color: var(--error); font-size: 0.92rem; margin-top: 6px; font-weight: 500; }
.field-error:empty { display: none; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }
@media (max-width: 560px) { .form-row { grid-template-columns: 1fr; } }
.disclosure { font-size: 0.9rem; color: var(--muted); margin: 12px 0 0; }
.form-status { margin: 14px 0 0; font-weight: 600; }
.form-status:empty { display: none; }
.form-status.is-ok { color: var(--ok); }
.form-status.is-error { color: var(--error); }
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

.signup .form-row { align-items: end; }
.signup .btn { width: 100%; }

.choice-list { display: flex; flex-wrap: wrap; gap: 8px; border: 0; padding: 0; margin: 0 0 16px; }
.choice-list legend { margin-bottom: 10px; }
.choice-list label { display: inline-flex; align-items: center; gap: 8px; padding: 9px 14px; border: 1px solid var(--rule-strong); border-radius: var(--radius); cursor: pointer; font-weight: 500; margin: 0; }
.choice-list input { accent-color: var(--ink); margin: 0; }
.choice-list label:has(input:checked) { border-color: var(--ink); background: var(--paper); }

/* ---------- Calculator ---------- */

.calc { display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: clamp(24px, 4vw, 48px); align-items: start; }
@media (max-width: 900px) { .calc { grid-template-columns: 1fr; } }
.calc-inputs .field input { max-width: 220px; }
.calc-inputs .check { display: flex; gap: 10px; align-items: flex-start; margin: 4px 0 20px; font-size: 0.95rem; max-width: 46ch; }
.calc-inputs .check .help { display: block; color: var(--muted); font-size: 0.9rem; margin-top: 2px; }
.calc-inputs .check input { margin-top: 4px; accent-color: var(--ink); width: 18px; height: 18px; flex-shrink: 0; }
.calc-results[hidden] { display: none; }
.calc-numbers { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0; border: 1px solid var(--rule-strong); border-top: 4px solid var(--bar); border-radius: var(--radius); margin: 0 0 18px; }
.calc-numbers div { padding: 14px 16px; border-left: 1px solid var(--rule); }
.calc-numbers div:first-child { border-left: 0; }
.calc-numbers dt { font-size: 0.86rem; color: var(--muted); margin-bottom: 4px; }
.calc-numbers dd { margin: 0; font-family: var(--serif); font-size: 1.9rem; font-weight: 600; color: var(--ink); line-height: 1.1; font-variant-numeric: tabular-nums; }
.calc-numbers .gap dd { color: var(--brass-dark); }
.calc-numbers .cost { grid-column: 1 / -1; border-left: 0; border-top: 1px solid var(--rule); }
.calc-numbers .cost[hidden] { display: none; }
@media (max-width: 520px) { .calc-numbers { grid-template-columns: 1fr; } .calc-numbers div { border-left: 0; border-top: 1px solid var(--rule); } .calc-numbers div:first-child { border-top: 0; } }
.calc-messages p { margin: 0 0 0.6em; }
.calc-disclaimer { font-size: 0.9rem; color: var(--muted); }
.calc-keep { margin-top: 28px; }
.calc-host-label { font-size: 0.92rem; color: var(--muted); margin: 0 0 10px; }

/* ---------- Checklist boxes inside posts ---------- */

.upgrade-box { background: var(--paper); border: 1px solid var(--rule); border-left: 4px solid var(--brass); border-radius: var(--radius); padding: 22px 24px; margin: 2.2em 0; }
.upgrade-box h2, .upgrade-box h3 { font-size: 1.3rem; margin: 0 0 0.35em; }
.upgrade-box p { margin-bottom: 0.9em; }
.upgrade-box .btn-row { margin-top: 0.4em; }
.upgrade-box .share { font-size: 0.95rem; margin: 14px 0 0; }
.upgrade-box form { margin-top: 6px; }

/* ---------- Article ---------- */

.article-head { padding: clamp(40px, 6vw, 72px) 0 clamp(24px, 3vw, 36px); }
.article-head .hub-link { font-size: 0.95rem; margin: 0 0 1rem; }
.article-head h1 { max-width: 24ch; font-size: clamp(2rem, 1.55rem + 2vw, 2.85rem); }
.article-head .subtitle { font-size: 1.2rem; color: var(--text); max-width: 60ch; margin-bottom: 1em; }
.article-head .byline { font-size: 0.95rem; color: var(--muted); margin: 0; }
.article { padding-bottom: clamp(48px, 6vw, 80px); }
.article-body { max-width: var(--measure); font-size: 1.08rem; line-height: 1.7; }
.article-body h2 { font-size: 1.6rem; margin: 2em 0 0.6em; }
.article-body h3 { font-size: 1.25rem; margin: 1.7em 0 0.5em; }
.article-body .pull-quote { font-family: var(--serif); font-size: 1.35rem; line-height: 1.45; color: var(--ink); border-left: 3px solid var(--brass); padding: 4px 0 4px 22px; margin: 1.8em 0; }
.article-body .callout { background: var(--paper); border: 1px solid var(--rule); border-radius: var(--radius); padding: 18px 20px; margin: 1.8em 0; }
.article-body .callout-label { font-weight: 650; color: var(--ink); margin-bottom: 0.4em; }
.article-body .callout > :last-child { margin-bottom: 0; }
.article-foot { max-width: var(--measure); border-top: 1px solid var(--rule); padding-top: 22px; margin-top: 2.4em; font-size: 0.97rem; }
.article-foot p { margin-bottom: 0.6em; }

/* ---------- CTA band ---------- */

.cta-band { background: var(--band-dark); padding: clamp(48px, 7vw, 80px) 0; }
.cta-band .wrap { display: grid; grid-template-columns: minmax(0, 1.2fr) auto; gap: 24px 48px; align-items: center; }
.cta-band h2 { margin-bottom: 0.3em; }
.cta-band p { margin: 0; max-width: 56ch; }
.cta-band .btn-row { margin: 0; justify-content: flex-end; }
@media (max-width: 820px) { .cta-band .wrap { grid-template-columns: 1fr; } .cta-band .btn-row { justify-content: flex-start; } }

/* ---------- Footer ---------- */

.site-footer { border-top: 1px solid rgba(245, 179, 53, 0.45); background: #0B0F14; color: #CACACA; font-size: 0.95rem; padding: 56px 0 28px; --focus: #F5B335; }
.site-footer a { color: #F2F2F2; text-decoration-color: rgba(245, 179, 53, 0.55); }
.site-footer a:hover { color: var(--white); text-decoration-color: #F5B335; }
.footer-grid { display: grid; grid-template-columns: minmax(0, 1.5fr) repeat(3, minmax(0, 1fr)); gap: 32px; }
.footer-brand img { width: 320px; max-width: 100%; height: auto; display: block; margin-bottom: 22px; }
.footer-brand p { max-width: 36ch; margin: 0 0 0.8em; }
.site-footer h2 { font-family: var(--sans); font-size: 0.95rem; font-weight: 650; color: var(--white); letter-spacing: 0; margin: 4px 0 12px; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: 8px; }
.footer-base { border-top: 1px solid #2A313B; margin-top: 40px; padding-top: 20px; display: flex; flex-wrap: wrap; gap: 8px 28px; justify-content: space-between; font-size: 0.88rem; }
.footer-base p { margin: 0; }
@media (max-width: 860px) { .footer-grid { grid-template-columns: 1fr 1fr; } .footer-brand { grid-column: 1 / -1; } }
@media (max-width: 480px) { .footer-grid { grid-template-columns: 1fr; } }

/* ---------- About ---------- */

.portrait { border-radius: var(--radius); border: 1px solid var(--rule); display: block; width: 100%; max-width: 360px; height: auto; }
.cred-list { columns: 2; column-gap: 32px; }
@media (max-width: 640px) { .cred-list { columns: 1; } }

/* ---------- Sample report ---------- */

.sample-notice { background: var(--note-bg); border: 1px solid var(--note-border); border-left: 4px solid var(--brass); border-radius: var(--radius); padding: 16px 20px; color: var(--ink); max-width: var(--measure); }
.sample-notice p { margin: 0; }
.report { border: 1px solid var(--rule-strong); border-radius: var(--radius); padding: clamp(22px, 4vw, 48px); background: var(--surface); }
.report h2 { font-size: 1.5rem; margin-top: 1.8em; }
.report h2:first-of-type { margin-top: 1em; }
.report .prose, .report p, .report ul { max-width: 72ch; }

/* ---------- Thank-you ---------- */

[data-variant] { display: none; }
[data-variant].is-active { display: block; }
.no-js [data-variant="default"] { display: block; }

/* ---------- 404 ---------- */

.notfound { min-height: 50vh; }

@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; transition: none !important; animation: none !important; }
}

@media print {
  .site-header, .site-footer, .cta-band, .upgrade-box, .skip-link, .btn-row { display: none !important; }
  body { font-size: 11pt; }
  a { text-decoration: none; }
}

.calc-placeholder p { margin: 0; color: var(--muted); }
.hero-figure .cores-sum { font-size: 1.5rem; }
@media (prefers-reduced-motion: no-preference) {
  .hero-figure .core.is-billed { animation: billed-in 700ms ease-out 600ms both; }
  @keyframes billed-in { from { opacity: 0; transform: scale(0.6); } to { opacity: 1; transform: none; } }
}
.more-link { margin: 1.4em 0 0; font-weight: 600; }
.calc + .aside-note { margin-top: 2.2rem; }
.booking-embed { width: 100%; min-height: 680px; overflow: auto; border: 1px solid var(--rule); border-radius: var(--radius); background: var(--surface); }
@media (max-width: 640px) { .booking-embed { min-height: 760px; } }
[data-variant] .btn-row + .lede { margin-top: 1.4rem; }
[data-variant] h2 { font-size: 1.3rem; margin-top: 1.6em; }
[data-renewal-question] { margin-top: 2rem; }
[data-renewal-question] .help { color: var(--muted); font-size: 0.95rem; }
.section.flush-top { padding-top: 0; }
.report h2.report-title { margin-top: 0; font-size: 1.7rem; }
.calc-numbers > div { display: flex; flex-direction: column; justify-content: space-between; }
.calc-results .cores-legend { margin-bottom: 10px; }
.article-body .pull-quote > :last-child, .article-body .signal-box > :last-child { margin-bottom: 0; }
.article-body .signal-box { background: var(--paper); border: 1px solid var(--rule); border-left: 4px solid var(--ink); border-radius: var(--radius); padding: 18px 20px; margin: 1.8em 0; }
.article-body .signal-box-label { font-weight: 650; color: var(--ink); margin-bottom: 0.5em; }
.article-body .signal-list { margin-bottom: 0; }
.article-body .upgrade-box h2 { font-size: 1.3rem; margin: 0 0 0.35em; }
.article-body .upgrade-box p { margin-bottom: 0.9em; }
.wrap.prose { max-width: var(--wrap); }
.wrap.prose > * { max-width: var(--measure); }
.page-head + .section:not(.band) { padding-top: 8px; }

/* =====================================================================
   Website v5 design layer: brand guidelines v1.0 visuals.
   Visual only. No content is added or changed by these rules.
   ===================================================================== */

/* ---------- Header: translucent, pinned ---------- */
.site-header {
  position: sticky; top: 0;
  background: color-mix(in srgb, var(--surface) 88%, transparent);
  -webkit-backdrop-filter: saturate(140%) blur(12px);
  backdrop-filter: saturate(140%) blur(12px);
}
@supports not (background: color-mix(in srgb, white 50%, transparent)) { .site-header { background: var(--surface); } }
.site-nav a { transition: background-color 120ms ease, color 120ms ease; }
.site-nav a[aria-current="page"] { text-decoration-thickness: 3px; }
.site-nav .nav-cta a { border-radius: var(--radius); }
.theme-toggle, .nav-toggle { border-radius: var(--radius); }

/* ---------- Buttons ---------- */
.btn { border-radius: var(--radius); letter-spacing: 0.01em; transition: background-color 140ms ease, border-color 140ms ease, color 140ms ease, transform 140ms ease, box-shadow 140ms ease; }
.btn:hover { transform: translateY(-1px); box-shadow: 0 8px 20px -12px rgba(18, 24, 32, 0.6); }
.btn-secondary { border-color: var(--ink); }

/* ---------- Gold accent rules ---------- */
.titled::after { width: 72px; height: 4px; border-radius: 2px; background: var(--brand-gold); }
.section-head h2 { position: relative; padding-top: 18px; }
.section-head h2::before { content: ""; position: absolute; left: 0; top: 0; width: 36px; height: 3px; border-radius: 2px; background: var(--brand-gold); }

/* ---------- Home hero: wireframe towers. Light theme: navy lines on white. Dark theme: white lines on navy ---------- */
:root {
  --hero-bg: #FFFFFF;
  --hero-art: url("/assets/art/towers-hero-light.svg");
  --hero-fade: 255, 255, 255;
}
:root[data-theme="dark"] {
  --hero-bg: #121820;
  --hero-art: url("/assets/art/towers-hero.svg");
  --hero-fade: 18, 24, 32;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --hero-bg: #121820;
    --hero-art: url("/assets/art/towers-hero.svg");
    --hero-fade: 18, 24, 32;
  }
}
.hero {
  position: relative; isolation: isolate; overflow: hidden;
  background: var(--hero-bg) var(--hero-art) calc(100% + 80px) bottom / cover no-repeat;
  padding: clamp(32px, 4vw, 56px) 0 clamp(48px, 6vw, 80px);
  border-bottom: 1px solid var(--rule);
}
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background:
    linear-gradient(90deg, rgba(var(--hero-fade), 0.97) 0%, rgba(var(--hero-fade), 0.92) 38%, rgba(var(--hero-fade), 0.3) 62%, rgba(var(--hero-fade), 0) 100%),
    linear-gradient(0deg, rgba(var(--hero-fade), 0.55) 0%, rgba(var(--hero-fade), 0) 35%);
}
.hero::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 3px; z-index: -1;
  background: linear-gradient(90deg, #F5B335 0, #F5B335 120px, rgba(245, 179, 53, 0.25) 120px, rgba(245, 179, 53, 0) 70%);
}
.hero .plate {
  background: color-mix(in srgb, var(--surface) 86%, transparent);
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
  border-top: 3px solid #F5B335;
}
@media (max-width: 860px) {
  .hero { background-position: 68% bottom; }
  .hero::before { background: linear-gradient(180deg, rgba(var(--hero-fade), 0.94) 0%, rgba(var(--hero-fade), 0.82) 60%, rgba(var(--hero-fade), 0.6) 100%); }
}

/* ---------- Page and article heads: blueprint grid with faint wireframe towers ---------- */
.page-head, .article-head { position: relative; isolation: isolate; overflow: hidden; border-bottom: 1px solid var(--rule); }
.page-head::before, .article-head::before {
  content: ""; position: absolute; inset: 0; z-index: -2; pointer-events: none;
  background-image:
    linear-gradient(var(--grid-line) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px);
  background-size: 32px 32px;
  -webkit-mask-image: linear-gradient(90deg, rgba(0, 0, 0, 0.35), #000 70%);
  mask-image: linear-gradient(90deg, rgba(0, 0, 0, 0.35), #000 70%);
}
.page-head::after, .article-head::after {
  content: ""; position: absolute; top: 0; bottom: 0; right: 0; width: min(58%, 760px); z-index: -1; pointer-events: none;
  background: var(--skyline) right bottom / cover no-repeat;
  -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 55%);
  mask-image: linear-gradient(90deg, transparent 0%, #000 55%);
  opacity: 0.9;
}
@media (max-width: 860px) { .page-head::after, .article-head::after { width: 70%; opacity: 0.45; } }
.page-head + .section:not(.band) { padding-top: clamp(40px, 5vw, 64px); }

/* ---------- Cards and plates ---------- */
.plate, .form-panel, .calc-numbers, .report {
  border-radius: var(--radius);
  border-top-width: 3px;
  box-shadow: var(--card-shadow);
}
.plate.offer { transition: transform 160ms ease, box-shadow 160ms ease; }
.plate.offer:hover { transform: translateY(-2px); }
.offer .kicker { letter-spacing: 0.12em; }
.offer .kicker::before { content: ""; display: inline-block; width: 18px; height: 2px; margin-right: 8px; vertical-align: middle; background: var(--brand-gold); }
.upgrade-box, .sample-notice, .article-body .callout, .article-body .signal-box { border-radius: var(--radius); }
.upgrade-box { border-left-color: var(--brand-gold); box-shadow: var(--card-shadow); }

/* ---------- Bands: paper with a faint grid ---------- */
.band {
  background-color: var(--paper);
  background-image:
    linear-gradient(var(--grid-line) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px);
  background-size: 32px 32px;
}

/* ---------- Steps: gold numbers on a navy rule ---------- */
.steps li { border-top: 2px solid var(--rule); position: relative; }
.steps li::after { content: ""; position: absolute; top: -2px; left: 0; width: 48px; height: 2px; background: var(--brand-gold); }

/* ---------- Closing band: navy with circuit traces ---------- */
.cta-band {
  position: relative; isolation: isolate; overflow: hidden;
}
.cta-band::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: url("/assets/art/traces-gold.svg") center / cover no-repeat;
  -webkit-mask-image: linear-gradient(90deg, transparent 10%, #000 60%);
  mask-image: linear-gradient(90deg, transparent 10%, #000 60%);
}
/* ---------- Footer: faint wireframe towers ---------- */
.site-footer { position: relative; isolation: isolate; overflow: hidden; }
.site-footer::before {
  content: ""; position: absolute; right: 0; bottom: 0; width: min(55%, 720px); height: 100%; z-index: -1; pointer-events: none;
  background: url("/assets/art/towers-footer.svg") right bottom / cover no-repeat;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 60%), linear-gradient(0deg, #000, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 60%);
  opacity: 1;
}

/* ---------- Tables, links, and core grid ---------- */
th { border-bottom-color: var(--brand-gold); }
.post-list h3 a:hover { color: var(--brass-dark); }
.core { border-radius: 3px; }
.cores-legend .core { border-radius: 2px; }

@media (prefers-reduced-motion: reduce) {
  .btn:hover, .plate.offer:hover { transform: none; }
}
@media print {
  .hero, .cta-band { background: none !important; color: #121820; }
  .hero::before, .hero::after, .page-head::before, .page-head::after, .article-head::before, .article-head::after, .site-footer::before { display: none; }
  .site-header { position: static; }
}
.hero .core.is-billed { background: repeating-linear-gradient(135deg, transparent 0 3px, rgba(245, 179, 53, 0.9) 3px 4.5px); box-shadow: inset 0 0 0 1.5px #F5B335; }
:root:not([data-theme="dark"]) .hero .core.is-billed { box-shadow: inset 0 0 0 1.5px #C98F1F; }
.article-head { margin-bottom: clamp(32px, 4vw, 48px); }
.article-body, .prose { overflow-wrap: break-word; }
.page-head .lede + p { margin-top: 1em; }

/* ---------- Closing band follows the theme: paper in light mode, near-black navy in dark mode ---------- */
.cta-band { background: var(--cta-bg, #F5F5F5); }
.cta-band.on-dark { color: var(--text); --focus: var(--focus); }
.cta-band.on-dark h2, .cta-band.on-dark h3, .cta-band.on-dark strong { color: var(--ink); }
.cta-band.on-dark a { color: var(--ink); }
.cta-band.on-dark .btn { background: var(--btn-bg); color: var(--btn-fg); border-color: var(--btn-bg); }
.cta-band.on-dark .btn:hover { background: var(--btn-hover); border-color: var(--btn-hover); }
.cta-band.on-dark .btn-secondary { background: transparent; color: var(--ink); border-color: var(--ink); }
.cta-band.on-dark .btn-secondary:hover { background: var(--paper); }
.cta-band { border-top: 1px solid var(--rule); }
:root[data-theme="dark"] .cta-band { --cta-bg: #0B0F14; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .cta-band { --cta-bg: #0B0F14; } }

/* ---------- Lighter, smaller large headings and tighter top spacing ----------
   Arial ships in Regular and Bold only, so the large headings use Regular:
   same font, less bold. Smaller headings and labels stay bold. */
h1, h2 { font-weight: 400; letter-spacing: -0.01em; }
h1 { font-size: clamp(1.9rem, 1.45rem + 1.9vw, 2.7rem); }
h2 { font-size: clamp(1.4rem, 1.25rem + 0.6vw, 1.7rem); }
.hero h1 { font-size: clamp(2rem, 1.5rem + 2.1vw, 2.85rem); letter-spacing: -0.01em; line-height: 1.12; }
.article-head h1 { font-size: clamp(1.85rem, 1.45rem + 1.6vw, 2.5rem); }
.article-body h2 { font-size: 1.5rem; }
.page-head { padding-top: clamp(24px, 3vw, 40px); padding-bottom: clamp(28px, 3.5vw, 44px); }
.article-head { padding-top: clamp(24px, 3vw, 40px); }
.titled { padding-bottom: 0.45em; margin-bottom: 0.5em; }

/* Phones: show only the icon part of the horizontal logo (the full icon, 66 px wide, above the 64 px minimum) */
@media (max-width: 560px) {
  .brand img { width: 69px; height: 60px; object-fit: cover; object-position: left center; }
}
