/* =========================================================================
   Kundenbewertung – öffentliches Design (Optik-Hühn-Layout)
   Barrierefrei (WCAG 2.2 AA). Marken-Farben pro Kunde via --brand/--brand-dark.
   ========================================================================= */

:root {
  --brand: #2d655e;
  --brand-dark: #204a45;

  --ink: #21343a;
  --ink-soft: #566a6b;
  --surface: #ffffff;
  --bg: #eef3f2;
  --row: #f1f5f4;
  --line: #e2eae8;
  --star-empty: #cdd8d6;
  --star-full: #f4b740;

  --ok: #2f7d5b;
  --danger: #c0392b;
  --focus: #1c6fb8;

  --radius: 22px;
  --radius-md: 16px;
  --radius-sm: 12px;
  --shadow: 0 30px 70px -34px rgba(20, 45, 45, 0.55);
  --shadow-sm: 0 10px 26px -14px rgba(20, 45, 45, 0.4);

  --space: clamp(1rem, 0.6rem + 1.8vw, 2rem);
  --maxw: 858px;
  --font: -apple-system, "system-ui", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.6;
  font-size: 1.0625rem;
  overflow-x: hidden;
}
/* Geschwungener, dezenter Hintergrund (hinter Karte/Formular sichtbar) */
body::after {
  content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 600 600'%3E%3Cg fill='none' stroke='%232d655e' stroke-width='1.5' opacity='0.16'%3E%3Ccircle cx='585' cy='300' r='120'/%3E%3Ccircle cx='585' cy='300' r='205'/%3E%3Ccircle cx='585' cy='300' r='290'/%3E%3Ccircle cx='585' cy='300' r='375'/%3E%3Ccircle cx='585' cy='300' r='460'/%3E%3C/g%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right -8vw center;
  background-size: 70vw auto;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--brand-dark); }

/* ---- A11y ---------------------------------------------------------------- */
.sr-only {
  position: absolute !important; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0);
  white-space: nowrap; border: 0;
}
.skip-link {
  position: absolute; left: 1rem; top: -3.5rem;
  background: var(--surface); color: var(--ink);
  padding: 0.6rem 1rem; border-radius: var(--radius-sm);
  box-shadow: var(--shadow-sm); z-index: 100; transition: top 120ms ease;
}
.skip-link:focus { top: 1rem; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 6px; }

/* ---- Header -------------------------------------------------------------- */
.site-header { background: var(--surface); }
.site-header .inner {
  max-width: 1180px; margin: 0 auto;
  padding: 1.1rem var(--space);
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
}
.brand { display: inline-flex; align-items: center; gap: 0.7rem; text-decoration: none; color: var(--ink); }
.brand img { max-height: var(--logo-h, 52px); width: auto; }
.brand__mark { color: var(--brand); flex: 0 0 auto; }
.brand__mark svg { width: calc(var(--logo-h, 52px) - 6px); height: calc(var(--logo-h, 52px) - 6px); }
.brand__name { display: flex; flex-direction: column; line-height: 1.1; }
.brand__name b { font-size: 1.5rem; font-weight: 700; letter-spacing: -0.01em; }
.brand__name small { font-size: 0.66rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-soft); }
.tagline {
  display: inline-flex; align-items: center; gap: 0.8rem;
  font-size: 0.74rem; letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--ink-soft); font-weight: 600;
}
.tagline::after { content: ""; width: 54px; height: 2px; background: currentColor; opacity: 0.5; }
@media (max-width: 640px) { .tagline { display: none; } }

