/* After Dark: register-slip layout. Every background sets its own text colour. */
/* Local serif only: no font files are downloaded. */
@font-face { font-family: "AD Serif"; font-weight: 400; src: local("Iowan Old Style"), local("IowanOldStyle-Roman"), local("Palatino Linotype"), local("Palatino"), local("Palatino-Roman"), local("Book Antiqua"); font-display: swap; }
@font-face { font-family: "AD Serif"; font-weight: 600 700; src: local("Iowan Old Style Bold"), local("IowanOldStyle-Bold"), local("Palatino Linotype Bold"), local("PalatinoLinotype-Bold"), local("Palatino Bold"), local("Palatino-Bold"), local("Book Antiqua Bold"); font-display: swap; }
:root {
  --paper: #F2F4F1;
  --slip: #FFFFFF;
  --ink: #16222A;
  --muted: #46565C;
  --felt: #1E5A44;
  --felt-deep: #143D2E;
  --oxblood: #8B2B2B;
  --rule: #C6CFCB;
  --serif: "AD Serif", "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", Georgia, serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --measure: none; /* text fills its column: no empty band on the right of wide screens */
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 1.125rem/1.7 var(--serif);
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--felt); text-underline-offset: .18em; text-decoration-thickness: 1px; }
a:hover { color: var(--felt-deep); text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--felt); outline-offset: 3px; }

