/* Layout: Werkzeug-Oberfläche. Kopfleiste, links Filter, rechts Katalograster; Detailansicht als Blatt mit 3D-Viewer. */
:root {
  --bg: #EDF0EE;
  --surface: #FFFFFF;
  --surface-2: #E2E7E4;
  --ink: #17201E;
  --muted: #56625F;
  --line: #CBD3D0;
  --accent: #1E4F8E;      /* Enzianblau, RAL 5010 */
  --accent-ink: #FFFFFF;
  --accent-soft: #DCE6F3;
  --ok: #23774A;
  --warn: #A86A12;
  --bad: #B42318;
  --shade: rgba(16, 24, 22, .5);
  --grid-major: #9AA6A2;
  --grid-minor: #C6CECB;
  --f-display: "Archivo", "Arial Narrow", system-ui, sans-serif;
  --f-body: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --f-mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #111615; --surface: #19201F; --surface-2: #212A28; --ink: #E5ECE9; --muted: #98A6A2;
    --line: #2E3937; --accent: #86AEE6; --accent-ink: #0B1729; --accent-soft: #1D2B40;
    --ok: #5EC48C; --warn: #E3AA48; --bad: #F2766B; --shade: rgba(0, 0, 0, .62);
    --grid-major: #56635F; --grid-minor: #313B39; color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #111615; --surface: #19201F; --surface-2: #212A28; --ink: #E5ECE9; --muted: #98A6A2;
  --line: #2E3937; --accent: #86AEE6; --accent-ink: #0B1729; --accent-soft: #1D2B40;
  --ok: #5EC48C; --warn: #E3AA48; --bad: #F2766B; --shade: rgba(0, 0, 0, .62);
  --grid-major: #56635F; --grid-minor: #313B39; color-scheme: dark;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { background: var(--bg); color: var(--ink); font: 15px/1.5 var(--f-body); }
body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 10; background: var(--surface); }
button, input, select { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
h1, h2, h3 { font-family: var(--f-display); font-stretch: 85%; line-height: 1.15; margin: 0; text-wrap: balance; }
.wrap { padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); max-width: 1440px; margin: 0 auto; }
.muted { color: var(--muted); }
.mono { font-family: var(--f-mono); font-variant-numeric: tabular-nums; }
.eyebrow { font-family: var(--f-mono); font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); margin: 0; }

/* Kopfleiste */
.top { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 5; background: var(--surface); border-bottom: 1px solid var(--line); }
.top .wrap { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 20px; padding-block: 12px; }
.brand { display: flex; align-items: baseline; gap: 6px; text-decoration: none; color: var(--ink); }
.brand b { font-family: var(--f-display); font-stretch: 75%; font-weight: 800; font-size: 26px; letter-spacing: -.01em; }
.brand span { font-family: var(--f-mono); font-size: 12px; color: var(--accent); font-weight: 500; }
.search { flex: 1 1 320px; min-width: 0; position: relative; }
.search input { width: 100%; height: 42px; padding: 0 14px 0 40px; border: 1px solid var(--line); border-radius: 8px; background: var(--bg); }
.search svg { position: absolute; left: 13px; top: 12px; width: 18px; height: 18px; stroke: var(--muted); }
.tabs { display: flex; gap: 4px; }
.tabs a { padding: 8px 12px; border-radius: 6px; color: var(--muted); text-decoration: none; font-weight: 500; }
.tabs a[aria-current="page"] { background: var(--accent-soft); color: var(--accent); }
.quota { font-family: var(--f-mono); font-size: 13px; padding: 6px 10px; border: 1px solid var(--line); border-radius: 999px; white-space: nowrap; }
.quota.pro { border-color: var(--accent); color: var(--accent); }
.quota.empty { border-color: var(--bad); color: var(--bad); }

.note { font-size: 13px; color: var(--muted); padding-block: 10px; border-bottom: 1px dashed var(--line); }

