/* ==========================================================================
   Steuerberater Lars Falke – Stylesheet
   Eine Datei für alle Seiten. Keine Frameworks, keine externen Abhängigkeiten.
   ========================================================================== */

/* ---------- Schrift (lokal eingebunden, DSGVO-konform) ----------
   Jost als zugeschnittene Web-Schrift (.woff, nur lateinische Zeichen).
   Die .ttf-Dateien dienen als Reserve, falls die .woff-Datei fehlt. */
@font-face {
  font-family: "Jost";
  src: url("../fonts/Jost-latin.woff") format("woff"),
       url("../fonts/Jost-VariableFont_wght.ttf") format("truetype");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}
/* Kursiv (z. B. "Spruch des Monats" auf der Aktuelles-Seite); wird nur geladen, wenn kursiver Text vorkommt */
@font-face {
  font-family: "Jost";
  src: url("../fonts/Jost-Italic-latin.woff") format("woff"),
       url("../fonts/Jost-Italic-VariableFont_wght.ttf") format("truetype");
  font-weight: 100 900;
  font-style: italic;
  font-display: swap;
}

/* ---------- Farben & Grundwerte ---------- */
:root {
  --blau: #011383;          /* Kanzleifarbe aus dem Logo */
  --blau-hell: #B8C0F0;     /* Text auf Blau */
  --blau-flaeche: #EEF0FA;  /* helle Hintergrundflächen */
  --blau-linie: #C9CFEA;
  --schwarz: #0A0B0D;
  --text: #2E3742;
  --text-leise: #4A5562;
  --linie: #E3E6EA;
  --rot: #C8102E;           /* nur für den Hinweis */
  --weiss: #FFFFFF;
  --breite: 1160px;
  --schrift: "Jost", "Futura", "Century Gothic", "Avenir Next", system-ui, sans-serif;
}

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

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  font-family: var(--schrift);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--schwarz);
  background: var(--weiss);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
body > main { flex: 1 0 auto; }

img, video { display: block; max-width: 100%; }

a { color: var(--blau); }
a:hover { color: var(--schwarz); }
:focus-visible { outline: 3px solid var(--blau); outline-offset: 3px; }

h1, h2, h3, h4 { line-height: 1.15; margin: 0; hyphens: auto; overflow-wrap: break-word; }

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

.skip-link {
  position: absolute; left: 16px; top: -60px; z-index: 30;
  background: var(--blau); color: var(--weiss); padding: 10px 16px;
}
.skip-link:focus { top: 16px; color: var(--weiss); }

/* ---------- Kopfbereich ---------- */
/* Kopfzeile bleibt beim Scrollen oben stehen */
.site-header {
  position: sticky; top: 0; z-index: 20;
  border-bottom: 1px solid var(--linie); background: var(--weiss);
  box-shadow: 0 2px 12px rgba(10, 11, 13, 0.06);
}
/* Sprungziele (#leistungen, #kontakt …) nicht unter der Kopfzeile verstecken */
html { scroll-padding-top: 110px; }
.site-header .container {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: 16px; padding-top: 22px; padding-bottom: 22px;
}

.nav { display: flex; flex-wrap: wrap; gap: 8px 12px; font-size: 0.95rem; font-weight: 500; }
.nav a { position: relative; color: var(--schwarz); text-decoration: none; padding: 6px 12px; border-bottom: 2px solid transparent; }
.nav a:hover { color: var(--blau); }
.nav a[aria-current="page"] { color: var(--blau); border-bottom-color: var(--blau); }

/* Beim Darüberfahren zeichnet sich ein Rahmen: erst oben + rechts, dann unten + links */
.nav a::before, .nav a::after {
  content: ""; position: absolute; width: 0; height: 0; pointer-events: none;
  border: 1px solid transparent; box-sizing: border-box;
}
.nav a::before { top: 0; left: 0; }
.nav a::after  { bottom: 0; right: 0; }
.nav a:not([aria-current]):hover::before, .nav a:not([aria-current]):focus-visible::before {
  width: 100%; height: 100%; border-top-color: var(--blau); border-right-color: var(--blau);
  transition: width 0.18s ease-out, height 0.18s ease-out 0.18s;
}
.nav a:not([aria-current]):hover::after, .nav a:not([aria-current]):focus-visible::after {
  width: 100%; height: 100%; border-bottom-color: var(--blau); border-left-color: var(--blau);
  transition: border-color 0s 0.36s, width 0.18s ease-out 0.36s, height 0.18s ease-out 0.54s;
}
@media (prefers-reduced-motion: reduce) {
  .nav a:not([aria-current]):hover::before, .nav a:not([aria-current]):hover::after, .nav a:not([aria-current]):focus-visible::before, .nav a:not([aria-current]):focus-visible::after { transition: none; }
}

/* ---------- Intro: Logo-Animation (CSS statt Video) ----------
   1. Umrisse des Zeichens zeichnen sich   2. Flächen füllen sich
   3. Zeichen rückt nach links             4. Trennstrich wächst
   5. Schriftzug erscheint von links nach rechts */
