/* ==========================================================================
   walter.berlin – gemeinsames Stylesheet
   Eingebunden in _partials/head.php. Seitenspezifische Regeln werden über die
   Body-Klasse gescoped: page-home, page-kontakt, page-legal, page-danke.
   ========================================================================== */

/* --- Reset --- */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

/* --- Design-Tokens --- */
:root {
  --blue: #1a56db;
  --blue-light: #3b7cf5;
  --blue-glow: rgba(26, 86, 219, 0.12);
  --ink: #0f172a;
  --ink-soft: #334155;
  --ink-muted: #64748b;
  --surface: #ffffff;
  --surface-dim: #f8fafc;
  --surface-dark: #0f172a;
  --border: #e2e8f0;
  --red: #ef4444;
  --green: #16a34a;
  --radius: 12px;
  --font-display: 'Plus Jakarta Sans', system-ui, sans-serif;
  --font-body: 'DM Sans', system-ui, sans-serif;
}

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  color: var(--ink);
  line-height: 1.7;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a { color: var(--blue); text-decoration: none; transition: color 0.2s; }
a:hover { color: var(--blue-light); }

section { padding: 100px 24px; }
.container { max-width: 1080px; margin: 0 auto; }

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 15px 30px;
  border-radius: 10px;
  font-weight: 600;
  font-size: 0.95rem;
  font-family: var(--font-body);
  cursor: pointer;
  border: none;
  transition: all 0.25s ease;
  text-decoration: none;
}
.btn-primary { background: var(--blue); color: #fff; }
.btn-primary:hover {
  background: var(--blue-light);
  color: #fff;
  box-shadow: 0 4px 16px rgba(26, 86, 219, 0.35);
  transform: translateY(-1px);
}
.btn-ghost {
  background: transparent;
  color: rgba(255,255,255,0.7);
  border: 1px solid rgba(255,255,255,0.15);
}
.btn-ghost:hover {
  color: #fff;
  border-color: rgba(255,255,255,0.4);
  background: rgba(255,255,255,0.05);
}
.btn-cta {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 16px 36px; background: #fff; color: var(--ink);
  border-radius: 10px; font-weight: 600; font-size: 1rem;
  transition: all 0.25s; text-decoration: none;
}
.btn-cta:hover { background: var(--surface-dim); color: var(--ink); transform: translateY(-1px); box-shadow: 0 8px 24px rgba(0,0,0,0.2); }

/* --- Section-Header --- */
.section-eyebrow {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--blue);
  margin-bottom: 12px;
}
.section-title {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 3.5vw, 2.4rem);
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 16px;
  letter-spacing: -0.5px;
}
.section-desc {
  font-size: 1.05rem;
  color: var(--ink-muted);
  max-width: 540px;
  line-height: 1.7;
}
.section-header-center { text-align: center; margin-bottom: 56px; }
.section-header-center .section-desc { margin-left: auto; margin-right: auto; }

/* --- Footer (alle Seiten außer Danke) --- */
footer {
  padding: 32px 24px; border-top: 1px solid var(--border);
  text-align: center; color: var(--ink-muted); font-size: 0.85rem;
}
footer a { color: var(--ink-muted); }
footer a:hover { color: var(--ink); }
.footer-links { margin-top: 8px; }
.footer-links a { margin: 0 14px; }

/* --- Hero (gemeinsame Basis) --- */
.hero {
  position: relative;
  background: var(--surface-dark);
  overflow: hidden;
}
.hero-inner { position: relative; z-index: 1; }

/* ==========================================================================
   Startseite (page-home)
   ========================================================================== */
