:root {
  --red: #c8191e;
  --red-dark: #8f171b;
  --ink: #111827;
  --muted: #64748b;
  --line: #e2e8f0;
  --paper: #ffffff;
  --soft: #f8fafc;
  --green: #047857;
  --amber: #b45309;
  --blue: #0875be;
  --blue-dark: #005c9c;
}

.asc-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}

.asc-control-card,
.asc-result-card {
  display: grid;
  gap: 16px;
  min-width: 0;
  width: 100%;
}

.asc-status-pill {
  max-width: none;
}

.asc-status-pill.ready {
  border-color: #9cf1c8;
  background: #effdf5;
}

.asc-status-pill.error {
  border-color: #fecaca;
  background: #fff1f2;
}

.asc-selection-grid {
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  margin: 0;
}

.field-hint,
.data-source-note {
  display: block;
  margin-top: 6px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.35;
  text-transform: none;
}

.asc-candidate-summary {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  gap: 10px;
}

.asc-candidate-summary div {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 10px;
}

.asc-candidate-summary span {
  display: block;
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.asc-candidate-summary strong {
  color: var(--blue-dark);
  font-size: 18px;
}

.asc-candidate-table {
  display: grid;
  gap: 8px;
  max-height: 460px;
  overflow: auto;
  padding-right: 3px;
}

.asc-candidate-toolbar,
.asc-job-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.asc-candidate-toolbar > span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.asc-candidate-toolbar > div,
.asc-job-controls {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.asc-candidate-row {
  display: grid;
  grid-template-columns: 28px minmax(220px, 1.35fr) minmax(220px, 1fr) minmax(210px, 0.85fr);
  gap: 12px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  padding: 10px;
  text-align: left;
  min-width: 760px;
}

.asc-candidate-row.imported {
  background: #f8fafc;
}

.asc-candidate-row.missing {
  border-color: #fed7aa;
  background: #fff7ed;
}

.asc-candidate-row input {
  width: 18px;
  height: 18px;
}

.asc-candidate-main,
.asc-candidate-meta {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.asc-candidate-main strong,
.asc-candidate-meta strong {
  color: var(--ink);
  overflow-wrap: anywhere;
}

.asc-candidate-main small,
.asc-candidate-meta small {
  color: var(--muted);
  font-weight: 700;
  overflow-wrap: anywhere;
}

.asc-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: flex-end;
  min-width: 0;
}

.asc-badge {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  background: #eef6ff;
  color: var(--blue-dark);
  padding: 4px 8px;
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.asc-badge.ok {
  background: #dcfce7;
  color: #047857;
}

.asc-badge.warn {
  background: #ffedd5;
  color: #b45309;
}

.asc-badge.imported {
  background: #e0f2fe;
  color: #075985;
}

.asc-group-result-list {
  display: grid;
  gap: 8px;
  margin-top: 10px;
}

.asc-candidate-list-label {
  display: grid;
  gap: 8px;
}

.asc-candidate-list-label span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
}

.asc-candidate-list-label textarea {
  min-height: 180px;
  resize: vertical;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  line-height: 1.45;
}

.asc-control-card .section-actions {
  justify-content: flex-end;
}

.asc-control-card .section-actions .primary-btn,
.asc-control-card .section-actions .secondary-btn {
  min-width: 148px;
}

.asc-import-result {
  display: grid;
  gap: 14px;
}

.asc-job-progress {
  display: grid;
  gap: 8px;
}

.asc-job-progress-bar {
  overflow: hidden;
  height: 14px;
  border: 1px solid #bfdbfe;
  border-radius: 999px;
  background: #eff6ff;
}

.asc-job-progress-bar span {
  display: block;
  height: 100%;
  min-width: 6px;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--blue), var(--red));
  transition: width 0.2s ease;
}

.asc-job-progress small {
  color: var(--muted);
  font-weight: 800;
}

.asc-import-result.success {
  border: 1px solid #bbf7d0;
  border-radius: 8px;
  background: #f0fdf4;
  padding: 14px;
}

.asc-import-result.alert {
  border: 1px solid #fecaca;
  border-radius: 8px;
  background: #fff1f2;
  padding: 14px;
}

.asc-result-summary {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.asc-result-summary div {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 10px;
}

.asc-result-summary span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.asc-result-summary strong {
  color: var(--ink);
  font-size: 18px;
}

.asc-import-result pre {
  overflow: auto;
  max-height: 320px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 12px;
  color: var(--muted);
  font-size: 12px;
  white-space: pre-wrap;
}

.danger-text {
  color: var(--red-dark);
  font-weight: 900;
}

.student-card.asc-locked {
  border-color: #0b78bd;
}

@media (max-width: 900px) {
  .asc-layout,
  .asc-selection-grid,
  .asc-result-summary,
  .asc-candidate-summary {
    grid-template-columns: 1fr;
  }

  .asc-candidate-table {
    overflow-x: auto;
  }

  .asc-candidate-row {
    grid-template-columns: 24px minmax(190px, 1.25fr) minmax(180px, 1fr) minmax(160px, 0.8fr);
    min-width: 640px;
  }

  .asc-candidate-row input {
    justify-self: start;
  }

  .asc-badges {
    justify-content: flex-start;
  }

  .asc-candidate-toolbar,
  .asc-job-controls {
    align-items: stretch;
  }

  .asc-candidate-toolbar > div,
  .asc-job-controls {
    width: 100%;
  }

  .asc-candidate-toolbar button,
  .asc-job-controls button {
    flex: 1 1 140px;
  }
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: #e5e7eb;
}

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

.login-screen {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(260px, 420px);
  justify-content: center;
  align-content: center;
  gap: 20px;
  padding: clamp(18px, 4vw, 44px);
  background:
    linear-gradient(135deg, rgba(127, 29, 29, 0.95), rgba(17, 24, 39, 0.96)),
    url("https://images.unsplash.com/photo-1523050854058-8df90110c9f1?auto=format&fit=crop&w=1600&q=80") center/cover;
}

.portal-gate {
  min-height: 100vh;
  padding: clamp(16px, 3vw, 36px);
  background:
    linear-gradient(135deg, rgba(143, 23, 27, 0.96), rgba(8, 117, 190, 0.92)),
    #991b1b;
}

.portal-gate-shell {
  width: min(1180px, 100%);
  margin: 0 auto;
  display: grid;
  gap: 18px;
}

.portal-gate-header,
.portal-gate-card {
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 8px;
  box-shadow: 0 28px 70px rgba(15, 23, 42, 0.24);
}

.portal-gate-header {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: clamp(16px, 2.4vw, 26px);
}

.portal-gate-header p,
.portal-gate-header h1 {
  margin: 0;
}

.portal-gate-header p {
  color: var(--red);
  font-weight: 1000;
  text-transform: uppercase;
}

.portal-gate-header h1 {
  color: #0f3f7f;
  font-size: clamp(28px, 4.6vw, 56px);
  line-height: 1.02;
}

.portal-gate-grid {
  display: grid;
  grid-template-columns: minmax(320px, 0.82fr) minmax(0, 1.18fr);
  gap: 18px;
  align-items: start;
}

.portal-gate-card {
  padding: clamp(18px, 2.8vw, 30px);
}

.portal-gate-countdown {
  display: grid;
  gap: 18px;
}

.portal-gate-countdown h2,
.portal-gate-countdown p {
  margin: 0;
}

.portal-gate-countdown h2 {
  color: #0f172a;
  font-size: clamp(28px, 4vw, 46px);
  line-height: 1.08;
}

.portal-gate-countdown h2 span {
  color: var(--blue);
}

.gate-countdown-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.gate-countdown-grid div {
  min-width: 0;
  padding: 14px 8px;
  border: 1px solid #dbeafe;
  border-radius: 8px;
  background: #eff6ff;
  text-align: center;
}

.gate-countdown-grid strong {
  display: block;
  color: var(--red);
  font-size: clamp(28px, 4.5vw, 44px);
  line-height: 1;
}

.gate-countdown-grid span {
  display: block;
  margin-top: 6px;
  color: #475569;
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.portal-gate-letter-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  width: fit-content;
  text-decoration: none;
}

.portal-gate-score-card {
  display: grid;
  gap: 12px;
}

.portal-gate-letter-card {
  display: grid;
  gap: 14px;
}

.portal-gate-letter-pages {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  align-items: start;
}

.portal-gate-letter-pages img {
  display: block;
  width: 100%;
  border: 1px solid #fee2e2;
  border-radius: 6px;
  background: #fff;
  box-shadow: 0 14px 38px rgba(15, 23, 42, 0.12);
}

.portal-gate-score-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.portal-gate-score-head span {
  color: var(--red);
  font-weight: 1000;
  text-transform: uppercase;
}

.portal-gate-score-head a {
  color: var(--blue);
  font-weight: 900;
}

.portal-gate-score-card img {
  display: block;
  width: 100%;
  max-height: calc(100vh - 190px);
  object-fit: contain;
  border: 1px solid #e5e7eb;
  border-radius: 6px;
  background: #fff;
}

.login-visual {
  position: relative;
  display: none;
  min-height: min(640px, calc(100vh - 88px));
  overflow: hidden;
  border: 10px solid rgba(255, 255, 255, 0.2);
  border-radius: 48px 4px 48px 4px;
  background: #111827;
  box-shadow: 0 30px 80px rgba(15, 23, 42, 0.28);
}

body.candidate-login-mode .login-screen {
  grid-template-columns: minmax(0, 1.1fr) minmax(320px, 430px);
  align-content: center;
  background:
    linear-gradient(135deg, rgba(143, 23, 27, 0.94), rgba(15, 63, 127, 0.9)),
    #8f171b;
}

body.candidate-login-mode .login-visual {
  display: block;
  grid-row: 1 / span 2;
}

body.candidate-login-mode .login-brand,
body.candidate-login-mode .login-card {
  grid-column: 2;
}

body.candidate-login-mode .login-brand {
  align-self: end;
}

body.candidate-login-mode .login-card {
  align-self: start;
}

body.candidate-login-mode #apiHealthStatus,
body.candidate-login-mode .login-copy,
body.candidate-login-mode .login-mode-note {
  display: none !important;
}

.login-slide-track,
.login-slide-track img {
  position: absolute;
  inset: 0;
}

.login-slide-track img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transform: scale(1.04);
  animation: loginSlideShow 42s infinite;
}

.login-slide-track img:nth-child(2) {
  animation-delay: 6s;
}

.login-slide-track img:nth-child(3) {
  animation-delay: 12s;
}

.login-slide-track img:nth-child(4) {
  animation-delay: 18s;
}

.login-slide-track img:nth-child(5) {
  animation-delay: 24s;
}

.login-slide-track img:nth-child(6) {
  animation-delay: 30s;
}

.login-slide-track img:nth-child(7) {
  animation-delay: 36s;
}

.login-visual::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.02), rgba(15, 23, 42, 0.6));
}

.login-visual-copy {
  position: absolute;
  left: clamp(20px, 4vw, 42px);
  right: clamp(20px, 4vw, 42px);
  bottom: clamp(22px, 4vw, 44px);
  z-index: 1;
  display: grid;
  gap: 8px;
  color: #fff;
}

.login-visual-copy span {
  color: #fecaca;
  font-size: 13px;
  font-weight: 1000;
  text-transform: uppercase;
}

.login-visual-copy strong {
  max-width: 620px;
  font-size: clamp(32px, 5vw, 64px);
  line-height: 1.02;
  font-weight: 1000;
}

@keyframes loginSlideShow {
  0%,
  100% {
    opacity: 0;
  }
  3%,
  13% {
    opacity: 1;
  }
  18% {
    opacity: 0;
    transform: scale(1.12);
  }
}

.login-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  color: #fff;
}

.login-brand strong,
.login-brand span {
  display: block;
}

.login-brand span {
  color: #fecaca;
  font-size: 13px;
  font-weight: 800;
}

.login-card {
  display: grid;
  gap: 16px;
  align-self: center;
  padding: 28px;
  border-radius: 8px;
  background: #fff;
  border: 1px solid rgba(255, 255, 255, 0.3);
  box-shadow: 0 24px 70px rgba(15, 23, 42, 0.25);
}

.dob-input-group {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 46px;
  gap: 8px;
}

.dob-input-group input {
  width: 100%;
  min-width: 0;
}

.dob-picker-input {
  padding: 0 8px;
  color: transparent;
}

.dob-picker-input::-webkit-calendar-picker-indicator {
  width: 22px;
  height: 22px;
  margin: 0 auto;
  cursor: pointer;
  opacity: 0.85;
}

body.candidate-login-mode .login-card {
  gap: 18px;
  padding: clamp(22px, 4vw, 34px);
  border: 0;
  border-radius: 28px 4px 28px 4px;
  box-shadow: 0 28px 70px rgba(15, 23, 42, 0.22);
}

body.candidate-login-mode .login-card .eyebrow {
  color: var(--red);
}

body.candidate-login-mode .login-card h1 {
  color: #0f3f7f;
  font-size: clamp(28px, 4vw, 44px);
  line-height: 1.05;
}

body.candidate-login-mode .candidate-login-fields {
  gap: 16px;
}

body.candidate-login-mode label span {
  color: #475569;
  font-size: 12px;
}

body.candidate-login-mode .candidate-login-fields input {
  height: 50px;
  border-color: #dbe3ee;
  border-radius: 12px;
  font-size: 16px;
  font-weight: 800;
}

body.candidate-login-mode .candidate-login-fields input:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 4px rgba(8, 117, 190, 0.12);
  outline: none;
}

body.candidate-login-mode #loginBtn {
  min-height: 52px;
  border-radius: 12px;
  font-size: 16px;
}

.login-copy {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.55;
  font-weight: 700;
}

.candidate-login-fields,
.admin-login-fields {
  display: grid;
  gap: 14px;
}

.candidate-data-loading {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    linear-gradient(rgba(255, 255, 255, 0.94), rgba(255, 247, 247, 0.96)),
    repeating-linear-gradient(135deg, rgba(200, 25, 30, 0.09) 0 12px, transparent 12px 24px);
}

.candidate-data-loading-card {
  display: grid;
  justify-items: center;
  gap: 12px;
  width: min(360px, 100%);
  padding: 30px 24px;
  border: 1px solid #fecaca;
  border-radius: 8px;
  color: #111827;
  text-align: center;
  background: #fff;
  box-shadow: 0 24px 70px rgba(15, 23, 42, 0.16);
}

.candidate-data-loading-card img {
  width: 74px;
  height: 74px;
  padding: 10px;
  border-radius: 999px;
  background: #fff7f7;
  animation: candidate-logo-spin 1.35s linear infinite;
}

.candidate-data-loading-card strong {
  color: var(--blue-dark);
  font-size: 22px;
  font-weight: 1000;
}

.candidate-data-loading-card span {
  color: var(--muted);
  font-weight: 850;
}

