/* ══════════════════════════════════════════════════════════════════════
   core/ui/stil.css – das EINE Stylesheet für alle Seiten (Etappe A, Okt. 2026)
   Aufbau: 1. Grundlagen (vorher app/style.css = core/ui/basis.css)
           2. Shell: Kopf, Fussnavigation, Menü, Modulfarben (vorher core/ui/gnoed.css)
           3. Seitenvorlage (core/ui/seite.html)
   Module ergänzen nur mit einer kleinen eigenen Datei <modul>/modul.css. Kein Inline-CSS.
   ══════════════════════════════════════════════════════════════════════ */

/* ── 1. Grundlagen ───────────────────────────────────────────────────── */
/* ============================================================
   Gemeinsames Stylesheet
   Starke Kontraste, klare Struktur
   ============================================================ */

:root {
  --blue:        #0f2d6b;
  --blue-hover:  #1a3f8f;
  --blue-light:  #ddeaff;
  --blue-mid:    #7aaaf0;
  --accent:      #c8000a;

  --text:        #0a0a0a;
  --text-muted:  #444444;
  --text-hint:   #777777;

  --bg:          #e8eaed;
  --bg-card:     #ffffff;
  --bg-input:    #ffffff;
  --bg-tertiary: #d0d3d8;

  --border:      #999999;
  --border-med:  #666666;

  --radius:      10px;
  --radius-sm:   6px;

  --green-bg:    #d4edda;
  --green-text:  #155724;
  --amber-bg:    #fff3cd;
  --amber-text:  #856404;

  --danger:      #b30000;
  --danger-bg:   #ffe5e5;
  --danger-border: #cc0000;

  --shadow:      0 2px 6px rgba(0,0,0,0.18);
  --shadow-card: 0 1px 4px rgba(0,0,0,0.12);
}

@media (prefers-color-scheme: dark) {
  :root {
    --blue:        #4d8aff;
    --blue-hover:  #6fa0ff;
    --blue-light:  #1a2d4a;
    --blue-mid:    #3a6bbf;
    --accent:      #ff4d4d;

    --text:        #f0f0f0;
    --text-muted:  #b0b0b0;
    --text-hint:   #808080;

    --bg:          #111318;
    --bg-card:     #1e2128;
    --bg-input:    #252830;
    --bg-tertiary: #2a2e38;

    --border:      #555555;
    --border-med:  #777777;

    --green-bg:    #1a3a22;
    --green-text:  #7ed9a0;
    --amber-bg:    #3a2d00;
    --amber-text:  #ffc940;

    --danger:      #ff6b6b;
    --danger-bg:   #3a1010;
    --danger-border: #cc3333;
  }
}

/* ── Manuelle Hell/Dunkel-Wahl ─────────────────────────────────
   Übersteuert per Attribut-Selektor (höhere Spezifität) die
   automatische Systemeinstellung oben, sobald der Nutzer in der
   App explizit Hell oder Dunkel wählt (siehe applyTheme() in JS).
   Ohne data-theme-Attribut bleibt es beim Systemverhalten. */
:root[data-theme="light"] {
  --blue:        #0f2d6b;
  --blue-hover:  #1a3f8f;
  --blue-light:  #ddeaff;
  --blue-mid:    #7aaaf0;
  --accent:      #c8000a;

  --text:        #0a0a0a;
  --text-muted:  #444444;
  --text-hint:   #777777;

  --bg:          #e8eaed;
  --bg-card:     #ffffff;
  --bg-input:    #ffffff;
  --bg-tertiary: #d0d3d8;

  --border:      #999999;
  --border-med:  #666666;

  --green-bg:    #d4edda;
  --green-text:  #155724;
  --amber-bg:    #fff3cd;
  --amber-text:  #856404;

  --danger:      #b30000;
  --danger-bg:   #ffe5e5;
  --danger-border: #cc0000;
}

:root[data-theme="dark"] {
  --blue:        #4d8aff;
  --blue-hover:  #6fa0ff;
  --blue-light:  #1a2d4a;
  --blue-mid:    #3a6bbf;
  --accent:      #ff4d4d;

  --text:        #f0f0f0;
  --text-muted:  #b0b0b0;
  --text-hint:   #808080;

  --bg:          #111318;
  --bg-card:     #1e2128;
  --bg-input:    #252830;
  --bg-tertiary: #2a2e38;

  --border:      #555555;
  --border-med:  #777777;

  --green-bg:    #1a3a22;
  --green-text:  #7ed9a0;
  --amber-bg:    #3a2d00;
  --amber-text:  #ffc940;

  --danger:      #ff6b6b;
  --danger-bg:   #3a1010;
  --danger-border: #cc3333;
}

/* ── Reset ─────────────────────────────────────────────────── */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  font-size: 19px;
  line-height: 1.5;
  overscroll-behavior: none;
}

