/* Zunft der Sechs – „Grünspan & Kupferstich“ (Gestaltung beschlossen 26.09.2026, docs/GESTALTUNG.md)
   Werkbank eines Instrumentenbauers bei Nacht: Messing mit Grünspan, gravierte Skalen, Kupferstiche.
   Metallplatten mit Fase, gravierte Doppellinie, Fortschritt als Skala mit Teilstrichen.
   Grünspan = Wert und Handlung, Glut nur für Kraft. Immer dunkel – wie die App (alle Kupferstiche
   sind auf dunklen Grund gezeichnet). Instrument Serif / Instrument Sans / Martian Mono, alles lokal. */

@font-face { font-family: "Instrument Serif"; font-weight: 400; font-display: swap;
  src: url("schrift/instrument-serif-regular.woff2") format("woff2"); }
@font-face { font-family: "Instrument Sans"; font-weight: 400; font-display: swap;
  src: url("schrift/instrument-sans-regular.woff2") format("woff2"); }
@font-face { font-family: "Instrument Sans"; font-weight: 600; font-display: swap;
  src: url("schrift/instrument-sans-semibold.woff2") format("woff2"); }
@font-face { font-family: "Martian Mono"; font-weight: 400; font-display: swap;
  src: url("schrift/martian-mono-regular.woff2") format("woff2"); }
@font-face { font-family: "Martian Mono"; font-weight: 600; font-display: swap;
  src: url("schrift/martian-mono-semibold.woff2") format("woff2"); }

:root {
  --grund: #0F1C1A;          /* Patina-Nacht */
  --flaeche: #1A2B28;
  --flaeche2: #223733;
  --linie: #2E4A45;          /* Ziergravur */
  --rand: #5E8A82;           /* Rand von Bedienelementen, ≥ 3 : 1 */
  --text: #E6EEEA;           /* 15,0 : 1 auf Grund */
  --leise: #8FB3AC;          /* 7,6 : 1 auf Grund, 6,7 : 1 auf Fläche */
  --gruenspan: #37D3C0;      /* Wert, Handlung; 9,2 : 1 auf Grund */
  --wert-grund: #12302C;
  --glut: #FF7A45;           /* nur Kraft; 6,9 : 1 auf Grund */
  --kraft-grund: #3A1E12;
  --auf-akzent: #0F1C1A;
  --warn: #F2A65A;
  --messing-hell: #E2C27A;   /* Würfel wie in der App */
  --messing-dunkel: #9C7431;
  --auge: #1A2B28;
  --f: 10px;                 /* Fase */
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; background: var(--grund); }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *, *::before, *::after { transition: none !important; animation: none !important; } }
body {
  margin: 0; background: var(--grund); color: var(--text);
  font: 400 1.0625rem/1.65 "Instrument Sans", system-ui, sans-serif;
  overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--gruenspan); text-underline-offset: 0.2em; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--gruenspan); outline-offset: 3px; }

h1, h2, h3 { font-family: "Instrument Serif", Georgia, serif; font-weight: 400; line-height: 1.05; margin: 0; letter-spacing: -0.005em; }
h2 { font-size: clamp(2.3rem, 5.5vw, 3.6rem); }
h3 { font-size: 1.75rem; }
p { margin: 0 0 0.9em; }
.mono { font-family: "Martian Mono", ui-monospace, monospace; font-size: 0.8rem; letter-spacing: 0.12em; text-transform: uppercase; }

.huelle { width: min(1180px, 100% - 32px); margin-inline: auto; }
.ueberspringen { position: absolute; left: -999px; top: 8px; background: var(--gruenspan); color: var(--auf-akzent); padding: 10px 14px; z-index: 10; }
.ueberspringen:focus { left: 16px; }

