/* ==========================================================================
   WME Design System
   Quelle: Markenhandbuch Webservices Michael Eberl, v1.3 — Juni 2026
   Hinweis: Dieses Stylesheet ist die EINZIGE Quelle für Design-Entscheidungen.
   Inhalte werden über /data/*.json + Templates gefüllt, nicht hier.
   ========================================================================== */

/* --------------------------------------------------------------------
   1. Design Tokens
   -------------------------------------------------------------------- */
:root {
  /* Farben — exakt aus Markenhandbuch S.07 */
  --color-navy:        #0B2038; /* Hauptfarbe, Text & Gerüst */
  --color-web-blau:    #38B6FF; /* Sparte Webdesign */
  --color-grafik-gruen:#20EB90; /* Sparte Grafik Design */
  --color-automation-pink: #FF66C4; /* Sparte Automation & KI */
  --color-nebelgrau:   #F4F5F7; /* Flächen & Karten */
  --color-papierweiss: #FFFFFF; /* Hintergrund */

  /* Abgeleitete Werte (nicht im Handbuch explizit, aber für Kontrast/States nötig) */
  --color-navy-soft:   #1C334D; /* Navy für Hover-States auf dunklem Grund */
  --color-border:      #E2E5EA; /* dezente Trennlinien auf Nebelgrau/Weiß */
  --color-text-muted:  #5C6B7A; /* gedämpfter Text auf Hell, AA-konform zu Navy */

  /* Typografie — Montserrat, S.08
     Schriftdateien liegen bereits auf dem eigenen Server.
     Pfade unten in @font-face an die tatsächliche Ablage anpassen. */
  --font-family-base: "Montserrat", -apple-system, "Segoe UI", sans-serif;

  --fw-regular:   400; /* Fließtext */
  --fw-medium:    500; /* Lead, Labels */
  --fw-semibold:  600; /* Subheads */
  --fw-bold:      700; /* Headlines */
  --fw-extrabold: 800; /* Display */

  /* Type Scale gemäß Handbuch S.08 (Desktop-Basiswerte) */
  --fs-display: 46px;  --lh-display: 48px; --ls-display: -0.02em;
  --fs-h1:      31px;  --lh-h1:      35px;
  --fs-h2:      20px;  --lh-h2:      26px;
  --fs-lead:    15px;  --lh-lead:    24px;
  --fs-body:    15px;  --lh-body:    23px; /* Handbuch: 14–16px, 15px als Mitte gewählt */
  --fs-label:   11px;  --ls-label:   2.4px;

  /* Radien gemäß Handbuch S.11: 10–14px */
  --radius-sm: 10px;
  --radius-md: 14px;

  /* Abstände — 8px-Grid */
  --space-1: 8px;
  --space-2: 16px;
  --space-3: 24px;
  --space-4: 32px;
  --space-5: 48px;
  --space-6: 64px;
  --space-7: 96px;

  /* Layout */
  --container-max: 1140px;
  --container-pad: var(--space-2);
}

/* --------------------------------------------------------------------
   2. Fonts — selbst gehostet, kein Google Fonts (siehe Anforderung)
   Dateien müssen unter /assets/fonts/ liegen. WOFF2 reicht für alle
   aktuellen Browser; WOFF-Fallback nur ergänzen falls nötig.
   -------------------------------------------------------------------- */