/* ---- Hero ---------------------------------------------------------------- */
.hero {
  position: relative;
  color: #fff;
  padding: clamp(2.4rem, 3vw, 4rem) var(--space) clamp(4rem, 7vw, 6.5rem);
  background: linear-gradient(120deg, var(--brand-dark), var(--brand));
  isolation: isolate;
}
.hero--photo {
  background:
    linear-gradient(102deg, var(--brand-dark) 0%, var(--brand) 40%, rgba(36, 79, 75, 0.55) 62%, rgba(36, 79, 75, 0.15) 100%),
    var(--hero-img) right center / cover no-repeat;
}
.hero__inner {
  max-width: 1180px; margin: 0 auto;
  display: flex; align-items: center; gap: 2rem; justify-content: space-between;
}
.hero__text { max-width: 640px; }
.hero h1 {
  margin: 0;
  font-size: clamp(1.9rem, 1.1rem + 3.6vw, 3.3rem);
  font-weight: 800; line-height: 1.08; letter-spacing: -0.015em;
  text-wrap: balance;
}
.hero__sub {
  margin: 1.1rem 0 0; max-width: 34em;
  font-size: clamp(1rem, 0.95rem + 0.3vw, 1.15rem);
  color: rgba(255, 255, 255, 0.9);
}
.hero__badge { flex: 0 0 auto; }
.hero__badge-inner {
  width: 168px; height: 168px; border-radius: 50%;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 0.4rem;
  text-align: center; padding: 1rem;
  border: 1.5px solid rgba(255, 255, 255, 0.55);
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(2px);
  font-weight: 600; font-size: 1.05rem;
}
.hero__badge-inner svg { width: 34px; height: 34px; }
@media (max-width: 820px) { .hero__badge { display: none; } }

.hero__wave { position: absolute; left: 0; right: 0; bottom: -1px; width: 100%; height: 60px; display: block; }
.hero__wave path { fill: var(--bg); }

/* ---- Karte --------------------------------------------------------------- */
.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 var(--space); }
.card {
  background: var(--surface);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: clamp(1.5rem, 1rem + 2.4vw, 3rem);
  margin-top: clamp(-3.5rem, -6vw, -5rem);
  position: relative; z-index: 3;
}

.card-head { text-align: center; margin-bottom: 1.8rem; }
.card-head h2 {
  margin: 0; color: var(--brand);
  font-size: clamp(1.5rem, 1.1rem + 1.6vw, 2rem); font-weight: 800; letter-spacing: -0.01em;
}
.card-head p { margin: 0.4rem 0 0; color: var(--ink-soft); }
.card-head::after {
  content: ""; display: block; width: 60px; height: 3px; border-radius: 3px;
  background: var(--brand); margin: 1rem auto 0; opacity: 0.85;
}

/* ---- Fragen (graue Zeilen mit Icon) -------------------------------------- */
.question {
  display: flex; gap: 1rem; align-items: flex-start;
  background: var(--row);
  border-radius: var(--radius-md);
  padding: 1.1rem 1.25rem;
  margin-bottom: 1rem;
}
.question--error { outline: 2px solid var(--danger); outline-offset: -1px; }
.question__icon {
  flex: 0 0 auto;
  width: 52px; height: 52px; border-radius: 50%;
  display: grid; place-items: center;
  background: #e6eeec; color: var(--brand);
}
.question__icon svg { width: 26px; height: 26px; }
.question__body { flex: 1 1 auto; min-width: 0; }
.question__label { display: block; font-weight: 700; color: var(--ink); margin-bottom: 0.5rem; }
.req { color: var(--danger); }

/* Sterne = Radio-Gruppe (row-reverse: DOM 5..1, Anzeige 1..5, korrekte Füllung) */
.rating { display: inline-flex; flex-direction: row-reverse; gap: 0.15rem; }
.rating input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.rating label {
  cursor: pointer; color: var(--star-empty); line-height: 1;
  padding: 3px; border-radius: 8px;
  transition: color 100ms ease, transform 100ms ease;
}
.rating label svg { width: 34px; height: 34px; display: block; fill: currentColor; }
.rating input:checked ~ label { color: var(--star-full); }
@media (hover: hover) {
  .rating label:hover, .rating label:hover ~ label { color: var(--star-full); }
  .rating label:hover { transform: translateY(-1px); }
}
.rating input:focus-visible + label { outline: 3px solid var(--focus); outline-offset: 2px; }

