/* REGION_2 – Grundlook: Schwarz, Off-White, Laserrot, Monospace */
@font-face { font-family: 'JetBrains Mono'; font-weight: 400; font-display: swap; src: url(fonts/jetbrains-mono-latin-400-normal.woff2) format('woff2'); }
@font-face { font-family: 'JetBrains Mono'; font-weight: 500; font-display: swap; src: url(fonts/jetbrains-mono-latin-500-normal.woff2) format('woff2'); }
@font-face { font-family: 'JetBrains Mono'; font-weight: 700; font-display: swap; src: url(fonts/jetbrains-mono-latin-700-normal.woff2) format('woff2'); }
@font-face { font-family: 'JetBrains Mono'; font-weight: 800; font-display: swap; src: url(fonts/jetbrains-mono-latin-800-normal.woff2) format('woff2'); }
@font-face { font-family: 'Doto'; font-weight: 900; font-display: swap; src: url(fonts/doto-r2-900.woff2) format('woff2'); }

:root {
  --bg: #0E0E0E;
  --surface: #161616;
  --card: #1A1A1A;
  --line: #262626;
  --line-strong: #3A3A3A;
  --text: #EDEAE4;
  --text-2: #D6D2CB;
  --muted: #A9A49B;
  --dim: #8C877F;
  --faint: #6B6760;
  --accent: #E8372C;
  --accent-fill: #C8261C;
  --danger: #FF6B5E;
  --mono: 'JetBrains Mono', ui-monospace, monospace;
  --dot: 'Doto', 'JetBrains Mono', monospace;
  --pad: 48px;
}

* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--text); font-family: var(--mono); -webkit-font-smoothing: antialiased; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }
img { display: block; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

.app { min-height: 100vh; padding: 0 var(--pad) 48px; }

/* Kopfzeile */
.top { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px 24px; padding: 28px 0 24px; border-bottom: 1px solid var(--line); }
.brand { display: flex; align-items: center; gap: 12px; font-size: 22px; font-weight: 700; letter-spacing: -0.5px; }
.brand svg { width: 36px; height: 36px; }
.search { flex: 1 1 340px; max-width: 560px; display: flex; align-items: center; gap: 12px; height: 48px; padding: 0 16px; border: 1px solid var(--line-strong); border-radius: 24px; color: var(--muted); }
.search:focus-within { border-color: var(--text); }
.search input { flex: 1; min-width: 0; background: transparent; border: 0; outline: none; color: var(--text); font: 400 14px var(--mono); }
.search input::placeholder { color: var(--dim); }
.search input::-webkit-search-cancel-button { -webkit-appearance: none; appearance: none; display: none; }
.search .leeren { flex: none; display: flex; align-items: center; justify-content: center; width: 28px; height: 28px; margin-right: -6px; padding: 0; border: 0; border-radius: 14px; background: var(--line-strong); color: var(--text); cursor: pointer; }
.search .leeren[hidden] { display: none; }
.search .leeren svg { width: 12px; height: 12px; }
.top-right { display: flex; align-items: center; gap: 20px; }
.counter { display: flex; align-items: baseline; gap: 10px; }
.counter b { font: 900 44px/1 var(--dot); }
.counter span { font-size: 11px; line-height: 1.3; color: var(--muted); letter-spacing: 1.5px; text-transform: uppercase; max-width: 9ch; }
.btn { height: 44px; padding: 0 20px; border-radius: 22px; border: 1px solid var(--text); background: transparent; font-size: 13px; font-weight: 700; letter-spacing: 1px; text-transform: uppercase; display: inline-flex; align-items: center; gap: 10px; cursor: pointer; }
.btn.solid { background: var(--text); color: var(--bg); }

/* Filter */
.filters { display: flex; flex-wrap: wrap; gap: 10px; padding: 24px 0; }
.chip { height: 36px; padding: 0 16px; border-radius: 18px; border: 1px solid var(--line-strong); background: transparent; font-size: 12px; letter-spacing: 1px; text-transform: uppercase; cursor: pointer; white-space: nowrap; }
.chip[aria-pressed="true"] { background: var(--text); border-color: var(--text); color: var(--bg); font-weight: 700; }

/* Galerie */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 28px 20px; }
.card { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.cover { position: relative; aspect-ratio: 2 / 3; border-radius: 6px; overflow: hidden; background: var(--card); }
.cover img { width: 100%; height: 100%; object-fit: cover; }
.cover .ph { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; padding: 12px; text-align: center; font-size: 12px; color: var(--muted); }
.card.wunsch .cover img { filter: grayscale(1); opacity: 0.35; }
.stamp { position: absolute; left: 8px; bottom: 8px; padding: 3px 7px; border: 1px dashed var(--text); border-radius: 4px; background: var(--bg); font-size: 10px; font-weight: 700; letter-spacing: 1px; text-transform: uppercase; }
.stamp.netflix { border: 1px solid var(--accent); background: var(--accent); color: #0E0E0E; }
.netflix-knopf { gap: 10px; }
.nf-marke { padding: 2px 6px; border-radius: 4px; background: var(--accent); color: #0E0E0E; font-size: 9px; font-weight: 800; letter-spacing: 1px; }
.badge { position: absolute; top: 8px; left: 8px; display: flex; align-items: center; gap: 6px; padding: 3px 8px; border-radius: 10px; background: var(--bg); font-size: 10px; font-weight: 700; }
.badge::before, .dot-accent { content: ''; width: 6px; height: 6px; border-radius: 3px; background: var(--accent); display: inline-block; }
/* Reihen-Badge: unvollständig neutral, komplett in der Akzentfarbe */
.badge::before { background: var(--text); }
.card-title { font-size: 13px; font-weight: 500; line-height: 1.35; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.card-year { font-size: 11px; color: var(--dim); }

.empty { padding: 80px 0; display: flex; flex-direction: column; align-items: center; gap: 12px; text-align: center; color: var(--muted); }
.empty b { font: 900 26px var(--dot); color: var(--text); }

/* Detail */
.back { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; font-size: 13px; letter-spacing: 1px; text-transform: uppercase; }
.detail { display: flex; flex-wrap: wrap; gap: 56px; padding-top: 40px; }
.detail-cover { flex: 0 1 340px; min-width: 220px; }
.detail-cover img { width: 100%; aspect-ratio: 2 / 3; object-fit: cover; border-radius: 8px; }
.detail-main { flex: 999 1 520px; min-width: 0; display: flex; flex-direction: column; gap: 26px; }
.eyebrow { font-size: 12px; letter-spacing: 2px; color: var(--accent); font-weight: 700; text-transform: uppercase; }
.detail h1 { margin: 0; font-size: 44px; font-weight: 800; letter-spacing: -1.5px; line-height: 1.1; }
.meta { display: flex; flex-wrap: wrap; gap: 8px 20px; font-size: 13px; color: var(--muted); text-transform: uppercase; }
.status-zeile { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.segment { display: inline-flex; width: fit-content; border: 1px solid var(--line-strong); border-radius: 24px; padding: 4px; }
.segment button { height: 40px; padding: 0 20px; border: 0; border-radius: 20px; background: transparent; font-size: 12px; letter-spacing: 1px; text-transform: uppercase; display: flex; align-items: center; gap: 8px; cursor: pointer; }
.segment button[aria-pressed="true"] { background: var(--text); color: var(--bg); font-weight: 700; }
.segment button[aria-pressed="true"]::before { content: ''; width: 8px; height: 8px; border-radius: 4px; background: var(--accent); }
.prose { margin: 0; max-width: 680px; font-size: 14px; line-height: 1.7; color: var(--text-2); }
.label { font-size: 11px; letter-spacing: 2px; color: var(--dim); text-transform: uppercase; }
.note { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--muted); }
.series { display: flex; flex-direction: column; gap: 16px; padding-top: 24px; border-top: 1px solid var(--line); }
.series-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; }
.dots { display: flex; gap: 6px; }
.dots i { width: 10px; height: 10px; border-radius: 5px; background: var(--text); }
.dots i.off { background: transparent; border: 1.5px solid var(--faint); }
.series-count { display: flex; align-items: center; gap: 14px; }
.series-count b { font: 900 22px var(--dot); }
.series-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(84px, 1fr)); gap: 12px; }
.series-grid .cover { border-radius: 5px; }
.series-grid .card.current .cover { outline: 2px solid var(--accent); outline-offset: -2px; }
.series-grid .card-year { font-size: 10px; letter-spacing: 1px; text-transform: uppercase; }

/* Tab-Leiste (nur iPhone) */
.tabbar { display: none; }
.toast { position: fixed; left: 50%; bottom: 110px; transform: translateX(-50%); padding: 12px 18px; border-radius: 22px; background: var(--surface); border: 1px solid var(--line-strong); font-size: 12px; z-index: 20; }

@media (max-width: 700px) {
  :root { --pad: 16px; }
  .app { padding-bottom: 120px; }
  .top { padding-top: 16px; border-bottom: 0; padding-bottom: 8px; }
  .brand { font-size: 18px; }
  .brand svg { width: 30px; height: 30px; }
  .search { order: 3; flex-basis: 100%; height: 44px; }
  .top-right .btn { display: none; }
  .counter b { font-size: 28px; }
  .counter span { font-size: 9px; }
  .filters { flex-wrap: nowrap; overflow-x: auto; padding: 12px 0 16px; scrollbar-width: none; }
  .chip { height: 32px; padding: 0 14px; font-size: 11px; }
  .grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px 12px; }
  .card { gap: 6px; }
  .card-title { font-size: 11px; }
  .card-year { display: none; }
  .stamp { left: 5px; bottom: 5px; font-size: 8px; padding: 2px 5px; }
  .badge { top: 5px; left: 5px; font-size: 9px; padding: 2px 6px; }
  .detail { gap: 20px; padding-top: 8px; }
  .detail-cover { flex: 0 0 132px; min-width: 0; }
  .detail-main { flex-basis: 100%; gap: 20px; }
  .detail h1 { font-size: 22px; letter-spacing: -0.5px; }
  .meta { font-size: 11px; }
  .segment { width: 100%; display: grid; grid-template-columns: 1fr 1fr; }
  .segment button { justify-content: center; }
  .status-zeile { flex-wrap: nowrap; gap: 8px; }
  .status-zeile .segment { flex: 1; min-width: 0; grid-template-columns: repeat(3, auto); justify-content: space-between; }
  .status-zeile .segment button { padding: 0 10px; font-size: 11px; letter-spacing: 0.5px; }
  .status-zeile .segment button[aria-pressed="true"]::before { display: none; }
  .series-grid { grid-template-columns: repeat(auto-fill, minmax(52px, 1fr)); gap: 8px; }
  .tabbar { position: fixed; left: 0; right: 0; bottom: 0; display: grid; grid-template-columns: repeat(5, 1fr); align-items: center; padding: 10px 8px calc(14px + env(safe-area-inset-bottom)); background: var(--bg); border-top: 1px solid var(--line); z-index: 10; }
  .tabbar a { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; min-height: 44px; font-size: 10px; letter-spacing: 1px; color: var(--dim); text-transform: uppercase; }
  .tabbar a[aria-current="page"] { color: var(--text); font-weight: 700; }
  .tabbar .plus { width: 56px; height: 56px; border-radius: 28px; background: var(--text); margin: 0 auto; }
}