/* Fase: Metallplatte mit abgeschrägten Ecken; Rand über eine zweite Schicht, damit auch die Schrägen eine Linie haben */
.platte { position: relative; isolation: isolate; padding: 24px clamp(16px, 3vw, 28px);
  background: var(--linie);
  clip-path: polygon(var(--f) 0, calc(100% - var(--f)) 0, 100% var(--f), 100% calc(100% - var(--f)), calc(100% - var(--f)) 100%, var(--f) 100%, 0 calc(100% - var(--f)), 0 var(--f)); }
.platte::before { content: ""; position: absolute; inset: 1.5px; z-index: -2; background: var(--flaeche);
  clip-path: polygon(var(--f) 0, calc(100% - var(--f)) 0, 100% var(--f), 100% calc(100% - var(--f)), calc(100% - var(--f)) 100%, var(--f) 100%, 0 calc(100% - var(--f)), 0 var(--f)); }
.platte::after { content: ""; position: absolute; inset: 6px; z-index: -1; border: 1px solid var(--linie); pointer-events: none;
  clip-path: polygon(6px 0, calc(100% - 6px) 0, 100% 6px, 100% calc(100% - 6px), calc(100% - 6px) 100%, 6px 100%, 0 calc(100% - 6px), 0 6px); }

/* Skala mit Teilstrichen (Fortschritt in der App) */
.skala { height: 12px; margin: 16px 0 0; position: relative;
  background: repeating-linear-gradient(90deg, var(--linie) 0 1.5px, transparent 1.5px 14px) bottom / 100% 9px no-repeat;
  border-bottom: 1.5px solid var(--linie); }
.skala::before { content: ""; position: absolute; left: 0; bottom: 0; height: 12px; width: var(--wert, 18%); background: var(--gruenspan); }

/* Doppellinie (graviert) */
.doppellinie { border: 0; height: 5px; border-top: 1px solid var(--linie); border-bottom: 1px solid var(--linie); margin: 0; }

/* ---------- Kopf ---------- */
.kopf { position: sticky; top: 0; z-index: 5; background: var(--grund); border-bottom: 1px solid var(--linie); box-shadow: 0 3px 0 -2px var(--linie); }
.kopf .huelle { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 64px; }
.marke { display: inline-flex; align-items: center; gap: 10px; font: 400 1.6rem/1 "Instrument Serif", serif; color: var(--text); text-decoration: none; }
.marke img { clip-path: polygon(5px 0, calc(100% - 5px) 0, 100% 5px, 100% calc(100% - 5px), calc(100% - 5px) 100%, 5px 100%, 0 calc(100% - 5px), 0 5px); }
.kopf ul { list-style: none; display: flex; gap: 2px; margin: 0; padding: 0; }
.kopf li a { display: inline-flex; align-items: center; min-height: 48px; padding: 0 10px; color: var(--leise); text-decoration: none;
  font: 400 0.75rem/1 "Martian Mono", monospace; letter-spacing: 0.12em; text-transform: uppercase; }
.kopf li a:hover { color: var(--gruenspan); }
.kopf .sprache { color: var(--gruenspan); border: 1px solid var(--rand); min-height: 40px; margin-block: 4px; }
@media (max-width: 800px) { .kopf li:not(.immer) { display: none; } }

/* ---------- Held ---------- */
.held { padding: clamp(28px, 6vw, 72px) 0 clamp(40px, 7vw, 88px); }
.held .huelle { display: grid; gap: clamp(28px, 5vw, 60px); grid-template-columns: 1fr; align-items: center; }
@media (min-width: 980px) { .held .huelle { grid-template-columns: 1fr 1fr; } }
.held .mono { color: var(--gruenspan); }
h1 { font-size: clamp(3.6rem, 12vw, 7rem); margin: 10px 0 0; }
.versprechen { font-size: clamp(1.15rem, 2.2vw, 1.35rem); color: var(--text); margin: 20px 0 22px; max-width: 32em; }
.fakten { list-style: none; margin: 0 0 26px; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.fakten li { font: 400 0.78rem/1 "Martian Mono", monospace; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text);
  border: 1px solid var(--rand); padding: 10px 12px; background: var(--flaeche); }