.page-home .hero { padding: 140px 24px 120px; }
.page-home .hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 60% at 20% 40%, rgba(26, 86, 219, 0.15) 0%, transparent 70%),
    radial-gradient(ellipse 60% 50% at 80% 60%, rgba(239, 68, 68, 0.06) 0%, transparent 70%);
  pointer-events: none;
}
.page-home .hero::after {
  content: '';
  position: absolute;
  inset: 0;
  background: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.03'/%3E%3C/svg%3E");
  pointer-events: none;
}
.page-home .hero-inner { max-width: 780px; }
.hero-logo {
  display: flex; align-items: center; gap: 16px;
  margin-bottom: 56px;
}
.hero-name {
  font-family: var(--font-display);
  font-size: 1.3rem; font-weight: 800; color: #fff; letter-spacing: -0.5px;
}
.hero-divider {
  width: 1px; height: 24px; background: rgba(255,255,255,0.2);
}
.hero-company {
  font-size: 0.85rem; color: rgba(255,255,255,0.45); font-weight: 500;
}
.hero-label {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--blue-light);
  margin-bottom: 24px;
  padding: 6px 16px;
  border: 1px solid rgba(59, 124, 245, 0.3);
  border-radius: 100px;
}
.page-home .hero h1 {
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 5vw, 3.6rem);
  font-weight: 800;
  line-height: 1.12;
  color: #fff;
  margin-bottom: 24px;
  letter-spacing: -1px;
}
.page-home .hero h1 em { font-style: normal; color: var(--blue-light); }
.hero-sub {
  font-size: 1.15rem;
  color: rgba(255,255,255,0.6);
  max-width: 560px;
  margin-bottom: 40px;
  line-height: 1.8;
}
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }

/* Leistungen */
.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}
.service-card {
  background: var(--surface);
  padding: 40px 32px;
  transition: background 0.3s ease;
}
.service-card:hover { background: var(--surface-dim); }
.service-icon {
  width: 44px; height: 44px;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 20px;
  color: var(--blue);
}
.service-card h3 {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 10px;
}
.service-card p { font-size: 0.92rem; color: var(--ink-muted); line-height: 1.7; }

/* USP */
.usp-section { background: var(--surface-dim); }
.usp-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 32px; margin-top: 48px; }
.usp-item { display: flex; gap: 16px; }
.usp-marker {
  flex-shrink: 0; width: 8px; height: 8px;
  background: var(--blue); border-radius: 50%; margin-top: 10px;
}
.usp-item h3 { font-weight: 600; font-size: 1rem; margin-bottom: 4px; }
.usp-item p { font-size: 0.92rem; color: var(--ink-muted); line-height: 1.7; }

