/* A separate, compact workspace for the server-authenticated teacher account. */
.teacher-workspace,
.teacher-auth {
  --teacher-ink: #352a24;
  --teacher-muted: #6e6054;
  --teacher-line: #e0d7ca;
  --teacher-paper: #f8f5ef;
  --teacher-dark: #2c211b;
  font: 400 15px/1.6 'Manrope', sans-serif;
  color: var(--teacher-ink);
  text-align: left;
}
.teacher-workspace *, .teacher-auth * { box-sizing: border-box; }
.teacher-workspace :is(button, input, select, textarea),
.teacher-auth :is(button, input, select, textarea) { font-family: 'Manrope', sans-serif; }
.teacher-workspace :is(h1, h2, h3, p, ul, dl),
.teacher-auth :is(h1, h2, h3, p) { margin: 0; }
.teacher-workspace :is(h1, h2, h3),
.teacher-auth :is(h1, h2, h3) { font-family: 'Manrope', sans-serif; font-style: normal; text-transform: none; color: var(--teacher-ink); overflow-wrap: anywhere; }
.teacher-workspace :is(a, button):focus-visible,
.teacher-auth :is(a, button):focus-visible { outline: 3px solid #a8844a; outline-offset: 4px; }
.teacher-workspace button, .teacher-auth button { cursor: pointer; }
.teacher-workspace button:disabled, .teacher-auth button:disabled { opacity: .65; cursor: wait; }
.teacher-workspace .icon, .teacher-auth .icon { width: 20px; height: 20px; flex: 0 0 auto; }
.teacher-eyebrow { display: block; color: var(--teacher-muted); font-size: 12px; font-weight: 700; letter-spacing: .065em; text-transform: uppercase; }
.teacher-back { display: inline-flex; align-items: center; gap: 7px; color: var(--teacher-muted); font-size: 14px; font-weight: 600; text-decoration: none; }
.teacher-back > .icon { transform: rotate(180deg); width: 17px; height: 17px; }
.teacher-primary,
.teacher-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 44px;
  border: 1px solid transparent;
  border-radius: 10px;
  padding: 11px 19px;
  font: 600 14px/1.4 'Manrope', sans-serif;
  text-decoration: none;
  transition: background-color 160ms, box-shadow 160ms;
}
.teacher-primary { background: var(--teacher-dark); color: #f8f5ef; box-shadow: 0 3px 6px rgb(44 33 27 / 10%); }
.teacher-secondary { background: #fffdf9; border-color: #d9cfc1; color: var(--teacher-ink); }
.teacher-primary:hover { background: #49392e; }
.teacher-secondary:hover { background: #eee6d9; }

/* Entry and first-time password setup. */
.teacher-auth {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(340px, .95fr);
  gap: 65px;
  align-items: center;
  max-width: 1120px;
  margin: 32px auto;
  padding: 38px 36px;
  background: linear-gradient(135deg, #f5efe4, #f8f5ef 54%, #eee4d3);
  border-radius: 24px;
}
.teacher-auth-intro > .teacher-back { margin-bottom: 35px; }
.teacher-auth-intro h1 { font-size: clamp(30px, 3vw, 42px); line-height: 1.2; letter-spacing: -.035em; max-width: 15ch; margin-top: 14px; }
.teacher-auth-intro > p { color: var(--teacher-muted); font-size: 16px; line-height: 1.7; max-width: 40ch; margin-top: 20px; }
.teacher-auth-art { display: block; width: 100%; max-width: 360px; height: auto; margin: 20px auto -12px; filter: drop-shadow(0 15px 16px rgb(44 33 27 / 10%)); }
.teacher-auth-panel { padding: 34px; background: #fffdf9; border: 1px solid #e4dacc; border-radius: 20px; box-shadow: 0 14px 35px -18px rgb(44 33 27 / 22%); }
.teacher-auth-panel h2 { font-size: 25px; line-height: 1.25; letter-spacing: -.025em; margin-top: 10px; }
.teacher-auth-panel > p { color: var(--teacher-muted); font-size: 15px; margin-top: 14px; }
.teacher-auth-panel .teacher-form { margin-top: 26px; }
.teacher-auth-panel .teacher-primary { width: 100%; }
.teacher-student-login { display: block; color: var(--teacher-muted); font-size: 13px; margin-top: 22px; text-align: center; text-underline-offset: 4px; }
.teacher-bound-account { display: flex; align-items: center; gap: 12px; background: #f0e9dd; border-radius: 11px; padding: 14px; }
.teacher-bound-account span { display: block; color: var(--teacher-muted); font-size: 12px; }
.teacher-bound-account strong { display: block; font-size: 14px; overflow-wrap: anywhere; }
.teacher-form .teacher-setup-note { color: var(--teacher-muted); font-size: 13px; line-height: 1.6; }

/* Header and roster stay visually quieter than the student's work. */
.teacher-workspace { min-height: 100vh; background: #f4f0e8; }
.teacher-header { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 18px 30px; border-bottom: 1px solid var(--teacher-line); background: #fffdf9; }
.teacher-brand { color: var(--teacher-dark); font: italic 700 24px/1.1 'PT Serif', Georgia, serif; text-decoration: none; }
.teacher-brand > span { display: block; margin-top: 6px; font: 600 11px/1.4 'Manrope', sans-serif; letter-spacing: .05em; text-transform: uppercase; color: var(--teacher-muted); }
.teacher-header > div { display: flex; align-items: center; gap: 22px; font-size: 13px; }
.teacher-header > div > span { font-weight: 600; }
.teacher-header a:not(.teacher-brand), .teacher-header button { color: var(--teacher-muted); }
.teacher-header button { display: flex; gap: 7px; align-items: center; border: 0; background: transparent; font-size: 13px; min-height: 40px; padding: 7px 0; }
.teacher-layout { display: grid; grid-template-columns: 250px minmax(0, 1fr); max-width: 1600px; margin: 0 auto; }
.teacher-roster { position: sticky; top: 0; align-self: start; min-height: calc(100vh - 85px); padding: 28px 16px; background: #f9f6f0; border-right: 1px solid var(--teacher-line); }
.teacher-roster-title { display: flex; gap: 9px; align-items: center; padding: 0 10px; color: var(--teacher-ink); font-size: 15px; font-weight: 700; text-decoration: none; }
.teacher-roster-title > span { margin-left: auto; color: var(--teacher-muted); font-size: 12px; }
#teacher-roster-search { margin: 23px 7px 18px; }
#teacher-roster-search label { display: block; color: var(--teacher-muted); font-size: 12px; margin-bottom: 7px; }
#teacher-roster-search > div { display: flex; border: 1px solid #d8cdbc; border-radius: 9px; background: #fffdf9; }
#teacher-roster-search input { width: 100%; min-width: 0; border: 0; background: transparent; padding: 11px 10px; border-radius: 9px 0 0 9px; font-size: 13px; color: var(--teacher-ink); }
#teacher-roster-search button { border: 0; background: transparent; color: var(--teacher-ink); width: 36px; flex-shrink: 0; padding: 7px; }
.teacher-roster nav { max-height: calc(100vh - 260px); overflow-y: auto; }
.teacher-roster nav ul { list-style: none; padding: 0; display: grid; gap: 6px; }
.teacher-roster nav a { display: flex; gap: 10px; align-items: center; padding: 12px 9px; border-radius: 11px; text-decoration: none; color: var(--teacher-ink); border: 1px solid transparent; }
.teacher-roster nav a:hover { background: #f0e7d8; }
.teacher-roster nav a[aria-current] { background: #ece0ca; border-color: #d9c6a4; }
.teacher-roster nav a > span:not(.teacher-avatar) { min-width: 0; }
.teacher-roster nav strong { display: block; font-size: 13px; line-height: 1.4; }
.teacher-roster nav small { display: block; color: var(--teacher-muted); font-size: 11px; line-height: 1.5; overflow-wrap: anywhere; margin-top: 3px; }
.teacher-roster-badge { flex-shrink: 0; align-self: flex-start; margin-left: auto; min-width: 20px; padding: 2px 5px; border-radius: 6px; background: #54402d; color: #fff9ee; text-align: center; font-size: 11px; }
.teacher-roster-empty { color: var(--teacher-muted); padding: 10px; font-size: 13px; }
.teacher-avatar { width: 42px; height: 42px; flex: 0 0 auto; display: grid; place-items: center; background: linear-gradient(135deg, #e9ddc6, #d3bd94); color: #4c3a25; border-radius: 13px; font-size: 18px; font-weight: 600; overflow: hidden; }
.teacher-avatar img { display: block; width: 100%; height: 100%; object-fit: cover; }
.teacher-avatar.is-large { width: 76px; height: 76px; border-radius: 21px; font-size: 30px; }
.teacher-main { min-width: 0; padding: 32px clamp(24px, 3vw, 42px) 50px; }
.teacher-page-heading { display: flex; justify-content: space-between; align-items: center; gap: 25px; margin-bottom: 27px; }
.teacher-page-heading h1, .teacher-student-heading h1 { font-size: 29px; line-height: 1.25; letter-spacing: -.03em; margin-top: 6px; }
.teacher-page-heading p { font-size: 14px; color: var(--teacher-muted); margin-top: 11px; max-width: 65ch; }
.teacher-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-bottom: 26px; }
.teacher-stat { border-radius: 16px; padding: 22px; border: 1px solid rgb(44 33 27 / 7%); box-shadow: inset 0 1px 0 rgb(255 255 255 / 35%); }
.teacher-stat > span { font-size: 13px; font-weight: 600; }
.teacher-stat > strong { display: block; font-size: 35px; line-height: 1.2; letter-spacing: -.04em; margin: 10px 0; }
.teacher-stat > p { font-size: 12px; line-height: 1.55; max-width: 28ch; }
.teacher-stat.is-cream { background: linear-gradient(135deg, #fffdf9, #ede5d7); color: #352a24; }
.teacher-stat.is-gold { background: linear-gradient(135deg, #e8d8b8, #d5bc8d); color: #352a24; }
.teacher-stat.is-espresso { background: linear-gradient(135deg, #514034, #2c211b); color: #f8f5ef; }
.teacher-stat.is-espresso > p { color: #e8ddce; }
.teacher-panel { background: #fffdf9; border: 1px solid var(--teacher-line); border-radius: 16px; padding: 23px; min-width: 0; }
.teacher-panel-heading { display: flex; align-items: center; justify-content: space-between; gap: 18px; margin-bottom: 19px; }
.teacher-panel-heading h2 { font-size: 19px; line-height: 1.3; font-weight: 700; letter-spacing: -.025em; }
.teacher-panel-heading > span { color: var(--teacher-muted); font-size: 12px; white-space: nowrap; }
.teacher-student-cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.teacher-student-card { display: block; padding: 19px; border: 1px solid #e0d5c4; border-radius: 12px; text-decoration: none; color: var(--teacher-ink); transition: box-shadow 180ms, border-color 180ms; }
.teacher-student-card:hover { border-color: #bfa472; box-shadow: 0 6px 16px -8px rgb(44 33 27 / 22%); }
.teacher-student-card-heading { display: flex; align-items: center; gap: 12px; }
.teacher-student-card-heading > div { min-width: 0; }
.teacher-student-card-heading > .icon { width: 17px; margin-left: auto; }
.teacher-student-card-heading h3 { font-size: 16px; line-height: 1.4; }
.teacher-student-card-heading p { font-size: 12px; color: var(--teacher-muted); overflow-wrap: anywhere; margin-top: 3px; }
.teacher-student-card dl { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; padding: 18px 0; margin-top: 15px; border-top: 1px solid #e9dfd1; }
.teacher-student-card dt { color: var(--teacher-muted); font-size: 11px; line-height: 1.4; }
.teacher-student-card dd { font-size: 21px; font-weight: 600; margin: 5px 0 0; }
.teacher-last-activity { color: var(--teacher-muted); font-size: 11px; }
.teacher-empty { padding: 27px 12px 30px; text-align: center; color: var(--teacher-muted); }
.teacher-empty > .icon { width: 30px; height: 30px; color: #9b7947; margin: 0 auto 11px; }
.teacher-empty h3 { font-size: 16px; line-height: 1.45; margin-bottom: 9px; }
.teacher-empty p { font-size: 13px; line-height: 1.65; max-width: 52ch; margin-inline: auto; }
.teacher-loading { padding: 25px 5px; color: var(--teacher-muted); font-size: 14px; }
.teacher-error { display: flex; align-items: flex-start; gap: 12px; background: #f5e5d9; border: 1px solid #d9b9a2; border-radius: 11px; padding: 16px; margin-bottom: 22px; color: #663e2b; font-size: 14px; }
.teacher-error p { flex: 1; }
.teacher-error button { flex-shrink: 0; background: transparent; border: 0; color: inherit; font-size: 13px; font-weight: 700; text-decoration: underline; text-underline-offset: 3px; }

/* The detailed card keeps manual review and measured activity separate. */
.teacher-student-heading { display: flex; gap: 18px; align-items: center; margin: 23px 0; }
.teacher-student-heading > div { min-width: 0; }
.teacher-student-heading p { font-size: 14px; color: var(--teacher-muted); overflow-wrap: anywhere; margin-top: 5px; }
.teacher-student-heading > button { margin-left: auto; flex-shrink: 0; }
.teacher-student-sections { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 26px; }
.teacher-student-sections a { color: #59472e; background: #ede5d7; padding: 8px 13px; font-size: 13px; border-radius: 8px; text-decoration: none; }
.teacher-student-sections a:hover { background: #dfd0b7; }
.teacher-detail-grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 20px; align-items: start; }
.teacher-detail-grid > div { display: grid; gap: 20px; min-width: 0; }
.teacher-detail-grid .teacher-panel { scroll-margin-top: 22px; }
.teacher-assignment-list, .teacher-writing-list, .teacher-variant-list, .teacher-lesson-list, .teacher-topic-results { list-style: none; padding: 0; }
.teacher-assignment-list > li, .teacher-writing-list > li { padding: 20px 0; border-top: 1px solid #e8dfd1; }
.teacher-assignment-list > li:first-child, .teacher-writing-list > li:first-child { border-top: 0; padding-top: 0; }
.teacher-list-title { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.teacher-list-title h3 { font-size: 15px; line-height: 1.5; }
.teacher-status { display: inline-block; padding: 4px 8px; border-radius: 6px; flex-shrink: 0; font-size: 11px; font-weight: 600; white-space: nowrap; }
.teacher-status.is-neutral { color: #625449; background: #eee8df; }
.teacher-status.is-attention { color: #6b451b; background: #f0dfbc; }
.teacher-status.is-complete { color: #405247; background: #e8ede3; }
.teacher-assignment-list > li > p, .teacher-student-note { margin-top: 10px; font-size: 13px; line-height: 1.65; color: var(--teacher-muted); white-space: pre-wrap; overflow-wrap: anywhere; }
.teacher-list-meta { display: grid; gap: 4px; margin-top: 12px; color: var(--teacher-muted); font-size: 11px; }
.teacher-list-date { display: block; margin-top: 5px; font-size: 11px; color: var(--teacher-muted); }
.teacher-file { display: flex; align-items: center; gap: 9px; border: 1px solid #e3d7c5; border-radius: 9px; padding: 12px; margin: 14px 0 10px; font-size: 13px; overflow-wrap: anywhere; }
.teacher-file a { color: #6b4b24; text-underline-offset: 3px; }
.teacher-review-result { background: #f0f0e7; border-radius: 11px; padding: 16px; margin-top: 15px; }
.teacher-review-result > div { display: flex; align-items: center; gap: 16px; }
.teacher-review-result strong { font-size: 22px; white-space: nowrap; }
.teacher-review-result span { color: var(--teacher-muted); font-size: 11px; }
.teacher-review-result > p { margin-top: 12px; font-size: 13px; line-height: 1.7; white-space: pre-wrap; overflow-wrap: anywhere; }
.teacher-data-scope { display: flex; gap: 10px; color: var(--teacher-muted); font-size: 12px; line-height: 1.65; padding: 12px 0 18px; }
.teacher-data-scope > .icon { width: 17px; height: 17px; margin-top: 2px; }
.teacher-topic-columns { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.teacher-topic-group { border-radius: 11px; padding: 15px; }
.teacher-topic-group.is-strong { background: #eef0e7; }
.teacher-topic-group.is-weak { background: #f4e9d3; }
.teacher-topic-group h3 { display: flex; align-items: center; gap: 7px; font-size: 13px; line-height: 1.4; margin-bottom: 12px; }
.teacher-topic-group h3 > .icon { width: 17px; height: 17px; }
.teacher-topic-group ul { padding: 0 0 0 17px; font-size: 12px; line-height: 1.55; }
.teacher-topic-group li + li { margin-top: 7px; }
.teacher-topic-group > p { color: var(--teacher-muted); font-size: 12px; line-height: 1.6; }
.teacher-topic-results li { border-top: 1px solid #e6ddcf; padding: 13px 0; font-size: 12px; }
.teacher-topic-results li > div { display: flex; justify-content: space-between; gap: 12px; }
.teacher-topic-results span, .teacher-topic-results small { color: var(--teacher-muted); font-size: 11px; }
.teacher-topic-results p { margin-top: 8px; overflow-wrap: anywhere; }
.teacher-topic-results small { display: block; margin-top: 5px; }
.teacher-variant-list li { display: flex; align-items: center; gap: 18px; justify-content: space-between; padding: 16px 0; border-top: 1px solid #e6ddcf; }
.teacher-variant-list li:first-child { border: 0; padding-top: 0; }
.teacher-variant-list h3 { font-size: 15px; line-height: 1.4; }
.teacher-variant-list li > div > span { display: block; color: var(--teacher-muted); font-size: 11px; margin-top: 5px; }
.teacher-variant-list p { font-size: 12px; margin-top: 8px; }
.teacher-variant-score { font-size: 27px; text-align: right; white-space: nowrap; }
.teacher-variant-score small { display: block; font-size: 11px; font-weight: 400; color: var(--teacher-muted); }
.teacher-variant-score > span { font-size: 12px; font-weight: 500; color: var(--teacher-muted); }
.teacher-lesson-list li { display: flex; gap: 12px; border-top: 1px solid #e6ddcf; padding: 15px 0; }
.teacher-lesson-list li:first-child { border: 0; padding-top: 0; }
.teacher-lesson-list > li > .icon { color: #8d6f46; margin-top: 2px; }
.teacher-lesson-list h3 { font-size: 14px; line-height: 1.45; }
.teacher-lesson-list span { display: block; font-size: 11px; color: var(--teacher-muted); margin-top: 5px; }
.teacher-lesson-list p { font-size: 12px; margin-top: 8px; white-space: pre-wrap; overflow-wrap: anywhere; }
.teacher-section-note { color: var(--teacher-muted); font-size: 11px; line-height: 1.6; margin-top: 14px !important; }
.teacher-data-notes { margin-top: 22px; color: var(--teacher-muted); font-size: 13px; }
.teacher-data-notes summary { display: flex; align-items: center; gap: 10px; cursor: pointer; padding: 12px 0; }
.teacher-data-notes ul { padding: 0 0 0 28px; max-width: 90ch; }
.teacher-data-notes li { margin-top: 7px; }
.teacher-data-notes summary > .icon:last-child { width: 16px; }

/* Form controls remain native and usable with keyboard and password managers. */
.teacher-form { display: grid; gap: 18px; }
.teacher-field { display: grid; gap: 7px; min-width: 0; }
.teacher-field label { font-size: 13px; font-weight: 600; line-height: 1.5; }
.teacher-field label > span { color: var(--teacher-muted); font-size: 11px; font-weight: 400; }
.teacher-field :is(input, select, textarea) { width: 100%; min-width: 0; padding: 11px 12px; border: 1px solid #cfc1ae; border-radius: 8px; background: #fffdf9; color: var(--teacher-ink); font-size: 14px; line-height: 1.5; }
.teacher-field input { min-height: 44px; }
.teacher-field textarea { resize: vertical; min-height: 94px; }
.teacher-field :is(input, select, textarea):focus { border-color: #967746; outline: 2px solid #dcc79e; outline-offset: 1px; }
.teacher-field small { color: var(--teacher-muted); font-size: 11px; line-height: 1.6; }
.teacher-form-columns { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 15px; }
.teacher-form-status { color: #794b30; font-size: 13px; line-height: 1.55; }
.teacher-form-status:empty { display: none; }
.teacher-form-disclosure { border-top: 1px solid #e4d7c3; margin-top: 15px; }
.teacher-form-disclosure summary, .teacher-detail-disclosure summary { display: flex; align-items: center; gap: 8px; cursor: pointer; padding: 15px 0; color: #674d28; font-size: 13px; font-weight: 600; list-style: none; }
.teacher-form-disclosure summary::-webkit-details-marker, .teacher-detail-disclosure summary::-webkit-details-marker { display: none; }
.teacher-form-disclosure summary > .icon:last-child, .teacher-detail-disclosure summary > .icon:last-child { width: 16px; margin-left: auto; }
.teacher-form-disclosure[open] summary > .icon:last-child, .teacher-detail-disclosure[open] summary > .icon:last-child { transform: rotate(90deg); }
.teacher-form-disclosure .teacher-form { padding: 4px 0 7px; }
.teacher-detail-disclosure { margin-top: 15px; }

@media (max-width: 1180px) {
  .teacher-layout { grid-template-columns: 220px minmax(0, 1fr); }
  .teacher-main { padding-inline: 24px; }
  .teacher-detail-grid { grid-template-columns: 1fr; }
  .teacher-student-cards { grid-template-columns: 1fr; }
  .teacher-stat { padding: 18px; }
  .teacher-stat > strong { font-size: 31px; }
  .teacher-auth { gap: 35px; margin-inline: 20px; }
}
@media (max-width: 800px) {
  .teacher-auth { grid-template-columns: 1fr; max-width: 600px; padding: 28px; gap: 24px; }
  .teacher-auth-intro h1 { font-size: 31px; max-width: 18ch; }
  .teacher-auth-intro > .teacher-back { margin-bottom: 24px; }
  .teacher-auth-art { display: none; }
  .teacher-auth-panel { padding: 28px; }
  .teacher-layout { grid-template-columns: 1fr; }
  .teacher-roster { position: static; min-height: 0; padding: 18px 20px; border-right: 0; border-bottom: 1px solid var(--teacher-line); }
  .teacher-roster nav { max-height: 200px; }
  .teacher-roster nav ul { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  #teacher-roster-search { margin-top: 15px; }
  .teacher-header { padding: 17px 22px; }
  .teacher-header > div { gap: 16px; }
  .teacher-main { padding: 26px 22px 40px; }
}
@media (max-width: 560px) {
  .teacher-header > div > span { display: none; }
  .teacher-header > div { gap: 13px; font-size: 12px; }
  .teacher-header { padding-inline: 17px; }
  .teacher-brand { font-size: 21px; }
  .teacher-roster nav ul { grid-template-columns: 1fr; }
  .teacher-roster { padding-inline: 12px; }
  .teacher-main { padding: 23px 16px 35px; }
  .teacher-page-heading { align-items: flex-start; flex-direction: column; gap: 17px; }
  .teacher-page-heading h1, .teacher-student-heading h1 { font-size: 26px; }
  .teacher-stats { grid-template-columns: 1fr; gap: 9px; }
  .teacher-stat { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 5px 18px; padding: 16px; border-radius: 12px; }
  .teacher-stat > span { font-size: 13px; line-height: 1.4; display: block; }
  .teacher-stat > strong { grid-column: 2; grid-row: 1 / 3; align-self: center; font-size: 30px; margin: 0; }
  .teacher-stat > p { font-size: 12px; max-width: none; }
  .teacher-panel { padding: 19px 17px; }
  .teacher-panel-heading h2 { font-size: 18px; }
  .teacher-student-heading { gap: 12px; flex-wrap: wrap; }
  .teacher-avatar.is-large { width: 60px; height: 60px; border-radius: 16px; }
  .teacher-student-heading > div { flex: 1; }
  .teacher-student-heading > button { margin-left: 0; margin-top: 3px; }
  .teacher-list-title { flex-direction: column; gap: 7px; }
  .teacher-topic-columns { grid-template-columns: 1fr; }
  .teacher-form-columns { grid-template-columns: 1fr; }
  .teacher-form :is(input, select, textarea) { font-size: 16px; }
  .teacher-auth { margin: 16px 12px; padding: 22px 17px; border-radius: 18px; }
  .teacher-auth-panel { padding: 25px 20px; }
  .teacher-auth-panel h2 { font-size: 23px; }
  .teacher-error { flex-wrap: wrap; }
}
@media (prefers-reduced-motion: reduce) {
  .teacher-primary, .teacher-secondary, .teacher-student-card { transition: none; }
}

.teacher-entry-link { display: inline-block; margin-top: 22px; padding-top: 16px; border-top: 1px solid #ded5ce; color: #543a2d; font-size: 14px; font-weight: 700; text-decoration-thickness: 1px; text-underline-offset: 4px; }

/* Clear section bands on the individual student's record, including shared analytics. */
.teacher-main > .student-analytics .sa-panel { --teacher-section-padding: 23px; padding: var(--teacher-section-padding); }
.teacher-main > .student-analytics .sa-panel > header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 16px;
  margin: calc(-1 * var(--teacher-section-padding)) calc(-1 * var(--teacher-section-padding)) 20px;
  padding: 17px var(--teacher-section-padding);
  border-radius: 16px 16px 0 0;
  background: #493325;
  color: #fffaf2;
}
.teacher-main > .student-analytics .sa-panel > header h2 { color: #fffaf2; font-size: 19px; line-height: 1.4; font-weight: 800; }
.teacher-main > .student-analytics .sa-panel > header :is(p, span) { color: #f1dfce; font-size: 13px; line-height: 1.6; }
.teacher-main > .student-analytics .sa-practice > header { display: block; }
.teacher-main > .student-analytics .sa-practice > header > span { margin-top: 6px; }
.teacher-main > .student-analytics .sa-panel > header .sa-link {
  min-height: 40px;
  flex-shrink: 0;
  color: #fffaf2;
  font-size: 13px;
  font-weight: 750;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
  white-space: normal;
}
.teacher-main > .student-analytics .sa-panel > header .sa-link:hover { color: #f1dfce; text-decoration-thickness: 2px; }
.teacher-main > .student-analytics .sa-panel > header .sa-link:focus-visible { outline: 3px solid #f2cc84; outline-offset: 4px; border-radius: 4px; }
.teacher-detail-grid .teacher-panel { --teacher-heading-pad-x: 23px; --teacher-heading-pad-y: 23px; }
.teacher-detail-grid .teacher-panel > .teacher-panel-heading {
  flex-wrap: wrap;
  gap: 10px 16px;
  margin: calc(-1 * var(--teacher-heading-pad-y)) calc(-1 * var(--teacher-heading-pad-x)) 20px;
  padding: 17px var(--teacher-heading-pad-x);
  border-radius: 15px 15px 0 0;
  background: #76512f;
  color: #fffaf2;
}
.teacher-detail-grid .teacher-panel-heading h2 { color: #fffaf2; font-size: 19px; line-height: 1.4; font-weight: 800; }
.teacher-detail-grid .teacher-panel-heading > span { color: #fffaf2; font-size: 13px; font-weight: 700; }
@media (max-width: 1160px) {
  .teacher-main > .student-analytics .sa-panel { --teacher-section-padding: 20px; }
}
@media (max-width: 560px) {
  .teacher-detail-grid .teacher-panel { --teacher-heading-pad-x: 17px; --teacher-heading-pad-y: 19px; }
  .teacher-main > .student-analytics .sa-panel > header h2,
  .teacher-detail-grid .teacher-panel-heading h2 { font-size: 18px; }
}
@media (max-width: 520px) {
  .teacher-main > .student-analytics .sa-panel { --teacher-section-padding: 18px; }
}