/* Katalog */
.catalog { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 28px; padding-block: 24px 48px; }
.filters { display: flex; flex-direction: column; gap: 22px; align-self: start; position: sticky; top: calc(env(safe-area-inset-top, 0px) + 84px); }
.filters summary { display: none; }
.fgroup { display: flex; flex-direction: column; gap: 6px; }
.fgroup h3 { font-size: 13px; font-family: var(--f-mono); font-stretch: 100%; font-weight: 500; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); margin-bottom: 2px; }
.fopt { display: flex; align-items: center; gap: 8px; cursor: pointer; }
.fopt input { accent-color: var(--accent); width: 16px; height: 16px; }
.fopt .n { margin-left: auto; font-family: var(--f-mono); font-size: 12px; color: var(--muted); }
.linkbtn { background: none; border: 0; padding: 0; color: var(--accent); cursor: pointer; text-align: left; text-decoration: underline; text-underline-offset: 3px; }

.toolbar { display: flex; flex-wrap: wrap; gap: 10px 16px; align-items: center; margin-bottom: 8px; }
.toolbar .count { font-family: var(--f-display); font-stretch: 85%; font-size: 22px; font-weight: 700; margin-right: auto; }
.field { display: flex; align-items: center; gap: 8px; font-size: 14px; color: var(--muted); }
select { height: 38px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); padding: 0 10px; color: var(--ink); }
.expand { font-size: 13px; color: var(--muted); margin: 0 0 16px; min-height: 20px; }
.expand b { color: var(--ink); font-weight: 500; }

