/* Buqora – Stylesheet
   Layout-Idee: "Schaltplan" – die Seite folgt dem Weg einer Anfrage. Feine Leiterbahnen
   mit Knotenpunkten (wie im Logo) verbinden Überschriften, Schritte und den Hero.
   Schriften liegen lokal unter assets/fonts (SIL Open Font License). */

@font-face { font-family: "Bricolage Grotesque"; src: url("../fonts/bricolage-grotesque-var.woff2") format("woff2"); font-weight: 200 800; font-display: swap; }
@font-face { font-family: "Instrument Sans"; src: url("../fonts/instrument-sans-var.woff2") format("woff2"); font-weight: 400 700; font-display: swap; }
@font-face { font-family: "JetBrains Mono"; src: url("../fonts/jetbrains-mono-500.woff2") format("woff2"); font-weight: 500; font-display: swap; }

:root {
  /* Farbe: Schwarz/Weiß + eine Signalfarbe (Bernstein) */
  --ink: #0C0C0B;          /* Hintergrund */
  --ink-2: #151513;        /* leicht angehobene Flächen */
  --ink-3: #1D1D1A;        /* Eingabefelder, Chat-Blasen */
  --paper: #F2EFE8;        /* Text */
  --mute: #A6A299;         /* Nebentext */
  --line: rgba(242, 239, 232, 0.12);
  --line-strong: rgba(242, 239, 232, 0.24);
  --signal: #FFB23F;       /* einzige Akzentfarbe */
  --signal-soft: rgba(255, 178, 63, 0.12);

  /* Typografie */
  --f-display: "Bricolage Grotesque", "Avenir Next", "Segoe UI", system-ui, sans-serif;
  --f-body: "Instrument Sans", "Segoe UI", system-ui, -apple-system, sans-serif;
  --f-mono: "JetBrains Mono", ui-monospace, "Cascadia Mono", Consolas, monospace;

  --step--1: 0.8125rem;
  --step-0: 1.0625rem;
  --step-1: clamp(1.2rem, 1.1rem + 0.4vw, 1.4rem);
  --step-2: clamp(1.5rem, 1.25rem + 1vw, 2rem);
  --step-3: clamp(2rem, 1.5rem + 2.2vw, 3.25rem);
  --step-4: clamp(2.35rem, 1.6rem + 3.4vw, 4.4rem);

  --radius: 10px;
  --gutter: clamp(16px, 4vw, 40px);
  --max: 1200px;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);

  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 84px; }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }

