.header-actions{display:flex;align-items:center;gap:20px}.theme-toggle{background:var(--soft);color:var(--ink);border:1px solid var(--line);border-radius:8px;padding:7px 11px;font-size:11px;letter-spacing:0;white-space:nowrap}
nav{margin-top:0}main>header{margin-bottom:28px}main>header>span{font-size:14px;letter-spacing:0;color:var(--ink);max-width:none;white-space:nowrap}
html[data-theme="dark"]{color-scheme:dark;--bg:#000;--paper:#0d0d0d;--ink:#cdcdcd;--muted:#8f8f8f;--line:#2a2a2a;--green:#ababab;--soft:#1e1e1e;--orange:#a0a0a0}
html[data-theme="light"]{color-scheme:light}
html[data-theme="dark"] body{background:#000}
html[data-theme="dark"] aside{background:#070707}
html[data-theme="dark"] .logo,html[data-theme="dark"] .primary{background:#4a4a4a;color:#dadada}
html[data-theme="dark"] .primary:hover{background:#5c5c5c;box-shadow:none}
html[data-theme="dark"] .nav{color:#9e9e9e}
html[data-theme="dark"] .nav:hover{background:#141414}
html[data-theme="dark"] .nav.active{background:#202020;color:#bdbdbd}
html[data-theme="dark"] .stats,html[data-theme="dark"] .flashcard,html[data-theme="dark"] .word-list,html[data-theme="dark"] .article{background:var(--paper);box-shadow:none}
html[data-theme="dark"] .stats .overall{background:#181818}
html[data-theme="dark"] .track{background:#2e2e2e}
html[data-theme="dark"] .track i{background:#818181}
html[data-theme="dark"] .segmented{background:#171717}
html[data-theme="dark"] .segmented button{color:#969696}
html[data-theme="dark"] .segmented .selected{background:#313131;color:#c0c0c0;box-shadow:none}
html[data-theme="dark"] .pill,html[data-theme="dark"] .speak,html[data-theme="dark"] .back,html[data-theme="dark"] .added-label{background:#232323;color:#b5b5b5}
html[data-theme="dark"] .speak:hover{background:#363636}
html[data-theme="dark"] .secondary,html[data-theme="dark"] .list-tools input,html[data-theme="dark"] .list-tools select{background:#101010;color:#b1b1b1}
html[data-theme="dark"] .secondary:hover{background:#1f1f1f}
html[data-theme="dark"] kbd{background:#191919;border-color:#3d3d3d;color:#a6a6a6}
html[data-theme="dark"] .primary kbd{background:#3f3f3f;border-color:#5d5d5d;color:#cacaca}
html[data-theme="dark"] .word-row+.word-row,html[data-theme="dark"] .sentence-block{border-color:#282828}
html[data-theme="dark"] .word-row:hover{background:#181818}
html[data-theme="dark"] .word-row.highlight{background:#2a2a2a}
html[data-theme="dark"] .row-actions button,html[data-theme="dark"] .sentence-controls button{background:#212121;color:#afafaf}
html[data-theme="dark"] .row-actions button.active,html[data-theme="dark"] .sentence-controls button.active{background:#3c3c3c;color:#cccccc}
html[data-theme="dark"] .row-actions button.no.active{background:#2a2a2a;color:#b2b2b2}
html[data-theme="dark"] .row-actions .goto{background:transparent}
html[data-theme="dark"] .token:hover,html[data-theme="dark"] .token:focus-visible,html[data-theme="dark"] .token.focus-token{background:#3a3a3a;color:#cfcfcf}
html[data-theme="dark"] .translation,html[data-theme="dark"] .word-meaning{color:#afafaf}
html[data-theme="dark"] .toast{background:#353535;color:#d4d4d4;border:1px solid #5b5b5b;box-shadow:none}
html[data-theme="dark"] .intro p,html[data-theme="dark"] .stats small,html[data-theme="dark"] .word-ipa,html[data-theme="dark"] .answer .ipa,html[data-theme="dark"] .plan-intro p,html[data-theme="dark"] .timeline p{color:#9c9c9c}
html[data-theme="dark"] .quiet-note,html[data-theme="dark"] footer,html[data-theme="dark"] .under-card,html[data-theme="dark"] .sentence-index,html[data-theme="dark"] .side-bottom small{color:#8c8c8c}
html[data-theme="dark"] input::placeholder{color:#8d8d8d}
html[data-theme="dark"] ::selection{background:#4b4b4b;color:#e5e5e5}
@media(max-width:760px){.header-actions{gap:9px;flex-wrap:wrap;justify-content:flex-end}.theme-toggle{font-size:10px;padding:6px 8px}header>span{max-width:105px;line-height:1.8}header{gap:12px}}
html[data-theme="dark"] .plain,html[data-theme="dark"] .card-top,html[data-theme="dark"] .list-meta,html[data-theme="dark"] .text-tools{color:#a0a0a0}
html[data-theme="dark"] .plain:hover{color:#c5c5c5}
html[data-theme="dark"] .muted,html[data-theme="dark"] .status-mark{color:#8c8c8c}
html[data-theme="dark"] .save-state i{background:#777}
html[data-theme="dark"] .save-state i.good{background:#aaa}
html[data-theme="dark"] .save-state i.bad{background:#bbb}
html[data-theme="dark"] :focus-visible{outline-color:#999}
#grading{flex-wrap:wrap;justify-content:center}.no-context{font-size:10px;color:var(--muted);max-width:115px;line-height:1.4}.row-actions{flex-wrap:wrap}.sentence-controls{flex-wrap:wrap}.status-mark.maybe{color:var(--ink)}

.row-actions button{width:30px;height:30px;min-width:30px;flex:0 0 30px;padding:0;display:inline-flex;align-items:center;justify-content:center;border-radius:7px;background:var(--soft);color:var(--ink)}
.row-actions .action-icon{width:15px;height:15px;display:block;pointer-events:none}
.row-actions .goto{background:var(--soft)}
html[data-theme="dark"] .row-actions .goto{background:#212121}
.row-actions button:hover{box-shadow:inset 0 0 0 1px var(--muted);transform:translateY(-1px)}

.flashcard .prompt.sentence{width:100%;margin-left:auto;margin-right:auto;text-align:justify;text-align-last:left}

.flashcard .prompt .token{font:inherit;line-height:inherit;letter-spacing:inherit;text-align:inherit;border-radius:4px}
.word-tip{position:fixed;z-index:50;width:260px;max-width:calc(100vw - 24px);padding:14px 16px;border:1px solid var(--line);border-radius:12px;background:var(--soft);color:var(--ink);box-shadow:0 8px 28px #0003;font-size:13px;line-height:1.6;pointer-events:auto;animation:enter .15s ease}
.word-tip strong,.word-tip span{display:block}.word-tip strong{font-size:15px;font-weight:500}.word-tip .tip-ipa{color:var(--muted);margin:3px 0 7px}

.word-tip .tip-expansion{margin-top:8px}.word-tip .tip-full{font-weight:500;margin-bottom:3px}

.flashcard:has(.prompt.sentence) .answer .meaning{text-align:justify;text-align-last:left}

.word-tip .tip-listen{display:block;margin-top:12px;padding:7px 12px;border-radius:7px;background:var(--paper);color:var(--ink);font-size:12px;border:1px solid var(--line)}.word-tip .tip-listen:hover{background:var(--line)}