/* ── App Shell ──────────────────────────────────────────────── */
.app {
  display: flex;
  flex-direction: column;
  height: 100dvh;
  width: 100%;
  max-width: 1000px;
  margin: 0 auto;
  overflow: hidden;
  position: relative;
}

@media (min-width:1000px) {
  body {
    background: #d0d3d8;
  }
  .app {
    box-shadow: 0 0 60px rgba(0,0,0,0.18);
  }
}

/* Multiscore-Queransicht: volle Seitenbreite statt Phone-Rahmen */
.app.full-width {
  max-width: 100% !important;
  box-shadow: none !important;
}

/* Multiscore-Queransicht: Bottom-Nav ausblenden (kein Platz/Bedarf während der
   Schnellerfassung) UND die Punkte-Buttons füllen die tatsächlich verfügbare
   Höhe flexibel aus (statt einer festen Kompakt-Höhe) — auf grossen Tablets
   werden sie automatisch grösser, auf kleinen bleiben sie klein genug, dass
   alle 11 Werte (0–10) ohne Scrollen sichtbar sind. */
.app.full-width .bottomnav { display: none !important; }

.app.full-width #multi-erf-content {
  display: flex;
  flex-direction: column;
  min-height: 0;
}
.app.full-width .multi-quer-panels {
  flex: 1;
  display: flex;
  min-height: 0;
  align-items: stretch;
}
.app.full-width .multi-quer-panel {
  display: flex;
  flex-direction: column;
  min-height: 0;
}
.app.full-width .multi-quer-panel-header {
  flex-shrink: 0;
}
.app.full-width .schuss-cols {
  flex: 1;
  min-height: 0;
  align-items: stretch;
}
.app.full-width .schuss-col {
  height: auto;
}
.app.full-width .schuss-col-header,
.app.full-width .schuss-val {
  flex-shrink: 0;
}
.app.full-width .pt-btn {
  flex: 1 1 0;
  height: auto !important;
  min-height: 22px;
  font-size: 15px !important;
}

/* ── Topbar ─────────────────────────────────────────────────── */
.topbar {
  background: var(--blue);
  color: #fff;
  padding: 12px 60px 12px 16px;
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 56px;
  flex-shrink: 0;
  box-shadow: 0 2px 6px rgba(0,0,0,0.3);
}

.topbar h1 {
  font-size: 21px;
  font-weight: 600;
  color: #fff;
  flex: 1;
  letter-spacing: 0.01em;
}

.topbar-icon {
  background: rgba(255,255,255,0.15);
  border: 1px solid rgba(255,255,255,0.3);
  color: #fff;
  font-size: 24px;
  cursor: pointer;
  padding: 6px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  line-height: 1;
}
.topbar-icon:active { background: rgba(255,255,255,0.3); }

/* ── Screens ────────────────────────────────────────────────── */
.screen {
  display: none;
  flex: 1;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  flex-direction: column;
  background: var(--bg);
}
.screen.active { display: flex; }
.pad { padding: 14px; }

/* ── Bottom Nav ─────────────────────────────────────────────── */
.bottomnav {
  display: flex;
  border-top: 2px solid var(--border);
  background: var(--bg-card);
  flex-shrink: 0;
  padding-bottom: env(safe-area-inset-bottom);
}

.tabnav {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 8px 4px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-muted);
  gap: 3px;
  border: none;
  background: none;
  border-top: 3px solid transparent;
  transition: color 0.15s;
}
.tabnav svg {
  width: 22px;
  height: 22px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.tabnav.active {
  color: var(--blue);
  border-top-color: var(--blue);
  background: var(--blue-light);
}

/* ── Cards ──────────────────────────────────────────────────── */
.card {
  background: var(--bg-card);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 14px;
  margin-bottom: 10px;
  box-shadow: var(--shadow-card);
}

/* ── Section Label ──────────────────────────────────────────── */
.section-label {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-muted);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin: 14px 0 8px;
}