@keyframes candidate-logo-spin {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

.login-mode-note {
  margin: -4px 0 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
  font-weight: 800;
}

.api-health-pill {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 2px 10px;
  align-items: center;
  padding: 11px 12px;
  border: 1px solid #bfdbfe;
  border-radius: 8px;
  background: #eff6ff;
  color: #1e3a8a;
}

.api-health-pill span {
  grid-row: span 2;
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 8px;
  background: #dbeafe;
  font-size: 11px;
  font-weight: 900;
}

.api-health-pill strong,
.api-health-pill small {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
}

.api-health-pill strong {
  font-size: 13px;
}

.api-health-pill small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.api-health-pill.ok {
  border-color: #bbf7d0;
  background: #ecfdf5;
  color: #065f46;
}

.api-health-pill.ok span {
  background: #dcfce7;
}

.api-health-pill.fail {
  border-color: #fecaca;
  background: #fef2f2;
  color: #991b1b;
}

.api-health-pill.fail span {
  background: #fee2e2;
}

.online-enrollment-card {
  margin-top: 14px;
}

.online-step-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.online-step-pill {
  padding: 8px 10px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: #f8fafc;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.online-step-pill.complete {
  border-color: #bbf7d0;
  background: #ecfdf5;
  color: #047857;
}

.online-document-list {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.online-document-row {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: start;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.online-document-index {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 1px solid #dc2626;
  border-radius: 999px;
  color: #b91c1c;
  font-size: 12px;
  font-weight: 1000;
}

.online-document-main {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.online-document-title-line {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 10px;
  align-items: center;
}

.online-document-title-line span {
  padding: 3px 7px;
  border: 1px solid #bfdbfe;
  border-radius: 999px;
  background: #eff6ff;
  color: #0f3f7f;
  font-size: 11px;
  font-weight: 900;
}

.online-document-main strong,
.online-document-main small {
  overflow-wrap: anywhere;
}

.online-document-main small,
.online-document-empty,
.muted-file {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.45;
}

.online-document-files {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.online-document-file {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  max-width: 100%;
  padding: 5px 7px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafc;
  font-size: 12px;
  font-weight: 800;
}

.online-document-file.selected {
  border-color: #93c5fd;
  background: #eff6ff;
}

.online-document-file a {
  color: #0f3f7f;
  text-decoration: none;
  overflow-wrap: anywhere;
}

.online-document-file a:hover {
  text-decoration: underline;
}

.online-document-file span {
  min-width: 0;
  overflow-wrap: anywhere;
}

.online-document-file em {
  color: var(--muted);
  font-style: normal;
  white-space: nowrap;
}

.online-document-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.online-enrollment-action-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 14px;
}

.online-enrollment-action-card {
  display: grid;
  gap: 14px;
  align-content: space-between;
  padding: 16px;
  border: 1px solid #111827;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.82);
}

.online-enrollment-action-card h4 {
  margin: 8px 0 6px;
  color: var(--blue);
  font-size: 18px;
}

.online-enrollment-action-card p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
  line-height: 1.45;
}

.online-action-index {
  display: inline-grid;
  place-items: center;
  min-width: 34px;
  height: 34px;
  padding: 0 8px;
  border: 1px solid var(--red);
  border-radius: 999px;
  color: var(--red);
  font-size: 12px;
  font-weight: 1000;
}

.online-action-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.student-profile-modal-card,
.online-documents-modal-card {
  width: min(940px, 100%);
  max-height: calc(100dvh - 32px);
  overflow-y: auto;
  overscroll-behavior: contain;
}

.student-profile-readonly-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  padding: 10px;
  border: 1px solid #111827;
  background: rgba(248, 250, 252, 0.74);
}

.student-profile-readonly-item {
  min-width: 0;
  display: grid;
  gap: 3px;
  padding: 8px;
  border-bottom: 1px solid #dbe3ef;
}

.student-profile-readonly-item span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.student-profile-readonly-item strong {
  color: var(--ink);
  font-size: 14px;
  overflow-wrap: anywhere;
}

.student-profile-form {
  display: block;
}

.student-profile-edit-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 12px;
}

.student-profile-form-group {
  grid-column: 1 / -1;
  margin: 10px 0 0;
  padding-top: 10px;
  border-top: 1px solid #fecaca;
  color: var(--red);
  font-size: 15px;
}

.parent-toggle-heading label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
}

.parent-toggle-heading input {
  width: 18px;
  height: 18px;
  accent-color: var(--red);
}

.student-profile-field {
  display: grid;
  gap: 6px;
}

.student-profile-field.hidden {
  display: none;
}

.student-profile-field span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.student-profile-field input,
.student-profile-field select,
.student-profile-field textarea,
.student-profile-otp-panel input {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 10px 11px;
  color: var(--ink);
  font: inherit;
  font-size: 14px;
  font-weight: 800;
  background: #fff;
}

.student-profile-field textarea {
  resize: vertical;
  min-height: 78px;
}

.student-profile-otp-panel {
  display: grid;
  gap: 8px;
  padding: 12px;
  border: 1px solid #bfdbfe;
  border-radius: 6px;
  background: #eff6ff;
}

.student-profile-modal-actions {
  justify-content: flex-end;
}

.modal-online-document-list {
  margin-top: 0;
}

.app-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  background: var(--soft);
}

body.candidate-mode .step[data-view="report"],
body.candidate-mode .step[data-view="asc"],
body.candidate-mode #view-asc,
body.candidate-mode .integration-card,
body.candidate-mode .search-panel {
  display: none;
}

body.candidate-mode .staff-student-dashboard {
  display: none;
}

body.candidate-mode.candidate-enrolled-mode #view-profile,
body.candidate-mode.candidate-enrolled-mode #view-notice,
body.candidate-mode.candidate-enrolled-mode #view-major,
body.candidate-mode.candidate-enrolled-mode #view-payment,
body.candidate-mode.candidate-enrolled-mode #topNoticeBtn,
body.candidate-mode.candidate-enrolled-mode #topMajorBtn {
  display: none !important;
}

body.candidate-mode.candidate-enrolled-mode #view-student {
  display: block;
  padding-top: 24px;
  border-top: 0;
}

.candidate-timeline {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 18px;
}

.candidate-timeline-step {
  min-height: 104px;
  display: grid;
  align-content: start;
  gap: 6px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  text-align: left;
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.04);
}

.candidate-timeline-step span {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: #fee2e2;
  color: var(--red-dark);
  font-size: 12px;
  font-weight: 1000;
}

.candidate-timeline-step strong {
  font-size: 14px;
  line-height: 1.25;
}

.candidate-timeline-step small {
  min-height: 32px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.35;
}

.candidate-timeline-step.complete {
  border-color: #bbf7d0;
  background: #f0fdf4;
}

.candidate-timeline-step.complete span {
  background: #dcfce7;
  color: var(--green);
}

.candidate-timeline-step.pending {
  border-color: #fde68a;
  background: #fffbeb;
}

.candidate-timeline-step.active {
  border-color: var(--red);
  box-shadow: inset 0 0 0 1px var(--red), 0 14px 34px rgba(185, 28, 28, 0.08);
}

.candidate-action-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 14px;
}

.candidate-action-card h3 {
  margin: 2px 0 6px;
}

.candidate-action-card p {
  margin: 0;
  color: var(--muted);
  font-weight: 800;
}

.candidate-action-buttons {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

body.candidate-mode .candidate-action-buttons [data-candidate-action-view="major"] {
  background: var(--blue);
}

body.candidate-mode .candidate-action-buttons [data-candidate-download-notice] {
  background: var(--red);
}

.sidebar {
  background: #0f172a;
  color: #fff;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.logo-mark {
  width: 48px;
  height: 48px;
  background: #fff;
  border-radius: 12px;
  display: grid;
  place-items: center;
  color: var(--red);
  font-size: 13px;
  font-weight: 900;
}

.logo-mark img {
  width: 38px;
  height: 38px;
  object-fit: contain;
  display: block;
}

.brand strong,
.brand span {
  display: block;
}

.brand span {
  color: #cbd5e1;
  font-size: 13px;
  font-weight: 700;
}

.steps {
  display: grid;
  gap: 10px;
}

.step {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  color: #cbd5e1;
  background: rgba(255, 255, 255, 0.04);
  text-align: left;
}

.step.active {
  background: #fff;
  color: var(--red-dark);
}

.step-icon {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.12);
  font-size: 12px;
  font-weight: 900;
}

.step.active .step-icon {
  background: #fee2e2;
}

.step strong,
.step small {
  display: block;
}

.step strong {
  font-size: 13px;
  text-transform: uppercase;
}

.step small {
  margin-top: 2px;
  font-size: 12px;
}

.integration-card {
  margin-top: auto;
  display: grid;
  gap: 8px;
  padding: 16px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.05);
}

.integration-card p,
.integration-card strong {
  margin: 0;
}

.integration-card p {
  color: #cbd5e1;
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.integration-card strong {
  font-size: 12px;
  color: #fff;
}

.main {
  min-width: 0;
  padding: 24px;
  overflow: auto;
}

.topbar,
.section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.topbar {
  margin-bottom: 18px;
}

.topbar-title {
  min-width: 0;
  display: grid;
  gap: 6px;
}

.topbar-school-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.topbar-school-brand img {
  width: 34px;
  height: 34px;
  object-fit: contain;
  flex: 0 0 34px;
  display: block;
}

.topbar-school-brand .eyebrow {
  min-width: 0;
  margin: 0;
  overflow-wrap: anywhere;
}

.eyebrow {
  margin: 0 0 4px;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
  color: var(--red);
}

h1,
h2,
h3 {
  margin: 0;
  letter-spacing: 0;
}

h1 {
  font-size: 28px;
  line-height: 1.15;
}

h2 {
  font-size: 20px;
}

h3 {
  font-size: 18px;
}

.top-actions,
.section-actions,
.search-grid,
.segmented {
  display: flex;
  align-items: center;
  gap: 10px;
}

.section-actions {
  flex-wrap: wrap;
  justify-content: flex-end;
}

.report-filter-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin: 14px 0 10px;
}

.report-filter-grid label {
  display: grid;
  gap: 6px;
  font-size: 12px;
  font-weight: 700;
  color: var(--muted);
  min-width: 0;
}

.report-filter-grid input,
.report-filter-grid select,
.report-filter-grid textarea {
  width: 100%;
  min-width: 0;
}

.icon-btn,
.primary-btn,
.secondary-btn,
.ghost-btn,
.segment {
  border: 0;
  border-radius: 8px;
  min-height: 40px;
  font-weight: 900;
}

.icon-btn {
  width: 42px;
  background: #fff;
  border: 1px solid var(--line);
  color: var(--muted);
  font-size: 20px;
}

.primary-btn {
  padding: 0 16px;
  background: var(--red);
  color: #fff;
}

.secondary-btn {
  padding: 0 16px;
  background: var(--blue);
  color: #fff;
}

.blue-btn,
.top-major-btn {
  background: var(--blue);
  color: #fff;
}

.top-notice-btn,
.top-major-btn {
  min-height: 42px;
  white-space: nowrap;
}

.logout-icon-btn {
  color: var(--blue);
}

.ghost-btn {
  padding: 0 16px;
  color: var(--red);
  background: #fff7ed;
  border: 1px solid #fed7aa;
}

.primary-btn:disabled,
.secondary-btn:disabled,
.ghost-btn:disabled,
.icon-btn:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.search-panel,
.view,
.kpi,
.notice-card,
.payment-control,
.qr-card,
.student-card,
.student-card-preview {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.04);
}

.search-panel {
  display: grid;
  grid-template-columns: minmax(220px, 0.8fr) minmax(320px, 1.2fr);
  gap: 18px;
  padding: 18px;
  margin-bottom: 16px;
}

.report-panel {
  display: grid;
  gap: 18px;
  margin-bottom: 22px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.04);
}

.report-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(280px, 0.6fr);
  gap: 18px;
  align-items: stretch;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--line);
}

.report-hero h2 {
  margin: 4px 0 10px;
  max-width: 860px;
  font-size: 26px;
  line-height: 1.18;
}

.report-hero p {
  max-width: 960px;
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.65;
  font-weight: 750;
}

.report-kpis {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.report-kpis article,
.report-card,
.operation-columns div,
.flow-diagram div {
  border: 1px solid var(--line);
  border-radius: 8px;
}

.report-kpis article {
  padding: 12px;
  background: var(--soft);
}

.report-kpis span,
.report-kpis strong {
  display: block;
}

.report-kpis span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.report-kpis strong {
  margin-top: 6px;
  font-size: 16px;
}

.report-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.live-report-card {
  margin-bottom: 16px;
}

.live-report-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-top: 16px;
}

.live-report-grid article {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px;
  background: var(--soft);
}

.live-report-grid span,
.live-report-grid small {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.live-report-grid strong {
  display: block;
  margin: 6px 0 4px;
  color: var(--ink);
  font-size: 24px;
  line-height: 1.1;
}

.report-status-layout {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: 18px;
}

.report-status-layout h4 {
  margin: 0 0 8px;
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.report-status-list {
  display: grid;
  gap: 8px;
}

.report-status-row {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 9px 10px;
  background: #fff;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.report-status-row span {
  min-width: 0;
}

.report-status-row small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-weight: 600;
  line-height: 1.35;
}

.report-status-row strong {
  color: var(--ink);
  white-space: nowrap;
}

.report-status-row.ok strong {
  color: var(--success);
}

.report-status-row.warn strong {
  color: var(--warning);
}

.report-status-row.error strong {
  color: var(--danger);
}

.finance-readiness-card {
  margin-bottom: 16px;
}

.finance-readiness-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 14px;
}

.finance-readiness-grid div {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
  background: var(--soft);
  min-width: 0;
}

.finance-readiness-grid span,
.finance-readiness-grid small {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.finance-readiness-grid strong {
  display: block;
  margin: 6px 0 4px;
  color: var(--ink);
  font-size: 18px;
  line-height: 1.2;
  overflow-wrap: anywhere;
}

.readiness-status.ok {
  color: var(--green);
}

.readiness-status.warn {
  color: var(--amber);
}

.readiness-status.error {
  color: var(--red);
}

.readiness-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-top: 12px;
}

.readiness-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px;
  background: #fff;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  min-width: 0;
}

.readiness-row span,
.readiness-row small {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
}

.readiness-row small {
  margin-top: 4px;
  color: var(--muted);
  font-weight: 700;
  line-height: 1.35;
}

.readiness-row strong {
  color: var(--ink);
  white-space: nowrap;
}

.readiness-row.ok strong {
  color: var(--green);
}

.readiness-row.warn strong {
  color: var(--amber);
}

.readiness-row.error strong {
  color: var(--red);
}

.finance-sync-panel {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--soft);
}

