/* Selbst gehostet (vorher Google Fonts), damit die Seite auch in der Vorschau des CMS mit
   ihren Schriften erscheint und keine Anfrage an Google geht. Archivo und Kalam: SIL Open Font License. */
@font-face {
  font-family: 'Archivo';
  font-style: normal;
  font-weight: 400 900;
  font-stretch: 62% 125%;
  font-display: swap;
  src: url(schriften/archivo-400-900-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Archivo';
  font-style: normal;
  font-weight: 400 900;
  font-stretch: 62% 125%;
  font-display: swap;
  src: url(schriften/archivo-400-900-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Kalam';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(schriften/kalam-400-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Kalam';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(schriften/kalam-400-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Kalam';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url(schriften/kalam-700-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Kalam';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url(schriften/kalam-700-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* Version 5 (CMS): wie Version 4, die Galerien sind Listen im Ferreira CMS.
   Darum hängt die Anordnung an der Position (nth-of-type), nicht an Klassen pro Bild:
   ein neues, verschobenes oder gelöschtes Bild fügt sich ohne Änderung am CSS ein.
   Die Randnotizen stehen im HTML nach den Bildern und werden mit order/grid platziert.

   Version 4: Skizzenbuch in Druckfarben.
   Aufbau, Schrift und Randnotizen aus Version 3, Farben aus Version 1
   (Papier, Druckblau, Pink, Gelb), die Zeichnungen schräg aufgeklebt wie in Version 2.
   Blau ist die Textfarbe. Pink nur als Fläche, Raster und Pfeile, als Schrift
   nur die dunkle Variante. Gelb für Klebeband und die Lehrstelle. */

:root {
  --papier: #e9e3d2;
  --druckweiss: #fbf8f0;
  --blau: #283f7a;          /* gedämpft nach Andreias Feedback, 7.9:1 auf Papier */
  --blau-tief: #1b2d5c;     /* 10.4:1 auf Papier */
  --pink: #cf5a95;          /* gedämpft: nur Fläche, Raster, Pfeile */
  --pink-tief: #962a63;     /* Randnotizen: 5.8:1 auf Papier */
  --gelb: #ecd060;
  --linie: 3px;
  --rand: 16px;
  --display: "Archivo", "Arial Narrow", sans-serif;
  --hand: "Kalam", "Comic Sans MS", cursive;

  /* Papierkorn als gekacheltes SVG-Rauschen (aus Version 1). */
  --korn: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='240'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .32 0 0 0 0 .27 0 0 0 0 .18 0 0 0 .55 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.5'/%3E%3C/svg%3E");
}

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

html { -webkit-text-size-adjust: 100%; }

@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

body {
  margin: 0;
  background: var(--papier) var(--korn);
  color: var(--blau-tief);
  font-family: var(--display);
  font-stretch: 100%;
  font-size: 18px;
  line-height: 1.55;
}

img { display: block; max-width: 100%; height: auto; }

a { color: inherit; }

:focus-visible {
  outline: 3px solid var(--blau-tief);
  outline-offset: 4px;
}

.filter-def { position: absolute; width: 0; height: 0; overflow: hidden; }

.skip {
  position: absolute;
  left: 8px;
  top: -60px;
  z-index: 10;
  background: var(--blau-tief);
  color: var(--papier);
  padding: 10px 14px;
}
.skip:focus { top: 8px; }

.punkt { color: var(--pink); }

/* ---------- Kopf ---------- */

.kopf {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px var(--rand);
  border-bottom: var(--linie) solid var(--blau);
}

.kopf-name {
  display: none;
  font-weight: 800;
  font-stretch: 75%;
  font-size: 22px;
  letter-spacing: -0.01em;
  text-decoration: none;
  color: var(--blau);
}

.kopf-nav {
  display: flex;
  flex: 1;
  justify-content: space-between;
  gap: 12px;
}

.kopf-nav a {
  font-size: 17px;
  font-weight: 600;
  text-decoration: none;
  padding: 6px 0;
  border-bottom: 2px solid transparent;
}
.kopf-nav a:hover { border-bottom-color: var(--pink); }

/* ---------- Titelseite ---------- */

.titel {
  position: relative;
  isolation: isolate;
  padding: 14px var(--rand) 56px;
  overflow-x: clip;
}

/* Die eine Halbton-Fläche der Seite: pinkes Punktraster, das ausläuft. */
.titel-raster {
  position: absolute;
  z-index: -1;
  width: 120vw;
  aspect-ratio: 1;
  right: -60vw;
  top: 520px;
  background: radial-gradient(circle, var(--pink) 40%, transparent 44%) 0 0 / 9px 9px;
  -webkit-mask-image: radial-gradient(circle closest-side, #000 15%, rgb(0 0 0 / 0.5) 45%, transparent 100%);
  mask-image: radial-gradient(circle closest-side, #000 15%, rgb(0 0 0 / 0.5) 45%, transparent 100%);
  opacity: 0.55;
  pointer-events: none;
}

.titel-h {
  margin: 0;
  font-weight: 860;
  font-stretch: 62%;
  line-height: 0.8;
  letter-spacing: -0.03em;
  color: var(--blau);
}

/* Breiten gemessen: «Andreia» 2.69em, «zeichnet.» 3.12em, «Sommer 2027» 4.62em.
   Jede Zeile füllt die Spalte. */
.titel-gross {
  position: relative;
  display: block;
  width: max-content;
  font-size: calc((100vw - 2 * var(--rand)) / 2.74);
  white-space: nowrap;
}
.titel-verb { font-size: calc((100vw - 2 * var(--rand)) / 3.17); }

.druck-blau { display: block; position: relative; z-index: 1; }

/* Zweite Druckplatte: pinkes Halbtonraster, leicht verrutscht (Passer).
   Sie liegt unter dem Blau, damit die Schrift voll und gut lesbar bleibt;
   sichtbar ist nur der verschobene Rand. */
/* Die pinke Platte ist ein Pseudo-Element (Text aus data-druck): so steht der Name
   nur einmal im Text, für Screenreader und für die Gruppennamen im CMS. */
.titel-gross::after {
  content: attr(data-druck);
  content: attr(data-druck) / "";
  position: absolute;
  z-index: 0;
  inset: 0;
  color: var(--pink);
  -webkit-mask: radial-gradient(circle, #000 52%, transparent 56%) 0 0 / 0.055em 0.055em;
  mask: radial-gradient(circle, #000 52%, transparent 56%) 0 0 / 0.055em 0.055em;
  transform: translate(0.05em, 0.035em);
  pointer-events: none;
  user-select: none;
}

@media (prefers-reduced-motion: no-preference) {
  .titel-gross::after { animation: passer 900ms cubic-bezier(0.16, 1, 0.3, 1) 250ms both; }
}

@keyframes passer {
  from { transform: translate(0, 0); }
  to { transform: translate(0.05em, 0.035em); }
}

.titel-mittel {
  display: block;
  font-size: 10.5vw;
  font-weight: 760;
  font-stretch: 70%;
  letter-spacing: 0;
  margin: 0.18em 0 0.12em 0.04em;
}

/* Lehrstelle: die zweite grosse Aussage im ersten Bildschirm */
.lehrstelle {
  margin-top: 22px;
}

.lehrstelle-satz {
  margin: 0;
  display: flex;
  flex-direction: column;
  color: var(--blau);
}

.lehrstelle-oben {
  font-weight: 760;
  font-stretch: 75%;
  font-size: clamp(24px, 6.6vw, 40px);
  line-height: 1.05;
}

.lehrstelle-gross {
  font-weight: 860;
  font-stretch: 62%;
  font-size: calc((100vw - 2 * var(--rand)) / 4.72);
  line-height: 0.92;
  letter-spacing: -0.02em;
  word-spacing: 0.08em;
  white-space: nowrap;
}

/* Gelb als Leuchtstift-Fläche hinter dem Datum */
.lehrstelle mark {
  color: inherit;
  background: linear-gradient(to bottom, transparent 18%, var(--gelb) 18% 92%, transparent 92%);
  padding: 0 0.06em;
}

.lehrstelle-beruf {
  margin: 12px 0 0;
  max-width: 30em;
}

.titel .titel-bild { margin-top: 34px; --r: -1deg; --band-r: 3deg; }

.titel-text {
  max-width: 34em;
  margin: 8px 0 0;
}

.knoepfe {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 18px;
}

.knopf {
  display: inline-block;
  border: var(--linie) solid var(--blau);
  background: var(--druckweiss);
  color: var(--blau);
  padding: 10px 18px 11px;
  font-size: 18px;
  font-weight: 700;
  text-decoration: none;
  line-height: 1.2;
}
.knopf-voll { background: var(--blau); color: var(--druckweiss); }
.knopf:hover { background: var(--gelb); border-color: var(--blau); color: var(--blau-tief); }

/* ---------- Aufgeklebte Zeichnungen (Polaroid mit Klebeband) ---------- */

.panel {
  position: relative;
  margin: 0;
  padding: 10px 10px 0;
  background: var(--druckweiss);
  box-shadow:
    0 1px 1px rgb(70 55 25 / 0.22),
    0 18px 26px -18px rgb(70 55 25 / 0.6);
  rotate: var(--r, 0deg);
}

/* Klebeband: halbtransparent, im Multiply wie gedruckte Farbe */
.panel::before {
  content: "";
  position: absolute;
  z-index: 2;
  top: -13px;
  left: 50%;
  width: 104px;
  height: 28px;
  translate: -50% 0;
  rotate: var(--band-r, -3deg);
  background: rgb(255 225 77 / 0.85);
  mix-blend-mode: multiply;
  clip-path: polygon(3% 0, 100% 0, 97% 100%, 0 100%);
  pointer-events: none;
}

.panel.band-pink::before { background: rgb(255 79 168 / 0.5); }

.bild-knopf {
  display: block;
  width: 100%;
  padding: 0;
  margin: 0;
  border: 0;
  background: #fff;
  cursor: zoom-in;
}

.bild-knopf img { width: 100%; }

/* Die Bilder der Listen haben keine width/height-Attribute: sonst schneidet das CMS ein neues
   Bild auf das Format des ersten Bildes zu. Bis ein Bild geladen ist, hält dieses Format den
   Platz frei; danach gilt das echte Format des Bildes («auto»). */
.bild-knopf img { aspect-ratio: auto 2 / 3; }
.panels-heft .bild-knopf img { aspect-ratio: auto 5 / 4; }
.seite-quer .bild-knopf img { aspect-ratio: auto 3 / 2; }

.panel:hover,
.panel:focus-within { rotate: 0deg; z-index: 3; }

@media (prefers-reduced-motion: no-preference) {
  .panel { transition: rotate 0.25s ease, box-shadow 0.25s ease; }
}

.panel:hover {
  box-shadow:
    0 1px 1px rgb(70 55 25 / 0.22),
    0 26px 34px -20px rgb(70 55 25 / 0.7);
}

/* Bleistift auf grauem Papier wirkt am Handy blass. Die Vorschau bekommt eine
   Tonwertkurve (Filter #graphit im HTML): Papier heller, Graphit dunkler.
   Die Grossansicht zeigt die Originaldatei unverändert. */
.bleistift img { filter: url(#graphit); }

/* ---------- Legenden (unten im Polaroid) ---------- */

.legende {
  display: flex;
  flex-direction: column;
  padding: 10px 4px 12px;
  font-size: 16px;
  line-height: 1.3;
  color: var(--blau-tief);
}
.legende strong { font-weight: 700; }

.legende-frei {
  display: inline-flex;
  margin: 20px 0 0;
  padding: 0;
}

/* ---------- Handnotizen ---------- */

.notiz {
  margin: 0;
  font-family: var(--hand);
  font-weight: 400;
  font-size: 23px;
  line-height: 1.15;
  color: var(--pink-tief);
  display: flex;
  align-items: center;
  gap: 6px;
  transform: rotate(-3deg);
}

.notiz-hell { color: var(--papier); }

.notiz-titel { justify-content: flex-end; margin: 18px 4px 10px 0; }
.notiz-titel .pfeil { order: -1; transform: scaleX(-1) rotate(-8deg); }

.pfeil {
  flex: none;
  overflow: visible;
}
.pfeil path {
  fill: none;
  stroke: var(--pink);
  stroke-width: 2.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.notiz-hell .pfeil path { stroke: var(--gelb); }

/* ---------- Kapitel ---------- */

.kapitel {
  padding: 56px var(--rand) 72px;
  border-top: var(--linie) solid var(--blau);
  overflow-x: clip;
}

.kapitel-kopf { margin-bottom: 40px; }

.kapitel-h {
  margin: 0 0 18px;
  font-weight: 860;
  font-stretch: 62%;
  font-size: clamp(64px, 19vw, 176px);
  line-height: 0.84;
  letter-spacing: -0.03em;
  color: var(--blau);
}

.kapitel-kopf p {
  margin: 0;
  max-width: 30em;
}

/* Am Handy: abwechselnd links und rechts, leicht geneigt */
.panels {
  display: flex;
  flex-direction: column;
  gap: 44px;
}

.panels > .panel { width: 88%; }
.panels > .panel:nth-of-type(odd) { align-self: flex-start; --r: -1.2deg; }
.panels > .panel:nth-of-type(even) { align-self: flex-end; --r: 1deg; --band-r: 4deg; }
.panels > .panel:nth-of-type(3n)::before { background: rgb(255 79 168 / 0.5); left: 30%; --band-r: -8deg; }

.notiz-flucht { align-self: flex-end; margin-right: 8px; }

/* Am Handy steht jede Notiz zwischen den Bildern, zu denen sie gehört */
.panels-hinschauen > .panel:nth-of-type(n+3),
.panels-heft > .panel:nth-of-type(n+2),
.seiten-paar > .panel:nth-of-type(n+2) { order: 2; }
.panels-hinschauen > .notiz,
.panels-heft > .notiz,
.seiten-paar > .notiz { order: 1; }
.notiz-flucht .pfeil { transform: scaleX(-1); order: 2; }

/* Notizbuch-Kapitel: blau liniertes Papier wie in ihren Heften */
.kapitel-heft .panels {
  margin: 0 calc(var(--rand) * -1);
  padding: 34px var(--rand) 44px;
  background-image: repeating-linear-gradient(to bottom, transparent 0 33px, rgb(44 76 158 / 0.2) 33px 34px);
}

.notiz-namen { align-self: flex-start; margin-left: 4px; }

/* ---------- Blaue Druckplatte (Farbarbeiten) ---------- */

.seiten {
  background: var(--blau) var(--korn);
  color: var(--papier);
  padding: 56px var(--rand) 80px;
  overflow: clip;
}

.seiten-h {
  margin: 0 0 44px;
  font-weight: 860;
  font-stretch: 62%;
  font-size: clamp(64px, 19vw, 176px);
  line-height: 0.84;
  letter-spacing: -0.03em;
}

.seiten-paar {
  display: flex;
  flex-direction: column;
  gap: 44px;
}

.seite { width: 88%; max-width: 460px; }
.seiten-paar > .seite:nth-of-type(odd) { --r: -1.4deg; }
.seiten-paar > .seite:nth-of-type(even) { --r: 1.4deg; --band-r: 5deg; align-self: flex-end; }
.seiten-paar > .seite:nth-of-type(even)::before { background: rgb(255 79 168 / 0.55); }

.seite { box-shadow: 0 20px 30px -18px rgb(5 12 40 / 0.7); }

.notiz-buch { align-self: center; transform: rotate(-4deg); }

.seiten-einzeln { padding-top: 72px; }

.quer-liste {
  display: flex;
  flex-direction: column;
  gap: 56px;
}

.seite-quer {
  width: auto;
  max-width: 980px;
  margin: 0 auto;
  --r: -1deg;
}
.seite-quer:nth-of-type(even) { --r: 1.2deg; --band-r: 4deg; }
.seite-quer:nth-of-type(even)::before { background: rgb(255 79 168 / 0.55); }

.notiz-wasser {
  justify-content: flex-end;
  margin-top: 26px;
  transform: rotate(-2deg);
}

/* ---------- Digitale Figuren ---------- */

.streifen {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 34px 18px;
  align-items: start;
}

.streifen .panel { padding-bottom: 10px; }
.streifen .panel::before { width: 76px; height: 24px; top: -11px; }
.streifen .panel:nth-child(odd) { --r: -1.4deg; }
.streifen .panel:nth-child(even) { --r: 1.2deg; margin-top: 36px; --band-r: 5deg; }
.streifen .panel:nth-child(4n+2)::before,
.streifen .panel:nth-child(4n+3)::before { background: rgb(255 79 168 / 0.5); }

.streifen img { aspect-ratio: 1328 / 1800; object-fit: cover; object-position: top; }

/* ---------- Über mich ---------- */

.ueber {
  padding: 56px var(--rand) 64px;
  border-top: var(--linie) solid var(--blau);
  overflow-x: clip;
}

.ueber-bild {
  margin: 8px 0 36px;
  width: 88%;
  max-width: 440px;
  rotate: -1.4deg;
}
.ueber-bild img {
  width: 100%;
  padding: 10px;
  background: var(--druckweiss);
  box-shadow: 0 18px 26px -18px rgb(70 55 25 / 0.6);
}
.ueber-bild figcaption {
  margin-top: 10px;
  font-size: 16px;
  color: var(--blau-tief);
}

.ueber-text { max-width: 34em; }
.ueber-text p { margin: 0 0 16px; }

/* Fett im Text «Über mich» (im CMS: fett) wird pink umkreist, wie von Hand */
.ueber-text strong {
  position: relative;
  white-space: nowrap;
  font-weight: 700;
  margin: 0 0.35em;
}
.ueber-text strong::after {
  content: "";
  position: absolute;
  left: -14px;
  top: -11px;
  width: calc(100% + 28px);
  height: calc(100% + 22px);
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -6 208 72' preserveAspectRatio='none'%3E%3Cpath d='M30 8 C 90 -2, 190 4, 194 28 C 198 52, 110 58, 50 54 C 4 50, 2 28, 14 18 C 26 8, 60 4, 96 6' fill='none' stroke='%23cf5a95' stroke-width='2.6' stroke-linecap='round' vector-effect='non-scaling-stroke'/%3E%3C/svg%3E") center / 100% 100% no-repeat;
  pointer-events: none;
}

/* ---------- Kontakt: blaue Platte mit pinkem Raster in der Ecke ---------- */

.kontakt {
  position: relative;
  isolation: isolate;
  padding: 64px var(--rand) 80px;
  background: var(--blau) var(--korn);
  color: var(--papier);
  overflow: hidden;
}

.kontakt::before {
  content: "";
  position: absolute;
  z-index: -1;
  width: 30rem;
  aspect-ratio: 1;
  right: -14rem;
  top: -12rem;
  background: radial-gradient(circle, var(--pink) 40%, transparent 44%) 0 0 / 10px 10px;
  -webkit-mask-image: radial-gradient(circle closest-side, #000 20%, transparent 100%);
  mask-image: radial-gradient(circle closest-side, #000 20%, transparent 100%);
  opacity: 0.75;
}

.kontakt-h {
  margin: 0 0 28px;
  font-weight: 860;
  font-stretch: 62%;
  font-size: clamp(64px, 19vw, 200px);
  line-height: 0.84;
  letter-spacing: -0.03em;
  text-shadow: 0.04em 0.03em 0 var(--pink);
}
.kontakt-h .punkt { color: var(--gelb); }

.kontakt-mail {
  display: inline-block;
  font-weight: 800;
  font-stretch: 75%;
  font-size: clamp(30px, 8.6vw, 84px);
  line-height: 1.1;
  color: var(--gelb);
  text-decoration: underline;
  text-decoration-color: var(--pink);
  text-decoration-thickness: 0.08em;
  text-underline-offset: 0.12em;
  overflow-wrap: anywhere;
}
.kontakt-mail:hover { text-decoration-color: var(--gelb); }

.seiten :focus-visible,
.kontakt :focus-visible,
.fuss :focus-visible { outline-color: var(--gelb); }

.fuss {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 4px 24px;
  padding: 18px var(--rand) 22px;
  background: var(--blau-tief);
  color: var(--papier);
  font-size: 16px;
}
.fuss p { margin: 0; }

/* ---------- Leuchte (Grossansicht) ---------- */

.leuchte {
  width: 100%;
  height: 100%;
  max-width: 100vw;
  max-height: 100dvh;
  margin: 0;
  padding: 10px;
  border: 0;
  background: var(--blau-tief);
  color: var(--papier);
}
.leuchte::backdrop { background: rgb(20 34 76 / 0.92); }
.leuchte :focus-visible { outline-color: var(--gelb); }

.leuchte-rahmen {
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  height: 100%;
}

.leuchte-bild {
  width: 100%;
  height: 100%;
  min-height: 0;
  object-fit: contain;
  padding: 12px;
}

.leuchte-leiste {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 20px;
  padding: 12px var(--rand) 16px;
  border-top: var(--linie) solid var(--papier);
}

.leuchte-text {
  margin: 0;
  display: flex;
  flex-direction: column;
  line-height: 1.3;
  flex: 1 1 14em;
}

.leuchte-zahl {
  margin: 0;
  font-family: var(--hand);
  font-size: 22px;
  color: var(--gelb);
}

.leuchte-knoepfe {
  display: flex;
  gap: 8px;
  flex: 1 1 100%;
}

.leuchte-knoepfe button {
  flex: 1;
  min-height: 46px;
  padding: 8px 14px;
  border: 2px solid var(--papier);
  background: transparent;
  color: var(--papier);
  font: 700 17px/1.2 var(--display);
  cursor: pointer;
}
.leuchte-knoepfe button:hover { background: var(--papier); color: var(--blau-tief); }
.leuchte-knoepfe .leuchte-zu { border-color: var(--gelb); background: var(--gelb); color: var(--blau-tief); }
.leuchte-knoepfe .leuchte-zu:hover { background: var(--papier); border-color: var(--papier); }

/* ---------- Handy: Knöpfe nebeneinander ---------- */

@media (max-width: 599px) {
  .knoepfe { gap: 10px; }
  .knopf { flex: 1 1 auto; text-align: center; padding: 10px 10px 11px; font-size: 17px; }
}

@media (max-width: 370px) {
  .lehrstelle { margin-top: 16px; }
  .lehrstelle-beruf { font-size: 17px; }
  .knopf { padding: 9px 8px 10px; font-size: 16px; }
}

/* ---------- Ab Tablet ---------- */

@media (min-width: 600px) {
  :root { --rand: 28px; }
  .kopf-name { display: inline; }
  .kopf-nav { flex: none; gap: 24px; }
  .leuchte-knoepfe { flex: none; }
  .streifen { gap: 34px 28px; }
}

/* ---------- Desktop ---------- */

@media (min-width: 900px) {
  :root { --rand: 40px; --linie: 4px; }

  .titel,
  .kapitel,
  .ueber {
    max-width: 1440px;
    margin: 0 auto;
  }

  .kapitel,
  .ueber { border-top: 0; box-shadow: 0 calc(var(--linie) * -1) 0 var(--blau); }

  .titel {
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr));
    column-gap: 24px;
    align-items: start;
    padding-top: 22px;
    padding-bottom: 64px;
  }

  .titel-raster {
    width: min(64vw, 56rem);
    right: -14vw;
    top: -10%;
  }

  /* Name und Lehrstelle teilen sich die Fensterhöhe: Schrift nach Breite
     und Höhe begrenzt, damit beides im ersten Bildschirm steht. */
  .titel-h { grid-column: 1 / 9; grid-row: 1; }
  .titel-gross { font-size: min(calc((min(100vw, 1440px) - 2 * var(--rand)) * 0.64 / 2.74), 20svh); }
  .titel-verb { font-size: min(calc((min(100vw, 1440px) - 2 * var(--rand)) * 0.64 / 3.17), 17.5svh); }
  .titel-mittel { font-size: min(4.6vw, 7svh, 72px); }

  .lehrstelle { grid-column: 1 / 9; grid-row: 2; margin-top: 3svh; }
  .lehrstelle-oben { font-size: min(3vw, 4.6svh, 44px); }
  .lehrstelle-gross { font-size: min(calc((min(100vw, 1440px) - 2 * var(--rand)) * 0.64 / 4.72), 18svh); }
  .lehrstelle-beruf { font-size: 19px; margin-top: 10px; }

  .titel-bild {
    grid-column: 9 / 13;
    grid-row: 1 / 3;
    margin-top: 18px;
    max-width: min(100%, 52svh);
    justify-self: center;
    --r: 2deg;
    --band-r: -4deg;
  }

  /* Die Notiz füllt die Lücke neben dem Namen und zeigt auf die Zeichnung */
  .notiz-titel {
    grid-column: 6 / 9;
    grid-row: 1;
    align-self: center;
    justify-self: end;
    margin: 40px 0 0;
    flex-direction: column;
    align-items: flex-end;
  }
  .notiz-titel .pfeil { order: 0; transform: rotate(-12deg); }

  .titel-text {
    grid-column: 1 / 9;
    grid-row: 3;
    margin-top: 28px;
    font-size: 19px;
  }

  .kapitel-kopf {
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr));
    column-gap: 24px;
    align-items: end;
    margin-bottom: 56px;
  }
  .kapitel-kopf .kapitel-h { grid-column: 1 / 13; }
  .kapitel-kopf p { grid-column: 7 / 12; font-size: 19px; }

  .panels {
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr));
    gap: 32px 28px;
    align-items: start;
  }
  .panels > .panel { width: auto; }

  /* Collage in Dreiergruppen: das Muster wiederholt sich für jedes weitere Bild.
     Nur die Spalte ist fest, die Zeile ergibt sich aus der Reihenfolge. */
  .panels-hinschauen > .panel:nth-of-type(3n+1) { grid-column: 1 / 6; --r: -1.8deg; }
  .panels-hinschauen > .panel:nth-of-type(1) { grid-row: 1 / 3; }
  .panels-hinschauen > .panel:nth-of-type(3n+2) { grid-column: 6 / 10; margin-top: 90px; --r: 2deg; }
  .panels-hinschauen > .panel:nth-of-type(3n) { grid-column: 10 / 13; margin-top: 240px; --r: -2.2deg; }
  .notiz-flucht { grid-column: 6 / 11; grid-row: 2; justify-self: center; align-self: start; margin-top: 10px; }

  .panels-heft > .panel:nth-of-type(3n+1) { grid-column: 1 / 8; --r: -1.5deg; }
  .panels-heft > .panel:nth-of-type(3n+2) { grid-column: 8 / 13; margin-top: 140px; --r: 2deg; }
  .panels-heft > .panel:nth-of-type(3n) { grid-column: 4 / 10; margin-top: 8px; --r: 1.2deg; }
  .notiz-namen { grid-column: 1 / 4; grid-row: 2; align-self: center; margin-left: 0; flex-direction: column; align-items: flex-end; }
  .notiz-namen .pfeil { transform: scaleX(-1); }

  .seiten > * { max-width: 1360px; margin-left: auto; margin-right: auto; }
  .seiten-h { text-align: center; margin-bottom: 64px; }

  .seiten-paar {
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr));
    gap: 24px;
    align-items: start;
  }
  .seite { width: auto; max-width: none; }
  .seiten-paar > .seite:nth-of-type(odd) { grid-column: 2 / 6; --r: -2deg; }
  .notiz-buch { grid-column: 6 / 8; grid-row: 1; justify-content: center; text-align: center; margin-top: 180px; }
  .seiten-paar > .seite:nth-of-type(even) { grid-column: 8 / 12; margin-top: 70px; --r: 2.2deg; }

  .seite-quer { max-width: 900px; --r: -1.2deg; }
  .quer-liste { gap: 72px; }
  .notiz-wasser { max-width: 900px; }

  .streifen {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 28px;
  }
  .streifen .panel:nth-child(odd) { --r: -2deg; }
  .streifen .panel:nth-child(even) { --r: 1.6deg; margin-top: 48px; }

  .ueber {
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr));
    column-gap: 24px;
    padding-top: 72px;
    padding-bottom: 88px;
  }
  .ueber .kapitel-h { grid-column: 1 / 13; margin-bottom: 40px; }
  .ueber-bild { grid-column: 1 / 6; margin: 0; width: auto; max-width: none; rotate: -2deg; }
  .ueber-text { grid-column: 7 / 12; font-size: 20px; align-self: center; }

  .kontakt { padding: 80px var(--rand) 104px; }
  .kontakt > * { max-width: 1360px; }
  .kontakt-h,
  .kontakt-mail { margin-left: max(0px, (100% - 1360px) / 2); }

  .leuchte-bild { padding: 20px 40px 12px; }
}

@media (prefers-reduced-motion: reduce) {
  .panel { transition: none; }
}