body {
  margin: 0;
  background: var(--ink);
  color: var(--paper);
  font-family: var(--f-body);
  font-size: var(--step-0);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img, svg, canvas { display: block; max-width: 100%; }
a { color: inherit; }
p { margin: 0; }
h1, h2, h3 { font-family: var(--f-display); font-weight: 700; line-height: 1.05; letter-spacing: -0.025em; margin: 0; text-wrap: balance; }
h2 { font-size: var(--step-3); }
h3 { font-size: var(--step-1); letter-spacing: -0.01em; line-height: 1.2; }
ul { margin: 0; padding: 0; list-style: none; }
::selection { background: var(--signal); color: var(--ink); }
:focus-visible { outline: 2px solid var(--signal); outline-offset: 3px; border-radius: 4px; }

.wrap { width: 100%; max-width: calc(var(--max) + 2 * var(--gutter)); margin-inline: auto; padding-inline: var(--gutter); }
.skip { position: absolute; left: 16px; top: -100px; z-index: 100; background: var(--signal); color: var(--ink); padding: 10px 14px; border-radius: var(--radius); font-weight: 600; }
.skip:focus { top: 12px; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Markierte Lücken, die noch ausgefüllt werden müssen */
.ph { font-family: var(--f-mono); font-size: 0.86em; color: var(--signal); background: var(--signal-soft); border: 1px dashed rgba(255, 178, 63, 0.5); border-radius: 4px; padding: 0 0.35em; white-space: nowrap; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.6em;
  min-height: 50px; padding: 0.75em 1.35em;
  border-radius: var(--radius); border: 1px solid transparent;
  font: 600 1rem/1.2 var(--f-body); text-decoration: none; cursor: pointer;
  position: relative; isolation: isolate; overflow: hidden;
  transition: transform 0.2s var(--ease), box-shadow 0.3s var(--ease), background-color 0.2s, border-color 0.2s, color 0.2s;
}
.btn:active { transform: scale(0.97); }
.btn svg { width: 18px; height: 18px; flex: none; }
.btn-primary { background: var(--signal); color: var(--ink); }
/* Glanzlicht, das beim Hover einmal über den Button läuft */
.btn-primary::after {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: linear-gradient(110deg, transparent 32%, rgba(255, 255, 255, 0.55) 50%, transparent 68%);
  transform: translateX(-120%); transition: transform 0.75s var(--ease);
}
.btn-ghost { border-color: var(--line-strong); color: var(--paper); background: transparent; }
.btn-primary:focus-visible { box-shadow: 0 0 0 1px rgba(255, 194, 102, 0.6), 0 10px 30px -6px rgba(255, 178, 63, 0.65), 0 0 48px -6px rgba(255, 178, 63, 0.55); }
@media (hover: hover) and (pointer: fine) {
  .btn-primary:hover {
    background: #FFC266; transform: translateY(-2px);
    box-shadow: 0 0 0 1px rgba(255, 194, 102, 0.6), 0 10px 30px -6px rgba(255, 178, 63, 0.65), 0 0 48px -6px rgba(255, 178, 63, 0.55);
  }
  .btn-primary:hover::after { transform: translateX(120%); }
  .btn-primary:active, .btn-ghost:active { transform: translateY(-1px) scale(0.97); }
  .btn-ghost:hover {
    border-color: rgba(255, 178, 63, 0.75); background: rgba(255, 178, 63, 0.06); transform: translateY(-2px);
    box-shadow: 0 0 26px -6px rgba(255, 178, 63, 0.45), inset 0 0 18px -8px rgba(255, 178, 63, 0.5);
  }
  .channel { transition: border-color 0.25s, box-shadow 0.3s var(--ease), transform 0.2s var(--ease); }
  .channel:hover { border-color: rgba(255, 178, 63, 0.6); box-shadow: 0 0 30px -8px rgba(255, 178, 63, 0.4); transform: translateY(-2px); }
}
.btn-sm { min-height: 40px; padding: 0.5em 0.95em; font-size: 0.9375rem; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 50;
  background: rgba(12, 12, 11, 0.78);
  -webkit-backdrop-filter: blur(14px) saturate(1.2); backdrop-filter: blur(14px) saturate(1.2);
  border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; gap: 20px; min-height: 68px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; margin-right: auto; }
.brand svg, .brand img { width: 36px; height: 36px; flex: none; }
.brand-name { font-family: var(--f-display); font-weight: 700; font-size: 1.35rem; letter-spacing: -0.02em; }
.nav { display: none; }
.nav ul { display: flex; gap: 4px; }
.nav a { display: block; padding: 8px 12px; border-radius: 8px; text-decoration: none; color: var(--mute); font-size: 0.9375rem; transition: color 0.2s; }
.nav a:hover { color: var(--paper); }
.menu-btn {
  display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px;
  background: transparent; border: 1px solid var(--line-strong); border-radius: var(--radius); color: var(--paper); cursor: pointer;
}
.menu-btn svg { width: 20px; height: 20px; }
.header-cta { display: none; }
.mobile-nav { border-top: 1px solid var(--line); padding-block: 8px 20px; }
.mobile-nav a { display: block; padding: 12px 0; text-decoration: none; font-size: 1.125rem; border-bottom: 1px solid var(--line); }
.mobile-nav .btn { margin-top: 16px; width: 100%; }

@media (min-width: 900px) {
  .nav { display: block; }
  .menu-btn, .mobile-nav { display: none !important; }
  .header-cta { display: inline-flex; }
}

/* ---------- Eyebrow mit Leiterbahn ---------- */
.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--f-mono); font-size: var(--step--1); letter-spacing: 0.08em; text-transform: uppercase; color: var(--mute);
}
.eyebrow::before { /* Knoten + Leiterbahn, wie im Logo */
  content: ""; flex: none; width: 36px; height: 9px;
  background:
    radial-gradient(circle at 4.5px 50%, var(--signal) 0 3px, transparent 3.5px),
    linear-gradient(var(--line-strong), var(--line-strong)) no-repeat 9px 50% / 27px 1px;
}
.section-head { display: grid; gap: 18px; max-width: 46rem; margin-bottom: clamp(36px, 5vw, 64px); }
.section-head .lede { color: var(--mute); font-size: var(--step-1); line-height: 1.5; max-width: 40rem; }