/* Vorher/Nachher */
.comparison {
  display: grid;
  grid-template-columns: 1fr 64px 1fr;
  align-items: stretch;
  margin-top: 48px;
}
.comp-box { padding: 36px 32px; border-radius: var(--radius); }
.comp-box.before { background: #fef2f2; border: 1px solid #fecaca; }
.comp-box.after { background: #f0fdf4; border: 1px solid #bbf7d0; }
.comp-arrow { display: flex; align-items: center; justify-content: center; color: var(--ink-muted); font-size: 1.5rem; }
.comp-box h3 {
  font-family: var(--font-display);
  font-size: 1.15rem; margin-bottom: 16px; font-weight: 700;
}
.comp-box ul { list-style: none; }
.comp-box li {
  padding: 7px 0; font-size: 0.92rem; color: var(--ink-soft);
  display: flex; align-items: flex-start; gap: 10px;
}
.comp-box li .marker {
  flex-shrink: 0; width: 18px; height: 18px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.65rem; margin-top: 3px;
}
.comp-box.before .marker { background: #fee2e2; color: var(--red); }
.comp-box.after .marker { background: #dcfce7; color: var(--green); }
.comp-box li .label { flex: 1; }
.comp-box li .price {
  flex-shrink: 0; font-variant-numeric: tabular-nums;
  font-size: 0.85rem; color: var(--ink-muted); font-weight: 600;
}
.comp-box.before li .price { color: #b91c1c; }
.comp-total {
  margin-top: 16px; padding-top: 14px;
  border-top: 1px dashed #fecaca;
  display: flex; justify-content: space-between; align-items: baseline;
  font-size: 0.9rem;
}
.comp-total .label { font-weight: 700; color: var(--ink); }
.comp-total .price { font-weight: 800; color: #b91c1c; font-size: 1rem; font-variant-numeric: tabular-nums; }
.comp-savings {
  margin-top: 32px; padding: 24px 28px;
  background: linear-gradient(135deg, #f0fdf4 0%, #ecfdf5 100%);
  border: 1px solid #bbf7d0; border-radius: var(--radius);
  display: flex; gap: 24px; align-items: center; justify-content: space-between;
  flex-wrap: wrap;
}
.comp-savings-text {
  font-family: var(--font-display); font-weight: 700;
  font-size: 1.1rem; color: #14532d;
}
.comp-savings-text small { display: block; font-family: var(--font-body); font-weight: 500; font-size: 0.85rem; color: #16653a; margin-top: 4px; }
.comp-savings-num {
  font-family: var(--font-display); font-weight: 800;
  font-size: 1.8rem; color: var(--green); font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

/* Ablauf / Steps */
.steps-section { background: var(--surface-dim); }
.steps-track {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 0; margin-top: 48px; position: relative;
}
.steps-track::before {
  content: ''; position: absolute; top: 23px; left: 48px; right: 48px;
  height: 2px; background: var(--border);
}
.step-item { text-align: center; position: relative; }
.step-num {
  width: 48px; height: 48px; border-radius: 50%;
  background: var(--surface); border: 2px solid var(--blue); color: var(--blue);
  display: inline-flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 1rem; margin-bottom: 20px;
  position: relative; z-index: 1;
}
.step-item h3 { font-family: var(--font-display); font-size: 1.1rem; font-weight: 700; margin-bottom: 8px; }
.step-item p { font-size: 0.88rem; color: var(--ink-muted); line-height: 1.6; max-width: 220px; margin: 0 auto; }

/* Über mich */
.about-inner { max-width: 680px; margin: 0 auto; }
.about-inner .lead {
  font-family: var(--font-display);
  font-size: 1.5rem; line-height: 1.5; margin-bottom: 20px; font-weight: 700;
}
.about-inner p { color: var(--ink-muted); margin-bottom: 16px; line-height: 1.8; }
.about-promise {
  margin-top: 28px; padding: 24px 28px;
  background: var(--surface-dim); border-left: 3px solid var(--blue);
  border-radius: 0 var(--radius) var(--radius) 0;
  font-style: italic; color: var(--ink-soft);
}
.linkedin-link {
  display: inline-flex; align-items: center; gap: 8px;
  margin-top: 28px; font-weight: 600; font-size: 0.92rem; color: var(--blue);
  padding: 10px 20px; border: 1px solid var(--border); border-radius: 8px;
  transition: all 0.2s;
}
.linkedin-link:hover { border-color: var(--blue); background: var(--blue-glow); color: var(--blue); }

/* CTA */
.cta-section { background: var(--surface-dark); position: relative; overflow: hidden; }
.cta-section::before {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(ellipse 70% 70% at 50% 50%, rgba(26, 86, 219, 0.1) 0%, transparent 70%);
  pointer-events: none;
}
.cta-inner { position: relative; z-index: 1; text-align: center; max-width: 560px; margin: 0 auto; }
.cta-section .section-title { color: #fff; }
.cta-section .section-desc { color: rgba(255,255,255,0.6); margin: 0 auto 36px; }

/* Scroll-Reveal */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity 0.7s ease, transform 0.7s ease; }
.reveal.visible { opacity: 1; transform: translateY(0); }

/* ==========================================================================
   Kontaktseite (page-kontakt)
   ========================================================================== */
.page-kontakt .hero { padding: 100px 24px 60px; }
.page-kontakt .hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 80% 60% at 20% 40%, rgba(26, 86, 219, 0.15) 0%, transparent 70%);
  pointer-events: none;
}
.page-kontakt .hero-inner { max-width: 600px; margin: 0 auto; }
.hero-back {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 0.85rem; color: rgba(255,255,255,0.5);
  margin-bottom: 32px; transition: color 0.2s;
}
.hero-back:hover { color: rgba(255,255,255,0.8); }
.page-kontakt .hero h1 {
  font-family: var(--font-display);
  font-size: 2.2rem; font-weight: 800; color: #fff;
  letter-spacing: -0.5px; margin-bottom: 12px;
}
.page-kontakt .hero p { font-size: 1rem; color: rgba(255,255,255,0.55); }

.form-section {
  max-width: 600px;
  margin: -40px auto 0;
  padding: 0 24px 80px;
  position: relative;
  z-index: 2;
}
.form-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 40px 36px;
  box-shadow: 0 4px 24px rgba(0,0,0,0.06);
}
.form-errors {
  background: #fef2f2;
  border: 1px solid #fecaca;
  color: #b91c1c;
  border-radius: 8px;
  padding: 14px 18px;
  margin-bottom: 24px;
  font-size: 0.9rem;
}
.form-errors ul { list-style: none; margin: 0; padding: 0; }
.form-errors li { padding: 2px 0; }
.form-group { margin-bottom: 20px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-group label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--ink-soft);
  margin-bottom: 6px;
}
.form-group label .required { color: var(--blue); }
.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--ink);
  background: var(--surface);
  transition: border-color 0.2s, box-shadow 0.2s;
  outline: none;
}
.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px var(--blue-glow);
}
.form-group textarea { resize: vertical; min-height: 100px; }
.form-group select { cursor: pointer; }

/* Honeypot */
.hp-field { position: absolute; left: -9999px; opacity: 0; height: 0; }

.form-submit {
  display: block;
  width: 100%;
  padding: 15px;
  background: var(--blue);
  color: #fff;
  border: none;
  border-radius: 10px;
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.25s;
  margin-top: 8px;
}
.form-submit:hover {
  background: var(--blue-light);
  box-shadow: 0 4px 16px rgba(26, 86, 219, 0.35);
  transform: translateY(-1px);
}
.form-note {
  text-align: center;
  margin-top: 16px;
  font-size: 0.8rem;
  color: var(--ink-muted);
}
.form-alt {
  text-align: center;
  margin-top: 24px;
  font-size: 0.9rem;
  color: var(--ink-muted);
}

/* ==========================================================================
   Rechtstexte (page-legal): Impressum, Datenschutz
   ========================================================================== */
.page-legal a:hover { text-decoration: underline; }
.page-legal .container { max-width: 780px; padding: 64px 24px 80px; }
.page-legal h1 { font-size: 2rem; font-weight: 800; margin-bottom: 32px; }
.page-legal h2 { font-size: 1.3rem; font-weight: 700; margin-top: 32px; margin-bottom: 12px; }
.page-legal h3 { font-size: 1.1rem; font-weight: 600; margin-top: 20px; margin-bottom: 8px; }
.page-legal p, .page-legal ul { margin-bottom: 12px; }
.page-legal ul { padding-left: 20px; }

/* ==========================================================================
   Danke-Seite (page-danke)
   ========================================================================== */
body.page-danke {
  display: flex; align-items: center; justify-content: center;
  min-height: 100vh; background: var(--surface-dim); padding: 24px;
}
.page-danke .card {
  max-width: 480px; background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 48px; text-align: center;
}
.page-danke .check {
  width: 56px; height: 56px; border-radius: 50%;
  background: #f0fdf4; border: 2px solid #bbf7d0;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 1.5rem; margin-bottom: 20px;
}
.page-danke h1 {
  font-family: var(--font-display);
  font-size: 1.8rem; font-weight: 800; letter-spacing: -0.5px; margin-bottom: 12px;
}
.page-danke p { color: var(--ink-muted); margin-bottom: 8px; }
.page-danke .back {
  display: inline-block; margin-top: 24px;
  color: var(--blue); font-weight: 600; text-decoration: none;
}
.page-danke .back:hover { color: var(--blue-light); }

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 900px) {
  .services-grid { grid-template-columns: 1fr; }
  .usp-grid { grid-template-columns: 1fr; }
  .steps-track { grid-template-columns: 1fr 1fr; gap: 32px; }
  .steps-track::before { display: none; }
}
@media (max-width: 768px) {
  section { padding: 72px 20px; }
  .page-home .hero { padding: 100px 20px 80px; }
  .comparison { grid-template-columns: 1fr; gap: 16px; }
  .comp-arrow { transform: rotate(90deg); padding: 4px 0; }
  .steps-track { grid-template-columns: 1fr; }
  .hero-actions { flex-direction: column; }
  .hero-actions .btn { text-align: center; justify-content: center; }
}
@media (max-width: 600px) {
  .form-row { grid-template-columns: 1fr; }
  .form-card { padding: 28px 20px; }
  .page-kontakt .hero { padding: 80px 20px 50px; }
  .page-kontakt .hero h1 { font-size: 1.8rem; }
}
