@font-face { font-family: "Signika"; font-weight: 300 700; font-display: swap; src: url(/fonts/signika-latin-ext-wght-normal.woff2) format("woff2-variations"); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Signika"; font-weight: 300 700; font-display: swap; src: url(/fonts/signika-latin-wght-normal.woff2) format("woff2-variations"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }

:root {
  --concrete: #eef0ec;
  --slab: #e2e5df;
  --white: #ffffff;
  --ink: #000000;
  --ink2: #3d4140;
  --grey: #6f7572;
  --rule: #c9cdc7;
  --sign: #f6c700;
  --signsoft: #fff1a8;
  --red: #c8102e;
  --green: #0a7d4f;
  --ok: #0a7d4f;
  --bad: #c8102e;
  --mark: #ffe680;
  --accent: #000000;
  --font: "Signika", "Helvetica Neue", Arial, sans-serif;
  --text: var(--ink);
  --text2: var(--ink2);
  --muted: var(--grey);
  --bg: var(--concrete);
  --surface: var(--white);
  --surface2: var(--slab);
  --on-accent: #ffffff;
  --on-mark: #000000;
  --mark-bg: var(--signsoft);
  --ok-bg: #e2f1e9;
  --bad-bg: #fbe4e7;
  --zebra: rgba(0, 0, 0, .03);
  --cond: var(--font);
}
* { box-sizing: border-box; }
html, body { margin: 0; }
html { overflow-x: hidden; }
body { background: var(--concrete); color: var(--ink); font-family: var(--font); font-size: 17px; line-height: 1.55; font-variant-numeric: tabular-nums; -webkit-font-smoothing: antialiased; }
button, input, select { font: inherit; color: inherit; }
a { color: inherit; text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--sign); outline-offset: 2px; }
h1, h2, h3 { font-weight: 600; line-height: 1.15; margin: 0; }
h1 { font-size: 40px; letter-spacing: -.015em; margin-bottom: 28px; }
h2 { font-size: 24px; padding-bottom: 6px; border-bottom: 1px solid var(--ink); margin: 52px 0 16px; }
h3 { font-size: 20px; margin: 32px 0 10px; }
.mono { font-variant-numeric: tabular-nums; }
.dim { color: var(--grey); }
.sm { font-size: 14px; }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.spread { justify-content: space-between; }
.gap { margin-top: 18px; }
.gap2 { margin-top: 36px; }
::selection { background: var(--sign); }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }

.btn { font-size: 15px; font-weight: 500; padding: 8px 16px; border: 1.5px solid var(--ink); background: var(--white); cursor: pointer; border-radius: 3px; line-height: 1.25; text-decoration: none; display: inline-block; white-space: nowrap; }
.btn:hover { background: var(--slab); text-decoration: none; }
.btn.dark { background: var(--ink); color: var(--white); }
.btn.dark:hover { background: var(--ink2); }
.btn.on { background: var(--ink); color: var(--sign); }
.btn.sm { font-size: 14px; padding: 4px 11px; }
.btn.link { border-color: transparent; background: none; padding-left: 0; padding-right: 0; text-decoration: underline; text-underline-offset: 3px; }
.btn.link:hover { background: none; }
.btn[disabled] { opacity: .3; cursor: default; }
.btn[disabled]:hover { background: var(--white); }
.btn.dark[disabled]:hover { background: var(--ink); }