.finance-sync-panel span,
.finance-sync-panel small {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.finance-sync-panel strong {
  display: block;
  margin: 4px 0;
  color: var(--ink);
  font-size: 15px;
}

.finance-sync-panel .sync-ok {
  color: var(--green);
}

.finance-sync-panel .sync-warn {
  color: var(--amber);
}

.finance-sync-panel .sync-error {
  color: var(--red);
}

.report-card {
  padding: 16px;
  background: var(--paper);
}

.report-card h3 {
  margin: 0 0 12px;
  font-size: 17px;
}

.report-steps {
  display: grid;
  gap: 8px;
  margin: 0;
  padding-left: 20px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
  font-weight: 750;
}

.report-steps strong {
  color: var(--ink);
}

.flow-diagram {
  display: grid;
  grid-template-columns: 1fr auto 1fr auto 1fr auto 1fr;
  gap: 8px;
  align-items: center;
}

.flow-diagram.second-row {
  grid-template-columns: 1fr auto 1fr auto 1fr;
  margin-top: 12px;
}

.flow-diagram div {
  min-height: 82px;
  display: grid;
  place-items: center;
  padding: 12px;
  background: #f8fafc;
  text-align: center;
  font-weight: 900;
}

.flow-diagram small {
  color: var(--muted);
  font-weight: 800;
}

.flow-diagram span {
  color: var(--red);
  font-weight: 900;
}

.report-table {
  width: 100%;
  border-collapse: collapse;
  overflow: hidden;
  font-size: 13px;
}

.report-table th,
.report-table td {
  padding: 10px;
  border: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
  line-height: 1.45;
}

.report-table th {
  background: #f1f5f9;
  color: #334155;
  font-size: 12px;
  text-transform: uppercase;
}

.finance-webhook-table td:last-child {
  max-width: 320px;
  overflow-wrap: anywhere;
}

.webhook-filter-grid {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr) minmax(0, 1fr) auto;
  gap: 10px;
  align-items: end;
  margin: 12px 0;
}

.webhook-filter-grid label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.webhook-filter-grid input,
.webhook-filter-grid select {
  width: 100%;
}

.webhook-filter-actions {
  display: flex;
  gap: 8px;
}

.operation-columns {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.operation-columns div {
  padding: 12px;
  background: var(--soft);
}

.operation-columns strong {
  display: block;
  margin-bottom: 8px;
}

.operation-columns p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
  font-weight: 750;
}

.panel-title {
  margin: 0 0 6px;
  font-size: 13px;
  font-weight: 900;
  text-transform: uppercase;
}

.panel-copy {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.search-grid {
  flex-wrap: wrap;
  justify-content: flex-end;
}

.search-results {
  grid-column: 1 / -1;
  display: grid;
  gap: 10px;
  padding-top: 4px;
}

.search-results-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.search-results-header strong {
  color: var(--ink);
  font-size: 13px;
}

.search-result-list {
  display: grid;
  gap: 8px;
}

.search-result-item {
  width: 100%;
  min-height: 58px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  text-align: left;
  cursor: pointer;
}

.search-result-item:hover {
  border-color: var(--blue);
  background: #eff6ff;
}

.search-result-main {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.search-result-main strong,
.search-result-main small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.search-result-main small {
  color: var(--muted);
  font-size: 12px;
}

.search-result-badges {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  min-width: 0;
}

.search-mini-badge {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 0 8px;
  border-radius: 999px;
  background: #f1f5f9;
  color: var(--muted);
  font-size: 10px;
  font-weight: 900;
  line-height: 1;
  text-transform: uppercase;
  white-space: nowrap;
}

.search-mini-badge.complete {
  background: #dcfce7;
  color: var(--green);
}

.search-mini-badge.partial {
  background: #fef3c7;
  color: var(--amber);
}

.search-mini-badge.danger {
  background: #fee2e2;
  color: var(--red-dark);
}

.search-result-item em {
  flex: 0 0 auto;
  padding: 5px 8px;
  border-radius: 999px;
  background: #f8fafc;
  color: var(--muted);
  font-size: 11px;
  font-style: normal;
  font-weight: 900;
}

.user-chip {
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  max-width: 320px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  font-size: 12px;
  font-weight: 900;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

label {
  display: grid;
  gap: 6px;
}

label span {
  font-size: 11px;
  color: var(--muted);
  font-weight: 900;
  text-transform: uppercase;
}

input,
select {
  height: 40px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 12px;
  background: #fff;
  color: var(--ink);
  min-width: 190px;
}

.search-field input {
  min-width: 300px;
}

.alert {
  margin-bottom: 16px;
  padding: 12px 14px;
  border-radius: 8px;
  background: #fef2f2;
  border: 1px solid #fecaca;
  color: #991b1b;
  font-size: 13px;
  font-weight: 800;
}

.hidden {
  display: none !important;
}

.kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 16px;
}

.kpi {
  padding: 16px;
}

.kpi span,
.label {
  display: block;
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.kpi strong {
  display: block;
  margin-top: 8px;
  font-size: 18px;
}

.kpi.success strong {
  color: var(--green);
}

.view {
  display: none;
  padding: 20px;
  margin-bottom: 16px;
}

.active-view {
  display: block;
}

.report-view {
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.app-shell[data-view="report"] .search-panel,
.app-shell[data-view="report"] .kpi-grid,
.app-shell[data-view="report"] #alert {
  display: none;
}

.badge {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 10px;
  border-radius: 999px;
  background: #f1f5f9;
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.badge.complete {
  background: #dcfce7;
  color: var(--green);
}

.badge.warn {
  background: #fee2e2;
  color: var(--red-dark);
}

.badge.partial {
  background: #fef3c7;
  color: var(--amber);
}

.badge.optional {
  background: #e0f2fe;
  color: #075985;
}

.badge.danger {
  background: #fee2e2;
  color: var(--red-dark);
}

.danger-line {
  color: var(--red-dark);
}

.notice-layout,
.major-layout,
.payment-layout,
.profile-layout,
.student-affairs-layout,
.full-profile-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 18px;
}

.full-span {
  grid-column: 1 / -1;
}

.compact-heading {
  margin-bottom: 12px;
}

.document-list {
  display: grid;
  gap: 10px;
}

.document-meta-card {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  padding: 10px 12px;
  border: 1px solid #bfdbfe;
  border-radius: 8px;
  background: #eff6ff;
}

.document-meta-card span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.document-meta-card strong {
  color: var(--blue);
  font-size: 18px;
  font-weight: 950;
}

.document-preview {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  overflow: hidden;
}

.document-preview-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px;
  border-bottom: 1px solid var(--line);
}

.document-preview-header strong,
.document-preview-header small {
  display: block;
}

.document-preview-header small {
  margin-top: 4px;
  color: var(--muted);
  font-weight: 700;
}

.document-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.document-row-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.document-preview-frame {
  height: 520px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f8fafc;
  overflow: auto;
}

.document-preview-frame img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.document-preview-frame iframe {
  width: 100%;
  height: 100%;
  border: 0;
  background: #fff;
}

.document-preview-empty {
  display: grid;
  gap: 12px;
  justify-items: center;
  padding: 24px;
  color: var(--muted);
  text-align: center;
  font-weight: 800;
}

.document-preview-modal-card {
  width: min(1100px, 100%);
  height: min(860px, calc(100dvh - 32px));
  max-height: calc(100dvh - 32px);
  grid-template-rows: auto auto auto minmax(0, 1fr) auto;
  overflow: hidden;
}

.modal-document-preview-frame {
  min-height: 0;
  height: auto;
}

.document-preview-modal-card .modal-actions {
  padding-top: 10px;
  border-top: 1px solid var(--line);
  background: #fff;
}

.document-items {
  display: grid;
  gap: 10px;
}

.document-item {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--soft);
  color: inherit;
  cursor: pointer;
  text-align: left;
}

.document-item.active {
  border-color: var(--primary);
  background: #fff7ed;
}

.small-btn {
  min-height: 0;
  padding: 8px 10px;
  font-size: 12px;
}

.tiny-btn {
  min-height: 24px;
  padding: 0 7px;
  border-radius: 8px;
  font-size: 11px;
}

.danger-btn {
  border-color: #fecaca;
  color: var(--red-dark);
  background: #fff1f2;
}

.document-item strong,
.document-item small {
  display: block;
}

.document-item small {
  margin-top: 4px;
  color: var(--muted);
  font-weight: 700;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 12px;
}

.form-grid input,
.form-grid select,
.otp-panel input,
.student-note input {
  width: 100%;
  min-width: 0;
}

input[readonly] {
  background: #f8fafc;
  color: #475569;
}

.identity-warning {
  padding: 12px 14px;
  border: 1px solid #fbbf24;
  border-radius: 8px;
  background: #fffbeb;
  color: #92400e;
  font-size: 13px;
  font-weight: 850;
}

.identity-warning strong {
  display: block;
  margin-bottom: 6px;
  color: #b45309;
  text-transform: uppercase;
}

.identity-warning ul {
  margin: 0;
  padding-left: 18px;
}

.system-score-card input[readonly] {
  border-color: #cbd5e1;
  background: rgba(248, 250, 252, 0.82);
  color: var(--ink);
}

.profile-form-card {
  align-content: start;
}

.profile-layout {
  grid-template-columns: minmax(0, 1.2fr) minmax(320px, 0.8fr);
}

.profile-layout .profile-form-card {
  min-height: 100%;
}

.admission-form-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.form-inline-check {
  min-height: 46px;
  align-self: end;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  font-weight: 850;
}

.form-inline-check input {
  width: 20px;
  min-width: 20px;
  height: 20px;
  accent-color: var(--red);
}

.notice-card {
  padding: 18px;
}

.notice-card.highlight {
  background: #fff7ed;
  border-color: #fed7aa;
}

.notice-card h3 {
  margin-top: 6px;
}

.notice-card p {
  margin: 8px 0 0;
  color: var(--muted);
  font-weight: 700;
}

.original-major {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid #fed7aa;
}

.original-major span,
.original-major strong {
  display: block;
}

.original-major span {
  color: var(--amber);
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.original-major strong {
  margin-top: 4px;
  color: var(--ink);
}

.info-list {
  margin: 16px 0 0;
  display: grid;
  gap: 10px;
}

.info-list div,
.fee-line,
.history-item,
.qr-line {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.info-list dt,
.info-list dd {
  margin: 0;
}

.info-list dt,
.fee-line span,
.qr-line span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.info-list dd,
.fee-line strong,
.qr-line strong {
  font-weight: 900;
  text-align: right;
}

.subject-score-panel {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}

.score-heading-row {
  align-items: flex-end;
  gap: 12px;
}

.score-source-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
  align-items: center;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.score-source-dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  display: inline-block;
}

.score-source-dot.moet {
  background: #0ea5e9;
}

.score-source-dot.candidate {
  background: #10b981;
}

.score-source-dot.staff {
  background: #d21b23;
}

.subject-score-list {
  margin-top: 10px;
  display: grid;
  gap: 8px;
}

.staff-score-sections {
  margin-top: 12px;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 14px;
}

.score-subpanel {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.58);
}

.score-subpanel-title {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: baseline;
}

.score-subpanel-title strong {
  color: var(--blue);
  font-size: 16px;
  font-weight: 950;
}

.score-subpanel-title span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
  text-align: right;
}

.subject-score-item {
  display: grid;
  grid-template-columns: minmax(110px, 0.8fr) minmax(220px, 1.4fr);
  gap: 12px;
  align-items: center;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--soft);
}

.staff-score-row {
  grid-template-columns: minmax(150px, 0.8fr) minmax(320px, 1.6fr);
  background: rgba(255, 255, 255, 0.72);
}

.subject-score-title {
  min-width: 0;
}

.subject-score-item strong,
.subject-score-item small {
  display: block;
}

.subject-score-item small {
  margin-top: 2px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.subject-score-values {
  display: grid;
  grid-template-columns: repeat(4, minmax(48px, 1fr));
  gap: 6px;
}

.subject-score-values span {
  display: grid;
  gap: 2px;
  padding: 6px;
  border-radius: 6px;
  background: #fff;
  color: var(--muted);
  font-size: 10px;
  font-weight: 900;
  text-align: center;
  text-transform: uppercase;
}

.subject-score-values b {
  color: var(--ink);
  font-size: 13px;
}

.staff-score-values {
  grid-template-columns: repeat(4, minmax(76px, 1fr));
}

.transcript-score-values {
  grid-template-columns: repeat(3, minmax(76px, 1fr));
}

.thpt-score-values {
  grid-template-columns: minmax(120px, 220px);
  justify-content: end;
}

.staff-score-cell {
  display: grid;
  gap: 4px;
  padding: 7px;
  border: 2px solid #e5e7eb;
  border-radius: 8px;
  background: #fff;
}

.staff-score-cell span,
.staff-score-cell em {
  color: #64748b;
  font-size: 10px;
  font-style: normal;
  font-weight: 900;
  text-align: center;
  text-transform: uppercase;
}

.staff-score-cell input {
  width: 100%;
  min-width: 0;
  height: 34px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--ink);
  font-size: 17px;
  font-weight: 950;
  text-align: center;
}

.staff-score-cell input:disabled {
  cursor: not-allowed;
  opacity: 1;
}

.staff-score-cell input:focus {
  outline: 2px solid rgba(0, 113, 188, 0.28);
  outline-offset: 1px;
}

.staff-score-cell.source-moet {
  border-color: #0ea5e9;
  background: #eff6ff;
}

.staff-score-cell.score-locked input {
  color: #075985;
}

.staff-score-cell.source-candidate {
  border-color: #10b981;
  background: #ecfdf5;
}

.staff-score-cell.source-staff {
  border-color: #d21b23;
  background: #fff1f2;
}

.staff-score-cell.source-empty {
  border-style: dashed;
  background: #f8fafc;
}

.thpt-elective-panel {
  margin-top: 10px;
  display: grid;
  grid-template-columns: minmax(220px, 1fr) minmax(220px, 0.8fr) minmax(120px, 0.4fr) auto;
  gap: 10px;
  align-items: end;
  padding: 12px;
  border: 1px dashed #bfdbfe;
  border-radius: 8px;
  background: #f8fbff;
}

.thpt-elective-panel > div {
  min-width: 0;
}

.thpt-elective-panel strong,
.thpt-elective-panel small {
  display: block;
}

.thpt-elective-panel strong {
  color: var(--blue);
  font-weight: 950;
}

.thpt-elective-panel small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.thpt-elective-panel label {
  display: grid;
  gap: 5px;
}

