/* ============================================================
   forte.de — Redesign 2026
   Reihenfolge: Fonts › Tokens › Reset › Basis › Layout › Sektionen
   ============================================================ */

/* ---------- Fonts (self-hosted, DSGVO: keine CDN-Requests) ---------- */

@font-face {
  font-family: 'Space Grotesk';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('/fonts/spacegrotesk-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: 'Space Grotesk';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('/fonts/spacegrotesk-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-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: 'Instrument Serif';
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/instrumentserif-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: 'Instrument Serif';
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/instrumentserif-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-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

/* Raleway ist eine Variable Font — 400/500/600 liegen in derselben Datei. */
@font-face {
  font-family: 'Raleway';
  font-style: normal;
  font-weight: 400 600;
  font-display: swap;
  src: url('/fonts/raleway-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: 'Raleway';
  font-style: normal;
  font-weight: 400 600;
  font-display: swap;
  src: url('/fonts/raleway-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-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

/* ---------- Tokens ---------- */

/* DUNKEL ist die Grundfassung (:root) — so sieht die Seite ohne gespeicherte
   Wahl und auch ganz ohne JavaScript aus. Hell hängt an
   html[data-theme="light"]. Alle Kontraste sind gemessen, nicht geschätzt.
   Wer eine Farbe hart in eine Regel schreibt, bricht eine der Fassungen. */
:root {
  color-scheme: dark;

  --bg: #0C0C0E;
  --bg-elevated: #141416;
  --text: #F5F3EF;
  --text-muted: #9B9791;          /* 6.7:1 auf --bg, erfüllt AA */
  --accent: #FF6B1A;              /* 6.9:1 auf --bg */
  --accent-deep: #C2470A;
  --accent-contrast: #14100C;     /* Text auf orangener Fläche */
  --line: rgba(245, 243, 239, 0.12);
  --line-strong: rgba(245, 243, 239, 0.28);

  --glow-rgb: 255, 107, 26;
  --glow-alpha: 0.35;
  --hero-glow-alpha: 0.20;
  --shadow-card: none;
  --success: #7BD88F;             /* 9.9:1 auf --bg */
  --error:   #FF9B9B;             /* 7.6:1 auf --bg */

  --header-bg: rgba(12, 12, 14, 0.72);
  --media-bg: #0A0A0C;
  --placeholder: rgba(155, 151, 145, 0.7);

  --blue: #1C9AC7;                /* 6.05:1 auf --bg — Originalton */

  /* --- ab hier themeunabhängig --- */
  --radius: 1rem;

  --font-display: 'Space Grotesk', 'Helvetica Neue', Arial, sans-serif;
  --font-serif: 'Instrument Serif', Georgia, 'Times New Roman', serif;
  --font-body: 'Raleway', system-ui, -apple-system, 'Segoe UI', sans-serif;

  --shell: 1200px;
  --pad: clamp(1.25rem, 5vw, 4rem);
  --gap-section: clamp(5rem, 12vh, 9rem);

  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}

/* ---------- Helle Fassung ---------- */

html[data-theme="light"] {
  color-scheme: light;

  --bg: #FAF8F5;                  /* warmes Off-White, kein hartes Weiß */
  --bg-elevated: #FFFFFF;
  --text: #14120F;                /* 16.9:1 auf --bg */
  --text-muted: #5F5A54;          /* 6.6:1 auf --bg, erfüllt AA */
  --accent: #C2470A;              /* 4.7:1 auf --bg — als Text nutzbar */
  --accent-deep: #8F3407;
  --accent-contrast: #FFFFFF;     /* weißer Text auf dem dunkleren Orange */
  --line: rgba(20, 18, 15, 0.14);
  --line-strong: rgba(20, 18, 15, 0.34);

  /* Der Glow ist hier zurückgenommen, sonst wirkt er auf hellem Grund
     wie ein Fleck statt wie Licht. */
  --glow-rgb: 255, 122, 40;
  --glow-alpha: 0.16;
  --hero-glow-alpha: 0.13;
  --shadow-card: 0 1px 2px rgba(20, 18, 15, 0.04), 0 8px 24px rgba(20, 18, 15, 0.05);
  --success: #1F7A3D;             /* 5.6:1 auf --bg */
  --error:   #B3261E;             /* 6.0:1 auf --bg */

  /* Bewusst feste Werte statt color-mix(): letzteres kostete im Test
     rund das 17-fache an Style-&-Layout-Zeit. */
  --header-bg: rgba(250, 248, 245, 0.78);
  --media-bg: #ECE7E1;
  --placeholder: rgba(95, 90, 84, 0.72);

  /* Markenblau von djforte.de (#1C9AC7). Bewusst nur als Detailakzent:
     Fokus-Ringe und Links in den Rechtstexten — Orange bleibt der einzige
     Signalakzent. Auf hellem Grund abgedunkelt, sonst nur 3.05:1. */
  --blue: #167B9F;                /* 4.54:1 auf --bg */
}

/* ---------- Reset ---------- */

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 5.5rem;   /* sticky Header */
  -webkit-text-size-adjust: 100%;
  /* Sicherheitsnetz gegen seitliches Wegschieben. `clip` statt `hidden`,
     weil hidden einen Scroll-Container erzeugen und damit den sticky
     Header brechen würde. */
  overflow-x: clip;
}

body {
  margin: 0;
  overflow-wrap: break-word;   /* lange Wörter/URLs sprengen das Layout nicht */
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1.05rem;
  font-weight: 400;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;   /* Fallback für Browser ohne overflow: clip */
  overflow-x: clip;
}

img { max-width: 100%; height: auto; display: block; }
ul, ol { list-style: none; margin: 0; padding: 0; }
p { margin: 0 0 1rem; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
address { font-style: normal; }
h1, h2, h3 { margin: 0; font-weight: 700; }

:focus-visible {
  /* Zurück auf Orange: der blaue Rahmen wirkte wie ein Browser-Default.
     Dünner, mit weichem Halo statt hartem Kasten. */
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 6px;
  box-shadow: 0 0 0 6px rgba(var(--glow-rgb), 0.14);
}

.visually-hidden, .sr-name {
  position: absolute;
  width: 1px; height: 1px;
  margin: -1px; padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  top: -100px; left: 1rem;
  z-index: 200;
  padding: 0.75rem 1.25rem;
  background: var(--accent);
  color: var(--accent-contrast);
  font-weight: 600;
  border-radius: 0 0 var(--radius) var(--radius);
  transition: top 0.2s var(--ease);
}
.skip-link:focus { top: 0; }

/* ---------- Typo-Rollen ---------- */

.eyebrow {
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--blue);          /* war grau */
  margin: 0 0 1.25rem;
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, 3.75rem);
  line-height: 1.05;
  letter-spacing: -0.02em;
  margin: 0 0 2.5rem;
}

/* Das Stilmittel: italic-Serif-Einschub in Orange */
.section-title em,
.hero-title em,
.cta-link em {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  color: var(--accent);
  letter-spacing: 0;
}

.section-lead {
  max-width: 52ch;
  color: var(--text-muted);
  margin: -1.5rem 0 3rem;
}

/* ---------- Layout ---------- */

.shell {
  width: 100%;
  max-width: var(--shell);
  margin-inline: auto;
  padding-inline: var(--pad);
}

.section {
  padding-block: var(--gap-section);
  border-top: 1px solid var(--line);
  position: relative;
}

/* ---------- Reveals ---------- */

.js .reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.5s var(--ease), transform 0.5s var(--ease);
}
.js .reveal.is-visible { opacity: 1; transform: none; }

/* ---------- Glow-Canvas ---------- */

#glow-canvas {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  display: block;
}

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--bg);
  border-bottom: 1px solid transparent;
  transition: background 0.3s var(--ease), border-color 0.3s var(--ease);
}
.site-header.is-scrolled {
  background: var(--header-bg);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom-color: var(--line);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  min-height: 4.5rem;
}

