:root {
  --bg: #f3f0e8;
  --paper: #fbf9f4;
  --ink: #1c1915;
  --muted: #3e4652;
  --line: #e3d9cb;
  --link: #0b4f5a;
  --link-hover: #08343c;
  --accent: #146e7a;
  --field: #f4e3c2;
  --field-ink: #3a2910;
  --shadow: 0 18px 50px rgba(48, 38, 22, 0.06);
  --serif: "Iowan Old Style", Palatino, "Palatino Linotype", Georgia, serif;
  --sans: "Segoe UI", "Helvetica Neue", Helvetica, Arial, sans-serif;
  color-scheme: light;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background:
    radial-gradient(circle at top left, rgba(20, 110, 122, 0.08), transparent 28rem),
    var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.65;
}

a {
  color: var(--link);
}

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

a:focus-visible,
.skip:focus {
  outline: 2px solid var(--link);
  outline-offset: 3px;
}

.skip {
  position: absolute;
  left: 1rem;
  top: -4rem;
  z-index: 2;
  background: var(--ink);
  color: var(--paper);
  padding: 0.6rem 0.9rem;
  border-radius: 999px;
  text-decoration: none;
}

.skip:focus {
  top: 0.8rem;
}

.crest {
  height: 4px;
  background: linear-gradient(90deg, #0e6e78, #31538f 70%, #6d4d86);
}

.wrap {
  width: min(46rem, calc(100% - 2rem));
  margin: 0 auto;
}

.site-head {
  padding: 1.4rem 0 0.4rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin: 0;
}

.brand > span {
  display: flex;
  flex-direction: column;
}

.brand svg {
  width: 1.75rem;
  height: 1.75rem;
  color: var(--accent);
  flex: none;
}

.brand-name {
  margin: 0;
  font-family: var(--serif);
  font-size: 1.35rem;
  letter-spacing: 0.01em;
  font-weight: 600;
}

.brand-kicker {
  margin: 0.1rem 0 0;
  color: var(--muted);
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.lang-switch {
  margin-top: 0.85rem;
}

.lang-switch select {
  font: inherit;
  font-size: 1rem;
  line-height: 1.3;
  min-height: 2.75rem;
  width: min(100%, 16rem);
  color: var(--ink);
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.35rem 0.9rem;
}

.lang-note {
  margin: 0.4rem 0 0;
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.45;
}

.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;
}

html[data-boot] main,
html[data-boot] .nav,
html[data-boot] .lang-note,
html[data-boot] .brand-kicker,
html[data-boot] .skip {
  visibility: hidden;
}

@media (max-width: 40rem) {
  .lang-switch select {
    width: 100%;
  }
}

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 1.15rem;
  margin: 1.15rem 0 0;
  padding: 0.35rem 0 0;
  border-top: 1px solid var(--line);
}

.nav a {
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
  color: var(--link);
  text-decoration: underline;
  text-underline-offset: 0.22em;
  text-decoration-thickness: 1px;
}

.nav a[aria-current="page"] {
  color: var(--ink);
  text-decoration: none;
  box-shadow: inset 0 -2px 0 var(--accent);
}

.sheet {
  margin: 0.6rem auto 2.5rem;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 20px;
  box-shadow: var(--shadow);
  padding: clamp(1.25rem, 4vw, 2.6rem);
}

.sheet h1,
.sheet h2,
.sheet h3 {
  font-family: var(--serif);
  line-height: 1.25;
  font-weight: 600;
  text-wrap: balance;
}

.sheet h1 {
  margin: 0 0 0.8rem;
  font-size: clamp(1.9rem, 4.4vw, 2.55rem);
  letter-spacing: -0.02em;
}

.sheet h2 {
  margin: 2.1rem 0 0.7rem;
  font-size: clamp(1.32rem, 2.4vw, 1.55rem);
}

.sheet h3 {
  margin: 1.5rem 0 0.45rem;
  font-size: 1.16rem;
}

.sheet p,
.sheet li {
  margin: 0.75rem 0;
}

.updated {
  color: var(--muted);
  font-size: 0.95rem;
}

.sheet ul,
.sheet ol {
  margin: 0.4rem 0 1rem;
  padding-left: 1.3rem;
}

.sheet li::marker {
  color: var(--accent);
}

.sheet a {
  text-decoration: underline;
  text-underline-offset: 0.16em;
  text-decoration-thickness: 1px;
}

.field {
  background: var(--field);
  color: var(--field-ink);
  border-radius: 0.3rem;
  padding: 0 0.2rem;
  overflow-wrap: anywhere;
}

code {
  font-family: Consolas, "Courier New", monospace;
  font-size: 0.92em;
}

.table-wrap {
  margin: 1rem 0 1.3rem;
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
}

th,
td {
  text-align: left;
  vertical-align: top;
  padding: 0.75rem 0.8rem;
  border-bottom: 1px solid var(--line);
}

th {
  color: var(--muted);
  font-size: 0.76rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  font-weight: 650;
}

.directory {
  list-style: none;
  padding: 0;
  margin: 1.2rem 0 0;
}

.directory a {
  display: block;
  min-height: 2.75rem;
  padding: 0.85rem 0;
  border-top: 1px solid var(--line);
  text-decoration: none;
}

.directory li:last-child a {
  border-bottom: 1px solid var(--line);
}

.directory strong {
  display: block;
  color: var(--link);
  text-decoration: underline;
  text-underline-offset: 0.16em;
  font-weight: 650;
}

.directory span {
  display: block;
  margin-top: 0.2rem;
  color: var(--muted);
  font-size: 0.95rem;
}

.site-foot {
  border-top: 1px solid var(--line);
  padding: 0.4rem 0 2.4rem;
}

@media (max-width: 42rem) {
  .table-wrap {
    overflow: visible;
  }

  table,
  thead,
  tbody,
  tr,
  th,
  td {
    display: block;
    width: 100%;
  }

  thead {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    clip-path: inset(50%);
    white-space: nowrap;
  }

  tbody tr {
    margin: 0 0 0.85rem;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: #fffdf9;
  }

  td {
    display: grid;
    grid-template-columns: minmax(7rem, 38%) 1fr;
    gap: 0.55rem 0.75rem;
    border-bottom: 1px solid var(--line);
    padding: 0.75rem 0.85rem;
  }

  tbody tr td:last-child {
    border-bottom: 0;
  }

  td::before {
    content: attr(data-label);
    color: var(--muted);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
  }
}

@media print {
  body {
    background: #fff;
  }

  .crest,
  .skip,
  .site-foot .nav {
    display: none;
  }

  .sheet {
    border: 0;
    box-shadow: none;
    margin: 0;
    padding: 0;
  }
}