@font-face {
  font-family: "Montserrat";
  src: url("../fonts/montserrat-v31-latin-regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Montserrat";
  src: url("../fonts/montserrat-v31-latin-500.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Montserrat";
  src: url("../fonts/montserrat-v31-latin-600.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Montserrat";
  src: url("../fonts/montserrat-v31-latin-700.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Montserrat";
  src: url("../fonts/montserrat-v31-latin-800.woff2") format("woff2");
  font-weight: 800;
  font-style: normal;
  font-display: swap;
}

/* --------------------------------------------------------------------
   3. Reset & Basis
   -------------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

body {
  margin: 0;
  font-family: var(--font-family-base);
  font-weight: var(--fw-regular);
  font-size: var(--fs-body);
  line-height: var(--lh-body);
  color: var(--color-navy);
  background: var(--color-papierweiss);
  -webkit-font-smoothing: antialiased;
}

img, svg { display: block; max-width: 100%; height: auto; }

a { color: inherit; }

/* --------------------------------------------------------------------
   4. Typografie-Hierarchie (Handbuch S.08)
   -------------------------------------------------------------------- */
.display {
  font-size: var(--fs-display);
  line-height: var(--lh-display);
  letter-spacing: var(--ls-display);
  font-weight: var(--fw-extrabold);
  margin: 0;
}

h1, .h1 {
  font-size: var(--fs-h1);
  line-height: var(--lh-h1);
  font-weight: var(--fw-bold);
  margin: 0 0 var(--space-2) 0;
}

h2, .h2 {
  font-size: var(--fs-h2);
  line-height: var(--lh-h2);
  font-weight: var(--fw-semibold);
  margin: 0 0 var(--space-1) 0;
}

.lead {
  font-size: var(--fs-lead);
  line-height: var(--lh-lead);
  font-weight: var(--fw-medium);
  margin: 0 0 var(--space-3) 0;
}

p, .body-text {
  font-size: var(--fs-body);
  line-height: var(--lh-body);
  font-weight: var(--fw-regular);
  margin: 0 0 var(--space-2) 0;
  color: var(--color-text-muted);
}

.label, .eyebrow {
  display: block;
  font-size: var(--fs-label);
  letter-spacing: var(--ls-label);
  font-weight: var(--fw-bold);
  text-transform: uppercase;
  margin: 0 0 var(--space-1) 0;
}

/* Sparten-Farbe als Eyebrow-Akzent (Akzent, nicht Hauptfarbe — S.04/07) */
.eyebrow--web        { color: var(--color-web-blau); }
.eyebrow--grafik      { color: var(--color-grafik-gruen); }
.eyebrow--automation  { color: var(--color-automation-pink); }

/* --------------------------------------------------------------------
   5. Layout-Hilfen
   -------------------------------------------------------------------- */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding-left: var(--container-pad);
  padding-right: var(--container-pad);
}

.section {
  padding-top: var(--space-6);
  padding-bottom: var(--space-6);
}

.section--muted { background: var(--color-nebelgrau); }
.section--navy  { background: var(--color-navy); color: var(--color-papierweiss); }
.section--navy p { color: rgba(255,255,255,0.72); }
.section--navy .h1, .section--navy .display { color: var(--color-papierweiss); }

.grid {
  display: grid;
  gap: var(--space-3);
}

@media (min-width: 768px) {
  .grid--2 { grid-template-columns: repeat(2, 1fr); }
  .grid--3 { grid-template-columns: repeat(3, 1fr); }
}

/* --------------------------------------------------------------------
   6. Buttons (Handbuch S.11)
   Primär = Navy · Sparten-Farbe für sparten-spezifische Aktion ·
   Grün = WhatsApp/Direktkontakt · Ghost = sekundär
   -------------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-1);
  font-family: var(--font-family-base);
  font-weight: var(--fw-semibold);
  font-size: var(--fs-body);
  line-height: 1;
  padding: 14px 24px;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.btn:focus-visible {
  outline: 2px solid var(--color-navy);
  outline-offset: 2px;
}

/* Primär — Hauptaktion */
.btn--primary {
  background: var(--color-navy);
  color: var(--color-papierweiss);
}
.btn--primary:hover { background: var(--color-navy-soft); }

/* WhatsApp / Direktkontakt — immer Grafik Grün laut Handbuch S.11 */
.btn--whatsapp {
  background: var(--color-grafik-gruen);
  color: var(--color-navy);
}
.btn--whatsapp:hover { background: #1bd183; }

/* Sparten-Buttons — Akzentfarbe je Bereich */
.btn--web       { background: var(--color-web-blau);       color: var(--color-navy); }
.btn--grafik     { background: var(--color-grafik-gruen);    color: var(--color-navy); }
.btn--automation { background: var(--color-automation-pink); color: var(--color-navy); }

/* Sekundär / Ghost */
.btn--ghost {
  background: transparent;
  color: var(--color-navy);
  border-color: var(--color-navy);
}
.btn--ghost:hover { background: var(--color-navy); color: var(--color-papierweiss); }

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  align-items: center;
}

/* Click-Trigger / Einwand-Vorwegnahme (Handbuch S.10) */
.click-trigger {
  display: inline-flex;
  align-items: center;
  font-size: 13px;
  font-weight: var(--fw-medium);
  color: var(--color-text-muted);
  margin-top: var(--space-1);
}

/* --------------------------------------------------------------------
   7. Karten / Leistungs-Kacheln
   -------------------------------------------------------------------- */
.card {
  background: var(--color-papierweiss);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: var(--space-3);
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.card--link:hover {
  transform: translateY(-4px);
  border-color: var(--color-web-blau);
  box-shadow: 0 8px 24px rgba(11, 32, 56, 0.08);
}

.card-link-text {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--color-navy);
  font-weight: var(--fw-semibold);
  font-size: 14px;
  margin-top: var(--space-2);
}
.card--link:hover .card-link-text { color: var(--color-web-blau); }
.card-link-text svg { transition: transform 0.2s ease; }
.card--link:hover .card-link-text svg { transform: translateX(3px); }

/* Phasen-Gruppen (Wachstumsreise) */
.phase-group { margin-bottom: var(--space-5); }
.phase-group:last-child { margin-bottom: 0; }
.phase-label {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  margin-bottom: var(--space-2);
}
.phase-label .phase-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px; height: 28px;
  border-radius: 50%;
  background: var(--color-navy);
  color: #fff;
  font-weight: var(--fw-bold);
  font-size: 13px;
  flex-shrink: 0;
}
.phase-label .phase-text {
  font-weight: var(--fw-semibold);
  font-size: 14px;
  color: var(--color-text-muted);
}
.phase-label .phase-text strong { color: var(--color-navy); }

.card--muted {
  background: var(--color-nebelgrau);
  border: none;
}

/* Sparten-Tag (Handbuch S.06/12) */
.tag {
  display: inline-block;
  font-size: var(--fs-label);
  letter-spacing: var(--ls-label);
  font-weight: var(--fw-bold);
  text-transform: uppercase;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  color: var(--color-navy);
}
.tag--web        { background: var(--color-web-blau); }
.tag--grafik      { background: var(--color-grafik-gruen); }
.tag--automation  { background: var(--color-automation-pink); }

/* --------------------------------------------------------------------
   7b. Testimonials & Referenz-Galerie
   -------------------------------------------------------------------- */
.testimonial {
  background: var(--color-papierweiss);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: var(--space-3);
  display: flex;
  flex-direction: column;
  height: 100%;
}
.testimonial p {
  color: var(--color-navy);
  flex-grow: 1;
  font-style: italic;
}
.testimonial cite {
  display: block;
  font-style: normal;
  font-weight: var(--fw-semibold);
  font-size: 14px;
  margin-top: var(--space-2);
}
.testimonial cite span {
  display: block;
  font-weight: var(--fw-regular);
  color: var(--color-text-muted);
  font-size: 13px;
}

/* Referenz-Galerie: Karten nur visuell, keine Links */
.gallery-card {
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--color-border);
  background: var(--color-papierweiss);
}
.gallery-card__image {
  aspect-ratio: 4 / 3;
  background: var(--color-nebelgrau);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-text-muted);
  font-size: 13px;
  text-align: center;
  padding: var(--space-2);
}
.gallery-card__image img {
  width: 100%; height: 100%; object-fit: cover;
}
.gallery-card__caption {
  padding: var(--space-2) var(--space-3);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
}
.gallery-card__caption--stacked {
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
}
.gallery-card__caption span:last-child {
  font-size: 14px;
  font-weight: var(--fw-medium);
  color: var(--color-text-muted);
}

