/* W.E.B. — Website Excellence Builders */
:root {
  --bg: oklch(0.985 0.004 95);
  --bg-2: oklch(0.96 0.006 95);
  --bg-3: oklch(0.93 0.008 95);
  --ink: oklch(0.2 0.015 260);
  --ink-2: oklch(0.35 0.015 260);
  --ink-3: oklch(0.45 0.014 260);
  --ink-4: oklch(0.75 0.01 260);
  --line: oklch(0.88 0.008 95);
  --line-2: oklch(0.82 0.01 95);
  --accent: oklch(0.78 0.19 138);
  --accent-ink: oklch(0.25 0.08 138);
  --accent-soft: oklch(0.94 0.06 138);
  --warn: oklch(0.7 0.16 50);
  --radius: 6px;
  --radius-lg: 14px;
  --maxw: 1280px;
  --pad: clamp(20px, 3vw, 48px);
  --font-display: "Inter Tight", "Inter", system-ui, sans-serif;
  --font-body: "Inter", system-ui, sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, monospace;
}

[data-theme="dark"] {
  --bg: oklch(0.18 0.012 260);
  --bg-2: oklch(0.22 0.013 260);
  --bg-3: oklch(0.26 0.014 260);
  --ink: oklch(0.97 0.005 95);
  --ink-2: oklch(0.85 0.008 95);
  --ink-3: oklch(0.78 0.01 95);
  --ink-4: oklch(0.45 0.01 95);
  --line: oklch(0.3 0.012 260);
  --line-2: oklch(0.38 0.014 260);
  --accent: oklch(0.82 0.2 138);
  --accent-ink: oklch(0.2 0.03 260);
  --accent-soft: oklch(0.3 0.08 138);
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--ink);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  transition: background 240ms ease, color 240ms ease;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

/* overflow-x nur auf Sections mit horizontalen Carousels/Animationen — NICHT auf body,
   weil das fixed-positioned Elemente (Chatbot rechts unten) clippen würde */
.quote-carousel { overflow-x: clip; }
.workflow { overflow-x: clip; }
section { overflow-x: clip; }
.container {
  max-width: var(--maxw);
  margin: 0 auto;
  padding-left: var(--pad);
  padding-right: var(--pad);
}

/* Type */
.display-xl, .display-l, .display-m, .display-s {
  font-family: var(--font-display);
  letter-spacing: -0.02em;
  line-height: 1.02;
  font-weight: 500;
  text-wrap: balance;
}
.display-xl { font-size: clamp(52px, 7.5vw, 112px); letter-spacing: -0.035em; font-weight: 450; }
.display-l { font-size: clamp(40px, 5.2vw, 72px); letter-spacing: -0.03em; }
.display-m { font-size: clamp(30px, 3.6vw, 50px); }
.display-s { font-size: clamp(22px, 2.4vw, 32px); line-height: 1.1; }
.eyebrow {
  font-family: var(--font-mono);
  font-size: 16px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--ink-2);
  font-weight: 600;
}
.eyebrow::before { content: "// "; color: oklch(0.6 0.22 138); font-weight: 700; }
[data-theme="dark"] .eyebrow::before { color: var(--accent); }
.lede {
  font-size: clamp(17px, 1.4vw, 20px);
  color: var(--ink-2);
  max-width: 62ch;
  line-height: 1.5;
  text-wrap: pretty;
}
.mono { font-family: var(--font-mono); }

