:root {
  --bg: #fff7f5;
  --ink: #172033;
  --muted: #657184;
  --line: #ead7d8;
  --white: #ffffff;
  --wine: #a91f2b;
  --wine-dark: #7f141f;
  --wine-soft: #fff1f2;
  --button-red: #b02020;
  --teal: #0f7f8c;
  --teal-deep: #075f69;
  --teal-soft: #edfafa;
  --sky: #2070c0;
  --blue: var(--wine);
  --violet: var(--teal);
  --green: var(--teal);
  --cyan: #2aa7b4;
  --amber: #d59a1a;
  --pink: #b52a36;
  --shadow: 0 22px 50px rgba(93, 28, 35, 0.14);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background:
    radial-gradient(circle at 25% 0%, rgba(169, 31, 43, 0.08), transparent 32rem),
    radial-gradient(circle at 88% 10%, rgba(15, 127, 140, 0.08), transparent 30rem),
    linear-gradient(110deg, #fff7f5 0%, #f8fbfa 52%, #eff8f9 100%);
}

button,
input,
textarea {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

button,
.primary-action,
.secondary-action,
.admin-shortcut,
.back-link,
.nav-link,
.ghost-link,
.compact-button,
.copy-button,
.pay-button {
  transition: transform 0.18s ease, box-shadow 0.18s ease, filter 0.18s ease, background-color 0.18s ease, opacity 0.18s ease;
}

button:hover,
.primary-action:hover,
.secondary-action:hover,
.admin-shortcut:hover,
.back-link:hover,
.nav-link:hover,
.ghost-link:hover,
.compact-button:hover,
.copy-button:hover,
.pay-button:hover {
  filter: brightness(1.06);
  transform: translateY(-1px);
  box-shadow: 0 14px 28px rgba(93, 28, 35, 0.16);
}

button:active,
.primary-action:active,
.secondary-action:active,
.admin-shortcut:active,
.back-link:active,
.nav-link:active,
.ghost-link:active,
.compact-button:active,
.copy-button:active,
.pay-button:active {
  filter: brightness(0.96);
  transform: translateY(0);
}

button {
  border: 0;
  cursor: pointer;
}

a {
  color: inherit;
  text-decoration: none;
}

.hidden {
  display: none !important;
}

.public-shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 54px 0 34px;
}

.hero {
  position: relative;
  display: grid;
  justify-items: center;
  text-align: center;
  gap: 18px;
  margin-bottom: 34px;
}

.admin-shortcut {
  position: absolute;
  top: 0;
  right: 0;
  padding: 10px 14px;
  color: var(--wine-dark);
  border: 1px solid rgba(169, 31, 43, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.68);
}

.brand-mark {
  display: grid;
  place-items: center;
  width: auto;
  height: auto;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  overflow: visible;
}

.brand-mark.small {
  flex: 0 0 auto;
  width: auto;
  height: auto;
  padding: 0;
}

.brand-mark img {
  display: block;
  width: clamp(54px, 7.4vw, 86px);
  height: auto;
  aspect-ratio: 281 / 679;
  object-fit: contain;
}

.brand-mark.small img {
  width: 34px;
  height: auto;
}

.hero h1 {
  margin: 0;
  font-size: clamp(28px, 4vw, 46px);
  line-height: 1.08;
}

.hero h1 span {
  display: block;
}

.hero h1 span + span {
  margin-top: 8px;
}

.hero p {
  width: min(920px, 100%);
  margin: 0;
  color: #4f5d70;
  line-height: 1.65;
  text-align: center;
}

.lookup-panel,
.result-panel,
.content-panel,
.login-card {
  border: 1px solid rgba(255, 255, 255, 0.85);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.lookup-panel {
  padding: 22px;
}

.panel-heading,
.section-title {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 22px;
}

.panel-heading h2,
.section-title h2,
.content-panel h2,
.login-card h1,
.admin-topbar h1,
.dialog-head h2 {
  margin: 0;
}

.panel-heading h2,
.section-title h2 {
  color: var(--wine);
  font-size: 22px;
}

.panel-heading p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.icon-box {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  color: #ffffff;
  border-radius: 8px;
  font-weight: 850;
}

.search-icon {
  background: var(--button-red);
}

.ok-icon {
  background: var(--green);
}

.lookup-form {
  display: grid;
  grid-template-columns: 1fr 92px;
  gap: 12px;
}

.input-wrap {
  position: relative;
}

.input-wrap input,
.table-tools input,
.table-tools select,
.login-card input,
.student-form input,
.student-form select,
.student-form textarea {
  width: 100%;
  border: 1px solid #ead7d8;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.72);
  color: var(--ink);
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.input-wrap input {
  height: 48px;
  padding: 0 44px 0 14px;
}

.input-wrap span {
  position: absolute;
  right: 14px;
  top: 50%;
  color: #7f8da6;
  transform: translateY(-50%);
}

.input-wrap input:focus,
.table-tools input:focus,
.table-tools select:focus,
.login-card input:focus,
.student-form input:focus,
.student-form select:focus,
.student-form textarea:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 4px rgba(169, 31, 43, 0.12);
}

.lookup-form button,
.login-card button,
.compact-button,
.import-form button,
.student-form button[type="submit"] {
  min-height: 44px;
  padding: 0 18px;
  border-radius: 8px;
  color: #ffffff;
  background: var(--button-red);
  box-shadow: 0 12px 24px rgba(169, 31, 43, 0.2);
  font-weight: 800;
}

.message {
  min-height: 22px;
  margin-top: 12px;
  color: var(--muted);
  font-size: 14px;
}

.is-loading {
  color: var(--sky);
}

.is-success {
  color: var(--teal-deep);
}

.is-error {
  color: var(--wine);
}

.result-panel {
  margin-top: 28px;
  padding: 22px;
}

.section-title h2 {
  color: var(--teal-deep);
}

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

.info-card {
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 70px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.64);
}

.info-card.span-2 {
  grid-column: 1 / -1;
}

.mini-icon {
  display: grid;
  flex: 0 0 32px;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.8);
  font-weight: 850;
}