.thpt-elective-panel label span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.empty-line {
  padding: 10px 12px;
  border: 1px dashed var(--line);
  border-radius: 8px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.score-data-summary {
  margin-top: 14px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 10px;
}

.score-data-card {
  display: grid;
  gap: 4px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafc;
}

.score-data-card small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.score-data-card strong {
  color: var(--ink);
  font-size: 14px;
}

.score-data-card span {
  color: var(--danger);
  font-size: 18px;
  font-weight: 900;
}

.score-data-form {
  margin-top: 14px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 10px;
  max-height: 480px;
  overflow: auto;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafc;
}

.score-data-field {
  min-width: 0;
  gap: 6px;
  padding: 10px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #fff;
}

.score-data-field span {
  min-height: 28px;
  overflow-wrap: anywhere;
  color: #475569;
  line-height: 1.25;
}

.score-data-field input {
  width: 100%;
  min-width: 0;
  height: 38px;
  font-weight: 850;
}

.score-data-field.boolean-field {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
}

.score-data-field.boolean-field input {
  width: 22px;
  min-width: 22px;
  height: 22px;
  accent-color: var(--red);
}

.score-json-editor {
  display: grid;
  gap: 8px;
  margin-top: 16px;
}

.score-json-editor span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.score-json-editor textarea {
  width: 100%;
  min-height: 260px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #0f172a;
  color: #e2e8f0;
  font: 12px/1.5 ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  resize: vertical;
}

.score-json-editor textarea:disabled {
  opacity: 0.72;
}

.fee-lines {
  margin-top: 14px;
  display: grid;
  gap: 8px;
}

.fee-line {
  padding: 12px;
  border-radius: 8px;
  background: var(--soft);
  border: 1px solid var(--line);
}

.fee-line.discount strong {
  color: var(--green);
}

.select-label {
  margin-bottom: 12px;
}

.select-label select {
  width: 100%;
}

.major-option-cards {
  display: grid;
  gap: 14px;
  margin: 10px 0 12px;
}

.major-option-group {
  display: grid;
  gap: 8px;
}

.major-option-group h3 {
  margin: 0;
  color: var(--blue);
  font-size: 14px;
  font-weight: 1000;
}

.major-option-group-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.major-option-card {
  min-height: 128px;
  display: grid;
  gap: 6px;
  justify-items: start;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  text-align: left;
}

.major-option-card strong,
.major-option-card small,
.major-option-card em {
  overflow-wrap: anywhere;
}

.major-option-card small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.major-option-card em {
  color: var(--red-dark);
  font-style: normal;
  font-weight: 900;
}

.major-option-card.active {
  border-color: var(--red);
  box-shadow: inset 0 0 0 1px var(--red);
}

.evaluation-card,
.history-list,
.payment-control,
.qr-card {
  min-height: 180px;
}

.payment-fee-items {
  display: grid;
  gap: 8px;
}

.payment-fee-heading {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.payment-fee-heading strong {
  color: var(--ink);
}

.payment-fee-item {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.payment-fee-item input {
  width: 18px;
  height: 18px;
}

.payment-fee-item span {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.payment-fee-item strong,
.payment-fee-item small {
  overflow-wrap: anywhere;
}

.payment-fee-item small,
.payment-fee-empty {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.payment-fee-item em {
  color: var(--ink);
  font-style: normal;
  font-weight: 900;
  white-space: nowrap;
}

.payment-fee-item.paid {
  opacity: 0.62;
}

.candidate-fee-table-wrap {
  width: 100%;
  overflow: hidden;
  border: 1px solid #111827;
  border-radius: 4px;
  background: #fff;
}

.candidate-fee-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
  font-size: 16px;
  line-height: 1.42;
}

.candidate-fee-table th,
.candidate-fee-table td {
  border: 1px solid #111827;
  padding: 11px 12px;
  vertical-align: middle;
}

.candidate-fee-table th {
  background: #fff;
  color: #111827;
  font-size: 16px;
  font-weight: 950;
  text-align: center;
}

.candidate-fee-check-col {
  width: 68px;
}

.candidate-fee-stt-col {
  width: 58px;
}

.candidate-fee-amount-col {
  width: 220px;
}

.candidate-fee-check-cell,
.candidate-fee-table td:nth-child(2) {
  text-align: center;
}

.candidate-fee-check-cell input {
  display: block;
  width: 22px;
  min-width: 22px;
  height: 22px;
  padding: 0;
  margin: 0 auto;
  accent-color: var(--red);
}

.candidate-fee-name {
  min-width: 0;
  color: #111827;
  font-weight: 900;
  overflow-wrap: normal;
  word-break: normal;
}

.candidate-fee-name small,
.candidate-fee-table small {
  display: block;
  margin-top: 3px;
  color: #4b5563;
  font-size: 11px;
  font-weight: 800;
}

.candidate-fee-note {
  line-height: 1.35;
}

.candidate-fee-table-note {
  padding: 10px 12px;
  border-top: 1px solid #111827;
  color: #374151;
  font-size: 13px;
  font-weight: 800;
  line-height: 1.45;
  background: #fff7ed;
}

.candidate-fee-table-note strong {
  color: var(--red);
  font-weight: 950;
}

.candidate-fee-tuition-line {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px 18px;
  align-items: center;
}

.candidate-fee-tuition-part {
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) max-content;
  gap: 8px;
  align-items: baseline;
}

.candidate-fee-tuition-part em {
  color: #111827;
  font-style: normal;
  font-weight: 900;
  overflow-wrap: normal;
  word-break: normal;
}

.candidate-fee-tuition-part strong {
  font-size: 18px;
  font-weight: 950;
  white-space: nowrap;
}

.candidate-fee-tuition-part .scholarship-money {
  color: var(--green);
}

.candidate-fee-amount {
  text-align: right;
  white-space: nowrap;
  font-size: 18px;
  font-weight: 950;
}

.candidate-fee-total-row td {
  font-weight: 950;
  background: #fff7f7;
}

.candidate-fee-total-row .candidate-fee-amount {
  color: var(--red);
  font-size: 22px;
}

.candidate-fee-paid {
  display: inline-block;
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
}

.candidate-fee-table tr.optional {
  background: #f8fafc;
}

.candidate-fee-table tr.paid {
  opacity: 0.58;
}

.staff-qr-card {
  padding: 0;
  overflow: hidden;
}

.staff-qr-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  justify-content: space-between;
  padding: 12px;
  border-top: 1px solid #111827;
  color: var(--muted);
  font-size: 13px;
  font-weight: 850;
}

.staff-qr-actions strong {
  color: var(--ink);
}

.notice-bulk-print-card {
  display: grid;
  gap: 14px;
  margin-top: 16px;
}

.notice-bulk-filter-grid {
  grid-template-columns: minmax(240px, 1.2fr) repeat(4, minmax(160px, 0.8fr));
}

.notice-print-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  border: 1px solid #bfdbfe;
  border-radius: 8px;
  background: #eff6ff;
  color: var(--blue);
  font-size: 13px;
  font-weight: 850;
}

.notice-print-summary.alert {
  border-color: #fecaca;
  background: #fff1f2;
  color: var(--danger);
}

.notice-print-table {
  display: grid;
  gap: 8px;
  overflow-x: auto;
}

.notice-print-select-all,
.notice-print-table-head,
.notice-print-row {
  display: grid;
  grid-template-columns: minmax(280px, 1.2fr) minmax(260px, 1.1fr) minmax(170px, 0.7fr) minmax(170px, 0.7fr);
  gap: 10px;
  align-items: center;
  min-width: 900px;
}

.notice-print-select-all {
  display: flex;
  min-width: 0;
  padding: 8px 10px;
  border: 1px dashed #bfdbfe;
  border-radius: 8px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
}

.notice-print-select-all strong {
  color: var(--blue);
}

.notice-print-table-head {
  padding: 8px 12px;
  border: 1px solid #111827;
  background: #f8fafc;
  color: var(--ink);
  font-size: 12px;
  font-weight: 950;
  text-transform: uppercase;
}

.notice-print-row {
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  cursor: pointer;
}

.notice-print-row:hover {
  border-color: #93c5fd;
  background: #f8fbff;
}

.notice-print-row span,
.notice-print-candidate {
  min-width: 0;
}

.notice-print-row strong,
.notice-print-row small {
  display: block;
}

.notice-print-row strong {
  overflow: hidden;
  color: var(--ink);
  font-size: 13px;
  font-weight: 950;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.notice-print-row small {
  overflow: hidden;
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.notice-address-ok {
  color: #047857 !important;
}

.notice-address-missing {
  color: var(--danger) !important;
}

.notice-source-badge {
  display: inline-flex;
  width: fit-content;
  max-width: 100%;
  margin-top: 6px;
  border-radius: 999px;
  padding: 4px 8px;
  background: #eef2ff;
  color: #1d4ed8;
  font-size: 10px;
  font-style: normal;
  font-weight: 950;
  line-height: 1.2;
  text-transform: uppercase;
  white-space: normal;
}

.notice-source-badge.official {
  background: #dbeafe;
  color: #1d4ed8;
}

.notice-source-badge.eligible {
  background: #fef3c7;
  color: #a16207;
}

.notice-source-badge.school {
  background: #dcfce7;
  color: #047857;
}

.notice-source-badge.direct {
  background: #e0f2fe;
  color: #075985;
}

.notice-source-badge.changed {
  background: #fee2e2;
  color: #b91c1c;
}

.notice-source-badge.unknown {
  background: #f1f5f9;
  color: #475569;
}

.notice-print-candidate {
  display: flex;
  gap: 10px;
  align-items: center;
}

.notice-print-pager {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  justify-content: space-between;
  min-width: 0;
  padding: 10px 12px;
  border: 1px solid #bfdbfe;
  border-radius: 8px;
  background: #eff6ff;
  color: var(--blue);
  font-size: 13px;
  font-weight: 900;
}

.notice-print-pager div {
  display: flex;
  gap: 8px;
}

.notice-print-job-panel {
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1px solid #bfdbfe;
  border-radius: 8px;
  background: #f8fbff;
}

.notice-print-job-header,
.notice-print-job-stats,
.notice-print-file-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  justify-content: space-between;
}

.notice-print-file-list {
  align-items: stretch;
  justify-content: flex-start;
}

.notice-print-file-btn {
  display: grid;
  min-width: min(100%, 320px);
  max-width: 100%;
  gap: 3px;
  justify-items: start;
  text-align: left;
  white-space: normal;
}

.notice-print-file-btn strong,
.notice-print-file-btn span,
.notice-print-file-btn small {
  max-width: 100%;
  overflow-wrap: anywhere;
}

.notice-print-file-btn small {
  opacity: .82;
  font-size: 11px;
}

.notice-print-history-panel {
  background: #fff;
}

.notice-print-history-list {
  display: grid;
  gap: 10px;
}

.notice-print-history-item {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafc;
}

.notice-print-history-item > div:first-child strong,
.notice-print-history-item > div:first-child small {
  display: block;
}

.notice-print-history-item > div:first-child strong {
  color: var(--ink);
  font-size: 14px;
  font-weight: 950;
}

.notice-print-history-item > div:first-child small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.notice-print-job-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.notice-print-job-header h4 {
  margin: 2px 0;
  color: var(--blue);
  font-size: 20px;
}

.notice-print-job-header small {
  color: var(--muted);
  font-weight: 850;
}

.notice-print-progress {
  height: 10px;
  overflow: hidden;
  border-radius: 999px;
  background: #dbeafe;
}

.notice-print-progress span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--danger), var(--blue));
  transition: width 0.25s ease;
}

.notice-print-progress.is-loading-source span {
  min-width: 72px;
  animation: notice-progress-pulse 1.2s ease-in-out infinite alternate;
}

@keyframes notice-progress-pulse {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(42px);
  }
}

.notice-print-job-stats {
  justify-content: flex-start;
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
}

