/* neukirchner.io – im Erscheinungsbild der MN Group (mngroup.io).
   Farben, Schriften und Bausteine sind von dort übernommen; Schriften liegen selbst gehostet
   (Subset: Latin-Basis plus alle auf der Seite verwendeten Zeichen, wght 400–800). */

@font-face {
  font-family: "Syne";
  src: url("/assets/fonts/syne.woff2") format("woff2");
  font-weight: 400 800;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Inter";
  src: url("/assets/fonts/inter.woff2") format("woff2");
  font-weight: 400 800;
  font-style: normal;
  font-display: swap;
}

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

:root {
  --bg:          #0f0e0d;
  --bg-warm:     #171410;
  --bg-card:     #1e1a16;
  --bg-card2:    #262220;
  --bg-rich:     #2a2420;
  --border:      rgba(255, 255, 255, .08);
  --border-md:   rgba(255, 255, 255, .13);
  --border-warm: rgba(217, 73, 41, .15);
  --accent:      #d94929;
  --accent-hi:   #f05a35;
  --accent-lo:   rgba(217, 73, 41, .12);
  --accent-bd:   rgba(217, 73, 41, .3);
  --text:        #f0ece8;
  --muted:       #b0a89e;
  --dim:         #6b6158;
  /* wie --dim, aber mit 4.5:1 auf --bg für kleine Schrift */
  --dim-text:    #8f867c;
  /* wie --accent, aber mit mind. 4.5:1 für kleine Schrift auf --bg (inkl. Körnung), --bg-card und --accent-lo */
  --accent-text: var(--accent-hi);
  --radius:      16px;
  --ease:        cubic-bezier(.16, 1, .3, 1);
  --gutter:      24px;
  color-scheme: dark;
}

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

body {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
  background: var(--bg);
  color: var(--text);
  font-family: "Inter", system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

/* Körnung über der ganzen Seite */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image: url("/assets/noise.svg");
  opacity: .028;
  pointer-events: none;
  z-index: 0;
}

a { color: inherit; }
img, svg { display: block; }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ── HINTERGRUND ── */
/* Nur Start- und Fehlerseite; die Rechtsseiten sind wie auf mngroup.io schlicht. */
.backdrop {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: 0;
  background:
    radial-gradient(ellipse 110% 70% at 78% 0%, rgba(217, 73, 41, .1) 0%, transparent 58%),
    radial-gradient(ellipse 80% 60% at 0% 100%, rgba(107, 97, 88, .12) 0%, transparent 55%);
}
.backdrop-grid {
  position: absolute;
  inset: 0 0 auto 0;
  height: 720px;
  background-image: radial-gradient(circle, rgba(240, 210, 190, .055) 1px, transparent 1px);
  background-size: 40px 40px;
  -webkit-mask-image: radial-gradient(ellipse 80% 70% at 50% 30%, #000 0%, transparent 75%);
  mask-image: radial-gradient(ellipse 80% 70% at 50% 30%, #000 0%, transparent 75%);
}
.backdrop-glow {
  position: absolute;
  top: -260px;
  right: -240px;
  width: 640px;
  height: 640px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(217, 73, 41, .14) 0%, rgba(200, 60, 20, .04) 50%, transparent 70%);
}
.backdrop-mark {
  position: absolute;
  top: 120px;
  right: -18%;
  width: 95%;
  max-width: 600px;
  height: auto;
  opacity: .035;
  user-select: none;
}

/* ── RAHMEN ── */
.shell {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 600px;
  margin: 0 auto;
  padding-left: max(var(--gutter), env(safe-area-inset-left));
  padding-right: max(var(--gutter), env(safe-area-inset-right));
  container-type: inline-size;
}
.shell--wide { max-width: 840px; }

.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-top: max(28px, env(safe-area-inset-top));
}
.top-logo { display: inline-flex; text-decoration: none; }
/* Das Logo ist auf Unterseiten der einzige Weg zur Startseite: Tippfläche mind. 48 px, ohne Layoutversatz */
a.top-logo {
  align-items: center;
  min-height: 48px;
  margin: -9px -8px;
  padding: 0 8px;
  border-radius: 8px;
}
.top-logo img, img.top-logo { height: 30px; width: auto; }

main { flex: 1 0 auto; }

/* ── KOPF DER STARTSEITE ── */
.intro { padding-top: 72px; padding-bottom: 48px; }

