/*
 * Wish the DJ – neutrales Grunddesign (Umsetzungsanweisung 3.2).
 * Alle Farben als Variablen: Hell/Dunkel über data-darstellung am <html>, sonst Systemeinstellung.
 * Das Branding eines DJs (Akzentfarbe) überschreibt später nur --akzent / --akzent-text.
 * Keine externen Schriften, kein Build-Schritt.
 */

:root {
    --accent: #4f46e5;
    --accent-text: #ffffff;
    --accent-light: color-mix(in srgb, var(--accent) 12%, transparent);

    --background: #f6f7f9;
    --surface: #ffffff;
    --surface-2: #eef0f4;
    --rand: #dfe2e8;
    --text: #15171c;
    --text-muted: #5d6370;
    --ok: #1a7f4b;
    --ok-light: #e6f4ec;
    --error: #b42318;
    --error-light: #fdecea;

    --radius: 12px;
    --radius-small: 8px;
    --shadow: 0 1px 2px rgba(16, 24, 40, .06), 0 1px 3px rgba(16, 24, 40, .08);
    --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    color-scheme: light;
}

@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) {
        --background: #0f1115;
        --surface: #171a21;
        --surface-2: #20242d;
        --rand: #2c313c;
        --text: #eceef2;
        --text-muted: #9aa1ae;
        --ok: #4ade80;
        --ok-light: #12301f;
        --error: #f87171;
        --error-light: #3a1515;
        --accent: #818cf8;
        --accent-text: #0f1115;
        color-scheme: dark;
    }
}

:root[data-theme="dark"] {
    --background: #0f1115;
    --surface: #171a21;
    --surface-2: #20242d;
    --rand: #2c313c;
    --text: #eceef2;
    --text-muted: #9aa1ae;
    --ok: #4ade80;
    --ok-light: #12301f;
    --error: #f87171;
    --error-light: #3a1515;
    --accent: #818cf8;
    --accent-text: #0f1115;
    color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
    margin: 0;
    background: var(--background);
    color: var(--text);
    font-family: var(--font);
    font-size: 16px;
    line-height: 1.5;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

a { color: var(--accent); }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; border-radius: 4px; }

h1 { font-size: 1.6rem; line-height: 1.2; margin: 0 0 .5rem; letter-spacing: -.01em; }
h2 { font-size: 1.15rem; margin: 0 0 .75rem; }
p { margin: 0 0 1rem; }

.muted { color: var(--text-muted); }
.small { font-size: .875rem; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* --- Kopf ------------------------------------------------------------------ */
.header { background: var(--surface); border-bottom: 1px solid var(--rand); }
.header-inner {
    max-width: 1080px; margin: 0 auto; padding: 0 16px;
    display: flex; align-items: center; gap: 16px; min-height: 60px; flex-wrap: wrap;
}
.header-badge { font-weight: 700; color: var(--text); text-decoration: none; display: flex; align-items: center; gap: 8px; }
.header-badge .item { width: 12px; height: 12px; border-radius: 50%; background: var(--accent); }
.header-nav { display: flex; gap: 4px; flex-wrap: wrap; margin-left: auto; align-items: center; }
.header-nav a, .header-nav button {
    color: var(--text-muted); text-decoration: none; padding: 8px 12px; border-radius: var(--radius-small);
    font: inherit; font-size: .95rem; background: none; border: 0; cursor: pointer;
}
.header-nav a:hover, .header-nav button:hover { background: var(--surface-2); color: var(--text); }
.header-nav a[aria-current="page"] { color: var(--text); background: var(--accent-light); }

/* --- Inhalt ---------------------------------------------------------------- */
main { width: 100%; max-width: 1080px; margin: 0 auto; padding: 24px 16px 48px; flex: 1; }
main.narrow { max-width: 720px; }

.page-header { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin-bottom: 20px; }
.page-header form.actions { flex-wrap: nowrap; }
.page-header form.actions input { width: auto; flex: 1; min-width: 0; }
.eyebrow { font-size: .8rem; color: var(--text-muted); font-weight: 600; }

.card {
    background: var(--surface); border: 1px solid var(--rand); border-radius: var(--radius);
    padding: 20px; box-shadow: var(--shadow); margin-bottom: 16px;
}

/* --- Gast-Layout (Login, Registrierung) ------------------------------------ */
.guest { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 32px 16px; }
.guest .card { width: 100%; max-width: 420px; padding: 28px; }
.guest .card-wide { max-width: 760px; }
.guest-badge { font-weight: 700; font-size: 1.25rem; margin-bottom: 20px; color: var(--text); text-decoration: none; display: flex; align-items: center; gap: 10px; }
.guest-badge .item { width: 16px; height: 16px; border-radius: 50%; background: var(--accent); }

/* --- Formulare ------------------------------------------------------------- */
.field { margin-bottom: 16px; }
.field label, .field .label { display: block; font-weight: 600; font-size: .9rem; margin-bottom: 6px; }
input[type="text"], input[type="email"], input[type="password"], input[type="number"], input[type="url"], input[type="date"], select, textarea {
    width: 100%; font: inherit; color: var(--text); background: var(--surface);
    border: 1px solid var(--rand); border-radius: var(--radius-small); padding: 10px 12px; min-height: 44px;
}
textarea { min-height: 88px; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-light); }
.field-error input, .field-error select, .field-error textarea { border-color: var(--error); }
.error-text { color: var(--error); font-size: .875rem; margin-top: 4px; }
.help { color: var(--text-muted); font-size: .85rem; margin-top: 4px; }
label.check { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; }
label.check input { margin-top: 4px; width: 18px; height: 18px; accent-color: var(--accent); }

