:root {
    --bg: #f3f5f7;
    --surface: #fff;
    --text: #17202a;
    --muted: #617080;
    --line: #d9e0e7;
    --brand: #1f5eff;
    --brand-dark: #1548c6;
    --success: #19764a;
    --success-bg: #e9f7ef;
    --danger: #b42318;
    --danger-bg: #fff0ee;
    --warning-bg: #fff8df;
    --radius: 14px;
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--text); line-height: 1.55; }
a { color: var(--brand-dark); }
input, select, textarea, button { font: inherit; }
input[type="text"], input[type="password"], input[type="number"], input[type="email"], select, textarea {
    width: 100%; padding: .72rem .8rem; border: 1px solid #b8c3ce; border-radius: 8px; background: #fff;
}
input:focus, select:focus, textarea:focus { outline: 3px solid #cbd8ff; border-color: var(--brand); }
.site-header {
    min-height: 64px; padding: 0 max(1rem, calc((100vw - 1180px) / 2));
    display: flex; align-items: center; gap: 2rem; background: #101828; color: #fff;
}
.site-header a { color: #fff; text-decoration: none; }
.brand { max-width: 360px; font-size: 1rem; font-weight: 800; line-height: 1.2; }
.site-header nav { display: flex; gap: 1.25rem; flex: 1; }
.header-login { margin-left: auto; padding: .45rem .75rem; border: 1px solid #667085; border-radius: 8px; font-weight: 700; }
.user-menu { display: flex; align-items: center; gap: .9rem; }
.user-menu form { margin: 0; }
.page-shell { max-width: 1180px; margin: 0 auto; padding: 2rem 1rem 5rem; }
.page-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 2rem; margin-bottom: 2rem; }
.page-heading h1 { margin: .15rem 0 .4rem; font-size: clamp(2rem, 4vw, 3.2rem); line-height: 1.1; }
.portal-hero { margin-bottom: 2.5rem; padding: clamp(1.5rem, 4vw, 3rem); border-radius: 20px; color: #fff; background: linear-gradient(135deg, #101828, #193a77 62%, #1f5eff); box-shadow: 0 18px 45px rgba(16, 24, 40, .18); }
.portal-hero h1 { max-width: 850px; margin: .25rem 0 .8rem; font-size: clamp(2.1rem, 5vw, 4rem); line-height: 1.05; }
.portal-hero p:not(.eyebrow) { max-width: 720px; color: #dbe6ff; font-size: 1.08rem; }
.portal-hero .eyebrow { color: #b9cbff; }
.hero-actions { display: flex; flex-wrap: wrap; gap: .7rem; margin-top: 1.4rem; }
.catalog-heading { margin-bottom: 1rem; }
.catalog-heading > p { max-width: 520px; }
.course-card { display: flex; flex-direction: column; align-items: flex-start; }
.course-card .button { margin-top: auto; }
.public-access-note { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin: 0 0 1.5rem; padding: 1rem 1.2rem; border: 1px solid #b7c8fa; border-radius: 11px; background: #f4f7ff; }
.public-access-note div { display: flex; flex-direction: column; }
.eyebrow { margin: 0 0 .3rem; color: var(--brand-dark); font-size: .78rem; font-weight: 800; letter-spacing: .11em; text-transform: uppercase; }
.muted, .meta { color: var(--muted); }
.meta { font-size: .86rem; }
.breadcrumbs { margin-bottom: 1.5rem; color: var(--muted); }
.messages { display: grid; gap: .5rem; margin-bottom: 1rem; }
.message { padding: .75rem 1rem; border-radius: 9px; background: #e7efff; }
.message-success { color: var(--success); background: var(--success-bg); }
.message-error { color: var(--danger); background: var(--danger-bg); }
.card-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 1rem; margin-bottom: 2.5rem; }
.card, .content-panel, .narrow-card, .auth-card {
    background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.35rem; box-shadow: 0 8px 28px rgba(16, 24, 40, .05);
}
.card h2, .card h3 { margin-top: .2rem; }
.card.compact { padding: 1rem 1.2rem; }
.teacher-group-card { display: flex; flex-direction: column; }
.group-student-count { margin: .35rem 0 1rem; padding: .55rem .7rem; border-radius: 8px; background: #f3f6f9; }
.group-practice-list { display: grid; gap: .9rem; margin-bottom: 1.2rem; }
.group-practice-progress { display: grid; gap: .4rem; }
.group-practice-heading { display: grid; gap: .15rem; font-size: .88rem; }
.group-practice-heading span:last-child { color: var(--muted); }
.group-practice-progress progress { width: 100%; height: .65rem; accent-color: var(--brand); }
.teacher-group-card .button-group { flex-wrap: wrap; margin-top: auto; }
.button {
    display: inline-flex; align-items: center; justify-content: center; min-height: 42px; padding: .55rem .9rem;
    border: 1px solid #a9b5c2; border-radius: 8px; color: var(--text); background: #fff; font-weight: 700; text-decoration: none; cursor: pointer;
}
.button:hover { background: #f3f6f9; }
.button.primary { color: #fff; background: var(--brand); border-color: var(--brand); }
.button.primary:hover { background: var(--brand-dark); }
.button.secondary { color: var(--brand-dark); border-color: #aec2ff; background: #f4f7ff; }
.button.danger-button { color: var(--danger); border-color: #e7aaa4; background: var(--danger-bg); }
.button.danger-button:hover { background: #ffe1dd; }
.link-button { padding: 0; color: var(--brand-dark); background: none; border: 0; text-decoration: underline; cursor: pointer; }
.site-header .link-button { color: #fff; }
.button-group { display: flex; gap: .5rem; }
.empty-state { padding: 1.25rem; border: 1px dashed #adb8c3; border-radius: 10px; color: var(--muted); background: rgba(255,255,255,.6); }
.block-section { margin: 2.5rem 0; }
.section-heading { display: flex; justify-content: space-between; align-items: center; gap: 1rem; }
.section-heading h2 { margin: .2rem 0; }
.practice-list { display: grid; gap: .7rem; }
.practice-row {
    display: grid; grid-template-columns: 52px 1fr auto; align-items: center; gap: 1rem;
    padding: 1rem; background: var(--surface); border: 1px solid var(--line); border-radius: 11px;
}
.practice-number {
    width: 44px; height: 44px; display: grid; place-items: center; border-radius: 50%;
    color: var(--brand-dark); background: #e9efff; font-weight: 800;
}
.practice-copy h3 { margin: 0; }
.practice-copy p { margin: .25rem 0; }
.practice-action { display: grid; justify-items: end; gap: .35rem; }
.status { display: inline-flex; width: fit-content; padding: .2rem .55rem; border-radius: 999px; color: #43505d; background: #edf1f4; font-size: .82rem; font-weight: 700; }
.status-completed, .status-accepted { color: var(--success); background: var(--success-bg); }
.status-needs_review { color: #854d0e; background: var(--warning-bg); }
.status-revision, .status-void, .danger { color: var(--danger); background: var(--danger-bg); }
.practice-heading { align-items: center; }
.score-panel, .timer-panel {
    min-width: 150px; padding: 1rem; display: grid; justify-items: end; border: 1px solid var(--line); border-radius: 12px; background: #fff;
}
.score-panel strong, .timer-panel strong { font-size: 1.6rem; }
.score-panel small { color: var(--muted); font-weight: 700; }
.timer-panel small { color: var(--muted); }
.lab-meta { display: flex; flex-wrap: wrap; gap: .5rem; margin: -1rem 0 1.5rem; }
.lab-meta span { padding: .3rem .65rem; border-radius: 999px; background: #e8edf2; font-size: .85rem; }
.content-admin-bar { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin: -1rem 0 1.5rem; padding: 1rem 1.2rem; border: 1px solid #b7c8fa; border-radius: 11px; background: #f4f7ff; }
.content-admin-bar div { display: grid; }
.content-admin-bar span { color: var(--muted); font-size: .9rem; }
.step-heading-actions { display: flex; align-items: center; justify-content: flex-end; flex-wrap: wrap; gap: .5rem; }
.compact-button { min-height: 34px; padding: .35rem .65rem; font-size: .86rem; }
.admin-add-controls { display: flex; align-items: center; flex-wrap: wrap; gap: .35rem .75rem; margin: .25rem 0 .9rem; padding: .65rem .8rem; border: 1px dashed #9cb1ee; border-radius: 8px; background: #f8faff; font-size: .9rem; }
.admin-add-controls a { font-weight: 700; }
.admin-editable-block { position: relative; min-height: 54px; padding-top: 3.55rem !important; outline: 1px dashed rgba(54, 87, 190, .32); outline-offset: 2px; }
.admin-block-actions { position: absolute; z-index: 2; top: .55rem; right: .55rem; display: flex; align-items: center; justify-content: flex-end; gap: .4rem; }
.admin-block-actions form { margin: 0; }
.admin-block-actions .button { min-width: auto; }
.add-hint-button { margin-top: .75rem; }
.admin-expected-answer { margin: .85rem 0; padding: 1rem; border: 1px solid #b7c8fa; border-radius: 10px; background: #f7f9ff; }
.admin-expected-heading { display: flex; align-items: center; justify-content: space-between; gap: .8rem; }
.admin-expected-heading h2, .admin-expected-heading h4 { margin: 0; }
.admin-expected-heading h4 { font-size: 1rem; }
.admin-expected-value { margin-top: .65rem; padding: .75rem .85rem; border-radius: 8px; background: #fff; font-weight: 750; overflow-wrap: anywhere; }
.admin-expected-answer > p { margin: .55rem 0 0; color: var(--muted); font-size: .88rem; }
.answer-mode { display: inline-flex; width: fit-content; padding: .2rem .55rem; border-radius: 999px; font-size: .78rem; font-weight: 800; }
.answer-mode-common { color: #155e55; background: #dff7ef; }
.answer-mode-individual { color: #694100; background: #fff0bd; }
.content-editor-panel { max-width: 920px; }
.content-editor-heading { margin-bottom: 1rem; }
.content-editor-panel .markdown-editor { min-height: 30rem; font-family: "SFMono-Regular", Consolas, monospace; line-height: 1.5; }
.editor-expected-answer { max-width: 920px; }
.editor-expected-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: .75rem; max-width: 920px; }
.editor-expected-list .editor-expected-answer { margin: 0; }
.disabled-field { padding: .8rem; border-radius: 9px; background: #f3f5f7; }
.disabled-field textarea, .disabled-field input { color: #4b5563; background: #e9edf1; }
.content-editor-actions { display: flex; justify-content: space-between; gap: 1rem; padding-top: .5rem; border-top: 1px solid var(--line); }
.delete-content-panel { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; max-width: 920px; border-color: #e7aaa4; background: #fff8f7; }
.delete-content-panel h2 { margin: 0; color: var(--danger); }
.delete-content-panel p { margin: .35rem 0 0; }
.content-panel { margin: 1rem 0; }
.content-panel pre { position: relative; padding: 2.7rem 1rem 1rem; overflow-x: auto; color: #e8edf2; background: #17202a; border-radius: 8px; }
.content-panel code { font-family: "SFMono-Regular", Consolas, monospace; }
.copy-code { position: absolute; top: .55rem; right: .55rem; padding: .3rem .55rem; border: 1px solid #617080; border-radius: 6px; color: #fff; background: #344054; font-size: .78rem; cursor: pointer; }
.copy-code:hover { background: #475467; }
.theory-reminder, .study-note { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin: 1rem 0; padding: 1rem 1.2rem; border: 1px solid #b7c8fa; border-radius: 11px; background: #f4f7ff; }
.theory-reminder div, .study-note { display: flex; }
.theory-reminder div { flex-direction: column; }
.study-note { align-items: flex-start; justify-content: flex-start; flex-direction: column; }
.theory-content { max-width: 900px; }
.theory-content h2 { margin-top: 2.2rem; padding-top: .5rem; border-top: 1px solid var(--line); }
.theory-content table { width: 100%; border-collapse: collapse; }
.theory-content th, .theory-content td { padding: .6rem; border: 1px solid var(--line); text-align: left; }
.next-actions { display: flex; flex-wrap: wrap; gap: .7rem; }
.step-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; }
.step-heading h2 { margin: .15rem 0 1rem; }
.step-time { white-space: nowrap; padding: .3rem .6rem; border-radius: 999px; color: var(--muted); background: #edf1f4; font-size: .84rem; }
.instruction-box { margin: .8rem 0; padding: .9rem 1rem; border-left: 4px solid #98a2b3; border-radius: 7px; background: #f8fafc; }
.instruction-box h3 { margin: 0 0 .4rem; font-size: 1rem; }
.instruction-box > :last-child { margin-bottom: 0; }
.instruction-objective { border-left-color: var(--brand); background: #f4f7ff; }
.instruction-theory { border-left-color: #7a5af8; background: #f7f5ff; }
.instruction-actions { border-left-color: #617080; }
.instruction-result { border-left-color: var(--success); background: var(--success-bg); }
.troubleshooting { margin: .8rem 0; padding: .8rem 1rem; border: 1px solid #ead58a; border-radius: 8px; background: var(--warning-bg); }
.troubleshooting summary { font-weight: 750; cursor: pointer; }
.config-list { display: grid; grid-template-columns: max-content 1fr; gap: .35rem 1rem; }
.config-list dt { font-weight: 700; }
.config-list dd { margin: 0; }
.download-list li { margin: .5rem 0; }
.download-list span { display: block; color: var(--muted); font-size: .85rem; }
.checkpoint { margin-top: 1.25rem; padding: 1rem; border: 1px solid var(--line); border-left: 5px solid #96a3b1; border-radius: 9px; background: #fbfcfd; }
.checkpoint-correct { border-left-color: var(--success); background: var(--success-bg); }
.checkpoint-title { display: flex; justify-content: space-between; gap: 1rem; }
.checkpoint-title h3 { margin-top: 0; }
.answer-form { display: grid; grid-template-columns: 1fr auto; align-items: end; gap: .6rem; }
.answer-form label { grid-column: 1 / -1; font-weight: 700; }
.answer-form textarea, .answer-form > div, .answer-form ul, .answer-form .meta { grid-column: 1 / -1; }
.answer-form ul { display: grid; gap: .45rem; margin: 0; padding: 0; list-style: none; }
.answer-form ul label { display: flex; align-items: flex-start; gap: .65rem; padding: .65rem .75rem; border: 1px solid var(--line); border-radius: 8px; background: #fff; cursor: pointer; }
.answer-form ul input { width: auto; margin-top: .3rem; }
.success-text { color: var(--success); font-weight: 700; }
.saved-text { color: #694100; font-weight: 700; }
.error-text { color: var(--danger); }
.rubric-note { margin: .75rem 0; padding: .7rem .9rem; border: 1px solid #c8bdf7; border-radius: 8px; background: #f7f5ff; }
.rubric-note summary { font-weight: 750; cursor: pointer; }
.case-briefing { border-top: 5px solid #7a5af8; }
.browser-task { max-width: 900px; font-size: 1.04rem; }
.browser-task > :first-child { margin-top: 0; }
.attempt-summary { margin: 1rem 0; padding: 1rem 1.15rem; border: 1px solid #9cc9ae; border-radius: 10px; background: #f5fbf7; }
.attempt-summary h3 { margin: .15rem 0 .35rem; }
.attempt-summary-groups { display: grid; gap: .75rem; margin-top: 1rem; }
.attempt-summary-groups section { padding: .8rem .9rem; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
.attempt-summary-groups h4 { margin: 0 0 .6rem; }
.attempt-summary-groups dl { display: grid; grid-template-columns: minmax(180px, 1fr) minmax(220px, 1.25fr); gap: .45rem 1rem; margin: 0; }
.attempt-summary-groups dt { font-weight: 700; }
.attempt-summary-groups dd { margin: 0; overflow-wrap: anywhere; }
.previous-analysis { border-color: #c8bdf7; background: #f7f5ff; }
.previous-analysis blockquote { margin: .8rem 0 0; padding: .8rem 1rem; border-left: 4px solid #7a5af8; background: #fff; overflow-wrap: anywhere; }
.step-tool-link { margin: 1rem 0 1.25rem; }
.training-note, .training-notice { padding: .75rem .9rem; border: 1px solid #d7c98d; border-radius: 9px; color: #5d4a14; background: #fffbea; }
.training-notice { margin: 1rem 0; }
.competitor-memo { margin: 1rem 0; padding: 1rem 1.15rem; border: 1px solid #d4c7f5; border-radius: 10px; background: #f8f6ff; }
.competitor-memo summary { color: #4d349f; font-weight: 850; cursor: pointer; }
.competitor-memo ol { margin-bottom: 0; }
.case-code { display: inline-flex; padding: .3rem .65rem; border-radius: 999px; color: #4d349f; background: #eee9ff; font-family: "SFMono-Regular", Consolas, monospace; }
.event-inject { margin: 1rem 0; padding: 1.1rem 1.2rem; border: 2px solid #d3aa55; border-radius: 10px; background: linear-gradient(135deg, #fff8df, #fffdf4); box-shadow: 0 8px 22px rgba(105, 65, 0, .08); }
.review-answer-list { display: grid; min-width: 0; gap: 1rem; margin: 1.5rem 0; }
.review-answer { min-width: 0; overflow: hidden; padding: 1rem; border: 1px solid var(--line); border-radius: 10px; background: #f8fafc; }
.review-answer h2 { margin-top: 0; font-size: 1.15rem; }
.review-answer blockquote { max-width: 100%; margin: .75rem 0; padding: .9rem 1rem; border-left: 4px solid #7a5af8; background: #fff; white-space: normal; overflow-wrap: anywhere; word-break: break-all; }
.review-feedback { border-color: #9cc9ae; background: #f5fbf7; }
.review-feedback-revision { border-color: #e7aaa4; background: #fff8f7; }
.review-feedback blockquote { margin: .8rem 0; padding: .8rem 1rem; border-left: 4px solid currentColor; background: rgba(255,255,255,.75); overflow-wrap: anywhere; word-break: break-word; }
.review-feedback-list { display: grid; gap: .65rem; }
.review-feedback-list article { padding: .8rem 1rem; border: 1px solid var(--line); border-radius: 9px; background: #fff; }
.review-feedback-list h3 { margin: 0 0 .25rem; font-size: 1rem; }
.review-feedback-list p { margin: 0; }
.review-form { display: grid; gap: 1rem; margin-top: 1.2rem; }
.review-score-box { display: grid; gap: .45rem; padding: 1rem; border: 1px solid var(--line); border-radius: 10px; }
.review-score-box legend { padding: 0 .35rem; font-weight: 800; }
.review-score-box input { max-width: 180px; }
.errorlist { margin: .25rem 0; color: var(--danger); }
.osint-hero { margin-bottom: 1rem; padding: clamp(1.4rem, 4vw, 2.5rem); border-radius: 18px; color: #eefcf7; background: linear-gradient(135deg, #102a27, #155e55 65%, #14866f); box-shadow: 0 16px 38px rgba(15, 61, 54, .18); }
.osint-hero.compact { padding-block: 1.7rem; }
.osint-hero h1 { margin: .15rem 0 .5rem; font-size: clamp(2rem, 5vw, 3.6rem); line-height: 1.05; }
.osint-hero .eyebrow { color: #9be1d2; }
.synthetic-warning { margin: 1rem 0; padding: .9rem 1.1rem; border: 1px solid #e1bd63; border-radius: 10px; background: #fff8df; }
.searchlab-form { display: grid; gap: .4rem; margin-top: 1.2rem; }
.searchlab-form label { font-weight: 800; }
.searchlab-form > div { display: grid; grid-template-columns: 1fr auto; gap: .55rem; }
.searchlab-form input[type="search"] { min-width: 0; padding: .75rem .85rem; border: 1px solid #9fb5b0; border-radius: 8px; }
.source-catalog { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: .6rem; margin-top: .8rem; }
.source-catalog a { display: grid; padding: .75rem; border: 1px solid var(--line); border-radius: 8px; color: var(--text); background: #fff; text-decoration: none; }
.source-catalog a:hover { border-color: #57a895; background: #f1fbf8; }
.source-catalog small { color: var(--muted); }
.search-results { display: grid; gap: .8rem; }
.search-result { padding: 1.1rem 1.25rem; border: 1px solid var(--line); border-radius: 11px; background: #fff; }
.search-result h2 { margin: .15rem 0 .35rem; font-size: 1.22rem; }
.synthetic-source { max-width: 900px; margin: 1rem auto; overflow: hidden; border: 1px solid #cfd7de; border-radius: 12px; background: #fff; box-shadow: 0 12px 32px rgba(16, 24, 40, .09); }
.synthetic-source header { padding: 1.4rem clamp(1.2rem, 4vw, 2.5rem); border-bottom: 1px solid var(--line); background: #f7faf9; }
.synthetic-source h1 { margin: .25rem 0 .5rem; line-height: 1.15; }
.source-brand { margin: 0; color: #155e55; font-weight: 900; letter-spacing: .05em; text-transform: uppercase; }
.source-body { padding: clamp(1.2rem, 4vw, 2.5rem); font-size: 1.05rem; }
.source-body span[id] { display: block; margin: .8rem 0; padding: .8rem 1rem; border-left: 4px solid #57a895; background: #f1fbf8; }
.archived-source { border-color: #d3aa55; }
.archived-source header { background: #fff8df; }
.archive-badge { display: inline-flex; margin-top: .45rem; padding: .2rem .55rem; border-radius: 999px; color: #694100; background: #f8df9a; font-weight: 800; }
.evidence-footer { max-width: 900px; margin-inline: auto; }
.source-actions { max-width: 900px; margin: 1rem auto; }
.editor-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
.editor-document { display: grid; gap: .55rem; padding: 1rem; border: 1px solid var(--line); border-radius: 11px; background: #fff; }
.editor-document label { font-weight: 800; }
.editor-document textarea { width: 100%; min-height: 10rem; resize: vertical; }
.editor-action { grid-column: 1 / -1; }
.editor-result { display: grid; gap: .35rem; margin-top: 1rem; }
.editor-success { padding: .85rem 1rem; border: 1px solid #9ad0b4; border-radius: 9px; color: var(--success); background: var(--success-bg); }
.editor-success code { width: fit-content; padding: .25rem .5rem; border-radius: 5px; color: #fff; background: #155e55; font-size: 1.08rem; }
.hint { margin-top: .75rem; padding: .75rem 1rem; border-radius: 8px; background: var(--warning-bg); }
.activation-panel { border-top: 5px solid var(--brand); }
.activation-ready { border-top-color: var(--success); }
.activation-action, .activation-waiting, .activation-success { margin-top: 1.2rem; padding: 1.1rem; border-radius: 10px; }
.activation-action { border: 1px solid #b7c8fa; background: #f4f7ff; }
.activation-action h3, .activation-waiting p, .activation-success p { margin-top: 0; }
.activation-form { display: grid; grid-template-columns: minmax(240px, 1fr) auto; align-items: end; gap: .7rem; max-width: 680px; }
.activation-form label { grid-column: 1 / -1; font-weight: 800; }
.activation-code-input { font-family: "SFMono-Regular", Consolas, monospace; font-size: 1.15rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.activation-waiting { border: 1px solid #ead58a; background: var(--warning-bg); }
.activation-success { border: 1px solid #9ad0b4; background: var(--success-bg); }
.waiting-dots { display: flex; gap: .35rem; }
.waiting-dots span { width: 9px; height: 9px; border-radius: 50%; background: var(--brand); animation: waiting-pulse 1.2s infinite ease-in-out; }
.waiting-dots span:nth-child(2) { animation-delay: .15s; }
.waiting-dots span:nth-child(3) { animation-delay: .3s; }
@keyframes waiting-pulse { 0%, 80%, 100% { opacity: .25; transform: scale(.8); } 40% { opacity: 1; transform: scale(1); } }
.locked-panel { display: flex; align-items: center; gap: 1rem; border-style: dashed; color: var(--muted); background: #f7f8fa; box-shadow: none; }
.locked-panel h2, .locked-panel p { margin: 0; }
.lock-icon { font-size: 1.7rem; }
.locked-step { color: var(--muted); background: #f7f8fa; box-shadow: none; }
.checkpoint-locked { background: #f3f5f7; }
.facts { display: flex; flex-wrap: wrap; gap: .75rem; }
.facts div { min-width: 130px; padding: .75rem; background: #f3f6f9; border-radius: 8px; }
.facts dt { color: var(--muted); font-size: .8rem; }
.facts dd { margin: 0; font-size: 1.2rem; font-weight: 800; }
.test-question h2 { font-size: 1.15rem; }
.choice { display: flex; align-items: flex-start; gap: .65rem; margin: .5rem 0; padding: .6rem; border: 1px solid var(--line); border-radius: 8px; cursor: pointer; }
.choice input { margin-top: .3rem; }
.sticky-submit { position: sticky; bottom: 1rem; display: flex; justify-content: flex-end; padding: 1rem; border-radius: 11px; background: rgba(16, 24, 40, .92); }
.test-result-card { border-top: 5px solid var(--brand); }
.result-card-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; padding-bottom: 1rem; border-bottom: 1px solid var(--line); }
.result-card-header h2 { margin: .15rem 0 0; }
.variant-code { padding: .65rem .8rem; border-radius: 8px; color: #fff; background: var(--brand-dark); font-family: "SFMono-Regular", Consolas, monospace; letter-spacing: .06em; white-space: nowrap; }
.result-grid { display: grid; grid-template-columns: repeat(2, minmax(220px, 1fr)); gap: .8rem; margin: 1.2rem 0; }
.result-grid div { padding: .85rem 1rem; border-radius: 8px; background: #f3f6f9; }
.result-grid dt { color: var(--muted); font-size: .8rem; }
.result-grid dd { margin: .25rem 0 0; font-weight: 800; }
.result-grid code { color: var(--brand-dark); font-size: 1.05rem; }
.sdo-screenshot-note { display: grid; gap: .3rem; padding: 1rem 1.1rem; border: 1px solid #ead58a; border-radius: 10px; background: var(--warning-bg); }
.result-actions { flex-wrap: wrap; margin-top: 1rem; }
.table-scroll { overflow-x: auto; background: #fff; border: 1px solid var(--line); border-radius: 11px; }
.progress-table { width: 100%; border-collapse: collapse; white-space: nowrap; }
.progress-table th, .progress-table td { padding: .65rem; border-bottom: 1px solid var(--line); text-align: center; }
.progress-table thead th { position: sticky; top: 0; background: #eef2f6; }
.progress-table tbody th { position: sticky; left: 0; z-index: 1; min-width: 220px; text-align: left; background: #fff; }
.progress-table small { display: block; color: var(--muted); }
.score-cell.status-completed, .score-cell.status-accepted { color: var(--success); background: var(--success-bg); }
.score-cell.status-needs_review { color: #854d0e; background: var(--warning-bg); }
.management-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 1rem; }
.management-card h2 { margin-top: .2rem; }
.teacher-course-list { display: grid; gap: .65rem; margin-bottom: 1.25rem; }
.teacher-course-list > div { display: flex; align-items: center; flex-wrap: wrap; gap: .45rem 1rem; padding: .75rem .9rem; border: 1px solid var(--line); border-radius: 9px; background: #f8fafc; }
.teacher-course-list > div > strong { flex: 1 1 280px; }
.teacher-course-list form, .teacher-group-settings form { margin: 0; }
.form-stack { display: grid; gap: 1rem; }
.form-field { display: grid; gap: .35rem; }
.form-field label { font-weight: 750; }
.form-field small { color: var(--muted); }
.field-errors, .field-errors ul { margin: 0; color: var(--danger); }
.student-table { width: 100%; border-collapse: collapse; }
.student-table th, .student-table td { padding: .7rem; border-bottom: 1px solid var(--line); text-align: left; }
.student-table thead th { background: #eef2f6; }
.inline-form { margin: 0; }
.auth-card, .narrow-card { max-width: 620px; margin: 3rem auto; }
.auth-layout { display: grid; grid-template-columns: minmax(280px, .8fr) minmax(420px, 1.2fr); align-items: start; gap: 1rem; max-width: 940px; margin: 1.5rem auto; }
.auth-layout .auth-card { width: 100%; max-width: none; margin: 0; }
.auth-card { max-width: 420px; }
.auth-card h1, .auth-card h2 { margin: .15rem 0 .7rem; }
.auth-card form { display: grid; gap: .6rem; }
.registration-form { margin-top: 1rem; }
.registration-form .button { margin-top: .35rem; }
@media (max-width: 760px) {
    .site-header { align-items: flex-start; flex-wrap: wrap; gap: .75rem; padding-block: .8rem; }
    .site-header nav { order: 3; flex-basis: 100%; flex-wrap: wrap; gap: .55rem 1rem; }
    .user-menu { margin-left: auto; }
    .page-heading, .section-heading { align-items: stretch; flex-direction: column; }
    .result-card-header { flex-direction: column; }
    .result-grid { grid-template-columns: 1fr; }
    .practice-row { grid-template-columns: 44px 1fr; }
    .practice-action { grid-column: 1 / -1; justify-items: stretch; }
    .answer-form { grid-template-columns: 1fr; }
    .searchlab-form > div { grid-template-columns: 1fr; }
    .activation-form { grid-template-columns: 1fr; }
    .activation-form label { grid-column: auto; }
    .theory-reminder { align-items: stretch; flex-direction: column; }
    .public-access-note { align-items: stretch; flex-direction: column; }
    .step-heading { flex-direction: column; }
    .step-heading-actions { justify-content: flex-start; }
    .content-admin-bar, .delete-content-panel { align-items: stretch; flex-direction: column; }
    .admin-expected-heading { align-items: flex-start; flex-direction: column; }
    .admin-block-actions { position: static; justify-content: flex-start; margin: -.2rem 0 .8rem; }
    .admin-editable-block { padding-top: 1rem !important; }
    .config-list { grid-template-columns: minmax(0, 1fr); }
    .config-list dd { overflow-wrap: anywhere; }
    .attempt-summary-groups dl { grid-template-columns: minmax(0, 1fr); }
    .attempt-summary-groups dd { margin-bottom: .35rem; }
    .editor-grid { grid-template-columns: 1fr; }
    .auth-layout { grid-template-columns: 1fr; }
    .page-heading .button-group { align-items: stretch; flex-direction: column; }
}

@media print {
    .site-header, .site-footer, .breadcrumbs, .result-actions { display: none !important; }
    .page-shell { max-width: none; padding: 0; }
    .test-result-card { box-shadow: none; }
}