.info-card span:not(.mini-icon) {
  display: block;
  color: var(--muted);
  font-size: 13px;
}

.info-card strong {
  display: block;
  margin-top: 4px;
  overflow-wrap: anywhere;
  color: var(--wine-dark);
}

.info-card.blue {
  border-color: #e9b9bd;
  background: #fff6f5;
}

.info-card.purple {
  border-color: #d5eef1;
  background: #f1fbfb;
}

.info-card.green {
  border-color: #b9e4e8;
  background: #effafa;
}

.info-card.amber {
  border-color: #ffd66e;
  background: #fff8e9;
}

.info-card.cyan {
  border-color: #b9e4e8;
  background: #effafa;
}

.info-card.pink {
  border-color: #e9b9bd;
  background: #fff3f4;
}

.info-card.indigo {
  border-color: #d7e9ec;
  background: #f7fcfc;
}

.info-card.neutral {
  border-color: #d7dde8;
  background: #f8fafc;
}

.info-card.money {
  grid-column: 1 / -1;
  border-color: #a9dde2;
  background: linear-gradient(135deg, #f0fbfb, #fff7f5);
}

.info-card.money strong {
  color: var(--teal-deep);
  font-size: 24px;
}

.info-card.note {
  border-color: #ffd66e;
  background: #fffaf0;
}

.result-actions {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  margin-top: 22px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}

.primary-action,
.secondary-action {
  display: grid;
  grid-template-columns: auto auto;
  align-items: center;
  justify-content: center;
  justify-items: start;
  column-gap: 12px;
  min-height: 56px;
  padding: 12px 16px;
  border-radius: 8px;
  text-align: left;
}

.primary-action {
  color: #ffffff;
  background: var(--button-red);
}

.secondary-action {
  color: var(--teal-deep);
  border: 1px solid #8fcdd3;
  background: var(--teal-soft);
}

.primary-action span,
.secondary-action span {
  grid-row: 1 / span 2;
}

.action-icon {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.16);
}

.action-icon svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2;
}

.primary-action strong,
.primary-action small,
.secondary-action strong,
.secondary-action small {
  grid-column: 2;
}

.primary-action small,
.secondary-action small {
  display: block;
  opacity: 0.84;
}

.support-band {
  position: relative;
  display: grid;
  justify-items: center;
  gap: 14px;
  overflow: hidden;
  margin-top: 30px;
  padding: 42px 26px;
  border-radius: 8px;
  color: #ffffff;
  text-align: center;
  background:
    linear-gradient(115deg, var(--button-red), var(--button-red));
  box-shadow: 0 24px 58px rgba(93, 28, 35, 0.24);
}

.support-band::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.18), transparent);
  opacity: 0.55;
  transform: translateX(-70%);
  animation: supportSweep 7s ease-in-out infinite;
}

.support-band > * {
  position: relative;
  z-index: 1;
}

.support-icon,
.support-mini-icon {
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.18);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.18);
}

.support-icon {
  width: 52px;
  height: 52px;
}

.support-icon svg,
.support-mini-icon svg {
  width: 24px;
  height: 24px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2;
}

.support-band h2 {
  margin: 4px 0 0;
  font-size: 28px;
  line-height: 1.1;
}

.support-band p {
  margin: 0;
  color: rgba(255, 255, 255, 0.88);
}

.support-contact-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(240px, 1fr));
  gap: 18px;
  width: min(920px, 100%);
  margin-top: 12px;
}

.support-contact-card {
  display: grid;
  grid-template-columns: 44px 1fr;
  align-items: center;
  gap: 14px;
  min-height: 78px;
  padding: 16px 22px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.14);
  box-shadow: 0 16px 34px rgba(93, 28, 35, 0.18);
  text-align: left;
  backdrop-filter: blur(12px);
}

.support-contact-card:hover {
  background: rgba(255, 255, 255, 0.22);
  box-shadow: 0 18px 42px rgba(255, 255, 255, 0.15), 0 18px 34px rgba(93, 28, 35, 0.2);
}

.support-mini-icon {
  width: 42px;
  height: 42px;
}

.support-contact-card small,
.support-contact-card strong {
  display: block;
}

.support-contact-card small {
  color: rgba(255, 255, 255, 0.72);
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
}

.support-contact-card strong {
  margin-top: 4px;
  overflow-wrap: anywhere;
  font-size: 18px;
}

.support-time {
  margin-top: 8px;
  color: rgba(255, 255, 255, 0.84);
}

@keyframes supportSweep {
  0%, 45% {
    transform: translateX(-75%);
  }
  70%, 100% {
    transform: translateX(75%);
  }
}

.admin-shell {
  min-height: 100vh;
}

.login-view {
  display: grid;
  min-height: 100vh;
  place-items: center;
  padding: 24px;
}

.login-card {
  display: grid;
  width: min(430px, 100%);
  gap: 16px;
  padding: 28px;
}

.login-card .brand-mark {
  margin-bottom: 4px;
}

.login-card p {
  margin: -8px 0 4px;
  color: var(--muted);
}

.login-card label,
.student-form label {
  display: grid;
  gap: 7px;
  color: #394257;
  font-weight: 700;
}

.login-card input,
.student-form input,
.student-form select,
.student-form textarea,
.table-tools input,
.table-tools select {
  min-height: 42px;
  padding: 10px 12px;
}

.dashboard {
  display: block;
  min-height: 100vh;
}

.sidebar {
  display: flex;
  position: fixed;
  top: 0;
  bottom: 0;
  left: 0;
  z-index: 20;
  flex-direction: column;
  width: 260px;
  min-height: 100vh;
  height: 100vh;
  overflow-y: auto;
  padding: 22px;
  color: #ffffff;
  background: var(--button-red);
}

.brand-line {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  margin-bottom: 28px;
  min-width: 0;
}

