/* JPM Katalog V2 – öffentliche Seiten (Katalog, Produkt, Impressum, Datenschutz, Hinweisseiten).
   Grundlage: design/katalog-v2-2026-10-23/oeffentlich.css ohne Mockup-Hilfen; Inline-Stile der Frames als Klassen (CSP style-src 'self').
   Nur Variablen aus /assets/css/tokens.css (wird davor geladen) — keine festen Farben im Bauteil. color-mix() nur mit
   rgba-Rückfallzeile davor (D14) und nie in einer Variablen (dort greift keine Rückfallzeile).
   Handy = Grundwerte (Frames *_Handy, 360 px); ab 900 px die Werte der Frames *_Rechner (1280 px).
   Farben: wählbare Töne als var(--dk-x, var(--x)) (Darstellung, Spec 2026-11-05 §5); feste Zustandsfarben --rot/--rot-tint.
   Präsentation/Kiosk (.ks-*, .kk-*) ergänzt Task 8. */

/* Schriften self-hosted wie basis.css (CLAUDE.md §5) */
@font-face {
    font-family: 'Instrument Sans';
    src: url('/assets/fonts/instrument-sans.ttf') format('truetype');
    font-weight: 400 700;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: 'Bricolage Grotesque';
    src: url('/assets/fonts/bricolage-grotesque.ttf') format('truetype');
    font-weight: 200 800;
    font-style: normal;
    font-display: swap;
}

html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body.k2 { margin: 0; }
.k2 {
  --schrift-display: "Bricolage Grotesque", system-ui, sans-serif;
  --schrift-text: "Instrument Sans", system-ui, sans-serif;
  background: var(--dk-bg, var(--bg)); color: var(--dk-tinte, var(--tinte));
  font-family: var(--schrift-text); font-size: 16px; line-height: 24px;
  -webkit-font-smoothing: antialiased;
}
.k2 *, .k2 *::before, .k2 *::after { box-sizing: border-box; }
.k2 p, .k2 h1, .k2 h2, .k2 h3, .k2 ul, .k2 dl, .k2 dd, .k2 figure { margin: 0; }
.k2 ul { padding: 0; list-style: none; }
.k2 a { color: var(--dk-akzent-dunkel, var(--akzent-dunkel)); }
.k2 a:hover { color: var(--dk-akzent-text, var(--akzent-text)); }
.k2 :focus-visible { outline: 3px solid var(--dk-akzent, var(--akzent)); outline-offset: 2px; }
.k2 [hidden] { display: none !important; }
.k2 img { display: block; max-width: 100%; }

/* ---------- Seite, Kopf ---------- */
.pk-seite { display: flex; flex-direction: column; min-height: 100vh; min-height: 100dvh; }
.pk-wrap { width: 100%; max-width: 1120px; margin: 0 auto; padding: 0 16px; }
.pk-kopf { padding-top: 24px; padding-bottom: 8px; display: flex; flex-direction: column; gap: 10px; }
.pk-kopf .pk-anzahl { margin-top: 8px; }
.pk-marke { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--dk-tinte, var(--tinte)); }
.k2 .pk-marke { color: var(--dk-tinte, var(--tinte)); } /* Task 10 R1: wie die Mockup-CSS; sonst färbt .k2 a die Marke in Akzent (Handy-Frame zeigt Tinte) */
.pk-firma { font-family: var(--schrift-display); font-weight: 700; font-size: 24px; line-height: 30px; letter-spacing: -0.015em; overflow-wrap: anywhere; }
.pk-marke .pk-firma { font-size: 20px; line-height: 26px; }
.pk-anzahl { font-size: 14px; color: var(--dk-tinte-2, var(--tinte-2)); }

/* Logo (E1, Spec §7; CR-37 Bastian 25.10. größer): ganz und unverzerrt, Handy höchstens 72 px hoch, höchstens 70 % der Breite */
.pk-logo-bild { display: block; max-height: 72px; max-width: 70%; width: auto; height: auto; object-fit: contain; }
.pk-logo-klein { max-height: 56px; max-width: 100%; }