.bald { display: inline-flex; flex-direction: column; gap: 4px; border: 1px dashed var(--gruenspan); padding: 14px 18px; background: var(--wert-grund); }
.bald strong { font: 400 1.5rem/1.1 "Instrument Serif", serif; color: var(--text); }
.bald span { color: var(--leise); font-size: 0.98rem; }
.hinweis { color: var(--leise); font-size: 0.98rem; margin-top: 14px; }

/* Spieltisch (Probierwurf) */
.tisch .kopfzeile-tisch { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.tisch .mono { color: var(--gruenspan); }
.tisch .stadt { font: 400 2.4rem/1 "Instrument Serif", serif; margin: 6px 0 2px; }
.tisch .leise { color: var(--leise); margin: 0; }
.wuerfelreihe { list-style: none; margin: 22px 0 6px; padding: 0; display: grid; grid-template-columns: repeat(5, 1fr); gap: clamp(8px, 2vw, 16px); }
.wuerfel { width: 100%; aspect-ratio: 1; padding: 0; border: 0; cursor: pointer; position: relative; display: block;
  background: transparent; border-radius: 8px; transition: transform .18s ease; }
.wuerfel .koerper { position: absolute; inset: 0; border-radius: 16%; background: linear-gradient(145deg, var(--messing-hell), var(--messing-dunkel));
  display: grid; grid-template: repeat(3, 1fr) / repeat(3, 1fr); padding: 16%; box-shadow: inset 0 -3px 0 rgba(0,0,0,.25); }
.wuerfel .auge { width: 62%; aspect-ratio: 1; border-radius: 50%; background: var(--auge); place-self: center; visibility: hidden; }
.wuerfel[data-augen="1"] .a5, .wuerfel[data-augen="3"] .a5, .wuerfel[data-augen="5"] .a5 { visibility: visible; }
.wuerfel:is([data-augen="2"],[data-augen="3"],[data-augen="4"],[data-augen="5"],[data-augen="6"]) :is(.a1,.a9) { visibility: visible; }
.wuerfel:is([data-augen="4"],[data-augen="5"],[data-augen="6"]) :is(.a3,.a7) { visibility: visible; }
.wuerfel[data-augen="6"] :is(.a4,.a6) { visibility: visible; }
.wuerfel[aria-pressed="true"] { transform: translateY(-6px); }
.wuerfel[aria-pressed="true"] .koerper { outline: 3px solid var(--gruenspan); outline-offset: 3px; }
.wuerfel[aria-pressed="true"]::after { content: ""; position: absolute; left: 0; right: 0; bottom: -14px; height: 4px; background: var(--gruenspan); }
.wuerfel:focus-visible { outline: 3px solid var(--text); outline-offset: 6px; }
.wuerfel:disabled { cursor: default; }
.zaehlt { list-style: none; margin: 14px 0 0; padding: 0; display: grid; grid-template-columns: repeat(5, 1fr); gap: clamp(8px, 2vw, 16px); }
.zaehlt li { height: 10px; display: grid; place-items: center; }
.zaehlt li.ja::before { content: ""; width: 9px; height: 9px; border-radius: 50%; background: var(--gruenspan); }
.rollen .koerper { animation: rollen .35s ease-out; }
@keyframes rollen { 0% { transform: rotate(-35deg) scale(.86); } 70% { transform: rotate(6deg) scale(1.03); } 100% { transform: none; } }

.rechnung { text-align: center; margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--linie); }
.rechnung .kombi { font: 400 2rem/1.1 "Instrument Serif", serif; margin: 0 0 12px; }
.gleichung { display: flex; justify-content: center; align-items: center; flex-wrap: wrap; gap: 10px 12px; }
.topf { min-width: 92px; padding: 6px 12px 8px; border: 2px solid; text-align: center; }
.topf .mono { display: block; font-size: 0.7rem; }
.topf b { display: block; font: 600 1.7rem/1.1 "Martian Mono", monospace; }
.topf--wert { border-color: var(--gruenspan); background: var(--wert-grund); color: var(--gruenspan); }
.topf--kraft { border-color: var(--glut); background: var(--kraft-grund); color: var(--glut); }
.gleichung .op { color: var(--leise); font-size: 1.4rem; }
.gleichung .punkte { font: 400 2.6rem/1 "Instrument Serif", serif; font-variant-numeric: lining-nums; }
.stoffe { list-style: none; margin: 14px 0 0; padding: 0; display: flex; justify-content: center; flex-wrap: wrap; gap: 6px; }
.stoffe li { display: inline-flex; align-items: center; gap: 7px; padding: 4px 11px; border: 1px solid var(--rand); font-weight: 600; font-size: 0.95rem;
  clip-path: polygon(6px 0, calc(100% - 6px) 0, 100% 6px, 100% 100%, 0 100%, 0 6px); background: var(--flaeche2); }
