/* =================================================================
   kw-uebersicht.de  |  IBAN-Tool
   Eigenes CSS, keine externen Quellen
   ================================================================= */

:root {
  --c-blue:      #1a5296;
  --c-blue-dk:   #0e3668;
  --c-blue-lt:   #e8eef7;
  --c-orange:    #d4691e;
  --c-green:     #1d6b35;
  --c-red:       #b52b27;
  --c-bg:        #f0f2f5;
  --c-white:     #ffffff;
  --c-border:    #c8d4e3;
  --c-text:      #1a1a1a;
  --c-muted:     #5a6472;
  --c-row-alt:   #f7f9fc;
  --ad-width:    300px;
  --content-max: 800px;
  --radius:      4px;
  --font:        Verdana, Geneva, 'DejaVu Sans', sans-serif;
  --font-mono:   'Courier New', Courier, monospace;
}

/* Reset */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 14px; scroll-behavior: smooth; }
body {
  font-family: var(--font);
  font-size: 13px;
  line-height: 1.55;
  color: var(--c-text);
  background: var(--c-bg);
}
a { color: var(--c-blue); text-decoration: none; }
a:hover { text-decoration: underline; color: var(--c-blue-dk); }
h1, h2, h3 { font-family: var(--font); font-weight: bold; color: var(--c-blue-dk); }

/* =================================================================
   SEITENLAYOUT: zwei Werbespalten + Mittelspalte
   ================================================================= */
#page-wrap {
  display: flex;
  justify-content: center;
  align-items: flex-start;
  min-height: 100vh;
}

/* Werbspalten */
.ad-col {
  width: var(--ad-width);
  flex-shrink: 0;
  padding: 10px 8px;
  position: sticky;
  top: 0;
  align-self: flex-start;
  max-height: 100vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.ad-slot {
  /* kein Hintergrund, keine Box – Anzeige direkt */
  display: block;
}
.ad-label {
  font-size: 10px;
  color: #aaa;
  text-align: center;
  margin-bottom: 4px;
  letter-spacing: .5px;
  width: 100%;
}

/* Mittelspalte */
#main-col {
  flex: 1;
  max-width: var(--content-max);
  min-width: 0;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* =================================================================
   HEADER
   ================================================================= */
#site-header {
  background: var(--c-blue);
  border-bottom: 3px solid var(--c-blue-dk);
}
.header-top {
  background: var(--c-blue-dk);
  padding: 6px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.site-logo {
  font-size: 18px;
  font-weight: bold;
  color: #fff;
  font-family: Georgia, serif;
  letter-spacing: -.3px;
}
.site-logo span { color: #f0a030; }
.site-tagline {
  font-size: 11px;
  color: rgba(255,255,255,.65);
}
.header-back {
  font-size: 11px;
  color: rgba(255,255,255,.7);
}
.header-back a { color: rgba(255,255,255,.8); }
.header-back a:hover { color: #fff; text-decoration: none; }

/* =================================================================
   NAVIGATION
   ================================================================= */
nav#main-nav {
  background: var(--c-blue);
}
nav#main-nav ul {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  margin: 0;
  padding: 0;
  border-top: 1px solid rgba(255,255,255,.12);
}
nav#main-nav ul li a {
  display: flex;
  align-items: center;
  gap: 5px;
  color: rgba(255,255,255,.88);
  padding: 8px 12px;
  font-size: 12px;
  border-right: 1px solid rgba(255,255,255,.1);
  transition: background .12s;
  white-space: nowrap;
}
nav#main-nav ul li a:hover,
nav#main-nav ul li a.active {
  background: rgba(0,0,0,.2);
  color: #fff;
  text-decoration: none;
}
nav#main-nav .nav-icon {
  width: 14px;
  height: 14px;
  fill: currentColor;
  flex-shrink: 0;
}

/* =================================================================
   BREADCRUMB
   ================================================================= */
#breadcrumb {
  background: #dde4ee;
  border-bottom: 1px solid var(--c-border);
  padding: 5px 12px;
  font-size: 11px;
  color: var(--c-muted);
}
#breadcrumb a { color: var(--c-blue); }
#breadcrumb .sep { margin: 0 5px; color: #999; }

/* =================================================================
   INHALT
   ================================================================= */
#content {
  padding: 16px 12px;
  flex: 1;
}
#content > h1 {
  font-size: 18px;
  margin-bottom: 4px;
  line-height: 1.3;
}
.page-intro {
  color: var(--c-muted);
  font-size: 12px;
  margin-bottom: 14px;
  line-height: 1.5;
}

/* =================================================================
   KARTEN
   ================================================================= */
