/* Tema da área do aluno (index.html, body.student-app): visual sóbrio e institucional.
   Os seletores começam por body.student-app para prevalecer sobre style.css e student-study.css
   (inclusive as regras html[data-theme="dark"] de mesma especificidade, por virem depois). */
body.student-app {
  --ink: #1d2733; --ink-2: #455263; --ink-3: #6b7685;
  --line: #dce1e7; --line-soft: #edf0f3; --surface: #fff; --canvas: #f4f5f7; --subtle: #f8f9fb;
  --accent: #0b4a85; --accent-hover: #083a69; --accent-soft: #e9f0f7; --accent-ink: #0b4a85;
  --pending: #b26a00; --ongoing: #0b4a85; --done: #2a7a4c; --danger: #b42318; --neutral: #8b95a3;
  --code-bg: #1f2933; --code-ink: #e5e9f0;
  --radius: 6px; --sticky-top: 72px;
  --font: "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
  font-family: var(--font); font-size: 14px; line-height: 1.5; -webkit-font-smoothing: antialiased;
}
html[data-theme="dark"] body.student-app {
  --ink: #e4e8ee; --ink-2: #b6bfcb; --ink-3: #8d97a5;
  --line: #2d3541; --line-soft: #232a34; --surface: #161b22; --canvas: #0e1217; --subtle: #1b2129;
  --accent: #6aa3dc; --accent-hover: #8cb9e6; --accent-soft: #1b2a3b; --accent-ink: #9cc4ee;
  --pending: #e0a43a; --ongoing: #6aa3dc; --done: #5cc28a; --danger: #f08b84; --neutral: #7d8796;
  --code-bg: #0b0f14; --code-ink: #dfe5ee;
}
html body.student-app,
html[data-theme] body.student-app { background: var(--canvas); color: var(--ink); }
html:has(body.student-app) { background: #f4f5f7; }
html[data-theme="dark"]:has(body.student-app) { background: #0e1217; }
body.student-app :is(h1, h2, h3, h4) { color: var(--ink); font-weight: 600; letter-spacing: -.005em; }
body.student-app .muted { color: var(--ink-3); }
body.student-app .eyebrow { margin: 0 0 4px; color: var(--ink-3); font-size: 12.5px; font-weight: 600; letter-spacing: 0; text-transform: none; }
body.student-app .visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Barra superior */
body.student-app .topbar { height: 56px; border-bottom: 1px solid var(--line); background: var(--surface); box-shadow: none; }
body.student-app .brand { gap: 10px; color: var(--ink); }
body.student-app .brand-symbol { width: 30px; height: 30px; border-radius: var(--radius); background: var(--accent); color: #fff; font-size: 16px; font-weight: 700; }
html[data-theme="dark"] body.student-app .brand-symbol { color: #0e1217; }
body.student-app .brand strong { color: var(--ink); font-size: 15px; font-weight: 600; }
body.student-app .brand small { color: var(--ink-3); font-size: 11.5px; }
body.student-app .brand-title { color: var(--ink); font-size: 16px; font-weight: 600; }
body.student-app .top-badge { margin: 0; padding: 6px 12px; border: 0; border-right: 1px solid var(--line); border-radius: 0; background: none; color: var(--ink-2); font: inherit; font-size: 13px; cursor: pointer; }
body.student-app .top-badge:hover { color: var(--accent-ink); text-decoration: underline; text-underline-offset: 3px; }
body.student-app .accessibility-button { min-height: 32px; padding: 0 10px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); color: var(--ink-2); font-size: 13px; font-weight: 500; box-shadow: none; }
body.student-app .accessibility-button:hover { background: var(--subtle); color: var(--ink); }

/* Superfícies, botões e campos */
body.student-app .paper { border: 1px solid var(--line); border-radius: 8px; background: var(--surface); box-shadow: none; }
body.student-app :is(.primary, .secondary, .finish) { min-height: 34px; padding: 7px 14px; border-radius: var(--radius); font-size: 13.5px; font-weight: 600; box-shadow: none; transition: background-color .12s, border-color .12s; }
body.student-app .primary { border: 1px solid var(--accent); background: var(--accent); color: #fff; }
html[data-theme="dark"] body.student-app .primary { color: #0e1217; }
body.student-app .primary:hover:not(:disabled) { border-color: var(--accent-hover); background: var(--accent-hover); }
body.student-app .secondary { border: 1px solid var(--line); background: var(--surface); color: var(--ink); }
body.student-app .secondary:hover:not(:disabled) { border-color: #c4ccd6; background: var(--subtle); }
html[data-theme="dark"] body.student-app .secondary:hover:not(:disabled) { border-color: #3c4654; }
body.student-app .text-button { padding: 4px 6px; border: 0; background: none; color: var(--accent-ink); font-size: 13.5px; font-weight: 600; text-decoration: none; }
body.student-app .text-button:hover { text-decoration: underline; text-underline-offset: 3px; }
body.student-app :is(button, select, input, a, [tabindex]):focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
body.student-app :is(input:not([type=checkbox]), select, textarea) { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); color: var(--ink); }
body.student-app :is(input:not([type=checkbox]), select, textarea):focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); outline: none; }

/* Login */
body.student-app .entry:not(.is-signed-in) { max-width: 400px; margin-top: 64px; text-align: left; }
body.student-app .entry:not(.is-signed-in) > .hero-icon { display: none; }
body.student-app .entry:not(.is-signed-in) > h1 { margin-bottom: 4px; font-size: 24px; }
body.student-app .entry .lead { color: var(--ink-3); font-size: 14px; }
body.student-app .login-paper { padding: 24px; }
body.student-app .login-paper label { margin: 12px 0 6px; color: var(--ink-2); font-size: 13px; font-weight: 600; }
body.student-app .login-paper input { padding: 9px 11px; }
body.student-app .entry > .caption { color: var(--ink-3); }

/* Painel: menu lateral + conteúdo */
body.student-app .entry.is-signed-in { max-width: 1360px; margin: 24px auto; text-align: left; }
.entry.is-signed-in > .hero-icon,
.entry.is-signed-in > .eyebrow,
.entry.is-signed-in > h1,
.entry.is-signed-in > .lead,
.entry.is-signed-in > .student-entry-caption { display: none; }
body.student-app .student-home { display: grid; grid-template-columns: 232px minmax(0, 1fr); align-items: stretch; padding: 0; }
.student-sidebar { position: sticky; top: var(--sticky-top); align-self: start; display: flex; flex-direction: column; gap: 4px; max-height: calc(100vh - var(--sticky-top) - 16px); overflow-y: auto; padding: 18px 12px; }
.student-sidebar-profile { padding: 0 10px 14px; margin-bottom: 8px; border-bottom: 1px solid var(--line-soft); }
body.student-app .student-sidebar-profile h2 { margin: 0 0 2px; font-size: 16px; }
.student-sidebar-profile .muted { margin: 0; font-size: 12.5px; }
.student-sidebar-title { margin: 16px 0 4px; padding: 0 10px; color: var(--ink-3); font-size: 12px; font-weight: 600; }
.student-tabs,
.student-module-nav > div { display: flex; flex-direction: column; gap: 1px; }
body.student-app :is(.student-tabs [role="tab"], .student-module-link, .study-nav-step) { display: flex; align-items: center; justify-content: space-between; gap: 10px; width: 100%; min-height: 34px; margin: 0; padding: 6px 10px; border: 0; border-radius: var(--radius); background: none; color: var(--ink-2); font: inherit; font-size: 14px; font-weight: 500; text-align: left; cursor: pointer; box-shadow: none; }
body.student-app .student-module-link { min-height: 30px; font-size: 13.5px; }
body.student-app :is(.student-tabs [role="tab"], .student-module-link, .study-nav-step):hover { background: var(--subtle); color: var(--ink); }
body.student-app :is(.student-tabs [role="tab"][aria-selected="true"], .student-module-link[aria-pressed="true"], .study-nav-step[aria-current]) { background: var(--accent-soft); color: var(--accent-ink); font-weight: 600; }
.student-nav-count { flex: 0 0 auto; color: var(--ink-3); font-size: 12.5px; font-weight: 500; font-variant-numeric: tabular-nums; }
.student-nav-count.is-todo { color: var(--ink-2); font-weight: 600; }
.student-module-nav { display: block; }
.student-sidebar-actions { display: flex; flex-direction: column; align-items: stretch; gap: 4px; margin-top: 16px; padding-top: 12px; border-top: 1px solid var(--line-soft); }
body.student-app .student-sidebar-actions .secondary { width: 100%; }
body.student-app .student-sidebar-actions .text-button { align-self: flex-start; color: var(--ink-2); font-weight: 500; }

.student-main { min-width: 0; min-height: 70vh; padding: 22px 28px 32px; border-left: 1px solid var(--line); }
.student-panel-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; }
body.student-app .student-panel-heading { margin: 0; font-size: 20px; }
.student-panel-heading:focus { outline: none; }
.student-panel-heading:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; border-radius: 4px; }
.student-panel-note { color: var(--ink-3); font-size: 13px; }
.student-panel-intro { margin: 4px 0 18px; color: var(--ink-2); font-size: 13.5px; }
.student-notice { margin: 8px 0 16px; padding: 9px 12px; border-left: 3px solid var(--line); background: var(--subtle); color: var(--ink-2); font-size: 13px; }

/* Filtros: controle segmentado + seleção de UC */
.student-exam-toolbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 16px; margin-bottom: 14px; }
body.student-app .student-dashboard-filters { display: inline-flex; flex-wrap: nowrap; gap: 0; margin: 0; overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius); }
body.student-app .student-dashboard-filters button { min-height: 32px; padding: 5px 12px; border: 0; border-right: 1px solid var(--line); border-radius: 0; background: var(--surface); color: var(--ink-2); font-size: 13px; font-weight: 500; box-shadow: none; }
body.student-app .student-dashboard-filters button:last-child { border-right: 0; }
body.student-app .student-dashboard-filters button:hover { background: var(--subtle); }
body.student-app .student-dashboard-filters [aria-pressed="true"] { background: var(--accent-soft); color: var(--accent-ink); font-weight: 600; box-shadow: none; }
.student-filter-count { margin-left: 4px; color: var(--ink-3); font-size: 12px; font-variant-numeric: tabular-nums; }
body.student-app .student-uc-filter { display: flex; align-items: center; gap: 8px; margin: 0; color: var(--ink-2); font-size: 13px; font-weight: 500; white-space: nowrap; }
body.student-app .student-uc-filter select { width: 300px; max-width: 100%; min-height: 32px; padding: 4px 8px; font-size: 13px; text-overflow: ellipsis; }