.brand-line > div:last-child {
  min-width: 0;
  padding-top: 10px;
}

.brand-line strong {
  display: block;
  overflow-wrap: anywhere;
}

.brand-line span {
  display: block;
  color: rgba(255, 255, 255, 0.72);
  font-size: 13px;
}

.sidebar nav {
  display: grid;
  gap: 8px;
}

.nav-link,
.ghost-button,
.ghost-link {
  border-radius: 8px;
  color: rgba(255, 255, 255, 0.86);
  background: rgba(255, 255, 255, 0.08);
}

.nav-link {
  padding: 13px 14px;
}

.nav-link.active {
  color: var(--wine-dark);
  background: #ffffff;
  font-weight: 800;
}

.ghost-button,
.ghost-link {
  display: grid;
  place-items: center;
  min-height: 42px;
  margin-top: auto;
}

.ghost-link {
  margin-top: 10px;
}

.admin-content {
  margin-left: 260px;
  padding: 26px;
}

.admin-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 22px;
}

.admin-topbar span {
  color: var(--muted);
}

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

.stats-grid article {
  padding: 18px;
  border: 1px solid rgba(255, 255, 255, 0.8);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.76);
  box-shadow: 0 16px 34px rgba(93, 28, 35, 0.09);
}

.stats-grid span {
  color: var(--muted);
}

.stats-grid strong {
  display: block;
  margin-top: 8px;
  color: var(--wine);
  font-size: 28px;
}

.content-panel {
  padding: 18px;
}

#scholarshipsTab {
  display: grid;
  gap: 26px;
}

#scholarshipsTab.hidden {
  display: none !important;
}

#scholarshipsTab .content-panel {
  padding: 24px;
}

#scholarshipsTab .student-form {
  margin-bottom: 22px;
}

#scholarshipsTab .table-wrap {
  margin-top: 8px;
}

.panel-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.panel-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.sub-title-row {
  margin-top: 18px;
  margin-bottom: 8px;
}

.sub-title-row h3 {
  margin: 0;
  color: var(--wine-dark);
  font-size: 18px;
}

.table-tools {
  display: flex;
  gap: 8px;
}

.table-tools select {
  min-width: 190px;
}

.icon-button,
.row-actions button {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border: 1px solid var(--button-red);
  border-radius: 8px;
  color: #ffffff;
  background: var(--button-red);
  font-weight: 900;
}

.row-actions button[data-hide-scholarship],
.row-actions button[data-restore-scholarship] {
  width: auto;
  min-width: 64px;
  padding: 0 12px;
}

.table-wrap {
  overflow: auto;
}

.pagination-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 14px;
  color: #52627c;
  font-weight: 700;
}

.pagination-controls {
  display: flex;
  align-items: center;
  gap: 8px;
}

.pagination-controls label {
  display: flex;
  align-items: center;
  gap: 8px;
}

.pagination-controls select,
.pagination-controls button {
  min-height: 38px;
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  color: var(--wine);
  font: inherit;
  font-weight: 800;
}

.pagination-controls button {
  border-color: var(--button-red);
  color: #ffffff;
  background: var(--button-red);
}

.pagination-controls button:disabled {
  color: #9aa7bb;
  background: #f3f6fb;
  cursor: not-allowed;
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 850px;
}

th,
td {
  padding: 13px 12px;
  border-bottom: 1px solid var(--line);
  text-align: left;
}

th {
  color: var(--muted);
  font-size: 13px;
}

.status-pill {
  display: inline-flex;
  padding: 6px 9px;
  border-radius: 8px;
  color: var(--teal-deep);
  background: var(--teal-soft);
  font-size: 13px;
  font-weight: 800;
}

.review-pill {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 10px;
  border-radius: 8px;
  color: #52627c;
  background: #edf2f8;
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
}

.review-pill.is-waiting {
  color: #935300;
  background: #fff4d8;
}

.review-pill.is-approved {
  color: var(--teal-deep);
  background: var(--teal-soft);
}

.review-pill.is-rejected {
  color: var(--wine-dark);
  background: #fff0f1;
}

.row-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

.receipt-row-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-width: 430px;
}

.receipt-row-actions .review-pill {
  margin-left: auto;
}

.table-action-link,
.table-action-button {
  display: inline-grid;
  place-items: center;
  min-height: 36px;
  padding: 0 12px;
  border: 1px solid var(--button-red);
  border-radius: 8px;
  color: #ffffff;
  background: var(--button-red);
  font-weight: 900;
  white-space: nowrap;
}

.row-actions .table-action-button {
  width: auto;
  min-width: 64px;
  height: 36px;
  padding: 0 14px;
  line-height: 1;
}

.table-action-link:hover,
.table-action-button:hover {
  filter: brightness(1.04);
  transform: translateY(-1px);
  box-shadow: 0 10px 20px rgba(39, 58, 91, 0.14);
}

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

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

.log-list article {
  display: grid;
  gap: 4px;
  padding: 13px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fffdfb;
}

.log-list span,
.log-list small,
.import-panel p,
.muted-note {
  color: var(--muted);
}

.muted-note {
  margin: 0 0 16px;
}

.import-panel {
  max-width: 760px;
}

.export-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 18px;
}

.export-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 12px 16px;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--admin-blue), #2f5cf6);
  color: #ffffff;
  font-weight: 800;
  text-decoration: none;
  box-shadow: 0 14px 28px rgba(37, 99, 235, 0.18);
  transition: transform 0.18s ease, box-shadow 0.18s ease, filter 0.18s ease;
}

.export-button:hover {
  filter: brightness(1.04);
  transform: translateY(-1px);
  box-shadow: 0 18px 34px rgba(37, 99, 235, 0.24);
}

.import-form {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-top: 18px;
}

.import-form input {
  flex: 1;
  padding: 12px;
  border: 1px dashed #e8b6bb;
  border-radius: 8px;
  background: #fffdfb;
}

dialog {
  width: min(760px, calc(100% - 28px));
  padding: 0;
  border: 0;
  border-radius: 8px;
  box-shadow: var(--shadow);
}