/* Kopfleiste der Unterseiten (Produkt, Impressum, Datenschutz): Marke zuerst (links), dann „Zum Katalog“ (CR-37) */
.pk-leiste { padding-top: 12px; display: flex; flex-direction: column; align-items: flex-start; gap: 4px; }
.pk-leiste .pk-marke { padding-top: 12px; }
.pk-leiste .pk-marke .pk-firma { font-size: 18px; line-height: 24px; }
.pk-leiste-produkt .pk-marke { display: none; }
.pk-zurueck { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; font-weight: 600; font-size: 15px; text-decoration: none; }

/* ---------- Raster, Karten (P2) ---------- */
.pk-raster { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px 12px; }
/* CR-73 (Bastian 02.11.: „unten im Katalog bis zum Footer mehr Abstand“): .k2 ul { padding: 0 } wog schwerer als .pk-raster — der Abstand unten war 0. */
.k2 .pk-raster { padding: 16px 0 48px; }
.pk-karte { display: flex; flex-direction: column; gap: 6px; text-decoration: none; color: var(--dk-tinte, var(--tinte)); border-radius: var(--r-klein); }
.k2 .pk-karte { color: var(--dk-tinte, var(--tinte)); }
.pk-karte:hover .pk-name, .pk-karte:focus-visible .pk-name { text-decoration: underline; text-underline-offset: 3px; }
.pk-bild { position: relative; aspect-ratio: 1 / 1; border-radius: var(--r-karte); background: var(--dk-platzhalter, var(--platzhalter)); overflow: hidden; display: block; }
.pk-bild img { width: 100%; height: 100%; object-fit: cover; }
.pk-name { font-weight: 600; font-size: 16px; line-height: 21px; margin-top: 4px; overflow-wrap: anywhere; }
.pk-preisblock { display: flex; flex-direction: column; }
.pk-preis { font-family: var(--schrift-display); font-weight: 700; font-size: 18px; line-height: 24px; }
.pk-preisangabe { font-size: 12.5px; line-height: 17px; color: var(--dk-tinte-2, var(--tinte-2)); }
.pk-kurz { font-size: 14px; line-height: 20px; color: var(--dk-tinte-2, var(--tinte-2)); display: -webkit-box; -webkit-line-clamp: 2; line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* ---------- Kategorien-Knöpfe (Kategorien im Katalog, Spec 2026-10-28 §2) ----------
   Reine Links, kein Skript. Handy: eine Reihe, seitlich wischbar bis an den Bildschirmrand (wie die Chips der Produktliste, basis.css .chips);
   der erste Knopf fluchtet mit dem Kopf (16 px Innenabstand). Ab 900 px brechen die Knöpfe um. 44 px hoch (Touchscreen am Stand).
   6 px Innenabstand oben/unten: der Fokusrahmen (3 px + 2 px Abstand) wird im Scrollbereich nicht abgeschnitten.
   .k2-Präfix: .k2 ul und .k2 a (oben) wiegen schwerer als eine einzelne Klasse; .k2 .pk-kategorien, weil die nav auch .pk-wrap trägt
   und „.pk-wrap { padding: 0 32px }“ im Rechner-Block (später in der Datei, gleiche Spezifität) den Abstand oben sonst auf 0 setzte. */
.k2 .pk-kategorien { padding-top: 4px; padding-bottom: 18px; } /* CR-46: Abstand zum Raster — dessen padding-top hebt .k2 ul { padding: 0 } auf */
.k2 .pk-kat-reihe { display: flex; gap: 8px; overflow-x: auto; margin: 0 -16px; padding: 6px 16px; scrollbar-width: none; overscroll-behavior-x: contain; }
.k2 .pk-kat-reihe::-webkit-scrollbar { display: none; }
.pk-kat-reihe li { flex: none; }
.k2 .pk-kat { display: inline-flex; align-items: center; min-height: 44px; padding: 0 18px; border-radius: var(--r-chip); border: 1px solid var(--dk-rand, var(--rand)); background: var(--dk-karte, var(--karte)); color: var(--dk-tinte-2, var(--tinte-2)); font-size: 15px; font-weight: 600; line-height: 20px; white-space: nowrap; text-decoration: none; }
.k2 .pk-kat:hover { color: var(--dk-tinte, var(--tinte)); border-color: var(--dk-tinte-2, var(--tinte-2)); }
.k2 .pk-kat[aria-current="page"] { background: var(--dk-akzent-tint, var(--akzent-tint)); border-color: var(--dk-akzent-tint, var(--akzent-tint)); color: var(--dk-akzent-dunkel, var(--akzent-dunkel)); }

/* ---------- Fuß (P4) ---------- */
.pk-fuss { margin-top: auto; border-top: 1px solid var(--dk-rand, var(--rand)); background: var(--dk-karte, var(--karte)); }
.pk-fuss-in { padding: 20px 16px 24px; display: flex; flex-direction: column; gap: 14px; }
.pk-fuss-gruppe { display: flex; flex-direction: column; gap: 14px; }
.pk-fuss-links { display: flex; gap: 6px 20px; flex-wrap: wrap; }
.pk-fuss-links a { min-height: 44px; display: inline-flex; align-items: center; font-weight: 600; font-size: 15px; }
.pk-fuss-firma { font-size: 13.5px; line-height: 20px; color: var(--dk-tinte-2, var(--tinte-2)); }
.pk-powered { font-size: 13px; line-height: 20px; color: var(--dk-tinte-2, var(--tinte-2)); }
.k2 .pk-powered a { color: var(--dk-tinte-2, var(--tinte-2)); text-decoration: underline; text-underline-offset: 2px; min-height: 44px; display: inline-flex; align-items: center; }

/* ---------- Hinweisseite (P8) ---------- */
.pk-hinweisseite { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; gap: 14px; padding: 48px 24px; }
.pk-hinweis-zeichen { width: 72px; height: 72px; border-radius: 50%; background: var(--rot-tint); color: var(--rot); display: grid; place-items: center; }
.pk-hinweis-titel { font-family: var(--schrift-display); font-weight: 700; font-size: 24px; line-height: 30px; letter-spacing: -0.015em; }
.pk-hinweis-text { font-size: 16px; line-height: 25px; color: var(--dk-tinte-2, var(--tinte-2)); max-width: 34ch; }
.pk-knopf { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 22px; border-radius: var(--r-button); background: var(--dk-akzent, var(--akzent)); color: var(--dk-auf-akzent, var(--auf-akzent)); font-weight: 600; font-size: 16px; text-decoration: none; border: 0; }
.k2 .pk-knopf { color: var(--dk-auf-akzent, var(--auf-akzent)); }
.pk-knopf-zweit { background: var(--dk-karte, var(--karte)); border: 1px solid var(--dk-rand, var(--rand)); }
.k2 .pk-knopf-zweit { color: var(--dk-akzent-dunkel, var(--akzent-dunkel)); }
.pk-knopf-breit { align-self: stretch; }

/* ---------- Produktseite (P3, P5–P7) ---------- */
.pp-haupt { display: flex; flex-direction: column; gap: 18px; padding-bottom: 36px; }
.pp-angaben { display: flex; flex-direction: column; gap: 18px; }
.pp-kopf { display: flex; flex-direction: column; gap: 8px; }
.pp-preisblock { align-self: flex-start; }
.pp-preisblock .pk-preisangabe { font-size: 14px; }

/* Galerie: ohne JS alle Fotos untereinander; mit JS (.pp-galerie-an) Wischen per scroll-snap */
.pp-galerie { display: flex; flex-direction: column; gap: 10px; }
.pp-buehne { position: relative; }
.pp-spur { display: flex; flex-direction: column; gap: 10px; }
.pp-hauptbild { position: relative; aspect-ratio: 1 / 1; border-radius: var(--r-karte); background: var(--dk-platzhalter, var(--platzhalter)); overflow: hidden; }
.pp-hauptbild img { width: 100%; height: 100%; object-fit: cover; }
.pp-galerie-an .pp-spur { flex-direction: row; gap: 0; overflow-x: auto; scroll-snap-type: x mandatory; overscroll-behavior-x: contain; scrollbar-width: none; border-radius: var(--r-karte); }
.pp-galerie-an .pp-spur::-webkit-scrollbar { display: none; }
.pp-galerie-an .pp-hauptbild { flex: 0 0 100%; scroll-snap-align: start; border-radius: 0; }
.pp-zaehler { position: absolute; right: 10px; top: 10px; font-size: 13px; font-weight: 600; padding: 2px 10px; border-radius: 999px; background: var(--dk-karte, var(--karte)); color: var(--dk-tinte, var(--tinte)); }
.pp-punkte { display: flex; justify-content: center; gap: 8px; }
.pp-punkt { appearance: none; border: 0; background: transparent; padding: 18px 2px; cursor: pointer; }
.pp-punkt i { display: block; width: 8px; height: 8px; border-radius: 50%; background: var(--dk-rand, var(--rand)); }
.pp-punkt[aria-current="true"] i { background: var(--dk-tinte, var(--tinte)); width: 22px; border-radius: 999px; }
.pp-pfeil { position: absolute; top: 50%; transform: translateY(-50%); width: 48px; height: 48px; border-radius: 50%; border: 1px solid var(--dk-rand, var(--rand)); background: var(--dk-karte, var(--karte)); color: var(--dk-tinte, var(--tinte)); display: none; place-items: center; cursor: pointer; padding: 0; }
.pp-pfeil.links { left: 12px; }
.pp-pfeil.rechts { right: 12px; }
.pp-daumen { display: none; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 10px; }
.pp-daumen-knopf { appearance: none; aspect-ratio: 1 / 1; border-radius: var(--r-klein); background: var(--dk-platzhalter, var(--platzhalter)); border: 2px solid transparent; display: block; cursor: pointer; padding: 0; overflow: hidden; }
.pp-daumen-knopf[aria-current="true"] { border-color: var(--dk-tinte, var(--tinte)); }
.pp-daumen-knopf img { width: 100%; height: 100%; object-fit: cover; }
.pp-haupt-schlicht .pp-galerie-eins .pp-hauptbild { aspect-ratio: 4 / 5; }

.pp-titel { font-family: var(--schrift-display); font-weight: 700; font-size: 28px; line-height: 34px; letter-spacing: -0.02em; overflow-wrap: anywhere; }
.pp-haupt-schlicht .pp-titel { font-size: 32px; line-height: 38px; }
.pp-preis { font-family: var(--schrift-display); font-weight: 700; font-size: 24px; line-height: 30px; }
.pp-kurz { font-size: 17px; line-height: 26px; }
.pp-abschnitt { display: flex; flex-direction: column; gap: 10px; padding-top: 22px; border-top: 1px solid var(--dk-rand, var(--rand)); }
.pp-h2 { font-family: var(--schrift-display); font-weight: 600; font-size: 20px; line-height: 26px; letter-spacing: -0.01em; }
.pp-h3 { font-weight: 600; font-size: 16px; line-height: 22px; margin-top: 8px; }
.pp-fliess { font-size: 16px; line-height: 26px; max-width: 65ch; overflow-wrap: anywhere; }
.pp-fliess ul, .pp-fliess ol { padding-left: 22px; margin: 4px 0; }
.pp-fliess ul { list-style: disc; }
.pp-fliess ol { list-style: decimal; }
.pp-fliess li { margin: 2px 0; }
.pp-fliess h3 { font-weight: 600; font-size: 16px; line-height: 22px; margin-top: 8px; }
.pp-daten { display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: 8px 16px; font-size: 15.5px; line-height: 23px; }
.pp-daten dt { color: var(--dk-tinte-2, var(--tinte-2)); }
.pp-hersteller { padding: 14px 16px; border-radius: var(--r-klein); background: var(--dk-karte, var(--karte)); border: 1px solid var(--dk-rand, var(--rand)); font-size: 14.5px; line-height: 22px; display: flex; flex-direction: column; gap: 2px; overflow-wrap: anywhere; }
.pp-hersteller b { font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: var(--dk-tinte-2, var(--tinte-2)); }

/* CR-72 (Bastian 02.11., Variante B): „Gut zu wissen“ — gleich große Links, Klick öffnet ein Fenster (Popover-API, ohne Skript).
   Handy: Fenster von unten; ab 900 px klein und mittig (Rechner-Block). Ohne Popover-Unterstützung: Texte offen, Links weg (@supports unten). */
.pp-info-kopf { font-size: 12px; line-height: 16px; letter-spacing: .06em; text-transform: uppercase; color: var(--dk-tinte-2, var(--tinte-2)); font-weight: 600; }
.k2 .pp-info-links { display: flex; flex-direction: column; }
.pp-info-link { font: inherit; font-weight: 600; font-size: 15px; line-height: 22px; color: var(--dk-akzent-dunkel, var(--akzent-dunkel)); background: none; border: 0; padding: 0; min-height: 44px; text-align: left; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.pp-info-link:hover { color: var(--dk-akzent-text, var(--akzent-text)); }
.pp-info-zeile { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.pp-info-titel { font-weight: 600; font-size: 16px; line-height: 22px; }
.pp-info-zu { width: 44px; height: 44px; margin: -12px -12px -12px 0; display: grid; place-items: center; background: none; border: 0; color: var(--dk-tinte-2, var(--tinte-2)); cursor: pointer; flex: none; }
.pp-info .pp-fliess { font-size: 15px; line-height: 23px; }
.pp-info:popover-open { position: fixed; inset: auto 0 0 0; margin: 0; width: 100%; max-height: 85vh; max-height: 85dvh; overflow: auto; box-sizing: border-box;
  background: var(--dk-karte, var(--karte)); color: var(--dk-tinte, var(--tinte)); border: 0; border-radius: 18px 18px 0 0; padding: 10px 16px 28px; display: flex; flex-direction: column; gap: 10px; }
.pp-info::backdrop {
  background: rgba(43, 33, 24, .42);
  background: color-mix(in srgb, var(--dk-tinte, var(--tinte)) 42%, transparent);
}
@supports not selector(:popover-open) {
  .pp-info-links { display: none; }
  .pp-info-zu { display: none; }
  .pp-info { display: flex; flex-direction: column; gap: 8px; }
}

/* ---------- Rechtstexte (P9) ---------- */
.pr-text { max-width: 65ch; display: flex; flex-direction: column; gap: 14px; font-size: 16px; line-height: 26px; padding-top: 8px; padding-bottom: 40px; overflow-wrap: anywhere; }
.pr-text h1 { font-family: var(--schrift-display); font-weight: 700; font-size: 30px; line-height: 36px; letter-spacing: -0.02em; }
.pr-text h2 { font-family: var(--schrift-display); font-weight: 600; font-size: 20px; line-height: 26px; margin-top: 14px; }
.pr-text dl { display: grid; grid-template-columns: 1fr; gap: 6px 16px; }
/* CR-41: Datenschutztext aus dem Editor — Absätze als div (Abstand über gap), Listen wie die Produkttexte (.pp-fliess) */
.pr-text ul, .pr-text ol { padding-left: 22px; }
.pr-text ul { list-style: disc; }
.pr-text ol { list-style: decimal; }
.pr-text strong { font-weight: 700; }
.pr-text dt { color: var(--dk-tinte-2, var(--tinte-2)); }
.pr-text dt:not(:first-child) { margin-top: 8px; }
.pr-stand { color: var(--dk-tinte-2, var(--tinte-2)); font-size: 14px; }

/* ---------- Rechner (Frames *_Rechner) ---------- */
@media (min-width: 900px) {
  .pk-wrap { max-width: 1184px; padding: 0 32px; }
  .pk-kopf { padding-top: 48px; padding-bottom: 8px; }
  .pk-kopf .pk-firma { font-size: 34px; line-height: 40px; }
  .pk-kopf .pk-marke .pk-firma { font-size: 20px; line-height: 26px; }
  .pk-kopf .pk-anzahl { margin-top: 0; }
  .k2 .pk-kat-reihe { flex-wrap: wrap; overflow-x: visible; margin: 0; padding: 6px 0; }
  .pk-logo-bild { max-height: 112px; }
  .pk-logo-klein { max-height: 64px; }

  .pk-raster { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 32px 24px; }
  .k2 .pk-raster { padding-bottom: 72px; }

  .pk-fuss-in { max-width: 1184px; margin: 0 auto; padding: 24px 32px 28px; flex-direction: row; align-items: center; justify-content: space-between; flex-wrap: wrap; }
  .pk-fuss-gruppe { flex-direction: row; align-items: center; gap: 28px; flex-wrap: wrap; }
  .pk-fuss-firma { order: -1; }

  .pk-leiste { padding-top: 24px; padding-bottom: 8px; flex-direction: row; align-items: center; justify-content: space-between; }
  .pk-leiste .pk-marke, .pk-leiste-produkt .pk-marke { display: flex; padding-top: 0; }
  .pk-leiste .pk-marke .pk-firma { font-size: 20px; line-height: 26px; }

  .pp-haupt { display: grid; grid-template-columns: minmax(0, 600px) minmax(320px, 1fr); gap: 56px; align-items: start; padding-top: 16px; padding-bottom: 56px; }
  .pp-galerie { position: sticky; top: 16px; }
  .pp-angaben { gap: 22px; padding-top: 8px; }
  .pp-kopf { gap: 10px; }
  .pp-titel { font-size: 40px; line-height: 46px; }
  .pp-preis { font-size: 28px; line-height: 34px; }
  .pp-kurz { font-size: 19px; line-height: 29px; }
  .pp-daten { grid-template-columns: 120px minmax(0, 1fr); }
  .pp-punkte { display: none; }
  .pp-pfeil { display: grid; }
  .pp-daumen { display: grid; }
  .k2 .pp-info-links { flex-direction: row; flex-wrap: wrap; column-gap: 20px; }
  .pp-info:popover-open { inset: 50% auto auto 50%; transform: translate(-50%, -50%); width: min(440px, calc(100vw - 32px)); max-height: 80vh; border: 1px solid var(--dk-rand, var(--rand)); border-radius: 12px; padding: 16px 18px; gap: 8px; }

  .pp-haupt-schlicht { grid-template-columns: minmax(0, 680px) minmax(320px, 1fr); align-items: center; }
  .pp-haupt-schlicht .pp-galerie { position: static; }
  .pp-haupt-schlicht .pp-galerie-eins .pp-hauptbild { aspect-ratio: 1 / 1; }
  .pp-haupt-schlicht .pp-angaben { gap: 28px; padding-top: 0; }
  .pp-haupt-schlicht .pp-kopf { gap: 12px; }
  .pp-haupt-schlicht .pp-titel { font-size: 44px; line-height: 50px; }
  .pp-haupt-schlicht .pp-preis { font-size: 30px; line-height: 36px; }
  .pk-knopf-breit { display: none; }

  .pr-haupt { padding-top: 24px; padding-bottom: 48px; }
  .pr-text { margin: 0 auto; padding-top: 0; }
  .pr-text dl { grid-template-columns: 170px minmax(0, 1fr); }
  .pr-text dt:not(:first-child) { margin-top: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .pp-galerie-an .pp-spur { scroll-behavior: auto; }
}