.brand { display: inline-flex; align-items: center; gap: 0.65rem; margin-right: auto; min-height: 2.75rem; }

.brand-mark {
  display: grid;
  place-items: center;
  width: 2.25rem; height: 2.25rem;
  border: 1px solid var(--line-strong);
  border-radius: 0.6rem;
  font-family: var(--font-display);
  font-size: 0.85rem;
  letter-spacing: 0.02em;
}
.brand-name { font-family: var(--font-display); font-size: 0.95rem; letter-spacing: -0.01em; }

.nav-desktop { display: none; gap: 1.75rem; }
.nav-desktop a {
  font-size: 0.9rem;
  color: var(--text-muted);
  padding-block: 0.25rem;
  border-bottom: 1px solid transparent;
  transition: color 0.2s var(--ease), border-color 0.2s var(--ease);
}
.nav-desktop a:hover,
.nav-desktop a.is-current { color: var(--text); border-bottom-color: var(--accent); }

.header-social { display: none; gap: 0.5rem; }
.header-social a {
  display: grid;
  place-items: center;
  width: 2.75rem; height: 2.75rem;   /* 44px Trefferfläche */
  border: 1px solid var(--line);
  border-radius: 50%;
  color: var(--text-muted);
  transition: color 0.2s var(--ease), border-color 0.2s var(--ease);
}
.header-social a:hover { color: var(--accent); border-color: var(--line-strong); }

