/* SBS Bildungsprojekte GmbH – Stylesheet (ohne externe Schriften, DSGVO-freundlich) */
:root {
  --yellow: #f6c945;
  --yellow-dark: #e0a800;
  --yellow-soft: #fff4c7;
  --cream: #fffbea;
  --ink: #2b2a26;
  --ink-soft: #57544a;
  --white: #ffffff;
  --line: #eadfae;
  --radius: 18px;
  --shadow: 0 10px 30px rgba(120, 90, 0, 0.12);
  --max: 1160px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color: var(--ink);
  background: var(--cream);
  line-height: 1.65;
  font-size: 1.05rem;
}
img, svg { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3, h4 { line-height: 1.2; margin: 0 0 .6em; letter-spacing: -0.01em; }
h1 { font-size: clamp(2.1rem, 5vw, 3.6rem); }
h2 { font-size: clamp(1.6rem, 3.2vw, 2.3rem); }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1em; }

.container { width: min(100% - 2.5rem, var(--max)); margin-inline: auto; }
.section { padding: clamp(3rem, 7vw, 5.5rem) 0; }
.section--soft { background: var(--yellow-soft); }
.eyebrow {
  display: inline-block;
  font-size: .85rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  background: var(--yellow); padding: .3em .9em; border-radius: 999px; margin-bottom: 1rem;
}
.lead { font-size: 1.2rem; color: var(--ink-soft); max-width: 62ch; }