/* Numerierte Problem-Liste */
.numbered-list {
  list-style: none;
  padding: 0;
  margin: 0 0 var(--space-2) 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}
.numbered-list li {
  display: flex;
  align-items: flex-start;
  gap: var(--space-2);
  color: var(--color-text-muted);
}
.numbered-list .num {
  flex-shrink: 0;
  width: 24px; height: 24px;
  border-radius: 50%;
  background: var(--color-nebelgrau);
  color: var(--color-navy);
  display: flex; align-items: center; justify-content: center;
  font-size: 12px; font-weight: var(--fw-bold);
}

/* Timeline (Über uns) */
.timeline {
  display: flex;
  flex-direction: column;
  gap: 0;
}
.timeline-item {
  display: grid;
  grid-template-columns: 64px 1fr;
  gap: var(--space-3);
  padding: var(--space-3) 0;
  border-bottom: 1px solid var(--color-border);
}
.timeline-item:last-child { border-bottom: none; }
.timeline-item .jahr {
  font-size: 22px;
  font-weight: var(--fw-extrabold);
  line-height: 1.3;
  color: var(--color-web-blau);
  white-space: nowrap;
}

@media (min-width: 480px) {
  .timeline-item { grid-template-columns: 80px 1fr; }
  .timeline-item .jahr { font-size: 28px; }
}

