/* ==========================================================================
   p17-data Theme – modern, aufgeräumt, minimalistisch
   Farben: Amber #FDB614 (Logo), Slate #1E293B, Hell #F0F5FA
   Fonts:  Oswald (Headlines), Open Sans (Text), Caveat (Buttons)
   ========================================================================== */

:root {
  --c-primary: #FDB614;
  --c-primary-dark: #E09E00;
  --c-primary-soft: #FFF4D6;
  --c-dark: #1E293B;
  --c-dark-2: #334155;
  --c-text: #2B3648;
  --c-muted: #5B6B82;
  --c-light: #F0F5FA;
  --c-white: #FFFFFF;
  --c-border: #E2E8F0;

  --f-head: 'Oswald', 'Arial Narrow', sans-serif;
  --f-body: 'Open Sans', 'Segoe UI', sans-serif;
  --f-hand: 'Caveat', cursive;

  --radius: 14px;
  --shadow: 0 6px 24px rgba(30, 41, 59, .08);
  --shadow-lg: 0 14px 44px rgba(30, 41, 59, .16);
  --wrap: 1200px;
  --speed: .45s;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--f-body);
  font-size: 1.05rem;
  line-height: 1.7;
  color: var(--c-text);
  background: var(--c-white);
  -webkit-font-smoothing: antialiased;
}

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

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 clamp(1rem, 4vw, 2rem); }

h1, h2, h3, h4 {
  font-family: var(--f-head);
  font-weight: 500;
  line-height: 1.2;
  color: var(--c-dark);
  margin: 0 0 .6em;
  text-wrap: balance;
}

h1 { font-size: clamp(2rem, 4.5vw, 3.2rem); letter-spacing: .01em; }
h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); }
h3 { font-size: clamp(1.15rem, 2vw, 1.4rem); }

p { margin: 0 0 1.1em; }

a { color: var(--c-dark); text-decoration-color: var(--c-primary); text-decoration-thickness: 2px; text-underline-offset: 3px; transition: color .2s; }
a:hover { color: var(--c-primary-dark); }

.skip-link {
  position: absolute; left: -999px; top: 0; z-index: 200;
  background: var(--c-dark); color: #fff; padding: .6rem 1rem;
}
.skip-link:focus { left: 0; }

.linklike { background: none; border: 0; padding: 0; font: inherit; color: inherit; cursor: pointer; text-decoration: underline; text-decoration-color: var(--c-primary); text-decoration-thickness: 2px; text-underline-offset: 3px; }

/* --------------------------------------------------------------------------
   Buttons – Handschrift (Caveat), plakativ
   -------------------------------------------------------------------------- */
.btn {
  display: inline-block;
  font-family: var(--f-hand);
  font-size: 1.45rem;
  font-weight: 600;
  line-height: 1.1;
  padding: .55rem 1.6rem;
  border-radius: 0;
  border: 2px solid transparent;
  text-decoration: none;
  cursor: pointer;
  transition: transform .2s ease, box-shadow .2s ease, background .2s ease, color .2s ease;
}
.btn:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.btn:active { transform: translateY(0); }

.btn-primary { background: var(--c-primary); color: var(--c-dark); }
.btn-primary:hover { background: var(--c-primary-dark); color: var(--c-dark); }

.btn-ghost { background: transparent; color: var(--c-dark); border-color: var(--c-dark-2); }
.btn-ghost:hover { border-color: var(--c-primary); color: var(--c-primary-dark); }

.btn-lg { font-size: 1.7rem; padding: .65rem 2.1rem; }

.btn-nav { background: var(--c-primary); color: var(--c-dark); font-size: 1.3rem; padding: .35rem 1.3rem; }

