/* ==========================================================================
   biteme.digital . Cases (pages/cases.css) . DAS LOGBUCH
   Sub-Page, KONVENTIONELLER Flow (Guide §5a/§6, kein dive, kein ascent).
   Starttiefe -500 m. Motiv: Logbuch. Filter-Leiste + Schriftzug-Logo-Wand
   + Case-Stories als Logbuch-Eintraege mit Tiefenmarken am Rand (mono,
   caribbean). Ruhiger als die Home: dosierte Occlusion, dezente Reveals.
   Regel (Guide §10.6): KEINE Initial-States (opacity:0) fuer INHALTE im CSS,
   die setzt scroll-engine.js via JS, damit die Seite ohne JS lesbar bleibt.
   CI v3: nur Caribbean / Purple Turtle / Jellofish als Akzente.
   ========================================================================== */

/* Landezone der Cases-Seite (oberste Sektion = midnight). Die Engine
   blendet --zone-bg beim Scrollen weiter (midnight -> twilight -> surface). */
body { --zone-bg: var(--zone-midnight); }

/* Fester Zonen-Hintergrund UNTER dem Fisch-Layer (z:0). Der Fisch (z:1)
   schwimmt davor, der Content in main (z:2) davor. (Spiegelt home.css.) */
.zone-bg-layer {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-color: var(--zone-bg, var(--bg-deep));
}

/* Content liegt ueber Fisch- und Deko-Layern */
main { position: relative; z-index: var(--z-content); }
.section { overflow: hidden; }
.section > .container { position: relative; z-index: 1; }

/* --------------------------------------------------------------------------
   HERO . ruhig, halbe Hoehe, kein Bild-Spektakel (Draft S.1)
   -------------------------------------------------------------------------- */
.cases-hero {
  padding-block: clamp(5rem, 16vh, 9rem) clamp(3rem, 8vh, 5rem);
}
.cases-hero__inner { max-width: 56rem; }
.cases-hero h1 { margin-top: 0.875rem; }
.cases-hero .lead { margin-top: 1.5rem; max-width: 44rem; }

/* --------------------------------------------------------------------------
   FILTER & LOGO-WAND
   -------------------------------------------------------------------------- */
.cases-wall { padding-block: clamp(2rem, 6vh, 4rem) var(--section-pad); }

.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-bottom: 2.5rem;
}
.filter-btn {
  font-family: var(--font-mono);
  font-size: 0.8125rem;
  letter-spacing: 0.02em;
  padding: 0.5rem 1.05rem;
  border-radius: 999px;
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  transition: color var(--t-med) ease, border-color var(--t-med) ease, background var(--t-med) ease;
}
.filter-btn:hover { border-color: var(--caribbean-40); color: var(--text-primary); }
.filter-btn[data-active="true"] {
  background: var(--caribbean-08);
  border-color: var(--caribbean-40);
  color: var(--accent-caribbean);
}