/* ---------- Theme-Umschalter ---------- */

/* Ohne JavaScript hat der Umschalter keine Funktion — dann gar nicht erst zeigen. */
.theme-toggle { display: none; }
.js .theme-toggle {
  display: grid;
  place-items: center;
  width: 2.75rem; height: 2.75rem;   /* 44px Trefferfläche */
  flex-shrink: 0;
  border: 1px solid var(--line);
  border-radius: 50%;
  color: var(--text-muted);
  transition: color 0.2s var(--ease), border-color 0.2s var(--ease);
}
.js .theme-toggle:hover { color: var(--accent); border-color: var(--line-strong); }
.theme-toggle svg { display: block; }
/* Dunkel ist die Grundfassung -> Sonne zeigen (= "auf hell schalten").
   Im Hellmodus der Mond. */
.theme-toggle .icon-sun { display: block; }
.theme-toggle .icon-moon { display: none; }
html[data-theme="light"] .theme-toggle .icon-sun { display: none; }
html[data-theme="light"] .theme-toggle .icon-moon { display: block; }


.nav-toggle {
  display: grid;
  place-items: center;
  width: 2.75rem; height: 2.75rem;   /* 44px Trefferfläche */
  border: 1px solid var(--line);
  border-radius: 0.6rem;
}
.nav-toggle-bars { display: block; width: 1.1rem; }
.nav-toggle-bars span {
  display: block;
  height: 1.5px;
  background: var(--text);
  transition: transform 0.25s var(--ease), opacity 0.2s var(--ease);
}
.nav-toggle-bars span + span { margin-top: 5px; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars span:first-child { transform: translateY(3.25px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars span:last-child  { transform: translateY(-3.25px) rotate(-45deg); }

/* ---------- Mobile-Overlay ---------- */

.nav-mobile {
  position: fixed;
  inset: 4.5rem 0 0;
  z-index: 99;
  background: var(--bg);
  padding: 2rem var(--pad) 3rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow-y: auto;
}
.nav-mobile[hidden] { display: none; }
.nav-mobile nav { display: flex; flex-direction: column; }
.nav-mobile nav a {
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 7vw, 2.25rem);
  letter-spacing: -0.02em;
  padding-block: 0.85rem;
  border-bottom: 1px solid var(--line);
  display: flex;
  align-items: baseline;
  gap: 1rem;
}
.nav-mobile nav a span {
  font-family: var(--font-body);
  font-size: 0.75rem;
  color: var(--text-muted);
  letter-spacing: 0.14em;
}
.nav-mobile-foot {
  display: flex;
  flex-direction: column;
  padding-top: 2rem;
  color: var(--text-muted);
  font-size: 0.95rem;
}
.nav-mobile-foot a { display: inline-block; padding-block: 0.65rem; align-self: flex-start; }
body.nav-open { overflow: hidden; }

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.85rem 1.6rem;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.95rem;
  border: 1px solid transparent;
  transition: background 0.25s var(--ease), border-color 0.25s var(--ease),
              color 0.25s var(--ease), transform 0.15s var(--ease);
}
.btn-primary {
  background: linear-gradient(135deg, var(--accent), var(--accent-deep));
  color: var(--accent-contrast);
}
.btn-primary:hover { filter: brightness(1.08); }
.btn-ghost { border-color: var(--line-strong); color: var(--text); }
.btn-ghost:hover { border-color: var(--accent); color: var(--accent); }
.btn:active { transform: translateY(1px); }
.btn-block { width: 100%; }

/* ---------- Hero ---------- */

.hero {
  position: relative;
  z-index: 1;
  padding-block: clamp(3rem, 8vh, 6rem) clamp(4rem, 10vh, 7rem);
  /* Der Glow unten ragt bewusst über die rechte Kante hinaus. Ohne clip
     verbreitert er auf dem Handy das Dokument (375px -> 535px) und die
     Seite lässt sich seitlich wegschieben. `clip` statt `hidden`, damit
     kein Scroll-Container entsteht. */
  overflow: clip;
}

/* Touch-Geräte bekommen statt des Mouse-Glows einen weichen Gradient */
.hero::before {
  content: '';
  position: absolute;
  top: -14rem;
  /* Bewusst KEIN negativer right-Wert mehr: der Gradient hat die Seite auf
     dem Handy verbreitert. Er endet jetzt an der rechten Kante — optisch
     kaum ein Unterschied, aber unabhängig davon, ob der Browser
     `overflow: clip` unterstützt (iOS Safari erst ab 16). */
  right: 0;
  width: min(46rem, 100%);
  aspect-ratio: 1;
  background: radial-gradient(circle at 70% 50%, rgba(var(--glow-rgb), var(--hero-glow-alpha)) 0%, rgba(var(--glow-rgb), 0) 68%);
  pointer-events: none;
  z-index: -1;
}
@media (hover: hover) and (pointer: fine) {
  .hero::before { opacity: 0.55; }
}

.hero-inner { display: grid; gap: clamp(2.5rem, 6vw, 4rem); }

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(2.8rem, 8vw, 6.5rem);
  line-height: 1.02;
  letter-spacing: -0.02em;
  margin: 0 0 1.75rem;
}