/* ── Tags ───────────────────────────────────────────────────── */
.tag {
  font-size: 15px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 4px;
  display: inline-block;
  border: 1px solid transparent;
}
.tag-hsm  { background: var(--amber-bg);  color: var(--amber-text);  border-color: #d4a017; }
.tag-sm   { background: var(--green-bg);  color: var(--green-text);  border-color: #2d8a4e; }
.tag-blue { background: var(--blue-light); color: var(--blue);        border-color: var(--blue-mid); }

/* ── Buttons ────────────────────────────────────────────────── */
.btn {
  display: block;
  width: 100%;
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  border: 1.5px solid var(--border-med);
  background: var(--bg-card);
  font-size: 16px;
  line-height: 1.3;
  font-weight: 500;
  cursor: pointer;
  color: var(--text);
  text-align: center;
  font-family: inherit;
  transition: background 0.15s;
}
.btn:active { opacity: 0.8; }
.btn + .btn { margin-top: 6px; }   /* Knöpfe kleiner und feiner (René 10.11.2026) */

/* ── Globale Tipp-Rückmeldung ──────────────────────────────────
   Trifft praktisch jedes klickbare Element in der App (Karten, Admin-
   Menüpunkte, Tabellenzeilen, individuelle Buttons mit Inline-Style),
   ohne jede einzelne onclick-Stelle im Code anfassen zu müssen.
   Ausgenommen: Formularfelder (native Fokus-Rückmeldung reicht dort)
   und bereits eigens behandelte Elemente (keine doppelte Wirkung, nur
   redundant, aber unschädlich). */
[onclick]:not(input):not(select):not(textarea):active {
  opacity: 0.6;
  transition: opacity 0.08s;
}

.btn-primary {
  background: var(--blue);
  color: #fff;
  border-color: var(--blue);
  font-weight: 600;
}
.btn-primary:active { background: var(--blue-hover); }

.btn-danger {
  background: var(--danger-bg);
  color: var(--danger);
  border-color: var(--danger-border);
  font-weight: 600;
}

/* ── Form ───────────────────────────────────────────────────── */
.form-group { margin-bottom: 14px; }

.form-label {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 5px;
  display: block;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.form-input {
  width: 100%;
  padding: 10px 12px;
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 19px;
  font-family: inherit;
  background: var(--bg-input);
  color: var(--text);
  outline: none;
  transition: border-color 0.15s;
}
.form-input:focus { border-color: var(--blue); }

.form-select {
  width: 100%;
  padding: 10px 12px;
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 18px;
  font-weight: 500;
  font-family: inherit;
  background: var(--bg-input);
  color: var(--text);
  outline: none;
}
.form-select:focus { border-color: var(--blue); }

/* ── Score List ─────────────────────────────────────────────── */
.score-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 0;
  border-bottom: 1.5px solid var(--border);
}
.score-thumb {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  background: var(--blue-light);
  border: 1.5px solid var(--blue-mid);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.score-thumb svg { width: 20px; height: 20px; stroke: var(--blue); fill: none; stroke-width: 2; }
.score-info { flex: 1; }
.score-name { font-size: 18px; font-weight: 600; color: var(--text); }
.score-meta { font-size: 16px; color: var(--text-muted); font-weight: 500; }
.score-total { font-size: 19px; font-weight: 700; color: var(--blue); white-space: nowrap; }

/* ── Passe Block ────────────────────────────────────────────── */
.passe-block {
  border: 2px solid var(--border);
  border-radius: var(--radius);
  padding: 12px;
  margin-bottom: 10px;
  background: var(--bg-card);
  box-shadow: var(--shadow-card);
}
.passe-header { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 3px; }
.passe-title  { font-size: 18px; font-weight: 700; color: var(--text); }
.passe-total  { font-size: 18px; font-weight: 700; color: var(--blue); }
.passe-meta   { font-size: 16px; font-weight: 500; color: var(--text-muted); margin-bottom: 10px; }

/* ── Score Input ────────────────────────────────────────────── */
.schuss-cols { display: flex; gap: 4px; flex-wrap: nowrap; overflow-x: auto; align-items: flex-start; padding-bottom: 4px; }



.schuss-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  flex: 0 0 calc((100% - 5 * 4px) / 6) !important;
  width: calc((100% - 5 * 4px) / 6) !important;
  min-width: 0 !important;
}

.pt-btn {
  width: 100% !important;
  height: 54px !important;
  font-size: 14px;
}
.schuss-col-header {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-muted);
  height: 24px;
  display: flex;
  align-items: center;
}
.schuss-val {
  width: 100%;
  height: 28px;
  border-radius: var(--radius-sm);
  border: 2px solid var(--blue-mid);
  background: var(--blue-light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  font-weight: 700;
  color: var(--blue);
}
.schuss-val.empty {
  background: var(--bg-tertiary);
  border: 2px dashed var(--border);
  color: var(--text-hint);
  font-weight: 400;
}
.pt-btn {
  width: 100%;
  min-width: 0;
  height: 44px;
  border-radius: 4px;
  border: 1.5px solid var(--border);
  font-size: 14px;
  font-weight: 600;
  background: var(--bg-card);
  cursor: pointer;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  transition: background 0.1s;
}
.pt-btn:active { opacity: 0.7; }
.pt-btn.sel {
  background: var(--blue);
  color: #fff;
  border-color: var(--blue);
  box-shadow: inset 0 0 0 2px rgba(255,255,255,0.3);
  font-weight: 800;
}

/* Ausgewählter Wert oben in der Spalte */
.schuss-val:not(.empty) {
  background: var(--blue);
  color: #fff;
  border-color: var(--blue);
  font-weight: 700;
}

/* ── Image Slots ────────────────────────────────────────────── */
.img-row { display: flex; gap: 4px; margin-top: 10px; }
.img-slot {
  flex: 0 0 calc((100% - 5 * 4px) / 6);
  width: calc((100% - 5 * 4px) / 6);
  height: 48px;
  border-radius: var(--radius-sm);
  border: 2px dashed var(--border-med);
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-tertiary);
  cursor: pointer;
  transition: border-color 0.15s;
}
.img-slot:active { opacity: 0.7; }
.img-slot.filled {
  background: var(--blue-light);
  border: 2px solid var(--blue-mid);
}
.img-slot svg { width: 20px; height: 20px; stroke: var(--text-muted); fill: none; stroke-width: 2; }
.img-slot.filled svg { stroke: var(--blue); }

/* ── Total Bar ──────────────────────────────────────────────── */
.total-bar {
  background: var(--blue);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 8px 0 12px;
}
.total-label { font-size: 17px; font-weight: 600; color: rgba(255,255,255,0.85); }
.total-val   { font-size: 24px; font-weight: 700; color: #fff; }

/* ── Signature ──────────────────────────────────────────────── */
.sig-canvas {
  width: 100%;
  height: 220px;
  border: 3px solid var(--blue);
  border-radius: var(--radius-sm);
  background: #ffffff;
  cursor: crosshair;
  touch-action: none;
  display: block;
}
.sig-clear {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-muted);
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px 0;
  text-decoration: underline;
}

/* ── Kontakt ────────────────────────────────────────────────── */
.kontakt-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 0;
  border-bottom: 1.5px solid var(--border);
}
.avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--blue);
  border: 2px solid var(--blue-mid);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
}
.avatar img { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; }

