/* ============================================================
   PV Beratung Keller — Stylesheet
   Farbwelt abgeleitet aus dem bestehenden Logo & Markenauftritt
   (identisch zur Farbpalette von Energieberatung Keller)
   ============================================================ */

:root {
  --navy: #002c6a;
  --navy-deep: #001b42;
  --blue: #1b74bb;
  --sky: #28a8e4;
  --gold: #ffd517;
  --ink: #1c2530;
  --body-text: #40474f;
  --line: #dfe4ea;
  --line-strong: #c5c5c5;
  --bg-soft: #f4f7fb;
  --bg-soft-2: #eef3f9;
  --white: #ffffff;

  --shadow-sm: 0 2px 8px rgba(0, 44, 106, 0.08);
  --shadow-md: 0 12px 32px rgba(0, 44, 106, 0.12);
  --shadow-lg: 0 24px 64px rgba(0, 28, 66, 0.18);

  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 24px;

  --container: 1180px;
  --font-head: "Manrope", "Segoe UI", system-ui, sans-serif;
  --font-body: "Inter", "Segoe UI", system-ui, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

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

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--body-text);
  background: var(--white);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: var(--font-head);
  color: var(--ink);
  line-height: 1.2;
  margin: 0 0 0.6em;
  font-weight: 800;
  letter-spacing: -0.01em;
  overflow-wrap: break-word;
  word-break: normal;
  text-wrap: balance;
}

h1 { font-size: clamp(2rem, 4.6vw, 3.1rem); }
h2 { font-size: clamp(1.55rem, 3.2vw, 2.15rem); }
h3 { font-size: clamp(1.2rem, 2vw, 1.4rem); }

p { margin: 0 0 1.1em; }

a {
  color: var(--blue);
  text-decoration: none;
}
a:hover { text-decoration: underline; }

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

ul { padding-left: 1.2em; }
li { margin-bottom: 0.5em; }

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--navy);
  color: #fff;
  padding: 12px 20px;
  z-index: 1000;
  border-radius: 0 0 8px 0;
}
.skip-link:focus {
  left: 0;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 26px;
  border-radius: 999px;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 0.98rem;
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease, color 0.15s ease;
  text-decoration: none;
  white-space: nowrap;
}
.btn:hover { text-decoration: none; transform: translateY(-2px); }
.btn:active { transform: translateY(0); }

.btn-primary {
  background: var(--gold);
  color: var(--navy-deep);
  box-shadow: 0 10px 24px rgba(255, 213, 23, 0.35);
}
.btn-primary:hover { background: #ffdf3f; box-shadow: 0 14px 30px rgba(255, 213, 23, 0.45); }

.btn-outline {
  background: transparent;
  color: var(--white);
  border-color: rgba(255,255,255,0.6);
}
.btn-outline:hover { background: rgba(255,255,255,0.12); border-color: #fff; }

.btn-outline-navy {
  background: transparent;
  color: var(--navy);
  border-color: var(--navy);
}
.btn-outline-navy:hover { background: var(--navy); color: #fff; }

.btn-block { width: 100%; justify-content: center; }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 500;
  background: rgba(255,255,255,0.92);
  backdrop-filter: saturate(180%) blur(10px);
  border-bottom: 1px solid transparent;
  transition: box-shadow 0.2s ease, border-color 0.2s ease;
}
.site-header.is-scrolled {
  box-shadow: var(--shadow-sm);
  border-bottom-color: var(--line);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 24px;
  gap: 16px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-head);
  font-weight: 800;
  color: var(--navy);
  font-size: 1.05rem;
}
.brand img {
  height: 56px;
  width: auto;
  aspect-ratio: 2093 / 680;
  flex: none;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 30px;
}
.main-nav ul {
  display: flex;
  gap: 28px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.main-nav a {
  color: var(--ink);
  font-weight: 600;
  font-size: 0.98rem;
  padding: 6px 2px;
  border-bottom: 2px solid transparent;
}
.main-nav a:hover,
.main-nav a[aria-current="page"] {
  color: var(--blue);
  text-decoration: none;
  border-bottom-color: var(--gold);
}

.header-cta {
  display: flex;
  align-items: center;
  gap: 18px;
}
.header-phone {
  display: none;
  color: var(--navy);
  font-weight: 700;
  font-size: 0.95rem;
  white-space: nowrap;
}
.header-phone svg { vertical-align: -3px; margin-right: 6px; }

.btn-sm {
  padding: 11px 20px;
  font-size: 0.92rem;
  background: var(--navy);
  color: #fff;
  box-shadow: none;
}
.btn-sm:hover { background: var(--blue); }

.nav-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 10px;
  border: 1px solid var(--line-strong);
  background: #fff;
  cursor: pointer;
}
.nav-toggle span,
.nav-toggle::before,
.nav-toggle::after {
  content: "";
  display: block;
  width: 20px;
  height: 2px;
  background: var(--navy);
  position: relative;
  transition: transform 0.2s ease, opacity 0.2s ease;
}
.nav-toggle::before { position: absolute; transform: translateY(-6px); }
.nav-toggle::after { position: absolute; transform: translateY(6px); }
.nav-toggle[aria-expanded="true"] span { opacity: 0; }
.nav-toggle[aria-expanded="true"]::before { transform: rotate(45deg); }
.nav-toggle[aria-expanded="true"]::after { transform: rotate(-45deg); }

.mobile-panel {
  display: none;
  background: #fff;
  border-top: 1px solid var(--line);
  padding: 10px 24px 24px;
}
.mobile-panel.is-open { display: block; }
.mobile-panel ul {
  list-style: none;
  padding: 0;
  margin: 0 0 18px;
}
.mobile-panel li { margin: 0; border-bottom: 1px solid var(--line); }
.mobile-panel a {
  display: block;
  padding: 14px 4px;
  color: var(--ink);
  font-weight: 600;
}
.mobile-panel .btn { margin-bottom: 10px; }
.mobile-phone {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--navy);
  font-weight: 700;
  padding: 10px 4px;
}