.hero-lead {
  max-width: 46ch;
  color: var(--text-muted);
  font-size: 1.05rem;
  margin-bottom: 2rem;
}

.hero-actions { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-bottom: 2.25rem; }

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  font-size: 0.9rem;
  color: var(--text-muted);
}
.hero-meta li { display: flex; align-items: center; }
/* Trennpunkte erst ab Tablet: bei schmalem Umbruch landen sie sonst
   allein am Zeilenanfang. */
@media (min-width: 640px) {
  .hero-meta li + li::before {
    content: '';
    width: 3px; height: 3px;
    border-radius: 50%;
    background: var(--line-strong);
    margin-right: 1.5rem;
  }
}
.hero-meta a {
  border-bottom: 1px solid transparent;
  display: inline-block;
  padding-block: 0.65rem;          /* Trefferfläche auf dem Handy */
  transition: color 0.2s var(--ease), border-color 0.2s var(--ease);
}
.hero-meta a:hover { color: var(--accent); border-bottom-color: var(--accent); }

.hero-media {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line);
  max-width: 26rem;
}
.hero-media img { width: 100%; aspect-ratio: 1667 / 2500; object-fit: cover; }

.hero-stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1px;
  margin: clamp(3rem, 8vh, 5rem) 0 0;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}
.stat { background: var(--bg); padding: clamp(1.5rem, 4vw, 2.5rem); }
.stat-num {
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 7vw, 4.5rem);
  line-height: 1;
  letter-spacing: -0.03em;
  color: var(--accent);
}
.stat-label {
  margin: 0.75rem 0 0;
  color: var(--text-muted);
  font-size: 0.9rem;
}

/* ---------- Marquee ---------- */

/* Der Marquee ist der einzige Inhalt, der breiter als der Viewport ist.
   Er darf das Dokument NICHT verbreitern — sonst lässt sich die Seite auf
   dem Handy seitlich wegschieben.

   Zwei Dinge sind hier bewusst so gebaut:
   1. Kein `width: max-content` im Fluss. Der Container ist 100% breit,
      nur die Tracks darin sind lang (flex, nicht schrumpfend). Damit
      entsteht gar keine Überbreite, die geclippt werden müsste.
   2. Keine `mask-image` für die weichen Ränder. In iOS Safari erzeugt eine
      Maske einen eigenen Rendering-Kontext, wodurch das `overflow: hidden`
      des Containers nicht zuverlässig greift — genau das war die Ursache
      des Rechts-Scrollens auf dem iPhone. Die Ränder kommen jetzt über
      zwei Farbverlauf-Overlays (::before/::after). */
.marquee-section {
  border-block: 1px solid var(--line);
  padding-block: clamp(1.5rem, 4vw, 2.25rem);
  overflow: hidden;
  position: relative;
  z-index: 1;
  background: var(--bg);
  contain: paint;
}

/* Weiche Ränder links/rechts statt mask-image */
.marquee-section::before,
.marquee-section::after {
  content: '';
  position: absolute;
  top: 0; bottom: 0;
  width: clamp(2rem, 8vw, 5rem);
  z-index: 2;
  pointer-events: none;
}
.marquee-section::before {
  left: 0;
  background: linear-gradient(90deg, var(--bg), transparent);
}
.marquee-section::after {
  right: 0;
  background: linear-gradient(270deg, var(--bg), transparent);
}

.marquee {
  display: flex;
  width: 100%;
  overflow: hidden;
}
.marquee-track {
  display: flex;
  flex: 0 0 auto;          /* darf nicht schrumpfen, sonst bricht die Schleife */
  align-items: center;
  gap: clamp(2rem, 5vw, 3.5rem);
  padding-right: clamp(2rem, 5vw, 3.5rem);
  animation: marquee-scroll 42s linear infinite;
}
.marquee:hover .marquee-track,
.marquee:focus-within .marquee-track { animation-play-state: paused; }
.marquee-track li {
  font-family: var(--font-display);
  font-size: clamp(1.05rem, 2.4vw, 1.6rem);
  letter-spacing: -0.01em;
  color: var(--text-muted);
  white-space: nowrap;
  transition: color 0.25s var(--ease);
}
.marquee-track li:hover { color: var(--accent); }