dialog::backdrop {
  background: rgba(9, 19, 38, 0.46);
}

.profile-dialog {
  width: min(980px, calc(100% - 28px));
  max-height: calc(100vh - 32px);
  overflow: auto;
}

.receipt-dialog {
  width: min(980px, calc(100% - 28px));
  max-height: calc(100vh - 32px);
  overflow: auto;
}

.receipt-preview-modal {
  padding: 20px;
  background: #ffffff;
}

.receipt-preview-modal .dialog-head {
  margin-bottom: 18px;
}

.receipt-preview-modal .dialog-head p {
  margin: 6px 0 0;
  color: #52627c;
  font-weight: 700;
}

.receipt-preview-frame {
  display: grid;
  place-items: center;
  min-height: 360px;
  padding: 14px;
  border: 1px solid #ead7d8;
  border-radius: 8px;
  background: #fffdfb;
}

.receipt-preview-frame img {
  display: block;
  max-width: 100%;
  max-height: calc(100vh - 190px);
  border-radius: 8px;
  object-fit: contain;
  background: #ffffff;
  box-shadow: 0 10px 28px rgba(93, 28, 35, 0.12);
}

.receipt-no-image-state {
  display: grid;
  justify-items: center;
  gap: 10px;
  max-width: 460px;
  padding: 28px;
  border: 1px dashed #e8b6bb;
  border-radius: 8px;
  color: #52627c;
  background: #ffffff;
  text-align: center;
}

.receipt-no-image-state strong {
  color: var(--wine);
  font-size: 20px;
}

.admin-receipt-upload-form {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  gap: 12px;
  margin-top: 14px;
  padding: 14px;
  border: 1px solid #ead7d8;
  border-radius: 8px;
  background: #fffdfb;
}

.admin-receipt-upload-form label {
  flex: 1;
  min-width: 260px;
  color: #37445c;
  font-weight: 800;
}

.admin-receipt-upload-form input {
  display: block;
  width: 100%;
  margin-top: 8px;
  padding: 10px;
  border: 1px solid #e8b6bb;
  border-radius: 8px;
  background: #ffffff;
}

.admin-receipt-upload-form button {
  min-height: 42px;
  padding: 0 18px;
  border-radius: 8px;
  color: #ffffff;
  background: var(--button-red);
  font-weight: 900;
}

.receipt-dialog-actions {
  align-items: center;
  margin-top: 16px;
}

.receipt-dialog-actions .message {
  min-height: 0;
  margin: 0;
  margin-right: auto;
}

.receipt-dialog-actions button {
  min-height: 42px;
  padding: 0 18px;
  border: 0;
  border-radius: 8px;
  color: #ffffff;
  background: var(--button-red);
  font-weight: 900;
}

.receipt-dialog-actions .secondary-action {
  border: 1px solid #e8b6bb;
  color: var(--wine);
  background: var(--wine-soft);
}

.receipt-dialog-actions button:disabled {
  cursor: default;
  opacity: 0.72;
}

.student-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  padding: 20px;
  background: #ffffff;
}

.dialog-head,
.dialog-actions,
.full-field {
  grid-column: 1 / -1;
}

.dialog-head,
.dialog-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.dialog-actions {
  justify-content: flex-end;
}

.dialog-actions .ghost-button {
  min-width: 96px;
  margin: 0;
  color: var(--wine);
  border: 1px solid var(--line);
  background: #fffdfb;
}

.dashboard {
  --admin-blue: #173f95;
  --admin-blue-dark: #132653;
  --admin-blue-soft: #eef5ff;
  --admin-blue-line: #abcaff;
}

.admin-page {
  zoom: 0.9;
  min-height: 111.112vh;
}

.admin-page .admin-shell,
.admin-page .dashboard,
.admin-page .sidebar {
  min-height: 111.112vh;
}

@supports not (zoom: 1) {
  .admin-page {
    width: 111.111%;
    min-height: 111.111vh;
    transform: scale(0.9);
    transform-origin: top left;
  }
}

.dashboard .sidebar {
  background: linear-gradient(180deg, var(--admin-blue), var(--admin-blue-dark));
}

.dashboard .nav-link.active {
  color: var(--admin-blue);
}

.dashboard .admin-topbar h1,
.dashboard .content-panel h2,
.dashboard .stats-grid strong {
  color: var(--admin-blue);
}

.dashboard .stats-grid article,
.dashboard .content-panel {
  box-shadow: 0 16px 34px rgba(39, 58, 91, 0.1);
}

.dashboard .icon-button,
.dashboard .row-actions button,
.dashboard .pagination-controls button,
.dashboard .table-action-link,
.dashboard .table-action-button,
.dashboard .receipt-dialog-actions button,
.dashboard .student-form button[type="submit"],
.dashboard .import-form button,
.dashboard .compact-button {
  border-color: var(--admin-blue);
  color: #ffffff;
  background: var(--admin-blue);
}

.dashboard .pagination-controls select {
  color: var(--admin-blue);
}

.dashboard .table-tools input,
.dashboard .table-tools select,
.dashboard .student-form input,
.dashboard .student-form select,
.dashboard .student-form textarea {
  border-color: var(--admin-blue-line);
}

.dashboard .table-tools input:focus,
.dashboard .table-tools select:focus,
.dashboard .student-form input:focus,
.dashboard .student-form select:focus,
.dashboard .student-form textarea:focus {
  border-color: var(--admin-blue);
  box-shadow: 0 0 0 4px rgba(47, 92, 246, 0.12);
}

.dashboard .import-form input,
.dashboard .log-list article,
.dashboard .receipt-preview-frame,
.dashboard .dialog-actions .ghost-button,
.dashboard .pagination-controls button:disabled {
  background: #f8fbff;
}

.dashboard .import-form input {
  border-color: #9ebbf0;
}