.intro-logo { display: block; width: min(680px, 100%); height: auto; margin: 0 auto; padding: clamp(48px, 8vw, 110px) 0; overflow: visible; }
.intro-flaeche { stroke-width: 2.4; stroke-linejoin: round; }
.intro-flaeche--blau    { fill: #011383; stroke: #011383; }
.intro-flaeche--schwarz { fill: #000000; stroke: #000000; }
.intro-strich { fill: #011383; }
.intro-text--name  { fill: #011383; }
.intro-text--beruf { fill: #000000; }

.intro-flaeche {
  stroke-dasharray: 1; stroke-dashoffset: 1; fill-opacity: 0;
  animation: intro-linie 1s 0.2s ease-in-out both, intro-fuellen 0.5s 1s ease-out both;
}
.intro-flaeche--schwarz { animation-delay: 0.35s, 1.1s; }
.intro-zeichen { transform: translateX(196px); animation: intro-rutschen 0.7s 1.4s cubic-bezier(.6,0,.2,1) both; }
.intro-strich { transform-box: fill-box; transform-origin: center; animation: intro-strich 0.35s 1.9s ease-out both; }
.intro-text { animation: intro-schrift 0.8s ease-out both; }
.intro-text--name  { animation-delay: 2s; }
.intro-text--beruf { animation-delay: 2.25s; }

@keyframes intro-linie   { from { stroke-dashoffset: 1; } to { stroke-dashoffset: 0; } }
@keyframes intro-fuellen { from { fill-opacity: 0; stroke-opacity: 1; } to { fill-opacity: 1; stroke-opacity: 0; } }
@keyframes intro-rutschen { from { transform: translateX(196px); } to { transform: translateX(0); } }
@keyframes intro-strich  { from { transform: scaleY(0); } to { transform: scaleY(1); } }
@keyframes intro-schrift { from { clip-path: inset(-10% 100% -10% 0); } to { clip-path: inset(-10% 0 -10% 0); } }

/* Übergang vom Intro in die Kopfzeile (gesteuert von assets/js/intro.js) */
.js-intro .logo-loop--kopf { opacity: 0; transition: opacity 0.35s ease; }
/* Notfall: falls das Skript nicht lädt, erscheint das Logo trotzdem nach 6 Sekunden */
.js-intro:not(.intro-fertig) .logo-loop--kopf { animation: kopf-notfall 0.35s 6s forwards; }
@keyframes kopf-notfall { to { opacity: 1; } }
.js-intro.intro-fertig .logo-loop--kopf { opacity: 1; }
.intro { overflow: hidden; }
.intro--zu { transition: height 0.9s cubic-bezier(.6,0,.2,1); }
.intro-flug {
  position: fixed; z-index: 40; margin: 0; pointer-events: none;
  transform-origin: 0 0; transition: transform 0.9s cubic-bezier(.6,0,.2,1), opacity 0.35s ease;
}
/* Während des Flugs das fertige Logo zeigen (Animation nicht neu starten) */
.intro-flug .intro-flaeche, .intro-flug .intro-zeichen, .intro-flug .intro-strich, .intro-flug .intro-text { animation: none; }
.intro-flug .intro-flaeche { stroke-dashoffset: 0; fill-opacity: 1; stroke-opacity: 0; }
.intro-flug .intro-zeichen { transform: none; }

@media (prefers-reduced-motion: reduce) {
  .intro-flaeche, .intro-zeichen, .intro-strich, .intro-text { animation: none; }
  .intro-flaeche { stroke-dashoffset: 0; fill-opacity: 1; stroke-opacity: 0; }
  .intro-zeichen { transform: none; }
}

/* ---------- Blaue Bühne ---------- */
.hero { background: var(--blau); color: var(--weiss); }
/* Erste Zeile: Hinweis-Label links, Buttons rechtsbündig. Zweite Zeile: Überschrift in voller Breite. */
.hero .container {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: 48px 40px; padding-top: 56px; padding-bottom: 96px;
}
.hero__hinweis { order: 1; flex: 0 1 auto; }
.hero__aktionen { order: 2; flex: 0 0 auto; margin-left: auto; display: flex; flex-wrap: wrap; gap: 16px; }
.hero__text { order: 3; flex: 1 1 100%; min-width: 0; }
.hero__aktionen { gap: 12px; }
.hero__aktionen .button { padding: 10px 20px; font-size: 0.95rem; }
@media (max-width: 1000px) {
  .hero__aktionen { margin-left: 0; flex: 1 1 100%; }
}
.hero h1 { font-weight: 600; font-size: clamp(1.65rem, 3.4vw, 2.35rem); line-height: 1.08; letter-spacing: -0.025em; }

.kicker { margin: 0 0 20px; font-size: 0.875rem; color: var(--blau-hell); }

/* ---------- Buttons ---------- */
.button {
  display: inline-block; text-decoration: none; font-weight: 600;
  padding: 14px 26px; border: 1px solid transparent; line-height: 1.3;
}
.button--weiss { background: var(--weiss); color: var(--blau); }
.button--weiss:hover { background: var(--blau-flaeche); color: var(--blau); }
.button--rahmen { border-color: var(--weiss); color: var(--weiss); font-weight: 500; }
.button--rahmen:hover { background: var(--weiss); color: var(--blau); }
.button--blau { background: var(--blau); color: var(--weiss); }
.button--blau:hover { background: var(--schwarz); color: var(--weiss); }

/* Rahmen, der sich beim Darüberfahren zeichnet (z. B. "Zu den Steuerinformationen")
   --rahmen-farbe: Linienfarbe, --rahmen-abstand: Abstand der Linie zum Rand des Buttons */
.rahmen-zeichnen { --rahmen-farbe: var(--weiss); --rahmen-abstand: 1px; position: relative; }
.rahmen-zeichnen::before, .rahmen-zeichnen::after {
  content: ""; position: absolute; width: 0; height: 0; pointer-events: none;
  border: 1px solid transparent; box-sizing: border-box;
}
.rahmen-zeichnen::before { top: var(--rahmen-abstand); left: var(--rahmen-abstand); }
.rahmen-zeichnen::after  { bottom: var(--rahmen-abstand); right: var(--rahmen-abstand); }
.rahmen-zeichnen:hover::before, .rahmen-zeichnen:focus-visible::before {
  width: calc(100% - 2 * var(--rahmen-abstand)); height: calc(100% - 2 * var(--rahmen-abstand));
  border-top-color: var(--rahmen-farbe); border-right-color: var(--rahmen-farbe);
  transition: width 0.18s ease-out, height 0.18s ease-out 0.18s;
}
.rahmen-zeichnen:hover::after, .rahmen-zeichnen:focus-visible::after {
  width: calc(100% - 2 * var(--rahmen-abstand)); height: calc(100% - 2 * var(--rahmen-abstand));
  border-bottom-color: var(--rahmen-farbe); border-left-color: var(--rahmen-farbe);
  transition: border-color 0s 0.36s, width 0.18s ease-out 0.36s, height 0.18s ease-out 0.54s;
}
.button--blau.rahmen-zeichnen:hover { background: var(--blau); color: var(--weiss); }
@media (prefers-reduced-motion: reduce) {
  .rahmen-zeichnen:hover::before, .rahmen-zeichnen:hover::after,
  .rahmen-zeichnen:focus-visible::before, .rahmen-zeichnen:focus-visible::after { transition: none; }
}

/* ---------- Hinweis "keine neuen Mandanten" ---------- */
@property --winkel { syntax: "<angle>"; inherits: false; initial-value: 0deg; }

.hinweis {
  display: inline-flex; padding: 4px; border-radius: 999px;
  background: conic-gradient(from var(--winkel), var(--rot) 0deg, var(--rot) 180deg, #FF5A6E 260deg, var(--weiss) 320deg, var(--rot) 360deg);
  box-shadow: 0 0 22px rgba(200, 16, 46, 0.45);
  animation: hinweis-kreis 2.4s linear infinite;
}
.hinweis p {
  margin: 0; display: inline-flex; align-items: center; gap: 14px;
  background: var(--weiss); color: var(--schwarz); border-radius: 999px;
  padding: 9px 22px 9px 9px; font-size: 1.05rem; font-weight: 600; line-height: 1.3;
}
.hinweis__icon {
  flex: none; width: 30px; height: 30px; border-radius: 50%;
  background: var(--rot); color: var(--weiss);
  display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 1.05rem;
  animation: hinweis-puls 1.8s ease-out infinite, hinweis-wackeln 3.6s ease-in-out infinite;
}

@keyframes hinweis-kreis { to { --winkel: 360deg; } }
@keyframes hinweis-puls {
  0% { box-shadow: 0 0 0 0 rgba(200, 16, 46, 0.7); }
  70%, 100% { box-shadow: 0 0 0 14px rgba(200, 16, 46, 0); }
}
@keyframes hinweis-wackeln {
  0%, 88%, 100% { transform: rotate(0); }
  91% { transform: rotate(-12deg); }
  94% { transform: rotate(10deg); }
  97% { transform: rotate(-6deg); }
}
@media (prefers-reduced-motion: reduce) {
  .hinweis, .hinweis__icon { animation: none; }
}

/* ---------- Checkliste Steuererklärung (checkliste.html) ---------- */
.checkliste { padding-top: 56px; padding-bottom: 112px; }
.checkliste__kopf { display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: space-between; gap: 20px 48px; margin-bottom: 48px; }
.checkliste__kopf p { flex: 1 1 420px; max-width: 720px; margin: 0; color: var(--text); }
.checkliste__kopf .button { padding: 10px 18px; font-size: 0.95rem; }
/* Spalten statt Raster: die Gruppen fließen untereinander, lange Gruppen hinterlassen keine Lücken */
.checkliste__raster { column-count: 3; column-gap: 48px; }
.checkliste__gruppe { display: block; margin-bottom: 40px; border-top: 3px solid var(--blau); padding-top: 20px; break-inside: avoid; }
@media (max-width: 1000px) { .checkliste__raster { column-count: 2; } }
/* Starres Raster in Zeilen (Checkliste Jahresabschluss) */
.checkliste__raster--zeilen { column-count: auto; display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 40px 48px; align-items: start; }
.checkliste__raster--zeilen .checkliste__gruppe { margin-bottom: 0; }

@media (max-width: 640px) { .checkliste__raster { column-count: 1; } }
.checkliste__gruppe h2 { margin-bottom: 14px; font-size: 1.15rem; font-weight: 600; color: var(--blau); }
.checkliste__gruppe ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 10px; }
.checkliste__gruppe label { display: flex; gap: 12px; align-items: flex-start; cursor: pointer; color: var(--text); line-height: 1.45; }
.checkliste__gruppe input {
  flex: none; width: 20px; height: 20px; margin: 2px 0 0; accent-color: var(--blau); cursor: pointer;
}
.checkliste__gruppe input:checked + span { color: var(--text-leise); text-decoration: line-through; text-decoration-color: var(--blau-linie); }
.checkliste__fuss { margin: 56px 0 0; padding-top: 20px; border-top: 1px solid var(--blau-linie); font-size: 0.95rem; color: var(--text-leise); }
.checkliste-link { margin: 48px 0 0; }

/* Auswahl "Was trifft auf Sie zu?" (Checkliste Steuererklärung) */
.profilwahl { margin: -16px 0 48px; padding: 24px 28px; background: var(--blau-flaeche); }
.profilwahl[hidden] { display: none; }
.profilwahl__frage { margin: 0 0 4px; font-size: 1.15rem; font-weight: 600; color: var(--blau); }
.profilwahl__hinweis { margin: 0 0 16px; font-size: 0.92rem; color: var(--text-leise); }
.profilwahl__knoepfe { display: flex; flex-wrap: wrap; gap: 10px; }
.profilwahl button {
  padding: 8px 16px; border: 1px solid var(--blau-linie); border-radius: 999px; background: var(--weiss);
  font: inherit; font-size: 0.95rem; font-weight: 500; color: var(--blau); cursor: pointer;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}
.profilwahl button:hover { border-color: var(--blau); }
.profilwahl button[aria-pressed="true"] { background: var(--blau); border-color: var(--blau); color: var(--weiss); }
.profilwahl button[aria-pressed="true"]::before { content: "✓ "; }
.profilwahl .profilwahl__alle { border-style: dashed; background: transparent; }
.checkliste__gruppe[hidden] { display: none; }
@media print { .profilwahl { display: none !important; } }

/* ---------- Arbeitshilfen auf der Startseite ---------- */
.arbeitshilfen { margin-top: 64px; }
.arbeitshilfen h3 { margin-bottom: 18px; font-size: 1.2rem; font-weight: 600; color: var(--blau); }
.arbeitshilfen ul { margin: 0; padding: 0; list-style: none; display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; }
.arbeitshilfen a {
  display: block; height: 100%; padding: 18px 20px; background: var(--blau); border: 1px solid var(--blau);
  color: var(--weiss); text-decoration: none; transition: background 0.2s, color 0.2s;
}
.arbeitshilfen strong { display: block; margin-bottom: 4px; font-weight: 600; color: inherit; }
.arbeitshilfen span { font-size: 0.9rem; color: var(--blau-hell); transition: color 0.2s; }
.arbeitshilfen a:hover, .arbeitshilfen a:focus-visible { background: var(--weiss); color: var(--blau); }
.arbeitshilfen a:hover span, .arbeitshilfen a:focus-visible span { color: var(--text-leise); }

/* ---------- Nützliche Tipps ---------- */
.tipps { padding-top: 56px; padding-bottom: 112px; }
.tipps__lead { max-width: 760px; margin: 0 0 48px; font-size: 1.1rem; color: var(--text); }
.tipps__raster { display: grid; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); gap: 40px 48px; align-items: start; }
.tipps__gruppe { border-top: 3px solid var(--blau); padding-top: 20px; break-inside: avoid; }
.tipps__gruppe h2 { margin-bottom: 16px; font-size: 1.15rem; font-weight: 600; color: var(--blau); }
.tipps__gruppe ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 16px; }
.tipps__gruppe li { color: var(--text); line-height: 1.55; }
.tipps__gruppe strong { display: block; margin-bottom: 2px; font-weight: 600; color: var(--schwarz); }
@media print { .tipps__raster { grid-template-columns: 1fr 1fr; gap: 16px 28px; } .tipps { padding-top: 10px; } .tipps__gruppe li { font-size: 9.5pt; } }

/* ---------- Aufbewahrungsfristen ---------- */
.fristen__lead { font-size: 1.1rem; }
.fristen__tabelle-rahmen { overflow-x: auto; margin-bottom: 16px; }
.fristen__tabelle { width: 100%; border-collapse: collapse; }
.fristen__tabelle th { padding: 10px 16px 10px 0; text-align: left; font-size: 0.85rem; font-weight: 500; color: var(--blau); border-bottom: 2px solid var(--blau); }
.fristen__tabelle td { padding: 14px 16px 14px 0; vertical-align: top; border-bottom: 1px solid var(--blau-linie); color: var(--text); }
.fristen__tabelle td:first-child { white-space: nowrap; width: 110px; color: var(--blau); }
.fristen__liste { display: grid; gap: 14px; }
.fristen__beispiel { display: block; margin-top: 4px; padding-left: 12px; border-left: 2px solid var(--blau-linie); font-size: 0.92rem; color: var(--text-leise); }
.fristen__stand { margin-top: 40px; font-size: 0.9rem; color: var(--text-leise); }

/* ---------- Hinweisfenster beim Klick auf den Telefon-Button ---------- */
.dialog {
  width: min(440px, calc(100% - 32px)); padding: 40px 32px 32px; border: 0; border-top: 6px solid var(--rot);
  text-align: center; color: var(--schwarz); font-family: var(--schrift);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.35);
}
.dialog::backdrop { background: rgba(1, 19, 131, 0.55); }
.dialog__icon {
  width: 56px; height: 56px; margin: 0 auto 18px; border-radius: 50%;
  background: var(--rot); color: var(--weiss); font-size: 1.75rem; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
  animation: hinweis-puls 1.8s ease-out infinite;
}
.dialog h2 { margin-bottom: 12px; font-size: 1.5rem; font-weight: 600; color: var(--blau); }
.dialog p { margin: 0 0 8px; color: var(--text); }
.dialog p:first-of-type { font-size: 1.15rem; font-weight: 600; color: var(--schwarz); }
.dialog__aktionen { margin-top: 28px; display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; }
.button--linie { background: var(--weiss); color: var(--blau); border-color: var(--blau-linie); font: inherit; font-weight: 500; cursor: pointer; }
.button--linie:hover { border-color: var(--blau); }
@media (prefers-reduced-motion: reduce) { .dialog__icon { animation: none; } }

/* ---------- Zitat ---------- */
.zitat { background: var(--schwarz); color: var(--weiss); }
.zitat figure {
  margin: 0 auto; display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between;
  gap: 8px 24px; padding-top: 28px; padding-bottom: 28px;
}
/* Zitat in klassischer Serifenschrift wie auf der früheren Webseite (Systemschrift, keine Datei nötig) */
.zitat blockquote { margin: 0; font-family: "Times New Roman", Times, "Liberation Serif", Georgia, serif; font-size: 1rem; font-weight: 400; line-height: 1.5; }
.zitat figcaption { font-size: 0.75rem; color: var(--blau-hell); }

/* ---------- Abschnitte ---------- */
.abschnitt { padding: 96px 0; }
.abschnitt--flaeche { background: var(--blau-flaeche); padding: 80px 0; }
.abschnitt h2 { font-weight: 600; font-size: clamp(1.6rem, 3.2vw, 2.1rem); letter-spacing: -0.02em; color: var(--blau); }
.einleitung { margin: 10px 0 48px; max-width: none; color: var(--text-leise); }

/* Leistungen */
.leistungen { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 40px; }
.leistung { border-top: 3px solid var(--blau); padding-top: 28px; }
.leistung:nth-child(2) { border-top-color: var(--schwarz); }
.leistung h3 { margin-bottom: 14px; font-size: 1.2rem; font-weight: 600; color: var(--blau); }
.leistung ul { margin: 0; padding-left: 18px; color: var(--text); display: grid; gap: 6px; }

/* Aktuelles-Teaser */
.teaser { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 40px; }
.teaser__text { flex: 999 1 560px; min-width: 0; }
.teaser__text p { margin: 14px 0 24px; max-width: 640px; color: var(--text); }
.themen { margin: 0; padding: 0; list-style: none; display: flex; flex-wrap: wrap; gap: 10px; font-size: 0.95rem; }
.themen a {
  position: relative; isolation: isolate; overflow: hidden;
  display: inline-block; background: var(--weiss); border: 1px solid var(--blau-linie); border-radius: 999px;
  padding: 6px 14px; color: var(--schwarz); text-decoration: none;
  transition: color 0.25s ease, border-color 0.25s ease;
}
/* Beim Darüberfahren: das ganze Etikett wechselt fließend die Farbe
   Kanzleiblau -> helleres Blau -> Schwarz -> helleres Blau -> Kanzleiblau (endlos) */
.themen a::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background-color: #011383;
  opacity: 0; transition: opacity 0.25s ease;
}
.themen a:hover, .themen a:focus-visible { color: var(--weiss); border-color: transparent; }
.themen a:hover::before, .themen a:focus-visible::before { opacity: 1; animation: themen-fluss 6s ease-in-out infinite; }
@keyframes themen-fluss {
  0%, 100% { background-color: #011383; }
  25%, 75% { background-color: #2a3fd0; }
  50% { background-color: #000000; }
}
@media (prefers-reduced-motion: reduce) {
  .themen a:hover::before, .themen a:focus-visible::before { animation: none; }
}

/* Kontakt */
.kontakt { margin-top: 48px; display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 32px; }
.kontakt dt { margin-bottom: 6px; font-size: 0.85rem; font-weight: 500; color: var(--blau); }
.kontakt dd { margin: 0; }

.kontakt-raster { margin-top: 48px; display: flex; flex-wrap: wrap; gap: 48px 56px; align-items: flex-start; }
.kontakt-raster .kontakt-spalte { flex: 1 1 260px; }
.kontakt-raster .kontakt { margin-top: 0; grid-template-columns: 1fr; gap: 24px; }
.kontakt__vcard { margin-top: 32px; padding: 10px 16px; font-size: 0.95rem; }
.kontakt__vcard::before { content: "+"; margin-right: 8px; font-weight: 600; }

/* Urlaubs-/Abwesenheitshinweis unter dem Menü (assets/js/abwesenheit.js) */
.abwesenheit { background: var(--blau-flaeche); border-bottom: 1px solid var(--blau-linie); }
.abwesenheit p { margin: 0 auto; padding-top: 12px; padding-bottom: 12px; color: var(--blau); font-weight: 500; text-align: center; }

/* Aktuelles: Hinweis, wenn die Steuerinformationen nicht laden */
.erv-fehler { padding: 24px; background: var(--blau-flaeche); border-left: 4px solid var(--blau); }
.anfahrt { flex: 999 1 560px; min-width: 0; margin: 0; }
.anfahrt img { width: 100%; height: auto; padding: 2px; background: var(--weiss); border: 1px solid var(--blau-linie); }
.anfahrt figcaption { margin-top: 8px; font-size: 0.8rem; color: var(--text-leise); text-align: right; }
.anfahrt figcaption a { color: var(--text-leise); }
.anfahrt__links { margin-top: 20px; display: flex; flex-wrap: wrap; gap: 12px; }
.anfahrt__links .button { padding: 10px 16px; font-size: 0.95rem; }
.anfahrt__hinweis { margin: 12px 0 0; font-size: 0.85rem; color: var(--text-leise); }
.anfahrt__zoom { position: relative; display: block; width: 100%; padding: 0; border: 0; background: none; cursor: zoom-in; }
.anfahrt__zoom img { display: block; }
.anfahrt__lupe {
  position: absolute; right: 12px; bottom: 12px; padding: 6px 12px; border-radius: 999px;
  background: var(--blau); color: var(--weiss); font: 500 0.85rem/1.2 var(--schrift);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25); transition: background 0.2s;
}
.anfahrt__zoom:hover .anfahrt__lupe, .anfahrt__zoom:focus-visible .anfahrt__lupe { background: var(--schwarz); }

/* Vergrößerte Karte (assets/js/karte.js) */
.karte-dialog {
  width: 100vw; height: 100dvh; max-width: none; max-height: none; margin: 0; padding: 0; border: 0;
  background: #F2EFE9; overflow: hidden;
}
.karte-dialog::backdrop { background: rgba(1, 19, 131, 0.55); }
.karte-dialog__flaeche { position: absolute; inset: 0; overflow: hidden; touch-action: none; cursor: grab; }
.karte-dialog__flaeche.ist-gezogen { cursor: grabbing; }
.karte-dialog__flaeche img {
  position: absolute; top: 0; left: 0; max-width: none; transform-origin: 0 0;
  user-select: none; -webkit-user-select: none;
}
.karte-dialog__leiste { position: absolute; top: 16px; right: 16px; display: flex; flex-direction: column; gap: 8px; }
.karte-dialog__leiste button {
  width: 44px; height: 44px; border: 1px solid var(--blau-linie); border-radius: 50%;
  background: var(--weiss); color: var(--blau); font: 600 1.35rem/1 var(--schrift); cursor: pointer;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}
.karte-dialog__leiste button:hover { background: var(--blau); color: var(--weiss); border-color: var(--blau); }
.karte-dialog__leiste [data-aktion="zu"] { margin-bottom: 8px; order: -1; font-size: 1.1rem; }
.karte-dialog__quelle {
  position: absolute; left: 0; bottom: 0; margin: 0; padding: 4px 10px;
  background: rgba(255, 255, 255, 0.85); font-size: 0.75rem; color: var(--text-leise);
}

/* ---------- Unterseiten-Kopf ---------- */
.seitenkopf { background: var(--blau); color: var(--weiss); }
.seitenkopf .container { padding-top: 64px; padding-bottom: 56px; }
.seitenkopf h1 { font-weight: 600; font-size: clamp(1.8rem, 4vw, 2.6rem); line-height: 1.1; letter-spacing: -0.025em; }
.brotkrumen { margin: 0 0 12px; font-size: 0.875rem; color: var(--blau-hell); }
.brotkrumen a { color: var(--blau-hell); }
.brotkrumen a:hover { color: var(--weiss); }

/* ---------- Textseiten (Impressum, Datenschutz) ---------- */
.textseite { max-width: 780px; padding-top: 72px; padding-bottom: 112px; }
.textseite h2 { margin: 48px 0 14px; font-size: 1.4rem; font-weight: 600; color: var(--blau); }
.textseite h2:first-child { margin-top: 0; }
.textseite h3 { margin: 28px 0 8px; font-size: 1.05rem; font-weight: 600; }
.textseite p, .textseite ul, .textseite address { margin: 0 0 16px; color: var(--text); }
.textseite address { font-style: normal; }
.textseite ul { padding-left: 20px; }

/* ---------- Aktuelles: Inhalte des ERV-Verlags ----------
   Das Skript von mainfo.net schreibt seine Inhalte samt eigenem CSS in
   #myContent. Die Regeln hier überschreiben dessen Float-Layout und Farben.
   Wichtig: Das ERV-CSS setzt global "a {text-decoration:none}" – deshalb
   haben Fußzeile & Co. unten ihre Unterstreichung ausdrücklich gesetzt. */
.aktuelles { padding-top: 72px; padding-bottom: 112px; }
#myContent { display: block; min-height: 200px; color: var(--text); }
#myContent * { font-family: var(--schrift); }
#myContent a { color: var(--blau); text-decoration: none; }
#myContent a:hover { color: var(--schwarz); text-decoration: underline; }

/* Grundraster: Inhalt links, Seitenleiste rechts */
#myContent .erv {
  display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 0 56px; align-items: start;
}
#myContent .erv > #erv-mainheader,
#myContent .erv > #erv-nav-responsive { grid-column: 1 / -1; }
#myContent .erv > .erv-spacer { display: none; }
#myContent #erv-content-1,
#myContent #erv-sidebar { width: auto; float: none; padding: 0; }

/* Monat */
#myContent #erv-mainheader {
  margin: 0 0 28px; font-size: 1.85rem; font-weight: 600; letter-spacing: -0.02em; line-height: 1.1; color: var(--blau);
}

/* Rubrik (z. B. "Steuerrecht") */
#myContent .erv-artikel-header {
  margin: 0; padding: 0 0 12px; border: 0; border-bottom: 2px solid var(--schwarz);
  font-size: 0.95rem; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; color: var(--schwarz);
}
#myContent .erv-artikel ~ .erv-artikel-header { margin-top: 56px; }

