:root {
  --ink: #20231f;
  --muted: #565c55;
  --paper: #f2efe4;
  --paper-deep: #dfe1d7;
  --surface: #fbf9f2;
  --rust: #9a402b;
  --rust-dark: #702d20;
  --blue: #405d65;
  --olive: #5b6850;
  --line: #abaea4;
  --focus: #006d8f;
  --max: 72rem;
  --reading: 45rem;
}

* { box-sizing: border-box; }

html {
  color-scheme: light;
  scroll-behavior: smooth;
  scroll-padding-top: 1rem;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: Verdana, Geneva, sans-serif;
  font-size: 1rem;
  line-height: 1.62;
}

button, input { font: inherit; }

a {
  color: var(--rust-dark);
  overflow-wrap: anywhere;
  text-decoration-thickness: .08em;
  text-underline-offset: .16em;
}

a:hover { color: var(--rust); }

:where(a, button, input, summary):focus-visible {
  outline: .2rem solid var(--focus);
  outline-offset: .18rem;
}

.skip-link {
  position: fixed;
  top: .5rem;
  left: .5rem;
  z-index: 100;
  padding: .7rem .9rem;
  background: var(--ink);
  color: #fff;
  transform: translateY(-150%);
}

.skip-link:focus { transform: translateY(0); }

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

.site-header {
  border-top: .3rem solid var(--rust);
  border-bottom: 1px solid #929990;
  background: var(--paper-deep);
}

.header-inner, .footer-inner, .page-shell {
  width: min(calc(100% - 1.5rem), var(--max));
  margin-inline: auto;
}

.header-inner { padding-block: .7rem .55rem; }

.brand {
  display: inline-block;
  color: var(--ink);
  font-family: "Courier New", Courier, monospace;
  font-size: 1rem;
  font-weight: 900;
  letter-spacing: .09em;
  line-height: 1.2;
  text-decoration: none;
}

.brand::before {
  content: "CH";
  display: inline-grid;
  width: 2rem;
  height: 1.45rem;
  margin-right: .5rem;
  border: 1px solid currentColor;
  place-items: center;
  font-size: .68rem;
  letter-spacing: 0;
  vertical-align: .08rem;
}

.site-nav ul, .footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: .15rem .35rem;
  margin: .55rem 0 0;
  padding: 0;
  list-style: none;
}

.site-nav a, .footer-nav a {
  display: inline-flex;
  min-height: 2.75rem;
  align-items: center;
  padding-inline: .45rem;
  font-size: .82rem;
  font-weight: 700;
}

.site-nav a[aria-current="page"] {
  color: var(--ink);
  text-decoration: none;
  box-shadow: inset 0 -.18rem var(--rust);
}

main { display: block; }

.hero, .page-header {
  padding-block: clamp(1.8rem, 6vw, 3.6rem);
  border-bottom: 1px solid var(--line);
}

.hero {
  background-color: #e8e8dd;
  background-image: linear-gradient(90deg, rgba(64,93,101,.08) 1px, transparent 1px), linear-gradient(rgba(64,93,101,.06) 1px, transparent 1px);
  background-size: 1.5rem 1.5rem;
}

.hero-copy {
  max-width: 42rem;
  margin-inline: auto;
  padding: 1rem;
  border: 1px solid var(--line);
  border-top: .3rem solid var(--ink);
  background: rgba(251,249,242,.94);
}

