:root{--ink:#183145;--accent:#22665b;--muted:#617584}body{background:#f4f7f8;color:var(--ink);font-family:system-ui,-apple-system,"Segoe UI",sans-serif}.topbar{background:var(--ink);color:white;padding:18px 0}.brand{font-size:1.25rem;font-weight:750;color:white;text-decoration:none}.adminnav{background:white;border-bottom:1px solid #dce4e9;padding:15px 0}.adminnav a{color:var(--ink);text-decoration:none;font-weight:550}.adminnav a[aria-current=page]{color:var(--accent);border-bottom:2px solid var(--accent)}.pagehead{margin-bottom:24px}.pagehead h1{font-size:1.9rem;font-weight:750;margin-bottom:8px}.pagehead p{color:var(--muted);max-width:800px}.panel{background:white;border:1px solid #dce4e9;border-radius:12px;padding:24px;margin-bottom:24px}.panel h2{font-size:1.2rem;font-weight:700;margin-bottom:18px}.stat{font-size:2rem;font-weight:750}.btn-primary{background:var(--accent);border-color:var(--accent)}.btn-primary:hover{background:#194d44;border-color:#194d44}.prose{white-space:pre-wrap;overflow-wrap:anywhere}.question-media{max-width:100%;max-height:350px;object-fit:contain;border:1px solid #dce4e9;border-radius:8px;padding:4px;background:white}.media-grid{display:flex;flex-wrap:wrap;gap:14px;margin:14px 0}.media-grid figure{max-width:320px;margin:0}.media-grid figcaption{font-size:.85rem;color:var(--muted);margin-top:6px}.choice{display:flex;align-items:flex-start;gap:12px;padding:16px;border:1px solid #dce4e9;border-radius:9px;margin:10px 0;cursor:pointer}.choice:has(input:checked){border-color:var(--accent);background:#eef7f4}.choice input{margin-top:5px}.examhead{display:flex;justify-content:space-between;gap:20px;align-items:start}.timer{font-size:1.6rem;font-weight:750;font-variant-numeric:tabular-nums;white-space:nowrap}.timer.urgent{color:#a32222}.questionnav{display:flex;gap:8px;flex-wrap:wrap}.questionnav a{min-width:38px}.questionnav .answered{background:#e6f4ed;border-color:#8cbbaa}.upload-entry{border:1px solid #dce4e9;padding:12px;border-radius:8px;margin:10px 0}.upload-entry img{max-width:180px;max-height:180px;display:block;margin-bottom:10px}.form-label{font-weight:600}.table td,.table th{vertical-align:middle}.table td{overflow-wrap:anywhere}details summary{cursor:pointer;font-weight:650}details[open] summary{margin-bottom:20px}.auth-panel{max-width:460px;margin:40px auto}.muted{color:var(--muted)}.badge-soft{background:#e9eff3;color:var(--ink)}.image-error{color:#a32222;font-size:.9rem}.missing-image{border:1px solid #c65858;padding:16px}.visually-hidden{position:absolute!important;width:1px!important;height:1px!important;overflow:hidden!important;clip:rect(0,0,0,0)!important}@media(max-width:600px){.panel{padding:16px}.examhead{flex-direction:column}.pagehead h1{font-size:1.5rem}.topbar span{display:none}}

.exam-workspace{display:grid;grid-template-columns:minmax(0,1fr) 300px;gap:24px;align-items:start}.exam-overview{position:sticky;top:20px}.overview-progress{font-size:1.2rem;font-weight:700;color:var(--accent)}.questionnav a[aria-current=step]{outline:3px solid #22665b;outline-offset:2px;font-weight:750}.exam-overview .questionnav{display:grid;grid-template-columns:repeat(5,1fr);gap:10px}.exam-overview .btn-primary{width:100%}.exam-question{min-height:460px}.choice:hover{background:#f4f9f7}.examhead{background:#e9f2ef;padding:22px;border-radius:12px}.topic-row{display:grid;grid-template-columns:2fr 1fr 1fr;gap:12px;align-items:center;padding:12px 0;border-bottom:1px solid #dce4e9}@media(max-width:991px){.exam-workspace{grid-template-columns:1fr}.exam-overview{position:static}.exam-overview .questionnav{display:flex}}

:fullscreen{background:#f4f7f8;overflow:auto}.proctor-gate{position:fixed;inset:0;z-index:10000;display:grid;place-items:center;background:rgba(24,49,69,.8);padding:20px}.proctor-gate[hidden]{display:none}.proctor-gate .panel{max-width:560px;margin:0}.proctor-rules{padding:12px 16px;background:#fff6de;border-radius:8px}.exam-image-viewer{max-width:95vw;max-height:95vh;border:0;border-radius:12px;padding:20px}.exam-image-viewer::backdrop{background:rgba(0,0,0,.7)}.exam-image-viewer img{display:block;max-width:85vw;max-height:75vh;margin-top:16px;object-fit:contain}

.college-heading{background:#fff;text-align:center;padding:24px 0 20px;border-bottom:1px solid #dce4e9}.college-heading h1{font-size:1.6rem;font-weight:750;margin:0 0 10px;line-height:1.3}.college-heading h2{font-size:1rem;font-weight:500;margin:6px 0;line-height:1.5}.topbar .brand{line-height:1.35}@media(max-width:600px){.college-heading{padding:18px 0}.college-heading h1{font-size:1.25rem}.college-heading h2{font-size:.85rem}.topbar .brand{font-size:1.05rem;max-width:72%}}

/* Shared theme for administration, student, and sign-in pages. */
:root {
    --ink: #24364b;
    --accent: #11796e;
    --muted: #64748b;
    --line: #e0e8f0;
    --bs-link-color: #2466a1;
    --bs-link-hover-color: #164b7c;
}
body {
    background: linear-gradient(135deg, #eef8f7 0, #f4f7fc 45%, #f7f4fc 100%);
    min-height: 100vh;
    line-height: 1.6;
}
.topbar {
    background: linear-gradient(110deg, #125b62, #244c79 70%, #514c85);
    box-shadow: 0 3px 14px #24364b14;
}
.brand { letter-spacing: -.02em; }
.brand:hover { color: #e1fff8; }
.college-heading {
    background: linear-gradient(110deg, #ffffff, #f5fbff 65%, #f8f5ff);
    border-bottom: 1px solid var(--line);
}
.college-heading h1 { color: #24516e; letter-spacing: -.025em; }
.college-heading h2 { color: #5c6e82; }
.college-identity { display: flex; align-items: center; gap: 28px; }
.college-logo { width: 180px; height: auto; flex-shrink: 0; border-radius: 8px; }
.college-title { flex: 1; min-width: 0; }
.adminnav { padding: 10px 0; border-color: var(--line); }
.adminnav > .container { gap: 6px !important; }
.adminnav a {
    padding: 8px 14px;
    border-radius: 9px;
    font-size: .93rem;
    color: #506176;
}
.adminnav a:hover { background: #f1f6fc; color: #2466a1; }
.adminnav a[aria-current=page] {
    background: #e4f4f0;
    color: #12675f;
    border-bottom: 0;
    box-shadow: inset 0 0 0 1px #c7e6de;
}
main.container { padding-top: 30px !important; }
.pagehead h1 { letter-spacing: -.035em; line-height: 1.25; }
.pagehead > h1::before {
    content: "";
    display: inline-block;
    width: 6px;
    height: .85em;
    margin-right: 12px;
    border-radius: 5px;
    background: linear-gradient(#11968a, #5383c2);
    vertical-align: -.04em;
}
.pagehead p { margin-bottom: 0; }
.panel {
    border-color: var(--line);
    border-radius: 16px;
    box-shadow: 0 5px 22px #2e456608;
}
.panel h2 { color: #304a65; letter-spacing: -.015em; }
.stat-card {
    position: relative;
    overflow: hidden;
    border-top: 4px solid #229b8b;
    background: linear-gradient(120deg, #ffffff, #edf9f5);
}
.stat-card::after {
    content: "";
    position: absolute;
    right: -18px;
    bottom: -30px;
    width: 100px;
    height: 100px;
    border: 18px solid #229b8b0c;
    border-radius: 50%;
    pointer-events: none;
}
.stat-card .stat { color: #11796e; font-size: 2.2rem; }
.stat-card .muted { font-weight: 600; }
.row > div:nth-child(4n+2) .stat-card { border-top-color: #5289cf; background: linear-gradient(120deg, #fff, #eef5ff); }
.row > div:nth-child(4n+2) .stat { color: #3469aa; }
.row > div:nth-child(4n+3) .stat-card { border-top-color: #9170c6; background: linear-gradient(120deg, #fff, #f5effc); }
.row > div:nth-child(4n+3) .stat { color: #7955a5; }
.row > div:nth-child(4n+4) .stat-card { border-top-color: #d2963c; background: linear-gradient(120deg, #fff, #fff8e9); }
.row > div:nth-child(4n+4) .stat { color: #956419; }
.btn { border-radius: 9px; font-weight: 600; padding: .55rem 1rem; }
.btn-sm { padding: .3rem .65rem; font-size: .85rem; }
.btn-primary {
    --bs-btn-bg: #11796e;
    --bs-btn-border-color: #11796e;
    --bs-btn-hover-bg: #0c6259;
    --bs-btn-hover-border-color: #0c6259;
    --bs-btn-active-bg: #0c6259;
    --bs-btn-active-border-color: #0c6259;
    --bs-btn-disabled-bg: #11796e;
    --bs-btn-disabled-border-color: #11796e;
    box-shadow: 0 3px 8px #11796e17;
}
.btn-outline-secondary { color: #455d79; border-color: #b9cadc; background: #fff; }
.btn-outline-secondary:hover { background: #edf3fa; color: #294c73; border-color: #8ba8c8; }
.btn-outline-primary { --bs-btn-color: #286aab; --bs-btn-border-color: #90b5dd; --bs-btn-hover-bg: #286aab; --bs-btn-hover-border-color: #286aab; }
.form-control, .form-select { border-color: #cddae6; border-radius: 9px; padding: .6rem .8rem; color: var(--ink); }
.form-control:focus, .form-select:focus { border-color: #4dafa3; box-shadow: 0 0 0 .2rem #11796e1a; }
.form-check-input:checked { background-color: var(--accent); border-color: var(--accent); }
.form-check-input:focus { border-color: #4dafa3; box-shadow: 0 0 0 .2rem #11796e1a; }
.form-text, .text-secondary { color: var(--muted) !important; }
.table { --bs-table-bg: transparent; --bs-table-border-color: #e6edf4; }
.table > thead > tr > th { background: #f0f5fa; color: #47627f; font-size: .85rem; font-weight: 700; padding: 13px 12px; white-space: nowrap; }
.table > tbody > tr > td { padding: 14px 12px; }
.table > tbody > tr:hover { background: #f7fbfd; }
.table > thead > tr > th:first-child { border-radius: 9px 0 0 0; }
.table > thead > tr > th:last-child { border-radius: 0 9px 0 0; }
.badge { border-radius: 7px; padding: .45em .65em; }
.badge-soft { background: #eaf0fc; color: #425f96; }
.alert { border-radius: 12px; border-width: 1px; }
.alert-success { background: #e8f7ef; color: #206342; border-color: #c4e7d2; }
.alert-info { background: #ecf5ff; color: #285e8e; border-color: #c8def4; }
.alert-warning, .proctor-rules { background: #fff6e5; color: #7e571c; border-color: #efd9ac; }
details > summary { color: #315f85; padding: 5px 0; }
.auth-panel { border-top: 4px solid var(--accent); padding: 32px; box-shadow: 0 12px 40px #264e7710; }
.auth-panel h1 { font-size: 1.9rem; font-weight: 750; letter-spacing: -.035em; }
.auth-panel .btn-primary { padding: .7rem 1rem; }
.examhead { background: linear-gradient(110deg, #e5f5ef, #edf4ff); border: 1px solid #cee4e0; border-radius: 16px; }
.timer { color: #146d63; }
.timer.urgent { color: #a32222; }
.exam-overview { border-top: 4px solid #5987c0; }
.choice { border-color: #d8e4ed; border-radius: 12px; }
.choice:hover { background: #f2f8fc; border-color: #a9c9dd; }
.choice:has(input:checked) { border-color: #34a392; background: #eaf8f3; box-shadow: inset 3px 0 #34a392; }
.questionnav a { border-radius: 8px; }
.questionnav .answered { background: #e5f5ee; border-color: #8ac8ad; color: #226349; }
.questionnav a[aria-current=step] { outline-color: #286aab; }
.upload-entry { background: #f8fbfe; border-color: var(--line); border-radius: 12px; }
.topic-row { border-color: var(--line); }
.page-link { color: #286aab; }
.active > .page-link { background: var(--accent); border-color: var(--accent); }
a:focus-visible, button:focus-visible, summary:focus-visible { outline: 3px solid #4e86bf; outline-offset: 3px; }
:fullscreen { background: #f3f7fb; }
footer { border-top: 1px solid var(--line); margin-top: 12px; }
@media (max-width:600px) {
    .college-identity { flex-direction: column; gap: 14px; }
    .college-logo { width: 145px; }
    main.container { padding-top: 22px !important; }
    .panel { border-radius: 12px; }
    .auth-panel { padding: 24px 20px; margin: 24px auto; }
    .adminnav a { padding: 7px 10px; font-size: .85rem; }
    .stat-card { padding: 18px; }
    .stat-card .stat { font-size: 1.9rem; }
    .examhead { padding: 18px; }
}
