/* ai.lowest.digital – Gestaltung von lowest.digital (website/src/app/globals.css), ohne Tailwind nachgebaut.
   Hausregeln von dort gelten hier auch:
   1. Genau eine gesättigte Farbe: --primary. Kein zweiter Akzent.
   2. Kontur statt Schatten.
   3. Hover bewegt die Kontur, Aktivierung die Füllung.
   4. Fließtext nie in Versalien, nie mit Laufweite. Versalien nur in .t-label (Mono, Mikroschrift).
   5. --border und --rule tragen nie Information.
   Die Maßlinie (.mass) erscheint nur, wo sie etwas misst: Lesezeit und Zahl der Quellen.
   Keine Bewegung, keine Übergänge – die Ruhe ist gewollt. */

@font-face { font-family: "Archivo"; src: url("fonts/archivo-latin-standard-normal.woff2") format("woff2");
  font-weight: 100 900; font-stretch: 62% 125%; font-display: swap; }
@font-face { font-family: "Geist"; src: url("fonts/geist-latin-wght-normal.woff2") format("woff2");
  font-weight: 100 900; font-display: swap; }
@font-face { font-family: "Geist Mono"; src: url("fonts/geist-mono-latin-wght-normal.woff2") format("woff2");
  font-weight: 100 900; font-display: swap; }

:root {
  color-scheme: light;
  /* Werte und Kontraste wie in globals.css von lowest.digital */
  --background: #F7F6F3;          /* Papier */
  --foreground: #18161C;          /* 16.60:1 auf bg */
  --card: #FFFFFF;
  --primary: #DA0055;             /* 4.73:1 bg / 5.11:1 card */
  --primary-hover: #C30046;       /* 5.70:1 bg */
  --primary-active: #AA003B;      /* 7.01:1 bg */
  --muted-foreground: #525159;    /* 7.21:1 bg / 7.79:1 card */
  --accent: #FCE9EB;              /* Hover-Tinte */
  --secondary: #EAE8E3;           /* Papierton der Balken */
  --border: #DBD9D5;              /* nur dekorativ */
  --rule: #A7A49E;                /* Zeichenlinie, trägt nie Information */
  --font-display: "Archivo", system-ui, sans-serif;
  --font-sans: "Geist", system-ui, sans-serif;
  --font-mono: "Geist Mono", ui-monospace, monospace;
  --rahmen: 72rem;
  --schmal: 42rem;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--background); color: var(--foreground);
  font-family: var(--font-sans); font-size: 1.0625rem; line-height: 1.65;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; height: auto; }
a { color: var(--foreground); text-decoration-color: var(--rule); text-underline-offset: 0.2em; text-decoration-thickness: 1px; }
a:hover { text-decoration-color: var(--primary); }
a:active { color: var(--primary-active); }
:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; border-radius: 2px; }

.skip { position: absolute; left: -999px; top: 0; background: var(--card); padding: 0.5rem 1rem; z-index: 10; }
.skip:focus { left: 1rem; top: 1rem; }

.rahmen { max-width: var(--rahmen); margin: 0 auto; padding: 0 1.5rem; }
.rahmen.schmal { max-width: calc(var(--schmal) + 3rem); }

.t-label {
  font-family: var(--font-mono); font-size: 0.6875rem; line-height: 1.3; font-weight: 500;
  text-transform: uppercase; letter-spacing: 0.18em; color: var(--muted-foreground); margin: 0;
}
.t-label a { color: inherit; text-decoration: none; }
.t-label a:hover { color: var(--foreground); text-decoration: underline; text-decoration-color: var(--primary); }

/* Kopf ---------------------------------------------------------------------------------------------- */
.kopf { background: var(--card); border-bottom: 1px solid var(--border); }
.kopf-innen { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 3.75rem; flex-wrap: wrap; }
.marke { display: inline-flex; align-items: center; gap: 0.5rem; text-decoration: none; }
.marke img { display: block; height: 22px; width: auto; }
.marke-zusatz {
  font-family: var(--font-mono); font-size: 0.75rem; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--primary); border: 1px solid var(--primary); border-radius: 4px; padding: 0.05rem 0.4rem; line-height: 1.4;
}
.kopf nav { display: flex; gap: 1.25rem; font-size: 0.875rem; }
.kopf nav a { text-decoration: none; color: var(--muted-foreground); padding: 0.25rem 0; border-bottom: 2px solid transparent; }
.kopf nav a:hover { color: var(--foreground); border-bottom-color: var(--border); }
.kopf nav a[aria-current="page"] { color: var(--foreground); border-bottom-color: var(--primary); }