.skip-link { position: absolute; left: -999px; top: 0; background: var(--ink); color: #fff; padding: .6rem 1rem; z-index: 200; }
.skip-link:focus { left: 0; }
:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; border-radius: 6px; }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(255, 251, 234, .92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 72px; }
.brand { display: flex; align-items: center; gap: .7rem; text-decoration: none; font-weight: 800; font-size: 1.15rem; }
.brand-mark {
  width: 42px; height: 42px; border-radius: 12px; background: var(--yellow);
  display: grid; place-items: center; font-weight: 900; box-shadow: var(--shadow);
}
.brand small { display: block; font-weight: 500; font-size: .75rem; color: var(--ink-soft); margin-top: -2px; }
.nav { display: flex; align-items: center; gap: .3rem; }
.nav a { text-decoration: none; padding: .55rem .9rem; border-radius: 999px; font-weight: 600; font-size: .98rem; }
.nav a:hover { background: var(--yellow-soft); }
.nav a[aria-current="page"] { background: var(--yellow); }
.nav .btn { margin-left: .4rem; }
.nav-toggle { display: none; background: var(--yellow); border: 0; border-radius: 12px; width: 46px; height: 46px; cursor: pointer; font-size: 1.3rem; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  background: var(--ink); color: #fff; text-decoration: none; border: 2px solid var(--ink);
  padding: .8rem 1.5rem; border-radius: 999px; font-weight: 700; font-size: 1rem; cursor: pointer;
  transition: transform .15s ease, background .15s ease, color .15s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn--yellow { background: var(--yellow); color: var(--ink); border-color: var(--yellow); }
.btn--yellow:hover { background: var(--yellow-dark); border-color: var(--yellow-dark); }
.btn--ghost { background: transparent; color: var(--ink); }
.btn--ghost:hover { background: var(--ink); color: #fff; }
.btn--small { padding: .55rem 1.1rem; font-size: .95rem; }

/* Hero */
.hero { position: relative; overflow: hidden; padding: clamp(3rem, 8vw, 6rem) 0; background: linear-gradient(135deg, var(--yellow) 0%, #fbe08a 55%, var(--cream) 100%); }
.hero-grid { display: grid; gap: 3rem; grid-template-columns: 1.15fr .85fr; align-items: center; }
.hero h1 span { background: linear-gradient(transparent 62%, rgba(255,255,255,.7) 62%); }
.hero-actions { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 1.6rem; }
.hero-card { background: var(--white); border-radius: var(--radius); padding: 1.8rem; box-shadow: var(--shadow); }
.hero-card ul { list-style: none; padding: 0; margin: 0; }
.hero-card li { display: flex; gap: .8rem; padding: .85rem 0; border-bottom: 1px dashed var(--line); }
.hero-card li:last-child { border: 0; }
.dot { flex: none; width: 34px; height: 34px; border-radius: 50%; background: var(--yellow); display: grid; place-items: center; font-weight: 800; }
.blob { position: absolute; border-radius: 50%; background: rgba(255,255,255,.35); pointer-events: none; }
.blob--1 { width: 420px; height: 420px; right: -120px; top: -140px; }
.blob--2 { width: 240px; height: 240px; left: -80px; bottom: -100px; }

/* Cards */
.grid { display: grid; gap: 1.5rem; }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--2 { grid-template-columns: repeat(2, 1fr); }
.card {
  background: var(--white); border-radius: var(--radius); padding: 1.8rem;
  border: 1px solid var(--line); box-shadow: var(--shadow); transition: transform .2s ease;
}
.card:hover { transform: translateY(-4px); }
.card .icon { width: 56px; height: 56px; border-radius: 16px; background: var(--yellow); display: grid; place-items: center; font-size: 1.6rem; margin-bottom: 1rem; }
.card ul { padding-left: 1.2rem; margin: 0 0 1rem; }
.card li { margin-bottom: .3rem; }
.link-arrow { font-weight: 700; text-decoration: none; border-bottom: 3px solid var(--yellow); }
.link-arrow:hover { background: var(--yellow); }

.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; text-align: center; }
.stat { background: var(--white); border-radius: var(--radius); padding: 1.4rem 1rem; border: 1px solid var(--line); }
.stat strong { display: block; font-size: 2rem; }

.steps { counter-reset: step; display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.2rem; }
.step { background: var(--white); border-radius: var(--radius); padding: 1.5rem; border: 1px solid var(--line); position: relative; }
.step::before {
  counter-increment: step; content: counter(step);
  display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%;
  background: var(--yellow); font-weight: 800; margin-bottom: .8rem;
}

.cta-band { background: var(--ink); color: #fff; border-radius: 28px; padding: clamp(2rem, 5vw, 3.5rem); display: flex; flex-wrap: wrap; gap: 1.5rem; align-items: center; justify-content: space-between; }
.cta-band h2 { margin: 0; }
.cta-band p { margin: .4rem 0 0; color: #ddd; }

/* Page header (Unterseiten) */
.page-head { background: linear-gradient(135deg, var(--yellow), #fbe08a); padding: clamp(2.5rem, 6vw, 4.5rem) 0; }
.page-head p { max-width: 62ch; margin: 0; font-size: 1.15rem; }
.breadcrumb { font-size: .9rem; margin-bottom: 1rem; }
.breadcrumb a { text-underline-offset: 3px; }

/* Maßnahmen-Detail */
.detail { display: grid; gap: 2.5rem; grid-template-columns: 1fr 340px; align-items: start; }
.detail aside { position: sticky; top: 96px; }
.facts { background: var(--yellow-soft); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.5rem; }
.facts dl { margin: 0; }
.facts dt { font-weight: 800; font-size: .85rem; text-transform: uppercase; letter-spacing: .05em; margin-top: .9rem; }
.facts dd { margin: .1rem 0 0; }
.check { list-style: none; padding: 0; }
.check li { padding-left: 2rem; position: relative; margin-bottom: .6rem; }
.check li::before { content: "✓"; position: absolute; left: 0; top: 0; width: 1.4rem; height: 1.4rem; border-radius: 50%; background: var(--yellow); display: grid; place-items: center; font-size: .85rem; font-weight: 800; }
.option-box { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin: 1.5rem 0; }
.option { border: 2px solid var(--yellow); border-radius: var(--radius); padding: 1.3rem; background: var(--white); }
.measure { padding: 2.5rem 0; border-bottom: 1px solid var(--line); scroll-margin-top: 90px; }
.measure:last-child { border: 0; }
.notice { background: var(--white); border-left: 6px solid var(--yellow-dark); border-radius: 12px; padding: 1rem 1.3rem; font-size: .95rem; }

details { background: var(--white); border: 1px solid var(--line); border-radius: 14px; padding: 1rem 1.3rem; margin-bottom: .8rem; }
summary { cursor: pointer; font-weight: 700; }
details[open] summary { margin-bottom: .6rem; }

/* Formular */
.form-wrap { display: grid; grid-template-columns: 1.2fr .8fr; gap: 2.5rem; align-items: start; }
form .field { margin-bottom: 1.2rem; }
label { display: block; font-weight: 700; margin-bottom: .35rem; }
input[type="text"], input[type="email"], input[type="tel"], select, textarea {
  width: 100%; padding: .85rem 1rem; font: inherit; color: var(--ink);
  border: 2px solid var(--line); border-radius: 12px; background: var(--white);
}
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--yellow-dark); box-shadow: 0 0 0 4px rgba(246, 201, 69, .4); }
textarea { min-height: 160px; resize: vertical; }
.row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.checkbox { display: flex; gap: .7rem; align-items: flex-start; font-weight: 400; }
.checkbox input { margin-top: .35rem; width: 20px; height: 20px; accent-color: var(--yellow-dark); flex: none; }
.hp { position: absolute; left: -9999px; height: 0; overflow: hidden; }
.form-status { margin-top: 1rem; padding: 1rem 1.2rem; border-radius: 12px; display: none; font-weight: 600; }
.form-status.ok { display: block; background: #e6f6d8; border: 1px solid #9ccc6a; }
.form-status.err { display: block; background: #fde3df; border: 1px solid #e58a7e; }
.required { color: #a35a00; }
.contact-box { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.8rem; box-shadow: var(--shadow); }
.contact-box p { margin-bottom: .8rem; }

/* Rechtstexte */
.legal { max-width: 820px; }
.legal h2 { margin-top: 2.2rem; font-size: 1.5rem; }
.legal h3 { margin-top: 1.5rem; font-size: 1.15rem; }
.legal ul { padding-left: 1.3rem; }
.placeholder { background: #fff0a8; padding: 0 .3em; border-radius: 4px; }

/* Footer */
.site-footer { background: var(--ink); color: #eee; padding: 3.5rem 0 1.5rem; margin-top: 0; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 2rem; }
.site-footer h4 { color: var(--yellow); font-size: 1rem; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: .45rem; }
.site-footer a { text-decoration: none; }
.site-footer a:hover { color: var(--yellow); text-decoration: underline; }
.footer-bottom { border-top: 1px solid #4b493f; margin-top: 2.5rem; padding-top: 1.2rem; font-size: .9rem; color: #bbb; display: flex; flex-wrap: wrap; gap: 1rem; justify-content: space-between; }
.link-button { background: none; border: 0; color: inherit; font: inherit; padding: 0; cursor: pointer; text-decoration: underline; }
.link-button:hover { color: var(--yellow); }

/* Cookie-Popup */
.cookie-overlay { position: fixed; inset: 0; background: rgba(43, 42, 38, .55); z-index: 500; display: none; align-items: flex-end; justify-content: center; padding: 1rem; }
.cookie-overlay.is-open { display: flex; }
.cookie-box {
  width: min(100%, 640px); background: var(--white); border-radius: 24px; padding: 1.8rem;
  box-shadow: 0 25px 60px rgba(0,0,0,.35); border-top: 8px solid var(--yellow);
  animation: pop .3s ease;
}
@keyframes pop { from { transform: translateY(30px); opacity: 0; } to { transform: none; opacity: 1; } }
.cookie-box h2 { font-size: 1.4rem; margin-bottom: .5rem; }
.cookie-box p { font-size: .97rem; color: var(--ink-soft); }
.cookie-options { margin: 1rem 0; display: none; }
.cookie-options.is-open { display: block; }
.cookie-opt { display: flex; justify-content: space-between; gap: 1rem; align-items: flex-start; padding: .8rem 0; border-bottom: 1px dashed var(--line); font-size: .95rem; }
.cookie-opt strong { display: block; }
.cookie-actions { display: flex; flex-wrap: wrap; gap: .7rem; margin-top: 1rem; }
.cookie-actions .btn { flex: 1 1 auto; }
.switch { position: relative; width: 48px; height: 28px; flex: none; }
.switch input { opacity: 0; width: 100%; height: 100%; position: absolute; margin: 0; cursor: pointer; z-index: 1; }
.switch span { position: absolute; inset: 0; background: #ccc; border-radius: 999px; transition: background .2s; }
.switch span::after { content: ""; position: absolute; width: 22px; height: 22px; left: 3px; top: 3px; border-radius: 50%; background: #fff; transition: transform .2s; }
.switch input:checked + span { background: var(--yellow-dark); }
.switch input:checked + span::after { transform: translateX(20px); }
.switch input:disabled { cursor: not-allowed; }
.switch input:disabled + span { opacity: .6; }

/* Responsive */
@media (max-width: 960px) {
  .hero-grid, .detail, .form-wrap { grid-template-columns: 1fr; }
  .detail aside { position: static; }
  .grid--3, .steps, .stats { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 760px) {
  .nav-toggle { display: block; }
  .nav {
    position: absolute; left: 0; right: 0; top: 72px; background: var(--cream);
    flex-direction: column; align-items: stretch; padding: 1rem 1.25rem 1.5rem;
    border-bottom: 1px solid var(--line); display: none;
  }
  .nav.is-open { display: flex; }
  .nav .btn { margin: .5rem 0 0; }
  .grid--3, .grid--2, .steps, .stats, .option-box, .row, .footer-grid { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

/* Kacheln (Unterseiten) */
.tiles { align-items: start; }
.tile .tags { display: flex; flex-wrap: wrap; gap: .4rem; margin-bottom: .6rem; min-height: 1.6rem; }
.tag { background: var(--yellow-soft); border: 1px solid var(--line); border-radius: 999px; padding: .1rem .7rem; font-size: .78rem; font-weight: 700; }
.tile details { background: transparent; border: 0; border-top: 1px dashed var(--line); border-radius: 0; padding: .9rem 0 0; margin: 1rem 0 0; }
.tile summary { color: var(--ink); list-style: none; display: inline-flex; align-items: center; gap: .4rem; background: var(--yellow); padding: .45rem 1rem; border-radius: 999px; font-size: .95rem; }
.tile summary::-webkit-details-marker { display: none; }
.tile summary::after { content: "▾"; transition: transform .2s; }
.tile details[open] summary::after { transform: rotate(180deg); }
.tile-detail { margin-top: 1rem; }
.tile-facts { background: var(--yellow-soft); border-radius: 12px; padding: .8rem 1rem; margin: 1rem 0; }
.tile-facts dt { font-size: .78rem; font-weight: 800; text-transform: uppercase; letter-spacing: .05em; margin-top: .6rem; }
.tile-facts dt:first-child { margin-top: 0; }
.tile-facts dd { margin: 0; }

/* Navigation mit 5 Punkten: früher einklappen */
@media (min-width: 761px) and (max-width: 1100px) {
  .nav-toggle { display: block; }
  .nav { position: absolute; left: 0; right: 0; top: 72px; background: var(--cream); flex-direction: column; align-items: stretch; padding: 1rem 1.25rem 1.5rem; border-bottom: 1px solid var(--line); display: none; }
  .nav.is-open { display: flex; }
  .nav .btn { margin: .5rem 0 0; }
}
@media (min-width: 1101px) { .nav a { padding: .55rem .7rem; font-size: .95rem; } }

/* Logo */
.site-header { background: rgba(255, 255, 255, .96); }
.brand-logo { height: 56px; width: auto; display: block; }
.footer-logo { height: 64px; width: auto; background: #fff; border-radius: 12px; padding: .4rem .8rem; margin-bottom: 1rem; }
@media (max-width: 760px) { .brand-logo { height: 46px; } }

/* Standorte */
.loc-jump { display: flex; flex-wrap: wrap; gap: .6rem; }
.loc-jump a { text-decoration: none; background: var(--white); border: 1px solid var(--line); padding: .45rem 1rem; border-radius: 999px; font-weight: 700; font-size: .95rem; }
.loc-jump a:hover { background: var(--yellow); }
.location { scroll-margin-top: 96px; }
.loc-head { display: flex; gap: 1rem; align-items: flex-start; margin-bottom: 1rem; }
.loc-no { flex: none; width: 48px; height: 48px; border-radius: 14px; background: var(--yellow); display: grid; place-items: center; font-weight: 900; font-size: 1.3rem; }
.loc-head h3 { margin: 0 0 .2rem; }
.loc-sub { margin: 0; color: var(--ink-soft); font-size: .95rem; }
.loc-facts { margin: 0 0 1.2rem; }
.loc-facts dt { font-size: .78rem; font-weight: 800; text-transform: uppercase; letter-spacing: .05em; margin-top: .8rem; }
.loc-facts dd { margin: .1rem 0 0; }
.loc-actions { display: flex; flex-wrap: wrap; gap: .6rem; }
.loc-note { background: var(--yellow-soft); display: flex; flex-direction: column; justify-content: center; align-items: flex-start; }
.loc-note:hover, .location:hover { transform: none; }
@media (min-width: 761px) and (max-width: 1240px) {
  .nav-toggle { display: block; }
  .nav { position: absolute; left: 0; right: 0; top: 72px; background: var(--cream); flex-direction: column; align-items: stretch; padding: 1rem 1.25rem 1.5rem; border-bottom: 1px solid var(--line); display: none; }
  .nav.is-open { display: flex; }
  .nav .btn { margin: .5rem 0 0; }
}