@media (min-width: 981px) {
  .header-phone { display: inline-flex; align-items: center; }
  .nav-toggle, .mobile-panel { display: none !important; }
}
@media (max-width: 980px) {
  .main-nav { display: none; }
  .header-cta .btn-sm { display: none; }
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  background: linear-gradient(135deg, var(--navy) 0%, var(--navy-deep) 55%, #001030 100%);
  color: #fff;
  overflow: hidden;
}
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 85% 15%, rgba(40,168,228,0.35), transparent 45%),
    radial-gradient(circle at 15% 90%, rgba(255,213,23,0.12), transparent 40%);
  pointer-events: none;
}
.hero-inner {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: center;
  padding: 40px 24px 52px;
}
.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.25);
  color: #cfe6fb;
  font-weight: 700;
  font-size: 0.82rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 7px 14px;
  border-radius: 999px;
  margin-bottom: 22px;
}
.hero h1 { color: #fff; margin-bottom: 0.5em; }
.hero-lead {
  color: #d7e6f5;
  font-size: 1.12rem;
  max-width: 54ch;
  margin-bottom: 2em;
}
.hero-ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 2.2em;
}
.hero-media {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  aspect-ratio: 4/5;
  max-width: 520px;
  width: 100%;
  margin-left: auto;
}
.hero-media img {
  width: 100%; height: 100%;
  object-fit: cover;
}
.hero-badge {
  position: absolute;
  left: 20px;
  bottom: 20px;
  right: 20px;
  background: rgba(255,255,255,0.94);
  color: var(--ink);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  display: flex;
  gap: 12px;
  align-items: center;
  box-shadow: var(--shadow-md);
  font-size: 0.88rem;
  font-weight: 600;
}
.hero-badge .dot {
  width: 10px; height: 10px; border-radius: 50%;
  background: #21c17a; flex: none;
}

.trust-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 28px;
  color: #cfe0f2;
  font-size: 0.92rem;
  font-weight: 600;
}
.trust-strip span { display: inline-flex; align-items: center; gap: 8px; }
.trust-strip svg { flex: none; }