.preview-bar { background: var(--foreground); color: var(--card); font-family: var(--font-mono); font-size: 0.75rem; text-align: center; padding: 0.4rem; }

/* Heldenbereich ------------------------------------------------------------------------------------- */
.held { padding: 4.5rem 0 3.5rem; border-bottom: 1px solid var(--border); }
.held-klein { padding: 3rem 0 2.25rem; }
.held-beitrag { padding: 3.25rem 0 2.25rem; }
h1, h2, h3 { font-family: var(--font-display); font-stretch: 106%; font-weight: 700; line-height: 1.1; letter-spacing: -0.01em; }
h1 { font-size: clamp(2.1rem, 5vw, 3.5rem); margin: 0.9rem 0 1.25rem; max-width: 22ch; text-wrap: balance; }
.held-beitrag h1 { font-size: clamp(1.9rem, 4.2vw, 2.9rem); max-width: none; }
.held-text, .teaser { font-size: 1.1875rem; line-height: 1.55; color: var(--muted-foreground); max-width: 40rem; margin: 0; }
.held-beitrag .teaser { color: var(--foreground); }

/* Maßlinie: misst Lesezeit und Quellenzahl. Wert steht als sichtbarer Text darin. */
.mass {
  position: relative; margin: 1.75rem 0 0; padding: 0 0 0 0.9rem; font-family: var(--font-mono);
  font-size: 0.75rem; color: var(--muted-foreground); letter-spacing: 0.04em;
}
.mass::before { content: ""; position: absolute; left: 0; top: 0.15rem; bottom: 0.15rem; width: 7px;
  background: linear-gradient(var(--rule), var(--rule)) top left / 7px 1px no-repeat,
              linear-gradient(var(--rule), var(--rule)) bottom left / 7px 1px no-repeat,
              linear-gradient(var(--rule), var(--rule)) 3px 0 / 1px 100% no-repeat; }

.ki-hinweis {
  margin: 1.25rem 0 0; padding: 0.75rem 1rem; border: 1px solid var(--border); border-left: 2px solid var(--primary);
  background: var(--card); font-size: 0.875rem; line-height: 1.5; color: var(--muted-foreground); border-radius: 0 6px 6px 0;
}
.entwurf { color: var(--primary); }

/* Liste --------------------------------------------------------------------------------------------- */
.abschnitt { padding-top: 2.5rem; padding-bottom: 4rem; }
.liste { list-style: none; margin: 1rem 0 0; padding: 0; }
.eintrag { padding: 1.75rem 0; border-top: 1px solid var(--border); display: grid; gap: 0.4rem; }
.eintrag-kopf { display: flex; gap: 0.9rem; align-items: baseline; flex-wrap: wrap; margin: 0; }
.eintrag-titel { font-size: clamp(1.35rem, 2.6vw, 1.75rem); margin: 0; max-width: 40ch; text-wrap: balance; }
.eintrag-titel a { text-decoration: none; }
.eintrag-titel a:hover { text-decoration: underline; text-decoration-color: var(--primary); text-decoration-thickness: 2px; }
.eintrag-teaser { margin: 0; max-width: 44rem; color: var(--muted-foreground); }
.eintrag-mass { margin: 0.2rem 0 0; font-family: var(--font-mono); font-size: 0.75rem; color: var(--muted-foreground); }
.leer { color: var(--muted-foreground); }

/* Beitragstext -------------------------------------------------------------------------------------- */
.text { padding-top: 2.5rem; padding-bottom: 4rem; }
.text h2 { font-size: 1.5rem; margin: 2.5rem 0 0.75rem; }
.text p, .text li { max-width: var(--schmal); }
.text p { margin: 0 0 1.1rem; }
.text ul, .text ol { padding-left: 1.25rem; margin: 0 0 1.1rem; }
.text li { margin-bottom: 0.4rem; }
.fn { font-family: var(--font-mono); font-size: 0.68em; line-height: 0; margin-left: 0.1em; }
.fn a { color: var(--primary); text-decoration: none; padding: 0 0.1em; }
.fn a:hover { text-decoration: underline; }
.fn-sep { color: var(--muted-foreground); }

.korrektur { border: 1px solid var(--primary); border-radius: 6px; padding: 0.9rem 1.1rem; margin-bottom: 2rem; background: var(--card); }
.korrektur p { margin: 0.4rem 0 0; font-size: 0.9375rem; }

