/* ===== Schrift (lokal, DSGVO-konform) ===== */
@font-face { font-family: "Barlow"; src: url("../fonts/barlow-400.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Barlow"; src: url("../fonts/barlow-600.woff2") format("woff2"); font-weight: 600; font-style: normal; font-display: swap; }
@font-face { font-family: "Barlow"; src: url("../fonts/barlow-700.woff2") format("woff2"); font-weight: 700; font-style: normal; font-display: swap; }

/* ===== CI-Farben ===== */
:root {
  --orange: #F78F14;
  --blau: #0E3674;
  --blau-dunkel: #0A2754;
  --text: #1F2328;
  --text-hell: #5B6470;
  --grau: #F4F5F7;
  --rand: #E2E5EA;
  --radius: 10px;
}

/* ===== Grundlagen ===== */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 90px; }
body { margin: 0; font-family: "Barlow", system-ui, -apple-system, "Segoe UI", Arial, sans-serif;
       font-size: 1.0625rem; line-height: 1.6; color: var(--text); background: #fff; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--blau); }
h1, h2, h3 { line-height: 1.15; margin: 0 0 .6em; font-weight: 700; }
.container { max-width: 1160px; margin: 0 auto; padding: 0 1.25rem; }
.section { padding: 5rem 0; }
.section-alt { background: var(--grau); }
.section-head { max-width: 680px; margin-bottom: 2.5rem; }
.section-head h2 { font-size: clamp(1.8rem, 3vw, 2.5rem); color: var(--blau); }
.nowrap { white-space: nowrap; }

/* ===== Unterüberschrift mit Muttersymbol (CI-Orange) ===== */
.eyebrow { display: flex; align-items: center; gap: .6rem; font-weight: 600; text-transform: uppercase;
           letter-spacing: .08em; font-size: .85rem; color: var(--blau); margin: 0 0 .75rem; }
.eyebrow::before {
  content: ""; flex: none; width: 1.7em; height: 1.7em;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100' fill='none' stroke='%23F78F14' stroke-width='6'%3E%3Cpolygon points='50,4 89.8,27 89.8,73 50,96 10.2,73 10.2,27'/%3E%3Ccircle cx='50' cy='50' r='39'/%3E%3Ccircle cx='50' cy='50' r='12'/%3E%3Cpath d='M32 57 A18 18 0 0 1 50 32 A19 19 0 0 1 69 51 A20 20 0 0 1 48 71'/%3E%3C/svg%3E") center / contain no-repeat;
}

/* ===== Buttons ===== */
.btn { display: inline-block; padding: .85rem 1.5rem; border-radius: 6px; font-weight: 600;
       text-decoration: none; transition: background .2s, transform .2s; }
.btn-primary { background: var(--orange); color: var(--text); }
.btn-primary:hover { background: #FFA33A; transform: translateY(-1px); }
.btn-outline { border: 2px solid #fff; color: #fff; }
.btn-outline:hover { background: rgba(255,255,255,.1); }

/* ===== Kopfzeile ===== */
.site-header { position: sticky; top: 0; z-index: 100; background: #fff; border-bottom: 1px solid var(--rand); }
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 80px; }
.logo img { height: 64px; width: auto; }
.main-nav { display: flex; align-items: center; gap: 2rem; }
.main-nav a { text-decoration: none; color: var(--text); font-weight: 600; }
.main-nav a:not(.btn):hover { color: var(--blau); }
.nav-toggle, .nav-toggle-label { display: none; }

/* ===== Hero ===== */
.hero { background: var(--blau); color: #fff; padding: 6rem 0 5rem; position: relative; overflow: hidden; }
.hero .container { position: relative; z-index: 1; }
.hero .eyebrow { color: var(--orange); }
.hero h1 { font-size: clamp(2rem, 4.2vw, 3.1rem); max-width: 860px; }
.hero h1 span { color: var(--orange); }
.lead { font-size: 1.2rem; max-width: 640px; opacity: .9; margin: 0 0 2rem; }
.hero-actions { display: flex; gap: 1rem; flex-wrap: wrap; }
.hero-deco { position: absolute; right: -40px; top: 50%; transform: translateY(-50%);
             width: 480px; color: var(--orange); opacity: .15; pointer-events: none; }

/* ===== Sortiment: Drehkarten ===== */
.grid { display: grid; gap: 1.5rem; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.icon { width: 56px; height: 56px; color: var(--orange); margin-bottom: 1rem; }

.flip-card { perspective: 1200px; cursor: pointer; border-radius: var(--radius); outline: none; }
.flip-inner { display: grid; height: 100%; transition: transform .6s ease; transform-style: preserve-3d; }
.flip-card.is-flipped .flip-inner { transform: rotateY(180deg); }

.flip-front, .flip-back { grid-area: 1 / 1; backface-visibility: hidden; -webkit-backface-visibility: hidden;
                          border-radius: var(--radius); }
.flip-front { background: #fff; border: 1px solid var(--rand); border-top: 4px solid var(--orange);
              padding: 1.75rem; display: flex; flex-direction: column; transition: box-shadow .2s; }
.flip-front h3 { color: var(--blau); font-size: 1.3rem; }
.flip-front p { margin: 0 0 1rem; }
.flip-hint { margin-top: auto; font-size: .9rem; font-weight: 600; color: var(--blau); }

.flip-back { transform: rotateY(180deg); overflow: hidden; border-top: 4px solid var(--orange);
             background: var(--grau); }
.flip-back img { width: 100%; height: 100%; object-fit: cover; }

.flip-card:hover .flip-front { box-shadow: 0 10px 30px rgba(14,54,116,.12); }
.flip-card:focus-visible { box-shadow: 0 0 0 3px var(--orange); }

/* ===== Leistungen (dunkel) ===== */
.section-dark { background: var(--blau); color: #fff; }
.section-dark .section-head h2, .section-dark .eyebrow { color: #fff; }
.steps { display: grid; gap: 2rem; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.step-nr { font-size: 2.5rem; font-weight: 700; color: var(--orange); line-height: 1; }
.step h3 { margin-top: .5rem; }
.step p { opacity: .9; margin: 0; }

/* ===== Über uns ===== */
.about { display: grid; gap: 3rem; grid-template-columns: 1.4fr 1fr; align-items: start; }
.about h2 { font-size: clamp(1.8rem, 3vw, 2.5rem); color: var(--blau); }

/* Zeitstrahl */
.timeline { list-style: none; margin: 2rem 0 0; padding: 0; border-left: 3px solid var(--orange); }
.timeline li { position: relative; padding: 0 0 1.5rem 1.5rem; }
.timeline li:last-child { padding-bottom: 0; }
.timeline li::before { content: ""; position: absolute; left: -9px; top: .3rem;
                       width: 15px; height: 15px; border-radius: 50%;
                       background: #fff; border: 3px solid var(--blau); }
.timeline .year { display: block; font-weight: 700; color: var(--blau); font-size: 1.15rem; line-height: 1.2; }
.timeline li.today::before { background: var(--orange); border-color: var(--orange); }
.timeline li.today .year { color: var(--orange); }

/* Ausklappbare Bilder im Zeitstrahl */
.tl-more { margin-top: .5rem; }
.tl-more summary { display: inline-flex; align-items: center; gap: .5rem; cursor: pointer;
                   font-weight: 600; font-size: .95rem; color: var(--blau); list-style: none; }
.tl-more summary::-webkit-details-marker { display: none; }
.tl-more summary::before { content: "+"; display: inline-grid; place-items: center; width: 20px; height: 20px;
                           border-radius: 50%; background: var(--orange); color: var(--text);
                           font-weight: 700; font-size: .9rem; line-height: 1; }
.tl-more[open] summary::before { content: "–"; }
.tl-more summary:hover { text-decoration: underline; }

.tl-img { margin: .75rem 0 .25rem; max-width: 340px; }
.tl-img img, .tl-img svg { width: 100%; height: auto; display: block; border-radius: 8px;
                           box-shadow: 0 6px 20px rgba(0,0,0,.12); }
.tl-map { max-width: 400px; }
.tl-img figcaption { font-size: .9rem; color: var(--text-hell); margin-top: .5rem; }

/* Infokasten mit Porträt */
.facts { background: #fff; border-radius: var(--radius); padding: 2rem; border-left: 4px solid var(--orange);
         position: sticky; top: 110px; }
.portrait { margin: 0 0 1.5rem; }
.portrait img { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; border-radius: 8px; }
.portrait figcaption { margin-top: .75rem; line-height: 1.4; }
.portrait strong { color: var(--blau); font-size: 1.15rem; }
.facts dl { margin: 0; }
.facts dt { font-weight: 600; color: var(--blau); }
.facts dd { margin: 0 0 1rem; }

/* ===== Kontakt ===== */
.contact-grid { display: grid; gap: 1.5rem; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); }
.contact-item h3 { font-size: 1.1rem; color: var(--blau); margin-bottom: .4rem; }
.contact-item p { margin: 0; }
.cta-box { margin-top: 3rem; background: var(--blau); color: #fff; border-radius: var(--radius);
           padding: 2.5rem; display: flex; flex-wrap: wrap; gap: 1.5rem; align-items: center; justify-content: space-between; }
.cta-box h3 { margin: 0; font-size: 1.5rem; }

/* ===== Rechtliche Seiten (Impressum, Datenschutz) ===== */
.legal { max-width: 760px; }
.legal h1 { color: var(--blau); font-size: clamp(2rem, 4vw, 2.6rem); }
.legal h2 { color: var(--blau); font-size: 1.3rem; margin-top: 2.5rem; }
.legal h3 { color: var(--blau); font-size: 1.1rem; margin-top: 1.75rem; }
.legal p, .legal ul { margin: 0 0 1rem; }

/* ===== Fußzeile ===== */
.site-footer { background: var(--blau-dunkel); color: rgba(255,255,255,.8); padding: 2rem 0; font-size: .95rem; }
.footer-inner { display: flex; flex-wrap: wrap; gap: 1rem; justify-content: space-between; }
.site-footer a { color: #fff; text-decoration: none; margin-left: 1.5rem; }
.site-footer a:hover { text-decoration: underline; }

/* ===== Reduzierte Bewegung ===== */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .flip-inner { transition: none; }
}

/* ===== Mobil ===== */
@media (max-width: 860px) {
  .section { padding: 3.5rem 0; }
  .hero { padding: 4rem 0; }
  .hero-deco { width: 300px; right: -110px; }
  .about { grid-template-columns: 1fr; }
  .facts { position: static; }
  .portrait img { max-width: 320px; }
  .logo img { height: 52px; }

  .nav-toggle-label { display: block; width: 44px; height: 44px; cursor: pointer; position: relative; }
  .nav-toggle-label span, .nav-toggle-label span::before, .nav-toggle-label span::after {
    content: ""; position: absolute; width: 24px; height: 2px; background: var(--text); }
  .nav-toggle-label span { top: 21px; left: 10px; }
  .nav-toggle-label span::before { top: -7px; left: 0; }
  .nav-toggle-label span::after { top: 7px; left: 0; }

  .main-nav { display: none; position: absolute; top: 80px; left: 0; right: 0; background: #fff;
              flex-direction: column; align-items: stretch; gap: 0; padding: 1rem 1.25rem;
              border-bottom: 1px solid var(--rand); }
  .nav-toggle:checked ~ .main-nav { display: flex; }
  .main-nav a { padding: .75rem 0; }
  .main-nav .btn { text-align: center; margin-top: .5rem; }
}