/* ── Kalender ───────────────────────────────────────────────── */
.kal-item {
  padding: 11px 0;
  border-bottom: 1.5px solid var(--border);
}
.kal-date  { font-size: 15px; font-weight: 700; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.05em; }
.kal-title { font-size: 19px; font-weight: 700; margin: 3px 0 2px; color: var(--text); }
.kal-time  { font-size: 17px; font-weight: 500; color: var(--text-muted); margin-bottom: 6px; }
.kal-tags  { display: flex; gap: 4px; flex-wrap: wrap; }

/* ── Timer ──────────────────────────────────────────────────── */
.timer-display {
  font-size: 92px;
  font-weight: 700;
  text-align: center;
  padding: 20px 0 4px;
  color: var(--text);
  letter-spacing: 2px;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}
.timer-display.running { color: var(--blue); }
.timer-display.urgent  { color: var(--danger); }

.zeit-grid { display: grid; grid-template-columns: repeat(5,1fr); gap: 6px; margin: 8px 0; }
.zeit-chip {
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 8px 4px;
  text-align: center;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  background: var(--bg-card);
  color: var(--text);
  font-family: inherit;
}
.zeit-chip.sel {
  background: var(--blue);
  border-color: var(--blue);
  color: #fff;
}

.timer-btns { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 14px; }

/* ── Login ──────────────────────────────────────────────────── */
.login-wrap {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  flex: 1;
  padding: 32px 24px;
  background: var(--bg);
}
.login-logo  { font-size: 60px; margin-bottom: 10px; }
.login-title { font-size: 26px; font-weight: 700; color: var(--blue); margin-bottom: 4px; }
.login-sub   { font-size: 18px; color: var(--text-muted); font-weight: 500; margin-bottom: 32px; }
.login-form  { width: 100%; max-width: 340px; }

.error-msg {
  background: var(--danger-bg);
  color: var(--danger);
  border: 2px solid var(--danger-border);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  font-size: 17px;
  font-weight: 600;
  margin-bottom: 12px;
  display: none;
}

/* ── Admin ──────────────────────────────────────────────────── */
.admin-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 0;
  border-bottom: 1.5px solid var(--border);
  cursor: pointer;
}
.admin-icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  background: var(--blue-light);
  border: 1.5px solid var(--blue-mid);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.admin-icon svg { width: 20px; height: 20px; stroke: var(--blue); fill: none; stroke-width: 2; }
.admin-label { font-size: 19px; font-weight: 600; color: var(--text); }
.admin-sub   { font-size: 16px; font-weight: 500; color: var(--text-muted); }
.chevron { width: 18px; height: 18px; stroke: var(--text-hint); fill: none; stroke-width: 2.5; margin-left: auto; }