.stoffe li::before { content: ""; width: 10px; height: 10px; border-radius: 50%; background: var(--farbe, var(--leise)); }
.stoffe .vorspann-stoffe { border: 0; background: none; color: var(--leise); font-weight: 400; padding-left: 0; clip-path: none; }
.stoffe .vorspann-stoffe::before { display: none; }
.knopf { min-height: 52px; padding: 0 22px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; cursor: pointer;
  font: 600 1.05rem "Instrument Sans", sans-serif; border: 0; background: var(--gruenspan); color: var(--auf-akzent); text-decoration: none;
  clip-path: polygon(var(--f) 0, calc(100% - var(--f)) 0, 100% var(--f), 100% 100%, 0 100%, 0 var(--f)); }
.knopf:focus-visible { outline: none; box-shadow: inset 0 0 0 3px var(--auf-akzent), inset 0 0 0 5px var(--text); }
.knopf--leise { background: var(--flaeche2); color: var(--text); box-shadow: inset 0 0 0 1.5px var(--rand); }
.knopf--leise:focus-visible { box-shadow: inset 0 0 0 3px var(--gruenspan); }
.knopf:disabled { opacity: .5; cursor: default; }
.tisch-knoepfe { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; }
.tisch-knoepfe .knopf { flex: 1 1 200px; }
.tisch .erklaer { color: var(--leise); font-size: 0.95rem; margin: 14px 0 0; }

/* ---------- Abschnitte ---------- */
.abschnitt { padding: clamp(52px, 8vw, 100px) 0; }
.abschnitt--flaeche { background: #132320; border-block: 1px solid var(--linie); }
.kopfzeile { margin-bottom: clamp(26px, 4vw, 44px); max-width: 760px; }
.kopfzeile .mono { color: var(--gruenspan); display: block; margin-bottom: 10px; }
.vorspann { font-size: 1.18rem; color: var(--leise); margin-top: 16px; max-width: 40em; }

.raster { display: grid; gap: 20px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); }
.raster .platte h3 { margin-bottom: 8px; }
.raster .platte .mono { color: var(--gruenspan); display: block; margin-bottom: 10px; font-size: 0.72rem; }
.raster .platte p:last-child { margin-bottom: 0; }

/* So geht's: drei Stationen auf der Walz */
.walz { list-style: none; margin: 0; padding: 0; display: grid; gap: 20px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); }

/* Werkstatt mit Talismanen */
.werkstatt { display: grid; gap: 28px; grid-template-columns: 1fr; align-items: start; }
@media (min-width: 900px) { .werkstatt { grid-template-columns: 1.2fr 1fr; } }
.talismane { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; }
.talismane figure { margin: 0; }
.talismane img { width: 100%; border: 2px solid var(--glut); }
.talismane li:nth-child(n+3) img { border-color: var(--rand); }
.talismane figcaption { font: 400 1.25rem/1.2 "Instrument Serif", serif; margin-top: 6px; }
.talismane small { display: block; color: var(--leise); font: 400 0.9rem/1.4 "Instrument Sans", sans-serif; }
.punktliste { margin: 0; padding: 0; list-style: none; display: grid; gap: 12px; }
.punktliste li { padding-left: 26px; position: relative; }
.punktliste li::before { content: ""; position: absolute; left: 2px; top: 0.55em; width: 9px; height: 9px; background: var(--gruenspan); transform: rotate(45deg); }