.quellen, .entstehung { margin-top: 3rem; padding-top: 1.5rem; border-top: 1px solid var(--border); }
.quellen h2, .entstehung h2 { margin-top: 0; font-size: 1.125rem; }
.quellen ol { font-size: 0.9375rem; padding-left: 1.75rem; }
.quellen li { margin-bottom: 0.6rem; overflow-wrap: anywhere; }
.quellen li:target { background: var(--accent); outline: 1px solid var(--primary); outline-offset: 4px; }
.quelle-meta { display: block; font-size: 0.8125rem; color: var(--muted-foreground); }
.entstehung { font-size: 0.9375rem; }
.entstehung dl { display: grid; grid-template-columns: 12rem 1fr; gap: 0.5rem 1.25rem; margin: 0 0 1rem; }
.entstehung dt { font-weight: 600; }
.entstehung dd { margin: 0; color: var(--muted-foreground); }
.schritte li { margin-bottom: 0.8rem; }


/* Das Wichtigste ------------------------------------------------------------------------------------ */
.kern { border: 1px solid var(--border); border-radius: 6px; background: var(--card); padding: 1.1rem 1.25rem 0.4rem; margin: 0 0 2.25rem; }
.kern h2 { margin: 0 0 0.6rem; font-size: 0.6875rem; }
.kern ol { list-style: none; padding: 0; margin: 0; counter-reset: kern; }
.kern li { counter-increment: kern; position: relative; padding: 0 0 0.75rem 2rem; margin: 0; font-size: 1rem; line-height: 1.5; }
.kern li::before { content: counter(kern, decimal-leading-zero); position: absolute; left: 0; top: 0.1rem;
  font-family: var(--font-mono); font-size: 0.75rem; color: var(--primary); }

/* Abbildungen: technische Zeichnung. Kontur in Tinte, eine Füllung in --primary für den Wert, um den es geht;
   die übrigen tragen Papierton. Hervorhebung zusätzlich über Schriftgewicht – Farbe nie allein. */
.fig { margin: 2rem 0 2.25rem; padding: 1.25rem 1.25rem 1rem; border: 1px solid var(--border); border-radius: 6px; background: var(--card); max-width: var(--schmal); }
.fig figcaption { font-family: var(--font-display); font-stretch: 104%; font-weight: 700; font-size: 1.0625rem; line-height: 1.3; margin-bottom: 1rem; }
.fig figcaption .t-label { display: block; margin-bottom: 0.35rem; font-family: var(--font-mono); font-stretch: normal; }
.skala { position: relative; display: flex; justify-content: space-between; margin: 0 0 0.75rem calc(38% + 0.75rem);
  padding-top: 0.55rem; font-family: var(--font-mono); font-size: 0.6875rem; color: var(--muted-foreground); }
.skala::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 7px;
  background: linear-gradient(var(--rule), var(--rule)) 0 3px / 100% 1px no-repeat,
              linear-gradient(var(--rule), var(--rule)) left top / 1px 7px no-repeat,
              linear-gradient(var(--rule), var(--rule)) right top / 1px 7px no-repeat; }
.balken { margin: 0; display: grid; gap: 0.7rem; }
.balken .zeile { display: grid; grid-template-columns: 38% 1fr; gap: 0.75rem; align-items: center; }
.balken dt { font-size: 0.875rem; line-height: 1.3; color: var(--muted-foreground); }
.balken dd { margin: 0; }
.bar { display: block; width: 100%; height: 1.1rem; overflow: visible; }
.bar rect { fill: var(--secondary); stroke: var(--foreground); stroke-width: 1px; }
.balken .wert { display: block; margin-top: 0.2rem; font-family: var(--font-mono); font-size: 0.8125rem; }
.balken .hervor dt, .balken .hervor .wert { color: var(--foreground); font-weight: 600; }
.balken .hervor .bar rect { fill: var(--primary); stroke: var(--primary-active); }

.chronik ol { list-style: none; margin: 0; padding: 0 0 0 1.25rem; position: relative; }
.chronik ol::before { content: ""; position: absolute; left: 3px; top: 0.45rem; bottom: 0.45rem; width: 1px; background: var(--rule); }
.chronik li { position: relative; display: grid; gap: 0.1rem; padding-bottom: 0.9rem; margin: 0; }
.chronik li::before { content: ""; position: absolute; left: calc(-1.25rem); top: 0.4rem; width: 7px; height: 7px;
  background: var(--card); border: 1px solid var(--foreground); border-radius: 50%; }
