:root {
  color-scheme: light;
  --ink: #244d43;
  --muted: #52635b;
  --paper: #f3f6f1;
  --card: #fcfdfa;
  --gold: #cebb94;
  --line: #d9e1d8;
  font: 17px/1.6 system-ui, sans-serif;
  color: var(--ink);
  background: var(--paper);
}
* { box-sizing: border-box; }
body { margin: 0; }
header, footer {
  padding: 16px max(20px, calc((100% - 960px) / 2));
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  background: var(--card);
  border-bottom: 1px solid var(--line);
}
footer { border-top: 1px solid var(--line); border-bottom: 0; }
main { width: min(960px, 100% - 40px); margin: 0 auto; min-height: 65vh; padding: 36px 0 64px; }
a { color: inherit; text-underline-offset: 4px; }
.brand { display: inline-flex; gap: 10px; align-items: center; text-decoration: none; font-family: Georgia, serif; font-size: 1.2rem; }
h1, h2, h3 { font-family: Georgia, serif; font-weight: 400; line-height: 1.2; }
h1 { font-size: clamp(2rem, 6vw, 3.25rem); margin: 0 0 24px; }
h2 { font-size: 1.6rem; margin: 0 0 12px; }
h3 { font-size: 1.2rem; margin: 0 0 10px; }
p { margin: 0 0 16px; }
.panel { background: var(--card); border: 1px solid var(--line); border-top: 2px solid var(--gold); border-radius: 6px; padding: clamp(16px, 4vw, 28px); margin-bottom: 24px; }
.narrow { max-width: 550px; }
.sign-in-panel { max-width: 672px; }
.heading, .actions, .inline-form, .module { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; }
.heading { justify-content: space-between; margin-bottom: 18px; }
.heading h1 { margin: 0; }
.inline-form { align-items: flex-end; margin: 12px 0 16px; }
.inline-form input { margin: 0; }
label { display: block; font-weight: 600; }
input, button, .button { font: inherit; }
input:not([type="hidden"]) { width: 100%; border: 1px solid #8b9d91; border-radius: 4px; padding: 9px 10px; background: #fff; color: var(--ink); margin-bottom: 12px; }
.inline-form input:not([type="hidden"]) { margin: 0; }
input[type="file"] { font-size: .85rem; }
button, .button { padding: 9px 15px; min-height: 44px; border: 1px solid var(--ink); border-radius: 4px; background: var(--ink); color: #fff; display: inline-block; text-decoration: none; cursor: pointer; }
.secondary { background: transparent; color: var(--ink); }
button:disabled { opacity: .55; cursor: wait; }
:focus-visible { outline: 3px solid #887045; outline-offset: 3px; }
[hidden] { display: none !important; }
.status { margin: 10px 0 0; font-size: .91rem; }
.status:empty { margin: 0; }
.notice { color: var(--muted); }
.modules, .admin-modules, .roster { list-style: none; padding: 0; margin: 0; }
.modules > li, .admin-modules > li, .roster > li { border-top: 1px solid var(--line); padding: 14px 0; }
.module h3 { margin: 0; flex: 1 0 110px; }
.roster li { display: flex; align-items: center; justify-content: space-between; gap: 12px; overflow-wrap: anywhere; }
details { margin-top: 14px; }
summary { cursor: pointer; padding: 8px 0; font-weight: 600; }
.file-forms { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.file-form > a { display: block; font-size: .9rem; margin-bottom: 8px; }
progress { width: 100%; accent-color: var(--ink); }
video { width: 100%; max-height: 64vh; background: #19251f; border-radius: 4px; }
#player .actions { margin-top: 12px; }
#student-code { max-width: 15ch; letter-spacing: .2em; }
@media (max-width: 620px) {
  header { gap: 12px; font-size: .83rem; }
  .brand { font-size: 1rem; }
  .brand img { width: 25px; height: 25px; }
  .file-forms { grid-template-columns: 1fr; }
}