.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    font: inherit; font-weight: 600; padding: 10px 18px; min-height: 44px; border-radius: var(--radius-small);
    border: 1px solid var(--rand); background: var(--surface); color: var(--text); cursor: pointer; text-decoration: none;
}
.btn:hover { background: var(--surface-2); }
.btn-primary { background: var(--accent); border-color: var(--accent); color: var(--accent-text); }
.btn-primary:hover { background: color-mix(in srgb, var(--accent) 88%, black); }
.btn-danger { color: var(--error); }
.btn-full { width: 100%; }
.actions { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; margin-top: 8px; }

.choice { display: flex; gap: 8px; flex-wrap: wrap; }
.choice label { flex: 1; min-width: 100px; border: 1px solid var(--rand); border-radius: var(--radius-small); padding: 10px 12px; cursor: pointer; display: flex; gap: 8px; align-items: center; font-weight: 400; }
.choice input { accent-color: var(--accent); }
.choice label:has(input:checked) { border-color: var(--accent); background: var(--accent-light); }

/* --- Meldungen ------------------------------------------------------------- */
.message { border-radius: var(--radius-small); padding: 12px 14px; margin-bottom: 16px; font-size: .95rem; }
.message ul { margin: 0; padding-left: 20px; }
.message-ok { background: var(--ok-light); color: var(--ok); }
.message-error { background: var(--error-light); color: var(--error); }

/* --- Tabellen und Listen --------------------------------------------------- */
.table-wrap { overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; font-size: .95rem; }
.table th { text-align: left; font-size: .8rem; color: var(--text-muted); font-weight: 600; padding: 8px 10px; border-bottom: 1px solid var(--rand); }
.table td { padding: 10px; border-bottom: 1px solid var(--rand); vertical-align: top; }
.table tr:last-child td { border-bottom: 0; }

.badge { display: inline-block; font-size: .75rem; font-weight: 600; padding: 2px 8px; border-radius: 999px; background: var(--surface-2); color: var(--text-muted); }
.badge-ok { background: var(--ok-light); color: var(--ok); }
.badge-error { background: var(--error-light); color: var(--error); }
.badge-accent { background: var(--accent-light); color: var(--accent); }

.grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.stat .value { font-size: 1.4rem; font-weight: 700; }