@keyframes marquee-scroll {
  from { transform: translateX(0); }
  to   { transform: translateX(-100%); }
}

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

.about-grid { display: grid; gap: clamp(2rem, 5vw, 3.5rem); }
.about-text p { max-width: 60ch; color: var(--text-muted); }
.about-text p:first-child { color: var(--text); font-size: 1.15rem; }

.fact-grid {
  display: grid;
  gap: 1rem;
  /* auto-fit + minmax: bei sehr schmalen Displays (oder großer
     Systemschrift) fällt das Raster automatisch auf eine Spalte,
     statt die Seite zu verbreitern. */
  grid-template-columns: repeat(auto-fit, minmax(9.5rem, 1fr));
}
.fact {
  min-width: 0;              /* darf schrumpfen, sonst erzwingt der Text Überbreite */
  overflow-wrap: anywhere;
  background: var(--bg-elevated);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(1.1rem, 3vw, 1.6rem);
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  box-shadow: var(--shadow-card);
  transition: border-color 0.25s var(--ease);
}
.fact:hover { border-color: var(--line-strong); }
.fact-title { font-family: var(--font-display); font-size: 1.05rem; letter-spacing: -0.01em; }
.fact-sub { color: var(--text-muted); font-size: 0.88rem; }

/* ---------- Akkordeon ---------- */

.accordion { border-top: 1px solid var(--line); }

.acc-item { border-bottom: 1px solid var(--line); }

.acc-item > summary {
  display: flex;
  align-items: center;
  gap: clamp(1rem, 3vw, 2rem);
  padding-block: clamp(1.25rem, 3.5vw, 2rem);
  cursor: pointer;
  list-style: none;
  transition: color 0.25s var(--ease);
}
.acc-item > summary::-webkit-details-marker { display: none; }
.acc-item > summary:hover { color: var(--accent); }
.acc-item > summary:hover .acc-num { color: var(--blue); }

.acc-num {
  font-family: var(--font-body);
  font-size: 0.8rem;
  letter-spacing: 0.14em;
  color: var(--blue);          /* war grau — Markenblau als Detailakzent */
  flex-shrink: 0;
}
.acc-label {
  font-family: var(--font-display);
  font-size: clamp(1.35rem, 4.5vw, 2.5rem);
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin-right: auto;
}
.acc-icon {
  position: relative;
  flex-shrink: 0;
  width: 1.1rem; height: 1.1rem;
}
.acc-icon::before, .acc-icon::after {
  content: '';
  position: absolute;
  inset: 50% 0 auto;
  height: 1.5px;
  background: currentColor;
  transition: transform 0.3s var(--ease);
}
.acc-icon::after { transform: rotate(90deg); }
.acc-item[open] .acc-icon::after { transform: rotate(0deg); }

.acc-body { padding-bottom: clamp(1.5rem, 4vw, 2.25rem); max-width: 62ch; }
.acc-body p { color: var(--text-muted); }

/* ---------- Tags ---------- */

.tags { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-top: 1rem; }
.tags li {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.35rem 0.85rem;
  font-size: 0.82rem;
  color: var(--text-muted);
  transition: border-color 0.25s var(--ease), color 0.25s var(--ease);
}
.tags li:hover { border-color: var(--accent); color: var(--text); }

/* ---------- Partikel-Silhouette (Werbeagentur) ---------- */

.agency-layout { display: grid; gap: clamp(1.5rem, 4vw, 3rem); }

.agency-visual {
  position: sticky;
  /* unter dem sticky Header */
  top: 4.75rem;
  z-index: 2;
  /* eigener Schichtkontext, damit das Canvas beim Scrollen nicht flackert */
  isolation: isolate;
}
.agency-visual-inner {
  position: relative;
  background: var(--media-bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  height: clamp(13rem, 30vh, 17rem);
}
.agency-visual canvas { display: block; width: 100%; height: 100%; }

.agency-visual-label {
  position: absolute;
  left: 0; right: 0; bottom: 0.65rem;
  margin: 0;
  text-align: center;
  font-family: var(--font-body);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-muted);
  pointer-events: none;
}
.agency-visual-label span { transition: opacity 0.3s var(--ease); }
.agency-visual-label.is-switching span { opacity: 0; }

/* Bis 900px komplett aus — auf dem Handy stört der Effekt mehr, als er bringt
   (Entscheidung von Dennis). Ohne JavaScript ebenfalls aus, da leeres Canvas. */
.agency-visual { display: none; }

/* ---------- Marken-Karten ---------- */

.brand-grid { display: grid; gap: 1.25rem; }
.brand-card, .case-card { min-width: 0; }