.name { font-weight: inherit; }
.name-row { display: block; font-family: "Syne", sans-serif; }
.name-first {
  font-size: clamp(1.05rem, 5vw, 1.6rem);
  font-weight: 600;
  color: var(--muted);
  letter-spacing: -.015em;
  line-height: 1.2;
}
.name-last {
  /* Syne 800 ist breit: „Neukirchner“ misst rund 9,3 em. Zusätzlich per cqi an die Spaltenbreite
     gebunden, damit größere Standardschrift nichts abschneidet; die erste Zeile ist der Fallback. */
  font-size: clamp(1.75rem, calc(10.4vw - 5px), 3.4rem);
  font-size: min(clamp(1.75rem, calc(10.4vw - 5px), 3.4rem), 10.6cqi);
  font-weight: 800;
  color: #fff;
  letter-spacing: -.04em;
  line-height: .98;
  margin-top: 6px;
  padding-bottom: .06em;
}

/* ── LINKS ── */
.groups { display: grid; gap: 32px; padding-bottom: 64px; }

.section-tag {
  display: block;
  font-family: "Syne", sans-serif;
  font-size: .7rem;
  font-weight: 700;
  line-height: 1.4;
  color: var(--accent-text);
  text-transform: uppercase;
  letter-spacing: .12em;
  margin-bottom: 14px;
}

.links { list-style: none; }
.links li + li .link { border-top: 0; }

.link {
  display: flex;
  align-items: center;
  gap: 18px;
  min-height: 66px;
  padding: 12px 4px;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  text-decoration: none;
  color: var(--text);
  -webkit-tap-highlight-color: transparent;
  transition: padding-left .35s var(--ease), background-color .2s;
}
.link-num {
  flex: 0 0 max(22px, 1.5em); /* wächst mit der Schrift für alle Zeilen gleich */
  font-family: "Syne", sans-serif;
  font-size: .72rem;
  font-weight: 700;
  color: var(--accent-text);
}
.link-text { display: flex; flex-direction: column; min-width: 0; }
.link-title {
  font-family: "Syne", sans-serif;
  font-size: 1.1rem;
  font-weight: 700;
  line-height: 1.3;
  color: #fff;
  letter-spacing: -.01em;
}
.link-sub {
  font-size: .85rem;
  color: var(--muted);
  line-height: 1.5;
  overflow-wrap: anywhere;
}
/* schmale Viewports (Galaxy Fold zugeklappt, Seitenzoom auf kleinen Phones): Handles einzeilig */
@media (max-width: 319px) {
  .link { gap: 12px; }
  .link-sub { font-size: .76rem; }
}
.link-arrow {
  flex: 0 0 auto;
  margin-left: auto;
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--bg-card2);
  border: 1px solid var(--border);
  transition: background-color .2s, border-color .2s, transform .35s var(--ease);
}
.link-arrow svg {
  width: 12px;
  height: 12px;
  stroke: var(--muted);
  transition: stroke .2s;
}

/* Hover nur bei Geräten mit Maus: auf Touch-Geräten bliebe der Zustand nach dem Antippen hängen. */
@media (hover: hover) {
  .link:hover { padding-left: 12px; }
  .link:hover .link-arrow {
    background: var(--accent-lo);
    border-color: var(--accent-bd);
    transform: translate(2px, -2px);
  }
  .link:hover .link-arrow svg { stroke: var(--accent); }
}
.link:focus-visible { padding-left: 12px; }
.link:focus-visible .link-arrow {
  background: var(--accent-lo);
  border-color: var(--accent-bd);
  transform: translate(2px, -2px);
}
.link:focus-visible .link-arrow svg { stroke: var(--accent); }
.link:active { background-color: var(--accent-lo); }
/* iOS setzt :active ohne Touch-Listener nicht; dort übernimmt die native Tipp-Markierung in der Akzentfläche.
   Nur WebKit auf iOS kennt -webkit-touch-callout, Android behält :active ohne Doppeltönung. */
@supports (-webkit-touch-callout: none) {
  .link { -webkit-tap-highlight-color: var(--accent-lo); }
}
.link:focus-visible { outline-offset: -2px; }