.dashboard .receipt-dialog-actions .secondary-action,
.dashboard .dialog-actions .ghost-button {
  color: var(--admin-blue);
  border-color: var(--admin-blue-line);
  background: var(--admin-blue-soft);
}

.dashboard .receipt-dialog-actions .danger-action {
  color: #ffffff;
  border-color: var(--wine-dark);
  background: var(--wine-dark);
}

.enrollment-shell {
  width: min(1360px, calc(100% - 32px));
  margin: 0 auto;
  padding: 34px 0;
}

.enrollment-hero {
  position: relative;
  display: grid;
  justify-items: center;
  gap: 18px;
  margin-bottom: 34px;
  text-align: center;
}

.enrollment-hero h1 {
  margin: 4px 0 0;
  font-size: clamp(30px, 4vw, 44px);
  line-height: 1.1;
}

.enrollment-hero h1 span {
  display: block;
}

.enrollment-hero h1 span + span {
  margin-top: 8px;
}

.enrollment-hero p {
  margin: 0;
  color: #294369;
  font-size: 18px;
}

.enrollment-hero strong {
  color: #0b5fff;
}

.back-link {
  position: absolute;
  left: 0;
  top: 4px;
  padding: 10px 14px;
  color: var(--wine-dark);
  border: 1px solid #edc7ca;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.75);
  font-weight: 800;
}

.enrollment-card {
  overflow: hidden;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow);
}

.student-summary-card {
  margin-bottom: 22px;
}

.enrollment-card-head {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 28px;
  color: #ffffff;
  background: var(--button-red);
}

.enrollment-card-head h2,
.tuition-heading h2,
.payment-head h2 {
  margin: 0;
}

.enrollment-card-head p,
.tuition-heading p,
.payment-head p {
  margin: 5px 0 0;
}

.step-icon,
.tuition-icon {
  display: grid;
  flex: 0 0 46px;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 8px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.18);
  font-weight: 900;
}

.enrollment-info-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px 80px;
  padding: 30px;
}

.enrollment-info-grid article {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.enrollment-info-grid span,
.tuition-major-box span,
.fee-block span,
.bank-box span {
  color: var(--muted);
}

.enrollment-info-grid strong,
.tuition-major-box strong,
.fee-block strong {
  overflow-wrap: anywhere;
  color: var(--ink);
  font-size: 18px;
}

.enrollment-steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin: 0 0 22px;
}

.step-tile {
  display: grid;
  justify-items: center;
  gap: 8px;
  min-height: 176px;
  padding: 18px 14px;
  border: 1px solid #dce7f6;
  border-radius: 8px;
  color: #64748b;
  background: rgba(255, 255, 255, 0.74);
  box-shadow: 0 14px 28px rgba(39, 58, 91, 0.08);
  text-align: center;
}

.step-tile span {
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  color: #ffffff;
  border-radius: 50%;
  background: #9aa4b4;
  box-shadow: inset 0 0 0 5px rgba(255, 255, 255, 0.28);
  font-size: 20px;
  font-weight: 900;
}

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

.step-tile strong {
  color: #52627c;
  font-size: 18px;
}

.step-tile small {
  max-width: 160px;
  color: #7b8798;
  line-height: 1.45;
}

.step-tile.active {
  border-color: #e8b6bb;
  color: var(--wine);
  background: #fff4f4;
}

.step-tile.active span,
.step-tile.done span {
  background: var(--button-red);
  box-shadow: 0 0 0 6px rgba(169, 31, 43, 0.14);
}

.step-tile.active strong {
  color: var(--wine);
}

.step-tile.done strong {
  color: var(--teal-deep);
}

.tuition-card {
  display: grid;
  gap: 16px;
  padding: 24px;
  background: #fff7f5;
}

.tuition-heading {
  display: grid;
  justify-items: center;
  gap: 12px;
  margin: 4px 0 12px;
  text-align: center;
}

.tuition-heading .tuition-icon {
  background: var(--button-red);
}

.tuition-major-box,
.fee-block,
.scholarship-box,
.total-box {
  border-radius: 8px;
  background: #ffffff;
}

.tuition-major-box {
  display: grid;
  gap: 10px;
  padding: 18px;
  border: 1px solid #edc7ca;
}

.exam-choice-box {
  display: grid;
  gap: 14px;
  padding: 18px;
  border-radius: 8px;
  background: #ffffff;
  border: 1px solid #ead7d8;
}

.form-field {
  display: grid;
  gap: 8px;
  min-width: 0;
}

.form-field span {
  color: var(--muted);
  font-weight: 800;
}

.form-field input,
.form-field select {
  width: 100%;
  min-height: 46px;
  padding: 10px 12px;
  border: 1px solid #ead7d8;
  border-radius: 8px;
  color: var(--ink);
  background: #ffffff;
  font: inherit;
}

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

.eligibility-box {
  padding: 12px 14px;
  border-radius: 8px;
  border: 1px solid #ead7d8;
  color: var(--muted);
  background: #fffdfb;
  font-weight: 800;
}

.check-score-button {
  justify-self: start;
  min-height: 46px;
  padding: 0 22px;
  border: 0;
  border-radius: 8px;
  color: #ffffff;
  background: var(--button-red);
  font-weight: 900;
  cursor: pointer;
  box-shadow: 0 12px 24px rgba(169, 31, 43, 0.18);
}

.check-score-button:hover {
  filter: brightness(1.04);
}

.eligibility-box.is-success {
  border-color: #9ed7dc;
  color: var(--teal-deep);
  background: var(--teal-soft);
}

.eligibility-box.is-error {
  border-color: #ffc2c2;
  color: #b42318;
  background: #fff5f5;
}

.major-choice-box select:disabled {
  color: #94a3b8;
  background: #f1f5f9;
}

.fee-block {
  display: grid;
  gap: 10px;
  padding: 18px;
  border-left: 4px solid #e9b9bd;
}

.fee-block.active {
  border-left-color: var(--wine);
}

.fee-block.success {
  border-left-color: var(--green);
}

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

.fee-block.purple {
  border-left-color: var(--teal);
}

