:root {
    --primary: #1a365d;
    --accent: #ed8936;
    --accent-dark: #dd6b20;
    --bg: #f8fafc;
    --card-bg: #ffffff;
    --text: #1a202c;
    --muted: #64748b;
    --border: #e2e8f0;
    --success: #16a34a;
    --warning: #ca8a04;
    --danger: #dc2626;
    --radius: 12px;
    --shadow: 0 4px 24px rgba(26, 54, 93, 0.08);
    --font: 'Segoe UI', system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
}
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }
body {
    font-family: var(--font);
    background: var(--bg);
    color: var(--text);
    line-height: 1.55;
    min-height: 100vh;
}
a { color: var(--accent); text-decoration: none; transition: color 0.15s; }
a:hover { color: var(--accent-dark); }
img { max-width: 100%; height: auto; }

.header {
    display: flex; align-items: center; gap: 0.85rem;
    padding: 0.9rem 1.25rem; background: var(--primary); color: #fff;
    box-shadow: 0 2px 12px rgba(0,0,0,0.15); position: sticky; top: 0; z-index: 100;
}
.header img.logo { height: 42px; width: auto; object-fit: contain; border-radius: 6px; }
.header .company { font-size: 1.25rem; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 0.4rem;
    padding: 0.7rem 1.35rem; border: none; border-radius: 10px; font-size: 0.95rem;
    font-weight: 600; font-family: inherit; cursor: pointer;
    transition: background 0.15s, transform 0.1s; text-decoration: none; line-height: 1.2;
}
.btn:active { transform: scale(0.97); }
.btn-primary { background: var(--accent); color: #fff; box-shadow: 0 2px 8px rgba(237,137,54,0.35); }
.btn-primary:hover { background: var(--accent-dark); color: #fff; }
.btn-secondary { background: var(--primary); color: #fff; }
.btn-secondary:hover { background: #2c5282; color: #fff; }
.btn-outline { background: transparent; border: 2px solid var(--primary); color: var(--primary); }
.btn-outline:hover { background: var(--primary); color: #fff; }
.btn-danger { background: var(--danger); color: #fff; }
.btn-sm { padding: 0.4rem 0.85rem; font-size: 0.85rem; border-radius: 8px; }

.form-group { margin-bottom: 1.15rem; }
.form-group label { display: block; font-weight: 600; margin-bottom: 0.4rem; color: var(--primary); font-size: 0.92rem; }
.form-control {
    width: 100%; padding: 0.75rem 1rem; border: 2px solid var(--border); border-radius: 10px;
    font-size: 1rem; font-family: inherit; background: #fff;
    transition: border-color 0.15s, box-shadow 0.15s; appearance: none;
}
.form-control:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(237,137,54,0.18); }
select.form-control {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%2364748b' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat; background-position: right 1rem center; padding-right: 2.5rem;
}
textarea.form-control { resize: vertical; min-height: 90px; }

.card {
    background: var(--card-bg); border-radius: var(--radius); box-shadow: var(--shadow);
    padding: 1.5rem; border: 1px solid var(--border);
}
.card-title {
    font-size: 1.15rem; font-weight: 700; color: var(--primary); margin-bottom: 1.1rem;
    padding-bottom: 0.6rem; border-bottom: 2px solid var(--border);
}
.page { max-width: 680px; margin: 0 auto; padding: 1.5rem 1rem 3rem; }
.page-title { font-size: 1.65rem; font-weight: 800; color: var(--primary); margin-bottom: 0.35rem; letter-spacing: -0.02em; }
.page-sub { color: var(--muted); margin-bottom: 1.5rem; font-size: 0.95rem; }

.alert { padding: 1rem 1.2rem; border-radius: 10px; margin-bottom: 1.15rem; font-size: 0.95rem; border-left: 4px solid; }
.alert-success { background: #f0fdf4; color: #166534; border-color: var(--success); }
.alert-error { background: #fef2f2; color: #991b1b; border-color: var(--danger); }
.alert-info { background: #eff6ff; color: #1e40af; border-color: #3b82f6; }

.slot-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(78px, 1fr)); gap: 0.5rem; margin-top: 0.5rem; }
.slot-btn {
    padding: 0.7rem 0.4rem; border: 2px solid var(--border); border-radius: 10px; background: #fff;
    cursor: pointer; font-weight: 600; font-size: 0.95rem; text-align: center; transition: all 0.15s; font-family: inherit;
}
.slot-btn:hover { border-color: var(--accent); background: #fff7ed; }
.slot-btn.selected { border-color: var(--accent); background: var(--accent); color: #fff; }

.badge { display: inline-block; padding: 0.25rem 0.7rem; border-radius: 999px; font-size: 0.78rem; font-weight: 600; }
.badge-pending { background: #fef9c3; color: #854d0e; }
.badge-confirmed { background: #dbeafe; color: #1e40af; }
.badge-arrived { background: #e0e7ff; color: #3730a3; }
.badge-in_progress { background: #ffedd5; color: #9a3412; }
.badge-ready { background: #dcfce7; color: #166534; }
.badge-completed { background: #f1f5f9; color: #475569; }
.badge-cancelled { background: #fee2e2; color: #991b1b; }

.admin-layout { display: grid; grid-template-columns: 250px 1fr; min-height: 100vh; }
.sidebar {
    background: var(--primary); color: #fff; padding: 1.35rem 1rem; display: flex; flex-direction: column;
    position: sticky; top: 0; height: 100vh; overflow-y: auto;
}
.sidebar .logo-area {
    display: flex; align-items: center; gap: 0.7rem; margin-bottom: 1.75rem; padding-bottom: 1rem;
    border-bottom: 1px solid rgba(255,255,255,0.15); font-weight: 700; font-size: 1.05rem;
}
.sidebar nav { flex: 1; }
.sidebar nav a {
    display: flex; align-items: center; gap: 0.6rem; padding: 0.75rem 1rem; color: rgba(255,255,255,0.8);
    border-radius: 10px; margin-bottom: 0.2rem; font-weight: 500; font-size: 0.95rem; transition: background 0.15s, color 0.15s;
}
.sidebar nav a:hover, .sidebar nav a.active { background: rgba(237,137,54,0.22); color: #fff; }
.sidebar .nav-footer { margin-top: auto; padding-top: 1rem; border-top: 1px solid rgba(255,255,255,0.15); }
.admin-content { padding: 1.5rem 1.75rem 3rem; background: var(--bg); overflow-x: auto; }
.admin-content h1 { font-size: 1.55rem; font-weight: 800; color: var(--primary); margin-bottom: 1.25rem; letter-spacing: -0.02em; }

.mobile-nav-toggle {
    display: none; position: fixed; bottom: 1.25rem; right: 1.25rem; z-index: 200;
    width: 52px; height: 52px; border-radius: 50%; background: var(--accent); color: #fff; border: none;
    box-shadow: 0 4px 16px rgba(237,137,54,0.45); font-size: 1.4rem; cursor: pointer;
}
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; border-radius: var(--radius); }
.table {
    width: 100%; border-collapse: collapse; background: var(--card-bg); border-radius: var(--radius);
    overflow: hidden; box-shadow: var(--shadow); min-width: 560px;
}
.table th, .table td { padding: 0.8rem 1rem; text-align: left; border-bottom: 1px solid var(--border); font-size: 0.92rem; }
.table th { background: var(--primary); color: #fff; font-weight: 600; white-space: nowrap; }
.table tbody tr:hover td { background: #fff7ed; }
.table tbody tr:last-child td { border-bottom: none; }

.stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 0.85rem; margin-bottom: 1.5rem; }
.stat-card {
    background: var(--card-bg); border-radius: var(--radius); padding: 1.15rem 1rem; text-align: center;
    box-shadow: var(--shadow); border: 1px solid var(--border);
}
.stat-card .num { font-size: 2rem; font-weight: 800; line-height: 1.1; color: var(--accent); }
.stat-card .label { font-size: 0.82rem; color: var(--muted); margin-top: 0.3rem; font-weight: 500; }

.toggle { display: inline-flex; align-items: center; gap: 0.65rem; cursor: pointer; font-weight: 500; }
.toggle input[type="checkbox"] {
    width: 44px; height: 24px; appearance: none; background: #cbd5e1; border-radius: 999px;
    position: relative; cursor: pointer; transition: background 0.2s; flex-shrink: 0;
}
.toggle input[type="checkbox"]::after {
    content: ''; position: absolute; top: 2px; left: 2px; width: 20px; height: 20px;
    background: #fff; border-radius: 50%; transition: transform 0.2s; box-shadow: 0 1px 4px rgba(0,0,0,0.2);
}
.toggle input[type="checkbox"]:checked { background: var(--accent); }
.toggle input[type="checkbox"]:checked::after { transform: translateX(20px); }

.staff-list { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.staff-chip {
    padding: 0.5rem 1rem; background: #fff; border: 2px solid var(--border); border-radius: 999px;
    cursor: pointer; font-weight: 600; font-size: 0.9rem; transition: all 0.15s; user-select: none;
}
.staff-chip.active { border-color: var(--accent); background: #fff7ed; color: var(--accent-dark); }
.staff-chip input { display: none; }
.settings-section { margin-bottom: 1.5rem; }
.settings-hint { font-size: 0.85rem; color: var(--muted); margin-top: 0.35rem; }
.config-list { list-style: none; padding: 0; }
.config-list li {
    padding: 0.65rem 0; border-bottom: 1px solid var(--border); display: flex;
    justify-content: space-between; gap: 1rem; font-size: 0.92rem;
}
.config-list li:last-child { border-bottom: none; }
.config-list .key { font-weight: 600; color: var(--primary); }
.config-list .val { color: var(--muted); text-align: right; word-break: break-all; }

/* ===== DISPLAY ===== */
.display-body { background: #ffffff; color: #1a202c; min-height: 100vh; overflow: hidden; margin: 0; }
.display-header {
    display: grid; grid-template-columns: 1fr auto 1fr; align-items: center;
    padding: 1rem 2rem; background: #ffffff;
    border-bottom: 2px solid #e2e8f0; min-height: 88px; flex-shrink: 0;
    color: #1a202c;
}
.display-header .logo-wrap { display: flex; align-items: center; gap: 0.9rem; justify-self: start; }
.display-header img.logo { height: 64px; width: auto; max-width: 220px; object-fit: contain; border-radius: 0; }
.display-header .company { font-size: 1.55rem; font-weight: 800; color: var(--primary); }
.display-header .eta-wrap { justify-self: center; text-align: center; }
.display-header .eta-label { font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.08em; color: #64748b; font-weight: 600; }
.display-header .eta-value { font-size: 1.85rem; font-weight: 800; color: var(--accent); font-variant-numeric: tabular-nums; line-height: 1.15; }
.display-header .clock-wrap { justify-self: end; text-align: right; }
.display-header .clock { font-size: 1.7rem; font-weight: 700; font-variant-numeric: tabular-nums; color: var(--primary); }
.display-header .clock-date { font-size: 0.85rem; color: #64748b; margin-top: 0.15rem; }

.display-shell { display: flex; flex-direction: column; height: 100vh; }
.display-main { flex: 1; position: relative; min-height: 0; }
.slide {
    position: absolute; inset: 0; display: flex; flex-direction: column;
    opacity: 0; pointer-events: none; transition: opacity 0.55s ease;
}
.slide.active { opacity: 1; pointer-events: auto; }

.slide-wait { padding: 1.25rem 2rem 0; }
.slide-wait .wait-body { flex: 1; overflow: auto; display: flex; flex-direction: column; align-items: center; width: 100%; }
.display-title {
    font-size: 3.2rem; font-weight: 800; margin-bottom: 1.5rem; color: var(--accent);
    text-align: center; letter-spacing: -0.02em; flex-shrink: 0;
}
.wait-table {
    width: 95vw; max-width: 95vw; margin: 0 auto; border-collapse: collapse;
    font-size: 2.6rem; border-radius: 0; overflow: visible; box-shadow: none;
}
#wait-content {
    width: 95vw; max-width: 95vw; margin: 0 auto;
}
.wait-table th {
    text-align: left; padding: 1.4rem 1.6rem; background: #ffffff; color: var(--primary);
    font-weight: 700; font-size: 2rem; text-transform: uppercase; letter-spacing: 0.04em;
    border-bottom: 3px solid var(--accent);
}
.wait-table td { padding: 1.5rem 1.6rem; border-bottom: none; background: #fff; }
.wait-table tbody tr + tr td { border-top: 3px solid var(--accent); }
.wait-table tr:nth-child(even) td { background: #fff; }
.wait-table tr:last-child td { border-bottom: none; }
.wait-table .name { font-weight: 700; color: var(--accent); font-size: 2.7rem; }
.wait-table .time { font-variant-numeric: tabular-nums; font-weight: 600; opacity: 0.9; }
.wait-table .status-badge {
    display: inline-block; padding: 0.5rem 1.2rem; border-radius: 999px; font-size: 1.85rem; font-weight: 600;
}
.badge-arrived { background: #3b82f6; color: #fff; }
.badge-progress { background: var(--accent); color: #fff; }
.badge-waiting { background: #475569; color: #fff; }
.empty-state { text-align: center; color: #64748b; font-size: 1.35rem; padding: 2rem; }

/* Tipp-Leiste am unteren Bildrand */
.tip-bar {
    flex-shrink: 0;
    background: #fff7ed;
    border-top: 3px solid var(--accent);
    padding: 0.85rem 1.5rem;
    text-align: center;
    font-size: 1.15rem;
    font-weight: 600;
    line-height: 1.4;
    color: #9a3412;
}

.slide-video-full {
    position: absolute; inset: 0; z-index: 1;
}
.video-wrap {
    width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; background: #000;
}
.video-wrap video {
    width: 100%; height: 100%; object-fit: cover;
}
/* Tip-Leiste über dem Video */
.display-shell .tip-bar-overlay {
    position: absolute; left: 0; right: 0; bottom: 0; z-index: 5;
}

@media (max-width: 900px) {
    .admin-layout { grid-template-columns: 1fr; }
    .sidebar {
        position: fixed; left: -280px; top: 0; width: 260px; z-index: 150;
        transition: left 0.25s ease; box-shadow: 4px 0 24px rgba(0,0,0,0.3);
    }
    .sidebar.open { left: 0; }
    .mobile-nav-toggle { display: flex; align-items: center; justify-content: center; }
    .admin-content { padding: 1.15rem 1rem 5rem; }
    .display-header {
        grid-template-columns: 1fr; gap: 0.5rem; padding: 0.75rem 1rem; text-align: center; min-height: auto;
    }
    .display-header .logo-wrap, .display-header .eta-wrap, .display-header .clock-wrap {
        justify-self: center; text-align: center;
    }
    .display-header .company { font-size: 1.15rem; }
    .display-header img.logo { height: 40px; }
    .display-header .eta-value { font-size: 1.35rem; }
    .display-header .clock { font-size: 1.25rem; }
    .display-title { font-size: 1.35rem; }
    .wait-table { font-size: 1.5rem; }
    .wait-table th, .wait-table td { padding: 0.9rem 1rem; }
    .wait-table th { font-size: 1.2rem; }
    .wait-table .name { font-size: 1.6rem; }
    .wait-table .status-badge { font-size: 1.15rem; padding: 0.35rem 0.75rem; }
    .display-title { font-size: 2rem; }
    .tip-bar { font-size: 0.95rem; padding: 0.7rem 1rem; }
}
@media (max-width: 600px) {
    .header { padding: 0.75rem 1rem; }
    .header .company { font-size: 1.05rem; }
    .header img.logo { height: 34px; }
    .page { padding: 1.15rem 0.85rem 2.5rem; }
    .page-title { font-size: 1.4rem; }
    .card { padding: 1.15rem; }
    .stats-grid { grid-template-columns: repeat(2, 1fr); }
    .form-control { font-size: 16px; }
}
.sidebar-overlay {
    display: none; position: fixed; inset: 0; background: rgba(0,0,0,0.45); z-index: 140;
}
.sidebar-overlay.show { display: block; }


/* Status-Verlauf (DHL-ähnlich) */
.track-timeline { list-style: none; padding: 0; margin: 1rem 0 0; position: relative; }
.track-timeline::before {
    content: ''; position: absolute; left: 11px; top: 8px; bottom: 8px; width: 3px; background: #e2e8f0;
}
.track-item { position: relative; padding: 0 0 1.15rem 2.25rem; }
.track-item:last-child { padding-bottom: 0; }
.track-item::before {
    content: ''; position: absolute; left: 4px; top: 4px; width: 16px; height: 16px;
    border-radius: 50%; background: #cbd5e1; border: 3px solid #fff; box-shadow: 0 0 0 2px #cbd5e1;
}
.track-item.done::before { background: var(--accent); box-shadow: 0 0 0 2px var(--accent); }
.track-item.current::before { background: var(--primary); box-shadow: 0 0 0 2px var(--primary); }
.track-item .track-time { font-size: 0.8rem; color: var(--muted); }
.track-item .track-msg { font-weight: 600; color: var(--text); margin-top: 0.15rem; }

.order-log { list-style: none; padding: 0; margin: 0; font-size: 0.88rem; }
.order-log li { padding: 0.55rem 0; border-bottom: 1px solid var(--border); }
.order-log li:last-child { border-bottom: none; }
.order-log .log-time { color: var(--muted); font-size: 0.8rem; }
.order-log .log-actor { color: var(--primary); font-weight: 600; }
.alert-warning { background: #fefce8; color: #854d0e; border-color: var(--warning); }

.slot-btn { display: flex; flex-direction: column; align-items: center; gap: 0.15rem; line-height: 1.2; }
.slot-btn .slot-time { font-weight: 700; }
.slot-btn .slot-wait { font-size: 0.72rem; font-weight: 600; color: var(--accent-dark); opacity: 0.9; }
.slot-btn.selected .slot-wait { color: #fff; opacity: 0.95; }

.slot-btn.slot-disabled,
.slot-btn:disabled {
    opacity: 0.45;
    cursor: not-allowed;
    background: #f1f5f9;
    border-color: #cbd5e1;
    color: #94a3b8;
    pointer-events: none;
}
.slot-btn.slot-disabled .slot-wait { color: #94a3b8; }


/* ===== Loader Overlay (max ~2s) ===== */
.page-loader {
    position: fixed; inset: 0; z-index: 99999;
    background: rgba(255,255,255,0.96);
    backdrop-filter: blur(6px);
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    opacity: 1; visibility: visible;
    transition: opacity 0.5s ease, visibility 0.5s ease, transform 0.5s ease;
}
.page-loader.hide {
    opacity: 0; visibility: hidden; pointer-events: none;
    transform: scale(1.03);
}
.page-loader img {
    width: 110px; height: 110px; object-fit: contain;
    animation: logo-pulse 1.1s ease-in-out infinite;
}
.page-loader .loader-name {
    margin-top: 1rem; font-weight: 800; color: var(--primary); font-size: 1.35rem;
    animation: logo-pulse 1.1s ease-in-out infinite;
}
.page-loader .loader-bar {
    width: 140px; height: 4px; margin-top: 1.35rem; border-radius: 999px;
    background: #e2e8f0; overflow: hidden;
}
.page-loader .loader-bar span {
    display: block; height: 100%; width: 40%;
    background: linear-gradient(90deg, var(--accent), var(--primary));
    border-radius: 999px;
    animation: loader-slide 0.9s ease-in-out infinite;
}
@keyframes logo-pulse {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.07); opacity: 0.88; }
}
@keyframes loader-slide {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(280%); }
}
/* Header logos stay small */
.header img.logo { height: 40px; width: auto; object-fit: contain; }
.customer-header img.logo, .home-header img.logo { height: 40px; width: auto; }

/* ===== Display slide animations ===== */
.display-main .slide {
    opacity: 0;
    transform: scale(0.96) translateY(18px);
    transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1),
                transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
    pointer-events: none;
}
.display-main .slide.active {
    opacity: 1;
    transform: scale(1) translateY(0);
    pointer-events: auto;
}
.display-main .slide.slide-exit {
    opacity: 0;
    transform: scale(1.03) translateY(-12px);
}

/* Tip slide prettier */
.tip-slide {
    background: radial-gradient(ellipse at 30% 20%, rgba(237,137,54,0.12), transparent 55%),
                radial-gradient(ellipse at 70% 80%, rgba(26,54,93,0.08), transparent 50%),
                #fff !important;
}
.tip-slide .tip-card {
    max-width: 820px; margin: 0 auto; padding: 2.5rem 2rem;
    border: 2px solid rgba(237,137,54,0.35);
    border-radius: 24px;
    background: rgba(255,255,255,0.9);
    box-shadow: 0 20px 50px rgba(26,54,93,0.08);
}
.tip-slide .tip-label {
    display: inline-block;
    background: var(--accent); color: #fff;
    padding: 0.35rem 1rem; border-radius: 999px;
    font-size: 0.9rem; letter-spacing: 0.12em;
}
.tip-slide .tip-text {
    margin-top: 1.25rem;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    -webkit-background-clip: text; background-clip: text;
    color: transparent;
}

/* Customer/admin fade-in */
.anim-fade-up {
    animation: fadeUp 0.55s cubic-bezier(0.22, 1, 0.36, 1) both;
}
@keyframes fadeUp {
    from { opacity: 0; transform: translateY(16px); }
    to { opacity: 1; transform: translateY(0); }
}
.admin-live-eta {
    display: flex; align-items: center; gap: 0.5rem; flex-wrap: wrap;
    background: #fff; border: 1px solid #e2e8f0; border-radius: 10px;
    padding: 0.55rem 0.9rem; margin-bottom: 1rem;
    font-size: 0.95rem;
}
.admin-live-eta strong { color: var(--accent); font-size: 1.1rem; }

.page-loader {
    -webkit-transform: translateZ(0);
    transform: translateZ(0);
    touch-action: none;
    -webkit-overflow-scrolling: auto;
}
@supports (-webkit-touch-callout: none) {
    .page-loader { min-height: 100vh; min-height: -webkit-fill-available; }
}
.page-loader.hide { -webkit-transform: scale(1.03); }

/* Block-Tagesansicht */
.schedule-toolbar { display:flex; flex-wrap:wrap; gap:0.75rem; align-items:center; margin-bottom:1rem; }
.schedule-wrap { overflow:auto; border:1px solid #e2e8f0; border-radius:12px; background:#fff; max-height:calc(100vh - 200px); }
.schedule-table { border-collapse:collapse; min-width:100%; font-size:0.85rem; }
.schedule-table th, .schedule-table td { border:1px solid #e8edf3; vertical-align:top; }
.schedule-table thead th {
    position:sticky; top:0; z-index:3; background:#f8fafc; padding:0.5rem 0.4rem;
    font-size:0.78rem; color:var(--primary); text-align:center; white-space:nowrap;
}
.schedule-table thead th.time-col { left:0; z-index:4; background:#f1f5f9; }
.schedule-table .time-col {
    position:sticky; left:0; z-index:2; background:#f8fafc; width:52px; min-width:52px;
    text-align:right; padding:0 0.4rem; color:var(--muted); font-variant-numeric:tabular-nums;
    font-size:0.75rem; font-weight:600;
}
.schedule-table tbody td { height:28px; padding:0; position:relative; min-width:88px; }
.schedule-table th.staff-off, .schedule-table td.staff-off { background:#f1f5f9; opacity:0.55; }
.schedule-table th.staff-off { color:#94a3b8; }
.block {
    position:absolute; left:2px; right:2px; z-index:1;
    border-radius:6px; padding:0.25rem 0.35rem; overflow:hidden;
    font-size:0.72rem; line-height:1.2; color:#fff; cursor:pointer;
    box-shadow:0 1px 4px rgba(0,0,0,0.12);
    border-left:3px solid rgba(0,0,0,0.15);
}
.block .b-name { font-weight:700; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.block .b-meta { opacity:0.9; font-size:0.65rem; }
.block-confirmed { background: #3b82f6; }
.block-arrived { background: #8b5cf6; }
.block-in_progress { background: var(--accent); }
.block-ready { background: #16a34a; }
.block-pending { background: #94a3b8; }
.block-cancelled { background: #dc2626; opacity:0.7; }
@media (max-width: 700px) {
    .schedule-table tbody td { min-width:72px; height:24px; }
    .block { font-size:0.65rem; }
}

.admin-topbar .admin-live-eta { margin-bottom: 0; }


/* Loader: weiß, volle Fläche, Logo mittig */
.page-loader {
    position: fixed !important;
    top: 0 !important; left: 0 !important; right: 0 !important; bottom: 0 !important;
    width: 100% !important;
    height: 100% !important;
    min-height: 100vh !important;
    min-height: 100dvh !important;
    min-height: -webkit-fill-available;
    z-index: 99999 !important;
    background: #ffffff !important;
    backdrop-filter: none !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    margin: 0 !important;
    padding: 0 !important;
    opacity: 1;
    visibility: visible;
    transition: opacity 0.5s ease, visibility 0.5s ease;
    transform: none !important;
}
.page-loader.hide {
    opacity: 0 !important;
    visibility: hidden !important;
    pointer-events: none !important;
    transform: none !important;
}
.page-loader img {
    width: min(160px, 40vw) !important;
    height: auto !important;
    max-height: 30vh;
    object-fit: contain !important;
    animation: logo-pulse 1.1s ease-in-out infinite;
}
.page-loader .loader-name {
    margin-top: 1rem;
    font-weight: 800;
    color: var(--primary, #1a365d);
    font-size: clamp(1.2rem, 4vw, 1.6rem);
    animation: logo-pulse 1.1s ease-in-out infinite;
}
.page-loader .loader-bar {
    width: min(160px, 50vw);
    height: 4px;
    margin-top: 1.5rem;
    border-radius: 999px;
    background: #e2e8f0;
    overflow: hidden;
}
.page-loader .loader-bar span {
    display: block;
    height: 100%;
    width: 40%;
    background: linear-gradient(90deg, var(--accent, #ed8936), var(--primary, #1a365d));
    border-radius: 999px;
    animation: loader-slide 0.9s ease-in-out infinite;
}
