/* WeiserHub — Feldnotizen zu Claude
   Handgeschriebenes CSS, keine Frameworks, keine externen Schriften. */

:root {
  --ink: #201c15;
  --paper: #f1ede2;
  --paper-raised: #e6e0d0;
  --gold: #a87a22;
  --teal: #2f6f68;
  --rule: #cfc6ae;
  --muted: #6b6252;
  --shadow: 220 20% 10%;

  --font-display: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", Palatino, Georgia, serif;
  --font-body: -apple-system, "Segoe UI", "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  --font-mono: ui-monospace, "Cascadia Code", "SF Mono", Consolas, "Liberation Mono", monospace;

  --measure: 38rem;
  --gap-xs: 0.5rem;
  --gap-s: 1rem;
  --gap-m: 1.75rem;
  --gap-l: 3rem;
  --gap-xl: 6rem;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --ink: #ede7d6;
    --paper: #17140f;
    --paper-raised: #211c14;
    --gold: #d9a83e;
    --teal: #5fb3a8;
    --rule: #3a3327;
    --muted: #a99c82;
  }
}

:root[data-theme="dark"] {
  --ink: #ede7d6;
  --paper: #17140f;
  --paper-raised: #211c14;
  --gold: #d9a83e;
  --teal: #5fb3a8;
  --rule: #3a3327;
  --muted: #a99c82;
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
}

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

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

::selection {
  background: var(--gold);
  color: var(--paper);
}

a { color: var(--teal); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--gold); }
a:focus-visible, button:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 600;
  text-wrap: balance;
  color: var(--ink);
  margin: 0;
}

p { margin: 0 0 1em; max-width: var(--measure); }
p:last-child { margin-bottom: 0; }

.eyebrow {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 0.6em;
}
.eyebrow .num { color: var(--gold); }

/* ---------- Skip link ---------- */
.skip-link {
  position: absolute; left: -999px; top: 0;
  background: var(--gold); color: var(--paper);
  padding: 0.6em 1em; z-index: 100; font-family: var(--font-mono);
}
.skip-link:focus { left: 1rem; top: 1rem; }

/* ---------- Top nav ---------- */
.topnav {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0.9rem clamp(1rem, 4vw, 2.5rem);
  background: color-mix(in srgb, var(--paper) 88%, transparent);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--rule);
  gap: 1rem;
}
.topnav .brand {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  letter-spacing: 0.04em;
  white-space: nowrap;
}
.topnav .brand strong { color: var(--gold); }
.topnav ol {
  list-style: none; display: flex; gap: clamp(0.6rem, 2vw, 1.4rem);
  margin: 0; padding: 0; overflow-x: auto; font-family: var(--font-mono); font-size: 0.78rem;
}
.topnav ol a { color: var(--muted); white-space: nowrap; }
.topnav ol a:hover { color: var(--gold); }
.theme-toggle {
  font-family: var(--font-mono); font-size: 0.75rem;
  background: none; border: 1px solid var(--rule); color: var(--muted);
  border-radius: 999px; padding: 0.35em 0.9em; cursor: pointer; flex-shrink: 0;
}
.theme-toggle:hover { border-color: var(--gold); color: var(--gold); }

/* ---------- Layout ---------- */
main { display: block; }
.entry {
  padding: var(--gap-xl) clamp(1.25rem, 6vw, 4rem);
  max-width: 68rem; margin: 0 auto;
  border-bottom: 1px solid var(--rule);
}
.entry:last-of-type { border-bottom: none; }
.entry-head { margin-bottom: var(--gap-l); max-width: var(--measure); }
.entry-head h2 { font-size: clamp(1.6rem, 3.2vw, 2.4rem); margin-top: 0.3em; }