.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 16px; }
.card { position: relative; background: var(--surface); border: 1px solid var(--line); border-radius: 10px; overflow: hidden; display: flex; flex-direction: column; transition: border-color .15s, transform .15s; }
.card:hover { border-color: var(--accent); transform: translateY(-2px); }
.card:focus-within { border-color: var(--accent); }
.thumb { aspect-ratio: 4 / 3; max-width: 100%; background: linear-gradient(180deg, var(--surface-2), var(--surface) 92%); display: grid; place-items: center; }
.thumb img { width: 100%; height: 100%; object-fit: contain; }
.thumb .ph { font-family: var(--f-mono); font-size: 12px; color: var(--muted); }
.card-body { padding: 12px 14px 14px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.card-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.maker { font-size: 13px; color: var(--muted); }
.card h3 { font-size: 19px; font-weight: 700; }
.card-link { all: unset; cursor: pointer; }
.card-link::after { content: ""; position: absolute; inset: 0; }
.card-link:focus-visible { outline: none; }
.dims { font-family: var(--f-mono); font-size: 13px; margin: 0; }
.fmts { display: flex; flex-wrap: wrap; gap: 4px; margin-top: auto; padding-top: 4px; }
.fmts span { font-family: var(--f-mono); font-size: 11px; padding: 1px 6px; border: 1px solid var(--line); border-radius: 4px; color: var(--muted); }
.fmts span.hit { border-color: var(--accent); color: var(--accent); }
.badge { font-size: 12px; font-weight: 600; padding: 2px 8px; border-radius: 999px; white-space: nowrap; }
.badge.ok { color: var(--ok); background: color-mix(in srgb, var(--ok) 14%, transparent); }
.badge.warn { color: var(--warn); background: color-mix(in srgb, var(--warn) 16%, transparent); }
.empty-state { padding: 48px 16px; text-align: center; color: var(--muted); grid-column: 1 / -1; }

/* Modale */
.modal { position: fixed; inset: 0; z-index: 20; background: var(--shade); display: grid; place-items: center; padding: max(16px, env(safe-area-inset-top, 0px)) max(16px, env(safe-area-inset-right, 0px)) max(16px, env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px)); }
.sheet { position: relative; background: var(--surface); border-radius: 12px; width: min(1100px, 100%); max-height: 100%; overflow: auto; display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); }
.close { position: absolute; top: 10px; right: 10px; z-index: 2; width: 38px; height: 38px; border-radius: 50%; border: 1px solid var(--line); background: var(--surface); cursor: pointer; font-size: 20px; line-height: 1; }
.d-view { position: relative; background: linear-gradient(180deg, var(--surface-2), var(--surface)); min-height: 420px; }
.viewer { position: absolute; inset: 0; }
.viewer canvas { display: block; width: 100%; height: 100%; touch-action: none; cursor: grab; }
.viewer-note { position: absolute; left: 12px; bottom: 10px; font-family: var(--f-mono); font-size: 12px; color: var(--muted); pointer-events: none; }
.d-info { padding: 26px 26px 24px; display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.d-info h2 { font-size: 32px; font-weight: 800; padding-right: 36px; }
.d-info h3 { font-size: 15px; font-family: var(--f-mono); font-stretch: 100%; font-weight: 500; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.specs { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; margin: 0; border: 1px solid var(--line); border-radius: 8px; }
.specs div { padding: 8px 10px; border-left: 1px solid var(--line); }
.specs div:first-child { border-left: 0; }
.specs dt { font-size: 12px; color: var(--muted); }
.specs dd { margin: 0; font-family: var(--f-mono); font-size: 15px; font-variant-numeric: tabular-nums; }
.checks { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.chk { display: grid; grid-template-columns: 22px minmax(0, 1fr); gap: 8px; font-size: 14px; }
.chk .ico { width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center; font-size: 12px; font-weight: 700; color: var(--surface); margin-top: 1px; }
.chk.ok .ico { background: var(--ok); }
.chk.warn .ico { background: var(--warn); }
.chk.bad .ico { background: var(--bad); }
.chk strong { font-weight: 600; margin-right: 6px; }
.chk .fix { margin-top: 6px; }
.compat { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px 16px; font-size: 14px; }
.compat li { display: flex; justify-content: space-between; gap: 8px; border-bottom: 1px dotted var(--line); padding: 3px 0; }
.compat li.no { color: var(--muted); }
.compat .mono { font-size: 12px; }
.dl-box { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; padding-top: 14px; border-top: 1px solid var(--line); margin-top: auto; }
.dl-box p { flex-basis: 100%; margin: 0; font-size: 13px; }
.btn { height: 40px; padding: 0 16px; border-radius: 8px; border: 1px solid var(--line); background: var(--surface); cursor: pointer; font-weight: 600; }
.btn.primary { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.btn.small { height: 32px; padding: 0 12px; font-size: 13px; }
.btn:disabled { opacity: .45; cursor: not-allowed; }

.paywall { width: min(760px, 100%); display: block; padding: 28px; }
.paywall h2 { font-size: 30px; font-weight: 800; padding-right: 40px; }
.paywall > p { max-width: 60ch; }
.plans { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin: 18px 0; }
.plan { border: 1px solid var(--line); border-radius: 10px; padding: 16px; display: flex; flex-direction: column; gap: 6px; }
.plan.hl { border: 2px solid var(--accent); }
.plan .price { font-family: var(--f-display); font-stretch: 85%; font-size: 30px; font-weight: 800; }
.plan .price small { font-family: var(--f-body); font-size: 14px; font-weight: 400; color: var(--muted); }
.plan ul { margin: 0; padding-left: 18px; font-size: 14px; color: var(--muted); flex: 1; }
.plan .btn { margin-top: 8px; }

/* Hochladen */
.upload { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); gap: 28px; padding-block: 28px 48px; }
.up-left { display: flex; flex-direction: column; gap: 16px; }
.up-left h2 { font-size: 34px; font-weight: 800; }
.up-left > p { margin: 0; max-width: 60ch; }
.drop { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 28px 16px; border: 2px dashed var(--line); border-radius: 10px; background: var(--surface); text-align: center; cursor: pointer; }
.drop.over { border-color: var(--accent); background: var(--accent-soft); }
.drop input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.drop span { font-size: 13px; color: var(--muted); }
.examples { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; font-size: 14px; color: var(--muted); }
form.meta { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 16px; }
form.meta label { display: flex; flex-direction: column; gap: 4px; font-size: 13px; color: var(--muted); min-width: 0; }
form.meta .full { grid-column: 1 / -1; }
form.meta input, form.meta select { height: 38px; border: 1px solid var(--line); border-radius: 8px; background: var(--bg); padding: 0 10px; color: var(--ink); width: 100%; }
.up-right { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.viewer-wrap { position: relative; aspect-ratio: 4 / 3; max-width: 100%; border-radius: 10px; border: 1px solid var(--line); background: linear-gradient(180deg, var(--surface-2), var(--surface)); overflow: hidden; }
.viewer-empty { position: absolute; inset: 0; display: grid; place-items: center; margin: 0; color: var(--muted); font-family: var(--f-mono); font-size: 13px; }
.verdict { padding: 12px 14px; border-radius: 8px; font-weight: 600; margin-bottom: 12px; }
.verdict.ok { color: var(--ok); background: color-mix(in srgb, var(--ok) 12%, transparent); }
.verdict.bad { color: var(--bad); background: color-mix(in srgb, var(--bad) 10%, transparent); }
.up-err { color: var(--bad); font-size: 14px; margin: 0; }
.bonus { margin: 0; padding: 12px 14px; border-radius: 8px; background: var(--accent-soft); color: var(--ink); font-size: 14px; max-width: 60ch; }
.bonus b { color: var(--accent); }

.toast { position: fixed; left: 50%; bottom: calc(20px + env(safe-area-inset-bottom, 0px)); transform: translateX(-50%); z-index: 30; background: var(--ink); color: var(--bg); padding: 12px 16px; border-radius: 8px; max-width: min(560px, calc(100% - 32px)); font-size: 14px; box-shadow: 0 6px 24px rgba(0,0,0,.25); }
footer .wrap { padding-block: 20px 32px; border-top: 1px solid var(--line); display: flex; flex-wrap: wrap; gap: 8px 20px; font-size: 13px; color: var(--muted); }

@media (max-width: 860px) {
  .catalog { grid-template-columns: minmax(0, 1fr); gap: 12px; padding-top: 16px; }
  .filters { position: static; display: block; background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 0 14px; }
  .filters summary { display: block; padding: 12px 0; cursor: pointer; font-weight: 600; }
  .filters .fbody { display: flex; flex-direction: column; gap: 18px; padding-bottom: 16px; }
  .sheet { grid-template-columns: minmax(0, 1fr); }
  .d-view { min-height: 300px; }
  .upload { grid-template-columns: minmax(0, 1fr); }
  .plans { grid-template-columns: minmax(0, 1fr); }
}
@media (min-width: 861px) { .filters .fbody { display: flex; flex-direction: column; gap: 22px; } }
@media (max-width: 520px) {
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .card h3 { font-size: 16px; }
  .card-body { padding: 10px; }
  .fmts { display: none; }
  .specs { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .specs div:nth-child(3) { border-left: 0; }
  .specs div:nth-child(n+3) { border-top: 1px solid var(--line); }
  .compat { grid-template-columns: minmax(0, 1fr); }
  form.meta { grid-template-columns: minmax(0, 1fr); }
  .d-info { padding: 20px 16px; }
  .d-info h2 { font-size: 26px; }
}
@media (prefers-reduced-motion: reduce) { .card { transition: none; } .card:hover { transform: none; } }

/* ---------- Ergänzungen für die echte Version ---------- */
.badge.bad { color: var(--bad); background: color-mix(in srgb, var(--bad) 12%, transparent); }
.empty-state a, .admin-msg a { color: var(--accent); }
form.meta .extras { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; }
form.meta .extras > label.btn { display: inline-flex; flex-direction: row; align-items: center; color: var(--ink); font-size: 13px; cursor: pointer; }
form.meta .extras input[type=file], .drop input { position: absolute; width: 1px; height: 1px; opacity: 0; }
form.meta .extras .muted { font-size: 12px; }
.files { list-style: none; margin: 0; padding: 0; flex-basis: 100%; display: flex; flex-direction: column; gap: 4px; }
.files li { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; font-size: 14px; padding: 6px 0; border-bottom: 1px dotted var(--line); }
.files .mono { font-size: 12px; padding: 1px 6px; border: 1px solid var(--accent); color: var(--accent); border-radius: 4px; }
.files .fname { min-width: 0; overflow-wrap: anywhere; flex: 1; }
form.meta .check-label { flex-direction: row; color: var(--ink); font-size: 14px; }
form.meta .check-label input { width: 16px; height: 16px; accent-color: var(--accent); margin: 0 6px 0 0; vertical-align: -2px; }
.up-status { margin: 0; font-size: 14px; color: var(--muted); }
.up-status.bad { color: var(--bad); }
.mine { display: flex; flex-direction: column; gap: 8px; }
.mine h3 { font-size: 20px; font-weight: 700; }
.mine ul { list-style: none; margin: 0; padding: 0; }
.mine li { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; padding: 8px 0; border-bottom: 1px solid var(--line); }
.mine li > span:first-child { flex: 1; min-width: 0; }
.mine small { flex-basis: 100%; }
.l-msg { margin: 0; font-size: 14px; color: var(--bad); }
.l-msg.ok { color: var(--ok); }
.login-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 18px; }
.small { font-size: 13px; }

/* Einführung und Über-Seite */
.intro { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 24px 48px; align-items: start; padding-block: 32px 4px; }
.intro h1 { font-size: clamp(30px, 4.2vw, 44px); font-weight: 800; margin: 6px 0 12px; }
.intro-text > p:not(.eyebrow) { margin: 0; max-width: 60ch; font-size: 16px; }
.intro-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; margin-top: 18px; }
.intro-points { list-style: none; margin: 0; padding: 0; background: var(--surface); border: 1px solid var(--line); border-radius: 10px; }
.intro-points li { display: flex; flex-direction: column; gap: 2px; padding: 14px 16px; border-top: 1px solid var(--line); font-size: 14px; }
.intro-points li:first-child { border-top: 0; }
.intro-points b { font-family: var(--f-display); font-stretch: 85%; font-size: 18px; font-weight: 700; }
.intro-points span { color: var(--muted); }
.about { max-width: 70ch; padding-block: 32px 56px; display: flex; flex-direction: column; gap: 14px; }
.about h2 { font-size: clamp(30px, 4.2vw, 42px); font-weight: 800; }
.about h3 { font-size: 22px; font-weight: 700; margin-top: 16px; }
.about p, .about li, .about dd { font-size: 16px; line-height: 1.65; }
.about p { margin: 0; }
.about .lead { font-size: 19px; line-height: 1.55; }
.about .plain, .about .steps { margin: 0; padding-left: 1.4em; display: flex; flex-direction: column; gap: 6px; }
.about .steps li::marker { font-family: var(--f-mono); color: var(--accent); }
.defs { margin: 0; display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 8px 20px; }
.defs dt { font-weight: 600; font-size: 16px; line-height: 1.65; }
.defs dd { margin: 0; color: var(--muted); }
.programs { font-family: var(--f-mono); font-size: 14px !important; color: var(--muted); }
.about-cta { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; }
footer a { color: var(--muted); }
@media (max-width: 860px) {
  .intro { grid-template-columns: minmax(0, 1fr); padding-top: 24px; }
}
@media (max-width: 520px) {
  .defs { grid-template-columns: minmax(0, 1fr); gap: 0 0; }
  .defs dd { margin-bottom: 10px; }
}

/* Rechtliche Seiten */
.entwurf { font-family: var(--f-mono); font-size: 13px !important; color: var(--warn); border: 1px dashed var(--warn); border-radius: 6px; padding: 6px 10px; align-self: flex-start; }
mark.fehlt { background: color-mix(in srgb, var(--warn) 22%, transparent); color: var(--ink); padding: 0 3px; border-radius: 3px; }
.legal a, .check-label a, #report a { color: var(--accent); }

/* Meldungen */
form.meta textarea { min-height: 96px; border: 1px solid var(--line); border-radius: 8px; background: var(--bg); padding: 8px 10px; color: var(--ink); width: 100%; font: inherit; resize: vertical; }
.report-link { font-size: 13px; color: var(--muted); }
.reports { display: flex; flex-direction: column; gap: 10px; margin-bottom: 24px; }
.reports h2 { font-size: 22px; font-weight: 800; }
.report { background: var(--surface); border: 1px solid color-mix(in srgb, var(--warn) 50%, var(--line)); border-radius: 10px; padding: 14px 16px; display: flex; flex-direction: column; gap: 6px; }
.report p { margin: 0; }
.report .msg { white-space: pre-wrap; overflow-wrap: anywhere; }

/* Mein Konto */
.konto { padding-block: 28px 48px; display: flex; flex-direction: column; gap: 24px; }
.konto-head { display: flex; flex-wrap: wrap; gap: 16px; justify-content: space-between; align-items: flex-end; }
.konto-head h2 { font-size: 32px; font-weight: 800; overflow-wrap: anywhere; }
.konto-head p { margin: 4px 0 0; }
.konto-actions { display: flex; gap: 10px; flex-wrap: wrap; }
a.btn { display: inline-flex; align-items: center; text-decoration: none; color: var(--ink); }
.konto-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 16px; align-items: start; }
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 18px; display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.panel h3 { font-size: 20px; font-weight: 700; }
.panel p { margin: 0; font-size: 14px; color: var(--muted); }
.panel label { display: flex; flex-direction: column; gap: 4px; font-size: 13px; color: var(--muted); }
.panel input, .panel select { height: 38px; border: 1px solid var(--line); border-radius: 8px; background: var(--bg); padding: 0 10px; color: var(--ink); width: 100%; }
.stack { display: flex; flex-direction: column; gap: 12px; align-items: flex-start; }
.stack label { align-self: stretch; }
.liste { list-style: none; margin: 0; padding: 0; max-height: 320px; overflow: auto; }
.liste li { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; padding: 8px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.liste li > span:first-child { flex: 1; min-width: 0; }
.liste small { flex-basis: 100%; }
.liste .mono { font-size: 12px; }
.panel.danger { border-color: color-mix(in srgb, var(--bad) 45%, var(--line)); }
.danger-btn { background: var(--bad); border-color: var(--bad); color: var(--surface); align-self: flex-start; }
#acct.active { border-color: var(--accent); color: var(--accent); }
.import-box { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 16px 18px; display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; margin-bottom: 20px; }
.import-box p { margin: 0; flex: 1 1 300px; font-size: 14px; }
.import-log { flex-basis: 100%; margin: 0; font-size: 13px; color: var(--muted); }

.admin { padding-block: 24px 48px; display: flex; flex-direction: column; gap: 20px; }
.admin-msg { font-size: 16px; }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 0; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); margin-bottom: 20px; }
.stats div { display: flex; flex-direction: column; padding: 14px 16px; border-left: 1px solid var(--line); }
.stats div:first-child { border-left: 0; }
.stat-v { font-family: var(--f-display); font-stretch: 85%; font-size: 30px; font-weight: 800; font-variant-numeric: tabular-nums; }
.stat-k { font-size: 13px; color: var(--muted); }
.review-list { display: flex; flex-direction: column; gap: 16px; }
.review { display: grid; grid-template-columns: 260px minmax(0, 1fr); background: var(--surface); border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.review .thumb { aspect-ratio: auto; min-height: 200px; }
.review-body { padding: 16px 18px; display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.review-body h3 { font-size: 22px; font-weight: 800; }
.review-body p { margin: 0; }
.file-row { display: flex; flex-wrap: wrap; gap: 8px; }
.note-field { display: flex; flex-direction: column; gap: 4px; font-size: 13px; color: var(--muted); }
.note-field input { height: 38px; border: 1px solid var(--line); border-radius: 8px; background: var(--bg); padding: 0 10px; }
.sheet.single { grid-template-columns: minmax(0, 1fr); width: min(900px, 100%); }
.sheet.single .d-view { min-height: min(70vh, 600px); }
@media (max-width: 700px) {
  .review { grid-template-columns: minmax(0, 1fr); }
  .stats div { border-left: 0; border-top: 1px solid var(--line); }
}
