/* Hutch theme documentation. Colors of the theme: paper #F6F1E7, ink #1B2A22, fir #1F4D3A, brick #E9825B,
   label yellow #FFC83D (only for the brand label). System fonts, no external requests. */
:root {
  --paper: #f6f1e7;
  --ink: #1b2a22;
  --fir: #1f4d3a;
  --brick: #e9825b;
  --label: #ffc83d;
  --plate: #e9e0cf;
  --muted: #4f5a53;
  --line: 3px;
  --radius: 10px;
  --side: 17rem;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-padding-top: 1rem; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 1.0625rem/1.6 system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  overflow-wrap: break-word;
}

a { color: var(--fir); text-decoration-thickness: 1px; text-underline-offset: 0.18em; }
a:hover { color: var(--ink); text-decoration-thickness: 2px; }

:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; border-radius: 2px; box-shadow: 0 0 0 6px var(--label); }

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

.skip { position: absolute; left: 1rem; top: -4rem; z-index: 10; padding: 0.6rem 1rem; background: var(--ink); color: var(--paper); border-radius: var(--radius); }
.skip:focus { top: 1rem; }

.draft {
  padding: 0.45rem 1rem;
  background: var(--brick);
  color: var(--ink);
  font-weight: 700;
  text-align: center;
  letter-spacing: 0.02em;
}

/* Top bar: the first shelf line */
.top {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.5rem 1.5rem;
  padding: 1rem clamp(1rem, 3vw, 2rem);
  border-bottom: var(--line) solid var(--ink);
}
.brand { display: inline-flex; align-items: center; gap: 0.6rem; color: var(--ink); text-decoration: none; font-weight: 700; font-size: 1.1rem; }
.brand__tag {
  position: relative; padding: 0.25rem 0.8rem 0.25rem 1.5rem; background: var(--label); color: var(--ink);
  border-radius: 4px var(--radius) var(--radius) 4px;
}
.brand__tag::before { content: ""; position: absolute; left: 0.55rem; top: 50%; width: 0.4rem; height: 0.4rem; margin-top: -0.2rem; border-radius: 50%; background: var(--paper); }
.top__version { margin: 0; color: var(--muted); font-size: 0.95rem; }

/* Layout */
.frame { display: grid; grid-template-columns: minmax(0, 1fr); max-width: 84rem; margin: 0 auto; }
main { padding: 1.5rem clamp(1rem, 4vw, 3rem) 3rem; min-width: 0; }
main:focus { outline: none; }

.nav-side { display: none; }
.nav-mobile { border-bottom: 1px solid var(--plate); }
.nav-mobile > summary {
  display: flex; align-items: center; justify-content: space-between; min-height: 3rem; padding: 0.5rem 1rem;
  font-weight: 700; cursor: pointer; list-style: none;
}
.nav-mobile > summary::-webkit-details-marker { display: none; }
.nav-mobile > summary::after { content: "+"; font-size: 1.4rem; line-height: 1; }
.nav-mobile[open] > summary::after { content: "–"; }
.nav-mobile nav { padding: 0 1rem 1rem; }

@media (min-width: 900px) {
  .nav-mobile { display: none; }
  .frame { grid-template-columns: var(--side) minmax(0, 1fr); }
  .nav-side {
    display: block; position: sticky; top: 0; align-self: start; max-height: 100vh; overflow-y: auto;
    padding: 1.5rem 1rem 2rem clamp(1rem, 2vw, 2rem); border-right: 1px solid var(--plate);
  }
}

.toc, .toc ul { list-style: none; margin: 0; padding: 0; }
.toc > li { margin: 0.1rem 0; }
.toc a { display: block; padding: 0.3rem 0.5rem; border-radius: 6px; color: var(--ink); text-decoration: none; line-height: 1.35; }
.toc a:hover { background: var(--plate); }
.toc a[aria-current="page"] { font-weight: 700; box-shadow: inset var(--line) 0 0 var(--ink); background: var(--plate); }
.toc ul { margin: 0.2rem 0 0.4rem 0.75rem; border-left: 1px solid var(--plate); }
.toc ul a { font-size: 0.93rem; padding-left: 0.75rem; }
.toc-search { margin-bottom: 0.75rem; }
.toc-search label { display: block; font-size: 0.9rem; font-weight: 600; margin-bottom: 0.2rem; }
.toc-search input { width: 100%; }
.toc li[hidden] { display: none; }

/* Type */
h1, h2, h3, h4 { line-height: 1.2; letter-spacing: -0.01em; margin: 2rem 0 0.75rem; scroll-margin-top: 1rem; }
h1 { font-size: clamp(1.9rem, 1.5rem + 1.6vw, 2.6rem); margin-top: 0.5rem; }
h2 { font-size: clamp(1.45rem, 1.25rem + 0.8vw, 1.8rem); padding-top: 1rem; border-top: var(--line) solid var(--ink); }
h3 { font-size: 1.25rem; }
h4 { font-size: 1.08rem; }
.anchor { margin-left: 0.3rem; color: var(--muted); text-decoration: none; font-weight: 400; opacity: 0.55; }
h1:hover .anchor, h2:hover .anchor, h3:hover .anchor, h4:hover .anchor, .anchor:focus-visible { opacity: 1; }
p, ul, ol, dl { margin: 0 0 1rem; max-width: 46rem; }
li { margin: 0.25rem 0; }
code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 0.9em; padding: 0.08em 0.3em; background: var(--plate); border-radius: 4px; overflow-wrap: anywhere; }
.muted { color: var(--muted); }
.ui { font-weight: 650; }
a.ui { font-weight: 650; }
mark.fehlt { background: var(--brick); color: var(--ink); padding: 0.05em 0.35em; border-radius: 4px; font-weight: 600; }