/* --------------------------------------------------------------------------
   Header & Navigation
   -------------------------------------------------------------------------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(255, 255, 255, .94);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--c-border);
  transition: box-shadow .25s;
}
.site-header.scrolled { box-shadow: var(--shadow); }

.header-inner { display: flex; align-items: center; gap: 1.2rem; min-height: 72px; }

.brand { display: flex; align-items: center; text-decoration: none; }
.brand img { display: block; }

.site-nav { margin-left: auto; }
.nav-list { display: flex; align-items: center; gap: .2rem; list-style: none; margin: 0; padding: 0; }
.nav-item > a {
  display: block; padding: .8rem .75rem;
  font-weight: 600; font-size: .95rem; text-decoration: none; color: var(--c-dark);
  border-radius: 8px;
}
.nav-item > a:hover { color: var(--c-primary-dark); }
.nav-item.is-active > a { color: var(--c-primary-dark); }
.nav-cta { margin-left: .5rem; }

.dd-toggle { display: none; }

/* Dropdowns (Desktop) */
.has-dropdown { position: relative; }
.has-dropdown > a::after { content: ' ▾'; font-size: .7em; color: var(--c-muted); }
.dropdown {
  position: absolute; top: 100%; left: 0; min-width: 260px;
  background: var(--c-white); border: 1px solid var(--c-border); border-radius: var(--radius);
  box-shadow: var(--shadow-lg); list-style: none; margin: 0; padding: .5rem;
  opacity: 0; visibility: hidden; transform: translateY(8px);
  transition: opacity .22s ease, transform .22s ease, visibility .22s;
}
.has-dropdown:hover .dropdown,
.has-dropdown:focus-within .dropdown,
.has-dropdown.open .dropdown { opacity: 1; visibility: visible; transform: translateY(0); }
.dropdown a {
  display: block; padding: .5rem .8rem; border-radius: 8px;
  text-decoration: none; font-size: .93rem; font-weight: 600; color: var(--c-dark-2);
}
.dropdown a:hover, .dropdown a[aria-current] { background: var(--c-primary-soft); color: var(--c-dark); }

/* Burger */
.nav-toggle {
  display: none; margin-left: auto;
  width: 46px; height: 46px; border: 0; background: none; cursor: pointer;
  flex-direction: column; justify-content: center; align-items: center; gap: 6px;
}
.nav-toggle span { display: block; width: 26px; height: 3px; background: var(--c-dark); border-radius: 2px; transition: transform .3s, opacity .3s; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(9px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-9px) rotate(-45deg); }

/* --------------------------------------------------------------------------
   Hero (Startseite)
   -------------------------------------------------------------------------- */
.hero { position: relative; color: #fff; overflow: hidden; }
.hero-bg {
  position: absolute; inset: 0; background-size: cover; background-position: center;
  animation: heroZoom 18s ease-out forwards;
}
.hero-bg::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(115deg, rgba(30,41,59,.92) 0%, rgba(30,41,59,.72) 45%, rgba(30,41,59,.35) 100%);
}
@keyframes heroZoom { from { transform: scale(1.08); } to { transform: scale(1); } }