.card {
  background: var(--c-white);
  border: 1px solid var(--c-border);
  margin-bottom: 14px;
}
.card-head {
  background: var(--c-blue);
  color: #fff;
  padding: 8px 12px;
  font-size: 13px;
  font-weight: bold;
  display: flex;
  align-items: center;
  gap: 7px;
}
.card-head svg {
  width: 15px;
  height: 15px;
  fill: currentColor;
  flex-shrink: 0;
}
.card-body { padding: 14px 12px; }

/* =================================================================
   FORMULAR-ZEILEN
   ================================================================= */
.f-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
  flex-wrap: wrap;
}
.f-row label {
  width: 155px;
  flex-shrink: 0;
  font-weight: bold;
  font-size: 12px;
  color: var(--c-text);
}
.f-row input,
.f-row select {
  flex: 1;
  min-width: 160px;
  padding: 6px 9px;
  border: 1px solid var(--c-border);
  border-radius: var(--radius);
  font-family: var(--font);
  font-size: 13px;
  background: #fafbfd;
  color: var(--c-text);
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}
.f-row input:focus,
.f-row select:focus {
  border-color: var(--c-blue);
  box-shadow: 0 0 0 2px rgba(26,82,150,.18);
  background: #fff;
}
.f-row input.iban-input {
  font-family: var(--font-mono);
  font-size: 14px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
}