.eyebrow, .kicker, .spec-label, .type-tag, .updated {
  color: var(--olive);
  font-family: "Courier New", Courier, monospace;
  font-size: .75rem;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.eyebrow, .kicker { margin: 0 0 .55rem; }

h1, h2, h3 {
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  line-height: 1.16;
  overflow-wrap: break-word;
  text-wrap: balance;
}

h1 {
  max-width: 18ch;
  font-size: clamp(2rem, 9vw, 3.3rem);
  letter-spacing: -.035em;
}

.hero h1 {
  max-width: none;
  font-family: "Courier New", Courier, monospace;
  font-size: clamp(1.7rem, 8vw, 3rem);
  font-weight: 900;
  letter-spacing: .015em;
}

h2 {
  margin-top: 2rem;
  font-size: clamp(1.4rem, 5vw, 1.95rem);
  letter-spacing: -.02em;
}

h3 { margin-top: 1.5rem; font-size: 1.15rem; }

.lede {
  max-width: 42rem;
  margin: .9rem 0 0;
  color: #3f433e;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.12rem, 4vw, 1.35rem);
  line-height: 1.48;
}

.hero-copy .lede { font-weight: 700; }
.hero-copy .hero-body { margin: 1rem 0 0; }
.hero-copy .hero-line { margin: .9rem 0 0; font-weight: 800; }

.actions {
  display: flex;
  flex-direction: column;
  gap: .65rem;
  margin-top: 1.2rem;
}

.button {
  display: inline-flex;
  min-height: 2.9rem;
  align-items: center;
  justify-content: center;
  padding: .7rem .9rem;
  border: 2px solid var(--rust-dark);
  border-radius: .15rem;
  background: var(--rust-dark);
  color: #fff;
  font-size: .86rem;
  font-weight: 800;
  line-height: 1.3;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
}

.button:hover { background: var(--rust); color: #fff; }
.button:active { transform: translateY(1px); box-shadow: inset 0 2px 0 rgba(0,0,0,.2); }

.button-secondary {
  background: transparent;
  color: var(--rust-dark);
}

.button-secondary:hover { background: var(--paper-deep); color: var(--rust-dark); }

.section { padding-block: clamp(1.8rem, 5vw, 3.3rem); }
.section + .section { border-top: 1px solid var(--line); }
.reading { max-width: var(--reading); }
.reading :where(p, ul, ol, dl) { margin-top: .8rem; margin-bottom: 0; }
.reading li + li { margin-top: .52rem; }

.intro-note, .field-note, .five-minute, .walk-away {
  padding: 1rem;
  border: 1px solid var(--line);
  border-left: .3rem solid var(--rust);
  background: var(--surface);
}

.intro-note p, .field-note p { margin: 0; }
.field-note { margin-top: 1.75rem; }

.five-minute {
  margin-top: 1.4rem;
  border-top: .3rem solid var(--ink);
  border-left-width: 1px;
}

.five-minute h2, .walk-away h2 {
  margin-top: 0;
  font-family: "Courier New", Courier, monospace;
  font-size: 1rem;
  letter-spacing: .04em;
  text-transform: uppercase;
}

.five-minute ul { padding-left: 1.25rem; }
.walk-away { border-left-color: var(--rust); background: #f4e9e2; }

.entry-list { border-top: 2px solid var(--ink); }
.entry { padding-block: 1.25rem; border-bottom: 1px solid var(--line); }
.entry :where(h2, p) { margin: 0; }
.entry h2 { margin-top: .25rem; font-size: clamp(1.25rem, 4vw, 1.65rem); }
.entry h2 a { color: var(--ink); }
.entry > p:last-child { max-width: 44rem; margin-top: .45rem; color: #3e453e; }

.merchant-box {
  padding: clamp(1rem, 4vw, 1.35rem);
  border: 1px solid var(--line);
  border-top: .3rem solid var(--blue);
  background: var(--surface);
}

.merchant-box h2 { margin-top: 0; }
.merchant-box > p:not(.kicker, .affiliate-disclosure) { max-width: 42rem; }

.merchant-links {
  margin: 1.15rem 0 0;
  padding: 0;
  border-top: 2px solid var(--ink);
  list-style: none;
}

.merchant-links li { margin: 0; border-bottom: 1px solid var(--line); }
.merchant-links-single { border-bottom: 1px solid var(--line); }

.merchant-links a {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: .75rem;
  min-height: 3.35rem;
  align-items: center;
  padding: .75rem;
  color: var(--ink);
  font-size: .9rem;
  font-weight: 800;
  line-height: 1.35;
  text-decoration: none;
}

.merchant-links a:hover { background: var(--paper-deep); color: var(--rust-dark); }
.merchant-links a > span:last-child { color: var(--rust-dark); white-space: nowrap; }

.affiliate-disclosure {
  margin: .85rem 0 0;
  color: var(--muted);
  font-size: .82rem;
  line-height: 1.5;
}

.contents {
  margin-top: 1.4rem;
  padding: 1rem;
  border: 1px solid var(--line);
  border-top: .25rem solid var(--blue);
  background: #e5e5db;
}

.contents h2 {
  margin-top: 0;
  font-family: "Courier New", Courier, monospace;
  font-size: .82rem;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.contents ol { padding-left: 1.25rem; }

.guide-layout { width: min(calc(100% - 1.5rem), var(--max)); margin-inline: auto; }
.guide-article { min-width: 0; max-width: var(--reading); }
.guide-section { padding-block: 1.8rem; border-top: 1px solid var(--line); scroll-margin-top: 1rem; }
.guide-section:first-child { border-top: 0; }
.guide-section h2 { margin-top: 0; }
.guide-section h2::before {
  display: inline-block;
  width: .55rem;
  height: .55rem;
  margin: 0 .58rem .12rem 0;
  background: var(--blue);
  content: "";
}
.guide-section ul, .guide-section ol { padding-left: 1.25rem; }

.camera-types { display: grid; gap: 1px; margin-top: 1rem; border: 1px solid var(--line); background: var(--line); }
.camera-type { padding: 1rem; background: var(--surface); }
.camera-type h3 { margin: 0; font-family: "Courier New", Courier, monospace; font-size: 1rem; text-transform: uppercase; }
.camera-type p { margin: .55rem 0 0; }

.term-details { margin: .45rem 0 .7rem; }
.term-details summary {
  display: inline-flex;
  min-height: 2.75rem;
  align-items: center;
  color: var(--rust-dark);
  cursor: pointer;
  font-size: .84rem;
  font-weight: 800;
  text-decoration: underline;
  text-decoration-thickness: .08em;
  text-underline-offset: .16em;
}
.term-details summary::after {
  content: "?";
  display: inline-grid;
  width: 1.2rem;
  height: 1.2rem;
  margin-left: .4rem;
  border: 1px solid currentColor;
  border-radius: 50%;
  place-items: center;
  font-size: .68rem;
  text-decoration: none;
}
.term-details[open] summary::after { background: var(--rust-dark); color: #fff; }
.term-explanation {
  display: block;
  position: relative;
  z-index: 2;
  max-width: 32rem;
  margin: .7rem 0;
  padding: .85rem;
  border: 1px solid var(--blue);
  background: #f9f7ec;
  box-shadow: .2rem .2rem 0 rgba(64,93,101,.18);
  font-size: .92rem;
}
.term-explanation p { margin: 0; }
.term-explanation a { display: inline-block; margin-top: .45rem; }

.basics-group { padding-block: 1.8rem; border-top: 1px solid var(--line); }
.basics-group:first-child { border-top: 0; }
.basics-group > h2 { margin-top: 0; }
.term-list { margin-top: 1rem; }
.term-entry { padding: 1rem 0; border-top: 1px dotted #888e85; scroll-margin-top: 1rem; }
.term-entry dt { font-family: Georgia, "Times New Roman", serif; font-size: 1.25rem; font-weight: 700; }
.term-entry dd { margin: .35rem 0 0; }
.why { color: #3f4b3d; }
.why strong { font-family: "Courier New", Courier, monospace; font-size: .78rem; letter-spacing: .03em; text-transform: uppercase; }

.check-intro { padding-block: 1.25rem; }
.check-intro h1 { font-family: "Courier New", Courier, monospace; font-size: clamp(1.75rem, 8vw, 2.5rem); text-transform: uppercase; }
.check-intro .lede { margin-top: .45rem; }
.download-box {
  margin-top: 1rem;
  padding: .85rem;
  border-block: 1px solid var(--line);
  background: rgba(251,249,242,.72);
}
.download-button { width: 100%; }
.save-help { margin-top: .35rem; }
.save-help summary {
  display: inline-flex;
  min-height: 2.75rem;
  align-items: center;
  color: var(--rust-dark);
  cursor: pointer;
  font-size: .82rem;
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: .16em;
}
.save-help p { margin: .2rem 0 .5rem; font-size: .9rem; }

.priority-block { margin-top: 1.7rem; }
.priority-block > h2 { padding-bottom: .55rem; border-bottom: .22rem solid var(--ink); font-family: "Courier New", Courier, monospace; font-size: 1.15rem; letter-spacing: .04em; text-transform: uppercase; }
.priority-secondary > h2 { border-color: var(--blue); }
.check-group { margin-top: 1.8rem; }
.check-group h3 { margin: 0; font-size: 1.25rem; }
.checklist { display: grid; gap: .65rem; min-inline-size: 0; margin: .8rem 0 0; padding: 0; border: 0; list-style: none; }
.check-item {
  display: grid;
  grid-template-columns: 1.25rem minmax(0, 1fr);
  gap: .75rem;
  min-height: 3.25rem;
  align-items: start;
  padding: .75rem .8rem;
  border: 1px solid var(--line);
  border-radius: .12rem;
  background: var(--surface);
  font-weight: 700;
  line-height: 1.38;
}
.check-item::before {
  width: 1rem;
  height: 1rem;
  margin-top: .13rem;
  border: 1.5px solid #747a73;
  background: #fff;
  content: "";
}
.check-copy { min-width: 0; overflow-wrap: anywhere; }
.type-tag { display: block; margin-top: .22rem; color: var(--blue); font-size: .67rem; line-height: 1.3; }
.check-caution { margin: 1rem 0 0; color: var(--muted); font-size: .85rem; }

.breadcrumb { margin-bottom: 1rem; font-family: "Courier New", Courier, monospace; font-size: .75rem; }
.breadcrumb ol { display: flex; flex-wrap: wrap; gap: .35rem; margin: 0; padding: 0; list-style: none; }
.breadcrumb li + li::before { content: "/"; margin-right: .35rem; color: var(--muted); }

.site-footer { border-top: 1px solid var(--line); background: var(--paper-deep); }
.footer-inner { padding-block: 1.2rem; }
.footer-nav { margin-top: 0; }
.footer-note { margin: .8rem 0 0; color: var(--muted); font-family: "Courier New", Courier, monospace; font-size: .75rem; }
.legal-copy h2 { padding-top: .45rem; border-top: 1px solid var(--line); font-size: 1.2rem; }
.not-found-links { display: grid; gap: .8rem; margin: 1.2rem 0; }
.not-found-links p { margin: 0; padding: 1rem; border-left: .25rem solid var(--blue); background: var(--surface); }
.not-found-links a { display: inline-block; margin-top: .25rem; font-family: Georgia, "Times New Roman", serif; font-size: 1.25rem; font-weight: 700; }

@media (min-width: 40rem) {
  body { font-size: 1.03rem; }
  .header-inner { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
  .site-nav ul { margin-top: 0; }
  .actions { flex-direction: row; align-items: stretch; }
  .entry { display: grid; grid-template-columns: 9rem minmax(12rem,.75fr) minmax(16rem,1fr); gap: 1.2rem; align-items: baseline; }
  .entry h2, .entry > p:last-child { margin-top: 0; }
  .contents ol { columns: 2; column-gap: 2rem; }
  .camera-types { grid-template-columns: 1fr 1fr; }
  .term-entry { display: grid; grid-template-columns: 10rem 1fr; gap: 1rem; }
  .term-entry dd { margin-top: 0; }
}

@media (min-width: 68rem) {
  .guide-layout { display: grid; grid-template-columns: 14rem minmax(0,var(--reading)); gap: 2.5rem; justify-content: center; align-items: start; }
  .guide-layout > .contents { position: sticky; top: 1rem; grid-column: 1; margin-top: 1.8rem; font-size: .78rem; }
  .guide-layout > .contents ol { columns: 1; }
  .guide-article { grid-column: 2; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

@media print {
  .site-header, .site-footer, .actions, .skip-link, .download-box, .term-details, .merchant-box { display: none !important; }
  body { background: #fff; color: #000; font-size: 11pt; }
  .page-header, .section { padding-block: 1rem; }
  .check-item { break-inside: avoid; background: #fff; }
  .checklist { gap: .25rem; }
  .check-item { min-height: 0; padding: .35rem .5rem; font-size: 9.5pt; }
}