/* Artikel */
#myContent .erv-artikel {
  display: grid; grid-template-columns: 168px minmax(0, 1fr); gap: 28px;
  margin: 0; padding: 32px 0; border: 0; border-bottom: 1px solid var(--linie);
}
#myContent .erv-artikel-img,
#myContent .erv-artikel-content { float: none; width: auto; margin: 0; text-align: left; }
#myContent .erv-artikel-img .erv-img {
  width: 100% !important; aspect-ratio: 3 / 2 !important; object-fit: cover !important; height: auto;
}
#myContent .erv-artikel .erv-spacer { display: none; }
#myContent .erv-artikel-content-header { margin: 0 0 8px; font-size: 1.2rem; font-weight: 600; line-height: 1.3; }
#myContent .erv-artikel-content-text { margin: 0; font-size: 1rem; line-height: 1.6; color: var(--text); }

/* "[...] weiterlesen" wird zu "Weiterlesen →" */
#myContent .erv-artikel-content-text a { font-size: 0; display: block; margin-top: 12px; }
#myContent .erv-artikel-content-text a br { display: none; }
#myContent .erv-artikel-content-text a::after { content: "Weiterlesen →"; font-size: 1rem; font-weight: 500; }

/* Seitenleiste: Monat & Kategorie */
#myContent #erv-sidebar { display: flex; flex-direction: column; gap: 24px; }
#myContent #erv-sidebar .erv-box { margin: 0; padding: 28px; border: 0; }
#myContent #erv-nav { background: var(--blau-flaeche); }
#myContent #erv-nav > br { display: none; }
#myContent .erv-headline {
  margin: 0 0 14px; font-size: 0.95rem; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; color: var(--schwarz);
}
#myContent #erv-nav .erv-headline:not(:first-child) { margin-top: 28px; }
#myContent .erv-list { margin: 0; padding: 0; list-style: none; display: grid; gap: 8px; }