/* Tabelas */
.student-exam-list { display: flex; flex-direction: column; gap: 22px; }
body.student-app .student-exam-group-title { display: flex; align-items: baseline; gap: 8px; margin: 0 0 8px; font-size: 14px; }
.student-exam-group-title span { color: var(--ink-3); font-size: 12.5px; font-weight: 400; }
.student-table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); }
.student-table { width: 100%; border-collapse: collapse; color: var(--ink-2); font-size: 13.5px; }
.student-table th { padding: 8px 14px; border-bottom: 1px solid var(--line); background: var(--subtle); color: var(--ink-3); font-size: 12px; font-weight: 600; text-align: left; white-space: nowrap; }
.student-table td { padding: 11px 14px; border-bottom: 1px solid var(--line-soft); vertical-align: middle; }
.student-table tbody tr:last-child td { border-bottom: 0; }
.student-table tbody tr:hover td { background: var(--subtle); }
.student-table .is-number { width: 1%; text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
.student-table .is-code { width: 1%; color: var(--ink-3); font-weight: 600; text-align: right; font-variant-numeric: tabular-nums; }
.student-table .is-actions { width: 1%; text-align: right; white-space: nowrap; }
.student-table .is-score { min-width: 150px; }
.student-cell-main strong { display: block; color: var(--ink); font-size: 14px; font-weight: 600; }
.student-cell-detail { display: block; margin-top: 2px; color: var(--ink-3); font-size: 12.5px; }
.student-row-actions { display: inline-flex; align-items: center; justify-content: flex-end; gap: 6px; }
.student-row-actions .student-cell-detail { margin: 0; }
body.student-app .student-table :is(.primary, .secondary) { min-height: 30px; padding: 4px 12px; font-size: 13px; }
.student-status { display: inline-flex; align-items: center; gap: 7px; color: var(--ink-2); font-size: 13px; white-space: nowrap; }
.student-status-dot { flex: 0 0 auto; width: 8px; height: 8px; border-radius: 50%; background: var(--neutral); }
.student-status.is-pending .student-status-dot { background: var(--pending); }
.student-status.is-ongoing .student-status-dot { background: var(--ongoing); }
.student-status.is-attempted .student-status-dot { background: var(--done); }
.student-status.is-canceled .student-status-dot { background: var(--danger); }
.student-tag { display: inline-block; margin-left: 6px; padding: 0 6px; border: 1px solid var(--line); border-radius: 4px; color: var(--ink-3); font-size: 11.5px; font-weight: 500; vertical-align: 1px; }
.student-table .is-score strong { display: inline; color: var(--ink); font-weight: 600; }
.student-table .is-score .student-cell-detail { display: inline; }
.student-result-bar { display: block; width: 120px; height: 4px; margin-top: 6px; overflow: hidden; border-radius: 2px; background: var(--line-soft); }
.student-result-bar span { display: block; height: 100%; background: var(--accent); }
.student-empty { margin: 0; padding: 28px; border: 1px dashed var(--line); border-radius: 8px; color: var(--ink-3); text-align: center; }

/* Trilhas de estudo */
body.student-app .student-study { max-width: 1360px; margin: 24px auto; padding: 0; text-align: left; }
body.student-app .student-study-header { margin: 0; padding: 20px 28px 16px; border-bottom: 1px solid var(--line); }
body.student-app .student-study-header h2 { margin: 0 0 4px; font-size: 20px; }
body.student-app .student-study-header .muted { margin: 0; font-size: 13.5px; }
body.student-app .study-source { margin: 0; padding: 8px 28px; border-bottom: 1px solid var(--line); border-radius: 0; background: var(--subtle); color: var(--ink-3); font-size: 12.5px; }
.study-layout { display: grid; grid-template-columns: 232px minmax(0, 1fr); align-items: stretch; }
.study-nav { position: sticky; top: var(--sticky-top); align-self: start; display: flex; flex-direction: column; gap: 4px; padding: 18px 12px; }
body.student-app .study-nav > button.secondary { justify-content: flex-start; width: 100%; margin-bottom: 8px; text-align: left; }
.study-nav-steps { display: flex; flex-direction: column; gap: 1px; margin: 0; padding: 0; list-style: none; counter-reset: study-step; }
body.student-app .study-nav-steps .study-nav-step { justify-content: flex-start; }
.study-nav-step::before { counter-increment: study-step; content: counter(study-step); display: grid; flex: 0 0 auto; place-items: center; width: 20px; height: 20px; border: 1px solid var(--line); border-radius: 50%; color: var(--ink-3); font-size: 11.5px; font-weight: 600; }
.study-nav-step[aria-current]::before { border-color: var(--accent); background: var(--accent); color: var(--surface); }
.study-parts { min-width: 0; min-height: 60vh; padding: 24px 28px 28px; border-left: 1px solid var(--line); }
.student-study.has-study-nav .student-sidebar-title { margin-top: 4px; }
body.student-app .study-slides { max-width: 860px; margin: 0 auto; }
body.student-app .study-progress-row { color: var(--ink-3); font-weight: 600; }
body.student-app .study-chip { padding: 2px 8px; border-radius: 4px; background: var(--accent-soft); color: var(--accent-ink); }
body.student-app .study-progress-track { height: 4px; border-radius: 2px; background: var(--line-soft); }
body.student-app .study-progress-track div { background: var(--accent); }
body.student-app .study-slide { min-height: 300px; padding: 28px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); color: var(--ink); }
body.student-app :is(.study-slide h3, .study-activity h3) { font-size: 20px; }
body.student-app :is(.study-slide-summary, .study-slide ul, .study-example p) { color: var(--ink-2); }
body.student-app .study-example { border-left: 3px solid var(--accent); border-radius: 0 var(--radius) var(--radius) 0; background: var(--subtle); color: var(--ink); }
body.student-app .study-activity { margin: 0; padding: 0; border: 0; border-radius: 0; background: none; color: var(--ink); }
body.student-app .study-activity > .eyebrow { display: none; }
body.student-app :is(.study-choice-list, .algo-choices) .secondary[aria-pressed="true"] { border-color: var(--accent); background: var(--accent-soft); color: var(--accent-ink); box-shadow: none; }
body.student-app .study-demo-output { border: 1px solid var(--line); border-radius: 8px; background: var(--subtle); color: var(--ink); }
body.student-app :is(.study-demo-output pre, .algo-code) { border-radius: var(--radius); background: var(--code-bg); color: var(--code-ink); }
body.student-app :is(.study-demo-output table, .algo-compare table) { background: var(--surface); }
body.student-app :is(.study-demo-output th, .study-demo-output td, .algo-compare th, .algo-compare td) { border-color: var(--line); }
body.student-app :is(.study-demo-output th, .algo-compare th) { background: var(--subtle); color: var(--ink-2); }
body.student-app .study-question { border: 1px solid var(--line); border-radius: 8px; }
body.student-app .study-answer-button { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); color: var(--ink); }
body.student-app .study-answer-button:hover:not(:disabled),
body.student-app .study-answer-button:focus-visible { border-color: var(--accent); background: var(--accent-soft); }
body.student-app .study-answer-button[aria-pressed="true"] { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent); }
body.student-app :is(.study-quiz-result, .logic-demo-result, .algo-message) { border: 1px solid var(--line); border-radius: var(--radius); background: var(--subtle); color: var(--ink); }
body.student-app .algo-summary { border-left: 3px solid var(--accent); border-radius: 0 var(--radius) var(--radius) 0; background: var(--subtle); color: var(--ink-2); }
body.student-app .algo-stage { border: 1px solid var(--line); border-radius: 8px; background: var(--subtle); }
body.student-app :is(.algo-choice-label, .algo-side-title) { color: var(--ink-3); font-size: 12px; font-weight: 600; letter-spacing: 0; text-transform: none; }
body.student-app :is(.algo-cell, .algo-speed select, .logic-demo-field input) { border-color: var(--line); border-radius: var(--radius); background: var(--surface); color: var(--ink); }
body.student-app .algo-predict { border-radius: var(--radius); }
/* Roteiro da UC ("O que a prova cobra") */
.roadmap-saep { margin: 0 0 16px; padding: 10px 14px; border-left: 3px solid var(--accent); background: var(--accent-soft); color: var(--ink-2); font-size: 13.5px; }
.roadmap-saep p { margin: 0; }
.roadmap-saep p + p { margin-top: 4px; }
.roadmap-saep strong { margin-right: 6px; color: var(--accent-ink); }
.roadmap-grid { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: 16px; }
.roadmap-block { padding: 16px 18px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); }
body.student-app .roadmap-block h4 { margin: 0 0 10px; font-size: 14px; }
.roadmap-capacities { margin: 0; padding-left: 20px; color: var(--ink-2); font-size: 13.5px; line-height: 1.55; }
.roadmap-capacities li + li { margin-top: 6px; }
body.student-app .roadmap-block .roadmap-subtitle { margin: 14px 0 6px; }
.roadmap-socio { margin: 0; color: var(--ink-2); font-size: 13.5px; line-height: 1.55; }
.roadmap-tags { display: flex; flex-wrap: wrap; gap: 6px; margin: 0; padding: 0; list-style: none; }
.roadmap-tags li { padding: 3px 8px; border: 1px solid var(--line); border-radius: 4px; background: var(--subtle); color: var(--ink-2); font-size: 12.5px; }
.roadmap-checks { margin-top: 16px; }
.roadmap-check-head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; }
.roadmap-progress { color: var(--ink-3); font-size: 13px; font-variant-numeric: tabular-nums; }
.roadmap-check-list { margin: 10px 0 0; padding: 0; list-style: none; }
.roadmap-check-list li { border-top: 1px solid var(--line-soft); }
.roadmap-check-list label { display: flex; align-items: flex-start; gap: 10px; margin: 0; padding: 9px 2px; color: var(--ink); font-size: 13.5px; font-weight: 400; cursor: pointer; }
.roadmap-check-list input { flex: 0 0 auto; width: 16px; height: 16px; margin-top: 2px; accent-color: var(--accent); }
@media (max-width: 900px) { .roadmap-grid { grid-template-columns: minmax(0, 1fr); } }
.study-part-footer { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; margin-top: 24px; padding-top: 16px; border-top: 1px solid var(--line); }