.facts { display: grid; gap: 0.5rem; padding: 1rem 1.25rem; background: var(--plate); border-radius: var(--radius); }
.facts div { display: grid; grid-template-columns: minmax(9rem, 14rem) minmax(0, 1fr); gap: 0.25rem 1rem; }
.facts dt { font-weight: 700; }
.facts dd { margin: 0; }
@media (max-width: 520px) { .facts div { grid-template-columns: minmax(0, 1fr); } }

.note { max-width: 46rem; margin: 0 0 1.25rem; padding: 0.8rem 1rem; border-left: var(--line) solid var(--fir); background: #ece6d8; border-radius: 0 var(--radius) var(--radius) 0; }
.note p { margin: 0.25rem 0; }
.note--warnung { border-left-color: var(--brick); background: #f3e1d6; }
.note--warnung p:first-child::before { content: "Warning: "; font-weight: 700; }
.note--tipp { border-left-color: var(--ink); }

.sec { margin-bottom: 2.5rem; }
.sec__where { color: var(--ink); }
.block { margin: 1rem 0 1.5rem; padding-left: 1rem; border-left: 1px solid #cfc5b1; }
.block h4 { margin-top: 1.25rem; }

.shot { margin: 0 0 1.5rem; max-width: 60rem; }
.shot img { display: block; width: 100%; height: auto; border: 1px solid #cfc5b1; border-radius: var(--radius); background: var(--plate); }
.shot figcaption { margin-top: 0.4rem; font-size: 0.9rem; color: var(--muted); }

/* Settings tables */
table { width: 100%; max-width: 60rem; margin: 0 0 1.5rem; border-collapse: collapse; font-size: 0.97rem; }
caption { text-align: left; font-weight: 700; padding: 0 0 0.4rem; }
th, td { padding: 0.6rem 0.7rem; text-align: left; vertical-align: top; border-bottom: 1px solid #cfc5b1; }
thead th { border-bottom: var(--line) solid var(--ink); font-size: 0.92rem; }
tbody th { font-weight: 700; width: 24%; }
.settings td:nth-child(3) { width: 22%; }
.settings td:nth-child(4) { width: 16%; }
.settings__info { display: block; margin-top: 0.3rem; font-weight: 400; font-size: 0.9rem; color: var(--muted); }
.settings__group th { background: var(--plate); font-size: 0.95rem; }
.settings__para td { font-style: italic; color: var(--muted); }
.swatch { display: inline-block; width: 1rem; height: 1rem; margin-right: 0.35rem; vertical-align: -0.15rem; border: 1px solid var(--ink); border-radius: 50%; }

@media (max-width: 720px) {
  table, thead, tbody, tr, th, td, caption { display: block; width: 100%; }
  thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  tbody tr { padding: 0.6rem 0; border-bottom: 1px solid #cfc5b1; }
  th, td { border: 0; padding: 0.2rem 0; }
  tbody th { width: auto; font-size: 1.02rem; }
  .settings td:nth-child(3), .settings td:nth-child(4) { width: auto; }
  td[data-col]::before { content: attr(data-col) ": "; font-weight: 700; }
  .settings td[data-col="What it does"]::before { content: none; }
  .settings__group th { padding: 0.4rem 0.6rem; border-radius: 6px; }
}

/* Support form */
.support-form { max-width: 38rem; margin-top: 1.5rem; }
.field { margin-bottom: 1.25rem; }
.field label { display: block; font-weight: 700; margin-bottom: 0.25rem; }
.req { font-weight: 400; color: var(--ink); }
.field__hint { margin: 0 0 0.35rem; font-size: 0.93rem; color: var(--muted); }
input, textarea {
  width: 100%; min-height: 2.9rem; padding: 0.6rem 0.75rem; font: inherit; color: var(--ink);
  background: #fffdf8; border: 2px solid var(--ink); border-radius: var(--radius);
}
input[type="file"] { padding: 0.5rem; background: transparent; }
textarea { min-height: 10rem; resize: vertical; }
.form-status { padding: 0.8rem 1rem; border-left: var(--line) solid var(--brick); background: #f3e1d6; border-radius: 0 var(--radius) var(--radius) 0; }
.button {
  display: inline-flex; align-items: center; justify-content: center; min-height: 3rem; padding: 0.6rem 1.4rem;
  font: inherit; font-weight: 700; color: var(--paper); background: var(--ink); border: 2px solid var(--ink); border-radius: var(--radius); cursor: pointer;
}
.button:hover { background: var(--fir); border-color: var(--fir); }
.button[disabled] { color: var(--ink); background: var(--plate); border-color: #8a8f88; cursor: not-allowed; }

.home-order { counter-reset: none; }
.page-foot { margin-top: 3rem; padding-top: 1rem; border-top: 1px solid #cfc5b1; font-size: 0.92rem; }

@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
@media print { .nav-side, .nav-mobile, .skip, .anchor { display: none !important; } .frame { display: block; } }
