/* =========================
   Zeman IT – Global Styles
   ========================= */

@media (prefers-color-scheme: light) {
  :root {
    color-scheme: light;
  }
  html {
    --theme: light;
  }
}

@media (prefers-color-scheme: dark) {
  :root {
    color-scheme: dark;
  }
  html {
    --theme: dark;
  }
}

/* ---------- Tokens ---------- */
:root {
  --bg: #0f172a;
  --panel: #111827;
  --text: #e5e7eb;
  --muted: #9ca3af;
  --brand: #7c3aed;
  --brand-contrast: #f5f3ff;
  --accent: #22c55e;
  --danger: #ef4444;
  --ring: rgba(124, 58, 237, 0.35);
  --max: 1100px;
  --header-h: 56px;
}
html[data-theme="light"] {
  --bg: #f8fafc;
  --panel: #fff;
  --text: #0f172a;
  --muted: #475569;
  --brand: #7c3aed;
  --brand-contrast: #fff;
  --ring: rgba(124, 58, 237, 0.28);
}

/* ---------- Base ---------- */
* {
  box-sizing: border-box;
}
html,
body {
  height: 100%;
}
body {
  margin: 0;
  font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto,
    Helvetica, Arial;
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
}
a {
  color: var(--brand);
  text-decoration: none;
}
a:hover {
  opacity: 0.9;
}
.container {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 28px;
}
.container h2 {
  margin-top: 10px;
}

/* Fixed gradient background */
.bg-layer {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background: radial-gradient(
      1200px 600px at 80% -10%,
      rgba(124, 58, 237, 0.25),
      transparent 60%
    ),
    radial-gradient(
      800px 420px at 10% 0%,
      rgba(34, 197, 94, 0.15),
      transparent 70%
    );
}
html[data-theme="light"] .bg-layer {
  background: radial-gradient(
      1200px 600px at 80% -10%,
      rgba(124, 58, 237, 0.14),
      transparent 60%
    ),
    radial-gradient(
      900px 450px at 8% -6%,
      rgba(34, 197, 94, 0.1),
      transparent 70%
    );
}

/* ---------- Header / Nav ---------- */
header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(15, 23, 42, 0.7);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
html[data-theme="light"] header {
  background: rgba(255, 255, 255, 0.86);
  border-bottom: 1px solid rgba(2, 6, 23, 0.08);
}

.nav {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  min-height: var(--header-h);
}
.nav-left {
  justify-self: start;
}
.nav-center {
  justify-self: center;
  display: flex;
  align-items: center;
  gap: 18px;
}
.nav-right {
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 12px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 700;
}
.logo-badge {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--brand), #9333ea);
  display: grid;
  place-items: center;
  box-shadow: 0 10px 30px rgba(124, 58, 237, 0.35);
}
.logo-badge svg {
  width: 22px;
  height: 22px;
  fill: var(--brand-contrast);
}

.nav-center a {
  color: var(--text);
  padding: 8px 10px;
  position: relative;
}
.nav-center a::after {
  content: "";
  position: absolute;
  left: 10px;
  right: 10px;
  bottom: 2px;
  height: 2px;
  background: transparent;
  transition: background 0.2s;
}
.nav-center a:hover::after {
  background: currentColor;
}

.iconbtn {
  display: inline-grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: transparent;
  border-radius: 12px;
  padding: 8px 10px;
  color: var(--text);
  cursor: pointer;
}
html[data-theme="light"] .iconbtn {
  border-color: rgba(2, 6, 23, 0.18);
}

#menuToggle {
  display: none;
}
#mobilePanel {
  display: none;
  position: absolute;
  left: 0;
  right: 0;
  top: 100%;
  background: var(--panel);
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.25);
}
#mobilePanel .panel-inner {
  padding: 18px 28px;
  display: grid;
  gap: 12px;
}
#mobilePanel a {
  color: var(--text);
}
html[data-theme="light"] #mobilePanel {
  border-bottom: 1px solid rgba(2, 6, 23, 0.08);
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  text-align: center;
  padding-top: 5px;
  padding-bottom: 5px;
}
.hero::before {
  content: "";
  position: absolute;
  inset: auto 0;
  top: 60px;
  height: 280px;
  margin: auto;
  max-width: 760px;
  filter: blur(40px);
  z-index: -1;
  background: radial-gradient(
    520px 190px at 50% 40%,
    rgba(124, 58, 237, 0.25),
    transparent 70%
  );
}
html[data-theme="light"] .hero::before {
  background: radial-gradient(
    540px 200px at 50% 40%,
    rgba(124, 58, 237, 0.14),
    transparent 70%
  );
}