.notice-sync-samples {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.notice-sync-samples span {
  padding: 6px 8px;
  border: 1px solid #bfdbfe;
  border-radius: 999px;
  background: #fff;
  color: var(--blue);
  font-size: 11px;
  font-weight: 900;
}

.notice-print-failures {
  padding: 10px;
  border: 1px solid #fecaca;
  border-radius: 8px;
  background: #fff1f2;
  color: #991b1b;
  font-size: 12px;
  font-weight: 800;
}

@media (max-width: 900px) {
  .notice-bulk-filter-grid {
    grid-template-columns: 1fr;
  }

  .notice-print-table {
    margin-inline: -4px;
    padding-bottom: 4px;
  }
}

.payment-followup {
  display: grid;
  gap: 14px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.staff-student-dashboard {
  display: grid;
  gap: 14px;
  margin-top: 18px;
}

.student-report-kpis {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.student-report-kpis > article {
  min-height: 96px;
  display: grid;
  align-content: center;
  gap: 6px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.04);
}

.student-report-kpis span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.student-report-kpis strong {
  color: var(--blue-dark);
  font-size: 28px;
  line-height: 1;
  font-weight: 1000;
}

.student-report-layout {
  display: grid;
  grid-template-columns: minmax(260px, 0.8fr) minmax(420px, 1.2fr);
  gap: 14px;
}

.student-report-list {
  display: grid;
  gap: 8px;
  max-height: 560px;
  overflow: auto;
  padding-right: 4px;
}

.student-report-row {
  width: 100%;
  display: grid;
  grid-template-columns: minmax(0, 1fr) max-content;
  gap: 12px;
  align-items: center;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: inherit;
  text-align: left;
  cursor: pointer;
}

.student-report-row:hover {
  border-color: var(--blue);
  box-shadow: inset 0 0 0 1px rgba(0, 112, 192, 0.16);
}

.student-report-row.enrolled {
  background: #f0fdf4;
  border-color: #bbf7d0;
}

.student-report-row strong,
.student-report-row small {
  display: block;
}

.student-report-row strong {
  color: var(--ink);
  font-size: 14px;
}

.student-report-row small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
}

.student-report-row em {
  color: var(--red);
  font-size: 12px;
  font-style: normal;
  font-weight: 950;
  text-align: right;
  white-space: nowrap;
}

.payment-followup-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.payment-choice-buttons {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.payment-choice-buttons.single-action {
  grid-template-columns: minmax(0, 1fr);
}

.payment-choice-buttons button.active {
  background: var(--red);
  color: #fff;
}

.payment-choice-buttons #chooseDirectPaymentBtn.active {
  background: var(--blue);
}

.payment-followup-header span,
.mini-label {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.payment-followup-header strong {
  display: block;
  margin-top: 3px;
}

.direct-date-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-top: 8px;
}

.direct-date-btn {
  min-height: 68px;
  display: grid;
  gap: 4px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafc;
  color: var(--ink);
  text-align: left;
}

.direct-date-btn strong,
.direct-date-btn span {
  overflow-wrap: anywhere;
}

.direct-date-btn span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.direct-date-btn.active {
  border-color: var(--green);
  background: #ecfdf5;
  color: #065f46;
  box-shadow: inset 0 0 0 1px #86efac;
}

.enrollment-plan-summary {
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1px solid rgba(14, 116, 144, 0.28);
  border-left: 5px solid var(--blue);
  border-radius: 8px;
  background: rgba(239, 246, 255, 0.82);
}

.enrollment-plan-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.enrollment-plan-heading strong {
  display: block;
  margin-top: 4px;
  color: var(--blue-dark);
  font-size: 18px;
  line-height: 1.25;
}

.enrollment-plan-documents {
  display: grid;
  gap: 6px;
  margin: 8px 0 0;
  padding-left: 22px;
  color: var(--ink);
  font-size: 13px;
  line-height: 1.35;
}

.enrollment-plan-documents li::marker {
  color: var(--red);
  font-weight: 900;
}

.enrollment-plan-notice-card {
  width: min(760px, 100%);
  max-height: min(86vh, 760px);
  overflow: auto;
}

.enrollment-plan-notice-date {
  display: block;
  padding: 12px 14px;
  border: 1px solid rgba(14, 116, 144, 0.24);
  border-left: 5px solid var(--blue);
  border-radius: 8px;
  background: #eff6ff;
  color: var(--blue-dark);
  font-size: 24px;
  line-height: 1.2;
}

.enrollment-plan-notice-docs {
  padding: 12px 14px;
  border: 1px solid rgba(220, 38, 38, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.82);
}

.enrollment-plan-notice-actions {
  justify-content: flex-end;
}

@media (max-width: 720px) {
  .enrollment-plan-heading {
    display: grid;
  }

  .enrollment-plan-heading button {
    width: 100%;
  }

  .enrollment-plan-notice-card {
    max-height: calc(100vh - 28px);
    padding: 20px;
  }

  .enrollment-plan-notice-date {
    font-size: 20px;
  }

  .enrollment-plan-notice-actions button {
    width: 100%;
  }
}

body.candidate-mode .candidate-timeline {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.qr-selected-fees {
  display: grid;
  gap: 4px;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafc;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.evaluation-card {
  padding: 16px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: var(--soft);
}

.evaluation-card.eligible {
  background: #ecfdf5;
  border-color: #bbf7d0;
}

.evaluation-card.ineligible {
  background: #fff1f2;
  border-color: #fecdd3;
}

.evaluation-card strong {
  display: block;
  margin-bottom: 8px;
}

.evaluation-card p {
  margin: 8px 0 0;
  color: var(--muted);
  font-weight: 700;
}

.otp-panel {
  display: grid;
  gap: 12px;
  margin-top: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.muted-note {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.45;
}

.warning-note {
  margin: 0;
  color: #9f1239;
  font-size: 12px;
  font-weight: 900;
  line-height: 1.45;
}

.history-list {
  display: grid;
  align-content: start;
  gap: 10px;
}

.history-item {
  padding: 12px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: var(--soft);
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(15, 23, 42, 0.62);
}

.modal-card {
  position: relative;
  width: min(520px, 100%);
  display: grid;
  gap: 14px;
  padding: 24px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: #fff;
  box-shadow: 0 24px 80px rgba(15, 23, 42, 0.28);
}

.modal-card h2 {
  margin: 0;
  font-size: 26px;
}

.modal-copy {
  margin: 0;
  color: var(--muted);
  font-weight: 800;
  line-height: 1.55;
}

.modal-close {
  position: absolute;
  top: 12px;
  right: 12px;
}

.modal-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.otp-mock-code {
  padding: 18px;
  border-radius: 8px;
  border: 2px dashed #f59e0b;
  background: #fffbeb;
  color: #7c2d12;
  font-size: 40px;
  line-height: 1;
  font-weight: 950;
  text-align: center;
  letter-spacing: 8px;
  font-variant-numeric: tabular-nums;
}

.history-item strong,
.history-item small {
  display: block;
}

.history-item small {
  margin-top: 4px;
  color: var(--muted);
  font-weight: 700;
}

.payment-control {
  padding: 18px;
  display: grid;
  align-content: start;
  gap: 14px;
  min-width: 0;
}

body.staff-mode .payment-layout {
  grid-template-columns: 1fr;
}

body.staff-mode .payment-control,
body.staff-mode .qr-card {
  width: 100%;
  min-width: 0;
}

.payment-policy {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid #bfdbfe;
  border-radius: 8px;
  background: #eff6ff;
}

.payment-policy > div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.payment-policy span,
.payment-policy small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.payment-policy strong {
  color: var(--blue);
  font-size: 13px;
}

.payment-readiness-note {
  margin: -4px 0 4px;
}

.payment-readiness-note.ok {
  color: var(--success);
}

.payment-readiness-note.warn {
  color: var(--warning);
}

.segmented {
  padding: 4px;
  border-radius: 8px;
  background: #f1f5f9;
}

.segment {
  flex: 1;
  background: transparent;
  color: var(--muted);
}

.segment.active {
  background: #fff;
  color: var(--red);
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.08);
}

.wide {
  width: 100%;
}

.qr-card {
  padding: 18px;
}

.qr-card.empty {
  display: grid;
  place-items: center;
}

.empty-state {
  text-align: center;
  color: var(--muted);
  font-weight: 800;
}

.big-icon {
  display: block;
  margin-bottom: 10px;
  font-size: 44px;
  color: #cbd5e1;
}

.qr-result {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  gap: 18px;
  align-items: start;
}

.bank-qr-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(112px, 1fr));
  gap: 10px;
  grid-column: 1 / -1;
}

.bank-qr-card {
  display: grid;
  gap: 6px;
  justify-items: center;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  text-align: center;
}

.bank-qr-card.selected {
  border-color: var(--red);
  box-shadow: inset 0 0 0 1px var(--red);
}

.bank-qr-card img {
  width: 132px;
  height: 132px;
  border: 0;
  border-radius: 6px;
}

.bank-qr-card strong,
.bank-qr-card span {
  overflow-wrap: anywhere;
}

.bank-qr-card span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.qr-result img {
  width: 180px;
  height: 180px;
  border: 1px solid var(--line);
  border-radius: 8px;
  object-fit: contain;
}

.qr-result .bank-qr-card img {
  width: 132px;
  height: 132px;
  border: 0;
  border-radius: 6px;
}

.qr-data {
  display: block;
  max-width: 100%;
  max-height: 180px;
  overflow: auto;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--text);
  font-size: 11px;
  line-height: 1.5;
  overflow-wrap: anywhere;
  text-align: left;
}

.qr-details {
  display: grid;
  gap: 10px;
}

.candidate-qr-card {
  padding: 0;
  overflow: hidden;
  background: #fff;
}

.candidate-qr-paper {
  border: 1px solid #111827;
  border-radius: 4px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.96);
}

.candidate-qr-beneficiary {
  padding: 8px 10px;
  border-bottom: 1px solid #111827;
  color: #111827;
  font-size: 15px;
  font-weight: 800;
  text-align: center;
}

.candidate-bank-qr-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.candidate-bank-qr-cell {
  min-width: 0;
  display: grid;
  align-content: start;
  justify-items: center;
  gap: 7px;
  padding: 10px;
  border-left: 1px solid #111827;
  text-align: center;
}

.candidate-bank-qr-cell:first-child {
  border-left: 0;
}

.candidate-bank-name {
  min-height: 58px;
  display: grid;
  place-items: center;
  color: #111827;
  font-size: 14px;
  line-height: 1.25;
  font-weight: 800;
  overflow-wrap: anywhere;
}

.candidate-bank-account {
  color: #ef0000;
  font-size: 18px;
  font-weight: 950;
  line-height: 1;
  overflow-wrap: anywhere;
}

.candidate-bank-qr-cell img {
  width: min(176px, 84%);
  aspect-ratio: 1;
  height: auto;
  object-fit: contain;
  border: 0;
  border-radius: 0;
}

.candidate-qr-row {
  display: grid;
  grid-template-columns: 140px minmax(0, 1fr);
  border-top: 1px solid #111827;
}

.candidate-qr-row span,
.candidate-qr-row strong {
  padding: 8px 10px;
}

.candidate-qr-row span {
  border-right: 1px solid #111827;
  color: #111827;
  font-weight: 800;
}

.candidate-qr-row strong {
  min-width: 0;
  color: #111827;
  font-size: 15px;
  overflow-wrap: anywhere;
}

.candidate-qr-content-row strong {
  color: #0070c0;
  text-align: center;
}

.payment-qr-modal-card {
  width: min(1040px, 100%);
  height: min(880px, calc(100dvh - 32px));
  max-height: calc(100dvh - 32px);
  grid-template-rows: auto auto minmax(0, 1fr) auto;
  overflow: hidden;
}

.payment-qr-modal-body {
  display: block;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  padding: 0 4px 12px 0;
}

.payment-qr-modal-body > * + * {
  margin-top: 12px;
}

.payment-qr-guide {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
}

.payment-qr-guide div,
.payment-qr-receipt-guide {
  min-width: 0;
  display: grid;
  gap: 4px;
  padding: 12px;
  border: 1px solid #111827;
  background: #fff7ed;
}

.payment-qr-guide strong,
.payment-qr-receipt-guide strong {
  color: var(--red);
  font-size: 13px;
  font-weight: 1000;
  text-transform: uppercase;
}

.payment-qr-guide span,
.payment-qr-receipt-guide span {
  color: var(--ink);
  font-size: 14px;
  font-weight: 850;
  line-height: 1.35;
}

.payment-qr-receipt-guide {
  background: #eff6ff;
  border-color: #1d4ed8;
}

.payment-qr-receipt-preview {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid var(--line);
  background: #fff;
}

.payment-qr-receipt-preview.empty {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.payment-qr-receipt-preview.success {
  border-color: #86efac;
  background: #f0fdf4;
}

.payment-qr-receipt-preview.success strong {
  color: #047857;
  font-size: 13px;
  font-weight: 950;
}

.payment-qr-receipt-preview img {
  display: block;
  width: min(420px, 100%);
  max-height: 260px;
  object-fit: contain;
  border: 1px solid var(--line);
  background: #fff;
}

.payment-qr-summary {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 8px;
  padding: 10px;
  border: 1px solid #111827;
  border-radius: 4px;
  background: #fff;
}

.payment-qr-summary div {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.payment-qr-summary span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.payment-qr-summary strong {
  color: var(--ink);
  font-size: 16px;
  font-weight: 950;
  overflow-wrap: anywhere;
}

.modal-qr-paper .candidate-bank-qr-cell img {
  width: min(210px, 78%);
}

.qr-download-btn {
  min-height: 34px;
  padding: 0 12px;
  font-size: 12px;
  font-weight: 950;
}

.payment-qr-modal-actions {
  margin-top: 0;
  padding-top: 12px;
  border-top: 1px solid var(--line);
  background: #fff;
}

.major-detail-otp-panel {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid #bfdbfe;
  border-radius: 8px;
  background: #eff6ff;
}

.major-detail-otp-panel input {
  width: 100%;
}

.health-insurance-optout-card {
  width: min(560px, 100%);
  gap: 12px;
}

.health-insurance-optout-card h2 {
  max-width: calc(100% - 48px);
  font-size: clamp(24px, 4vw, 32px);
  line-height: 1.15;
}

.health-insurance-optout-card .modal-copy {
  font-size: 15px;
  line-height: 1.55;
}

.health-insurance-optout-card .modal-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.health-insurance-optout-card .modal-actions button {
  min-width: 0;
  min-height: 44px;
  white-space: normal;
  line-height: 1.25;
}

.candidate-qr-missing {
  display: grid;
  place-items: center;
  width: 150px;
  aspect-ratio: 1;
  border: 1px dashed var(--line);
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.student-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 220px;
  gap: 20px;
  align-items: center;
  padding: 28px;
}

.student-card.enrolled {
  color: #fff;
  background: var(--green);
  border-color: var(--green);
}

.student-card.enrolled .eyebrow,
.student-card.enrolled .student-code span,
.student-card.enrolled p {
  color: #d1fae5;
}

.student-card p {
  color: var(--muted);
  font-weight: 700;
}

.student-code {
  padding: 18px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.22);
}

.student-code span,
.student-code strong {
  display: block;
}

.student-code span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.student-code strong {
  margin-top: 6px;
  font-size: 28px;
}

.print-notice {
  margin-top: 16px;
  padding: 22px;
  border: 1px dashed #cbd5e1;
  border-radius: 8px;
  background: #fff;
}

.print-notice-header,
.print-notice-grid div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.print-notice h2 {
  margin: 18px 0;
  text-align: center;
}

.print-notice p {
  line-height: 1.6;
  font-weight: 700;
}

.print-notice-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 16px 0;
}

.print-notice-grid div {
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.print-notice-grid dt,
.print-notice-grid dd {
  margin: 0;
}

.print-notice-grid dt {
  color: var(--muted);
  font-weight: 900;
}

.print-notice-grid dd {
  text-align: right;
  font-weight: 900;
}

.print-note {
  color: var(--muted);
  font-size: 12px;
}

.student-affairs-layout {
  margin-top: 16px;
}

.checklist {
  display: grid;
  gap: 10px;
  margin: 14px 0;
}

.checklist label {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
}

.checklist input {
  min-width: 18px;
  width: 18px;
  height: 18px;
}

.student-card-preview {
  min-height: 260px;
  padding: 24px;
  display: grid;
  align-content: center;
  justify-items: center;
  text-align: center;
  color: #fff;
  background: linear-gradient(135deg, #991b1b, #111827);
}

.student-card-preview span,
.student-card-preview small {
  font-weight: 900;
  letter-spacing: 0;
}

.student-card-preview strong {
  margin: 18px 0 8px;
  font-size: 34px;
}

.student-card-preview p {
  margin: 0 0 8px;
  font-size: 18px;
  font-weight: 900;
}

.candidate-enrolled-portal {
  display: grid;
  gap: 18px;
}

.enrolled-welcome-card,
.student-login-card,
.freshman-plan-panel,
.freshman-documents-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 16px 42px rgba(15, 23, 42, 0.08);
}

.enrolled-welcome-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 20px;
  border-color: #bfdbfe;
  background: linear-gradient(135deg, #eff6ff, #fff);
}

.enrolled-welcome-card h2 {
  margin: 4px 0 8px;
  color: var(--blue-dark);
  font-size: clamp(22px, 3vw, 34px);
  line-height: 1.12;
}

.enrolled-welcome-card p {
  max-width: 760px;
  color: var(--muted);
  font-weight: 800;
  line-height: 1.55;
}

.student-portal-button {
  display: inline-grid;
  place-items: center;
  min-width: 210px;
  padding: 13px 18px;
  border: 0;
  border-radius: 8px;
  color: #fff;
  text-align: center;
  text-decoration: none;
  background: var(--blue);
  box-shadow: 0 12px 24px rgba(2, 132, 199, 0.22);
}

.student-portal-button span {
  font-size: 18px;
  font-weight: 1000;
  line-height: 1.1;
}

.student-portal-button small {
  margin-top: 4px;
  color: rgba(255, 255, 255, 0.82);
  font-size: 12px;
  font-weight: 850;
}

.student-portal-button:hover {
  background: var(--blue-dark);
}

.enrolled-student-layout {
  display: grid;
  grid-template-columns: minmax(520px, 680px) minmax(280px, 1fr);
  align-items: stretch;
  gap: 18px;
}

.student-id-card-shell {
  display: grid;
  justify-items: center;
  gap: 12px;
}

.student-id-card-template {
  overflow: hidden;
  justify-self: center;
  width: min(100%, 640px);
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 20px 50px rgba(15, 23, 42, 0.14);
}

.student-id-header {
  position: relative;
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr) 116px;
  align-items: stretch;
  min-height: 150px;
}