/* ── RECHTSSEITEN ── */
/* Lange Wörter brechen bei Seitenzoom oder großer Schrift um, statt abgeschnitten zu werden */
.page { padding-top: 64px; padding-bottom: 88px; overflow-wrap: anywhere; }
.page-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 28px;
  background: var(--accent-lo);
  border: 1px solid var(--accent-bd);
  border-radius: 100px;
  padding: 6px 16px;
  font-family: "Syne", sans-serif;
  font-size: .72rem;
  font-weight: 700;
  line-height: 1.4;
  color: var(--accent-text);
  letter-spacing: .1em;
  text-transform: uppercase;
}
.page-title {
  font-family: "Syne", sans-serif;
  /* breitestes Wort „Datenschutz-“ misst rund 10,5 em; cqi-Grenze wie beim Namen */
  font-size: clamp(1.6rem, calc(9vw - 4px), 4rem);
  font-size: min(clamp(1.6rem, calc(9vw - 4px), 4rem), 9.4cqi);
  font-weight: 800;
  color: var(--text);
  letter-spacing: -.04em;
  line-height: 1.05;
  margin-bottom: 16px;
  hyphens: manual;
}
.page-intro {
  color: var(--muted);
  font-size: 1rem;
  max-width: 580px;
  margin-bottom: 44px;
  padding-bottom: 32px;
  border-bottom: 1px solid var(--border);
}
/* Keine einzelnen Wörter in der letzten Zeile; Browser ohne Unterstützung ignorieren die Angabe */
.page p,
.page li { text-wrap: pretty; }
/* hält Wörter mit Bindestrich zusammen (z. B. „E-Mail“ in Überschriften mit text-wrap: balance) */
.nowrap { white-space: nowrap; }

.cards { display: flex; flex-direction: column; gap: 16px; }

.card {
  background: var(--bg-card);
  border: 1px solid var(--border-warm);
  border-radius: var(--radius);
  overflow: hidden;
}
.card-head {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 20px 22px;
  font-family: "Syne", sans-serif;
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.35;
  color: var(--text);
  letter-spacing: -.01em;
  text-wrap: balance;
}
.card-num {
  flex: 0 0 auto;
  font-size: .68rem;
  font-weight: 700;
  color: var(--accent-text);
  letter-spacing: .12em;
  background: var(--accent-lo);
  border: 1px solid var(--accent-bd);
  padding: 3px 10px;
  border-radius: 100px;
}
.card-body {
  padding: 0 22px 24px;
  border-top: 1px solid var(--border);
}

.impr-section { margin-top: 24px; }
.impr-section .impr-label {
  font-family: "Syne", sans-serif;
  font-size: .66rem;
  font-weight: 700;
  line-height: 1.5;
  color: var(--accent-text);
  letter-spacing: .12em;
  text-transform: uppercase;
  margin-bottom: 7px;
}
.impr-section p {
  color: var(--muted);
  font-size: .92rem;
  line-height: 1.7;
}
.impr-section strong { color: var(--text); font-weight: 500; }
.impr-section a {
  color: var(--accent-text);
  text-decoration: none;
  overflow-wrap: anywhere;
  transition: color .2s;
}
@media (hover: hover) { .impr-section a:hover { color: var(--text); text-decoration: underline; text-underline-offset: 3px; } }
.impr-divider { height: 1px; background: var(--border); margin: 24px 0 0; }

/* ── DATENSCHUTZ (Aufbau wie auf mngroup.io) ── */
.page-intro a { color: var(--accent-text); text-decoration: none; }
@media (hover: hover) { .page-intro a:hover { text-decoration: underline; text-underline-offset: 3px; } }
.page-intro--lead { margin-bottom: 0; }
.ds-updated {
  display: inline-block;
  margin-top: 12px;
  padding: 6px 14px;
  font-size: .8rem;
  color: var(--dim-text);
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
}
.ds-divider { height: 1px; background: var(--border); margin: 44px 0; }

.ds-section { margin-bottom: 44px; }
.ds-section:last-child { margin-bottom: 0; }
.ds-section h2 {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
  font-family: "Syne", sans-serif;
  font-size: 1.2rem;
  font-weight: 700;
  line-height: 1.3;
  color: var(--text);
  letter-spacing: -.02em;
  text-wrap: balance;
}
.ds-section h2::before {
  content: "";
  flex-shrink: 0;
  width: 20px;
  height: 2px;
  border-radius: 2px;
  background: var(--accent);
}
.ds-section p,
.ds-section li { color: var(--muted); font-size: .93rem; line-height: 1.8; }
.ds-section p + p,
.ds-section ul + p { margin-top: 12px; }
.ds-section strong { color: var(--text); font-weight: 500; }
.ds-section a { color: var(--accent-text); text-decoration: none; overflow-wrap: anywhere; transition: color .2s; }
@media (hover: hover) { .ds-section a:hover { color: var(--text); text-decoration: underline; text-underline-offset: 3px; } }
.ds-section ul {
  list-style: none;
  margin-top: 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.ds-section ul li { position: relative; padding-left: 20px; }
.ds-section ul li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 11px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  opacity: .6;
}
.ds-card {
  margin-top: 18px;
  padding: 20px 22px;
  background: var(--bg-card);
  border: 1px solid var(--border-warm);
  border-radius: var(--radius);
}
.ds-card h3 {
  margin-bottom: 4px;
  font-size: .9rem;
  font-weight: 500;
  line-height: 1.7;
  color: var(--text);
}
.ds-card p { font-size: .9rem; line-height: 1.7; }
.ds-card + p { margin-top: 18px; }