.reveal { opacity: 0; transform: translateY(14px); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal.is-visible { opacity: 1; transform: none; }

/* ---------- Hero ---------- */
.hero {
  padding: clamp(3rem, 10vh, 6rem) clamp(1.25rem, 6vw, 4rem) var(--gap-xl);
  display: grid; grid-template-columns: 1.1fr 1fr; gap: var(--gap-l); align-items: center;
  max-width: 68rem; margin: 0 auto;
}
@media (max-width: 800px) { .hero { grid-template-columns: 1fr; } }
.hero h1 {
  font-size: clamp(2.2rem, 5.5vw, 3.6rem);
  line-height: 1.08;
  margin: 0.4em 0 0.5em;
}
.hero .lede { font-size: 1.1rem; color: var(--muted); max-width: 34rem; }
.hero .figure-wrap { max-width: 30rem; }
.hero svg { width: 100%; height: auto; }

/* ---------- Prose ---------- */
.prose { max-width: var(--measure); }
.prose + .figure { margin-top: var(--gap-l); }
.pull { font-family: var(--font-display); font-style: italic; font-size: 1.3rem; color: var(--gold); border-left: 3px solid var(--gold); padding-left: 1em; margin: 1.6em 0; max-width: var(--measure); }

/* ---------- Figures / diagrams ---------- */
.figure { margin: var(--gap-l) 0 0; }
.figure svg { width: 100%; height: auto; display: block; }
figcaption { font-family: var(--font-mono); font-size: 0.78rem; color: var(--muted); margin-top: 0.8em; max-width: var(--measure); }

/* ---------- Capability cards ---------- */
.grid-cards {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
  gap: 1px; background: var(--rule); border: 1px solid var(--rule); margin-top: var(--gap-l);
}
.card {
  background: var(--paper); padding: 1.6rem; display: flex; flex-direction: column; gap: 0.8rem;
}
.card svg { width: 2rem; height: 2rem; color: var(--gold); }
.card h3 { font-size: 1.05rem; }
.card p { font-size: 0.92rem; color: var(--muted); margin: 0; }
.card .ex {
  font-family: var(--font-mono); font-size: 0.78rem; color: var(--teal);
  border-top: 1px dashed var(--rule); padding-top: 0.7rem; margin-top: auto;
}

/* ---------- Specimens (prompt/result cards) ---------- */
.specimens { display: grid; gap: var(--gap-m); margin-top: var(--gap-l); }
.specimen {
  background: var(--paper-raised); border: 1px solid var(--rule); border-radius: 2px;
  padding: 1.5rem clamp(1.2rem, 3vw, 2rem);
}
.specimen .tag {
  font-family: var(--font-mono); font-size: 0.7rem; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--gold); margin-bottom: 0.9rem; display: block;
}
.specimen .prompt {
  font-family: var(--font-mono); font-size: 0.85rem; color: var(--ink);
  background: color-mix(in srgb, var(--ink) 6%, transparent);
  border-left: 2px solid var(--muted); padding: 0.6em 0.9em; margin-bottom: 1rem; white-space: pre-wrap;
}
.specimen .result { font-size: 0.95rem; }
.specimen .result code, .specimen pre {
  font-family: var(--font-mono); font-size: 0.82rem; background: color-mix(in srgb, var(--ink) 6%, transparent);
  display: block; padding: 0.9em 1em; overflow-x: auto; border-radius: 2px; line-height: 1.55;
}
.specimen .result-figure svg { width: 100%; height: auto; }
.specimen-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(21rem, 1fr)); gap: var(--gap-m); }

/* ---------- Chart ---------- */
.chart-wrap { overflow-x: auto; }
.chart-row { display: flex; align-items: baseline; gap: 0.8em; font-family: var(--font-mono); font-size: 0.82rem; margin: 0.55em 0; }
.chart-label { width: 12rem; flex-shrink: 0; color: var(--muted); }
.chart-track { flex: 1; background: color-mix(in srgb, var(--ink) 6%, transparent); height: 0.9em; position: relative; min-width: 6rem; }
.chart-fill { background: var(--gold); height: 100%; }
.chart-val { font-variant-numeric: tabular-nums; width: 2.4rem; text-align: right; color: var(--ink); }

/* ---------- Limits list ---------- */
.limits { list-style: none; margin: var(--gap-l) 0 0; padding: 0; display: grid; gap: 1.1rem; }
.limits li { display: grid; grid-template-columns: 1.6rem 1fr; gap: 0.8rem; max-width: var(--measure); }
.limits svg { width: 1.3rem; height: 1.3rem; color: var(--teal); margin-top: 0.2em; }
.limits strong { display: block; margin-bottom: 0.2em; }
.limits p { color: var(--muted); font-size: 0.94rem; }

/* ---------- Colophon ---------- */
.colophon dl { display: grid; grid-template-columns: max-content 1fr; gap: 0.5em 1.5em; font-size: 0.92rem; margin-top: var(--gap-m); }
.colophon dt { font-family: var(--font-mono); color: var(--muted); }
.colophon dd { margin: 0; }

/* ---------- Footer ---------- */
footer {
  padding: var(--gap-l) clamp(1.25rem, 6vw, 4rem) var(--gap-xl);
  max-width: 68rem; margin: 0 auto;
  font-family: var(--font-mono); font-size: 0.78rem; color: var(--muted);
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 1em;
}

@media (max-width: 560px) {
  .entry { padding-left: 1.1rem; padding-right: 1.1rem; }
  .chart-label { width: 8rem; font-size: 0.72rem; }
}