/* Nav */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in oklab, var(--bg) 82%, transparent);
  backdrop-filter: saturate(1.4) blur(12px);
  -webkit-backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid var(--line);
}
.nav-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 68px;
}
.logo {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--font-display); font-weight: 600;
  font-size: 17px; letter-spacing: -0.01em;
}
.logo-mark {
  width: 48px; height: 48px;
  display: grid; place-items: center;
  background: transparent;
  position: relative;
}
.logo-mark img { width: 100%; height: 100%; object-fit: contain; display: block; }
.nav-links { display: flex; gap: 28px; align-items: center; }
.nav-links a { font-size: 14px; color: var(--ink-2); transition: color 160ms; position: relative; padding-bottom: 4px; }
.nav-links a:hover { color: var(--ink); }
.nav-links a.active { color: var(--ink); font-weight: 500; }
.nav-links a.active::after {
  content: '';
  position: absolute;
  left: 0; right: 0;
  bottom: -2px;
  height: 2px;
  background: oklch(0.6 0.22 138);
  border-radius: 2px;
}
[data-theme="dark"] .nav-links a.active::after { background: var(--accent); }
.nav-links a.nav-external {
  display: inline-flex; align-items: center; gap: 6px;
  color: var(--accent-ink); font-weight: 500;
  padding: 5px 11px; border: 1px solid color-mix(in oklab, var(--accent) 50%, transparent);
  border-radius: 999px; background: var(--accent-soft);
  transition: all 180ms;
}
.nav-links a.nav-external:hover {
  background: var(--accent); color: var(--accent-ink);
  border-color: var(--accent);
  transform: translateY(-1px);
}
[data-theme="dark"] .nav-links a.nav-external { color: var(--accent); background: transparent; }
[data-theme="dark"] .nav-links a.nav-external:hover { background: var(--accent); color: var(--bg); }
/* Brand-Link (Ovylon-KI-Marke) — Mono-Font + neutrale Outline,
   visuell von der grünen KI-Plattform-Pill abgesetzt. Macht klar:
   es ist eine eigene Marke, kein Plattform-Tool. */
.nav-links a.nav-brand {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.06em;
  color: var(--ink);
  background: transparent;
  border-color: var(--line-2);
}
.nav-links a.nav-brand:hover {
  background: var(--bg-2);
  border-color: var(--ink-3);
  color: var(--ink);
  transform: translateY(-1px);
}
[data-theme="dark"] .nav-links a.nav-brand { color: var(--ink); background: transparent; border-color: var(--line-2); }
[data-theme="dark"] .nav-links a.nav-brand:hover { background: var(--bg-2); color: var(--ink); }
.nav-cta { display: flex; align-items: center; gap: 10px; }
@media (max-width: 820px) {
  .nav-links { display: none; }
}

/* Hamburger-Button (nur mobile) */
.nav-burger {
  display: none;
  align-items: center; justify-content: center;
  width: 40px; height: 40px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  transition: background 160ms, border-color 160ms;
  padding: 0;
}
.nav-burger:hover { background: var(--bg-2); border-color: var(--ink-3); }
@media (max-width: 820px) { .nav-burger { display: inline-flex; } }

/* Mobile Drawer */
.nav-drawer {
  position: fixed;
  inset: 0;
  z-index: 100;
  pointer-events: none;
  visibility: hidden;
  transition: visibility 0s linear 280ms;
}
.nav-drawer.is-open {
  pointer-events: auto;
  visibility: visible;
  transition: visibility 0s;
}
.nav-drawer-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  opacity: 0;
  transition: opacity 240ms ease;
  cursor: pointer;
}
.nav-drawer.is-open .nav-drawer-backdrop { opacity: 1; }
.nav-drawer-panel {
  position: absolute;
  top: 0; right: 0; bottom: 0;
  width: min(88vw, 380px);
  background: var(--bg);
  border-left: 1px solid var(--line);
  transform: translateX(100%);
  transition: transform 280ms cubic-bezier(0.22, 0.61, 0.36, 1);
  display: flex;
  flex-direction: column;
  box-shadow: -20px 0 60px -20px rgba(0, 0, 0, 0.25);
  overflow-y: auto;
  overscroll-behavior: contain;
}
.nav-drawer.is-open .nav-drawer-panel { transform: translateX(0); }

.nav-drawer-head {
  display: flex; justify-content: space-between; align-items: center;
  padding: 18px 22px;
  border-bottom: 1px solid var(--line);
}
.nav-drawer-title { font-size: 11px; color: var(--ink-3); letter-spacing: 0.1em; }
.nav-drawer-close {
  width: 36px; height: 36px;
  display: grid; place-items: center;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  padding: 0;
  transition: background 150ms;
}
.nav-drawer-close:hover { background: var(--bg-2); }

