/* ═══════════════════════════════════════════════════════
   Einzelruf, SDS und Änderungs-Log
   ═══════════════════════════════════════════════════════ */

/* ── Anrufen-Knopf in den Hörer-Listen ──────────────────── */
.anruf-knopf {
    border: none; background: rgba(255,255,255,0.08); color: var(--text);
    width: 18px; height: 18px; border-radius: 50%; flex: none;
    display: inline-flex; align-items: center; justify-content: center;
    font-size: var(--fs-3xs); margin-left: 0.35rem; cursor: pointer;
    transition: background 0.15s, color 0.15s;
}
.anruf-knopf:hover { background: var(--green); color: #06170c; }

/* ── Eingehender/ausgehender Ruf ────────────────────────── */
/* [hidden] hat dieselbe Spezifität wie die Klasse — ohne diese Regel
   gewinnt unser display:flex und das Overlay bleibt IMMER sichtbar. */
.ruf-overlay[hidden], .ruf-leiste[hidden] { display: none !important; }

.ruf-overlay {
    position: fixed; inset: 0; z-index: 500;
    display: flex; align-items: center; justify-content: center;
    background: rgba(6,6,10,0.72); backdrop-filter: blur(6px);
    padding: 1rem;
}
.ruf-karte {
    width: 100%; max-width: 320px;
    background: var(--surface2); border: 1px solid var(--border-red);
    border-radius: var(--radius-lg); box-shadow: var(--card-shadow);
    padding: 1.6rem 1.4rem; text-align: center;
}
.ruf-symbol {
    width: 56px; height: 56px; margin: 0 auto 0.8rem;
    border-radius: 50%; background: var(--red-dim); color: var(--red);
    display: flex; align-items: center; justify-content: center; font-size: var(--fs-lg);
    animation: rufPulse 1.4s ease-in-out infinite;
}
@keyframes rufPulse {
    0%, 100% { box-shadow: 0 0 0 0 var(--red-glow); }
    50%      { box-shadow: 0 0 0 12px rgba(232,25,44,0); }
}
.ruf-titel { font-family: var(--cond); font-weight: 700; font-size: var(--fs-base); color: var(--text-dim); text-transform: uppercase; letter-spacing: 0.05em; }
.ruf-von   { font-size: var(--fs-lg); font-weight: 700; margin: 0.3rem 0 1.2rem; }
.ruf-knoepfe { display: flex; gap: 1.2rem; justify-content: center; }
.ruf-btn {
    width: 54px; height: 54px; border-radius: 50%; border: none; cursor: pointer;
    color: #fff; font-size: var(--fs-md); display: flex; align-items: center; justify-content: center;
    transition: transform 0.15s, opacity 0.15s;
}
.ruf-btn:hover { transform: scale(1.06); }
.ruf-btn:active { transform: scale(0.95); }
.ruf-an { background: var(--green); }
.ruf-ab { background: var(--red); }

/* ── Leiste für ein laufendes Gespräch ──────────────────── */
/* Eingehender Ruf bleibt rot umrandet (Signal) — schlägt die Modal-Optik aus bausteine.css */
.ruf-overlay .ruf-karte { border-color: var(--border-red); }

.ruf-leiste {
    position: fixed; left: 50%; transform: translateX(-50%);
    bottom: calc(env(safe-area-inset-bottom, 0px) + 12px);
    z-index: 400;
    display: flex; align-items: center; gap: 0.6rem;
    background: var(--surface2); border: 1px solid rgba(31,207,90,0.35);
    border-radius: 999px; padding: 0.45rem 0.6rem 0.45rem 0.9rem;
    box-shadow: var(--card-shadow); color: var(--green); font-size: var(--fs-xs);
}
.ruf-leiste button {
    border: none; background: var(--red); color: #fff; width: 30px; height: 30px;
    border-radius: 50%; display: flex; align-items: center; justify-content: center; cursor: pointer;
}

/* ── SDS-Anzeige (Funk-Tab, eigenes Fahrzeug) ───────────── */
.sds-karte {
    background: var(--surface); border: 1px solid var(--border);
    border-radius: var(--radius); padding: 0.85rem 1rem; margin-bottom: 0.9rem;
}
.sds-kopf { font-family: var(--cond); font-weight: 700; font-size: var(--fs-sm); color: var(--text-mid); text-transform: uppercase; letter-spacing: 0.04em; margin-bottom: 0.5rem; display: flex; align-items: center; gap: 0.4rem; }
.sds-kopf .zahl { margin-left: auto; color: var(--text-dim); font-weight: 400; text-transform: none; }
.sds-liste { display: flex; flex-direction: column; gap: 0.4rem; max-height: 160px; overflow-y: auto; }
.sds-eintrag { font-size: var(--fs-xs); display: flex; flex-wrap: wrap; gap: 0.4rem; align-items: baseline; }
.sds-eintrag .zeit { color: var(--text-dim); font-family: var(--mono); font-size: var(--fs-2xs); }
.sds-eintrag .von  { color: var(--blue); font-weight: 600; }
.sds-eintrag .text { color: var(--text); flex-basis: 100%; }

/* ── SDS senden (Leitstelle) ─────────────────────────────── */
.sds-compose[hidden] { display: none !important; }

.sds-knopf {
    border: none; background: transparent; color: var(--text-dim); cursor: pointer;
    font-size: var(--fs-sm); margin-left: 0.5rem; padding: 0.15rem;
}
.sds-knopf:hover { color: var(--blue); }
.sds-compose {
    display: flex; align-items: center; gap: 0.5rem; margin-top: 0.6rem;
    padding: 0.6rem; background: var(--surface3); border: 1px solid var(--border); border-radius: var(--radius-sm);
}
.sds-compose .ziel { font-size: var(--fs-xs); color: var(--text-dim); flex: none; }
.sds-compose .feld { flex: 1; min-width: 100px; }

/* ── Änderungs-Log (Admin) ───────────────────────────────── */
.log-liste { display: flex; flex-direction: column; gap: 0.4rem; max-height: 320px; overflow-y: auto; }
.log-eintrag { display: flex; align-items: center; gap: 0.6rem; font-size: var(--fs-xs); padding: 0.4rem 0.1rem; border-bottom: 1px solid var(--border); }
.log-eintrag:last-child { border-bottom: none; }
.log-eintrag i { color: var(--text-dim); width: 16px; text-align: center; flex: none; }
.log-inhalt { flex: 1; color: var(--text-mid); }
.log-zeit { color: var(--text-dim); font-size: var(--fs-2xs); flex: none; }

@media (max-width: 860px) {
    .ruf-karte { padding: 1.2rem 1rem; }
    .ruf-leiste { width: calc(100% - 24px); justify-content: center; }
    .sds-compose { flex-wrap: wrap; }
    .sds-compose .feld { flex: 1 1 100%; }
}