/* Resultado e gabarito */
body.student-app #completed .result { border-radius: 8px; box-shadow: none; }
body.student-app .result-icon { width: 48px; height: 48px; border-radius: 50%; background: var(--accent-soft); color: var(--accent-ink); font-size: 22px; }
body.student-app #completed .result h1 { font-size: 24px; font-weight: 600; }
body.student-app #resultPct { color: var(--ink); font-weight: 600; }
body.student-app :is(.result-review-card, .result-review-navigation) { border-color: var(--line); border-radius: 8px; background: var(--surface); color: var(--ink); }

/* Botão flutuante "Voltar ao painel" (resultado) */
.student-back-fab { position: fixed; left: max(16px, env(safe-area-inset-left, 0px)); bottom: calc(16px + env(safe-area-inset-bottom, 0px)); z-index: 30; padding: 9px 16px; border: 1px solid var(--accent); border-radius: var(--radius); background: var(--accent); color: #fff; font: inherit; font-size: 14px; font-weight: 600; box-shadow: 0 4px 12px rgba(16, 24, 40, .18); cursor: pointer; }
html[data-theme="dark"] .student-back-fab { color: #0e1217; }
.student-back-fab:hover { background: var(--accent-hover); }
body:has(.student-back-fab:not(.hidden)) main { padding-bottom: 80px; }

/* Telas estreitas (uso eventual) */
@media (max-width: 900px) {
  body.student-app .student-home,
  .study-layout { grid-template-columns: minmax(0, 1fr); }
  .student-sidebar,
  .study-nav { position: static; max-height: none; border-bottom: 1px solid var(--line); }
  .student-main,
  .study-parts { padding: 18px 16px; border-left: 0; }
  body.student-app .student-dashboard-filters { flex-wrap: wrap; }
}

/* Representação visual dos slides (renderSlideVisual em student.js) */
body.student-app .slide-visual { display: grid; gap: 14px; margin: 16px 0; }
body.student-app .slide-visual[hidden] { display: none; }
body.student-app .sv-figure { margin: 0; padding: 16px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--subtle); }
body.student-app .sv-figure figcaption { margin-top: 12px; color: var(--ink-2); font-size: .92rem; }
body.student-app .sv-body { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
body.student-app .sv-flow, body.student-app .sv-stack { flex-direction: column; align-items: flex-start; }
body.student-app .sv-stack { align-items: stretch; max-width: 280px; }
body.student-app .sv-name { width: 100%; font-weight: 600; color: var(--ink-2); font-size: .9rem; margin-bottom: 6px; }
body.student-app .sv-cells { display: flex; flex-wrap: wrap; }
body.student-app .sv-cell { display: flex; flex-direction: column; align-items: center; justify-content: center; min-width: 64px; padding: 10px 12px; border: 1px solid var(--line); background: var(--surface); font-weight: 600; text-align: center; }
body.student-app .sv-cells .sv-cell + .sv-cell { border-left: 0; }
body.student-app .sv-index { font-family: Consolas, monospace; font-weight: 400; font-size: .8rem; color: var(--ink-3); margin-top: 4px; }
body.student-app .sv-hl { background: var(--accent-soft) !important; color: var(--accent-ink); outline: 2px solid var(--accent); outline-offset: -2px; }
body.student-app .sv-hl-row td { background: var(--accent-soft); }
body.student-app .sv-tag, body.student-app .sv-op, body.student-app .sv-arrow { color: var(--ink-3); font-size: .85rem; }
body.student-app .sv-op { font-size: 1.4rem; font-weight: 600; padding: 0 4px; }
body.student-app .sv-arrow { padding-left: 18px; line-height: 1; }
body.student-app .sv-table-wrap { overflow-x: auto; }
body.student-app .sv-table { border-collapse: collapse; background: var(--surface); font-size: .92rem; }
body.student-app .sv-table th, body.student-app .sv-table td { border: 1px solid var(--line); padding: 6px 12px; text-align: center; }
body.student-app .sv-table th { background: var(--line-soft); font-weight: 600; color: var(--ink-2); }
body.student-app .sv-step { padding: 8px 14px; border: 1px solid var(--line); background: var(--surface); font-family: Consolas, monospace; }
body.student-app .sv-start { border-radius: 999px; }
body.student-app .sv-io { transform: skewX(-12deg); }
body.student-app .sv-decision { border: 2px solid var(--pending); }

/* Fullscreen alert during the exam: blinks so the student notices */
.fullscreen-alert { position: fixed; top: 0; left: 0; right: 0; z-index: 1000; display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 12px 20px; padding: 14px 20px; background: #b42318; color: #fff; font-size: 1.05rem; box-shadow: 0 4px 16px rgba(0,0,0,.3); animation: fullscreen-blink 1s steps(1, end) infinite; }
.fullscreen-alert.hidden { display: none; }
.fullscreen-alert strong { font-size: 1.2rem; }
.fullscreen-alert button { background: #fff; color: #b42318; border: 0; border-radius: 6px; padding: 8px 16px; font-weight: 700; cursor: pointer; }
@keyframes fullscreen-blink { 0% { background: #b42318; } 50% { background: #f79009; } }

/* Enunciados com pseudocodigo (VisuAlg): renderPromptText em student.js */
.prompt-block { display: block; margin: 0 0 12px; white-space: pre-wrap; }
.prompt-code { display: block; margin: 4px 0 14px; padding: 12px 16px; border-radius: 6px; background: var(--code-bg, #1f2933); color: var(--code-ink, #e5e9f0); font-family: Consolas, "Cascadia Mono", "Courier New", monospace; font-size: .95em; line-height: 1.55; white-space: pre; overflow-x: auto; }
legend .prompt-block:last-child, .question-prompt .prompt-block:last-child { margin-bottom: 0; }