/* Seitenleiste: Fälligkeitstermine, Basiszins, Verbraucherpreisindex */
#myContent #erv-sidebar #erv-vpt { padding: 0; display: grid; gap: 8px; background: none; }
#myContent #erv-vpt > a { display: block; text-decoration: none; }
#myContent .erv-vpt-container { background: var(--schwarz); padding: 20px 24px; }
#myContent .erv-vpt-container img { display: none; }
#myContent .erv-vpt-container .content { position: static; background: none; width: auto; text-align: left; }
#myContent .erv-vpt-container .content p { margin: 0; color: var(--weiss); font-size: 1rem; font-weight: 600; line-height: 1.35; }
#myContent .erv-vpt-container .content p::after { content: " →"; }
#myContent #erv-vpt > a:hover .erv-vpt-container { background: var(--blau); }

/* Seitenleiste: Spruch des Monats */
#myContent #erv-sidebar #spruch { border-left: 3px solid var(--blau); padding: 4px 0 4px 20px; }
#myContent #spruch > p:empty { display: none; }
#myContent #zitat { font-style: italic; color: var(--text); line-height: 1.5; }
#myContent #zitat #name { display: block; margin-top: 10px; font-style: normal; font-size: 0.85rem; color: var(--text-leise); }

/* Handy-Menü des ERV-Verlags (Monat / Themengebiete) */
#myContent #erv-nav-responsive { display: none; }
#myContent .dropbtn { background: var(--blau); color: var(--weiss); font-size: 1rem; font-weight: 600; text-align: left; padding: 14px 18px; }
#myContent .dropbtn:hover, #myContent .dropbtn:focus { background: var(--schwarz); }
#myContent .dropdown + .dropdown { margin-top: 8px; }
#myContent .dropdown-content { width: 100%; background: var(--weiss); border: 1px solid var(--blau-linie); }
#myContent .dropdown-content a { color: var(--blau); }
#myContent .dropdown-content.show { display: block; }

