/* Learner cabinet (/account/): the site's tokens, plus a dark scheme for this page only. */
@media (prefers-color-scheme: dark) {
  body.is-account {
    color-scheme: dark;
    --ground: #0b1220; --alt: #131c2e; --surface: #111a2b; --sunk: #1a2438;
    --ink: #eef2f8; --ink-2: #c9d2e0; --ink-3: #9aa6b8; --rule: #253149; --rule-2: #34425e;
    --accent: #4d94ff; --accent-hover: #6aa6ff; --link: #7fb2ff; --focus: #7fb2ff;
    --good: #5fd08a; --good-soft: #13301f; --warn: #ffb066; --warn-soft: #3a2610;
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.4); background: var(--ground); color: var(--ink);
  }
  body.is-account .topbar { background: rgba(11, 18, 32, 0.92); border-color: var(--rule); }
  body.is-account .wm-logo { background: #fff; border-radius: 6px; }
  body.is-account .vbtn:not(.ghost):not(.is-big) { background: #2f6fe0; }
}
body.is-account { background: var(--ground); }
.acct { padding-block: 32px 72px; min-height: 70vh; max-width: 880px; }
.acct .sr, .sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.acct-head { margin-bottom: 20px; }
.acct-head .vpage-title { margin: 6px 0 8px; font-size: clamp(26px, 5vw, 38px); line-height: 1.15; overflow-wrap: anywhere; }
.acct-head .vlead { color: var(--ink-2); max-width: 60ch; overflow-wrap: anywhere; }
.acct h1:focus { outline: none; }
.acct h1:focus-visible { outline: none; }
.acct h2 { font-size: 20px; margin: 0 0 12px; }
.acct-card { background: var(--surface); border: 1px solid var(--rule); border-radius: var(--radius-sm, 12px); padding: 20px; box-shadow: var(--shadow); margin-bottom: 16px; }
.acct-form { display: grid; gap: 16px; max-width: 520px; }
.acct-field { display: grid; gap: 6px; min-width: 0; }
.acct-field label { font-weight: 600; font-size: 14px; color: var(--ink); }
.acct input[type=email], .acct input[type=text], .acct input[type=search], .acct select {
  font: inherit; font-size: 16px; color: var(--ink); background: var(--ground); border: 1.5px solid var(--rule-2); border-radius: 10px;
  padding: 11px 12px; min-height: 46px; width: 100%; min-width: 0; box-sizing: border-box;
}
.acct input:focus-visible, .acct select:focus-visible { outline: 3px solid var(--focus); outline-offset: 1px; border-color: var(--focus); }
.acct [aria-invalid=true] { border-color: #c4291c; }
.acct-err { color: #b3261e; font-size: 14px; margin: 0; }
@media (prefers-color-scheme: dark) { body.is-account .acct-err { color: #ff8a80; } body.is-account .acct [aria-invalid=true] { border-color: #ff8a80; } }
.acct-new { border: 0; padding: 0; margin: 0; display: grid; gap: 10px; }
.acct-check { display: grid; grid-template-columns: 22px 1fr; gap: 10px; align-items: start; font-size: 15px; color: var(--ink-2); }
.acct-check input { width: 20px; height: 20px; margin: 2px 0 0; accent-color: var(--accent); }
.acct-check a, .acct-hint a { color: var(--link); }
.acct-hint, .acct-note, .acct-meta { color: var(--ink-3); font-size: 14px; margin: 0; overflow-wrap: anywhere; }
.acct-submit { justify-content: center; width: 100%; }
.acct-linkbtn { background: none; border: 0; padding: 4px 0; font: inherit; font-size: 15px; color: var(--link); text-decoration: underline; cursor: pointer; justify-self: start; text-align: start; }
.acct-callout { background: var(--warn-soft); color: var(--ink); border-radius: 10px; padding: 12px 14px; max-width: 520px; }
.acct-banner { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; background: var(--warn-soft); color: var(--ink); border: 1px solid var(--warn); border-radius: 12px; padding: 12px 14px; margin-bottom: 18px; }
.acct-banner[hidden] { display: none; }
.acct-row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.acct-mail { overflow-wrap: anywhere; }
.acct-inbox { display: grid; gap: 12px; max-width: 560px; }
.acct-envelope { width: 56px; height: 40px; border-radius: 8px; border: 2px solid var(--accent); position: relative; overflow: hidden; }
.acct-envelope::after { content: ""; position: absolute; left: 6px; right: 6px; top: -22px; height: 40px; border: 2px solid var(--accent); transform: rotate(45deg) scale(.72); transform-origin: center; border-radius: 4px; }
.acct-tabs { display: flex; gap: 4px; margin: 0 0 20px; border-bottom: 1px solid var(--rule); }
.acct-tab { padding: 10px 14px; text-decoration: none; color: var(--ink-2); font-weight: 600; border-bottom: 3px solid transparent; margin-bottom: -1px; }
.acct-tab[aria-current=page] { color: var(--ink); border-bottom-color: var(--accent); }
.acct-hero { margin-bottom: 26px; }
.acct-continue { width: 100%; justify-content: center; text-align: center; font-size: 17px; padding: 16px 22px; box-sizing: border-box; border-radius: 16px; }
.acct-continue-txt { overflow-wrap: anywhere; }
.acct-sec { margin-bottom: 30px; }
.acct-grid { list-style: none; padding: 0; margin: 0; display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr)); }
.acct-grid .acct-card { margin: 0; display: grid; gap: 8px; align-content: start; }
.acct-en.is-active { border-color: var(--accent); }
.acct-en-top { display: flex; gap: 8px; justify-content: space-between; align-items: start; }
.acct-en-title { font-size: 17px; margin: 0; overflow-wrap: anywhere; }
.acct-pill { display: inline-block; font-size: 12px; font-weight: 600; padding: 3px 9px; border-radius: 980px; background: var(--alt); color: var(--ink-2); white-space: nowrap; margin-inline-start: 6px; }
.acct-pill.is-done { background: var(--good-soft); color: var(--good); }
.acct-pill.is-active { background: color-mix(in oklab, var(--accent) 14%, transparent); color: var(--ink); }
.acct progress { width: 100%; height: 10px; border-radius: 6px; overflow: hidden; appearance: none; border: 0; background: var(--sunk); }
.acct progress::-webkit-progress-bar { background: var(--sunk); border-radius: 6px; }
.acct progress::-webkit-progress-value { background: var(--accent); border-radius: 6px; }
.acct progress::-moz-progress-bar { background: var(--accent); border-radius: 6px; }
.acct-active { color: var(--accent); font-weight: 600; font-size: 14px; margin: 0; }
@media (prefers-color-scheme: dark) { body.is-account .acct-active { color: var(--link); } }
.acct-sm { font-size: 14px; padding: 7px 14px; justify-self: start; }
.acct-badges { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.acct-badge { display: grid; grid-template-columns: 36px 1fr auto; gap: 12px; align-items: center; background: var(--surface); border: 1px solid var(--rule); border-radius: 12px; padding: 12px 14px; }
.acct-badge a { color: var(--link); font-weight: 600; }
.acct-medal { width: 32px; height: 32px; border-radius: 50%; background: radial-gradient(circle at 35% 35%, #ffe08a, #d79b00); }
.acct-filters { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 150px), 1fr)); margin-bottom: 10px; }
.acct-q { grid-column: 1 / -1; }
.acct-course .acct-row { margin-top: 4px; }
.acct-sum { margin: 0; color: var(--ink-2); font-size: 15px; overflow-wrap: anywhere; }
.acct-cmsg { margin: 0; font-size: 14px; color: var(--ink-2); }
.acct-cmsg:empty { display: none; }
.acct-empty { list-style: none; grid-column: 1 / -1; display: grid; gap: 10px; justify-items: start; }
.acct-sessions { list-style: none; padding: 0; margin: 0 0 14px; display: grid; gap: 10px; }
.acct-sess { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; align-items: center; padding-bottom: 10px; border-bottom: 1px solid var(--rule); }
.acct-del { border-color: #e2b4ae; display: grid; gap: 12px; max-width: none; }
.acct-del p { margin: 0; color: var(--ink-2); }
.acct-danger { background: #b3261e; }
.acct-danger:hover { background: #8f1d17; }
.acct-danger:disabled, .acct .vbtn:disabled { opacity: .55; cursor: not-allowed; }
.acct-skel { display: grid; gap: 12px; padding-top: 8px; }
.acct-skel span { display: block; height: 18px; border-radius: 8px; background: var(--sunk); }
.acct-skel span:first-child { height: 36px; width: 60%; }
.acct .vbtn:focus-visible, .acct a:focus-visible, .acct button:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
@media (max-width: 520px) { .acct { padding-block: 22px 56px; } .acct-card { padding: 16px; } .acct-badge { grid-template-columns: 32px 1fr; } .acct-badge a { grid-column: 2; } }
.acct-block { display: block; margin-top: 2px; }
/* Sign-in: form on the left, the real course list on the right. */
.acct:has(.acct-signin) { max-width: 1040px; }
.acct-signin { display: grid; gap: 32px; grid-template-columns: minmax(0, 1fr); align-items: start; padding-top: 12px; }
@media (min-width: 900px) { .acct-signin { grid-template-columns: minmax(0, 440px) minmax(0, 1fr); gap: 72px; padding-top: 32px; } }
.acct-signin-main { display: grid; gap: 0; min-width: 0; }
.acct-title { font-family: var(--f-hero); font-size: clamp(32px, 5vw, 44px); font-weight: 800; letter-spacing: -0.025em; line-height: 1.05; margin: 0 0 10px; color: var(--ink); }
.acct-lead { margin: 0 0 28px; color: var(--ink-2); font-size: 16px; line-height: 1.5; max-width: 42ch; }
.acct-signin .acct-form { gap: 18px; max-width: none; }
.acct-modes { display: grid; grid-template-columns: 1fr 1fr; gap: 2px; padding: 3px; background: var(--alt); border: 1px solid var(--rule); border-radius: 10px; }
.acct-mode { font: inherit; font-size: 14px; font-weight: 600; color: var(--ink-3); background: transparent; border: 0; border-radius: 7px; padding: 8px 10px; cursor: pointer; }
.acct-mode:hover { color: var(--ink); }
.acct-mode[aria-pressed=true] { background: var(--surface); color: var(--ink); box-shadow: 0 1px 2px rgba(11, 27, 54, .10), 0 0 0 1px var(--rule); }
.acct-signin input[type=email] { background: var(--surface); min-height: 48px; }
.acct-signin input::placeholder { color: var(--ink-3); opacity: .7; }
.acct-send { font: inherit; font-size: 16px; font-weight: 600; color: #fff; background: var(--accent); border: 0; border-radius: 10px; min-height: 48px; padding: 0 18px; cursor: pointer; width: 100%; }
.acct-send:hover { background: var(--accent-hover); }
.acct-send:disabled { opacity: .6; cursor: progress; }
.acct-send:focus-visible, .acct-mode:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
.acct-signin .acct-note { font-size: 13px; line-height: 1.5; }
.acct-new[hidden] { display: none; }
.acct-shelf { min-width: 0; border-top: 1px solid var(--rule); padding-top: 24px; }
.acct-shelf[hidden] { display: none; }
@media (min-width: 900px) { .acct-shelf { border-top: 0; border-inline-start: 1px solid var(--rule); padding: 6px 0 0 48px; } }
.acct-shelf h2 { font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-3); margin: 0 0 8px; }
.acct-shelf-lead { margin: 0 0 18px; color: var(--ink-2); font-size: 15px; max-width: 46ch; }
.acct-shelf-list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--rule); }
.acct-shelf-list li { display: grid; grid-template-columns: 40px minmax(0, 1fr); gap: 14px; align-items: baseline; padding: 14px 0; border-bottom: 1px solid var(--rule); }
.acct-shelf-cc { font: 700 11px/1 ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace; letter-spacing: .04em; color: var(--ink-2); border: 1px solid var(--rule-2); border-radius: 5px; padding: 4px 0; text-align: center; }
.acct-shelf-body { display: grid; gap: 3px; min-width: 0; }
.acct-shelf-t { font-weight: 600; color: var(--ink); font-size: 15px; line-height: 1.35; overflow-wrap: anywhere; }
.acct-shelf-m { font-size: 13px; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.acct-shelf-foot { margin: 14px 0 0; font-size: 13px; color: var(--ink-3); }