.field-error { color: var(--danger); font-weight: 600; margin: 0.5rem 0 0; font-size: 0.98rem; }
.legend-hint { color: var(--ink-soft); font-size: 0.95rem; margin: 0.2rem 0 0; padding: 0 0.25rem; }

/* ---- Kommentar & Checkboxen ---------------------------------------------- */
.comment-field { display: flex; gap: 1rem; align-items: flex-start; margin: 1.6rem 0 1.2rem; }
.comment-field .question__icon { background: #e6eeec; }
.comment-field .comment-main { flex: 1 1 auto; }
.comment-field label { display: block; font-weight: 700; margin-bottom: 0.5rem; }
textarea, input[type="text"], input[type="email"], input[type="url"] {
  width: 100%; font: inherit; color: var(--ink);
  padding: 0.8rem 0.95rem; border: 1.5px solid var(--line);
  border-radius: var(--radius-sm); background: #fbfdfc;
}
textarea { min-height: 120px; resize: vertical; }
textarea:focus, input:focus { border-color: var(--brand); }

.checks { padding-left: calc(52px + 1rem); }
@media (max-width: 520px) { .checks { padding-left: 0; } }
.check { display: flex; gap: 0.7rem; align-items: flex-start; margin: 0.7rem 0; }
.check input[type="checkbox"] {
  width: 1.35rem; height: 1.35rem; margin-top: 0.12rem;
  accent-color: var(--brand); flex: 0 0 auto;
}
.check label { line-height: 1.5; }

/* Rückruf-Block (Name + Telefon) */
.callback {
  border: 1px solid var(--line); border-radius: var(--radius-md);
  padding: 1.1rem 1.25rem; margin: 1.4rem 0 1.2rem;
}
.callback legend { font-weight: 700; color: var(--ink); padding: 0 0.4rem; }
.callback__hint { margin: 0 0 0.9rem; color: var(--ink-soft); font-size: 0.96rem; }
.callback__grid { display: grid; gap: 1rem; }
@media (min-width: 560px) { .callback__grid { grid-template-columns: 1fr 1fr; } }
.callback__grid label { display: block; font-weight: 600; margin-bottom: 0.4rem; }

/* Datenschutz-Hinweis (ersetzt die Checkbox) */
.privacy-notice { margin: 1.2rem 0 0; color: var(--ink-soft); font-size: 0.9rem; line-height: 1.5; }
.privacy-notice a { color: var(--brand-dark); }

/* ---- Buttons ------------------------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
  font: inherit; font-weight: 700; cursor: pointer;
  padding: 0.9rem 1.5rem; border-radius: var(--radius-sm);
  border: 2px solid transparent; text-decoration: none;
  transition: background 120ms ease, transform 80ms ease, box-shadow 120ms ease;
  min-height: 48px;
}
.btn-primary {
  position: relative;
  background: linear-gradient(120deg, var(--brand), var(--brand-dark));
  color: #fff; width: 100%; font-size: 1.15rem;
  margin-top: 1.4rem; padding: 1.05rem 3rem; box-shadow: var(--shadow-sm);
}
.btn-primary svg { width: 22px; height: 22px; }
.btn-primary .chev { position: absolute; right: 1.3rem; opacity: 0.9; }
.btn-primary:hover { filter: brightness(1.06); }
.btn-primary:active { transform: translateY(1px); }

.btn-google { background: #fff; color: #1a1a1a; border-color: var(--line); }
.btn-google:hover { border-color: #b9c4c2; box-shadow: var(--shadow-sm); }
.btn-facebook { background: #1877f2; color: #fff; }
.btn-facebook:hover { background: #145dc0; }
.btn-ghost { background: #fff; border-color: var(--line); color: var(--ink); }
.btn-row { display: grid; gap: 0.8rem; margin-top: 1.4rem; }

/* ---- Trust-Badges -------------------------------------------------------- */
.trust {
  max-width: var(--maxw); margin: 2rem auto 0; padding: 0 var(--space);
  display: grid; gap: 1.4rem; grid-template-columns: 1fr;
}
@media (min-width: 640px) { .trust { grid-template-columns: repeat(3, 1fr); } }
.trust__item { display: flex; gap: 0.8rem; align-items: flex-start; }
.trust__icon { flex: 0 0 auto; color: var(--brand); }
.trust__icon svg { width: 30px; height: 30px; }
.trust__item h3 { margin: 0 0 0.15rem; font-size: 1rem; color: var(--ink); }
.trust__item p { margin: 0; font-size: 0.9rem; color: var(--ink-soft); line-height: 1.45; }

/* ---- Danke-Seiten -------------------------------------------------------- */
.lead { color: var(--ink-soft); font-size: 1.08rem; }
.thanks-icon { width: 64px; height: 64px; border-radius: 50%; display: grid; place-items: center; margin: 0 auto 1rem; }
.thanks-icon svg { width: 34px; height: 34px; }
.thanks-icon.top, .thanks-icon.ok { background: #eaf5ef; color: var(--ok); }
.thanks-icon.neg { background: #fdeeee; color: var(--danger); }
.card--center { text-align: center; }
.card--center .btn-row, .card--center .review-copy { text-align: left; }
.contact-box { margin-top: 1.8rem; padding-top: 1.4rem; border-top: 1px solid var(--line); color: var(--ink-soft); font-size: 0.98rem; }
.contact-box strong { color: var(--ink); }
.footnote { color: var(--ink-soft); font-size: 0.9rem; margin-top: 1rem; }

/* ---- Prose (Datenschutz) ------------------------------------------------- */
.prose { color: var(--ink); }
.prose h2 { margin-top: 1.8rem; }
.prose h3 { margin-top: 1.4rem; }
.prose a { color: var(--brand-dark); }

/* ---- Fehler-Zusammenfassung --------------------------------------------- */
.error-summary { background: #fdeeee; border: 1.5px solid #f2c9c9; border-radius: var(--radius-sm); padding: 1rem 1.2rem; margin-bottom: 1.4rem; }
.error-summary h2 { margin: 0 0 0.4rem; font-size: 1.05rem; color: var(--danger); }
.error-summary ul { margin: 0; padding-left: 1.2rem; }
.error-summary a { color: var(--danger); }

/* ---- Text-Übernahme (Top-Seite) ------------------------------------------ */
.review-copy { margin: 1.4rem 0 0.4rem; padding: 1.2rem 1.3rem; background: #f2f7f5; border: 1px solid var(--line); border-radius: var(--radius-sm); }
.review-copy__hint { margin: 0 0 0.9rem; color: var(--ink); }
.review-copy__box { background: #fff; border: 1px solid var(--line); border-left: 4px solid var(--brand); border-radius: 10px; padding: 0.9rem 1rem; margin-bottom: 0.9rem; }
.review-copy__text { margin: 0; color: var(--ink); font-style: italic; }
.review-copy__status { display: block; margin-top: 0.6rem; color: var(--ok); font-weight: 600; font-size: 0.95rem; }

/* ---- Fuß ----------------------------------------------------------------- */
.site-footer {
  max-width: 1180px; margin: 2.5rem auto 0; padding: 1.6rem var(--space) 3rem;
  border-top: 1px solid var(--line);
  display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap;
  color: var(--ink-soft); font-size: 0.9rem;
}
.site-footer nav { display: flex; gap: 1.2rem; flex-wrap: wrap; }
.site-footer a { color: var(--ink-soft); }

/* ---- Landing / 404 ------------------------------------------------------- */
.landing { max-width: 640px; margin: 12vh auto; padding: 0 var(--space); text-align: center; }
.landing h1 { color: var(--brand); }

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; scroll-behavior: auto !important; }
  .hero__badge-inner { backdrop-filter: none; }
}