/* Prozess-Schritte (z.B. Kontakt-Ablauf) */
.step-card {
  text-align: center;
}
.step-card .step-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px; height: 40px;
  border-radius: 50%;
  background: var(--color-navy);
  color: #fff;
  font-weight: var(--fw-extrabold);
  font-size: 16px;
  margin-bottom: var(--space-2);
}

/* Case-Study Kennzahlen */
.stat-box {
  background: var(--color-papierweiss);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: var(--space-3);
  text-align: center;
}
.stat-box .stat-value {
  font-size: 28px;
  font-weight: var(--fw-extrabold);
  color: var(--color-navy);
  line-height: 1.2;
}
.stat-box .stat-label {
  font-size: 13px;
  color: var(--color-text-muted);
  font-weight: var(--fw-medium);
  text-transform: none;
  letter-spacing: normal;
  display: block;
  margin-top: 4px;
}

/* Feature-Liste mit Checkmarks */
.feature-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}
.feature-list li {
  display: flex;
  align-items: flex-start;
  gap: var(--space-2);
}
.feature-list svg {
  flex-shrink: 0;
  margin-top: 3px;
  color: var(--color-grafik-gruen);
}

/* --------------------------------------------------------------------
   8. Header / Navigation
   -------------------------------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--color-papierweiss);
  border-bottom: 1px solid var(--color-border);
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: var(--space-2);
  padding-bottom: var(--space-2);
}

.logo {
  font-size: 22px;
  font-weight: var(--fw-extrabold);
  text-decoration: none;
  color: var(--color-navy);
  letter-spacing: -0.01em;
}
/* "web" in Pink, Rest Navy — gemäß Wortmarke S.05 */
.logo span { color: var(--color-automation-pink); }

.main-nav {
  list-style: none;
  margin: 0;
  padding: 0;
}

.main-nav a {
  text-decoration: none;
  font-weight: var(--fw-medium);
  font-size: 14px;
  color: var(--color-navy);
}
.main-nav a:hover { color: var(--color-web-blau); }

/* Fix: .main-nav a (spezifischer) überschreibt sonst .btn--primary's weiße Schrift */
.main-nav a.btn--primary,
.main-nav a.btn--primary:hover { color: var(--color-papierweiss); }

/* Mobile: Nav als Dropdown-Panel, standardmäßig versteckt */
@media (max-width: 959px) {
  .main-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--color-papierweiss);
    border-bottom: 1px solid var(--color-border);
    padding: var(--space-2) var(--container-pad);
    flex-direction: column;
    gap: var(--space-2);
  }
  .main-nav.is-open { display: flex; }
  .main-nav li { width: 100%; }
  .main-nav a { display: block; padding: var(--space-1) 0; }
  .main-nav .btn { width: 100%; }
}

@media (min-width: 960px) {
  .main-nav { display: flex; align-items: center; gap: var(--space-4); }
  .nav-toggle { display: none; }
}

.nav-toggle {
  background: none;
  border: none;
  cursor: pointer;
  padding: var(--space-1);
  color: var(--color-navy);
}

.site-header__inner { position: relative; }

/* --------------------------------------------------------------------
   9. Footer (Handbuch S.13 — Finale Conversion-Möglichkeit)
   -------------------------------------------------------------------- */
.site-footer {
  background: var(--color-navy);
  color: rgba(255,255,255,0.72);
  padding-top: var(--space-6);
  padding-bottom: var(--space-4);
}

.site-footer a { color: var(--color-papierweiss); text-decoration: none; }
.site-footer a:hover { color: var(--color-web-blau); }

.footer-grid {
  display: grid;
  gap: var(--space-4);
  margin-bottom: var(--space-5);
}

@media (min-width: 768px) {
  .footer-grid { grid-template-columns: 2fr 1fr 1fr 1fr; }
}

.footer-grid h3 {
  font-size: var(--fs-label);
  letter-spacing: var(--ls-label);
  text-transform: uppercase;
  color: var(--color-papierweiss);
  margin: 0 0 var(--space-2) 0;
}

.footer-grid ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.12);
  padding-top: var(--space-3);
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  justify-content: space-between;
  font-size: 13px;
}

/* --------------------------------------------------------------------
   10. Utilities
   -------------------------------------------------------------------- */
.text-center { text-align: center; }
.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }
.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* Vorschau-Banner (Admin-Panel Preview-Modus) */
.preview-bar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 200;
  background: var(--color-automation-pink);
  color: #fff; text-align: center; padding: 8px 12px;
  font-weight: 700; font-size: 13px;
}