/* ── BUTTON (404) ── */
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 48px;
  /* Grundton = Hover-Ton von mngroup.io, damit Weiß auf 14 px fett 4.5:1 erreicht */
  background: #c23e22;
  color: #fff;
  text-decoration: none;
  font-family: "Syne", sans-serif;
  font-weight: 700;
  font-size: .875rem;
  padding: 14px 28px;
  border-radius: 9px;
  letter-spacing: .01em;
  transition: background .2s, box-shadow .3s;
}
@media (hover: hover) { .btn-primary:hover { background: #ad371e; box-shadow: 0 8px 32px rgba(217, 73, 41, .35); } }

/* ── FUSS ── */
.foot {
  position: relative;
  z-index: 1;
  border-top: 1px solid var(--border-warm);
  background: var(--bg-card);
}
.foot-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 24px;
  padding-top: 32px;
  padding-bottom: max(32px, env(safe-area-inset-bottom));
}
.foot-copy { font-size: .75rem; color: var(--dim-text); }
/* Schriftgröße auch an der Liste, damit die Zeilenhöhe der li die Zeile nicht anhebt */
.foot-legal { display: flex; gap: 24px; list-style: none; font-size: .75rem; }
.foot-legal a {
  position: relative;
  display: inline-block;
  font-size: .75rem;
  color: var(--dim-text);
  text-decoration: none;
  transition: color .2s;
}
/* Tippfläche 48 px über ::after statt Padding: Text sitzt mittig, der Fokusrahmen liegt am Wort */
.foot-legal a::after { content: ""; position: absolute; inset: -14px 0; }
@media (hover: hover) { .foot-legal a:hover { color: var(--muted); } }
.foot-legal a[aria-current="page"] { color: var(--accent-text); }

/* ── BEWEGUNG (nur wenn erwünscht) ── */
@media (prefers-reduced-motion: no-preference) {
  .backdrop-glow { animation: drift 12s ease-in-out infinite alternate; }
  /* Nur Bewegung, keine Ausblendung: Inhalte bleiben sichtbar, auch wenn eine Animation nicht läuft. */
  .name-row, .groups, .page-eyebrow, .page-title, .page-intro, .ds-updated, .ds-divider, .cards, .ds-body {
    animation: riseIn .7s var(--ease) backwards;
  }
  .page-eyebrow { animation-delay: .05s; }
  .name-first, .page-title { animation-delay: .1s; }
  .name-last, .page-intro, .ds-updated, .ds-divider { animation-delay: .2s; }
  .cards, .ds-body, .groups { animation-delay: .3s; }
}
@media (prefers-reduced-motion: reduce) {
  /* Zustandswechsel ja, Gleiten nein (gilt für Fokus und Hover) */
  .link { transition: background-color .2s; }
  .link-arrow { transition: background-color .2s, border-color .2s; }
}
@keyframes drift { from { transform: translate(0, 0) scale(1); } to { transform: translate(-40px, 40px) scale(1.08); } }
@keyframes riseIn { from { transform: translateY(14px); } to { transform: none; } }

/* ── GRÖSSERE BILDSCHIRME ── */
@media (min-width: 720px) {
  :root { --gutter: 40px; }
  .top { padding-top: 40px; }
  .top-logo img, img.top-logo { height: 34px; }
  .intro { padding-top: 120px; padding-bottom: 64px; }
  .backdrop-mark { top: 80px; right: -4%; width: 60%; opacity: .05; }
  .backdrop-glow { top: -10%; right: -8%; width: 800px; height: 800px; }
  .page { padding-top: 96px; padding-bottom: 120px; }
  .card-head { padding: 26px 30px; font-size: 1.05rem; gap: 16px; }
  .card-body { padding: 0 30px 32px; }
  .ds-divider { margin: 52px 0; }
  .ds-section { margin-bottom: 52px; }
  .ds-card { padding: 22px 26px; }
  .link-title { font-size: 1.15rem; }
}

/* Handys im Querformat: breit, aber niedrig – Desktop-Abstände würden die Links unter die Falz schieben */
@media (min-width: 720px) and (max-height: 500px) {
  .top { padding-top: max(20px, env(safe-area-inset-top)); }
  .intro { padding-top: 32px; padding-bottom: 32px; }
  .page { padding-top: 48px; }
}