.brand-card {
  background: var(--bg-elevated);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(1.5rem, 4vw, 2.25rem);
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-card);
  transition: border-color 0.25s var(--ease), transform 0.25s var(--ease);
}
.brand-card:hover { border-color: var(--line-strong); }
.brand-card h3 {
  font-family: var(--font-display);
  font-size: clamp(1.3rem, 3vw, 1.7rem);
  letter-spacing: -0.02em;
  margin-bottom: 1rem;
}

.bullets { display: flex; flex-direction: column; gap: 0.6rem; color: var(--text-muted); font-size: 0.95rem; }
.bullets li { display: flex; gap: 0.7rem; }
.bullets li::before { content: '—'; color: var(--accent); flex-shrink: 0; }

.card-link {
  margin-top: auto;
  padding-top: 1.5rem;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  align-self: flex-start;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text);
  transition: color 0.25s var(--ease);
}
.card-link span { transition: transform 0.25s var(--ease); }
.card-link:hover { color: var(--accent); }
.card-link:hover span { transform: translate(2px, -2px); }

/* ---------- Case-Grid (DJ & Events) ---------- */

/* Versetztes Zwei-Spalten-Raster (nach dem Vorbild von hoculus.com):
   große Bildkacheln, die rechte Spalte nach unten verschoben, abwechselnd
   quadratisch und hochformatig. Kein Kartenrahmen — das Bild trägt die
   Kachel, Titel und Text stehen darunter. */
.case-grid { display: grid; gap: clamp(2.5rem, 6vw, 4.5rem); }

.case-card {
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.case-media {
  position: relative;
  aspect-ratio: 3 / 2;
  background: var(--media-bg);
  overflow: hidden;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  transition: border-color 0.25s var(--ease);
}
.case-card:hover .case-media { border-color: var(--line-strong); }
.case-media figure { margin: 0; position: absolute; inset: 0; }
.case-media img { width: 100%; height: 100%; object-fit: cover; }

/* Feinjustierung einzelner Ausschnitte. Betrifft nur Karten mit `square`
   oder `tall` — bei `wide` (3:2) entspricht der Rahmen dem Originalformat,
   dort wird ohnehin nichts beschnitten.
   Beim Alkotester-Panel steht der Schriftzug links: bei zentriertem
   Ausschnitt fehlt das „A", bei 10 % ist er vollständig. */
.case-media img[src*="alkotester-mieten-luebeck"] { object-position: 14% center; }
.case-media img[src*="alkotester-test-pusten"]    { object-position: 42% center; }
.case-media img[src*="audio-gaestebuch-gold"]     { object-position: 45% center; }

/* Ohne JS: nur das erste Bild zeigen. Mit JS übernimmt der Fade-Slider. */
.case-media figure + figure { display: none; }
.js .case-media figure {
  display: block;
  opacity: 0;
  transition: opacity 0.7s var(--ease);
}
.js .case-media figure.is-active { opacity: 1; }

.case-dots {
  position: absolute;
  left: 0; right: 0; bottom: 0.25rem;
  display: flex;
  justify-content: center;
  gap: 0;
  z-index: 2;
}
/* Der sichtbare Punkt bleibt klein, die Trefferfläche ist 44x44px —
   sonst sind die Dots auf dem Handy praktisch nicht treffbar. */
.case-dots button {
  width: 2.75rem; height: 2.75rem;
  display: grid;
  place-items: center;
  background: none;
}
.case-dots button::before {
  content: '';
  width: 0.5rem; height: 0.5rem;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.45);
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.25);
  transition: background 0.25s var(--ease), transform 0.25s var(--ease);
}
.case-dots button.is-active::before { background: var(--accent); transform: scale(1.3); }

.case-body {
  padding: clamp(1.1rem, 2.5vw, 1.6rem) 0 0;
  display: flex;
  flex-direction: column;
  flex: 1;
}
.case-body h3 {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 3.4vw, 2.15rem);
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin-bottom: 0.75rem;
}
.case-body p { color: var(--text-muted); font-size: 0.98rem; max-width: 46ch; }

/* ---------- Coming Soon ---------- */

.soon-list { border-top: 1px solid var(--line); }
.soon-item {
  display: flex;
  align-items: baseline;
  gap: clamp(1rem, 4vw, 3rem);
  padding-block: clamp(1.25rem, 3.5vw, 2rem);
  border-bottom: 1px solid var(--line);
}
.soon-year {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 5vw, 3rem);
  line-height: 1;
  letter-spacing: -0.03em;
  color: var(--blue);          /* war grau */
  flex-shrink: 0;
  opacity: 1;                  /* 0.75 drückte den Kontrast im Hellen auf exakt 3.0:1 */
}
.soon-body { display: flex; flex-direction: column; gap: 0.25rem; }
.soon-name {
  font-family: var(--font-display);
  font-size: clamp(1.15rem, 3vw, 1.6rem);
  letter-spacing: -0.02em;
}
.soon-desc { color: var(--text-muted); font-size: 0.95rem; }

