:root {
  --bg: #f4f5f7; --panel: #ebecf0; --card: #fff; --text: #1d2433; --muted: #5d6679;
  --line: #d7dae1; --accent: #2b5fd9;
  --video: #7c3aed; --autograph: #b45309; --card-c: #be185d; --speaking: #0f766e; --other: #64748b;
}
@media (prefers-color-scheme: dark) {
  :root { --bg: #14171f; --panel: #1c212c; --card: #262c3a; --text: #e8ebf2; --muted: #9aa3b6; --line: #343b4c; --accent: #7aa2ff; }
}
* { box-sizing: border-box; }
body { margin: 0; font: 15px/1.45 system-ui, sans-serif; background: var(--bg); color: var(--text); }
button { font: inherit; cursor: pointer; border: 0; border-radius: 6px; padding: 7px 12px; background: var(--accent); color: #fff; }
button.ghost { background: transparent; color: var(--muted); border: 1px solid var(--line); }
button.ghost.on { color: var(--text); border-color: var(--accent); }
input, textarea, select { font: inherit; color: inherit; background: var(--card); border: 1px solid var(--line); border-radius: 6px; padding: 8px; width: 100%; }
.top { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; padding: 12px 16px; border-bottom: 1px solid var(--line); }
.top h1 { font-size: 18px; margin: 0; }
.filters { display: flex; flex-wrap: wrap; gap: 6px; flex: 1; }
.who { color: var(--muted); font-size: 13px; display: flex; gap: 8px; align-items: center; }
.banner { margin: 12px 16px 0; padding: 10px 12px; border-radius: 6px; background: #fff4d6; color: #5a4300; }
.login { display: grid; place-items: center; padding: 60px 16px; }
.login form { background: var(--card); padding: 24px; border-radius: 10px; width: min(360px, 100%); display: grid; gap: 12px; }
.login h2, .login p { margin: 0; }
.msg { color: var(--muted); font-size: 13px; }
.board { display: flex; gap: 12px; padding: 16px; overflow-x: auto; align-items: flex-start; min-height: calc(100vh - 70px); }
.col { background: var(--panel); border-radius: 10px; width: 290px; flex: 0 0 290px; padding: 10px; }
.col.over { outline: 2px dashed var(--accent); }
.col h3 { margin: 2px 4px 10px; font-size: 13px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); display: flex; justify-content: space-between; }
.card { background: var(--card); border-radius: 8px; padding: 10px; margin-bottom: 8px; cursor: grab; border-left: 4px solid var(--other); box-shadow: 0 1px 2px rgba(0,0,0,.08); }
.card:hover { box-shadow: 0 2px 8px rgba(0,0,0,.18); }
.card .name { font-weight: 600; }
.card .subj { color: var(--muted); font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.card .meta { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 6px; font-size: 12px; color: var(--muted); }
.tag { padding: 1px 7px; border-radius: 99px; background: var(--panel); }
.tag.warn { background: #fde2e2; color: #8a1c1c; }
.t-video { border-left-color: var(--video); } .t-autograph { border-left-color: var(--autograph); }
.t-card { border-left-color: var(--card-c); } .t-speaking { border-left-color: var(--speaking); }
.t-unsorted { border-left-style: dashed; }
.drawer { position: fixed; top: 0; right: 0; bottom: 0; width: min(480px, 100%); background: var(--card); box-shadow: -4px 0 24px rgba(0,0,0,.25); padding: 20px 16px; overflow-y: auto; }
.drawer .close { position: absolute; top: 10px; right: 12px; font-size: 20px; line-height: 1; padding: 2px 9px; }
.drawer h2 { margin: 0 32px 4px 0; }
.drawer .row { display: grid; gap: 4px; margin: 14px 0; }
.drawer label { font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.body-text { white-space: pre-wrap; background: var(--panel); padding: 10px; border-radius: 6px; max-height: 220px; overflow: auto; font-size: 14px; }
.timeline { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; font-size: 13px; }
.timeline time { color: var(--muted); margin-right: 6px; }
.actions { display: flex; flex-wrap: wrap; gap: 6px; }
@media (max-width: 600px) { .col { width: 82vw; flex-basis: 82vw; } }
[hidden] { display: none !important; }