.logo-wall {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem;
}
@media (min-width: 600px) { .logo-wall { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 900px) { .logo-wall { grid-template-columns: repeat(5, 1fr); } }

/* Filter-Ausblendung: rein additiv, kein Layout-Sprung beim Laden (CLS ~0,
   Initial-Zustand ist sichtbar, JS blendet nur weg). */
.logo-card.is-filtered-out,
.log-entry.is-filtered-out { display: none; }

.logo-wall__empty {
  margin-top: 1.5rem;
  font-size: 0.8125rem;
  color: var(--text-muted);
  opacity: 0.7;
}

/* --------------------------------------------------------------------------
   CASE STUDIES . Logbuch-Eintraege mit Tiefenmarken am Rand
   -------------------------------------------------------------------------- */
.cases-list { position: relative; }

.log { display: flex; flex-direction: column; gap: 1.25rem; }

.log-entry {
  position: relative;
  display: grid;
  grid-template-columns: 64px 1fr;
  gap: 1.5rem;
  background: var(--bg-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
}
@media (min-width: 720px) {
  .log-entry { grid-template-columns: 92px 1fr; padding: 2rem 2.25rem; gap: 2rem; }
}

/* Tiefenmarken-Rail: mono caribbean, Seekarten-/Logbuch-Stil */
.log-entry__rail {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.5rem;
  padding-top: 0.35rem;
}
.log-entry__depth {
  font-size: 0.8125rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--accent-caribbean);
  white-space: nowrap;
}
.log-entry__tick {
  width: 1px;
  flex: 1;
  min-height: 28px;
  background: linear-gradient(var(--caribbean-40), transparent);
}
.log-entry__no {
  font-size: 0.6875rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
  opacity: 0.7;
}

.log-entry__head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem 1.5rem;
  margin-bottom: 1.5rem;
}
.log-entry__logo {
  min-height: 0;
  padding: 0.6rem 1.1rem;
  font-size: 1.0625rem;
  color: var(--text-primary);
  flex: none;
}
.log-entry__meta { display: flex; flex-direction: column; gap: 0.55rem; }
.log-entry__tags { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.log-entry__branche {
  font-size: 0.75rem;
  letter-spacing: 0.04em;
  color: var(--text-muted);
}

/* Status-Pill: Purple-Ton, klar abgesetzt vom Cluster-Tag (Caribbean) */
.pill--status {
  background: var(--purple-soft);
  border-color: rgba(74, 36, 120, 0.45);
  color: #C4A6E0;
}

.log-entry__fields {
  display: grid;
  gap: 1.1rem;
}
.log-entry__fields dt { margin-bottom: 0.3rem; }
.log-entry__fields dd {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.9375rem;
  line-height: 1.65;
  max-width: 62ch;
}

.log-entry__quote {
  margin-top: 1.4rem;
  padding-left: 1.1rem;
  border-left: 2px solid var(--caribbean-40);
  font-style: italic;
  color: rgba(245, 247, 250, 0.82);
  line-height: 1.6;
}

.log-entry__more { margin-top: 1.4rem; margin-bottom: 0; }
/* "Volle Case lesen" ist Pending: Detail-Sub-Pages folgen nach Kunden-
   Freigabe (Draft "Was als naechstes"). Kein toter Link, sichtbar gestundet. */
.arrow-link.is-pending {
  color: var(--text-muted);
  cursor: default;
  opacity: 0.85;
}
.log-entry__pending {
  font-size: 0.6875rem;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  opacity: 0.7;
}

/* --------------------------------------------------------------------------
   TESTIMONIALS . Platzhalter-Slots (Pending Kuratierung)
   -------------------------------------------------------------------------- */
.voice-card { display: flex; flex-direction: column; }
.voice-card__mark {
  font-family: var(--font-display);
  font-size: 2.5rem;
  line-height: 0.6;
  color: var(--caribbean-40);
  margin-bottom: 0.75rem;
}
.voice-card__quote {
  font-style: italic;
  color: var(--text-muted);
  line-height: 1.65;
  margin-bottom: 1.25rem;
  flex: 1;
}
.voice-card__foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border-subtle);
}
.voice-card__who { display: flex; flex-direction: column; gap: 0.15rem; }
.voice-card__who strong { font-weight: 600; }
.voice-card__who .text-muted { font-size: 0.8125rem; }
.voice-card__src {
  font-size: 0.75rem;
  color: var(--text-muted);
  opacity: 0.7;
  white-space: nowrap;
}

/* --------------------------------------------------------------------------
   FINAL CTA . twilight-Aufhellung, kein Breach
   -------------------------------------------------------------------------- */
.cases-cta__box {
  position: relative;
  text-align: center;
  max-width: 48rem;
  margin-inline: auto;
  padding: clamp(2.5rem, 7vw, 4.5rem) clamp(1.5rem, 5vw, 3.5rem);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  background: linear-gradient(160deg, var(--bg-elevated-2), var(--bg-elevated) 55%, var(--bg-deep));
}
.cases-cta__box .lead { margin: 1.5rem auto 0; max-width: 40rem; }
.cases-cta__actions {
  margin-top: 2.5rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.9rem;
}
.cases-cta__alt { margin: 0; font-size: 0.9375rem; color: var(--text-muted); }

/* --------------------------------------------------------------------------
   DEKO . dosierte Occlusion (Sub-Page ruhiger als die Home)
   -------------------------------------------------------------------------- */
.occluder {
  position: absolute;
  bottom: 0;
  pointer-events: none;
  z-index: 0;
  filter: blur(2px);
}
.occluder svg { display: block; width: 100%; height: auto; }
.occluder--kelp {
  left: -2vw;
  width: clamp(120px, 14vw, 200px);
  opacity: 0.85;
}

.deko-sway { transform-origin: 50% 100%; animation: deko-sway 11s ease-in-out infinite alternate; }
@keyframes deko-sway {
  from { transform: rotate(-1.4deg); }
  to { transform: rotate(1.4deg); }
}

