/* =========================================================
   "Kontor" – Gestaltungsebene über style.css
   =========================================================

   Diese Datei ändert das Erscheinungsbild, nicht die Struktur. Sie wird NACH
   style.css geladen; das HTML bleibt unangetastet.

   Fassung 2 (22.09.2026) – nach Rückmeldung überarbeitet:
   - weniger harte Kanten: ruhige kleine Radien statt scharfer Ecken
   - Texte beginnen wieder am linken Rand statt weit eingerückt
   - ruhiger: weniger Linien, leisere Abschnittsmarken, Monospace nur noch
     für Zahlen und kurze Marken, nicht für ganze Textblöcke
   - Tiefe über weiche, flache Schatten und abgesetzte Flächen
   - ein durchlaufendes Häuserband verbindet die Abschnitte über alle Seiten
   - kompaktere Abstände

   UMSCHALTEN: python webseite\design-umschalten.py aus | an | stand
   ========================================================= */

:root {
  /* Kanten: ruhig gerundet, nicht verspielt */
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 14px;
  --radius-pill: 999px;

  --color-border: #e3ded3;
  --color-border-strong: #d2cbba;
  --color-bg-alt: #f4f2ec;

  --font-mono: 'IBM Plex Mono', ui-monospace, 'SFMono-Regular', Consolas, monospace;

  /* Tiefe: flach und weich, nie hart abgesetzt */
  --schatten-weich: 0 1px 2px rgba(22, 33, 62, .04), 0 12px 28px -20px rgba(22, 33, 62, .30);
  --schatten-tief: 0 2px 6px rgba(22, 33, 62, .06), 0 30px 60px -34px rgba(22, 33, 62, .45);
  --shadow-float: var(--schatten-weich);
  --shadow-sm: 0 1px 2px rgba(22, 33, 62, .04);
}

body { counter-reset: abschnitt; }

/* ---------------- Kopfzeile ---------------- */
/* Ohne Weichzeichnung: Chrome baute diese Ebene beim Aufklappen des Menüs neu
   auf, der Kopf blitzte dabei kurz weg. */
.site-header {
  background: #faf9f6; backdrop-filter: none; -webkit-backdrop-filter: none;
  border-bottom-color: transparent;
}
.site-header.scrolled {
  background: #faf9f6; border-bottom-color: var(--color-border);
  box-shadow: 0 1px 0 rgba(22, 33, 62, .03);
}
.dropdown-menu { box-shadow: var(--schatten-weich); border: 1px solid var(--color-border); }
.dropdown-menu a small { font-size: 0.72rem; }

/* Flackerndes Klappmenue: Zwischen der Unterkante des Menuepunkts und der
   Unterkante des Kopfes liegt das Innenpolster der Kopfzeile. Dieser Streifen
   gehoert nicht mehr zum <li>, also verlor der Zeiger auf dem Weg nach unten
   kurz den Hover - das Menue blendete aus und sofort wieder ein. Zwei Mittel:
   eine unsichtbare Bruecke ueber den Streifen und eine kurze Verzoegerung
   beim Schliessen. */
.main-nav a.nav-link { position: relative; }
.has-dropdown > a.nav-link::after {
  content: ''; position: absolute; left: 0; right: 0; top: 100%; height: 30px;
}
.dropdown-menu { transition-delay: .14s; }
.has-dropdown:hover .dropdown-menu,
.has-dropdown:focus-within .dropdown-menu { transition-delay: 0s; }

/* ---------------- Abschnitte ---------------- */
/* Kompakter, und ohne Trennlinie zwischen jedem Block - die wechselnden
   Flächentöne reichen als Gliederung aus. */
section { padding-top: 62px; padding-bottom: 62px; }
section.hero { padding-top: 56px; padding-bottom: 66px; }
section.bg-alt { background: var(--color-bg-alt); }

/* Abschnittsmarke: Nummer und Name, leise, mit kurzem Strich. Vorher lief eine
   Linie über die ganze Breite - das war zu laut. */
