Files
Sternsinger/CMBNet/static/css/dispatcher.css
T

920 lines
18 KiB
CSS

/* Dispatcher-View: Karte 2/3 links, Kontrollansicht 1/3 rechts */
body.dispatcher-page {
--dispatcher-shell-bg: #eef1f4;
--dispatcher-map-bg: #dce3e8;
--dispatcher-border: rgba(0, 0, 0, 0.12);
--dispatcher-border-strong: rgba(0, 0, 0, 0.18);
--dispatcher-subtle-bg: rgba(0, 0, 0, 0.045);
--dispatcher-subtle-bg-hover: rgba(47, 111, 219, 0.13);
--dispatcher-chip-bg: rgba(0, 0, 0, 0.07);
--dispatcher-own-message-bg: rgba(47, 111, 219, 0.12);
--dispatcher-dot-ring: var(--card-background-color, #fff);
--dispatcher-dot-outline: rgba(0, 0, 0, 0.2);
margin: 0;
overflow: hidden;
height: 100vh;
height: 100dvh;
background: var(--dispatcher-shell-bg);
}
html[data-theme="dark"] body.dispatcher-page {
--dispatcher-shell-bg: #0b1116;
--dispatcher-map-bg: #0d141a;
--dispatcher-border: rgba(255, 255, 255, 0.14);
--dispatcher-border-strong: rgba(255, 255, 255, 0.2);
--dispatcher-subtle-bg: rgba(255, 255, 255, 0.06);
--dispatcher-subtle-bg-hover: rgba(88, 166, 255, 0.2);
--dispatcher-chip-bg: rgba(255, 255, 255, 0.09);
--dispatcher-own-message-bg: rgba(88, 166, 255, 0.18);
--dispatcher-dot-outline: rgba(255, 255, 255, 0.3);
}
body.dispatcher-page main.container {
width: 100vw;
max-width: none;
height: 100vh;
height: 100dvh;
margin: 0;
padding: 0;
}
.dispatcher-layout {
display: grid;
grid-template-columns: minmax(0, 2fr) minmax(320px, 1fr);
width: 100vw;
height: 100vh;
height: 100dvh;
overflow: hidden;
}
.map-pane {
position: relative;
min-width: 0;
min-height: 0;
background: var(--dispatcher-map-bg);
}
#map {
position: absolute;
inset: 0;
width: 100%;
height: 100%;
z-index: 1;
}
/* Fadenkreuz-Modus der Karte */
.leaflet-container.crosshair,
.leaflet-container.crosshair .leaflet-interactive {
cursor: crosshair !important;
}
.control-pane {
display: flex;
flex-direction: column;
min-width: 0;
min-height: 0;
overflow: hidden;
background: var(--card-background-color, #fff);
border-left: 1px solid var(--dispatcher-border-strong);
}
/* ---------- Header ---------- */
.control-header {
flex: 0 0 auto;
padding: 0.85rem 1rem 0.6rem;
border-bottom: 1px solid var(--dispatcher-border);
}
.clock-row {
display: flex;
align-items: center;
justify-content: space-between;
gap: 0.5rem;
margin-bottom: 0.55rem;
}
.clock {
display: flex;
flex-direction: column;
gap: 0.05rem;
min-width: 0;
flex: 1 1 0;
}
.clock-row > #speakerButton {
flex: 0 0 auto;
margin: 0 0.25rem;
}
.clock-date {
display: flex;
align-items: baseline;
gap: 0.35rem;
font-size: 0.78rem;
color: var(--muted-color, #5b6771);
text-transform: capitalize;
}
.clock-weekday {
font-size: 0.95rem;
font-weight: 700;
line-height: 1;
}
.clock-day {
font-size: 0.72rem;
font-variant-numeric: tabular-nums;
}
.clock-time {
font-size: clamp(1.8rem, 4vw, 2.7rem);
line-height: 1.05;
font-weight: 700;
font-variant-numeric: tabular-nums;
letter-spacing: 0.03em;
}
.dispatcher-logo {
flex: 0 0 auto;
width: auto;
height: 3rem;
margin-left: 0.25rem;
}
/* ---------- Straßensuche ---------- */
.street-search {
position: relative;
}
.street-search input[type="search"] {
width: 100%;
height: 2.35rem;
margin: 0;
padding: 0.25rem 2rem 0.25rem 2.4rem;
font-size: 0.8rem;
text-indent: 0;
}
.street-search-results {
position: absolute;
z-index: 60;
top: calc(100% + 0.25rem);
right: 0;
left: 0;
max-height: 14rem;
margin: 0;
padding: 0.25rem;
overflow-y: auto;
overscroll-behavior: contain;
list-style: none;
border: 1px solid var(--dispatcher-border-strong);
border-radius: 0.5rem;
background: var(--card-background-color, #fff);
box-shadow: 0 12px 32px rgba(0, 0, 0, 0.24);
}
.street-search-results[hidden] {
display: none;
}
.street-search-option {
margin: 0;
padding: 0.42rem 0.55rem;
border-radius: 0.35rem;
font-size: 0.8rem;
line-height: 1.25;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
cursor: pointer;
}
.street-search-option:hover,
.street-search-option.is-active {
background: var(--dispatcher-subtle-bg-hover);
}
.street-search-status {
margin-top: 0.3rem;
font-size: 0.7rem;
color: var(--muted-color, #5b6771);
}
.street-search-status:empty {
display: none;
}
.street-search-status.error {
color: #b42318;
}
.map-layer-label {
flex: 1 1 auto;
max-width: 9.5rem;
min-width: 0;
margin: 0 !important;
font-size: 0.7rem;
}
.map-layer-label > span {
display: block;
margin-bottom: 0.15rem;
color: var(--muted-color, #5b6771);
white-space: nowrap;
}
.map-layer-label select {
margin: 0;
height: 1.95rem;
padding: 0.15rem 1.7rem 0.15rem 0.45rem;
font-size: 0.72rem;
}
.theme-switch {
display: inline-flex;
align-items: center;
flex: 0 0 auto;
gap: 0.35rem;
margin: 0 !important;
padding-bottom: 0.15rem;
color: var(--muted-color, #5b6771);
font-size: 0.7rem;
white-space: nowrap;
cursor: pointer;
user-select: none;
}
.theme-switch input[type="checkbox"][role="switch"] {
flex: 0 0 auto;
margin: 0;
font-size: 0.9rem;
}
.icon-button {
display: inline-flex;
align-items: center;
justify-content: center;
flex: 0 0 auto;
width: 2.5rem;
height: 2.5rem;
margin: 0;
padding: 0;
border-radius: 0.55rem;
font-size: 1.2rem;
line-height: 1;
text-decoration: none;
}
a.icon-button {
border: 1px solid var(--dispatcher-border-strong);
background: var(--form-element-background-color, #fff);
color: inherit;
}
.icon-button.active {
background: #2f6fdb;
border-color: #2f6fdb;
color: #fff;
}
.connection-status {
margin-top: 0.45rem;
font-size: 0.72rem;
color: var(--muted-color, #5b6771);
}
.connection-status.connected {
color: #18794e;
}
.connection-status.disconnected {
color: #b42318;
}
/* ---------- Accordion ---------- */
.group-accordion {
flex: 1 1 auto;
min-height: 0;
overflow-y: auto;
padding: 0.7rem;
scrollbar-gutter: stable;
}
.group-empty {
padding: 1rem;
color: var(--muted-color, #5b6771);
font-size: 0.9rem;
}
.group-item {
margin: 0 0 0.55rem;
border: 1px solid var(--dispatcher-border);
border-radius: 0.65rem;
background: var(--card-background-color, #fff);
overflow: hidden;
}
.group-item > summary {
display: flex;
align-items: center;
gap: 0.55rem;
padding: 0.65rem 0.75rem;
cursor: pointer;
list-style: none;
user-select: none;
}
.group-item > summary::-webkit-details-marker {
display: none;
}
.group-item > summary::after {
content: "▾";
margin-left: auto;
font-size: 0.8rem;
color: var(--muted-color, #5b6771);
transition: transform 0.15s ease;
}
.group-item[open] > summary::after {
transform: rotate(180deg);
}
.group-dot {
flex: 0 0 auto;
width: 0.8rem;
height: 0.8rem;
border-radius: 50%;
box-shadow: 0 0 0 2px var(--dispatcher-dot-ring), 0 0 0 3px var(--dispatcher-dot-outline);
}
.group-name {
min-width: 0;
font-weight: 650;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.group-state {
flex: 0 0 auto;
margin-left: 0.35rem;
padding: 0.1rem 0.45rem;
border-radius: 999px;
background: var(--dispatcher-chip-bg);
font-size: 0.7rem;
white-space: nowrap;
}
.group-details {
padding: 0 0.75rem 0.75rem;
display: flex;
flex-direction: column;
gap: 0.6rem;
}
.group-position-row {
display: flex;
align-items: center;
gap: 0.5rem;
}
.group-position-row .icon-button {
width: 2.25rem;
height: 2.25rem;
font-size: 1.05rem;
}
.group-position-row progress {
flex: 1 1 auto;
width: auto;
height: 0.75rem;
margin: 0;
}
.group-position-meta {
font-size: 0.72rem;
color: var(--muted-color, #5b6771);
}
.group-actions {
display: flex;
align-items: center;
gap: 0.5rem;
}
.group-crosshair,
.group-streets,
.group-alias {
width: 2.35rem;
height: 2.35rem;
margin: 0;
padding: 0;
font-size: 1.1rem;
}
.group-state-select {
flex: 1 1 auto;
width: auto;
min-width: 0;
height: 2.35rem;
margin: 0;
padding: 0.25rem 1.8rem 0.25rem 0.55rem;
font-size: 0.78rem;
}
.group-message {
margin: 0;
cursor: pointer;
background: var(--dispatcher-subtle-bg);
font-size: 0.82rem;
}
.group-message:focus {
cursor: pointer;
}
/* ---------- Footer ---------- */
.control-footer {
flex: 0 0 auto;
display: flex;
flex-direction: column;
gap: 0.55rem;
padding: 0.7rem 1rem 0.85rem;
border-top: 1px solid var(--dispatcher-border);
background: var(--card-background-color, #fff);
}
.slider-control {
margin: 0 !important;
font-size: 0.74rem;
}
.slider-control > span {
display: flex;
justify-content: space-between;
color: var(--muted-color, #5b6771);
}
.slider-control input[type="range"] {
margin: 0.25rem 0 0;
height: 1.15rem;
}
.footer-bottom {
display: flex;
align-items: flex-end;
justify-content: space-between;
gap: 0.5rem;
min-width: 0;
}
.footer-settings {
display: flex;
align-items: flex-end;
flex: 1 1 auto;
gap: 0.55rem;
min-width: 0;
}
.footer-buttons {
display: flex;
flex: 0 0 auto;
justify-content: flex-end;
gap: 0.5rem;
margin-top: 0;
}
/* ---------- Dialoge ---------- */
dialog article {
--block-spacing-vertical: 0.85rem;
--block-spacing-horizontal: 1rem;
display: flex;
flex-direction: column;
max-height: min(90dvh, 48rem);
padding: var(--block-spacing-vertical) var(--block-spacing-horizontal);
overflow: hidden;
}
dialog article > header,
dialog article > footer {
flex: 0 0 auto;
}
dialog article > footer {
display: flex;
flex-wrap: wrap;
justify-content: flex-end;
gap: 0.5rem;
}
dialog article > footer > button {
width: auto;
margin: 0;
flex: 0 0 auto;
}
dialog article > .dialog-body {
flex: 1 1 auto;
min-height: 0;
overflow-y: auto;
overscroll-behavior: contain;
}
/* Nicht-modaler Straßendialog: bleibt neben der Karte bedienbar. */
dialog.group-streets-dialog {
position: fixed;
top: 4.5rem;
left: 1rem;
right: auto;
bottom: auto;
z-index: 1200;
width: min(26rem, calc(100vw - 2rem));
min-width: 0;
max-width: calc(100vw - 2rem);
height: auto;
min-height: 0;
max-height: min(70dvh, 40rem);
margin: 0;
padding: 0;
overflow: hidden;
border: 1px solid var(--dispatcher-border-strong);
border-radius: 0.75rem;
box-shadow: 0 18px 50px rgba(0, 0, 0, 0.28);
background: var(--card-background-color, #fff);
}
dialog.group-streets-dialog[open] {
display: block;
}
dialog.group-streets-dialog article {
--block-spacing-vertical: 0.85rem;
--block-spacing-horizontal: 1rem;
max-height: min(70dvh, 40rem);
margin: 0;
padding: var(--block-spacing-vertical) var(--block-spacing-horizontal);
overflow: hidden;
background: transparent;
}
dialog.group-streets-dialog article header {
cursor: move;
touch-action: none;
user-select: none;
}
dialog.group-streets-dialog.is-dragging {
box-shadow: 0 24px 60px rgba(0, 0, 0, 0.34);
}
dialog.group-streets-dialog.is-dragging article header {
cursor: grabbing;
}
.group-streets-section + .group-streets-section {
margin-top: 1rem;
}
.group-streets-section h4 {
margin: 0 0 0.4rem;
font-size: 0.72rem;
font-weight: 700;
letter-spacing: 0.04em;
text-transform: uppercase;
color: var(--muted-color, #5b6771);
}
.group-streets-list {
display: flex;
flex-direction: column;
gap: 0.25rem;
margin: 0;
padding: 0;
list-style: none;
}
.group-streets-list li {
margin: 0;
}
.group-street-entry {
display: flex;
align-items: center;
justify-content: space-between;
gap: 0.6rem;
width: 100%;
margin: 0;
padding: 0.42rem 0.55rem;
border: 0;
border-radius: 0.42rem;
background: var(--dispatcher-subtle-bg);
color: inherit;
font-size: 0.84rem;
text-align: left;
}
.group-street-entry:hover,
.group-street-entry:focus-visible {
background: var(--dispatcher-subtle-bg-hover);
}
.group-street-name {
min-width: 0;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.group-street-state {
flex: 0 0 auto;
font-size: 0.68rem;
color: var(--muted-color, #5b6771);
}
.group-streets-empty {
margin: 0;
padding: 0.5rem 0.55rem;
border-radius: 0.42rem;
background: var(--dispatcher-subtle-bg);
color: var(--muted-color, #5b6771);
font-size: 0.8rem;
}
#chatModal article,
.chat-dialog,
#broadcastModal article,
.broadcast-dialog {
width: min(44rem, 94vw);
max-width: 94vw;
}
.chat-dialog > footer.chat-input-row {
display: flex;
align-items: stretch;
gap: 0.5rem;
flex-wrap: nowrap;
}
.chat-input {
flex: 1 1 0%;
min-width: 0;
margin: 0;
height: 2.4rem;
align-self: center;
}
.chat-send-button {
flex: 0 0 2.4rem;
width: 2.4rem;
height: 2.4rem;
margin: 0;
padding: 0;
border-radius: 0.55rem;
font-size: 1rem;
align-self: stretch;
line-height: 1;
}
.chat-messages {
display: flex;
flex-direction: column;
gap: 0.55rem;
overflow-y: auto;
padding: 0.15rem;
}
.chat-empty {
padding: 1rem;
text-align: center;
color: var(--muted-color, #5b6771);
font-size: 0.9rem;
}
.chat-message {
padding: 0.5rem 0.65rem;
border-radius: 0.55rem;
background: var(--dispatcher-subtle-bg);
}
.chat-message.own {
background: var(--dispatcher-own-message-bg);
}
.chat-message-header {
display: flex;
justify-content: space-between;
gap: 0.7rem;
margin-bottom: 0.18rem;
font-size: 0.7rem;
color: var(--muted-color, #5b6771);
}
.chat-message-text {
white-space: pre-wrap;
overflow-wrap: anywhere;
font-size: 0.9rem;
}
/* ---------- Leaflet-Marker ---------- */
/* Leaflet setzt role="button"; Pico würde sonst Button-Padding und Zeilenhöhe
anwenden und den Marker gegenüber der gesetzten Position verschieben. */
.group-marker-icon {
display: flex;
align-items: center;
justify-content: center;
padding: 0;
background: transparent;
border: 0;
line-height: 0;
}
.group-marker-icon.is-marker-hidden {
visibility: hidden;
pointer-events: none;
}
.group-marker-icon span {
display: block;
width: 18px;
height: 18px;
border-radius: 50%;
background: var(--marker-color, #2f6fdb);
border: 2px solid #fff;
box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.38), 0 1px 3px rgba(0, 0, 0, 0.4);
}
/* Markierungsfahne für gesuchte Hausnummern */
.house-number-marker-icon {
padding: 0;
border: 0;
background: transparent;
line-height: 0;
}
.house-number-flag {
position: relative;
display: inline-block;
max-width: 12rem;
padding: 0.22rem 0.5rem 0.22rem 0.55rem;
overflow: hidden;
border-radius: 0.15rem 0.35rem 0.35rem 0.15rem;
background: #c62828;
color: #fff;
font-size: 0.68rem;
font-weight: 700;
line-height: 1.25;
white-space: nowrap;
text-overflow: ellipsis;
box-shadow: 0 2px 6px rgba(0, 0, 0, 0.42);
}
.house-number-flag::before {
content: "";
position: absolute;
top: 100%;
left: 0;
width: 2px;
height: 0.7rem;
background: #343a40;
box-shadow: 0 1px 2px rgba(0, 0, 0, 0.35);
}
@media (max-width: 900px) {
.dispatcher-layout {
grid-template-columns: 1fr;
grid-template-rows: minmax(0, 55vh) minmax(0, 45vh);
grid-template-rows: minmax(0, 55dvh) minmax(0, 45dvh);
}
.control-pane {
border-left: 0;
border-top: 1px solid var(--dispatcher-border-strong);
}
.control-header {
padding-top: 0.55rem;
padding-bottom: 0.45rem;
}
.clock {
flex-direction: row;
align-items: baseline;
justify-content: space-between;
gap: 0.75rem;
}
.clock-row {
gap: 0.5rem;
margin-bottom: 0.4rem;
}
.dispatcher-logo {
height: 2.25rem;
}
.clock-row > #speakerButton {
width: 2.25rem;
height: 2.25rem;
}
.clock-time {
font-size: 1.55rem;
}
.group-accordion {
padding: 0.5rem;
}
.control-footer {
padding: 0.5rem 0.75rem;
}
dialog.group-streets-dialog {
top: 0.75rem;
left: 0.75rem;
width: min(24rem, calc(100vw - 1.5rem));
min-width: 0;
max-width: calc(100vw - 1.5rem);
height: auto;
min-height: 0;
max-height: 65dvh;
}
dialog.group-streets-dialog article {
max-height: 65dvh;
}
}
/* ---------- Dark-Modus ---------- */
html[data-theme="dark"] .connection-status.connected {
color: #5bd6a2;
}
html[data-theme="dark"] .connection-status.disconnected {
color: #ff8b8b;
}
html[data-theme="dark"] .street-search-status.error {
color: #ff8b8b;
}
html[data-theme="dark"] .leaflet-container {
background: var(--dispatcher-map-bg);
}
/* OSM-Kacheln werden nur im Dark-Modus abgedunkelt; Luftbilder bleiben unverändert. */
html[data-theme="dark"] #map:not(.is-aerial-base) .leaflet-tile-pane {
filter: invert(1) hue-rotate(180deg) brightness(0.82) contrast(0.92);
}
html[data-theme="dark"] .leaflet-bar a {
background-color: #141e26;
color: #e1e6eb;
border-bottom-color: #2a3944;
}
html[data-theme="dark"] .leaflet-bar a:hover {
background-color: #1f2d38;
}
html[data-theme="dark"] .leaflet-control-attribution {
background: rgba(11, 17, 22, 0.82);
color: var(--muted-color, #8a99a6);
}
html[data-theme="dark"] .leaflet-control-attribution a {
color: var(--primary, #35b9e0);
}
html[data-theme="dark"] .leaflet-tooltip {
background: #141e26;
border-color: #141e26;
color: var(--color, #c8d1d8);
box-shadow: 0 1px 4px rgba(0, 0, 0, 0.55);
}
html[data-theme="dark"] .leaflet-tooltip-top::before {
border-top-color: #141e26;
}
html[data-theme="dark"] .leaflet-tooltip-bottom::before {
border-bottom-color: #141e26;
}
html[data-theme="dark"] .leaflet-tooltip-left::before {
border-left-color: #141e26;
}
html[data-theme="dark"] .leaflet-tooltip-right::before {
border-right-color: #141e26;
}