.fee-block.purple strong {
  color: var(--teal-deep);
}

.fee-block p {
  margin: 0;
  color: #52627c;
}

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

.tuition-options label {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 38px;
  padding: 10px;
  border: 1px solid #d0d9e8;
  border-radius: 8px;
  cursor: pointer;
}

.tuition-options label:has(input:checked) {
  border-color: var(--wine);
  background: var(--wine-soft);
  box-shadow: 0 0 0 3px rgba(169, 31, 43, 0.12);
}

.admission-options {
  display: grid;
  gap: 10px;
}

.admission-options label {
  display: grid;
  grid-template-columns: auto minmax(96px, max-content) 1fr;
  align-items: center;
  gap: 10px;
  padding: 12px;
  border: 1px solid #d0d9e8;
  border-radius: 8px;
  cursor: pointer;
}

.admission-options label:has(input:checked) {
  border-color: var(--wine);
  background: var(--wine-soft);
  box-shadow: 0 0 0 3px rgba(169, 31, 43, 0.12);
}

.admission-options span {
  color: #52627c;
}

.tuition-options .custom-tuition-option {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: auto max-content minmax(180px, 1fr);
  gap: 10px;
}

.custom-tuition-option input[type="text"] {
  min-height: 38px;
  padding: 8px 10px;
  border: 1px solid #ead7d8;
  border-radius: 8px;
  color: var(--ink);
  font: inherit;
  outline: none;
}

.custom-tuition-option input[type="text"]:focus {
  border-color: var(--wine);
  box-shadow: 0 0 0 3px rgba(169, 31, 43, 0.12);
}

.scholarship-box {
  padding: 18px;
  border: 1px solid #e7b100;
  background: #fff9df;
}

.scholarship-box strong {
  color: #8a5d00;
}

.scholarship-box p {
  margin: 8px 0 0;
  color: #7a5300;
}

.scholarship-slots,
.scholarship-preview {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.scholarship-slots span,
.scholarship-preview {
  padding: 8px 10px;
  border: 1px solid rgba(138, 93, 0, 0.22);
  border-radius: 8px;
  background: #ffffff;
  color: #6f4a00;
  font-weight: 800;
}

.scholarship-preview:empty {
  display: none;
}

.scholarship-preview {
  display: block;
}

.scholarship-preview.is-success {
  border-color: rgba(15, 127, 140, 0.26);
  background: #eaf8f7;
  color: var(--teal-deep);
}

.scholarship-preview.is-muted {
  border-color: rgba(169, 31, 43, 0.2);
  background: #fff7f5;
  color: var(--wine-dark);
}

.total-box {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 18px;
  color: var(--wine);
  border: 1px solid #e8b6bb;
  background: var(--wine-soft);
}

.total-box span {
  font-size: 22px;
  font-weight: 900;
  white-space: nowrap;
}

.payment-consent {
  display: grid;
  grid-template-columns: 20px 1fr;
  align-items: flex-start;
  gap: 10px;
  padding: 14px 16px;
  border: 1px solid #e8b6bb;
  border-radius: 8px;
  background: #fff7f5;
  color: var(--ink);
  font-size: 15px;
  font-weight: 700;
  line-height: 1.55;
  cursor: pointer;
}

.payment-consent input {
  width: 18px;
  height: 18px;
  margin-top: 3px;
  accent-color: var(--wine);
  cursor: pointer;
}

.pay-button {
  min-height: 52px;
  border-radius: 8px;
  color: #ffffff;
  background: var(--button-red);
  font-weight: 900;
}

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

.pay-button:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.next-step-button:disabled,
.ghost-step-button:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.next-step-button,
.ghost-step-button {
  min-height: 48px;
  padding: 0 18px;
  border-radius: 8px;
  font-weight: 900;
}

.next-step-button {
  color: #ffffff;
  border: 1px solid var(--button-red);
  background: var(--button-red);
}

.ghost-step-button {
  color: #52627c;
  border: 1px solid #d6e0ee;
  background: #ffffff;
}

.step-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 12px;
}

.receipt-card {
  display: grid;
  gap: 18px;
  padding: 24px;
  background: #fff7f5;
}

.receipt-main-icon {
  background: var(--button-red);
}

.receipt-upload-card {
  overflow: hidden;
  border-radius: 8px;
  background: #ffffff;
  box-shadow: var(--shadow);
}

.receipt-card-head {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 24px;
  color: #ffffff;
  background: var(--button-red);
}

.receipt-card-head h3,
.receipt-card-head p {
  margin: 0;
}

.receipt-card-head p {
  margin-top: 5px;
  color: rgba(255, 255, 255, 0.86);
}

.receipt-head-icon,
.receipt-image-icon {
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.18);
}

.receipt-head-icon {
  width: 46px;
  height: 46px;
  font-size: 24px;
  font-weight: 900;
}

.receipt-dropzone {
  display: grid;
  justify-items: center;
  gap: 12px;
  margin: 46px 22px 22px;
  padding: 42px 18px;
  border: 1px dashed #e8b6bb;
  border-radius: 8px;
  background: #fffdfb;
  text-align: center;
  cursor: pointer;
}

.receipt-dropzone input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.receipt-image-icon {
  width: 62px;
  height: 62px;
  color: var(--wine);
  background: var(--wine-soft);
  font-size: 28px;
}

.receipt-dropzone strong {
  color: #1d2a44;
  font-size: 18px;
}

.receipt-dropzone small,
.receipt-file-name {
  color: #52627c;
}

.receipt-file-name {
  padding: 8px 12px;
  border-radius: 8px;
  background: var(--wine-soft);
}

.receipt-upload-card .step-actions,
.receipt-upload-card .message {
  margin: 0 22px 22px;
}

.cash-step-card {
  overflow: hidden;
  border-radius: 8px;
  background: #ffffff;
  box-shadow: var(--shadow);
}