.section-head { max-width: 760px; margin: 0 0 34px; text-align: left; }
.section-head .eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--font-mono); font-size: 0.66rem; letter-spacing: .13em;
  color: var(--color-text-muted); margin-bottom: 14px;
}
.section-head .eyebrow::before {
  counter-increment: abschnitt;
  content: counter(abschnitt, decimal-leading-zero);
  color: var(--color-gold); letter-spacing: .08em;
}
.section-head .eyebrow::after { content: ''; width: 26px; height: 1px; background: var(--color-border-strong); }
.section-head h2 { text-align: left; letter-spacing: -.022em; }
.section-head > p { text-align: left; max-width: 64ch; }
.hero .eyebrow { font-family: var(--font-mono); font-size: 0.66rem; letter-spacing: .12em; }

/* ---------------- Aus Kacheln werden Bahnen ---------------- */
/* Bahnen statt Kacheln: eine Zeile je Angebot, durch Haarlinien getrennt.
   Ohne Nummernspalte - der Text beginnt direkt am linken Rand. */
.grid:has(> .card) {
  grid-template-columns: 1fr; gap: 0;
  border-top: 1px solid var(--color-border);
}
.grid:has(> .card) > .card {
  display: block;
  padding: 22px 16px 22px 0; border-bottom: 1px solid var(--color-border);
  background: transparent; border-radius: var(--radius-sm);
  transition: background .35s var(--ease-out-expo);
}
.grid:has(> .card) > .card:hover { background: rgba(22, 33, 62, .028); }
.grid:has(> .card) > .card h3 { font-family: var(--font-display); font-weight: 400; font-size: 1.38rem; margin-bottom: 6px; }
.grid:has(> .card) > .card p { max-width: 66ch; margin-bottom: 8px; }
.grid:has(> .card) > .card .icon {
  background: none; border: none; width: auto; height: auto; padding: 0; margin-bottom: 8px;
}
.grid:has(> .card) > .card .icon svg { width: 26px; height: 26px; stroke-width: 1.3; color: var(--color-text-soft); }
.grid:has(> .card) > .card a.card-link { font-size: 0.86rem; }

/* ---------------- Häkchenlisten ---------------- */
.usp-list { border-top: 1px solid var(--color-border); }
.usp-list li {
  display: grid; grid-template-columns: 28px 1fr; gap: 0 14px;
  padding: 18px 0; border-bottom: 1px solid var(--color-border);
  background: transparent !important; border-radius: 0;
}
.usp-list .tick {
  color: var(--color-gold); background: none; width: auto; height: auto;
  border-radius: 0; padding-top: 2px; font-size: 0.9rem;
}

/* ---------------- Kennzahlen ---------------- */
.hero-photo { box-shadow: var(--schatten-tief); }
.hero-photo-badge {
  border-radius: var(--radius-sm); border-left: 3px solid var(--color-gold);
  box-shadow: var(--schatten-weich);
}
.hero-photo-badge .num, .stat-card .num { font-variant-numeric: tabular-nums; letter-spacing: -.028em; }
.hero-photo-badge .label, .stat-card .label {
  font-family: var(--font-mono); font-size: 0.64rem; letter-spacing: .08em; text-transform: uppercase;
}
.hero-badges-clean .hero-badge-clean { font-size: 0.8rem; }

/* ---------------- Tabellen ---------------- */
table th {
  font-family: var(--font-mono); font-size: 0.64rem; letter-spacing: .1em;
  text-transform: uppercase; font-weight: 400; color: var(--color-text-muted);
}
table td { font-variant-numeric: tabular-nums; }

/* ---------------- Fragen ---------------- */
.accordion-item .q { font-family: var(--font-display); font-weight: 400; font-size: 1.22rem; }

/* ---------------- Meldungen und Kästen ---------------- */
.rate-news-badge { font-family: var(--font-mono); font-size: 0.62rem; letter-spacing: .07em; }
.rate-news-date { font-family: var(--font-mono); font-size: 0.68rem; }
.autor-box { border-left: 3px solid var(--color-gold); box-shadow: var(--shadow-sm); }
.bank-logo-card { box-shadow: none; }