.brandname {
  display: block;
  font-size: clamp(60px, 7vw, 68px);
  font-weight: 900;
  letter-spacing: -0.02em;
  line-height: 1.05;
  background: linear-gradient(180deg, #b18cff 0%, #7c3aed 55%, #6d28d9 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow: 0 6px 24px rgba(124, 58, 237, 0.35);
  margin: 10px 0 10px;
  padding-bottom: 7px;
}
.headline {
  font-size: clamp(28px, 4vw, 46px);
  line-height: 1.15;
  margin: 6px 0 12px;
  font-weight: 800;
}
.subtitle {
  font-size: clamp(16px, 2.5vw, 20px);
  color: rgba(229, 231, 235, 0.78);
  max-width: 720px;
  margin: 0 auto;
}
html[data-theme="light"] .subtitle {
  color: rgba(15, 23, 42, 0.7);
}
.pill {
  display: inline-block;
  padding: 6px 12px;
  font-size: 13px;
  color: var(--muted);
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.06),
    rgba(255, 255, 255, 0.03)
  );
  border-radius: 999px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.15);
}
html[data-theme="light"] .pill {
  border-color: rgba(2, 6, 23, 0.12);
  background: linear-gradient(
    180deg,
    rgba(2, 6, 23, 0.06),
    rgba(2, 6, 23, 0.03)
  );
  box-shadow: inset 0 1px 0 rgba(2, 6, 23, 0.1);
}

.contact-inline {
  margin: 10px auto 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
  font-size: 16px;
  line-height: 1.5;
  color: color-mix(in oklab, var(--text) 85%, transparent);
}
.contact-inline .ci-item {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 4px 8px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(4px);
}
.contact-inline a {
  color: color-mix(in oklab, var(--text) 96%, transparent);
  font-weight: 600;
}
.ci-sep {
  opacity: 0.5;
}

/* === KPI Grid (Icon links, Text stabil) === */
.kpis {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
  margin: 22px 0;
}

.kpi {
  /* statt flex -> grid, damit Icon zwei Zeilen abdeckt */
  display: grid;
  grid-template-columns: 32px 1fr; /* fixe Icon-Spalte */
  grid-template-rows: auto auto; /* Titel + Sub */
  align-items: center;
  column-gap: 12px;

  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  padding: 16px 18px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.kpi:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
}

/* Emoji stabilisieren + über beide Zeilen spannen */
.kpi-icon {
  grid-row: 1 / span 2; /* Icon deckt Titel & Sub ab */
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  font-size: 22px;
  line-height: 1;
}

/* Textspalte */
.kpi-text {
  display: contents; /* Titel/Sub direkt ins Grid */
}

.kpi-title {
  grid-column: 2;
  font-weight: 700;
  font-size: 18px;
  line-height: 1.15;
}

.kpi-sub {
  grid-column: 2;
  font-size: 14px;
  color: var(--muted);
  line-height: 1.15;
}