/* Einzelner Beitrag (Detailansicht) */
#myContent .erv:has(#erv-content-1 > .erv-headline) #erv-mainheader { display: none; }
#myContent #erv-content-1 > .erv-headline {
  margin: 0 0 24px; font-size: clamp(1.5rem, 3vw, 1.9rem); font-weight: 600; letter-spacing: -0.02em;
  line-height: 1.15; text-transform: none; color: var(--blau);
}
#myContent #erv-content-1 > hr { border: 0; border-top: 1px solid var(--linie); margin: 32px 0; clear: both; }
#myContent #erv-content-1 > .erv-headline + hr { margin-top: 0; }
#myContent #erv-content-1 > p,
#myContent #erv-content-1 { color: var(--text); line-height: 1.7; }
#myContent .erv-img-beitrag {
  float: right; width: 100% !important; max-width: 340px !important; height: auto;
  aspect-ratio: 4 / 3 !important; object-fit: cover !important; margin: 4px 0 24px 32px;
}
#myContent #erv-content-1 table { border-collapse: collapse; width: 100%; margin: 8px 0 24px; clear: both; }
#myContent #erv-content-1 td { padding: 12px 14px; border-bottom: 1px solid var(--linie); vertical-align: top; }
#myContent #erv-content-1 tr:first-child td { background: var(--blau); color: var(--weiss); font-weight: 600; }
#myContent #erv-content-1 tr:nth-child(n+2) td:first-child { font-weight: 600; color: var(--blau); white-space: nowrap; }