/* ---------- Kontakt ---------- */

.contact-grid { display: grid; gap: clamp(2rem, 5vw, 3rem); align-items: start; }

.contact-form-wrap,
.contact-card {
  background: var(--bg-elevated);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(1.5rem, 4vw, 2.25rem);
  box-shadow: var(--shadow-card);
}

.contact-h3 {
  font-family: var(--font-display);
  font-size: 1.25rem;
  letter-spacing: -0.01em;
  margin-bottom: 1.5rem;
}

.field-row { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(8rem, 1fr)); }
.field-row > .field { min-width: 0; }
.field { display: flex; flex-direction: column; gap: 0.4rem; margin: 0 0 1rem; }
.field label { font-size: 0.85rem; font-weight: 500; }
.req { color: var(--accent); }

.field input,
.field textarea {
  width: 100%;
  font: inherit;
  font-size: 0.95rem;
  color: var(--text);
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 0.65rem;
  padding: 0.7rem 0.9rem;
  transition: border-color 0.2s var(--ease);
}
.field textarea { resize: vertical; min-height: 8rem; }
.field input::placeholder,
.field textarea::placeholder { color: var(--placeholder); }
.field input:hover,
.field textarea:hover { border-color: var(--line-strong); }
.field input:focus-visible,
.field textarea:focus-visible { border-color: var(--accent); }

.field.has-error input,
.field.has-error textarea { border-color: var(--error); }
.field-error { color: var(--error); font-size: 0.82rem; margin: 0; }

.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.form-status { margin: 1rem 0 0; font-size: 0.9rem; min-height: 1.4em; }
.form-status.is-ok { color: var(--success); }
.form-status.is-error { color: var(--error); }
.form-note { color: var(--text-muted); font-size: 0.8rem; margin: 0.75rem 0 0; }

.contact-card picture { display: block; }
.contact-card img {
  width: 100%;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  border-radius: calc(var(--radius) - 0.35rem);
  margin-bottom: 1.5rem;
}
.contact-list { display: flex; flex-direction: column; gap: 1.1rem; }
.contact-list li { display: flex; flex-direction: column; gap: 0.15rem; }
.contact-label {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--text-muted);
}
.contact-list a {
  border-bottom: 1px solid transparent;
  align-self: flex-start;
  display: inline-block;
  padding-block: 0.55rem;
  transition: color 0.2s var(--ease), border-color 0.2s var(--ease);
}
.contact-list a:hover { color: var(--accent); border-bottom-color: var(--accent); }

/* ---------- Footer-CTA ---------- */

.cta {
  border-top: 1px solid var(--line);
  padding-block: clamp(4rem, 12vh, 8rem);
}
.cta-link {
  display: flex;
  flex-direction: column;
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 9vw, 6rem);
  line-height: 1.02;
  letter-spacing: -0.03em;
  transition: color 0.3s var(--ease);
}
.cta-link:hover { color: var(--accent); }
.cta-link:hover em { color: var(--text); }
.cta-link em { transition: color 0.3s var(--ease); }

/* ---------- Footer ---------- */

.site-footer {
  border-top: 1px solid var(--line);
  padding-top: clamp(3rem, 8vh, 4.5rem);
  position: relative;
  z-index: 1;
  background: var(--bg);
}
.footer-grid { display: grid; gap: 2.5rem; }
.footer-brand p { color: var(--text-muted); font-size: 0.92rem; max-width: 34ch; margin-top: 1rem; }
.footer-h {
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--text-muted);
  margin-bottom: 1rem;
}
.footer-col ul { display: flex; flex-direction: column; gap: 0.15rem; font-size: 0.92rem; }
.footer-col ul a {
  color: var(--text-muted);
  border-bottom: 1px solid transparent;
  /* inline-block, sonst umfasst die Trefferfläche nur die Font-Box
     und das padding-block vergrößert sie nicht. */
  display: inline-block;
  padding-block: 0.65rem;
  transition: color 0.2s var(--ease), border-color 0.2s var(--ease);
}
.footer-col ul a:hover { color: var(--accent); border-bottom-color: var(--accent); }

.footer-bottom {
  margin-top: clamp(2.5rem, 6vh, 4rem);
  padding-block: 1.5rem;
  border-top: 1px solid var(--line);
}
.footer-bottom p { margin: 0; color: var(--text-muted); font-size: 0.85rem; }

/* ---------- Rechtstexte (Impressum / Datenschutz) ---------- */