/* Responsive */
@media (max-width: 1000px) {
  .kpis {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (max-width: 560px) {
  .kpis {
    grid-template-columns: 1fr;
  }
  .kpi {
    grid-template-columns: 28px 1fr;
    column-gap: 10px;
  }
  .kpi-icon {
    width: 28px;
    height: 28px;
    font-size: 20px;
  }
  .kpi-title {
    font-size: 1.05rem;
  }
  .kpi-sub {
    font-size: 0.9rem;
  }
}

/* Fallback gegen minimale Font-Abweichungen */
.kpi-icon,
.kpi-title,
.kpi-sub {
  vertical-align: middle;
}

/* ---------- Buttons ---------- */
.stack {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 16px 0 8px;
  justify-content: center;
}
.cta {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 18px;
  border-radius: 999px;
  white-space: nowrap;
}
.cta.primary {
  background: linear-gradient(135deg, #8b5cf6, #5b21b6);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: 0 12px 30px rgba(124, 58, 237, 0.35);
  height: 100%;
  cursor: pointer;
}
.cta.primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 30px rgba(124, 58, 237, 0.45),
    0 0 0 4px rgba(124, 58, 237, 0.18);
  background: linear-gradient(135deg, #9a6bff, #5b21b6);
}
.cta.primary:active {
  transform: translateY(0);
  box-shadow: 0 8px 18px rgba(124, 58, 237, 0.32);
}
.cta.secondary {
  background: transparent;
  color: var(--text);
  border: 1px solid rgba(255, 255, 255, 0.18);
}
.cta.secondary:hover {
  transform: translateY(-2px);
  background: rgba(255, 255, 255, 0.06);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.16), 0 0 0 4px var(--ring);
}
.cta.secondary:active {
  transform: translateY(0);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.12);
}
.cta.whatsapp {
  background: linear-gradient(135deg, #25d366, #128c7e);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.14);
}
.cta.whatsapp:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 32px rgba(37, 211, 102, 0.45),
    0 0 0 4px rgba(37, 211, 102, 0.18);
  background: linear-gradient(135deg, #2af173, #128c7e);
}
.cta.whatsapp:active {
  transform: translateY(0);
  box-shadow: 0 8px 18px rgba(37, 211, 102, 0.32);
}
/* Light Mode Variante (damit Kontrast bleibt) */
html[data-theme="light"] .cta.whatsapp {
  border-color: rgba(2, 6, 23, 0.12);
  box-shadow: 0 10px 24px rgba(37, 211, 102, 0.28);
}
html[data-theme="light"] .cta.whatsapp:hover {
  box-shadow: 0 14px 32px rgba(37, 211, 102, 0.45),
    0 0 0 4px rgba(37, 211, 102, 0.18);
}
html[data-theme="light"] .cta.secondary {
  border-color: rgba(2, 6, 23, 0.18);
}

/* ---------- Cards / Grids ---------- */
section {
  padding: 15px 0;
}
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 18px;
}
.card {
  background: rgba(17, 24, 39, 0.65);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 18px;
  padding: 18px;
}
html[data-theme="light"] .card {
  background: var(--panel);
  border: 1px solid rgba(2, 6, 23, 0.08);
  box-shadow: 0 10px 24px rgba(2, 6, 23, 0.06);
}
.card h3 {
  margin: 0 0 6px;
}
ul {
  padding-left: 18px;
}

/* Preise + Ablauf Spalten */
.cols {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 26px;
  align-items: stretch;
}
.cols > div {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.cols > div > h2 {
  margin: 0;
  line-height: 1.25;
}
.cols > div > .card {
  flex: 1;
  display: flex;
  flex-direction: column;
}
.cols > div > .card .notice {
  margin-top: auto;
}
.price {
  font-size: 36px;
  font-weight: 800;
}
.notice {
  border-left: 4px solid var(--accent);
  padding: 10px 12px;
  background: rgba(34, 197, 94, 0.1);
  border-radius: 12px;
}
.danger {
  border-left-color: var(--danger);
  background: rgba(239, 68, 68, 0.08);
}

/* Kontakt */
.contact-grid {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 28px;
  align-items: stretch;
}
.info-card,
.form-card {
  background: rgba(17, 24, 39, 0.65);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 18px;
  padding: 18px;
  display: flex;
  flex-direction: column;
}
html[data-theme="light"] .info-card,
html[data-theme="light"] .form-card {
  background: #fff;
  border: 1px solid rgba(2, 6, 23, 0.08);
  box-shadow: 0 10px 24px rgba(2, 6, 23, 0.06);
}
.info-card .contact-intro {
  margin: 2px 0 10px;
  color: var(--muted);
  max-width: 60ch;
}
.info-card .row {
  display: flex;
  gap: 10px;
  align-items: center;
  margin: 10px 0;
}
.info-card .row strong {
  min-width: 110px;
  flex: 0 0 110px;
  font-weight: 600;
}
.info-card .row span {
  margin-left: 4px;
}
.info-card .chip-whatsapp {
  padding: 6px 10px;
  border-radius: 10px;
  background: linear-gradient(135deg, #25d366, #128c7e);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.14);
}
.info-card .spacer {
  flex: 1;
}

.form-row label {
  display: block;
  margin: 0 0 6px;
  padding-top: 10px;
}
.form-row input,
.form-row textarea,
input,
textarea {
  width: 100%;
  padding: 12px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
}
html[data-theme="light"] .form-row input,
html[data-theme="light"] .form-row textarea,
html[data-theme="light"] input,
html[data-theme="light"] textarea {
  background: #fff;
  border: 1px solid rgba(2, 6, 23, 0.14);
  color: var(--text);
}
.ring:focus {
  outline: none;
  box-shadow: 0 0 0 6px var(--ring);
}

.consent {
  display: grid;
  grid-template-columns: 18px 1fr;
  column-gap: 10px;
  align-items: start;
  padding-top: 5px;
  padding-bottom: 15px;
}
.consent input {
  margin-top: 3px;
}
.consent small {
  color: var(--muted);
  max-width: 62ch;
  text-wrap: pretty;
}
.actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-start;
  padding-top: 5px;
}
.consent input {
  margin: auto;
}

/* ---------- Footer ---------- */
.footer {
  color: var(--muted);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding: 22px 0 60px;
}
.footer-top {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: start;
  gap: 18px;
}
.footer-links {
  text-align: right;
}
html[data-theme="light"] .footer {
  border-top: 1px solid rgba(2, 6, 23, 0.08);
}
@media (max-width: 700px) {
  .footer-top {
    grid-template-columns: 1fr;
  }
  .footer-links {
    text-align: left;
  }
}

/* ---------- Back to top ---------- */
.totop {
  position: fixed;
  right: 22px;
  bottom: 22px;
  width: 50px;
  height: 50px;
  display: grid;
  place-items: center;
  border-radius: 16px;
  background: rgba(17, 24, 39, 0.85);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.25);
  font-size: 22px;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px) scale(0.95);
  transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s ease,
    box-shadow 0.3s ease, background 0.3s ease;
  z-index: 50;
}