.student-id-header img {
  width: 74px;
  align-self: start;
  justify-self: center;
  margin-top: 28px;
}

.student-id-header > div {
  display: grid;
  align-content: start;
  gap: 9px;
  padding: 38px 10px 10px;
}

.student-id-header span {
  color: #111827;
  font-size: 17px;
  font-weight: 1000;
  text-transform: uppercase;
}

.student-id-header strong {
  color: #b91c1c;
  font-size: 23px;
  line-height: 1.2;
  text-transform: uppercase;
}

.student-id-header em {
  display: grid;
  place-items: center;
  padding: 8px;
  background: #b91c1c;
  color: #fff;
  font-size: 25px;
  font-style: normal;
  font-weight: 1000;
  line-height: 1.1;
  text-align: center;
  text-transform: uppercase;
  writing-mode: vertical-rl;
  transform: rotate(180deg);
}

.student-id-photo-row {
  display: grid;
  grid-template-columns: 1fr;
  align-items: center;
  padding: 38px 146px 0 46px;
}

.student-id-photo {
  justify-self: center;
  width: min(400px, 62vw);
  aspect-ratio: 3 / 4;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px solid #e5e7eb;
  background: #f8fafc;
}

.student-id-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.student-id-photo span {
  color: var(--muted);
  font-size: 40px;
  font-weight: 900;
  text-align: center;
}

.student-id-identity-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 144px;
  align-items: end;
  gap: 12px;
  padding: 38px 18px 0 0;
}

.student-id-qr {
  display: grid;
  place-items: center;
  align-self: stretch;
  min-height: 132px;
  padding: 0;
  border: 0;
  text-decoration: none;
}

.student-id-qr img {
  width: 120px;
  height: 120px;
  image-rendering: crisp-edges;
  background: #fff;
}

.student-id-name {
  min-height: 82px;
  margin: 0;
  padding: 22px 18px;
  background: #b91c1c;
  color: #fff;
  font-size: 31px;
  font-weight: 1000;
  line-height: 1.2;
  text-align: center;
  text-transform: uppercase;
}

.student-id-number {
  padding: 28px 160px 0 14px;
  color: #dc2626;
  font-size: 39px;
  font-weight: 1000;
  text-align: center;
}

.student-id-meta {
  display: grid;
  gap: 6px;
  margin: 28px 0 0;
  padding: 0 34px 34px;
}

.student-id-meta div,
.student-login-card dl div {
  display: grid;
  grid-template-columns: 190px minmax(0, 1fr);
  gap: 16px;
  align-items: baseline;
}

.student-id-meta div {
  font-size: 30px;
}

.student-card-download-btn {
  width: min(100%, 640px);
  min-height: 58px;
  border-radius: 8px;
}

.student-id-meta dt,
.student-login-card dt {
  color: #111827;
  font-weight: 1000;
}

.student-id-meta dd,
.student-login-card dd {
  min-width: 0;
  margin: 0;
  color: #111827;
  font-weight: 900;
  overflow-wrap: anywhere;
}

.student-login-card {
  display: grid;
  align-content: start;
  gap: 12px;
  padding: 20px;
}

.student-login-card h3 {
  color: var(--blue-dark);
  font-size: 24px;
}

.student-login-card dl {
  display: grid;
  gap: 12px;
  margin: 0;
}

.student-login-card a {
  color: var(--blue);
  font-weight: 1000;
}

.freshman-plan-panel,
.freshman-documents-panel {
  padding: 20px;
}

.freshman-section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 14px;
}

.freshman-section-heading h3 {
  color: var(--blue-dark);
  font-size: clamp(20px, 2.5vw, 28px);
  line-height: 1.18;
}

.freshman-plan-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.freshman-plan-item {
  display: grid;
  gap: 6px;
  padding: 14px;
  border: 1px solid #dbeafe;
  border-left: 5px solid var(--blue);
  border-radius: 8px;
  background: #f8fafc;
}

.freshman-plan-item span {
  color: var(--red);
  font-size: 12px;
  font-weight: 1000;
  text-transform: uppercase;
}

.freshman-plan-item strong {
  color: var(--ink);
  font-size: 16px;
}

.freshman-plan-item em {
  color: var(--blue);
  font-style: normal;
  font-weight: 1000;
}

.freshman-plan-item p {
  color: var(--muted);
  font-weight: 750;
  line-height: 1.45;
}

.freshman-document-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.freshman-document-link {
  display: grid;
  gap: 6px;
  min-height: 104px;
  padding: 14px;
  border: 1px solid #fecaca;
  border-radius: 8px;
  color: inherit;
  text-decoration: none;
  background: #fff7f7;
}

.freshman-document-link strong {
  color: var(--red);
  font-size: 16px;
}

.freshman-document-link span {
  color: var(--muted);
  font-weight: 750;
  line-height: 1.4;
}

.freshman-document-link:hover {
  border-color: var(--red);
  background: #fff;
}

@media (max-width: 860px) {
  .enrolled-welcome-card,
  .freshman-section-heading {
    align-items: stretch;
    flex-direction: column;
  }

  .enrolled-student-layout,
  .freshman-plan-list,
  .freshman-document-grid {
    grid-template-columns: 1fr;
  }

  .student-id-card-template {
    width: 100%;
  }
}

@media (max-width: 560px) {
  .enrolled-welcome-card,
  .student-login-card,
  .freshman-plan-panel,
  .freshman-documents-panel {
    padding: 14px;
  }

  .student-id-header {
    grid-template-columns: 62px minmax(0, 1fr) 78px;
    min-height: 104px;
  }

  .student-id-header img {
    width: 52px;
  }

  .student-id-header span {
    font-size: 9px;
  }

  .student-id-header strong {
    font-size: 12px;
  }

  .student-id-header em {
    font-size: 12px;
  }

  .student-id-photo-row {
    padding: 16px 94px 0 18px;
  }

  .student-id-photo {
    width: min(250px, 62vw);
  }

  .student-id-identity-row {
    grid-template-columns: minmax(0, 1fr) 96px;
    gap: 6px;
  }

  .student-id-name {
    min-height: 50px;
    padding: 12px 10px;
    font-size: 17px;
  }

  .student-id-qr img {
    width: 84px;
    height: 84px;
  }

  .student-id-number {
    padding-right: 100px;
    font-size: 21px;
  }

  .student-id-meta {
    padding: 0 12px 14px;
  }

  .student-id-meta div,
  .student-login-card dl div {
    grid-template-columns: 96px minmax(0, 1fr);
    gap: 6px;
    font-size: 17px;
  }

  .freshman-plan-item,
  .freshman-document-link {
    padding: 12px;
  }
}

@media (max-width: 640px) {
  body.candidate-mode.candidate-enrolled-mode .main {
    width: calc(100% - 4px);
    margin-top: 2px;
    padding: 4px;
    border-width: 5px;
  }

  body.candidate-mode.candidate-enrolled-mode .main::before {
    inset: 4px;
  }

  body.candidate-mode.candidate-enrolled-mode .view {
    padding-left: 0;
    padding-right: 0;
  }
}

.print-window {
  background: #fff;
  padding: 0;
}

.print-window .print-notice,
.print-window .student-card-preview {
  box-shadow: none;
  border-radius: 0;
}

body.candidate-mode {
  background: #f3f4f6;
}

body.candidate-mode .app-shell {
  grid-template-columns: 1fr;
  background:
    linear-gradient(90deg, var(--red) 0 10px, transparent 10px),
    #f3f4f6;
}

body.candidate-mode .sidebar,
body.candidate-mode .kpi-grid,
body.candidate-mode #view-profile > .profile-layout,
body.candidate-mode #view-profile > .full-profile-grid,
body.candidate-mode #view-profile .section-actions,
body.candidate-mode #view-notice .notice-layout,
body.candidate-mode #view-notice #feeLines,
body.candidate-mode #printNoticeArea,
body.candidate-mode #paymentBadge,
body.candidate-mode .finance-sync-panel,
body.candidate-mode .payment-policy,
body.candidate-mode .payment-bank-label,
body.candidate-mode #qrCard,
body.candidate-mode .payment-control > .muted-note {
  display: none !important;
}

body.candidate-mode .main {
  width: min(1380px, 100%);
  margin: 0 auto;
  padding: 16px;
}

body.candidate-mode .topbar {
  padding: 14px 16px;
  border: 1px solid #f2c8c8;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 10px 30px rgba(185, 28, 28, 0.06);
}

body.candidate-mode .top-actions {
  flex-wrap: wrap;
  justify-content: flex-end;
}

body.candidate-mode .topbar-title {
  min-width: 0;
}

body.candidate-mode .topbar-school-brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  margin-bottom: 4px;
}

body.candidate-mode .topbar-school-brand img {
  width: 30px;
  height: 30px;
  object-fit: contain;
  flex: 0 0 auto;
}

body.candidate-mode .topbar-school-brand .eyebrow {
  margin: 0;
  color: var(--red);
  overflow-wrap: anywhere;
}

body.candidate-mode .top-actions #refreshBtn {
  display: none !important;
}

body.candidate-mode .top-notice-btn {
  background: var(--red);
}

body.candidate-mode .top-major-btn {
  background: var(--blue);
}

body.candidate-mode .candidate-timeline {
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 12px;
}

body.candidate-mode .candidate-timeline-step {
  min-height: 84px;
  padding: 10px;
  box-shadow: none;
}

body.candidate-mode .candidate-timeline-step small {
  min-height: 0;
}

body.candidate-mode .view {
  padding: 16px;
  margin-bottom: 12px;
}