/* Seekarten-/Tiefen-Label (Jellofish-Ton wie Home v7) */
.seekarten-label {
  position: absolute;
  z-index: 0;
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  letter-spacing: 0.06em;
  color: var(--accent-caribbean);
  opacity: 0.5;
  white-space: nowrap;
  pointer-events: none;
}
.seekarten-label--hero { right: clamp(12px, 3vw, 40px); bottom: 8vh; }

/* God Rays in der CTA-Aufhellung (dezent) */
.god-rays {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}
.god-rays i {
  position: absolute;
  top: -20%;
  width: 18%;
  height: 140%;
  background: linear-gradient(var(--caribbean-15), transparent 70%);
  transform: rotate(8deg);
  filter: blur(6px);
  opacity: 0.5;
}
.god-rays i:nth-child(1) { left: 12%; }
.god-rays i:nth-child(2) { left: 48%; animation-delay: -3s; }
.god-rays i:nth-child(3) { left: 78%; }

/* Blasen (Hero) */
.bubbles {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}
.bubbles i {
  position: absolute;
  bottom: -24px;
  width: 6px; height: 6px;
  border-radius: 999px;
  background: var(--caribbean-25);
  animation: bubble-rise 9s linear infinite;
}
.bubbles i:nth-child(1) { left: 14%; animation-delay: -1s; }
.bubbles i:nth-child(2) { left: 36%; width: 4px; height: 4px; animation-delay: -4s; }
.bubbles i:nth-child(3) { left: 62%; animation-delay: -2.5s; }
.bubbles i:nth-child(4) { left: 84%; width: 5px; height: 5px; animation-delay: -6s; }
@keyframes bubble-rise {
  0% { transform: translateY(0) translateX(0); opacity: 0; }
  12% { opacity: 0.6; }
  100% { transform: translateY(-90vh) translateX(10px); opacity: 0; }
}

/* --------------------------------------------------------------------------
   RESPONSIVE . Mobile 390px ohne Overflow
   -------------------------------------------------------------------------- */
@media (max-width: 719px) {
  .log-entry { grid-template-columns: 1fr; gap: 0.9rem; }
  /* Tiefenmarke als horizontale Logbuch-Zeile statt Rail */
  .log-entry__rail {
    flex-direction: row;
    align-items: center;
    gap: 0.75rem;
    padding-top: 0;
  }
  .log-entry__tick { width: auto; height: 1px; min-height: 0; flex: 1;
    background: linear-gradient(90deg, var(--caribbean-40), transparent); }
  .log-entry__head { gap: 0.75rem 1rem; }
  .voice-card__foot { flex-direction: column; align-items: flex-start; gap: 0.5rem; }
}