/* ── Loader ─────────────────────────────────────────────────── */
.loader { display: flex; align-items: center; justify-content: center; flex: 1; min-height: 80px; }
.spinner {
  width: 36px;
  height: 36px;
  border: 3px solid var(--border);
  border-top-color: var(--blue);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ── Toast ──────────────────────────────────────────────────── */
.toast {
  position: fixed;
  bottom: 84px;
  left: 50%;
  transform: translateX(-50%);
  background: #111;
  color: #fff;
  padding: 10px 20px;
  border-radius: 20px;
  font-size: 17px;
  font-weight: 600;
  opacity: 0;
  transition: opacity 0.3s;
  pointer-events: none;
  z-index: 999;
  white-space: nowrap;
  box-shadow: 0 4px 12px rgba(0,0,0,0.3);
}
.toast.show { opacity: 1; }

/* ── Overlay / Modal ────────────────────────────────────────── */
.overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.55);
  z-index: 100;
  align-items: flex-end;
}
.overlay.show { display: flex; }
.overlay { justify-content: center; }
.modal {
  max-width: 1000px;
  background: var(--bg-card);
  border-radius: 20px 20px 0 0;
  border-top: 3px solid var(--blue);
  padding: 20px 16px 32px;
  width: 100%;
  max-height: 85dvh;
  overflow-y: auto;
  box-shadow: 0 -4px 16px rgba(0,0,0,0.25);
}
.modal-handle {
  width: 40px;
  height: 5px;
  background: var(--border-med);
  border-radius: 3px;
  margin: 0 auto 16px;
}
.modal-title { font-size: 22px; font-weight: 700; margin-bottom: 16px; color: var(--text); }