.hero-inner { position: relative; padding: clamp(4.5rem, 10vw, 8.5rem) clamp(1rem, 4vw, 2rem); max-width: 860px; margin: 0; }
.hero-kicker {
  font-family: var(--f-hand); font-size: clamp(1.4rem, 2.6vw, 1.9rem); font-weight: 600;
  color: var(--c-primary); margin-bottom: .4rem;
}
.hero h1 { color: #fff; margin-bottom: .4em; }
.hero-sub { font-size: clamp(1.05rem, 2vw, 1.3rem); max-width: 620px; color: #E6EDF5; }
.hero-actions { display: flex; flex-wrap: wrap; gap: .9rem; margin-top: 1.6rem; }
.hero .btn-ghost { color: #fff; border-color: rgba(255,255,255,.65); }
.hero .btn-ghost:hover { border-color: var(--c-primary); color: var(--c-primary); }

.hero-wave { position: absolute; left: 0; right: 0; bottom: -1px; height: 56px;
  background: var(--c-white);
  clip-path: polygon(0 100%, 100% 100%, 100% 40%, 0 100%);
}

/* --------------------------------------------------------------------------
   Unterseiten-Hero
   -------------------------------------------------------------------------- */
.page-hero { position: relative; background: var(--c-light); padding: clamp(2.2rem, 5vw, 3.6rem) 0 clamp(1.6rem, 4vw, 2.6rem); overflow: hidden; }
.page-hero.has-image { color: #fff; }
.page-hero.has-image .hero-bg { position: absolute; inset: 0; background-size: cover; background-position: center; }
.page-hero.has-image .hero-bg::after { content: ''; position: absolute; inset: 0; background: linear-gradient(100deg, rgba(30,41,59,.9), rgba(30,41,59,.55)); }
.page-hero.has-image .wrap { position: relative; }
.page-hero.has-image h1, .page-hero.has-image .lead { color: #fff; }
.page-hero.has-image .breadcrumbs, .page-hero.has-image .breadcrumbs a { color: #D9E2EC; }

.lead { font-size: clamp(1.05rem, 2vw, 1.25rem); color: var(--c-muted); max-width: 760px; margin-top: .2rem; }

.breadcrumbs { font-size: .85rem; margin-bottom: .8rem; }
.breadcrumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: .35rem; margin: 0; padding: 0; }
.breadcrumbs li + li::before { content: '›'; margin-right: .35rem; color: var(--c-muted); }
.breadcrumbs a { text-decoration: none; color: var(--c-muted); }
.breadcrumbs a:hover { color: var(--c-primary-dark); }
.breadcrumbs [aria-current] { color: var(--c-dark); font-weight: 600; }

/* --------------------------------------------------------------------------
   Inhalt / Prosa
   -------------------------------------------------------------------------- */
.page-body, .section-body, .home-content { padding: clamp(1.8rem, 4vw, 3rem) 0; }

.content-prose { max-width: 820px; }
.content-prose h2 { margin-top: 1.8em; }
.content-prose h3 { margin-top: 1.4em; }
.content-prose ul { padding-left: 1.3rem; }
.content-prose li { margin-bottom: .4em; }
.content-prose blockquote {
  margin: 1.5em 0; padding: 1rem 1.4rem; background: var(--c-primary-soft);
  border-left: 4px solid var(--c-primary); border-radius: 0 var(--radius) var(--radius) 0;
}
.content-prose table { width: 100%; border-collapse: collapse; margin: 1.4em 0; font-size: .95rem; }
.content-prose th, .content-prose td { text-align: left; padding: .6rem .8rem; border-bottom: 1px solid var(--c-border); }
.content-prose th { font-family: var(--f-head); font-weight: 500; color: var(--c-dark); background: var(--c-light); }
.content-prose hr { border: 0; border-top: 1px solid var(--c-border); margin: 2.2em 0; }

/* Software-Hinweis-Box (per Markdown: > mit Link) nutzt blockquote-Stil */

/* Themen-Illustration auf Detailseiten: fließt rechts im Text */
.page-illu {
  float: right;
  width: min(46%, 400px);
  margin: .3rem 0 1.2rem 1.8rem;
}
.page-illu img { display: block; width: 100%; height: auto; }
@media (max-width: 700px) {
  .page-illu { float: none; width: 100%; max-width: 440px; margin: 0 auto 1.4rem; }
}
/* Nachfolgende Abschnitte nicht um die Illustration fließen lassen? Doch – bewusster Umfluss.
   Aber Tabellen brauchen volle Breite: */
.content-prose table { clear: both; }
.siblings { clear: both; }

/* --------------------------------------------------------------------------
   USP-Karten, Teaser, Cards
   -------------------------------------------------------------------------- */
.usps { padding: clamp(1.6rem, 4vw, 2.6rem) 0 0; }
.usp-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 1.1rem; }
.usp-card {
  background: var(--c-white); border: 1px solid var(--c-border); border-radius: var(--radius);
  padding: 1.4rem 1.3rem; box-shadow: var(--shadow);
  transition: transform .25s ease, box-shadow .25s ease;
}
.usp-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.usp-card h2 { font-size: 1.15rem; margin-bottom: .3em; }
.usp-card p { font-size: .93rem; color: var(--c-muted); margin: 0; }
.usp-icon { display: inline-grid; place-items: center; width: 46px; height: 46px; margin-bottom: .7rem;
  background: var(--c-primary-soft); color: var(--c-primary-dark); font-size: 1.4rem; }

.section-title { text-align: center; margin-bottom: clamp(1.4rem, 3vw, 2.2rem); }

.teasers, .steps { padding: clamp(2rem, 5vw, 3.5rem) 0; }
.teasers { background: var(--c-light); }

.teaser-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 1.4rem; }
.teaser-card {
  display: flex; flex-direction: column; background: var(--c-white); border-radius: var(--radius);
  overflow: hidden; text-decoration: none; box-shadow: var(--shadow);
  transition: transform .25s ease, box-shadow .25s ease;
}
.teaser-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-lg); }
.teaser-img { aspect-ratio: 16 / 9; overflow: hidden; }
.teaser-img img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.teaser-card:hover .teaser-img img { transform: scale(1.05); }
.teaser-body { padding: 1.2rem 1.3rem 1.4rem; }
.teaser-body h3 { margin-bottom: .35em; }
.teaser-body p { font-size: .95rem; color: var(--c-muted); }
.teaser-more { font-family: var(--f-hand); font-size: 1.25rem; font-weight: 600; color: var(--c-primary-dark); }

.card-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 1.3rem; padding-bottom: clamp(2rem, 5vw, 3.5rem); }
.card {
  background: var(--c-white); border: 1px solid var(--c-border); border-radius: var(--radius);
  padding: 1.5rem 1.4rem; text-decoration: none; box-shadow: var(--shadow);
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}
.card:hover { transform: translateY(-5px); box-shadow: var(--shadow-lg); border-color: var(--c-primary); }
.card h2 { font-size: 1.25rem; }
.card p { font-size: .95rem; color: var(--c-muted); }