.legal { padding-block: clamp(3rem, 8vh, 5rem) var(--gap-section); position: relative; z-index: 1; }
.legal-head { margin-bottom: clamp(2.5rem, 6vh, 4rem); }
.legal-head h1 {
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 6vw, 3.75rem);
  line-height: 1.05;
  letter-spacing: -0.02em;
  margin-bottom: 1rem;
}
.legal-head p { color: var(--text-muted); }

.legal-block {
  background: var(--bg-elevated);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(1.5rem, 4vw, 2.25rem);
  margin-bottom: 1.25rem;
  max-width: 72ch;
  box-shadow: var(--shadow-card);
}
.legal-block h2 {
  font-family: var(--font-display);
  font-size: clamp(1.2rem, 3vw, 1.5rem);
  letter-spacing: -0.01em;
  margin-bottom: 1.25rem;
}
.legal-block h3 {
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 600;
  margin: 1.75rem 0 0.5rem;
}
.legal-block h3:first-of-type { margin-top: 0; }
.legal-block p, .legal-block li { color: var(--text-muted); font-size: 0.95rem; }
.legal-block strong { color: var(--text); font-weight: 600; }
.legal-block a { color: var(--blue); border-bottom: 1px solid transparent; }
.legal-block a:hover { border-bottom-color: var(--blue); }
.legal-block ul { display: flex; flex-direction: column; gap: 0.6rem; margin: 1rem 0; }
.legal-block ul li { display: flex; gap: 0.7rem; }
.legal-block ul li::before { content: '—'; color: var(--accent); flex-shrink: 0; }
.legal-foot { color: var(--text-muted); font-size: 0.9rem; margin-top: 2.5rem; }
.legal-foot a { color: var(--blue); }

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 2rem;
  transition: color 0.2s var(--ease);
}
.back-link:hover { color: var(--accent); }

/* ============================================================
   Breakpoints
   ============================================================ */

@media (min-width: 640px) {
  .hero-media { max-width: none; }
  .contact-card img { aspect-ratio: 16 / 10; }
}

@media (min-width: 900px) {
  .nav-desktop { display: flex; }
  .header-social { display: flex; }
  .nav-toggle { display: none; }
  .nav-mobile { display: none !important; }

  .hero-inner { grid-template-columns: 1.35fr 0.65fr; align-items: center; }
  .hero-media { max-width: 24rem; margin-left: auto; }

  .about-grid { grid-template-columns: 1.1fr 0.9fr; align-items: start; }
  /* Karten links, Silhouette rechts (Reihenfolge per grid-column gedreht,
     damit das Markup semantisch sinnvoll bleibt: Karten zuerst im DOM). */
  .agency-layout {
    grid-template-columns: 1.15fr 0.85fr;
    align-items: start;
    column-gap: clamp(2rem, 4vw, 3.5rem);
  }
  .js .agency-visual {
    display: block;
    grid-column: 2;
    grid-row: 1;
    top: 6rem;
  }
  .agency-layout .brand-grid { grid-column: 1; grid-row: 1; }
  .agency-visual-inner { height: clamp(20rem, 46vh, 30rem); }

  /* Versetztes Raster: rechte Spalte startet tiefer */
  .case-grid {
    grid-template-columns: repeat(2, 1fr);
    column-gap: clamp(2rem, 4vw, 3.5rem);
  }
  .case-card:nth-child(even) { margin-top: clamp(3rem, 7vw, 6.5rem); }

  /* Format nach Motiv, nicht nach Position: breite Motive (XXL-Buchstaben,
     Melobox, DJ-Pult) würden in einem quadratischen Ausschnitt angeschnitten,
     stehende Geräte (Alkotester, Fotobox, Telefone) vertragen Hochformat. */
  .case-card[data-format="square"] .case-media { aspect-ratio: 1 / 1; }
  .case-card[data-format="tall"]   .case-media { aspect-ratio: 4 / 5; }
  .case-card[data-format="wide"]   .case-media { aspect-ratio: 3 / 2; }
  .contact-grid { grid-template-columns: 1.15fr 0.85fr; }
  .footer-grid { grid-template-columns: 1.5fr repeat(3, 1fr); gap: 2rem; }
  .cta-link { align-items: flex-start; }
}

@media (min-width: 1200px) {
  /* bewusst weiterhin zweispaltig — die Kacheln sollen groß bleiben */
  .fact-grid { gap: 1.25rem; }
}

/* ============================================================
   Reduced Motion — Canvas aus, Reveals sofort sichtbar
   ============================================================ */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }

  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }

  .js .reveal { opacity: 1; transform: none; }
  .marquee-track { animation: none; }
  #glow-canvas { display: none; }
}