@media (max-width: 899px) {
  .occluder--kelp { display: none; }
  .seekarten-label { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .deko-sway { animation: none; }
  .bubbles i { animation: none; opacity: 0; }
}


/* ============================================================
   LOGO-CLOUD (Juergen-GO 13.06.): Tiefen-Schwarm der Kundennamen
   statt 20 Kachel-Container. flex-wrap = responsive + kompakt
   (kein Grid-Teppich, kein 20-untereinander mobil), Groessen-
   Klassen = Tiefenwirkung, sanftes Bobben = Stroemung. Nur
   transform/opacity. reduced-motion: kein Drift.
   ============================================================ */
.logo-cloud {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: clamp(0.9rem, 2.5vw, 2rem) clamp(1.1rem, 3vw, 2.8rem);
  max-width: 60rem;
  margin: clamp(1.5rem, 5vh, 3rem) auto 0;
  padding: clamp(1rem, 4vh, 2.5rem) 0;
}
.lc-name {
  font-family: var(--font-mono);
  letter-spacing: 0.02em;
  color: var(--text-muted);
  white-space: nowrap;
  line-height: 1;
  will-change: transform;
  animation: lc-bob 6s ease-in-out infinite alternate;
}
.lc-name--xl { font-size: clamp(1.5rem, 3.4vw, 2.6rem); color: var(--accent-caribbean); opacity: 0.95; }
.lc-name--l  { font-size: clamp(1.15rem, 2.4vw, 1.8rem); opacity: 0.82; }
.lc-name--m  { font-size: clamp(0.95rem, 1.8vw, 1.35rem); opacity: 0.6; }
.lc-name--s  { font-size: clamp(0.8rem, 1.4vw, 1.05rem); opacity: 0.42; }
.lc-name:nth-child(3n)   { animation-duration: 7.5s; animation-delay: -1.5s; }
.lc-name:nth-child(3n+1) { animation-duration: 6.5s; animation-delay: -3s; }
.lc-name:nth-child(4n)   { animation-duration: 8.5s; animation-delay: -2.2s; }
@keyframes lc-bob {
  from { transform: translateY(-4px); }
  to   { transform: translateY(4px); }
}
@media (prefers-reduced-motion: reduce) { .lc-name { animation: none; } }


/* ============================================================
   STIMMEN-WIRBEL (Juergen-GO 13.06.): dichtes Zitat-Mosaik aus
   echten LinkedIn-Shoutouts, anonymisiert auf Vornamen. Masonry
   via CSS columns = die MENGE des Lobs wird sichtbar. Karten
   schweben beim Scroll ein (data-reveal). break-inside:avoid.
   ============================================================ */
.voice-mosaic {
  columns: 1;
  column-gap: clamp(0.9rem, 2vw, 1.4rem);
  max-width: 66rem;
  margin: clamp(1.5rem, 5vh, 3rem) auto 0;
}
@media (min-width: 600px) { .voice-mosaic { columns: 2; } }
@media (min-width: 980px) { .voice-mosaic { columns: 3; } }
.voice-card {
  break-inside: avoid;
  display: block;
  margin: 0 0 clamp(0.9rem, 2vw, 1.4rem);
  padding: clamp(1.05rem, 2.4vw, 1.6rem);
  background: var(--bg-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg, 1.1rem);
}
.voice-card__mark { display: block; font-family: var(--font-display); font-size: 2.2rem; line-height: 0.5; height: 0.6em; color: var(--accent-caribbean); opacity: 0.5; }
.voice-card__quote { margin: 0.2rem 0 0.85rem; font-size: clamp(0.98rem, 1.3vw, 1.1rem); line-height: 1.5; color: var(--text-primary); }
.voice-card__foot { display: flex; flex-direction: column; gap: 0.1rem; }
.voice-card__foot strong { color: var(--text-primary); font-size: 0.9rem; }
.voice-card__foot .text-muted { font-size: 0.78rem; }

.voice-more { max-width: 50rem; margin: clamp(1.2rem, 3vh, 2rem) auto 0; text-align: center; font-size: 0.8rem; letter-spacing: 0.04em; color: var(--text-muted); opacity: 0.7; line-height: 1.7; }


/* ============================================================
   STIMMEN-WIRBELWIND (Juergen-GO 13.06.): scroll-gekoppelte Szene,
   in der die Shoutout-Stimmen aus der Tiefe nach vorne fliegen und
   im Vorbeiziehen lesbar werden. JS (cases.js) steuert den Flug via
   GSAP ScrollTrigger (pin+scrub). NUR Desktop + no-reduced-motion.
   Mobil/reduced/no-JS: schlanke Liste (max 6 Karten, kein Pin).
   ============================================================ */
.voice-vortex { position: relative; }
/* Default (Mobil / kein JS / reduced): kompakte Liste, NICHT 15 Kacheln */
.vortex-stage { display: flex; flex-direction: column; gap: 0.9rem; max-width: 40rem; margin: clamp(1.5rem,5vh,2.5rem) auto 0; }
.vortex-stage > .voice-card:nth-child(n+7) { display: none; }
/* Wirbelwind aktiv (Desktop): Buehne 100vh, Karten absolut im Zentrum */
.vortex-stage.is-vortex { display: block; height: 100vh; max-width: none; margin: 0; perspective: 1200px; overflow: hidden; }
.vortex-stage.is-vortex > .voice-card { position: absolute; top: 50%; left: 50%; width: min(440px, 46vw); margin: 0; display: block !important; box-shadow: 0 20px 60px rgba(0,0,0,0.45); will-change: transform, opacity; }


/* ============================================================
   BILD-STIMMEN (Juergen-GO 13.06.): die voice-cards sind jetzt
   anonymisierte LinkedIn-Screenshots (Kopf ersetzt, Foto+Nachname
   weg). Karte = Bild, kein Text-Styling. Wirbelwind + Mobile-Liste
   nutzen dieselbe Karte.
   ============================================================ */
.voice-card { padding: 0 !important; background: none !important; border: none !important; overflow: hidden; border-radius: 14px; box-shadow: 0 14px 44px rgba(0,0,0,0.45); }
.voice-card img { display: block; width: 100%; height: auto; border-radius: 14px; }
.vortex-stage.is-vortex > .voice-card { width: min(460px, 50vw); }