/* Simpler page hero (interior pages) */
.page-hero {
  background: linear-gradient(135deg, var(--navy) 0%, var(--navy-deep) 100%);
  color: #fff;
  padding: 40px 24px 44px;
  position: relative;
  overflow: hidden;
}
.page-hero::after {
  content: "";
  position: absolute; inset: 0;
  background: radial-gradient(circle at 90% 10%, rgba(40,168,228,0.3), transparent 45%);
}
.page-hero .container { position: relative; }
.page-hero h1 { color: #fff; max-width: 46ch; }
.page-hero p { color: #d7e6f5; font-size: 1.08rem; max-width: 100%; margin-bottom: 0; }
.breadcrumb {
  font-size: 0.85rem;
  color: #a9c3dd;
  margin-bottom: 18px;
}
.breadcrumb a { color: #cfe0f2; }

/* ---------- Sections ---------- */
section { padding: 68px 0; }
.section-soft { background: var(--bg-soft); }
.section-tight { padding: 44px 0; }

.section-head {
  max-width: 880px;
  margin: 0 auto 40px;
  text-align: center;
}
.section-head p {
  max-width: 640px;
  margin-left: auto;
  margin-right: auto;
}
.section-head.align-left { margin-left: 0; text-align: left; }
.section-head.align-left p { margin-left: 0; }
.eyebrow {
  display: inline-block;
  color: var(--blue);
  font-weight: 700;
  font-size: 0.85rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-bottom: 12px;
}

.intro-split {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 56px;
  align-items: center;
}
.intro-split figure { margin: 0; }
.photo-frame {
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  aspect-ratio: 4/5;
  max-width: 360px;
}
.photo-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.photo-frame.landscape {
  aspect-ratio: 3/2;
  max-width: 480px;
}
.intro-split .photo-frame { margin: 0 auto; }
.intro-split blockquote {
  margin: 24px 0 0;
  padding-left: 18px;
  border-left: 3px solid var(--gold);
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--navy);
}

/* Card grids */
.grid {
  display: grid;
  gap: 28px;
}
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }

.card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 30px 26px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.card .icon {
  width: 52px; height: 52px;
  border-radius: 14px;
  background: var(--bg-soft-2);
  color: var(--blue);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 18px;
}
.card h3 { margin-bottom: 0.5em; }
.card p:last-child { margin-bottom: 0; }
.card .step-num {
  font-family: var(--font-head);
  font-weight: 800;
  font-size: 0.85rem;
  color: var(--gold-text, var(--navy));
  background: var(--bg-soft-2);
  display: inline-block;
  padding: 4px 12px;
  border-radius: 999px;
  margin-bottom: 14px;
}

/* Benefit rows (Warum PV) */
.benefit {
  display: grid;
  grid-template-columns: 64px 1fr;
  gap: 22px;
  padding: 30px 0;
  border-bottom: 1px solid var(--line);
}
.benefit:last-child { border-bottom: none; }
.benefit .icon {
  width: 56px; height: 56px;
  border-radius: 16px;
  background: var(--navy);
  color: #fff;
  display: flex; align-items: center; justify-content: center;
}
.benefit h3 { margin-bottom: 0.4em; }
.benefit p { margin-bottom: 0; color: var(--body-text); }

/* Callout box */
.callout {
  background: var(--navy);
  color: #fff;
  border-radius: var(--radius-lg);
  padding: 44px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 28px;
  align-items: center;
}
.callout h3 { color: #fff; margin-bottom: 0.4em; }
.callout p { color: #d7e6f5; margin-bottom: 0; max-width: 60ch; }

.callout-gold {
  background: #fff7dc;
  border: 1px solid #ffe793;
  border-radius: var(--radius-lg);
  padding: 40px;
}
.callout-gold h3 { color: var(--navy); }

/* Long-form article sections (Die große Verunsicherung) */
.article-section {
  max-width: 760px;
  margin: 0 auto 64px;
}
.article-section:last-of-type { margin-bottom: 0; }
.article-section h2 {
  display: flex;
  align-items: baseline;
  gap: 14px;
}
.article-section h2 .num {
  font-family: var(--font-head);
  font-size: 1rem;
  font-weight: 800;
  color: var(--navy);
  background: var(--bg-soft-2);
  border-radius: 999px;
  padding: 4px 13px;
  flex: none;
}
.article-section p, .article-section ul { color: var(--body-text); }
.article-section ul { margin: 0 0 1.1em; }
.article-lede {
  max-width: 760px;
  margin: 0 auto 56px;
  font-size: 1.18rem;
  color: var(--ink);
  font-family: var(--font-head);
  font-weight: 600;
}
.norm-list {
  background: var(--bg-soft);
  border-radius: var(--radius-md);
  padding: 26px 28px;
  margin: 1.4em 0;
}
.norm-list li { margin-bottom: 10px; }
.norm-list li:last-child { margin-bottom: 0; }
.pull-quote {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.3rem;
  color: var(--navy);
  border-left: 4px solid var(--gold);
  padding: 4px 0 4px 22px;
  margin: 1.6em 0;
}

/* Timeline / Werdegang (Über mich) */
.timeline {
  position: relative;
  padding-left: 32px;
  border-left: 2px solid var(--line);
}
.timeline-item { position: relative; padding-bottom: 40px; }
.timeline-item:last-child { padding-bottom: 0; }
.timeline-item::before {
  content: "";
  position: absolute;
  left: -39px; top: 4px;
  width: 16px; height: 16px;
  border-radius: 50%;
  background: var(--gold);
  border: 3px solid var(--navy);
}
.timeline-item h3 { margin-bottom: 0.4em; }

.credential-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 1.5em 0;
}
.credential-badges span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-soft-2);
  color: var(--navy);
  font-weight: 700;
  font-size: 0.88rem;
  padding: 9px 16px;
  border-radius: 999px;
  border: 1px solid #dbe8f5;
}

