:root {
  --ink: #17221d;
  --muted: #66736c;
  --surface: #ffffff;
  --surface-soft: #f4f7f5;
  --line: #dce5df;
  --brand: #146c43;
  --brand-dark: #0d4f31;
  --brand-soft: #e5f4ec;
  --accent: #d99a24;
  --danger: #b42318;
  --danger-soft: #fef3f2;
  --warning: #8a5a00;
  --warning-soft: #fff8e6;
  --shadow: 0 18px 50px rgba(18, 49, 34, 0.10);
  --radius: 20px;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: #edf3ef;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; min-height: 100vh; background: radial-gradient(circle at 15% 0%, #f9fcfa 0, #edf3ef 45%, #e8efeb 100%); }
button, input { font: inherit; }
button { cursor: pointer; }
button:disabled { cursor: not-allowed; opacity: .55; }

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 16px clamp(20px, 5vw, 72px);
  background: rgba(255,255,255,.92);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(220,229,223,.9);
}

.brand { display: flex; gap: 12px; align-items: center; color: inherit; text-decoration: none; }
.brand-mark { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 13px; background: var(--brand); color: white; font: 800 22px Georgia, serif; box-shadow: 0 8px 20px rgba(20,108,67,.22); }
.brand strong { display: block; font-size: 18px; letter-spacing: -.02em; }
.brand small { display: block; color: var(--muted); font-size: 11px; margin-top: 2px; }
nav { display: flex; gap: 6px; padding: 4px; background: var(--surface-soft); border-radius: 12px; }
.nav-button { border: 0; background: transparent; color: var(--muted); border-radius: 9px; padding: 9px 16px; font-weight: 700; }
.nav-button.active { background: white; color: var(--brand-dark); box-shadow: 0 3px 10px rgba(23,34,29,.08); }

main { width: min(1180px, calc(100% - 32px)); margin: 0 auto; }
.view { display: none; }
.view.active { display: block; }