/* ── Rangliste ──────────────────────────────────────────────── */
.rang-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1.5px solid var(--border);
}
.rang-nr        { width: 26px; font-size: 18px; font-weight: 700; color: var(--text-muted); flex-shrink: 0; }
.rang-nr.gold   { color: #b8860b; }
.rang-nr.silver { color: #606060; }
.rang-info      { flex: 1; }
.rang-name      { font-size: 18px; font-weight: 600; color: var(--text); }
.rang-detail    { font-size: 16px; font-weight: 500; color: var(--text-muted); }
.rang-score     { font-size: 19px; font-weight: 700; color: var(--blue); }

/* ── Offene Termine ─────────────────────────────────────────── */
.termin-datum {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-muted);
  margin-top: 2px;
}

/* News-Fliesstext: Absicherung gegen zu grosse/überlappende Bilder,
   falls künftig Bilder direkt im Richtext eingefügt werden können. */
.news-html img {
  max-width: 100%;
  height: auto;
  display: block;
  border-radius: var(--radius-sm);
  margin: 8px 0;
}

/* ── 2. Shell (vorher core/ui/gnoed.css) ──────────────────────────────── */
/* gnoed.css — gemeinsame Basis aller Module: Modulfarben, Kopfzeilen-Rechtsgruppe, Unternavigation, Profil-Menü.
   Nach dem Basis-Stylesheet einbinden. <html data-modul="schuetzen|helfer|checklists|zeit"> setzt die Grundfarbe.
   --gn / --gn-light / --gn-mid = Modulfarbe (auch für Module ohne --blue-Variablen, z. B. Helfertool). */
:root[data-modul="schuetzen"]{--blue:#0f2d6b;--blue-hover:#1a3f8f;--blue-light:#ddeaff;--blue-mid:#7aaaf0;--gn:#0f2d6b;--gn-light:#ddeaff;--gn-mid:#7aaaf0;}
@media(prefers-color-scheme:dark){:root[data-modul="schuetzen"]:not([data-theme="light"]){--blue:#4d8aff;--blue-hover:#6fa0ff;--blue-light:#1a2d4a;--blue-mid:#3a6bbf;--gn:#4d8aff;--gn-light:#1a2d4a;--gn-mid:#3a6bbf;}}
:root[data-modul="schuetzen"][data-theme="dark"]{--blue:#4d8aff;--blue-hover:#6fa0ff;--blue-light:#1a2d4a;--blue-mid:#3a6bbf;--gn:#4d8aff;--gn-light:#1a2d4a;--gn-mid:#3a6bbf;}
:root[data-modul="helfer"]{--blue:#1a4d2e;--blue-hover:#236b3f;--blue-light:#d9f2e2;--blue-mid:#6fc48f;--gn:#1a4d2e;--gn-light:#d9f2e2;--gn-mid:#6fc48f;}
@media(prefers-color-scheme:dark){:root[data-modul="helfer"]:not([data-theme="light"]){--blue:#2e9e5b;--blue-hover:#38b068;--blue-light:#12301e;--blue-mid:#2f8a55;--gn:#2e9e5b;--gn-light:#12301e;--gn-mid:#2f8a55;}}
:root[data-modul="helfer"][data-theme="dark"]{--blue:#2e9e5b;--blue-hover:#38b068;--blue-light:#12301e;--blue-mid:#2f8a55;--gn:#2e9e5b;--gn-light:#12301e;--gn-mid:#2f8a55;}
:root[data-modul="checklists"]{--blue:#b45309;--blue-hover:#c96a10;--blue-light:#ffe9d0;--blue-mid:#f0a860;--gn:#b45309;--gn-light:#ffe9d0;--gn-mid:#f0a860;}
@media(prefers-color-scheme:dark){:root[data-modul="checklists"]:not([data-theme="light"]){--blue:#ff9a3d;--blue-hover:#ffb066;--blue-light:#3a2610;--blue-mid:#b3671c;--gn:#ff9a3d;--gn-light:#3a2610;--gn-mid:#b3671c;}}
:root[data-modul="checklists"][data-theme="dark"]{--blue:#ff9a3d;--blue-hover:#ffb066;--blue-light:#3a2610;--blue-mid:#b3671c;--gn:#ff9a3d;--gn-light:#3a2610;--gn-mid:#b3671c;}
:root[data-modul="verwaltung"]{--blue:#475569;--blue-hover:#556479;--blue-light:#e2e8f0;--blue-mid:#94a3b8;--gn:#475569;--gn-light:#e2e8f0;--gn-mid:#94a3b8;}
@media(prefers-color-scheme:dark){:root[data-modul="verwaltung"]:not([data-theme="light"]){--blue:#94a3b8;--blue-hover:#b4c0d0;--blue-light:#1e2530;--blue-mid:#5b6b80;--gn:#94a3b8;--gn-light:#1e2530;--gn-mid:#5b6b80;}}
:root[data-modul="verwaltung"][data-theme="dark"]{--blue:#94a3b8;--blue-hover:#b4c0d0;--blue-light:#1e2530;--blue-mid:#5b6b80;--gn:#94a3b8;--gn-light:#1e2530;--gn-mid:#5b6b80;}
:root[data-modul="zeit"]{--blue:#5b2d9e;--blue-hover:#6e3fb8;--blue-light:#eadfff;--blue-mid:#a98be0;--gn:#5b2d9e;--gn-light:#eadfff;--gn-mid:#a98be0;}
@media(prefers-color-scheme:dark){:root[data-modul="zeit"]:not([data-theme="light"]){--blue:#a77dff;--blue-hover:#bb98ff;--blue-light:#281a45;--blue-mid:#6a45b8;--gn:#a77dff;--gn-light:#281a45;--gn-mid:#6a45b8;}}
:root[data-modul="zeit"][data-theme="dark"]{--blue:#a77dff;--blue-hover:#bb98ff;--blue-light:#281a45;--blue-mid:#6a45b8;--gn:#a77dff;--gn-light:#281a45;--gn-mid:#6a45b8;}
:root[data-modul="dateien"]{--blue:#0f766e;--blue-hover:#138a7e;--blue-light:#d5f5ef;--blue-mid:#6dd3c3;--gn:#0f766e;--gn-light:#d5f5ef;--gn-mid:#6dd3c3;}
@media(prefers-color-scheme:dark){:root[data-modul="dateien"]:not([data-theme="light"]){--blue:#3fd1bc;--blue-hover:#62dccb;--blue-light:#0f2e2b;--blue-mid:#1f8a7c;--gn:#3fd1bc;--gn-light:#0f2e2b;--gn-mid:#1f8a7c;}}
:root[data-modul="dateien"][data-theme="dark"]{--blue:#3fd1bc;--blue-hover:#62dccb;--blue-light:#0f2e2b;--blue-mid:#1f8a7c;--gn:#3fd1bc;--gn-light:#0f2e2b;--gn-mid:#1f8a7c;}
:root[data-modul="protokolle"]{--blue:#9d174d;--blue-hover:#b51e5c;--blue-light:#fbe4ee;--blue-mid:#e690b6;--gn:#9d174d;--gn-light:#fbe4ee;--gn-mid:#e690b6;}
@media(prefers-color-scheme:dark){:root[data-modul="protokolle"]:not([data-theme="light"]){--blue:#f472a8;--blue-hover:#f794bd;--blue-light:#3a1426;--blue-mid:#a3325f;--gn:#f472a8;--gn-light:#3a1426;--gn-mid:#a3325f;}}
:root[data-modul="protokolle"][data-theme="dark"]{--blue:#f472a8;--blue-hover:#f794bd;--blue-light:#3a1426;--blue-mid:#a3325f;--gn:#f472a8;--gn-light:#3a1426;--gn-mid:#a3325f;}

.gn-right{margin-left:auto;display:flex;align-items:center;gap:6px;flex-shrink:0}
.gn-btn{width:36px;height:36px;border-radius:50%;border:2px solid rgba(255,255,255,.6);background:rgba(255,255,255,.2);color:#fff;font-size:15px;font-weight:700;display:flex;align-items:center;justify-content:center;cursor:pointer;padding:0;font-family:inherit;background-size:cover;background-position:center;overflow:hidden}
/* ☰ (App-Wechsel) links vor dem Titel, Zeichen gross genug neben ＋ und Profilbild (René 7.11.2026) */
.gn-btn.gn-apps{flex-shrink:0}
.gn-btn.gn-apps svg{display:block}
.gn-menu{position:fixed;inset:0;z-index:100001;background:rgba(0,0,0,.3);font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Helvetica,Arial,sans-serif}
.gn-menu>div{position:absolute;top:56px;right:8px;min-width:230px;max-width:calc(100vw - 16px);max-height:calc(100vh - 70px);overflow-y:auto;background:var(--bg-card,#fff);color:var(--text,#111);border:1px solid var(--border,#ddd);border-top:3px solid var(--gn,#0f2d6b);border-radius:12px;box-shadow:0 4px 24px rgba(0,0,0,.25)}
.gn-menu .gn-head{padding:10px 14px;border-bottom:1px solid var(--border,#ddd);background:var(--bg-tertiary,#f5f7fa)}
.gn-menu .gn-head b{display:block;font-size:14px}.gn-menu .gn-head small{display:block;color:var(--text-muted,#666);font-size:12px;word-break:break-all}
.gn-menu button{display:block;width:100%;text-align:left;padding:11px 14px;margin:0;border:none;border-top:1px solid var(--border,#e5e5e5);border-radius:0;background:transparent;color:var(--text,#111);font-size:14px;font-family:inherit;cursor:pointer}
.gn-menu .gn-head+button{border-top:none}
.gn-menu button.gn-danger{color:#c8000a}
.gn-menu .gn-sep{height:6px;background:var(--bg-tertiary,#f0f2f5);border-top:1px solid var(--border,#e5e5e5)}
/* Schützen-App: Platz für ⠿ links neben dem Konto-Knopf, damit die Kopfzeilen-Knöpfe nicht überlagert werden */
.gn-hat-knopf .topbar{padding-right:104px !important}

/* Fusszeilen-Navigation (wie Schützen-App): .gn-foot am unteren Rand, Buttons mit Icon (<i>) und Text */
.gn-foot{display:flex;border-top:2px solid var(--border,#ddd);background:var(--bg-card,#fff);flex-shrink:0;padding-bottom:env(safe-area-inset-bottom)}
.gn-foot button{flex:1;min-width:0;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:3px;padding:8px 4px;font-size:14px;font-weight:500;font-family:inherit;color:var(--text-muted,#666);border:none;background:none;border-top:3px solid transparent;cursor:pointer;white-space:nowrap}
.gn-foot button i{font-style:normal;font-size:22px;line-height:1}
.gn-foot button.akt{color:var(--gn,#0f2d6b);border-top-color:var(--gn,#0f2d6b);background:var(--gn-light,#eef3fc)}
/* Seitenhintergrund wie im Helfertool (neutral); die Farbe kommt allein von der Kopfzeile */
html[data-modul]{background:var(--bg,#e8eaed);margin:0;height:100%;height:100dvh}
html[data-modul] body{background:var(--bg,#f4f6f5);margin:0;height:100%;height:100dvh}
/* Kopfzeile geht bis ganz nach oben (unter die iOS-Statusleiste) – wie im Helfertool: Vollfarbe */
html[data-modul] .topbar{padding-top:calc(12px + env(safe-area-inset-top))}
/* App-Fläche fest am Bildschirm (wie im Helfertool): iOS färbt die Statusleiste dann mit der Farbe der Kopfzeile */
html[data-modul] .app{position:fixed;top:0;left:0;right:0;bottom:0;height:auto;max-width:1000px;margin:0 auto}

/* Aufbau wie Helfertool: Anmeldung und Hauptansicht sind gleichrangige, bildschirmfüllende Rahmen (kein .app-Wrapper) */
html[data-modul] #s-login,html[data-modul] #s-main{position:fixed;top:0;left:0;right:0;bottom:0;overflow:hidden;max-width:1000px;margin:0 auto}
html[data-modul] #appShell.aktiv{max-width:1000px;margin:0 auto;background:var(--bg,#e8eaed)}
html[data-modul] #s-login{overflow-y:auto}
/* Rahmenbreite wie ursprünglich im Schützenmodul: max. 1000 px, auf dem Desktop mit Schatten */
@media(min-width:1000px){html[data-modul],html[data-modul] body{background:#d0d3d8}html[data-modul] .app,html[data-modul] #s-main,html[data-modul] #s-login,html[data-modul] #appShell.aktiv{box-shadow:0 0 60px rgba(0,0,0,.18)}}
/* aktiver Punkt der Fussnavigation: Modulfarbe hell hinterlegt (wie Arbeitszeiten) */
html[data-modul] nav.bottom-nav button.aktiv{background:var(--gn-light,#eef3fc);color:var(--gn,#1a4d2e);border-top-color:var(--gn,#1a4d2e)}

/* ── 3. Seitenvorlage (core/ui/seite.html) ───────────────────────────── */
#fehlerband{display:none;position:fixed;bottom:90px;left:8px;right:8px;border-radius:8px;background:#b30000;color:#fff;padding:8px;z-index:9999;text-align:center;font-size:15px}
.gn-seite #s-main{padding:0}
.gn-seite #s-main > .topbar{padding-right:10px;gap:8px}
.gn-seite #titel{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;min-width:0}
.gn-seite #main{flex:1;overflow-y:auto;min-height:0;-webkit-overflow-scrolling:touch}
.gn-seite .topbar-icon.gn-plus{font-size:24px}
/* Knöpfe in der Kopfzeile der Module rund wie ⠿ und Profil */
.gn-seite .topbar .topbar-icon{width:36px;height:36px;min-width:36px;padding:0;justify-content:center;border-radius:50%;border:2px solid rgba(255,255,255,.6);background:rgba(255,255,255,.2);flex-shrink:0}

/* Textfeld mit Formatierung (core/ui/richtext.js) und Anzeige von formatiertem Text */
.rt-box{border:2px solid var(--border);border-radius:10px;background:var(--bg-card);overflow:hidden}
.rt-box:focus-within{border-color:var(--gn,#0f2d6b)}
.rt-leiste{display:flex;gap:2px;padding:4px;border-bottom:1px solid var(--border);background:var(--bg-tertiary,#f5f7fa)}
.rt-leiste button{min-width:34px;height:32px;border:none;border-radius:6px;background:transparent;color:var(--text);font-size:15px;font-family:inherit;cursor:pointer;padding:0 6px}
.rt-leiste button:active{background:var(--gn-light,#eef3fc)}
.rt-feld{min-height:70px;padding:10px 12px;font-size:17px;line-height:1.45;outline:none;color:var(--text);word-break:break-word}
.rt-feld:empty:before{content:attr(data-ph);color:var(--text-hint,#999)}
.rt-feld ul,.rt-feld ol,.rt-anzeige ul,.rt-anzeige ol{margin:4px 0;padding-left:24px}
.rt-feld p,.rt-anzeige p{margin:0 0 6px}
.rt-anzeige{line-height:1.5;word-break:break-word}
.rt-anzeige a,.rt-feld a{color:var(--gn,#0f2d6b)}
.rt-feld h3,.rt-anzeige h3{font-size:19px;margin:6px 0 4px}
.rt-leiste{flex-wrap:wrap}
/* Textfeld gross anzeigen (Knopf ⤢ rechts in der Leiste) */
.rt-leiste .rt-gross-knopf{margin-left:auto;font-weight:700}
.rt-box.rt-gross{position:fixed;z-index:100500;top:calc(6px + env(safe-area-inset-top));bottom:calc(6px + env(safe-area-inset-bottom));left:6px;right:6px;
  max-width:1000px;margin:0 auto;display:flex;flex-direction:column;border:2px solid var(--gn,#0f2d6b);border-radius:10px;box-shadow:0 0 0 100vmax rgba(0,0,0,.45)}
.rt-box.rt-gross .rt-feld{flex:1;overflow-y:auto;min-height:0 !important;font-size:19px;padding:14px 16px}
.rt-box.rt-gross .rt-gross-knopf{background:var(--gn,#0f2d6b);color:#fff;padding:0 14px}
html.rt-gross-offen,html.rt-gross-offen body{overflow:hidden}

/* Weitere Benachrichtigungen (core/ui/benachrichtigungen.js) */
.gbn{margin-top:14px;border:2px solid var(--border);border-radius:10px;padding:0 12px;background:var(--bg-card)}
.gbn summary{cursor:pointer;font-weight:600;font-size:16px;padding:12px 0;color:var(--text)}
.gbn[open] summary{border-bottom:1px solid var(--border);margin-bottom:6px}
.gbn-hinweis{font-size:14px;color:var(--text-muted);margin:4px 0 8px}
.gbn-zeile{display:flex;align-items:center;gap:10px;padding:8px 0;font-size:16px;color:var(--text);cursor:pointer}
.gbn-zeile input[type=checkbox]{width:20px;height:20px;flex-shrink:0}
.gbn-wahl{flex-wrap:wrap;justify-content:space-between}
.gbn-wahl select{font:inherit;font-size:15px;padding:6px 8px;border:2px solid var(--border);border-radius:8px;background:var(--bg-card);color:var(--text);max-width:100%}
.gbn-status{font-size:14px;color:var(--text-muted);min-height:20px;padding:4px 0 10px}