.codes { display: grid; grid-template-columns: repeat(2, 1fr); gap: 6px; font-family: ui-monospace, Consolas, monospace; background: var(--surface-2); padding: 12px; border-radius: var(--radius-small); }
.qr svg { background: #fff; padding: 8px; border-radius: var(--radius-small); max-width: 100%; height: auto; }

details > summary { cursor: pointer; }
details.settings-collapsed > summary h2 { display: inline; }

.legal-text h2 { font-size: 1.3rem; margin-top: 0; }
.legal-text p { margin-bottom: .8rem; }

/* --- Kanäle (DJ-Bereich) ---------------------------------------------------- */
.filter-bar { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; padding: 12px; }
.filter-bar input { flex: 2; min-width: 180px; }
.filter-bar select { flex: 1; min-width: 140px; width: auto; }
.channel-row { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; align-items: center; text-decoration: none; color: inherit; padding: 14px 16px; margin-bottom: 10px; }
a.channel-row:hover, .channel-row a.channel-row-main:hover strong { color: var(--accent); }
.channel-row-main { display: flex; flex-direction: column; text-decoration: none; color: inherit; min-width: 0; }
.channel-row-info { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.date-time { display: flex; gap: 8px; }
.date-time input { flex: 1; min-width: 0; }
.date-time input.time { flex: 0 0 96px; }
.input-prefix { display: flex; align-items: stretch; border: 1px solid var(--rand); border-radius: var(--radius-small); overflow: hidden; background: var(--surface); }
.input-prefix span { padding: 10px 0 10px 12px; color: var(--text-muted); white-space: nowrap; font-size: .9rem; align-self: center; }
.input-prefix input { border: 0; padding-left: 2px; min-width: 0; }
.color-picker input[type="color"] { width: 64px; height: 44px; border: 1px solid var(--rand); border-radius: var(--radius-small); background: var(--surface); padding: 4px; cursor: pointer; }
.image-preview img { max-width: 220px; max-height: 120px; border-radius: var(--radius-small); border: 1px solid var(--rand); display: block; margin-bottom: 6px; background: repeating-conic-gradient(#ddd 0 25%, #fff 0 50%) 0 0 / 16px 16px; }
input[type="file"] { font: inherit; max-width: 100%; }
.badge-warning { background: #fff4e5; color: #9a5b00; }
code { font-family: ui-monospace, Consolas, monospace; background: var(--surface-2); padding: 1px 6px; border-radius: 6px; overflow-wrap: anywhere; word-break: break-all; }

/* --- Öffentliche Kanalseiten (Gäste, Kunde) – Branding über --akzent, --kanal-hintergrund --------------- */
.channel-page { background: var(--background); }
.channel-header {
    background: var(--channel-background, #15171c) center / cover no-repeat; color: var(--channel-text, #fff);
    position: relative; text-align: center;
}
.channel-header[style*="background-image"]::before { content: ""; position: absolute; inset: 0; background: linear-gradient(to bottom, rgba(0,0,0,.25), rgba(0,0,0,.65)); }
.channel-header[style*="background-image"] { color: #fff; }
.channel-header-inner { position: relative; max-width: 640px; margin: 0 auto; padding: 32px 16px 28px; }
.channel-header h1 { font-size: 1.7rem; margin: 0 0 6px; }
.channel-logo { max-height: 72px; max-width: 220px; margin: 0 auto 12px; display: block; }
.channel-description { margin: 0 0 6px; opacity: .92; }
.channel-meta { margin: 0; font-size: .9rem; opacity: .85; }
.guest-content { width: 100%; max-width: 640px; margin: 0 auto; padding: 16px 12px 32px; flex: 1; }
.guest-card { background: var(--surface); border: 1px solid var(--rand); border-radius: var(--radius); padding: 16px; box-shadow: var(--shadow); margin-bottom: 16px; }
.guest-card h2 { font-size: 1.1rem; }
.grid.eng { gap: 0 12px; }
.guest-notice { background: var(--accent-light); border: 1px solid var(--accent); border-radius: var(--radius); padding: 12px 14px; margin-bottom: 16px; font-weight: 600; text-align: center; }
.search-field { position: relative; }
input[type="search"] { width: 100%; font: inherit; color: var(--text); background: var(--surface); border: 1px solid var(--rand); border-radius: var(--radius-small); padding: 10px 12px; min-height: 44px; -webkit-appearance: none; appearance: none; }
.hits { display: flex; flex-direction: column; gap: 4px; margin-top: 6px; }
.hits:empty { display: none; }
.hits-entry { display: flex; gap: 10px; align-items: center; text-align: left; font: inherit; color: var(--text); background: var(--surface-2); border: 1px solid transparent; border-radius: var(--radius-small); padding: 8px 10px; cursor: pointer; min-height: 48px; }
.hits-entry:hover, .hits-entry:focus-visible { border-color: var(--accent); }
.hits-entry img { border-radius: 4px; flex: 0 0 40px; }
.hits-entry span { display: flex; flex-direction: column; min-width: 0; }
.hits-entry strong, .hits-entry .muted { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hits-empty { margin: 4px 0 0; }

.now { display: grid; gap: 8px; margin-bottom: 16px; }
.now-entry { background: var(--surface); border: 1px solid var(--rand); border-radius: var(--radius); padding: 12px 14px; display: flex; flex-direction: column; }
.now-playing { background: var(--accent); color: var(--accent-text); border-color: var(--accent); }
.now-label { font-size: .75rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; opacity: .85; }

.tabs { display: flex; gap: 4px; overflow-x: auto; margin-bottom: 8px; border-bottom: 1px solid var(--rand); scrollbar-width: none; }
.tabs a, .tabs button { flex: 0 0 auto; padding: 10px 12px; color: var(--text-muted); text-decoration: none; border-bottom: 3px solid transparent; font-weight: 600; font-size: .95rem; background: none; border-top: 0; border-left: 0; border-right: 0; font-family: inherit; cursor: pointer; }
.tabs a[aria-current="page"], .tabs button[aria-current="page"] { color: var(--text); border-bottom-color: var(--accent); }
.tabs .counter { display: inline-block; min-width: 1.6em; padding: 0 6px; margin-left: 4px; border-radius: 999px; background: var(--surface-2); font-size: .8rem; text-align: center; }

.wish-list { list-style: none; margin: 0; padding: 0; }
.wish { display: flex; gap: 12px; align-items: center; justify-content: space-between; padding: 12px 4px; border-bottom: 1px solid var(--rand); }
.wish-text { display: flex; flex-direction: column; min-width: 0; gap: 2px; }
.wish-text strong { overflow-wrap: anywhere; }
.wish-text .badge { align-self: flex-start; }
.wish-list .empty { padding: 20px 4px; text-align: center; }
.votes { display: flex; align-items: center; gap: 4px; flex: 0 0 auto; margin: 0; }
.vote { width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--rand); background: var(--surface); color: var(--text-muted); font-size: 1rem; cursor: pointer; }
.vote.selected { background: var(--accent); border-color: var(--accent); color: var(--accent-text); }
.score { min-width: 2ch; text-align: center; font-weight: 700; font-variant-numeric: tabular-nums; }
.guest-footer { text-align: center; color: var(--text-muted); font-size: .85rem; padding: 16px; }
.guest-footer a { color: inherit; }
.guest-ads { margin: 0 0 8px; }

/* Verbindungsstatus (Polling) */
.connection { display: none; position: sticky; top: 0; z-index: 10; background: var(--error); color: #fff; text-align: center; padding: 6px 12px; font-size: .9rem; font-weight: 600; }
body.disconnected .connection { display: block; }
.htmx-request.btn, .htmx-request .btn-primary { opacity: .7; }

/* --- Live-Modus (DJ, dunkel, große Schaltflächen) ------------------------------------------------------- */
.live { background: var(--background); }
.live-header { position: sticky; top: 0; z-index: 5; display: flex; align-items: center; gap: 12px; padding: 10px 12px; background: var(--surface); border-bottom: 1px solid var(--rand); }
.live-back { font-size: 1.3rem; text-decoration: none; color: var(--text-muted); width: 44px; height: 44px; display: grid; place-items: center; border-radius: var(--radius-small); }
.live-title { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.live-title strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.live-title .badge { align-self: flex-start; }
.live-header form { margin: 0; }
.live-content { width: 100%; max-width: 900px; margin: 0 auto; padding: 12px; flex: 1; }
.live-add { margin-bottom: 12px; }
.live-add > summary { list-style: none; width: 100%; }
.live-add > summary::-webkit-details-marker { display: none; }
.live-add[open] > form { background: var(--surface); border: 1px solid var(--rand); border-radius: var(--radius); padding: 14px; margin-top: 8px; }
.live-bar { display: flex; justify-content: space-between; gap: 8px; align-items: flex-end; flex-wrap: wrap; }
.live-bar .tabs { flex: 1 1 100%; margin-bottom: 0; }
.live-bar form { margin: 0 0 6px; }
.live-wishes { list-style: none; margin: 8px 0 0; padding: 0; display: grid; gap: 8px; }
.live-wish { background: var(--surface); border: 1px solid var(--rand); border-radius: var(--radius); padding: 12px; }
.live-wish.status-playing { border-color: var(--ok); box-shadow: inset 4px 0 0 var(--ok); }
.live-wish.status-next { border-color: var(--accent); box-shadow: inset 4px 0 0 var(--accent); }
.live-wish.status-pending { border-style: dashed; }
.live-wish-header { display: flex; gap: 12px; justify-content: space-between; }
.live-wish-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.live-wish-text .badge { align-self: flex-start; }
.live-title-text { font-size: 1.15rem; overflow-wrap: anywhere; }
.live-artist { color: var(--text-muted); }
.live-comment { font-style: italic; }
.live-votes { display: flex; flex-direction: column; align-items: flex-end; flex: 0 0 auto; }
.live-votes .score { font-size: 1.5rem; line-height: 1.1; }
.live-actions { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 10px; align-items: flex-start; }
.live-actions form { margin: 0; flex: 1 1 auto; }
.live-actions form .btn { width: 100%; }
.live-actions .btn { min-height: 48px; padding: 10px 14px; }
.live-more { position: relative; }
.live-actions form.live-arrow { flex: 0 0 auto; }
.live-more > summary { list-style: none; }
.live-more > summary::-webkit-details-marker { display: none; }
.live-more-content { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 6px; }
.live-wishes .empty { padding: 24px; text-align: center; }
@media (min-width: 700px) { .live-actions { justify-content: flex-end; } }

/* --- Beamer/TV (Vollbild, große Schrift, dunkel) --------------------------------------------------------- */
.screen { background: var(--channel-background, #0b0b0b); color: var(--channel-text, #fff); overflow: hidden; }
.screen-frame { height: 100vh; display: flex; flex-direction: column; padding: 3vh 3vw; gap: 2vh; }
.screen-header { display: flex; align-items: center; gap: 2vw; }
.screen-header h1 { font-size: 4.2vh; margin: 0; }
.screen-logo { max-height: 8vh; max-width: 20vw; }
.screen-main { flex: 1; display: grid; grid-template-columns: 1fr auto; gap: 3vw; min-height: 0; }
.screen-list { min-height: 0; overflow: hidden; }
.screen-list h2 { font-size: 2.6vh; text-transform: uppercase; letter-spacing: .08em; opacity: .7; margin: 2vh 0 1vh; }
.screen-now { background: var(--accent); color: var(--accent-text); border-radius: 1.5vh; padding: 2vh 2vw; display: flex; flex-direction: column; font-size: 3vh; }
.screen-now strong { font-size: 5vh; line-height: 1.1; }
.screen-next { margin-top: 1.5vh; font-size: 2.8vh; display: flex; flex-direction: column; }
.screen-next strong { font-size: 3.4vh; }
.screen .now-label { font-size: 1.8vh; }
.screen-top { list-style: none; margin: 0; padding: 0; }
.screen-top li { display: flex; align-items: center; gap: 1.5vw; padding: 1.1vh 0; border-bottom: 1px solid rgba(255,255,255,.12); font-size: 3vh; }
.screen-rank { width: 5vh; height: 5vh; border-radius: 50%; background: rgba(255,255,255,.1); display: grid; place-items: center; font-weight: 700; flex: 0 0 auto; }
.screen-title { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.screen-score { font-weight: 700; font-variant-numeric: tabular-nums; }
.screen .muted { color: inherit; opacity: .65; }
.screen-qr { display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; width: 34vw; max-width: 60vh; }
.screen-qr .qr svg { width: min(30vw, 52vh); height: auto; background: #fff; padding: 1.5vh; border-radius: 1.5vh; }
.screen-headline { font-size: 3.4vh; font-weight: 700; margin: 2vh 0 .5vh; }
.screen-address { font-size: 2.2vh; opacity: .8; margin: 0; }
@media (max-aspect-ratio: 1/1) { .screen-main { grid-template-columns: 1fr; } .screen-qr { width: auto; } }

/* --- Vorbereitung, Kundenportal, Fragen ----------------------------------------------------------------- */
h3 { font-size: 1rem; margin: 16px 0 8px; }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); }
.btn-small { min-height: 36px; padding: 4px 10px; font-size: .9rem; }
.song-list, .question-list { list-style: none; padding: 0; margin: 0 0 16px; }
.song-list li, .question-list li { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--rand); }
.song-list li form, .question-list li form { margin: 0; }
.question-list details { flex: 1; min-width: 0; }
.question-list details[open] { padding-bottom: 8px; }
.song-list-new { background: var(--surface-2); border-radius: var(--radius-small); padding: 12px; }
.schedule { display: grid; gap: 8px; }
.schedule-row { display: grid; grid-template-columns: 84px 1fr; gap: 6px; padding: 8px; border: 1px solid var(--rand); border-radius: var(--radius-small); }
.schedule-row input, .schedule-row textarea { min-height: 40px; }
.schedule-row textarea { grid-column: 1 / -1; min-height: 40px; }
.schedule-row input[name$="[music]"] { grid-column: 1 / -1; }
@media (min-width: 900px) { .schedule-row { grid-template-columns: 84px 2fr 1.5fr; } .schedule-row input[name$="[music]"] { grid-column: auto; } }
.schedule-view { list-style: none; padding: 0; margin: 0 0 12px; }
.schedule-view li { display: flex; gap: 12px; padding: 6px 0; border-bottom: 1px solid var(--rand); }
.schedule-view .time { flex: 0 0 48px; font-weight: 700; font-variant-numeric: tabular-nums; }
.schedule-view li > span:last-child { display: flex; flex-direction: column; }
.answers dt { font-weight: 600; margin-top: 10px; }
.answers dd { margin: 2px 0 0; color: var(--text-muted); white-space: pre-line; }
.client-intro { font-weight: 400; text-align: left; }

/* --- Posteingang ------------------------------------------------------------------------------------------ */
.inbox { list-style: none; padding: 0; margin: 0; }
.inbox li { border-bottom: 1px solid var(--rand); }
.inbox form { margin: 0; }
.inbox-entry { display: flex; flex-direction: column; gap: 2px; width: 100%; text-align: left; background: none; border: 0; padding: 12px 4px; font: inherit; color: inherit; cursor: pointer; }
.inbox li.unread .inbox-entry strong::before { content: "● "; color: var(--accent); }
.counter-accent { display: inline-block; min-width: 1.5em; margin-left: 4px; padding: 0 5px; border-radius: 999px; background: var(--accent); color: var(--accent-text); font-size: .75rem; text-align: center; }

/* --- Fußzeile -------------------------------------------------------------- */
.footer { border-top: 1px solid var(--rand); color: var(--text-muted); font-size: .85rem; }
.footer-inner { max-width: 1080px; margin: 0 auto; padding: 16px; display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.footer a { color: inherit; }
.version { opacity: .8; }

@media (max-width: 600px) {
    h1 { font-size: 1.35rem; }
    .card { padding: 16px; }
    .header-nav { margin-left: 0; width: 100%; padding-bottom: 8px; }
}

@media (prefers-reduced-motion: reduce) {
    * { transition: none !important; animation: none !important; }
}
.list-plain { list-style: none; padding: 0; margin: 0 0 12px; }
.list-plain li { padding: 8px 0; border-bottom: 1px solid var(--rand); }
.list-plain li:last-child { border-bottom: 0; }
.bar { height: 10px; border-radius: 999px; background: var(--surface-2); overflow: hidden; flex: 1; }
.bar span { display: block; height: 100%; background: var(--accent); }
.hour { display: flex; align-items: center; gap: 8px; font-size: .9rem; margin-bottom: 4px; font-variant-numeric: tabular-nums; }
.hour > span:first-child { width: 48px; }
.poll-options { display: grid; gap: 6px; margin-bottom: 12px; }
.poll-options form { margin: 0; }
.reactions { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 12px; }
.reactions form { margin: 0; }
.reaction { font-size: 1.6rem; width: 52px; height: 52px; border-radius: 50%; border: 1px solid var(--rand); background: var(--surface); cursor: pointer; }
.reaction:active { transform: scale(.9); }
.shoutout-form label { display: block; font-weight: 600; font-size: .9rem; margin-bottom: 6px; }
.screen-reactions { display: flex; gap: 2vw; font-size: 4vh; margin: 1.5vh 0; }
.screen-reactions small { font-size: 2vh; opacity: .7; }
.screen-poll { margin: 1.5vh 0; font-size: 2.6vh; }
.screen-poll .hour { font-size: 2.4vh; }
.screen-shoutout { font-size: 3vh; margin: 1vh 0; padding: 1vh 1.5vw; border-left: .6vh solid var(--accent); background: rgba(255,255,255,.06); border-radius: .8vh; }