.nav-drawer-links {
  display: flex; flex-direction: column;
  padding: 8px 0;
}
.nav-drawer-links a {
  padding: 16px 22px;
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 500;
  color: var(--ink);
  border-bottom: 1px solid var(--line);
  display: flex; align-items: center; gap: 8px;
  transition: background 150ms, color 150ms;
}
.nav-drawer-links a:hover { background: var(--bg-2); }
.nav-drawer-links a.active {
  color: oklch(0.6 0.22 138);
  background: color-mix(in oklab, var(--accent) 8%, transparent);
  border-left: 3px solid oklch(0.6 0.22 138);
  padding-left: 19px;
}
[data-theme="dark"] .nav-drawer-links a.active { color: var(--accent); border-left-color: var(--accent); }
.nav-drawer-links a svg { color: var(--ink-3); }

.nav-drawer-footer {
  padding: 20px 22px;
  margin-top: auto;
  border-top: 1px solid var(--line);
  display: flex; flex-direction: column; gap: 16px;
  background: var(--bg-2);
}
.nav-drawer-contact {
  font-size: 12px;
  color: var(--ink-3);
  display: flex; flex-direction: column; gap: 4px;
}
.nav-drawer-contact a { color: var(--ink-2); transition: color 150ms; }
.nav-drawer-contact a:hover { color: var(--ink); }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 11px 18px; border-radius: 999px;
  font-size: 14px; font-weight: 500;
  border: 1px solid transparent;
  cursor: pointer; transition: all 160ms ease;
  font-family: var(--font-body);
  white-space: nowrap;
}
.btn-primary {
  background: var(--ink); color: var(--bg);
}
.btn-primary:hover { transform: translateY(-1px); }
.btn-accent {
  background: var(--accent); color: var(--accent-ink);
  font-weight: 600;
}
.btn-accent:hover { transform: translateY(-1px); filter: brightness(1.03); }
.btn-ghost {
  background: transparent; color: var(--ink);
  border-color: var(--line-2);
}
.btn-ghost:hover { background: var(--bg-2); border-color: var(--ink-3); }
.btn .arrow { transition: transform 200ms; }
.btn:hover .arrow { transform: translateX(3px); }

/* Theme toggle */
.theme-toggle {
  width: 36px; height: 36px; border-radius: 999px;
  border: 1px solid var(--line-2);
  background: transparent; color: var(--ink);
  cursor: pointer; display: grid; place-items: center;
}
.theme-toggle:hover { background: var(--bg-2); }

/* Sections */
section { padding: clamp(24px, 3vw, 48px) 0; }
.section-head {
  display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  gap: clamp(32px, 5vw, 80px);
  margin-bottom: clamp(28px, 4vw, 48px);
  align-items: center;
  grid-auto-rows: minmax(0, auto);
  align-items: start;
}
.section-head > .lede { max-width: 48ch; align-self: center; }
.section-head .eyebrow-wrap { display: flex; flex-direction: column; gap: 12px; align-self: center; }
@media (max-width: 820px) {
  .section-head { grid-template-columns: 1fr; gap: 20px; align-items: start; }
  .section-head > .lede, .section-head .eyebrow-wrap { align-self: start; }
}
.section-head h2 { text-wrap: balance; }

/* Grid helpers */
.grid { display: grid; gap: 24px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 900px) {
  .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 600px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
}

/* Cards */
.card {
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 28px;
  transition: border-color 200ms, transform 200ms;
}
.card:hover { border-color: var(--ink-3); }
.card-tight { padding: 20px; }