.top { background: var(--ink); position: sticky; top: 0; z-index: 10; }
.top .in { max-width: 1040px; margin: 0 auto; padding: 8px 28px; display: flex; align-items: center; gap: 16px; }
.top .logo { display: none; }
.top nav { display: flex; gap: 3px; flex: 1; align-items: stretch; }
.top nav a { text-decoration: none; background: var(--sign); color: var(--ink); font-weight: 600; font-size: 15px; padding: 6px 13px; border-radius: 2px; border: 2px solid var(--sign); line-height: 1.2; }
.top nav a:hover { background: #ffd83d; border-color: #ffd83d; }
.top nav a.cur { background: var(--ink); color: var(--sign); border-color: var(--sign); }
.top nav a.me { margin-left: auto; background: none; border-color: transparent; color: #b9bfbb; font-weight: 400; }
.top nav a.me:hover { color: var(--white); }
.top nav a.me.cur { color: var(--sign); }
.burger { display: none; }
.page { max-width: 1040px; margin: 0 auto; padding: 44px 28px 120px; }
.narrow { max-width: 720px; }

.login { max-width: 340px; margin: 14vh auto 0; padding: 0 24px; }
.login .sign { display: inline-block; background: var(--ink); color: var(--sign); border: 3px solid var(--sign); outline: 3px solid var(--ink); font-size: 40px; font-weight: 700; padding: 2px 16px; border-radius: 3px; margin: 0 0 14px 3px; letter-spacing: .02em; }
.login .sub { color: var(--grey); margin-bottom: 30px; }
label.f { display: block; margin-bottom: 16px; }
label.f span { display: block; font-size: 14px; color: var(--ink2); margin-bottom: 4px; }
label.f input, label.f select { width: 100%; padding: 9px 11px; border: 1.5px solid var(--ink); background: var(--white); border-radius: 3px; outline: none; }
label.f input:focus { box-shadow: 0 0 0 3px var(--sign); }
.err { color: var(--bad); font-size: 14px; min-height: 22px; }

.lead { font-size: 21px; line-height: 1.45; max-width: 720px; margin: 0; }
.facts { display: grid; grid-template-columns: repeat(4, minmax(0, 170px)); gap: 0 36px; }
.facts b { display: block; font-size: 30px; font-weight: 600; line-height: 1.1; }
.facts span { color: var(--grey); font-size: 15px; }
.bar { height: 4px; background: var(--slab); margin-top: 8px; border-radius: 2px; overflow: hidden; }
.bar i { display: block; height: 100%; background: var(--ink); }

table.t { width: 100%; border-collapse: collapse; font-size: 16px; line-height: 1.45; margin: 12px 0 22px; background: var(--white); }
table.t th { background: var(--ink); color: var(--white); text-align: left; font-weight: 600; padding: 8px 12px; }
table.t td { padding: 8px 12px; border-bottom: .5px solid #bdbdbd; vertical-align: top; }
table.t tbody tr:nth-child(even) td { background: #f2f2f2; }
table.t tbody tr:last-child td { border-bottom: 1.2px solid var(--ink); }
table.t td.n { color: var(--grey); width: 38px; }
table.t td.c, table.t th.c { text-align: center; width: 104px; }
table.t td.time, table.t td.day { white-space: nowrap; width: 112px; }
table.t tr.now td { background: var(--signsoft) !important; }
table.t tr.past td { color: var(--grey); }
table.t tr.done td.what { text-decoration: line-through; color: var(--grey); }
table.t a { text-decoration: none; }
table.t a:hover { text-decoration: underline; }
.box { width: 17px; height: 17px; border: 1.5px solid var(--ink); border-radius: 2px; display: inline-block; vertical-align: middle; cursor: pointer; position: relative; background: var(--white); }
.box:hover { background: var(--signsoft); }
.box.on { background: var(--ink); }
.box.on::after { content: ""; position: absolute; left: 4.5px; top: 1px; width: 4px; height: 9px; border: solid var(--sign); border-width: 0 2px 2px 0; transform: rotate(45deg); }

.toc { list-style: none; padding: 0; margin: 0; background: var(--white); border-radius: 3px; }
.toc li + li { border-top: 1px solid var(--slab); }
.toc a { display: grid; grid-template-columns: 52px 1fr 110px 64px; align-items: center; padding: 14px 8px; text-decoration: none; gap: 8px; }
.toc a:hover { background: var(--signsoft); }
.toc .no { font-weight: 700; font-size: 15px; background: var(--ink); color: var(--sign); width: 34px; text-align: center; border-radius: 2px; padding: 2px 0; }
.toc .tt { font-size: 20px; font-weight: 500; }
.toc .meta { font-size: 14px; color: var(--grey); }
.toc .pc { font-size: 15px; text-align: right; padding-right: 6px; }

.lesson .kicker { font-size: 15px; color: var(--grey); margin-bottom: 6px; }
.player { position: sticky; top: 52px; z-index: 5; background: var(--concrete); border-bottom: 1px solid var(--rule); padding: 10px 0; margin: 0 0 10px; display: flex; gap: 12px; align-items: center; flex-wrap: wrap; font-size: 14px; }
.lesson h3.sec { font-size: 24px; padding-bottom: 6px; border-bottom: 1px solid var(--ink); margin: 44px 0 14px; }
.lesson ul { margin: 0 0 14px; padding-left: 20px; list-style: none; }
.lesson ul > li { position: relative; margin: 8px 0; }
.lesson ul > li::before { content: "•"; position: absolute; left: -16px; }
.lesson ul ul > li::before { content: "–"; }
.lesson [data-r] { border-radius: 2px; box-decoration-break: clone; -webkit-box-decoration-break: clone; transition: background .15s; }
.lesson b { font-weight: 650; }
.lesson .en { font-style: italic; color: var(--ink2); }
.memo { background: var(--white); border-left: 5px solid var(--sign); padding: 10px 16px; margin: 18px 0; }

.lab { margin: 32px 0 36px; background: var(--white); border-radius: 3px; padding: 18px 20px 22px; }
.lab-h { font-weight: 600; font-size: 18px; margin-bottom: 12px; }
.lab svg { display: block; width: 100%; height: auto; border-radius: 2px; }
.lab .ctrls { display: flex; flex-wrap: wrap; gap: 14px 26px; align-items: flex-end; margin: 12px 0; }
.lab label.sl { display: flex; flex-direction: column; gap: 2px; font-size: 14px; color: var(--ink2); min-width: 170px; flex: 1; }
.lab label.sl b { color: var(--ink); font-weight: 600; font-size: 16px; }
.lbl { font-size: 13px; color: var(--grey); margin-bottom: 3px; }
input[type=range] { width: 100%; accent-color: var(--ink); }
.seg { display: inline-flex; flex-wrap: wrap; border: 1.5px solid var(--ink); border-radius: 3px; overflow: hidden; background: var(--white); }
.seg button { border: none; background: none; padding: 5px 12px; cursor: pointer; font-size: 14px; border-right: 1px solid var(--rule); }
.seg button:last-child { border-right: none; }
.seg button:hover { background: var(--slab); }
.seg button.on { background: var(--ink); color: var(--sign); }
.info { font-size: 16px; padding: 10px 0 0; min-height: 34px; }
.info:empty { display: none; }
.result { display: flex; flex-wrap: wrap; gap: 8px 40px; margin-top: 14px; }
.result div span { display: block; font-size: 13px; color: var(--grey); }
.result div b { font-size: 24px; font-weight: 600; }
.ex { border-top: 1px solid var(--slab); margin-top: 18px; padding-top: 14px; }
.ex .exh { font-size: 14px; color: var(--grey); display: flex; justify-content: space-between; }
.ex input.num { width: 110px; padding: 6px 9px; border: 1.5px solid var(--ink); border-radius: 3px; background: var(--white); }
.ex input.num.ok { background: #d9efe4; border-color: var(--ok); }
.ex input.num.bad { background: #f7dadf; border-color: var(--bad); }
.choices { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.choices .btn.on { background: var(--ok); border-color: var(--ok); color: var(--white); }
.choices .btn.wrong { background: var(--bad); border-color: var(--bad); color: var(--white); }
.hit { cursor: pointer; }
.hit:hover { opacity: .82; }
.flash { animation: flash .9s; }
@keyframes flash { 0%, 100% { opacity: 1; } 50% { opacity: .25; } }
.ok { color: var(--ok); }
.bad { color: var(--bad); }
kbd { font: inherit; font-size: 13px; border: 1px solid var(--rule); border-radius: 3px; padding: 0 5px; background: var(--white); }

.qtop { display: flex; justify-content: space-between; align-items: center; font-size: 14px; color: var(--grey); gap: 12px; }
.ticks { display: flex; gap: 3px; flex-wrap: wrap; }
.ticks i { width: 16px; height: 8px; background: var(--rule); display: block; cursor: pointer; border-radius: 1px; }
.ticks i.ok { background: var(--ok); }
.ticks i.bad { background: var(--bad); }
.ticks i.cur { background: var(--ink); }
.qtext { font-size: 27px; line-height: 1.3; margin: 28px 0 22px; font-weight: 600; letter-spacing: -.005em; }
.opts { display: grid; gap: 6px; }
.opt { display: grid; grid-template-columns: 30px 1fr 24px; gap: 12px; align-items: center; width: 100%; text-align: left; background: var(--white); border: 1.5px solid transparent; border-radius: 3px; padding: 12px 12px; cursor: pointer; font-size: 18px; }
.opt:hover:not([disabled]) { border-color: var(--ink); }
.opt .k { font-weight: 700; font-size: 15px; background: var(--ink); color: var(--sign); width: 26px; height: 26px; display: grid; place-items: center; border-radius: 2px; }
.opt .m { text-align: right; font-weight: 700; }
.opt.ok { border-color: var(--ok); background: #e3f3ea; }
.opt.ok .k { background: var(--ok); color: var(--white); }
.opt.ok .m { color: var(--ok); }
.opt.bad { border-color: var(--bad); background: #fbe5e8; }
.opt.bad .k { background: var(--bad); color: var(--white); }
.opt.bad .m { color: var(--bad); }
.opt.picked { border-color: var(--ink); }
.opt[disabled] { cursor: default; color: var(--ink); }
.why { margin-top: 16px; font-size: 16px; color: var(--ink2); }
.qnav { display: flex; justify-content: space-between; margin-top: 26px; }
.choose { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0 22px; }
.score { font-size: 72px; font-weight: 700; line-height: 1; margin: 8px 0 10px; letter-spacing: -.02em; }
.review { margin-top: 28px; background: var(--white); border-radius: 3px; }
.review div { padding: 12px 16px; font-size: 16px; }
.review div + div { border-top: 1px solid var(--slab); }

.card-stage { perspective: 1400px; height: 300px; margin: 22px 0; cursor: pointer; }
.card-stage .in { position: relative; height: 100%; transition: transform .45s cubic-bezier(.3,.7,.2,1); transform-style: preserve-3d; }
.card-stage.flip .in { transform: rotateY(180deg); }
.idx { position: absolute; inset: 0; backface-visibility: hidden; -webkit-backface-visibility: hidden; background: var(--white); border-radius: 4px; display: flex; flex-direction: column; justify-content: center; padding: 56px 40px 24px; box-shadow: 0 1px 0 var(--rule); }
.idx .ch { position: absolute; top: 18px; left: 20px; font-size: 14px; font-weight: 700; background: var(--ink); color: var(--sign); padding: 1px 8px; border-radius: 2px; }
.idx .t { font-size: 28px; font-weight: 600; line-height: 1.25; }
.idx.back { transform: rotateY(180deg); background: var(--ink); color: var(--white); }
.idx.back .ch { background: var(--sign); color: var(--ink); font-weight: 600; }
.idx.back .t { font-size: 23px; font-weight: 400; }
.grade { display: flex; gap: 8px; }
.grade .btn { flex: 1; padding: 11px; }
.boxes { display: flex; gap: 24px; font-size: 15px; color: var(--grey); flex-wrap: wrap; }
.boxes b { color: var(--ink); font-weight: 600; }

.match { display: grid; grid-template-columns: 1fr 1fr; gap: 0 18px; }
.match .col { display: grid; gap: 6px; align-content: start; }
.match .col button { display: block; width: 100%; text-align: left; background: var(--white); border: 1.5px solid transparent; border-radius: 3px; padding: 12px 14px; cursor: pointer; font-size: 16px; min-height: 58px; }
.match .col button:hover { border-color: var(--ink); }
.match .col button.sel { background: var(--sign); }
.match .col button.gone { opacity: .3; pointer-events: none; background: #e3f3ea; }
.match .col button.wrong { background: #fbe5e8; border-color: var(--bad); }

.labidx { list-style: none; padding: 0; margin: 0; background: var(--white); border-radius: 3px; columns: 2; column-gap: 0; }
.labidx li { break-inside: avoid; }
.labidx a { display: flex; justify-content: space-between; padding: 11px 14px; text-decoration: none; }
.labidx a:hover { background: var(--signsoft); }
.labidx .dim { color: var(--ok); font-weight: 700; }

.toast { position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%); background: var(--ink); color: var(--sign); font-size: 14px; padding: 9px 16px; border-radius: 3px; opacity: 0; transition: opacity .2s; pointer-events: none; z-index: 50; }
.toast.on { opacity: 1; }
.duo { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

@media (max-width: 820px) {
  body { font-size: 16px; }
  .top .in { padding: 8px 14px; }
  .burger { display: block; margin-left: auto; background: var(--sign); border-color: var(--sign); }
  .top nav { display: none; position: absolute; top: 100%; left: 0; right: 0; background: var(--ink); flex-direction: column; gap: 4px; padding: 10px 14px 14px; }
  .top nav.open { display: flex; }
  .top nav a.me { margin-left: 0; }
  .page { padding: 26px 16px 100px; }
  h1 { font-size: 32px; }
    .facts { grid-template-columns: 1fr 1fr; gap: 18px 20px; }
  .toc a { grid-template-columns: 44px 1fr 54px; }
  .toc .meta { display: none; }
  .match { grid-template-columns: 1fr; gap: 6px; }
  .labidx { columns: 1; }
  .qtext { font-size: 22px; }
  table.t td.c, table.t th.c { width: 50px; font-size: 13px; }
  .player { top: 50px; }
    .duo { grid-template-columns: 1fr; }
}

.tools { flex-basis: 100%; display: flex; flex-wrap: wrap; gap: 6px 10px; align-items: center; padding-top: 6px; }
.tool { border: 1.5px solid var(--ink); background: var(--white); border-radius: 3px; padding: 3px 10px; font-size: 14px; cursor: pointer; }
.tool:hover { background: var(--slab); }
.tool.on { background: var(--ink); color: var(--sign); }
.tgroup { display: inline-flex; align-items: center; gap: 4px; }
.tlabel { font-size: 14px; color: var(--ink2); margin-right: 2px; }
.sw { width: 24px; height: 24px; border-radius: 3px; border: 1.5px solid var(--ink); background: var(--c); cursor: pointer; padding: 0; }
.sw.pen { background: var(--white); position: relative; }
.sw.pen::after { content: ""; position: absolute; inset: 6px; border-radius: 50%; background: var(--c); }
.sw.on { outline: 3px solid var(--sign); outline-offset: 1px; }
mark.hl { background: var(--c); color: inherit; border-radius: 2px; padding: 1px 0; box-decoration-break: clone; -webkit-box-decoration-break: clone; }
canvas.ink { position: absolute; left: 0; top: 0; pointer-events: none; z-index: 3; touch-action: none; }
#body[data-mode="pen"] canvas.ink { cursor: crosshair; }
#body[data-mode="erase"] canvas.ink { cursor: cell; }
#body[data-mode="hl"] { cursor: text; }
#body[data-mode="memo"] [data-r] { cursor: copy; }
#body[data-mode="memo"] [data-r]:hover { background: var(--signsoft); }
.memos { position: absolute; top: 0; left: calc(100% + 28px); width: 230px; z-index: 4; }
.sticky { position: absolute; left: 0; width: 230px; background: var(--sign); border-radius: 2px; padding: 8px 26px 8px 10px; box-shadow: 0 1px 0 rgba(0, 0, 0, .25); }
.sticky textarea { width: 100%; border: none; background: transparent; resize: none; font: inherit; font-size: 15px; line-height: 1.4; outline: none; overflow: hidden; }
.sticky .x { position: absolute; top: 4px; right: 6px; border: none; background: none; font-size: 18px; line-height: 1; cursor: pointer; }
@media (max-width: 1120px) {
  .memos { position: static; width: auto; margin-top: 20px; }
  .sticky { position: relative; top: 0 !important; width: auto; margin-bottom: 8px; }
}

.tabs { display: flex; flex-wrap: wrap; gap: 6px; margin: -10px 0 22px; }
.tabs button { border: 1.5px solid var(--ink); background: var(--white); border-radius: 3px; padding: 5px 12px; font-size: 15px; cursor: pointer; text-align: left; }
.tabs button:hover { background: var(--slab); }
.tabs button.on { background: var(--ink); color: var(--sign); }
.tabs button.on .dim { color: #b9bfbb; }
.lesson.wide { max-width: none; }
iframe.pdf { display: block; width: 100%; height: calc(100vh - 150px); min-height: 480px; border: none; background: var(--white); border-radius: 3px; }
#body[data-mode="pen"]::before, #body[data-mode="erase"]::before { content: ""; position: absolute; top: 0; bottom: 0; left: -12px; right: -12px; border-left: 1px dashed var(--rule); border-right: 1px dashed var(--rule); pointer-events: none; }

.tabs a.tab { border: 1.5px solid var(--ink); background: var(--white); border-radius: 3px; padding: 5px 12px; font-size: 15px; text-decoration: none; }
.tabs a.tab:hover { background: var(--slab); }
.tabs a.tab.on { background: var(--ink); color: var(--sign); }
.tabs a.tab.on .dim { color: #b9bfbb; }
.qlist { display: grid; gap: 6px; margin-bottom: 10px; }
.qi { display: grid; grid-template-columns: 52px 1fr; gap: 4px 12px; background: var(--white); border-radius: 3px; padding: 12px 14px; font-size: 16px; }
details.qi { display: block; position: relative; padding-left: 78px; }
details.qi .qs { position: absolute; left: 14px; top: 13px; }
details.qi > div { margin-top: 6px; }
.qi summary { cursor: pointer; list-style: none; }
.qi summary::-webkit-details-marker { display: none; }
.qi summary:hover { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
.qq { font-weight: 600; }
.qs { font-size: 13px; font-weight: 700; text-align: center; border-radius: 2px; padding: 1px 0; height: fit-content; width: 52px; }
.qs.ok { background: #e3f3ea; }
.qs.bad { background: #fbe5e8; }
.qs.new { background: var(--signsoft); color: var(--ink); font-weight: 600; }
.resume { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; background: var(--signsoft); border-left: 5px solid var(--sign); padding: 10px 14px; margin-bottom: 22px; border-radius: 2px; }
input.count { width: 84px; padding: 4px 8px; border: 1.5px solid var(--ink); border-radius: 3px; background: var(--white); font-size: 14px; }
input.search { flex: 1; min-width: 200px; padding: 7px 11px; border: 1.5px solid var(--ink); border-radius: 3px; background: var(--white); font-size: 16px; }
.qfilter { margin-bottom: 12px; }
.pbar { height: 4px; background: var(--slab); margin-top: 8px; border-radius: 2px; overflow: hidden; }
.pbar i { display: block; height: 100%; background: var(--ink); transition: width .3s; }
.reveal { background: var(--white); border-left: 5px solid var(--ok); padding: 14px 16px; font-size: 21px; font-weight: 600; border-radius: 2px; }
.reveal-btn { padding: 12px 22px; font-size: 16px; }
.qi.hidden-a { cursor: pointer; }
.qi.hidden-a .ans { display: none; }
.qi .ans > div { margin-top: 4px; }
.qi .meta { margin-top: 4px; }
.qs.learn { background: #e4ecf7; }
.qs.ok { color: var(--ok); }
.qs.bad { color: var(--bad); }
.stack { display: flex; height: 14px; border-radius: 3px; overflow: hidden; background: var(--slab); }
.stack i, .legend i { display: block; }
.stack .ok, .legend i.ok { background: var(--ok); }
.stack .learn, .legend i.learn { background: #6f93c4; }
.stack .bad, .legend i.bad { background: var(--bad); }
.stack .new, .legend i.new { background: #c9cdc7; }
.legend { display: flex; gap: 20px; flex-wrap: wrap; margin-top: 10px; font-size: 15px; }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.legend i { width: 12px; height: 12px; border-radius: 2px; }
.days { display: flex; gap: 6px; align-items: flex-end; height: 150px; }
.days > div { flex: 1; height: 100%; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: 3px; font-size: 12px; color: var(--grey); }
.days i { width: 100%; background: var(--rule); border-radius: 2px 2px 0 0; display: flex; align-items: flex-end; min-height: 2px; }
.days em { display: block; width: 100%; background: var(--ok); border-radius: 2px 2px 0 0; }
.days .n { color: var(--ink); }
.tw { overflow-x: auto; margin: 12px 0 22px; }
.tw table.t { margin: 0; min-width: 100%; }
.tw table.t td, .tw table.t th { min-width: 64px; }
.star { background: none; border: 0; padding: 0 4px; font-size: 22px; line-height: 1; color: #9a9d9b; cursor: pointer; font-family: inherit; }
.star:hover { color: var(--ink); }
.star.on { color: #d9a400; }
.star:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
.qi { position: relative; padding-right: 46px; }
.qi > .star { position: absolute; top: 9px; right: 8px; }

.lab .chip { display: inline-block; border: 1.5px solid var(--rule); background: var(--bg); border-radius: 3px; padding: 6px 11px; margin: 3px; cursor: pointer; font-size: 15px; }
.lab .chip:hover { border-color: var(--text2); }
.lab .chip.sel { border-color: var(--mark); background: var(--mark-bg); }
.lab .chip.ok { border-color: var(--ok); background: var(--ok-bg); cursor: default; }
.lab .chip.bad { border-color: var(--bad); background: var(--bad-bg); }
.lab .slots { display: grid; gap: 8px; margin: 10px 0; }
.lab .slot { display: grid; grid-template-columns: 200px 1fr; gap: 10px; align-items: center; border: 1.5px dashed var(--rule); border-radius: 3px; padding: 8px 10px; min-height: 48px; cursor: pointer; }
.lab .slot:hover { border-color: var(--text2); }
.lab .slot b { font-weight: 600; }
.lab .slot.ok { border-style: solid; border-color: var(--ok); background: var(--ok-bg); }
.lab .slot.bad { border-color: var(--bad); }
.lab .stage { margin: 12px 0; }
.lab .note { color: var(--text2); font-size: 15px; }
.lab svg .s-line { stroke: var(--text2); fill: none; }
.lab svg .s-box { fill: var(--surface2); stroke: var(--text2); }
.lab svg .s-acc { fill: var(--accent); }
.lab svg .s-accl { stroke: var(--accent); fill: none; }
.lab svg .s-mark { fill: var(--mark); }
.lab svg .s-ok { fill: var(--ok); }
.lab svg .s-bad { fill: var(--bad); }
.lab svg text { fill: var(--text); font-family: var(--font); }
.lab svg text.s-dim { fill: var(--muted); }
.lab svg text.s-on { fill: var(--on-accent); }

.lab .pool { display: flex; flex-wrap: wrap; gap: 2px; margin: 6px 0 10px; min-height: 10px; }
.lab .slot [data-in] { display: flex; flex-wrap: wrap; gap: 2px; }
.lab .slot .chip { cursor: default; margin: 2px; }
.lab ol.seq { margin: 8px 0 10px; padding-left: 26px; }
.lab ol.seq li { padding: 4px 0; border-bottom: 1px solid var(--rule); }
.lab ol.seq li::marker { font-family: var(--cond); font-weight: 600; color: var(--accent); }
.lab .chip.bad { animation: flash .45s; }
.lab .stage ul { padding-left: 20px; }
.lab .stage li { margin: 6px 0; }

.top .subj { border-color: #3d4140; background: transparent; flex-shrink: 0; }
.top .subj button { background: transparent; color: #b9bfbb; font-weight: 600; border-right-color: #3d4140; padding: 5px 11px; }
.top .subj button:hover { background: #1c1d1c; color: var(--white); }
.top .subj button.on { background: var(--sign); color: var(--ink); }
.adm td { vertical-align: middle; }
.adm .st-pending { color: var(--red); font-weight: 600; }
.adm .st-blocked { color: var(--grey); text-decoration: line-through; }
.adm .acts { white-space: nowrap; text-align: right; }
.adm .acts .btn { margin-left: 4px; }
@media (max-width: 820px) { .lab .slot { grid-template-columns: 1fr; } .top .subj button { padding: 5px 8px; } }