/* ---------------- Aufruf-Band mit Tiefe ---------------- */
.cta-band {
  position: relative; overflow: hidden; box-shadow: var(--schatten-tief);
  background:
    radial-gradient(120% 140% at 12% 0%, rgba(255, 255, 255, .10) 0%, rgba(255, 255, 255, 0) 58%),
    linear-gradient(160deg, #1b2a4e 0%, var(--color-primary) 52%, #101a33 100%);
}
/* Angedeutete Dachlinie im Band - gibt der Fläche Tiefe, ohne laut zu werden */
.cta-band::after {
  content: ''; position: absolute; right: -30px; bottom: -24px; width: 320px; height: 180px;
  background: url('../img/deko/haeuserband.svg') no-repeat right bottom / cover;
  opacity: .22; filter: brightness(0) invert(1); pointer-events: none;
}
.cta-band > * { position: relative; z-index: 1; }

/* ---------------- Durchlaufendes Häuserband ---------------- */
/* Liegt am oberen Rand der abgesetzten Abschnitte und zieht sich damit über
   alle Seiten hinweg. Rein dekorativ, deshalb ohne eigenes Markup. */
section.bg-alt { position: relative; }
section.bg-alt::before {
  content: ''; position: absolute; left: 0; right: 0; top: 0; height: 112px;
  background: url('../img/deko/haeuserband.svg') repeat-x left bottom / auto 112px;
  /* Die Datei selbst ist voll deckend; die Staerke wird nur hier gesteuert.
     Vorher standen 42 % in der Datei und 15 % hier - multipliziert 6 %,
     also unsichtbar. */
  opacity: .30; pointer-events: none;
  -webkit-mask-image: linear-gradient(to bottom, #000 35%, transparent 100%);
  mask-image: linear-gradient(to bottom, #000 35%, transparent 100%);
}
section.bg-alt > .container { position: relative; }

/* ---------------- Fußzeile ---------------- */
.site-footer h4 {
  font-family: var(--font-mono); font-size: 0.64rem; letter-spacing: .1em;
  text-transform: uppercase; font-weight: 400;
}

/* ---------------- Bewegung ---------------- */
[data-zeichnung] path, [data-zeichnung] circle, [data-zeichnung] rect,
[data-zeichnung] line, [data-zeichnung] polyline {
  stroke-dasharray: var(--l); stroke-dashoffset: var(--l);
  transition: stroke-dashoffset 1.1s var(--ease-out-expo);
}
[data-zeichnung].gezeichnet path, [data-zeichnung].gezeichnet circle,
[data-zeichnung].gezeichnet rect, [data-zeichnung].gezeichnet line,
[data-zeichnung].gezeichnet polyline { stroke-dashoffset: 0; }

tbody[data-staffel] tr { opacity: 0; transform: translateY(6px); transition: opacity .5s var(--ease-out-expo), transform .5s var(--ease-out-expo); }
tbody[data-staffel].da tr { opacity: 1; transform: none; }
tbody[data-staffel].da tr:nth-child(2) { transition-delay: .05s; }
tbody[data-staffel].da tr:nth-child(3) { transition-delay: .1s; }
tbody[data-staffel].da tr:nth-child(4) { transition-delay: .15s; }
tbody[data-staffel].da tr:nth-child(5) { transition-delay: .2s; }

@media (prefers-reduced-motion: reduce) {
  [data-zeichnung] path, [data-zeichnung] circle, [data-zeichnung] rect,
  [data-zeichnung] line, [data-zeichnung] polyline { stroke-dashoffset: 0 !important; transition: none !important; }
  tbody[data-staffel] tr { opacity: 1 !important; transform: none !important; }
}

@media (max-width: 760px) {
  section { padding-top: 46px; padding-bottom: 46px; }
  .section-head { margin-bottom: 26px; }
  section.bg-alt::before { height: 76px; background-size: auto 76px; }
}