/* Geschichte */
.geschichte { display: grid; gap: 28px; grid-template-columns: 1fr; align-items: center; }
@media (min-width: 900px) { .geschichte { grid-template-columns: 1fr 1fr; } }
.stich { margin: 0; }
.stich img { border: 1px solid var(--linie); outline: 1px solid var(--linie); outline-offset: 5px; }
.stich figcaption { color: var(--leise); font-size: 0.92rem; margin-top: 12px; }
.sage { font: 400 clamp(1.4rem, 2.6vw, 1.75rem)/1.35 "Instrument Serif", serif; margin: 0 0 18px; }

/* Bilder */
.galerie { list-style: none; margin: 0; padding: 4px 4px 18px; display: flex; gap: 18px; overflow-x: auto; scroll-snap-type: x mandatory; }
.galerie li { flex: none; width: 236px; scroll-snap-align: start; }
.galerie figure { margin: 0; }
.galerie img { width: 236px; height: auto; border: 1px solid var(--rand); }
.galerie figcaption { font: 400 0.72rem/1.5 "Martian Mono", monospace; letter-spacing: 0.06em; text-transform: uppercase; color: var(--leise); margin-top: 10px; }

/* Grade */
.grade { list-style: none; margin: 18px 0 0; padding: 0; display: grid; gap: 0; }
.grade li { display: flex; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--linie); }
.grade li span:last-child { color: var(--leise); font: 400 0.75rem/1.8 "Martian Mono", monospace; letter-spacing: 0.08em; text-transform: uppercase; text-align: right; }
.grade li.frei span:last-child { color: var(--gruenspan); }
.preis { display: grid; gap: 22px; grid-template-columns: 1fr; }
@media (min-width: 860px) { .preis { grid-template-columns: 1fr 1fr; } }
.betrag { font: 600 2rem/1 "Martian Mono", monospace; color: var(--gruenspan); margin: 4px 0 12px; }
.kleingedruckt { font-size: 0.95rem; color: var(--leise); margin-top: 14px; }

/* Fragen */
.fragen { display: grid; gap: 12px; max-width: 860px; }
.fragen details { background: var(--flaeche); border: 1px solid var(--linie); border-left: 3px solid var(--rand); }
.fragen details[open] { border-left-color: var(--gruenspan); }
.fragen summary { cursor: pointer; list-style: none; min-height: 52px; padding: 12px 48px 12px 18px; position: relative; display: flex; align-items: center;
  font: 400 1.4rem/1.2 "Instrument Serif", serif; }
.fragen summary::-webkit-details-marker { display: none; }
.fragen summary::after { content: "+"; position: absolute; right: 18px; font: 400 1.2rem "Martian Mono", monospace; color: var(--gruenspan); }
.fragen details[open] summary::after { content: "–"; }
.fragen details > div { padding: 12px 18px 6px; border-top: 1px solid var(--linie); color: var(--text); }

.schluss { text-align: center; }
.schluss .vorspann { margin-inline: auto; margin-bottom: 22px; }

.fuss { border-top: 1px solid var(--linie); box-shadow: 0 -4px 0 -3px var(--linie); padding: 40px 0 48px; color: var(--leise); font-size: 0.98rem; }
.fuss ul { list-style: none; margin: 0 0 16px; padding: 0; display: flex; flex-wrap: wrap; gap: 4px 22px; }
.fuss a { color: var(--text); display: inline-flex; min-height: 44px; align-items: center; }
.fuss p { margin: 0 0 6px; }