/* Tags / pills */
.pill {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 5px 10px;
  border: 1px solid var(--line-2);
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--ink-3);
  background: var(--bg);
}
.pill-dot { width: 6px; height: 6px; border-radius: 999px; background: var(--accent); }
.pill-live .pill-dot { animation: pulse 1.6s ease-in-out infinite; }
.pill-afterlive {
  background: var(--bg);
  border-color: oklch(0.6 0.22 138);
  color: oklch(0.6 0.22 138);
  font-weight: 600;
}
[data-theme="dark"] .pill-afterlive {
  background: transparent;
  border-color: var(--accent);
  color: var(--accent);
}
.pill-afterlive .pill-dot { background: oklch(0.6 0.22 138); }
[data-theme="dark"] .pill-afterlive .pill-dot { background: var(--accent); }
@keyframes pulse {
  0%, 100% { box-shadow: 0 0 0 0 color-mix(in oklab, var(--accent) 50%, transparent); }
  50% { box-shadow: 0 0 0 6px color-mix(in oklab, var(--accent) 0%, transparent); }
}

/* Hairline helpers */
.hr { height: 1px; background: var(--line); border: 0; margin: 0; }
.hrule { border-top: 1px solid var(--line); padding-top: 20px; }

/* Footer */
.footer {
  border-top: 1px solid var(--line);
  padding: 64px 0 40px;
  color: var(--ink-2);
  font-size: 14px;
}
.footer-grid {
  display: grid; grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
}
@media (max-width: 820px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
.footer h4 {
  font-family: var(--font-mono); font-size: 11px; text-transform: uppercase;
  letter-spacing: 0.08em; color: var(--ink-3); margin: 0 0 18px;
  font-weight: 500;
}
.footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.footer a:hover { color: oklch(0.6 0.22 138); }
[data-theme="dark"] .footer a:hover { color: var(--accent); }
.footer-bottom {
  display: flex; justify-content: space-between; align-items: center;
  margin-top: 56px; padding-top: 24px; border-top: 1px solid var(--line);
  font-family: var(--font-mono); font-size: 12px; color: var(--ink-3);
  flex-wrap: wrap; gap: 12px;
}

/* Utilities */
.flex { display: flex; }
.flex-wrap { flex-wrap: wrap; }
.items-center { align-items: center; }
.items-start { align-items: flex-start; }
.justify-between { justify-content: space-between; }
.gap-2 { gap: 8px; }
.gap-3 { gap: 12px; }
.gap-4 { gap: 16px; }
.gap-6 { gap: 24px; }
.mt-2 { margin-top: 8px; }
.mt-4 { margin-top: 16px; }
.mt-6 { margin-top: 24px; }
.mt-8 { margin-top: 32px; }
.mt-12 { margin-top: 48px; }
.text-muted { color: var(--ink-3); }
.text-strong { color: var(--ink); }
.text-accent { color: var(--accent-ink); }
[data-theme="dark"] .text-accent { color: var(--accent); }
.text-center { text-align: center; }
.hidden-mobile { }
@media (max-width: 820px) { .hidden-mobile { display: none; } }

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

/* Scroll reveal */
.reveal { opacity: 0; transform: translateY(16px); transition: opacity 700ms ease, transform 700ms ease; transition-delay: var(--reveal-delay, 0ms); }
.reveal.in { opacity: 1; transform: none; }

/* Scroll-Progress-Bar */
.scroll-progress {
  position: fixed;
  top: 0; left: 0;
  height: 2px;
  width: 0;
  background: oklch(0.6 0.22 138);
  z-index: 200;
  transition: width 80ms linear;
  pointer-events: none;
  box-shadow: 0 0 6px color-mix(in oklab, var(--accent) 60%, transparent);
}
[data-theme="dark"] .scroll-progress { background: var(--accent); }

/* Grüner Suffix bei animierten Zahlen (+, %, ms) */
.count-suffix { color: oklch(0.6 0.22 138); font-weight: inherit; }
[data-theme="dark"] .count-suffix { color: var(--accent); }

/* ---- Legal pages ---- */
.legal-grid {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: clamp(32px, 5vw, 80px);
  align-items: start;
}
@media (max-width: 900px) {
  .legal-grid { grid-template-columns: 1fr; gap: 24px; }
}
.legal-toc {
  position: sticky;
  top: 92px;
  font-size: 13px;
  line-height: 1.7;
  border-left: 1px solid var(--line);
  padding-left: 16px;
}
@media (max-width: 900px) {
  .legal-toc {
    position: static;
    border-left: 0;
    border-top: 1px solid var(--line);
    padding: 16px 0 0;
  }
}
.legal-toc ul { list-style: none; margin: 0; padding: 0; }
.legal-toc li { margin: 0; }
.legal-toc a {
  color: var(--ink-3);
  text-decoration: none;
  display: block;
  padding: 3px 0;
  border-bottom: 1px dashed transparent;
  transition: color 160ms ease, border-color 160ms ease;
}
.legal-toc a:hover {
  color: var(--ink);
  border-bottom-color: var(--line-2);
}

.legal {
  max-width: 68ch;
  font-size: 15.5px;
  line-height: 1.72;
  color: var(--ink-2);
}
.legal h2 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 22px;
  letter-spacing: -0.01em;
  color: var(--ink);
  margin: 44px 0 10px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
  scroll-margin-top: 96px;
}
.legal h2:first-of-type { margin-top: 8px; padding-top: 0; border-top: 0; }
.legal p { margin: 0 0 14px; }
.legal ul {
  margin: 6px 0 18px;
  padding-left: 20px;
}
.legal ul li { margin: 4px 0; }
.legal a {
  color: var(--ink);
  text-decoration: underline;
  text-decoration-color: var(--line-2);
  text-underline-offset: 3px;
  text-decoration-thickness: 1px;
}
.legal a:hover {
  text-decoration-color: var(--accent);
  color: var(--accent-ink);
}
[data-theme="dark"] .legal a:hover { color: var(--accent); }
.legal strong { color: var(--ink); font-weight: 550; }