/* =================================================================
   BUTTONS
   ================================================================= */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 7px 16px;
  background: var(--c-blue);
  color: #fff;
  border: none;
  border-radius: var(--radius);
  font-family: var(--font);
  font-size: 12px;
  font-weight: bold;
  cursor: pointer;
  transition: background .12s;
  white-space: nowrap;
}
.btn:hover { background: var(--c-blue-dk); color: #fff; text-decoration: none; }
.btn svg { width: 13px; height: 13px; fill: currentColor; }
.btn-sm { padding: 5px 11px; font-size: 11px; }
.btn-secondary {
  background: #5a6472;
}
.btn-secondary:hover { background: #3a4452; }

/* =================================================================
   ERGEBNISBOXEN
   ================================================================= */
.result-box {
  margin-top: 12px;
  border: 1px solid var(--c-border);
  border-left: 4px solid var(--c-border);
  padding: 12px;
  background: #fafbfd;
}
.result-box.valid   { border-left-color: var(--c-green); background: #f2fbf4; }
.result-box.invalid { border-left-color: var(--c-red);   background: #fdf4f4; }
.result-box.info    { border-left-color: var(--c-blue);  background: #f0f5fc; }

.result-status {
  font-size: 14px;
  font-weight: bold;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 7px;
}
.result-status.ok  { color: var(--c-green); }
.result-status.err { color: var(--c-red); }
.result-status svg { width: 16px; height: 16px; fill: currentColor; flex-shrink: 0; }

.iban-display {
  font-family: var(--font-mono);
  font-size: 17px;
  letter-spacing: 2px;
  background: #e8eef7;
  border: 1px solid var(--c-border);
  padding: 8px 12px;
  display: inline-block;
  margin-bottom: 10px;
  color: var(--c-blue-dk);
  border-radius: var(--radius);
}

.res-table { width: 100%; border-collapse: collapse; font-size: 12px; margin-top: 6px; }
.res-table td { padding: 5px 7px; border-bottom: 1px solid #e8eef0; }
.res-table td:first-child { color: var(--c-muted); width: 38%; font-weight: bold; }
.res-table tr:last-child td { border-bottom: none; }
.res-table code { font-family: var(--font-mono); font-size: 12px; background: #eef2f8; padding: 1px 4px; }

/* =================================================================
   HINWEIS-BOX
   ================================================================= */
.notice {
  background: #fffbea;
  border: 1px solid #e8d860;
  border-left: 3px solid #c8a820;
  padding: 8px 11px;
  font-size: 12px;
  color: #5a4800;
  margin-bottom: 12px;
  border-radius: var(--radius);
}

/* =================================================================
   TOOL-KACHELN
   ================================================================= */
.tool-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 10px;
}
.tool-tile {
  border: 1px solid var(--c-border);
  padding: 12px 10px;
  text-align: center;
  cursor: pointer;
  background: var(--c-white);
  color: var(--c-text);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  text-decoration: none;
  transition: border-color .12s, background .12s;
}
.tool-tile:hover {
  border-color: var(--c-blue);
  background: var(--c-blue-lt);
  text-decoration: none;
  color: var(--c-blue-dk);
}
.tool-tile svg { width: 26px; height: 26px; fill: var(--c-blue); }
.tool-tile .tile-name { font-weight: bold; font-size: 12px; }
.tool-tile .tile-desc { font-size: 11px; color: var(--c-muted); }

/* =================================================================
   BADGE-LINKS (Beispiele)
   ================================================================= */
.badge-list { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 8px; }
.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  border: 1px solid var(--c-border);
  padding: 3px 9px;
  font-size: 11px;
  cursor: pointer;
  background: #f4f7fb;
  border-radius: 2px;
  transition: background .12s;
}
.badge:hover { background: var(--c-blue-lt); border-color: var(--c-blue); }

/* =================================================================
   SEO-TEXT / INFOBEREICH
   ================================================================= */
.info-text { font-size: 12px; color: var(--c-muted); line-height: 1.65; }
.info-text h2 { font-size: 14px; color: var(--c-blue-dk); margin: 14px 0 5px; font-family: var(--font); }
.info-text h3 { font-size: 13px; color: var(--c-text); margin: 10px 0 4px; }
.info-text ul, .info-text ol { margin-left: 18px; margin-top: 4px; }
.info-text li { margin-bottom: 3px; }
.info-text code { font-family: var(--font-mono); background: #eef2f8; padding: 1px 4px; font-size: 12px; }

/* =================================================================
   FAQ
   ================================================================= */
.faq-item { border-top: 1px solid var(--c-border); }
.faq-q {
  padding: 9px 0;
  font-weight: bold;
  font-size: 12px;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  color: var(--c-blue-dk);
}
.faq-arrow {
  width: 12px;
  height: 12px;
  fill: var(--c-muted);
  flex-shrink: 0;
  transition: transform .2s;
}
.faq-item.open .faq-arrow { transform: rotate(180deg); }
.faq-a { display: none; padding: 0 0 10px; font-size: 12px; color: var(--c-muted); line-height: 1.65; }
.faq-item.open .faq-a { display: block; }

/* =================================================================
   TABELLEN (Länderliste etc.)
   ================================================================= */
.data-table { width: 100%; border-collapse: collapse; font-size: 12px; }
.data-table th {
  background: var(--c-blue-lt);
  padding: 6px 8px;
  text-align: left;
  border-bottom: 2px solid var(--c-border);
  font-weight: bold;
  color: var(--c-blue-dk);
}
.data-table td { padding: 5px 8px; border-bottom: 1px solid #eaeff6; }
.data-table tr:nth-child(even) td { background: var(--c-row-alt); }
.data-table tr:hover td { background: var(--c-blue-lt); }
.data-table td:last-child { font-family: var(--font-mono); font-size: 11px; color: var(--c-blue); }
.badge-sepa {
  display: inline-block;
  background: #1d6b35;
  color: #fff;
  font-size: 10px;
  padding: 1px 5px;
  border-radius: 2px;
}
.badge-intl {
  display: inline-block;
  background: #5a6472;
  color: #fff;
  font-size: 10px;
  padding: 1px 5px;
  border-radius: 2px;
}

/* =================================================================
   LOADING OVERLAY
   ================================================================= */
#page-loader {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(255,255,255,.65);
  z-index: 9999;
  align-items: center;
  justify-content: center;
}
#page-loader.active { display: flex; }
#page-loader img { width: 48px; height: 48px; }

/* =================================================================
   SEITENÜBERGANG
   ================================================================= */
#content { transition: opacity .15s; }
#content.fading { opacity: 0; }

/* =================================================================
   FOOTER
   ================================================================= */
footer#site-footer {
  background: var(--c-blue-dk);
  color: rgba(255,255,255,.75);
  padding: 14px 12px;
  font-size: 11px;
}
.footer-links { display: flex; flex-wrap: wrap; gap: 3px 12px; margin-bottom: 7px; }
.footer-links a { color: rgba(255,255,255,.8); }
.footer-links a:hover { color: #fff; text-decoration: none; }
.footer-sep { color: rgba(255,255,255,.3); margin: 0 2px; }
.footer-copy { color: rgba(255,255,255,.4); font-size: 10px; }

/* =================================================================
   RESPONSIVE – Formular/Grid
   ================================================================= */
@media (max-width: 540px) {
  .f-row { flex-direction: column; align-items: flex-start; }
  .f-row label { width: auto; }
  .f-row input, .f-row select { width: 100%; }
  .tool-grid { grid-template-columns: 1fr 1fr; }
}

/* =================================================================
   AD COLUMNS – adaptiv 300x600
   Breakpoints:
   - >= 1340px : beide Spalten (links + rechts), je 300px
   - 1040–1339px: nur rechte Spalte, 300px
   - < 1040px  : keine Spalten
   ================================================================= */

/* Beide Spalten: ab 1340px */
@media (max-width: 1339px) {
  #ad-left { display: none !important; }
}

/* Nur rechts: 1040–1339px */
@media (min-width: 1040px) and (max-width: 1339px) {
  #ad-right { display: flex !important; }
  #main-col { max-width: calc(100% - 316px); }
}

/* Keine Spalten unter 1040px */
@media (max-width: 1039px) {
  #ad-left, #ad-right { display: none !important; }
  #main-col { max-width: 100%; }
}

/* Ab 1340px: beide sichtbar */
@media (min-width: 1340px) {
  #ad-left, #ad-right { display: flex !important; }
  #main-col { max-width: 800px; }
}
