:root {
  color-scheme: dark;
  --bg: #0a0f13;
  --panel: #10181d;
  --line: #24343c;
  --text: #e7eff2;
  --muted: #8799a1;
  --green: #71e1b0;
  --red: #ff8888;
  font-family: Inter, ui-sans-serif, system-ui, sans-serif;
}

* { box-sizing: border-box; }
body { min-height: 100vh; margin: 0; color: var(--text); background: radial-gradient(ellipse at 50% -25%, #1b3033, var(--bg) 58%); }
button, input { font: inherit; }
.app-shell { max-width: 1240px; margin: 0 auto; padding: 0 32px 28px; }
.topbar { height: 70px; display: flex; align-items: center; gap: 24px; border-bottom: 1px solid var(--line); }
.brand { display: flex; align-items: center; gap: 10px; color: var(--text); font: 700 13px ui-monospace, monospace; letter-spacing: .1em; text-decoration: none; }
.brand-mark { display: grid; place-items: center; width: 25px; height: 25px; border-radius: 7px; color: #07130f; background: var(--green); font: 700 15px system-ui, sans-serif; }
.topbar-label, .connection-state { color: var(--muted); font-size: 13px; }
.connection-state { display: inline-flex; align-items: center; gap: 9px; margin-left: auto; }
.status-dot { width: 7px; height: 7px; border-radius: 50%; background: #69777d; }
.status-dot.is-online { background: var(--green); box-shadow: 0 0 10px #71e1b077; }
.intro { display: flex; align-items: center; justify-content: space-between; padding: 42px 0 30px; }
.eyebrow { color: var(--green); font: 500 11px ui-monospace, monospace; letter-spacing: .11em; }
h1 { margin: 13px 0 12px; font-size: clamp(29px, 4vw, 42px); letter-spacing: -.045em; line-height: 1.14; }
.lead { max-width: 730px; margin: 0; color: #a8b7bd; font-size: 16px; }
.xp-badge { display: flex; flex: 0 0 74px; flex-direction: column; align-items: center; justify-content: center; width: 74px; height: 74px; border: 1px solid #3d664f; border-radius: 50%; color: var(--green); transform: rotate(8deg); }
.xp-badge strong { font: 500 19px ui-monospace, monospace; }
.xp-badge span { font-size: 10px; letter-spacing: .12em; }
.workspace { display: grid; grid-template-columns: minmax(0, var(--terminal-width, 60%)) minmax(280px, 1fr); gap: 18px; align-items: stretch; }
.terminal-card, .task-card { min-height: 570px; overflow: hidden; border: 1px solid var(--line); border-radius: 13px; background: linear-gradient(150deg, #111b20, #0d1418); }
.card-heading { display: flex; height: 54px; align-items: center; gap: 12px; padding: 0 19px; border-bottom: 1px solid var(--line); font-size: 14px; }
.terminal-heading { justify-content: space-between; background: #10191d; color: #b7c6cc; font: 12px ui-monospace, monospace; }
.terminal-heading > div { display: flex; align-items: center; gap: 12px; }
.window-lights { display: flex; gap: 5px; }
.window-lights i { width: 8px; height: 8px; border-radius: 50%; background: #ff7672; }
.window-lights i:nth-child(2) { background: #e9bd65; }
.window-lights i:nth-child(3) { background: #70d6a4; }
.terminal-status { color: var(--muted); font-size: 11px; }
.terminal-body { display: flex; min-height: 455px; flex-direction: column; padding: 18px 20px 12px; background: #080d10; }
.terminal-live-status { display: flex; min-height: 24px; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 8px; color: #7b9892; font: 10px ui-monospace, monospace; }
.terminal-live-status > span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.terminal-actions { display: flex; flex: 0 0 auto; align-items: center; gap: 6px; }
.terminal-action { min-height: 27px; padding: 5px 8px; border: 1px solid #2d4543; border-radius: 6px; color: #b7d6ca; background: #111d1d; font: 10px system-ui, sans-serif; cursor: pointer; }
.terminal-action:hover { border-color: #4a8065; color: var(--green); background: #14231c; }
.terminal-action.is-primary { border-color: #4b9871; color: #07130f; background: var(--green); font-weight: 700; }
.terminal-paste-fallback { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: center; gap: 8px; margin: 0 0 10px; padding: 10px; border: 1px solid #2d4543; border-radius: 8px; background: #10191d; }
.terminal-paste-fallback[hidden] { display: none; }
.terminal-paste-fallback label { grid-column: 1 / -1; color: #9aabb1; font: 10px system-ui, sans-serif; }
.terminal-paste-fallback textarea { grid-column: 1 / -1; width: 100%; padding: 8px; border: 1px solid #2a3a40; border-radius: 6px; outline: none; color: var(--text); background: #080e11; font: 12px ui-monospace, monospace; resize: vertical; }
.terminal-paste-fallback textarea:focus { border-color: #4a8065; }
.terminal-reconnect { padding: 5px 8px; border: 1px solid #365a48; border-radius: 6px; color: var(--green); background: #12221a; font: 10px system-ui, sans-serif; cursor: pointer; }
.terminal-viewport { min-height: 410px; flex: 1; overflow: hidden; }
.terminal-viewport .xterm { height: 100%; }
.terminal-viewport .xterm-viewport { overflow-y: auto !important; }
.terminal-scroll-help { margin: 8px 0 0; color: #829b9a; font: 10px ui-monospace, monospace; }
.terminal-empty { display: grid; min-height: 455px; place-content: center; justify-items: center; gap: 12px; padding: 30px; color: var(--muted); background: #080d10; text-align: center; }
.terminal-glyph { padding: 14px 18px; border: 1px solid #355b48; border-radius: 10px; color: var(--green); font: 22px ui-monospace, monospace; }
.terminal-empty p { margin: 0 0 9px; }
.terminal-footer { display: flex; min-height: 59px; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 8px 12px; padding: 10px 18px; border-top: 1px solid var(--line); color: var(--muted); font-size: 11px; }
.lab-expiry strong { color: var(--green); font-variant-numeric: tabular-nums; }
.task-icon { display: grid; width: 25px; height: 25px; place-items: center; border-radius: 6px; color: var(--green); background: #14291f; font: 11px ui-monospace, monospace; }
.task-content { padding: 20px; }
.task-content h2 { margin: 0 0 9px; font-size: 19px; letter-spacing: -.02em; }
.task-content > p { margin: 0; color: #a8b7bd; font-size: 14px; }
.checklist { margin: 22px 0 17px; padding: 14px; border: 1px solid var(--line); border-radius: 9px; background: #0b1216; }
.checklist-title { margin: 0 0 9px; color: var(--muted); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; }
.checklist > div { display: flex; align-items: center; gap: 9px; margin-top: 7px; color: #c3cfd3; font-size: 12px; }
.check-pending { color: #718189; font: 15px ui-monospace, monospace; }
.check-complete { color: var(--green); }
.button { display: inline-flex; align-items: center; justify-content: center; gap: 9px; padding: 10px 15px; border: 0; border-radius: 7px; font-weight: 700; text-decoration: none; cursor: pointer; }
.button-primary, .button-check { color: #07130f; background: var(--green); }
.button-check { width: 100%; }
.button-check:disabled { cursor: not-allowed; opacity: .42; }
.button-quiet { padding: 7px 10px; color: #c1cdd1; background: #1b292f; font-size: 11px; }
.check-result { min-height: 18px; margin: 10px 0 0; color: var(--muted); font-size: 12px; }
.check-result.is-success { color: var(--green); }
.check-result.is-error { color: var(--red); }
.hints { margin-top: 18px; color: #dce6e8; font-size: 13px; }
.hints summary { cursor: pointer; }
.hints ol { padding-left: 20px; color: #9eafb5; }
.hints li { padding: 4px 0; }
.hint-status { margin: 9px 0 0; color: var(--muted); font-size: 11px; }
.button-hint { margin-top: 8px; padding: 8px 11px; color: #cdebd9; background: #183024; font-size: 11px; }
.button-hint:disabled { cursor: default; opacity: .65; }
.solution { margin-top: 15px; padding: 12px; border: 1px solid #315843; border-radius: 8px; color: #dce6e8; background: #102019; font-size: 12px; }
.solution summary { color: var(--green); cursor: pointer; font-weight: 700; }
.solution p { color: #b8c9c1; line-height: 1.5; }
.solution ol { padding-left: 19px; color: #9eafb5; line-height: 1.55; }
.solution li + li { margin-top: 6px; }
.solution-block + .solution-block { margin-top: 16px; padding-top: 13px; border-top: 1px solid #294437; }
.solution-block h3 { margin: 0 0 7px; color: #a8cbb8; font-size: 11px; letter-spacing: .02em; }
.solution-block p { margin: 0; }
.remember-commands { display: grid; gap: 6px; margin: 0; padding-left: 18px; }
.remember-commands code { color: #b9e5cf; font: 11px ui-monospace, monospace; overflow-wrap: anywhere; }
.learning-note { display: flex; gap: 10px; margin-top: 18px; padding: 12px; border-radius: 8px; color: #9cafb6; background: #101d22; }
.learning-note > span { display: grid; flex: 0 0 18px; height: 18px; place-items: center; border: 1px solid #527b8a; border-radius: 50%; color: #8ab4ff; font: 11px ui-monospace, monospace; }
.learning-note p { margin: 0; font-size: 11px; }
.flash { margin-top: 14px; padding: 10px 14px; border-radius: 7px; font-size: 13px; }
.flash-success { color: var(--green); background: #10251c; }
.flash-error { color: var(--red); background: #2a1718; }
.page-footer { display: flex; gap: 14px; padding-top: 22px; color: #63747b; font: 10px ui-monospace, monospace; letter-spacing: .08em; }
.page-footer span { color: #87979d; font: 11px system-ui, sans-serif; letter-spacing: 0; }
.difficulty-tag { padding: 3px 7px; border-radius: 999px; color: #a9d8be; background: #183024; font-size: 10px; }
.catalog-search:focus-within, .machine-switcher select:focus { border-color: #4a8065; }
.attempt-summary { margin: 8px 0 0 !important; color: #809198 !important; font-size: 11px !important; }
.replacement-note { max-width: 480px; padding: 11px 13px; border: 1px solid #725d35; border-radius: 8px; color: #e2c681; background: #211d12; font-size: 12px; line-height: 1.55; }
.account-control { display: flex; align-items: center; gap: 13px; color: #c8d4d8; font-size: 12px; }
.logout-link { padding: 0; border: 0; color: var(--muted); background: transparent; font-size: 12px; cursor: pointer; }
.logout-link:hover, .auth-switch a { color: var(--green); }
.progress-overview { display: grid; grid-template-columns: minmax(220px, .7fr) minmax(200px, 1fr); align-items: center; gap: 20px; margin: 14px 0 4px; padding: 15px 18px; border: 1px solid var(--line); border-radius: 10px; background: #0e171b; }
.progress-copy { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 5px 14px; }
.progress-copy .eyebrow { grid-column: 1 / -1; margin: 0; font-size: 9px; }
.progress-copy strong { font-size: 13px; }
.progress-copy > span:last-child { color: var(--muted); font-size: 11px; }
.progress-track { height: 8px; overflow: hidden; border-radius: 999px; background: #243238; }
.progress-track span { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #51b98a, var(--green)); transition: width .25s ease; }
.topology-card { margin: 0 0 17px; padding: 15px 18px; border: 1px solid var(--line); border-radius: 10px; background: #0e171b; }
.topology-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.topology-heading > span:last-child { color: var(--muted); font-size: 11px; }
.topology-flow { display: flex; align-items: center; gap: 10px; overflow-x: auto; }
.topology-node { display: grid; min-width: 145px; gap: 5px; padding: 11px 13px; border: 1px solid #2b3f45; border-radius: 8px; background: #101d22; }
.topology-node strong { font-size: 12px; }
.topology-node > span { color: var(--muted); font: 10px ui-monospace, monospace; }
.topology-arrow { color: var(--green); font-size: 19px; }
.machine-switcher { display: inline-flex; align-items: center; gap: 7px; color: var(--muted); font: 10px system-ui, sans-serif; }
.machine-switcher select { max-width: 160px; padding: 5px 7px; border: 1px solid #2a3a40; border-radius: 6px; color: #c8d6d9; background: #0b1216; font: 11px system-ui, sans-serif; }
.auth-shell { display: grid; min-height: 100vh; align-content: center; justify-items: center; gap: 28px; padding: 34px 18px; }
.auth-brand { justify-self: center; }
.auth-card { width: min(100%, 440px); padding: 32px; border: 1px solid var(--line); border-radius: 14px; background: linear-gradient(150deg, #111b20, #0d1418); box-shadow: 0 24px 80px #0005; }
.auth-card .eyebrow { margin: 0 0 11px; }
.auth-card h1 { margin: 0 0 9px; font-size: 30px; }
.auth-description { margin: 0 0 23px; color: #9aaeb5; font-size: 13px; line-height: 1.6; }
.auth-form { display: grid; gap: 9px; }
.auth-form label { margin-top: 7px; color: #c8d4d8; font-size: 12px; }
.auth-form input { width: 100%; min-height: 42px; padding: 10px 12px; border: 1px solid #2a3a41; border-radius: 7px; outline: none; color: var(--text); background: #080e11; }
.auth-form input:focus { border-color: #58a87d; box-shadow: 0 0 0 3px #71e1b018; }
.auth-form input[type="submit"] { width: 100%; margin-top: 12px; border: 0; color: #07130f; background: var(--green); font-weight: 700; cursor: pointer; }
.field-hint { margin-top: -4px; color: var(--muted); font-size: 10px; }
.auth-switch { margin: 20px 0 0; color: var(--muted); font-size: 12px; text-align: center; }
.auth-switch a { text-decoration: none; }
.flash p { margin: 0; }
.flash p + p { margin-top: 5px; }

/* Multi-page navigation and practice catalog */
.main-nav { display: flex; height: 100%; align-items: center; gap: 5px; }
.main-nav a { padding: 9px 12px; border-radius: 7px; color: #9aabb1; font-size: 12px; text-decoration: none; }
.main-nav a:hover, .main-nav a.is-current { color: var(--text); background: #18262b; }
.catalog-hero { display: flex; min-height: 220px; align-items: center; justify-content: space-between; gap: 30px; padding: 35px 0 25px; }
.catalog-hero h1 { max-width: 650px; }
.hero-action { flex: 0 0 auto; }
.dashboard-stats { display: grid; grid-template-columns: repeat(3, minmax(130px, .75fr)) minmax(190px, 1.25fr); gap: 12px; margin: 4px 0 34px; }
.stat-card, .stat-progress { display: flex; min-height: 112px; flex-direction: column; justify-content: center; gap: 8px; padding: 17px 18px; border: 1px solid var(--line); border-radius: 10px; background: #10191e; }
.stat-card .eyebrow { font-size: 9px; }
.stat-card strong { font-size: 27px; letter-spacing: -.04em; }
.stat-card strong small { color: #8ea1a8; font-size: 14px; font-weight: 500; letter-spacing: 0; }
.stat-card > span:last-child { color: var(--muted); font-size: 11px; }
.stat-progress { gap: 14px; }
.stat-progress-copy, .section-heading, .practice-block-heading { display: flex; align-items: center; justify-content: space-between; gap: 14px; }
.stat-progress-copy { color: #c8d4d8; font-size: 12px; }
.stat-progress-copy strong { color: var(--green); }
.catalog-section { padding: 5px 0 25px; }
.learning-path-section { margin: 0 0 32px; }
.learning-path-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 11px; }
.learning-path-card { display: flex; min-width: 0; flex-direction: column; gap: 10px; padding: 16px; border: 1px solid #293a40; border-radius: 11px; background: linear-gradient(145deg, #111c20, #0d1519); }
.learning-path-meta { display: flex; align-items: center; justify-content: space-between; color: #85a397; font: 9px ui-monospace, monospace; letter-spacing: .07em; }
.learning-path-meta span:last-child { color: var(--green); }
.learning-path-card h3 { margin: 0; font-size: 15px; }
.learning-path-card > p { min-height: 34px; margin: 0; color: #9aabb1; font-size: 11px; line-height: 1.55; }
.learning-path-progress { display: grid; grid-template-columns: minmax(0, 1fr) 38px; align-items: center; gap: 9px; color: var(--green); font: 10px ui-monospace, monospace; }
.learning-path-progress .progress-track { margin: 0; }
.learning-path-next { color: #c9f3dc; font-size: 11px; line-height: 1.45; text-decoration: none; }
.learning-path-next:hover { color: var(--green); text-decoration: underline; }
.learning-path-complete { color: var(--green); font-size: 11px; }
.learning-path-outline { padding-top: 9px; border-top: 1px solid #26373e; color: #b8c8cc; font-size: 10px; }
.learning-path-outline summary { cursor: pointer; }
.learning-path-outline ol { display: grid; gap: 7px; max-height: 220px; overflow: auto; margin: 10px 0 0; padding-left: 20px; }
.learning-path-outline li { padding-left: 2px; color: #7f9399; }
.learning-path-outline li a { color: #b7c8cc; text-decoration: none; }
.learning-path-outline li a:hover { color: var(--green); }
.learning-path-outline li.is-complete a, .learning-path-outline li.is-complete span { color: var(--green); }
.learning-path-outline li span { margin-left: 5px; color: #71848b; font-size: 9px; }
.section-heading { margin-bottom: 16px; }
.section-heading .eyebrow { margin: 0 0 6px; }
.section-heading h2 { margin: 0; font-size: 22px; letter-spacing: -.025em; }
.section-heading > span { color: var(--muted); font-size: 12px; }
.catalog-tools { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-bottom: 24px; }
.catalog-search { display: flex; min-width: 220px; max-width: 510px; flex: 1; align-items: center; gap: 9px; padding: 0 12px; border: 1px solid #2a3a40; border-radius: 8px; color: #81959d; background: #0b1216; }
.catalog-search input { width: 100%; min-height: 42px; border: 0; outline: 0; color: var(--text); background: transparent; font-size: 12px; }
.catalog-status-filters { display: flex; gap: 6px; }
.filter-chip { padding: 8px 11px; border: 1px solid #26373e; border-radius: 999px; color: #9aabb1; background: #0d1519; font-size: 11px; cursor: pointer; }
.filter-chip:hover, .filter-chip.is-active { border-color: #416a55; color: #c8f0d9; background: #14251d; }
.practice-block { margin: 0 0 27px; }
.practice-block[hidden] { display: none; }
.practice-block-heading { justify-content: flex-start; margin-bottom: 12px; }
.practice-block-heading h3 { margin: 0; font-size: 15px; }
.practice-block-heading span { display: grid; min-width: 22px; height: 22px; place-items: center; border: 1px solid #27383f; border-radius: 999px; color: var(--muted); font-size: 10px; }
.practice-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.practice-card { display: flex; min-height: 200px; flex-direction: column; gap: 10px; padding: 15px; border: 1px solid #26373e; border-radius: 10px; color: var(--text); background: linear-gradient(145deg, #111b20, #0d1418); text-decoration: none; transition: border-color .15s ease, transform .15s ease, background .15s ease; }
.practice-card:hover { transform: translateY(-2px); border-color: #4a8065; background: #101d18; }
.practice-card[hidden] { display: none; }
.practice-card-meta { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.practice-state { color: #8799a1; font-size: 10px; }
.practice-state.is-complete { color: var(--green); }
.practice-card h4 { margin: 2px 0 0; font-size: 14px; line-height: 1.35; }
.practice-card p { margin: 0; color: #9aabb1; font-size: 11px; line-height: 1.55; }
.practice-card-footer { display: flex; align-items: flex-start; justify-content: space-between; gap: 9px; margin-top: auto; color: #8ea1a8; font-size: 10px; }
.practice-card-footer span:first-child { max-width: 72%; }
.practice-card-footer span:last-child { flex: 0 0 auto; color: var(--green); font: 10px ui-monospace, monospace; }
.practice-duration { color: #63747b; font-size: 10px; }
.catalog-empty { padding: 45px 15px; color: var(--muted); text-align: center; }
.detail-breadcrumb { display: flex; align-items: center; justify-content: space-between; padding-top: 18px; color: #82949b; font-size: 11px; }
.detail-breadcrumb a, .text-link { color: var(--green); text-decoration: none; }
.detail-breadcrumb a:hover, .text-link:hover { text-decoration: underline; }
.detail-breadcrumb > span { color: #71838a; }
.account-hero { display: flex; align-items: center; gap: 18px; padding: 38px 0 28px; }
.account-avatar { display: grid; width: 64px; height: 64px; flex: 0 0 64px; place-items: center; border: 1px solid #3f7256; border-radius: 18px; color: var(--green); background: #14251d; font-size: 25px; font-weight: 700; }
.account-hero .eyebrow { margin: 0 0 7px; }
.account-hero h1 { margin: 0 0 4px; font-size: 28px; }
.account-hero .lead { font-size: 12px; }
.account-xp { display: grid; gap: 3px; margin-left: auto; text-align: right; }
.account-xp strong { color: var(--green); font: 500 27px ui-monospace, monospace; }
.account-xp span { color: var(--muted); font-size: 11px; }
.account-stats { grid-template-columns: repeat(4, minmax(0, 1fr)); margin-bottom: 38px; }
.history-section { padding: 4px 0 26px; }
.text-link { font-size: 12px; }
.history-list { overflow: hidden; border: 1px solid var(--line); border-radius: 10px; background: #10191e; }
.history-row { display: grid; grid-template-columns: 34px minmax(0, 1fr) minmax(80px, auto) minmax(90px, auto) auto; align-items: center; gap: 13px; padding: 14px 16px; border-bottom: 1px solid #1e2c32; color: var(--text); text-decoration: none; }
.history-row:last-child { border-bottom: 0; }
.history-row:hover { background: #14211c; }
.history-icon { display: grid; width: 30px; height: 30px; place-items: center; border-radius: 8px; color: #d9bd7b; background: #292414; }
.history-icon.is-complete { color: var(--green); background: #14291f; }
.history-main { display: grid; gap: 4px; min-width: 0; }
.history-main strong { overflow: hidden; font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.history-main small, .history-row time { color: var(--muted); font-size: 10px; }
.history-status { color: #a9b7bc; font-size: 11px; }
.history-duration { color: var(--green); font-size: 11px; }
.empty-history { display: grid; justify-items: center; gap: 10px; padding: 50px 20px; border: 1px dashed #2b4047; border-radius: 10px; text-align: center; }
.empty-history p { margin: 0 0 6px; color: var(--muted); font-size: 12px; }
.terminal-settings { position: relative; margin-left: auto; font: 11px system-ui, sans-serif; }
.terminal-settings > summary { padding: 7px 9px; border: 1px solid #2a3b42; border-radius: 7px; color: #b8c9ce; background: #131f24; cursor: pointer; list-style: none; }
.terminal-settings > summary::-webkit-details-marker { display: none; }
.terminal-settings > summary span { margin-left: 4px; }
.terminal-settings-panel { position: absolute; z-index: 5; top: 40px; right: 0; display: grid; width: 270px; gap: 12px; padding: 14px; border: 1px solid #355047; border-radius: 9px; background: #111b1e; box-shadow: 0 12px 35px #0008; }
.terminal-settings-panel > label { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 8px; color: #c1d0d3; font-size: 10px; }
.terminal-settings-panel output { color: var(--green); font: 10px ui-monospace, monospace; }
.terminal-settings-panel input[type="range"] { grid-column: 1 / -1; width: 100%; accent-color: var(--green); }
.terminal-settings-panel select { grid-column: 1 / -1; width: 100%; padding: 7px; border: 1px solid #2a3a40; border-radius: 6px; color: var(--text); background: #080e11; font-size: 11px; }
.terminal-settings-panel .terminal-setting-toggle { display: flex; align-items: center; gap: 8px; }
.terminal-setting-toggle input { accent-color: var(--green); }
.terminal-card { min-height: calc(var(--terminal-height, 410px) + 160px); }
.terminal-body { min-height: calc(var(--terminal-height, 410px) + 45px); }
.terminal-viewport { height: var(--terminal-height, 410px); min-height: 220px; flex: 0 0 auto; }
.practice-next { display: flex; align-items: center; justify-content: space-between; gap: 15px; margin-top: 18px; padding: 15px 18px; border: 1px solid var(--line); border-radius: 10px; background: #0e171b; }
.practice-next > span { color: var(--muted); font-size: 11px; }
.practice-next a { color: var(--green); font-size: 12px; text-decoration: none; }
.practice-next a:hover { text-decoration: underline; }
.launch-progress { width: min(100%, 520px); padding: 17px; border: 1px solid #2d4940; border-radius: 12px; background: linear-gradient(145deg, #101c1a, #0b1215); text-align: left; }
.launch-progress[hidden] { display: none; }
.launch-progress-title { margin: 0 0 4px; color: var(--text); font-size: 14px; }
.launch-progress-copy { margin: 0; color: var(--muted); font-size: 11px; line-height: 1.5; }
.launch-steps { display: grid; gap: 7px; margin: 15px 0; padding: 0; list-style: none; }
.launch-steps li { display: flex; align-items: center; gap: 9px; color: #70838a; font-size: 11px; }
.launch-steps li::before { content: "○"; color: #52636a; font: 13px ui-monospace, monospace; }
.launch-steps li.is-active { color: #dce9e4; }
.launch-steps li.is-active::before { content: "◌"; color: var(--green); animation: launch-spin 1.2s linear infinite; }
.launch-steps li.is-complete { color: var(--green); }
.launch-steps li.is-complete::before { content: "✓"; color: var(--green); }
.launch-error { margin: 10px 0; padding: 10px; border: 1px solid #573638; border-radius: 7px; color: #ffaaaa; background: #241719; font-size: 11px; line-height: 1.5; }
.launch-error[hidden] { display: none; }
@keyframes launch-spin { to { transform: rotate(360deg); } }
.site-preview-card { margin: 18px 0 0; overflow: hidden; border: 1px solid var(--line); border-radius: 12px; background: #10191e; }
.site-preview-heading { display: flex; min-height: 66px; align-items: center; justify-content: space-between; gap: 15px; padding: 12px 16px; border-bottom: 1px solid var(--line); }
.site-preview-title, .site-preview-actions { display: flex; align-items: center; gap: 10px; min-width: 0; }
.site-preview-title > div { display: grid; gap: 4px; }
.site-preview-title strong { font-size: 12px; }
.site-preview-title small { color: var(--muted); font-size: 10px; }
.site-preview-live-dot { width: 8px; height: 8px; flex: 0 0 8px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 4px #65d6a41c; }
.site-preview-actions code { max-width: min(42vw, 520px); overflow: hidden; color: #8fa5a7; font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.site-preview-frame { display: block; width: 100%; height: 720px; border: 0; background: #f6f8fc; }
.site-preview-empty { display: grid; min-height: 280px; place-items: center; padding: 25px; color: var(--muted); font-size: 12px; text-align: center; }
.account-skills { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin: 0 0 34px; }
.skill-card { display: grid; gap: 10px; padding: 15px 16px; border: 1px solid var(--line); border-radius: 10px; background: #10191e; }
.skill-card-heading { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.skill-card-heading strong { font-size: 12px; }
.skill-card-heading span { color: var(--muted); font-size: 10px; }
.skill-track { height: 6px; overflow: hidden; border-radius: 999px; background: #243238; }
.skill-track span { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #51b98a, var(--green)); }
.account-attempts { margin-bottom: 34px; }
.attempt-list { overflow: hidden; border: 1px solid var(--line); border-radius: 10px; background: #10191e; }
.attempt-row { display: grid; grid-template-columns: 30px minmax(0, 1fr) 105px 150px; align-items: center; gap: 12px; padding: 12px 15px; border-bottom: 1px solid #1e2c32; }
.attempt-row:last-child { border-bottom: 0; }
.attempt-mark { display: grid; width: 27px; height: 27px; place-items: center; border-radius: 8px; color: #ffb4a9; background: #2c1a1b; }
.attempt-mark.is-success { color: var(--green); background: #14291f; }
.attempt-row strong { font-size: 11px; }
.attempt-row span, .attempt-row time { color: var(--muted); font-size: 10px; }
.attempt-row .attempt-result { color: #ffaaaa; }
.attempt-row .attempt-result.is-success { color: var(--green); }

.assigned-practice-list { overflow: hidden; border: 1px solid var(--line); border-radius: 9px; background: #10191e; }
.assigned-practice-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 13px 15px; border-bottom: 1px solid #1e2c32; color: var(--text); text-decoration: none; }
.assigned-practice-row:last-child { border-bottom: 0; }
.assigned-practice-row:hover { background: #14211c; }
.assigned-practice-row > span:first-child { display: grid; gap: 5px; }
.assigned-practice-row strong { font-size: 11px; }
.assigned-practice-row small, .assigned-practice-status { color: var(--muted); font-size: 10px; }
.assigned-practice-status.is-complete { color: var(--green); }
.skill-recommendation { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin: 0 0 28px; padding: 20px 22px; border: 1px solid #345943; border-radius: 12px; background: linear-gradient(120deg, #12231a, #10191e 68%); }
.skill-recommendation-copy { min-width: 0; }
.skill-recommendation .eyebrow { margin: 0 0 6px; color: var(--green); }
.skill-recommendation h2 { margin: 0 0 7px; font-size: 17px; }
.skill-recommendation p { margin: 0 0 5px; color: #c4d0d2; font-size: 11px; }
.skill-recommendation p strong { color: var(--green); }
.skill-recommendation-copy > span { color: var(--muted); font-size: 10px; }
.student-notebook { margin: 18px 0; padding: 18px; border: 1px solid var(--line); border-radius: 12px; background: #10191e; }
.student-notebook-heading { display: flex; align-items: center; justify-content: space-between; gap: 15px; margin-bottom: 14px; }
.student-notebook-heading .eyebrow { margin: 0 0 5px; color: var(--green); }
.student-notebook-heading h2 { margin: 0; font-size: 16px; }
.student-notebook-heading > span { color: var(--muted); font-size: 10px; }
.student-notebook-form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.notebook-field { display: grid; gap: 7px; color: #c5d1d3; font-size: 11px; }
.notebook-field small { margin-left: 5px; color: var(--muted); font-size: 9px; }
.notebook-field textarea { width: 100%; min-height: 115px; padding: 10px; border: 1px solid #2a3a40; border-radius: 7px; outline: none; color: var(--text); background: #080e11; font: 11px/1.5 ui-monospace, monospace; resize: vertical; }
.notebook-field textarea:focus { border-color: #4a8065; }
.notebook-save-row { display: flex; grid-column: 1 / -1; align-items: center; gap: 12px; }
.notebook-save-row [role="status"] { color: var(--muted); font-size: 10px; }
.saved-command-section { margin-top: 18px; }
.saved-command-section h3 { margin: 0 0 8px; font-size: 12px; }
.saved-command-list { overflow: hidden; margin: 0; padding: 0; border: 1px solid var(--line); border-radius: 8px; list-style: none; }
.saved-command-list li { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 9px 10px; border-bottom: 1px solid #1e2c32; }
.saved-command-list li:last-child { border-bottom: 0; }
.saved-command-list code { min-width: 0; overflow-wrap: anywhere; color: #b8d9c9; font-size: 10px; }
.saved-command-list li > span { display: flex; flex: 0 0 auto; gap: 5px; }
.practice-skill-recommendation { display: flex; align-items: center; justify-content: space-between; gap: 15px; margin-top: 15px; padding: 17px 19px; border: 1px solid #345943; border-radius: 10px; background: linear-gradient(120deg, #12231a, #0e171b); }
.practice-skill-recommendation[hidden] { display: none; }
.practice-skill-recommendation .eyebrow { margin: 0 0 5px; color: var(--green); font-size: 9px; }
.practice-skill-recommendation h2 { margin: 0 0 5px; font-size: 14px; }
.practice-skill-recommendation p { margin: 0 0 9px; color: var(--muted); font-size: 10px; }
.practice-skill-recommendation > p { color: var(--green); }
@media (max-width: 700px) {
  .student-notebook-form { grid-template-columns: 1fr; }
  .skill-recommendation, .practice-skill-recommendation { align-items: flex-start; flex-direction: column; }
  .student-notebook-heading { align-items: flex-start; flex-direction: column; }
}

@media (max-width: 900px) {
  .practice-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .learning-path-grid { grid-template-columns: 1fr; }
  .dashboard-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .account-skills { grid-template-columns: 1fr; }
}

@media (max-width: 560px) {
  .main-nav { gap: 0; }
  .main-nav a { padding: 8px 7px; font-size: 10px; }
  .catalog-hero { min-height: 0; align-items: flex-start; flex-direction: column; gap: 18px; padding: 28px 0 22px; }
  .catalog-hero h1 { font-size: 30px; }
  .hero-action { width: 100%; }
  .dashboard-stats, .account-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .stat-card, .stat-progress { min-height: 100px; padding: 13px; }
  .catalog-tools { align-items: stretch; flex-direction: column; }
  .catalog-status-filters { overflow-x: auto; }
  .filter-chip { flex: 0 0 auto; }
  .practice-grid { grid-template-columns: 1fr; }
  .learning-path-card { padding: 14px; }
  .practice-card { min-height: 170px; }
  .account-hero { gap: 12px; padding: 30px 0 22px; }
  .account-avatar { width: 48px; height: 48px; flex-basis: 48px; border-radius: 14px; font-size: 19px; }
  .account-hero h1 { font-size: 22px; }
  .account-xp strong { font-size: 20px; }
  .history-row { grid-template-columns: 30px minmax(0, 1fr) auto; gap: 8px; padding: 12px; }
  .history-status { display: none; }
  .history-row time { grid-column: 2; }
  .terminal-settings { margin-left: auto; }
  .terminal-settings > summary span { display: none; }
  .terminal-status { display: none; }
  .terminal-live-status { align-items: flex-start; flex-direction: column; }
  .terminal-actions { width: 100%; justify-content: flex-end; }
  .terminal-paste-fallback { grid-template-columns: 1fr auto; }
  .terminal-paste-fallback .is-primary { grid-column: 1 / 2; }
  .site-preview-heading { align-items: flex-start; flex-direction: column; }
  .site-preview-actions { width: 100%; justify-content: space-between; }
  .site-preview-actions code { max-width: calc(100vw - 130px); }
  .site-preview-frame { height: 640px; }
  .terminal-viewport { min-height: 220px; }
  .terminal-settings-panel { position: fixed; top: auto; right: 15px; left: 15px; bottom: 18px; width: auto; }
  .attempt-row { grid-template-columns: 28px minmax(0, 1fr) auto; gap: 8px; padding: 11px; }
  .attempt-row time { grid-column: 2 / -1; }
  .attempt-row .attempt-result { grid-column: 3; grid-row: 1; }
  .practice-next { align-items: flex-start; flex-direction: column; }
  .assigned-practice-row { align-items: flex-start; flex-direction: column; }
}

@media (max-width: 850px) {
  .terminal-card, .task-card { min-height: 0; }
}

@media (max-width: 850px) {
  .workspace { grid-template-columns: 1fr; }
  .terminal-card, .task-card { min-height: 0; }
  .terminal-body, .terminal-empty { min-height: 380px; }
  .terminal-viewport { min-height: 340px; }
  .topbar-label { display: none; }
  .intro { padding: 30px 0 23px; }
  .progress-overview { grid-template-columns: 1fr; gap: 12px; }
}

@media (max-width: 560px) {
  .app-shell { padding: 0 15px 22px; }
  .topbar { height: 58px; }
  .connection-state { font-size: 11px; }
  .account-control { gap: 8px; font-size: 10px; }
  .logout-link { font-size: 10px; }
  .intro { align-items: flex-start; gap: 14px; }
  .xp-badge { flex-basis: 55px; width: 55px; height: 55px; }
  .lead { font-size: 14px; }
  .terminal-card, .task-card { border-radius: 10px; }
  .terminal-heading { padding: 0 12px; }
  .terminal-body { padding: 14px 12px 10px; }
  .terminal-footer { padding: 0 11px; }
  .task-content { padding: 17px 14px; }
  .auth-card { padding: 25px 20px; }
}

/* Skill atlas visual system */
html[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0e0d19;
  --panel: #191827;
  --line: #302e42;
  --text: #f5f3fc;
  --muted: #a4a1ba;
  --green: #59dfac;
  --red: #ff939d;
  --atlas-sidebar: #11101e;
  --atlas-topbar: #13121f;
  --atlas-deep: #131321;
  --atlas-soft: #242338;
  --atlas-accent: #ff985e;
  --atlas-accent-text: #211322;
  --atlas-cyan: #53d5ed;
  --atlas-node-muted: #8886a5;
  --atlas-field: #1b1a2b;
}

html[data-theme="light"] {
  color-scheme: light;
  --bg: #f7f6f3;
  --panel: #ffffff;
  --line: #d9d6e1;
  --text: #252137;
  --muted: #69667b;
  --green: #087d63;
  --red: #bb3f54;
  --atlas-sidebar: #f0eef4;
  --atlas-topbar: #fcfbfd;
  --atlas-deep: #f4f2f7;
  --atlas-soft: #e9e7f0;
  --atlas-accent: #ad461f;
  --atlas-accent-text: #ffffff;
  --atlas-cyan: #0b809b;
  --atlas-node-muted: #77738f;
  --atlas-field: #f9f8fa;
}

body { color: var(--text); background: var(--bg); }
.app-shell { max-width: none; margin: 0 0 0 218px; padding: 0 24px 38px; }
.ui-icon { display: inline-block; width: 20px; height: 20px; flex: 0 0 auto; background: currentColor; -webkit-mask: var(--icon-url) center / contain no-repeat; mask: var(--icon-url) center / contain no-repeat; vertical-align: middle; }
.atlas-overline { color: var(--atlas-accent); font: 700 10px ui-monospace, monospace; letter-spacing: .14em; }
.eyebrow { color: var(--atlas-accent); }
a:focus-visible, button:focus-visible, summary:focus-visible, input:focus-visible, textarea:focus-visible { outline: 2px solid var(--atlas-cyan); outline-offset: 3px; }

.app-sidebar { position: fixed; z-index: 40; inset: 0 auto 0 0; display: flex; width: 218px; flex-direction: column; padding: 22px 14px 18px; border-right: 1px solid var(--line); background: var(--atlas-sidebar); }
.atlas-brand { min-height: 58px; padding: 0 10px 19px; border-bottom: 1px solid var(--line); font: 800 12px/1.25 ui-sans-serif, system-ui, sans-serif; letter-spacing: .03em; }
.atlas-brand-mark { display: grid; width: 34px; height: 34px; place-items: center; color: var(--atlas-accent); }
.atlas-brand-mark .ui-icon { width: 33px; height: 33px; }
.sidebar-nav { display: grid; align-content: start; gap: 8px; padding-top: 21px; }
.sidebar-link { display: flex; min-height: 61px; align-items: center; gap: 13px; padding: 10px 12px; border: 1px solid transparent; border-radius: 11px; color: var(--muted); font-size: 13px; font-weight: 600; text-decoration: none; transition: background .15s ease, color .15s ease, border-color .15s ease; }
.sidebar-link:hover { color: var(--text); background: var(--atlas-soft); }
.sidebar-link.is-current { border-color: var(--atlas-accent); color: var(--text); background: color-mix(in srgb, var(--atlas-accent) 9%, var(--atlas-sidebar)); }
.sidebar-link.is-current > .ui-icon { color: var(--atlas-accent); }
.sidebar-link span:not(.ui-icon) { display: grid; gap: 3px; }
.sidebar-link small { color: var(--muted); font-size: 10px; font-weight: 400; }
.sidebar-bottom { display: flex; align-items: flex-start; gap: 9px; margin-top: auto; padding: 15px 10px 0; border-top: 1px solid var(--line); color: var(--muted); font-size: 10px; line-height: 1.5; }
.sidebar-status-dot { width: 8px; height: 8px; flex: 0 0 8px; margin-top: 4px; border-radius: 50%; background: var(--green); }

.atlas-topbar { position: sticky; z-index: 30; top: 0; height: 81px; gap: 17px; margin: 0 -24px 20px; padding: 0 24px; border-bottom: 1px solid var(--line); background: var(--atlas-topbar); }
.topbar-context { display: grid; min-width: 172px; gap: 4px; }
.topbar-context-label { color: var(--atlas-accent); font: 700 9px ui-monospace, monospace; letter-spacing: .1em; }
.topbar-context strong { overflow: hidden; color: var(--text); font-size: 14px; text-overflow: ellipsis; white-space: nowrap; }
.topbar-search { display: flex; width: min(100%, 360px); min-width: 170px; height: 39px; align-items: center; gap: 9px; margin-left: auto; padding: 0 11px; border: 1px solid var(--line); border-radius: 9px; color: var(--muted); background: var(--atlas-field); }
.topbar-search .ui-icon { width: 17px; height: 17px; }
.topbar-search input { width: 100%; min-width: 0; border: 0; outline: 0; color: var(--text); background: transparent; font-size: 12px; }
.topbar-search input::placeholder { color: var(--muted); }
.topbar-search kbd { padding: 3px 5px; border: 1px solid var(--line); border-radius: 5px; color: var(--muted); font: 10px ui-monospace, monospace; }
.theme-toggle { display: inline-flex; flex: 0 0 auto; align-items: center; gap: 2px; padding: 3px; border: 1px solid var(--line); border-radius: 9px; background: var(--atlas-field); }
.theme-toggle__option { display: inline-flex; min-height: 32px; align-items: center; justify-content: center; gap: 5px; padding: 5px 8px; border: 0; border-radius: 6px; color: var(--muted); background: transparent; font-size: 11px; cursor: pointer; }
.theme-toggle__option .ui-icon { width: 15px; height: 15px; }
.theme-toggle__option[aria-pressed="true"] { color: var(--text); background: var(--atlas-soft); box-shadow: 0 1px 4px #0002; }
.theme-toggle__option:hover { color: var(--text); }
.auth-theme-toggle { position: fixed; z-index: 10; top: 20px; right: 22px; }
.topbar-account { position: relative; flex: 0 0 auto; }
.topbar-account > summary { display: flex; align-items: center; gap: 8px; cursor: pointer; list-style: none; }
.topbar-account > summary::-webkit-details-marker { display: none; }
.topbar-avatar { display: grid; width: 35px; height: 35px; place-items: center; border: 1px solid var(--line); border-radius: 50%; color: var(--text); background: var(--atlas-soft); font-size: 12px; font-weight: 700; }
.topbar-account-name { max-width: 120px; overflow: hidden; color: var(--text); font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.topbar-account-menu { position: absolute; top: 47px; right: 0; display: grid; min-width: 154px; gap: 4px; padding: 7px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel); box-shadow: 0 12px 30px #0003; }
.topbar-account-menu a, .topbar-account-menu .logout-link { display: block; width: 100%; padding: 8px 9px; border-radius: 6px; color: var(--text); font-size: 11px; text-align: left; text-decoration: none; }
.topbar-account-menu a:hover, .topbar-account-menu .logout-link:hover { color: var(--text); background: var(--atlas-soft); }
.topbar-account-menu form { margin: 0; }

.button-primary, .button-check { color: var(--atlas-accent-text); background: var(--atlas-accent); }
.button-primary:hover, .button-check:not(:disabled):hover { filter: brightness(1.08); }
.progress-track, .skill-track { background: var(--atlas-soft); }
.progress-track span, .skill-track span { background: var(--atlas-cyan); }
.page-footer { color: var(--muted); }
.page-footer span { color: var(--muted); }

/* The atlas is the signed-in home page. Its route cards contain real learning paths. */
.atlas-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(315px, 366px); grid-template-rows: auto minmax(650px, auto); gap: 16px; max-width: 1570px; margin: 0 auto; }
.atlas-progress, .atlas-map, .atlas-detail { min-width: 0; border: 1px solid var(--line); border-radius: 15px; background: var(--panel); }
.atlas-progress { display: grid; grid-template-columns: minmax(210px, 1fr) repeat(3, minmax(87px, auto)); align-items: center; gap: 22px; min-height: 120px; padding: 20px 25px; }
.atlas-progress-main { display: grid; gap: 8px; }
.atlas-progress-main strong { font-size: clamp(17px, 1.6vw, 22px); letter-spacing: -.03em; }
.atlas-progress-track { height: 7px; overflow: hidden; border-radius: 30px; background: var(--atlas-soft); }
.atlas-progress-track > span { display: block; height: 100%; border-radius: inherit; background: var(--atlas-cyan); transition: width .25s ease; }
.atlas-progress-count { display: grid; grid-template-columns: 19px auto; align-items: center; gap: 1px 5px; color: var(--muted); }
.atlas-progress-count .ui-icon { width: 17px; height: 17px; color: var(--atlas-cyan); }
.atlas-progress-count strong { color: var(--text); font-size: 19px; line-height: 1; }
.atlas-progress-count span:last-child { grid-column: 1 / -1; padding-left: 24px; font-size: 10px; }
.atlas-progress-count:last-child .ui-icon { color: var(--atlas-node-muted); }
.atlas-map { position: relative; display: flex; flex-direction: column; min-height: 660px; overflow: hidden; padding: 28px 31px 19px; background: var(--atlas-deep) var(--atlas-dark-image) center center / cover no-repeat; }
html[data-theme="light"] .atlas-map { background-image: var(--atlas-light-image); }
.atlas-map-heading { position: relative; z-index: 1; display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; }
.atlas-map-heading h1 { margin: 7px 0 0; font-size: clamp(21px, 2.1vw, 29px); letter-spacing: -.035em; }
.atlas-map-heading p { max-width: 256px; margin: 5px 0 0; color: var(--muted); font-size: 11px; line-height: 1.55; }
.atlas-catalog-link { display: flex; min-width: 218px; align-items: center; gap: 11px; padding: 10px 12px; border: 1px solid color-mix(in srgb, var(--atlas-accent) 55%, var(--line)); border-radius: 12px; color: var(--text); background: color-mix(in srgb, var(--atlas-accent) 9%, var(--panel)); text-decoration: none; box-shadow: 0 8px 24px #0002; transition: transform .15s ease, border-color .15s ease, background .15s ease; }
.atlas-catalog-link:hover { transform: translateY(-2px); border-color: var(--atlas-accent); background: color-mix(in srgb, var(--atlas-accent) 17%, var(--panel)); }
.atlas-catalog-link-count { display: grid; width: 41px; height: 41px; flex: 0 0 41px; place-items: center; border-radius: 9px; color: var(--atlas-accent-text); background: var(--atlas-accent); font-size: 16px; font-weight: 800; }
.atlas-catalog-link-copy { display: grid; flex: 1; gap: 2px; }
.atlas-catalog-link-copy strong { font-size: 12px; }
.atlas-catalog-link-copy small { color: var(--muted); font-size: 10px; }
.atlas-catalog-link > .ui-icon { width: 17px; height: 17px; color: var(--atlas-accent); }
.atlas-route-nodes { position: relative; z-index: 1; flex: 1; min-height: 526px; margin: 0; padding: 0; list-style: none; }
.atlas-node-position { position: absolute; width: clamp(154px, 21%, 204px); }
.atlas-node-position--1 { top: 6%; left: 50%; transform: translateX(-50%); }
.atlas-node-position--2 { top: 38%; left: 4%; }
.atlas-node-position--3 { top: 38%; right: 4%; }
.atlas-node-position--4 { bottom: 3%; left: 18%; }
.atlas-node-position--5 { bottom: 3%; right: 18%; }
.atlas-node { display: grid; width: 100%; min-height: 144px; justify-items: center; gap: 5px; padding: 15px 12px 12px; border: 1px solid var(--line); border-radius: 14px; color: var(--text); background: color-mix(in srgb, var(--panel) 94%, transparent); box-shadow: 0 12px 30px #0002; font: inherit; text-align: center; cursor: pointer; transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease; }
.atlas-node:hover { transform: translateY(-3px); border-color: var(--atlas-accent); }
.atlas-node.is-selected { border-color: var(--atlas-accent); box-shadow: 0 0 0 2px color-mix(in srgb, var(--atlas-accent) 15%, transparent), 0 14px 32px #0003; }
.atlas-node-icon { display: grid; width: 43px; height: 43px; place-items: center; border: 1px solid var(--line); border-radius: 12px; color: var(--atlas-node-muted); background: var(--atlas-soft); }
.atlas-node-icon .ui-icon { width: 25px; height: 25px; }
.atlas-node--active .atlas-node-icon, .atlas-node.is-selected .atlas-node-icon { color: var(--atlas-accent); background: color-mix(in srgb, var(--atlas-accent) 12%, var(--atlas-soft)); }
.atlas-node--complete .atlas-node-icon { color: var(--atlas-cyan); }
.atlas-node strong { max-width: 100%; font-size: 12px; line-height: 1.2; }
.atlas-node-count { color: var(--muted); font-size: 10px; }
.atlas-node-track { width: 78%; height: 4px; margin-top: 2px; overflow: hidden; border-radius: 10px; background: var(--atlas-soft); }
.atlas-node-track > span { display: block; height: 100%; border-radius: inherit; background: var(--atlas-cyan); }
.atlas-legend { position: relative; z-index: 1; display: flex; justify-content: flex-end; gap: 17px; color: var(--muted); font-size: 10px; }
.atlas-legend span { display: inline-flex; align-items: center; gap: 6px; }
.atlas-legend i { display: inline-block; width: 7px; height: 7px; border-radius: 50%; border: 1px solid var(--atlas-node-muted); }
.atlas-legend i.is-complete { border-color: var(--atlas-cyan); background: var(--atlas-cyan); }
.atlas-legend i.is-active { border-color: var(--atlas-accent); background: var(--atlas-accent); }

.atlas-detail { grid-column: 2; grid-row: 1 / span 2; overflow: auto; }
.atlas-detail-panel { display: grid; align-content: start; min-height: 100%; padding: 27px 25px 22px; }
.atlas-detail-panel[hidden] { display: none; }
.atlas-detail-eyebrow { display: flex; align-items: center; gap: 7px; margin: 0 0 16px; color: var(--atlas-accent); font: 700 10px ui-monospace, monospace; letter-spacing: .07em; }
.atlas-detail-eyebrow .ui-icon { width: 16px; height: 16px; }
.atlas-detail h2 { margin: 0 0 14px; font-size: clamp(21px, 1.9vw, 27px); line-height: 1.17; letter-spacing: -.035em; }
.atlas-detail-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.atlas-detail-tags span { padding: 6px 9px; border: 1px solid var(--line); border-radius: 6px; color: var(--muted); background: var(--atlas-soft); font-size: 10px; }
.atlas-detail-description { margin: 23px 0 15px; color: var(--muted); font-size: 12px; line-height: 1.65; }
.atlas-detail-facts { display: grid; gap: 3px; padding: 9px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.atlas-detail-facts > div { display: flex; align-items: center; gap: 12px; min-height: 47px; }
.atlas-detail-facts .ui-icon { width: 19px; height: 19px; color: var(--atlas-cyan); }
.atlas-detail-facts > div > span { display: grid; gap: 2px; }
.atlas-detail-facts small { color: var(--muted); font-size: 10px; }
.atlas-detail-facts strong { font-size: 11px; font-weight: 600; }
.atlas-start-button { display: flex; min-height: 45px; align-items: center; justify-content: center; gap: 9px; margin-top: 20px; padding: 10px 15px; border-radius: 9px; color: var(--atlas-accent-text); background: var(--atlas-accent); font-size: 12px; font-weight: 750; text-decoration: none; transition: filter .15s ease, transform .15s ease; }
.atlas-start-button:hover { transform: translateY(-1px); filter: brightness(1.08); }
.atlas-start-button .ui-icon { width: 17px; height: 17px; }
.atlas-start-button .ui-icon:last-child { margin-left: auto; }
.atlas-detail-program { margin-top: 30px; padding-top: 21px; border-top: 1px solid var(--line); }
.atlas-detail-program h3 { margin: 0 0 10px; font-size: 13px; }
.atlas-detail-program p { margin: 0 0 19px; color: var(--muted); font-size: 11px; line-height: 1.65; }
.atlas-detail-program-progress { display: flex; justify-content: space-between; gap: 8px; margin-bottom: 8px; color: var(--muted); font-size: 10px; }
.atlas-detail-program-progress strong { color: var(--atlas-cyan); }
.atlas-step-list { margin-top: 24px; border-top: 1px solid var(--line); color: var(--muted); font-size: 11px; }
.atlas-step-list summary { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 15px 0; color: var(--text); cursor: pointer; list-style: none; }
.atlas-step-list summary::-webkit-details-marker { display: none; }
.atlas-step-list summary .ui-icon { width: 15px; height: 15px; transition: transform .15s ease; }
.atlas-step-list[open] summary .ui-icon { transform: rotate(90deg); }
.atlas-step-list ol { display: grid; gap: 0; max-height: 340px; overflow: auto; margin: 0; padding: 0; list-style: none; }
.atlas-step-list li { display: flex; justify-content: space-between; gap: 9px; padding: 9px 0; border-top: 1px solid var(--line); }
.atlas-step-list li a { color: var(--text); text-decoration: none; }
.atlas-step-list li a:hover { color: var(--atlas-accent); }
.atlas-step-list li span { flex: 0 0 auto; color: var(--muted); font-size: 10px; }
.atlas-step-list li.is-complete span { color: var(--green); }

/* Shared pages follow the same palette, while the SSH terminal keeps its own theme. */
.catalog-header { display: flex; align-items: end; justify-content: space-between; gap: 25px; max-width: 1570px; margin: 0 auto 27px; padding: 23px 0 28px; border-bottom: 1px solid var(--line); }
.catalog-header .atlas-overline { margin: 0 0 9px; }
.catalog-header h1 { margin: 0 0 9px; font-size: clamp(28px, 3vw, 41px); }
.catalog-header .lead { max-width: 650px; font-size: 13px; line-height: 1.6; }
.catalog-header-count { display: grid; flex: 0 0 auto; min-width: 155px; justify-items: end; gap: 3px; padding-left: 24px; border-left: 1px solid var(--line); }
.catalog-header-count strong { color: var(--atlas-accent); font-size: 30px; line-height: 1; }
.catalog-header-count span { color: var(--muted); font-size: 11px; }
.catalog-header-count a { margin-top: 10px; color: var(--atlas-cyan); font-size: 11px; text-decoration: none; }
.catalog-header-count a:hover { text-decoration: underline; }
.catalog-page .catalog-section { max-width: 1570px; margin: 0 auto; }
.catalog-search, .filter-chip, .practice-card, .stat-card, .stat-progress, .learning-path-card, .history-list, .attempt-list, .skill-card, .progress-overview, .student-notebook, .site-preview-card, .practice-next, .empty-history, .assigned-practice-list { border-color: var(--line); background: var(--panel); }
.catalog-search { color: var(--muted); background: var(--atlas-field); }
.catalog-search .ui-icon { width: 17px; height: 17px; }
.catalog-search:focus-within, .topbar-search:focus-within { border-color: var(--atlas-cyan); box-shadow: 0 0 0 3px color-mix(in srgb, var(--atlas-cyan) 18%, transparent); }
.filter-chip { color: var(--muted); }
.filter-chip:hover, .filter-chip.is-active { border-color: var(--atlas-accent); color: var(--text); background: color-mix(in srgb, var(--atlas-accent) 11%, var(--panel)); }
.practice-card { min-height: 162px; padding: 17px; }
.practice-card:hover { border-color: var(--atlas-accent); background: var(--atlas-soft); }
.practice-card h4 { font-size: 15px; }
.practice-card-footer, .practice-duration, .practice-card p, .practice-state, .lead { color: var(--muted); }
.practice-card-footer span:last-child, .account-xp strong { color: var(--atlas-accent); }
.practice-duration { display: flex; align-items: center; gap: 5px; }
.practice-duration .ui-icon { width: 13px; height: 13px; }
.practice-block-heading span { border-color: var(--line); }
.difficulty-tag { color: var(--atlas-cyan); background: color-mix(in srgb, var(--atlas-cyan) 10%, var(--panel)); }
.account-hero { border-bottom: 1px solid var(--line); }
.account-avatar { border-color: var(--atlas-accent); color: var(--atlas-accent); background: var(--atlas-soft); }
.learning-path-card { border-color: var(--line); }
.learning-path-card > p, .learning-path-outline, .learning-path-outline li a, .skill-recommendation p { color: var(--muted); }
.learning-path-meta, .learning-path-outline li, .learning-path-outline li span { color: var(--muted); }
.learning-path-outline { border-color: var(--line); }
.learning-path-next, .learning-path-outline li.is-complete a { color: var(--atlas-cyan); }
.history-row, .attempt-row, .saved-command-list li { border-color: var(--line); }
.history-row:hover, .assigned-practice-row:hover { background: var(--atlas-soft); }
.history-status, .attempt-row .attempt-result { color: var(--muted); }
.history-icon, .attempt-mark { color: var(--atlas-accent); background: var(--atlas-soft); }
.history-icon.is-complete, .attempt-mark.is-success { color: var(--green); background: var(--atlas-soft); }
.skill-recommendation, .practice-skill-recommendation { border-color: var(--line); background: var(--panel); }
.skill-recommendation .eyebrow, .practice-skill-recommendation .eyebrow { color: var(--atlas-accent); }
.notebook-field { color: var(--text); }
.notebook-field textarea, .auth-form input, .terminal-settings-panel select, .machine-switcher select { border-color: var(--line); color: var(--text); background: var(--atlas-field); }
.notebook-field textarea:focus, .auth-form input:focus { border-color: var(--atlas-cyan); box-shadow: 0 0 0 3px color-mix(in srgb, var(--atlas-cyan) 18%, transparent); }
.saved-command-list code { color: var(--text); }
.terminal-card, .task-card { background: var(--panel); }
.terminal-heading, .terminal-footer { color: var(--muted); background: var(--atlas-deep); }
.terminal-settings > summary, .terminal-settings-panel { border-color: var(--line); color: var(--text); background: var(--panel); }
.task-content > p, .attempt-summary { color: var(--muted) !important; }
.learning-note { color: var(--muted); background: var(--atlas-soft); }
.button-quiet, .button-hint { color: var(--text); background: var(--atlas-soft); }
.detail-breadcrumb, .detail-breadcrumb > span { color: var(--muted); }
.detail-breadcrumb a, .text-link, .practice-next a { color: var(--atlas-cyan); }
.flash-success { color: var(--green); background: color-mix(in srgb, var(--green) 10%, var(--panel)); }
.flash-error { color: var(--red); background: color-mix(in srgb, var(--red) 10%, var(--panel)); }
.auth-card { border-color: var(--line); background: var(--panel); }
.auth-description, .auth-form label { color: var(--muted); }
.auth-form input[type="submit"] { color: var(--atlas-accent-text); background: var(--atlas-accent); }
.auth-form input[type="submit"]:hover { filter: brightness(1.08); }
.auth-switch a { color: var(--atlas-cyan); }
.checklist, .topology-card, .topology-node, .launch-progress { border-color: var(--line); background: var(--atlas-deep); }
.checklist > div, .hints, .solution, .solution p, .solution ol, .solution-block h3, .remember-commands code, .terminal-settings-panel > label, .launch-steps li.is-active { color: var(--text); }
.hints ol { color: var(--muted); }
.solution { border-color: var(--line); background: color-mix(in srgb, var(--green) 8%, var(--panel)); }
.solution-block + .solution-block { border-color: var(--line); }
.solution summary { color: var(--green); }
.task-icon { color: var(--atlas-cyan); background: var(--atlas-soft); }
.replacement-note { border-color: var(--atlas-accent); color: var(--text); background: color-mix(in srgb, var(--atlas-accent) 9%, var(--panel)); }
.launch-steps li { color: var(--muted); }
.launch-steps li::before { color: var(--atlas-node-muted); }
.launch-error { border-color: var(--red); color: var(--red); background: color-mix(in srgb, var(--red) 9%, var(--panel)); }
.site-preview-actions code { color: var(--muted); }
.assigned-practice-row { border-color: var(--line); }
.terminal-paste-fallback textarea { color: #e7eff2; }
html[data-theme="light"] .terminal-reconnect { color: #8df2c1; }
html[data-theme="light"] .terminal-action.is-primary { color: #fff; }
html[data-theme="light"] .terminal-empty { color: #aab9c2; }
html[data-theme="light"] .terminal-empty .terminal-glyph { color: #71e1b0; }

@media (max-width: 1100px) {
  .atlas-layout { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto; }
  .atlas-detail { grid-column: 1; grid-row: auto; }
  .atlas-map { min-height: 610px; }
  .atlas-route-nodes { min-height: 480px; }
  .atlas-detail-panel { min-height: 0; }
}

@media (max-width: 900px) {
  .app-shell { margin-left: 0; padding: 0 20px calc(88px + env(safe-area-inset-bottom)); }
  .app-sidebar { inset: auto 0 0; width: 100%; flex-direction: row; padding: 5px 8px calc(5px + env(safe-area-inset-bottom)); border-top: 1px solid var(--line); border-right: 0; box-shadow: 0 -8px 20px #0002; }
  .atlas-brand, .sidebar-bottom { display: none; }
  .sidebar-nav { display: grid; width: 100%; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 4px; padding: 0; }
  .sidebar-link { display: grid; min-height: 52px; justify-items: center; gap: 3px; padding: 5px 2px; font-size: 10px; line-height: 1.1; text-align: center; }
  .sidebar-link span:not(.ui-icon) { display: block; }
  .sidebar-link small { display: none; }
  .sidebar-link .ui-icon { width: 18px; height: 18px; }
  .atlas-topbar { margin: 0 -20px 18px; padding: 0 20px; }
  .topbar-search { max-width: 300px; }
}

@media (max-width: 700px) {
  .atlas-topbar { height: 67px; gap: 9px; }
  .topbar-context { min-width: 0; margin-right: auto; }
  .topbar-context strong { font-size: 12px; }
  .topbar-search { display: none; }
  .topbar-account-name { display: none; }
  .topbar-avatar { width: 31px; height: 31px; }
  .atlas-progress { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 13px 7px; padding: 18px; }
  .atlas-progress-main { grid-column: 1 / -1; }
  .atlas-progress-count { justify-content: center; }
  .atlas-map { min-height: 0; padding: 22px 18px 17px; }
  .atlas-map-heading { flex-direction: column; gap: 8px; }
  .atlas-map-heading p { max-width: 420px; }
  .atlas-catalog-link { width: 100%; }
  .atlas-route-nodes { display: grid; min-height: 0; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 11px; margin: 23px 0; }
  .atlas-node-position { position: static; width: 100%; transform: none; }
  .atlas-node-position--1 { grid-column: 1 / -1; width: min(100%, 230px); justify-self: center; }
  .atlas-node { min-height: 133px; }
  .atlas-legend { justify-content: flex-start; flex-wrap: wrap; }
  .catalog-header { align-items: flex-start; flex-direction: column; gap: 16px; }
  .catalog-header-count { width: 100%; grid-template-columns: auto 1fr auto; align-items: center; justify-items: start; padding: 13px 0 0; border-left: 0; border-top: 1px solid var(--line); }
  .catalog-header-count strong { font-size: 25px; }
  .catalog-header-count a { margin-top: 0; }
}

@media (max-width: 480px) {
  .app-shell { padding-right: 14px; padding-left: 14px; }
  .atlas-topbar { margin-right: -14px; margin-left: -14px; padding: 0 14px; }
  .theme-toggle__option { min-width: 30px; padding: 5px; }
  .theme-toggle__option span:not(.ui-icon) { display: none; }
  .atlas-map-heading h1 { font-size: 22px; }
  .atlas-node { min-height: 131px; padding: 12px 8px; }
  .atlas-node strong { font-size: 11px; }
  .atlas-node-count { font-size: 9px; }
  .atlas-legend { gap: 9px; font-size: 9px; }
  .atlas-detail-panel { padding: 21px 18px; }
  .catalog-header-count { grid-template-columns: auto 1fr; }
  .catalog-header-count a { grid-column: 1 / -1; }
}

@media (max-width: 560px) {
  .terminal-settings-panel { bottom: calc(76px + env(safe-area-inset-bottom)); }
}

@media (prefers-reduced-motion: reduce) {
  .atlas-node, .atlas-start-button, .sidebar-link, .atlas-progress-track > span { transition: none; }
}

/* Design audit refinements */
.terminal-card--prelaunch { min-height: 0; }
.terminal-card--prelaunch .terminal-empty { min-height: 230px; padding: 22px; }
.terminal-card--prelaunch .terminal-glyph { padding: 10px 14px; font-size: 18px; }
.launch-action { display: grid; gap: 9px; margin: 15px 0 19px; padding: 13px; border: 1px solid var(--line); border-radius: 9px; background: var(--atlas-deep); }
.launch-action .replacement-note { max-width: none; margin: 0; }
.launch-helper { margin: 0 !important; color: var(--muted) !important; font-size: 10px !important; line-height: 1.45; }
.check-availability { margin: 9px 0 0; color: var(--muted); font-size: 11px; line-height: 1.5; }
.button-check:disabled { border: 1px solid var(--line); color: var(--muted); background: var(--atlas-soft); opacity: 1; }
.flash-info { color: var(--atlas-cyan); background: color-mix(in srgb, var(--atlas-cyan) 10%, var(--panel)); }
.category-jump-nav { display: flex; gap: 8px; margin: -5px 0 17px; overflow-x: auto; padding: 3px 2px 8px; scrollbar-width: none; }
.category-jump-nav::-webkit-scrollbar { display: none; }
.category-jump-nav a { display: inline-flex; min-height: 36px; flex: 0 0 auto; align-items: center; gap: 8px; padding: 6px 10px; border: 1px solid var(--line); border-radius: 999px; color: var(--muted); background: var(--panel); font-size: 11px; text-decoration: none; white-space: nowrap; }
.category-jump-nav a:hover { border-color: var(--atlas-accent); color: var(--text); background: var(--atlas-soft); }
.category-jump-nav small { color: var(--atlas-cyan); font-size: 10px; }
.practice-block { scroll-margin-top: 98px; }
.theme-toggle__option { min-width: 44px; min-height: 44px; }
html[data-theme="light"] .auth-form input:not([type="submit"]) { border-color: #898596; }

/* Admin progress overview */
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; clip-path: inset(50%); }
.admin-shell { padding-bottom: 44px; }
.admin-page-intro { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; padding: 34px 0 27px; }
.admin-page-intro .eyebrow, .admin-student-hero .eyebrow { margin: 0 0 8px; }
.admin-page-intro h1, .admin-student-hero h1 { margin: 0 0 9px; font-size: clamp(26px, 3vw, 36px); }
.admin-page-intro .lead { max-width: 680px; font-size: 13px; line-height: 1.6; }
.admin-access-badge { max-width: 260px; overflow: hidden; padding: 9px 12px; border: 1px solid var(--line); border-radius: 999px; color: var(--muted); background: var(--panel); font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.admin-overview { grid-template-columns: repeat(4, minmax(0, 1fr)); margin-bottom: 24px; }
.admin-user-panel { margin: 0 0 24px; overflow: hidden; border: 1px solid var(--line); border-radius: 13px; background: var(--panel); }
.admin-panel-heading { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 20px 22px 16px; border-bottom: 1px solid var(--line); }
.admin-panel-heading .eyebrow { margin: 0 0 6px; }
.admin-panel-heading h2 { margin: 0; font-size: 19px; letter-spacing: -.02em; }
.admin-panel-heading > span { color: var(--muted); font-size: 11px; }
.admin-search-form { display: flex; align-items: center; gap: 10px; padding: 16px 20px; border-bottom: 1px solid var(--line); }
.admin-search-field { display: flex; min-width: 180px; height: 42px; flex: 1; align-items: center; gap: 9px; padding: 0 11px; border: 1px solid var(--line); border-radius: 8px; color: var(--muted); background: var(--atlas-field); }
.admin-search-field:focus-within { border-color: var(--atlas-cyan); box-shadow: 0 0 0 3px color-mix(in srgb, var(--atlas-cyan) 16%, transparent); }
.admin-search-field .ui-icon { width: 16px; height: 16px; }
.admin-search-field input { width: 100%; min-width: 0; height: 100%; border: 0; outline: 0; color: var(--text); background: transparent; font-size: 12px; }
.admin-search-form .button { min-height: 42px; padding: 9px 15px; font-size: 11px; }
.admin-reset-link { flex: 0 0 auto; }
.admin-table-wrap { width: 100%; overflow-x: auto; }
.admin-table { width: 100%; border-collapse: collapse; text-align: left; }
.admin-table th, .admin-table td { padding: 13px 14px; border-bottom: 1px solid var(--line); color: var(--muted); font-size: 11px; white-space: nowrap; }
.admin-table th { color: var(--atlas-node-muted); background: var(--atlas-deep); font-size: 9px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.admin-table th:first-child, .admin-table td:first-child { padding-left: 20px; }
.admin-table th:last-child, .admin-table td:last-child { padding-right: 20px; }
.admin-table tbody tr:last-child td { border-bottom: 0; }
.admin-table tbody tr:not(.admin-progress-row):hover { background: color-mix(in srgb, var(--atlas-accent) 4%, var(--panel)); }
.admin-table td > strong { color: var(--text); font-size: 12px; }
.admin-student-link { display: flex; min-width: 190px; align-items: center; gap: 10px; color: var(--text); text-decoration: none; }
.admin-student-link > span:last-child { display: grid; min-width: 0; gap: 4px; }
.admin-student-link strong { overflow: hidden; max-width: 240px; font-size: 12px; text-overflow: ellipsis; }
.admin-student-link small { overflow: hidden; max-width: 240px; color: var(--muted); font-size: 10px; text-overflow: ellipsis; }
.admin-student-avatar { display: grid; width: 34px; height: 34px; flex: 0 0 34px; place-items: center; border: 1px solid var(--line); border-radius: 11px; color: var(--atlas-accent); background: var(--atlas-soft); font-size: 13px; font-weight: 700; }
.admin-student-avatar--large { width: 56px; height: 56px; flex-basis: 56px; border-radius: 16px; font-size: 21px; }
.admin-cell-caption { margin-left: 5px; color: var(--muted); font-size: 10px; }
.admin-xp { color: var(--atlas-accent) !important; font: 600 12px ui-monospace, monospace !important; }
.admin-open-link { color: var(--atlas-cyan); font-size: 10px; text-decoration: none; }
.admin-open-link:hover { text-decoration: underline; }
.admin-progress-row td { padding-top: 0; padding-bottom: 8px; border-bottom: 1px solid var(--line); }
.admin-progress-track { height: 3px; overflow: hidden; border-radius: 999px; background: var(--atlas-soft); }
.admin-progress-track span { display: block; height: 100%; border-radius: inherit; background: var(--atlas-accent); }
.admin-pagination { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px 20px; color: var(--muted); font-size: 11px; }
.admin-pagination > div { display: flex; gap: 8px; }
.admin-pagination .button { min-height: 34px; font-size: 10px; }
.admin-empty-state { display: grid; justify-items: center; gap: 6px; padding: 45px 18px; color: var(--text); text-align: center; }
.admin-empty-state p { margin: 0; color: var(--muted); font-size: 11px; }
.admin-breadcrumb { display: flex; align-items: center; gap: 9px; padding: 8px 0 0; color: var(--muted); font-size: 11px; }
.admin-breadcrumb a { color: var(--atlas-cyan); text-decoration: none; }
.admin-student-hero { display: flex; align-items: center; gap: 16px; padding: 30px 0 25px; border-bottom: 1px solid var(--line); }
.admin-student-hero h1 { margin-bottom: 5px; font-size: 27px; }
.admin-student-hero .lead { font-size: 11px; }
.admin-back-link { margin-left: auto; white-space: nowrap; }
.admin-progress-table { min-width: 680px; }
.admin-progress-table td:first-child { min-width: 260px; white-space: normal; }
.admin-progress-table td:first-child strong, .admin-scenario-stack { display: block; }
.admin-scenario-stack { margin-top: 4px; color: var(--muted); font-size: 10px; }
.admin-status { display: inline-flex; padding: 4px 8px; border: 1px solid var(--line); border-radius: 999px; color: var(--muted); background: var(--atlas-deep); font-size: 10px; }
.admin-status--completed { border-color: color-mix(in srgb, var(--green) 36%, var(--line)); color: var(--green); background: color-mix(in srgb, var(--green) 9%, var(--panel)); }
.admin-status--in_progress { border-color: color-mix(in srgb, var(--atlas-cyan) 38%, var(--line)); color: var(--atlas-cyan); }
.admin-attempt-panel { margin-top: 25px; }
.admin-attempt-row { display: grid; grid-template-columns: 28px minmax(0, 1fr) auto auto; align-items: center; gap: 12px; padding: 12px 20px; border-bottom: 1px solid var(--line); }
.admin-attempt-row:last-child { border-bottom: 0; }
.admin-attempt-row strong { color: var(--text); font-size: 11px; }
.admin-attempt-row time, .admin-attempt-result { color: var(--muted); font-size: 10px; white-space: nowrap; }
.admin-attempt-result.is-success { color: var(--green); }
.admin-attempt-mark { display: grid; width: 26px; height: 26px; place-items: center; border-radius: 8px; color: var(--atlas-cyan); background: var(--atlas-soft); }
.admin-attempt-mark.is-success { color: var(--green); }

@media (max-width: 900px) {
  .admin-overview { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 600px) {
  .admin-page-intro { align-items: flex-start; flex-direction: column; gap: 13px; padding: 25px 0 20px; }
  .admin-access-badge { max-width: 100%; }
  .admin-search-form { flex-wrap: wrap; padding: 13px; }
  .admin-search-field { flex-basis: 100%; }
  .admin-panel-heading { padding-right: 14px; padding-left: 14px; }
  .admin-pagination { align-items: flex-start; flex-direction: column; padding-right: 14px; padding-left: 14px; }
  .admin-student-hero { align-items: flex-start; flex-wrap: wrap; gap: 12px; padding-top: 22px; }
  .admin-student-hero > div { min-width: 0; flex: 1; }
  .admin-student-hero .lead { overflow-wrap: anywhere; }
  .admin-back-link { margin-left: 0; }
  .admin-attempt-row { grid-template-columns: 28px minmax(0, 1fr); gap: 8px 10px; }
  .admin-attempt-row .admin-attempt-result, .admin-attempt-row time { grid-column: 2; }
}

@media (max-width: 850px) {
  .workspace--prelaunch .task-card { order: -1; }
  .workspace--prelaunch .terminal-card--prelaunch { order: 0; }
  .terminal-card--prelaunch .terminal-empty { min-height: 170px; }
}

@media (max-width: 700px) {
  .catalog-header { gap: 9px; margin-bottom: 17px; padding: 17px 0 16px; }
  .catalog-header .atlas-overline { margin-bottom: 5px; }
  .catalog-header h1 { margin-bottom: 6px; font-size: 28px; }
  .catalog-header .lead { margin-bottom: 0; font-size: 12px; line-height: 1.5; }
  .catalog-header-count { display: flex; width: auto; align-items: center; gap: 8px; padding: 0; border: 0; }
  .catalog-header-count strong { font-size: 17px; }
  .catalog-header-count a { margin: 0 0 0 auto; }
  .catalog-tools { gap: 9px; margin-bottom: 13px; }
  .category-jump-nav { margin-bottom: 14px; }
}

@media (max-width: 560px) {
  .progress-overview { gap: 6px; margin: 10px 0 4px; padding: 10px 12px; }
  .progress-copy { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 4px 8px; }
  .progress-copy .eyebrow { display: none; }
  .progress-copy strong { font-size: 12px; }
  .progress-copy > span:last-child { font-size: 10px; }
  .progress-track { height: 5px; }
  .intro { padding: 21px 0 16px; }
  .terminal-card--prelaunch .terminal-empty { min-height: 155px; padding: 17px 14px; }
  .terminal-card--prelaunch .terminal-glyph { display: none; }
  .terminal-card--prelaunch .replacement-note { margin: 0; }
}

@media (max-width: 480px) {
  .theme-toggle__option { min-width: 44px; min-height: 44px; padding: 5px; }
}