.legal .kv {
  display: grid;
  grid-template-columns: 180px 1fr;
  row-gap: 6px;
  column-gap: 16px;
  margin: 6px 0 18px;
  padding: 16px 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--bg-2);
}
.legal .kv dt {
  color: var(--ink-3);
  font-size: 13px;
  letter-spacing: 0.01em;
}
.legal .kv dd { margin: 0; color: var(--ink); }
@media (max-width: 560px) {
  .legal .kv { grid-template-columns: 1fr; padding: 14px; }
  .legal .kv dt { margin-top: 4px; }
}

.legal-meta {
  margin-top: 48px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  color: var(--ink-3);
  font-size: 11px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

/* ==========================================================================
   Cookie-/Analytics-Info-Banner
   ========================================================================== */
.cookie-banner {
  position: fixed;
  left: 50%;
  bottom: 20px;
  transform: translateX(-50%) translateY(16px);
  z-index: 9999;
  max-width: min(640px, calc(100vw - 24px));
  width: 100%;
  background: var(--bg);
  border: 1px solid var(--line-2);
  border-radius: 14px;
  box-shadow: 0 12px 40px -12px rgba(0, 0, 0, 0.22), 0 2px 8px -2px rgba(0, 0, 0, 0.08);
  opacity: 0;
  pointer-events: none;
  transition: opacity 240ms ease, transform 240ms ease;
}
.cookie-banner.is-open {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
  pointer-events: auto;
}
.cookie-banner-inner {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
}
.cookie-banner-icon {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent-ink);
}
.cookie-banner-text {
  flex: 1 1 auto;
  font-size: 13px;
  line-height: 1.5;
  color: var(--ink-2);
}
.cookie-banner-text strong {
  color: var(--ink);
  font-weight: 600;
}
.cookie-banner-text em {
  font-style: normal;
  color: var(--ink);
}
.cookie-banner-text a {
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.cookie-banner-close {
  flex: 0 0 auto;
  padding: 9px 16px;
  font-size: 13px;
}
@media (max-width: 640px) {
  .cookie-banner {
    left: 12px;
    right: 12px;
    bottom: 12px;
    transform: translateY(16px);
    max-width: none;
  }
  .cookie-banner.is-open {
    transform: translateY(0);
  }
  .cookie-banner-inner {
    flex-wrap: wrap;
    gap: 10px;
  }
  .cookie-banner-text {
    flex-basis: 100%;
    order: 2;
  }
  .cookie-banner-icon {
    order: 1;
  }
  .cookie-banner-close {
    order: 3;
    margin-left: auto;
  }
}