/* Haftungshinweis, Zurück-Link und Fragen-Kasten am Ende des Beitrags */
#myContent #erv-content-1 > hr + p { font-size: 0.875rem; color: var(--text-leise); }
#myContent #erv-content-1 > .erv-list { margin: 24px 0; }
#myContent #erv-content-1 > .erv-list a { font-size: 0; }
#myContent #erv-content-1 > .erv-list a::before { content: "← Zurück zur Übersicht"; font-size: 1rem; font-weight: 500; }
#myContent #erv-content-1 > .erv-list + p { background: var(--blau-flaeche); padding: 24px 28px; margin: 0; }
#myContent #erv-content-1 > .erv-list + p strong { font-weight: 500; color: var(--schwarz); }
#myContent #erv-content-1 > .erv-list + p a { text-decoration: underline; }

/* Alte Fußzeile, die der ERV-Verlag in der Detailansicht mitliefert */
#myContent #footer { display: none; }

#myContent .erv img:not(.erv-img):not(.erv-img-beitrag) { max-width: 100%; height: auto; }

@media (max-width: 900px) {
  #myContent .erv { display: block; }
  #myContent #erv-nav-responsive { display: block; margin-bottom: 32px; }
  #myContent #erv-sidebar { display: flex; margin-top: 48px; }
  #myContent #erv-nav, #myContent #spruch { display: none; }
}
@media (max-width: 600px) {
  #myContent .erv-artikel { grid-template-columns: 1fr; gap: 16px; }
  #myContent .erv-artikel-img .erv-img { width: 100% !important; }
  #myContent .erv-img-beitrag { float: none; max-width: 100% !important; margin: 0 0 24px; }
  #myContent #erv-content-1 tr:nth-child(n+2) td:first-child { white-space: normal; }
}