.skip { position: absolute; left: 1rem; top: -200px; background: var(--ink); color: #FFFFFF; padding: .6rem 1rem; min-height: 44px; z-index: 10; }
.skip:focus { top: 1rem; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.wrap { width: min(1120px, 100% - 2rem); margin-inline: auto; }

/* Age bar and header */
.agebar { background: var(--ink); color: #E8EEEB; font: .8125rem/1.4 var(--sans); padding: .45rem 0; }
.agebar p { margin-block: 0; }
.agebar strong { color: #FFFFFF; }

.top { border-bottom: 1px solid var(--rule); background: var(--paper); color: var(--ink); }
.top .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .75rem 2rem; padding-block: 1.1rem; }
.brand { display: flex; align-items: center; gap: .65rem; min-height: 48px; color: var(--ink); text-decoration: none; }
.brand .mark { width: 36px; height: 36px; flex: none; }
.brand span { font: 600 1.35rem/1 var(--serif); letter-spacing: .01em; }
.nav { display: flex; flex-wrap: wrap; gap: .5rem 1.25rem; font: .9375rem/1.4 var(--sans); }
.nav a { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; min-width: 44px; color: var(--ink); text-decoration: none; border-bottom: 2px solid transparent; }
.nav a:hover { border-bottom-color: var(--rule); }
.nav a[aria-current="page"] { border-bottom-color: var(--felt); }

/* Type */
h1, h2, h3 { font-family: var(--serif); font-weight: 600; line-height: 1.2; color: var(--ink); }
h1 { font-size: clamp(2rem, 4.4vw, 3.1rem); margin: 0 0 1rem; letter-spacing: -.01em; }
h2 { font-size: clamp(1.45rem, 2.6vw, 1.85rem); margin: 2.75rem 0 .85rem; }
h3 { font-size: 1.2rem; margin: 1.75rem 0 .5rem; }
p, ul, ol { margin: 0 0 1.1rem; }
.lede { font-size: 1.2rem; line-height: 1.6; }
.prose { max-width: var(--measure); }
.prose li { margin-bottom: .45rem; }
.meta { font: .875rem/1.5 var(--sans); color: var(--muted); margin: 0 0 1.75rem; }
.meta a { color: var(--muted); }

.breadcrumb { font: .8125rem/1.4 var(--sans); color: var(--muted); padding-top: .75rem; }
.breadcrumb ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; align-items: center; gap: .4rem; }
.breadcrumb li + li::before { content: "/"; margin-right: .4rem; color: var(--rule); }
.breadcrumb a { display: inline-flex; align-items: center; min-height: 44px; color: var(--muted); }
.breadcrumb a[aria-current="page"] { color: var(--ink); text-decoration: none; }

main { padding-bottom: 4rem; }

/* Home hero */
.hero { display: grid; grid-template-columns: 1.05fr .95fr; gap: 2.5rem; align-items: center; padding-block: 3rem 2rem; }
.hero figure { margin: 0; }
.hero img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; object-position: 25% 70%; border-radius: 6px; }
.hero figcaption { font: .75rem/1.4 var(--sans); color: var(--muted); margin-top: .45rem; }
.hero figcaption a { color: var(--muted); }

/* The register board: licence slips with ink stamps */
.board { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.25rem; margin: 1.5rem 0 1rem; padding: 0; list-style: none; }
.slip {
  position: relative;
  background: var(--slip);
  color: var(--ink);
  border: 1px solid var(--rule);
  border-top: 0;
  border-radius: 0 0 3px 3px;
  padding: 1.6rem 1.35rem 1.25rem;
  font-family: var(--sans);
  box-shadow: 0 1px 0 var(--rule), 0 8px 18px -14px rgba(22, 34, 42, .35);
}
/* perforation: a row of paper-coloured holes along the top edge */
.slip::before {
  content: ""; position: absolute; left: -1px; right: -1px; top: 0; height: 10px;
  background:
    radial-gradient(circle at 7px 0, var(--paper) 4.5px, transparent 5px) 0 0 / 14px 10px repeat-x,
    linear-gradient(var(--rule), var(--rule)) 0 9px / 100% 1px no-repeat;
}
.slip .licno-band { background: #EAF1EC; color: var(--ink); margin: 0 -1.35rem; padding: .7rem 1.35rem .75rem; border-block: 1px solid #D3E0D7; }
.board li { display: flex; }
.board .slip { flex: 1; display: flex; flex-direction: column; }
.board .slip .read { margin-top: auto; align-self: flex-start; }
.slip h2, .slip h3 { margin: 0 0 .2rem; font-size: 1.35rem; }
.slip .entity { font-size: .9rem; color: var(--muted); margin: 0 0 1rem; line-height: 1.45; }
.slip .licno { font-size: 1.3rem; font-weight: 600; font-variant-numeric: tabular-nums; letter-spacing: .02em; margin: 0; overflow-wrap: anywhere; }
.slip .licno-label { font-size: .8125rem; color: var(--muted); margin: 0 0 .1rem; }
.slip dl { margin: 1rem 0 1.1rem; display: grid; grid-template-columns: auto 1fr; gap: .3rem .9rem; font-size: .875rem; line-height: 1.45; }
.slip dt { color: var(--muted); }
.slip dd { margin: 0; font-variant-numeric: tabular-nums; }
.slip .read { display: inline-flex; align-items: center; min-height: 44px; font-weight: 600; font-size: .9375rem; }
.slip .stamp { position: absolute; top: 1.1rem; right: 1rem; }
.logo-plate { height: 56px; display: flex; align-items: center; margin: 0 6.5rem 1rem 0; }
.logo-plate img { display: block; height: 56px; width: auto; max-width: 100%; object-fit: contain; object-position: left center; border-radius: 3px; }
.logo-plate.is-empty { border: 1px dashed var(--rule); border-radius: 3px; padding: 0 .75rem; font-size: .8125rem; line-height: 1.35; color: var(--muted); }

.stamp {
  display: inline-block;
  padding: .2rem .55rem;
  border: 2px solid currentColor;
  outline: 1px solid currentColor; outline-offset: 2px;
  border-radius: 3px;
  font: 700 .8125rem/1.3 var(--sans);
  letter-spacing: .02em;
  color: var(--felt);
  background: var(--slip);
  transform: rotate(-4deg);
}
.stamp.is-surrendered { color: var(--oxblood); transform: rotate(5deg); }
.slip .stamp { opacity: .92; }
@media (prefers-reduced-motion: no-preference) {
  .board .stamp { animation: stamp .45s cubic-bezier(.2, .8, .3, 1.2); }
  .board li:nth-child(2) .stamp { animation-delay: .12s; }
  .board li:nth-child(3) .stamp { animation-delay: .24s; }
  .board li:nth-child(4) .stamp { animation-delay: .36s; }
  .board li:nth-child(5) .stamp { animation-delay: .48s; }
  .board li:nth-child(6) .stamp { animation-delay: .6s; }
  @keyframes stamp { from { scale: 1.5; } to { scale: 1; } }
}

.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 0 3rem; }

.steps { counter-reset: step; list-style: none; padding: 0; max-width: var(--measure); }
.steps li { counter-increment: step; position: relative; padding-left: 2.75rem; margin-bottom: 1rem; }
.steps li::before {
  content: counter(step);
  position: absolute; left: 0; top: .1rem;
  width: 1.85rem; height: 1.85rem; border-radius: 50%;
  border: 2px solid var(--felt); color: var(--felt); background: var(--paper);
  font: 700 .875rem/1.6rem var(--sans); text-align: center;
}

/* Review page */
.doc { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 3.5rem; align-items: start; }
.doc aside { position: sticky; top: 1.5rem; }
.doc-main > section:first-child > h2:first-child { margin-top: 1.5rem; }
.doc aside .slip .stamp { position: static; margin-bottom: .75rem; }
.toc { background: var(--slip); color: var(--ink); border: 1px solid var(--rule); border-radius: 2px; padding: 1.1rem 1.25rem; font: .9375rem/1.45 var(--sans); }
.toc-h { font: 600 1.05rem/1.3 var(--serif); color: var(--ink); margin: 0 0 .35rem; }
.toc ol { list-style: none; padding: 0; margin: 0; }
.toc li { border-bottom: 1px solid var(--rule); margin: 0; }
.toc li a { display: flex; align-items: center; min-height: 44px; padding-block: .35rem; color: var(--ink); text-decoration: none; }
.toc li a:hover { color: var(--felt); text-decoration: underline; }
.toc-more { margin: .9rem 0 0; }
.toc-more a { font-weight: 600; }
h2[id] { scroll-margin-top: 1.5rem; }

/* Register screenshot on each review: evidence, framed like a page clipped from the register */
.evidence { margin: 1.75rem 0 2rem; }
.evidence a:has(img) { display: block; padding: 0; }
.evidence img { width: 100%; height: auto; background: #FFFFFF; border: 1px solid var(--rule); border-radius: 3px; box-shadow: 0 10px 24px -18px rgba(22, 34, 42, .45); }
.evidence figcaption { font: .8125rem/1.5 var(--sans); color: var(--muted); margin-top: .6rem; }
.evidence figcaption a { color: var(--muted); }

/* Brand, company, licence chain on How we review */
.chain { margin: 1.75rem 0 2rem; }
.chain ol { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2.25rem; font-family: var(--sans); }
.chain li { position: relative; background: var(--slip); color: var(--ink); border: 1px solid var(--rule); border-radius: 3px; padding: 1rem 1.1rem; margin: 0; display: flex; flex-direction: column; gap: .15rem; }
.chain li:last-child { border-color: var(--felt); box-shadow: inset 0 3px 0 var(--felt); }
.chain strong { font: 600 1.1rem/1.3 var(--serif); overflow-wrap: anywhere; }
.chain li:last-child strong { font: 600 1rem/1.3 var(--sans); font-variant-numeric: tabular-nums; white-space: nowrap; }
.chain-k { font-size: .8125rem; color: var(--muted); }
.chain-v { font-size: .875rem; color: var(--muted); }
.chain-link { order: -1; font-size: .8125rem; font-weight: 600; color: var(--felt); margin: 0 0 .35rem; }
.chain-link::before { content: "…"; }
.chain li:not(:last-child)::after { content: "\2192"; position: absolute; right: -1.6rem; top: 50%; transform: translateY(-50%); font-size: 1.3rem; color: var(--felt); }
.chain figcaption { font: .8125rem/1.5 var(--sans); color: var(--muted); margin-top: .75rem; }
.chain figcaption a { color: var(--muted); }
@media (max-width: 700px) {
  .chain ol { grid-template-columns: 1fr; gap: 1.25rem; }
  .chain li:not(:last-child)::after { content: none; }
  .chain-link::before { content: "\2193  "; }
}
}
.doc-main + aside { margin-top: 2.75rem; }
.log { background: var(--slip); color: var(--ink); border: 1px solid var(--rule); border-radius: 3px; padding: 1.25rem 1.35rem; font: .9375rem/1.5 var(--sans); }
.log .log-h { font: 600 1.3rem/1.2 var(--serif); margin: 0 0 .25rem; }
.log h3 { font: 600 .9375rem/1.4 var(--sans); color: var(--muted); margin: 1.1rem 0 .4rem; }
.log-list { list-style: none; padding: 0; margin: 0; border-left: 2px solid var(--rule); }
.log-list li { position: relative; padding: 0 0 .85rem 1rem; margin: 0; }
.log-list li::before { content: ""; position: absolute; left: -6px; top: .4rem; width: 10px; height: 10px; border-radius: 50%; background: var(--slip); border: 2px solid var(--felt); }
.log-list time { display: block; font-weight: 600; font-variant-numeric: tabular-nums; }
.log-list p { margin: .1rem 0 0; color: var(--ink); }
.log-note { color: var(--muted); font-size: .875rem; border-top: 1px solid var(--rule); padding-top: .85rem; margin: .4rem 0 .5rem; }
.log-more { margin: 0; }
.log-more a { display: inline-flex; align-items: center; min-height: 44px; font-weight: 600; }
.answer { border-left: 3px solid var(--felt); padding: .2rem 0 .2rem 1.1rem; margin: 0 0 1.5rem; max-width: var(--measure); }
.answer p { margin: 0; font-size: 1.15rem; line-height: 1.6; }

.checklist { list-style: none; padding: 0; font-family: var(--sans); font-size: .9375rem; max-width: var(--measure); }
.checklist li { display: flex; justify-content: space-between; gap: 1rem; padding: .55rem 0; border-bottom: 1px solid var(--rule); margin: 0; }
.checklist .yes { color: var(--felt); font-weight: 600; white-space: nowrap; }
.checklist .no { color: var(--muted); white-space: nowrap; }

.sources { font-family: var(--sans); font-size: .9rem; line-height: 1.5; max-width: var(--measure); padding-left: 1.35rem; }
.src-note { font-family: var(--sans); font-size: .9rem; color: var(--muted); margin-bottom: .4rem; }
.sources li { margin-bottom: .6rem; }
.sources span { color: var(--muted); display: block; }

/* FAQ */
.faq { max-width: var(--measure); }
.faq details { border-bottom: 1px solid var(--rule); padding: .9rem 0; }
.faq summary { cursor: pointer; font-weight: 600; font-size: 1.1rem; list-style-position: outside; }
.faq details p { margin: .65rem 0 0; }

/* Notices */
.notice { background: #E3EBE6; color: var(--ink); border-radius: 4px; padding: 1.1rem 1.25rem; max-width: var(--measure); font-size: 1rem; }
.notice p { margin: 0; color: var(--ink); }
.notice a { color: var(--felt-deep); }

/* Compare */
.picker { border: 0; padding: 0; margin: 0 0 1.25rem; display: flex; flex-wrap: wrap; gap: .5rem 1.25rem; font-family: var(--sans); }
.picker legend { font-weight: 600; margin-bottom: .5rem; padding: 0; }
.picker label { display: inline-flex; align-items: center; gap: .4rem; cursor: pointer; }
.picker input { width: 1.1rem; height: 1.1rem; accent-color: var(--felt); }
.table-scroll { overflow-x: auto; background: var(--slip); color: var(--ink); border: 1px solid var(--rule); border-radius: 2px; }
.cmp { border-collapse: collapse; width: 100%; min-width: 1040px; font: .9rem/1.5 var(--sans); }
.cmp th, .cmp td { text-align: left; vertical-align: top; padding: .75rem .9rem; border-bottom: 1px solid var(--rule); }
.cmp thead th { font-size: 1rem; border-bottom: 2px solid var(--ink); }
.cmp tbody th { color: var(--muted); font-weight: 500; width: 9.5rem; }
.cmp td { font-variant-numeric: tabular-nums; }
.cmp [hidden] { display: none; }
.count { font: .875rem/1.4 var(--sans); color: var(--muted); margin: 0 0 .75rem; }

/* Footer */
.foot { background: var(--ink); color: #DCE4E0; font: .875rem/1.6 var(--sans); padding: 2.5rem 0; }
.foot p { margin: 0 0 .9rem; }
.foot-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 2rem 3rem; padding-bottom: 2rem; border-bottom: 1px solid #33434B; }
.foot .brand { color: #FFFFFF; margin-bottom: .75rem; }
.foot-brand p { color: #C9D3CE; max-width: 40ch; }
.foot-h { font-weight: 600; color: #FFFFFF; margin: 0 0 .4rem; }
.foot ul { list-style: none; padding: 0; margin: 0; }
.foot li a { display: inline-flex; align-items: center; min-height: 44px; color: #DCE4E0; text-decoration: none; }
.foot li a:hover { color: #FFFFFF; text-decoration: underline; }
.foot-base { display: flex; flex-wrap: wrap; justify-content: space-between; gap: .5rem 2rem; padding-top: 1.5rem; font-size: .8125rem; color: #B5C1BB; }
.foot-base p { margin: 0; }
.foot-base a { display: inline-flex; align-items: center; min-height: 44px; margin-left: 1rem; color: #DCE4E0; }
.agebar a { color: #FFFFFF; }
.foot strong { color: #FFFFFF; }
.foot a { color: #FFFFFF; }

@media (max-width: 900px) {
  .hero, .two-col { grid-template-columns: 1fr; }
  .hero { gap: 1.5rem; padding-top: 2rem; }
  .board { grid-template-columns: 1fr; }
  .doc { grid-template-columns: 1fr; gap: 1.5rem; }
  .doc aside { position: static; order: -1; }
  .doc-main + aside { order: 0; margin-top: 0; }
  .foot-grid { grid-template-columns: 1fr 1fr; }
  .foot-brand { grid-column: 1 / -1; }
  .foot-base a { margin: 0 1rem 0 0; }
}

/* Inline text links: taller tap area without moving the text. Vertical padding on an inline box
   does not change line layout; the negative outline offset keeps the focus ring on the words. */
main p a, main li a, .foot p a, .faq a, figcaption a { padding-block: calc(24px - .5em); }
main p a:focus-visible, main li a:focus-visible, .foot p a:focus-visible, figcaption a:focus-visible { outline-offset: calc(.5em - 22px); }
.picker label { min-height: 44px; }
.picker input { width: 1.35rem; height: 1.35rem; }
