:root {
  --blue: #1f7bf2;
  --blue-dark: #0d63d8;
  --primary-blue: #1467f2;
  --primary-blue-hover: #0d56d9;
  --light-blue-bg: #eef6ff;
  --ink: #101827;
  --text-primary: #101827;
  --muted: #697386;
  --text-muted: #667085;
  --line: #d7dce5;
  --border-color: #e3eaf4;
  --border: var(--border-color);
  --panel: #ffffff;
  --card-bg: #ffffff;
  --page: #f3f6fc;
  --page-bg: #f5f7fb;
  --danger: #d93245;
  --danger-soft: #fff1f3;
  --success: #138a52;
  --success-soft: #eefbf4;
  --warning-orange: #f97316;
  --warning-soft: #fff4e6;
  --purple-accent: #7c3aed;
  --purple-soft: #f2eaff;
  --radius-sm: 10px;
  --radius-md: 14px;
  --radius-lg: 18px;
  --radius-xl: 24px;
  --shadow: 0 18px 35px rgba(18, 31, 55, 0.16);
  --card-shadow: 0 16px 36px rgba(15, 23, 42, 0.07);
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 20px;
  --space-6: 24px;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--page);
  color: var(--ink);
  font-family: "Poppins", Arial, sans-serif;
}

body.drawer-scroll-lock {
  height: 100vh;
  overflow: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

button,
input,
select {
  font: inherit;
}

.toast-container {
  position: fixed;
  top: 18px;
  left: 50%;
  z-index: 2200;
  width: min(460px, calc(100vw - 28px));
  display: grid;
  gap: 10px;
  transform: translateX(-50%);
  pointer-events: none;
}

.app-toast {
  min-height: 66px;
  padding: 14px;
  border: 1px solid #dbe4f1;
  border-left: 5px solid #1f7bf2;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 18px 38px rgba(15, 23, 42, 0.16);
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) 32px;
  gap: 12px;
  align-items: start;
  pointer-events: auto;
  animation: toast-in 180ms ease-out;
}

.app-toast.leaving {
  animation: toast-out 180ms ease-in forwards;
}

.app-toast > svg {
  width: 24px;
  height: 24px;
  color: #1f7bf2;
}

.app-toast.success { border-left-color: #138a52; }
.app-toast.success > svg { color: #138a52; }
.app-toast.warning { border-left-color: #f59e0b; }
.app-toast.warning > svg { color: #d97706; }
.app-toast.error { border-left-color: #d93245; }
.app-toast.error > svg { color: #d93245; }

.app-toast strong,
.app-toast span {
  display: block;
}

.app-toast strong {
  font-weight: 900;
}

.app-toast span {
  margin-top: 3px;
  color: #667085;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.35;
}

.app-toast button {
  width: 30px;
  height: 30px;
  border: 0;
  border-radius: 8px;
  background: #f2f6fc;
  color: #475467;
  display: grid;
  place-items: center;
  cursor: pointer;
}

.app-toast button svg {
  width: 16px;
  height: 16px;
}

.feedback-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 2100;
  padding: 22px;
  background: rgba(15, 23, 42, 0.52);
  display: grid;
  place-items: center;
  animation: modal-fade 160ms ease-out;
}

.feedback-modal-overlay.closing {
  animation: modal-fade-out 160ms ease-in forwards;
}

.feedback-modal {
  width: min(560px, 100%);
  padding: 24px 26px 26px;
  border-radius: 20px;
  background: #fff;
  box-shadow: 0 28px 70px rgba(15, 23, 42, 0.28);
  display: grid;
  gap: 18px;
}

.feedback-modal-main {
  min-width: 0;
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr);
  gap: 18px;
  align-items: start;
}

.feedback-modal-content {
  min-width: 0;
}

.feedback-modal-icon {
  width: 58px;
  height: 58px;
  border-radius: 16px;
  background: #eaf2ff;
  color: #1f7bf2;
  display: grid;
  place-items: center;
}

.feedback-modal.danger .feedback-modal-icon {
  background: #fff1f3;
  color: #d93245;
}

.feedback-modal-icon svg {
  width: 28px;
  height: 28px;
}

.feedback-modal h2 {
  margin: 0;
  font-size: 24px;
  line-height: 1.15;
}

.feedback-modal p {
  margin: 8px 0 0;
  color: #667085;
  font-weight: 700;
  line-height: 1.45;
}

.feedback-modal-field {
  margin-top: 16px;
  display: grid;
  gap: 8px;
  color: #344054;
  font-weight: 900;
}

.feedback-modal-field input {
  width: 100%;
  min-height: 46px;
  border: 1px solid #d7e1ef;
  border-radius: 12px;
  padding: 0 14px;
  background: #f9fbff;
  color: #101828;
}

.feedback-modal-error {
  margin-top: 12px !important;
  padding: 10px 12px;
  border-radius: 10px;
  background: #fff1f3;
  color: #bd1f33 !important;
  font-size: 13px;
}

.feedback-suggestion-list {
  margin-top: 12px;
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.feedback-suggestion-list button {
  border: 1px solid #d7e1ef;
  border-radius: 999px;
  background: #f4f8ff;
  color: #1f5fbf;
  padding: 7px 10px;
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
}

.publish-checklist {
  margin-top: 16px;
  display: grid;
  gap: 12px;
}

.publish-checklist strong {
  color: #172033;
  font-size: 13px;
}

.publish-checklist ul {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 8px;
}

.publish-checklist li {
  display: grid;
  grid-template-columns: 20px minmax(0, 1fr);
  gap: 8px;
  align-items: start;
  color: #475467;
  font-size: 13px;
  font-weight: 800;
}

.publish-checklist svg {
  width: 18px;
  height: 18px;
  color: #d93245;
}

.publish-checklist li svg[data-lucide="triangle-alert"] {
  color: #d97706;
}

.feedback-modal-actions {
  margin-top: 2px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  align-items: center;
}

.feedback-modal-actions:has(button:only-child) {
  grid-template-columns: minmax(0, 1fr);
}

.feedback-modal-actions button {
  min-height: 46px;
  width: 100%;
}

.feedback-modal .primary-button.danger {
  background: #d93245;
  border-color: #d93245;
}

.feedback-modal.certificate-modal {
  width: min(980px, calc(100vw - 32px));
  max-height: calc(100vh - 32px);
  overflow: auto;
}

.feedback-modal.certificate-generator-modal {
  width: min(1180px, calc(100vw - 32px));
}

.assessment-review-summary {
  margin-top: 16px;
  padding: 14px;
  border: 1px solid #d8e5f7;
  border-radius: 16px;
  background: #f8fbff;
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
}

.assessment-review-summary > span {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: #eaf2ff;
  color: #1f7bf2;
  display: grid;
  place-items: center;
}

.assessment-review-summary strong,
.assessment-review-summary small {
  display: block;
}

.assessment-review-summary strong {
  color: #07111f;
  font-size: 28px;
  line-height: 1;
  font-weight: 900;
}

.assessment-review-summary small {
  margin-top: 4px;
  color: #667085;
  font-size: 12px;
  font-weight: 800;
}

.assessment-review-list {
  max-height: min(420px, 52vh);
  margin-top: 14px;
  padding-right: 4px;
  display: grid;
  gap: 10px;
  overflow: auto;
}

.assessment-review-row {
  padding: 12px;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  background: #fff;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 10px;
}

.assessment-review-row > span {
  width: 34px;
  height: 34px;
  border-radius: 12px;
  display: grid;
  place-items: center;
}

.assessment-review-row.correct > span {
  background: #e8f8ef;
  color: #0aa85b;
}

.assessment-review-row.incorrect > span {
  background: #fff1f3;
  color: #d93245;
}

.assessment-review-row strong,
.assessment-review-row p,
.assessment-review-row small,
.assessment-review-row em {
  display: block;
}

.assessment-review-row strong {
  color: #07111f;
  font-size: 13px;
  font-weight: 900;
}

.assessment-review-row p {
  margin: 3px 0 8px;
  color: #344054;
  font-size: 13px;
  font-weight: 800;
}

.assessment-review-row small {
  color: #667085;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.35;
}

.assessment-review-row em {
  margin-top: 8px;
  color: #1f5fbf;
  font-size: 12px;
  font-style: normal;
  font-weight: 900;
  line-height: 1.35;
}

.feedback-modal-spinner {
  width: 16px;
  height: 16px;
  border: 2px solid rgba(255, 255, 255, 0.55);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 700ms linear infinite;
}

.button-spinner {
  width: 18px;
  height: 18px;
  border: 2px solid rgba(255, 255, 255, 0.55);
  border-top-color: #fff;
  border-radius: 50%;
  display: inline-block;
  animation: spin 700ms linear infinite;
}

.small-button .button-spinner,
.student-assessment-action .button-spinner {
  border-color: rgba(31, 123, 242, 0.22);
  border-top-color: #1f7bf2;
}

button.is-loading {
  cursor: wait;
}

@keyframes toast-in {
  from { opacity: 0; transform: translateY(-10px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes toast-out {
  to { opacity: 0; transform: translateY(-8px); }
}

@keyframes modal-fade {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes modal-fade-out {
  to { opacity: 0; }
}

.auth-shell {
  width: min(1420px, 100%);
  min-height: 100vh;
  margin: 0 auto;
  padding: clamp(14px, 2vh, 30px) clamp(18px, 3.4vw, 58px);
  display: grid;
  grid-template-columns: minmax(360px, 0.95fr) minmax(390px, 526px);
  align-items: center;
  gap: clamp(26px, 4vw, 64px);
}

body[data-page="login"] .auth-shell {
  width: min(1520px, calc(100% - 72px));
  grid-template-columns: minmax(560px, 700px) minmax(430px, 560px);
  justify-content: center;
  align-items: center;
  gap: clamp(72px, 8vw, 128px);
}

body[data-page="login"] .brand-panel {
  display: grid;
  align-content: center;
}

body[data-page="login"] .brand-mark {
  margin-bottom: 26px;
}

body[data-page="login"] .brand-panel h1 {
  font-size: clamp(48px, 4.4vw, 68px);
  line-height: 1.04;
}

body[data-page="login"] .brand-panel p {
  max-width: 650px;
  margin-top: 24px;
  margin-bottom: 24px;
  font-size: clamp(17px, 1.28vw, 21px);
}

body[data-page="login"] .asset-stage,
body[data-page="login"] .feature-strip {
  width: min(640px, 100%);
  margin-left: 0;
}

body[data-page="login"] .asset-stage {
  border-radius: 20px;
}

body[data-page="login"] .feature-strip {
  min-height: 78px;
  margin-top: 18px;
  padding: 12px 18px;
  border-radius: 16px;
}

body[data-page="login"] .feature-strip div {
  gap: 8px;
  justify-content: center;
  font-size: 12px;
}

body[data-page="login"] .feature-strip svg {
  width: 26px;
  height: 26px;
}

.create-shell {
  width: min(1640px, calc(100% - 56px));
  grid-template-columns: minmax(430px, 520px) minmax(760px, 1040px);
  align-items: center;
  justify-content: center;
  gap: clamp(42px, 5vw, 86px);
}

.brand-panel {
  min-width: 0;
}

.brand-mark {
  display: inline-block;
  color: #05070b;
  font-size: clamp(28px, 2.7vw, 46px);
  font-weight: 800;
  line-height: 1;
  margin-bottom: clamp(14px, 2vh, 28px);
}

.brand-mark span,
.brand-panel h1 span {
  color: var(--blue);
}

.brand-panel h1 {
  margin: 0;
  color: #05070b;
  font-size: clamp(38px, 4.6vw, 64px);
  font-weight: 900;
  line-height: 1.04;
  letter-spacing: 0;
}

.brand-panel p {
  width: min(640px, 100%);
  margin: clamp(14px, 2vh, 24px) 0 clamp(16px, 2.3vh, 28px);
  font-size: clamp(15px, 1.15vw, 19px);
  line-height: 1.22;
}

.asset-stage {
  position: relative;
  width: min(560px, 100%);
  aspect-ratio: 1.74 / 1;
  margin-left: -2.5%;
  border-radius: 20px;
  background: #fff;
  box-shadow: var(--shadow);
  overflow: visible;
}

.asset {
  position: absolute;
  display: block;
  user-select: none;
  pointer-events: none;
}

.pc-case {
  left: 4%;
  bottom: 12%;
  width: 43%;
  z-index: 2;
}

.fan {
  left: 7%;
  bottom: 6%;
  width: 13%;
  z-index: 4;
}

.gpu {
  left: 23%;
  bottom: 4%;
  width: 21%;
  z-index: 4;
}

.vr {
  left: 44%;
  bottom: 11%;
  width: 30%;
  z-index: 3;
}

.word {
  right: 16%;
  top: 14%;
  width: 17%;
  z-index: 2;
}

.excel {
  right: 3%;
  top: 31%;
  width: 18%;
  z-index: 2;
}

.ppt {
  right: 8%;
  bottom: 7%;
  width: 15%;
  z-index: 4;
}

.feature-strip {
  width: min(560px, 100%);
  min-height: 74px;
  margin-top: clamp(14px, 2vh, 24px);
  padding: 12px 18px;
  border-radius: 18px;
  background: #fff;
  box-shadow: var(--shadow);
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  align-items: center;
  gap: 12px;
}

.feature-strip div {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-width: 0;
  color: #101827;
  font-size: clamp(12px, 0.9vw, 15px);
  font-weight: 500;
  line-height: 1.08;
}

.feature-strip svg {
  flex: 0 0 auto;
  width: clamp(26px, 2vw, 34px);
  height: clamp(26px, 2vw, 34px);
  color: var(--blue);
  stroke-width: 2.2;
}

.form-card {
  width: 100%;
  background: var(--panel);
  border-radius: 22px;
  box-shadow: var(--shadow);
  padding: clamp(24px, 2.6vw, 42px);
}

.login-card {
  min-height: min(66vh, 650px);
  display: flex;
  flex-direction: column;
  justify-content: center;
}

body[data-page="login"] .login-card {
  min-height: 0;
  height: auto;
  padding: 52px 48px;
  border-radius: 22px;
}

body[data-page="login"] .login-card .form-heading {
  margin-bottom: 28px;
}

body[data-page="login"] .login-card .form-heading h2 {
  font-size: 38px;
}

body[data-page="login"] .login-card .form-stack {
  gap: 20px;
}

body[data-page="login"] .login-card .input-wrap {
  height: 58px;
}

body[data-page="login"] .login-card .form-row {
  margin: 0 0 22px;
}

.create-card {
  padding: clamp(20px, 2.2vh, 30px) clamp(28px, 2.6vw, 40px);
  max-width: 1040px;
  justify-self: center;
}

.form-heading {
  text-align: center;
  margin-bottom: clamp(14px, 1.8vh, 24px);
}

.form-heading h2 {
  margin: 0;
  font-size: clamp(26px, 2.2vw, 36px);
  line-height: 1.1;
}

.form-heading p {
  margin: 8px 0 0;
  color: #344054;
  font-size: clamp(14px, 1vw, 17px);
}

.form-stack {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.form-stack.compact {
  gap: 10px;
}

.field-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 9px;
  color: #121a2a;
  font-size: clamp(15px, 1.1vw, 19px);
  font-weight: 500;
}

.compact .field {
  gap: 6px;
  font-size: 13px;
}

.input-wrap {
  height: 58px;
  border: 2px solid var(--line);
  border-radius: 12px;
  background: #fff;
  display: grid;
  grid-template-columns: 26px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  padding: 0 16px;
  color: #111827;
}

.compact .input-wrap {
  height: 44px;
  grid-template-columns: 24px minmax(0, 1fr) auto;
  gap: 8px;
  padding: 0 13px;
}

.input-wrap:focus-within {
  border-color: var(--blue);
  box-shadow: 0 0 0 4px rgba(31, 123, 242, 0.12);
}

.input-wrap svg {
  width: 22px;
  height: 22px;
  color: #111;
}

.compact .input-wrap svg {
  width: 17px;
  height: 17px;
}

.input-wrap input,
.input-wrap select {
  width: 100%;
  min-width: 0;
  border: 0;
  outline: 0;
  color: #111827;
  background: transparent;
  font-size: clamp(14px, 1vw, 17px);
}

.compact .input-wrap input,
.compact .input-wrap select {
  font-size: 13px;
}

.input-wrap input::placeholder,
.input-wrap select:invalid {
  color: #768195;
}

.input-wrap input[readonly],
.input-wrap select:disabled {
  color: #566176;
  cursor: not-allowed;
}

.input-wrap:has(input[readonly]),
.input-wrap:has(select:disabled) {
  background: #f8fbff;
}

.select-wrap {
  grid-template-columns: 24px minmax(0, 1fr);
}

.select-wrap select {
  appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, #7d8797 50%), linear-gradient(135deg, #7d8797 50%, transparent 50%);
  background-position: calc(100% - 14px) 50%, calc(100% - 8px) 50%;
  background-size: 7px 7px, 7px 7px;
  background-repeat: no-repeat;
  padding-right: 34px;
}

.icon-button {
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: #9aa4b5;
  display: inline-grid;
  place-items: center;
  cursor: pointer;
}

.icon-button:hover {
  background: #eef4ff;
  color: var(--blue);
}

.form-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
}

.check-label {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: #172033;
  font-size: clamp(14px, 1vw, 17px);
  font-weight: 500;
}

.terms {
  align-items: flex-start;
  font-size: 15px;
}

.check-label input {
  width: 28px;
  height: 28px;
  margin: 0;
  accent-color: var(--blue);
}

.terms input {
  width: 22px;
  height: 22px;
  margin-top: 2px;
}

.create-card .terms {
  font-size: 13px;
  gap: 9px;
  margin-top: 2px;
}

.create-card .terms input {
  width: 16px;
  height: 16px;
}

.create-card .field-hint {
  font-size: 11px;
  line-height: 1.25;
}

.text-link {
  color: var(--blue);
  font-weight: 600;
}

.primary-button,
.outline-button,
.ghost-button,
.small-button,
.approve-button,
.reject-button {
  min-height: 50px;
  border-radius: 10px;
  border: 2px solid transparent;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  font-weight: 700;
  cursor: pointer;
}

.primary-button {
  width: 100%;
  color: #fff;
  background: var(--blue);
  font-size: clamp(17px, 1.25vw, 21px);
}

.primary-button:hover {
  background: var(--blue-dark);
}

.outline-button {
  width: 100%;
  color: var(--blue);
  border-color: var(--blue);
  background: #fff;
  font-size: clamp(16px, 1.15vw, 20px);
}

.create-card .primary-button,
.create-card .outline-button {
  min-height: 44px;
  font-size: 14px;
}

.outline-button:hover,
.small-button:hover,
.ghost-button:hover {
  background: #eef5ff;
}

.outline-button.centered {
  justify-content: center;
}

.status-message {
  min-height: 24px;
  margin: 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.4;
}

.status-message.error {
  color: var(--danger);
}

.status-message.success {
  color: var(--success);
}

.dashboard-shell {
  width: min(1220px, calc(100% - 32px));
  margin: 0 auto;
  padding: 28px 0 52px;
}

.dashboard-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 34px;
}

.dashboard-topbar .brand-mark {
  margin: 0;
  font-size: clamp(28px, 3vw, 42px);
}

.ghost-button,
.small-button {
  min-height: 44px;
  padding: 0 18px;
  border-color: var(--line);
  background: #fff;
  color: var(--ink);
}

.ghost-button svg,
.small-button svg,
.approve-button svg,
.reject-button svg {
  width: 19px;
  height: 19px;
}

.dashboard-hero,
.student-home {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 24px;
  align-items: stretch;
  margin-bottom: 24px;
}

.dashboard-hero > div:first-child,
.student-welcome,
.profile-summary,
.dashboard-panel,
.metric-card {
  background: #fff;
  border: 1px solid #e7ebf2;
  border-radius: 18px;
  box-shadow: 0 12px 30px rgba(18, 31, 55, 0.08);
}

.dashboard-hero > div:first-child,
.student-welcome {
  padding: clamp(24px, 4vw, 42px);
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--blue);
  font-size: 14px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0;
}

.dashboard-hero h1,
.student-home h1 {
  margin: 0;
  font-size: clamp(32px, 5vw, 56px);
  line-height: 1.05;
}

.student-welcome p:last-child {
  margin: 14px 0 0;
  color: var(--muted);
  font-size: 18px;
}

.metric-card {
  min-width: 240px;
  padding: 28px;
  display: grid;
  place-items: center;
  text-align: center;
}

.metric-card span {
  color: var(--blue);
  font-size: 64px;
  font-weight: 900;
  line-height: 1;
}

.metric-card p {
  margin: 8px 0 0;
  color: var(--muted);
  font-weight: 600;
}

.dashboard-panel {
  padding: clamp(22px, 3vw, 34px);
}

.panel-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 16px;
}

.panel-heading h2,
.profile-summary h2 {
  margin: 0;
  font-size: clamp(22px, 3vw, 30px);
}

.student-list {
  display: grid;
  gap: 16px;
}

.student-card {
  border: 1px solid #e4e9f2;
  border-radius: 14px;
  padding: 20px;
  display: grid;
  gap: 18px;
}

.student-card-main {
  display: flex;
  gap: 16px;
  align-items: flex-start;
}

.student-avatar {
  width: 54px;
  height: 54px;
  border-radius: 14px;
  background: #eaf3ff;
  color: var(--blue);
  display: grid;
  place-items: center;
  font-weight: 800;
}

.student-card h3 {
  margin: 0;
  font-size: 22px;
}

.student-card p {
  margin: 2px 0 10px;
  color: var(--muted);
}

.student-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.student-tags span,
.status-pill {
  border-radius: 999px;
  padding: 7px 10px;
  background: #eef5ff;
  color: var(--blue-dark);
  font-size: 13px;
  font-weight: 700;
}

.student-details,
.profile-summary dl {
  margin: 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.profile-summary dl {
  grid-template-columns: 1fr;
}

.student-details div,
.profile-summary dl div {
  min-width: 0;
  padding: 14px;
  border-radius: 12px;
  background: #f7f9fd;
}

dt {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
}

dd {
  margin: 4px 0 0;
  overflow-wrap: anywhere;
  font-weight: 600;
}

.student-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.approve-button,
.reject-button {
  min-height: 46px;
  padding: 0 18px;
}

.approve-button {
  background: var(--success-soft);
  color: var(--success);
  border-color: #b9e9ce;
}

.reject-button {
  background: var(--danger-soft);
  color: var(--danger);
  border-color: #fac4cc;
}

.student-home {
  grid-template-columns: 1fr minmax(300px, 420px);
}

.profile-summary {
  padding: clamp(22px, 3vw, 34px);
}

.profile-summary h2 {
  margin-bottom: 18px;
}

@media (max-width: 1180px) {
  .auth-shell {
    grid-template-columns: 1fr;
    align-items: start;
    gap: 36px;
  }

  .brand-panel {
    display: grid;
    justify-items: center;
    text-align: center;
  }

  .brand-panel p {
    margin-bottom: 32px;
  }

  .asset-stage,
  .feature-strip {
    width: min(650px, 100%);
    margin-left: 0;
  }

  .form-card {
    width: min(640px, 100%);
    margin: 0 auto;
  }
}

@media (max-width: 760px) {
  .auth-shell {
    padding: 20px 14px 34px;
  }

  .brand-mark {
    margin-bottom: 20px;
  }

  .brand-panel h1 {
    font-size: clamp(36px, 11vw, 54px);
  }

  .brand-panel p {
    font-size: 16px;
    margin-top: 18px;
    margin-bottom: 22px;
  }

  .asset-stage {
    border-radius: 16px;
  }

  .feature-strip {
    min-height: auto;
    grid-template-columns: repeat(2, 1fr);
    padding: 16px;
    border-radius: 16px;
  }

  .feature-strip div {
    justify-content: flex-start;
  }

  .form-card {
    border-radius: 24px;
    padding: 26px 16px;
  }

  .login-card {
    min-height: auto;
  }

  .field-grid,
  .dashboard-hero,
  .student-home,
  .student-details {
    grid-template-columns: 1fr;
  }

  .input-wrap,
  .compact .input-wrap {
    height: 54px;
    padding: 0 14px;
  }

  .primary-button,
  .outline-button {
    min-height: 54px;
  }

  .dashboard-shell {
    width: min(100% - 24px, 1220px);
    padding-top: 18px;
  }

  .dashboard-topbar {
    align-items: flex-start;
  }

  .ghost-button span,
  .small-button span {
    display: none;
  }

  .metric-card {
    min-width: 0;
  }

  .student-card-main {
    flex-direction: column;
  }
}

.field-hint {
  color: #667085;
  font-size: 12px;
  line-height: 1.35;
}

@media (min-width: 1181px) {
  body[data-page="login"],
  body[data-page="register"] {
    overflow: hidden;
  }

  .auth-shell {
    height: 100vh;
    overflow: hidden;
  }

  .auth-shell .brand-panel {
    display: grid;
    align-content: center;
  }

  .create-shell .brand-panel h1 {
    font-size: clamp(34px, 3.5vw, 56px);
  }

  .create-shell .brand-panel p {
    font-size: clamp(14px, 1vw, 17px);
    margin-top: 18px;
    margin-bottom: 20px;
  }

  .create-shell .asset-stage {
    width: min(486px, 100%);
  }

  .create-shell .feature-strip {
    width: min(486px, 100%);
    min-height: 68px;
    padding: 10px 14px;
    margin-top: 18px;
  }

  .create-shell .feature-strip div {
    gap: 8px;
    font-size: 11px;
  }

  .create-shell .feature-strip svg {
    width: 22px;
    height: 22px;
  }

  .create-shell .brand-mark {
    font-size: clamp(26px, 2.2vw, 38px);
    margin-bottom: 18px;
  }

  .create-card .form-stack.compact {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 9px 16px;
  }

  .create-card .field-grid {
    display: contents;
  }

  .create-card .terms,
  .create-card .status-message,
  .create-card .primary-button,
  .create-card .outline-button {
    grid-column: 1 / -1;
  }

  .create-card .form-heading {
    margin-bottom: 18px;
  }

  .create-card .form-heading h2 {
    font-size: 36px;
  }

  .create-card .form-heading p {
    font-size: 16px;
  }
}

@media (min-width: 1181px) and (max-height: 820px) {
  .auth-shell {
    padding-top: 10px;
    padding-bottom: 10px;
  }

  .brand-panel h1 {
    font-size: clamp(34px, 4.1vw, 58px);
  }

  .asset-stage {
    width: min(510px, 100%);
  }

  .feature-strip {
    min-height: 62px;
  }

  .feature-strip div {
    font-size: 11px;
  }

  .feature-strip svg {
    width: 24px;
    height: 24px;
  }

  .login-card {
    min-height: 0;
  }

  body[data-page="login"] .auth-shell {
    width: min(1460px, calc(100% - 64px));
    gap: clamp(56px, 6vw, 96px);
  }

  body[data-page="login"] .brand-mark {
    margin-bottom: 18px;
  }

  body[data-page="login"] .brand-panel h1 {
    font-size: clamp(44px, 4vw, 60px);
  }

  body[data-page="login"] .brand-panel p {
    margin-top: 18px;
    margin-bottom: 18px;
  }

  body[data-page="login"] .asset-stage,
  body[data-page="login"] .feature-strip {
    width: min(590px, 100%);
  }

  body[data-page="login"] .feature-strip {
    min-height: 64px;
  }

  body[data-page="login"] .login-card {
    padding: 42px 44px;
  }

  body[data-page="login"] .login-card .form-heading {
    margin-bottom: 22px;
  }

  body[data-page="login"] .login-card .form-stack {
    gap: 16px;
  }

  body[data-page="login"] .login-card .form-row {
    margin-bottom: 14px;
  }

  .create-shell {
    gap: clamp(34px, 4vw, 68px);
  }

  .create-card {
    padding-top: 20px;
    padding-bottom: 20px;
  }

  .create-card .form-stack.compact {
    gap: 8px 14px;
  }

  .create-card .form-heading {
    margin-bottom: 14px;
  }

  .create-card .form-heading h2 {
    font-size: 32px;
  }

  .create-card .form-heading p {
    font-size: 14px;
  }

  .create-card .primary-button,
  .create-card .outline-button,
  .create-card .compact .input-wrap {
    min-height: 40px;
    height: 40px;
  }

  .compact .field {
    gap: 4px;
    font-size: 12px;
  }

  .create-card .terms {
    font-size: 12px;
  }
}

@media (min-width: 1181px) and (max-height: 680px) {
  .create-shell .brand-panel p,
  .create-shell .asset-stage,
  .create-shell .feature-strip {
    display: none;
  }

  .create-shell {
    grid-template-columns: minmax(230px, 0.42fr) minmax(760px, 1040px);
  }

  .create-card {
    padding-top: 16px;
    padding-bottom: 16px;
  }
}

.app-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: clamp(132px, 12.5vw, 190px) minmax(0, 1fr);
  background: #f2f5fb;
}

.app-sidebar {
  --sidebar-item-count: 7;
  position: sticky;
  top: 0;
  height: 100vh;
  min-height: 0;
  padding: clamp(14px, 2vh, 28px) clamp(10px, 1vw, 16px);
  background: #1f7bf2;
  display: grid;
  grid-template-rows: repeat(var(--sidebar-item-count), minmax(0, 1fr));
  align-content: stretch;
  gap: clamp(8px, 1.2vh, 14px);
  overflow: hidden;
}

body[data-page="teacher"] .app-sidebar {
  --sidebar-item-count: 8;
}

body[data-page="student"] .app-sidebar {
  --sidebar-item-count: 6;
}

.nav-item {
  width: 100%;
  min-width: 0;
  min-height: 0;
  height: 100%;
  border: 0;
  border-radius: 16px;
  background: transparent;
  color: #fff;
  display: grid;
  place-items: center;
  align-content: center;
  gap: clamp(4px, 0.8vh, 7px);
  cursor: pointer;
  font-weight: 600;
  font-size: clamp(12px, 1.05vw, 16px);
  line-height: 1.15;
  text-align: center;
}

.nav-item svg {
  width: clamp(24px, 2.1vw, 34px);
  height: clamp(24px, 2.1vw, 34px);
  stroke-width: 2.2;
}

.nav-item.active,
.nav-item:hover {
  background: #fff;
  color: #1f7bf2;
  box-shadow: 0 8px 18px rgba(16, 24, 40, 0.18);
}

.app-main {
  min-width: 0;
  padding-bottom: 32px;
}

.app-topbar {
  min-height: clamp(86px, 10vh, 124px);
  padding: clamp(14px, 1.8vh, 22px) clamp(24px, 3vw, 42px);
  background: #f8faff;
  border-bottom: 1px solid #d9dfeb;
  box-shadow: 0 2px 8px rgba(16, 24, 40, 0.08);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.compact-brand {
  margin: 0;
  font-size: clamp(32px, 3vw, 50px);
}

.topbar-profile {
  display: flex;
  align-items: center;
  gap: clamp(10px, 1.3vw, 18px);
  color: #111827;
}

.topbar-profile > svg {
  width: clamp(28px, 2.4vw, 38px);
  height: clamp(28px, 2.4vw, 38px);
  color: #111;
}

.topbar-profile strong {
  display: block;
  font-size: clamp(18px, 1.8vw, 30px);
  line-height: 1.05;
}

.topbar-profile span {
  color: #777d89;
  font-size: clamp(13px, 1.35vw, 22px);
  font-weight: 600;
}

.notification-center {
  position: relative;
  display: grid;
  place-items: center;
}

.notification-button {
  position: relative;
  width: 36px;
  height: 36px;
  border: 1px solid var(--border-color, #dfe7ee);
  border-radius: 10px;
  background: #fff;
  color: #4e5a67;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.16s ease;
}

.notification-button:hover,
.notification-button[aria-expanded="true"] {
  background: #eef4ff;
  border-color: #c4d7ec;
  color: #1f7bf2;
}

.notification-button :is(svg, i) {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  stroke-width: 2px;
  color: inherit;
  display: block;
}

.notification-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border: 2px solid #fff;
  border-radius: 999px;
  background: #ef4444;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  font-weight: 800;
  line-height: 14px;
  box-shadow: 0 2px 5px rgba(239, 68, 68, 0.45);
  box-sizing: border-box;
  z-index: 5;
  pointer-events: none;
}

.notification-badge[hidden] {
  display: none !important;
}

.notification-panel {
  position: absolute;
  top: calc(100% + 14px);
  right: 0;
  z-index: 35;
  width: min(390px, calc(100vw - 28px));
  max-height: min(560px, calc(100vh - 130px));
  overflow: hidden;
  border: 1px solid #dbe3f0;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 22px 55px rgba(15, 23, 42, 0.18);
}

.notification-panel-header {
  padding: 16px;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  border-bottom: 1px solid #edf1f7;
}

.notification-panel-header strong {
  display: block;
  font-size: 18px;
  line-height: 1.15;
}

.notification-panel-header span {
  display: block;
  margin-top: 3px;
  font-size: 12px;
  color: #6b7280;
}

.notification-list {
  max-height: 440px;
  overflow-y: auto;
  padding: 8px;
}

.notification-item {
  width: 100%;
  border: 0;
  border-radius: 14px;
  background: #fff;
  color: #111827;
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  gap: 12px;
  padding: 12px;
  text-align: left;
  cursor: pointer;
}

.notification-item:hover {
  background: #f6f9ff;
}

.notification-item.unread {
  background: #eef6ff;
}

.notification-item.unread:hover {
  background: #e5f1ff;
}

.notification-icon {
  width: 42px;
  height: 42px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  color: #1f7bf2;
  background: #eaf2ff;
}

.topbar-profile .notification-icon {
  color: #1f7bf2;
  font-size: 14px;
}

.notification-icon.green {
  color: #059669;
  background: #e9fdf3;
}

.topbar-profile .notification-icon.green {
  color: #059669;
}

.notification-icon.orange {
  color: #f97316;
  background: #fff4e6;
}

.topbar-profile .notification-icon.orange {
  color: #f97316;
}

.notification-icon.purple {
  color: #7c3aed;
  background: #f1e8ff;
}

.topbar-profile .notification-icon.purple {
  color: #7c3aed;
}

.notification-icon.red {
  color: #dc2626;
  background: #fee2e2;
}

.topbar-profile .notification-icon.red {
  color: #dc2626;
}

.notification-icon svg {
  width: 22px;
  height: 22px;
}

.notification-content {
  min-width: 0;
}

.notification-content strong {
  display: block;
  font-size: 14px;
  line-height: 1.2;
}

.notification-content span {
  display: block;
  margin-top: 4px;
  color: #4b5563;
  font-size: 12px;
  line-height: 1.35;
}

.notification-content time {
  display: block;
  margin-top: 6px;
  color: #7b8494;
  font-size: 11px;
  font-weight: 700;
}

.notification-unread-dot {
  width: 9px;
  height: 9px;
  margin-top: 8px;
  border-radius: 999px;
  background: #1f7bf2;
  display: block;
}

.notification-section-label {
  padding: 9px 12px 5px;
  color: #6b7280;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

.notification-item.reminder {
  background: #fffaf3;
}

.notification-item.reminder.overdue {
  background: #fff5f5;
}

.notification-item.reminder:hover {
  background: #fff0dc;
}

.notification-item.reminder.overdue:hover {
  background: #fee8e8;
}

.topbar-profile .notification-badge,
.topbar-profile .notification-unread-dot {
  color: #fff;
  font-size: 11px;
  font-weight: 800;
}

.notification-empty {
  min-height: 160px;
  display: grid;
  place-items: center;
  padding: 24px;
  color: #6b7280;
  text-align: center;
  font-weight: 700;
}

.profile-badge {
  width: clamp(60px, 6vw, 86px);
  height: clamp(60px, 6vw, 86px);
  border-radius: 999px;
  background: #fff;
  color: #1f7bf2;
  display: grid;
  place-items: center;
  box-shadow: 0 5px 12px rgba(16, 24, 40, 0.18);
  overflow: hidden;
}

.profile-badge svg {
  width: 62%;
  height: 62%;
}

.profile-badge img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.profile-badge span {
  color: #1f5fbf;
  font-size: 20px;
  font-weight: 900;
}

.icon-shell {
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 14px;
  background: #eef4ff;
  color: #1f7bf2;
  display: grid;
  place-items: center;
  cursor: pointer;
}

.dashboard-status {
  margin: 10px clamp(24px, 3vw, 42px) 0;
}

.teacher-section,
.student-section {
  display: none;
  padding: clamp(20px, 3vh, 34px) clamp(24px, 3vw, 42px) 18px;
}

.teacher-section.active,
.student-section.active {
  display: block;
}

.section-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: clamp(18px, 2.2vh, 24px);
}

.section-heading h1 {
  margin: 0;
  font-size: clamp(28px, 3vw, 42px);
  line-height: 1.05;
}

.section-heading p {
  margin: 8px 0 0;
  color: #6d7480;
  font-weight: 600;
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 28px;
  margin-bottom: 28px;
}

.stat-card,
.panel-card,
.welcome-block,
.achievement-strip,
.quick-access {
  background: #fff;
  border: 1px solid #e1e6ef;
  border-radius: 18px;
  box-shadow: 0 8px 16px rgba(16, 24, 40, 0.12);
}

.stat-card {
  min-height: 150px;
  padding: 24px;
  display: flex;
  align-items: center;
  gap: 22px;
}

.stat-card p,
.stat-card small {
  margin: 0;
  color: #757b86;
  font-weight: 700;
}

.stat-card strong {
  display: block;
  color: #05070b;
  font-size: 42px;
  line-height: 1.05;
}

.stat-icon {
  width: 76px;
  height: 76px;
  border-radius: 999px;
  display: grid;
  place-items: center;
}

.stat-icon svg {
  width: 38px;
  height: 38px;
}

.stat-icon.blue { background: #eaf2ff; color: #1f7bf2; }
.stat-icon.green { background: #eafaf0; color: #08a64b; }
.stat-icon.orange { background: #fff2df; color: #ff8b22; }
.stat-icon.purple { background: #f2eaff; color: #7a42f4; }

.settings-header {
  margin-bottom: 24px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
}

.settings-header h1 {
  margin: 0;
  font-size: clamp(30px, 3vw, 46px);
  line-height: 1.05;
}

.settings-header p {
  max-width: 760px;
  margin: 8px 0 0;
  color: #526079;
  font-weight: 700;
}

.settings-status-pill {
  flex: 0 0 auto;
  min-height: 44px;
  padding: 10px 14px;
  border-radius: 14px;
  background: #eef6ff;
  color: #1f7bf2;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 800;
}

.settings-status-pill svg {
  width: 20px;
  height: 20px;
}

.settings-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(360px, 0.85fr);
  gap: 22px;
  align-items: start;
}

.settings-card {
  min-width: 0;
  padding: 24px;
  border: 1px solid #e1e6ef;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 8px 16px rgba(16, 24, 40, 0.12);
  display: grid;
  gap: 16px;
}

.settings-profile-card,
.settings-security-card {
  grid-column: span 1;
}

.settings-card-heading {
  display: flex;
  align-items: center;
  gap: 14px;
}

.settings-card-heading h2 {
  margin: 0;
  font-size: 24px;
  line-height: 1.1;
}

.settings-card-heading p {
  margin: 4px 0 0;
  color: #717b8d;
  font-weight: 700;
  line-height: 1.35;
}

.settings-card-icon {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  display: grid;
  place-items: center;
}

.settings-card-icon svg {
  width: 28px;
  height: 28px;
}

.settings-card-icon.blue { background: #eaf2ff; color: #1f7bf2; }
.settings-card-icon.green { background: #e9fdf3; color: #059669; }
.settings-card-icon.orange { background: #fff4e6; color: #f97316; }
.settings-card-icon.purple { background: #f1e8ff; color: #7c3aed; }
.settings-card-icon.red { background: #fee2e2; color: #dc2626; }

.settings-card label {
  display: grid;
  gap: 8px;
  color: #182236;
  font-weight: 800;
}

.settings-card input,
.settings-card select {
  width: 100%;
  min-height: 48px;
  border: 1px solid #ccd6e5;
  border-radius: 12px;
  padding: 0 14px;
  background: #fff;
  color: #111827;
  font: inherit;
  font-weight: 700;
}

.settings-card input[readonly] {
  background: #f4f7fb;
  color: #687386;
}

.settings-readonly-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.settings-toggle {
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  padding: 14px;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  background: #f9fbff;
}

.settings-toggle input {
  width: 22px;
  height: 22px;
  min-height: 22px;
  accent-color: #1f7bf2;
}

.settings-toggle strong,
.settings-toggle small {
  display: block;
}

.settings-toggle small {
  margin-top: 3px;
  color: #6b7280;
  font-weight: 700;
  line-height: 1.35;
}

.settings-card .primary-button {
  justify-self: start;
  min-height: 48px;
  padding-inline: 18px;
}

.dashboard-grid {
  display: grid;
  gap: 24px;
}

.two-col {
  grid-template-columns: minmax(0, 1.35fr) minmax(320px, 0.65fr);
}

.three-col {
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr) minmax(320px, 1fr);
}

.students-layout {
  grid-template-columns: minmax(0, 1fr) 420px;
}

.panel-card {
  padding: 24px;
  min-width: 0;
}

.panel-card h2,
.quick-access h2 {
  margin: 0;
  font-size: 25px;
  line-height: 1.1;
}

.panel-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.compact-list {
  display: grid;
  gap: 12px;
}

.mini-row {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
  padding: 14px;
  border: 1px solid #e4e9f2;
  border-radius: 14px;
}

.mini-row strong,
.mini-row span,
.mini-row small {
  display: block;
}

.mini-row span,
.mini-row small,
.muted-text,
.empty-text {
  color: #747b87;
  font-weight: 600;
}

.mini-avatar {
  width: 46px;
  height: 46px;
  border-radius: 12px;
  background: #eaf2ff;
  color: #1f7bf2;
  display: grid;
  place-items: center;
  font-weight: 800;
}

.mini-avatar.line {
  background: #fff;
}

.row-actions,
.table-actions {
  display: inline-flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}

.approve-button.mini,
.reject-button.mini {
  min-height: 38px;
  width: 42px;
  padding: 0;
}

.quarter-spotlight {
  min-height: 150px;
  padding: 18px;
  border-radius: 16px;
  background: #eef5ff;
  display: grid;
  align-content: center;
  gap: 8px;
}

.capstone-evidence-panel {
  margin-top: 24px;
  padding: 24px;
  border: 1px solid #dfe6f2;
  border-radius: 20px;
  background: #fff;
  box-shadow: 0 8px 16px rgba(16, 24, 40, 0.12);
}

.capstone-evidence-header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(360px, auto);
  gap: 20px;
  align-items: end;
  margin-bottom: 20px;
}

.capstone-evidence-header h1,
.capstone-evidence-header p {
  margin: 0;
}

.capstone-evidence-header h1 {
  margin-top: 8px;
  font-size: clamp(28px, 2.7vw, 40px);
  line-height: 1.05;
}

.capstone-evidence-header p {
  max-width: 780px;
  margin-top: 8px;
  color: #596579;
  font-weight: 700;
  line-height: 1.4;
}

.evidence-eyebrow,
.evidence-quarter-pill,
.evidence-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border-radius: 999px;
  background: #eef6ff;
  color: #1f7bf2;
  font-weight: 800;
}

.evidence-eyebrow {
  padding: 8px 12px;
  font-size: 13px;
  text-transform: uppercase;
}

.evidence-eyebrow svg,
.evidence-quarter-pill svg {
  width: 16px;
  height: 16px;
}

.evidence-toolbar {
  display: grid;
  grid-template-columns: minmax(180px, 1fr) auto auto;
  gap: 12px;
  align-items: end;
}

.evidence-toolbar label {
  display: grid;
  gap: 7px;
  color: #667085;
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.evidence-toolbar select {
  min-height: 46px;
  border: 1px solid #cfd8e8;
  border-radius: 12px;
  background: #fff;
  color: #101828;
  font: inherit;
  font-weight: 800;
  padding: 0 12px;
}

.evidence-quarter-pill {
  min-height: 46px;
  padding: 0 14px;
  border-radius: 12px;
  align-self: end;
  white-space: nowrap;
}

.evidence-export-actions {
  display: inline-flex;
  gap: 8px;
  align-self: end;
}

.evidence-export-actions button {
  min-height: 46px;
  border: 0;
  border-radius: 12px;
  background: #1f7bf2;
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 14px;
  font: inherit;
  font-weight: 900;
  cursor: pointer;
}

.evidence-export-actions button:last-child {
  background: #eef4ff;
  color: #1f7bf2;
}

.evidence-export-actions svg {
  width: 18px;
  height: 18px;
}

.evidence-metric-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 16px;
}

.evidence-metric-grid article {
  min-width: 0;
  padding: 16px;
  border: 1px solid #e3eaf4;
  border-radius: 16px;
  background: #fbfdff;
  display: grid;
  gap: 8px;
}

.evidence-metric-grid span {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: grid;
  place-items: center;
}

.evidence-metric-grid svg {
  width: 22px;
  height: 22px;
}

.evidence-metric-grid p,
.evidence-metric-grid small {
  margin: 0;
  color: #667085;
  font-weight: 800;
}

.evidence-metric-grid p {
  color: #111827;
}

.evidence-metric-grid strong {
  color: #05070b;
  font-size: 30px;
  line-height: 1;
}

.evidence-metric-grid .blue { background: #e9f2ff; color: #1f7bf2; }
.evidence-metric-grid .green { background: #e9fbf1; color: #09a957; }
.evidence-metric-grid .purple { background: #f0e9ff; color: #6f3ff5; }
.evidence-metric-grid .orange { background: #fff3df; color: #f97316; }
.evidence-metric-grid .silver { background: #eef1f5; color: #8b95a4; }
.evidence-metric-grid .red { background: #ffecef; color: #d93245; }

.evidence-active-summary {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 1px;
  overflow: hidden;
  margin-bottom: 16px;
  border: 1px solid #e3eaf4;
  border-radius: 16px;
  background: #e3eaf4;
}

.evidence-active-summary span {
  min-width: 0;
  padding: 14px;
  background: #f8fbff;
  color: #667085;
  display: grid;
  gap: 3px;
  font-weight: 800;
}

.evidence-active-summary strong {
  color: #111827;
  font-size: 22px;
}

.evidence-dashboard-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(310px, 0.8fr);
  gap: 16px;
}

.evidence-card {
  min-width: 0;
  padding: 20px;
  border: 1px solid #e3eaf4;
  border-radius: 18px;
  background: #fff;
}

.evidence-card h2 {
  margin: 0;
  font-size: 23px;
  line-height: 1.1;
}

.evidence-chip {
  padding: 8px 11px;
  border-radius: 12px;
  font-size: 13px;
  white-space: nowrap;
}

.evidence-mastery-list,
.evidence-intervention-list,
.evidence-readiness-list {
  display: grid;
  gap: 12px;
}

.evidence-mastery-list article,
.evidence-intervention-list article,
.evidence-readiness-list article {
  min-width: 0;
  display: grid;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border: 1px solid #e5ebf5;
  border-radius: 14px;
  background: #fbfdff;
}

.evidence-mastery-list article {
  grid-template-columns: auto minmax(0, 1fr) auto;
}

.evidence-topic-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: #eaf2ff;
  color: #1f7bf2;
  display: grid;
  place-items: center;
}

.evidence-topic-icon svg {
  width: 24px;
  height: 24px;
}

.evidence-mastery-list strong,
.evidence-mastery-list small,
.evidence-intervention-list strong,
.evidence-intervention-list span,
.evidence-intervention-list small,
.evidence-readiness-list strong,
.evidence-readiness-list small {
  display: block;
}

.evidence-mastery-list small,
.evidence-intervention-list span,
.evidence-intervention-list small,
.evidence-readiness-list small {
  color: #667085;
  font-weight: 700;
}

.evidence-mastery-list b,
.evidence-intervention-list b {
  font-size: 20px;
}

.evidence-growth-card {
  display: grid;
  gap: 16px;
}

.evidence-growth-score {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  gap: 14px;
  align-items: center;
}

.evidence-growth-score div {
  padding: 14px;
  border-radius: 14px;
  background: #f8fbff;
  text-align: center;
}

.evidence-growth-score span {
  display: block;
  color: #667085;
  font-weight: 800;
}

.evidence-growth-score strong {
  display: block;
  margin-top: 4px;
  font-size: 30px;
  line-height: 1;
}

.evidence-growth-score svg {
  width: 24px;
  height: 24px;
  color: #1f7bf2;
}

.evidence-growth-bar {
  position: relative;
  height: 14px;
  border-radius: 999px;
  background: #e8eef8;
  overflow: hidden;
}

.evidence-growth-bar span {
  position: absolute;
  inset: 0 auto 0 0;
  border-radius: inherit;
  background: #9dbff7;
}

.evidence-growth-bar span.post {
  background: #1f7bf2;
  opacity: 0.88;
}

.evidence-growth-card p {
  margin: 0;
  font-weight: 900;
}

.evidence-empty {
  min-height: 170px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 8px;
  text-align: center;
  color: #667085;
}

.evidence-empty svg {
  width: 42px;
  height: 42px;
  color: #1f7bf2;
}

.evidence-empty strong {
  color: #111827;
  font-size: 18px;
}

.evidence-empty span,
.evidence-empty small {
  max-width: 340px;
  font-weight: 700;
}

.evidence-intervention-list article {
  grid-template-columns: auto minmax(0, 1fr) auto;
}

.evidence-readiness-list article {
  grid-template-columns: auto minmax(0, 1fr);
}

.evidence-readiness-list article > span {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: grid;
  place-items: center;
}

.evidence-readiness-list article.ready > span {
  background: #e8f8ef;
  color: #09a957;
}

.evidence-readiness-list article.pending > span {
  background: #fff4e6;
  color: #f97316;
}

.evidence-readiness-list svg {
  width: 22px;
  height: 22px;
}

.quarter-spotlight strong {
  font-size: 30px;
}

.toolbar-row {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-bottom: 26px;
  flex-wrap: wrap;
}

.toolbar-row select,
.form-panel input,
.form-panel select,
.form-panel textarea {
  min-height: 50px;
  border: 1px solid #d9dfeb;
  border-radius: 10px;
  background: #fff;
  padding: 0 14px;
  color: #1f2937;
  outline: 0;
}

.form-panel textarea {
  min-height: 96px;
  padding-top: 12px;
  resize: vertical;
}

.search-box {
  min-height: 64px;
  min-width: min(390px, 100%);
  border: 1px solid #d9dfeb;
  border-radius: 12px;
  background: #fff;
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  align-items: center;
  padding: 0 16px;
}

.search-box.small {
  min-height: 48px;
  min-width: 260px;
}

.search-box svg {
  width: 28px;
  height: 28px;
}

.search-box input {
  border: 0;
  outline: 0;
  font-size: 17px;
  background: transparent;
}

.table-card {
  overflow-x: auto;
  padding: 10px;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 760px;
}

.data-table th,
.data-table td {
  padding: 16px 18px;
  border-bottom: 1px solid #e6ebf3;
  text-align: left;
  vertical-align: middle;
}

.data-table th {
  color: #172033;
  font-size: 14px;
  font-weight: 800;
}

.data-table td small {
  display: block;
  color: #697386;
  font-weight: 600;
  margin-top: 4px;
}

.table-person {
  display: flex;
  align-items: center;
  gap: 12px;
}

.table-person span {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  border: 2px solid #1f7bf2;
  color: #1f7bf2;
  display: grid;
  place-items: center;
  font-size: 12px;
  font-weight: 800;
}

.mini-progress,
.wide-progress {
  height: 7px;
  border-radius: 999px;
  background: #edf1f7;
  overflow: hidden;
}

.mini-progress {
  width: 110px;
  margin-top: 8px;
}

.wide-progress {
  width: 100%;
  height: 10px;
}

.mini-progress span,
.wide-progress span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: #1f7bf2;
}

.status-pill.good,
.status-pill.published,
.status-pill.completed {
  background: #e4f8eb;
  color: #079443;
}

.status-pill.warning,
.status-pill.draft,
.status-pill.in_progress {
  background: #fff1dc;
  color: #f27a1a;
}

.status-pill.rejected,
.status-pill.archived,
.status-pill.inactive {
  background: #fff1f3;
  color: #d93245;
}

.status-pill.pending,
.status-pill.not_started {
  background: #eef4ff;
  color: #1f7bf2;
}

.good-text {
  color: #08a64b;
  font-weight: 800;
}

.warn-text,
.attention-row b {
  color: #ff5c1a;
  font-weight: 800;
}

.student-management-header {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 28px;
  margin-bottom: 28px;
}

.student-metric-card {
  min-height: 142px;
  padding: 24px 26px;
  border: 1px solid #e1e6ef;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 8px 16px rgba(16, 24, 40, 0.12);
  display: flex;
  align-items: center;
  gap: 22px;
}

.student-metric-card p,
.student-metric-card small {
  margin: 0;
  color: #777d89;
  font-weight: 800;
}

.student-metric-card strong {
  display: block;
  margin: 8px 0;
  color: #05070b;
  font-size: 34px;
  line-height: 1.05;
}

.student-metric-card small b {
  color: #1f7bf2;
}

.student-metric-card.top-performer strong {
  font-size: 22px;
}

.student-metric-card.top-performer small b {
  color: #ffb400;
}

.student-metric-icon {
  width: 82px;
  height: 82px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
}

.student-metric-icon svg {
  width: 46px;
  height: 46px;
  stroke-width: 2.1;
}

.student-metric-icon.blue { background: #1f7bf2; color: #fff; }
.student-metric-icon.green { background: #08b850; color: #fff; }
.student-metric-icon.orange { background: #fff0d9; color: #ff8b22; }
.student-metric-icon.gold { background: #fff5d7; color: #ffb400; }

.student-toolbar {
  display: grid;
  grid-template-columns: minmax(260px, 390px) auto auto auto minmax(140px, 190px);
  align-items: center;
  gap: 18px;
  margin-bottom: 28px;
}

.student-search {
  height: 72px;
  border: 1px solid #d9dfeb;
  border-radius: 12px;
  background: #fff;
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr);
  align-items: center;
  padding: 0 18px;
}

.student-search svg {
  width: 32px;
  height: 32px;
}

.student-search input {
  border: 0;
  outline: 0;
  background: transparent;
  color: #172033;
  font-size: 18px;
  font-weight: 600;
}

.student-toolbar select,
.export-button {
  height: 70px;
  border: 1px solid #d9dfeb;
  border-radius: 12px;
  background: #fff;
  color: #777d89;
  padding: 0 22px;
  font-weight: 800;
}

.segmented-control {
  display: inline-grid;
  grid-template-columns: repeat(2, minmax(150px, 1fr));
  gap: 16px;
}

.segment-button,
.export-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  cursor: pointer;
}

.segment-button {
  height: 70px;
  border: 2px solid #1f7bf2;
  border-radius: 12px;
  background: #fff;
  color: #1f7bf2;
  font-weight: 900;
  font-size: 18px;
}

.segment-button.active {
  background: #1f7bf2;
  color: #fff;
}

.export-button svg {
  width: 26px;
  height: 26px;
}

.student-management-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(340px, 430px);
  gap: 24px;
  align-items: start;
}

.student-table-card,
.student-side-card {
  border: 1px solid #e1e6ef;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 8px 16px rgba(16, 24, 40, 0.12);
}

.student-table-card {
  overflow-x: auto;
  padding: 10px;
}

.student-management-table {
  width: 100%;
  min-width: 1120px;
  border-collapse: collapse;
}

.student-management-table th,
.student-management-table td {
  padding: 15px 18px;
  border-bottom: 1px solid #e6ebf3;
  text-align: left;
  vertical-align: middle;
}

.student-management-table th {
  color: #0f172a;
  font-size: 14px;
  font-weight: 900;
  line-height: 1.05;
}

.student-name-cell {
  display: flex;
  align-items: center;
  gap: 13px;
  min-width: 190px;
}

.student-name-cell svg {
  width: 32px;
  height: 32px;
  color: #1f7bf2;
  flex: 0 0 auto;
}

.reward-icons,
.certificate-count,
.student-row-actions {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.reward-icon {
  width: 22px;
  height: 22px;
}

.reward-icon.gold { color: #ffb400; }
.reward-icon.blue { color: #1f7bf2; }
.reward-icon.green { color: #0ca95a; }
.reward-icon.purple { color: #6f3ff5; }

.reward-empty {
  color: #9aa4b5;
  font-weight: 800;
}

.certificate-count svg {
  width: 18px;
  height: 18px;
  color: #ffb400;
}

.student-row-actions .icon-button {
  width: 34px;
  height: 34px;
  border-radius: 9px;
}

.good-action { color: #0ca95a; }
.warning-action { color: #ff8b22; }
.danger-action { color: #d93245; }

.student-table-footer {
  min-width: 1120px;
  padding: 14px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  color: #1f2937;
  font-weight: 600;
}

.student-pagination {
  display: inline-flex;
  align-items: center;
  gap: 12px;
}

.student-pagination button {
  min-width: 38px;
  height: 38px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: #172033;
  font-weight: 800;
  cursor: pointer;
}

.student-pagination button.active {
  background: #1f7bf2;
  color: #fff;
}

.student-pagination button:disabled {
  color: #c0c7d2;
  cursor: default;
}

.student-right-rail {
  display: grid;
  gap: 24px;
}

.student-side-card {
  padding: 22px;
}

.student-side-card h2 {
  margin: 0 0 18px;
  font-size: 22px;
}

.distribution-layout {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  gap: 18px;
  align-items: center;
}

.distribution-donut {
  width: 150px;
  aspect-ratio: 1;
  border-radius: 999px;
  background: conic-gradient(#0ca95a 0 var(--excellent, 0deg), #1f7bf2 var(--excellent, 0deg) var(--good, 0deg), #ffb400 var(--good, 0deg) var(--fair, 0deg), #ff5c1a var(--fair, 0deg) 360deg);
  display: grid;
  place-items: center;
  position: relative;
}

.distribution-donut.empty {
  background: #edf1f7;
}

.distribution-donut::after {
  content: "";
  position: absolute;
  inset: 34px;
  border-radius: inherit;
  background: #fff;
}

.distribution-donut strong,
.distribution-donut span {
  position: relative;
  z-index: 1;
}

.distribution-donut strong {
  align-self: end;
  font-size: 26px;
  line-height: 1;
}

.distribution-donut span {
  align-self: start;
  font-size: 13px;
  font-weight: 700;
}

.distribution-legend {
  display: grid;
  gap: 12px;
}

.distribution-legend div {
  display: grid;
  grid-template-columns: 12px minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
}

.distribution-legend p,
.distribution-legend strong {
  margin: 0;
  font-size: 12px;
}

.legend-dot {
  width: 11px;
  height: 11px;
  border-radius: 999px;
}

.legend-dot.excellent { background: #0ca95a; }
.legend-dot.good { background: #1f7bf2; }
.legend-dot.fair { background: #ffb400; }
.legend-dot.needs { background: #ff5c1a; }

.attention-list {
  display: grid;
}

.attention-row {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 14px 0;
  border-bottom: 1px solid #e6ebf3;
}

.attention-row:last-child {
  border-bottom: 0;
}

.attention-row > svg {
  width: 34px;
  height: 34px;
  color: #1f7bf2;
}

.attention-row strong,
.attention-row span {
  display: block;
}

.attention-row span {
  color: #697386;
  font-size: 13px;
  font-weight: 700;
}

.student-drawer {
  position: fixed;
  inset: 0;
  z-index: 50;
  pointer-events: none;
  opacity: 0;
  overflow: hidden;
  transition: opacity 160ms ease;
}

.student-drawer.open {
  pointer-events: auto;
  opacity: 1;
}

.student-drawer-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.35);
}

.student-drawer-panel {
  position: absolute;
  top: 0;
  right: 0;
  width: min(460px, 100%);
  height: 100%;
  padding: 24px;
  background: #fff;
  box-shadow: -14px 0 30px rgba(16, 24, 40, 0.18);
  display: grid;
  align-content: start;
  gap: 14px;
  overflow-y: auto;
  transform: translateX(100%);
  transition: transform 180ms ease;
}

.student-drawer.open .student-drawer-panel {
  transform: translateX(0);
}

.student-drawer-panel header {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
}

.student-drawer-panel h2 {
  margin: 0;
  font-size: 26px;
}

.drawer-summary {
  padding: 16px;
  border-radius: 16px;
  background: #eef5ff;
  display: flex;
  align-items: center;
  gap: 14px;
}

.drawer-summary > span {
  width: 54px;
  height: 54px;
  border-radius: 999px;
  background: #1f7bf2;
  color: #fff;
  display: grid;
  place-items: center;
  font-weight: 900;
}

.drawer-summary strong,
.drawer-summary small {
  display: block;
}

.drawer-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}

.drawer-stats div {
  padding: 10px;
  border-radius: 12px;
  background: #f7f9fd;
  text-align: center;
}

.drawer-stats strong,
.drawer-stats span {
  display: block;
}

.drawer-stats span {
  color: #697386;
  font-size: 11px;
  font-weight: 800;
}

.student-drawer-panel label {
  display: grid;
  gap: 7px;
  font-size: 13px;
  font-weight: 800;
}

.student-drawer-panel input,
.student-drawer-panel select,
.student-drawer-panel textarea {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

.student-drawer-panel input,
.student-drawer-panel select {
  min-height: 46px;
  border: 1px solid #d9dfeb;
  border-radius: 10px;
  padding: 0 12px;
  outline: 0;
}

.drawer-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.drawer-actions .primary-button {
  grid-column: 1 / -1;
}

.empty-cell {
  color: #697386;
  text-align: center;
  font-weight: 700;
}

.quarter-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.quarter-card {
  padding: 18px;
  border: 1px solid #dde4ef;
  border-radius: 16px;
  display: grid;
  gap: 10px;
}

.quarter-card.active {
  border-color: #1f7bf2;
  background: #eef5ff;
}

.quarter-card.archived {
  background: #f7f8fb;
  border-style: dashed;
}

.quarter-card-header {
  min-width: 0;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.quarter-card-header > span {
  width: fit-content;
  min-width: 64px;
  min-height: 46px;
  padding: 8px 12px;
  border-radius: 12px;
  background: #1f7bf2;
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 900;
  line-height: 1.1;
  text-align: center;
}

.quarter-card strong {
  font-size: 22px;
}

.quarter-card p {
  margin: 0;
  color: #687180;
  font-weight: 600;
}

.quarter-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.quarter-actions .small-button {
  min-height: 36px;
}

.small-button.danger {
  border-color: #ffd2d8;
  background: #fff5f6;
  color: #d51f3f;
}

.form-action-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.form-action-row .primary-button {
  min-width: 160px;
}

.student-full-profile,
.student-profile-shell {
  display: grid;
  gap: 12px;
}

.student-profile-loading,
.student-profile-empty {
  min-height: 320px;
  display: grid;
  place-items: center;
  text-align: center;
  align-content: center;
  gap: 12px;
}

.student-profile-loading svg,
.student-profile-empty svg {
  width: 54px;
  height: 54px;
  color: #1f7bf2;
}

.student-profile-hero {
  padding: 18px;
  border: 1px solid #d7e1f0;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 14px 30px rgba(15, 23, 42, 0.08);
  display: grid;
  gap: 12px;
}

.student-profile-top-actions,
.student-profile-actions,
.student-profile-tags,
.student-profile-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.student-profile-top-actions {
  justify-content: space-between;
}

.profile-quarter-select {
  display: inline-flex;
  gap: 8px;
  align-items: center;
  color: #5d6676;
  font-weight: 800;
}

.profile-quarter-select select {
  min-height: 40px;
  border: 1px solid #d8e1ef;
  border-radius: 10px;
  padding: 0 12px;
  font: inherit;
  font-weight: 800;
}

.student-profile-identity {
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
}

.student-profile-avatar {
  width: 88px;
  height: 88px;
  border-radius: 50%;
  background: linear-gradient(135deg, #eaf2ff, #f1edff);
  border: 4px solid #fff;
  box-shadow: 0 10px 22px rgba(31, 123, 242, 0.2);
  display: grid;
  place-items: center;
  overflow: hidden;
}

.student-profile-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.student-profile-avatar span {
  color: #1f5fbf;
  font-size: 30px;
  font-weight: 900;
}

.student-profile-identity h1 {
  margin: 0;
  font-size: clamp(26px, 3.4vw, 38px);
  line-height: 1.05;
}

.student-profile-tags span:not(.status-pill) {
  min-height: 32px;
  padding: 6px 10px;
  border-radius: 999px;
  background: #f1f5fb;
  color: #344054;
  display: inline-flex;
  gap: 6px;
  align-items: center;
  font-weight: 800;
}

.student-profile-tags svg {
  width: 16px;
  height: 16px;
}

.student-profile-meta {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.student-profile-meta article {
  padding: 12px;
  border: 1px solid #e1e8f3;
  border-radius: 12px;
  background: #f8fbff;
  display: grid;
  gap: 4px;
}

.student-profile-meta span,
.student-profile-metrics span {
  color: #677386;
  font-size: 12px;
  font-weight: 800;
}

.student-profile-meta strong {
  color: #101828;
  font-size: 15px;
}

.student-profile-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.75fr) minmax(320px, 0.75fr);
  gap: 20px;
  align-items: start;
}

.student-profile-card-grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 16px;
  align-items: start;
}

.student-profile-card-grid > .panel-card {
  min-width: 0;
  height: auto;
}

.student-profile-card-grid > .profile-module-mastery {
  grid-column: span 5;
}

.student-profile-card-grid > .profile-prepost-card {
  grid-column: span 4;
}

.student-profile-card-grid > .profile-support-card {
  grid-column: span 3;
}

.student-profile-card-grid > .profile-info-card,
.student-profile-card-grid > .profile-achievements-card,
.student-profile-card-grid > .profile-activity-card {
  grid-column: span 4;
}

.student-profile-card-grid > .profile-table-card {
  grid-column: 1 / -1;
}

.student-profile-priority-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  align-items: start;
}

.student-profile-column-stack,
.student-profile-record-stack {
  display: grid;
  gap: 12px;
  min-width: 0;
}

.student-profile-shell > .panel-card,
.student-profile-column-stack > .panel-card,
.student-profile-record-stack > .panel-card {
  padding: 18px;
}

.student-profile-shell > .panel-card h2,
.student-profile-column-stack > .panel-card h2,
.student-profile-record-stack > .panel-card h2 {
  font-size: 21px;
}

.student-profile-main,
.student-profile-side {
  display: grid;
  gap: 18px;
}

.student-profile-metrics {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 12px;
}

.student-profile-metrics article {
  padding: 12px;
  border: 1px solid #dce5f2;
  border-radius: 14px;
  background: #fff;
  display: grid;
  gap: 6px;
}

.student-profile-metrics svg {
  width: 26px;
  height: 26px;
}

.student-profile-metrics strong {
  font-size: 22px;
}

.student-profile-metrics .blue { color: #1f7bf2; }
.student-profile-metrics .green { color: #12a05c; }
.student-profile-metrics .purple { color: #7245db; }
.student-profile-metrics .orange { color: #f27a1a; }

.student-weak-panel {
  border: 1px solid #dbe5f2;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 14px 30px rgba(15, 23, 42, 0.08);
  padding: 14px;
  scroll-margin-top: 96px;
}

.student-weak-header {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: flex-start;
  margin-bottom: 10px;
}

.student-weak-header h2,
.student-weak-header p {
  margin: 0;
}

.student-weak-header h2 {
  color: #071225;
  font-size: 1.24rem;
  font-weight: 900;
}

.student-weak-header p {
  margin-top: 5px;
  color: #536076;
  font-size: 13px;
  font-weight: 800;
}

.student-weak-header > span {
  border-radius: 999px;
  background: #e9f2ff;
  color: #1f7bf2;
  padding: 7px 10px;
  font-size: 11px;
  font-weight: 900;
  white-space: nowrap;
}

.student-weak-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  align-items: start;
}

.student-weak-column {
  display: grid;
  gap: 12px;
  min-width: 0;
}

.student-weak-card {
  box-shadow: none;
}

.trend-card {
  grid-column: span 1;
}

.profile-intervention-card { grid-column: auto; }

.weak-link-button {
  width: 100%;
  min-height: 38px;
  margin-top: 10px;
  border: 1px solid #bdd4ff;
  border-radius: 10px;
  background: #f8fbff;
  color: #0d63d8;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  font: inherit;
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
}

.weak-link-button svg {
  width: 15px;
  height: 15px;
}

.weak-link-button:hover {
  border-color: #1f7bf2;
  background: #eef4ff;
}

.root-cause-note {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin: 12px 0 0;
  border: 1px solid #fecaca;
  border-radius: 12px;
  background: #fff1f2;
  color: #991b1b;
  padding: 10px;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.35;
}

.root-cause-note svg {
  width: 16px;
  height: 16px;
  flex: 0 0 auto;
}

.profile-trend-empty {
  min-height: 104px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 8px;
  border: 1px dashed #d8e1ee;
  border-radius: 12px;
  color: #667085;
  font-size: 12px;
  font-weight: 800;
  text-align: center;
}

.profile-trend-empty svg {
  width: 34px;
  height: 34px;
  color: #1f7bf2;
}

.profile-trend-chart {
  position: relative;
  min-height: 184px;
}

.profile-trend-chart svg {
  display: block;
  width: 100%;
  height: auto;
}

.profile-trend-grid line {
  stroke: #e3eaf4;
  stroke-width: 1;
}

.profile-trend-grid text,
.profile-trend-label,
.profile-trend-value {
  fill: #667085;
  font-size: 11px;
  font-weight: 800;
  text-anchor: middle;
}

.profile-trend-grid text {
  text-anchor: start;
}

.profile-trend-line {
  fill: none;
  stroke: #1f7bf2;
  stroke-width: 4;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.profile-trend-point {
  fill: #fff;
  stroke: #1f7bf2;
  stroke-width: 4;
}

.profile-target-line {
  stroke: #f97316;
  stroke-width: 2;
  stroke-dasharray: 7 6;
}

.trend-summary-pill,
.trend-target-box {
  position: absolute;
  right: 0;
  border: 1px solid #dbe6f4;
  border-radius: 12px;
  background: #fff;
  padding: 10px;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.08);
}

.trend-summary-pill {
  top: 12px;
  display: grid;
  grid-template-columns: 20px minmax(0, 1fr);
  gap: 2px 8px;
  min-width: 150px;
}

.trend-summary-pill svg {
  grid-row: span 2;
  width: 20px;
  height: 20px;
  color: #f59e0b;
}

.trend-summary-pill.up svg { color: #10b981; }
.trend-summary-pill.down svg { color: #ef4444; }

.trend-summary-pill strong,
.trend-target-box strong {
  color: #101828;
  font-size: 13px;
  font-weight: 900;
}

.trend-summary-pill span,
.trend-target-box span,
.trend-target-box small,
.trend-latest {
  color: #667085;
  font-size: 11px;
  font-weight: 800;
}

.trend-target-box {
  bottom: 8px;
  min-width: 124px;
}

.trend-target-box span,
.trend-target-box strong,
.trend-target-box small {
  display: block;
}

.trend-target-box strong {
  margin: 2px 0;
  font-size: 20px;
}

.trend-latest {
  margin: 6px 0 0;
}

.profile-intervention-list article {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  border: 1px solid #e3ebf5;
  border-radius: 12px;
  background: #fbfdff;
  padding: 8px;
}

.profile-intervention-list b {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #1f7bf2;
  color: #fff;
  display: grid;
  place-items: center;
  font-size: 12px;
}

.profile-intervention-list article.orange b { background: #f97316; }
.profile-intervention-list article.red b { background: #ef4444; }
.profile-intervention-list article.green b { background: #10b981; }
.profile-intervention-list article.purple b { background: #7c3aed; }

.profile-intervention-list button {
  min-height: 32px;
  border: 1px solid #bdd4ff;
  border-radius: 9px;
  background: #fff;
  color: #0d63d8;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 0 10px;
  font: inherit;
  font-size: 11px;
  font-weight: 900;
  cursor: pointer;
}

.profile-intervention-list button:hover {
  background: #eef4ff;
  border-color: #1f7bf2;
}

.profile-intervention-list button svg {
  width: 14px;
  height: 14px;
}

.profile-support-diagnosis {
  margin: 8px 0 0;
  color: #344054;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.35;
}

.profile-support-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
}

.profile-card-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 10px;
}

.profile-card-heading h2 {
  margin: 0;
}

.profile-card-heading span {
  color: #667085;
  font-size: 12px;
  font-weight: 900;
}

.profile-module-list,
.profile-achievements-card ul,
.profile-activity-card,
.profile-support-card dl,
.profile-info-card dl {
  display: grid;
  gap: 8px;
}

.profile-info-card dl {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px 16px;
}

.profile-table-card {
  scroll-margin-top: 96px;
}

.profile-module-list article {
  padding: 10px 12px;
  border: 1px solid #e0e8f4;
  border-radius: 12px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 6px 10px;
  align-items: center;
}

.profile-module-list .wide-progress,
.profile-module-list small {
  grid-column: 1 / -1;
}

.profile-table-wrap {
  overflow-x: auto;
}

.profile-table-wrap table {
  min-width: 900px;
  width: 100%;
  border-collapse: collapse;
}

.profile-table-wrap th,
.profile-table-wrap td {
  padding: 10px 12px;
  border-bottom: 1px solid #e5ecf5;
  text-align: left;
  font-size: 13px;
}

.profile-table-wrap th {
  color: #46556b;
  font-weight: 900;
}

.profile-info-card dl div,
.profile-support-card dl div {
  padding: 7px 0;
  border-bottom: 1px solid #edf2f8;
}

.profile-info-card dt,
.profile-support-card dt {
  color: #667085;
  font-size: 12px;
  font-weight: 800;
}

.profile-info-card dd,
.profile-support-card dd {
  margin: 3px 0 0;
  color: #101828;
  font-weight: 800;
}

.prepost-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.prepost-grid article {
  padding: 12px;
  border-radius: 12px;
  background: #f8fbff;
  border: 1px solid #dfe8f5;
  display: grid;
  gap: 6px;
}

.prepost-grid strong {
  font-size: 24px;
}

.profile-achievements-card h3 {
  margin: 14px 0 0;
  font-size: 14px;
}

.profile-achievements-card ul {
  margin: 6px 0 0;
  padding: 0;
  list-style: none;
}

.profile-achievements-card li,
.profile-activity-card article {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
}

.profile-achievements-card li span {
  display: grid;
  gap: 2px;
}

.profile-activity-card article > div {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.profile-activity-card article strong,
.profile-activity-card article span {
  display: block;
}

.profile-activity-card article span {
  color: #344054;
  font-weight: 600;
  line-height: 1.35;
}

.profile-activity-card article time {
  justify-self: end;
  text-align: right;
  white-space: nowrap;
}

.profile-achievements-card li em {
  color: #667085;
  font-size: 11px;
  font-style: normal;
  font-weight: 800;
}

.profile-achievements-card li svg,
.profile-activity-card article > svg {
  width: 24px;
  height: 24px;
  color: #1f7bf2;
}

.profile-achievements-card li svg.green { color: #12a05c; }
.profile-achievements-card li svg.gold { color: #f4a100; }
.profile-achievements-card li svg.purple { color: #7245db; }

.profile-activity-card time,
.profile-achievements-card small {
  color: #667085;
  font-size: 12px;
  font-weight: 800;
}

.profile-pagination-row {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid #edf2f8;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.profile-pagination-row > span {
  color: #667085;
  font-size: 12px;
  font-weight: 900;
}

.profile-pagination {
  gap: 6px;
}

.profile-pagination button {
  min-width: 32px;
  height: 32px;
  border-radius: 8px;
  font-size: 12px;
}

@media (max-width: 1500px) {
  .student-profile-metrics {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 1120px) {
  .student-profile-grid,
  .student-profile-card-grid,
  .student-profile-priority-grid,
  .student-profile-meta,
  .student-weak-grid {
    grid-template-columns: 1fr;
  }

  .student-profile-card-grid > .panel-card {
    grid-column: 1 / -1;
  }

  .student-profile-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .profile-info-card dl {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .profile-intervention-card,
  .trend-card {
    grid-column: auto;
  }

  .report-support-list > button {
    grid-template-columns: 42px minmax(0, 1fr);
  }

  .report-support-reason,
  .report-support-score {
    grid-column: 2;
    justify-self: start;
  }
}

@media (max-width: 640px) {
  .student-profile-identity {
    grid-template-columns: 1fr;
  }

  .student-profile-avatar {
    width: 88px;
    height: 88px;
  }

  .prepost-grid {
    grid-template-columns: 1fr;
  }

  .student-profile-metrics,
  .student-profile-priority-grid,
  .profile-info-card dl {
    grid-template-columns: 1fr;
  }

  .profile-activity-card article {
    grid-template-columns: 28px minmax(0, 1fr);
  }

  .profile-activity-card article time {
    grid-column: 2;
    justify-self: start;
    text-align: left;
  }

  body[data-page="student"] .student-profile-editor-grid,
  body[data-page="student"] .profile-details dl {
    grid-template-columns: 1fr;
  }

  body[data-page="student"] .student-profile-photo-card,
  body[data-page="student"] .student-profile-form {
    padding: 18px;
  }

  body[data-page="student"] .student-profile-actions button {
    flex-basis: 100%;
  }
}

.form-panel {
  display: grid;
  gap: 14px;
}

.form-panel label {
  display: grid;
  gap: 7px;
  color: #172033;
  font-size: 14px;
  font-weight: 800;
}

.simple-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.check-label.slim {
  display: inline-flex;
  grid-template-columns: none;
  align-items: center;
}

.content-forms {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
  margin-bottom: 24px;
}

.compact-action {
  min-height: 44px;
  font-size: 15px;
}

.compact-toolbar {
  margin: 0;
}

.empty-panel {
  min-height: 420px;
  display: grid;
  place-items: center;
  align-content: center;
  text-align: center;
}

.empty-panel svg {
  width: 54px;
  height: 54px;
  color: #1f7bf2;
}

.student-hero-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(420px, 0.72fr);
  gap: 28px;
  margin-bottom: 26px;
}

.welcome-block {
  min-height: 220px;
  padding: 46px;
  display: grid;
  align-content: center;
}

.welcome-block h1 {
  margin: 0;
  font-size: clamp(34px, 4vw, 58px);
  line-height: 1.02;
}

.welcome-block p {
  margin: 16px 0 0;
  color: #757b86;
  font-size: 20px;
  font-weight: 700;
}

.achievement-strip {
  padding: 28px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  align-items: center;
  text-align: center;
  gap: 16px;
}

.achievement-strip div {
  display: grid;
  gap: 6px;
  place-items: center;
}

.achievement-strip svg {
  width: 60px;
  height: 60px;
  color: #1f7bf2;
}

.achievement-strip div:nth-child(2) svg { color: #a0a7b3; }
.achievement-strip div:nth-child(3) svg { color: #ffb400; }

.achievement-strip strong {
  font-size: 22px;
}

.achievement-strip span {
  color: #757b86;
  font-weight: 800;
}

.quick-access {
  padding: 24px;
  margin-bottom: 28px;
}

.quick-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 22px;
  margin-top: 16px;
}

.quick-card {
  min-height: 178px;
  border: 1px solid #dbe3f1;
  border-radius: 18px;
  padding: 20px;
  display: grid;
  align-content: end;
  position: relative;
  overflow: hidden;
}

.quick-card > svg {
  position: absolute;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  width: 62px;
  height: 62px;
  color: #1f7bf2;
}

.quick-card strong {
  font-size: 19px;
  line-height: 1.1;
}

.quick-card span {
  color: #6d7480;
  font-weight: 700;
}

.quick-card button {
  position: absolute;
  right: 18px;
  bottom: 18px;
  border: 0;
  background: transparent;
  color: #1f7bf2;
  cursor: pointer;
}

.quick-card button svg {
  width: 38px;
  height: 38px;
}

.blue-soft { background: #eaf1ff; }
.green-soft { background: #ebfaef; }
.purple-soft { background: #f1eaff; }
.gold-soft { background: #fff5df; }

.soft-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 14px;
  border-radius: 999px;
  color: #1f7bf2;
  background: #eef5ff;
  font-weight: 800;
}

.soft-pill svg {
  width: 18px;
  height: 18px;
}

.mission-card h3 {
  margin: 12px 0 4px;
  font-size: 22px;
}

.mission-card p {
  color: #6d7480;
  font-weight: 700;
}

.mission-visual {
  width: 110px;
  height: 110px;
  border-radius: 24px;
  background: #eaf2ff;
  color: #1f7bf2;
  display: grid;
  place-items: center;
}

.mission-visual svg {
  width: 70px;
  height: 70px;
}

.link-button {
  border: 0;
  background: transparent;
  color: #1f7bf2;
  font-weight: 800;
  cursor: pointer;
}

.link-label {
  color: #1f7bf2;
  font-weight: 800;
}

.activity-list {
  display: grid;
}

.activity-row {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 14px;
  padding: 18px 0;
  border-bottom: 1px solid #e6ebf3;
}

.activity-row svg {
  color: #08a64b;
  width: 34px;
  height: 34px;
}

.activity-row span {
  display: block;
  color: #777d89;
  font-weight: 700;
  margin-top: 4px;
}

.gauge {
  width: 220px;
  height: 118px;
  margin: 16px auto 24px;
  border-radius: 220px 220px 0 0;
  border: 28px solid #eaf1ff;
  border-bottom: 0;
  display: grid;
  place-items: end center;
  padding-bottom: 8px;
}

.gauge strong {
  font-size: 42px;
  line-height: 1;
}

.gauge span {
  display: block;
  color: #777d89;
  font-size: 14px;
  font-weight: 800;
}

.progress-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 6px 14px rgba(16, 24, 40, 0.12);
}

.progress-stats div {
  padding: 14px 8px;
  display: grid;
  place-items: center;
  gap: 4px;
  border-right: 1px solid #e0e5ee;
}

.progress-stats div:last-child {
  border-right: 0;
}

.progress-stats svg {
  color: #1f7bf2;
  width: 34px;
  height: 34px;
}

.progress-stats strong {
  font-size: 18px;
}

.progress-stats span {
  color: #697386;
  font-size: 12px;
  font-weight: 800;
}

.lesson-card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
}

.lesson-card {
  min-height: 260px;
  background: #fff;
  border: 1px solid #e1e6ef;
  border-radius: 18px;
  box-shadow: 0 8px 16px rgba(16, 24, 40, 0.12);
  padding: 24px;
  display: grid;
  gap: 12px;
  align-content: start;
}

.lesson-card > svg {
  width: 58px;
  height: 58px;
  color: #1f7bf2;
}

.lesson-card strong {
  font-size: 22px;
}

.lesson-card span,
.lesson-card p,
.lesson-card small {
  color: #697386;
  font-weight: 700;
}

.profile-details dl {
  margin: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.profile-details dl div {
  padding: 16px;
  border-radius: 12px;
  background: #f7f9fd;
}

body[data-page="student"] .student-profile-editor-grid {
  display: grid;
  grid-template-columns: minmax(280px, 0.75fr) minmax(0, 1.25fr);
  gap: 18px;
  align-items: start;
}

body[data-page="student"] .student-profile-photo-card,
body[data-page="student"] .student-profile-form {
  display: grid;
  gap: 14px;
  align-content: start;
}

body[data-page="student"] .student-profile-photo-card h2,
body[data-page="student"] .student-profile-form h2 {
  margin: 0;
}

body[data-page="student"] .student-profile-editor-avatar {
  width: clamp(112px, 18vw, 150px);
  height: clamp(112px, 18vw, 150px);
  border-radius: 50%;
  margin: 0 auto;
  background: linear-gradient(135deg, #eaf2ff, #f2efff);
  border: 5px solid #fff;
  box-shadow: 0 16px 28px rgba(31, 123, 242, 0.18);
  display: grid;
  place-items: center;
  overflow: hidden;
}

body[data-page="student"] .student-profile-editor-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

body[data-page="student"] .student-profile-editor-avatar span {
  color: #1f5fbf;
  font-size: 44px;
  font-weight: 900;
}

body[data-page="student"] .student-avatar-upload {
  position: relative;
  min-height: 112px;
  border: 2px dashed #a9c7f7;
  border-radius: 14px;
  background: #f7fbff;
  color: #1f5fbf;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 6px;
  text-align: center;
  cursor: pointer;
}

body[data-page="student"] .student-profile-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

body[data-page="student"] .student-profile-actions button {
  flex: 1 1 180px;
  min-width: 0;
}

body[data-page="student"] .student-avatar-upload input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

body[data-page="student"] .student-avatar-upload svg {
  width: 32px;
  height: 32px;
}

body[data-page="student"] .student-avatar-upload span,
body[data-page="student"] .student-profile-form label {
  font-weight: 900;
}

body[data-page="student"] .student-avatar-upload small {
  color: #6b7280;
  font-weight: 700;
}

body[data-page="student"] .student-profile-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

body[data-page="student"] .student-profile-form label {
  display: grid;
  gap: 7px;
  color: #172033;
  font-size: 14px;
}

body[data-page="student"] .student-profile-form input {
  min-height: 44px;
  border: 1px solid #d9dfeb;
  border-radius: 10px;
  padding: 0 12px;
  font: inherit;
}

.progress-heading {
  align-items: center;
}

.progress-range-pill {
  min-height: 52px;
  padding: 0 18px;
  border: 1px solid #cfd7e5;
  border-radius: 14px;
  background: #fff;
  color: #6c7481;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.progress-range-pill svg {
  width: 22px;
  height: 22px;
}

.student-progress-dashboard {
  min-width: 0;
}

.student-progress-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(360px, 0.92fr);
  gap: 18px;
  align-items: stretch;
}

.student-progress-card {
  min-height: 0;
}

.student-progress-overall,
.student-weekly-card,
.student-goals-card {
  grid-column: 1;
}

.student-topic-mastery,
.student-recent-scores,
.student-hours-card,
.student-recommend-card {
  grid-column: 2;
}

.student-recommend-card {
  grid-column: 1 / -1;
}

.student-completion-progress-card {
  grid-column: 1 / -1;
}

.student-completion-progress-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 12px;
}

.student-completion-progress-list article {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px 14px;
  align-items: center;
  padding: 14px;
  border: 1px solid #d8e4f5;
  border-radius: 8px;
  background: #f8fbff;
}

.student-completion-progress-list strong,
.student-completion-progress-list span {
  display: block;
}

.student-completion-progress-list span {
  margin-top: 4px;
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
}

.student-completion-progress-list b {
  color: #0f172a;
  font-size: 18px;
}

.student-completion-progress-list .wide-progress {
  grid-column: 1 / -1;
}

.student-overall-layout {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  align-items: center;
  gap: 24px;
}

.student-progress-donut {
  --value: 0;
  width: 178px;
  aspect-ratio: 1;
  margin: 0 auto;
  border-radius: 50%;
  background: conic-gradient(#1f7bf2 calc(var(--value) * 1%), #f0f2f6 0);
  display: grid;
  place-items: center;
  position: relative;
}

.student-progress-donut::after {
  content: "";
  position: absolute;
  inset: 28px;
  border-radius: inherit;
  background: #fff;
}

.student-progress-donut strong,
.student-progress-donut span {
  position: relative;
  z-index: 1;
  display: block;
  text-align: center;
}

.student-progress-donut strong {
  font-size: 42px;
  line-height: 1;
}

.student-progress-donut span {
  margin-top: 8px;
  color: #747b87;
  font-weight: 800;
}

.student-progress-kpis {
  display: grid;
  gap: 13px;
  padding-left: 22px;
  border-left: 1px solid #dfe5ef;
}

.student-progress-kpis article {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
}

.student-progress-kpis svg {
  width: 38px;
  height: 38px;
  color: #1f7bf2;
}

.student-progress-kpis article:nth-child(3) svg {
  color: #ffb400;
}

.student-progress-kpis article:nth-child(4) svg {
  color: #a6adb8;
}

.student-progress-kpis span {
  min-width: 0;
  color: #737a86;
  font-weight: 800;
}

.student-progress-kpis strong {
  color: #111827;
  font-size: 20px;
}

.student-card-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}

.student-card-title-row h2 {
  margin: 0;
}

.student-card-title-row > svg,
.student-card-title-row > i {
  color: #8b94a3;
  width: 22px;
  height: 22px;
  flex: 0 0 auto;
}

.student-card-title-row span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #737a86;
  font-weight: 800;
}

.student-card-title-row span svg {
  width: 28px;
  height: 28px;
  color: #1f7bf2;
  fill: #1f7bf2;
}

.student-mastery-list {
  display: grid;
  gap: 18px;
}

.student-mastery-row {
  display: grid;
  grid-template-columns: 42px minmax(130px, 0.45fr) minmax(140px, 1fr) 52px;
  align-items: center;
  gap: 14px;
}

.student-mastery-row svg {
  width: 34px;
  height: 34px;
  color: #1f7bf2;
}

.student-mastery-row svg.green { color: #12a76a; }
.student-mastery-row svg.orange { color: #ffad1f; }
.student-mastery-row svg.purple { color: #7a42f4; }

.student-mastery-row strong {
  min-width: 0;
  font-size: 18px;
  line-height: 1.15;
}

.student-mastery-track {
  height: 10px;
  border-radius: 999px;
  overflow: hidden;
  background: #edf1f7;
}

.student-mastery-track span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: #1f7bf2;
}

.student-mastery-row b {
  text-align: right;
  font-size: 18px;
}

.student-line-chart {
  width: 100%;
  min-height: 260px;
  overflow: hidden;
}

.student-line-chart svg {
  display: block;
  width: 100%;
  height: auto;
}

.student-line-chart .chart-grid line {
  stroke: #dfe3eb;
  stroke-width: 1;
}

.student-line-chart .chart-area {
  fill: rgba(31, 123, 242, 0.2);
}

.student-line-chart .chart-line {
  fill: none;
  stroke: #1f7bf2;
  stroke-width: 5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.student-line-chart .chart-point {
  fill: #1f7bf2;
  stroke: #1f7bf2;
}

.student-line-chart .chart-value {
  fill: #737b88;
  font-size: 16px;
  font-weight: 800;
  text-anchor: middle;
}

.student-line-chart .chart-label {
  fill: #717985;
  font-size: 14px;
  font-weight: 800;
  text-anchor: middle;
}

.student-line-chart .chart-label.sub {
  font-size: 12px;
}

.student-score-list {
  display: grid;
  gap: 0;
}

.student-score-row {
  min-height: 62px;
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid #e5eaf2;
  cursor: pointer;
  border-radius: 12px;
  transition: background 160ms ease, box-shadow 160ms ease;
}

.student-score-row:hover,
.student-score-row:focus-visible {
  outline: 0;
  background: #f3f8ff;
  box-shadow: 0 0 0 8px #f3f8ff;
}

.student-score-row:last-child {
  border-bottom: 0;
}

.student-score-row > svg {
  width: 36px;
  height: 36px;
  padding: 7px;
  border-radius: 12px;
  background: #eaf2ff;
  color: #1f7bf2;
}

.student-score-row > svg.green { background: #e8f8ef; color: #10a65a; }
.student-score-row > svg.orange { background: #fff4dd; color: #ffad1f; }
.student-score-row > svg.purple { background: #f1eaff; color: #7a42f4; }

.student-score-row strong,
.student-score-row span {
  display: block;
}

.student-score-row strong {
  line-height: 1.15;
}

.student-score-row span {
  color: #767e8b;
  font-weight: 700;
}

.student-score-row b.good { color: #08a64b; }
.student-score-row b.warn { color: #ff7a1a; }
.student-score-row b.danger { color: #d93245; }

.student-score-row small {
  color: #1f7bf2;
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
}

.student-hours-total {
  text-align: center;
}

.student-hours-total strong {
  display: block;
  color: #05070b;
  font-size: 38px;
  line-height: 1;
}

.student-hours-total span {
  display: block;
  margin-top: 8px;
  color: #777f8d;
  font-weight: 800;
}

.student-hour-bars {
  min-height: 150px;
  margin-top: 16px;
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 8px;
  align-items: end;
}

.student-hour-bars article {
  min-width: 0;
  display: grid;
  justify-items: center;
  gap: 6px;
}

.student-hour-bars article > span,
.student-hour-bars small {
  color: #757d8b;
  font-size: 12px;
  font-weight: 800;
}

.student-hour-bars article > div {
  height: 96px;
  display: flex;
  align-items: end;
}

.student-hour-bars b {
  display: block;
  width: 16px;
  min-height: 8px;
  border-radius: 999px 999px 0 0;
  background: #1f7bf2;
}

.student-goal-list {
  display: grid;
  gap: 16px;
}

.student-goal-row {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr) 32px;
  align-items: center;
  gap: 14px;
}

.student-goal-row > svg {
  width: 42px;
  height: 42px;
  color: #1f7bf2;
}

.student-goal-row > svg.complete {
  color: #10a65a;
}

.student-goal-row div div:first-child {
  margin-bottom: 9px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.student-goal-row strong,
.student-goal-row b {
  font-size: 18px;
  line-height: 1.15;
}

.student-goal-row > span {
  color: #8b929d;
}

.student-goal-row > span.complete {
  color: #10a65a;
}

.student-goal-row > span svg {
  width: 30px;
  height: 30px;
}

.student-recommend-card {
  min-height: 0;
  display: flex;
  flex-direction: column;
  background: #fff;
}

.student-recommend-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(250px, 0.36fr);
  gap: 24px;
  align-items: center;
  width: 100%;
}

.recommend-copy > p {
  margin: -8px 0 16px;
  color: #737b88;
  font-weight: 800;
}

.recommend-lesson {
  min-height: 112px;
  max-width: 650px;
  display: grid;
  grid-template-columns: 74px minmax(0, 1fr);
  align-items: center;
  gap: 18px;
  padding: 18px;
  border-radius: 16px;
  background: #fff;
}

.recommend-lesson > svg {
  width: 62px;
  height: 62px;
  padding: 12px;
  border-radius: 999px;
  background: #ddf8e8;
  color: #0aa15c;
}

.recommend-lesson > svg.blue { background: #e5f0ff; color: #1f7bf2; }
.recommend-lesson > svg.orange { background: #fff3d6; color: #ffad1f; }
.recommend-lesson > svg.purple { background: #f1eaff; color: #7a42f4; }

.recommend-lesson strong,
.recommend-lesson span {
  display: block;
}

.recommend-lesson strong {
  font-size: 20px;
  line-height: 1.15;
}

.recommend-lesson span {
  margin: 4px 0 12px;
  color: #747d8b;
  font-weight: 700;
}

.recommend-action {
  display: grid;
  gap: 18px;
  justify-items: stretch;
}

.recommend-visual {
  min-height: 124px;
  border-radius: 16px;
  background: linear-gradient(135deg, #1f7bf2, #0d63d8);
  color: #fff;
  display: grid;
  place-items: center;
}

.recommend-visual svg {
  width: 72px;
  height: 72px;
}

.student-chart-empty,
.empty-progress-state {
  min-height: 220px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 12px;
  text-align: center;
}

.student-chart-empty svg,
.empty-progress-state svg {
  width: 48px;
  height: 48px;
  color: #1f7bf2;
}

.student-chart-empty p,
.empty-progress-state p {
  max-width: 420px;
  margin: 0;
  color: #747c89;
  font-weight: 700;
}

@media (max-width: 1280px) {
  .metric-grid,
  .evidence-metric-grid,
  .quick-grid,
  .student-management-header {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .evidence-active-summary {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .two-col,
  .three-col,
  .capstone-evidence-header,
  .evidence-dashboard-grid,
  .students-layout,
  .student-hero-row,
  .content-forms,
  .lesson-card-grid {
    grid-template-columns: 1fr;
  }

  .student-toolbar {
    grid-template-columns: 1fr 1fr;
  }

  .student-management-grid {
    grid-template-columns: 1fr;
  }

  .settings-grid {
    grid-template-columns: 1fr;
  }

  .student-progress-grid {
    grid-template-columns: 1fr;
  }

  .student-progress-overall,
  .student-weekly-card,
  .student-goals-card,
  .student-topic-mastery,
  .student-recent-scores,
  .student-hours-card,
  .student-recommend-card {
    grid-column: auto;
  }

  .student-right-rail {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .app-topbar {
    min-height: 96px;
  }

  .profile-badge {
    width: 68px;
    height: 68px;
  }

  .profile-badge svg {
    width: 42px;
    height: 42px;
  }
}

@media (max-width: 1080px) and (min-width: 841px) {
  .app-shell {
    grid-template-columns: 116px minmax(0, 1fr);
  }

  .app-sidebar {
    padding: 12px 8px;
    gap: 8px;
  }

  .nav-item {
    border-radius: 14px;
    font-size: 12px;
  }

  .nav-item svg {
    width: 24px;
    height: 24px;
  }

  .compact-brand {
    font-size: 32px;
  }

  .topbar-profile strong {
    font-size: 18px;
  }

  .topbar-profile span {
    font-size: 13px;
  }
}

@media (max-width: 840px) {
  .app-shell {
    grid-template-columns: 1fr;
  }

  .app-sidebar {
    position: fixed;
    inset: auto 0 0 0;
    z-index: 20;
    height: 82px;
    padding: 8px 10px;
    display: grid;
    grid-template-rows: 1fr;
    grid-auto-flow: column;
    grid-auto-columns: minmax(76px, 1fr);
    grid-auto-rows: 1fr;
    overflow-x: auto;
  }

  .nav-item {
    min-height: 64px;
    border-radius: 14px;
    font-size: 12px;
  }

  .nav-item svg {
    width: 24px;
    height: 24px;
  }

  .app-main {
    padding-bottom: 96px;
  }

  .app-topbar {
    min-height: auto;
    padding: 18px;
    align-items: flex-start;
  }

  .settings-header {
    align-items: flex-start;
    flex-direction: column;
  }

  .settings-status-pill {
    width: 100%;
    justify-content: center;
  }

  .settings-readonly-grid {
    grid-template-columns: 1fr;
  }

  .settings-card {
    padding: 18px;
    border-radius: 16px;
  }

  .settings-card .primary-button {
    width: 100%;
    justify-self: stretch;
  }

  .topbar-profile {
    gap: 10px;
  }

  .profile-badge {
    display: none;
  }

  .notification-button {
    width: 42px;
    height: 42px;
    border-radius: 14px;
    background: #eef4ff;
    color: #1f7bf2;
  }

  .notification-panel {
    position: fixed;
    top: 78px;
    right: 12px;
    left: 12px;
    width: auto;
    max-height: calc(100vh - 178px);
  }

  .teacher-section,
  .student-section {
    padding: 20px 14px;
  }

  .dashboard-status {
    margin: 12px 14px 0;
  }

  .metric-grid,
  .quick-grid,
  .student-management-header,
  .quarter-grid,
  .profile-details dl,
  .simple-grid {
    grid-template-columns: 1fr;
  }

  .student-toolbar {
    grid-template-columns: 1fr;
  }

  .segmented-control {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .student-search,
  .student-toolbar select,
  .export-button,
  .segment-button {
    height: 56px;
  }

  .student-right-rail {
    grid-template-columns: 1fr;
  }

  .distribution-layout {
    grid-template-columns: 1fr;
    justify-items: center;
  }

  .student-table-footer {
    align-items: flex-start;
    flex-direction: column;
  }

  .stat-card {
    min-height: auto;
  }

  .welcome-block {
    min-height: auto;
    padding: 26px;
  }

  .achievement-strip {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    padding: 18px;
  }

  .toolbar-row {
    align-items: stretch;
  }

  .toolbar-row select,
  .search-box {
    width: 100%;
  }

  .progress-heading {
    align-items: flex-start;
    flex-direction: column;
  }

  .progress-range-pill {
    width: 100%;
    justify-content: center;
  }

  .student-overall-layout,
  .student-recommend-card {
    grid-template-columns: 1fr;
  }

  .student-progress-kpis {
    padding-left: 0;
    border-left: 0;
  }

  .student-mastery-row {
    grid-template-columns: 34px minmax(0, 1fr) 48px;
    gap: 10px;
  }

  .student-mastery-row .student-mastery-track {
    grid-column: 2 / -1;
    width: 100%;
  }

  .student-line-chart {
    min-height: 210px;
    overflow-x: auto;
  }

  .student-line-chart svg {
    min-width: 520px;
  }

  .student-goal-row {
    grid-template-columns: 38px minmax(0, 1fr) 28px;
  }

  .student-goal-row div div:first-child {
    align-items: flex-start;
    flex-direction: column;
    gap: 4px;
  }

  .recommend-lesson {
    grid-template-columns: 54px minmax(0, 1fr);
    padding: 14px;
  }

  .recommend-lesson > svg {
    width: 48px;
    height: 48px;
    padding: 10px;
  }
}

/* Compact density pass */
:root {
  --compact-radius: 14px;
  --compact-card-pad: clamp(14px, 1.5vw, 20px);
  --compact-gap: clamp(12px, 1.35vw, 18px);
  --compact-control: 46px;
  --compact-shadow: 0 7px 15px rgba(16, 24, 40, 0.11);
}

@media (min-width: 841px) {
  body[data-page="teacher"],
  body[data-page="student"] {
    font-size: 14px;
  }

  .app-shell {
    grid-template-columns: clamp(108px, 9.6vw, 154px) minmax(0, 1fr);
  }

  .app-sidebar {
    padding: clamp(10px, 1.4vh, 18px) 8px;
    gap: clamp(6px, 0.85vh, 10px);
  }

  .nav-item {
    border-radius: 12px;
    gap: 4px;
    font-size: clamp(10px, 0.85vw, 13px);
  }

  .nav-item svg {
    width: clamp(20px, 1.65vw, 27px);
    height: clamp(20px, 1.65vw, 27px);
  }

  .app-main {
    padding-bottom: 18px;
  }

  .app-topbar {
    min-height: clamp(64px, 7.3vh, 88px);
    padding: 10px clamp(18px, 2.4vw, 32px);
    gap: 16px;
  }

  .compact-brand {
    font-size: clamp(25px, 2.25vw, 38px);
  }

  .topbar-profile {
    gap: 10px;
  }

  .topbar-profile > svg {
    width: clamp(22px, 1.75vw, 30px);
    height: clamp(22px, 1.75vw, 30px);
  }

  .topbar-profile strong {
    font-size: clamp(16px, 1.45vw, 23px);
  }

  .topbar-profile span {
    font-size: clamp(11px, 1.05vw, 16px);
  }

  .profile-badge {
    width: clamp(46px, 4.5vw, 64px);
    height: clamp(46px, 4.5vw, 64px);
  }

  .icon-shell {
    width: 36px;
    height: 36px;
    border-radius: 10px;
  }

  .teacher-section,
  .student-section {
    padding: clamp(14px, 2vh, 24px) clamp(16px, 2.4vw, 30px) 12px;
  }

  .dashboard-status {
    margin: 8px clamp(16px, 2.4vw, 30px) 0;
  }

  .section-heading {
    margin-bottom: 16px;
    gap: 14px;
  }

  .section-heading h1 {
    font-size: clamp(24px, 2.25vw, 34px);
  }

  .section-heading p {
    margin-top: 5px;
    font-size: 13px;
  }

  .metric-grid,
  .student-management-header {
    gap: var(--compact-gap);
    margin-bottom: 18px;
  }

  .dashboard-grid,
  .evidence-dashboard-grid,
  .student-right-rail,
  .quick-grid,
  .lesson-card-grid {
    gap: var(--compact-gap);
  }

  .student-hero-row {
    gap: var(--compact-gap);
    margin-bottom: 18px;
  }

  .stat-card,
  .student-metric-card {
    min-height: 104px;
    padding: 16px 18px;
    gap: 14px;
    border-radius: var(--compact-radius);
    box-shadow: var(--compact-shadow);
  }

  .stat-card strong {
    font-size: 30px;
  }

  .student-metric-card strong {
    margin: 4px 0;
    font-size: 26px;
  }

  .student-metric-card.top-performer strong {
    font-size: 18px;
  }

  .stat-card p,
  .stat-card small,
  .student-metric-card p,
  .student-metric-card small {
    font-size: 12px;
  }

  .stat-icon,
  .student-metric-icon {
    width: 54px;
    height: 54px;
  }

  .stat-icon svg,
  .student-metric-icon svg {
    width: 29px;
    height: 29px;
  }

  .panel-card,
  .student-side-card,
  .quick-access,
  .achievement-strip {
    padding: var(--compact-card-pad);
    border-radius: var(--compact-radius);
    box-shadow: var(--compact-shadow);
  }

  .panel-card h2,
  .quick-access h2,
  .student-side-card h2 {
    margin-bottom: 12px;
    font-size: 18px;
  }

  .student-toolbar {
    grid-template-columns: minmax(220px, 320px) auto auto auto minmax(120px, 150px);
    gap: 12px;
    margin-bottom: 18px;
  }

  .student-search,
  .student-toolbar select,
  .export-button,
  .segment-button {
    height: var(--compact-control);
    border-radius: 10px;
    font-size: 13px;
  }

  .student-search {
    grid-template-columns: 38px minmax(0, 1fr);
    padding: 0 12px;
  }

  .student-search svg,
  .export-button svg {
    width: 21px;
    height: 21px;
  }

  .student-search input {
    font-size: 13px;
  }

  .student-toolbar select,
  .export-button {
    padding: 0 14px;
  }

  .segmented-control {
    gap: 10px;
  }

  .segment-button {
    min-width: 118px;
    border-width: 1px;
    font-size: 14px;
  }

  .student-management-grid {
    grid-template-columns: minmax(0, 1fr) minmax(295px, 360px);
    gap: var(--compact-gap);
  }

  .student-table-card,
  .student-side-card {
    border-radius: var(--compact-radius);
    box-shadow: var(--compact-shadow);
  }

  .student-table-card {
    padding: 8px;
  }

  .student-management-table {
    min-width: 980px;
  }

  .student-management-table th,
  .student-management-table td {
    padding: 9px 11px;
    font-size: 12px;
  }

  .student-name-cell {
    min-width: 165px;
    gap: 9px;
  }

  .student-name-cell svg {
    width: 24px;
    height: 24px;
  }

  .mini-progress {
    width: 76px;
    height: 6px;
  }

  .reward-icons,
  .certificate-count,
  .student-row-actions {
    gap: 6px;
  }

  .reward-icon {
    width: 18px;
    height: 18px;
  }

  .student-row-actions .icon-button {
    width: 28px;
    height: 28px;
    border-radius: 8px;
  }

  .student-table-footer {
    min-width: 980px;
    padding: 10px 12px;
    font-size: 12px;
  }

  .student-pagination {
    gap: 8px;
  }

  .student-pagination button {
    min-width: 30px;
    height: 30px;
    border-radius: 8px;
  }

  .distribution-layout {
    grid-template-columns: 112px minmax(0, 1fr);
    gap: 12px;
  }

  .distribution-donut {
    width: 112px;
  }

  .distribution-donut::after {
    inset: 25px;
  }

  .distribution-donut strong {
    font-size: 20px;
  }

  .distribution-donut span,
  .distribution-legend p,
  .distribution-legend strong {
    font-size: 10px;
  }

  .distribution-legend {
    gap: 8px;
  }

  .attention-row {
    grid-template-columns: 30px minmax(0, 1fr) auto;
    gap: 9px;
    padding: 10px 0;
  }

  .attention-row > svg {
    width: 26px;
    height: 26px;
  }

  .attention-row span {
    font-size: 11px;
  }

  .student-drawer-panel {
    width: min(400px, 100%);
    padding: 18px;
    gap: 10px;
  }

  .student-drawer-panel h2 {
    font-size: 21px;
  }

  .drawer-summary {
    padding: 12px;
    border-radius: 12px;
  }

  .drawer-summary > span {
    width: 42px;
    height: 42px;
  }

  .drawer-stats div {
    padding: 8px 6px;
  }

  .student-drawer-panel label {
    gap: 5px;
    font-size: 12px;
  }

  .student-drawer-panel input,
  .student-drawer-panel select {
    min-height: 40px;
    border-radius: 9px;
    font-size: 13px;
  }

  .drawer-actions {
    gap: 8px;
  }

  .drawer-actions button {
    min-height: 40px;
    font-size: 12px;
  }

  .quarter-grid {
    gap: 12px;
  }

  .quarter-card {
    padding: 14px;
    border-radius: 12px;
  }

  .content-form,
  .inline-form,
  .table-shell {
    border-radius: var(--compact-radius);
  }

  .content-form,
  .inline-form {
    padding: 16px;
    gap: 12px;
  }

  .toolbar-row {
    gap: 10px;
  }
}

@media (min-width: 1181px) {
  body[data-page="login"] .auth-shell {
    width: min(1320px, calc(100% - 56px));
    grid-template-columns: minmax(450px, 570px) minmax(350px, 460px);
    gap: clamp(44px, 5vw, 82px);
  }

  body[data-page="login"] .brand-mark {
    margin-bottom: 18px;
    font-size: clamp(28px, 2.25vw, 40px);
  }

  body[data-page="login"] .brand-panel h1 {
    font-size: clamp(42px, 3.85vw, 56px);
  }

  body[data-page="login"] .brand-panel p {
    max-width: 560px;
    margin-top: 18px;
    margin-bottom: 18px;
    font-size: clamp(15px, 1.05vw, 18px);
  }

  body[data-page="login"] .asset-stage,
  body[data-page="login"] .feature-strip {
    width: min(540px, 100%);
  }

  body[data-page="login"] .feature-strip {
    min-height: 60px;
    margin-top: 14px;
    padding: 10px 14px;
  }

  body[data-page="login"] .feature-strip div {
    gap: 7px;
    font-size: 10px;
  }

  body[data-page="login"] .feature-strip svg {
    width: 22px;
    height: 22px;
  }

  body[data-page="login"] .login-card {
    padding: 34px 38px;
    border-radius: 18px;
  }

  body[data-page="login"] .login-card .form-heading {
    margin-bottom: 20px;
  }

  body[data-page="login"] .login-card .form-heading h2 {
    font-size: 32px;
  }

  body[data-page="login"] .login-card .form-heading p {
    font-size: 14px;
  }

  body[data-page="login"] .login-card .form-stack {
    gap: 14px;
  }

  body[data-page="login"] .login-card .input-wrap {
    height: 50px;
  }

  body[data-page="login"] .login-card .form-row {
    margin-bottom: 14px;
  }

  body[data-page="login"] .login-card .primary-button,
  body[data-page="login"] .login-card .outline-button {
    min-height: 48px;
    font-size: 16px;
  }

  .check-label {
    gap: 9px;
    font-size: 13px;
  }

  .check-label input {
    width: 22px;
    height: 22px;
  }

  .create-shell {
    width: min(1470px, calc(100% - 48px));
    grid-template-columns: minmax(340px, 450px) minmax(680px, 910px);
    gap: clamp(28px, 4vw, 58px);
  }

  .create-shell .brand-mark {
    font-size: clamp(25px, 2vw, 36px);
    margin-bottom: 16px;
  }

  .create-shell .brand-panel h1 {
    font-size: clamp(34px, 3.3vw, 52px);
  }

  .create-shell .brand-panel p {
    max-width: 510px;
    margin-top: 16px;
    margin-bottom: 16px;
    font-size: clamp(13px, 0.9vw, 16px);
  }

  .create-shell .asset-stage,
  .create-shell .feature-strip {
    width: min(455px, 100%);
  }

  .create-shell .feature-strip {
    min-height: 58px;
    margin-top: 14px;
    padding: 9px 12px;
  }

  .create-card {
    max-width: 910px;
    padding: 16px 28px;
    border-radius: 18px;
  }

  .create-card .form-heading {
    margin-bottom: 12px;
  }

  .create-card .form-heading h2 {
    font-size: 30px;
  }

  .create-card .form-heading p {
    font-size: 13px;
  }

  .create-card .form-stack.compact {
    gap: 7px 14px;
  }

  .compact .field {
    gap: 4px;
    font-size: 12px;
  }

  .create-card .compact .input-wrap {
    min-height: 38px;
    height: 38px;
    border-width: 1px;
    border-radius: 9px;
    padding: 0 12px;
  }

  .create-card .compact .input-wrap input,
  .create-card .compact .input-wrap select {
    font-size: 12px;
  }

  .create-card .field-hint,
  .create-card .terms {
    font-size: 11px;
  }

  .create-card .primary-button,
  .create-card .outline-button {
    min-height: 40px;
    font-size: 14px;
  }
}

@media (min-width: 841px) {
  body[data-page="student"] .welcome-block {
    min-height: 160px;
    padding: 28px;
  }

  body[data-page="student"] .welcome-block h1 {
    font-size: clamp(28px, 3vw, 42px);
  }

  body[data-page="student"] .welcome-block p {
    margin-top: 10px;
    font-size: 15px;
  }

  body[data-page="student"] .achievement-strip {
    padding: 18px;
    gap: 10px;
  }

  body[data-page="student"] .achievement-strip svg {
    width: 42px;
    height: 42px;
  }

  body[data-page="student"] .achievement-strip strong {
    font-size: 17px;
  }

  body[data-page="student"] .achievement-strip span {
    font-size: 12px;
  }

  body[data-page="student"] .quick-access {
    margin-bottom: 18px;
  }

  body[data-page="student"] .quick-grid {
    margin-top: 12px;
  }

  body[data-page="student"] .quick-card {
    min-height: 132px;
    padding: 16px;
    border-radius: var(--compact-radius);
  }

  body[data-page="student"] .quick-card > svg {
    top: 16px;
    width: 44px;
    height: 44px;
  }

  body[data-page="student"] .quick-card strong {
    font-size: 15px;
  }

  body[data-page="student"] .quick-card span {
    font-size: 12px;
  }

  body[data-page="student"] .quick-card button {
    right: 12px;
    bottom: 12px;
  }

  body[data-page="student"] .quick-card button svg {
    width: 28px;
    height: 28px;
  }

  .soft-pill {
    padding: 6px 10px;
    font-size: 12px;
  }

  .mission-card h3 {
    font-size: 17px;
  }

  .mission-visual {
    width: 80px;
    height: 80px;
    border-radius: 18px;
  }

  .mission-visual svg {
    width: 48px;
    height: 48px;
  }

  .activity-row {
    grid-template-columns: 32px minmax(0, 1fr);
    gap: 10px;
    padding: 12px 0;
  }

  .activity-row svg,
  .progress-stats svg {
    width: 25px;
    height: 25px;
  }

  .gauge {
    width: 160px;
    height: 86px;
    margin: 12px auto 18px;
    border-width: 20px;
  }

  .gauge strong {
    font-size: 30px;
  }

  .progress-stats div {
    padding: 10px 6px;
  }

  .progress-stats strong {
    font-size: 15px;
  }

  .progress-stats span {
    font-size: 10px;
  }

  .lesson-card {
    min-height: 190px;
    padding: 16px;
    gap: 9px;
    border-radius: var(--compact-radius);
    box-shadow: var(--compact-shadow);
  }

  .lesson-card > svg {
    width: 42px;
    height: 42px;
  }

  .lesson-card strong {
    font-size: 17px;
  }

  .lesson-card span,
  .lesson-card p,
  .lesson-card small {
    font-size: 12px;
  }
}

@media (max-width: 840px) {
  .app-sidebar {
    height: 72px;
    grid-template-rows: 1fr;
    grid-auto-columns: minmax(68px, 1fr);
    grid-auto-rows: 1fr;
  }

  .nav-item {
    min-height: 56px;
    width: 100%;
    font-size: 11px;
  }

  .nav-item svg {
    width: 21px;
    height: 21px;
  }

  .app-main {
    padding-bottom: 82px;
  }

  .teacher-section,
  .student-section {
    padding: 16px 12px;
  }

  .student-search,
  .student-toolbar select,
  .export-button,
  .segment-button {
    height: 48px;
  }
}

/* Premium dashboard fit and alignment polish */
body[data-page="teacher"],
body[data-page="student"] {
  background:
    radial-gradient(circle at top right, rgba(31, 123, 242, 0.09), transparent 34rem),
    linear-gradient(180deg, #f7faff 0%, #edf3fb 100%);
}

body[data-page="teacher"] .teacher-section[data-view="content"] {
  padding-top: clamp(14px, 2vh, 22px);
}

body[data-page="teacher"] .app-main,
body[data-page="student"] .app-main {
  background: transparent;
}

body[data-page="teacher"] .app-topbar,
body[data-page="student"] .app-topbar {
  background: rgba(248, 250, 255, 0.9);
  backdrop-filter: blur(14px);
}

body[data-page="teacher"] .stat-card,
body[data-page="teacher"] .panel-card,
body[data-page="teacher"] .student-metric-card,
body[data-page="teacher"] .student-table-card,
body[data-page="teacher"] .student-side-card,
body[data-page="student"] .stat-card,
body[data-page="student"] .panel-card,
body[data-page="student"] .welcome-block,
body[data-page="student"] .quick-access,
body[data-page="student"] .quick-card,
body[data-page="student"] .achievement-strip,
body[data-page="student"] .lesson-card {
  border-color: #dfe7f2;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.09);
}

body[data-page="teacher"] .student-management-header {
  gap: 14px;
  margin-bottom: 16px;
}

body[data-page="teacher"] .student-metric-card {
  min-height: 94px;
  padding: 14px 16px;
  gap: 12px;
}

body[data-page="teacher"] .student-metric-icon {
  width: 48px;
  height: 48px;
}

body[data-page="teacher"] .student-metric-icon svg {
  width: 25px;
  height: 25px;
}

body[data-page="teacher"] .student-metric-card p,
body[data-page="teacher"] .student-metric-card small {
  font-size: 11px;
  line-height: 1.2;
}

body[data-page="teacher"] .student-metric-card strong {
  margin: 3px 0;
  font-size: 24px;
}

body[data-page="teacher"] .student-metric-card.top-performer strong {
  max-width: 150px;
  overflow: hidden;
  font-size: 16px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body[data-page="teacher"] .student-toolbar {
  grid-template-columns: minmax(190px, 1.15fr) minmax(210px, auto) minmax(132px, 0.55fr) minmax(150px, 0.7fr) 112px;
  gap: 10px;
  margin-bottom: 14px;
}

body[data-page="teacher"] .student-search,
body[data-page="teacher"] .student-toolbar select,
body[data-page="teacher"] .export-button,
body[data-page="teacher"] .segment-button {
  height: 42px;
  border-radius: 11px;
  font-size: 12px;
}

body[data-page="teacher"] .student-search {
  grid-template-columns: 32px minmax(0, 1fr);
  padding: 0 12px;
}

body[data-page="teacher"] .student-search svg,
body[data-page="teacher"] .export-button svg {
  width: 18px;
  height: 18px;
}

body[data-page="teacher"] .student-search input {
  font-size: 12px;
}

body[data-page="teacher"] .student-toolbar select,
body[data-page="teacher"] .export-button {
  padding: 0 12px;
}

body[data-page="teacher"] .segmented-control {
  gap: 8px;
}

body[data-page="teacher"] .segment-button {
  min-width: 96px;
  font-size: 13px;
}

body[data-page="teacher"] .student-management-grid {
  grid-template-columns: minmax(0, 1fr) minmax(250px, 320px);
  gap: 14px;
}

body[data-page="teacher"] .student-table-card {
  overflow-x: visible;
  padding: 0;
}

body[data-page="teacher"] .student-management-table {
  width: 100%;
  min-width: 0;
  table-layout: fixed;
  border-collapse: separate;
  border-spacing: 0;
}

body[data-page="teacher"] .student-col-name { width: 20%; }
body[data-page="teacher"] .student-col-grade { width: 10%; }
body[data-page="teacher"] .student-col-lessons { width: 14%; }
body[data-page="teacher"] .student-col-average { width: 11%; }
body[data-page="teacher"] .student-col-badges { width: 8%; }
body[data-page="teacher"] .student-col-certificates { width: 10%; }
body[data-page="teacher"] .student-col-active { width: 13%; }
body[data-page="teacher"] .student-col-status { width: 14%; }

body[data-page="teacher"] .student-management-table th,
body[data-page="teacher"] .student-management-table td {
  padding: 10px 8px;
  font-size: 11px;
  line-height: 1.18;
  text-overflow: clip;
  white-space: normal;
  word-break: normal;
}

body[data-page="teacher"] .student-management-table th {
  color: #111827;
  font-size: 10.5px;
  font-weight: 900;
  letter-spacing: 0;
  line-height: 1.05;
}

body[data-page="teacher"] .student-management-table tbody tr {
  cursor: pointer;
  transition: background 140ms ease, box-shadow 140ms ease, transform 140ms ease;
}

body[data-page="teacher"] .student-management-table tbody tr:hover,
body[data-page="teacher"] .student-management-table tbody tr:focus-within {
  background: #f7fbff;
}

body[data-page="teacher"] .student-data-row:focus {
  outline: 2px solid rgba(31, 123, 242, 0.38);
  outline-offset: -2px;
}

body[data-page="teacher"] .student-name-cell {
  min-width: 0;
  gap: 7px;
}

body[data-page="teacher"] .student-name-cell svg {
  width: 18px;
  height: 18px;
}

body[data-page="teacher"] .student-name-cell strong {
  min-width: 0;
  overflow: hidden;
  font-size: 11.5px;
  font-weight: 800;
  line-height: 1.18;
  overflow-wrap: anywhere;
  text-overflow: clip;
  white-space: normal;
}

.grade-chip {
  display: inline-flex;
  max-width: 100%;
  align-items: center;
  justify-content: center;
  padding: 4px 7px;
  border-radius: 999px;
  background: #f0f6ff;
  color: #1f5fbf;
  font-size: 10.5px;
  font-weight: 800;
}

body[data-page="teacher"] .mini-progress {
  width: min(74px, 100%);
  height: 5px;
  margin-top: 5px;
}

body[data-page="teacher"] .good-text,
body[data-page="teacher"] .warn-text {
  font-size: 12px;
  font-weight: 900;
}

body[data-page="teacher"] .reward-icons,
body[data-page="teacher"] .certificate-count {
  gap: 4px;
}

body[data-page="teacher"] .reward-icon {
  width: 15px;
  height: 15px;
}

body[data-page="teacher"] .certificate-count svg {
  width: 14px;
  height: 14px;
}

body[data-page="teacher"] .status-pill {
  display: inline-flex;
  min-width: 94px;
  max-width: none;
  min-height: 28px;
  align-items: center;
  justify-content: center;
  padding: 6px 10px;
  font-size: 10.5px;
  font-weight: 800;
  line-height: 1;
  text-align: center;
  white-space: nowrap;
}

body[data-page="teacher"] .student-table-footer {
  min-width: 0;
  padding: 10px 14px;
  font-size: 11px;
}

body[data-page="teacher"] .student-pagination {
  gap: 5px;
}

body[data-page="teacher"] .student-pagination button {
  min-width: 28px;
  height: 28px;
  border-radius: 8px;
  font-size: 11px;
}

body[data-page="teacher"] .student-pagination svg {
  width: 15px;
  height: 15px;
}

body[data-page="teacher"] .student-side-card {
  padding: 14px;
}

body[data-page="teacher"] .student-side-card h2 {
  margin-bottom: 10px;
  font-size: 16px;
}

body[data-page="teacher"] .distribution-layout {
  grid-template-columns: 88px minmax(0, 1fr);
  gap: 10px;
}

body[data-page="teacher"] .distribution-donut {
  width: 88px;
}

body[data-page="teacher"] .distribution-donut::after {
  inset: 20px;
}

body[data-page="teacher"] .distribution-donut strong {
  font-size: 17px;
}

body[data-page="teacher"] .distribution-donut span,
body[data-page="teacher"] .distribution-legend p,
body[data-page="teacher"] .distribution-legend strong {
  font-size: 9px;
}

body[data-page="teacher"] .distribution-legend {
  gap: 6px;
}

body[data-page="teacher"] .distribution-legend div {
  grid-template-columns: 8px minmax(0, 1fr) auto;
  gap: 6px;
}

body[data-page="teacher"] .legend-dot {
  width: 8px;
  height: 8px;
}

body[data-page="teacher"] .attention-row {
  grid-template-columns: 24px minmax(0, 1fr) auto;
  gap: 8px;
  padding: 9px 0;
}

body[data-page="teacher"] .attention-row > svg {
  width: 22px;
  height: 22px;
}

body[data-page="teacher"] .attention-row strong {
  overflow: hidden;
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body[data-page="teacher"] .attention-row span {
  overflow: hidden;
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body[data-page="teacher"] .attention-row b {
  font-size: 12px;
}

body[data-page="student"] .welcome-block,
body[data-page="student"] .quick-access,
body[data-page="student"] .achievement-strip,
body[data-page="student"] .lesson-card {
  border-radius: 16px;
}

body[data-page="student"] .quick-card {
  border-radius: 14px;
}

@media (max-width: 1500px) and (min-width: 841px) {
  body[data-page="teacher"] .student-management-grid {
    grid-template-columns: 1fr;
  }

  body[data-page="teacher"] .student-right-rail {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 1120px) and (min-width: 841px) {
  body[data-page="teacher"] .student-toolbar {
    grid-template-columns: 1fr 1fr;
  }

  body[data-page="teacher"] .student-management-table th,
  body[data-page="teacher"] .student-management-table td {
    padding: 9px 7px;
    font-size: 10px;
  }

  body[data-page="teacher"] .student-management-table th {
    font-size: 9.5px;
  }

  body[data-page="teacher"] .status-pill,
  body[data-page="teacher"] .grade-chip {
    padding: 4px 6px;
    font-size: 9.5px;
  }
}

@media (max-width: 840px) {
  body[data-page="teacher"] .student-table-card {
    overflow-x: visible;
  }

  body[data-page="teacher"] .student-management-table,
  body[data-page="teacher"] .student-management-table thead,
  body[data-page="teacher"] .student-management-table tbody,
  body[data-page="teacher"] .student-management-table tr,
  body[data-page="teacher"] .student-management-table th,
  body[data-page="teacher"] .student-management-table td {
    display: block;
    width: 100%;
  }

  body[data-page="teacher"] .student-management-table colgroup,
  body[data-page="teacher"] .student-management-table thead {
    display: none;
  }

  body[data-page="teacher"] .student-management-table tbody {
    display: grid;
    gap: 10px;
    padding: 10px;
  }

  body[data-page="teacher"] .student-management-table tr {
    border: 1px solid #e3eaf4;
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.08);
  }

  body[data-page="teacher"] .student-management-table td {
    display: grid;
    grid-template-columns: 118px minmax(0, 1fr);
    align-items: center;
    padding: 8px 12px;
    border-bottom: 1px solid #edf1f7;
    font-size: 12px;
    white-space: normal;
  }

  body[data-page="teacher"] .student-management-table td:last-child {
    border-bottom: 0;
  }

  body[data-page="teacher"] .student-management-table td::before {
    color: #687386;
    font-size: 10px;
    font-weight: 900;
    text-transform: uppercase;
  }

  body[data-page="teacher"] .student-management-table td:nth-child(1)::before { content: "Student"; }
  body[data-page="teacher"] .student-management-table td:nth-child(2)::before { content: "Grade"; }
  body[data-page="teacher"] .student-management-table td:nth-child(3)::before { content: "Lessons"; }
  body[data-page="teacher"] .student-management-table td:nth-child(4)::before { content: "Average"; }
  body[data-page="teacher"] .student-management-table td:nth-child(5)::before { content: "Badges"; }
  body[data-page="teacher"] .student-management-table td:nth-child(6)::before { content: "Certificates"; }
  body[data-page="teacher"] .student-management-table td:nth-child(7)::before { content: "Last Active"; }
  body[data-page="teacher"] .student-management-table td:nth-child(8)::before { content: "Status"; }

  body[data-page="teacher"] .student-table-footer {
    flex-direction: column;
    align-items: flex-start;
  }

  body[data-page="teacher"] .student-right-rail {
    grid-template-columns: 1fr;
  }
}

/* Teacher lessons dashboard */
.lesson-dashboard-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 330px);
  gap: 18px;
  align-items: start;
}

.lesson-main-column {
  min-width: 0;
  display: grid;
  gap: 16px;
  overflow: hidden;
}

.lesson-metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.lesson-metric-card,
.lesson-library-card,
.lesson-side-card {
  border: 1px solid #dfe7f2;
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.09);
}

.lesson-metric-card {
  min-width: 0;
  min-height: 96px;
  padding: 14px;
  display: flex;
  align-items: center;
  gap: 11px;
}

.lesson-metric-icon {
  width: 44px;
  height: 44px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
}

.lesson-metric-icon svg {
  width: 24px;
  height: 24px;
}

.lesson-metric-icon.blue { background: #eef4ff; color: #1f7bf2; }
.lesson-metric-icon.green { background: #e9f9ef; color: #09a957; }
.lesson-metric-icon.orange { background: #fff0dd; color: #ff8428; }
.lesson-metric-icon.purple { background: #f3eaff; color: #7b42f5; }

.lesson-metric-card p,
.lesson-metric-card small {
  margin: 0;
  color: #777d89;
  font-size: 11px;
  font-weight: 800;
  line-height: 1.2;
  overflow-wrap: anywhere;
}

.lesson-metric-card strong {
  display: block;
  margin: 4px 0;
  color: #05070b;
  font-size: 25px;
  line-height: 1;
}

.lesson-metric-card b {
  color: #1f7bf2;
}

.lesson-library-card {
  padding: 14px 16px 16px;
  min-width: 0;
  overflow: hidden;
}

.lesson-library-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.lesson-library-actions {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex: 0 0 auto;
}

.primary-button.compact {
  min-height: 38px;
  padding: 0 14px;
  border-radius: 10px;
  font-size: 12px;
}

.lesson-library-header h1 {
  margin: 0;
  font-size: 22px;
  line-height: 1;
}

.lesson-icon-button {
  width: 38px;
  height: 38px;
  border: 1px solid #dfe7f2;
  border-radius: 10px;
  background: #fff;
  color: #27354a;
  display: inline-grid;
  place-items: center;
  cursor: pointer;
}

.lesson-icon-button svg {
  width: 19px;
  height: 19px;
}

.lesson-toolbar {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) minmax(135px, 170px) minmax(120px, 150px) minmax(130px, 160px);
  gap: 10px;
  margin-bottom: 14px;
}

.lesson-search,
.lesson-toolbar select {
  height: 42px;
  border: 1px solid #d9dfeb;
  border-radius: 10px;
  background: #fff;
  color: #27354a;
  font-size: 12px;
  font-weight: 700;
}

.lesson-search {
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr);
  align-items: center;
  padding: 0 12px;
}

.lesson-search svg {
  width: 18px;
  height: 18px;
}

.lesson-search input {
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  font-size: 12px;
  font-weight: 700;
}

.lesson-toolbar select {
  padding: 0 12px;
}

.lesson-table-heading,
.lesson-row {
  display: grid;
  grid-template-columns: minmax(220px, 1.6fr) minmax(112px, 0.72fr) minmax(86px, 0.5fr) minmax(82px, 0.48fr) minmax(88px, 0.5fr) minmax(230px, 1.25fr);
  align-items: center;
  gap: 10px;
}

.lesson-table-heading {
  padding: 0 10px 9px;
  color: #27354a;
  font-size: 12px;
  font-weight: 900;
}

.lesson-row-list {
  display: grid;
  border: 1px solid #e3eaf4;
  border-radius: 12px;
  overflow: hidden;
}

.lesson-row {
  min-height: 82px;
  padding: 11px;
  border-bottom: 1px solid #e8edf5;
  background: #fff;
}

.lesson-row > * {
  min-width: 0;
}

.lesson-row:last-child {
  border-bottom: 0;
}

.lesson-row-list.compact .lesson-row {
  min-height: 68px;
  padding-top: 9px;
  padding-bottom: 9px;
}

.lesson-title-cell {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 12px;
}

.lesson-title-cell div {
  min-width: 0;
}

.lesson-title-cell strong,
.recent-upload-row strong {
  display: block;
  color: #111827;
  font-size: 13px;
  font-weight: 900;
  line-height: 1.2;
}

.lesson-title-cell small,
.recent-upload-row small {
  display: block;
  margin-top: 4px;
  color: #31415c;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.25;
}

.lesson-type-icon {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
}

.lesson-type-icon svg {
  width: 22px;
  height: 22px;
}

.lesson-type-icon.blue,
.category-pill.blue { background: #eaf2ff; color: #1f7bf2; }
.lesson-type-icon.green,
.category-pill.green { background: #e8f8ef; color: #0aa85b; }
.lesson-type-icon.orange,
.category-pill.orange { background: #fff0dc; color: #ff8428; }
.lesson-type-icon.purple,
.category-pill.purple { background: #f2eaff; color: #7b42f5; }

.category-pill {
  display: inline-flex;
  max-width: 100%;
  align-items: center;
  justify-content: center;
  padding: 6px 8px;
  border-radius: 8px;
  font-size: 10.5px;
  font-weight: 900;
  line-height: 1.1;
  text-align: center;
}

.duration-cell {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: #26354d;
  font-size: 12px;
  font-weight: 800;
}

.duration-cell svg {
  width: 16px;
  height: 16px;
}

.lesson-actions {
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  gap: 6px;
  min-width: 0;
  flex-wrap: wrap;
}

.lesson-actions .small-button {
  min-height: 32px;
  padding: 0 8px;
  border-color: #dfe7f2;
  background: #fff;
  color: #26354d;
  font-size: 11px;
  gap: 6px;
  white-space: nowrap;
}

.lesson-actions .small-button svg {
  width: 15px;
  height: 15px;
}

.lesson-actions .small-button:disabled {
  color: #a6afbf;
  cursor: default;
}

.lesson-actions .icon-button {
  width: 32px;
  height: 32px;
  border: 1px solid #dfe7f2;
  border-radius: 9px;
  flex: 0 0 auto;
}

.lesson-table-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-top: 14px;
  color: #111827;
  font-size: 12px;
  font-weight: 800;
}

.lesson-side-rail {
  display: grid;
  gap: 16px;
  min-width: 0;
}

.lesson-side-card {
  min-width: 0;
  padding: 16px;
}

.lesson-side-card h2 {
  margin: 0 0 12px;
  font-size: 17px;
}

.lesson-drop-zone {
  min-height: 164px;
  border: 2px dashed #9db8ee;
  border-radius: 12px;
  background: #fbfdff;
  color: #233251;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 5px;
  text-align: center;
  cursor: pointer;
}

.lesson-drop-zone.dragging {
  border-color: #1f7bf2;
  background: #eef5ff;
}

.lesson-drop-zone input {
  display: none;
}

.lesson-drop-zone svg {
  width: 42px;
  height: 42px;
  color: #0b5ff0;
}

.lesson-drop-zone strong,
.lesson-drop-zone span,
.lesson-drop-zone small {
  font-size: 11px;
  font-weight: 700;
}

.lesson-drop-zone small {
  margin-top: 8px;
  color: #26354d;
}

.upload-file-name {
  margin: 10px 0;
  color: #687386;
  font-size: 11px;
  font-weight: 800;
  overflow-wrap: anywhere;
}

.recent-upload-list {
  display: grid;
  gap: 10px;
}

.recent-upload-row {
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
}

.recent-upload-row > span {
  width: 28px;
  height: 34px;
  border: 2px solid currentColor;
  border-radius: 6px;
  display: grid;
  place-items: center;
}

.recent-upload-row > span.red { color: #df2f2f; }
.recent-upload-row > span.orange { color: #ff8428; }
.recent-upload-row > span.blue { color: #1f7bf2; }
.recent-upload-row > span.purple { color: #7b42f5; }

.recent-upload-row svg {
  width: 17px;
  height: 17px;
}

.recent-upload-row time {
  color: #263b70;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}

.mini-calendar {
  display: grid;
  gap: 10px;
}

.calendar-topline,
.calendar-weekdays,
.calendar-grid,
.calendar-legend {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 6px;
}

.calendar-topline {
  grid-template-columns: 1fr auto;
  align-items: center;
}

.calendar-weekdays {
  color: #263b70;
  font-size: 10px;
  font-weight: 800;
  text-align: center;
}

.calendar-grid button {
  min-height: 28px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: #111827;
  font-size: 11px;
  font-weight: 800;
  display: grid;
  place-items: center;
  gap: 2px;
}

.calendar-grid button.active {
  background: #0b5ff0;
  color: #fff;
}

.calendar-grid button.muted {
  color: #9aa4b5;
}

.calendar-grid i,
.calendar-legend span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
  font-style: normal;
}

.dot {
  width: 7px;
  height: 7px;
  border-radius: 999px;
  display: inline-block;
}

.dot.blue,
.calendar-event-list span.blue { background: #0b5ff0; }
.dot.orange,
.calendar-event-list span.orange { background: #ff8b22; }
.dot.green,
.calendar-event-list span.green { background: #0aa85b; }

.calendar-legend {
  grid-template-columns: repeat(3, auto);
  justify-content: start;
  gap: 14px;
  color: #263b70;
  font-size: 11px;
  font-weight: 700;
}

.lesson-author-drawer .student-drawer-backdrop {
  background: rgba(15, 23, 42, 0.5);
}

.lesson-drawer-panel {
  left: 50%;
  right: auto;
  width: min(1180px, calc(100vw - 40px));
  height: calc(100vh - 40px);
  max-height: calc(100vh - 40px);
  margin: 20px 0;
  border-radius: 18px;
  transform: translate(-50%, 24px);
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.24);
}

.student-drawer.open .lesson-drawer-panel {
  transform: translate(-50%, 0);
}

.lesson-drawer-panel textarea {
  min-height: 86px;
  border: 1px solid #d9dfeb;
  border-radius: 10px;
  padding: 10px 12px;
  resize: vertical;
}

.lesson-author-tabs {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin: 4px 0 8px;
}

.lesson-author-tabs button {
  min-height: 38px;
  border: 1px solid #d7e2f2;
  border-radius: 8px;
  background: #f8fbff;
  color: #61708a;
  font-weight: 800;
  cursor: pointer;
}

.lesson-author-tabs button.active {
  background: #247cf3;
  border-color: #247cf3;
  color: #fff;
}

.lesson-tab-panel { display: none; }

.lesson-tab-panel.active {
  display: grid;
  gap: 12px;
}

.lesson-tab-panel[data-lesson-panel="details"].active,
.lesson-tab-panel[data-lesson-panel="resources"].active {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.lesson-tab-panel[data-lesson-panel="details"].active > label:nth-child(1),
.lesson-tab-panel[data-lesson-panel="details"].active > label:nth-child(2),
.lesson-tab-panel[data-lesson-panel="details"].active > label:nth-child(3),
.lesson-tab-panel[data-lesson-panel="resources"].active > label,
.lesson-tab-panel[data-lesson-panel="resources"].active > p {
  grid-column: 1 / -1;
}

.author-panel-heading,
.author-item-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.author-panel-heading {
  flex-wrap: wrap;
}

.author-panel-heading strong,
.author-item-top strong {
  color: #071225;
  font-size: 1rem;
  font-weight: 900;
}

.author-panel-heading span,
.helper-text {
  display: block;
  color: #6e7787;
  font-size: 0.82rem;
  font-weight: 700;
  line-height: 1.45;
}

.author-list {
  display: grid;
  gap: 12px;
}

.author-item {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid #dfe7f4;
  border-radius: 10px;
  background: #fbfdff;
  min-width: 0;
  overflow: hidden;
}

.lesson-player-drawer .lesson-preview-panel {
  width: min(1560px, calc(100vw - 32px));
  max-width: 1560px;
  height: calc(100vh - 32px);
  max-height: calc(100vh - 32px);
  overflow: hidden;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  align-content: stretch;
  background: #f7faff;
}

.lesson-player-shell {
  display: grid;
  gap: 12px;
  min-height: 0;
  overflow: visible !important;
  padding-right: 2px;
  scroll-behavior: smooth;
}

.lesson-preview-state {
  min-height: min(520px, calc(100vh - 170px));
  display: grid;
  place-items: center;
  align-content: center;
  gap: 14px;
  padding: 28px;
  border: 1px dashed #b9cef3;
  border-radius: 16px;
  background: #f8fbff;
  color: #1b2b4b;
  text-align: center;
}

.lesson-preview-state > span {
  width: 58px;
  height: 58px;
  border-radius: 18px;
  display: inline-grid;
  place-items: center;
  background: #eaf2ff;
  color: #247cf3;
}

.lesson-preview-state svg {
  width: 30px;
  height: 30px;
}

.lesson-preview-state.loading svg {
  animation: spin 900ms linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.lesson-preview-state.error {
  border-color: #fecaca;
  background: #fff7f7;
}

.lesson-preview-state.error > span {
  background: #fee2e2;
  color: #dc2626;
}

.lesson-preview-state strong {
  display: block;
  font-size: 1.15rem;
  font-weight: 900;
}

.lesson-preview-state p {
  max-width: 560px;
  margin: 8px auto 0;
  color: #667085;
  font-weight: 800;
}

.lesson-preview-state small {
  display: block;
  max-width: 620px;
  margin: 8px auto 0;
  color: #9a3412;
  font-weight: 800;
}

.lesson-preview-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  border: 1px solid #d7e5fb;
  border-radius: 12px;
  background: #f6f9ff;
}

.lesson-preview-toolbar > span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #263b70;
  font-size: 0.88rem;
  font-weight: 900;
}

.lesson-preview-toolbar svg {
  width: 17px;
  height: 17px;
}

.lesson-preview-toolbar div {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.lesson-preview-toolbar button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid #d7e2f2;
  border-radius: 8px;
  background: #fff;
  color: #263b70;
  font-weight: 900;
  cursor: pointer;
}

.lesson-preview-toolbar button.active {
  background: #247cf3;
  border-color: #247cf3;
  color: #fff;
}

.lesson-preview-toolbar button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.lesson-player-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.lesson-player-heading h1 {
  margin: 0;
  color: #050b18;
  font-size: clamp(1.7rem, 2vw, 2.45rem);
  line-height: 1.05;
}

.lesson-player-heading p {
  margin: 8px 0 0;
  color: #777e8c;
  font-weight: 800;
}

.lesson-player-grid {
  display: grid;
  grid-template-columns: minmax(280px, 0.86fr) minmax(470px, 1.35fr) minmax(290px, 0.78fr);
  gap: 14px;
  align-items: start;
}

.lesson-sequence-card,
.lesson-content-card,
.lesson-progress-card,
.lesson-quick-tips {
  background: #fff;
  border: 1px solid #dce5f2;
  border-radius: 12px;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.1);
  transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
}

.lesson-sequence-card { overflow: hidden; }

.lesson-back-link { margin: 18px 18px 6px; }

.preview-label {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #247cf3;
  font-size: 0.88rem;
  font-weight: 900;
}

.lesson-module-title {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px 18px 18px;
}

.lesson-module-title strong {
  display: block;
  color: #050b18;
  font-size: 1.22rem;
  font-weight: 900;
}

.lesson-module-title small {
  color: #6e7787;
  font-weight: 700;
}

.lesson-sequence-top {
  display: flex;
  justify-content: space-between;
  padding: 12px 18px;
  border-top: 1px solid #e1e7f0;
  border-bottom: 1px solid #e1e7f0;
  font-weight: 900;
}

.lesson-sequence-top span {
  color: #777e8c;
  font-weight: 800;
}

.lesson-sequence-list:not(.netacad-sequence-list) {
  display: grid;
  gap: 7px;
  max-height: min(420px, calc(100vh - 430px));
  overflow: auto;
  padding: 14px;
}

.lesson-sequence-list:not(.netacad-sequence-list) button {
  display: grid;
  grid-template-columns: 32px 36px minmax(0, 1fr);
  align-items: start;
  column-gap: 9px;
  width: 100%;
  border: 0;
  border-radius: 10px;
  background: transparent;
  padding: 12px 10px;
  min-height: 86px;
  color: #071225;
  text-align: left;
  cursor: pointer;
  overflow: hidden;
  transition: background 160ms ease, transform 160ms ease;
}

.lesson-sequence-list:not(.netacad-sequence-list) button:hover { background: #f4f8ff; }

.lesson-sequence-list:not(.netacad-sequence-list) button.active {
  background: #eaf1ff;
  transform: translateX(2px);
}

.lesson-sequence-list:not(.netacad-sequence-list) b {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: #247cf3;
  color: #fff;
  font-size: 0.86rem;
  margin-top: 2px;
}

.lesson-sequence-list:not(.netacad-sequence-list) span {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 1px solid #d8e1ef;
  border-radius: 9px;
  color: #247cf3;
  margin-top: 1px;
}

.lesson-sequence-copy {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.lesson-sequence-list:not(.netacad-sequence-list) strong {
  font-size: 0.84rem;
  font-weight: 900;
  line-height: 1.2;
  min-width: 0;
}

.lesson-sequence-list:not(.netacad-sequence-list) em {
  color: #247cf3;
  font-size: 0.76rem;
  font-style: normal;
  font-weight: 800;
  line-height: 1.1;
  margin-top: 0;
}

.lesson-sequence-list:not(.netacad-sequence-list) button.complete em { color: #09a957; }

.lesson-sequence-list:not(.netacad-sequence-list) button.locked,
.lesson-sequence-list:not(.netacad-sequence-list) button:disabled {
  cursor: not-allowed;
  opacity: 0.7;
  background: #f5f8fc;
  transform: none;
}

.lesson-sequence-list:not(.netacad-sequence-list) button.locked:hover,
.lesson-sequence-list:not(.netacad-sequence-list) button:disabled:hover {
  background: #f5f8fc;
}

.lesson-sequence-list:not(.netacad-sequence-list) button.locked b,
.lesson-sequence-list:not(.netacad-sequence-list) button:disabled b {
  background: #c7d2e0;
}

.lesson-sequence-list:not(.netacad-sequence-list) button.locked span,
.lesson-sequence-list:not(.netacad-sequence-list) button:disabled span {
  color: #718199;
}

.lesson-sequence-list:not(.netacad-sequence-list) button.locked em,
.lesson-sequence-list:not(.netacad-sequence-list) button:disabled em {
  color: #718199;
}

.lesson-content-card { padding: 18px; }

/* ==========================================================================
   INTERACTIVE TECHNICAL LEARNING INTERFACE DESIGN SYSTEM
   Modular Course Reader & Formative Assessment Experience
   ========================================================================== */

.netacad-preview-banner {
  background: linear-gradient(135deg, #1467f2 0%, #0d56d9 100%);
  border: 1px solid #1467f2;
  border-radius: 10px;
  color: #ffffff;
  padding: 10px 14px;
  box-shadow: 0 4px 14px rgba(20, 103, 242, 0.18);
}

.netacad-preview-banner > span {
  color: #ffffff;
  font-weight: 750;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.88rem;
}

.netacad-preview-banner button {
  background: rgba(255, 255, 255, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.35);
  color: #ffffff;
  border-radius: 6px;
  padding: 6px 14px;
  font-weight: 750;
  transition: all 160ms ease;
  cursor: pointer;
}

.netacad-preview-banner button:hover {
  background: rgba(255, 255, 255, 0.28);
}

.netacad-preview-banner button.active {
  background: #ffffff;
  border-color: #ffffff;
  color: #1467f2;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.netacad-reader-topbar {
  margin-bottom: 8px;
}

.netacad-breadcrumb-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding: 8px 14px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04);
}

.netacad-breadcrumbs {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.84rem;
  color: #64748b;
  flex-wrap: wrap;
}

.netacad-crumb-root {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 750;
  color: #1467f2;
}

.netacad-crumb-root svg {
  width: 15px;
  height: 15px;
}

.netacad-crumb-sep {
  width: 14px;
  height: 14px;
  color: #94a3b8;
}

.netacad-crumb-module {
  font-weight: 600;
  color: #475569;
}

.netacad-crumb-current {
  font-weight: 750;
  color: #0f172a;
}

.netacad-meta-chips {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.netacad-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 0.76rem;
  font-weight: 700;
  background: #f1f5f9;
  color: #475569;
  border: 1px solid #e2e8f0;
}

.netacad-chip svg {
  width: 13px;
  height: 13px;
}

.netacad-chip.duration {
  background: #eef6ff;
  color: #1467f2;
  border-color: #bfdbfe;
}

.netacad-chip.standard {
  background: #f0fdf4;
  color: #15803d;
  border-color: #bbf7d0;
}

.netacad-chip.date {
  background: #f8fafc;
  color: #64748b;
  border-color: #cbd5e1;
}

.netacad-heading {
  margin-bottom: 12px;
}

.netacad-topic-kicker-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
}

.netacad-kicker-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 4px;
  background: #eef6ff;
  color: #1467f2;
  border: 1px solid #bfdbfe;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.netacad-kicker-part {
  font-size: 0.8rem;
  font-weight: 700;
  color: #64748b;
}

.netacad-course-progress {
  height: 4px;
  border-radius: 999px;
  background: #e2e8f0;
  overflow: hidden;
  margin-bottom: 14px;
}

.netacad-course-progress span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, #1467f2, #38bdf8);
  border-radius: 999px;
  transition: width 300ms ease;
}

.netacad-sequence-card {
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  background: #ffffff;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.04);
}

.netacad-module-header {
  padding: 16px 18px 14px;
  border-bottom: 1px solid #edf2f7;
}

.netacad-curriculum-tag {
  display: block;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #1467f2;
  margin-bottom: 2px;
}

.netacad-sequence-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 18px;
  background: #f8fafc;
  border-bottom: 1px solid #e2e8f0;
  font-size: 0.82rem;
}

.netacad-sequence-top span {
  font-weight: 700;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.netacad-sequence-top strong {
  color: #1467f2;
  font-weight: 750;
}

.netacad-sequence-list {
  display: flex !important;
  flex-direction: column !important;
  gap: 8px !important;
  padding: 12px !important;
  max-height: calc(100vh - 220px) !important;
  min-height: 200px !important;
  overflow-y: auto !important;
  overflow-x: hidden !important;
  scrollbar-width: thin !important;
  scrollbar-color: #cbd5e1 transparent !important;
}

.netacad-sequence-list::-webkit-scrollbar {
  width: 6px;
}

.netacad-sequence-list::-webkit-scrollbar-track {
  background: transparent;
}

.netacad-sequence-list::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 4px;
}

.netacad-sequence-list::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

/* Neutralize any legacy conflicting selectors inside netacad-sequence-list */
.netacad-sequence-list button {
  min-height: 72px !important;
  flex-shrink: 0 !important;
}

.netacad-topic-nav-item {
  display: flex !important;
  align-items: flex-start !important;
  gap: 10px !important;
  width: 100% !important;
  flex-shrink: 0 !important;
  min-height: 72px !important;
  height: auto !important;
  border: 1px solid #e2e8f0 !important;
  border-left: 4px solid transparent !important;
  border-radius: 9px !important;
  background: #ffffff !important;
  padding: 12px 12px 14px 12px !important;
  text-align: left !important;
  cursor: pointer !important;
  transition: all 160ms ease !important;
  box-sizing: border-box !important;
  overflow: visible !important;
  position: relative !important;
}

.netacad-topic-nav-item:hover {
  background: #f8faff !important;
  border-color: #cbd5e1 !important;
}

.netacad-topic-nav-item.active {
  background: #eff6ff !important;
  border-color: #bfdbfe !important;
  border-left-color: #1467f2 !important;
  box-shadow: 0 2px 8px rgba(20, 103, 242, 0.08) !important;
}

.netacad-topic-nav-item.locked,
.netacad-topic-nav-item:disabled {
  opacity: 1 !important;
  background: #fbfcfe !important;
  cursor: not-allowed !important;
  border-color: #e2e8f0 !important;
  border-left-color: transparent !important;
  transform: none !important;
}

.netacad-topic-num {
  display: grid !important;
  place-items: center !important;
  flex: 0 0 32px !important;
  width: 32px !important;
  height: 24px !important;
  border-radius: 4px !important;
  background: #f1f5f9 !important;
  color: #475569 !important;
  font-size: 0.76rem !important;
  font-weight: 800 !important;
  font-family: ui-monospace, SFMono-Regular, monospace !important;
  margin-top: 2px !important;
  box-sizing: border-box !important;
}

.netacad-topic-nav-item.active .netacad-topic-num {
  background: #1467f2 !important;
  color: #ffffff !important;
}

.netacad-topic-nav-item.complete .netacad-topic-num {
  background: #dcfce7 !important;
  color: #15803d !important;
}

.netacad-topic-nav-item.locked .netacad-topic-num,
.netacad-topic-nav-item:disabled .netacad-topic-num {
  background: #f1f5f9 !important;
  color: #94a3b8 !important;
}

.netacad-topic-icon {
  display: grid !important;
  place-items: center !important;
  flex: 0 0 20px !important;
  width: 20px !important;
  height: 24px !important;
  color: #64748b !important;
  margin-top: 2px !important;
}

.netacad-topic-icon svg {
  width: 18px !important;
  height: 18px !important;
}

.netacad-topic-nav-item.active .netacad-topic-icon {
  color: #1467f2 !important;
}

.netacad-topic-nav-item.locked .netacad-topic-icon,
.netacad-topic-nav-item:disabled .netacad-topic-icon {
  color: #94a3b8 !important;
}

.netacad-topic-text-col {
  display: flex !important;
  flex-direction: column !important;
  gap: 4px !important;
  min-width: 0 !important;
  flex: 1 1 auto !important;
  overflow: visible !important;
}

.netacad-topic-tag-line {
  display: block !important;
  font-size: 0.68rem !important;
  font-weight: 800 !important;
  text-transform: uppercase !important;
  letter-spacing: 0.04em !important;
  color: #64748b !important;
  line-height: 1.2 !important;
}

.netacad-topic-title-text {
  display: block !important;
  font-size: 0.84rem !important;
  font-weight: 700 !important;
  color: #0f172a !important;
  line-height: 1.35 !important;
  word-break: break-word !important;
  overflow-wrap: break-word !important;
  white-space: normal !important;
  margin: 0 !important;
  padding: 0 !important;
  overflow: visible !important;
}

.netacad-topic-nav-item.active .netacad-topic-title-text {
  color: #1467f2 !important;
  font-weight: 800 !important;
}

.netacad-topic-nav-item.locked .netacad-topic-title-text,
.netacad-topic-nav-item:disabled .netacad-topic-title-text {
  color: #475569 !important;
}

.netacad-topic-status-line {
  display: block !important;
  font-size: 0.74rem !important;
  font-weight: 700 !important;
  color: #94a3b8 !important;
  line-height: 1.3 !important;
  margin-top: 3px !important;
  padding-bottom: 2px !important;
}

.netacad-topic-status-line.active {
  color: #1467f2 !important;
  font-weight: 800 !important;
}

.netacad-topic-status-line.complete {
  color: #16a34a !important;
  font-weight: 700 !important;
}

.netacad-topic-status-line.locked {
  color: #dc2626 !important;
  font-weight: 700 !important;
}

.netacad-topic-check {
  display: grid !important;
  place-items: center !important;
  flex: 0 0 20px !important;
  width: 20px !important;
  height: 20px !important;
  border-radius: 50% !important;
  background: #16a34a !important;
  color: #ffffff !important;
  margin-top: 3px !important;
  margin-left: auto !important;
}

.netacad-topic-check svg {
  width: 13px !important;
  height: 13px !important;
}

/* Center Canvas */
.netacad-content-canvas {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 32px 36px;
  box-shadow: 0 4px 18px rgba(15, 23, 42, 0.04);
}

.netacad-topic-header {
  margin-bottom: 24px;
  padding-bottom: 18px;
  border-bottom: 1px solid #edf2f7;
}

.netacad-header-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 10px;
}

.netacad-topic-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 6px;
  background: #eef6ff;
  color: #1467f2;
  border: 1px solid #bfdbfe;
  font-size: 0.74rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.netacad-topic-pill svg {
  width: 14px;
  height: 14px;
}

.netacad-header-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.netacad-topic-title {
  margin: 8px 0 14px;
  font-size: clamp(1.45rem, 1.85vw, 1.95rem);
  font-weight: 800;
  color: #0f172a;
  line-height: 1.22;
}

.netacad-objective-card {
  padding: 16px 20px;
  border-radius: 8px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-left: 4px solid #1467f2;
}

.netacad-objective-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.74rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #1467f2;
  margin-bottom: 6px;
}

.netacad-objective-badge svg {
  width: 14px;
  height: 14px;
}

.netacad-objective-card p {
  margin: 0;
  color: #334155;
  font-size: 0.95rem;
  line-height: 1.6;
  font-weight: 500;
}

/* Pedagogical Callout Blocks */
.netacad-blocks {
  display: grid;
  gap: 20px;
}

.netacad-callout {
  border-radius: 8px;
  border: 1px solid #e2e8f0;
  background: #ffffff;
  overflow: hidden;
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.03);
}

.netacad-callout-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 18px;
  background: #f8fafc;
  border-bottom: 1px solid #edf2f7;
}

.netacad-callout-icon {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 6px;
  background: #eef6ff;
  color: #1467f2;
  flex: 0 0 32px;
}

.netacad-callout-icon svg {
  width: 18px;
  height: 18px;
}

.netacad-callout-kicker {
  display: block;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #64748b;
  margin-bottom: 2px;
}

.netacad-callout-header h3 {
  margin: 0;
  font-size: 1.02rem;
  font-weight: 750;
  color: #0f172a;
}

.netacad-callout-body {
  padding: 18px 22px;
  color: #334155;
  font-size: 0.96rem;
  line-height: 1.68;
}

.netacad-text-p {
  margin: 0 0 12px;
  color: #334155;
  font-size: 0.96rem;
  line-height: 1.68;
}

.netacad-text-p:last-child {
  margin-bottom: 0;
}

/* Callout Variants */
.netacad-callout.key_points {
  border-left: 4px solid #1467f2;
}
.netacad-callout.key_points .netacad-callout-kicker {
  color: #1467f2;
}

.netacad-callout.safety_note {
  border-color: #fde68a;
  border-left: 4px solid #d97706;
  background: #fffdfa;
}
.netacad-callout.safety_note .netacad-callout-header {
  background: #fffbeb;
  border-bottom-color: #fde68a;
}
.netacad-callout.safety_note .netacad-callout-icon {
  background: #fef3c7;
  color: #d97706;
}
.netacad-callout.safety_note .netacad-callout-kicker {
  color: #b45309;
}
.netacad-callout.safety_note .netacad-callout-body {
  color: #78350f;
}

.netacad-callout.steps {
  border-left: 4px solid #0284c7;
}
.netacad-callout.steps .netacad-callout-icon {
  background: #e0f2fe;
  color: #0284c7;
}
.netacad-callout.steps .netacad-callout-kicker {
  color: #0284c7;
}

.netacad-callout.vocabulary {
  border-left: 4px solid #059669;
}
.netacad-callout.vocabulary .netacad-callout-icon {
  background: #ecfdf5;
  color: #059669;
}
.netacad-callout.vocabulary .netacad-callout-kicker {
  color: #059669;
}

.netacad-callout.quick_tip {
  border-color: #bbf7d0;
  border-left: 4px solid #10b981;
  background: #fcfdfd;
}
.netacad-callout.quick_tip .netacad-callout-header {
  background: #f0fdf4;
  border-bottom-color: #bbf7d0;
}
.netacad-callout.quick_tip .netacad-callout-icon {
  background: #dcfce7;
  color: #16a34a;
}
.netacad-callout.quick_tip .netacad-callout-kicker {
  color: #15803d;
}

.netacad-callout.example {
  border-left: 4px solid #6366f1;
}
.netacad-callout.example .netacad-callout-icon {
  background: #eef2ff;
  color: #6366f1;
}
.netacad-callout.example .netacad-callout-kicker {
  color: #6366f1;
}

.netacad-callout.summary {
  border-left: 4px solid #334155;
}
.netacad-callout.summary .netacad-callout-icon {
  background: #f1f5f9;
  color: #334155;
}
.netacad-callout.summary .netacad-callout-kicker {
  color: #475569;
}

/* Step Timeline */
.netacad-step-timeline {
  display: grid;
  gap: 14px;
  position: relative;
  padding-left: 10px;
  margin: 6px 0;
}

.netacad-step-timeline::before {
  content: "";
  position: absolute;
  left: 24px;
  top: 18px;
  bottom: 22px;
  width: 2px;
  background: #e2e8f0;
  z-index: 0;
}

.netacad-step-item {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  position: relative;
  z-index: 1;
}

.netacad-step-badge {
  display: grid;
  place-items: center;
  flex: 0 0 30px;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: #1467f2;
  color: #ffffff;
  font-size: 0.82rem;
  font-weight: 800;
  border: 2px solid #ffffff;
  box-shadow: 0 0 0 2px #bfdbfe;
}

.netacad-step-content {
  flex: 1;
  min-width: 0;
  padding: 12px 16px;
  border-radius: 8px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
}

.netacad-step-title {
  display: block;
  font-size: 0.95rem;
  font-weight: 750;
  color: #0f172a;
  margin-bottom: 4px;
}

.netacad-step-desc {
  margin: 0;
  font-size: 0.92rem;
  color: #475569;
  line-height: 1.55;
}

/* Glossary & Technical Specifications Grid */
.netacad-glossary-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 12px;
  margin: 6px 0;
}

.netacad-glossary-card {
  padding: 14px 16px;
  border-radius: 8px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  transition: all 160ms ease;
}

.netacad-glossary-card:hover {
  border-color: #1467f2;
  background: #f8faff;
}

.netacad-term-pill {
  display: inline-block;
  padding: 3px 8px;
  border-radius: 4px;
  background: #eef6ff;
  color: #1467f2;
  border: 1px solid #bfdbfe;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.84rem;
  font-weight: 750;
  margin-bottom: 6px;
}

.netacad-term-def {
  margin: 0;
  font-size: 0.88rem;
  color: #475569;
  line-height: 1.5;
}

/* NetAcad Bullet List */
.netacad-bullet-list {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.netacad-bullet-list li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 6px;
  background: #f8fafc;
  border: 1px solid #edf2f7;
}

.netacad-bullet-icon {
  display: grid;
  place-items: center;
  width: 20px;
  height: 20px;
  flex: 0 0 20px;
  color: #1467f2;
  margin-top: 1px;
}

.netacad-bullet-icon svg {
  width: 16px;
  height: 16px;
}

.netacad-bullet-list.summary .netacad-bullet-icon {
  color: #16a34a;
}

.netacad-bullet-text {
  flex: 1;
  font-size: 0.92rem;
  color: #334155;
  line-height: 1.55;
}

.netacad-resource-panel {
  margin-top: 24px;
  padding: 16px 20px;
  border-radius: 8px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
}

.netacad-resource-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  font-size: 0.9rem;
  font-weight: 750;
  color: #0f172a;
}

.netacad-resource-header svg {
  width: 17px;
  height: 17px;
  color: #1467f2;
}

.netacad-resource-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: 6px;
  border: 1px solid #cbd5e1;
  background: #ffffff;
  color: #1467f2;
  font-weight: 750;
  font-size: 0.88rem;
  text-decoration: none;
  transition: all 160ms ease;
}

.netacad-resource-btn:hover {
  background: #eff6ff;
  border-color: #1467f2;
}

.netacad-section-media {
  margin: 14px 0 0;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #f8fafc;
  overflow: hidden;
}

.netacad-section-media img {
  display: block;
  width: 100%;
  max-height: 380px;
  object-fit: contain;
}

.netacad-link-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 6px;
  background: #f0f7ff;
  border: 1px solid #bae6fd;
  color: #0284c7;
  font-weight: 700;
  font-size: 0.88rem;
  text-decoration: none;
}

/* ==========================================================================
   FORMATIVE "CHECK YOUR UNDERSTANDING" (CYU) & ASSESSMENT SYSTEM
   ========================================================================== */

.netacad-embedded-cyu {
  margin-top: 36px;
  padding-top: 28px;
  border-top: 2px dashed #e2e8f0;
}

.netacad-cyu-panel {
  display: grid;
  gap: 20px;
}

.netacad-cyu-header-banner {
  padding: 22px 26px;
  border-radius: 12px;
  background: linear-gradient(135deg, #1467f2 0%, #0d56d9 100%);
  color: #ffffff;
  box-shadow: 0 6px 18px rgba(20, 103, 242, 0.22);
}

.netacad-cyu-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 8px;
}

.netacad-cyu-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 1.12rem;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: 0.02em;
}

.netacad-cyu-tag svg {
  width: 22px;
  height: 22px;
  color: #ffffff;
}

.netacad-cyu-chips {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.netacad-cyu-chips .netacad-chip {
  background: rgba(255, 255, 255, 0.2);
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.35);
  font-weight: 700;
}

.netacad-cyu-chips .netacad-chip.score.pass {
  background: #16a34a;
  border-color: #22c55e;
}

.netacad-cyu-chips .netacad-chip.score.retry {
  background: #ea580c;
  border-color: #f97316;
}

.netacad-cyu-lead {
  margin: 0;
  color: rgba(255, 255, 255, 0.94);
  font-size: 0.94rem;
  line-height: 1.55;
  max-width: 820px;
}

.netacad-cyu-lead strong {
  color: #ffffff;
  font-weight: 800;
}

.netacad-cyu-questions-list {
  display: grid;
  gap: 18px;
}

.netacad-question-card {
  padding: 22px 24px;
  border-radius: 10px;
  background: #ffffff;
  border: 1.5px solid #e2e8f0;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.04);
  transition: all 160ms ease;
}

.netacad-question-card:hover {
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.06);
}

.netacad-question-card.needs-answer {
  border-color: #f97316;
  box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.12);
}

.netacad-question-card.correct {
  border-color: #16a34a;
  background: #fcfdfc;
}

.netacad-question-card.incorrect {
  border-color: #f59e0b;
  background: #fffefa;
}

.netacad-question-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
  font-size: 0.8rem;
  font-weight: 750;
  color: #64748b;
}

.netacad-q-counter {
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #1467f2;
  font-weight: 800;
}

.netacad-q-points {
  background: #f1f5f9;
  padding: 2px 8px;
  border-radius: 4px;
}

.netacad-q-prompt {
  margin-bottom: 16px;
  font-size: 1.05rem;
  font-weight: 700;
  color: #0f172a;
  line-height: 1.5;
}

.netacad-choice-grid {
  display: grid;
  gap: 10px;
}

.netacad-choice-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  border-radius: 8px;
  border: 1.5px solid #e2e8f0;
  background: #ffffff;
  cursor: pointer;
  transition: all 160ms ease;
  position: relative;
}

.netacad-choice-card input[type="radio"] {
  appearance: none;
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.netacad-choice-letter {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #f1f5f9;
  color: #475569;
  font-size: 0.82rem;
  font-weight: 800;
  flex: 0 0 28px;
  transition: all 160ms ease;
}

.netacad-choice-text {
  flex: 1;
  font-size: 0.94rem;
  color: #334155;
  font-weight: 600;
  line-height: 1.4;
}

.netacad-choice-card:hover {
  border-color: #1467f2;
  background: #f8faff;
}

.netacad-choice-card:hover .netacad-choice-letter {
  background: #eef6ff;
  color: #1467f2;
}

.netacad-choice-card:has(input:checked) {
  border-color: #1467f2;
  background: #eff6ff;
  box-shadow: 0 0 0 1px #1467f2;
}

.netacad-choice-card:has(input:checked) .netacad-choice-letter {
  background: #1467f2;
  color: #ffffff;
}

.netacad-choice-card.is-correct {
  border-color: #16a34a !important;
  background: #f0fdf4 !important;
  box-shadow: 0 0 0 1px #16a34a;
}

.netacad-choice-card.is-correct .netacad-choice-letter {
  background: #16a34a !important;
  color: #ffffff !important;
}

.netacad-choice-card.is-wrong {
  border-color: #dc2626 !important;
  background: #fef2f2 !important;
  box-shadow: 0 0 0 1px #dc2626;
}

.netacad-choice-card.is-wrong .netacad-choice-letter {
  background: #dc2626 !important;
  color: #ffffff !important;
}

.netacad-choice-icon-correct {
  color: #16a34a;
  width: 20px;
  height: 20px;
}

.netacad-choice-icon-wrong {
  color: #dc2626;
  width: 20px;
  height: 20px;
}

.netacad-text-input {
  width: 100%;
  min-height: 44px;
  padding: 10px 14px;
  border: 1.5px solid #cbd5e1;
  border-radius: 8px;
  font-size: 0.95rem;
  font-family: inherit;
  font-weight: 600;
  color: #0f172a;
  transition: border-color 160ms ease;
}

.netacad-text-input:focus {
  border-color: #1467f2;
  outline: none;
  box-shadow: 0 0 0 3px rgba(20, 103, 242, 0.14);
}

.netacad-hint-section {
  margin-top: 14px;
}

.netacad-hint-toggle {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: none;
  background: transparent;
  color: #0284c7;
  font-size: 0.84rem;
  font-weight: 750;
  cursor: pointer;
  padding: 4px 0;
}

.netacad-hint-toggle:hover {
  color: #0369a1;
  text-decoration: underline;
}

.netacad-hint-toggle svg {
  width: 16px;
  height: 16px;
}

.netacad-hint-drawer {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-top: 8px;
  padding: 12px 16px;
  border-radius: 8px;
  background: #fffbeb;
  border: 1px solid #fde68a;
  color: #92400e;
  font-size: 0.88rem;
  line-height: 1.55;
  animation: lessonContentIn 160ms ease;
}

.netacad-hint-drawer svg {
  width: 18px;
  height: 18px;
  color: #d97706;
  flex: 0 0 18px;
  margin-top: 1px;
}

.netacad-hint-drawer p {
  margin: 0;
}

.netacad-feedback-card {
  margin-top: 16px;
  padding: 14px 18px;
  border-radius: 8px;
  animation: lessonContentIn 180ms ease;
}

.netacad-feedback-card.correct {
  background: #f0fdf4;
  border: 1px solid #86efac;
  border-left: 4px solid #16a34a;
}

.netacad-feedback-card.incorrect {
  background: #fffbeb;
  border: 1px solid #fde68a;
  border-left: 4px solid #f59e0b;
}

.netacad-feedback-badge {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.88rem;
  font-weight: 800;
  margin-bottom: 4px;
}

.netacad-feedback-badge svg {
  width: 18px;
  height: 18px;
}

.netacad-feedback-card.correct .netacad-feedback-badge {
  color: #15803d;
}

.netacad-feedback-card.incorrect .netacad-feedback-badge {
  color: #b45309;
}

.netacad-feedback-text {
  margin: 0;
  font-size: 0.9rem;
  line-height: 1.55;
  color: #334155;
}

.netacad-action-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 16px;
  flex-wrap: wrap;
}

.netacad-submit-btn {
  min-height: 48px;
  padding: 0 26px;
  border-radius: 8px;
  background: #1467f2;
  color: #ffffff;
  font-size: 0.95rem;
  font-weight: 800;
  box-shadow: 0 4px 14px rgba(20, 103, 242, 0.25);
  border: none;
  cursor: pointer;
  transition: all 160ms ease;
}

.netacad-submit-btn:hover {
  background: #0d56d9;
  box-shadow: 0 6px 18px rgba(20, 103, 242, 0.35);
}

.netacad-submit-btn:disabled {
  background: #cbd5e1;
  color: #64748b;
  box-shadow: none;
  cursor: not-allowed;
}

.netacad-reset-btn {
  min-height: 48px;
  padding: 0 20px;
  border-radius: 8px;
  border: 1px solid #cbd5e1;
  background: #ffffff;
  color: #334155;
  font-weight: 750;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all 160ms ease;
}

.netacad-reset-btn:hover {
  background: #f1f5f9;
  border-color: #94a3b8;
}

.lesson-player-actions,
.netacad-player-actions {
  position: static !important;
  bottom: auto !important;
  z-index: 1 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 16px !important;
  margin-top: 36px !important;
  padding: 24px 0 8px 0 !important;
  border-top: 1px solid #e2e8f0 !important;
  background: transparent !important;
  box-shadow: none !important;
  width: 100% !important;
}

.lesson-player-actions.single-action,
.netacad-player-actions.single-action {
  justify-content: flex-end !important;
}

.netacad-prev-btn {
  display: inline-flex !important;
  align-items: center !important;
  gap: 8px !important;
  min-height: 44px !important;
  padding: 10px 20px !important;
  border-radius: 8px !important;
  border: 1px solid #cbd5e1 !important;
  background: #ffffff !important;
  color: #334155 !important;
  font-weight: 750 !important;
  font-size: 0.88rem !important;
  cursor: pointer !important;
  transition: all 180ms ease !important;
}

.netacad-prev-btn:hover {
  background: #f8fafc !important;
  border-color: #94a3b8 !important;
  color: #0f172a !important;
}

.netacad-next-btn {
  display: inline-flex !important;
  align-items: center !important;
  gap: 8px !important;
  min-height: 44px !important;
  padding: 10px 24px !important;
  border-radius: 8px !important;
  background: #1467f2 !important;
  color: #ffffff !important;
  font-weight: 800 !important;
  font-size: 0.88rem !important;
  border: none !important;
  cursor: pointer !important;
  margin-left: auto !important;
  box-shadow: 0 4px 12px rgba(20, 103, 242, 0.22) !important;
  transition: all 180ms ease !important;
}

.netacad-next-btn:hover:not(:disabled) {
  background: #0d56d9 !important;
  box-shadow: 0 6px 16px rgba(20, 103, 242, 0.32) !important;
  transform: translateY(-1px) !important;
}

.netacad-next-btn:disabled {
  background: #e2e8f0 !important;
  color: #94a3b8 !important;
  box-shadow: none !important;
  cursor: not-allowed !important;
  transform: none !important;
}

.netacad-cyu-empty {
  padding: 32px;
  text-align: center;
  color: #64748b;
  background: #f8fafc;
  border: 1px dashed #cbd5e1;
  border-radius: 8px;
}

.netacad-cyu-empty svg {
  width: 36px;
  height: 36px;
  color: #94a3b8;
  margin-bottom: 8px;
}

.lesson-loading-panel {
  min-height: min(560px, calc(100vh - 180px));
  border: 1px solid #d8e5f7;
  border-radius: 20px;
  background: #fff;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 12px;
  color: #667085;
  text-align: center;
  box-shadow: 0 18px 40px rgba(16, 24, 40, 0.08);
}

.lesson-loading-panel .button-spinner {
  width: 34px;
  height: 34px;
  border-width: 3px;
  border-color: rgba(31, 123, 242, 0.18);
  border-top-color: #1f7bf2;
}

.lesson-loading-panel strong {
  color: #07111f;
  font-size: 1.2rem;
  font-weight: 900;
}

.lesson-loading-panel p {
  max-width: 360px;
  margin: 0;
  font-weight: 700;
}

.lesson-player-drawer .lesson-preview-panel {
  width: min(1500px, calc(100vw - 28px));
  height: calc(100vh - 28px);
  max-height: calc(100vh - 28px);
  border-radius: 18px;
}

.lesson-player-shell {
  gap: 10px;
  padding: 0 4px 28px 0;
  overflow: visible !important;
}

body[data-page="student"] .student-section[data-view="lesson-player"],
body[data-page="student"] #studentLessonPlayer,
body[data-page="teacher"] .teacher-section[data-view="lesson-preview"],
body[data-page="teacher"] #teacherLessonPreview {
  overflow: visible !important;
  overflow-x: visible !important;
  min-height: 0;
}

.teacher-preview-heading {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  flex-wrap: wrap !important;
  gap: 12px !important;
  margin-bottom: 16px !important;
}

.teacher-preview-mode-tag .preview-mode-pill {
  display: inline-flex !important;
  align-items: center !important;
  gap: 8px !important;
  padding: 6px 14px !important;
  border-radius: 999px !important;
  background: #eff6ff !important;
  border: 1px solid #bfdbfe !important;
  color: #1e40af !important;
  font-size: 0.82rem !important;
  font-weight: 700 !important;
}

.teacher-preview-mode-tag .preview-mode-pill svg {
  width: 16px !important;
  height: 16px !important;
}

.lesson-player-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
  color: #247cf3;
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.lesson-player-kicker b {
  padding: 3px 8px;
  border-radius: 999px;
  background: #eaf2ff;
  color: #1d62c7;
  font-size: 0.72rem;
}

.lesson-player-heading h1 {
  max-width: 880px;
  font-size: clamp(1.45rem, 1.65vw, 2rem);
  line-height: 1.12;
}

.lesson-player-heading p {
  margin-top: 6px;
  font-size: 0.9rem;
  color: #6b7280;
}

.lesson-course-progress {
  height: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: #e8eef8;
}

.lesson-course-progress span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #247cf3, #18a058);
  transition: width 260ms ease;
}

.lesson-player-grid {
  grid-template-columns: minmax(250px, 0.78fr) minmax(460px, 1.45fr) minmax(260px, 0.77fr);
  gap: 14px;
  align-items: start !important;
}

.lesson-sequence-card,
.lesson-content-card,
.lesson-progress-card,
.lesson-focus-card,
.lesson-quick-tips {
  border-color: #d9e4f2;
  border-radius: 14px;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
}

.lesson-sequence-card {
  position: sticky !important;
  top: 80px !important;
  align-self: start !important;
  max-height: calc(100vh - 96px) !important;
  display: flex !important;
  flex-direction: column !important;
  overflow: hidden !important;
  z-index: 10;
}

.lesson-module-title {
  padding: 8px 18px 16px;
  flex-shrink: 0;
}

.lesson-module-title strong {
  font-size: 1.08rem;
  line-height: 1.18;
}

.lesson-sequence-top {
  padding: 10px 18px;
  font-size: 0.88rem;
  flex-shrink: 0;
}

.lesson-sequence-list:not(.netacad-sequence-list) {
  max-height: none;
  min-height: 0;
  gap: 8px;
  padding: 12px 14px 16px;
}

.lesson-sequence-list:not(.netacad-sequence-list) button {
  grid-template-columns: 30px 34px minmax(0, 1fr);
  padding: 12px 11px;
  min-height: 88px;
  border: 1px solid transparent;
}

.lesson-sequence-list:not(.netacad-sequence-list) button:hover {
  border-color: #cfe0f7;
}

.lesson-sequence-list:not(.netacad-sequence-list) button.active {
  border-color: #c9dcff;
  box-shadow: inset 3px 0 0 #247cf3;
}

.lesson-sequence-list:not(.netacad-sequence-list) button.complete b {
  background: #0bbf61;
}

.lesson-sequence-list:not(.netacad-sequence-list) strong {
  display: grid;
  gap: 2px;
  font-size: 0.82rem;
  line-height: 1.18;
}

.lesson-sequence-list:not(.netacad-sequence-list) strong small {
  color: #718096;
  font-size: 0.66rem;
  font-weight: 900;
  text-transform: uppercase;
}

.lesson-sequence-list:not(.netacad-sequence-list) em {
  margin-top: 0;
  font-size: 0.72rem;
  line-height: 1.15;
}

.lesson-content-card {
  padding: 18px;
  min-width: 0;
  animation: lessonContentIn 180ms ease;
}

@keyframes lessonContentIn {
  from {
    opacity: 0;
    transform: translateY(5px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.lesson-content-header {
  padding: 2px 2px 4px;
}

.lesson-content-header span {
  color: #247cf3;
  font-size: 0.78rem;
  text-transform: uppercase;
}

.lesson-content-header h2 {
  font-size: clamp(1.24rem, 1.35vw, 1.62rem);
  line-height: 1.15;
}

.lesson-content-header p {
  color: #596579;
  font-size: 0.94rem;
  font-weight: 650;
  line-height: 1.5;
}

.lesson-content-blocks,
.practice-panel {
  gap: 12px;
}

.lesson-content-block,
.practice-question {
  padding: 14px 16px;
  border-radius: 12px;
}

.practice-panel > .primary-button {
  position: sticky;
  bottom: 10px;
  z-index: 2;
  min-height: 54px;
  border-radius: 14px;
  box-shadow: 0 14px 28px rgba(31, 123, 242, 0.2);
}

.practice-panel > .primary-button:disabled {
  background: #e3ebf5;
  color: #64748b;
  box-shadow: none;
  cursor: not-allowed;
}

.lesson-content-block h3 {
  font-size: 0.98rem;
  line-height: 1.2;
}

.lesson-content-block p,
.lesson-content-block a {
  color: #263247;
  font-size: 0.93rem;
  font-weight: 600;
  line-height: 1.56;
}

.lesson-block-list {
  gap: 9px;
}

.lesson-block-list li {
  padding: 10px 12px 10px 38px;
  font-size: 0.9rem;
  font-weight: 650;
  line-height: 1.42;
}

.lesson-block-list.steps li {
  border-color: #cfe0fb;
  background: linear-gradient(180deg, #fff, #f8fbff);
}

.lesson-block-list.vocabulary {
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
}

.lesson-block-list.vocabulary li {
  padding-left: 12px;
}

.lesson-block-list.vocabulary li::before {
  display: none;
}

.lesson-content-block.safety_note {
  border-color: #fdba74;
  background: #fff8ed;
  box-shadow: inset 4px 0 0 #fb923c;
}

.lesson-content-block.summary {
  border-color: #bbf7d0;
  background: #f3fff7;
  box-shadow: inset 4px 0 0 #0bbf61;
}

.lesson-content-block.reflection,
.lesson-content-block.example {
  background: #f8fbff;
}

.lesson-tips-rail {
  position: sticky !important;
  top: 80px !important;
  align-self: start !important;
  max-height: calc(100vh - 96px) !important;
  display: flex !important;
  flex-direction: column !important;
  gap: 14px !important;
  overflow-y: auto !important;
  scrollbar-width: thin !important;
  scrollbar-color: #cbd5e1 transparent !important;
  z-index: 10;
}

.lesson-tips-rail::-webkit-scrollbar {
  width: 5px;
}

.lesson-tips-rail::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 4px;
}

.lesson-progress-card,
.lesson-focus-card,
.lesson-quick-tips {
  padding: 16px;
}

.lesson-focus-card {
  background: #fff;
}

.lesson-focus-card h2,
.lesson-progress-card h2,
.lesson-quick-tips h2 {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  font-size: 1rem;
}

.lesson-focus-card svg,
.lesson-quick-tips h2 svg {
  width: 19px;
  height: 19px;
  color: #247cf3;
}

.lesson-focus-card p {
  margin: 0;
  color: #4b5563;
  font-size: 0.88rem;
  font-weight: 650;
  line-height: 1.45;
}

.lesson-ring {
  width: 112px;
  height: 112px;
  margin-bottom: 14px;
}

.lesson-ring strong {
  font-size: 1.42rem;
}

.lesson-progress-facts {
  display: flex !important;
  flex-direction: column !important;
  gap: 8px !important;
}

.lesson-progress-facts div {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  padding: 10px 14px !important;
  border-radius: 8px !important;
  background: #f8fafc !important;
  border: 1px solid #edf2f7 !important;
}

.lesson-progress-facts strong {
  font-size: 0.94rem !important;
  font-weight: 800 !important;
  color: #0f172a !important;
}

.lesson-progress-facts span {
  max-width: none !important;
  font-size: 0.74rem !important;
  font-weight: 600 !important;
  color: #64748b !important;
  text-align: right !important;
}

.lesson-quick-tips article {
  padding: 10px;
  border-radius: 12px;
  background: #f8fbff;
}

.lesson-quick-tips p {
  color: #253148;
  font-size: 0.84rem;
  font-weight: 700;
  line-height: 1.35;
}

.practice-task-title span {
  display: block;
  margin-top: 2px;
  color: #4b5563;
  font-weight: 650;
  line-height: 1.38;
}

.practice-order-help {
  margin: 0;
  color: #5b677a;
  font-size: 0.86rem;
  font-weight: 700;
}

.practice-choice-grid label,
.practice-order-list span {
  transition: border-color 160ms ease, background 160ms ease, transform 160ms ease;
}

.practice-choice-grid label:has(input:checked) {
  border-color: #247cf3;
  background: #eaf2ff;
}

.practice-feedback {
  animation: lessonContentIn 180ms ease;
}


.lesson-player-heading {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  gap: 18px;
}

.lesson-player-top-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.lesson-player-top-actions .small-button {
  min-height: 38px;
  padding-inline: 14px;
  white-space: nowrap;
}

.lesson-player-top-actions .rail-toggle {
  border-color: #cfe0f7;
  color: #247cf3;
  background: #fff;
}

.lesson-player-top-actions .rail-toggle.active {
  border-color: #247cf3;
  background: #eaf2ff;
  color: #1d62c7;
}

.lesson-player-top-actions .lesson-exit-button {
  border-color: #d6e0ec;
  color: #0f172a;
  background: #fff;
}

.lesson-player-grid.sequence-collapsed {
  grid-template-columns: minmax(620px, 1.45fr) minmax(275px, 0.58fr);
}

.lesson-player-grid.tools-collapsed {
  grid-template-columns: minmax(260px, 0.64fr) minmax(640px, 1.48fr);
}

.lesson-player-grid.focus-mode {
  grid-template-columns: minmax(0, 1040px);
  justify-content: center;
}

.lesson-player-grid.focus-mode .lesson-content-card {
  width: 100%;
}

.lesson-panel-label {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 38px;
  margin: 12px 16px 0;
}

.lesson-sequence-card .lesson-module-title:first-child {
  padding-top: 16px;
}

.lesson-sequence-card .lesson-module-title {
  padding: 12px 16px 14px;
}

.lesson-sequence-card .lesson-type-icon {
  flex: 0 0 42px;
  width: 42px;
  height: 42px;
  border-radius: 12px;
}

.lesson-sequence-card .lesson-type-icon svg {
  width: 23px;
  height: 23px;
}

.lesson-sequence-card .lesson-module-title strong {
  font-size: 1rem;
}

.lesson-sequence-card .lesson-module-title small {
  font-size: 0.76rem;
}

.lesson-sequence-list {
  scrollbar-gutter: stable;
}

.lesson-player-grid.sequence-collapsed .lesson-content-card,
.lesson-player-grid.tools-collapsed .lesson-content-card,
.lesson-player-grid.focus-mode .lesson-content-card {
  min-height: min(620px, calc(100vh - 240px));
}

@media (max-width: 1024px) {
  .lesson-player-grid {
    grid-template-columns: minmax(240px, 0.75fr) minmax(420px, 1.25fr);
  }

  .lesson-player-grid.sequence-collapsed,
  .lesson-player-grid.focus-mode {
    grid-template-columns: minmax(0, 1fr);
  }

  .lesson-tips-rail {
    position: static !important;
    max-height: none !important;
    grid-column: 1 / -1;
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 980px) {
  .lesson-player-grid,
  .lesson-tips-rail {
    grid-template-columns: 1fr;
  }

  .lesson-preview-toolbar {
    align-items: flex-start;
    flex-direction: column;
  }

  .lesson-preview-toolbar div {
    justify-content: flex-start;
  }

  .lesson-player-heading {
    align-items: flex-start;
    flex-direction: column;
  }

  .lesson-player-heading {
    grid-template-columns: 1fr;
  }

  .lesson-player-top-actions {
    justify-content: flex-start;
    width: 100%;
  }

  .lesson-player-top-actions .small-button {
    flex: 1 1 150px;
  }

  .lesson-sequence-card,
  .lesson-tips-rail {
    position: static !important;
    max-height: none !important;
  }

  .lesson-author-tabs {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .feedback-modal-overlay {
    padding: 14px;
    align-items: center;
  }

  .feedback-modal {
    padding: 18px;
    gap: 12px;
    border-radius: 18px;
  }

  .feedback-modal-main {
    grid-template-columns: 46px minmax(0, 1fr);
    gap: 12px;
  }

  .feedback-modal-icon {
    width: 46px;
    height: 46px;
    border-radius: 14px;
  }

  .feedback-modal-icon svg {
    width: 24px;
    height: 24px;
  }

  .feedback-modal h2 {
    font-size: 20px;
  }

  .feedback-modal p {
    font-size: 14px;
    line-height: 1.35;
  }

  .feedback-modal-actions {
    grid-template-columns: 1fr;
  }

  .lesson-preview-panel,
  .lesson-player-drawer .lesson-preview-panel {
    width: 100%;
  }

  .lesson-content-card,
  .lesson-progress-card,
  .lesson-quick-tips {
    padding: 16px;
  }

  .lesson-sequence-list:not(.netacad-sequence-list) button {
    grid-template-columns: 32px minmax(0, 1fr);
  }

  .lesson-sequence-list:not(.netacad-sequence-list) span {
    display: none;
  }

  .lesson-sequence-list:not(.netacad-sequence-list) em {
    grid-column: auto;
  }

  .lesson-player-actions,
  .lesson-player-actions.single-action {
    display: flex !important;
    flex-wrap: wrap !important;
    justify-content: stretch !important;
    gap: 10px !important;
  }

  .lesson-player-actions .netacad-prev-btn,
  .lesson-player-actions .netacad-next-btn {
    flex: 1 1 180px !important;
    justify-content: center !important;
    min-height: 46px !important;
  }

  .assessment-review-list {
    max-height: 46vh;
  }
}

.assessment-metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 24px;
  margin-bottom: 18px;
}

.assessment-metric-card,
.assessment-library-card,
.assessment-insight-card {
  border: 1px solid #e1e6ef;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 8px 16px rgba(16, 24, 40, 0.12);
}

.assessment-metric-card {
  display: flex;
  align-items: center;
  gap: 18px;
  min-height: 132px;
  padding: 22px;
}

.assessment-metric-card p {
  margin: 0 0 8px;
  color: #0f172a;
  font-weight: 900;
}

.assessment-metric-card strong {
  display: block;
  color: #050b18;
  font-size: 2rem;
  line-height: 1;
}

.assessment-metric-card small {
  display: block;
  margin-top: 8px;
  color: #7a8290;
  font-weight: 800;
}

.assessment-metric-card small b {
  color: #1f7bf2;
}

.assessment-metric-icon {
  display: grid;
  place-items: center;
  width: 62px;
  height: 62px;
  border-radius: 18px;
  flex: 0 0 auto;
}

.assessment-metric-icon svg {
  width: 34px;
  height: 34px;
  stroke-width: 2.2;
}

.assessment-metric-icon.blue { background: #e9f2ff; color: #1f7bf2; }
.assessment-metric-icon.green { background: #e9fbf1; color: #09a957; }
.assessment-metric-icon.orange { background: #fff0df; color: #ff8b22; }
.assessment-metric-icon.purple { background: #f0e9ff; color: #6f3ff5; }

.assessment-library-card {
  padding: 18px;
  margin-bottom: 18px;
}

.assessment-library-header {
  display: grid;
  grid-template-columns: minmax(180px, 1fr) minmax(0, 1.8fr);
  gap: 18px;
  align-items: center;
  margin-bottom: 14px;
}

.assessment-library-header h1 {
  margin: 0;
  color: #050b18;
  font-size: 1.35rem;
}

.assessment-toolbar {
  display: grid;
  grid-template-columns: minmax(130px, 0.8fr) minmax(120px, 0.75fr) minmax(130px, 0.75fr) minmax(220px, 1.3fr);
  gap: 12px;
}

.assessment-toolbar select,
.assessment-search {
  height: 48px;
  border: 1px solid #d9dfeb;
  border-radius: 10px;
  background: #fff;
  color: #172033;
  font-weight: 700;
}

.assessment-toolbar select {
  padding: 0 14px;
}

.assessment-search {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 42px;
  align-items: center;
  padding-left: 14px;
}

.assessment-search input {
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: #172033;
  font: inherit;
}

.assessment-search svg {
  width: 22px;
  height: 22px;
  color: #172033;
}

.assessment-table-wrap {
  overflow-x: auto;
  border: 1px solid #e6ebf3;
  border-radius: 14px;
}

.assessment-table {
  width: 100%;
  min-width: 1120px;
  border-collapse: collapse;
}

.assessment-table th,
.assessment-table td {
  padding: 14px 16px;
  border-bottom: 1px solid #e6ebf3;
  text-align: left;
  vertical-align: middle;
}

.assessment-table tr:last-child td {
  border-bottom: 0;
}

.assessment-table th {
  color: #273348;
  background: #fbfcff;
  font-size: 0.82rem;
  font-weight: 900;
}

.assessment-title-cell {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 260px;
}

.assessment-title-cell strong,
.assessment-title-cell small {
  display: block;
}

.assessment-title-cell strong {
  color: #071225;
  font-weight: 900;
  line-height: 1.18;
}

.assessment-title-cell small {
  margin-top: 4px;
  color: #778092;
  font-weight: 800;
}

.assessment-row-icon {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 8px;
  flex: 0 0 auto;
}

.assessment-row-icon.green { background: #e9fbf1; color: #09a957; }
.assessment-row-icon.purple { background: #f0e9ff; color: #6f3ff5; }

.assessment-type-pill,
.time-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 30px;
  padding: 6px 12px;
  border-radius: 8px;
  font-size: 0.78rem;
  font-weight: 900;
}

.assessment-type-pill.practice { background: #e9fbf1; color: #07984e; }
.assessment-type-pill.assessment { background: #f0e9ff; color: #5b2bea; }
.time-pill { background: #eef5ff; color: #1f7bf2; }

.assessment-actions {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}

.score-good { color: #09a957; }
.score-warn { color: #ff8b22; }
.score-low { color: #d93245; }
.muted-score { color: #8b94a5; }
.status-pill.scheduled { background: #e9f2ff; color: #1f7bf2; }

.assessment-table-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 2px 0;
  color: #172033;
  font-weight: 700;
}

.assessment-empty-state {
  display: grid;
  justify-items: center;
  gap: 10px;
  padding: 34px 16px;
  color: #697386;
  text-align: center;
}

.assessment-empty-state svg {
  width: 44px;
  height: 44px;
  color: #1f7bf2;
}

.assessment-empty-state strong {
  color: #071225;
  font-size: 1.1rem;
}

.assessment-insight-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(340px, 0.9fr);
  gap: 18px;
}

.assessment-insight-card {
  padding: 18px;
  min-width: 0;
}

.assessment-insight-card h2 {
  margin: 0;
  color: #050b18;
  font-size: 1.16rem;
}

.assessment-bar-chart {
  display: grid;
  grid-template-columns: repeat(6, minmax(70px, 1fr));
  gap: 18px;
  min-height: 230px;
  align-items: end;
  padding-top: 20px;
}

.assessment-bar-chart article {
  display: grid;
  justify-items: center;
  gap: 8px;
  min-width: 0;
}

.assessment-bar-track {
  display: flex;
  align-items: flex-end;
  width: 54px;
  height: 150px;
  border-radius: 8px 8px 4px 4px;
  background: #eef3fb;
  overflow: hidden;
}

.assessment-bar-track span {
  display: block;
  width: 100%;
  min-height: 4px;
  border-radius: 8px 8px 0 0;
  background: linear-gradient(180deg, #1f7bf2, #0d63d8);
}

.assessment-bar-chart strong {
  color: #071225;
  font-weight: 900;
}

.assessment-bar-chart small {
  max-width: 90px;
  color: #536076;
  font-size: 0.72rem;
  font-weight: 800;
  line-height: 1.15;
  text-align: center;
}

.assessment-submission-list {
  display: grid;
  gap: 10px;
}

.assessment-submission-list button {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  width: 100%;
  border: 0;
  border-radius: 12px;
  background: #fff;
  padding: 10px;
  color: #071225;
  text-align: left;
  cursor: pointer;
}

.assessment-submission-list button:hover {
  background: #f4f8ff;
}

.assessment-submission-list button > span {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  color: #1f7bf2;
}

.assessment-submission-list strong,
.assessment-submission-list small {
  display: block;
}

.assessment-submission-list small {
  color: #777f8d;
  font-weight: 700;
}

.assessment-results-panel {
  width: min(620px, 100%);
}

.assessment-results-content {
  display: grid;
  gap: 14px;
}

.assessment-result-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.assessment-result-summary div {
  border: 1px solid #e1e8f4;
  border-radius: 12px;
  background: #f8fbff;
  padding: 12px;
}

.assessment-result-summary span,
.assessment-result-meta span {
  display: block;
  color: #697386;
  font-weight: 800;
}

.assessment-result-summary strong {
  display: block;
  margin-top: 5px;
  color: #071225;
  font-size: 1.25rem;
}

.assessment-result-meta {
  border: 1px solid #e1e8f4;
  border-radius: 12px;
  padding: 12px;
}

.assessment-result-meta strong {
  display: block;
  color: #071225;
}

.assessment-student-results {
  display: grid;
  gap: 10px;
}

.assessment-student-result {
  border: 1px solid #e1e8f4;
  border-radius: 12px;
  background: #fff;
}

.assessment-student-result.missing,
.assessment-student-result summary {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  padding: 12px;
}

.assessment-student-result summary {
  cursor: pointer;
  list-style: none;
}

.assessment-student-result summary::-webkit-details-marker {
  display: none;
}

.assessment-student-result strong,
.assessment-student-result span {
  display: block;
}

.assessment-student-result span {
  color: #697386;
  font-weight: 700;
}

.assessment-student-result > b,
.assessment-student-result summary b {
  font-weight: 900;
}

.assessment-student-result.missing {
  background: #fbfcff;
}

.assessment-student-result.missing > b {
  color: #8b94a5;
}

.assessment-attempt-detail {
  display: grid;
  gap: 8px;
  padding: 0 12px 12px 66px;
}

.assessment-attempt-detail article {
  border-radius: 10px;
  padding: 10px;
}

.assessment-attempt-detail article.correct { background: #effbf5; }
.assessment-attempt-detail article.incorrect { background: #fff4f2; }

.assessment-attempt-detail p {
  margin: 8px 0 0;
  color: #2c3648;
  font-weight: 700;
}

.reports-header {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) minmax(520px, 0.95fr);
  gap: 18px;
  align-items: end;
  margin-bottom: 18px;
}

.reports-header h1,
.reports-header p,
.report-download-panel h2,
.report-download-panel p {
  margin: 0;
}

.reports-header h1 {
  color: #050b18;
  font-size: 1.6rem;
  font-weight: 900;
}

.reports-header p,
.report-download-panel p {
  margin-top: 6px;
  color: #536076;
  font-weight: 700;
}

.reports-toolbar {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  padding: 14px;
  border: 1px solid #e1e6ef;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 8px 16px rgba(16, 24, 40, 0.08);
}

.reports-toolbar label {
  display: grid;
  gap: 6px;
  color: #667085;
  font-size: 0.74rem;
  font-weight: 900;
  text-transform: uppercase;
}

.reports-toolbar input,
.reports-toolbar select {
  width: 100%;
  min-width: 0;
  height: 42px;
  border: 1px solid #d9dfeb;
  border-radius: 10px;
  background: #fff;
  color: #172033;
  padding: 0 12px;
  font: inherit;
  font-weight: 800;
}

.report-metric-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 18px;
}

.report-metric-card,
.report-card,
.report-mini-panel {
  border: 1px solid #e1e6ef;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 8px 16px rgba(16, 24, 40, 0.12);
}

.report-metric-card {
  display: flex;
  align-items: center;
  gap: 16px;
  min-height: 118px;
  padding: 18px 20px;
}

.report-metric-card p {
  margin: 0 0 7px;
  color: #0f172a;
  font-size: 0.96rem;
  font-weight: 900;
  line-height: 1.25;
}

.report-metric-card strong {
  display: block;
  color: #050b18;
  font-size: 2rem;
  line-height: 1;
}

.report-metric-card small {
  display: block;
  max-width: 210px;
  margin-top: 7px;
  color: #7a8290;
  font-size: 0.78rem;
  font-weight: 800;
  line-height: 1.35;
}

.report-metric-icon,
.report-download-icon {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 18px;
}

.report-metric-icon {
  width: 56px;
  height: 56px;
}

.report-metric-icon svg {
  width: 29px;
  height: 29px;
  stroke-width: 2.2;
}

.report-metric-icon.blue,
.report-download-icon.blue { background: #e9f2ff; color: #1f7bf2; }
.report-metric-icon.green,
.report-download-icon.green { background: #e9fbf1; color: #09a957; }
.report-metric-icon.purple,
.report-download-icon.purple { background: #f0e9ff; color: #6f3ff5; }
.report-metric-icon.orange { background: #fff3e8; color: #f97316; }
.report-metric-icon.red { background: #fff1f3; color: #e11d48; }
.report-metric-icon.silver { background: #eef1f5; color: #8b95a4; }

.report-dashboard-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  margin-bottom: 18px;
}

.report-completion-dashboard {
  margin: 0 0 18px;
  padding: 18px;
  border: 1px solid #e1e6ef;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 8px 16px rgba(16, 24, 40, 0.12);
}

.report-completion-dashboard .dashboard-page-header {
  margin-bottom: 14px;
}

.report-completion-dashboard .dashboard-page-header h1 {
  margin: 4px 0;
  color: #050b18;
  font-size: 1.5rem;
  line-height: 1.1;
}

.report-completion-dashboard .dashboard-page-header p {
  color: #536076;
  font-size: 13px;
  font-weight: 800;
}

.completion-overview-row,
.completion-breakdown-row {
  display: grid;
  gap: 12px;
  margin-bottom: 14px;
}

.completion-overview-row {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.completion-overview-card {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
  min-height: 92px;
  padding: 16px;
  border: 1px solid #e1e8f3;
  border-radius: 14px;
  background: #f9fbff;
}

.completion-overview-card p,
.completion-overview-card strong,
.completion-overview-card small {
  display: block;
  margin: 0;
}

.completion-overview-card p {
  color: #667085;
  font-size: 13px;
  font-weight: 900;
}

.completion-overview-card strong {
  margin-top: 4px;
  color: #050b18;
  font-size: 1.8rem;
  line-height: 1;
}

.completion-overview-card small {
  margin-top: 5px;
  color: #737b89;
  font-size: 12px;
  font-weight: 800;
}

.completion-breakdown-row {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.completion-breakdown-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 8px;
  align-items: center;
  min-height: 48px;
  padding: 10px 12px;
  border: 1px solid #e1e8f3;
  border-radius: 12px;
  background: #fff;
}

.completion-breakdown-item span,
.completion-breakdown-item small {
  color: #667085;
  font-size: 12px;
  font-weight: 900;
}

.completion-breakdown-item strong {
  color: #071225;
  font-size: 18px;
  line-height: 1;
}

.completion-breakdown-item.green { border-color: #c7efd7; background: #f1fbf5; }
.completion-breakdown-item.blue { border-color: #cfe0ff; background: #f4f8ff; }
.completion-breakdown-item.orange { border-color: #fed7aa; background: #fff7ed; }
.completion-breakdown-item.red { border-color: #fecdd3; background: #fff1f3; }

.report-completion-card {
  padding: 14px;
  border-radius: 14px;
  box-shadow: none;
}

.report-completion-dashboard .leaderboard-toolbar {
  align-items: end;
  gap: 12px;
  margin-bottom: 14px;
}

.completion-filter-context {
  display: grid;
  gap: 3px;
  min-width: min(100%, 300px);
  margin-right: auto;
}

.completion-filter-context strong {
  color: #071225;
  font-weight: 900;
}

.completion-filter-context span {
  color: #667085;
  font-size: 12px;
  font-weight: 800;
}

@media (max-width: 1280px) {
  .report-metric-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 1180px) {
  .completion-overview-row,
  .completion-breakdown-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  .report-metric-grid,
  .completion-overview-row,
  .completion-breakdown-row,
  .completion-breakdown-item {
    grid-template-columns: 1fr;
  }
}

.report-support-panel {
  margin-bottom: 18px;
}

.report-support-panel .panel-title-row p {
  margin: 4px 0 0;
  color: #737b89;
  font-size: 13px;
  font-weight: 800;
}

.report-support-list {
  margin-top: 14px;
  display: grid;
  gap: 10px;
}

.report-support-list > button {
  width: 100%;
  border: 1px solid #e1e8f3;
  border-radius: 14px;
  background: #f9fbff;
  padding: 12px;
  display: grid;
  grid-template-columns: 42px minmax(160px, 1fr) minmax(180px, 0.8fr) 64px;
  gap: 12px;
  align-items: center;
  text-align: left;
  cursor: pointer;
}

.report-support-list > button:hover {
  border-color: #1f7bf2;
  box-shadow: 0 10px 20px rgba(31, 123, 242, 0.1);
}

.report-support-avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: #e9f2ff;
  color: #1f5fbf;
  display: grid;
  place-items: center;
  font-weight: 900;
}

.report-support-main {
  display: grid;
  gap: 2px;
}

.report-support-main strong {
  color: #101828;
  font-weight: 900;
}

.report-support-main small,
.report-support-reason {
  color: #667085;
  font-size: 12px;
  font-weight: 800;
}

.report-support-reason {
  padding: 7px 10px;
  border-radius: 999px;
  background: #fff4e6;
  color: #b45309;
  text-align: center;
}

.report-support-score {
  justify-self: end;
  color: #172033;
  font-size: 18px;
  font-weight: 900;
}

.report-support-empty {
  min-height: 112px;
  border: 1px dashed #cfd8e7;
  border-radius: 14px;
  background: #f8fbff;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 6px;
  text-align: center;
}

.report-support-empty svg {
  width: 30px;
  height: 30px;
  color: #09a957;
}

.report-support-empty span {
  color: #667085;
  font-size: 13px;
  font-weight: 800;
}

.report-weak-panel {
  margin-bottom: 18px;
}

.report-weak-panel .panel-title-row p {
  margin: 4px 0 0;
  color: #536076;
  font-size: 13px;
  font-weight: 800;
}

.report-weak-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-top: 14px;
}

.weak-analysis-card,
.student-weak-card {
  min-width: 0;
  border: 1px solid #dfe7f3;
  border-radius: 14px;
  background: #fff;
  padding: 16px;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.06);
}

.weak-card-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.weak-card-heading h3,
.weak-card-heading p {
  margin: 0;
}

.weak-card-heading h3 {
  color: #071225;
  font-size: 15px;
  font-weight: 900;
}

.weak-card-heading p {
  margin-top: 3px;
  color: #58667a;
  font-size: 12px;
  font-weight: 800;
}

.weak-card-heading > i,
.weak-card-heading > svg {
  width: 24px;
  height: 24px;
  color: #1f7bf2;
  flex: 0 0 auto;
}

.weak-progress-list,
.missed-topic-list,
.intervention-list,
.root-cause-list,
.profile-intervention-list {
  display: grid;
  gap: 10px;
}

.weak-progress-row {
  display: grid;
  gap: 6px;
}

.weak-progress-row div:first-child {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  color: #172033;
  font-size: 12px;
  font-weight: 900;
}

.weak-progress-row b {
  white-space: nowrap;
}

.weak-progress-row small {
  color: #667085;
  font-size: 11px;
  font-weight: 800;
}

.weak-progress-track {
  height: 8px;
  border-radius: 999px;
  background: #e9eef6;
  overflow: hidden;
}

.weak-progress-track i {
  display: block;
  height: 100%;
  min-width: 4px;
  border-radius: inherit;
}

.weak-progress-row.critical .weak-progress-track i,
.weak-legend b.critical {
  background: #ef4444;
}

.missed-topic-list strong.critical {
  color: #dc2626;
}

.weak-progress-row.attention .weak-progress-track i,
.weak-legend b.attention {
  background: #f97316;
}

.missed-topic-list strong.attention {
  color: #ea580c;
}

.weak-progress-row.improving .weak-progress-track i,
.weak-legend b.improving {
  background: #10b981;
}

.missed-topic-list strong.improving {
  color: #059669;
}

.weak-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
  margin-top: 14px;
}

.weak-legend span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #667085;
  font-size: 10px;
  font-weight: 800;
}

.weak-legend b {
  width: 9px;
  height: 9px;
  border-radius: 50%;
}

.missed-topic-list div {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  min-height: 30px;
  border-bottom: 1px solid #edf2f8;
}

.missed-topic-list div:last-child {
  border-bottom: 0;
}

.missed-topic-list span {
  color: #172033;
  font-size: 12px;
  font-weight: 800;
}

.missed-topic-list strong {
  font-size: 12px;
  font-weight: 900;
}

.intervention-list article,
.root-cause-list article {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  min-height: 58px;
  border: 1px solid #e4ebf5;
  border-radius: 12px;
  padding: 10px;
  background: #fbfdff;
}

.intervention-list span,
.root-cause-list span {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  display: grid;
  place-items: center;
}

.intervention-list svg,
.root-cause-list svg {
  width: 20px;
  height: 20px;
}

.intervention-list strong,
.root-cause-list strong,
.profile-intervention-list strong {
  display: block;
  color: #101828;
  font-size: 12px;
  font-weight: 900;
}

.intervention-list small,
.root-cause-list small,
.profile-intervention-list small {
  display: block;
  margin-top: 2px;
  color: #536076;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.25;
}

.intervention-list article.red span,
.root-cause-list article.red span { background: #fee2e2; color: #ef4444; }
.intervention-list article.orange span,
.root-cause-list article.orange span { background: #fff3e8; color: #f97316; }
.intervention-list article.green span,
.root-cause-list article.green span { background: #e9fbf1; color: #09a957; }
.intervention-list article.blue span,
.root-cause-list article.blue span { background: #e9f2ff; color: #1f7bf2; }
.intervention-list article.purple span,
.root-cause-list article.purple span { background: #f0e9ff; color: #7c3aed; }
.intervention-list article.slate span,
.root-cause-list article.slate span { background: #eef2f7; color: #64748b; }

.weak-empty {
  min-height: 92px;
  display: grid;
  place-items: center;
  margin: 0;
  border: 1px dashed #d7e0ee;
  border-radius: 12px;
  color: #667085;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.35;
  text-align: center;
  padding: 14px;
}

.student-weak-panel .student-weak-card {
  padding: 12px;
  box-shadow: none;
}

.student-weak-panel .weak-card-heading {
  margin-bottom: 10px;
}

.student-weak-panel .weak-progress-list,
.student-weak-panel .root-cause-list,
.student-weak-panel .profile-intervention-list {
  gap: 8px;
}

.student-weak-panel .root-cause-list article {
  grid-template-columns: 34px minmax(0, 1fr);
  min-height: 52px;
  padding: 8px;
}

.student-weak-panel .root-cause-list span {
  width: 34px;
  height: 34px;
}

.student-weak-panel .root-cause-list svg {
  width: 18px;
  height: 18px;
}

.student-weak-panel .weak-empty {
  min-height: 72px;
  padding: 10px;
}

.report-support-table {
  display: grid;
  gap: 0;
  overflow-x: auto;
}

.report-support-head,
.report-support-row {
  display: grid;
  grid-template-columns: minmax(180px, 1.2fr) 110px minmax(190px, 1fr) minmax(220px, 1.25fr) minmax(190px, 1fr) 112px;
  gap: 12px;
  align-items: center;
  min-width: 980px;
}

.report-support-head {
  padding: 0 12px 10px;
  color: #58667a;
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.report-support-row {
  border: 1px solid #e4ebf5;
  border-radius: 12px;
  background: #fff;
  padding: 12px;
  margin-bottom: 8px;
}

.report-support-student,
.support-action-button {
  border: 0;
  background: transparent;
  font: inherit;
  cursor: pointer;
}

.report-support-student {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  min-width: 0;
  text-align: left;
}

.report-support-student:hover strong {
  color: #1f7bf2;
}

.risk-score-ring {
  --risk: 0%;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  justify-self: center;
  background: conic-gradient(#1f7bf2 var(--risk), #e8edf5 0);
  position: relative;
}

.risk-score-ring::after {
  content: "";
  position: absolute;
  inset: 6px;
  border-radius: 50%;
  background: #fff;
}

.risk-score-ring b {
  position: relative;
  z-index: 1;
  color: #111827;
  font-size: 12px;
  font-weight: 900;
}

.risk-score-ring.critical { background: conic-gradient(#ef4444 var(--risk), #e8edf5 0); }
.risk-score-ring.high { background: conic-gradient(#f97316 var(--risk), #e8edf5 0); }
.risk-score-ring.medium { background: conic-gradient(#facc15 var(--risk), #e8edf5 0); }
.risk-score-ring.low { background: conic-gradient(#10b981 var(--risk), #e8edf5 0); }

.support-reason-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.support-reason-stack em,
.profile-support-chips span {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  border-radius: 999px;
  padding: 4px 8px;
  font-size: 10px;
  font-style: normal;
  font-weight: 900;
  line-height: 1.1;
}

.support-reason-stack em.red,
.profile-support-chips span.red { background: #fee2e2; color: #dc2626; }
.support-reason-stack em.orange,
.profile-support-chips span.orange { background: #fff3e8; color: #c2410c; }
.support-reason-stack em.slate,
.profile-support-chips span.slate { background: #eef2f7; color: #475569; }

.support-diagnosis {
  color: #344054;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.35;
}

.support-action-button {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  gap: 7px;
  min-height: 38px;
  border: 1px solid #bdd4ff;
  border-radius: 10px;
  background: #f8fbff;
  color: #0d63d8;
  font-weight: 900;
}

.support-action-button svg {
  width: 16px;
  height: 16px;
}

.support-action-button:hover {
  border-color: #1f7bf2;
  background: #eef4ff;
}

.risk-level-pill {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  min-height: 28px;
  border-radius: 999px;
  padding: 5px 10px;
  font-size: 11px;
  font-weight: 900;
}

.risk-level-pill.critical { background: #fee2e2; color: #dc2626; }
.risk-level-pill.high { background: #ffedd5; color: #c2410c; }
.risk-level-pill.medium { background: #fef3c7; color: #b45309; }
.risk-level-pill.low { background: #dff8ea; color: #087f4b; }

.report-risk-note {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin: 12px 0 0;
  color: #667085;
  font-size: 12px;
  font-weight: 800;
}

.report-risk-note svg {
  width: 16px;
  height: 16px;
}

@media (max-width: 1120px) {
  .report-support-list > button {
    grid-template-columns: 42px minmax(0, 1fr);
  }

  .report-support-reason,
  .report-support-score {
    grid-column: 2;
    justify-self: start;
  }
}

.report-card {
  padding: 18px;
  min-width: 0;
}

.report-card h2,
.report-mini-panel h2 {
  margin: 0;
  color: #050b18;
  font-size: 1.16rem;
}

.report-chart-key {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #737b89;
  font-weight: 900;
}

.report-chart-key b {
  width: 28px;
  height: 4px;
  border-radius: 999px;
  background: #1f7bf2;
}

.report-line-chart {
  min-height: 320px;
  margin-top: 16px;
}

.report-line-chart svg {
  display: block;
  width: 100%;
  height: auto;
  min-height: 300px;
}

.report-grid-lines line {
  stroke: #dfe5ee;
  stroke-width: 1;
}

.report-grid-lines text,
.report-axis-label {
  fill: #7b8493;
  font-size: 13px;
  font-weight: 800;
}

.report-area {
  fill: rgba(31, 123, 242, 0.18);
}

.report-line {
  fill: none;
  stroke: #1f7bf2;
  stroke-width: 5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.report-point circle {
  fill: #1f7bf2;
  stroke: #fff;
  stroke-width: 4;
}

.report-point text {
  fill: #687386;
  font-size: 14px;
  font-weight: 900;
  text-anchor: middle;
}

.report-split-card {
  display: grid;
  grid-template-columns: repeat(2, minmax(320px, 1fr));
  gap: 14px;
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.report-mini-panel {
  padding: 16px;
  min-width: 0;
}

.report-topic-chart {
  display: grid;
  grid-template-columns: repeat(4, minmax(62px, 1fr));
  gap: 14px;
  min-height: 250px;
  align-items: end;
  padding-top: 18px;
}

.report-topic-chart article {
  display: grid;
  justify-items: center;
  gap: 8px;
  min-width: 0;
}

.report-topic-bar {
  display: flex;
  align-items: flex-end;
  width: 48px;
  height: 150px;
  border-radius: 8px 8px 4px 4px;
  background: #eef3fb;
  overflow: hidden;
}

.report-topic-bar span {
  display: block;
  width: 100%;
  min-height: 4px;
  border-radius: 8px 8px 0 0;
  background: linear-gradient(180deg, #1f7bf2, #0d63d8);
}

.report-topic-chart strong,
.report-topic-chart small {
  text-align: center;
}

.report-topic-chart small {
  max-width: 82px;
  color: #536076;
  font-size: 0.7rem;
  font-weight: 800;
  line-height: 1.15;
}

.report-topic-chart .empty-text {
  grid-column: 1 / -1;
  align-self: center;
  justify-self: center;
  max-width: 220px;
  color: #697386;
  font-weight: 800;
  line-height: 1.35;
  text-align: center;
}

.report-distribution-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 18px;
  align-items: center;
  justify-items: center;
  min-height: 0;
  padding: 16px 0 4px;
}

.report-donut {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 156px;
  height: 156px;
  border-radius: 50%;
}

.report-donut::after {
  content: "";
  position: absolute;
  width: 78px;
  height: 78px;
  border-radius: 50%;
  background: #fff;
}

.report-donut strong,
.report-donut span {
  position: relative;
  z-index: 1;
  display: block;
  margin: 0;
  text-align: center;
}

.report-donut strong {
  color: #050b18;
  font-size: 1.45rem;
  line-height: 1.05;
}

.report-donut span {
  color: #667085;
  font-size: 0.72rem;
  font-weight: 800;
  line-height: 1.1;
}

.report-donut-legend {
  display: grid;
  gap: 10px;
  width: 100%;
  margin-top: 2px;
}

.report-donut-legend span {
  display: grid;
  grid-template-columns: 12px minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
  min-width: 0;
  color: #172033;
  font-size: 0.82rem;
  font-weight: 800;
}

.report-donut-legend b {
  width: 10px;
  height: 10px;
  border-radius: 999px;
}

.report-donut-legend strong {
  color: #050b18;
  white-space: nowrap;
}

.report-donut-legend small {
  display: none;
}

.report-download-panel {
  display: grid;
  gap: 18px;
  padding: 22px;
}

.report-download-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.report-download-grid article {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  min-height: 126px;
  border: 1px solid #e1e7f0;
  border-radius: 16px;
  padding: 16px;
}

.report-download-icon {
  width: 58px;
  height: 58px;
}

.report-download-icon svg {
  width: 32px;
  height: 32px;
}

.report-download-grid strong,
.report-download-grid small {
  display: block;
}

.report-download-grid strong {
  color: #050b18;
  font-size: 1.05rem;
  font-weight: 900;
}

.report-download-grid small {
  margin-top: 6px;
  color: #536076;
  font-weight: 700;
}

.report-download-actions {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.report-download-actions button {
  min-width: 54px;
  height: 38px;
  border: 1px solid #1f7bf2;
  border-radius: 10px;
  background: #fff;
  color: #1f7bf2;
  font: inherit;
  font-weight: 900;
  cursor: pointer;
}

.report-download-actions button:first-child {
  background: #1f7bf2;
  color: #fff;
}

.report-download-actions button.preferred {
  outline: 3px solid rgba(31, 123, 242, 0.18);
  box-shadow: 0 5px 12px rgba(31, 123, 242, 0.16);
}

body[data-page="teacher"] .report-download-actions button {
  border-color: #bdd4ff;
  background: #fff;
  color: var(--primary-blue);
  box-shadow: none;
}

body[data-page="teacher"] .report-download-actions button:hover {
  border-color: var(--primary-blue);
  background: #eef4ff;
  color: var(--primary-blue-hover);
}

body[data-page="teacher"] .report-download-actions button:first-child,
body[data-page="teacher"] .report-download-actions button.preferred {
  border-color: var(--primary-blue);
  background: var(--primary-blue);
  color: #fff;
}

body[data-page="teacher"] .report-download-actions button:first-child:hover,
body[data-page="teacher"] .report-download-actions button.preferred:hover {
  background: var(--primary-blue-hover);
  color: #fff;
}

body[data-page="teacher"] .report-download-actions button:disabled {
  border-color: #d8e2f0;
  background: #e8eef8;
  color: #667085;
  cursor: not-allowed;
  opacity: 1;
}

.report-empty-state {
  display: grid;
  justify-items: center;
  gap: 10px;
  min-height: 280px;
  align-content: center;
  color: #697386;
  text-align: center;
}

.report-empty-state svg {
  width: 44px;
  height: 44px;
  color: #1f7bf2;
}

.report-empty-state strong {
  color: #071225;
  font-size: 1.1rem;
}

@media (max-width: 1500px) {
  .assessment-metric-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .assessment-library-header,
  .assessment-insight-grid,
  .reports-header,
  .report-dashboard-grid {
    grid-template-columns: 1fr;
  }

  .report-metric-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .report-weak-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .report-download-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 980px) {
  .evidence-toolbar {
    grid-template-columns: 1fr;
  }

  .evidence-quarter-pill,
  .evidence-export-actions {
    width: 100%;
  }

  .evidence-export-actions button {
    flex: 1;
  }

  .assessment-toolbar {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .assessment-bar-chart,
  .report-topic-chart,
  .reports-toolbar {
    grid-template-columns: repeat(3, minmax(70px, 1fr));
  }

  .report-split-card {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 680px) {
  .assessment-metric-grid,
  .evidence-metric-grid,
  .evidence-active-summary,
  .assessment-toolbar,
  .assessment-result-summary,
  .report-metric-grid,
  .report-weak-grid,
  .reports-toolbar,
  .report-download-grid article,
  .report-distribution-layout {
    grid-template-columns: 1fr;
  }

  .assessment-table-footer {
    align-items: flex-start;
    flex-direction: column;
  }

  .assessment-bar-chart,
  .report-topic-chart {
    grid-template-columns: repeat(2, minmax(70px, 1fr));
  }

  .capstone-evidence-panel,
  .evidence-card {
    padding: 16px;
  }

  .evidence-mastery-list article,
  .evidence-intervention-list article {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .evidence-mastery-list b,
  .evidence-intervention-list b {
    grid-column: 2;
    justify-self: start;
  }

  .evidence-growth-score {
    grid-template-columns: 1fr;
  }

  .evidence-growth-score svg {
    justify-self: center;
    transform: rotate(90deg);
  }

  .assessment-attempt-detail {
    padding-left: 12px;
  }

  .report-download-actions {
    justify-content: stretch;
  }

  .report-download-actions button {
    flex: 1;
  }
}

.calendar-event-list {
  display: grid;
  gap: 10px;
}

.calendar-event-list article {
  display: grid;
  grid-template-columns: 10px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  padding: 10px;
  border: 1px solid #e3eaf4;
  border-radius: 12px;
}

.calendar-event-list article > span {
  width: 10px;
  height: 10px;
  border-radius: 999px;
}

@media (max-width: 1780px) {
  .lesson-dashboard-grid {
    grid-template-columns: 1fr;
  }

  .lesson-side-rail {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    align-items: stretch;
  }

  .lesson-drop-zone {
    min-height: 132px;
  }
}

@media (max-width: 1280px) {
  .lesson-metric-grid,
  .lesson-side-rail {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .lesson-toolbar {
    grid-template-columns: 1fr 1fr;
  }

  .lesson-table-heading {
    display: none;
  }

  .lesson-row {
    grid-template-columns: 1fr 1fr;
    align-items: start;
  }

  .lesson-actions {
    justify-content: flex-start;
    grid-column: 1 / -1;
  }
}

@media (max-width: 980px) {
  .lesson-metric-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .lesson-metric-grid,
  .lesson-side-rail,
  .lesson-toolbar,
  .lesson-row {
    grid-template-columns: 1fr;
  }

  .lesson-table-footer {
    align-items: flex-start;
    flex-direction: column;
  }

  .lesson-actions {
    flex-wrap: wrap;
  }
}

/* Student dashboard fit and progress reference alignment */
@media (min-width: 841px) {
  body[data-page="student"] .app-shell {
    grid-template-columns: clamp(104px, 8.6vw, 152px) minmax(0, 1fr);
  }

  body[data-page="student"] .app-sidebar {
    padding: clamp(10px, 1.1vh, 16px) 8px;
    gap: clamp(5px, 0.7vh, 9px);
  }

  body[data-page="student"] .nav-item {
    border-radius: 12px;
    gap: 3px;
    font-size: clamp(10px, 0.78vw, 12.5px);
  }

  body[data-page="student"] .nav-item svg {
    width: clamp(20px, 1.55vw, 26px);
    height: clamp(20px, 1.55vw, 26px);
  }

  body[data-page="student"] .app-topbar {
    min-height: clamp(62px, 6.4vh, 82px);
    padding: 8px clamp(18px, 2.1vw, 30px);
  }

  body[data-page="student"] .compact-brand {
    font-size: clamp(24px, 2.05vw, 36px);
  }

  body[data-page="student"] .topbar-profile {
    gap: clamp(8px, 0.9vw, 12px);
  }

  body[data-page="student"] .topbar-profile > svg {
    width: clamp(21px, 1.55vw, 28px);
    height: clamp(21px, 1.55vw, 28px);
  }

  body[data-page="student"] .topbar-profile strong {
    font-size: clamp(15px, 1.25vw, 21px);
  }

  body[data-page="student"] .topbar-profile span {
    font-size: clamp(11px, 0.9vw, 15px);
  }

  body[data-page="student"] .profile-badge {
    width: clamp(44px, 3.9vw, 58px);
    height: clamp(44px, 3.9vw, 58px);
  }

  body[data-page="student"] .profile-badge svg {
    width: clamp(28px, 2.4vw, 38px);
    height: clamp(28px, 2.4vw, 38px);
  }

  body[data-page="student"] .student-section {
    padding: clamp(12px, 1.6vh, 22px) clamp(16px, 2vw, 28px) 12px;
  }

  body[data-page="student"] .section-heading {
    margin-bottom: clamp(12px, 1.5vh, 18px);
  }

  body[data-page="student"] .section-heading h1 {
    font-size: clamp(24px, 2vw, 34px);
  }

  body[data-page="student"] .section-heading p {
    max-width: 720px;
    font-size: 13px;
    line-height: 1.35;
  }

  body[data-page="student"] .student-hero-row {
    grid-template-columns: minmax(0, 1fr) minmax(340px, 0.62fr);
    gap: 14px;
    margin-bottom: 14px;
  }

  body[data-page="student"] .welcome-block {
    min-height: 136px;
    padding: 22px 24px;
  }

  body[data-page="student"] .welcome-block h1 {
    font-size: clamp(25px, 2.25vw, 36px);
  }

  body[data-page="student"] .welcome-block p {
    margin-top: 8px;
    font-size: 13px;
  }

  body[data-page="student"] .achievement-strip {
    padding: 16px;
    gap: 8px;
  }

  body[data-page="student"] .achievement-strip svg {
    width: 36px;
    height: 36px;
  }

  body[data-page="student"] .achievement-strip strong {
    font-size: 16px;
  }

  body[data-page="student"] .achievement-strip span {
    font-size: 11px;
  }

  body[data-page="student"] .quick-access {
    padding: 16px;
    margin-bottom: 14px;
  }

  body[data-page="student"] .quick-grid,
  body[data-page="student"] .dashboard-grid,
  body[data-page="student"] .lesson-card-grid {
    gap: 14px;
  }

  body[data-page="student"] .quick-card {
    min-height: 116px;
    padding: 14px;
  }

  body[data-page="student"] .quick-card > svg {
    top: 14px;
    width: 38px;
    height: 38px;
  }

  body[data-page="student"] .quick-card strong {
    font-size: 14px;
  }

  body[data-page="student"] .quick-card span {
    font-size: 11px;
  }

  body[data-page="student"] .quick-card button svg {
    width: 24px;
    height: 24px;
  }

  body[data-page="student"] .panel-card {
    padding: 16px;
  }

  body[data-page="student"] .panel-card h2,
  body[data-page="student"] .quick-access h2 {
    margin-bottom: 10px;
    font-size: 17px;
  }

  body[data-page="student"] .progress-range-pill {
    min-height: 42px;
    padding: 0 14px;
    border-radius: 12px;
    gap: 10px;
    font-size: 13px;
  }

  body[data-page="student"] .progress-range-pill svg {
    width: 18px;
    height: 18px;
  }

  body[data-page="student"] .student-progress-card {
    min-height: 0;
    padding: 16px;
  }

  body[data-page="student"] .student-overall-layout {
    grid-template-columns: minmax(150px, 0.82fr) minmax(0, 1fr);
    gap: 18px;
  }

  body[data-page="student"] .student-progress-donut {
    width: clamp(132px, 9.4vw, 166px);
  }

  body[data-page="student"] .student-progress-donut::after {
    inset: 24px;
  }

  body[data-page="student"] .student-progress-donut strong {
    font-size: clamp(28px, 2.3vw, 38px);
  }

  body[data-page="student"] .student-progress-donut span {
    margin-top: 5px;
    font-size: 12px;
  }

  body[data-page="student"] .student-progress-kpis {
    gap: 10px;
    padding-left: 18px;
  }

  body[data-page="student"] .student-progress-kpis article {
    grid-template-columns: 38px minmax(0, 1fr) auto;
    gap: 11px;
  }

  body[data-page="student"] .student-progress-kpis svg {
    width: 32px;
    height: 32px;
  }

  body[data-page="student"] .student-progress-kpis span {
    font-size: 13px;
    line-height: 1.15;
  }

  body[data-page="student"] .student-progress-kpis strong {
    font-size: 16px;
  }

  body[data-page="student"] .student-card-title-row {
    margin-bottom: 12px;
  }

  body[data-page="student"] .student-card-title-row h2 {
    font-size: 17px;
  }

  body[data-page="student"] .student-card-title-row span {
    font-size: 13px;
  }

  body[data-page="student"] .student-mastery-list {
    gap: 14px;
  }

  body[data-page="student"] .student-mastery-row {
    min-width: 0;
    display: grid;
    grid-template-columns: 28px minmax(0, 1.2fr) minmax(50px, 1fr) auto;
    align-items: center;
    gap: 10px;
  }

  body[data-page="student"] .student-mastery-row svg {
    width: 22px;
    height: 22px;
    flex-shrink: 0;
  }

  body[data-page="student"] .student-mastery-row strong {
    min-width: 0;
    overflow: hidden;
    font-size: 13px;
    font-weight: 700;
    line-height: 1.2;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  body[data-page="student"] .student-mastery-row b {
    font-size: 13px;
    font-weight: 700;
    text-align: right;
    white-space: nowrap;
    flex-shrink: 0;
    min-width: 32px;
  }

  body[data-page="student"] .student-mastery-track {
    height: 8px;
  }

  body[data-page="student"] .student-line-chart {
    min-height: 216px;
  }

  body[data-page="student"] .student-line-chart .chart-line {
    stroke-width: 4;
  }

  body[data-page="student"] .student-line-chart .chart-point {
    r: 6px;
  }

  body[data-page="student"] .student-line-chart .chart-value {
    font-size: 14px;
  }

  body[data-page="student"] .student-line-chart .chart-label {
    font-size: 12px;
  }

  body[data-page="student"] .student-score-row {
    min-height: 52px;
    grid-template-columns: 36px minmax(0, 1fr) auto;
    gap: 9px;
    padding: 8px 0;
  }

  body[data-page="student"] .student-score-row small {
    display: none;
  }

  body[data-page="student"] .student-score-row > svg {
    width: 30px;
    height: 30px;
    padding: 6px;
  }

  body[data-page="student"] .student-score-row strong {
    overflow: hidden;
    font-size: 13px;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  body[data-page="student"] .student-score-row span,
  body[data-page="student"] .student-score-row b {
    font-size: 12px;
  }

  body[data-page="student"] .student-hours-total strong {
    font-size: 32px;
  }

  body[data-page="student"] .student-hours-total span {
    margin-top: 5px;
    font-size: 12px;
  }

  body[data-page="student"] .student-hour-bars {
    min-height: 124px;
    margin-top: 12px;
  }

  body[data-page="student"] .student-hour-bars article > div {
    height: 78px;
  }

  body[data-page="student"] .student-hour-bars b {
    width: 14px;
  }

  body[data-page="student"] .student-hour-bars article > span,
  body[data-page="student"] .student-hour-bars small {
    font-size: 10.5px;
  }

  body[data-page="student"] .student-goal-list {
    gap: 13px;
  }

  body[data-page="student"] .student-goal-row {
    grid-template-columns: 38px minmax(0, 1fr) 28px;
    gap: 12px;
  }

  body[data-page="student"] .student-goal-row > svg {
    width: 34px;
    height: 34px;
  }

  body[data-page="student"] .student-goal-row strong,
  body[data-page="student"] .student-goal-row b {
    font-size: 14px;
  }

  body[data-page="student"] .student-goal-row > span svg {
    width: 24px;
    height: 24px;
  }

  body[data-page="student"] .student-recommend-card {
    min-height: 0;
    display: flex;
    flex-direction: column;
    background: #fff;
  }

  body[data-page="student"] .student-recommend-body {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(210px, 0.34fr);
    gap: 18px;
    align-items: center;
    width: 100%;
  }

  body[data-page="student"] .recommend-copy > p {
    margin: -6px 0 12px;
    font-size: 13px;
  }

  body[data-page="student"] .recommend-lesson {
    min-height: 94px;
    max-width: none;
    grid-template-columns: 58px minmax(0, 1fr);
    gap: 14px;
    padding: 14px;
    border-radius: 14px;
  }

  body[data-page="student"] .recommend-lesson > svg {
    width: 50px;
    height: 50px;
    padding: 10px;
  }

  body[data-page="student"] .recommend-lesson strong {
    font-size: 16px;
  }

  body[data-page="student"] .recommend-lesson span {
    margin: 3px 0 9px;
    font-size: 12px;
  }

  body[data-page="student"] .recommend-action {
    gap: 14px;
  }

  body[data-page="student"] .recommend-visual {
    min-height: 104px;
  }

  body[data-page="student"] .recommend-visual svg {
    width: 58px;
    height: 58px;
  }
}

@media (min-width: 1181px) {
  body[data-page="student"] .student-progress-grid {
    grid-template-columns: repeat(12, minmax(0, 1fr));
    gap: 16px;
    align-items: stretch;
  }

  body[data-page="student"] .student-progress-overall {
    grid-column: 1 / span 5;
  }

  body[data-page="student"] .student-topic-mastery {
    grid-column: 6 / -1;
  }

  body[data-page="student"] .student-weekly-card {
    grid-column: 1 / span 5;
  }

  body[data-page="student"] .student-recent-scores {
    grid-column: 6 / span 3;
  }

  body[data-page="student"] .student-hours-card {
    grid-column: 9 / -1;
  }

  body[data-page="student"] .student-goals-card {
    grid-column: 1 / span 5;
  }

  body[data-page="student"] .student-recommend-card {
    grid-column: 6 / -1;
  }
}

@media (max-width: 1180px) and (min-width: 841px) {
  body[data-page="student"] .student-progress-grid {
    grid-template-columns: 1fr;
  }

  body[data-page="student"] .student-progress-overall,
  body[data-page="student"] .student-topic-mastery,
  body[data-page="student"] .student-weekly-card,
  body[data-page="student"] .student-recent-scores,
  body[data-page="student"] .student-hours-card,
  body[data-page="student"] .student-goals-card,
  body[data-page="student"] .student-recommend-card {
    grid-column: auto;
  }
}

/* Student home/progress spacing correction */
@media (min-width: 841px) {
  body[data-page="student"] .dashboard-grid.three-col {
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr) minmax(330px, 0.95fr);
    gap: 14px;
    align-items: stretch;
  }

  body[data-page="student"] .dashboard-grid.three-col > .panel-card {
    min-height: clamp(292px, 30vh, 360px);
  }

  body[data-page="student"] .mission-card {
    display: grid;
    grid-template-rows: auto minmax(0, 1fr);
    gap: 8px;
  }

  body[data-page="student"] #dailyMission {
    min-height: 0;
    display: grid;
    grid-template-rows: auto auto minmax(0, 1fr) auto auto;
    align-content: start;
    gap: 11px;
  }

  body[data-page="student"] .mission-visual {
    width: 70px;
    height: 70px;
    border-radius: 16px;
  }

  body[data-page="student"] .mission-visual svg {
    width: 42px;
    height: 42px;
  }

  body[data-page="student"] .mission-card h3 {
    margin: 0;
    max-width: 100%;
    font-size: clamp(15px, 1.04vw, 18px);
    line-height: 1.2;
  }

  body[data-page="student"] .mission-card p {
    margin: 0;
    color: #626b79;
    font-size: clamp(12px, 0.82vw, 14px);
    font-weight: 700;
    line-height: 1.45;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
  }

  body[data-page="student"] .mission-progress {
    display: grid;
    gap: 6px;
  }

  body[data-page="student"] .mission-progress strong {
    font-size: 13px;
    line-height: 1.15;
  }

  body[data-page="student"] .mission-progress .wide-progress {
    height: 9px;
  }

  body[data-page="student"] .mission-action {
    width: 100%;
    min-height: 46px;
    margin-top: 0;
    border-radius: 11px;
    font-size: 17px;
  }

  body[data-page="student"] .activity-list {
    min-height: 0;
    align-content: start;
  }

  body[data-page="student"] .activity-row {
    grid-template-columns: 30px minmax(0, 1fr);
    gap: 10px;
    padding: 12px 0;
  }

  body[data-page="student"] .activity-row svg {
    width: 24px;
    height: 24px;
  }

  body[data-page="student"] .activity-row strong {
    display: block;
    line-height: 1.35;
  }

  body[data-page="student"] .activity-row span {
    margin-top: 4px;
    font-size: 12px;
  }

  body[data-page="student"] .progress-card {
    display: grid;
    grid-template-rows: auto auto minmax(0, auto);
    align-content: start;
  }

  body[data-page="student"] .progress-card .panel-title-row {
    margin-bottom: 10px;
  }

  body[data-page="student"] .gauge {
    width: clamp(148px, 9vw, 176px);
    height: clamp(86px, 5.4vw, 100px);
    margin: 8px auto 16px;
    border-width: clamp(18px, 1.55vw, 24px);
    place-items: center;
    align-content: center;
    padding: 15px 0 0;
    position: relative;
  }

  body[data-page="student"] .gauge strong,
  body[data-page="student"] .gauge span {
    position: relative;
    transform: translateY(8px);
  }

  body[data-page="student"] .gauge strong {
    font-size: clamp(24px, 2vw, 34px);
  }

  body[data-page="student"] .gauge span {
    margin-top: 4px;
    font-size: 12px;
    line-height: 1.25;
    text-align: center;
  }

  body[data-page="student"] .progress-stats {
    width: 100%;
    margin-top: 0;
    border-radius: 14px;
  }

  body[data-page="student"] .progress-stats div {
    min-width: 0;
    padding: 12px 6px;
    gap: 4px;
  }

  body[data-page="student"] .progress-stats svg {
    width: 25px;
    height: 25px;
  }

  body[data-page="student"] .progress-stats strong {
    font-size: 15px;
    line-height: 1;
  }

  body[data-page="student"] .progress-stats span {
    font-size: 10.5px;
    line-height: 1.1;
    text-align: center;
  }

  body[data-page="student"] .student-progress-overall h2 {
    margin-bottom: 8px;
  }

  body[data-page="student"] .student-overall-layout {
    align-items: center;
  }

  body[data-page="student"] .student-progress-donut {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    line-height: 1;
  }

  body[data-page="student"] .student-progress-donut strong {
    line-height: 1;
  }

  body[data-page="student"] .student-progress-donut span {
    margin-top: 0;
    line-height: 1.15;
  }

  body[data-page="student"] .student-progress-kpis {
    justify-content: center;
  }

  body[data-page="student"] .student-progress-kpis article {
    min-height: 31px;
  }
}

@media (max-width: 1180px) and (min-width: 841px) {
  body[data-page="student"] .dashboard-grid.three-col {
    grid-template-columns: 1fr;
  }

  body[data-page="student"] .dashboard-grid.three-col > .panel-card {
    min-height: auto;
  }
}

@media (max-width: 840px) {
  body[data-page="student"] #dailyMission,
  body[data-page="student"] .mission-progress {
    display: grid;
    gap: 10px;
  }

  body[data-page="student"] .mission-action {
    width: 100%;
  }

body[data-page="student"] .gauge {
    place-items: center;
    padding-top: 14px;
  }
}

/* Student capstone polish */
body[data-page="student"] .student-home-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  align-items: stretch;
}

body[data-page="student"] .student-home-grid > .panel-card {
  min-width: 0;
  min-height: 0;
}

body[data-page="student"] .student-next-action-card {
  grid-column: span 2;
}

body[data-page="student"] .student-evidence-timeline-card {
  grid-column: 1 / -1;
}

body[data-page="student"] .next-action-panel {
  min-height: 164px;
  display: grid;
  grid-template-columns: 70px minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
  padding: 16px;
  border: 1px solid #dfe7f2;
  border-radius: 16px;
  background: #f8fbff;
}

body[data-page="student"] .next-action-panel.danger {
  border-color: #ffd1d9;
  background: #fff8fa;
}

body[data-page="student"] .next-action-panel.orange {
  border-color: #ffe2bb;
  background: #fffaf2;
}

body[data-page="student"] .next-action-panel.green {
  border-color: #c8efd8;
  background: #f7fff9;
}

body[data-page="student"] .next-action-panel.purple {
  border-color: #ded1ff;
  background: #fbf8ff;
}

body[data-page="student"] .next-action-icon,
body[data-page="student"] .student-skill-map-icon,
body[data-page="student"] .student-evidence-icon {
  display: grid;
  place-items: center;
  border-radius: 16px;
  background: #eaf2ff;
  color: #1f7bf2;
}

body[data-page="student"] .next-action-icon {
  width: 70px;
  height: 70px;
}

body[data-page="student"] .next-action-icon svg {
  width: 36px;
  height: 36px;
}

body[data-page="student"] .next-action-copy {
  min-width: 0;
}

body[data-page="student"] .next-action-copy span,
body[data-page="student"] .next-action-copy small,
body[data-page="student"] .student-skill-snapshot-row span,
body[data-page="student"] .student-skill-map-row small,
body[data-page="student"] .student-readiness-row small {
  color: #707987;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.2;
}

body[data-page="student"] .next-action-copy strong {
  display: block;
  margin: 4px 0;
  color: #07111f;
  font-size: clamp(18px, 1.45vw, 24px);
  line-height: 1.15;
}

body[data-page="student"] .next-action-copy p {
  margin: 0 0 12px;
  color: #566171;
  font-weight: 700;
  line-height: 1.45;
}

body[data-page="student"] .next-action-button {
  min-width: 150px;
  min-height: 46px;
  white-space: nowrap;
}

body[data-page="student"] .next-action-empty,
body[data-page="student"] .student-due-empty {
  min-height: 132px;
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr);
  align-items: center;
  gap: 14px;
  color: #707987;
  font-weight: 800;
}

body[data-page="student"] .next-action-empty svg,
body[data-page="student"] .student-due-empty svg {
  width: 44px;
  height: 44px;
  color: #10a65a;
}

body[data-page="student"] .student-skill-snapshot-list,
body[data-page="student"] .student-due-list,
body[data-page="student"] .student-evidence-list,
body[data-page="student"] .student-skill-map-list,
body[data-page="student"] .student-readiness-list {
  min-width: 0;
  display: grid;
  gap: 10px;
}

body[data-page="student"] .student-skill-snapshot-row {
  min-width: 0;
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr) minmax(72px, 0.5fr) 46px;
  align-items: center;
  gap: 10px;
}

body[data-page="student"] .student-skill-snapshot-row svg {
  width: 28px;
  height: 28px;
  color: #1f7bf2;
}

body[data-page="student"] .student-skill-snapshot-row svg.green { color: #10a65a; }
body[data-page="student"] .student-skill-snapshot-row svg.orange { color: #ffad1f; }
body[data-page="student"] .student-skill-snapshot-row svg.purple { color: #7a42f4; }

body[data-page="student"] .student-skill-snapshot-row strong,
body[data-page="student"] .student-due-row strong,
body[data-page="student"] .student-evidence-row strong {
  display: block;
  min-width: 0;
  color: #07111f;
  line-height: 1.2;
}

body[data-page="student"] .student-mini-track {
  height: 8px;
  border-radius: 999px;
  overflow: hidden;
  background: #edf1f7;
}

body[data-page="student"] .student-mini-track span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: #1f7bf2;
}

body[data-page="student"] .student-skill-snapshot-row b,
body[data-page="student"] .student-skill-map-row b {
  text-align: right;
  font-size: 14px;
}

body[data-page="student"] b.good { color: #08a64b; }
body[data-page="student"] b.warn { color: #ff7a1a; }
body[data-page="student"] b.danger { color: #d93245; }

body[data-page="student"] .student-due-row {
  min-width: 0;
  min-height: 58px;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 10px;
  border: 1px solid #e3e9f2;
  border-radius: 14px;
  background: #fff;
}

body[data-page="student"] .student-due-row > svg {
  width: 26px;
  height: 26px;
  color: #1f7bf2;
}

body[data-page="student"] .student-due-row.warn > svg { color: #ff8a1e; }
body[data-page="student"] .student-due-row.danger > svg { color: #d93245; }
body[data-page="student"] .student-due-row.good > svg { color: #10a65a; }

body[data-page="student"] .student-due-row span {
  display: block;
  margin-top: 3px;
  color: #707987;
  font-size: 12px;
  font-weight: 800;
}

body[data-page="student"] .student-due-row .small-button {
  min-height: 36px;
  padding: 0 12px;
  border-radius: 10px;
  white-space: nowrap;
}

body[data-page="student"] .student-evidence-list.compact {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

body[data-page="student"] .student-evidence-row {
  width: 100%;
  min-width: 0;
  min-height: 64px;
  padding: 10px;
  border: 1px solid #e3e9f2;
  border-radius: 14px;
  background: #fff;
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  text-align: left;
  cursor: pointer;
}

body[data-page="student"] .student-evidence-row:hover {
  border-color: #bcd2f8;
  box-shadow: 0 8px 18px rgba(31, 123, 242, 0.1);
}

body[data-page="student"] .student-evidence-icon {
  width: 42px;
  height: 42px;
}

body[data-page="student"] .student-evidence-icon svg {
  width: 22px;
  height: 22px;
}

body[data-page="student"] .student-evidence-icon.green,
body[data-page="student"] .student-skill-map-icon.green {
  background: #e8f8ef;
  color: #10a65a;
}

body[data-page="student"] .student-evidence-icon.orange,
body[data-page="student"] .student-skill-map-icon.orange {
  background: #fff4dd;
  color: #ffad1f;
}

body[data-page="student"] .student-evidence-icon.purple,
body[data-page="student"] .student-skill-map-icon.purple {
  background: #f1eaff;
  color: #7a42f4;
}

body[data-page="student"] .student-evidence-row small,
body[data-page="student"] .student-evidence-row time {
  display: block;
  color: #707987;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.2;
}

body[data-page="student"] .student-evidence-row time {
  text-align: right;
  white-space: nowrap;
}

body[data-page="student"] .student-skill-map-card {
  grid-column: 1;
}

body[data-page="student"] .student-readiness-card {
  grid-column: 2;
}

body[data-page="student"] .student-evidence-progress-card {
  grid-column: 1 / -1;
}

body[data-page="student"] .student-skill-map-row {
  min-width: 0;
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr) 54px;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border: 1px solid #e3e9f2;
  border-radius: 14px;
  background: #fff;
}

body[data-page="student"] .student-skill-map-icon {
  width: 48px;
  height: 48px;
}

body[data-page="student"] .student-skill-map-icon svg {
  width: 26px;
  height: 26px;
}

body[data-page="student"] .student-skill-map-row strong {
  display: block;
  margin-bottom: 2px;
  font-size: 15px;
  line-height: 1.2;
}

body[data-page="student"] .student-skill-map-row .student-mastery-track {
  margin-top: 8px;
}

body[data-page="student"] .student-readiness-row {
  min-width: 0;
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) 58px;
  align-items: center;
  gap: 12px;
  padding: 11px;
  border: 1px solid #e3e9f2;
  border-radius: 14px;
  background: #fff;
}

body[data-page="student"] .student-readiness-row.done {
  border-color: #c8efd8;
  background: #f7fff9;
}

body[data-page="student"] .student-readiness-row > span {
  width: 42px;
  height: 42px;
  border-radius: 13px;
  background: #eaf2ff;
  color: #1f7bf2;
  display: grid;
  place-items: center;
}

body[data-page="student"] .student-readiness-row.done > span {
  background: #e8f8ef;
  color: #10a65a;
}

body[data-page="student"] .student-readiness-row svg {
  width: 22px;
  height: 22px;
}

body[data-page="student"] .student-readiness-row strong {
  display: block;
  line-height: 1.2;
}

body[data-page="student"] .student-readiness-row b {
  color: #1f7bf2;
  font-size: 13px;
  text-align: right;
}

body[data-page="student"] .student-readiness-row.done b {
  color: #10a65a;
}

@media (min-width: 1181px) {
  body[data-page="student"] .student-skill-map-card {
    grid-column: 1 / span 7;
  }

  body[data-page="student"] .student-readiness-card {
    grid-column: 8 / -1;
  }

  body[data-page="student"] .student-evidence-progress-card {
    grid-column: 1 / -1;
  }
}

@media (max-width: 1180px) and (min-width: 841px) {
  body[data-page="student"] .student-home-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  body[data-page="student"] .student-next-action-card,
  body[data-page="student"] .student-evidence-timeline-card {
    grid-column: 1 / -1;
  }

  body[data-page="student"] .student-skill-map-card,
  body[data-page="student"] .student-readiness-card,
  body[data-page="student"] .student-evidence-progress-card {
    grid-column: auto;
  }
}

@media (max-width: 840px) {
  body[data-page="student"] .student-home-grid,
  body[data-page="student"] .student-evidence-list.compact {
    grid-template-columns: 1fr;
  }

  body[data-page="student"] .student-next-action-card,
  body[data-page="student"] .student-evidence-timeline-card,
  body[data-page="student"] .student-skill-map-card,
  body[data-page="student"] .student-readiness-card,
  body[data-page="student"] .student-evidence-progress-card {
    grid-column: auto;
  }

  body[data-page="student"] .next-action-panel,
  body[data-page="student"] .student-due-row,
  body[data-page="student"] .student-evidence-row {
    grid-template-columns: 1fr;
    justify-items: start;
  }

  body[data-page="student"] .next-action-button,
  body[data-page="student"] .student-due-row .small-button {
    width: 100%;
  }

  body[data-page="student"] .student-skill-snapshot-row {
    grid-template-columns: 30px minmax(0, 1fr) 42px;
  }

  body[data-page="student"] .student-skill-snapshot-row .student-mini-track {
    grid-column: 2 / -1;
    width: 100%;
  }

  body[data-page="student"] .student-evidence-row time {
    text-align: left;
  }
}

/* Student Assessments task center */
body[data-page="student"] .student-assessments-dashboard {
  min-width: 0;
  display: grid;
  gap: 18px;
}

body[data-page="student"] .student-assessment-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

body[data-page="student"] .student-assessment-metric-card {
  min-width: 0;
  min-height: 108px;
  padding: 16px;
  border: 1px solid #dfe7f2;
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.09);
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr);
  align-items: center;
  gap: 13px;
}

body[data-page="student"] .assessment-metric-icon {
  width: 54px;
  height: 54px;
  border-radius: 16px;
  display: grid;
  place-items: center;
}

body[data-page="student"] .assessment-metric-icon svg {
  width: 28px;
  height: 28px;
}

body[data-page="student"] .assessment-metric-icon.blue { background: #eaf2ff; color: #1f7bf2; }
body[data-page="student"] .assessment-metric-icon.green { background: #e9f9ef; color: #09a957; }
body[data-page="student"] .assessment-metric-icon.purple { background: #f1eaff; color: #7a42f4; }
body[data-page="student"] .assessment-metric-icon.gold { background: #fff3d7; color: #ffad1f; }

body[data-page="student"] .student-assessment-metric-card p,
body[data-page="student"] .student-assessment-metric-card small {
  margin: 0;
  color: #737b88;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.2;
}

body[data-page="student"] .student-assessment-metric-card strong {
  display: block;
  margin: 4px 0;
  color: #07111f;
  font-size: 28px;
  line-height: 1;
}

body[data-page="student"] .student-assessment-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(310px, 0.34fr);
  gap: 18px;
  align-items: start;
}

body[data-page="student"] .student-assessment-flow-card {
  min-width: 0;
  margin: 16px 0;
  padding: 16px;
  border-radius: 16px;
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
  border-color: #dbe8ff;
  background: #f8fbff;
}

body[data-page="student"] .student-assessment-flow-card.green {
  border-color: #d7f2e2;
  background: #f7fdf9;
}

body[data-page="student"] .student-assessment-flow-card.purple {
  border-color: #e6dcff;
  background: #fbf9ff;
}

body[data-page="student"] .student-assessment-flow-icon {
  width: 52px;
  height: 52px;
  border-radius: 16px;
  background: #eaf2ff;
  color: #1f7bf2;
  display: grid;
  place-items: center;
}

body[data-page="student"] .student-assessment-flow-card.green .student-assessment-flow-icon {
  background: #e8f8ef;
  color: #0aa85b;
}

body[data-page="student"] .student-assessment-flow-card.purple .student-assessment-flow-icon {
  background: #f2eaff;
  color: #7b42f5;
}

body[data-page="student"] .student-assessment-flow-icon svg {
  width: 28px;
  height: 28px;
}

body[data-page="student"] .student-assessment-flow-card strong,
body[data-page="student"] .student-assessment-flow-card p {
  margin: 0;
}

body[data-page="student"] .student-assessment-flow-card strong {
  color: #07111f;
  font-size: 17px;
  font-weight: 900;
}

body[data-page="student"] .student-assessment-flow-card p {
  margin-top: 4px;
  color: #667085;
  font-size: 13px;
  font-weight: 750;
  line-height: 1.35;
}

body[data-page="student"] .student-assessment-flow-action {
  min-height: 42px;
  padding: 0 14px;
  border: 0;
  border-radius: 12px;
  background: #1f7bf2;
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font: inherit;
  font-size: 13px;
  font-weight: 900;
  cursor: pointer;
  white-space: nowrap;
}

body[data-page="student"] .student-assessment-list-card,
body[data-page="student"] .student-assessment-results-card,
body[data-page="student"] .student-assessment-readiness-card {
  min-width: 0;
}

body[data-page="student"] .student-assessment-side,
body[data-page="student"] .student-assessment-list,
body[data-page="student"] .student-assessment-results-list,
body[data-page="student"] .student-assessment-readiness-list {
  min-width: 0;
  display: grid;
  gap: 12px;
}

body[data-page="student"] .student-assessment-card {
  min-width: 0;
  min-height: 136px;
  padding: 14px;
  border: 1px solid #dfe7f2;
  border-radius: 16px;
  background: #fff;
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr) minmax(112px, auto);
  align-items: center;
  gap: 14px;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.07);
}

body[data-page="student"] .student-assessment-card.overdue {
  border-color: #ffd2d8;
  background: #fffafb;
}

body[data-page="student"] .student-assessment-card.is-locked {
  border-color: #d8e1ef;
  background: #f8fbff;
  box-shadow: 0 8px 16px rgba(16, 24, 40, 0.06);
}

body[data-page="student"] .student-assessment-card.is-locked .assessment-card-icon {
  background: #eef3f8;
  color: #718199;
}

body[data-page="student"] .student-assessment-card.pretest:not(.submitted),
body[data-page="student"] .student-assessment-card.posttest:not(.submitted) {
  border-color: #b9d4ff;
  box-shadow: 0 12px 24px rgba(31, 123, 242, 0.12);
}

body[data-page="student"] .assessment-card-icon {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  background: #eaf2ff;
  color: #1f7bf2;
}

body[data-page="student"] .assessment-card-icon svg {
  width: 30px;
  height: 30px;
}

body[data-page="student"] .assessment-card-icon.green { background: #e8f8ef; color: #0aa85b; }
body[data-page="student"] .assessment-card-icon.orange { background: #fff0dc; color: #ff8428; }
body[data-page="student"] .assessment-card-icon.purple { background: #f2eaff; color: #7b42f5; }

body[data-page="student"] .assessment-card-copy {
  min-width: 0;
  display: grid;
  gap: 8px;
}

body[data-page="student"] .assessment-card-topline,
body[data-page="student"] .assessment-card-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

body[data-page="student"] .assessment-type-pill,
body[data-page="student"] .assessment-step-pill,
body[data-page="student"] .assessment-status-pill {
  min-height: 28px;
  padding: 5px 9px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 900;
  line-height: 1;
  white-space: nowrap;
}

body[data-page="student"] .assessment-type-pill {
  background: #eef4ff;
  color: #1f64d8;
}

body[data-page="student"] .assessment-step-pill {
  background: #1f7bf2;
  color: #fff;
}

body[data-page="student"] .assessment-status-pill.submitted { background: #e8f8ef; color: #0aa85b; }
body[data-page="student"] .assessment-status-pill.in_progress { background: #eaf2ff; color: #1f7bf2; }
body[data-page="student"] .assessment-status-pill.not_started { background: #f1f4f9; color: #687386; }
body[data-page="student"] .assessment-status-pill.overdue { background: #ffe8ec; color: #d93245; }

body[data-page="student"] .assessment-card-copy > strong {
  min-width: 0;
  color: #0d1728;
  font-size: 17px;
  font-weight: 900;
  line-height: 1.2;
}

body[data-page="student"] .assessment-card-copy p {
  margin: 0;
  color: #737b88;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.25;
}

body[data-page="student"] .assessment-card-meta span {
  min-width: 0;
  color: #687386;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 11px;
  font-weight: 800;
}

body[data-page="student"] .assessment-card-meta svg {
  width: 14px;
  height: 14px;
  color: #1f7bf2;
}

body[data-page="student"] .assessment-progress-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
}

body[data-page="student"] .assessment-progress-row b,
body[data-page="student"] .student-assessment-result-row b,
body[data-page="student"] .student-assessment-readiness-row b {
  color: #07111f;
  font-weight: 900;
  white-space: nowrap;
}

body[data-page="student"] .assessment-progress-row b.good,
body[data-page="student"] .student-assessment-result-row b.good,
body[data-page="student"] .student-assessment-readiness-row b.good {
  color: #08a64b;
}

body[data-page="student"] .assessment-progress-row b.warn,
body[data-page="student"] .student-assessment-result-row b.warn,
body[data-page="student"] .student-assessment-readiness-row b.warn {
  color: #ff7a1a;
}

body[data-page="student"] .assessment-progress-row b.danger,
body[data-page="student"] .student-assessment-result-row b.danger,
body[data-page="student"] .student-assessment-readiness-row b.danger {
  color: #d93245;
}

body[data-page="student"] .student-assessment-action {
  min-height: 42px;
  padding: 0 14px;
  border: 0;
  border-radius: 12px;
  background: #1f7bf2;
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font: inherit;
  font-size: 13px;
  font-weight: 900;
  cursor: pointer;
  white-space: nowrap;
}

body[data-page="student"] .student-assessment-action:disabled {
  background: #e3ebf5;
  color: #64748b;
  cursor: not-allowed;
}

body[data-page="student"] .student-assessment-action svg {
  width: 18px;
  height: 18px;
}

body[data-page="student"] .student-assessment-result-row {
  min-width: 0;
  min-height: 58px;
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) auto 34px;
  align-items: center;
  gap: 10px;
  padding: 8px 0;
  border-bottom: 1px solid #e5eaf2;
}

body[data-page="student"] .student-assessment-result-row:last-child {
  border-bottom: 0;
}

body[data-page="student"] .student-assessment-result-row > svg {
  width: 34px;
  height: 34px;
  padding: 7px;
  border-radius: 12px;
  background: #eaf2ff;
  color: #1f7bf2;
}

body[data-page="student"] .student-assessment-result-row > svg.green { background: #e8f8ef; color: #10a65a; }
body[data-page="student"] .student-assessment-result-row > svg.orange { background: #fff4dd; color: #ffad1f; }
body[data-page="student"] .student-assessment-result-row > svg.purple { background: #f1eaff; color: #7a42f4; }

body[data-page="student"] .student-assessment-result-row strong,
body[data-page="student"] .student-assessment-result-row span {
  display: block;
  min-width: 0;
}

body[data-page="student"] .student-assessment-result-row strong {
  overflow: hidden;
  line-height: 1.15;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body[data-page="student"] .student-assessment-result-row span {
  color: #737b88;
  font-size: 12px;
  font-weight: 700;
}

body[data-page="student"] .student-assessment-result-row .icon-button {
  width: 34px;
  height: 34px;
  border-radius: 10px;
}

body[data-page="student"] .student-assessment-readiness-row {
  min-width: 0;
  display: grid;
  grid-template-columns: 24px minmax(0, 1.2fr) minmax(44px, 1fr) auto;
  align-items: center;
  gap: 8px;
}

body[data-page="student"] .student-assessment-readiness-row > svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  color: #1f7bf2;
}

body[data-page="student"] .student-assessment-readiness-row > svg.green { color: #10a65a; }
body[data-page="student"] .student-assessment-readiness-row > svg.orange { color: #ffad1f; }
body[data-page="student"] .student-assessment-readiness-row > svg.purple { color: #7a42f4; }

body[data-page="student"] .student-assessment-readiness-row strong {
  min-width: 0;
  overflow: hidden;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body[data-page="student"] .student-assessment-readiness-row .student-mastery-track {
  min-width: 36px;
  height: 8px;
}

body[data-page="student"] .student-assessment-readiness-row b {
  font-size: 12px;
  font-weight: 700;
  text-align: right;
  white-space: nowrap;
  flex-shrink: 0;
  min-width: 28px;
}

body[data-page="student"] .assessment-empty-state .primary-button {
  min-height: 42px;
  padding: 0 18px;
}

@media (max-width: 1280px) {
  body[data-page="student"] .student-assessment-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 1180px) {
  body[data-page="student"] .student-assessment-layout {
    grid-template-columns: 1fr;
  }

  body[data-page="student"] .student-assessment-side {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 840px) {
  body[data-page="student"] .student-assessment-metrics,
  body[data-page="student"] .student-assessment-side {
    grid-template-columns: 1fr;
  }

  body[data-page="student"] .student-assessment-card {
    grid-template-columns: 46px minmax(0, 1fr);
    align-items: start;
  }

  body[data-page="student"] .student-assessment-flow-card {
    grid-template-columns: 44px minmax(0, 1fr);
  }

  body[data-page="student"] .student-assessment-flow-icon {
    width: 44px;
    height: 44px;
    border-radius: 14px;
  }

  body[data-page="student"] .student-assessment-flow-icon svg {
    width: 24px;
    height: 24px;
  }

  body[data-page="student"] .assessment-card-icon {
    width: 44px;
    height: 44px;
    border-radius: 14px;
  }

  body[data-page="student"] .assessment-card-icon svg {
    width: 24px;
    height: 24px;
  }

  body[data-page="student"] .student-assessment-action {
    grid-column: 1 / -1;
    width: 100%;
  }

  body[data-page="student"] .student-assessment-flow-action {
    grid-column: 1 / -1;
    width: 100%;
  }

  body[data-page="student"] .student-assessment-result-row {
    grid-template-columns: 36px minmax(0, 1fr) auto;
  }

  body[data-page="student"] .student-assessment-result-row .icon-button {
    grid-column: 2 / -1;
    width: 100%;
  }

  body[data-page="student"] .student-assessment-readiness-row {
    grid-template-columns: 30px minmax(0, 1fr) 42px;
  }

  body[data-page="student"] .student-assessment-readiness-row .student-mastery-track {
    grid-column: 2 / -1;
  }
}

/* Student Learn and Achievements reference layout */
body[data-page="student"] .student-learn-dashboard,
body[data-page="student"] .student-achievements-dashboard {
  min-width: 0;
}

body[data-page="student"] .student-learn-layout,
body[data-page="student"] .student-achievements-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(292px, 0.34fr);
  gap: 18px;
  align-items: start;
}

body[data-page="student"] .student-learn-main,
body[data-page="student"] .student-achievements-main,
body[data-page="student"] .student-learn-side,
body[data-page="student"] .student-achievements-side {
  min-width: 0;
}

body[data-page="student"] .student-learn-side,
body[data-page="student"] .student-achievements-side {
  display: grid;
  gap: 18px;
}

body[data-page="student"] .student-learn-filters,
body[data-page="student"] .achievement-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 16px;
}

body[data-page="student"] .student-learn-filters button,
body[data-page="student"] .achievement-tabs button {
  min-height: 42px;
  padding: 0 20px;
  border: 1px solid #cfd9ee;
  border-radius: 11px;
  background: #fff;
  color: #777d89;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
}

body[data-page="student"] .student-learn-filters button.active,
body[data-page="student"] .achievement-tabs button.active {
  border-color: #1f7bf2;
  background: #1f7bf2;
  color: #fff;
  box-shadow: 0 8px 18px rgba(31, 123, 242, 0.2);
}

body[data-page="student"] .student-learn-filters svg {
  width: 22px;
  height: 22px;
}

body[data-page="student"] .student-learn-card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

body[data-page="student"] .student-learn-card {
  min-width: 0;
  min-height: 480px;
  border: 1px solid #cbd8f2;
  border-radius: 16px;
  background: #fff;
  overflow: hidden;
  box-shadow: 0 8px 16px rgba(16, 24, 40, 0.12);
  display: grid;
  grid-template-rows: 142px minmax(0, 1fr);
}

body[data-page="student"] .student-learn-card.is-locked {
  border-color: #d8e1ef;
  background: #f8fbff;
  box-shadow: 0 8px 16px rgba(16, 24, 40, 0.06);
}

body[data-page="student"] .student-learn-card.is-locked .student-learn-visual img,
body[data-page="student"] .student-learn-card.is-locked .student-learn-visual.icon-only svg {
  filter: grayscale(0.45) opacity(0.62);
}

body[data-page="student"] .student-learn-visual {
  position: relative;
  min-width: 0;
  background: #eaf1ff;
  display: grid;
  place-items: center;
  overflow: hidden;
}

body[data-page="student"] .student-learn-visual img {
  width: 78%;
  height: 118px;
  object-fit: contain;
  filter: drop-shadow(0 8px 8px rgba(16, 24, 40, 0.16));
}

body[data-page="student"] .student-learn-visual.icon-only svg {
  width: 70px;
  height: 70px;
  color: #1f7bf2;
}

body[data-page="student"] .student-learn-complete {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 4px solid #0bb35c;
  background: #eafff2;
  color: #0bb35c;
  display: grid;
  place-items: center;
}

body[data-page="student"] .student-learn-complete svg {
  width: 28px;
  height: 28px;
  stroke-width: 3;
}

body[data-page="student"] .student-learn-lock {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 1px solid #d5deea;
  background: #fff;
  color: #718199;
  display: grid;
  place-items: center;
  box-shadow: 0 8px 18px rgba(16, 24, 40, 0.1);
}

body[data-page="student"] .student-learn-lock svg {
  width: 22px;
  height: 22px;
}

body[data-page="student"] .student-learn-card-body {
  min-width: 0;
  padding: 14px 16px 16px;
  display: grid;
  grid-template-rows: auto auto auto minmax(0, 1fr) auto auto auto;
  gap: 9px;
}

body[data-page="student"] .student-learn-card-body > strong {
  min-width: 0;
  color: #0d1728;
  font-size: 16px;
  line-height: 1.2;
}

body[data-page="student"] .student-learn-card-body p {
  margin: 0;
  color: #737a86;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.25;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

body[data-page="student"] .student-learn-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

body[data-page="student"] .student-module-overview {
  min-width: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

body[data-page="student"] .student-module-overview span {
  min-height: 24px;
  padding: 4px 8px;
  border-radius: 999px;
  background: #eef5ff;
  color: #1f5fbf;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 11px;
  font-weight: 900;
  line-height: 1;
}

body[data-page="student"] .student-module-overview svg {
  width: 14px;
  height: 14px;
}

body[data-page="student"] .student-module-lesson-list {
  min-width: 0;
  display: grid;
  gap: 6px;
  align-self: start;
}

body[data-page="student"] .student-module-lesson-item {
  min-width: 0;
  min-height: 34px;
  padding: 6px 8px;
  border: 1px solid #d8e3f6;
  border-radius: 8px;
  background: #fbfdff;
  color: #0d1728;
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr) auto;
  align-items: center;
  gap: 7px;
  font: inherit;
  cursor: pointer;
  text-align: left;
}

body[data-page="student"] .student-module-lesson-item:hover {
  border-color: #1f7bf2;
  background: #f2f7ff;
}

body[data-page="student"] .student-module-lesson-item.is-locked,
body[data-page="student"] .student-module-lesson-item:disabled {
  border-color: #d8e1ef;
  background: #f3f6fa;
  color: #667085;
  cursor: not-allowed;
}

body[data-page="student"] .student-module-lesson-item.is-locked:hover,
body[data-page="student"] .student-module-lesson-item:disabled:hover {
  border-color: #d8e1ef;
  background: #f3f6fa;
}

body[data-page="student"] .student-module-lesson-item.is-locked svg,
body[data-page="student"] .student-module-lesson-item:disabled svg {
  color: #7b8798;
}

body[data-page="student"] .student-module-lesson-item svg {
  width: 17px;
  height: 17px;
  color: #1f7bf2;
}

body[data-page="student"] .student-module-lesson-item span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 12px;
  font-weight: 900;
}

body[data-page="student"] .student-module-lesson-item small,
body[data-page="student"] .student-module-more {
  color: #727b8c;
  font-size: 11px;
  font-weight: 900;
}

body[data-page="student"] .student-module-more {
  padding: 0 3px;
}

body[data-page="student"] .student-learn-meta small {
  color: #777d89;
  font-size: 12px;
  font-weight: 800;
}

body[data-page="student"] .difficulty-pill {
  min-width: 0;
  padding: 4px 8px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 12px;
  font-weight: 900;
}

body[data-page="student"] .difficulty-pill svg {
  width: 15px;
  height: 15px;
}

body[data-page="student"] .difficulty-pill.easy {
  background: #dffbed;
  color: #0ca45b;
}

body[data-page="student"] .difficulty-pill.medium {
  background: #fff0df;
  color: #f27a1a;
}

body[data-page="student"] .difficulty-pill.hard {
  background: #ffe8e8;
  color: #e21d3d;
}

body[data-page="student"] .student-learn-action {
  min-height: 38px;
  border: 2px solid #1f7bf2;
  border-radius: 10px;
  background: #fff;
  color: #1f7bf2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font: inherit;
  font-size: 14px;
  font-weight: 900;
  cursor: pointer;
}

body[data-page="student"] .student-learn-action:disabled {
  border-color: #d4deea;
  background: #eef3f8;
  color: #667085;
  cursor: not-allowed;
}

body[data-page="student"] .student-learn-action svg {
  order: 2;
  width: 18px;
  height: 18px;
}

body[data-page="student"] .student-learn-summary,
body[data-page="student"] .student-weekly-goal {
  padding: 22px;
}

body[data-page="student"] .student-learn-summary h2,
body[data-page="student"] .student-weekly-goal h2 {
  margin: 0 0 18px;
  font-size: 22px;
  line-height: 1.15;
}

body[data-page="student"] .student-learn-summary {
  display: grid;
  gap: 14px;
}

body[data-page="student"] .student-learn-summary article {
  min-height: 92px;
  padding: 16px;
  border: 1px solid #d7e0f0;
  border-radius: 16px;
  display: grid;
  grid-template-columns: 74px minmax(0, 1fr);
  align-items: center;
  gap: 16px;
}

body[data-page="student"] .student-learn-summary svg {
  width: 54px;
  height: 54px;
}

body[data-page="student"] .student-learn-summary strong {
  display: block;
  font-size: 26px;
  line-height: 1;
}

body[data-page="student"] .student-learn-summary span {
  color: #737a86;
  font-weight: 800;
}

body[data-page="student"] .student-learn-summary .green { color: #0ca45b; }
body[data-page="student"] .student-learn-summary .blue { color: #1f7bf2; }
body[data-page="student"] .student-learn-summary .teal { color: #00a7a7; }

body[data-page="student"] .student-weekly-goal p {
  margin: -8px 0 16px;
  color: #747b87;
  font-weight: 800;
}

body[data-page="student"] .student-goal-donut {
  --value: 0;
  width: 150px;
  aspect-ratio: 1;
  margin: 8px auto 12px;
  border-radius: 50%;
  background: conic-gradient(#1f7bf2 calc(var(--value) * 1%), #f0f2f6 0);
  display: grid;
  place-items: center;
  position: relative;
}

body[data-page="student"] .student-goal-donut::after {
  content: "";
  position: absolute;
  inset: 24px;
  border-radius: inherit;
  background: #fff;
}

body[data-page="student"] .student-goal-donut strong,
body[data-page="student"] .student-goal-donut span {
  position: relative;
  z-index: 1;
  text-align: center;
}

body[data-page="student"] .student-goal-donut {
  align-content: center;
  gap: 4px;
}

body[data-page="student"] .student-goal-donut span {
  color: #737a86;
  font-weight: 700;
}

body[data-page="student"] .student-goal-donut strong {
  font-size: 34px;
  line-height: 1;
}

body[data-page="student"] .student-weekly-goal small {
  color: #737a86;
  font-weight: 800;
}

body[data-page="student"] .student-empty-dashboard {
  min-height: 260px;
  display: grid;
  place-items: center;
  align-content: center;
  text-align: center;
  gap: 10px;
}

body[data-page="student"] .student-empty-dashboard svg {
  width: 46px;
  height: 46px;
  color: #1f7bf2;
}

body[data-page="student"] .achievements-heading {
  align-items: end;
  margin-bottom: 16px;
}

body[data-page="student"] .achievement-tabs {
  margin: 0;
}

body[data-page="student"] .achievement-tabs button {
  min-width: 150px;
}

body[data-page="student"] .student-top-badges,
body[data-page="student"] .student-milestone-card,
body[data-page="student"] .student-achievement-mission,
body[data-page="student"] .student-achievement-summary,
body[data-page="student"] .student-recent-rewards {
  padding: 20px;
}

body[data-page="student"] .student-badge-gallery {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 14px;
  align-items: stretch;
}

body[data-page="student"] .student-badge-card {
  min-width: 0;
  min-height: 190px;
  display: grid;
  justify-items: center;
  align-content: start;
  gap: 8px;
  text-align: center;
}

body[data-page="student"] .student-badge-shape {
  width: 94px;
  height: 94px;
  clip-path: polygon(50% 0, 91% 25%, 91% 75%, 50% 100%, 9% 75%, 9% 25%);
  display: grid;
  place-items: center;
  color: #fff;
  background: #1f7bf2;
}

body[data-page="student"] .student-badge-shape svg {
  width: 48px;
  height: 48px;
}

body[data-page="student"] .student-badge-shape.green { background: #13a66b; }
body[data-page="student"] .student-badge-shape.gold { background: #ffb21c; }
body[data-page="student"] .student-badge-shape.purple { background: #7245db; }
body[data-page="student"] .student-badge-shape.teal { background: #08aeea; }
body[data-page="student"] .student-badge-shape.gray { background: #a9b0bb; }

body[data-page="student"] .student-badge-card strong {
  max-width: 100%;
  font-size: 15px;
  line-height: 1.15;
}

body[data-page="student"] .student-badge-card > span {
  color: #737a86;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.15;
}

body[data-page="student"] .student-badge-card small.earned {
  color: #0bb35c;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 900;
}

body[data-page="student"] .student-badge-card small svg {
  width: 18px;
  height: 18px;
}

body[data-page="student"] .student-badge-card.locked .student-badge-shape {
  background: #fff;
  color: #8d96a5;
  border: 2px solid #d2d8e4;
  clip-path: none;
  border-radius: 14px;
}

body[data-page="student"] .student-badge-progress {
  width: 100%;
  display: grid;
  gap: 4px;
  color: #7a828e;
  font-weight: 800;
}

body[data-page="student"] .student-certificate-list {
  display: grid;
  gap: 12px;
}

body[data-page="student"] .student-certificate-card {
  min-height: 86px;
  padding: 14px;
  border: 1px solid #d9e1ef;
  border-radius: 14px;
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
}

body[data-page="student"] .student-certificate-card.locked {
  grid-template-columns: 54px minmax(0, 1fr);
}

body[data-page="student"] .student-certificate-card > svg {
  width: 42px;
  height: 42px;
  color: #00a7a7;
}

body[data-page="student"] .student-certificate-card.locked > svg {
  color: #9aa3b0;
}

body[data-page="student"] .student-certificate-card strong,
body[data-page="student"] .student-reward-row strong,
body[data-page="student"] .achievement-mission-body strong {
  display: block;
  line-height: 1.2;
}

body[data-page="student"] .student-certificate-card span,
body[data-page="student"] .student-reward-row span,
body[data-page="student"] .achievement-mission-body p {
  margin: 3px 0 0;
  color: #737a86;
  font-weight: 700;
  line-height: 1.25;
}

body[data-page="student"] .student-achievement-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  text-align: center;
}

body[data-page="student"] .student-achievement-summary article {
  min-width: 0;
  display: grid;
  justify-items: center;
  gap: 6px;
}

body[data-page="student"] .student-achievement-summary svg {
  width: 54px;
  height: 54px;
}

body[data-page="student"] .student-achievement-summary .blue { color: #1f7bf2; }
body[data-page="student"] .student-achievement-summary .gray { color: #a6adb8; }
body[data-page="student"] .student-achievement-summary .gold { color: #ffb21c; }

body[data-page="student"] .student-achievement-summary strong {
  font-size: 20px;
  line-height: 1;
}

body[data-page="student"] .student-achievement-summary span {
  color: #737a86;
  font-weight: 800;
}

body[data-page="student"] .student-achievement-bottom {
  margin-top: 18px;
  display: grid;
  grid-template-columns: minmax(0, 0.96fr) minmax(0, 1.04fr);
  gap: 18px;
}

body[data-page="student"] .student-milestone-list {
  display: grid;
  gap: 12px;
}

body[data-page="student"] .student-milestone-list article {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr) 34px;
  gap: 14px;
  align-items: center;
}

body[data-page="student"] .student-milestone-list article > span {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: #1f7bf2;
  color: #fff;
  display: grid;
  place-items: center;
  font-weight: 900;
}

body[data-page="student"] .student-milestone-list article:not(.done) > span {
  background: #fff;
  color: #1f7bf2;
  border: 2px solid #d8e1ef;
}

body[data-page="student"] .student-milestone-list p {
  margin: 4px 0 6px;
  color: #737a86;
  font-weight: 700;
}

body[data-page="student"] .student-milestone-list article > svg {
  width: 28px;
  height: 28px;
  color: #0bb35c;
}

body[data-page="student"] .student-milestone-list article:not(.done) > svg {
  color: #c0c7d2;
}

body[data-page="student"] .student-achievement-mission {
  display: grid;
  align-content: start;
  gap: 14px;
}

body[data-page="student"] .achievement-mission-body {
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr);
  align-items: center;
  gap: 14px;
}

body[data-page="student"] .achievement-mission-body > svg {
  width: 68px;
  height: 68px;
  padding: 12px;
  border-radius: 18px;
  background: #eaf1ff;
  color: #1f7bf2;
}

body[data-page="student"] .achievement-mission-body > svg.green { background: #e8fbef; color: #0ca45b; }
body[data-page="student"] .achievement-mission-body > svg.orange { background: #fff1df; color: #ff9f1c; }
body[data-page="student"] .achievement-mission-body > svg.purple { background: #f0eaff; color: #7245db; }

body[data-page="student"] .student-achievement-mission > b {
  justify-self: center;
  color: #737a86;
  font-size: 22px;
}

body[data-page="student"] .student-achievement-mission .primary-button {
  min-height: 44px;
}

body[data-page="student"] .student-recent-rewards > div:last-child {
  display: grid;
}

body[data-page="student"] .student-reward-row {
  min-width: 0;
  padding: 12px 0;
  border-bottom: 1px solid #e1e6ef;
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
}

body[data-page="student"] .student-reward-row:last-child {
  border-bottom: 0;
}

body[data-page="student"] .student-reward-row > svg {
  width: 42px;
  height: 42px;
  padding: 8px;
  border-radius: 12px;
  color: #fff;
  background: #1f7bf2;
}

body[data-page="student"] .student-reward-row > svg.green { background: #13a66b; }
body[data-page="student"] .student-reward-row > svg.gold { background: #ffb21c; }
body[data-page="student"] .student-reward-row > svg.purple { background: #7245db; }
body[data-page="student"] .student-reward-row > svg.gray { background: #a6adb8; }

body[data-page="student"] .student-reward-row time {
  color: #737a86;
  font-size: 13px;
  font-weight: 800;
  white-space: nowrap;
}

@media (max-width: 1320px) and (min-width: 841px) {
  body[data-page="student"] .student-learn-card-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  body[data-page="student"] .student-badge-gallery {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 1180px) {
  body[data-page="student"] .student-learn-layout,
  body[data-page="student"] .student-achievements-layout,
  body[data-page="student"] .student-achievement-bottom {
    grid-template-columns: 1fr;
  }

  body[data-page="student"] .student-learn-side,
  body[data-page="student"] .student-achievements-side {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 840px) {
  body[data-page="student"] .student-learn-filters,
  body[data-page="student"] .achievement-tabs {
    gap: 8px;
  }

  body[data-page="student"] .student-learn-filters button,
  body[data-page="student"] .achievement-tabs button {
    flex: 1 1 150px;
    min-height: 40px;
    padding: 0 12px;
    font-size: 13px;
  }

  body[data-page="student"] .student-learn-card-grid,
  body[data-page="student"] .student-learn-side,
  body[data-page="student"] .student-achievements-side,
  body[data-page="student"] .student-badge-gallery,
  body[data-page="student"] .student-achievement-summary {
    grid-template-columns: 1fr;
  }

  body[data-page="student"] .student-learn-card {
    min-height: 0;
  }

  body[data-page="student"] .student-learn-visual {
    min-height: 126px;
  }

  body[data-page="student"] .student-learn-summary article,
  body[data-page="student"] .achievement-mission-body,
  body[data-page="student"] .student-reward-row {
    grid-template-columns: 54px minmax(0, 1fr);
  }

  body[data-page="student"] .student-reward-row time {
    grid-column: 2;
    justify-self: start;
  }
}

/* Evaluation Center */
.evaluation-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 18px;
  margin-bottom: 18px;
}

.evaluation-header h1 {
  margin: 6px 0 6px;
  font-size: 34px;
  line-height: 1.08;
}

.evaluation-header p {
  max-width: 760px;
  color: #5f6877;
  font-weight: 700;
}

.evaluation-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.evaluation-actions button,
.evaluation-tabs button {
  border: 1px solid #cdd9ef;
  background: #fff;
  color: #1f7bf2;
  border-radius: 12px;
  min-height: 42px;
  padding: 0 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-weight: 900;
  cursor: pointer;
}

.evaluation-actions svg {
  width: 18px;
  height: 18px;
}

.evaluation-tabs {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 18px;
}

.evaluation-tabs button.active {
  background: #1f7bf2;
  border-color: #1f7bf2;
  color: #fff;
}

.evaluation-dashboard {
  display: grid;
  gap: 18px;
}

.evaluation-metric-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 14px;
}

.evaluation-metric-card {
  min-width: 0;
  background: #fff;
  border: 1px solid #dbe3ef;
  border-radius: 16px;
  padding: 18px;
  box-shadow: 0 12px 22px rgba(16, 33, 62, 0.08);
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
}

.evaluation-metric-icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: #eaf1ff;
  color: #1f7bf2;
}

.evaluation-metric-icon.green { background: #e8fbef; color: #0ba85c; }
.evaluation-metric-icon.purple { background: #f0eaff; color: #7245db; }
.evaluation-metric-icon.orange { background: #fff1df; color: #ff9f1c; }
.evaluation-metric-icon.teal { background: #e7fbfb; color: #0d9ca6; }
.evaluation-metric-icon.gold { background: #fff6db; color: #d79000; }

.evaluation-metric-card p,
.evaluation-metric-card small {
  margin: 0;
  color: #6f7785;
  font-weight: 800;
}

.evaluation-metric-card strong {
  display: block;
  margin: 2px 0;
  color: #061126;
  font-size: 24px;
  line-height: 1.05;
}

.evaluation-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(360px, 0.78fr);
  gap: 18px;
  align-items: start;
}

.evaluation-board-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(340px, 0.85fr);
  gap: 18px;
  align-items: start;
}

.evaluation-board-column {
  min-width: 0;
  display: grid;
  gap: 18px;
  align-content: start;
}

.evaluation-board-column > .panel-card {
  min-width: 0;
}

.evaluation-setup-list,
.evaluation-gain-list,
.evaluation-category-list,
.evaluation-readiness-list {
  display: grid;
  gap: 14px;
}

.evaluation-setup-card {
  border: 1px solid #dbe3ef;
  border-radius: 14px;
  padding: 16px;
  background: #fbfdff;
  display: grid;
  gap: 16px;
  min-width: 0;
  overflow: hidden;
}

.evaluation-setup-card form,
.teacher-evaluation-survey-form,
.student-evaluation-form {
  display: grid;
  gap: 14px;
}

.evaluation-setup-heading,
.evaluation-survey-form-heading,
.student-evaluation-form-header,
.evaluation-category-list article,
.evaluation-readiness-list article {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 14px;
}

.evaluation-setup-heading {
  align-items: center;
}

.evaluation-setup-heading span,
.evaluation-survey-form-heading span,
.evaluation-note {
  color: #6f7785;
  font-weight: 700;
}

.inline-toggle {
  width: auto;
  min-width: 210px;
  max-width: 250px;
  padding: 12px 14px;
  border-radius: 12px;
}

.evaluation-setup-card .field-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.evaluation-setup-card label,
.evaluation-setup-card select {
  min-width: 0;
}

.evaluation-setup-card select {
  width: 100%;
  min-height: 42px;
  border: 1px solid #d9dfeb;
  border-radius: 10px;
  padding: 0 12px;
  background: #fff;
  color: #061126;
  font: inherit;
}

.evaluation-survey-category {
  border: 1px solid #dbe3ef;
  border-radius: 12px;
  padding: 12px;
  display: grid;
  gap: 10px;
}

.evaluation-survey-category legend {
  padding: 0 6px;
  font-weight: 900;
}

.evaluation-survey-category label {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 92px;
  align-items: center;
  gap: 12px;
  color: #2b3444;
  font-weight: 700;
}

.evaluation-gain-card,
.evaluation-category-list article {
  border-bottom: 1px solid #e1e8f2;
  padding-bottom: 14px;
}

.evaluation-gain-card:last-child,
.evaluation-category-list article:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.evaluation-gain-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-items: stretch;
  gap: 12px;
}

.evaluation-gain-card > div:first-child,
.evaluation-gain-card small {
  min-width: 0;
  color: #6f7785;
  font-weight: 700;
}

.evaluation-gain-card strong {
  display: block;
  color: #061126;
}

.evaluation-gain-bars {
  display: grid;
  gap: 8px;
}

.evaluation-gain-bars span {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) 44px;
  align-items: center;
  gap: 8px;
}

.evaluation-gain-bars i,
.evaluation-category-list .wide-progress {
  height: 10px;
  border-radius: 999px;
  background: #edf2fa;
  overflow: hidden;
}

.evaluation-gain-bars u {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: #1f7bf2;
}

.evaluation-survey-summary {
  display: inline-grid;
  grid-template-columns: auto auto;
  align-items: baseline;
  gap: 8px;
  margin-bottom: 12px;
}

.evaluation-survey-summary strong {
  font-size: 28px;
}

.evaluation-category-list article {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 160px 70px;
  align-items: center;
}

.evaluation-category-list article > div:first-child {
  display: grid;
}

.evaluation-category-list span {
  color: #6f7785;
  font-weight: 800;
}

.evaluation-readiness-list article {
  display: grid;
  gap: 8px;
  justify-content: stretch;
}

.evaluation-readiness-list span {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #6f7785;
  font-weight: 800;
}

.evaluation-readiness-list span.ready {
  color: #0ba85c;
}

.evaluation-readiness-list svg {
  width: 18px;
  height: 18px;
}

.evaluation-table-wrap {
  overflow-x: auto;
}

.evaluation-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 720px;
}

.evaluation-table th,
.evaluation-table td {
  padding: 12px 10px;
  border-bottom: 1px solid #e1e8f2;
  text-align: left;
  vertical-align: middle;
}

.evaluation-table th {
  color: #6f7785;
  font-size: 12px;
  text-transform: uppercase;
}

.evaluation-table td span {
  display: block;
  color: #6f7785;
  font-weight: 700;
}

.evaluation-empty {
  min-height: 260px;
  display: grid;
  place-items: center;
  text-align: center;
  gap: 10px;
}

.evaluation-empty svg {
  width: 58px;
  height: 58px;
  color: #1f7bf2;
}

body[data-page="student"] .student-evaluation-prompt {
  margin-bottom: 18px;
  background: #fff;
  border: 1px solid #dbe3ef;
  border-radius: 16px;
  padding: 18px;
  box-shadow: 0 12px 22px rgba(16, 33, 62, 0.08);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

body[data-page="student"] .student-evaluation-prompt-copy {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 14px;
}

body[data-page="student"] .student-evaluation-icon {
  width: 54px;
  height: 54px;
  border-radius: 16px;
  background: #eaf1ff;
  color: #1f7bf2;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
}

body[data-page="student"] .student-evaluation-prompt p {
  margin: 4px 0 0;
  color: #6f7785;
  font-weight: 700;
}

body[data-page="student"] .student-evaluation-form {
  max-width: 980px;
}

body[data-page="student"] .student-evaluation-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

@media (max-width: 1280px) {
  .evaluation-metric-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .evaluation-layout,
  .evaluation-board-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 840px) {
  .evaluation-header,
  body[data-page="student"] .student-evaluation-prompt {
    display: grid;
    justify-content: stretch;
  }

  .evaluation-actions {
    justify-content: stretch;
  }

  .evaluation-actions button,
  .evaluation-tabs button,
  body[data-page="student"] .student-evaluation-prompt .primary-button {
    width: 100%;
  }

  .evaluation-metric-grid {
    grid-template-columns: 1fr;
  }

  .evaluation-metric-card,
  .evaluation-gain-card,
  .evaluation-category-list article,
  .evaluation-survey-category label {
    grid-template-columns: 1fr;
  }

  .evaluation-survey-category select {
    width: 100%;
  }

  body[data-page="student"] .student-evaluation-actions .primary-button,
  body[data-page="student"] .student-evaluation-actions .small-button {
    width: 100%;
  }
}

/* Final mobile responsiveness guardrails */
@media (max-width: 840px) {
  html,
  body {
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
  }

  body[data-page="teacher"],
  body[data-page="student"],
  body[data-page="teacher"] .app-shell,
  body[data-page="student"] .app-shell,
  body[data-page="teacher"] .app-main,
  body[data-page="student"] .app-main,
  body[data-page="teacher"] .teacher-section,
  body[data-page="student"] .student-section {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    overflow-x: hidden;
  }

  body[data-page="teacher"] .app-main,
  body[data-page="student"] .app-main {
    padding-bottom: calc(92px + env(safe-area-inset-bottom));
  }

  body[data-page="teacher"] .app-topbar,
  body[data-page="student"] .app-topbar {
    width: 100%;
    max-width: 100%;
    min-height: auto;
    padding: 14px 16px;
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
  }

  body[data-page="teacher"] .compact-brand,
  body[data-page="student"] .compact-brand {
    min-width: 0;
    font-size: clamp(28px, 7.8vw, 38px);
    line-height: 0.98;
  }

  body[data-page="teacher"] .topbar-profile,
  body[data-page="student"] .topbar-profile {
    min-width: 0;
    margin-left: auto;
    gap: 8px;
  }

  body[data-page="teacher"] .topbar-profile strong,
  body[data-page="student"] .topbar-profile strong {
    font-size: clamp(14px, 4.2vw, 18px);
    line-height: 1.05;
  }

  body[data-page="teacher"] .topbar-profile span,
  body[data-page="student"] .topbar-profile span {
    font-size: 11px;
    line-height: 1.2;
  }

  body[data-page="teacher"] .notification-panel,
  body[data-page="student"] .notification-panel {
    max-width: calc(100vw - 24px);
    overflow-x: hidden;
  }

  body[data-page="teacher"] .app-sidebar,
  body[data-page="student"] .app-sidebar {
    width: 100%;
    max-width: 100%;
    height: calc(76px + env(safe-area-inset-bottom));
    padding: 7px 8px calc(7px + env(safe-area-inset-bottom));
    display: grid;
    grid-template-columns: repeat(var(--sidebar-item-count), minmax(0, 1fr));
    grid-template-rows: 1fr;
    grid-auto-flow: row;
    grid-auto-columns: initial;
    grid-auto-rows: initial;
    gap: 4px;
    overflow: hidden;
  }

  body[data-page="teacher"] .nav-item,
  body[data-page="student"] .nav-item {
    min-width: 0;
    min-height: 0;
    height: 100%;
    padding: 4px 2px;
    border-radius: 12px;
    gap: 3px;
    font-size: clamp(8.5px, 1.65vw, 11px);
    line-height: 1.05;
    overflow: hidden;
  }

  body[data-page="teacher"] .nav-item svg,
  body[data-page="student"] .nav-item svg {
    width: clamp(18px, 3.3vw, 22px);
    height: clamp(18px, 3.3vw, 22px);
  }

  body[data-page="teacher"] .nav-item span,
  body[data-page="student"] .nav-item span {
    max-width: 100%;
    overflow-wrap: anywhere;
  }

  body[data-page="teacher"] .teacher-section,
  body[data-page="student"] .student-section {
    padding: 18px 14px;
  }

  body[data-page="teacher"] .section-heading,
  body[data-page="student"] .section-heading,
  body[data-page="teacher"] .settings-header,
  body[data-page="teacher"] .reports-header,
  body[data-page="teacher"] .evaluation-header {
    display: grid;
    grid-template-columns: 1fr;
    align-items: start;
    gap: 10px;
  }

  body[data-page="teacher"] .section-heading h1,
  body[data-page="student"] .section-heading h1,
  body[data-page="teacher"] .settings-header h1,
  body[data-page="teacher"] .reports-header h1,
  body[data-page="teacher"] .evaluation-header h1 {
    font-size: clamp(26px, 8vw, 36px);
    line-height: 1.05;
  }

  body[data-page="teacher"] .metric-grid,
  body[data-page="teacher"] .evidence-metric-grid,
  body[data-page="teacher"] .dashboard-grid,
  body[data-page="teacher"] .evidence-dashboard-grid,
  body[data-page="teacher"] .assessment-metric-grid,
  body[data-page="teacher"] .report-metric-grid,
  body[data-page="teacher"] .report-weak-grid,
  body[data-page="teacher"] .report-dashboard-grid,
  body[data-page="teacher"] .reports-toolbar,
  body[data-page="teacher"] .settings-grid,
  body[data-page="teacher"] .evaluation-metric-grid,
  body[data-page="teacher"] .evaluation-layout,
  body[data-page="teacher"] .evaluation-board-grid,
  body[data-page="teacher"] .student-management-header,
  body[data-page="teacher"] .student-management-grid,
  body[data-page="teacher"] .student-right-rail,
  body[data-page="teacher"] .lesson-dashboard-grid,
  body[data-page="teacher"] .lesson-metric-grid,
  body[data-page="teacher"] .lesson-side-rail,
  body[data-page="teacher"] .lesson-toolbar,
  body[data-page="student"] .metric-grid,
  body[data-page="student"] .dashboard-grid,
  body[data-page="student"] .student-hero-row,
  body[data-page="student"] .student-home-grid,
  body[data-page="student"] .student-progress-grid,
  body[data-page="student"] .student-progress-kpis,
  body[data-page="student"] .student-learn-layout,
  body[data-page="student"] .student-learn-card-grid,
  body[data-page="student"] .student-learn-side,
  body[data-page="student"] .student-achievements-layout,
  body[data-page="student"] .student-achievements-side,
  body[data-page="student"] .student-achievement-bottom,
  body[data-page="student"] .student-achievement-summary,
  body[data-page="student"] .student-badge-gallery,
  body[data-page="student"] .student-assessment-metrics,
  body[data-page="student"] .student-assessment-layout,
  body[data-page="student"] .student-assessment-side {
    grid-template-columns: 1fr !important;
    width: 100%;
    max-width: 100%;
    min-width: 0;
  }

  body[data-page="teacher"] .stat-card,
  body[data-page="teacher"] .panel-card,
  body[data-page="teacher"] .student-metric-card,
  body[data-page="teacher"] .student-table-card,
  body[data-page="teacher"] .student-side-card,
  body[data-page="teacher"] .lesson-metric-card,
  body[data-page="teacher"] .lesson-library-card,
  body[data-page="teacher"] .lesson-side-card,
  body[data-page="teacher"] .settings-card,
  body[data-page="teacher"] .evaluation-card,
  body[data-page="student"] .stat-card,
  body[data-page="student"] .panel-card,
  body[data-page="student"] .welcome-block,
  body[data-page="student"] .quick-access,
  body[data-page="student"] .quick-card,
  body[data-page="student"] .achievement-strip,
  body[data-page="student"] .student-progress-card,
  body[data-page="student"] .student-learn-card,
  body[data-page="student"] .student-learn-summary,
  body[data-page="student"] .student-weekly-goal,
  body[data-page="student"] .student-top-badges,
  body[data-page="student"] .student-milestone-card,
  body[data-page="student"] .student-achievement-mission,
  body[data-page="student"] .student-recent-rewards,
  body[data-page="student"] .student-assessment-list-card,
  body[data-page="student"] .student-assessment-results-card,
  body[data-page="student"] .student-assessment-readiness-card {
    width: 100%;
    max-width: 100%;
    min-width: 0;
  }

  body[data-page="teacher"] .student-toolbar,
  body[data-page="teacher"] .lesson-toolbar {
    grid-template-columns: 1fr !important;
    width: 100%;
    max-width: 100%;
    gap: 10px;
  }

  body[data-page="teacher"] .student-search,
  body[data-page="teacher"] .student-toolbar select,
  body[data-page="teacher"] .export-button,
  body[data-page="teacher"] .segment-button,
  body[data-page="teacher"] .lesson-search,
  body[data-page="teacher"] .lesson-toolbar select {
    width: 100%;
    min-width: 0;
    height: 46px;
    font-size: 13px;
  }

  body[data-page="teacher"] .segmented-control {
    width: 100%;
    max-width: 100%;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  body[data-page="teacher"] .student-table-card {
    overflow: visible !important;
    padding: 10px;
  }

  body[data-page="teacher"] .student-management-table,
  body[data-page="teacher"] .student-table-footer {
    width: 100%;
    min-width: 0 !important;
    max-width: 100%;
  }

  body[data-page="teacher"] .student-management-table tbody {
    gap: 12px;
    padding: 0;
  }

  body[data-page="teacher"] .student-management-table tr {
    width: 100%;
    max-width: 100%;
    overflow: hidden;
  }

  body[data-page="teacher"] .student-management-table td {
    grid-template-columns: minmax(78px, 34%) minmax(0, 1fr);
    gap: 10px;
    padding: 10px 12px;
    min-width: 0;
  }

  body[data-page="teacher"] .student-name-cell {
    min-width: 0;
    gap: 8px;
  }

  body[data-page="teacher"] .student-name-cell svg {
    width: 24px;
    height: 24px;
  }

  body[data-page="teacher"] .student-name-cell strong,
  body[data-page="teacher"] .attention-row strong,
  body[data-page="teacher"] .attention-row span,
  body[data-page="teacher"] .status-pill,
  body[data-page="teacher"] .grade-chip {
    max-width: 100%;
    overflow-wrap: anywhere;
    white-space: normal;
  }

  body[data-page="teacher"] .student-table-footer {
    padding: 12px 4px 2px;
    gap: 12px;
  }

  body[data-page="teacher"] .student-pagination {
    width: 100%;
    justify-content: center;
    gap: 8px;
  }

  body[data-page="teacher"] .student-pagination button {
    min-width: 34px;
    height: 34px;
  }

  body[data-page="teacher"] .student-side-card {
    padding: 16px;
  }

  body[data-page="teacher"] .distribution-layout {
    grid-template-columns: 1fr;
    justify-items: center;
  }

  body[data-page="teacher"] .distribution-legend {
    width: 100%;
  }

  body[data-page="teacher"] .attention-row {
    grid-template-columns: 28px minmax(0, 1fr) auto;
    gap: 8px;
  }

  body[data-page="teacher"] .lesson-library-card,
  body[data-page="teacher"] .lesson-side-card {
    padding: 16px;
  }

  body[data-page="teacher"] .lesson-table-heading {
    display: none;
  }

  body[data-page="teacher"] .lesson-row-list {
    border: 0;
    border-radius: 0;
    overflow: visible;
    gap: 12px;
    background: transparent;
  }

  body[data-page="teacher"] .lesson-row {
    grid-template-columns: 1fr !important;
    min-height: 0;
    padding: 14px;
    border: 1px solid #e3eaf4;
    border-radius: 14px;
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.08);
  }

  body[data-page="teacher"] .lesson-title-cell {
    align-items: flex-start;
  }

  body[data-page="teacher"] .lesson-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    width: 100%;
    gap: 8px;
  }

  body[data-page="teacher"] .lesson-actions .small-button,
  body[data-page="teacher"] .lesson-actions .icon-button {
    width: 100%;
    min-width: 0;
    justify-content: center;
  }

  body[data-page="teacher"] .lesson-table-footer {
    display: grid;
    justify-items: center;
    gap: 12px;
  }

  body[data-page="teacher"] .table-card,
  body[data-page="teacher"] .table-shell,
  body[data-page="teacher"] .evaluation-table-wrap,
  body[data-page="student"] .table-card,
  body[data-page="student"] .table-shell,
  body[data-page="student"] .evaluation-table-wrap {
    max-width: 100%;
    overflow-x: auto;
  }

  body[data-page="student"] .student-next-action-card,
  body[data-page="student"] .student-evidence-timeline-card,
  body[data-page="student"] .student-progress-overall {
    grid-column: auto !important;
  }

  body[data-page="student"] .next-action-panel,
  body[data-page="student"] .student-assessment-card,
  body[data-page="student"] .student-assessment-flow-card,
  body[data-page="student"] .student-overall-layout,
  body[data-page="student"] .student-recommend-card,
  body[data-page="student"] .student-goal-row,
  body[data-page="student"] .achievement-mission-body,
  body[data-page="student"] .student-reward-row {
    grid-template-columns: 1fr !important;
  }

  body[data-page="student"] .next-action-button,
  body[data-page="student"] .student-assessment-action,
  body[data-page="student"] .student-assessment-flow-action,
  body[data-page="student"] .student-learn-action,
  body[data-page="student"] .student-achievement-mission .primary-button {
    width: 100%;
  }

  body[data-page="student"] .student-mastery-row {
    grid-template-columns: 28px minmax(0, 1fr) auto;
    gap: 8px;
  }

  body[data-page="student"] .student-mastery-row .student-mastery-track {
    grid-column: 2 / -1;
    width: 100%;
  }

  body[data-page="student"] .student-line-chart,
  body[data-page="student"] .student-hour-bars,
  body[data-page="student"] .student-progress-donut,
  body[data-page="student"] .student-goal-donut {
    max-width: 100%;
  }

  body[data-page="student"] .student-line-chart {
    overflow-x: hidden;
  }

  body[data-page="student"] .student-line-chart svg {
    width: 100%;
    min-width: 0;
  }

  body[data-page="student"] .student-learn-filters,
  body[data-page="student"] .achievement-tabs {
    width: 100%;
    gap: 8px;
  }

  body[data-page="student"] .student-learn-filters button,
  body[data-page="student"] .achievement-tabs button {
    flex: 1 1 calc(50% - 8px);
    min-width: 0;
  }

  body[data-page="teacher"] img,
  body[data-page="teacher"] svg,
  body[data-page="student"] img,
  body[data-page="student"] svg {
    max-width: 100%;
  }
}

@media (max-width: 520px) {
  body[data-page="teacher"] .app-main,
  body[data-page="student"] .app-main {
    padding-bottom: calc(128px + env(safe-area-inset-bottom));
  }

  body[data-page="teacher"] .app-sidebar,
  body[data-page="student"] .app-sidebar {
    height: calc(118px + env(safe-area-inset-bottom));
    grid-template-rows: repeat(2, minmax(0, 1fr));
    gap: 6px;
  }

  body[data-page="teacher"] .app-sidebar {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  body[data-page="student"] .app-sidebar {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  body[data-page="teacher"] .nav-item,
  body[data-page="student"] .nav-item {
    min-height: 0;
    border-radius: 13px;
    font-size: 10px;
  }

  body[data-page="teacher"] .nav-item svg,
  body[data-page="student"] .nav-item svg {
    width: 21px;
    height: 21px;
  }

  body[data-page="teacher"] .app-topbar,
  body[data-page="student"] .app-topbar {
    padding: 16px 14px;
  }

  body[data-page="teacher"] .compact-brand,
  body[data-page="student"] .compact-brand {
    max-width: 42%;
    font-size: clamp(26px, 8.6vw, 34px);
  }

  body[data-page="teacher"] .topbar-profile,
  body[data-page="student"] .topbar-profile {
    max-width: 55%;
  }

  body[data-page="teacher"] .topbar-profile > div:last-of-type,
  body[data-page="student"] .topbar-profile > div:last-of-type {
    min-width: 0;
  }

  body[data-page="teacher"] .topbar-profile strong,
  body[data-page="student"] .topbar-profile strong {
    display: block;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  body[data-page="teacher"] .teacher-section,
  body[data-page="student"] .student-section {
    padding: 16px 12px;
  }

  body[data-page="teacher"] .student-metric-card,
  body[data-page="teacher"] .lesson-metric-card {
    min-height: 92px;
    padding: 14px;
  }

  body[data-page="teacher"] .student-management-table td {
    grid-template-columns: minmax(70px, 32%) minmax(0, 1fr);
    padding: 9px 10px;
  }

  body[data-page="teacher"] .lesson-actions {
    grid-template-columns: 1fr;
  }

  body[data-page="student"] .student-learn-filters button,
  body[data-page="student"] .achievement-tabs button {
    flex-basis: 100%;
  }
}

.compact-auth-shell {
  width: 100%;
  max-width: 100%;
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  place-items: center;
  padding: 32px 18px;
}

.recovery-card {
  width: min(520px, 100%);
  min-height: 0;
  justify-self: center;
  align-self: center;
}

body[data-page="reset-password"] {
  min-height: 100vh;
  display: grid;
}

.dashboard-page-header,
.page-action-row,
.leaderboard-toolbar,
.card-action-row {
  display: flex;
  align-items: center;
  gap: 14px;
}

.dashboard-page-header {
  justify-content: space-between;
  margin-bottom: 18px;
}

.dashboard-page-header h1 {
  margin: 4px 0;
  font-size: 2rem;
}

.dashboard-page-header p {
  margin: 0;
  color: var(--muted);
}

.leaderboard-metrics,
.leaderboard-dashboard .metric-grid,
.completion-dashboard .metric-grid,
.badge-dashboard .metric-grid {
  margin-bottom: 18px;
}

.teacher-leaderboard-header .compact-action,
.achievement-management-header .compact-action {
  align-self: flex-start;
}

.teacher-leaderboard-metrics {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.leaderboard-metric-card {
  position: relative;
  min-height: 126px;
  overflow: hidden;
  padding: 20px;
  border: 1px solid var(--border-color);
  border-radius: 18px;
  background: #fff;
  box-shadow: var(--card-shadow);
}

.leaderboard-metric-card .stat-icon {
  width: 54px;
  height: 54px;
  border-radius: 14px;
}

.leaderboard-metric-card .stat-icon svg {
  width: 28px;
  height: 28px;
}

.leaderboard-metric-card strong {
  font-size: clamp(24px, 2.2vw, 32px);
  line-height: 1;
}

.leaderboard-sparkline {
  position: absolute;
  right: 18px;
  bottom: 20px;
  width: 58px;
  height: 34px;
  opacity: 0.88;
}

.leaderboard-sparkline svg {
  width: 100%;
  height: 100%;
  overflow: visible;
}

.leaderboard-sparkline path {
  fill: none;
  stroke: currentColor;
  stroke-width: 3;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.leaderboard-metric-card.green .leaderboard-sparkline { color: var(--success); }
.leaderboard-metric-card.blue .leaderboard-sparkline { color: var(--primary-blue); }
.leaderboard-metric-card.purple .leaderboard-sparkline { color: var(--purple-accent); }
.leaderboard-metric-card.orange .leaderboard-sparkline { color: var(--warning-orange); }

.embedded-dashboard {
  margin-top: 18px;
}

.embedded-dashboard .dashboard-page-header {
  padding-top: 4px;
}

.leaderboard-toolbar {
  flex-wrap: wrap;
  justify-content: space-between;
  margin-bottom: 16px;
}

.leaderboard-filter-panel {
  margin-bottom: 18px;
}

.leaderboard-toolbar label {
  display: grid;
  gap: 6px;
  min-width: 190px;
  font-weight: 800;
  color: var(--ink);
}

.leaderboard-toolbar label span {
  color: var(--muted);
  font-size: .78rem;
}

.leaderboard-toolbar select {
  min-height: 44px;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0 12px;
  font: inherit;
  font-weight: 700;
  color: var(--ink);
  background: #fff;
}

.leaderboard-table-wrap {
  overflow-x: auto;
}

.leaderboard-table {
  width: 100%;
  min-width: 980px;
  border-collapse: collapse;
}

.leaderboard-table th,
.leaderboard-table td {
  padding: 14px 12px;
  text-align: left;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
}

.leaderboard-table th {
  font-size: .78rem;
  color: var(--muted);
}

.leaderboard-table td strong,
.leaderboard-table td small {
  display: block;
}

.leaderboard-table td small {
  margin-top: 2px;
  color: var(--muted);
  font-size: .78rem;
}

.leaderboard-empty-cell {
  padding: 28px 18px !important;
  text-align: center;
}

.leaderboard-empty-cell strong,
.leaderboard-empty-cell span {
  display: block;
}

.leaderboard-empty-cell strong {
  color: #071225;
  font-size: 15px;
  font-weight: 900;
}

.leaderboard-empty-cell span {
  max-width: 520px;
  margin: 6px auto 0;
  color: #667085;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.4;
}

.rank-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 2px;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: #edf3ff;
  color: var(--primary-blue);
  font-weight: 900;
}

.rank-badge svg {
  width: 16px;
  height: 16px;
}

.rank-badge b {
  font: inherit;
}

.rank-1 { background: #fff3d4; color: #b87900; }
.rank-2 { background: #eef2f7; color: #64748b; }
.rank-3 { background: #ffe6d4; color: #b45309; }

.leaderboard-student-cell {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
}

.avatar-initials {
  width: 42px;
  height: 42px;
  border-radius: 999px;
  background: #eaf2ff;
  color: var(--primary-blue);
  display: inline-grid;
  place-items: center;
  font-size: 13px;
  font-weight: 900;
}

.leaderboard-simulation {
  display: grid;
  gap: 3px;
  color: var(--primary-blue);
  font-weight: 900;
}

.leaderboard-score-cell {
  display: grid;
  min-width: 116px;
  gap: 7px;
}

.leaderboard-score-bar {
  height: 7px;
  overflow: hidden;
  border-radius: 999px;
  background: #e8eef8;
}

.leaderboard-score-bar span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--primary-blue);
}

.current-student-row {
  background: #eff6ff;
}

.competition-grid,
.badge-definition-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(270px, 1fr));
  gap: 16px;
}

.competition-card,
.badge-definition-card,
.completion-module-card {
  min-width: 0;
}

.competition-management-panel {
  display: grid;
  gap: 16px;
}

.compact-definition-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 16px 0;
}

.compact-definition-list div {
  padding: 10px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #f8fbff;
}

.compact-definition-list dt {
  color: var(--muted);
  font-size: .75rem;
  font-weight: 800;
}

.compact-definition-list dd {
  margin: 2px 0 0;
  color: var(--ink);
  font-weight: 800;
}

.card-action-row {
  flex-wrap: wrap;
  justify-content: flex-end;
}

.badge-definition-icon {
  display: inline-grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: #eff6ff;
  color: var(--primary-blue);
}

.badge-definition-card h2 {
  margin: 12px 0 6px;
}

.badge-definition-card p {
  color: var(--muted);
  min-height: 44px;
}

.badge-definition-meta {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin: 14px 0;
  color: var(--muted);
  font-weight: 800;
}

.badge-color-gold .badge-definition-icon { background: #fff3d4; color: #b87900; }
.badge-color-green .badge-definition-icon,
.badge-color-teal .badge-definition-icon { background: #dcfce7; color: #15803d; }
.badge-color-purple .badge-definition-icon { background: #f3e8ff; color: #7e22ce; }
.badge-color-orange .badge-definition-icon { background: #ffedd5; color: #c2410c; }
.badge-color-red .badge-definition-icon { background: #fee2e2; color: #b91c1c; }

.completion-list {
  display: grid;
  gap: 12px;
}

.completion-row {
  display: grid;
  grid-template-columns: minmax(220px, 1.4fr) minmax(180px, 1fr) 70px 120px 100px;
  align-items: center;
  gap: 14px;
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #fff;
}

.completion-row span,
.completion-row small {
  color: var(--muted);
}

.completion-bar {
  height: 10px;
  overflow: hidden;
  border-radius: 999px;
  background: #e8eef8;
}

.completion-bar span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #1f6feb, #22c55e);
}

.student-completion-list {
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.lesson-check-list {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.lesson-check-list div {
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 10px;
  border-radius: 8px;
  background: #f8fbff;
}

.lesson-check-list span {
  min-width: 0;
  font-weight: 800;
}

.lesson-check-list small {
  color: var(--muted);
  font-weight: 800;
}

.stat-icon.gold {
  background: #fff3d4;
  color: #b87900;
}

.modal-form-stack {
  display: grid;
  gap: 12px;
}

.modal-form-stack label {
  display: grid;
  gap: 6px;
  font-weight: 800;
}

.modal-form-stack input,
.modal-form-stack select,
.modal-form-stack textarea {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 12px;
  font: inherit;
  font-weight: 700;
}

.feedback-modal.management-modal {
  width: min(660px, calc(100vw - 32px));
  max-height: calc(100vh - 32px);
  overflow: auto;
  padding: 28px 30px 30px;
  border: 1px solid var(--border-color);
}

.management-modal .feedback-modal-main {
  grid-template-columns: 58px minmax(0, 1fr);
}

.management-modal .feedback-modal-content > p {
  max-width: 46rem;
}

.management-form {
  margin-top: 18px;
  gap: 14px;
}

.management-form .field-grid.simple-grid {
  gap: 14px;
}

.management-form label {
  gap: 8px;
  color: var(--text-primary);
  font-size: 13px;
  font-weight: 900;
}

.management-form label > span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.management-form input,
.management-form select,
.management-form textarea {
  min-height: 48px;
  border: 1px solid #d7e1ef;
  border-radius: 12px;
  padding: 11px 13px;
  background: #fff;
  color: var(--text-primary);
  font-weight: 800;
  box-shadow: 0 1px 0 rgba(15, 23, 42, 0.02);
}

.management-form textarea {
  min-height: 96px;
  resize: vertical;
}

.management-form input::placeholder,
.management-form textarea::placeholder {
  color: #8a94a6;
}

.management-form small {
  color: var(--text-muted);
  font-size: 12px;
  font-weight: 700;
}

.management-modal .feedback-modal-actions {
  margin-top: 4px;
}

.management-modal .feedback-modal-actions .small-button {
  border: 1px solid #d7e1ef;
  background: #fff;
  color: var(--text-primary);
}

@media (max-width: 900px) {
  .dashboard-page-header,
  .page-action-row {
    align-items: stretch;
    flex-direction: column;
  }

  .completion-row {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 380px) {
  body[data-page="teacher"] .nav-item,
  body[data-page="student"] .nav-item {
    font-size: 9px;
  }

  body[data-page="teacher"] .nav-item svg,
  body[data-page="student"] .nav-item svg {
    width: 19px;
    height: 19px;
  }

  body[data-page="teacher"] .compact-brand,
  body[data-page="student"] .compact-brand {
    font-size: 25px;
  }
}

/* Mobile burger navigation and compact phone sizing */
.mobile-nav-toggle,
.mobile-nav-backdrop {
  display: none;
}

@media (max-width: 840px) {
  .mobile-nav-toggle {
    position: fixed;
    top: calc(12px + env(safe-area-inset-top));
    left: 12px;
    z-index: 70;
    width: 42px;
    height: 42px;
    border: 1px solid #dbe6f4;
    border-radius: 13px;
    background: #fff;
    color: #1f7bf2;
    box-shadow: 0 10px 22px rgba(15, 23, 42, 0.16);
    display: grid;
    place-items: center;
    cursor: pointer;
  }

  .mobile-nav-toggle svg {
    width: 22px;
    height: 22px;
    stroke-width: 2.4;
  }

  .mobile-nav-backdrop {
    position: fixed;
    inset: 0;
    z-index: 55;
    background: rgba(15, 23, 42, 0.32);
    opacity: 0;
    pointer-events: none;
    transition: opacity 160ms ease;
  }

  body.mobile-nav-open .mobile-nav-backdrop {
    display: block;
    opacity: 1;
    pointer-events: auto;
  }

  body[data-page="teacher"] .app-sidebar,
  body[data-page="student"] .app-sidebar {
    position: fixed;
    top: calc(62px + env(safe-area-inset-top));
    left: 10px;
    bottom: auto;
    z-index: 65;
    width: min(238px, calc(100vw - 20px));
    max-width: calc(100vw - 20px);
    height: auto !important;
    max-height: calc(100vh - 82px - env(safe-area-inset-top));
    padding: 10px;
    border-radius: 18px;
    grid-template-columns: 1fr !important;
    grid-template-rows: none !important;
    grid-auto-flow: row;
    grid-auto-columns: initial;
    gap: 7px;
    overflow-y: auto;
    overflow-x: hidden;
    box-shadow: 0 22px 44px rgba(15, 23, 42, 0.28);
    transform: translateX(calc(-100% - 18px));
    opacity: 0;
    pointer-events: none;
    transition: transform 180ms ease, opacity 180ms ease;
  }

  body.mobile-nav-open[data-page="teacher"] .app-sidebar,
  body.mobile-nav-open[data-page="student"] .app-sidebar {
    transform: translateX(0);
    opacity: 1;
    pointer-events: auto;
  }

  body[data-page="teacher"] .nav-item,
  body[data-page="student"] .nav-item {
    min-height: 44px;
    height: 44px;
    padding: 0 12px;
    border-radius: 12px;
    display: grid;
    grid-template-columns: 24px minmax(0, 1fr);
    place-items: center start;
    align-content: center;
    gap: 10px;
    font-size: 12px;
    text-align: left;
  }

  body[data-page="teacher"] .nav-item svg,
  body[data-page="student"] .nav-item svg {
    width: 21px;
    height: 21px;
  }

  body[data-page="teacher"] .nav-item span,
  body[data-page="student"] .nav-item span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  body[data-page="teacher"] .app-main,
  body[data-page="student"] .app-main {
    padding-bottom: 24px;
  }

  body[data-page="teacher"] .app-topbar,
  body[data-page="student"] .app-topbar {
    padding: calc(12px + env(safe-area-inset-top)) 12px 12px 62px;
    min-height: 66px;
    flex-wrap: nowrap;
  }

  body[data-page="teacher"] .compact-brand,
  body[data-page="student"] .compact-brand {
    max-width: 46%;
    font-size: clamp(24px, 7vw, 32px);
  }

  body[data-page="teacher"] .topbar-profile,
  body[data-page="student"] .topbar-profile {
    max-width: 52%;
    flex-shrink: 1;
  }

  body[data-page="teacher"] .teacher-section,
  body[data-page="student"] .student-section {
    padding: 14px 10px 22px;
  }

  body[data-page="teacher"] .dashboard-status,
  body[data-page="student"] .dashboard-status {
    margin: 10px 10px 0;
  }

  body[data-page="teacher"] .section-heading h1,
  body[data-page="student"] .section-heading h1,
  body[data-page="teacher"] .settings-header h1,
  body[data-page="teacher"] .reports-header h1,
  body[data-page="teacher"] .evaluation-header h1,
  body[data-page="teacher"] .lesson-library-header h1 {
    font-size: clamp(24px, 7vw, 32px);
  }

  body[data-page="teacher"] .section-heading p,
  body[data-page="student"] .section-heading p,
  body[data-page="teacher"] .settings-header p,
  body[data-page="teacher"] .reports-header p,
  body[data-page="teacher"] .evaluation-header p {
    font-size: 13px;
    line-height: 1.45;
  }

  body[data-page="teacher"] .stat-card,
  body[data-page="teacher"] .panel-card,
  body[data-page="teacher"] .student-metric-card,
  body[data-page="teacher"] .student-table-card,
  body[data-page="teacher"] .student-side-card,
  body[data-page="teacher"] .lesson-metric-card,
  body[data-page="teacher"] .lesson-library-card,
  body[data-page="teacher"] .lesson-side-card,
  body[data-page="teacher"] .settings-card,
  body[data-page="teacher"] .evaluation-card,
  body[data-page="student"] .stat-card,
  body[data-page="student"] .panel-card,
  body[data-page="student"] .welcome-block,
  body[data-page="student"] .quick-access,
  body[data-page="student"] .quick-card,
  body[data-page="student"] .achievement-strip,
  body[data-page="student"] .student-progress-card,
  body[data-page="student"] .student-learn-card,
  body[data-page="student"] .student-learn-summary,
  body[data-page="student"] .student-weekly-goal,
  body[data-page="student"] .student-top-badges,
  body[data-page="student"] .student-milestone-card,
  body[data-page="student"] .student-achievement-mission,
  body[data-page="student"] .student-recent-rewards,
  body[data-page="student"] .student-assessment-list-card,
  body[data-page="student"] .student-assessment-results-card,
  body[data-page="student"] .student-assessment-readiness-card {
    border-radius: 14px;
    padding: 14px;
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.09);
  }

  body[data-page="teacher"] .student-management-header,
  body[data-page="teacher"] .student-management-grid,
  body[data-page="teacher"] .student-right-rail,
  body[data-page="teacher"] .lesson-dashboard-grid,
  body[data-page="teacher"] .lesson-main-column,
  body[data-page="teacher"] .lesson-side-rail,
  body[data-page="student"] .student-home-grid,
  body[data-page="student"] .student-progress-grid,
  body[data-page="student"] .student-learn-layout,
  body[data-page="student"] .student-achievements-layout,
  body[data-page="student"] .student-assessment-layout {
    gap: 12px;
  }

  body[data-page="teacher"] .student-metric-card,
  body[data-page="teacher"] .lesson-metric-card {
    min-height: 78px;
    gap: 10px;
  }

  body[data-page="teacher"] .student-metric-icon,
  body[data-page="teacher"] .lesson-metric-icon,
  body[data-page="student"] .assessment-metric-icon,
  body[data-page="student"] .student-evaluation-icon {
    width: 42px;
    height: 42px;
  }

  body[data-page="teacher"] .student-metric-icon svg,
  body[data-page="teacher"] .lesson-metric-icon svg,
  body[data-page="student"] .assessment-metric-icon svg,
  body[data-page="student"] .student-evaluation-icon svg {
    width: 22px;
    height: 22px;
  }

  body[data-page="teacher"] .student-metric-card strong,
  body[data-page="teacher"] .lesson-metric-card strong,
  body[data-page="student"] .student-assessment-metric-card strong {
    font-size: clamp(24px, 7vw, 34px);
  }

  body[data-page="teacher"] .student-search,
  body[data-page="teacher"] .student-toolbar select,
  body[data-page="teacher"] .export-button,
  body[data-page="teacher"] .segment-button,
  body[data-page="teacher"] .lesson-search,
  body[data-page="teacher"] .lesson-toolbar select {
    height: 43px;
    border-radius: 11px;
  }

  body[data-page="student"] .student-learn-visual {
    min-height: 112px;
  }

  body[data-page="student"] .student-progress-donut,
  body[data-page="student"] .student-goal-donut {
    width: min(148px, 52vw);
    height: min(148px, 52vw);
  }

  body[data-page="student"] .student-hour-bars {
    min-height: 128px;
  }
}

/* Shared dashboard pagination */
.student-pagination.dashboard-pagination {
  display: inline-flex;
  width: fit-content;
  max-width: 100%;
  margin-inline: auto;
  align-items: stretch;
  gap: 0;
  border: 1px solid #dce6f3;
  border-radius: 12px;
  background: #f5f8fc;
  overflow-x: auto;
  box-shadow: 0 7px 18px rgba(31, 65, 112, 0.08);
  scrollbar-width: none;
}

.student-pagination.dashboard-pagination::-webkit-scrollbar {
  display: none;
}

.student-pagination.dashboard-pagination button,
.student-pagination.dashboard-pagination .pagination-current {
  position: relative;
  min-width: 52px;
  height: 42px;
  border: 0;
  border-left: 1px solid #e5ebf4;
  border-radius: 0;
  background: transparent;
  color: #172033;
  font: inherit;
  font-size: 13px;
  font-weight: 850;
}

.student-pagination.dashboard-pagination > :first-child {
  border-left: 0;
}

.student-pagination.dashboard-pagination button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background-color 160ms ease, color 160ms ease;
}

.student-pagination.dashboard-pagination button:hover:not(:disabled),
.student-pagination.dashboard-pagination button:focus-visible {
  background: #e8f2ff;
  color: #1268d8;
}

.student-pagination.dashboard-pagination button:focus-visible {
  z-index: 1;
  outline: 3px solid rgba(31, 123, 242, 0.2);
  outline-offset: -3px;
}

.student-pagination.dashboard-pagination button:disabled {
  background: #f7f9fc;
  color: #b9c3d1;
  cursor: default;
}

.student-pagination.dashboard-pagination .pagination-current {
  min-width: 132px;
  padding: 0 22px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  white-space: nowrap;
}

.student-pagination.dashboard-pagination .pagination-current::after {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  height: 3px;
  border-radius: 3px 3px 0 0;
  background: #1f7bf2;
  content: "";
}

.student-pagination.dashboard-pagination .pagination-current strong {
  margin-left: 4px;
  color: #1268d8;
  font-size: 14px;
}

.student-pagination.dashboard-pagination svg {
  width: 17px;
  height: 17px;
  stroke-width: 2.4;
}

body[data-page="teacher"] .student-table-footer,
body[data-page="teacher"] .lesson-table-footer,
body[data-page="teacher"] .assessment-table-footer,
body[data-page="teacher"] .achievement-list-footer,
body[data-page="teacher"] .profile-pagination-row,
body[data-page="student"] .student-dashboard-pagination-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  justify-items: center;
  gap: 12px;
}

body[data-page="teacher"] .student-pagination.dashboard-pagination,
body[data-page="teacher"] .student-pagination.dashboard-pagination button,
body[data-page="teacher"] .student-pagination.dashboard-pagination .pagination-current {
  border-radius: 0;
}

body[data-page="teacher"] .student-pagination.dashboard-pagination {
  border-radius: 12px;
}

body[data-page="teacher"] .student-pagination.dashboard-pagination button {
  min-width: 48px;
  height: 40px;
  font-size: 12px;
}

body[data-page="teacher"] .student-pagination.dashboard-pagination .pagination-current {
  min-width: 124px;
  height: 40px;
  padding-inline: 18px;
  font-size: 12px;
}

body[data-page="student"] .student-dashboard-pagination-row {
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid #e4ebf5;
  color: #475569;
  font-size: 13px;
  font-weight: 800;
}

@media (max-width: 620px) {
  .student-pagination.dashboard-pagination .pagination-number {
    display: none;
  }

  .student-pagination.dashboard-pagination .pagination-current,
  body[data-page="teacher"] .student-pagination.dashboard-pagination .pagination-current {
    min-width: 116px;
    padding-inline: 14px;
  }

  .student-pagination.dashboard-pagination button,
  body[data-page="teacher"] .student-pagination.dashboard-pagination button {
    min-width: 44px;
  }
}

@media (max-width: 520px) {
  body[data-page="teacher"] .app-sidebar,
  body[data-page="student"] .app-sidebar {
    width: min(226px, calc(100vw - 20px));
    height: auto !important;
    grid-template-columns: 1fr !important;
    grid-template-rows: none !important;
  }

  body[data-page="teacher"] .nav-item,
  body[data-page="student"] .nav-item {
    height: 43px;
    min-height: 43px;
    font-size: 11.5px;
  }

  body[data-page="teacher"] .compact-brand,
  body[data-page="student"] .compact-brand {
    max-width: 44%;
    font-size: clamp(22px, 7.8vw, 30px);
  }

  body[data-page="teacher"] .topbar-profile,
  body[data-page="student"] .topbar-profile {
    max-width: 54%;
  }

  body[data-page="teacher"] .notification-button,
  body[data-page="student"] .notification-button,
  body[data-page="teacher"] .icon-shell,
  body[data-page="student"] .icon-shell {
    width: 38px;
    height: 38px;
    border-radius: 12px;
  }

  body[data-page="teacher"] .student-metric-card,
  body[data-page="teacher"] .lesson-metric-card {
    min-height: 74px;
  }
}

/* Final mobile auth-page guardrails */
@media (max-width: 900px) {
  body[data-page="login"],
  body[data-page="register"] {
    overflow-x: hidden;
  }

  body[data-page="login"] .auth-shell,
  body[data-page="register"] .auth-shell,
  body[data-page="register"] .create-shell {
    width: 100% !important;
    max-width: 100% !important;
    min-height: 100dvh;
    grid-template-columns: minmax(0, 1fr) !important;
    align-items: start;
    justify-content: stretch;
    gap: 18px;
    padding: 18px 14px 30px;
    overflow-x: hidden;
  }

  body[data-page="login"] .brand-panel,
  body[data-page="register"] .brand-panel {
    width: 100%;
    max-width: 100%;
    justify-items: center;
    text-align: center;
    overflow: hidden;
  }

  body[data-page="login"] .brand-mark,
  body[data-page="register"] .brand-mark {
    margin-bottom: 10px;
    font-size: clamp(28px, 8vw, 38px);
  }

  body[data-page="login"] .brand-panel h1,
  body[data-page="register"] .brand-panel h1 {
    max-width: 100%;
    font-size: clamp(32px, 9.5vw, 44px);
    line-height: 1.06;
    overflow-wrap: anywhere;
  }

  body[data-page="login"] .brand-panel p,
  body[data-page="register"] .brand-panel p {
    width: min(100%, 520px);
    margin: 12px auto 14px;
    font-size: 14px;
    line-height: 1.35;
  }

  body[data-page="login"] .asset-stage,
  body[data-page="register"] .asset-stage {
    width: min(100%, 380px);
    margin: 0 auto;
    border-radius: 16px;
    box-shadow: 0 10px 22px rgba(18, 31, 55, 0.12);
  }

  body[data-page="login"] .feature-strip,
  body[data-page="register"] .feature-strip {
    width: min(100%, 380px);
    min-height: 0;
    margin: 12px auto 0;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    padding: 12px;
    border-radius: 14px;
    box-shadow: 0 10px 22px rgba(18, 31, 55, 0.1);
  }

  body[data-page="login"] .feature-strip div,
  body[data-page="register"] .feature-strip div {
    justify-content: flex-start;
    gap: 8px;
    font-size: 11px;
  }

  body[data-page="login"] .feature-strip svg,
  body[data-page="register"] .feature-strip svg {
    width: 22px;
    height: 22px;
  }

  body[data-page="login"] .form-card,
  body[data-page="register"] .form-card,
  body[data-page="login"] .login-card,
  body[data-page="register"] .create-card {
    width: min(100%, 520px) !important;
    max-width: 100% !important;
    justify-self: center;
    margin: 0 auto;
    border-radius: 18px;
    padding: 22px 16px;
    box-shadow: 0 12px 28px rgba(18, 31, 55, 0.14);
  }

  body[data-page="login"] .login-card .form-heading,
  body[data-page="register"] .form-heading {
    margin-bottom: 16px;
  }

  body[data-page="login"] .login-card .form-heading h2,
  body[data-page="register"] .form-heading h2 {
    font-size: 28px;
  }

  body[data-page="login"] .login-card .form-heading p,
  body[data-page="register"] .form-heading p {
    font-size: 13px;
  }

  body[data-page="login"] .login-card .form-stack,
  body[data-page="register"] .form-stack,
  body[data-page="register"] .form-stack.compact {
    gap: 13px;
  }

  body[data-page="login"] .field-grid,
  body[data-page="register"] .field-grid {
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 12px;
  }

  body[data-page="login"] .field,
  body[data-page="register"] .field {
    min-width: 0;
    gap: 7px;
    font-size: 14px;
  }

  body[data-page="login"] .input-wrap,
  body[data-page="register"] .input-wrap,
  body[data-page="login"] .login-card .input-wrap,
  body[data-page="register"] .compact .input-wrap {
    width: 100%;
    max-width: 100%;
    height: 48px;
    min-width: 0;
    padding: 0 12px;
    border-radius: 12px;
  }

  body[data-page="login"] .input-wrap input,
  body[data-page="register"] .input-wrap input,
  body[data-page="register"] .input-wrap select {
    min-width: 0;
    font-size: 13px;
  }

  body[data-page="login"] .form-row {
    margin: 0 0 8px;
    align-items: flex-start;
    gap: 10px;
  }

  body[data-page="login"] .check-label,
  body[data-page="register"] .check-label {
    min-width: 0;
    font-size: 12px;
    line-height: 1.3;
  }

  body[data-page="login"] .primary-button,
  body[data-page="login"] .outline-button,
  body[data-page="register"] .primary-button,
  body[data-page="register"] .outline-button {
    min-height: 48px;
    width: 100%;
    border-radius: 12px;
    font-size: 15px;
  }
}

@media (max-width: 430px) {
  body[data-page="login"] .auth-shell,
  body[data-page="register"] .auth-shell,
  body[data-page="register"] .create-shell {
    padding: 14px 10px 24px;
    gap: 14px;
  }

  body[data-page="login"] .brand-panel h1,
  body[data-page="register"] .brand-panel h1 {
    font-size: clamp(28px, 9vw, 38px);
  }

  body[data-page="login"] .brand-panel p,
  body[data-page="register"] .brand-panel p {
    font-size: 12.5px;
  }

  body[data-page="login"] .asset-stage,
  body[data-page="register"] .asset-stage {
    width: min(100%, 320px);
  }

  body[data-page="login"] .feature-strip,
  body[data-page="register"] .feature-strip {
    width: min(100%, 320px);
    padding: 10px;
  }

  body[data-page="login"] .form-card,
  body[data-page="register"] .form-card,
  body[data-page="login"] .login-card,
  body[data-page="register"] .create-card {
    padding: 18px 12px;
  }
}

/* Final authoring/evaluation polish overrides */
.lesson-author-drawer .lesson-drawer-panel {
  width: min(1180px, calc(100vw - 40px));
  max-width: min(1180px, calc(100vw - 40px));
  overflow-x: hidden;
  overscroll-behavior: contain;
  box-sizing: border-box;
}

.lesson-author-drawer .student-drawer-backdrop {
  overscroll-behavior: contain;
}

.lesson-drawer-panel .simple-grid,
.lesson-drawer-panel .field-grid {
  min-width: 0;
}

.lesson-drawer-panel .field-grid > *,
.lesson-drawer-panel label {
  min-width: 0;
}

.lesson-drawer-panel .drawer-actions {
  position: sticky;
  bottom: -24px;
  margin: 8px -24px -24px;
  padding: 14px 24px 18px;
  width: calc(100% + 48px);
  max-width: calc(100% + 48px);
  box-sizing: border-box;
  background: rgba(255, 255, 255, 0.96);
  border-top: 1px solid #e5ebf4;
  backdrop-filter: blur(10px);
}

.evaluation-setup-card .evaluation-note {
  max-width: 720px;
  line-height: 1.45;
}

.evaluation-setup-card .primary-button {
  width: 100%;
}

.evaluation-gain-card b.good,
.evaluation-gain-card b.danger {
  justify-self: start;
}

@media (max-width: 980px) {
  .lesson-author-drawer .lesson-drawer-panel {
    width: calc(100vw - 24px);
    max-width: calc(100vw - 24px);
    height: calc(100vh - 24px);
    max-height: calc(100vh - 24px);
    margin: 12px 0;
    padding: 18px;
    border-radius: 14px;
  }

  .lesson-tab-panel[data-lesson-panel="details"].active,
  .lesson-tab-panel[data-lesson-panel="resources"].active,
  .evaluation-setup-card .field-grid {
    grid-template-columns: 1fr;
  }

  .lesson-drawer-panel .drawer-actions {
    bottom: -18px;
    margin: 8px -18px -18px;
    padding: 12px 18px 16px;
    width: calc(100% + 36px);
    max-width: calc(100% + 36px);
  }

  .evaluation-setup-heading {
    display: grid;
    grid-template-columns: 1fr;
  }

  .inline-toggle {
    min-width: 0;
    max-width: none;
    width: 100%;
  }
}

@media (max-width: 640px) {
  .lesson-library-header {
    align-items: stretch;
  }

  .lesson-library-actions {
    width: 100%;
    justify-content: space-between;
  }

  .lesson-library-actions .primary-button {
    flex: 1 1 auto;
  }

  .lesson-author-tabs {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .author-panel-heading,
  .author-item-top {
    align-items: stretch;
  }

  .author-panel-heading .small-button,
  .author-item-top .icon-button {
    align-self: start;
  }

  .lesson-drawer-panel .drawer-actions {
    grid-template-columns: 1fr;
  }
}

/* Teacher home refresh inspired by the reference dashboard. */
body[data-page="teacher"] .app-shell {
  grid-template-columns: clamp(184px, 14vw, 232px) minmax(0, 1fr);
  background: #f3f6fb;
}

body[data-page="teacher"] .app-sidebar {
  margin: 16px 0 16px 16px;
  height: calc(100vh - 32px);
  padding: 18px 12px;
  border: 1px solid #e3eaf4;
  border-radius: 24px;
  background: #fff;
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.08);
}

body[data-page="teacher"] .app-sidebar .nav-item {
  border-radius: 18px;
  color: #667085;
  font-weight: 800;
}

body[data-page="teacher"] .app-sidebar .nav-item.active,
body[data-page="teacher"] .app-sidebar .nav-item:hover {
  background: #1f7bf2;
  color: #fff;
  box-shadow: 0 12px 24px rgba(31, 123, 242, 0.22);
}

body[data-page="teacher"] .app-topbar {
  min-height: 92px;
  margin: 16px 16px 0;
  border: 1px solid #e3eaf4;
  border-radius: 24px;
  background: #fff;
  box-shadow: 0 14px 34px rgba(15, 23, 42, 0.07);
}

body[data-page="teacher"] .compact-brand {
  font-size: clamp(30px, 2.7vw, 42px);
  font-weight: 900;
}

body[data-page="teacher"] .profile-badge {
  width: 58px;
  height: 58px;
  box-shadow: 0 10px 24px rgba(31, 123, 242, 0.16);
}

body[data-page="teacher"] .topbar-profile strong {
  font-size: clamp(17px, 1.45vw, 24px);
}

body[data-page="teacher"] .topbar-profile span {
  font-size: 14px;
}

body[data-page="teacher"] .teacher-section.active[data-view="overview"] {
  padding: 22px 16px 28px;
}

.teacher-home-surface {
  display: grid;
  gap: 20px;
}

.teacher-home-hero {
  min-height: 118px;
  padding: 22px 24px;
  border: 1px solid #e3eaf4;
  border-radius: 24px;
  background: #fff;
  box-shadow: 0 16px 36px rgba(15, 23, 42, 0.07);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.teacher-home-hero h1,
.teacher-home-hero p {
  margin: 0;
}

.teacher-home-hero h1 {
  margin-top: 9px;
  color: #07111f;
  font-size: clamp(30px, 3vw, 44px);
  line-height: 1.02;
  font-weight: 900;
}

.teacher-home-hero p {
  max-width: 700px;
  margin-top: 8px;
  color: #667085;
  font-weight: 700;
  line-height: 1.45;
}

.home-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 11px;
  border-radius: 999px;
  background: #eef6ff;
  color: #1f7bf2;
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.home-eyebrow svg {
  width: 16px;
  height: 16px;
}

.home-hero-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  flex-wrap: wrap;
}

.compact-action {
  width: auto;
  flex: 0 0 auto;
  min-height: 46px;
  padding: 0 18px;
  border-radius: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.teacher-home-metrics {
  gap: 16px;
  margin-bottom: 0;
}

.teacher-home-metrics .stat-card {
  min-height: 126px;
  padding: 18px;
  border-radius: 22px;
  border-color: #e3eaf4;
  box-shadow: 0 16px 34px rgba(15, 23, 42, 0.07);
  gap: 16px;
}

.teacher-home-metrics .stat-icon {
  width: 58px;
  height: 58px;
  border-radius: 18px;
}

.teacher-home-metrics .stat-icon svg {
  width: 29px;
  height: 29px;
}

.teacher-home-metrics .stat-card strong {
  margin-top: 3px;
  font-size: 34px;
  font-weight: 900;
}

.teacher-home-metrics .stat-card p,
.teacher-home-metrics .stat-card small {
  font-size: 13px;
}

.teacher-home-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(290px, 360px);
  gap: 20px;
  align-items: start;
}

.teacher-home-rail {
  display: grid;
  gap: 20px;
}

.home-side-card {
  padding: 20px;
  border-radius: 22px;
  box-shadow: 0 16px 34px rgba(15, 23, 42, 0.07);
}

body[data-page="teacher"] .capstone-evidence-panel {
  min-width: 0;
  margin-top: 0;
  padding: 22px;
  border-radius: 24px;
  border-color: #e3eaf4;
  box-shadow: 0 16px 34px rgba(15, 23, 42, 0.07);
}

body[data-page="teacher"] .capstone-evidence-header {
  align-items: center;
  margin-bottom: 18px;
}

body[data-page="teacher"] .capstone-evidence-header h1 {
  font-size: clamp(25px, 2.2vw, 34px);
  font-weight: 900;
}

body[data-page="teacher"] .capstone-evidence-header p {
  max-width: 640px;
  color: #667085;
  font-size: 14px;
}

body[data-page="teacher"] .evidence-toolbar {
  grid-template-columns: minmax(180px, 1fr) auto;
  justify-items: stretch;
}

body[data-page="teacher"] .evidence-export-actions {
  grid-column: 1 / -1;
  justify-content: flex-end;
}

body[data-page="teacher"] .evidence-toolbar select,
body[data-page="teacher"] .evidence-quarter-pill,
body[data-page="teacher"] .evidence-export-actions button,
body[data-page="teacher"] .small-button,
body[data-page="teacher"] .link-button {
  border-radius: 14px;
}

body[data-page="teacher"] .evidence-metric-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

body[data-page="teacher"] .evidence-metric-grid article {
  min-height: 118px;
  border-radius: 18px;
  background: #fff;
  box-shadow: inset 0 0 0 1px rgba(227, 234, 244, 0.3);
}

body[data-page="teacher"] .evidence-active-summary {
  border-radius: 18px;
}

body[data-page="teacher"] .evidence-dashboard-grid {
  grid-template-columns: minmax(0, 1.05fr) minmax(300px, 0.95fr);
  gap: 14px;
}

body[data-page="teacher"] .evidence-card {
  border-radius: 20px;
  background: #fff;
  box-shadow: inset 0 0 0 1px rgba(227, 234, 244, 0.35);
}

body[data-page="teacher"] .evidence-card h2,
body[data-page="teacher"] .panel-title-row h2 {
  color: #07111f;
  font-size: 20px;
  font-weight: 900;
}

body[data-page="teacher"] .evidence-chip {
  background: #f2f6fb;
  color: #52637a;
}

body[data-page="teacher"] .evidence-mastery-list article,
body[data-page="teacher"] .evidence-intervention-list article,
body[data-page="teacher"] .evidence-readiness-list article,
body[data-page="teacher"] .compact-list .mini-row {
  border-radius: 16px;
  background: #f9fbfe;
}

body[data-page="teacher"] .quarter-spotlight {
  min-height: 160px;
  border: 1px solid #d9e7ff;
  border-radius: 18px;
  background: linear-gradient(135deg, #eef6ff 0%, #f8fbff 100%);
}

body[data-page="teacher"] .quarter-spotlight strong {
  color: #07111f;
  font-size: 30px;
  line-height: 1;
}

body[data-page="teacher"] .quarter-spotlight span,
body[data-page="teacher"] .quarter-spotlight p {
  margin: 0;
  color: #667085;
  font-weight: 800;
}

.evidence-mastery-overview {
  padding: 14px;
  border: 1px solid #e3eaf4;
  border-radius: 18px;
  background: #f8fbff;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 14px;
  align-items: center;
}

.evidence-mastery-overview > div:last-child {
  min-width: 0;
}

.evidence-mastery-overview strong,
.evidence-mastery-overview span {
  display: block;
}

.evidence-mastery-overview > div:last-child strong {
  color: #07111f;
  font-size: 16px;
  font-weight: 900;
}

.evidence-mastery-overview > div:last-child span {
  margin-top: 4px;
  color: #667085;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.35;
}

.mastery-ring {
  --mastery: 0;
  width: 82px;
  height: 82px;
  border-radius: 999px;
  background:
    radial-gradient(circle at center, #fff 0 55%, transparent 56%),
    conic-gradient(#1f7bf2 calc(var(--mastery) * 1%), #e6edf7 0);
  display: grid;
  place-items: center;
  align-content: center;
  box-shadow: inset 0 0 0 1px #dce7f5;
}

.mastery-ring.warn {
  background:
    radial-gradient(circle at center, #fff 0 55%, transparent 56%),
    conic-gradient(#f97316 calc(var(--mastery) * 1%), #e6edf7 0);
}

.mastery-ring strong {
  color: #07111f;
  font-size: 20px;
  line-height: 1;
  font-weight: 900;
}

.mastery-ring span {
  color: #667085;
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.evidence-line-chart {
  min-height: 150px;
  padding: 12px;
  border: 1px solid #e3eaf4;
  border-radius: 18px;
  background: linear-gradient(180deg, #f8fbff 0%, #fff 100%);
}

.evidence-line-chart svg {
  display: block;
  width: 100%;
  height: 150px;
  overflow: visible;
}

.chart-grid-line {
  fill: none;
  stroke: #e3eaf4;
  stroke-width: 1;
}

.chart-area {
  fill: rgba(31, 123, 242, 0.1);
}

.chart-line {
  fill: none;
  stroke: #1f7bf2;
  stroke-width: 6;
  stroke-linecap: round;
}

.chart-point {
  fill: #fff;
  stroke-width: 5;
}

.chart-point.pre {
  stroke: #9dbff7;
}

.chart-point.post {
  stroke: #1f7bf2;
}

@media (max-width: 1180px) {
  body[data-page="teacher"] .app-shell {
    grid-template-columns: clamp(132px, 12.5vw, 190px) minmax(0, 1fr);
  }

  .teacher-home-layout,
  body[data-page="teacher"] .capstone-evidence-header,
  body[data-page="teacher"] .evidence-dashboard-grid {
    grid-template-columns: 1fr;
  }

  .teacher-home-rail {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 840px) {
  body[data-page="teacher"] .app-shell {
    grid-template-columns: 1fr;
  }

  body[data-page="teacher"] .app-sidebar {
    margin: 0;
    border-radius: 18px;
  }

  body[data-page="teacher"] .app-topbar {
    margin: 0;
    border-radius: 0;
  }
}

@media (max-width: 760px) {
  body[data-page="teacher"] .app-sidebar {
    border-radius: 18px;
  }

  body[data-page="teacher"] .app-topbar {
    border-radius: 0;
  }

  body[data-page="teacher"] .teacher-section.active[data-view="overview"] {
    padding: 16px;
  }

  .teacher-home-hero {
    align-items: stretch;
    flex-direction: column;
  }

  .home-hero-actions,
  body[data-page="teacher"] .evidence-export-actions {
    justify-content: flex-start;
  }

  .teacher-home-rail,
  body[data-page="teacher"] .evidence-metric-grid,
  body[data-page="teacher"] .evidence-toolbar {
    grid-template-columns: 1fr;
  }
}

/* Portal-wide polish from the Lessons & Modules reference image. */
body[data-page="teacher"],
body[data-page="student"] {
  background: var(--page-bg);
}

body[data-page="teacher"] .app-shell,
body[data-page="student"] .app-shell {
  background: var(--page-bg);
}

@media (min-width: 841px) {
  body[data-page="teacher"] .app-shell,
  body[data-page="student"] .app-shell {
    grid-template-columns: clamp(236px, 17vw, 292px) minmax(0, 1fr);
  }

  body[data-page="teacher"] .app-sidebar,
  body[data-page="student"] .app-sidebar {
    position: sticky;
    top: 0;
    height: 100vh;
    margin: 0;
    padding: 18px 16px 14px;
    border: 0;
    border-right: 1px solid var(--border-color);
    border-radius: 0;
    background: #fff;
    box-shadow: none;
    display: flex;
    flex-direction: column;
    gap: 6px;
    overflow: hidden;
  }

  body[data-page="teacher"] .app-sidebar .nav-item,
  body[data-page="student"] .app-sidebar .nav-item {
    min-height: 44px;
    height: auto;
    padding: 0 12px;
    border-radius: 12px;
    display: grid;
    grid-template-columns: 24px minmax(0, 1fr);
    place-items: center start;
    gap: 10px;
    color: #344054;
    font-size: 13px;
    font-weight: 800;
    text-align: left;
  }

  body[data-page="teacher"] .app-sidebar .nav-item svg,
  body[data-page="student"] .app-sidebar .nav-item svg {
    width: 20px;
    height: 20px;
  }
}

.sidebar-brand-block {
  min-width: 0;
  margin-bottom: 12px;
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
}

.sidebar-logo-mark {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  background: linear-gradient(135deg, #1f7bf2 0%, #0d63d8 100%);
  color: #fff;
  display: grid;
  place-items: center;
  box-shadow: 0 12px 20px rgba(31, 123, 242, 0.2);
}

.sidebar-logo-mark svg {
  width: 22px;
  height: 22px;
}

.sidebar-brand-block strong,
.sidebar-brand-block small,
.sidebar-help-card strong,
.sidebar-help-card small {
  display: block;
}

.sidebar-brand-block strong {
  color: var(--text-primary);
  font-size: 18px;
  line-height: 1.05;
  font-weight: 900;
}

.sidebar-brand-block small {
  margin-top: 3px;
  color: var(--text-muted);
  font-size: 10px;
  font-weight: 700;
}

.sidebar-help-card {
  margin-top: auto;
  padding: 12px;
  border: 1px solid #d8e7ff;
  border-radius: 16px;
  background: linear-gradient(180deg, #eef6ff 0%, #f9fbff 100%);
  color: var(--text-primary);
  text-align: center;
}

.sidebar-help-card > span {
  width: 48px;
  height: 48px;
  margin: 0 auto 8px;
  border-radius: 15px;
  background: #fff;
  color: var(--primary-blue);
  display: grid;
  place-items: center;
  box-shadow: 0 12px 24px rgba(31, 123, 242, 0.14);
}

.sidebar-help-card svg {
  width: 24px;
  height: 24px;
}

.sidebar-help-card strong {
  font-size: 13px;
  font-weight: 900;
}

.sidebar-help-card small {
  margin-top: 5px;
  color: var(--text-muted);
  font-size: 10px;
  font-weight: 700;
  line-height: 1.35;
}

body[data-page="teacher"] .app-sidebar .nav-item.active,
body[data-page="teacher"] .app-sidebar .nav-item:hover,
body[data-page="student"] .app-sidebar .nav-item.active,
body[data-page="student"] .app-sidebar .nav-item:hover {
  background: var(--primary-blue);
  color: #fff;
  box-shadow: 0 12px 24px rgba(20, 103, 242, 0.22);
}

body[data-page="teacher"] .app-topbar,
body[data-page="student"] .app-topbar {
  min-height: 78px;
  margin: 0;
  padding: 16px 26px;
  border: 0;
  border-bottom: 1px solid var(--border-color);
  border-radius: 0;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: none;
}

body[data-page="teacher"] .compact-brand,
body[data-page="student"] .compact-brand {
  font-size: clamp(26px, 2.2vw, 36px);
  font-weight: 900;
}

body[data-page="teacher"] .profile-badge,
body[data-page="student"] .profile-badge,
.topbar-avatar {
  width: 48px;
  height: 48px;
  border: 1px solid var(--border-color);
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
}

body[data-page="teacher"] .notification-button,
body[data-page="student"] .notification-button,
body[data-page="teacher"] .icon-shell,
body[data-page="student"] .icon-shell,
.lesson-icon-button,
.icon-button {
  border-radius: 12px;
  border: 1px solid var(--border-color);
  background: #fff;
}

body[data-page="teacher"] .teacher-section,
body[data-page="student"] .student-section {
  padding: 24px 26px 28px;
}

.lesson-page-heading {
  margin-bottom: 18px;
  padding: 0 10px;
}

.lesson-page-heading h1 {
  font-size: clamp(26px, 2.4vw, 34px);
  font-weight: 900;
}

.lesson-page-heading p {
  color: var(--text-muted);
  font-size: 14px;
  font-weight: 700;
}

.lesson-page-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
}

body[data-page="teacher"] .lesson-dashboard-grid {
  grid-template-columns: minmax(0, 1fr) minmax(300px, 360px);
  gap: 18px;
}

body[data-page="teacher"] .lesson-metric-grid {
  gap: 14px;
}

body[data-page="teacher"] .lesson-metric-card,
body[data-page="teacher"] .lesson-library-card,
body[data-page="teacher"] .lesson-side-card,
body[data-page="teacher"] .assessment-library-card,
body[data-page="teacher"] .assessment-insight-card,
body[data-page="teacher"] .student-table-card,
body[data-page="teacher"] .student-side-card,
body[data-page="teacher"] .panel-card,
body[data-page="student"] .panel-card,
body[data-page="student"] .welcome-block,
body[data-page="student"] .quick-card,
body[data-page="student"] .lesson-card,
body[data-page="student"] .achievement-card {
  border: 1px solid var(--border-color);
  border-radius: 18px;
  background: var(--card-bg);
  box-shadow: var(--card-shadow);
}

body[data-page="teacher"] .lesson-metric-card {
  min-height: 104px;
  padding: 16px;
}

body[data-page="teacher"] .lesson-metric-icon,
body[data-page="teacher"] .assessment-metric-icon,
body[data-page="teacher"] .student-metric-icon,
body[data-page="teacher"] .assessment-row-icon,
body[data-page="teacher"] .lesson-type-icon {
  border-radius: 14px;
}

body[data-page="teacher"] .lesson-library-card {
  padding: 0;
  overflow: hidden;
}

body[data-page="teacher"] .lesson-library-header {
  margin: 0;
  padding: 20px 22px;
  border-bottom: 1px solid var(--border-color);
}

body[data-page="teacher"] .lesson-library-header h1 {
  font-size: 21px;
  font-weight: 900;
}

body[data-page="teacher"] .lesson-toolbar {
  margin: 0;
  padding: 18px 22px;
  border-bottom: 1px solid var(--border-color);
  background: #fff;
}

body[data-page="teacher"] .lesson-search,
body[data-page="teacher"] .lesson-toolbar select,
body[data-page="teacher"] .assessment-toolbar select,
body[data-page="teacher"] .assessment-search,
body[data-page="teacher"] .student-search,
body[data-page="teacher"] .student-toolbar select,
.student-drawer-panel input,
.student-drawer-panel select,
.student-drawer-panel textarea {
  height: 46px;
  min-height: 46px;
  border: 1px solid #d8e2f0;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 1px 0 rgba(15, 23, 42, 0.02);
}

.student-drawer-panel textarea {
  height: auto;
  min-height: 92px;
}

body[data-page="teacher"] .lesson-table-heading,
body[data-page="teacher"] .lesson-row {
  grid-template-columns: minmax(210px, 1.4fr) minmax(108px, 0.55fr) minmax(84px, 0.36fr) minmax(78px, 0.34fr) minmax(96px, 0.42fr) minmax(300px, 0.9fr);
  gap: 8px;
}

body[data-page="teacher"] .lesson-table-heading {
  padding: 12px 22px;
  border-bottom: 1px solid var(--border-color);
  color: #475467;
  background: #f8fafc;
  font-size: 11px;
  text-transform: none;
}

body[data-page="teacher"] .lesson-row-list {
  border: 0;
  border-radius: 0;
}

body[data-page="teacher"] .lesson-row {
  min-height: 88px;
  padding: 16px 18px 16px 22px;
  border-bottom: 1px solid #edf1f7;
}

body[data-page="teacher"] .lesson-row:hover {
  background: #f8fbff;
  box-shadow: inset 3px 0 0 var(--primary-blue);
}

body[data-page="teacher"] .lesson-row.package-row {
  background: #f7fbff;
}

@media (min-width: 841px) {
  body[data-page="teacher"] .lesson-actions {
    flex-wrap: nowrap;
    gap: 7px;
  }

  body[data-page="teacher"] .lesson-actions .small-button {
    min-height: 34px;
    padding: 0 9px;
    font-size: 11px;
    line-height: 1;
  }

  body[data-page="teacher"] .lesson-actions .icon-button {
    width: 34px;
    height: 34px;
    min-width: 34px;
  }
}

body[data-page="teacher"] .lesson-table-footer {
  padding: 16px 22px;
  background: #fff;
}

body[data-page="teacher"] .lesson-side-rail {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 18px;
  align-content: start;
  min-width: 0;
}

body[data-page="teacher"] .lesson-side-card {
  min-width: 0;
  padding: 20px;
  border-radius: 20px;
  overflow: hidden;
}

body[data-page="teacher"] .lesson-side-card h2 {
  color: var(--text-primary);
  font-size: 20px;
  font-weight: 900;
}

body[data-page="teacher"] .upload-card {
  position: static;
  top: auto;
}

body[data-page="teacher"] .lesson-drop-zone {
  border-radius: 18px;
  border-color: #bfd7ff;
  background: #f8fbff;
}

.primary-button,
.export-button,
body[data-page="teacher"] .evidence-export-actions button {
  border-radius: 12px;
  background: var(--primary-blue);
  box-shadow: 0 10px 20px rgba(20, 103, 242, 0.16);
}

.primary-button:hover:not(:disabled),
.export-button:hover:not(:disabled),
body[data-page="teacher"] .evidence-export-actions button:hover:not(:disabled) {
  background: var(--primary-blue-hover);
}

body[data-page="teacher"] .primary-button,
body[data-page="teacher"] .export-button,
body[data-page="teacher"] .evidence-export-actions button {
  color: #fff;
}

body[data-page="teacher"] .primary-button svg,
body[data-page="teacher"] .export-button svg,
body[data-page="teacher"] .evidence-export-actions button svg,
.report-download-actions button svg {
  color: currentColor;
  stroke: currentColor;
}

body[data-page="teacher"] .evidence-export-actions button:last-child {
  background: #fff;
  color: var(--primary-blue);
  border: 1px solid #bdd4ff;
  box-shadow: none;
}

body[data-page="teacher"] .evidence-export-actions button:last-child:hover {
  background: #eef4ff;
  color: var(--primary-blue-hover);
}

body[data-page="teacher"] .primary-button:disabled,
body[data-page="teacher"] .export-button:disabled,
body[data-page="teacher"] .evidence-export-actions button:disabled,
body[data-page="teacher"] .primary-button.is-loading,
body[data-page="teacher"] .export-button.is-loading,
body[data-page="teacher"] .evidence-export-actions button.is-loading {
  border-color: #d8e2f0;
  background: #e8eef8;
  color: #667085;
  box-shadow: none;
  opacity: 1;
  cursor: not-allowed;
}

body[data-page="teacher"] .primary-button:disabled .button-spinner,
body[data-page="teacher"] .export-button:disabled .button-spinner,
body[data-page="teacher"] .evidence-export-actions button:disabled .button-spinner,
body[data-page="teacher"] .primary-button.is-loading .button-spinner,
body[data-page="teacher"] .export-button.is-loading .button-spinner,
body[data-page="teacher"] .evidence-export-actions button.is-loading .button-spinner {
  border-color: rgba(102, 112, 133, 0.28);
  border-top-color: #667085;
}

.small-button,
.link-button,
.lesson-actions .small-button,
.assessment-actions .small-button {
  border-radius: 12px;
}

.status-pill,
.assessment-type-pill,
.category-pill,
.time-pill,
.evidence-chip {
  border-radius: 999px;
  font-weight: 900;
}

.status-pill.published,
.status-pill.approved,
.status-pill.completed,
.status-pill.active,
.status-pill.passed {
  background: #dcfce7;
  color: #15803d;
}

.status-pill.draft,
.status-pill.not-started,
.status-pill.not_started {
  background: #eef4ff;
  color: #2563eb;
}

.status-pill.pending,
.status-pill.in-progress,
.status-pill.in_progress,
.status-pill.scheduled,
.status-pill.medium-priority {
  background: #fff4e6;
  color: #c2410c;
}

.status-pill.rejected,
.status-pill.archived,
.status-pill.failed,
.status-pill.high-priority,
.status-pill.overdue {
  background: #fff1f3;
  color: #d93245;
}

.student-drawer-panel {
  border-left: 1px solid var(--border-color);
  background: #fff;
  box-shadow: -24px 0 50px rgba(15, 23, 42, 0.16);
}

.student-drawer-panel header {
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border-color);
}

.drawer-summary {
  border: 1px solid #d8e7ff;
  border-radius: 18px;
  background: #f8fbff;
}

.notification-panel,
.app-modal,
.modal-card {
  border: 1px solid var(--border-color);
  border-radius: 18px;
  box-shadow: 0 24px 54px rgba(15, 23, 42, 0.16);
}

body[data-page="login"],
body[data-page="register"] {
  background:
    linear-gradient(180deg, rgba(238, 246, 255, 0.7) 0%, rgba(245, 247, 251, 0) 42%),
    var(--page-bg);
}

body[data-page="login"] .form-card,
body[data-page="register"] .form-card {
  border: 1px solid var(--border-color);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: var(--card-shadow);
}

body[data-page="login"] .input-wrap,
body[data-page="register"] .input-wrap {
  border-color: #d8e2f0;
  border-radius: 14px;
  background: #fff;
}

body[data-page="login"] .feature-strip,
body[data-page="register"] .feature-strip {
  border: 1px solid var(--border-color);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 14px 30px rgba(15, 23, 42, 0.06);
}

body[data-page="login"] .feature-strip div,
body[data-page="register"] .feature-strip div {
  min-height: 52px;
  padding: 8px;
  border: 1px solid rgba(216, 231, 255, 0.82);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.78);
}

body[data-page="login"] .feature-strip svg,
body[data-page="register"] .feature-strip svg {
  padding: 5px;
  border-radius: 10px;
  background: var(--light-blue-bg);
}

body[data-page="login"] .asset-stage,
body[data-page="register"] .asset-stage {
  border: 1px solid #d8e7ff;
  border-radius: 24px;
  background: #f8fbff;
}

body[data-page="login"] .brand-panel,
body[data-page="register"] .brand-panel {
  padding: clamp(18px, 2.5vw, 28px);
  border: 1px solid rgba(216, 231, 255, 0.7);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.42);
  box-shadow: 0 18px 44px rgba(15, 23, 42, 0.05);
}

body[data-page="login"] .brand-mark,
body[data-page="register"] .brand-mark {
  padding: 10px 14px;
  border: 1px solid #d8e7ff;
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 10px 26px rgba(15, 23, 42, 0.06);
}

.achievement-management-header,
.teacher-achievements-dashboard {
  width: 100%;
}

.achievement-management-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 20px;
}

.achievement-management-header h1 {
  margin: 4px 0 6px;
  font-size: clamp(28px, 3vw, 42px);
}

.achievement-management-header p,
.achievement-tab-bar p,
.certificate-template-option p {
  margin: 0;
  color: #64748b;
  font-weight: 700;
}

.achievement-summary-grid,
.achievement-workspace-grid {
  display: grid;
  gap: 16px;
}

.achievement-summary-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-bottom: 18px;
}

.achievement-summary-grid .stat-card {
  min-height: 116px;
  padding: 20px;
  border: 1px solid var(--border-color);
  border-radius: 18px;
  background: #fff;
  box-shadow: var(--card-shadow);
}

.achievement-summary-grid .stat-icon {
  width: 58px;
  height: 58px;
  border-radius: 16px;
}

.achievement-summary-grid .stat-icon svg {
  width: 30px;
  height: 30px;
}

.achievement-summary-grid .stat-card strong {
  font-size: clamp(24px, 2.4vw, 34px);
}

.achievement-tab-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 18px;
  padding: 8px;
  border: 1px solid var(--border-color);
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.05);
}

.achievement-tab-bar button,
.achievement-quick-actions button,
.student-awards-list button,
.history-row-actions button,
.student-certificate-actions button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid #d8e4f5;
  border-radius: 8px;
  background: #fff;
  color: #1d4ed8;
  font-weight: 900;
  cursor: pointer;
}

.achievement-tab-bar button {
  min-height: 48px;
  padding: 0 16px;
  border-radius: 12px;
}

.achievement-tab-bar button.active {
  border-color: #1f75ff;
  background: #1f75ff;
  color: #fff;
}

.achievement-workspace-grid {
  grid-template-columns: minmax(0, 1.15fr) minmax(320px, 0.85fr);
  margin-bottom: 16px;
}

.achievement-workspace-grid.two-column {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.overview-student-awards-card {
  margin-bottom: 16px;
}

.achievement-snapshot-header {
  align-items: flex-start;
}

.achievement-snapshot-header .page-action-row {
  justify-content: flex-end;
}

.award-tools-grid {
  align-items: start;
}

.achievement-template-card,
.achievement-awards-card,
.certificate-template-library,
.badge-design-library,
.student-awards-table-card {
  overflow: hidden;
}

.certificate-preview {
  width: 100%;
  overflow: hidden;
  border: 1px solid #d8e4f5;
  border-radius: 8px;
  background: #f8fbff;
}

.certificate-preview-stage {
  position: relative;
  width: 100%;
  aspect-ratio: 1685 / 1191;
  overflow: hidden;
  background: #fff;
  color: #2b1767;
  container-type: inline-size;
  font-family: Georgia, "Times New Roman", serif;
}

.certificate-preview-stage img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.certificate-preview-stage.is-expandable {
  cursor: zoom-in;
}

.certificate-preview-stage.is-expandable:focus-visible {
  outline: 3px solid rgba(31, 117, 255, 0.45);
  outline-offset: -5px;
}

.certificate-overlay {
  position: absolute;
  z-index: 1;
  left: 50%;
  max-width: 78%;
  text-align: center;
  transform: translateX(-50%);
}

.certificate-recipient {
  top: 52.6%;
  max-width: 66%;
  font-size: clamp(30px, 8cqw, 78px);
  line-height: 0.95;
  white-space: nowrap;
}

.certificate-achievement {
  top: 72.7%;
  max-width: 52%;
  color: #111827;
  font-size: clamp(10px, 1.95cqw, 22px);
  font-weight: 600;
  line-height: 1.15;
}

.certificate-date {
  top: 77.2%;
  color: #111827;
  font-size: clamp(10px, 1.75cqw, 20px);
  line-height: 1.1;
}

.certificate-principal,
.certificate-teacher {
  top: 83.8%;
  width: 28%;
  color: #2b1767;
  font-size: clamp(12px, 2.35cqw, 26px);
  line-height: 1;
  white-space: nowrap;
}

.certificate-principal {
  left: 30%;
}

.certificate-teacher {
  left: 69%;
}

.certificate-number {
  top: 92.8%;
  left: auto;
  right: 9%;
  max-width: 24%;
  color: #64748b;
  font-family: Poppins, sans-serif;
  font-size: clamp(7px, 1cqw, 12px);
  transform: none;
}

.certificate-preview.compact .certificate-preview-stage {
  min-height: 0;
}

.certificate-template-grid,
.badge-design-grid,
.student-awards-list,
.achievement-history-list {
  display: grid;
  gap: 12px;
}

.certificate-template-option {
  display: grid;
  grid-template-columns: minmax(260px, 0.9fr) minmax(220px, 1fr);
  gap: 18px;
  align-items: center;
  padding: 14px;
  border: 1px solid #d8e4f5;
  border-radius: 8px;
  background: #fff;
}

.badge-design-grid {
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.badge-design-grid article,
.award-mini-stats article {
  display: grid;
  gap: 8px;
  padding: 16px;
  border: 1px solid #d8e4f5;
  border-radius: 8px;
  background: #f8fbff;
}

.badge-design-grid .empty-progress-state {
  grid-column: 1 / -1;
}

.badge-definition-card {
  align-content: start;
}

.badge-definition-card .card-action-row {
  margin-top: auto;
}

.badge-design-grid strong,
.award-mini-stats strong {
  font-size: 20px;
}

.award-mini-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 12px;
}

.award-filter-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(180px, 240px));
  gap: 12px;
  align-items: end;
  margin: 0 0 12px;
}

.award-filter-row label {
  display: grid;
  gap: 7px;
  color: #475569;
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0;
}

.award-filter-row select {
  min-height: 44px;
  width: 100%;
  border: 1px solid #cfe0f5;
  border-radius: 8px;
  background: #fff;
  color: #0f172a;
  padding: 0 12px;
  font-weight: 800;
}

.award-filter-row select:disabled {
  background: #f1f5f9;
  color: #94a3b8;
  cursor: not-allowed;
}

.achievement-quick-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.teacher-quick-action-grid button {
  min-height: 86px;
  justify-content: space-between;
  padding: 16px 18px;
  text-align: left;
}

.teacher-quick-action-grid button svg {
  width: 24px;
  height: 24px;
}

.teacher-quick-action-grid button span {
  min-width: 0;
  flex: 1 1 auto;
}

.achievement-quick-actions button,
.student-awards-list button,
.history-row-actions button,
.student-certificate-actions button {
  min-height: 42px;
  padding: 0 12px;
}

.student-awards-list article,
.achievement-history-row {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto auto auto;
  gap: 12px;
  align-items: center;
  padding: 14px;
  border: 1px solid #d8e4f5;
  border-radius: 8px;
  background: #fff;
}

.student-award-row {
  grid-template-columns: minmax(0, 1fr);
  align-items: stretch;
}

.student-award-main {
  display: grid;
  grid-template-columns: 48px minmax(180px, 1.2fr) minmax(150px, 0.7fr) minmax(220px, 1fr) minmax(260px, auto);
  gap: 14px;
  align-items: center;
}

.student-award-row.compact .student-award-main {
  grid-template-columns: 48px minmax(180px, 1.1fr) minmax(130px, 0.55fr) minmax(180px, 0.85fr) minmax(230px, auto);
  gap: 12px;
}

.student-award-identity {
  min-width: 0;
}

.student-award-identity strong,
.student-award-identity small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.student-award-identity small {
  margin-top: 3px;
  color: #64748b;
  font-size: 12px;
  font-weight: 700;
}

.student-award-counts,
.student-award-chips,
.student-award-actions,
.coverage-action-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.student-award-counts,
.student-award-chips {
  min-width: 0;
}

.student-award-counts span {
  display: inline-flex;
  align-items: baseline;
  gap: 4px;
  color: #475569;
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.student-award-counts b {
  color: #0f172a;
  font-size: 15px;
}

.award-chip {
  display: inline-flex;
  max-width: min(240px, 100%);
  min-height: 28px;
  align-items: center;
  gap: 6px;
  padding: 5px 8px;
  overflow: hidden;
  border-radius: 999px;
  background: #eef6ff;
  color: #1d4ed8;
  font-size: 11px;
  font-weight: 900;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.award-chip svg {
  width: 14px;
  height: 14px;
  flex: 0 0 auto;
}

.award-chip.badge {
  background: #ecfdf5;
  color: #047857;
}

.award-chip.empty {
  background: #f1f5f9;
  color: #64748b;
}

.student-award-actions {
  justify-content: flex-end;
  flex-wrap: nowrap;
  min-width: 0;
}

.student-award-actions button {
  min-width: 0;
  white-space: nowrap;
}

.student-award-row.compact .student-award-actions button {
  padding-inline: 10px;
}

.student-award-details {
  display: grid;
  gap: 8px;
  padding: 12px;
  border-radius: 8px;
  background: #f8fbff;
}

.student-award-details.compact {
  margin-top: 8px;
  padding: 10px;
}

.student-award-details.compact .student-award-detail-row {
  padding: 8px;
}

.student-award-more {
  margin: 2px 0 0;
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
}

.student-award-detail-row {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  padding: 10px;
  border: 1px solid #d8e4f5;
  border-radius: 8px;
  background: #fff;
}

.student-award-detail-row strong,
.student-award-detail-row small {
  display: block;
}

.student-award-detail-row small {
  color: #64748b;
  font-size: 12px;
  font-weight: 700;
}

.student-award-detail-icon {
  display: inline-grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border-radius: 8px;
  background: #eaf2ff;
  color: #1f75ff;
}

.student-award-detail-icon.badge,
.student-award-detail-icon.green,
.student-award-detail-icon.teal {
  background: #ecfdf5;
  color: #047857;
}

.student-award-detail-icon.gold,
.student-award-detail-icon.orange {
  background: #fff7ed;
  color: #c2410c;
}

.student-award-detail-icon.purple {
  background: #f3e8ff;
  color: #7e22ce;
}

.achievement-list-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 12px;
  padding-top: 14px;
  border-top: 1px solid #e4ebf5;
  color: #475569;
  font-size: 13px;
  font-weight: 800;
}

.achievement-pagination {
  gap: 6px;
}

.achievement-pagination button {
  min-width: 34px;
  height: 34px;
}

@media (max-width: 1360px) {
  .student-award-main,
  .student-award-row.compact .student-award-main {
    grid-template-columns: 48px minmax(180px, 1fr) minmax(140px, 0.7fr);
  }

  .student-award-chips {
    grid-column: 2 / 4;
  }

  .student-award-actions {
    grid-column: 1 / -1;
    justify-content: flex-start;
  }
}

@media (max-width: 780px) {
  .award-mini-stats,
  .award-filter-row {
    grid-template-columns: 1fr;
  }

  .student-award-main,
  .student-award-row.compact .student-award-main {
    grid-template-columns: 44px minmax(0, 1fr);
  }

  .student-award-counts,
  .student-award-chips,
  .student-award-actions {
    grid-column: 2;
  }

  .student-award-actions {
    align-items: stretch;
  }

  .student-award-actions button {
    flex: 1 1 140px;
    justify-content: center;
  }

  .student-award-detail-row {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .student-award-detail-row .history-row-actions {
    grid-column: 2;
    justify-content: flex-start;
  }

  .achievement-list-footer {
    align-items: flex-start;
    flex-direction: column;
  }
}

.student-achievement-coverage {
  display: grid;
  gap: 12px;
}

.coverage-stat-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.coverage-stat-grid article {
  padding: 10px;
  border: 1px solid #d8e4f5;
  border-radius: 8px;
  background: #f8fbff;
}

.coverage-stat-grid strong,
.coverage-stat-grid span {
  display: block;
}

.coverage-stat-grid strong {
  color: #0f172a;
  font-size: 20px;
  line-height: 1;
}

.coverage-stat-grid span {
  margin-top: 4px;
  color: #64748b;
  font-size: 10px;
  font-weight: 800;
}

.coverage-latest-award {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  padding: 12px;
  border: 1px solid #d8e4f5;
  border-radius: 8px;
  background: #fff;
}

.coverage-latest-award > span {
  display: inline-grid;
  width: 40px;
  height: 40px;
  place-items: center;
  border-radius: 10px;
  background: #eaf2ff;
  color: #1f75ff;
}

.coverage-latest-award > span.badge {
  background: #ecfdf5;
  color: #047857;
}

.coverage-latest-award > span.empty {
  background: #f1f5f9;
  color: #64748b;
}

.coverage-latest-award strong,
.coverage-latest-award small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.coverage-latest-award small {
  margin-top: 3px;
  color: #64748b;
  font-size: 11px;
  font-weight: 700;
}

.coverage-action-row button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 36px;
  padding: 0 10px;
  border: 1px solid #d8e4f5;
  border-radius: 8px;
  background: #fff;
  color: #1d4ed8;
  font-weight: 900;
  cursor: pointer;
}

.coverage-action-row button svg {
  width: 16px;
  height: 16px;
}

.achievement-history-row strong,
.student-awards-list strong {
  color: var(--text-primary);
}

.achievement-history-row > span:last-of-type {
  justify-self: start;
}

.achievement-history-row {
  grid-template-columns: auto minmax(0, 1fr) auto auto;
}

.history-award-icon {
  display: inline-grid;
  width: 44px;
  height: 44px;
  place-items: center;
  border-radius: 8px;
  background: #eaf2ff;
  color: #1f75ff;
}

.history-award-icon.badge {
  background: #ecfdf5;
  color: #059669;
}

.history-row-actions,
.student-certificate-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.certificate-generator-form {
  display: grid;
  gap: 12px;
  margin-top: 12px;
}

.certificate-generator-layout {
  display: grid;
  grid-template-columns: minmax(320px, 0.82fr) minmax(460px, 1.18fr);
  gap: 18px;
  align-items: start;
}

.certificate-generator-fields {
  display: grid;
  gap: 12px;
}

.certificate-generator-form label {
  display: grid;
  gap: 6px;
  color: #0f172a;
  font-weight: 900;
}

.certificate-generator-form input,
.certificate-generator-form select,
.certificate-generator-form textarea {
  width: 100%;
  min-height: 48px;
  border: 1px solid #d4e0f2;
  border-radius: 8px;
  padding: 10px 12px;
  background: #fff;
  color: #0f172a;
  font: inherit;
  font-weight: 800;
}

.certificate-generator-form textarea {
  resize: vertical;
}

.certificate-generator-preview {
  margin-top: 4px;
}

.certificate-generator-preview-panel {
  position: sticky;
  top: 0;
  display: grid;
  gap: 12px;
}

.certificate-viewer {
  display: grid;
  gap: 12px;
  margin-top: 12px;
}

.certificate-viewer .certificate-preview {
  max-width: 900px;
  margin: 0 auto;
}

.certificate-lightbox-overlay {
  position: fixed;
  inset: 0;
  z-index: 2400;
  padding: 18px;
  background: rgba(15, 23, 42, 0.72);
  display: grid;
  place-items: center;
  animation: modal-fade 140ms ease-out;
}

.certificate-lightbox-overlay.closing {
  animation: modal-fade-out 140ms ease-in forwards;
}

.certificate-lightbox-card {
  position: relative;
  width: min(1380px, 96vw);
  max-height: calc(100vh - 36px);
  overflow: auto;
  padding: 48px 16px 16px;
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.34);
}

.certificate-lightbox-card .certificate-preview {
  max-width: 1320px;
  margin: 0 auto;
}

.certificate-lightbox-close {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 36px;
  height: 36px;
  border: 1px solid #d8e4f5;
  border-radius: 8px;
  background: #fff;
  color: #0f172a;
  display: grid;
  place-items: center;
  cursor: pointer;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.12);
}

.certificate-lightbox-close svg {
  width: 18px;
  height: 18px;
}

.student-certificate-card {
  grid-template-columns: auto minmax(0, 1fr) auto;
}

.student-certificate-card > i {
  flex: 0 0 auto;
}

.student-certificate-card > div:first-of-type {
  min-width: 0;
}

body.printing-certificate .app-shell,
body.printing-certificate .toast-region {
  display: none !important;
}

body.printing-certificate .feedback-modal-overlay {
  position: static;
  display: block;
  min-height: auto;
  padding: 0;
  background: #fff;
}

body.printing-certificate .feedback-modal {
  width: 100%;
  max-width: none;
  padding: 0;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

body.printing-certificate .feedback-modal-icon,
body.printing-certificate .feedback-modal-content > h2,
body.printing-certificate .feedback-modal-content > p,
body.printing-certificate .feedback-modal-actions,
body.printing-certificate .certificate-print-button {
  display: none !important;
}

body.printing-certificate .feedback-modal-main,
body.printing-certificate .feedback-modal-content,
body.printing-certificate .certificate-viewer,
body.printing-certificate .certificate-generator-form,
body.printing-certificate .certificate-generator-layout,
body.printing-certificate .certificate-generator-preview-panel,
body.printing-certificate .certificate-generator-preview,
body.printing-certificate .certificate-preview {
  display: block;
  width: 100%;
  margin: 0;
  padding: 0;
  border: 0;
  box-shadow: none;
}

body.printing-certificate .certificate-generator-form > :not(.certificate-generator-layout):not(.certificate-generator-preview) {
  display: none !important;
}

body.printing-certificate .certificate-generator-fields {
  display: none !important;
}

@page {
  size: landscape;
  margin: 0.25in;
}

@media (max-width: 1500px) {
  body[data-page="teacher"] .lesson-dashboard-grid {
    grid-template-columns: 1fr;
  }

  body[data-page="teacher"] .lesson-side-rail {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 1180px) {
  body[data-page="login"] .brand-panel,
  body[data-page="register"] .brand-panel {
    width: min(720px, 100%);
    margin: 0 auto;
  }

  body[data-page="teacher"] .lesson-dashboard-grid {
    grid-template-columns: 1fr;
  }

  body[data-page="teacher"] .lesson-side-rail {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .achievement-workspace-grid,
  .achievement-workspace-grid.two-column {
    grid-template-columns: 1fr;
  }

  .achievement-summary-grid,
  .teacher-leaderboard-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  body[data-page="teacher"] .upload-card {
    position: static;
  }
}

@media (max-width: 840px) {
  .sidebar-brand-block,
  .sidebar-help-card {
    display: none;
  }

  body[data-page="teacher"] .app-topbar,
  body[data-page="student"] .app-topbar {
    padding: calc(12px + env(safe-area-inset-top)) 12px 12px 62px;
  }
}

@media (max-width: 760px) {
  body[data-page="teacher"] .teacher-section,
  body[data-page="student"] .student-section {
    padding: 16px;
  }

  .lesson-page-heading {
    padding: 0;
  }

  .lesson-page-actions,
  .lesson-page-actions .primary-button {
    width: 100%;
  }

  body[data-page="teacher"] .lesson-library-header,
  body[data-page="teacher"] .lesson-toolbar,
  body[data-page="teacher"] .lesson-table-footer {
    padding-left: 16px;
    padding-right: 16px;
  }

  .achievement-management-header,
  .certificate-template-option,
  .certificate-generator-layout,
  .management-form .field-grid.simple-grid,
  .teacher-leaderboard-metrics,
  .achievement-summary-grid,
  body[data-page="teacher"] .lesson-side-rail,
  .student-awards-list article,
  .student-award-main,
  .student-award-detail-row,
  .coverage-stat-grid,
  .achievement-history-row,
  body[data-page="student"] .student-certificate-card {
    grid-template-columns: 1fr;
  }

  .feedback-modal.certificate-modal {
    width: min(720px, calc(100vw - 24px));
    max-height: calc(100vh - 24px);
  }

  .certificate-generator-preview-panel {
    position: static;
  }

  body[data-page="student"] .student-certificate-card.locked {
    grid-template-columns: 1fr;
  }

  .achievement-management-header {
    display: grid;
  }

  .achievement-management-header .primary-button,
  .teacher-leaderboard-header .primary-button,
  .achievement-quick-actions,
  .award-mini-stats {
    grid-template-columns: 1fr;
    width: 100%;
  }

  .student-certificate-actions,
  .history-row-actions,
  .student-award-actions {
    justify-content: stretch;
    flex-wrap: wrap;
  }

  .student-certificate-actions button,
  .history-row-actions button,
  .student-award-actions button {
    flex: 1 1 130px;
  }

  .achievement-list-footer {
    align-items: stretch;
    flex-direction: column;
  }

  .achievement-pagination {
    justify-content: center;
  }
}

@media (max-width: 520px) {
  .feedback-modal.management-modal {
    padding: 22px 18px;
  }

  .management-modal .feedback-modal-main {
    grid-template-columns: 1fr;
  }

  .management-modal .feedback-modal-icon {
    width: 50px;
    height: 50px;
  }

  body[data-page="teacher"] .app-topbar,
  body[data-page="student"] .app-topbar {
    min-height: 60px;
    gap: 8px;
    padding: calc(10px + env(safe-area-inset-top)) 10px 10px 58px;
  }

  body[data-page="teacher"] .compact-brand,
  body[data-page="student"] .compact-brand {
    max-width: 44vw;
    overflow: hidden;
    font-size: 18px;
    line-height: 1;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  body[data-page="teacher"] .topbar-profile,
  body[data-page="student"] .topbar-profile {
    gap: 6px;
    max-width: none;
    margin-left: auto;
  }

  body[data-page="teacher"] .topbar-profile > div:last-of-type,
  body[data-page="student"] .topbar-profile > div:last-of-type {
    display: none;
  }

  body[data-page="teacher"] .notification-button,
  body[data-page="student"] .notification-button,
  body[data-page="teacher"] .icon-shell,
  body[data-page="student"] .icon-shell,
  body[data-page="teacher"] .profile-badge,
  body[data-page="student"] .profile-badge {
    width: 38px;
    height: 38px;
    min-width: 38px;
  }

  .mobile-nav-toggle {
    top: calc(10px + env(safe-area-inset-top));
    left: 10px;
    width: 38px;
    height: 38px;
  }
}

/* Home reference cascade lock: keep this block last so legacy portal themes do not recolor the Home view. */
body[data-page="teacher"] .app-shell {
  grid-template-columns: 252px minmax(0, 1fr);
  background: #f7f9fb;
}

@media (min-width: 841px) {
  body[data-page="teacher"] .app-sidebar {
    position: sticky;
    top: 0;
    height: 100vh;
    margin: 0;
    padding: 22px 16px 16px;
    border: 0;
    border-right: 1px solid var(--home-line);
    border-radius: 0;
    background: #fff;
    box-shadow: none;
    gap: 5px;
    overflow-y: auto;
  }

  body[data-page="teacher"] .app-sidebar .nav-item {
    min-height: 38px;
    padding: 0 11px;
    border: 1px solid transparent;
    border-radius: 9px;
    grid-template-columns: 20px minmax(0, 1fr);
    gap: 9px;
    color: #4f5762;
    font-size: 11px;
    font-weight: 600;
    box-shadow: none;
  }
}

body[data-page="teacher"] .app-sidebar .nav-item.active,
body[data-page="teacher"] .app-sidebar .nav-item:hover {
  border-color: #dce7ef;
  background: var(--home-blue);
  color: var(--home-ink);
  box-shadow: none;
}

body[data-page="teacher"] .app-topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  min-height: 66px;
  margin: 0;
  padding: 0 22px;
  border: 0;
  border-bottom: 1px solid var(--home-line);
  border-radius: 0;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: none;
}

body[data-page="teacher"] .teacher-section.active[data-view="overview"] {
  padding: 16px 20px 26px;
  background: #fff;
}

body[data-page="teacher"] .teacher-home-hero {
  min-height: 94px;
  padding: 12px 0 14px;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

body[data-page="teacher"] .teacher-home-hero h1 {
  margin: 0;
  color: var(--home-ink);
  font-size: clamp(24px, 2.25vw, 34px);
  line-height: 1.1;
  font-weight: 600;
  letter-spacing: -0.045em;
}

body[data-page="teacher"] .teacher-home-hero p {
  margin-top: 7px;
  color: var(--home-muted);
  font-size: 11px;
  font-weight: 400;
}

body[data-page="teacher"] .teacher-home-layout {
  grid-template-columns: minmax(0, 1fr) minmax(268px, 304px);
  gap: 16px;
  align-items: start;
}

body[data-page="teacher"] .teacher-home-main,
body[data-page="teacher"] .teacher-home-rail {
  min-width: 0;
  display: grid;
  gap: 16px;
}

body[data-page="teacher"] .teacher-home-metrics {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 0;
}

body[data-page="teacher"] .teacher-home-metrics .stat-card {
  min-width: 0;
  min-height: 116px;
  padding: 14px;
  border: 1px solid var(--home-line);
  border-radius: 13px;
  background: #fff;
  box-shadow: none;
  display: block;
  gap: 0;
}

body[data-page="teacher"] .teacher-home-metrics .stat-icon,
body[data-page="teacher"] .teacher-home-metrics .stat-icon.blue,
body[data-page="teacher"] .teacher-home-metrics .stat-icon.green,
body[data-page="teacher"] .teacher-home-metrics .stat-icon.orange,
body[data-page="teacher"] .teacher-home-metrics .stat-icon.purple {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: var(--home-blue) !important;
  color: var(--home-ink) !important;
}

body[data-page="teacher"] .teacher-home-metrics .stat-card > strong {
  display: block;
  margin-top: 9px;
  color: var(--home-ink);
  font-size: clamp(25px, 2.2vw, 34px);
  line-height: 1;
  font-weight: 500;
}

body[data-page="teacher"] .teacher-home-metrics .stat-card > small {
  display: block;
  margin-top: 8px;
  color: var(--home-muted);
  font-size: 8px;
  font-weight: 500;
}

body[data-page="teacher"] .capstone-evidence-panel,
body[data-page="teacher"] .home-side-card {
  border: 1px solid var(--home-line);
  border-radius: 14px;
  background: #fff;
  box-shadow: none;
}

body[data-page="teacher"] .capstone-evidence-panel {
  min-width: 0;
  margin: 0;
  padding: 0;
  overflow: hidden;
}

body[data-page="teacher"] .capstone-evidence-header {
  margin: 0;
  padding: 14px 16px;
  border-bottom: 1px solid var(--home-line);
}

body[data-page="teacher"] .capstone-evidence-header h1 {
  margin-top: 4px;
  color: var(--home-ink);
  font-size: 15px;
  font-weight: 600;
}

body[data-page="teacher"] .capstone-evidence-header p {
  margin-top: 4px;
  color: var(--home-muted);
  font-size: 9px;
  font-weight: 400;
}

body[data-page="teacher"] .evidence-metric-grid {
  margin: 0;
  padding: 12px 14px;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 8px;
  border-bottom: 1px solid var(--home-line);
  background: #fbfcfd;
}

body[data-page="teacher"] .evidence-metric-grid article {
  min-height: 88px;
  padding: 10px;
  border: 1px solid #e7ebef;
  border-radius: 10px;
  background: #fff;
  box-shadow: none;
}

body[data-page="teacher"] .evidence-active-summary {
  margin: 12px 14px 0;
  border: 1px solid #dbe9f3;
  border-radius: 10px;
  background: var(--home-blue);
}

body[data-page="teacher"] .evidence-dashboard-grid {
  padding: 12px 14px 14px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

body[data-page="teacher"] .evidence-card {
  min-width: 0;
  padding: 13px;
  border: 1px solid #e7ebef;
  border-radius: 11px;
  background: #fff;
  box-shadow: none;
}

body[data-page="teacher"] .teacher-home-rail {
  position: sticky;
  top: 82px;
  gap: 12px;
}

body[data-page="teacher"] .home-side-card {
  padding: 14px;
}

body[data-page="teacher"] .quarter-spotlight {
  min-height: 112px;
  padding: 14px;
  border: 1px solid #dceaf4;
  border-radius: 10px;
  background: var(--home-blue);
}

@media (max-width: 1360px) {
  body[data-page="teacher"] .app-shell {
    grid-template-columns: 226px minmax(0, 1fr);
  }

  body[data-page="teacher"] .teacher-home-layout {
    grid-template-columns: minmax(0, 1fr) 258px;
  }

  body[data-page="teacher"] .teacher-home-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  body[data-page="teacher"] .evidence-metric-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 1080px) and (min-width: 841px) {
  body[data-page="teacher"] .teacher-home-layout {
    grid-template-columns: 1fr;
  }

  body[data-page="teacher"] .teacher-home-rail {
    position: static;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 840px) {
  body[data-page="teacher"] .app-shell {
    grid-template-columns: 1fr;
  }

  body[data-page="teacher"] .app-topbar {
    min-height: 60px;
    padding: 0 14px 0 60px;
  }

  body[data-page="teacher"] .teacher-section.active[data-view="overview"] {
    padding: 14px;
  }

  body[data-page="teacher"] .teacher-home-layout,
  body[data-page="teacher"] .teacher-home-rail,
  body[data-page="teacher"] .evidence-dashboard-grid {
    grid-template-columns: 1fr;
  }

  body[data-page="teacher"] .teacher-home-rail {
    position: static;
  }
}

@media (max-width: 620px) {
  body[data-page="teacher"] .teacher-home-metrics,
  body[data-page="teacher"] .evidence-metric-grid,
  body[data-page="teacher"] .evidence-toolbar {
    grid-template-columns: 1fr;
  }
}

/* Home reference components and motion. */
body[data-page="teacher"] {
  --home-ink: #111318;
  --home-muted: #69717d;
  --home-line: #e3e8ed;
  --home-blue: #eef7ff;
  --home-blue-strong: #d8ecff;
}

body[data-page="teacher"] .sidebar-brand-block {
  min-height: 46px;
  margin: 0 0 16px;
  grid-template-columns: 44px minmax(0, 1fr);
  gap: 11px;
}

body[data-page="teacher"] .sidebar-logo-mark {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: var(--home-ink);
  color: #fff;
  box-shadow: 0 8px 18px rgba(17, 19, 24, 0.18), inset 0 0 0 1px rgba(255, 255, 255, 0.08);
}

body[data-page="teacher"] .sidebar-logo-mark svg {
  width: 25px;
  height: 25px;
}

body[data-page="teacher"] .techwise-cube-logo path {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.65;
  stroke-linecap: round;
  stroke-linejoin: round;
  vector-effect: non-scaling-stroke;
}

body[data-page="teacher"] .sidebar-brand-block strong {
  color: var(--home-ink);
  font-size: 17px;
  letter-spacing: -0.03em;
}

body[data-page="teacher"] .sidebar-brand-block small {
  color: var(--home-muted);
  font-size: 9px;
}

.sidebar-search {
  position: relative;
  min-height: 42px;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
}

.sidebar-search > svg {
  position: absolute;
  left: 12px;
  width: 17px;
  height: 17px;
  color: #555e69;
  pointer-events: none;
}

.sidebar-search input {
  width: 100%;
  height: 42px;
  padding: 0 58px 0 38px;
  border: 1px solid var(--home-line);
  border-radius: 10px;
  outline: 0;
  background: #fff;
  color: var(--home-ink);
  font: inherit;
  font-size: 12px;
  transition: border-color 180ms ease, box-shadow 180ms ease, background 180ms ease;
}

.sidebar-search input:focus {
  border-color: #b9d7ef;
  background: #fbfdff;
  box-shadow: 0 0 0 3px var(--home-blue);
}

.sidebar-search kbd {
  position: absolute;
  right: 9px;
  padding: 2px 5px;
  border: 0;
  border-radius: 5px;
  background: #f2f5f7;
  color: #737b85;
  font: inherit;
  font-size: 8px;
  font-weight: 700;
}

.sidebar-section-label {
  margin: 9px 8px 4px;
  color: #8a919b;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.sidebar-profile-card {
  min-width: 0;
  min-height: 58px;
  margin-top: auto;
  padding: 9px;
  border: 1px solid var(--home-line);
  border-radius: 12px;
  background: #fff;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) 30px;
  gap: 8px;
  align-items: center;
}

.sidebar-profile-card .profile-badge {
  width: 34px !important;
  height: 34px !important;
  border: 0 !important;
  border-radius: 50%;
  background: var(--home-blue);
  color: var(--home-ink);
  box-shadow: none !important;
}

.sidebar-profile-card strong,
.sidebar-profile-card small {
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sidebar-profile-card strong {
  color: var(--home-ink);
  font-size: 10px;
  font-weight: 700;
}

.sidebar-profile-card small {
  margin-top: 2px;
  color: var(--home-muted);
  font-size: 8px;
}

.sidebar-profile-card .icon-shell {
  width: 30px !important;
  height: 30px !important;
  min-width: 30px !important;
  border: 0 !important;
  background: transparent !important;
  color: var(--home-muted);
}

.topbar-breadcrumb,
.topbar-actions {
  display: flex;
  align-items: center;
}

.topbar-breadcrumb {
  gap: 10px;
  color: var(--home-muted);
  font-size: 11px;
}

.topbar-breadcrumb svg:first-child { width: 17px; height: 17px; }
.topbar-breadcrumb svg:nth-of-type(2) { width: 13px; height: 13px; color: #a4aab2; }
.topbar-breadcrumb strong { color: var(--home-ink); font-weight: 700; }
.topbar-actions { gap: 8px; }

body:is([data-page="teacher"], [data-page="student"]) .topbar-actions :is(.notification-button, .icon-shell) {
  width: 36px;
  height: 36px;
  min-width: 36px;
  border: 1px solid var(--border-color, #dfe7ee);
  border-radius: 10px;
  background: #fff;
  color: #4e5a67;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.16s ease;
}

body:is([data-page="teacher"], [data-page="student"]) .topbar-actions :is(.notification-button, .icon-shell):hover,
body:is([data-page="teacher"], [data-page="student"]) .topbar-actions .notification-button[aria-expanded="true"] {
  background: #eef4ff;
  border-color: #c4d7ec;
  color: #1f7bf2;
}

body[data-page="teacher"] .teacher-home-surface { gap: 16px; }
body[data-page="teacher"] .teacher-home-hero h1 > span:first-child { font-weight: 700; }

.wave {
  display: inline-block;
  font-size: 0.76em;
  transform-origin: 70% 70%;
  animation: home-wave 2.6s ease-in-out 700ms 2;
}

.home-hero-actions { gap: 8px; }

.home-period-pill,
body[data-page="teacher"] .home-hero-actions .small-button,
body[data-page="teacher"] .home-hero-actions .primary-button {
  min-height: 38px;
  height: 38px;
  padding: 0 12px;
  border: 1px solid var(--home-line);
  border-radius: 9px;
  font-size: 10px;
  font-weight: 600;
  box-shadow: none;
}

.home-period-pill {
  background: #fff;
  color: #49515c;
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.home-period-pill svg,
body[data-page="teacher"] .home-hero-actions svg { width: 15px; height: 15px; }
.home-period-pill svg:last-child { width: 12px; height: 12px; }
body[data-page="teacher"] .home-hero-actions .small-button { background: #fff; color: var(--home-ink); }
body[data-page="teacher"] .home-hero-actions .primary-button { background: var(--home-ink); color: #fff; }

.stat-card-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

body[data-page="teacher"] .teacher-home-metrics .stat-card {
  overflow: hidden;
  transition: border-color 180ms ease, box-shadow 180ms ease, transform 180ms ease;
  animation: home-rise 520ms both;
}

body[data-page="teacher"] .teacher-home-metrics .stat-card:nth-child(2) { animation-delay: 70ms; }
body[data-page="teacher"] .teacher-home-metrics .stat-card:nth-child(3) { animation-delay: 140ms; }
body[data-page="teacher"] .teacher-home-metrics .stat-card:nth-child(4) { animation-delay: 210ms; }

body[data-page="teacher"] .teacher-home-metrics .stat-card:hover {
  border-color: #c9dbe8;
  box-shadow: 0 12px 28px rgba(28, 39, 51, 0.08);
  transform: translateY(-3px);
}

body[data-page="teacher"] .teacher-home-metrics .stat-card p {
  margin: 0;
  color: #454d57;
  font-size: 10px;
  font-weight: 600;
}

body[data-page="teacher"] .teacher-home-metrics .stat-icon svg { width: 14px; height: 14px; }
body[data-page="teacher"] .teacher-home-metrics .stat-card > small b { color: #415a70; font-weight: 700; }

body[data-page="teacher"] .capstone-evidence-panel,
body[data-page="teacher"] .home-side-card { animation: home-rise 560ms 150ms both; }

body[data-page="teacher"] .evidence-toolbar {
  grid-template-columns: minmax(120px, 1fr) auto;
  gap: 7px;
}

body[data-page="teacher"] .evidence-toolbar label span { display: none; }

body[data-page="teacher"] .evidence-toolbar select,
body[data-page="teacher"] .evidence-quarter-pill,
body[data-page="teacher"] .evidence-export-actions button {
  min-height: 32px;
  height: 32px;
  border: 1px solid var(--home-line);
  border-radius: 8px;
  background: #fff;
  color: #424a54;
  font-size: 8px;
  font-weight: 600;
  box-shadow: none;
}

body[data-page="teacher"] .evidence-export-actions { grid-column: 1 / -1; gap: 6px; }
body[data-page="teacher"] .evidence-export-actions button:first-child { border-color: var(--home-ink); background: var(--home-ink); color: #fff; }
body[data-page="teacher"] .evidence-export-actions button:last-child { border-color: var(--home-line); background: var(--home-blue); color: var(--home-ink); }

body[data-page="teacher"] .teacher-section[data-view="overview"] .evidence-metric-grid article > span {
  width: 23px;
  height: 23px;
  border-radius: 7px;
  background: var(--home-blue) !important;
  color: var(--home-ink) !important;
}

body[data-page="teacher"] .evidence-metric-grid article > span svg { width: 12px; height: 12px; }

body[data-page="teacher"] .evidence-metric-grid article p,
body[data-page="teacher"] .evidence-metric-grid article small {
  color: var(--home-muted);
  font-size: 7px;
  font-weight: 500;
  line-height: 1.25;
}

body[data-page="teacher"] .evidence-metric-grid article strong {
  margin: 3px 0;
  color: var(--home-ink);
  font-size: 18px;
  font-weight: 600;
}

body[data-page="teacher"] .evidence-card h2,
body[data-page="teacher"] .panel-title-row h2 { color: var(--home-ink); font-size: 12px; font-weight: 600; }
body[data-page="teacher"] .evidence-chip { background: var(--home-blue); color: #53606c; font-size: 7px; }

body[data-page="teacher"] .evidence-mastery-list article,
body[data-page="teacher"] .evidence-intervention-list article,
body[data-page="teacher"] .evidence-readiness-list article,
body[data-page="teacher"] .compact-list .mini-row { border-radius: 8px; background: #fbfcfd; }

body[data-page="teacher"] .mastery-ring,
body[data-page="teacher"] .mastery-ring.warn {
  background: radial-gradient(circle at center, #fff 0 55%, transparent 56%), conic-gradient(var(--home-ink) calc(var(--mastery) * 1%), var(--home-blue-strong) 0);
}

body[data-page="teacher"] .chart-area { fill: rgba(216, 236, 255, 0.65); }
body[data-page="teacher"] .chart-line { stroke: var(--home-ink); }
body[data-page="teacher"] .chart-point.pre,
body[data-page="teacher"] .chart-point.post { stroke: var(--home-ink); }

body[data-page="teacher"] .home-side-card:nth-child(2) { animation-delay: 230ms; }
body[data-page="teacher"] .home-side-card .panel-title-row { margin-bottom: 11px; }

body[data-page="teacher"] .home-side-card .small-button,
body[data-page="teacher"] .home-side-card .icon-button {
  min-height: 30px;
  height: 30px;
  padding: 0 9px;
  border: 1px solid var(--home-line);
  border-radius: 8px;
  background: #fff;
  color: var(--home-ink);
  font-size: 8px;
  box-shadow: none;
}

body[data-page="teacher"] .home-side-card .icon-button { width: 30px; min-width: 30px; padding: 0; }

.home-update-tabs {
  margin-bottom: 12px;
  padding: 3px;
  border: 1px solid var(--home-line);
  border-radius: 9px;
  background: #fbfcfd;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 3px;
}

.home-update-tabs button {
  min-height: 28px;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: var(--home-muted);
  font: inherit;
  font-size: 8px;
  font-weight: 600;
}

.home-update-tabs button.active { background: var(--home-ink); color: #fff; }

.home-card-label {
  margin: 0 0 7px;
  color: var(--home-muted);
  font-size: 8px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.07em;
}

body[data-page="teacher"] .quarter-spotlight strong { color: var(--home-ink); font-size: 20px; font-weight: 600; }
body[data-page="teacher"] .quarter-spotlight span,
body[data-page="teacher"] .quarter-spotlight p { color: var(--home-muted); font-size: 9px; font-weight: 500; }
body[data-page="teacher"] .home-side-card .compact-list { display: grid; gap: 7px; }

body[data-page="teacher"] .home-side-card .compact-list .mini-row {
  min-height: 46px;
  padding: 9px;
  border: 1px solid #edf0f2;
  transition: background 160ms ease, transform 160ms ease;
}

body[data-page="teacher"] .home-side-card .compact-list .mini-row:hover { background: var(--home-blue); transform: translateX(2px); }

@keyframes home-rise {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes home-wave {
  0%, 60%, 100% { transform: rotate(0deg); }
  10% { transform: rotate(14deg); }
  20% { transform: rotate(-8deg); }
  30% { transform: rotate(12deg); }
  40% { transform: rotate(-4deg); }
}

@media (max-width: 620px) {
  .topbar-breadcrumb > span,
  .topbar-breadcrumb svg:nth-of-type(2) { display: none; }
  body[data-page="teacher"] .teacher-home-hero { align-items: stretch; flex-direction: column; }
  .home-hero-actions { justify-content: flex-start; }
  .home-period-pill { width: 100%; justify-content: center; }
}

@media (prefers-reduced-motion: reduce) {
  .wave,
  body[data-page="teacher"] .teacher-home-metrics .stat-card,
  body[data-page="teacher"] .capstone-evidence-panel,
  body[data-page="teacher"] .home-side-card { animation: none !important; }
}

body[data-page="teacher"] .teacher-section[data-view="overview"] .evidence-topic-icon,
body[data-page="teacher"] .teacher-section[data-view="overview"] .evidence-readiness-list article > span {
  background: var(--home-blue) !important;
  color: var(--home-ink) !important;
}

body[data-page="teacher"] .teacher-section[data-view="overview"] .wide-progress,
body[data-page="teacher"] .teacher-section[data-view="overview"] .evidence-growth-bar {
  background: var(--home-blue-strong);
}

body[data-page="teacher"] .teacher-section[data-view="overview"] .wide-progress span,
body[data-page="teacher"] .teacher-section[data-view="overview"] .evidence-growth-bar span,
body[data-page="teacher"] .teacher-section[data-view="overview"] .evidence-growth-bar span.post {
  background: var(--home-ink);
}

body[data-page="teacher"] .teacher-section[data-view="overview"] .evidence-growth-bar span:not(.post) {
  opacity: 0.35;
}

body[data-page="teacher"] .teacher-section[data-view="overview"] .evidence-growth-score svg,
body[data-page="teacher"] .teacher-section[data-view="overview"] .evidence-empty svg,
body[data-page="teacher"] .teacher-section[data-view="overview"] .good-text,
body[data-page="teacher"] .teacher-section[data-view="overview"] .warn-text,
body[data-page="teacher"] .teacher-section[data-view="overview"] .evidence-growth-card p {
  color: var(--home-ink) !important;
}

body[data-page="teacher"] .teacher-section[data-view="overview"] .approve-button,
body[data-page="teacher"] .teacher-section[data-view="overview"] .reject-button {
  border-color: #d9e6ef;
  background: var(--home-blue);
  color: var(--home-ink);
}

/* Reference-style metric cards: tinted header, top-right symbol, value and sparkline. */
body[data-page="teacher"] .teacher-home-metrics .stat-card {
  min-height: 132px;
  padding: 0;
}

body[data-page="teacher"] .teacher-home-metrics .stat-card-heading {
  min-height: 38px;
  padding: 0 12px;
  border-bottom: 1px solid #dce8f1;
  background:
    repeating-linear-gradient(118deg, rgba(255, 255, 255, 0.44) 0 2px, transparent 2px 7px),
    var(--home-blue);
}

body[data-page="teacher"] .teacher-home-metrics .stat-card-heading p {
  color: #3f4852;
  font-size: 10px;
  font-weight: 600;
}

body[data-page="teacher"] .teacher-home-metrics .stat-card-heading .stat-icon,
body[data-page="teacher"] .teacher-home-metrics .stat-card-heading .stat-icon.blue,
body[data-page="teacher"] .teacher-home-metrics .stat-card-heading .stat-icon.green,
body[data-page="teacher"] .teacher-home-metrics .stat-card-heading .stat-icon.orange,
body[data-page="teacher"] .teacher-home-metrics .stat-card-heading .stat-icon.purple {
  width: 22px;
  height: 22px;
  border-radius: 0;
  background: transparent !important;
  color: #5b6671 !important;
}

body[data-page="teacher"] .teacher-home-metrics .stat-card-heading .stat-icon svg {
  width: 15px;
  height: 15px;
  stroke-width: 1.8;
}

.stat-card-body {
  min-height: 93px;
  padding: 13px 11px 12px 13px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 8px;
}

.stat-card-value {
  min-width: 0;
  flex: 1 1 auto;
}

body[data-page="teacher"] .teacher-home-metrics .stat-card-value > strong {
  display: block;
  margin: 0;
  color: var(--home-ink);
  font-size: clamp(25px, 2.15vw, 33px);
  line-height: 1;
  font-weight: 500;
  letter-spacing: -0.045em;
}

body[data-page="teacher"] .teacher-home-metrics .stat-card-value > small {
  display: block;
  max-width: 164px;
  margin-top: 9px;
  overflow: hidden;
  color: var(--home-muted);
  font-size: clamp(8px, 0.72vw, 10px);
  font-weight: 500;
  line-height: 1.35;
  letter-spacing: 0.005em;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body[data-page="teacher"] .teacher-home-metrics .stat-card-value > small b {
  color: #4f7b9a;
  font-weight: 700;
}

.metric-sparkline {
  width: clamp(58px, 5.8vw, 92px);
  height: 48px;
  flex: 0 0 auto;
  overflow: visible;
}

.metric-sparkline.is-ready .sparkline-area {
  fill: #e5f3ff;
  opacity: 0.72;
  animation: sparkline-area-in 700ms 240ms ease both;
}

.metric-sparkline.is-ready polyline {
  fill: none;
  stroke: #5799bd;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 1;
  stroke-dashoffset: 1;
  vector-effect: non-scaling-stroke;
  animation: sparkline-draw 900ms 180ms ease-out forwards;
}

body[data-page="teacher"] .teacher-home-metrics .stat-card:hover .metric-sparkline polyline {
  stroke: #2f708f;
}

@keyframes sparkline-draw {
  to { stroke-dashoffset: 0; }
}

@keyframes sparkline-area-in {
  from { opacity: 0; }
  to { opacity: 0.72; }
}

@media (max-width: 1360px) {
  .metric-sparkline {
    width: clamp(82px, 10vw, 126px);
  }
}

@media (max-width: 620px) {
  .metric-sparkline {
    width: clamp(96px, 30vw, 140px);
  }
}

@media (prefers-reduced-motion: reduce) {
  .metric-sparkline .sparkline-area,
  .metric-sparkline polyline {
    animation: none;
    stroke-dashoffset: 0;
  }
}

/* Slightly clearer helper labels beneath the Class Progress metric values. */
body[data-page="teacher"] .teacher-section[data-view="overview"] .evidence-metric-grid article small {
  font-size: clamp(8px, 0.64vw, 9.5px);
  line-height: 1.35;
  letter-spacing: 0.004em;
}

/* Empty dashboard messages must not reserve a strip below the top bar. */
body[data-page="teacher"] .dashboard-status:empty,
body[data-page="student"] .dashboard-status:empty {
  display: none;
}

/* Real-data sparklines inside the six Class Progress metric cards. */
.evidence-metric-value-row {
  min-width: 0;
  min-height: 42px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 7px;
}

body[data-page="teacher"] .evidence-metric-grid .evidence-metric-value-row > strong {
  flex: 0 0 auto;
  margin-bottom: 3px;
}

body[data-page="teacher"] .evidence-metric-grid .evidence-metric-sparkline {
  width: clamp(54px, 4.6vw, 76px);
  height: 38px;
  min-width: 0;
  flex: 0 1 76px;
  overflow: visible;
}

body[data-page="teacher"] .evidence-metric-grid article {
  min-height: 122px;
}

@media (max-width: 1360px) {
  body[data-page="teacher"] .evidence-metric-grid .evidence-metric-sparkline {
    width: clamp(66px, 8vw, 100px);
    flex-basis: 100px;
  }
}

@media (max-width: 620px) {
  body[data-page="teacher"] .evidence-metric-grid .evidence-metric-sparkline {
    width: clamp(100px, 34vw, 150px);
    flex-basis: 150px;
  }
}

/* Keep every metric helper phrase readable instead of truncating it. */
body[data-page="teacher"] .teacher-home-metrics .stat-card-value > small {
  max-width: none;
  overflow: visible;
  text-overflow: clip;
  white-space: normal;
  overflow-wrap: break-word;
}

body[data-page="teacher"] .teacher-section[data-view="overview"] .evidence-metric-grid article small {
  max-width: 100%;
  overflow: visible;
  text-overflow: clip;
  white-space: normal;
  overflow-wrap: break-word;
}

/* Assessment controls shared by student activities and teacher previews. */
.netacad-question-card { min-width:0; }
.netacad-question-header { gap:12px; flex-wrap:wrap; }
.netacad-q-prompt p { white-space:pre-line; overflow-wrap:anywhere; line-height:1.6; }
.netacad-q-inputs { min-width:0; }
.netacad-q-inputs .practice-order-help { margin:0 0 12px; line-height:1.7; font-size:13px; color:var(--theme-muted,#52627a); }
.netacad-q-inputs .practice-order-list { display:grid; gap:8px; margin:0 0 16px; padding:0; list-style:none; }
.netacad-q-inputs .practice-order-list li { display:flex; align-items:flex-start; gap:12px; padding:12px; background:var(--theme-surface,#f6f9ff); border:1px solid var(--theme-border,#dce6f3); border-radius:10px; }
.netacad-q-inputs .practice-step-number { display:grid; place-items:center; flex:0 0 28px; height:28px; background:#eaf2ff; color:#1f6feb; border-radius:8px; font-size:12px; font-weight:700; }
.netacad-q-inputs .practice-step-text { min-width:0; padding-top:3px; font-size:13px; line-height:1.7; overflow-wrap:anywhere; }
.practice-order-label { display:block; font-size:13px; font-weight:600; margin:0 0 8px; }
.netacad-q-inputs .netacad-text-input { width:100%; max-width:100%; min-width:0; min-height:46px; box-sizing:border-box; font-size:14px; }
.netacad-choice-grid { grid-template-columns:1fr; gap:10px; }
.netacad-choice-card { min-width:0; min-height:48px; height:auto; align-items:flex-start; }
.netacad-choice-letter { flex-shrink:0; }
.netacad-choice-text { min-width:0; white-space:normal; overflow-wrap:anywhere; line-height:1.65; }
.netacad-choice-card:has(input:focus-visible) { outline:3px solid #8bb7ff; outline-offset:3px; }
.netacad-choice-card:has(input:disabled) { cursor:default; }
.netacad-question-card .practice-required-note { display:flex; align-items:flex-start; gap:8px; margin-top:16px; padding:10px 12px; border-radius:8px; background:#fff3f0; color:#a33724; font-size:12px; line-height:1.6; }
.practice-required-note svg { flex:0 0 16px; width:16px; height:16px; margin-top:2px; }
.netacad-question-card .netacad-hint-section { margin-top:16px; }
.netacad-feedback-text,.netacad-hint-drawer p { overflow-wrap:anywhere; line-height:1.7; }
@media(max-width:540px) { .netacad-question-card { padding:16px; } .netacad-choice-card { padding:12px; gap:10px; } .netacad-q-prompt p { font-size:15px; } }

.practice-order-card { display:flex; align-items:center; gap:12px; width:100%; padding:12px; text-align:left; font:inherit; color:var(--theme-text,#152238); background:var(--theme-surface,#fff); border:1px solid var(--theme-border,#dce6f3); border-radius:10px; cursor:pointer; }
.practice-order-card .practice-step-text { flex:1; }
.practice-order-card[aria-pressed="true"] { border-color:#1f6feb; background:var(--theme-bg,#eef5ff); }
.practice-order-card[aria-pressed="true"] .practice-step-number { background:#1f6feb; color:#fff; }
.practice-order-card:focus-visible { outline:3px solid #8bb7ff; outline-offset:3px; }
.practice-order-card:disabled { cursor:default; opacity:1; }
.practice-order-position { font-size:11px; color:var(--theme-muted,#52627a); flex-shrink:0; }
.practice-order-toolbar { display:flex; flex-wrap:wrap; align-items:center; justify-content:space-between; gap:12px; }
.practice-order-progress { font-size:12px; color:var(--theme-muted,#52627a); }
@media(max-width:540px) { .practice-order-card { flex-wrap:wrap; } .practice-order-position { width:100%; padding-left:40px; } }