.candidate-admission-summary {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(320px, 1fr);
  gap: 14px;
  margin: 14px 0;
  padding: 18px;
  border: 1px solid #fecaca;
  border-radius: 8px;
  background: linear-gradient(180deg, #fff, #fff7f7);
}

.admission-hero {
  display: grid;
  align-content: start;
  gap: 8px;
}

.admission-hero h3 {
  color: var(--red-dark);
  font-size: 26px;
  line-height: 1.18;
}

.admission-hero p {
  margin: 0;
  color: var(--muted);
  font-weight: 800;
}

.admission-metric-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.admission-metric-grid div,
.scholarship-summary {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.admission-metric-grid span,
.scholarship-summary span,
.scholarship-summary small {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.admission-metric-grid strong,
.scholarship-summary strong {
  display: block;
  margin-top: 6px;
  color: var(--ink);
  font-size: 17px;
  line-height: 1.25;
}

.scholarship-summary {
  grid-column: 1 / -1;
}

.scholarship-summary strong {
  color: var(--green);
}

.scholarship-summary small {
  margin-top: 6px;
  line-height: 1.45;
}

.admission-confirm-panel {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 14px;
  border: 1px solid #111827;
  background: rgba(255, 255, 255, 0.82);
}

.admission-confirm-panel span,
.admission-confirm-panel small {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.admission-confirm-panel strong {
  display: block;
  margin: 4px 0;
  color: var(--ink);
  font-size: 18px;
  line-height: 1.25;
}

.admission-confirm-actions {
  display: flex;
  align-items: stretch;
  gap: 10px;
  flex: 0 0 auto;
}

.admission-confirm-actions button {
  min-height: 52px;
  padding-inline: 18px;
  font-size: 16px;
}

.candidate-action-card-highlight {
  animation: candidate-action-pulse 1.6s ease;
}

@keyframes candidate-action-pulse {
  0%,
  100% {
    box-shadow: none;
  }
  35% {
    box-shadow: 0 0 0 4px rgba(14, 118, 192, 0.18);
  }
}

.candidate-readonly-profile {
  margin-bottom: 14px;
}

.candidate-readonly-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.candidate-code-pill {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid #bfdbfe;
  border-radius: 999px;
  background: #eff6ff;
  color: #0f3f7f;
  font-size: 13px;
  font-weight: 1000;
  white-space: nowrap;
}

.readonly-profile-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px 14px;
}

.readonly-profile-grid div {
  display: grid;
  gap: 4px;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}

.readonly-profile-grid dd {
  text-align: left;
}

body.candidate-mode .candidate-action-card {
  margin-bottom: 0;
  box-shadow: none;
}

body.candidate-mode #onlineEnrollmentCard {
  margin-top: 12px;
  border-color: #fecaca;
}

.document-next-actions {
  display: flex;
  justify-content: flex-end;
  margin-top: 14px;
}

.health-insurance-input {
  max-width: 360px;
  margin-top: 2px;
}

.health-insurance-input input {
  width: 100%;
}

.health-insurance-lookup-guide {
  display: grid;
  gap: 8px;
  max-width: 640px;
  margin-top: 10px;
  padding: 12px 14px;
  border: 1px solid #bfdbfe;
  border-left: 4px solid var(--blue);
  border-radius: 8px;
  background: rgba(239, 246, 255, 0.92);
  color: var(--blue-dark);
  line-height: 1.5;
}

.health-insurance-lookup-guide strong {
  color: var(--red);
  font-size: 15px;
  text-transform: uppercase;
}

.health-insurance-lookup-guide p,
.health-insurance-lookup-guide ol {
  margin: 0;
}

.health-insurance-lookup-guide a {
  width: fit-content;
  color: var(--blue);
  font-weight: 900;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.health-insurance-lookup-guide ol {
  padding-left: 20px;
}

.health-insurance-lookup-guide small {
  color: var(--muted);
  font-weight: 750;
}

body.candidate-mode .major-layout {
  grid-template-columns: 1fr;
}

body.candidate-mode .major-option-cards {
  grid-template-columns: 1fr;
}

body.candidate-mode .major-option-group-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

body.candidate-mode .major-option-card {
  min-height: 0;
  grid-template-columns: 1fr;
  align-items: start;
}

body.candidate-mode .major-option-card strong {
  font-size: 15px;
}

body.candidate-mode .major-option-card small {
  justify-self: start;
}

body.candidate-mode .major-option-card em {
  justify-self: start;
  text-align: left;
}

body.candidate-mode #requestMajorOtpBtn,
body.candidate-mode .select-label,
body.candidate-mode .otp-panel {
  display: none;
}

body.candidate-mode .otp-panel.otp-active {
  display: grid;
}

body.candidate-mode .history-item {
  background: #fff;
}

.major-detail-card,
.enrollment-date-card {
  width: min(620px, 100%);
}

.modal-info-list {
  margin-top: 0;
}

body.candidate-mode .payment-layout {
  grid-template-columns: 1fr;
  gap: 12px;
}

body.candidate-mode .payment-control {
  box-shadow: none;
}

.partial-payment-panel {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid #fed7aa;
  border-radius: 8px;
  background: #fff7ed;
}

.inline-check {
  display: flex;
  align-items: center;
  gap: 10px;
}

.inline-check input {
  width: 18px;
  height: 18px;
  min-width: 18px;
}

.inline-check span {
  color: var(--ink);
  font-size: 13px;
  text-transform: none;
}

.partial-percent-label {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
}

.partial-percent-label span {
  grid-column: 1 / -1;
}

.partial-percent-label input {
  width: 100%;
  min-width: 0;
  padding: 0;
}

.partial-percent-label strong {
  min-width: 54px;
  text-align: right;
}

body.candidate-mode .payment-fee-items {
  gap: 0;
  overflow: visible;
  border: 0;
  border-radius: 0;
  background: transparent;
}

body.candidate-mode .payment-fee-heading,
body.candidate-mode .payment-fee-item {
  border: 0;
  border-bottom: 1px solid var(--line);
  border-radius: 0;
}

body.candidate-mode .payment-fee-item:last-child {
  border-bottom: 0;
}

.payment-fee-item.locked {
  background: #fff;
}

.payment-fee-item.optional {
  background: #f8fafc;
}

.payment-fee-item.scholarship-row em {
  color: var(--green);
}

body.candidate-mode .qr-card {
  width: 100%;
  box-shadow: none;
}

body.candidate-mode .bank-qr-card img,
body.candidate-mode .qr-result .bank-qr-card img {
  width: 156px;
  height: 156px;
}

body.candidate-mode .candidate-bank-qr-cell img {
  width: min(210px, 78%);
}

.modal-date-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

@media print {
  body:not(.print-window) .app-shell,
  body:not(.print-window) .login-screen {
    display: none;
  }

  .print-window {
    margin: 0;
  }
}

@media (max-width: 980px) {
  .app-shell {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: static;
    padding: 16px;
  }

  .steps {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }

  .step {
    display: grid;
    justify-items: center;
    text-align: center;
  }

  .integration-card {
    display: none;
  }

  .search-panel,
  .candidate-timeline,
  .report-hero,
  .report-grid,
  .live-report-grid,
  .finance-readiness-grid,
  .readiness-list,
  .report-status-layout,
  .notice-layout,
  .major-layout,
  .payment-layout,
  .profile-layout,
  .student-report-layout,
  .full-profile-grid,
  .form-grid,
  .report-filter-grid,
  .webhook-filter-grid,
  .operation-columns,
  .student-affairs-layout,
  .student-card {
    grid-template-columns: 1fr;
  }

  .bank-qr-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  body.candidate-mode .major-option-group-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  body.candidate-mode .payment-layout {
    grid-template-columns: 1fr;
  }

  .flow-diagram,
  .flow-diagram.second-row {
    grid-template-columns: 1fr;
  }

  .flow-diagram span {
    transform: rotate(90deg);
  }

  .kpi-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .student-report-kpis {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .main {
    padding: 14px;
  }

  .topbar,
  .section-heading {
    align-items: flex-start;
    flex-direction: column;
  }

  .steps {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .search-grid,
  .report-filter-grid,
  .finance-sync-panel,
  .top-actions {
    width: 100%;
  }

  .search-grid label,
  .search-grid button,
  .top-actions button,
  input,
  select {
    width: 100%;
    min-width: 0;
  }

  body.candidate-mode .top-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr)) 44px;
    width: 100%;
  }

  body.candidate-mode .top-actions .user-chip {
    grid-column: 1 / -1;
  }

  body.candidate-mode .top-actions button {
    width: 100%;
  }

  body.candidate-mode .top-actions .icon-btn {
    width: 44px;
    min-width: 44px;
    justify-self: end;
  }

  .finance-sync-panel {
    align-items: stretch;
    flex-direction: column;
  }

  .online-document-row,
  .payment-fee-item,
  .direct-date-grid,
  .major-option-cards,
  .major-option-group-grid,
  .bank-qr-grid,
  .candidate-bank-qr-grid {
    grid-template-columns: 1fr;
  }

  .candidate-fee-table-wrap {
    border-color: #111827;
    overflow: hidden;
  }

  .candidate-fee-table,
  .candidate-fee-table tbody,
  .candidate-fee-table tr,
  .candidate-fee-table td {
    display: block;
    width: 100%;
  }

  .candidate-fee-table thead {
    display: none;
  }

  .candidate-fee-table tr {
    border-bottom: 1px solid #111827;
  }

  .candidate-fee-table tr:last-child {
    border-bottom: 0;
  }

  .candidate-fee-table td {
    display: grid;
    grid-template-columns: 76px minmax(0, 1fr);
    gap: 8px;
    border: 0;
    border-bottom: 1px solid #e5e7eb;
    padding: 10px 12px;
    text-align: left;
    white-space: normal;
  }

  .candidate-fee-table td::before {
    content: attr(data-label);
    color: #4b5563;
    font-size: 11px;
    font-weight: 900;
    text-transform: uppercase;
  }

  .candidate-fee-table td:last-child {
    border-bottom: 0;
  }

  .candidate-fee-check-cell,
  .candidate-fee-table td:nth-child(2),
  .candidate-fee-amount {
    text-align: left;
  }

  .candidate-fee-table {
    font-size: 14px;
  }

  .candidate-fee-amount,
  .candidate-fee-tuition-part strong {
    font-size: 17px;
  }

  .student-report-kpis,
  .student-report-row {
    grid-template-columns: 1fr;
  }

  .student-report-row em {
    text-align: left;
    white-space: normal;
  }

  .thpt-elective-panel {
    grid-template-columns: 1fr;
  }

  .staff-qr-actions,
  .staff-qr-actions button {
    width: 100%;
  }

  .candidate-fee-tuition-line {
    grid-template-columns: 1fr;
    gap: 3px;
  }

  .candidate-fee-tuition-part {
    grid-template-columns: minmax(0, 1fr) max-content;
  }

  .candidate-fee-total-row td:first-child,
  .candidate-fee-total-row td:nth-child(2) {
    display: none;
  }

  .health-insurance-optout-card {
    padding: 18px;
  }

  .health-insurance-optout-card .modal-actions {
    grid-template-columns: 1fr;
  }

  .candidate-qr-paper {
    border-radius: 4px;
  }

  .candidate-bank-qr-cell {
    border-left: 0;
    border-top: 1px solid #111827;
  }

  .candidate-bank-qr-cell:first-child {
    border-top: 0;
  }

  .candidate-bank-name {
    min-height: 0;
  }

  .candidate-bank-qr-cell img {
    width: min(220px, 72vw);
  }

  .candidate-qr-row {
    grid-template-columns: 1fr;
  }

  .candidate-qr-row span {
    border-right: 0;
    border-bottom: 1px solid #111827;
  }

  .payment-qr-summary {
    grid-template-columns: 1fr;
  }

  .payment-qr-modal-card {
    width: 100%;
    height: calc(100dvh - 16px);
    max-height: calc(100dvh - 16px);
    padding: 16px;
  }

  .payment-qr-modal-body {
    padding-right: 0;
  }

  .modal-qr-paper .candidate-bank-qr-cell img {
    width: min(230px, 76vw);
  }

  .candidate-action-card,
  .payment-followup-header {
    align-items: flex-start;
    flex-direction: column;
  }

  .candidate-action-buttons,
  .candidate-action-buttons button,
  .payment-followup-header button {
    width: 100%;
  }

  .online-document-actions,
  .payment-fee-heading {
    justify-content: flex-start;
  }

  .online-document-row {
    grid-template-columns: 34px minmax(0, 1fr);
  }

  .online-document-actions {
    grid-column: 1 / -1;
    width: 100%;
  }

  .online-document-actions button {
    flex: 1 1 130px;
  }

  .online-document-file {
    width: 100%;
    justify-content: flex-start;
  }

  .online-enrollment-action-grid,
  .student-profile-readonly-grid,
  .student-profile-edit-grid {
    grid-template-columns: 1fr;
  }

  .student-profile-modal-card,
  .online-documents-modal-card {
    width: 100%;
    max-height: calc(100dvh - 16px);
    padding: 16px;
  }

  .online-action-buttons,
  .online-action-buttons button,
  .student-profile-modal-actions,
  .student-profile-modal-actions button {
    width: 100%;
  }

  .kpi-grid {
    grid-template-columns: 1fr;
  }

  .report-panel {
    padding: 12px;
  }

  .report-hero h2 {
    font-size: 21px;
  }

  .report-kpis {
    grid-template-columns: 1fr;
  }

  .live-report-grid,
  .finance-readiness-grid,
  .readiness-list,
  .report-status-layout {
    grid-template-columns: 1fr;
  }

  .report-table {
    display: block;
    overflow-x: auto;
    white-space: nowrap;
  }

  .qr-result {
    grid-template-columns: 1fr;
  }

  .subject-score-item,
  .subject-score-values {
    grid-template-columns: 1fr;
  }

  .staff-score-row {
    grid-template-columns: 1fr;
  }

  .staff-score-values {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .transcript-score-values,
  .thpt-score-values {
    grid-template-columns: 1fr;
    justify-content: stretch;
  }

  .score-subpanel-title {
    align-items: flex-start;
    flex-direction: column;
  }

  .score-subpanel-title span {
    text-align: left;
  }

  .document-preview-header,
  .document-item {
    align-items: flex-start;
    flex-direction: column;
  }

  .document-actions {
    width: 100%;
    justify-content: space-between;
  }

  .document-row-actions {
    width: 100%;
    justify-content: space-between;
  }

  .document-preview-frame {
    height: 380px;
  }

  .candidate-admission-summary,
  .admission-metric-grid,
  .readonly-profile-grid,
  body.candidate-mode .payment-layout,
  body.candidate-mode .major-option-card,
  .modal-date-grid {
    grid-template-columns: 1fr;
  }

  body.candidate-mode .main {
    padding: 12px;
  }

  body.candidate-mode .bank-qr-card img,
  body.candidate-mode .qr-result .bank-qr-card img {
    width: 176px;
    height: 176px;
  }

  .modal-backdrop {
    padding: 8px;
  }

  body.candidate-mode .major-option-card em {
    justify-self: start;
    text-align: left;
  }

  .document-next-actions,
  .document-next-actions button,
  .payment-choice-buttons {
    width: 100%;
  }

  .payment-choice-buttons {
    grid-template-columns: 1fr;
  }

  .payment-qr-guide,
  .payment-qr-summary {
    grid-template-columns: 1fr;
  }
}

/* Candidate electronic admission notice */
html.candidate-mode-root {
  scroll-behavior: auto;
  scroll-padding-top: var(--candidate-sticky-top, 104px);
  overflow-anchor: none;
}

body.candidate-mode {
  background: #fff;
  overflow-anchor: none;
}

body.candidate-mode .app-shell {
  display: block;
  min-height: 100vh;
  background:
    linear-gradient(90deg, var(--red) 0 8px, transparent 8px),
    #fff;
}

body.candidate-mode .main {
  position: relative;
  width: min(1120px, calc(100% - 28px));
  margin: 18px auto 52px;
  padding: clamp(18px, 3vw, 38px);
  overflow: visible;
  border: 18px solid transparent;
  border-radius: 54px 4px 54px 4px;
  background:
    linear-gradient(rgba(255, 255, 255, 0.94), rgba(255, 255, 255, 0.9)) padding-box,
    repeating-linear-gradient(135deg, var(--red) 0 14px, #a9161a 14px 16px, #dc2626 16px 28px) border-box;
  box-shadow: 0 22px 70px rgba(15, 23, 42, 0.18);
  backdrop-filter: blur(2px);
}

body.candidate-mode .main::before {
  content: "";
  position: absolute;
  inset: 14px;
  z-index: 0;
  pointer-events: none;
  border: 1px solid rgba(200, 25, 30, 0.35);
  border-radius: 38px 2px 38px 2px;
}

body.candidate-mode::after {
  content: "";
  position: fixed;
  left: 50%;
  top: 50%;
  z-index: 20;
  pointer-events: none;
  width: min(80vw, 80vh, 780px);
  height: min(80vw, 80vh, 780px);
  background: url("./logo-dau.svg") center / contain no-repeat;
  opacity: 0.04;
  transform: translate(-50%, -50%);
  filter: blur(1.6px) saturate(0.8);
  mix-blend-mode: multiply;
}

body.candidate-mode .main > * {
  position: relative;
  z-index: 1;
}

body.candidate-mode .topbar {
  position: sticky;
  top: 12px;
  z-index: 35;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  row-gap: 12px;
  margin: 0 0 12px;
  padding: 14px 0 0;
  border: 0;
  border-radius: 0;
  background: rgba(255, 255, 255, 0.72);
  box-shadow: none;
  backdrop-filter: blur(10px);
}

body.candidate-mode .top-actions {
  flex-wrap: nowrap;
}

body.candidate-mode .topbar h1 {
  color: #0f3f7f;
  font-size: clamp(24px, 3vw, 34px);
  font-weight: 1000;
  text-transform: uppercase;
}

body.candidate-mode .user-chip {
  border-color: #bfdbfe;
  color: #0f3f7f;
  background: #eff6ff;
}

body.candidate-mode .logout-icon-btn {
  border-color: #bfdbfe;
  color: var(--blue);
}

body.candidate-mode .candidate-timeline {
  grid-column: 1 / -1;
  position: relative;
  z-index: 30;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 0;
  margin: 0;
  padding: 0 0 8px;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  backdrop-filter: none;
}

body.candidate-mode .candidate-timeline::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 10px;
  height: 3px;
  background: linear-gradient(90deg, var(--red), var(--red) 42%, rgba(8, 117, 190, 0.7));
  pointer-events: none;
}

body.candidate-mode .candidate-timeline-step {
  position: relative;
  min-height: 40px;
  display: grid;
  justify-items: center;
  align-content: start;
  gap: 6px;
  padding: 0 6px;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  color: #64748b;
}

body.candidate-mode .candidate-timeline-step span {
  position: relative;
  z-index: 1;
  width: 18px;
  height: 18px;
  display: grid;
  place-items: center;
  border: 2px solid #fecaca;
  border-radius: 999px;
  background: #fff;
  color: var(--red-dark);
  font-size: 0;
  font-weight: 1000;
}

body.candidate-mode .candidate-timeline-step strong {
  font-size: 12px;
  font-weight: 1000;
  line-height: 1.15;
  text-align: center;
}

body.candidate-mode .candidate-timeline-step small {
  min-height: 0;
  display: none;
}

body.candidate-mode .candidate-timeline-step.complete {
  color: #0f766e;
  background: transparent;
}

body.candidate-mode .candidate-timeline-step.complete span {
  border-color: #5eead4;
  background: #ccfbf1;
  color: #0f766e;
}

body.candidate-mode .candidate-timeline-step.pending {
  color: #92400e;
  background: transparent;
}

body.candidate-mode .candidate-timeline-step.pending span {
  border-color: #fde68a;
  background: #fef3c7;
  color: #92400e;
}

body.candidate-mode .candidate-timeline-step.active {
  color: #0f3f7f;
  background: transparent;
  box-shadow: none;
}

body.candidate-mode .candidate-timeline-step.active span {
  width: 24px;
  height: 24px;
  margin-top: -3px;
  border-color: var(--blue);
  background: var(--blue);
  color: #fff;
  box-shadow: 0 0 0 5px rgba(14, 118, 192, 0.12), inset 0 0 0 5px #fff;
}

body.staff-mode .topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  row-gap: 12px;
  margin: -24px -24px 18px;
  padding: 18px 24px 12px;
  border-bottom: 1px solid rgba(200, 25, 30, 0.18);
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.08);
  backdrop-filter: blur(12px);
}

body.staff-mode .top-actions {
  flex-wrap: nowrap;
}

body.staff-mode .topbar h1 {
  color: #0f3f7f;
  font-size: clamp(24px, 2.4vw, 34px);
  font-weight: 1000;
  text-transform: uppercase;
}

body.staff-mode .candidate-timeline {
  grid-column: 1 / -1;
  position: relative;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 0;
  margin: 0;
  padding: 0 0 6px;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

body.staff-mode .candidate-timeline::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 10px;
  height: 3px;
  background: linear-gradient(90deg, var(--red), var(--red) 42%, rgba(8, 117, 190, 0.75));
  pointer-events: none;
}

body.staff-mode .candidate-timeline-step {
  position: relative;
  min-height: 42px;
  display: grid;
  justify-items: center;
  align-content: start;
  gap: 6px;
  padding: 0 6px;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  color: #64748b;
}

body.staff-mode .candidate-timeline-step span {
  position: relative;
  z-index: 1;
  width: 20px;
  height: 20px;
  display: grid;
  place-items: center;
  border: 2px solid #fecaca;
  border-radius: 999px;
  background: #fff;
  color: var(--red-dark);
  font-size: 0;
  font-weight: 1000;
}

body.staff-mode .candidate-timeline-step strong {
  color: currentColor;
  font-size: 12px;
  font-weight: 1000;
  line-height: 1.15;
  text-align: center;
}

body.staff-mode .candidate-timeline-step small {
  display: none;
}

body.staff-mode .candidate-timeline-step.complete {
  color: #0f766e;
}

body.staff-mode .candidate-timeline-step.complete span {
  border-color: #5eead4;
  background: #ccfbf1;
}

body.staff-mode .candidate-timeline-step.active {
  color: var(--blue);
}

body.staff-mode .candidate-timeline-step.active span {
  width: 24px;
  height: 24px;
  margin-top: -3px;
  border-color: var(--blue);
  background: var(--blue);
  color: #fff;
  box-shadow: 0 0 0 5px rgba(14, 118, 192, 0.12), inset 0 0 0 5px #fff;
}

body.candidate-mode .view {
  display: block;
  margin: 0;
  padding: 32px 0;
  scroll-margin-top: calc(var(--candidate-sticky-top, 104px) + 18px);
  border: 0;
  border-top: 2px solid #111827;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

body.candidate-mode #view-report {
  display: none !important;
}

body.candidate-mode #view-profile {
  border-top: 0;
  padding-top: 18px;
}