.totop.show {
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
}

.totop:hover {
  background: linear-gradient(135deg, #7c3aed, #5b21b6);
  box-shadow: 0 0 25px rgba(124, 58, 237, 0.45);
  transform: translateY(-3px) scale(1.05);
}

html[data-theme="light"] .totop {
  background: #fff;
  color: #0f172a;
  border-color: rgba(2, 6, 23, 0.12);
}

html[data-theme="light"] .totop:hover {
  background: linear-gradient(135deg, #8b5cf6, #5b21b6);
  color: #fff;
  box-shadow: 0 0 25px rgba(124, 58, 237, 0.45);
}

/* ---------- A11y ---------- */
.nav-center a:focus-visible,
.cta:focus-visible,
.totop:focus-visible {
  outline: none;
  box-shadow: 0 0 0 4px var(--ring);
}

/* ---------- Responsive ---------- */
@media (max-width: 920px) {
  .cols {
    grid-template-columns: 1fr;
  }
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 18px;
  }
}
@media (max-width: 820px) {
  .container {
    padding: 0 22px;
  }
  .nav-center {
    display: none;
  }
  #menuToggle {
    display: inline-grid;
  }
  .nav {
    grid-template-columns: auto 1fr auto;
  }
  .nav-right {
    gap: 8px;
    margin-left: auto;
  }
  .headline {
    font-size: 28px;
  }
}
@media (max-width: 640px) {
  .contact-inline {
    flex-direction: column;
    gap: 8px;
  }
  .ci-sep {
    display: none;
  }
  .contact-inline .ci-item {
    width: 100%;
    justify-content: center;
  }
}
@media (max-width: 420px) {
  .container {
    padding: 0 20px;
  }
  #mobilePanel .panel-inner {
    padding: 16px 20px;
  }
  .iconbtn {
    padding: 8px 10px;
  }
}

#ueber {
  max-width: 800px;
  margin: 10px auto;
  text-align: center;
  line-height: 1.6;
  font-size: 1.05rem;
  color: var(--muted, #cbd5e1);
}
#ueber h2 {
  font-size: 1.6rem;
  margin-bottom: 12px;
  color: var(--text, #fff);
}
