:root {
  color-scheme: light;
  --ink: #203b36;
  --ink-deep: #17332f;
  --sage: #e7efea;
  --sage-light: #f2f6f3;
  --paper: #f7f8f5;
  --white: #fff;
  --copper: #a85831;
  --copper-light: #d6a27e;
  --line: #dbe3de;
  --muted: #60716b;
  --reading-width: 920px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 16px/1.7 Arial, Helvetica, sans-serif;
  -webkit-font-smoothing: antialiased;
}
button, input { font: inherit; }
a { color: #8e4829; text-underline-offset: 3px; }
a:hover { color: #69351f; }
button, a, input, summary { touch-action: manipulation; }
button:focus-visible, a:focus-visible, input:focus-visible, summary:focus-visible {
  outline: 3px solid #bd7048;
  outline-offset: 4px;
}

.banner-header {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 6 / 1;
  max-height: 260px;
  overflow: hidden;
  padding: 0;
  background: var(--ink-deep);
}
.banner-header a { display: block; width: 100%; height: 100%; line-height: 0; }
.banner-header img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

main {
  display: grid;
  grid-template-columns: minmax(250px, 292px) minmax(0, 1fr);
  max-width: 1600px;
  margin: 0 auto;
  background: var(--paper);
}
aside {
  position: sticky;
  top: 0;
  align-self: start;
  height: calc(100vh - 8px);
  min-height: 500px;
  overflow-y: auto;
  padding: 36px 22px 28px 28px;
  border-right: 1px solid var(--line);
  background: #f3f6f3;
}
.navtitle, .eyebrow {
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.45px;
  line-height: 1.4;
  text-transform: uppercase;
}
.navtitle { margin: 0 0 18px 10px; }
nav { display: grid; gap: 6px; }
nav button {
  display: block;
  width: 100%;
  padding: 12px 13px 13px;
  border: 0;
  border-left: 3px solid transparent;
  border-radius: 0 7px 7px 0;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  text-align: left;
  line-height: 1.4;
  transition: background-color .18s ease, border-color .18s ease;
}
nav button:hover { background: #eaf0ec; }
nav button.active {
  border-left-color: var(--copper);
  background: #e2ebe5;
  color: var(--ink);
}
nav button .nav-label, nav button.active .nav-label {
  display: block;
  color: #1d302c;
  font-size: 14px;
  font-weight: 700;
}
nav button .nav-description {
  display: block;
  margin-top: 5px;
  color: #687770;
  font-size: 12px;
  font-style: italic;
  font-weight: 400;
  line-height: 1.45;
}
nav button.active .nav-description { color: #52665e; }
.website { display: inline-block; margin: 26px 0 0 10px; font-size: 13px; }

.workspace { min-width: 0; }
.intro {
  padding: 40px clamp(28px, 6vw, 82px) 32px;
  border-bottom: 2px solid var(--copper-light);
  background: var(--white);
}
.intro h1 {
  margin: 8px 0 12px;
  color: var(--ink-deep);
  font: 400 clamp(32px, 3.2vw, 46px)/1.13 Georgia, 'Times New Roman', serif;
  letter-spacing: -.5px;
}
.intro p {
  max-width: 760px;
  margin: 0 0 21px;
  color: #4e625b;
  font-size: 16px;
  line-height: 1.65;
}
.searchbox {
  display: flex;
  align-items: center;
  gap: 12px;
  width: min(100%, 760px);
  min-height: 48px;
  padding: 8px 14px;
  border: 1px solid #c9d5ce;
  border-radius: 7px;
  background: #fafcfb;
  color: var(--ink);
}
.searchbox span { color: var(--copper); font-size: 27px; line-height: 1; }
.searchbox input { width: 100%; min-width: 0; border: 0; outline: 0; background: transparent; color: var(--ink); }
.searchbox input::placeholder { color: #77867f; }
.searchbox:focus-within { outline: 3px solid #e6c3ad; outline-offset: 2px; }
kbd { padding: 0 7px; border: 1px solid var(--line); border-radius: 4px; background: white; color: var(--muted); font-size: 12px; }
.shortcuts { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.shortcuts button {
  padding: 7px 12px;
  border: 1px solid #cad7cf;
  border-radius: 999px;
  background: var(--sage-light);
  color: #315047;
  cursor: pointer;
  font-size: 13px;
  transition: background-color .18s ease, border-color .18s ease;
}
.shortcuts button:hover { border-color: #b6c8bc; background: var(--sage); }

.content {
  min-height: 58vh;
  padding: 38px clamp(28px, 6vw, 82px) 72px;
}
.sectionhead {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  max-width: var(--reading-width);
  margin: 0 auto 22px;
  padding-bottom: 15px;
  border-bottom: 1px solid var(--line);
}
.sectionhead .eyebrow { color: var(--copper); }
.sectionhead h2 {
  margin: 7px 0 0;
  color: var(--ink-deep);
  font: 400 clamp(27px, 2.5vw, 34px)/1.2 Georgia, 'Times New Roman', serif;
}
#count { padding-bottom: 5px; color: var(--muted); font-size: 13px; white-space: nowrap; }
#results { max-width: var(--reading-width); margin: 0 auto; }
.topic {
  overflow: hidden;
  margin: 0 0 12px;
  border: 1px solid #dce4df;
  border-radius: 9px;
  background: var(--white);
  box-shadow: 0 2px 8px rgb(23 51 47 / 3%);
  scroll-margin-top: 18px;
}
.topic > summary {
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 66px;
  padding: 16px 20px;
  cursor: pointer;
  list-style: none;
  color: #203a34;
  font: 700 17px/1.45 Arial, Helvetica, sans-serif;
}
.topic > summary::-webkit-details-marker { display: none; }
.topic > summary::after {
  flex: 0 0 auto;
  margin-left: auto;
  color: var(--copper);
  content: '+';
  font: 400 25px/1 Arial, sans-serif;
}
.topic[open] > summary { border-bottom: 1px solid #e3e9e5; background: #f6f9f7; }
.topic[open] > summary::after { content: '−'; }
.topic-number {
  display: inline-grid;
  flex: 0 0 30px;
  width: 30px;
  height: 30px;
  place-items: center;
  border-radius: 50%;
  background: #edf3ef;
  color: #8d4a2d;
  font-size: 11px;
  font-weight: 700;
}
.topic-body {
  max-width: 850px;
  margin: 0 auto;
  padding: 26px clamp(22px, 4.2vw, 56px) 40px;
  color: #2f413c;
  font-size: 16px;
  line-height: 1.76;
  overflow-wrap: anywhere;
}
.topic-body > :first-child { margin-top: 0; }
.topic-body h2, .topic-body h3, .topic-body h4 {
  color: var(--ink-deep);
  scroll-margin-top: 22px;
}
.topic-body h2, .topic-body h3 {
  margin: 34px 0 12px;
  font: 400 25px/1.3 Georgia, 'Times New Roman', serif;
}
.topic-body h4 { margin: 26px 0 9px; font-size: 16px; line-height: 1.4; }
.topic-body p { margin: 13px 0; }
.topic-body ul, .topic-body ol { padding-left: 25px; }
.topic-body li { margin: 7px 0; padding-left: 2px; }
.topic-body li::marker { color: #8b6e58; }
.topic-body hr { height: 1px; margin: 26px 0; border: 0; background: #e2e8e3; }
.topic-body blockquote {
  margin: 22px 0;
  padding: 17px 21px;
  border-left: 3px solid var(--copper-light);
  border-radius: 0 6px 6px 0;
  background: #f4f7f4;
  color: #314840;
}
.topic-body table { display: block; width: 100%; margin: 22px 0; overflow-x: auto; border-collapse: collapse; }
.topic-body td, .topic-body th { min-width: 145px; padding: 11px 13px; border: 1px solid var(--line); text-align: left; vertical-align: top; }
.topic-body th { background: #f1f5f2; color: var(--ink-deep); }
.topic-body details { padding: 13px 0; border-bottom: 1px solid #e5ebe7; }
.topic-body details summary { cursor: pointer; color: #29473f; font-weight: 700; }
.topic-body figure { margin: 22px auto; }
.topic-body .source-image img { display: block; max-width: 100%; height: auto; border: 1px solid #e2e7e3; border-radius: 5px; }
.topic-body .review-image img { width: 180px; }
.topic-body .acknowledgment-images { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; gap: 18px; }
.topic-body .acknowledgment-images .source-image { margin: 10px 0; }
.task { display: flex; align-items: flex-start; gap: 12px; padding: 11px 0; border-bottom: 1px solid #e9eeea; }
.task input { flex: 0 0 19px; width: 19px; height: 19px; margin: 4px 0 0; accent-color: var(--ink); }
.task:has(input:checked) span { color: var(--muted); text-decoration: line-through; }
.check-progress { padding: 9px 0 16px; color: var(--copper); font-size: 13px; font-weight: 700; }
.empty { padding: 26px; border: 1px dashed #b8c8be; border-radius: 8px; background: white; }
.empty h3 { margin-top: 0; color: var(--ink); font: 400 24px Georgia, serif; }

footer { padding: 34px 24px 30px; border-top: 1px solid var(--line); background: #f3f6f3; color: var(--muted); text-align: center; }
footer .footer-logo { display: block; width: 210px; max-width: 70%; height: auto; margin: 0 auto 12px; }
footer .copyright { max-width: none; margin: 0 auto; color: #74817b; font-size: 12px; }

@media (min-width: 1500px) {
  .intro, .content { padding-left: 90px; padding-right: 90px; }
}
@media (max-width: 900px) {
  main { grid-template-columns: 235px minmax(0, 1fr); }
  aside { padding: 28px 15px 22px; }
  .intro, .content { padding-right: 30px; padding-left: 30px; }
  nav button { padding: 10px 10px 11px; }
  nav button .nav-description { font-size: 11px; }
}
@media (max-width: 700px) {
  .banner-header { aspect-ratio: 5.5 / 1; }
  main { display: block; }
  aside {
    position: sticky;
    z-index: 5;
    top: 0;
    height: auto;
    min-height: 0;
    padding: 11px 14px;
    border-right: 0;
    border-bottom: 1px solid var(--line);
    background: rgb(243 246 243 / 96%);
    backdrop-filter: blur(10px);
  }
  .navtitle, .website { display: none; }
  nav { display: flex; gap: 7px; overflow-x: auto; padding: 1px 1px 3px; scrollbar-width: thin; }
  nav button {
    flex: 0 0 178px;
    width: auto;
    padding: 9px 10px;
    border: 1px solid #dce5df;
    border-radius: 6px;
    background: #fff;
  }
  nav button.active { border-color: #b6c8bc; background: #e5eee8; }
  nav button .nav-label { font-size: 12px; }
  nav button .nav-description { margin-top: 3px; font-size: 10px; }
  .intro { padding: 26px 21px 24px; }
  .intro h1 { font-size: 31px; }
  .intro p { font-size: 15px; }
  .content { padding: 28px 18px 48px; }
  .sectionhead { align-items: start; margin-bottom: 17px; }
  .sectionhead h2 { font-size: 28px; }
  #count { margin-top: 25px; font-size: 12px; }
  .topic > summary { min-height: 60px; padding: 14px 13px; gap: 10px; font-size: 15px; }
  .topic-number { flex-basis: 27px; width: 27px; height: 27px; }
  .topic-body { padding: 21px 18px 31px; font-size: 15px; line-height: 1.72; }
  .topic-body h2, .topic-body h3 { font-size: 23px; }
  .topic-body .acknowledgment-images { grid-template-columns: 1fr; }
  footer { padding: 26px 20px; }
  kbd { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .01ms !important; }
}
@media print {
  .banner-header, aside, .intro, .shortcuts, footer { display: none; }
  main { display: block; }
  .content { padding: 0; }
  .topic { break-inside: avoid; box-shadow: none; }
  .topic-body { max-width: none; padding: 12px; }
  .topic:not([open]) > .topic-body { display: block; }
}


/* v20: consistent hierarchy, related asset groupings, and easier in-topic navigation */
.topic-body hr { display: none; }
.topic-body h2, .topic-body h3 { margin: 30px 0 11px; font-size: 22px; line-height: 1.32; }
.topic-body h4 { margin: 24px 0 8px; font-size: 16px; line-height: 1.45; }
.topic-body .assets-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; gap: 20px; }
.topic-body .asset-column { min-width: 0; padding: 18px 20px 20px; border: 1px solid #dce5df; border-radius: 9px; background: #f8faf8; }
.topic-body .asset-column-title { margin: 0 0 15px; padding-bottom: 12px; border-bottom: 1px solid #dce5df; color: var(--ink-deep); font: 700 17px/1.35 Arial, Helvetica, sans-serif; }
.topic-body .asset-column h4:first-of-type { margin-top: 5px; }
.topic-body .asset-column > p:first-of-type { margin-top: 7px; }
.topic-body .asset-column > p:nth-of-type(2) { padding: 12px 14px; border-left: 3px solid var(--copper-light); border-radius: 0 5px 5px 0; background: white; }
.topic-body details.handbook-toggle { margin: 16px 0; padding: 0; overflow: hidden; border: 1px solid #dce5df; border-radius: 8px; background: #fff; }
.topic-body details.handbook-toggle > summary { padding: 14px 16px; background: #f5f8f6; color: var(--ink-deep); font: 700 17px/1.4 Arial, Helvetica, sans-serif; list-style: none; }
.topic-body details.handbook-toggle > summary::-webkit-details-marker { display: none; }
.topic-body details.handbook-toggle > summary::after, .topic-body details.template-toggle > summary::after { float: right; color: var(--copper); content: '+'; font: 400 20px/1 Arial, sans-serif; }
.topic-body details.handbook-toggle[open] > summary::after, .topic-body details.template-toggle[open] > summary::after { content: '−'; }
.topic-body details.handbook-toggle > :not(summary) { margin-left: 17px; margin-right: 17px; }
.topic-body details.handbook-toggle > :last-child { margin-bottom: 18px; }
.topic-body details.template-toggle { margin: 12px 0; padding: 0; border: 1px solid #dce5df; border-radius: 7px; background: #fafcfb; }
.topic-body details.template-toggle > summary { padding: 12px 14px; color: var(--ink-deep); font-weight: 700; list-style: none; }
.topic-body details.template-toggle > summary::-webkit-details-marker { display: none; }
.topic-body details.template-toggle > :not(summary) { margin-left: 14px; margin-right: 14px; }
.topic-body details.template-toggle > :last-child { margin-bottom: 14px; }
.search-section-label { display: block; margin-top: 3px; color: #8e4829; font-size: 11px; font-weight: 700; letter-spacing: .45px; text-transform: uppercase; }
.search-result-snippet { display: block; margin-top: 5px; color: #5a6b64; font-size: 13px; font-weight: 400; line-height: 1.5; }
@media (max-width: 700px) {
  .topic-body .assets-grid { grid-template-columns: 1fr; gap: 14px; }
  .topic-body .asset-column { padding: 15px 16px 17px; }
  .topic-body h2, .topic-body h3 { font-size: 21px; }
  .topic-body details.handbook-toggle > summary { padding: 13px 14px; font-size: 16px; }
}