.chronik li.jetzt::before { background: var(--primary); border-color: var(--primary); }
.chronik time { font-family: var(--font-mono); font-size: 0.75rem; color: var(--muted-foreground); }
.chronik li.jetzt time { color: var(--foreground); font-weight: 600; }
.chronik li span { font-size: 0.9375rem; line-height: 1.45; }

/* Startseite ---------------------------------------------------------------------------------------- */
.held-start { padding-bottom: 3rem; }
.aufmacher { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 2.5rem; align-items: start;
  padding-top: 2.75rem; padding-bottom: 2.75rem; }
.aufmacher-titel { font-size: clamp(1.7rem, 3.4vw, 2.5rem); margin: 0.6rem 0 0.9rem; text-wrap: balance; }
.aufmacher-titel a, .karte-titel a { text-decoration: none; }
.aufmacher-titel a:hover, .karte-titel a:hover { text-decoration: underline; text-decoration-color: var(--primary); text-decoration-thickness: 2px; }
.aufmacher-teaser { font-size: 1.125rem; line-height: 1.55; margin: 0 0 1rem; }
.aufmacher-kern { margin: 0 0 1rem; padding-left: 1.1rem; color: var(--muted-foreground); font-size: 0.9375rem; }
.aufmacher-kern li { margin-bottom: 0.35rem; }
.aufmacher-fig .fig { margin: 0; }
.marker { color: var(--primary); }

.rubrikleiste { display: flex; flex-wrap: wrap; gap: 0.5rem; padding-top: 1.25rem; padding-bottom: 1.25rem;
  border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.rubrikleiste a { display: inline-flex; align-items: center; gap: 0.5rem; padding: 0.3rem 0.75rem; border: 1px solid var(--border);
  border-radius: 999px; background: var(--card); font-size: 0.875rem; text-decoration: none; }
.rubrikleiste a:hover { border-color: var(--foreground); }
.rubrikleiste a:active { background: var(--accent); }
.rubrikleiste .zahl { font-family: var(--font-mono); font-size: 0.75rem; color: var(--muted-foreground); }

.raster { list-style: none; margin: 1rem 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(19rem, 1fr)); gap: 1rem; }
.karte { display: flex; flex-direction: column; gap: 0.5rem; padding: 1.25rem; background: var(--card); border: 1px solid var(--border); border-radius: 6px; }
.karte:hover { border-color: var(--foreground); }
.karte-titel { font-size: 1.25rem; margin: 0; text-wrap: balance; }
.karte .eintrag-teaser { font-size: 0.9375rem; line-height: 1.5; flex: 1; }
.karte-zahl { margin: 0.25rem 0 0; font-family: var(--font-mono); font-size: 0.8125rem; color: var(--muted-foreground); border-top: 1px solid var(--border); padding-top: 0.6rem; }
.karte-zahl .groß { font-family: var(--font-display); font-stretch: 106%; font-weight: 700; font-size: 1.5rem; color: var(--foreground); }
.karte-zahl .klein { display: block; }

/* Fuß ----------------------------------------------------------------------------------------------- */
.fuss { background: var(--card); border-top: 1px solid var(--border); padding: 3rem 0 1.5rem; font-size: 0.875rem; }
.fuss-innen { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 2rem; }
.fuss nav { display: flex; flex-direction: column; gap: 0.45rem; }
.fuss nav a { text-decoration: none; color: var(--muted-foreground); }
.fuss nav a:hover { color: var(--foreground); text-decoration: underline; text-decoration-color: var(--primary); }
.fuss .t-label { margin-bottom: 0.4rem; }
.fuss-claim { font-family: var(--font-display); font-stretch: 106%; font-weight: 700; font-size: 1.25rem; line-height: 1.2; margin: 0 0 0.75rem; }
.fuss-notiz { color: var(--muted-foreground); margin: 0; max-width: 28rem; }
.fuss-copy { margin-top: 2.5rem; color: var(--muted-foreground); font-size: 0.8125rem; }

@media (max-width: 48rem) {
  .rahmen { padding-left: 1rem; padding-right: 1rem; }
  .held { padding: 3rem 0 2.5rem; }
  .fuss-innen { grid-template-columns: 1fr; }
  .entstehung dl { grid-template-columns: 1fr; }
  .aufmacher { grid-template-columns: 1fr; gap: 1.75rem; }
  .balken .zeile { grid-template-columns: 1fr; gap: 0.3rem; }
  .skala { margin-left: 0; }
  .entstehung dd { margin-bottom: 0.5rem; }
  .kopf nav { gap: 1rem; }
}

@media print {
  .kopf nav, .fuss, .skip { display: none; }
  body { background: #fff; }
}
