/* Werkbank – Oberfläche */
/* Schriften – liegen selbst gehostet in assets/fonts/ (keine Verbindung zu Google) */
@font-face {
  font-family: "Schibsted Grotesk"; font-style: normal; font-weight: 400 900; font-display: swap;
  src: url("fonts/SchibstedGrotesk.woff") format("woff"), url("fonts/SchibstedGrotesk-VariableFont_wght.ttf") format("truetype");
}
@font-face {
  font-family: "Martian Mono"; font-style: normal; font-weight: 100 800; font-display: swap;
  src: url("fonts/MartianMono.woff") format("woff"), url("fonts/MartianMono-VariableFont_wdth,wght.ttf") format("truetype");
}

:root {
  --font: "Schibsted Grotesk", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "Martian Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  --bg: #efe9dd;
  --dot: rgba(70, 50, 25, .16);
  --ink: #1b1a17;
  --ink2: #57534a;
  --ink3: #8a857a;
  --card: #fffdf8;
  --soft: #f6f1e6;
  --line: #d9d0bd;
  --edge: #1b1a17;
  --accent: #ff5a36;
  --accent-ink: #fff;
  --ok: #2f9e6b;
  --danger: #d6402b;
  --head-mix: 100%;
  --icon-bg: rgba(255, 255, 255, .92);
  --radius: 16px;
  --shadow: 3px 3px 0 var(--edge);
  --shadow-hi: 6px 6px 0 var(--edge);
  color-scheme: light;
}
:root[data-theme="dark"] {
  --bg: #15161a; --dot: rgba(255, 255, 255, .075); --ink: #f2eee6; --ink2: #b9b3a7; --ink3: #7e796f;
  --card: #1f2126; --soft: #262930; --line: #363941; --edge: #000; --accent: #ff6b4a;
  --head-mix: 78%; --icon-bg: rgba(20, 21, 26, .55);
  --shadow: 3px 3px 0 #000; --shadow-hi: 6px 6px 0 #000;
  color-scheme: dark;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #15161a; --dot: rgba(255, 255, 255, .075); --ink: #f2eee6; --ink2: #b9b3a7; --ink3: #7e796f;
    --card: #1f2126; --soft: #262930; --line: #363941; --edge: #000; --accent: #ff6b4a;
    --head-mix: 78%; --icon-bg: rgba(20, 21, 26, .55);
    --shadow: 3px 3px 0 #000; --shadow-hi: 6px 6px 0 #000;
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; min-height: 100vh; font-family: var(--font); color: var(--ink); font-size: 15px; line-height: 1.45;
  background-color: var(--bg);
  background-image: radial-gradient(circle at center, var(--dot) 2.2px, transparent 2.7px);
  background-size: 26px 26px; background-attachment: fixed;
}
button, input, select, textarea { font: inherit; color: inherit; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
[hidden] { display: none !important; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- Marke ---------- */
.brand { display: flex; align-items: center; gap: 12px; font-weight: 900; letter-spacing: -.02em; font-size: 26px; line-height: 1; }
.brand-big { font-size: 34px; }
.brand-mark { width: 34px; height: 34px; border-radius: 10px; background: var(--accent); display: grid; grid-template-columns: 1fr 1fr; place-items: center; padding: 7px; border: 2px solid var(--edge); box-shadow: 2px 2px 0 var(--edge); flex: none; }
.brand-big .brand-mark { width: 42px; height: 42px; padding: 9px; }
.brand-mark i { width: 6px; height: 6px; border-radius: 50%; background: var(--bg); display: block; }

/* ---------- Knöpfe & Felder ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 42px; padding: 0 16px;
  border: 2px solid var(--edge); border-radius: 12px; background: var(--card); color: var(--ink); font-weight: 700; cursor: pointer;
  box-shadow: 2px 2px 0 var(--edge); transition: transform .12s, box-shadow .12s; text-decoration: none; white-space: nowrap;
}
.btn:hover { transform: translate(-1px, -1px); box-shadow: 3px 3px 0 var(--edge); }
.btn:active { transform: translate(1px, 1px); box-shadow: 0 0 0 var(--edge); }
.btn-primary { background: var(--accent); color: var(--accent-ink); }
.btn-danger { color: var(--danger); }
.btn-small { min-height: 34px; padding: 0 11px; font-size: 13px; border-radius: 10px; }
.btn-wide { width: 100%; }
.btn-icon { width: 42px; padding: 0; }
.btn svg { width: 18px; height: 18px; flex: none; }
.btn[disabled] { opacity: .5; pointer-events: none; }
.linkbtn { background: none; border: 0; padding: 0; color: var(--ink2); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; font-weight: 600; }

.field { display: grid; gap: 6px; margin: 0 0 14px; align-content: start; }
.field > span { font-weight: 700; font-size: 13px; color: var(--ink2); }
.field small { color: var(--ink3); font-size: 12px; }
input[type=text], input[type=password], input[type=search], input:not([type]), select, textarea {
  width: 100%; min-height: 44px; padding: 9px 12px; border: 2px solid var(--line); border-radius: 12px; background: var(--card); outline: none;
}
textarea { min-height: 96px; resize: vertical; line-height: 1.45; }
input:focus, select:focus, textarea:focus { border-color: var(--edge); }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.grow { flex: 1 1 auto; min-width: 0; }

/* ---------- Anmeldeseite ---------- */
body.gate { display: grid; place-items: center; padding: 24px; }
.gate-card { width: min(420px, 100%); background: var(--card); border: 2px solid var(--edge); border-radius: 22px; padding: 30px 28px 26px; box-shadow: var(--shadow-hi); }
.gate-card .brand { margin-bottom: 22px; }
.gate-lead { margin: 0 0 18px; color: var(--ink2); }
.gate-error { color: var(--danger); font-weight: 700; margin: -4px 0 14px; }

/* ---------- Kopfbereich ---------- */
.top { position: sticky; top: 0; z-index: 20; backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  background: color-mix(in srgb, var(--bg) 82%, transparent); border-bottom: 2px solid var(--edge); }
.top-inner { max-width: 2400px; margin: 0 auto; padding: 14px clamp(14px, 3vw, 40px); display: flex; align-items: center; gap: 14px; }
.top .count { font-family: var(--mono); font-size: 12px; color: var(--ink3); font-weight: 400; letter-spacing: 0; margin-left: 2px; }
.top-actions { margin-left: auto; display: flex; gap: 8px; }

.wrap { max-width: 2400px; margin: 0 auto; padding: 22px clamp(14px, 3vw, 40px) 80px; }

/* ---------- Werkzeugleiste ---------- */
.bar { display: grid; gap: 14px; margin-bottom: 24px; }
.bar-row { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.search { position: relative; flex: 1 1 320px; max-width: 640px; }
.search input { min-height: 50px; padding-left: 46px; padding-right: 44px; font-size: 17px; font-weight: 600; border: 2px solid var(--edge); box-shadow: var(--shadow); border-radius: 14px; }
.search svg { position: absolute; left: 15px; top: 50%; translate: 0 -50%; width: 20px; height: 20px; color: var(--ink3); pointer-events: none; }
.search kbd { position: absolute; right: 12px; top: 50%; translate: 0 -50%; font-family: var(--mono); font-size: 11px; border: 1.5px solid var(--line); border-radius: 6px; padding: 2px 7px; color: var(--ink3); background: var(--soft); }
.search input:focus + kbd, .search input:not(:placeholder-shown) + kbd { display: none; }

.sort { display: flex; align-items: center; gap: 0; border: 2px solid var(--edge); border-radius: 14px; background: var(--card); box-shadow: var(--shadow); overflow: hidden; min-height: 50px; }
.sort button { border: 0; background: none; padding: 0 14px; min-height: 46px; font-weight: 700; font-size: 14px; color: var(--ink2); cursor: pointer; border-right: 1.5px solid var(--line); }
.sort button:last-child { border-right: 0; }
.sort button[aria-pressed="true"] { background: var(--ink); color: var(--bg); }
.sort .dir { font-family: var(--mono); width: 48px; padding: 0; font-size: 16px; color: var(--ink); }
.sort select { display: none; border: 0; min-height: 46px; background: none; font-weight: 700; padding-left: 12px; }

.chips { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.chips-label { font-family: var(--mono); font-size: 11px; text-transform: uppercase; letter-spacing: .08em; color: var(--ink3); margin-right: 4px; }
.chip { display: inline-flex; align-items: center; gap: 7px; min-height: 36px; padding: 0 14px; border-radius: 999px; border: 2px solid var(--edge); background: var(--card);
  font-weight: 700; font-size: 14px; cursor: pointer; transition: transform .1s; }
.chip:hover { transform: translateY(-1px); }
.chip b { font-family: var(--mono); font-weight: 400; font-size: 11px; color: var(--ink3); }
.chip[aria-pressed="true"] { background: var(--ink); color: var(--bg); }
.chip[aria-pressed="true"] b { color: color-mix(in srgb, var(--bg) 70%, transparent); }
.chip-tag { min-height: 30px; padding: 0 11px; font-size: 13px; border-width: 1.5px; border-color: var(--line); font-weight: 600; }
.chip-tag::before { content: "#"; font-family: var(--mono); color: var(--accent); font-weight: 600; }
.chip-tag[aria-pressed="true"] { border-color: var(--edge); }
.chip-tag[aria-pressed="true"]::before { color: var(--accent); }
.chips-more { display: none; }
.active-filters { font-size: 13px; color: var(--ink2); display: flex; gap: 10px; align-items: center; min-height: 20px; }

/* ---------- Kachelraster ---------- */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(258px, 1fr)); gap: 26px 22px; align-items: start; }
@media (min-width: 1800px) { .grid { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); } }

.tile {
  --c: #ff5a36;
  position: relative; display: flex; flex-direction: column; background: var(--card); border: 2px solid var(--edge); border-radius: var(--radius);
  box-shadow: var(--shadow); transform-origin: 50% 0; transition: transform .25s cubic-bezier(.3, 1.6, .5, 1), box-shadow .2s; min-height: 100%;
}
.tile:hover, .tile:focus-within { transform: translate(-2px, -2px) rotate(-.8deg); box-shadow: var(--shadow-hi); z-index: 2; }
.tile-head {
  position: relative; height: 92px; border-radius: calc(var(--radius) - 2px) calc(var(--radius) - 2px) 0 0; border-bottom: 2px solid var(--edge);
  background: color-mix(in srgb, var(--c) var(--head-mix), var(--card));
  background-image: repeating-linear-gradient(135deg, rgba(255,255,255,.10) 0 10px, transparent 10px 20px);
  display: flex; align-items: flex-end; padding: 0 16px; overflow: visible;
}
.tile-hole { position: absolute; top: 12px; left: 50%; translate: -50% 0; width: 16px; height: 16px; border-radius: 50%; background: var(--bg); border: 2px solid var(--edge); box-shadow: inset 1px 2px 0 rgba(0,0,0,.18); }
.tile-icon {
  width: 60px; height: 60px; border-radius: 16px; background: var(--icon-bg); border: 2px solid var(--edge); display: grid; place-items: center;
  font-size: 32px; line-height: 1; translate: 0 26px; box-shadow: 2px 2px 0 var(--edge); flex: none;
}
.tile-icon.letters { font-weight: 900; font-size: 22px; letter-spacing: -.03em; color: var(--ink); }
.tile-ver { position: absolute; right: 12px; top: 12px; font-family: var(--mono); font-size: 11px; font-weight: 600; background: var(--card); border: 1.5px solid var(--edge); border-radius: 7px; padding: 3px 7px; }
.tile-body { padding: 36px 16px 12px; display: grid; gap: 7px; flex: 1; align-content: start; }
.tile-cat { font-family: var(--mono); font-size: 10.5px; text-transform: uppercase; letter-spacing: .09em; color: var(--ink3); }
.tile-name { margin: 0; font-size: 19px; line-height: 1.18; font-weight: 800; letter-spacing: -.01em; overflow-wrap: anywhere; hyphens: auto; }
.tile-name a { text-decoration: none; }
.tile-name a::after { content: ""; position: absolute; inset: 0; border-radius: var(--radius); z-index: 1; }
.tile-desc { margin: 0; color: var(--ink2); font-size: 14px; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.tile-tags { display: flex; flex-wrap: wrap; gap: 5px 9px; font-size: 12.5px; font-weight: 600; color: var(--ink2); }
.tile-tags span::before { content: "#"; color: var(--accent); font-family: var(--mono); margin-right: 1px; }
.tile-tags button { position: relative; z-index: 3; border: 0; background: none; padding: 0; cursor: pointer; font: inherit; color: inherit; }
.tile-tags button:hover { text-decoration: underline; }
.tile-foot { display: flex; gap: 6px 12px; flex-wrap: wrap; padding: 10px 16px 13px; border-top: 1.5px dashed var(--line); font-family: var(--mono); font-size: 10.5px; color: var(--ink3); }
.tile-foot span { display: inline-flex; align-items: center; gap: 4px; white-space: nowrap; }
.tile-foot span.hot { color: var(--ink); font-weight: 600; }
.tile-foot svg { width: 12px; height: 12px; }
.tile-edit {
  position: absolute; z-index: 3; right: 10px; bottom: 10px; width: 36px; height: 36px; border-radius: 10px; border: 2px solid var(--edge);
  background: var(--card); display: grid; place-items: center; cursor: pointer; opacity: 0; transition: opacity .15s; box-shadow: 2px 2px 0 var(--edge);
}
.tile-edit svg { width: 17px; height: 17px; }
.tile:hover .tile-edit, .tile:focus-within .tile-edit { opacity: 1; }
@media (hover: none) { .tile-edit { opacity: 1; } }

.empty { text-align: center; padding: 70px 20px; border: 3px dashed var(--line); border-radius: 22px; background: color-mix(in srgb, var(--card) 70%, transparent); }
.empty h2 { font-size: 26px; margin: 0 0 8px; font-weight: 900; letter-spacing: -.02em; }
.empty p { color: var(--ink2); margin: 0 0 20px; }

/* ---------- Handy: Kacheln als Reihen ---------- */
@media (max-width: 620px) {
  body { font-size: 15px; background-size: 22px 22px; }
  .top-inner { padding: 10px 14px; gap: 10px; }
  .brand { font-size: 22px; }
  .brand-mark { width: 30px; height: 30px; padding: 6px; }
  .top .count { display: none; }
  .btn-label { display: none; }
  .wrap { padding: 16px 14px 70px; }
  .bar { gap: 12px; margin-bottom: 18px; }
  .search { flex-basis: 100%; }
  .search kbd { display: none; }
  .sort { width: 100%; }
  .sort button:not(.dir) { display: none; }
  .sort select { display: block; flex: 1; }
  .sort .dir { border-left: 1.5px solid var(--line); }
  .chips { flex-wrap: nowrap; overflow-x: auto; margin: 0 -14px; padding: 2px 14px 6px; scrollbar-width: none; }
  .chips::-webkit-scrollbar { display: none; }
  .chip { flex: none; }
  .grid { grid-template-columns: 1fr; gap: 12px; }
  .tile { display: grid; grid-template-columns: 74px 1fr; align-items: stretch; min-height: 0; }
  .tile:hover, .tile:focus-within { transform: none; box-shadow: var(--shadow); }
  .tile-head { width: 74px; height: auto; min-height: 86px; border-radius: calc(var(--radius) - 2px) 0 0 calc(var(--radius) - 2px); border-bottom: 0; border-right: 2px solid var(--edge); align-items: center; justify-content: center; padding: 0; grid-row: 1 / span 2; }
  .tile-hole, .tile-ver { display: none; }
  .tile-icon { translate: none; width: 48px; height: 48px; font-size: 26px; border-radius: 13px; }
  .tile-icon.letters { font-size: 18px; }
  .tile-body { padding: 11px 50px 6px 13px; gap: 4px; min-width: 0; }
  .tile-name { font-size: 17px; }
  .tile-name small { font-family: var(--mono); font-size: 10.5px; font-weight: 600; color: var(--ink3); margin-left: 4px; white-space: nowrap; }
  .tile-desc { -webkit-line-clamp: 2; font-size: 13.5px; }
  .tile-foot { grid-column: 2; padding: 7px 13px 9px; border-top: 0; }
  .tile-edit { top: 10px; bottom: auto; width: 34px; height: 34px; }
}
@media (min-width: 621px) { .tile-name small { display: none; } }

/* ---------- Dialoge ---------- */
dialog { border: 0; padding: 0; background: transparent; color: var(--ink); max-width: none; max-height: none; }
dialog::backdrop { background: rgba(15, 12, 8, .45); backdrop-filter: blur(3px); }
.sheet {
  position: fixed; top: 0; right: 0; bottom: 0; width: min(600px, 100vw); background: var(--card); border-left: 2px solid var(--edge);
  display: flex; flex-direction: column; animation: slidein .22s ease-out;
}
.modal {
  width: min(760px, calc(100vw - 24px)); max-height: calc(100vh - 40px); margin: 20px auto; background: var(--card); border: 2px solid var(--edge);
  border-radius: 20px; box-shadow: var(--shadow-hi); display: flex; flex-direction: column; animation: pop .18s ease-out;
}
dialog.is-modal { position: fixed; inset: 0; width: 100vw; height: 100vh; display: flex; align-items: flex-start; justify-content: center; }
dialog:not([open]) { display: none; }
@keyframes slidein { from { transform: translateX(40px); opacity: 0; } }
@keyframes pop { from { transform: scale(.97); opacity: 0; } }
.dlg-head { display: flex; align-items: center; gap: 12px; padding: 16px 18px; border-bottom: 2px solid var(--edge); }
.dlg-head h2 { margin: 0; font-size: 21px; font-weight: 900; letter-spacing: -.015em; flex: 1; min-width: 0; overflow-wrap: anywhere; }
.dlg-head .tile-icon { translate: none; width: 44px; height: 44px; font-size: 24px; border-radius: 12px; background: color-mix(in srgb, var(--c) var(--head-mix), var(--card)); }
.dlg-body { padding: 18px; overflow: auto; flex: 1; }
.dlg-foot { display: flex; gap: 10px; padding: 14px 18px; border-top: 2px solid var(--edge); flex-wrap: wrap; align-items: center; }
.dlg-foot .spacer { flex: 1; }
.tabs { display: flex; gap: 0; padding: 0 18px; border-bottom: 2px solid var(--edge); background: var(--soft); }
.tabs button { border: 0; background: none; padding: 12px 14px 10px; font-weight: 800; color: var(--ink3); cursor: pointer; border-bottom: 4px solid transparent; margin-bottom: -2px; }
.tabs button[aria-selected="true"] { color: var(--ink); border-bottom-color: var(--accent); }
@media (max-width: 620px) {
  .sheet { width: 100vw; border-left: 0; }
  .modal { width: 100vw; max-height: 100vh; height: 100vh; margin: 0; border-radius: 0; border: 0; }
}

.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 14px; }
@media (max-width: 520px) { .grid2 { grid-template-columns: 1fr; } }

.swatches { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.swatch { width: 32px; height: 32px; border-radius: 10px; border: 2px solid var(--edge); cursor: pointer; padding: 0; position: relative; }
.swatch[aria-pressed="true"]::after { content: ""; position: absolute; inset: 7px; border-radius: 50%; background: #fff; border: 2px solid var(--edge); }
.swatch-custom { width: 32px; height: 32px; padding: 0; border: 2px dashed var(--line); border-radius: 10px; background: none; cursor: pointer; overflow: hidden; }
.emojis { display: grid; grid-template-columns: repeat(auto-fill, minmax(38px, 1fr)); gap: 4px; margin-top: 8px; max-height: 172px; overflow: auto; padding: 6px; border: 2px solid var(--line); border-radius: 12px; background: var(--soft); }
.emojis button { height: 38px; border: 0; border-radius: 9px; background: none; font-size: 22px; cursor: pointer; }
.emojis button:hover { background: var(--card); }
.emojis button[aria-pressed="true"] { background: var(--card); outline: 2px solid var(--edge); }

.taginput { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; min-height: 44px; padding: 5px 8px; border: 2px solid var(--line); border-radius: 12px; background: var(--card); cursor: text; }
.taginput:focus-within { border-color: var(--edge); }
.taginput input { flex: 1 1 120px; border: 0 !important; min-height: 30px !important; padding: 2px 4px !important; background: none; }
.taginput .t { display: inline-flex; align-items: center; gap: 4px; background: var(--soft); border: 1.5px solid var(--line); border-radius: 999px; padding: 2px 4px 2px 10px; font-size: 13px; font-weight: 700; }
.taginput .t::before { content: "#"; color: var(--accent); font-family: var(--mono); }
.taginput .t button { border: 0; background: none; cursor: pointer; width: 20px; height: 20px; border-radius: 50%; font-size: 14px; line-height: 1; color: var(--ink3); }
.taginput .t button:hover { background: var(--line); color: var(--ink); }
.suggest { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.suggest button { border: 1.5px dashed var(--line); background: none; border-radius: 999px; padding: 3px 10px; font-size: 12.5px; font-weight: 600; cursor: pointer; color: var(--ink2); }
.suggest button:hover { border-style: solid; color: var(--ink); }

.list { display: grid; gap: 8px; }
.item { display: flex; gap: 12px; align-items: center; padding: 11px 12px; border: 2px solid var(--line); border-radius: 13px; background: var(--card); flex-wrap: wrap; }
.item.current { border-color: var(--edge); background: var(--soft); }
.item .meta { font-family: var(--mono); font-size: 11px; color: var(--ink3); }
.item .name { font-weight: 800; }
.pill { font-family: var(--mono); font-size: 10.5px; font-weight: 600; border: 1.5px solid var(--edge); border-radius: 6px; padding: 2px 6px; background: var(--accent); color: var(--accent-ink); }
.pill-new { background: var(--ok); }
.pill-up { background: #3b8fd9; }
.note { font-size: 13px; color: var(--ink2); background: var(--soft); border: 1.5px solid var(--line); border-radius: 12px; padding: 10px 12px; margin: 0 0 14px; }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 10px; margin-bottom: 16px; }
.stat { border: 2px solid var(--line); border-radius: 13px; padding: 10px 12px; }
.stat b { display: block; font-size: 20px; font-weight: 900; }
.stat span { font-family: var(--mono); font-size: 10.5px; color: var(--ink3); text-transform: uppercase; letter-spacing: .06em; }
h3.sec { font-size: 13px; font-family: var(--mono); text-transform: uppercase; letter-spacing: .08em; color: var(--ink3); margin: 22px 0 10px; font-weight: 600; }
h3.sec:first-child { margin-top: 0; }
.toggle { display: flex; align-items: center; gap: 10px; font-weight: 700; cursor: pointer; margin-bottom: 14px; }
.toggle input { width: 20px; height: 20px; accent-color: var(--accent); }
.mono { font-family: var(--mono); font-size: 12px; }
.muted { color: var(--ink3); }
.err { color: var(--danger); font-weight: 700; }

/* Häkchen-Listen (Freigaben) */
.checks { display: flex; flex-wrap: wrap; gap: 8px; }
.checks-col { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 6px; max-height: 360px; overflow: auto; padding: 8px; border: 2px solid var(--line); border-radius: 12px; background: var(--soft); }
.check { display: inline-flex; align-items: center; gap: 8px; padding: 7px 12px 7px 9px; border: 2px solid var(--line); border-radius: 11px; background: var(--card); font-weight: 700; font-size: 14px; cursor: pointer; }
.check:has(input:checked) { border-color: var(--edge); box-shadow: 2px 2px 0 var(--edge); }
.check input { width: 18px; height: 18px; accent-color: var(--accent); margin: 0; flex: none; }
.ck-ico { width: 26px; height: 26px; border-radius: 8px; border: 1.5px solid var(--edge); display: grid; place-items: center; font-size: 14px; font-weight: 900; flex: none; background: color-mix(in srgb, var(--c) var(--head-mix), var(--card)); }
.ck-ico.l { font-size: 10px; letter-spacing: -.02em; }
.tile-foot .shared { margin-left: auto; color: var(--ink2); }

/* Upload-Liste */
.up { display: grid; grid-template-columns: auto 1fr; gap: 6px 12px; padding: 12px; border: 2px solid var(--line); border-radius: 14px; align-items: center; }
.up + .up { margin-top: 10px; }
.up .fname { font-weight: 800; overflow-wrap: anywhere; }
.up .opts { grid-column: 1 / -1; display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 8px; }
.up .status { grid-column: 1 / -1; font-size: 13px; font-weight: 700; }
.up.done { border-color: var(--ok); }
.up.failed { border-color: var(--danger); }
@media (max-width: 620px) { .up .opts { grid-template-columns: 1fr; } }

/* Ablegen-Hinweis */
.dropzone { position: fixed; inset: 0; z-index: 50; display: none; place-items: center; background: color-mix(in srgb, var(--accent) 22%, transparent); backdrop-filter: blur(2px); }
.dropzone.on { display: grid; }
.dropzone div { background: var(--card); border: 3px dashed var(--edge); border-radius: 26px; padding: 40px 50px; font-size: 24px; font-weight: 900; box-shadow: var(--shadow-hi); text-align: center; }
.dropzone small { display: block; font-size: 14px; font-weight: 600; color: var(--ink2); margin-top: 6px; }

/* Meldungen */
.toasts { position: fixed; left: 50%; bottom: 20px; translate: -50% 0; z-index: 100; display: grid; gap: 8px; width: max-content; max-width: calc(100vw - 24px); }
.toast { background: var(--ink); color: var(--bg); padding: 11px 16px; border-radius: 12px; font-weight: 700; font-size: 14px; box-shadow: 3px 3px 0 var(--accent); animation: pop .18s ease-out; }
.toast.bad { box-shadow: 3px 3px 0 var(--danger); }

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } .tile:hover, .tile:focus-within { transform: none; } }
