/* cutover-nachlauf-1 C4: Karten-Widget (TC-Farben wie Galerie-Widget). */
:root { --kw-rot: #e20000; --kw-text: #222; --kw-grau: #6b7280; --kw-linie: #e5e7eb; --kw-flaeche: #fff; }
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; font-family: Arial, Helvetica, sans-serif; color: var(--kw-text); background: transparent; }
.kw { position: relative; height: 100%; min-height: 420px; }
/* K 21.11.2026 18:12 (KRE): Kopf wie Galerie-Widget (.ig-wrap.embed-mode + .ig-header/.ig-count, Werte 1:1, ohne sticky) */
body.kw-mit-kopf { display: flex; flex-direction: column; background: #fff; }
body.kw-mit-kopf .kw { flex: 1 1 auto; height: auto; }
.kw-kopf { text-align: center; padding: 24px 0 10px; background: #fff; color: #1a1a2e;
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif; }
.kw-kopf[hidden] { display: none; }
.kw-kopf h2 { margin: 0 0 6px; font-size: 1.8rem; font-weight: 700; color: #1a1a2e; }
.kw-kopf p { margin: 0; color: #4a4a5a; font-size: 1rem; }
.kw-zaehler { display: inline-block; background: #E30613; color: #fff; font-size: .8rem; font-weight: 600; padding: 3px 10px;
  border-radius: 20px; margin-left: 8px; vertical-align: middle; }
.kw-zaehler[hidden] { display: none; }
@media (max-width: 768px) { .kw-kopf h2 { font-size: 1.4rem; } .kw-kopf { padding: 20px 0 8px; } }
.kw-karte { position: absolute; inset: 0; }
.kw-hinweis { position: absolute; left: 12px; top: 12px; z-index: 500; margin: 0; padding: 8px 12px; background: var(--kw-flaeche);
  border: 1px solid var(--kw-linie); border-radius: 6px; font-size: 14px; }
.kw-schleier { position: fixed; inset: 0; z-index: 1000; display: flex; align-items: center; justify-content: center;
  padding: 16px; background: rgba(0, 0, 0, .5); }
.kw-schleier[hidden] { display: none; }
.kw-dialog { position: relative; width: 100%; max-width: 520px; max-height: calc(100vh - 32px); overflow: auto; padding: 20px;
  background: var(--kw-flaeche); border-radius: 10px; box-shadow: 0 20px 50px rgba(0, 0, 0, .3); }
.kw-zu { position: absolute; top: 8px; right: 10px; border: 0; background: none; font-size: 26px; line-height: 1; cursor: pointer; color: var(--kw-grau); }
.kw-bild { display: block; width: 100%; max-height: 240px; object-fit: cover; border-radius: 6px; margin-bottom: 12px; }
.kw-dialog h2 { margin: 0 28px 10px 0; font-size: 18px; }
.kw-daten { display: grid; grid-template-columns: auto 1fr; gap: 4px 12px; margin: 0 0 14px; font-size: 14px; }
.kw-daten dt { color: var(--kw-grau); }
.kw-daten dd { margin: 0; font-weight: bold; }
.kw-partner { display: flex; gap: 12px; align-items: center; padding: 12px; border: 1px solid var(--kw-linie); border-radius: 8px; margin-bottom: 14px; font-size: 14px; }
.kw-partner a { display: block; color: var(--kw-rot); text-decoration: none; }
.kw-partner-name { font-weight: bold; }
.kw-avatar { flex: 0 0 44px; height: 44px; border-radius: 50%; background: var(--kw-rot); color: #fff; display: flex;
  align-items: center; justify-content: center; font-weight: bold; }
.kw-knoepfe { display: flex; gap: 8px; flex-wrap: wrap; }
.kw-knopf { display: inline-flex; align-items: center; justify-content: center; min-height: 38px; padding: 0 16px; border: 1px solid var(--kw-rot);
  border-radius: 6px; background: #fff; color: var(--kw-rot); font: inherit; font-size: 14px; font-weight: bold; cursor: pointer; text-decoration: none; }
.kw-knopf[hidden] { display: none; }
.kw-primaer { background: var(--kw-rot); color: #fff; }
.kw-formular { display: flex; flex-direction: column; gap: 8px; margin-top: 14px; font-size: 14px; }
.kw-formular[hidden] { display: none; }
.kw-formular label { display: flex; flex-direction: column; gap: 3px; }
.kw-formular input, .kw-formular textarea { padding: 8px; border: 1px solid var(--kw-linie); border-radius: 6px; font: inherit; }
.kw-formular .kw-einwilligung { flex-direction: row; gap: 8px; font-size: 12px; color: var(--kw-grau); }
.kw-meldung { margin: 0; min-height: 1em; }
.kw-meldung.fehler { color: var(--kw-rot); }
.kw-meldung.ok { color: #15803d; }
.kw-gesendet { margin: 12px 0 4px; padding: 16px; border-radius: 8px; background: #f0fdf4; border: 1px solid #86efac; text-align: center; }
.kw-gesendet-titel { margin: 0 0 6px; font-size: 1.2em; font-weight: 700; color: #15803d; }
.kw-gesendet p { margin: 0; }
.kw-pin { background: var(--kw-rot); }
/* NACHTRAG C-3: Honeypot ausserhalb des sichtbaren Bereichs (nicht display:none, sonst fuellen manche Bots nicht) */
.kw-falle { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.kw-partner[hidden] { display: none; }
.kw-vorschau-band { position: absolute; right: 12px; top: 12px; z-index: 500; margin: 0; padding: 6px 10px; border-radius: 6px;
  background: #fef3c7; color: #8a6100; font-size: 13px; font-weight: bold; }
.kw-vorschau-band[hidden] { display: none; }
/* E-0189 P1: Stapel-Pin mit Zahl + Liste im Dialog */
.kw-stapel { display: flex; align-items: center; justify-content: center; width: 30px; height: 30px; border: 2px solid #fff;
  border-radius: 50%; background: var(--kw-rot); color: #fff; font-size: 13px; font-weight: bold; box-shadow: 0 1px 4px rgba(0, 0, 0, .35); }
.kw-liste { list-style: none; margin: 0 0 6px; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.kw-liste[hidden], .kw-zurueck[hidden], .kw-daten[hidden], .kw-knoepfe[hidden] { display: none; }
.kw-liste button { width: 100%; min-height: 44px; padding: 10px 12px; border: 1px solid var(--kw-linie); border-radius: 8px;
  background: #fff; font: inherit; font-size: 14px; text-align: left; cursor: pointer; }
.kw-liste button:hover, .kw-liste button:focus-visible { border-color: var(--kw-rot); }
.kw-liste strong { display: block; }
.kw-liste span { color: var(--kw-grau); }
.kw-zurueck { margin: 0 0 10px; padding: 0; border: 0; background: none; color: var(--kw-rot); font: inherit; font-size: 14px; cursor: pointer; }
/* AUFTRAG-EK-KARTE: mobil als Bottom-Sheet (gilt fuer Widget und EK-Modus) */
@media (max-width: 640px) {
  .kw-schleier { align-items: flex-end; padding: 0; }
  .kw-dialog { max-width: none; max-height: 80vh; border-radius: 14px 14px 0 0; padding-bottom: 24px; }
  .kw-knoepfe .kw-knopf { flex: 1 1 100%; }
}