/* Reihen-Pakete: leicht gestapelt, damit man sie als Paket erkennt */
.cover.stack { overflow: visible; --st: 6px; }
/* Stapel: pro weiterem Film ein Schatten, höchstens drei */
.cover.stack.s1 { box-shadow: var(--st) calc(var(--st) * -1) 0 0 #4A4A4A; }
.cover.stack.s2 { box-shadow: var(--st) calc(var(--st) * -1) 0 0 #4A4A4A, calc(var(--st) * 2) calc(var(--st) * -2) 0 0 #363636; }
.cover.stack.s3 { box-shadow: var(--st) calc(var(--st) * -1) 0 0 #4A4A4A, calc(var(--st) * 2) calc(var(--st) * -2) 0 0 #363636, calc(var(--st) * 3) calc(var(--st) * -3) 0 0 #262626; }
.cover.stack img { border-radius: 6px; }
.badge.voll::before { background: var(--accent); }
.reihe-h1 { margin: 0; font-size: 44px; font-weight: 800; letter-spacing: -1.5px; line-height: 1.1; }
a.eyebrow:hover { text-decoration: underline; }
@media (max-width: 700px) {
  .cover.stack { --st: 4px; }
  .reihe-h1 { font-size: 24px; letter-spacing: -0.5px; }
  .grid { padding-top: 6px; }
}

/* ---------- Etappe 3 + 4 ---------- */
.icon-btn { width: 44px; height: 44px; border-radius: 22px; border: 1px solid var(--line-strong); background: transparent; display: inline-flex; align-items: center; justify-content: center; cursor: pointer; flex-shrink: 0; }
.btn.danger { background: #B3241B; border-color: #B3241B; color: #fff; }
.btn.ghost { border-color: transparent; color: var(--muted); text-decoration: underline; text-transform: none; font-weight: 400; letter-spacing: 0; }
.btn.gross { height: 52px; border-radius: 26px; justify-content: center; width: 100%; }
.btn:disabled { opacity: 0.4; cursor: default; }
.btn .dot-accent, .dot-accent { flex-shrink: 0; }
.notiz { display: flex; flex-direction: column; gap: 6px; padding: 12px 14px; border: 1px dashed var(--line-strong); border-radius: 12px; font-size: 13px; max-width: 680px; }
.hint { margin: 0; font-size: 12px; line-height: 1.6; color: var(--muted); }
.akzent-text { color: var(--text); display: inline-flex; align-items: center; gap: 6px; }
.segment.voll { display: grid; grid-template-columns: 1fr 1fr; width: 100%; max-width: 520px; }
.segment.voll button { justify-content: center; }
.segment.voll button[aria-pressed="true"]::before { display: none; }

/* Dialoge */
.modal { position: fixed; inset: 0; z-index: 30; background: rgba(0, 0, 0, 0.6); display: flex; align-items: center; justify-content: center; padding: 16px; }
.modal-box { width: 100%; max-width: 440px; max-height: 86vh; overflow: auto; background: var(--surface); border: 1px solid #2A2A2A; border-radius: 24px; padding: 20px; display: flex; flex-direction: column; gap: 16px; }
.modal-box.breit { max-width: 760px; }
.modal-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.modal-head b { font-size: 14px; }
.modal-head .sub { display: block; font-size: 10px; letter-spacing: 1px; color: var(--muted); text-transform: uppercase; margin-top: 2px; }
.modal-actions { display: flex; justify-content: flex-end; gap: 10px; }
.feld { width: 100%; background: #121212; border: 1px solid var(--line-strong); border-radius: 14px; padding: 14px 16px; color: var(--text); font: 400 14px/1.6 var(--mono); outline: none; resize: vertical; }
.feld:focus { border-color: var(--text); }
input.feld { border-radius: 24px; height: 48px; }
.menu { display: flex; flex-direction: column; }
.menu-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 56px; padding: 0 4px; background: transparent; border: 0; border-bottom: 1px solid #222; text-align: left; cursor: pointer; }
.menu-row:last-child { border-bottom: 0; }
.menu-row b { display: block; font-size: 13px; }
.menu-row small { display: block; font-size: 11px; color: var(--muted); margin-top: 2px; }
.menu-row.rot { color: var(--danger); }
.chips-wrap { display: flex; flex-wrap: wrap; gap: 8px; }
.cover-wahl { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 12px; }
.cover-option { position: relative; padding: 0; border: 1px solid transparent; border-radius: 6px; background: var(--card); overflow: hidden; cursor: pointer; aspect-ratio: 2 / 3; }
.cover-option:hover { border-color: var(--text); }
.cover-option img { width: 100%; height: 100%; object-fit: cover; }
.cover-option small { position: absolute; left: 6px; bottom: 6px; padding: 2px 5px; background: var(--bg); border-radius: 3px; font-size: 9px; }
.loeschen { display: flex; flex-direction: column; align-items: center; gap: 12px; text-align: center; }
.loeschen b { font-size: 16px; }
.loeschen p { margin: 0; font-size: 12px; line-height: 1.6; color: var(--text-2); }
.loeschen .btn { width: 100%; justify-content: center; }

/* Hinzufügen */
.add { max-width: 720px; margin: 0 auto; padding-top: 24px; display: flex; flex-direction: column; gap: 18px; }
.search.gross { max-width: none; height: 56px; border-color: var(--text); }
.search.gross input { font-size: 17px; }
.treffer { display: flex; flex-direction: column; }
.treffer-row, .check-row { display: flex; align-items: center; gap: 14px; min-height: 64px; padding: 8px 0; border-bottom: 1px solid #1F1F1F; }
.treffer-row img, .check-row img, .ph-mini { width: 44px; aspect-ratio: 2 / 3; object-fit: cover; border-radius: 3px; background: var(--card); flex-shrink: 0; }
.treffer-row > svg { color: var(--faint); flex-shrink: 0; }
.treffer-text { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.treffer-text b { font-size: 13px; overflow: hidden; text-overflow: ellipsis; }
.treffer-text small { font-size: 11px; color: var(--muted); }
.treffer-text small.akzent { color: var(--text); font-weight: 700; letter-spacing: 1px; text-transform: uppercase; font-size: 10px; }
.link-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 48px; padding: 0 16px; border: 1px solid var(--line); border-radius: 14px; font-size: 12px; color: var(--text-2); }
.tmdb { margin: 0; font-size: 10px; line-height: 1.6; color: var(--faint); text-align: center; }
.bestaetigen .back { align-self: flex-start; }
.best-film { display: flex; gap: 24px; align-items: flex-end; }
.best-film img { width: 180px; aspect-ratio: 2 / 3; object-fit: cover; border-radius: 8px; flex-shrink: 0; }
.best-text { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.best-text h1 { margin: 0; font-size: 28px; font-weight: 800; letter-spacing: -0.5px; line-height: 1.15; }
.reihe-box { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 16px; border: 1px solid var(--line); border-radius: 14px; }
.reihe-box b { display: block; font-size: 12px; }
.reihe-box small { display: block; font-size: 12px; color: var(--muted); margin-top: 2px; }
.dots i.akzent { background: var(--accent); }
.aktionen { display: flex; flex-direction: column; gap: 10px; }
.aktionen.zwei { display: grid; grid-template-columns: 1fr 1fr; }
.aktionen.drei { display: grid; grid-template-columns: repeat(3, 1fr); }
.aktionen.drei .btn { padding-left: 8px; padding-right: 8px; }
.check-list { display: flex; flex-direction: column; }
.check-row input { width: 22px; height: 22px; margin: 0; accent-color: var(--text); flex-shrink: 0; }
.check-done { width: 22px; height: 22px; border-radius: 6px; background: var(--card); color: var(--faint); display: inline-flex; align-items: center; justify-content: center; font-size: 12px; flex-shrink: 0; }
.check-row.erledigt .treffer-text b { color: var(--muted); }
.sticky-actions { position: sticky; bottom: 0; background: var(--bg); padding: 14px 0 8px; border-top: 1px solid var(--line); display: flex; flex-direction: column; gap: 10px; }

/* Hinzugefügt */
.fertig { min-height: 100vh; max-width: 480px; margin: 0 auto; display: flex; flex-direction: column; justify-content: center; align-items: stretch; gap: 26px; padding: 40px 0; }
.fertig-zahl { display: flex; flex-direction: column; align-items: center; gap: 8px; }
.zahl-zeile { display: flex; align-items: flex-start; gap: 8px; }
.zahl-zeile b { font: 900 104px/0.9 var(--dot); transition: opacity 0.2s; }
.zahl-zeile b.blink { animation: blink 0.5s steps(2) 2; }
@keyframes blink { 50% { opacity: 0.2; } }
.plus-eins { font: 900 26px var(--dot); color: var(--accent); }
.fertig-karte { display: flex; gap: 14px; align-items: center; padding: 14px; border: 1px solid var(--line); border-radius: 14px; }
.fertig-karte img { width: 52px; aspect-ratio: 2 / 3; object-fit: cover; border-radius: 4px; }
.fertig-karte b { display: block; font-size: 13px; }
.fertig-karte small { display: flex; font-size: 11px; color: var(--muted); margin-top: 4px; }
.fertig .btn.ghost { align-self: center; }

/* Import */
.import { display: flex; flex-wrap: wrap; gap: 40px; padding-top: 28px; }
.import-links { flex: 1 1 320px; min-width: 0; display: flex; flex-direction: column; gap: 14px; }
.import-rechts { flex: 999 1 520px; min-width: 0; display: flex; flex-direction: column; gap: 14px; }
.import-zahlen { display: flex; flex-wrap: wrap; gap: 20px; font-size: 12px; }
.import-zahlen b { font: 900 20px var(--dot); }
.import-liste { display: flex; flex-direction: column; }
.import-row { display: flex; align-items: center; gap: 14px; min-height: 56px; padding: 8px 0; border-bottom: 1px solid #1F1F1F; }
.import-row input[type=checkbox] { width: 20px; height: 20px; accent-color: var(--text); flex-shrink: 0; }
.import-row .zeile { width: 170px; flex-shrink: 0; font-size: 12px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.import-row.aus { opacity: 0.55; }
.import-row select { width: 100%; background: #121212; color: var(--text); border: 1px solid var(--line-strong); border-radius: 10px; padding: 8px 10px; font: 400 12px var(--mono); }

@media (max-width: 700px) {
  .modal { align-items: flex-end; padding: 0; }
  .modal-box { max-width: none; border-radius: 28px 28px 0 0; padding: 20px 20px calc(24px + env(safe-area-inset-bottom)); }
  .add { padding-top: 8px; }
  .best-film { flex-direction: column; align-items: center; text-align: center; }
  .best-film img { width: 160px; }
  .best-text { align-items: center; }
  .best-text h1 { font-size: 20px; }
  .zahl-zeile b { font-size: 88px; }
  .import-row { flex-wrap: wrap; }
  .import-row .zeile { width: auto; flex: 1; }
  .import-row .treffer-text { flex-basis: 100%; padding-left: 34px; }
  .fertig { min-height: calc(100vh - 40px); padding: 24px 0; }
}

/* iPhone: Platz für Uhrzeit/Akku oben (Statusleiste) und unten (Home-Balken) */
.app { padding-top: env(safe-area-inset-top); padding-left: max(var(--pad), env(safe-area-inset-left)); padding-right: max(var(--pad), env(safe-area-inset-right)); }
.fertig { padding-top: calc(24px + env(safe-area-inset-top)); }
/* Suchfeld beim Hinzufügen bleibt oben (die Regel für die Galerie schiebt es sonst nach unten) */
.add .search { order: 0; }

/* iPhone zoomt in Eingabefelder mit Schrift unter 16px – deshalb dort mindestens 16px */
@media (max-width: 700px) {
  input, select, textarea, .search input, .feld, .import-row select { font-size: 16px; }
}

/* ---------- Etappe 5: Zufall, Mehr ---------- */
.btn.rot { background: var(--accent); border-color: var(--accent); color: #0E0E0E; }
.zufall { max-width: 560px; margin: 0 auto; padding-top: 24px; display: flex; flex-direction: column; gap: 16px; }
.dot-titel { margin: 0; font: 900 40px/1.05 var(--dot); }
.zufall-film { display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; padding: 8px 0; }
.zufall-cover { width: min(240px, 60vw); aspect-ratio: 2 / 3; border-radius: 8px; overflow: hidden; background: var(--card); margin-bottom: 8px; }
.zufall-cover img { width: 100%; height: 100%; object-fit: cover; }
.zufall-start { display: flex; align-items: center; justify-content: center; border: 1px dashed var(--line-strong); }
.zufall-start span { font: 900 96px var(--dot); color: var(--accent); }
.zufall .aktionen .btn.aus { opacity: .5; pointer-events: none; }
.zufall .aktionen .btn svg { width: 18px; height: 18px; }
.zufall-film b { font-size: 18px; }
.chip .farbpunkt, .farbpunkt { display: inline-block; width: 10px; height: 10px; border-radius: 5px; background: var(--accent); margin-right: 8px; vertical-align: middle; }
.chip.geschaut { align-self: flex-start; }
.mehr { max-width: 720px; margin: 0 auto; padding-top: 24px; display: flex; flex-direction: column; gap: 18px; }
.mehr-titel { margin: 0; font-size: 18px; letter-spacing: 1px; text-transform: uppercase; }
.stat-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.stat { padding: 16px; border: 1px solid var(--line); border-radius: 14px; display: flex; flex-direction: column; gap: 8px; }
.stat b { font: 900 38px/1 var(--dot); }
.stat span { font-size: 10px; letter-spacing: 1.5px; color: var(--muted); text-transform: uppercase; }
.menu-row .wert { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; color: var(--muted); }
.schalter { width: 44px; height: 26px; border-radius: 13px; background: var(--line-strong); position: relative; flex-shrink: 0; transition: background 0.2s; }
.schalter::after { content: ''; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 10px; background: var(--text); transition: left 0.2s; }
.schalter.an { background: var(--accent); }
.schalter.an::after { left: 21px; }
.backup-box { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 16px; border: 1px solid var(--line); border-radius: 14px; }
.backup-box b { display: block; font-size: 13px; }
.backup-box small { display: flex; font-size: 11px; color: var(--muted); margin-top: 4px; }
@media (max-width: 700px) {
  .nur-gross { display: none; }
  .stat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stat b { font-size: 32px; }
  .dot-titel { font-size: 30px; }
  .zufall { padding-top: 4px; }
  .backup-box { flex-direction: column; align-items: stretch; }
  .backup-box .btn { justify-content: center; }
}

/* ---------- Etappe 6: Login, offline ---------- */
.login { min-height: 100vh; max-width: 400px; margin: 0 auto; display: flex; flex-direction: column; justify-content: center; gap: 36px; padding: 40px 0; }
.login-logo { display: flex; flex-direction: column; align-items: center; gap: 14px; }
.login-logo b { font-size: 28px; letter-spacing: -0.5px; }
.login-form { display: flex; flex-direction: column; gap: 10px; }
.feld-label { font-size: 10px; letter-spacing: 2px; color: var(--dim); text-transform: uppercase; padding-top: 6px; }
.offline { margin-top: 16px; padding: 10px 14px; border: 1px dashed var(--muted); border-radius: 12px; font-size: 11px; line-height: 1.5; }
div.menu-row { cursor: default; }

/* Passwortfeld mit Auge */
.pw-wrap { position: relative; }
.pw-wrap .feld { padding-right: 52px; }
.auge { position: absolute; right: 4px; top: 50%; transform: translateY(-50%); width: 44px; height: 44px; border: 0; border-radius: 22px; background: transparent; color: var(--muted); display: flex; align-items: center; justify-content: center; cursor: pointer; }
.auge:hover, .auge[aria-pressed="true"] { color: var(--text); }

/* ---------- Filter & Sortierung ---------- */
.fx-knopf { margin-left: auto; display: inline-flex; align-items: center; }
#fx { display: flex; flex-direction: column; gap: 22px; }
.fx-gruppe { display: flex; flex-direction: column; gap: 14px; }
.fx-gruppe + .fx-gruppe { padding-top: 22px; border-top: 1px solid var(--line); }
.fx-gruppe .chips-wrap { gap: 10px; }
.fx-fuss { position: sticky; bottom: -20px; display: flex; align-items: center; gap: 16px; padding: 14px 0 4px; background: var(--surface); border-top: 1px solid var(--line); }
.fx-zahl { display: flex; flex-direction: column; gap: 2px; }
.fx-zahl b { font: 900 28px/1 var(--dot); }
.fx-fuss .btn { flex: 1; }
.aktive-filter { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: -12px 0 20px; }
.chip.klein { height: 28px; padding: 0 12px; font-size: 11px; border-color: var(--text); }
@media (max-width: 700px) {
  .fx-knopf { margin-left: 0; order: -1; }
  .aktive-filter { margin: -6px 0 14px; }
  .fx-fuss { bottom: calc(-24px - env(safe-area-inset-bottom)); padding-bottom: 8px; }
}

/* Reihen prüfen */
.pruef-reihe { display: flex; flex-direction: column; gap: 4px; padding-top: 8px; }
.pruef-kopf { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-bottom: 8px; border-bottom: 1px solid var(--line-strong); }
.pruef-kopf span { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.pruef-kopf b { font-size: 15px; }
.pruef-kopf small { font-size: 11px; letter-spacing: 1px; text-transform: uppercase; color: var(--muted); }

/* Hinzufügen am Mac: Suche links, Vorschau rechts */
.add .search { flex: none; }

.split-links { display: flex; flex-direction: column; gap: 18px; min-width: 0; }
.vorschau { display: none; }
.treffer-row[aria-current] { background: var(--card); margin: 0 -12px; padding-left: 12px; padding-right: 12px; border-radius: 10px; border-bottom-color: transparent; }
@media (min-width: 1000px) {
  .add.split { max-width: 1200px; display: grid; grid-template-columns: minmax(0, 440px) minmax(0, 1fr); gap: 48px; align-items: start; }
  .vorschau { display: flex; flex-direction: column; gap: 18px; position: sticky; top: 24px; padding: 28px; border: 1px solid var(--line); border-radius: 20px; min-height: 420px; }
  .vorschau .best-film img { width: 200px; }
  .vorschau .aktionen { display: grid; grid-template-columns: 1fr 1fr; }
  .vorschau-leer { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px; color: var(--faint); font-size: 12px; text-align: center; min-height: 360px; }
  .vorschau-leer svg { width: 28px; height: 28px; }
}
.best-inhalt { margin: 0; font-size: 13px; line-height: 1.7; color: var(--text-2); display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }

/* Vorschläge */
.vorschlaege { display: flex; flex-direction: column; gap: 28px; padding-top: 32px; }
.vs-kopf { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 16px; }
.vorschlag { position: relative; }
.vorschlag .cover { display: block; }
.vs-weg { position: absolute; top: 6px; right: 6px; width: 30px; height: 30px; border-radius: 15px; border: 0; background: rgba(14, 14, 14, 0.75); color: var(--text); display: flex; align-items: center; justify-content: center; cursor: pointer; }
.vs-weg svg { width: 14px; height: 14px; }
.vs-weil { font-size: 10px; color: var(--faint); line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* Bewertungen: IMDb und Tomatometer als Kapseln */
.bewertung { display: flex; flex-wrap: wrap; gap: 8px; }
.bewertung span { display: inline-flex; align-items: center; gap: 7px; height: 28px; padding: 0 12px; border: 1px solid var(--line-strong); border-radius: 14px; font-size: 11px; letter-spacing: 1px; color: var(--muted); text-transform: uppercase; white-space: nowrap; }
.bewertung b { color: var(--text); font-weight: 700; }
.bewertung i { width: 6px; height: 6px; border-radius: 3px; background: var(--accent); display: inline-block; }
@media (max-width: 700px) { .best-text .bewertung { justify-content: center; } }

/* Ausleihen */
.detail-chips { gap: 8px; }
.detail-chips .chip { display: inline-flex; align-items: center; gap: 8px; }
.ausleihe { display: flex; align-items: center; gap: 14px; padding: 14px 16px; border: 1px solid var(--line-strong); border-radius: 14px; max-width: 680px; }
.ausleihe > div { flex: 1; min-width: 0; }
.ausleihe b { display: block; font-size: 13px; }
.ausleihe small { display: block; font-size: 11px; color: var(--muted); margin-top: 3px; }
.ausleihe .dot-accent { flex-shrink: 0; }
.leih-an { color: var(--text-2); }

/* Mehr: zusätzliche Notizen unter den Zahlen */
.stat-notes { display: flex; flex-direction: column; gap: 10px; }

/* Mehr: mehr Luft, vor allem auf dem iPhone */
.mehr { gap: 22px; padding-bottom: 40px; }
.mehr > .label { margin-top: 18px; }
.stat-grid { gap: 12px; }
.stat { padding: 18px; gap: 10px; }
.stat span { line-height: 1.5; }
.menu-row { min-height: 60px; }
@media (max-width: 700px) {
  .mehr { gap: 20px; padding-top: 12px; }
  .mehr > .label { margin-top: 22px; }
  .mehr-titel { margin-bottom: 4px; }
  .stat-grid { gap: 12px; }
  .stat { padding: 16px; min-height: 104px; justify-content: space-between; }
  .menu-row { min-height: 64px; padding: 0 2px; }
  .mehr .chips-wrap { gap: 10px; }
  .backup-box { gap: 14px; padding: 18px 16px; }
  /* Detail: Status-Knöpfe kompakt nebeneinander statt über die ganze Breite verteilt */
  .status-zeile .segment { flex: 0 1 auto; display: inline-flex; width: auto; }
  .status-zeile .segment button { padding: 0 12px; }
}
.ausleihe .btn { height: 38px; padding: 0 14px; font-size: 11px; flex-shrink: 0; }

/* iOS Safari: Beim Ein-/Ausblenden der Adressleiste rechnet Safari fixierte Elemente kurz mit der alten
   Fensterhöhe. Die Leiste «schwebt» dann einen Moment zu hoch. Diese Verlängerung nach unten deckt den
   Inhalt darunter ab, damit man den Sprung nicht sieht. Im normalen Zustand liegt sie ausserhalb des Bildschirms. */
.tabbar::after { content: ''; position: absolute; left: 0; right: 0; top: 100%; height: 160px; background: var(--bg); pointer-events: none; }

/* Konto: Wiederherstellungscode, Einladungen */
.code-box { padding: 18px 16px; border: 1px dashed var(--line-strong); border-radius: 14px; font: 700 20px/1.4 var(--mono, 'JetBrains Mono', monospace); letter-spacing: 2px; text-align: center; user-select: all; -webkit-user-select: all; word-break: break-all; }
.code-box.klein { font-size: 12px; letter-spacing: 0; font-weight: 500; text-align: left; }
.check-zeile { display: flex; align-items: center; gap: 10px; font-size: 13px; padding: 6px 0; cursor: pointer; }
.check-zeile input { width: 20px; height: 20px; accent-color: var(--accent); }
.btn.gefahr { background: var(--danger); border-color: var(--danger); color: #0E0E0E; }
.link { color: var(--text-2); text-decoration: underline; }
.modal .menu-row .btn.ghost { flex-shrink: 0; }

/* Leere Sammlung */
.willkommen { max-width: 520px; margin: 40px auto; display: flex; flex-direction: column; gap: 18px; text-align: left; }
.willkommen p { margin: 0; color: var(--text-2); line-height: 1.6; font-size: 14px; }

/* Installieren */
.install-karte { display: flex; flex-direction: column; gap: 10px; padding: 18px; border: 1px solid var(--line); border-radius: 16px; }
.install-karte b { font-size: 13px; }
.schritte { margin: 0; padding-left: 22px; display: flex; flex-direction: column; gap: 10px; font-size: 14px; line-height: 1.5; }
.schritte li::marker { color: var(--accent); font-weight: 700; }
.andere summary { cursor: pointer; font-size: 12px; color: var(--muted); padding: 8px 0; }
.andere[open] { display: flex; flex-direction: column; gap: 12px; }

/* Datenschutz */
.datenschutz section { display: flex; flex-direction: column; gap: 8px; }
.datenschutz h2 { margin: 8px 0 0; font-size: 14px; }
.datenschutz p { margin: 0; font-size: 13px; line-height: 1.7; color: var(--text-2); }

/* Update-Hinweis: grosses Update = Leiste oben, kleines = Karte unten */
.update-banner.gross { position: sticky; top: 0; z-index: 40; display: flex; align-items: center; justify-content: center; gap: 14px; min-height: 40px;
  padding: calc(6px + env(safe-area-inset-top)) 16px 6px; background: var(--accent); color: #0E0E0E; font-size: 12px; font-weight: 700; text-align: center; }
.update-banner.gross .los { flex: none; border: 1.5px solid #0E0E0E; border-radius: 14px; padding: 4px 12px; background: none; color: #0E0E0E; font: 800 10px var(--mono); letter-spacing: 1px; text-transform: uppercase; cursor: pointer; }
.update-banner.klein { position: fixed; left: 16px; right: 16px; bottom: calc(96px + env(safe-area-inset-bottom)); z-index: 40; padding: 18px; border-radius: 14px;
  border: 1px solid var(--line-strong); background: var(--surface); box-shadow: 0 12px 40px rgba(0,0,0,.6);
  display: grid; grid-template-columns: 1fr auto; gap: 4px 16px; align-items: center; }
.update-banner.klein .t { font-size: 10px; letter-spacing: 2px; text-transform: uppercase; color: var(--accent); font-weight: 700; display: flex; align-items: center; gap: 8px; }
.update-banner.klein .v { font: 900 26px var(--dot); grid-row: 2; }
.update-banner.klein .s { font-size: 11px; color: var(--muted); grid-row: 3; }
.update-banner.klein .knoepfe { grid-column: 2; grid-row: 1 / 4; display: flex; flex-direction: column; gap: 8px; }
.update-banner.klein .los { border: 0; border-radius: 18px; padding: 10px 16px; background: var(--accent); color: #0E0E0E; font: 800 11px var(--mono); letter-spacing: 1px; text-transform: uppercase; cursor: pointer; }
.update-banner.klein .spaeter { border: 1px solid var(--line-strong); border-radius: 18px; padding: 8px 16px; background: none; color: var(--muted); font: 700 10px var(--mono); letter-spacing: 1px; text-transform: uppercase; cursor: pointer; }
@media (min-width: 701px) { .update-banner.klein { left: auto; right: 32px; bottom: 32px; width: 380px; } }
.login-logo.klein b { font-size: 20px; text-align: center; line-height: 1.3; }