.section { position: relative; padding-block: clamp(72px, 10vw, 136px); }
.section + .section { border-top: 1px solid var(--line); }

/* ---------- Hero ---------- */
.hero { position: relative; overflow: hidden; isolation: isolate; padding-block: clamp(48px, 9vw, 120px) clamp(56px, 8vw, 110px); }
.hero-bg {
  position: absolute; inset: -12% 0 -12% 0; z-index: -1; will-change: transform;
  /* Statischer Fallback (ohne JavaScript / vor dem Laden): feines Leiterbahn-Raster */
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='160' fill='none' stroke='%23F2EFE8' stroke-opacity='.07'%3E%3Cpath d='M0 40h80l14 14v26h146M0 120h40l14-14h66l14 14h106M160 0v40l14 14h66'/%3E%3Ccircle cx='120' cy='80' r='2.5'/%3E%3Ccircle cx='54' cy='106' r='2.5'/%3E%3C/svg%3E");
  -webkit-mask-image: linear-gradient(100deg, rgba(0,0,0,.25) 0%, rgba(0,0,0,.55) 40%, #000 75%);
          mask-image: linear-gradient(100deg, rgba(0,0,0,.25) 0%, rgba(0,0,0,.55) 40%, #000 75%);
}
.hero-bg.is-live { background-image: none; }
.hero-bg canvas { width: 100%; height: 100%; }
/* Hero-Film: autoplay, stumm, Schleife, Poster. Poster bleibt bei Reduced Motion / Datensparmodus stehen. */
.hero-video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 72% 50%; background: var(--ink); }
.hero-bg.has-video { background-image: none; }
.hero-video.is-idle { opacity: 0; }
@media (max-width: 959px) {
  .hero-bg.has-video::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(12,12,11,.55), rgba(12,12,11,.78) 60%, rgba(12,12,11,.9)); }
}
.hero::after { /* sanfter Übergang nach unten */
  content: ""; position: absolute; inset: auto 0 0 0; height: 120px; z-index: -1;
  background: linear-gradient(to bottom, transparent, var(--ink));
}
.hero-grid { display: grid; gap: clamp(40px, 6vw, 72px); align-items: center; }
.hero-copy { display: grid; gap: 24px; min-width: 0; }
.hero h1 { font-size: var(--step-4); line-height: 0.98; letter-spacing: -0.035em; max-width: 15ch; }
.hero h1 em { font-style: normal; color: var(--signal); }
.hero .lede { font-size: var(--step-1); line-height: 1.5; color: #D9D5CC; max-width: 36rem; }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; }
.trust { display: flex; flex-wrap: wrap; gap: 8px 20px; font-size: 0.9375rem; color: var(--mute); }
.trust li { display: inline-flex; align-items: center; gap: 8px; }
.trust li::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: var(--signal); }