.cash-card-head {
  background: linear-gradient(135deg, #b45309, #ef4444);
}

.cash-instruction-list {
  display: grid;
  gap: 12px;
  padding: 24px;
}

.cash-instruction-list article {
  display: grid;
  gap: 5px;
  padding: 16px;
  border: 1px solid #fed7aa;
  border-radius: 8px;
  background: #fff7ed;
}

.cash-instruction-list strong {
  color: #7c2d12;
}

.cash-instruction-list span {
  color: #52627c;
  line-height: 1.5;
}

.cash-warning {
  margin: 0 24px 20px;
  padding: 14px 16px;
  border: 1px solid #f59e0b;
  border-radius: 8px;
  color: #7c2d12;
  background: #fffbeb;
  font-weight: 800;
}

.cash-step-card .step-actions {
  margin: 0 24px 24px;
}

.complete-card {
  display: grid;
  gap: 18px;
  padding: 24px;
  background: #fff7f5;
}

.complete-main-icon {
  background: var(--button-red);
}

.completion-box {
  padding: 22px;
  border: 1px solid #edc7ca;
  border-radius: 8px;
  background: #fff4f4;
  text-align: center;
}

.completion-box h3 {
  margin: 0;
  color: var(--wine);
  font-size: 22px;
}

.completion-box p {
  margin: 8px 0 0;
  color: #52627c;
}

.payment-dialog {
  width: min(1120px, calc(100dvw - 24px));
  max-width: calc(100dvw - 24px);
  max-height: calc(100dvh - 24px);
  overflow: auto;
  overscroll-behavior: contain;
}

.payment-modal {
  padding: 24px;
  background: #ffffff;
}

.app-alert-dialog {
  width: min(460px, calc(100% - 36px));
  padding: 0;
  overflow: visible;
  border: 0;
  border-radius: 8px;
  background: transparent;
}

.app-alert-dialog::backdrop {
  background: rgba(23, 32, 51, 0.58);
  backdrop-filter: blur(4px);
}

.app-alert-modal {
  display: grid;
  justify-items: center;
  gap: 14px;
  padding: 28px;
  border: 1px solid #f1c9ce;
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 28px 70px rgba(93, 28, 35, 0.26);
  text-align: center;
}

.app-alert-icon {
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  border-radius: 999px;
  color: #ffffff;
  background: var(--button-red);
  font-size: 30px;
  font-weight: 900;
  box-shadow: 0 14px 30px rgba(185, 28, 28, 0.24);
}

.app-alert-content h2 {
  margin: 0 0 8px;
  color: var(--wine-dark);
  font-size: 1.35rem;
}

.app-alert-content p {
  margin: 0;
  color: #475569;
  line-height: 1.55;
}

.app-alert-modal .pay-button {
  width: auto;
  min-width: 132px;
  min-height: 44px;
  margin-top: 4px;
  padding: 0 24px;
}

.payment-head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 18px;
}

.payment-head h2 {
  color: var(--wine);
}

.payment-head p {
  color: #5f6f87;
  line-height: 1.5;
}

.payment-body {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(280px, 0.9fr);
  gap: 24px;
}

.payment-left {
  display: grid;
  gap: 16px;
}

.payment-table {
  overflow: hidden;
  border-radius: 8px;
  border: 1px solid var(--line);
}

.table-title {
  padding: 12px 16px;
  color: var(--muted);
  background: #fff7f5;
  font-weight: 900;
}

.line-item {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  padding: 10px 16px;
  border-top: 1px solid #eef1f5;
}

.line-item span {
  color: #263247;
}

.line-item strong {
  min-width: 0;
  white-space: nowrap;
  text-align: right;
}

.line-item.total {
  color: var(--wine);
  background: var(--wine-soft);
  font-weight: 900;
}

.line-item.total span,
.line-item.total strong {
  color: var(--wine);
  font-size: 1.06rem;
}

.line-item-note {
  background: #fbfcff;
}

.line-item-note strong {
  max-width: 58%;
  color: #33425c;
  white-space: normal;
  line-height: 1.35;
}

.bank-box {
  position: relative;
  display: grid;
  gap: 12px;
  padding: 18px;
  border: 1px solid #9ed7dc;
  border-radius: 8px;
  background: var(--teal-soft);
}

.bank-box span {
  color: var(--teal-deep);
  font-weight: 900;
}

.bank-box strong {
  overflow-wrap: anywhere;
  font-size: 18px;
}

.copy-box {
  padding-right: 126px;
}

.copy-button {
  position: absolute;
  right: 18px;
  top: 50%;
  min-width: 86px;
  min-height: 38px;
  transform: translateY(-50%);
  border: 1px solid var(--button-red);
  border-radius: 8px;
  color: #ffffff;
  background: var(--button-red);
  font-weight: 900;
}

.qr-panel {
  display: grid;
  justify-items: center;
  align-content: start;
  gap: 16px;
  padding: 22px;
  border: 1px solid #9ed7dc;
  border-radius: 8px;
  background: var(--teal-soft);
  text-align: center;
}

.qr-panel > strong {
  color: var(--teal-deep);
  font-size: 18px;
}

.qr-tabs {
  display: flex;
  gap: 8px;
}

.qr-tabs button {
  min-height: 38px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  font-weight: 900;
}

.qr-tabs button.active {
  color: #ffffff;
  background: var(--button-red);
}

.real-qr {
  display: block;
  width: min(300px, 100%);
  padding: 14px;
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 8px 24px rgba(39, 58, 91, 0.2);
}

.qr-holder {
  min-height: 328px;
}

.secure-qr-image {
  display: block;
  width: 100%;
  height: auto;
}

.qr-blocked-state {
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 10px;
  width: 100%;
  min-height: 300px;
  padding: 18px;
  border: 1px solid #e8b6bb;
  border-radius: 8px;
  background: #fff6f4;
  color: var(--wine);
  text-align: center;
}

.qr-blocked-state strong,
.qr-blocked-state span {
  display: block;
}

.qr-blocked-state span {
  max-width: 220px;
  color: #7d4750;
  line-height: 1.5;
}