/* Unterstreichung trotz ERV-Regel "a {text-decoration:none}" */
.site-footer a, .brotkrumen a, .textseite a, .kontakt a { text-decoration: underline; }

/* ---------- Fußzeile ---------- */
.site-footer { background: var(--schwarz); color: #C3CAD3; font-size: 0.875rem; }
.site-footer .container {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: 16px; padding-top: 32px; padding-bottom: 32px;
}
.site-footer__marke { display: flex; flex-wrap: wrap; align-items: center; gap: 24px; }
/* ---------- Logo (Kopf- und Fußzeile, ohne Animation) ----------
   Kopfzeile: farbiges Zeichen mit farbigem Schriftzug.
   Fußzeile: Zeichen als weiße Umrisslinie mit weißem Schriftzug. */
.logo-loop { --logo-h: 44px; display: inline-flex; align-items: center; gap: 14px; line-height: 0; text-decoration: none; }
.logo-loop--kopf { --logo-h: 52px; gap: 12px; }
.logo-loop__label { display: block; }
.logo-loop__text { display: block; height: var(--logo-h); width: auto; }
.logo-zeichen { position: relative; display: block; width: calc(var(--logo-h) * 0.877); height: var(--logo-h); }
.logo-zeichen__bild { display: block; width: 100%; height: 100%; }
.logo-zeichen__kontur { display: none; }
@supports ((mask-image: url("x.svg")) or (-webkit-mask-image: url("x.svg"))) {
  .logo-loop--fuss .logo-zeichen__bild { visibility: hidden; }
  .logo-loop--fuss .logo-zeichen__kontur {
    display: block; position: absolute; inset: -1px; background: #FFFFFF;
    -webkit-mask: url("../img/zeichen-maske-kontur.svg") center / 100% 100% no-repeat;
            mask: url("../img/zeichen-maske-kontur.svg") center / 100% 100% no-repeat;
  }
}
.site-footer nav { display: flex; flex-wrap: wrap; gap: 8px 24px; }
.site-footer__hilfen { order: 3; flex: 1 1 100%; justify-content: flex-start; padding-top: 18px; border-top: 1px solid rgba(255, 255, 255, 0.12); }
.site-footer a { color: #C3CAD3; }
.site-footer a:hover { color: var(--weiss); }

/* ---------- Druckansicht ----------
   Nur Inhalt in Schwarz auf Weiß, mit Logo oben und Kanzleiadresse unten. */
@media print {
  @page { margin: 18mm 16mm; }
  html { scroll-padding-top: 0; }
  body { display: block; min-height: 0; font-size: 11pt; color: #000; background: #fff; }
  .site-header { position: static; box-shadow: none; border-bottom: 1px solid #999; }
  .js-intro .logo-loop--kopf { opacity: 1 !important; animation: none !important; }
  .nav, .skip-link, .intro, .intro-flug, .hero__hinweis, .hero__aktionen, .themen, .teaser .button,
  .anfahrt__links, .anfahrt__hinweis, .anfahrt__lupe, .kontakt__vcard, .checkliste__kopf .button, .checkliste-link, .arbeitshilfen, .fristen [data-drucken], .karte-dialog, .dialog, .site-footer nav, .site-footer__marke,
  #erv-nav-responsive, #erv-sidebar, #myContent .erv-artikel-content-text a::after,
  #myContent #erv-content-1 > .erv-list { display: none !important; }
  .hero, .seitenkopf, .zitat, .abschnitt--flaeche, .site-footer { background: none !important; color: #000 !important; }
  .hero .container, .seitenkopf .container { padding-top: 16px; padding-bottom: 8px; }
  .abschnitt, .abschnitt--flaeche, .aktuelles, .textseite { padding-top: 16px; padding-bottom: 16px; }
  .zitat blockquote, .zitat figcaption, .kicker, .brotkrumen, .brotkrumen a { color: #000 !important; }
  h1, h2, h3, h4, .abschnitt h2, .leistung h3, .seitenkopf h1, .hero h1 { color: #000 !important; }
  h2, h3, h4 { break-after: avoid; }
  .leistung, #myContent .erv-artikel, table, figure { break-inside: avoid; }
  a { color: #000 !important; text-decoration: none !important; }
  .textseite a[href^="http"]::after { content: " (" attr(href) ")"; font-size: 9pt; color: #444; }
  #myContent .erv { display: block; }
  #myContent .erv-artikel { grid-template-columns: 110px minmax(0, 1fr); padding: 14px 0; }
  .anfahrt img { max-width: 140mm; }
  .site-footer { border-top: 1px solid #999; }
  .site-footer .container { padding-top: 10px; padding-bottom: 0; }
  .site-footer .container::before {
    content: "Steuerberater Lars Falke · Rostocker Straße 26 · 18190 Sanitz · (038209) 87 59 38 · info@stb-falke.com";
    font-size: 9pt; color: #000;
  }
}

/* ---------- Kleine Bildschirme ---------- */
@media (max-width: 640px) {
  .logo-loop--kopf { --logo-h: 36px; }
  .site-header .container { gap: 8px; padding-top: 12px; padding-bottom: 8px; }
  .nav { gap: 4px 0; margin-left: -6px; }
  .nav a { padding: 6px 6px; }
  .anfahrt img { aspect-ratio: 4 / 3; object-fit: cover; object-position: 42% 55%; }
  .hero .container { padding-top: 40px; padding-bottom: 64px; }
  .hinweis { border-radius: 18px; }
  .hinweis p { border-radius: 14px; font-size: 1rem; padding: 9px 16px 9px 9px; }
  .abschnitt { padding: 72px 0; }
  .abschnitt--flaeche { padding: 64px 0; }
}

/* Druck der Checkliste: zwei Spalten, kompakt */
@media print {
  .abwesenheit { display: none !important; }
  .checkliste { padding-top: 10px; padding-bottom: 0; }
  .checkliste__kopf { margin-bottom: 14px; }
  .checkliste__kopf p { font-size: 10pt; }
  .checkliste__raster { column-count: auto; display: grid; grid-template-columns: 1fr 1fr; gap: 14px 28px; align-items: start; }
  .checkliste__gruppe { display: block; margin-bottom: 0; padding-top: 8px; border-top: 2px solid #000; }
  .checkliste__gruppe h2 { margin-bottom: 6px; font-size: 11pt; }
  .checkliste__gruppe ul { gap: 4px; }
  .checkliste__gruppe label { font-size: 9.5pt; gap: 8px; }
  .checkliste__gruppe input { width: 12px; height: 12px; margin-top: 1px; }
  .checkliste__fuss { margin-top: 14px; font-size: 9pt; }
}

/* Druck der Aufbewahrungsfristen */
@media print {
  .fristen__tabelle td:first-child, .fristen__tabelle th { color: #000; }
}