/* Schritte */
.step-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1.3rem; counter-reset: step; }
.step-card { position: relative; background: var(--c-white); border: 1px solid var(--c-border); border-radius: var(--radius); padding: 1.6rem 1.4rem 1.4rem; box-shadow: var(--shadow); }
.step-num {
  display: inline-grid; place-items: center; width: 44px; height: 44px; margin-bottom: .8rem;
  background: var(--c-primary); color: var(--c-dark); font-family: var(--f-hand); font-size: 1.5rem; font-weight: 700;
}
.step-card h3 { margin-bottom: .3em; }
.step-card p { font-size: .95rem; color: var(--c-muted); margin: 0; }

/* --------------------------------------------------------------------------
   Geschwister-Navigation (interne Verlinkung)
   -------------------------------------------------------------------------- */
.siblings { background: var(--c-light); padding: clamp(1.6rem, 4vw, 2.4rem) 0; }
.siblings-title { font-size: 1.2rem; margin-bottom: .9rem; }
.sibling-list { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: .6rem; }
.sibling-list a {
  display: inline-block; padding: .45rem 1rem; background: var(--c-white);
  border: 1px solid var(--c-border); text-decoration: none;
  font-size: .9rem; font-weight: 600; color: var(--c-dark-2);
  transition: border-color .2s, color .2s, transform .2s;
}
.sibling-list a:hover { border-color: var(--c-primary); color: var(--c-primary-dark); transform: translateY(-2px); }
.sibling-up a { background: var(--c-primary-soft); border-color: var(--c-primary); }

/* --------------------------------------------------------------------------
   Kontakt-Band (Deftform auf jeder Seite)
   -------------------------------------------------------------------------- */