/* Contact */
.contact-wrap {
  display: grid;
  grid-template-columns: 1fr 1.15fr;
  gap: 48px;
  align-items: start;
}
.contact-info {
  background: var(--navy);
  color: #fff;
  border-radius: var(--radius-lg);
  padding: 40px;
}
.contact-info h3 { color: #fff; }
.contact-info ul { list-style: none; padding: 0; margin: 24px 0 0; }
.contact-info li {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  margin-bottom: 18px;
  color: #d7e6f5;
}
.contact-info li strong { display: block; color: #fff; }
.contact-info a { color: #fff; }
.contact-info .icon-circle {
  width: 38px; height: 38px; border-radius: 50%;
  background: rgba(255,255,255,0.12);
  display: flex; align-items: center; justify-content: center;
  flex: none;
}

.form-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 40px;
  box-shadow: var(--shadow-sm);
}
.form-row { margin-bottom: 20px; }
.form-row label {
  display: block;
  font-weight: 700;
  font-size: 0.92rem;
  color: var(--ink);
  margin-bottom: 8px;
}
.form-row input,
.form-row textarea {
  width: 100%;
  padding: 13px 14px;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  font-family: var(--font-body);
  font-size: 1rem;
  color: var(--ink);
  background: #fbfcfe;
}
.form-row input:focus,
.form-row textarea:focus {
  outline: none;
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(27,116,187,0.15);
}
.form-row textarea { resize: vertical; min-height: 130px; }
.form-note { font-size: 0.85rem; color: #7a828a; margin-top: 14px; }
.hp-field { position: absolute; left: -9999px; }

/* Fehlermeldung im Kontaktformular */
.form-error {
  margin: 0 0 20px;
  padding: 12px 16px;
  border: 1px solid #f0b4b4;
  border-left: 4px solid #c0392b;
  border-radius: var(--radius-sm);
  background: #fdf2f2;
  color: #97231a;
  font-size: 0.92rem;
  line-height: 1.45;
}
.form-error[hidden] { display: none; }


/* Footer */
.site-footer {
  background: var(--navy-deep);
  color: #b9cbe0;
  padding: 64px 0 28px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr 1.2fr;
  gap: 36px;
  padding-bottom: 40px;
  border-bottom: 1px solid rgba(255,255,255,0.12);
}
.footer-brand .logo-chip {
  display: inline-flex;
  background: #fff;
  border-radius: 14px;
  padding: 10px 18px;
  margin-bottom: 18px;
}
.footer-brand .logo-chip img {
  height: 46px;
  width: auto;
  aspect-ratio: 2093 / 680;
  flex: none;
}
.footer-brand p { color: #9fb4cd; font-size: 0.94rem; max-width: 34ch; }
.footer h4 {
  color: #fff;
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 18px;
}
.footer-col ul { list-style: none; padding: 0; margin: 0; }
.footer-col li { margin-bottom: 12px; }
.footer-col a { color: #b9cbe0; font-size: 0.95rem; }
.footer-col a:hover { color: #fff; }
.footer-bottom {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  padding-top: 24px;
  font-size: 0.85rem;
  color: #7f93ac;
}
.footer-bottom a { color: #7f93ac; }
.footer-bottom a:hover { color: #fff; }

/* Legal pages */
.legal-content {
  max-width: 780px;
  margin: 0 auto;
}
.legal-content h2 { margin-top: 1.6em; }
.legal-content h2:first-child { margin-top: 0; }
.legal-content h3 { margin-top: 1.3em; }
.legal-content ul { margin-bottom: 1.2em; }

/* Reveal animation — progressive enhancement only.
   Content is fully visible by default (no-JS, slow-JS, print, a11y tools).
   JS adds "js-anim" to <html> before observing, so the fade-in only
   ever applies when we can guarantee it will also be removed again. */
.js-anim .reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.js-anim .reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
  .hero-inner { grid-template-columns: 1fr; padding: 32px 24px 40px; }
  .hero-media { order: -1; max-width: 340px; margin: 0 auto; }
  .intro-split { grid-template-columns: 1fr; }
  .intro-split figure { max-width: 340px; margin: 0 auto; }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .contact-wrap { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .callout { grid-template-columns: 1fr; text-align: left; }
  section { padding: 52px 0; }
  .page-hero { padding: 32px 24px 36px; }
}

@media (max-width: 640px) {
  body { font-size: 16px; }
  .grid-3, .grid-4, .grid-2 { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 28px; }
  .benefit { grid-template-columns: 48px 1fr; }
  .benefit .icon { width: 44px; height: 44px; }
  .form-card, .contact-info { padding: 28px 22px; }
  .page-hero { padding: 26px 20px 30px; }
  .callout { padding: 30px 24px; }
  section { padding: 44px 0; }
  .hero-inner { padding: 24px 20px 32px; }
  .brand img { height: 44px; }
  .photo-frame { max-width: 300px; }
}