body.candidate-mode .view.active-view {
  background: transparent;
}

body.candidate-mode .view > .section-heading {
  align-items: flex-start;
  justify-content: flex-start;
  gap: 12px;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid #111827;
}

body.candidate-mode .view > .section-heading::before {
  flex: 0 0 auto;
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border: 2px solid var(--red);
  border-radius: 999px;
  color: var(--red);
  background: rgba(255, 255, 255, 0.82);
  font-size: 16px;
  font-weight: 1000;
}

body.candidate-mode #view-profile > .section-heading::before {
  content: "I";
}

body.candidate-mode #view-notice > .section-heading::before {
  content: "II";
}

body.candidate-mode #view-major > .section-heading::before {
  content: "III";
}

body.candidate-mode #view-payment > .section-heading::before {
  content: "IV";
}

body.candidate-mode #view-student > .section-heading::before,
body.candidate-mode #view-student .student-card::before {
  content: "V";
}

body.candidate-mode .view > .section-heading > div {
  min-width: 0;
  flex: 1 1 auto;
}

body.candidate-mode .view > .section-heading h2 {
  color: #0f3f7f;
  font-size: clamp(20px, 2.4vw, 28px);
  font-weight: 1000;
}

body.candidate-mode .candidate-admission-summary,
body.candidate-mode .notice-card,
body.candidate-mode .payment-control,
body.candidate-mode .student-card,
body.candidate-mode .evaluation-card,
body.candidate-mode .major-option-card,
body.candidate-mode .online-document-row,
body.candidate-mode .partial-payment-panel {
  border: 1px solid #111827;
  border-radius: 0;
  background: rgba(255, 255, 255, 0.72);
  box-shadow: none;
  backdrop-filter: blur(1.5px);
}

body.candidate-mode .candidate-admission-summary {
  margin: 0 0 12px;
  padding: 18px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.8), rgba(255, 247, 247, 0.7));
}

body.candidate-mode .admission-hero h3 {
  color: var(--red-dark);
  font-size: clamp(25px, 3vw, 36px);
}

body.candidate-mode .admission-metric-grid div,
body.candidate-mode .scholarship-summary {
  border: 1px solid #111827;
  border-radius: 0;
}

body.candidate-mode .admission-metric-grid strong,
body.candidate-mode .scholarship-summary strong {
  font-size: 18px;
}

body.candidate-mode .candidate-readonly-profile,
body.candidate-mode .candidate-action-card,
body.candidate-mode #onlineEnrollmentCard,
body.candidate-mode .payment-control {
  margin-top: 12px;
}

body.candidate-mode .candidate-action-card {
  display: flex !important;
  border-color: #111827;
  background: rgba(255, 255, 255, 0.72);
}

body.candidate-mode .candidate-action-card.hidden {
  display: none !important;
}

body.candidate-mode .candidate-action-card .label {
  color: var(--red);
}

.enrollment-mode-buttons {
  align-items: stretch;
}

.enrollment-mode-btn {
  min-width: 210px;
  min-height: 56px;
  font-size: 18px;
  justify-content: center;
}

.enrollment-mode-btn.online {
  background: var(--red);
}

.enrollment-mode-btn.direct {
  background: var(--blue);
  color: #fff;
  border-color: var(--blue);
}

.flow-reminder {
  margin: 10px 0 0;
  padding: 10px 12px;
  border: 1px solid #fecaca;
  border-left: 5px solid var(--red);
  background: rgba(254, 242, 242, 0.86);
  color: var(--red-dark);
  font-size: 14px;
  font-weight: 900;
}

.document-download-strip {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
  padding: 10px 12px;
  border: 1px solid #bfdbfe;
  background: rgba(239, 246, 255, 0.88);
}

.document-download-strip span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 1000;
  text-transform: uppercase;
}

.document-download-strip a {
  color: var(--blue-dark);
  font-weight: 1000;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.document-download-strip em {
  color: var(--muted);
  font-style: normal;
  font-weight: 800;
}

.enrollment-gate-card,
.health-insurance-info-card {
  max-width: 760px;
}

.enrollment-gate-blockers {
  display: grid;
  gap: 8px;
  margin: 14px 0 18px;
}

.enrollment-gate-blockers div {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  padding: 12px;
  border: 1px solid #fecaca;
  background: rgba(254, 242, 242, 0.74);
}

.enrollment-gate-blockers span {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 999px;
  background: var(--red);
  color: #fff;
  font-size: 12px;
  font-weight: 1000;
}

.enrollment-gate-blockers strong {
  color: var(--ink);
  font-size: 16px;
}

.health-insurance-rule-box {
  margin: 12px 0;
  padding: 14px;
  border: 1px solid #bfdbfe;
  border-left: 5px solid var(--blue);
  background: rgba(239, 246, 255, 0.9);
  color: var(--ink);
  font-size: 15px;
  font-weight: 800;
  line-height: 1.55;
}

body.candidate-mode .student-card,
body.candidate-mode .student-card.enrolled {
  color: var(--ink);
  background: rgba(255, 255, 255, 0.82);
  border-color: #111827;
}

body.candidate-mode .student-card.enrolled .eyebrow {
  color: var(--red);
}

body.candidate-mode .student-card.enrolled h2 {
  color: var(--blue-dark);
}

body.candidate-mode .student-card.enrolled .student-code span,
body.candidate-mode .student-card.enrolled p {
  color: var(--muted);
}

body.candidate-mode .student-card.enrolled .student-code {
  background: rgba(239, 246, 255, 0.9);
  border-color: #bfdbfe;
}

body.candidate-mode .student-card.enrolled .student-code strong {
  color: var(--red);
}

@media (max-width: 720px) {
  body.candidate-mode .candidate-action-card {
    align-items: stretch;
    flex-direction: column;
  }

  body.candidate-mode .candidate-action-buttons,
  body.candidate-mode .enrollment-mode-buttons {
    display: grid;
    grid-template-columns: 1fr;
    justify-content: stretch;
  }

  body.candidate-mode .enrollment-mode-btn {
    width: 100%;
    min-width: 0;
    min-height: 52px;
    font-size: 16px;
  }

  .document-download-strip {
    align-items: flex-start;
    flex-direction: column;
  }

  .health-insurance-rule-box {
    font-size: 14px;
  }

  .enrollment-gate-blockers div {
    grid-template-columns: 36px minmax(0, 1fr);
  }
}

body.candidate-mode .candidate-action-buttons .primary-btn,
body.candidate-mode .candidate-action-buttons .secondary-btn,
body.candidate-mode .payment-choice-buttons .primary-btn,
body.candidate-mode .payment-choice-buttons .secondary-btn {
  min-height: 44px;
}

body.candidate-mode .major-layout,
body.candidate-mode .payment-layout {
  margin-top: 0;
}

body.candidate-mode .major-history-panel {
  display: none !important;
}

body.candidate-mode #majorEvaluation {
  display: none !important;
}

body.candidate-mode .major-option-cards {
  gap: 10px;
}

body.candidate-mode .major-option-card.active {
  border-color: var(--red);
  background: #fff1f2;
}

body.candidate-mode .payment-control {
  padding: 0;
  border: 0;
  background: transparent;
}

body.candidate-mode .candidate-fee-table-wrap {
  border-radius: 0;
}

body.candidate-mode .payment-followup {
  margin-top: 14px;
  padding: 14px;
  border: 1px solid #111827;
  background: rgba(255, 255, 255, 0.72);
}

body.candidate-mode .student-card {
  position: relative;
  grid-template-columns: minmax(0, 1fr) minmax(160px, 220px);
  margin-top: 0;
  padding-left: 72px;
}

body.candidate-mode .student-card::before {
  position: absolute;
  left: 18px;
  top: 24px;
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border: 2px solid currentColor;
  border-radius: 999px;
  font-weight: 1000;
}

body.candidate-mode .student-affairs-layout {
  display: none !important;
}

@media (max-width: 980px) {
  .portal-gate-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .portal-gate-score-card img {
    max-height: none;
  }

  .portal-gate-letter-pages {
    grid-template-columns: minmax(0, 1fr);
  }

  body.candidate-login-mode .login-screen {
    grid-template-columns: minmax(0, 1fr);
    align-content: start;
    min-height: 100dvh;
  }

  body.candidate-login-mode .login-visual,
  body.candidate-login-mode .login-brand,
  body.candidate-login-mode .login-card {
    grid-column: 1;
  }

  body.candidate-login-mode .login-visual {
    grid-row: auto;
    min-height: 320px;
  }

  body.candidate-mode .main {
    width: min(calc(100% - 20px), 920px);
    border-width: 14px;
    border-radius: 36px 4px 36px 4px;
  }

  body.candidate-mode .candidate-timeline {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .portal-gate {
    padding: 10px;
  }

  .portal-gate-header {
    align-items: flex-start;
  }

  .portal-gate-header .logo-mark {
    width: 54px;
    height: 54px;
  }

  .gate-countdown-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .portal-gate-letter-btn {
    width: 100%;
  }

  .portal-gate-score-head {
    align-items: flex-start;
    flex-direction: column;
  }

  body.candidate-login-mode .login-screen {
    gap: 12px;
    padding: 12px;
  }

  body.candidate-login-mode .login-visual {
    min-height: 220px;
    border-width: 6px;
    border-radius: 28px 3px 28px 3px;
  }

  body.candidate-login-mode .login-visual-copy strong {
    font-size: 30px;
  }

  body.candidate-login-mode .login-card {
    padding: 20px;
    border-radius: 22px 3px 22px 3px;
  }

  body.candidate-mode .app-shell {
    background:
      linear-gradient(90deg, var(--red) 0 5px, transparent 5px),
      #fff;
  }

  body.candidate-mode .main {
    width: calc(100% - 10px);
    margin: 5px auto 24px;
    padding: 12px;
    border-width: 8px;
    border-radius: 26px 2px 26px 2px;
  }

  body.candidate-mode .main::before {
    inset: 7px;
    border-radius: 19px 2px 19px 2px;
  }

  body.candidate-mode .topbar {
    top: 0;
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
    padding: 10px 0 0;
  }

  body.candidate-mode .topbar h1 {
    font-size: 22px;
  }

  body.candidate-mode .candidate-timeline {
    display: grid !important;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 3px;
    padding-bottom: 6px;
    overflow: hidden;
  }

  body.candidate-mode .candidate-timeline-step {
    min-height: 34px;
    gap: 4px;
    padding: 0 2px;
  }

  body.candidate-mode .candidate-timeline-step span {
    width: 15px;
    height: 15px;
    border-width: 2px;
  }

  body.candidate-mode .candidate-timeline-step.active span {
    width: 20px;
    height: 20px;
  }

  body.candidate-mode .candidate-timeline-step strong {
    font-size: 9px;
    line-height: 1.05;
  }

  body.candidate-mode .top-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr)) 44px;
    flex-wrap: initial;
    width: 100%;
  }

  body.candidate-mode .top-actions .user-chip {
    display: none !important;
  }

  body.candidate-mode .top-actions button {
    width: 100%;
  }

  body.candidate-mode .top-actions .icon-btn {
    width: 44px;
    min-width: 44px;
  }

  body.candidate-mode .candidate-timeline-step small {
    display: none;
  }

  body.candidate-mode .view {
    padding: 24px 0;
    scroll-margin-top: calc(var(--candidate-sticky-top, 104px) + 14px);
  }

  body.candidate-mode .view > .section-heading {
    flex-direction: row;
    align-items: flex-start;
  }

  body.candidate-mode .candidate-readonly-heading {
    align-items: flex-start;
  }

  body.candidate-mode .candidate-code-pill {
    min-height: 30px;
    padding: 0 9px;
    font-size: 12px;
  }

  body.candidate-mode .view > .section-heading::before {
    width: 36px;
    height: 36px;
    font-size: 14px;
  }

  body.candidate-mode .candidate-admission-summary,
  body.candidate-mode .notice-card,
  body.candidate-mode .payment-followup {
    padding: 12px;
  }

  .admission-confirm-panel,
  .admission-confirm-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .admission-confirm-actions button {
    width: 100%;
  }

  body.candidate-mode .student-card {
    grid-template-columns: 1fr;
    padding: 58px 14px 16px;
  }

  body.candidate-mode .student-card::before {
    left: 14px;
    top: 14px;
  }
}

body.candidate-mode .candidate-timeline {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}