.contact-band { background: var(--c-dark); color: #E6EDF5; padding: clamp(2.4rem, 6vw, 4rem) 0; }
.contact-band-inner { display: grid; grid-template-columns: 1fr 1.2fr; gap: clamp(1.6rem, 4vw, 3rem); align-items: start; }
.contact-band h2 { color: #fff; font-size: clamp(1.6rem, 3vw, 2.2rem); }
.contact-band p { color: #C3CFDD; }
.check-list { list-style: none; margin: 1.2rem 0 0; padding: 0; }
.check-list li { padding-left: 1.7rem; position: relative; margin-bottom: .55rem; }
.check-list li::before { content: '✔'; position: absolute; left: 0; color: var(--c-primary); font-weight: 700; }
.contact-band-form { background: var(--c-white); border-radius: var(--radius); padding: 1.2rem; box-shadow: var(--shadow-lg); }

/* Kontaktseite */
.kontakt-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: clamp(1.6rem, 4vw, 3rem); align-items: start; }
.kontakt-card { background: var(--c-light); border-radius: var(--radius); padding: 1.8rem 1.6rem; box-shadow: var(--shadow); }
.kontakt-card h2 { font-size: 1.3rem; }
.kontakt-links .btn { margin: .3rem 0; }
.kontakt-hinweis { font-size: .9rem; color: var(--c-muted); margin-top: 1rem; }

/* --------------------------------------------------------------------------
   Footer
   -------------------------------------------------------------------------- */
.site-footer { background: var(--c-dark); color: #C3CFDD; margin-top: 0; }
.footer-grid { display: grid; grid-template-columns: 1.3fr 1fr 1fr 1fr 1fr; gap: 1.8rem; padding: clamp(2.4rem, 5vw, 3.6rem) clamp(1rem, 4vw, 2rem); }
.footer-col h3 { color: #fff; font-size: 1.05rem; margin-bottom: .8rem; }
.footer-col ul { list-style: none; margin: 0; padding: 0; }
.footer-col li { margin-bottom: .45rem; }
.footer-col a { color: #C3CFDD; text-decoration: none; font-size: .93rem; }
.footer-col a:hover { color: var(--c-primary); }
.footer-brand img { margin-bottom: .8rem; }
.footer-brand p { font-size: .93rem; }
.footer-brand a { color: #E6EDF5; }

.footer-bottom { border-top: 1px solid rgba(255,255,255,.12); }
.footer-bottom-inner { display: flex; flex-wrap: wrap; gap: .8rem; align-items: center; justify-content: space-between; padding-top: 1rem; padding-bottom: 1rem; font-size: .85rem; }
.footer-bottom p { margin: 0; }
.legal-nav { list-style: none; display: flex; gap: 1.2rem; margin: 0; padding: 0; }
.legal-nav a, .legal-nav .linklike { color: #C3CFDD; text-decoration: none; font-size: .85rem; }
.legal-nav a:hover, .legal-nav .linklike:hover { color: var(--c-primary); }

/* --------------------------------------------------------------------------
   Cookie-Banner
   -------------------------------------------------------------------------- */
.cookie-banner {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 300;
  padding: 1rem;
  animation: cookieUp .5s ease both;
}
@keyframes cookieUp { from { transform: translateY(100%); } to { transform: translateY(0); } }
.cookie-inner {
  max-width: 680px; margin: 0 auto; background: var(--c-white);
  border: 1px solid var(--c-border); border-radius: var(--radius);
  box-shadow: var(--shadow-lg); padding: 1.3rem 1.5rem;
}
.cookie-title { font-size: 1.15rem; margin-bottom: .4em; }
.cookie-inner p { font-size: .9rem; color: var(--c-muted); margin-bottom: 1rem; }
.cookie-actions { display: flex; flex-wrap: wrap; gap: .7rem; justify-content: flex-end; }

/* --------------------------------------------------------------------------
   Scroll-Reveal-Animationen
   -------------------------------------------------------------------------- */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity var(--speed) ease var(--d, 0ms), transform var(--speed) ease var(--d, 0ms); }
.reveal.in-view { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .hero-bg { animation: none; }
  * { transition-duration: .01ms !important; animation-duration: .01ms !important; }
}

/* --------------------------------------------------------------------------
   Responsive
   -------------------------------------------------------------------------- */
@media (max-width: 1300px) {
  .nav-item > a { padding: .8rem .5rem; font-size: .9rem; }
}

@media (max-width: 1024px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 1080px) {
  .nav-toggle { display: flex; }
  .site-nav {
    /* absolute statt fixed: backdrop-filter am Header macht ihn zum Containing Block */
    position: absolute; top: 100%; left: 0; right: 0; z-index: 90;
    height: calc(100vh - 72px);
    height: calc(100dvh - 72px);
    background: var(--c-white); overflow-y: auto; padding: 1rem clamp(1rem, 4vw, 2rem) 3rem;
    transform: translateX(100%); transition: transform .3s ease, visibility .3s;
    visibility: hidden;
  }
  .site-nav.open { visibility: visible; transform: translateX(0); }
  .nav-list { flex-direction: column; align-items: stretch; gap: 0; }
  .nav-item { border-bottom: 1px solid var(--c-border); position: relative; }
  .nav-item > a { padding: .95rem .2rem; font-size: 1.05rem; }
  .nav-cta { margin: 1rem 0 0; border: 0; }
  .nav-cta .btn-nav { display: block; text-align: center; font-size: 1.5rem; }

  .has-dropdown > a::after { content: ''; }
  .dd-toggle {
    display: block; position: absolute; top: .45rem; right: 0;
    width: 42px; height: 42px; border: 0; background: none; cursor: pointer;
  }
  .dd-toggle::before { content: '▾'; font-size: 1.1rem; color: var(--c-muted); display: inline-block; transition: transform .25s; }
  .dd-toggle[aria-expanded="true"]::before { transform: rotate(180deg); }
  .dropdown {
    position: static; min-width: 0; opacity: 1; visibility: hidden; transform: none;
    box-shadow: none; border: 0; padding: 0 0 .6rem .8rem; display: none;
  }
  .has-dropdown.open .dropdown { display: block; visibility: visible; }
}

@media (max-width: 860px) {
  .contact-band-inner, .kontakt-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 1.4rem; }
  .footer-bottom-inner { flex-direction: column; align-items: flex-start; }
}

@media (max-width: 480px) {
  .hero-actions .btn { width: 100%; text-align: center; }
}