.flow { position: relative; display: grid; gap: 14px; max-width: 420px; width: 100%; justify-self: center; }
.flow-label { font-family: var(--f-mono); font-size: 0.75rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--mute); }
.flow-layer { will-change: transform; }
.flow-card {
  position: relative; background: rgba(21, 21, 19, 0.88); border: 1px solid var(--line); border-radius: 14px;
  padding: 16px 18px; display: grid; gap: 8px;
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
}
.flow-card .meta { display: flex; align-items: center; justify-content: space-between; gap: 12px; font-family: var(--f-mono); font-size: 0.75rem; color: var(--mute); }
.flow-card .meta b { font-weight: 500; color: var(--paper); }
.flow-card p { font-size: 0.975rem; line-height: 1.45; }
.flow-card.is-bot { margin-left: 28px; border-color: rgba(255, 178, 63, 0.35); }
.flow-card.is-done { margin-left: 56px; }
.flow-card.is-done p { display: flex; gap: 10px; align-items: center; }
.check { flex: none; width: 22px; height: 22px; border-radius: 50%; background: var(--signal); color: var(--ink); display: grid; place-items: center; }
.check svg { width: 12px; height: 12px; }
.flow-wire { position: absolute; left: 10px; top: 38px; bottom: 30px; width: 1px; background: var(--line-strong); z-index: -1; }

@media (min-width: 960px) {
  .hero-grid { grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.9fr); }
  .flow { justify-self: end; }
}

/* Ladesequenz im Hero – kurz und einmalig */
@media (prefers-reduced-motion: no-preference) {
  /* Text bleibt sofort sichtbar (schnellster Seitenaufbau); nur der Beispielablauf baut sich auf */
  .flow-layer > * { animation: rise 0.6s var(--ease) both; }
  .flow-layer:nth-of-type(2) > * { animation-delay: 0.35s; }
  .flow-layer:nth-of-type(3) > * { animation-delay: 0.65s; }
  .flow-layer:nth-of-type(4) > * { animation-delay: 0.95s; }
}
@keyframes rise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

/* ---------- Problem ---------- */
.pain-grid { display: grid; gap: 0; border-top: 1px solid var(--line-strong); }
.pain { display: grid; gap: 14px; padding-block: 28px; border-bottom: 1px solid var(--line); min-width: 0; }
.pain .log { font-family: var(--f-mono); font-size: 0.75rem; color: var(--mute); display: flex; align-items: center; gap: 8px; letter-spacing: 0.02em; }
.pain .log::before { content: ""; width: 7px; height: 7px; border-radius: 50%; border: 1.5px solid var(--mute); }
.pain h3 { font-size: var(--step-2); }
.pain p { color: var(--mute); max-width: 34rem; }
@media (min-width: 860px) {
  .pain-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); border-bottom: 1px solid var(--line); }
  .pain { padding: 32px 32px 36px 0; border-bottom: 0; }
  .pain + .pain { padding-left: 32px; border-left: 1px solid var(--line); }
}