.hero { display: grid; grid-template-columns: 1.35fr .65fr; gap: 36px; padding: 68px 0 38px; align-items: center; }
.hero h1, .admin-header h1 { font: 700 clamp(38px, 5vw, 66px)/1.04 Georgia, serif; letter-spacing: -.045em; margin: 12px 0 18px; color: #173023; }
.hero-copy > p { max-width: 720px; color: var(--muted); font-size: 18px; line-height: 1.7; }
.eyebrow { color: var(--brand); text-transform: uppercase; letter-spacing: .11em; font-size: 12px; font-weight: 800; }
.hero-stats { display: flex; gap: 12px; margin-top: 28px; flex-wrap: wrap; }
.hero-stats div { min-width: 132px; padding: 15px 18px; border: 1px solid var(--line); background: rgba(255,255,255,.72); border-radius: 14px; }
.hero-stats strong { display: block; font-size: 22px; color: var(--brand-dark); }
.hero-stats span { color: var(--muted); font-size: 12px; }
.principle-card { padding: 28px; border-radius: var(--radius); background: #173f2c; color: white; box-shadow: var(--shadow); }
.principle-card h2 { margin: 0 0 16px; font: 700 26px Georgia, serif; }
.principle-card ul { padding-left: 20px; margin: 0; color: #dceae1; line-height: 1.65; }
.principle-card li + li { margin-top: 10px; }

.workflow-shell { margin: 20px 0 80px; }
.steps { display: grid; grid-template-columns: repeat(4, 1fr); list-style: none; padding: 0 18px; margin: 0 0 14px; }
.step { position: relative; display: flex; align-items: center; justify-content: center; gap: 8px; color: #88958e; font-size: 13px; font-weight: 750; }
.step:not(:last-child)::after { content: ""; position: absolute; height: 2px; background: #d6dfda; right: -12%; left: 62%; top: 50%; }
.step span { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: #dce5df; color: #647068; font-size: 12px; z-index: 1; }
.step.active { color: var(--brand-dark); }
.step.active span, .step.complete span { background: var(--brand); color: white; }
.step.complete::after { background: var(--brand); }

.panel { display: none; background: var(--surface); border: 1px solid rgba(220,229,223,.9); border-radius: var(--radius); padding: clamp(22px, 4vw, 42px); box-shadow: var(--shadow); }
.panel.active { display: block; animation: panel-in .25s ease-out; }
@keyframes panel-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.panel-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 24px; margin-bottom: 28px; }
.panel h2 { margin: 7px 0 0; font: 700 clamp(27px, 3vw, 38px) Georgia, serif; color: #173023; }
.privacy-chip, .threshold-badge { padding: 8px 12px; border-radius: 999px; background: var(--brand-soft); color: var(--brand-dark); font-size: 12px; font-weight: 800; white-space: nowrap; }

.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
label { display: grid; gap: 8px; color: #314139; font-size: 13px; font-weight: 750; }
input[type="text"], input[type="password"] { width: 100%; border: 1px solid #cbd7d0; background: #fbfdfc; border-radius: 11px; padding: 13px 14px; color: var(--ink); outline: none; transition: border .15s, box-shadow .15s; }
input:focus { border-color: var(--brand); box-shadow: 0 0 0 4px rgba(20,108,67,.1); }
.full-width { grid-column: 1 / -1; }
.file-drop { min-height: 175px; place-items: center; align-content: center; text-align: center; border: 1.5px dashed #9bb5a6; border-radius: 16px; background: #f7fbf8; padding: 24px; cursor: pointer; transition: .15s; }
.file-drop:hover, .file-drop.dragover { border-color: var(--brand); background: var(--brand-soft); }
.file-drop input { position: absolute; opacity: 0; pointer-events: none; }
.file-drop strong { color: var(--brand-dark); }
.file-drop small { color: var(--muted); font-weight: 500; }
.file-icon { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 50%; background: var(--brand); color: white; font-size: 22px; }
.form-actions { display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.form-actions.align-right { justify-content: flex-end; }
.form-note { margin: 0; color: var(--muted); max-width: 680px; font-size: 12px; line-height: 1.55; }
.primary-button, .secondary-button { border: 0; border-radius: 11px; padding: 12px 18px; font-weight: 800; transition: transform .12s, box-shadow .12s; }
.primary-button { background: var(--brand); color: white; box-shadow: 0 8px 20px rgba(20,108,67,.22); }
.primary-button:hover:not(:disabled) { transform: translateY(-1px); box-shadow: 0 11px 25px rgba(20,108,67,.28); }
.secondary-button { color: var(--brand-dark); background: var(--brand-soft); }
.text-button { border: 0; background: transparent; color: var(--brand); font-weight: 800; padding: 8px; }

.message { display: none; margin-top: 18px; border-radius: 11px; padding: 12px 14px; font-size: 13px; line-height: 1.5; }
.message.visible { display: block; }
.message.error { background: var(--danger-soft); color: var(--danger); border: 1px solid #fecdca; }
.message.warning { background: var(--warning-soft); color: var(--warning); border: 1px solid #f4d58b; }
.message.success { background: var(--brand-soft); color: var(--brand-dark); border: 1px solid #b6ddc7; }

.processing-card { text-align: center; padding: 30px 10px; max-width: 720px; margin: 0 auto; }
.spinner { width: 56px; height: 56px; border-radius: 50%; border: 5px solid #dfe9e3; border-top-color: var(--brand); margin: 0 auto 22px; animation: spin .9s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.processing-card p { color: var(--muted); }
.progress-track, .question-progress { overflow: hidden; height: 8px; border-radius: 999px; background: #e4ebe7; }
.progress-track { margin: 24px auto; max-width: 520px; }
.progress-track span, .question-progress span { display: block; height: 100%; width: 8%; border-radius: inherit; background: var(--brand); transition: width .3s ease; }
.processing-grid { display: flex; justify-content: center; gap: 70px; }
.processing-grid span { display: block; font-size: 25px; font-weight: 850; color: var(--brand-dark); text-transform: capitalize; }
.processing-grid small { color: var(--muted); }

.instruction-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.instruction-grid article { border: 1px solid var(--line); border-radius: 14px; padding: 18px; background: #fbfdfc; }
.instruction-grid strong { color: var(--brand-dark); }
.instruction-grid p { color: var(--muted); margin: 6px 0 0; font-size: 13px; line-height: 1.5; }
.consent-row { display: flex; align-items: flex-start; gap: 10px; margin: 24px 0; padding: 16px; border-radius: 12px; background: var(--surface-soft); }
.consent-row input { width: 18px; height: 18px; accent-color: var(--brand); }

.test-panel { min-height: 540px; }
.test-header { display: grid; grid-template-columns: 1fr auto; gap: 24px; align-items: center; }
.question-progress { width: min(560px, 70vw); margin-top: 9px; }
.timer { min-width: 108px; text-align: center; padding: 12px 15px; background: var(--brand-soft); border-radius: 15px; color: var(--brand-dark); }
.timer.warning { background: var(--warning-soft); color: var(--warning); }
.timer.danger { background: var(--danger-soft); color: var(--danger); }
.timer strong { display: block; font-size: 25px; font-variant-numeric: tabular-nums; }
.timer small { font-size: 10px; text-transform: uppercase; letter-spacing: .08em; }
.difficulty-row { display: flex; align-items: center; gap: 10px; margin-top: 34px; color: var(--muted); font-size: 12px; }
.difficulty-badge { padding: 6px 10px; border-radius: 999px; background: #eef2ff; color: #3e4a8a; font-weight: 800; text-transform: capitalize; }
.question-text { max-width: 900px; font: 700 clamp(24px, 3vw, 35px)/1.28 Georgia, serif !important; margin: 18px 0 26px !important; }
.options { display: grid; grid-template-columns: 1fr 1fr; gap: 13px; }
.option-button { display: flex; align-items: flex-start; gap: 13px; min-height: 74px; text-align: left; border: 1px solid #cfdad4; background: #fbfdfc; border-radius: 14px; padding: 16px; color: var(--ink); font-weight: 650; line-height: 1.45; }
.option-button:hover:not(:disabled) { border-color: var(--brand); background: var(--brand-soft); }
.option-letter { flex: 0 0 auto; display: grid; place-items: center; width: 27px; height: 27px; border-radius: 8px; background: #e7eeea; color: var(--brand-dark); font-size: 12px; font-weight: 850; }
.option-button.selected { border-color: var(--brand); background: var(--brand-soft); }

.result-layout { display: grid; grid-template-columns: 310px 1fr; gap: 48px; align-items: center; }
.score-ring { width: 260px; aspect-ratio: 1; display: grid; place-content: center; text-align: center; border-radius: 50%; background: conic-gradient(var(--brand) 0%, #e6ede9 0); position: relative; }
.score-ring::before { content: ""; position: absolute; inset: 20px; border-radius: 50%; background: white; }
.score-ring > * { position: relative; z-index: 1; }
.score-ring strong { font-size: 52px; color: var(--brand-dark); }
.score-ring span { color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: .08em; }
.result-copy h2 { margin-bottom: 12px; }
.decision-text { font-size: 23px; font-weight: 800; color: var(--brand-dark); }
.result-metrics { display: flex; gap: 12px; margin: 24px 0; flex-wrap: wrap; }
.result-metrics div { min-width: 125px; padding: 14px 16px; border-radius: 12px; background: var(--surface-soft); }
.result-metrics strong { display: block; font-size: 21px; }
.result-metrics span { color: var(--muted); font-size: 11px; }
.muted { color: var(--muted); line-height: 1.55; }

.admin-header { display: grid; grid-template-columns: 1fr 360px; gap: 40px; align-items: end; padding: 58px 0 30px; }
.admin-header h1 { font-size: clamp(38px, 5vw, 58px); margin-bottom: 12px; }
.admin-header p { color: var(--muted); max-width: 650px; line-height: 1.6; }
.admin-key-card { background: white; border: 1px solid var(--line); box-shadow: var(--shadow); border-radius: var(--radius); padding: 20px; }
.admin-key-card .primary-button { width: 100%; margin-top: 12px; }
.admin-table-card, .review-panel { background: white; border: 1px solid var(--line); box-shadow: var(--shadow); border-radius: var(--radius); margin-bottom: 30px; }
.table-heading, .review-heading { display: flex; justify-content: space-between; align-items: center; gap: 20px; padding: 22px 24px; border-bottom: 1px solid var(--line); }
.table-heading h2, .review-heading h2 { margin: 0; font: 700 27px Georgia, serif; }
.table-scroll { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 13px; }
th, td { padding: 15px 18px; text-align: left; border-bottom: 1px solid #edf1ee; vertical-align: top; }
th { color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .06em; background: #fafcfb; }
td strong { display: block; }
td small { color: var(--muted); }
.empty-state { text-align: center; padding: 40px; color: var(--muted); }
.status-pill { display: inline-flex; padding: 5px 9px; border-radius: 999px; background: #eef2f0; font-size: 11px; font-weight: 800; text-transform: capitalize; }
.status-pill.completed, .status-pill.ready { background: var(--brand-soft); color: var(--brand-dark); }
.action-row { display: flex; gap: 6px; flex-wrap: wrap; }
.action-row button { border: 1px solid var(--line); background: white; border-radius: 8px; padding: 6px 9px; color: var(--brand-dark); font-size: 11px; font-weight: 800; }
.action-row button.delete { color: var(--danger); }
.hidden { display: none !important; }
.review-panel { overflow: hidden; }
.review-summary { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; padding: 22px 24px; background: #fafcfb; }
.review-summary div { padding: 13px; border-radius: 10px; background: white; border: 1px solid var(--line); }
.review-summary strong { display: block; font-size: 18px; }
.review-summary span { color: var(--muted); font-size: 11px; }
.review-questions { padding: 24px; }
.review-question { border: 1px solid var(--line); border-radius: 14px; padding: 18px; margin-bottom: 12px; }
.review-question h3 { margin: 0 0 12px; font-size: 16px; line-height: 1.4; }
.review-meta { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 12px; }
.review-meta span { padding: 5px 8px; border-radius: 8px; background: var(--surface-soft); color: var(--muted); font-size: 11px; }
.review-meta .correct { color: var(--brand-dark); background: var(--brand-soft); }
.review-meta .incorrect { color: var(--danger); background: var(--danger-soft); }
.review-options { display: grid; gap: 7px; margin: 0 0 14px; padding-left: 26px; font-size: 12px; color: var(--muted); }
.review-options li { padding: 7px 9px; border-radius: 8px; }
.review-options .selected-option { outline: 1px solid #d5a84c; background: #fff9e9; }
.review-options .correct-option { color: var(--brand-dark); background: var(--brand-soft); font-weight: 800; }
.review-options .selected-option.correct-option { outline: 2px solid var(--brand); }
.source-evidence { padding: 12px; border-left: 3px solid var(--accent); background: #fffaf0; color: #59451d; font-size: 12px; line-height: 1.5; }

footer { width: min(1180px, calc(100% - 32px)); margin: 0 auto; display: flex; justify-content: space-between; gap: 20px; padding: 24px 0 40px; border-top: 1px solid #d3ddd7; color: var(--muted); font-size: 12px; }
footer strong { color: var(--brand-dark); }

@media (max-width: 850px) {
  .hero, .admin-header, .result-layout { grid-template-columns: 1fr; }
  .hero { padding-top: 42px; }
  .hero h1 { font-size: 44px; }
  .admin-key-card { width: 100%; }
  .form-grid, .instruction-grid, .options { grid-template-columns: 1fr; }
  .result-layout { justify-items: center; text-align: center; }
  .result-metrics { justify-content: center; }
  .review-summary { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 580px) {
  main { width: min(100% - 20px, 1180px); }
  .topbar { padding: 12px 14px; }
  .brand small { display: none; }
  .nav-button { padding: 8px 10px; }
  .hero h1 { font-size: 36px; }
  .hero-stats { display: grid; grid-template-columns: repeat(3, 1fr); }
  .hero-stats div { min-width: 0; padding: 12px; }
  .steps { padding: 0; }
  .step { font-size: 0; }
  .step span { font-size: 12px; }
  .step:not(:last-child)::after { left: 58%; right: -42%; }
  .panel { padding: 20px 16px; }
  .panel-heading, .form-actions, footer { align-items: stretch; flex-direction: column; }
  .privacy-chip, .threshold-badge { align-self: flex-start; }
  .test-header { grid-template-columns: 1fr auto; gap: 10px; }
  .question-progress { width: 100%; }
  .timer { min-width: 84px; }
  .processing-grid { gap: 30px; }
  .score-ring { width: 220px; }
}

.webcam-monitor {
  display: flex;
  align-items: center;
  gap: 14px;
  width: min(420px, 100%);
  margin-top: 18px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #f8fbf9;
}
.webcam-monitor video {
  width: 112px;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: 10px;
  background: #142219;
  transform: scaleX(-1);
}
.webcam-copy { display: grid; gap: 5px; }
.webcam-copy small { color: var(--muted); line-height: 1.4; }
.camera-live { display: inline-flex; align-items: center; gap: 7px; color: var(--brand-dark); font-size: 12px; font-weight: 850; text-transform: uppercase; letter-spacing: .06em; }
.camera-dot { width: 9px; height: 9px; border-radius: 50%; background: #d92d20; box-shadow: 0 0 0 5px rgba(217,45,32,.10); }
.webcam-monitor.interrupted { border-color: #f0b8b4; background: var(--danger-soft); }
.webcam-monitor.interrupted .camera-live { color: var(--danger); }
.webcam-monitor.captured .camera-dot { background: var(--brand); box-shadow: 0 0 0 5px rgba(20,108,67,.10); }

.snapshot-cell { min-width: 112px; }
.snapshot-thumb {
  display: block;
  width: 84px;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: 9px;
  border: 1px solid var(--line);
  background: #edf2ef;
}
.snapshot-placeholder { display: inline-block; color: var(--muted); font-size: 11px; line-height: 1.35; }
.snapshot-time { display: block; margin-top: 4px; color: var(--muted); font-size: 10px; }
.review-snapshot { display: flex; align-items: center; gap: 12px; padding: 0 24px 20px; background: #fafcfb; }
.review-snapshot img { width: 150px; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 12px; border: 1px solid var(--line); }
.review-snapshot span { color: var(--muted); font-size: 12px; }

@media (max-width: 580px) {
  .webcam-monitor { align-items: flex-start; }
  .webcam-monitor video { width: 88px; }
}

/* Lecturer accounts and course management */
button, input, select { font: inherit; }
input[type="email"], select {
  width: 100%;
  border: 1px solid #cbd7d0;
  background: #fbfdfc;
  border-radius: 11px;
  padding: 13px 14px;
  color: var(--ink);
  outline: none;
  transition: border .15s, box-shadow .15s;
}
select:focus, input[type="email"]:focus { border-color: var(--brand); box-shadow: 0 0 0 4px rgba(20,108,67,.1); }
label small { color: var(--muted); font-weight: 500; line-height: 1.4; }
.security-note {
  background: #173f2c;
  color: white;
  border-radius: var(--radius);
  padding: 22px;
  box-shadow: var(--shadow);
}
.security-note strong { font-size: 18px; }
.security-note p { color: #dceae1; margin: 8px 0 0; font-size: 13px; line-height: 1.55; }
.auth-grid { display: grid; grid-template-columns: .85fr 1.15fr; gap: 24px; margin-bottom: 24px; }
.auth-card, .management-card, .platform-admin-card {
  background: white;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  border-radius: var(--radius);
}
.auth-card { padding: 28px; }
.auth-card h2 { margin: 7px 0 22px; font: 700 30px Georgia, serif; }
.stack-form { display: grid; gap: 16px; }
.stack-form .primary-button, .stack-form .secondary-button { justify-self: start; }
.dashboard-header { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 56px 0 26px; }
.dashboard-header h1 { margin: 8px 0 8px; font: 700 clamp(38px, 5vw, 58px)/1.08 Georgia, serif; }
.dashboard-header p { margin: 0; color: var(--muted); text-transform: capitalize; }
.management-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin-bottom: 30px; }
.management-card .stack-form { padding: 22px 24px 26px; }
.compact-form { grid-template-columns: 1fr 1fr; }
.compact-form label:nth-last-child(2), .compact-form button { grid-column: 1 / -1; }
.table-heading > div > small { display: block; margin-top: 5px; color: var(--muted); }
.table-tools { display: flex; align-items: center; gap: 10px; }
.table-tools select { min-width: 220px; padding: 9px 11px; }
.enrollment-code { display: inline-block; white-space: nowrap; padding: 7px 9px; border-radius: 8px; background: var(--brand-soft); color: var(--brand-dark); font-weight: 850; letter-spacing: .04em; }
.course-lecturers { min-width: 220px; color: var(--muted); line-height: 1.45; }
.platform-admin-card { margin: 34px 0 70px; overflow: hidden; }
.platform-controls { display: grid; grid-template-columns: minmax(280px, 1fr) auto; gap: 14px; align-items: end; padding: 22px 24px 4px; }
.platform-controls + .message { margin-left: 24px; margin-right: 24px; }
.small-button { padding: 8px 11px; font-size: 11px; }
.snapshot-cell { min-width: 106px; }
.snapshot-thumb { display: block; width: 86px; height: 64px; object-fit: cover; border-radius: 9px; border: 1px solid var(--line); }
.snapshot-time { display: block; max-width: 100px; margin-top: 4px; font-size: 9px; }
.snapshot-placeholder { color: var(--muted); font-size: 11px; }

@media (max-width: 900px) {
  .auth-grid, .management-grid { grid-template-columns: 1fr; }
  .compact-form { grid-template-columns: 1fr; }
  .compact-form label, .compact-form button { grid-column: auto; }
  .dashboard-header { align-items: flex-start; flex-direction: column; }
  .platform-controls { grid-template-columns: 1fr; }
  .table-tools { align-items: stretch; flex-direction: column; }
}

/* Administrator-created lecturer accounts */
.header-actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.lecturer-auth-grid { grid-template-columns: 1fr 1fr; max-width: 960px; }
.account-help-card p { color: var(--muted); line-height: 1.55; }
.password-field { display: grid; grid-template-columns: 1fr auto; gap: 8px; align-items: center; margin-top: 7px; }
.password-field input { margin-top: 0; }
.password-toggle { border: 1px solid var(--line); border-radius: 10px; background: var(--surface-soft); padding: 12px 13px; color: var(--brand-dark); font-weight: 800; cursor: pointer; }
.password-change-card { margin-bottom: 26px; overflow: hidden; border-color: #d5a84c; }
.password-change-form { max-width: 780px; }
.password-change-card .message { margin: 0 24px 24px; }
.standalone-card { max-width: 620px; margin: 12px 0 70px; }
.admin-key-card { padding: 28px; }
.admin-management-grid { align-items: start; }
.credential-card { padding-bottom: 25px; border-color: #9cc9ad; background: #fbfffc; }
.credential-card > p { padding: 0 24px; }
.credential-output { display: flex; align-items: center; gap: 12px; padding: 14px 24px; flex-wrap: wrap; }
.credential-output code { flex: 1; min-width: 210px; padding: 15px; border-radius: 11px; background: #173f2c; color: white; font-size: 17px; letter-spacing: .05em; overflow-wrap: anywhere; }
.status-pill.suspended { background: #fff0ee; color: var(--danger); }
.status-pill.pending { background: #fff9e9; color: #7b5a15; }
.status-pill.active { background: var(--brand-soft); color: var(--brand-dark); }
#platform-users-body td small, #reset-requests-body td small { display: block; margin-top: 5px; color: var(--muted); line-height: 1.4; }
#platform-dashboard .admin-table-card { margin-bottom: 28px; }

@media (max-width: 900px) {
  .lecturer-auth-grid { grid-template-columns: 1fr; }
  .header-actions { width: 100%; }
  .credential-output { align-items: stretch; flex-direction: column; }
  .credential-output code { width: 100%; min-width: 0; }
}

/* Account activation and recovery */
.account-access-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  max-width: 1320px;
}
.credential-list {
  display: grid;
  gap: 12px;
  padding: 8px 24px 16px;
}
.credential-list > div {
  display: grid;
  gap: 6px;
}
.credential-list span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .05em;
}
.credential-list code {
  padding: 14px;
  border-radius: 11px;
  background: #173f2c;
  color: white;
  font-size: 16px;
  overflow-wrap: anywhere;
}
#copy-setup-details { margin: 0 24px 12px; }
.status-pill.pending_activation { background: #fff9e9; color: #7b5a15; }

@media (max-width: 1100px) {
  .account-access-grid { grid-template-columns: 1fr 1fr; }
  .account-access-grid .account-help-card { grid-column: 1 / -1; }
}

@media (max-width: 760px) {
  .account-access-grid { grid-template-columns: 1fr; }
  .account-access-grid .account-help-card { grid-column: auto; }
}


/* Practice or trial course code */
.trial-code-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin: 0 0 24px;
  padding: 20px 22px;
  border: 1px solid rgba(23, 63, 44, 0.18);
  border-radius: 16px;
  background: linear-gradient(135deg, rgba(23, 63, 44, 0.08), rgba(255, 249, 233, 0.9));
}
.trial-code-banner > div {
  display: grid;
  gap: 7px;
}
.trial-code-banner strong {
  font-size: 18px;
  color: var(--ink);
}
.trial-code-banner code {
  display: inline-block;
  margin-left: 5px;
  padding: 5px 9px;
  border-radius: 8px;
  background: #173f2c;
  color: #fff;
  font-size: 16px;
  letter-spacing: .04em;
}
.trial-code-banner p {
  margin: 0;
  color: var(--muted);
}
.trial-code-banner .secondary-button {
  flex: 0 0 auto;
}

@media (max-width: 700px) {
  .trial-code-banner {
    align-items: stretch;
    flex-direction: column;
  }
  .trial-code-banner .secondary-button {
    width: 100%;
  }
}