.fake-qr {
  position: relative;
  display: grid;
  place-items: center;
  width: min(300px, 78vw);
  aspect-ratio: 1;
  border: 16px solid #ffffff;
  border-radius: 8px;
  background:
    linear-gradient(90deg, #000 12px, transparent 12px 24px, #000 24px 36px, transparent 36px 48px) 0 0 / 48px 48px,
    linear-gradient(#000 12px, transparent 12px 24px, #000 24px 36px, transparent 36px 48px) 0 0 / 48px 48px,
    #ffffff;
  box-shadow: 0 8px 24px rgba(39, 58, 91, 0.2);
}

.fake-qr::before,
.fake-qr::after {
  content: "";
  position: absolute;
  width: 62px;
  height: 62px;
  border: 12px solid #000000;
  background: #ffffff;
}

.fake-qr::before {
  left: 12px;
  top: 12px;
  box-shadow: 180px 0 0 -12px #ffffff, 180px 0 0 0 #000000, 0 180px 0 -12px #ffffff, 0 180px 0 0 #000000;
}

.fake-qr::after {
  right: 42px;
  bottom: 42px;
  width: 36px;
  height: 36px;
  border-width: 8px;
}

.fake-qr span {
  z-index: 1;
  display: grid;
  place-items: center;
  width: 64px;
  height: 64px;
  color: #ffffff;
  border-radius: 50%;
  background: var(--button-red);
  font-weight: 900;
}

.qr-panel p {
  margin: 0;
  color: var(--teal-deep);
}

.qr-panel .qr-note {
  max-width: 360px;
  padding: 10px 12px;
  color: #8a4b00;
  border: 1px solid #ffd58a;
  border-radius: 8px;
  background: #fff8e8;
  font-weight: 800;
  line-height: 1.4;
}

.payment-warning {
  margin-top: 18px;
  padding: 16px;
  color: var(--wine-dark);
  border: 1px solid #edc7ca;
  border-radius: 8px;
  background: var(--wine-soft);
  font-weight: 800;
}

@media (max-width: 900px) {
  .dashboard {
    display: grid;
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: static;
    width: auto;
    min-height: auto;
    height: auto;
  }

  .admin-page .sidebar {
    min-height: auto;
  }

  .admin-content {
    margin-left: 0;
  }

  .sidebar nav {
    grid-template-columns: repeat(3, 1fr);
  }

  .ghost-button,
  .ghost-link {
    margin-top: 10px;
  }

  .enrollment-steps {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .stats-grid,
  .student-grid,
  .result-actions,
  .enrollment-info-grid,
  .score-grid,
  .payment-body {
    grid-template-columns: 1fr;
  }

  .payment-dialog {
    width: min(760px, calc(100dvw - 20px));
  }

  .qr-panel {
    order: -1;
  }

  .info-card.span-2,
  .info-card.money {
    grid-column: auto;
  }
}

@media (max-width: 640px) {
  .public-shell {
    width: min(100% - 20px, 1180px);
    padding-top: 28px;
  }

  .admin-shortcut {
    position: static;
    order: -2;
  }

  .lookup-form,
  .student-form,
  .panel-title-row,
  .admin-topbar,
  .pagination-bar,
  .import-form {
    grid-template-columns: 1fr;
  }

  .lookup-form,
  .panel-title-row,
  .admin-topbar,
  .pagination-bar,
  .import-form {
    display: grid;
  }

  .pagination-controls {
    flex-wrap: wrap;
  }

  .sidebar nav {
    grid-template-columns: 1fr;
  }

  .enrollment-steps {
    grid-template-columns: 1fr;
  }

  .admin-content {
    padding: 14px;
  }

  .enrollment-shell {
    width: min(100% - 20px, 1360px);
  }

  .back-link {
    position: static;
  }

  .tuition-options,
  .total-box {
    grid-template-columns: 1fr;
  }

  .tuition-options .custom-tuition-option {
    grid-template-columns: auto 1fr;
  }

  .admission-options label {
    grid-template-columns: auto 1fr;
  }

  .admission-options span {
    grid-column: 1 / -1;
  }

  .custom-tuition-option input[type="text"] {
    grid-column: 1 / -1;
  }

  .total-box {
    display: grid;
  }

  .copy-box {
    padding-right: 18px;
  }

  .copy-button {
    position: static;
    justify-self: start;
    transform: none;
  }

  .payment-dialog {
    width: calc(100dvw - 16px);
    max-width: calc(100dvw - 16px);
    max-height: calc(100dvh - 16px);
  }

  .payment-modal {
    padding: 14px;
  }

  .payment-head {
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 14px;
  }

  .payment-head h2 {
    font-size: 1.25rem;
  }

  .payment-head p {
    font-size: 0.95rem;
  }

  .payment-body {
    gap: 14px;
  }

  .line-item {
    display: grid;
    grid-template-columns: 1fr;
    gap: 6px;
    padding: 10px 12px;
  }

  .line-item strong {
    white-space: normal;
    text-align: left;
    overflow-wrap: anywhere;
  }

  .line-item-note strong {
    max-width: none;
  }

  .bank-box,
  .qr-panel {
    padding: 14px;
  }

  .bank-box strong {
    font-size: 16px;
  }

  .qr-tabs {
    width: 100%;
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .qr-tabs button {
    min-width: 0;
    padding: 0 8px;
    font-size: 0.9rem;
  }

  .real-qr {
    width: min(260px, 100%);
    padding: 10px;
  }

  .payment-warning {
    margin-top: 14px;
    padding: 12px;
    font-size: 0.92rem;
  }

  .support-contact-grid {
    grid-template-columns: 1fr;
  }

  .support-band {
    padding: 34px 16px;
  }

  .support-contact-card {
    min-height: 72px;
  }

  .step-actions {
    display: grid;
    grid-template-columns: 1fr;
  }

  .receipt-card,
  .complete-card,
  .tuition-card {
    padding: 16px;
  }
}
