:root {
  color-scheme: light;
  --ink: #22170f;
  --muted: #6f5e50;
  --paper: #fffaf0;
  --panel: #ffffff;
  --gold: #f0b429;
  --gold-dark: #9b5a08;
  --red: #a92b28;
  --line: #e9dcc9;
  --shadow: 0 18px 48px rgba(68, 42, 18, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  background: #efe2c7;
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(circle at 10% 0%, rgba(240, 180, 41, 0.24), transparent 32rem),
    linear-gradient(180deg, var(--paper), #f7eedc);
  font-family: ui-rounded, "Avenir Next", Avenir, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 17px;
  line-height: 1.65;
}

a {
  color: var(--red);
  text-decoration-thickness: 0.11em;
  text-underline-offset: 0.18em;
}

a:hover {
  color: #781c1a;
}

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

.site-header {
  border-bottom: 1px solid rgba(155, 90, 8, 0.18);
  background: rgba(255, 250, 240, 0.94);
}

.header-inner,
.page,
.site-footer {
  width: min(100% - 2rem, 68rem);
  margin-inline: auto;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 4.75rem;
}

.brand {
  color: var(--ink);
  font-size: clamp(1.1rem, 3vw, 1.35rem);
  font-weight: 900;
  letter-spacing: 0.045em;
  text-decoration: none;
  text-transform: uppercase;
}

.brand span {
  color: var(--red);
}

.nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.4rem 1rem;
  font-size: 0.92rem;
  font-weight: 700;
}

.nav a {
  color: var(--ink);
  text-decoration: none;
}

.nav a[aria-current="page"] {
  color: var(--red);
  text-decoration: underline;
  text-decoration-thickness: 0.14em;
  text-underline-offset: 0.25em;
}

.page {
  padding-block: clamp(2.5rem, 7vw, 5.5rem);
}

.hero {
  display: grid;
  gap: 2rem;
  align-items: center;
  grid-template-columns: minmax(0, 1.35fr) minmax(17rem, 0.65fr);
}

.eyebrow {
  margin: 0 0 0.65rem;
  color: var(--gold-dark);
  font-size: 0.82rem;
  font-weight: 900;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

h1,
h2,
h3 {
  line-height: 1.15;
  text-wrap: balance;
}

h1 {
  max-width: 18ch;
  margin: 0;
  font-size: clamp(2.4rem, 8vw, 5.5rem);
  letter-spacing: -0.045em;
}

h2 {
  margin: 2.6rem 0 0.8rem;
  font-size: clamp(1.45rem, 4vw, 2.05rem);
  letter-spacing: -0.02em;
}

h3 {
  margin: 1.8rem 0 0.45rem;
  font-size: 1.13rem;
}

p,
ul,
ol {
  max-width: 72ch;
}

.lead {
  max-width: 52ch;
  margin: 1.2rem 0 0;
  color: #4f4034;
  font-size: clamp(1.1rem, 2.4vw, 1.32rem);
}

.notice,
.card {
  border: 1px solid var(--line);
  border-radius: 1.25rem;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow);
}

.notice {
  padding: 1.4rem;
  border-top: 0.45rem solid var(--gold);
}

.notice strong {
  display: block;
  margin-bottom: 0.35rem;
}

.grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 2.5rem;
}

.card {
  padding: 1.35rem;
}

.card h2,
.card h3 {
  margin-top: 0;
}

.card p:last-child {
  margin-bottom: 0;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.8rem;
}

.button {
  display: inline-flex;
  align-items: center;
  min-height: 3rem;
  padding: 0.6rem 1rem;
  border: 2px solid var(--ink);
  border-radius: 999px;
  color: var(--ink);
  background: var(--gold);
  font-weight: 900;
  text-decoration: none;
  box-shadow: 4px 4px 0 var(--ink);
}

.button.secondary {
  background: var(--panel);
}

.button:hover {
  color: var(--ink);
  transform: translate(1px, 1px);
  box-shadow: 3px 3px 0 var(--ink);
}

.document {
  max-width: 52rem;
}

.document h1 {
  max-width: 22ch;
  font-size: clamp(2.2rem, 7vw, 4.2rem);
}

.meta {
  margin: 0.8rem 0 2.25rem;
  color: var(--muted);
  font-size: 0.94rem;
}

.toc {
  margin: 2rem 0;
  padding: 1.2rem 1.35rem;
  border-left: 0.4rem solid var(--gold);
  background: rgba(255, 255, 255, 0.7);
}

.toc ul {
  columns: 2;
  margin: 0.5rem 0 0;
  padding-left: 1.2rem;
}

li + li {
  margin-top: 0.35rem;
}

.contact-box {
  margin: 2rem 0;
  padding: 1.4rem;
  border: 2px solid var(--ink);
  border-radius: 1rem;
  background: var(--gold);
  box-shadow: 5px 5px 0 var(--ink);
}

.contact-box p {
  margin: 0;
}

.contact-box a {
  color: var(--ink);
  font-weight: 900;
}

.small {
  color: var(--muted);
  font-size: 0.92rem;
}

code {
  padding: 0.1em 0.35em;
  border: 1px solid var(--line);
  border-radius: 0.3rem;
  background: #fff;
  font-size: 0.9em;
}

.site-footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.75rem 1.5rem;
  padding-block: 1.5rem 2.5rem;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.87rem;
}

.site-footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
}

.site-footer p {
  margin: 0;
}

@media (max-width: 48rem) {
  .header-inner,
  .hero {
    display: block;
  }

  .header-inner {
    padding-block: 1rem;
  }

  .nav {
    justify-content: flex-start;
    margin-top: 0.65rem;
  }

  .hero .notice {
    margin-top: 2rem;
  }

  .grid {
    grid-template-columns: 1fr;
  }

  .toc ul {
    columns: 1;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    transition: none !important;
  }
}