/* ---------- Leistungen ---------- */
.services { display: grid; gap: 16px; }
.service {
  display: grid; gap: 24px; padding: clamp(24px, 4vw, 44px);
  background: var(--ink-2); border: 1px solid var(--line); border-radius: 18px; min-width: 0;
}
.service-head { display: grid; gap: 14px; align-content: start; }
.service-icon { width: 52px; height: 52px; color: var(--paper); }
.service .kicker { font-family: var(--f-mono); font-size: 0.75rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--signal); }
.service h3 { font-size: var(--step-2); }
.service .benefit { color: #D9D5CC; }
.ticks { display: grid; gap: 12px; }
.ticks li { position: relative; padding-left: 28px; }
.ticks li::before {
  content: ""; position: absolute; left: 2px; top: 0.55em; width: 12px; height: 7px;
  border-left: 2px solid var(--signal); border-bottom: 2px solid var(--signal); transform: rotate(-45deg) translateY(-3px);
}
.glossary { margin-top: 8px; padding: 14px 16px; border-left: 2px solid var(--line-strong); color: var(--mute); font-size: 0.9375rem; }
.glossary b { color: var(--paper); font-weight: 600; }
@media (min-width: 900px) {
  .service { grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: 48px; }
}
.custom-note {
  margin-top: 16px; display: grid; gap: 10px; padding: clamp(24px, 4vw, 40px);
  border: 1px dashed var(--line-strong); border-radius: 18px;
}
.custom-note h3 { font-size: var(--step-2); }
.custom-note p { color: var(--mute); max-width: 52rem; }

/* ---------- Beispiele ---------- */
.tablist { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px; margin-bottom: 28px; scrollbar-width: none; }
.tablist::-webkit-scrollbar { display: none; }
.tab {
  flex: none; min-height: 44px; padding: 0.55em 1.1em; border-radius: var(--radius);
  border: 1px solid var(--line-strong); background: transparent; color: var(--mute);
  font: 500 0.9375rem/1.2 var(--f-body); cursor: pointer; transition: color 0.2s, border-color 0.2s, background-color 0.2s;
}
.tab:hover { color: var(--paper); }
.tab[aria-selected="true"] { color: var(--ink); background: var(--paper); border-color: var(--paper); }
.example { display: grid; gap: 32px; }
.example[hidden] { display: none; }
.example-intro { display: grid; gap: 14px; align-content: start; }
.badge {
  justify-self: start; display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--f-mono); font-size: 0.75rem; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--signal); border: 1px solid rgba(255, 178, 63, 0.5); border-radius: 6px; padding: 4px 9px;
}
.example-intro h3 { font-size: var(--step-2); }
.example-intro p { color: var(--mute); }
.timeline { display: grid; position: relative; }
.timeline li { display: grid; grid-template-columns: 92px minmax(0, 1fr); gap: 16px; padding-block: 16px; border-bottom: 1px solid var(--line); }
.timeline li:first-child { border-top: 1px solid var(--line); }
.timeline time, .timeline .when { font-family: var(--f-mono); font-size: 0.8125rem; color: var(--mute); padding-top: 2px; }
.timeline strong { display: block; font-weight: 600; margin-bottom: 2px; }
.timeline span.txt { color: var(--mute); }
.timeline li.is-key strong { color: var(--signal); }
@media (min-width: 900px) {
  .example { grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); gap: 56px; }
  .timeline li { grid-template-columns: 120px minmax(0, 1fr); }
}

/* ---------- Ablauf ---------- */
.steps { display: grid; gap: 0; counter-reset: step; }
.step { position: relative; display: grid; gap: 10px; padding: 0 0 36px 52px; min-width: 0; }
.step::before {
  counter-increment: step; content: counter(step);
  position: absolute; left: 0; top: -4px; width: 34px; height: 34px; border-radius: 50%;
  display: grid; place-items: center; font-family: var(--f-mono); font-size: 0.875rem;
  border: 1.5px solid var(--line-strong); background: var(--ink); color: var(--paper);
}
.step:first-child::before { border-color: var(--signal); color: var(--signal); }
/* Schritte erscheinen beim Scrollen nacheinander (Klasse .js-reveal setzt main.js) */
.steps.js-reveal .step { opacity: 0; transform: translateY(32px); transition: opacity 0.6s var(--ease), transform 0.8s var(--ease); }
.steps.js-reveal .step.is-in { opacity: 1; transform: none; }
.steps.js-reveal .step::before { border-color: var(--line-strong); color: var(--paper); transition: border-color 0.4s 0.2s, color 0.4s 0.2s, box-shadow 0.6s 0.2s; }
.steps.js-reveal .step.is-in::before { border-color: var(--signal); color: var(--signal); box-shadow: 0 0 22px -4px rgba(255, 178, 63, 0.55); }
.steps.js-reveal .step::after { transform: scaleY(0); transform-origin: top; transition: transform 0.9s var(--ease) 0.35s; }
.steps.js-reveal .step.is-in::after { transform: none; }
.step::after { content: ""; position: absolute; left: 17px; top: 34px; bottom: 0; width: 1px; background: var(--line-strong); }
.step:last-child::after { display: none; }
.step h3 { font-size: var(--step-1); }
.step p { color: var(--mute); }
.step .dur { font-family: var(--f-mono); font-size: 0.75rem; color: var(--mute); letter-spacing: 0.04em; }
@media (min-width: 900px) {
  .steps { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 32px; }
  .step { padding: 56px 0 0 0; }
  .step::before { top: 0; }
  .step::after { left: 46px; right: -24px; top: 17px; bottom: auto; width: auto; height: 1px; }
  .steps.js-reveal .step::after { transform: scaleX(0); transform-origin: left; }
  .steps.js-reveal .step.is-in::after { transform: none; }
}

/* ---------- Demo ---------- */
.demo-grid { display: grid; gap: 40px; align-items: start; }
.demo-copy { display: grid; gap: 20px; min-width: 0; }
.demo-copy .ticks li { color: #D9D5CC; }
.demo-note { font-size: 0.9375rem; color: var(--mute); padding: 14px 16px; border: 1px dashed var(--line-strong); border-radius: var(--radius); }
@media (min-width: 960px) { .demo-grid { grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: 64px; } }

.chat {
  display: flex; flex-direction: column; width: 100%; max-width: 520px; justify-self: center;
  height: min(640px, 82vh); min-height: 480px;
  background: var(--ink-2); border: 1px solid var(--line-strong); border-radius: 20px; overflow: hidden;
  box-shadow: 0 30px 80px -30px rgba(0, 0, 0, 0.8);
}
.chat-head { display: flex; align-items: center; gap: 12px; padding: 14px 16px; border-bottom: 1px solid var(--line); background: var(--ink-3); }
.chat-avatar { width: 38px; height: 38px; border-radius: 50%; background: var(--paper); color: var(--ink); display: grid; place-items: center; flex: none; font-family: var(--f-display); font-weight: 700; }
.chat-title { display: grid; line-height: 1.25; min-width: 0; margin-right: auto; }
.chat-title b { font-size: 0.9875rem; font-weight: 600; }
.chat-title span { font-size: 0.8125rem; color: var(--mute); }
.chat-title span::before { content: ""; display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: #5BD18B; margin-right: 6px; vertical-align: 1px; }
.demo-badge { font-family: var(--f-mono); font-size: 0.6875rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink); background: var(--signal); border-radius: 5px; padding: 3px 7px; flex: none; }
.chat-reset { background: transparent; border: 1px solid var(--line-strong); color: var(--mute); border-radius: 8px; width: 36px; height: 36px; display: grid; place-items: center; cursor: pointer; flex: none; }
.chat-reset:hover { color: var(--paper); }
.chat-reset svg { width: 16px; height: 16px; }
.chat-log { flex: 1; overflow-y: auto; padding: 18px 16px; display: flex; flex-direction: column; gap: 10px; overscroll-behavior: contain; scroll-behavior: smooth; }
.msg { max-width: 86%; padding: 10px 14px; border-radius: 16px; font-size: 0.96rem; line-height: 1.45; white-space: pre-line; }
.msg.bot { align-self: flex-start; background: var(--ink-3); border: 1px solid var(--line); border-bottom-left-radius: 5px; }
.msg.user { align-self: flex-end; background: var(--paper); color: var(--ink); border-bottom-right-radius: 5px; }
.msg.summary { align-self: stretch; max-width: none; background: transparent; border: 1px dashed rgba(255, 178, 63, 0.55); border-radius: 12px; white-space: normal; }
.msg.summary .sum-title { font-family: var(--f-mono); font-size: 0.72rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--signal); margin-bottom: 8px; }
.msg.summary dl { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 4px 14px; margin: 0; font-size: 0.9rem; }
.msg.summary dt { color: var(--mute); }
.msg.summary dd { margin: 0; }
.msg-time { align-self: center; font-family: var(--f-mono); font-size: 0.7rem; color: var(--mute); padding-block: 4px; }
.typing { align-self: flex-start; display: inline-flex; gap: 4px; padding: 13px 14px; background: var(--ink-3); border: 1px solid var(--line); border-radius: 16px; border-bottom-left-radius: 5px; }
.typing i { width: 6px; height: 6px; border-radius: 50%; background: var(--mute); }
@media (prefers-reduced-motion: no-preference) {
  .typing i { animation: blink 1s infinite both; }
  .typing i:nth-child(2) { animation-delay: 0.15s; }
  .typing i:nth-child(3) { animation-delay: 0.3s; }
  .msg { animation: pop 0.25s var(--ease) both; }
}
@keyframes blink { 0%, 80%, 100% { opacity: 0.3; } 40% { opacity: 1; } }
@keyframes pop { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.chat-options { display: flex; flex-wrap: wrap; gap: 8px; padding: 0 16px 12px; }
.chat-options:empty { display: none; }
.opt {
  min-height: 40px; padding: 0.45em 0.95em; border-radius: 999px; border: 1px solid rgba(255, 178, 63, 0.55);
  background: transparent; color: var(--paper); font: 500 0.9rem/1.2 var(--f-body); cursor: pointer; text-align: left;
  transition: background-color 0.2s, color 0.2s;
}
.opt:hover { background: var(--signal); color: var(--ink); }
.opt.is-link { border-color: var(--line-strong); }
.chat-form { display: flex; gap: 8px; padding: 12px; border-top: 1px solid var(--line); background: var(--ink-3); }
.chat-form input {
  flex: 1; min-width: 0; min-height: 44px; padding: 0 14px; border-radius: 12px; border: 1px solid var(--line-strong);
  background: var(--ink); color: var(--paper); font: 400 1rem var(--f-body);
}
.chat-form input::placeholder { color: #807C74; }
.chat-form button { flex: none; width: 44px; height: 44px; border-radius: 12px; border: 0; background: var(--signal); color: var(--ink); display: grid; place-items: center; cursor: pointer; }
.chat-form button svg { width: 18px; height: 18px; }

/* ---------- Über mich ---------- */
.about { display: grid; gap: 40px; align-items: center; }
.portrait {
  position: relative; aspect-ratio: 4 / 5; max-width: 420px; width: 100%;
  border-radius: 18px; overflow: hidden; background: var(--ink-2); border: 1px solid var(--line);
}
.portrait img { width: 100%; height: 100%; object-fit: cover; }
.portrait-ph { position: absolute; inset: 14px; border: 1px dashed rgba(255, 178, 63, 0.5); border-radius: 12px; display: grid; place-items: center; text-align: center; padding: 20px; color: var(--mute); font-size: 0.9rem; }
.portrait-ph .ph { font-size: 1rem; }
.portrait-frame { position: absolute; inset: 6px; border: 1px solid var(--line); border-radius: 14px; pointer-events: none; }
.about-copy { display: grid; gap: 20px; min-width: 0; }
.about-copy p { color: #D9D5CC; max-width: 38rem; }
.about-copy h2 { font-size: var(--step-3); }
.facts { display: flex; flex-wrap: wrap; gap: 10px; }
.facts li { font-size: 0.9375rem; padding: 8px 12px; border: 1px solid var(--line-strong); border-radius: 8px; color: var(--paper); }
@media (min-width: 900px) { .about { grid-template-columns: minmax(0, 0.75fr) minmax(0, 1.25fr); gap: 72px; } .portrait { justify-self: start; } }

/* ---------- Kontakt ---------- */
.contact { display: grid; gap: 32px; max-width: 760px; }
.form { display: grid; gap: 16px; padding: clamp(20px, 4vw, 36px); background: var(--ink-2); border: 1px solid var(--line); border-radius: 18px; min-width: 0; }
.field { display: grid; gap: 6px; }
.field label { font-size: 0.9375rem; font-weight: 600; }
.field label small { font-weight: 400; color: var(--mute); }
.field input, .field textarea {
  width: 100%; min-height: 50px; padding: 12px 14px; border-radius: var(--radius);
  border: 1px solid var(--line-strong); background: var(--ink); color: var(--paper); font: 400 1rem/1.4 var(--f-body);
}
.field textarea { min-height: 128px; resize: vertical; }
.field input:focus, .field textarea:focus { outline: none; border-color: var(--signal); box-shadow: 0 0 0 3px var(--signal-soft); }
.field input[aria-invalid="true"], .field textarea[aria-invalid="true"] { border-color: #FF8A7A; }
.field .err, .form > .err { font-size: 0.85rem; color: #FF9F91; min-height: 0; }
.row-2 { display: grid; gap: 16px; }
@media (min-width: 640px) { .row-2 { grid-template-columns: 1fr 1fr; } }
.consent { display: grid; grid-template-columns: auto 1fr; gap: 12px; align-items: start; font-size: 0.9rem; color: var(--mute); }
.consent input { width: 20px; height: 20px; margin: 2px 0 0; accent-color: var(--signal); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-status { font-size: 0.95rem; padding: 12px 14px; border-radius: var(--radius); }
.form-status.ok { background: rgba(91, 209, 139, 0.1); border: 1px solid rgba(91, 209, 139, 0.4); }
.form-status.warn { background: var(--signal-soft); border: 1px solid rgba(255, 178, 63, 0.45); }
.form-status a { color: var(--signal); }
.channels { display: grid; gap: 14px; align-content: start; min-width: 0; }
.channel {
  display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 14px; align-items: center;
  padding: 16px 18px; border: 1px solid var(--line); border-radius: 14px; text-decoration: none; transition: border-color 0.2s;
}
a.channel:hover { border-color: var(--line-strong); }
.channel .ico { width: 44px; height: 44px; border-radius: 10px; display: grid; place-items: center; border: 1px solid var(--line-strong); }
.channel .ico svg { width: 20px; height: 20px; }
.channel.is-wa { border-color: rgba(255, 178, 63, 0.5); }
.channel.is-wa .ico { background: var(--signal); color: var(--ink); border-color: var(--signal); }
.channel b { display: block; font-weight: 600; }
.channel span { color: var(--mute); font-size: 0.9375rem; overflow-wrap: anywhere; }
.region { margin-top: 6px; padding: 18px; border-left: 2px solid var(--signal); color: var(--mute); font-size: 0.9375rem; }
.region b { color: var(--paper); }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--line); padding-block: 56px 40px; font-size: 0.9375rem; color: var(--mute); }
.footer-grid { display: grid; gap: 32px; }
.footer-grid h2 { font-family: var(--f-mono); font-size: 0.75rem; font-weight: 500; letter-spacing: 0.08em; text-transform: uppercase; color: var(--paper); margin-bottom: 12px; }
.footer-grid li + li { margin-top: 6px; }
.footer-grid a { text-decoration: none; }
.footer-grid a:hover { color: var(--paper); text-decoration: underline; }
.footer-brand { display: grid; gap: 14px; max-width: 22rem; }
.footer-bottom { margin-top: 48px; padding-top: 20px; border-top: 1px solid var(--line); display: flex; flex-wrap: wrap; gap: 8px 24px; justify-content: space-between; font-size: 0.85rem; }
@media (min-width: 760px) { .footer-grid { grid-template-columns: 2fr 1fr 1fr; } }

/* ---------- Rechtstexte ---------- */
.legal { padding-block: clamp(48px, 8vw, 96px); }
.legal-inner { max-width: 46rem; display: grid; gap: 18px; }
.legal h1 { font-size: var(--step-3); margin-bottom: 12px; }
.legal h2 { font-size: var(--step-1); margin-top: 22px; letter-spacing: -0.01em; }
.legal h3 { font-size: 1.05rem; margin-top: 8px; }
.legal p, .legal li { color: #D9D5CC; }
.legal ul { list-style: disc; padding-left: 1.2em; display: grid; gap: 4px; }
.legal a { color: var(--signal); }
.legal .note { padding: 14px 16px; border: 1px dashed rgba(255, 178, 63, 0.55); border-radius: var(--radius); color: var(--mute); font-size: 0.9375rem; }

/* ---------- Reduced Motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; scroll-behavior: auto !important; }
  [data-depth] { transform: none !important; }
}
