* {
  box-sizing: border-box;
}

html,
body {
  width: 100%;
  height: 100%;
}

:root {
  --bg-sky: linear-gradient(180deg, #e5f1ff 0%, #f5f8fc 46%, #ecf2f8 100%);
  --panel: #ffffff;
  --panel-border: #d4dce8;
  --text-main: #1e2b3b;
  --text-soft: #4f5f76;
  --brand: #0f6efd;
  --brand-strong: #0d4fb8;
  --danger: #cc2f3d;
  --inactive-bg: #e6ebf2;
  --inactive-text: #5d6f87;
  --active-bg: #dff5e7;
  --active-text: #135d33;
  --occupied-bg: #f8f1dd;
  --occupied-border: #d8b25c;
  --selected-bg: #dce8ff;
  --shadow-soft: 0 8px 20px rgba(21, 47, 84, 0.08);
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  background: var(--bg-sky);
  color: var(--text-main);
  display: grid;
  place-items: center;
  padding: 16px;
}

.card {
  width: 100%;
  max-width: 560px;
  background: var(--panel);
  border: 1px solid var(--panel-border);
  border-radius: 14px;
  padding: 18px;
  box-shadow: var(--shadow-soft);
}

.card.wide {
  max-width: 1080px;
}

h1,
h2,
h3 {
  margin-top: 0;
}

label {
  display: block;
  margin: 12px 0 6px;
  font-weight: 600;
}

input,
button {
  width: 100%;
  padding: 10px 12px;
  border-radius: 9px;
  border: 1px solid #c7d3e4;
  font: inherit;
}

input[type="radio"] {
  width: auto;
  border: none;
  padding: 0;
}

button {
  cursor: pointer;
  background: var(--brand);
  color: #fff;
  border: none;
  transition: background 0.18s ease;
}

button:hover:enabled {
  background: var(--brand-strong);
}

button.secondary {
  background: #5f6d82;
}

button.secondary:hover:enabled {
  background: #4f5b6d;
}

button.danger {
  background: var(--danger);
}

button.danger:hover:enabled {
  background: #a42733;
}

button:disabled {
  opacity: 0.62;
  cursor: not-allowed;
}

.actions {
  display: grid;
  gap: 8px;
  margin-top: 16px;
}

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

.inline-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
}

.muted {
  color: var(--text-soft);
}

.error-text {
  color: #b91c1c;
  min-height: 20px;
}

.placeholder {
  border: 1px dashed #c8d3e4;
  border-radius: 10px;
  padding: 14px;
  margin: 14px 0;
}

.hidden {
  display: none !important;
}

.legend {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 10px;
}

.legend-item {
  border: 1px solid #ccd6e2;
  border-radius: 999px;
  padding: 4px 10px;
  font-size: 13px;
}

.seat-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(56px, 1fr));
  gap: 8px;
  margin-bottom: 12px;
}

.seat {
  border: 1px solid #9ca9bf;
  border-radius: 9px;
  padding: 10px 8px;
  text-align: center;
  font-weight: 600;
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #ffffff;
}

.seat.inactive,
.legend-item.inactive {
  background: var(--inactive-bg);
  color: var(--inactive-text);
}

.seat.active,
.legend-item.active {
  background: var(--active-bg);
  color: var(--active-text);
}

.seat.occupied,
.legend-item.occupied {
  background: #f9e1c0;
  color: #8a4f0c;
}

.seat.selected,
.legend-item.selected {
  background: var(--selected-bg);
  color: #1f4ea7;
  border-color: #2f65cc;
}

.roster-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 8px;
}

.roster-card {
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  padding: 10px;
  background: #f8fafc;
  display: grid;
  gap: 4px;
}

.state-pill {
  display: inline-block;
  border-radius: 999px;
  border: 1px solid #cbd5e1;
  padding: 2px 8px;
  text-transform: lowercase;
}

.state-ready {
  background: #dcfce7;
  color: #166534;
}

.state-waiting {
  background: #fef3c7;
  color: #92400e;
}

.state-seated,
.state-ordering,
.state-eating,
.state-serving {
  background: #e2e8f0;
  color: #334155;
}

.choice-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 8px;
  margin-bottom: 12px;
}

.choice-grid label {
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  padding: 8px;
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
}

.prompt-box {
  border: 1px solid #bfd6ff;
  background: #edf4ff;
  border-radius: 8px;
  padding: 10px;
}

.attendant-banner {
  border: 1px solid #e09d2d;
  background: #fff2d2;
  color: #8a520e;
  border-radius: 8px;
  padding: 10px;
}

/* Teacher dashboard overhaul */
body.teacher-page {
  padding: 0;
  overflow: hidden;
  display: block;
  place-items: normal;
  background: radial-gradient(circle at top, #d5ebff 0%, #e7f1fc 35%, #edf2f8 100%);
}

.teacher-shell {
  height: 100vh;
  width: 100vw;
  padding: clamp(8px, 1.6vh, 14px);
  display: grid;
  grid-template-rows: auto 1fr;
  gap: clamp(6px, 1.2vh, 10px);
}

.teacher-auth-panel {
  min-height: 100%;
  display: grid;
  place-items: center;
}

.teacher-auth-card {
  width: min(92vw, 380px);
  border: 1px solid #c8d8ea;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.95);
  padding: 18px;
  box-shadow: var(--shadow-soft);
  display: grid;
  gap: 10px;
}

.teacher-toolbar {
  display: grid;
  grid-template-columns: minmax(280px, 1fr) minmax(380px, 1.6fr);
  gap: clamp(8px, 1.2vw, 14px);
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid #c9d7ea;
  border-radius: 14px;
  padding: clamp(8px, 1.2vh, 12px);
  box-shadow: var(--shadow-soft);
}

.teacher-title-block {
  display: grid;
  gap: 4px;
  align-content: center;
}

.teacher-title-block h1 {
  margin: 0;
  font-size: clamp(18px, 2.2vh, 26px);
  letter-spacing: 0.3px;
}

.teacher-subtitle,
.teacher-lock-status,
.teacher-live-status {
  margin: 0;
  font-size: clamp(12px, 1.4vh, 15px);
}

.teacher-live-status {
  color: #2d4e73;
  min-height: 18px;
}

.teacher-controls {
  display: grid;
  gap: 8px;
}

.teacher-control-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.teacher-control-row input {
  text-transform: uppercase;
}

.teacher-stage {
  min-height: 0;
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid #cad8ea;
  border-radius: 14px;
  padding: clamp(8px, 1.1vh, 12px);
  display: grid;
  grid-template-rows: auto 1fr;
  gap: clamp(8px, 1vh, 12px);
  box-shadow: var(--shadow-soft);
}

.teacher-legend {
  margin: 0;
}

.teacher-seat-grid {
  min-height: 0;
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  grid-template-rows: repeat(6, minmax(0, 1fr));
  gap: clamp(4px, 0.7vh, 8px);
}

.teacher-seat-tile {
  border: 1px solid #b3c5de;
  border-radius: 11px;
  background: #f9fbff;
  color: var(--text-main);
  padding: clamp(4px, 0.7vh, 8px);
  min-height: 0;
  width: 100%;
  height: 100%;
  display: grid;
  align-content: start;
  justify-items: center;
  gap: clamp(2px, 0.45vh, 5px);
  text-align: center;
  overflow: hidden;
  box-shadow: 0 3px 8px rgba(28, 52, 88, 0.08);
}

.teacher-seat-tile.inactive {
  background: var(--inactive-bg);
  border-color: #c4d0e0;
}

.teacher-seat-tile.active {
  background: var(--active-bg);
  border-color: #9bc9ae;
}

.teacher-seat-tile.occupied {
  background: var(--occupied-bg);
  border-color: var(--occupied-border);
}

.teacher-seat-tile.editable {
  outline: 2px dashed #81a8f0;
  outline-offset: 0;
}

.seat-empty-dot {
  width: clamp(7px, 1.2vh, 10px);
  height: clamp(7px, 1.2vh, 10px);
  margin-top: auto;
  margin-bottom: auto;
  border-radius: 50%;
  background: rgba(49, 88, 145, 0.45);
}

.seat-student-id {
  width: 100%;
  font-size: var(--seat-id-size, clamp(12px, 1.9vh, 20px));
  line-height: 1.05;
  font-weight: 700;
  letter-spacing: 0.2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.seat-role-pill {
  border-radius: 999px;
  padding: 2px 8px;
  font-size: var(--seat-role-size, clamp(10px, 1.3vh, 14px));
  font-weight: 700;
  white-space: nowrap;
}

.role-attendant {
  background: #d8f4df;
  color: #15603a;
  border: 1px solid #9fd4ae;
}

.role-passenger {
  background: #ffe7cb;
  color: #8d4d12;
  border: 1px solid #e5b57c;
}

.seat-meta {
  width: 100%;
  font-size: var(--seat-meta-size, clamp(9px, 1.1vh, 13px));
  line-height: 1.1;
  color: #2a4667;
  white-space: nowrap;
  text-overflow: ellipsis;
  overflow: hidden;
}

.teacher-empty {
  display: grid;
  place-items: center;
  border: 1px dashed #c0cfe2;
  border-radius: 10px;
  color: var(--text-soft);
  font-size: clamp(14px, 2vh, 18px);
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(16, 32, 52, 0.42);
  display: grid;
  place-items: center;
  z-index: 50;
}

.modal-card {
  width: min(92vw, 360px);
  background: #fff;
  border-radius: 12px;
  border: 1px solid #d2dceb;
  padding: 16px;
  box-shadow: 0 16px 32px rgba(8, 26, 52, 0.25);
}

.modal-card h3 {
  margin-bottom: 8px;
}

.action-menu-card {
  width: min(92vw, 420px);
}

.action-menu-grid {
  display: grid;
  gap: 8px;
  margin-top: 10px;
}

.modal-actions {
  margin-top: 14px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.modal-actions.single {
  grid-template-columns: 1fr;
}

/* Ranking screen */
.ranking-screen {
  position: fixed;
  inset: 0;
  display: grid;
  grid-template-columns: 1fr;
  place-items: center;
  gap: 0;
  padding: clamp(16px, 2vh, 24px);
  background-image:
    linear-gradient(180deg, rgba(16, 29, 46, 0.28) 0%, rgba(16, 29, 46, 0.38) 100%),
    url("/assets/images/ScorePage.png");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  border: none;
  border-radius: 0;
  box-shadow: none;
  z-index: 40;
}

.ranking-side {
  display: none;
}

.ranking-side svg {
  width: min(18vw, 140px);
  max-height: 26vh;
}

.ranking-center {
  width: min(95vw, 890px);
  text-align: center;
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid rgba(201, 217, 234, 0.92);
  border-radius: 14px;
  padding: clamp(28px, 4.8vh, 48px);
  box-shadow: 0 10px 22px rgba(14, 33, 57, 0.2);
  backdrop-filter: blur(2px);
  transform: translateY(-8vh);
}

.ranking-center h2 {
  font-size: clamp(56px, 8.8vh, 96px);
  margin-bottom: 24px;
  letter-spacing: 0.2px;
  color: #173a62;
  text-shadow: 0 1px 1px rgba(255, 255, 255, 0.5);
}

.ranking-list {
  list-style: none;
  margin: 0 auto;
  padding: 0;
  width: min(100%, 1080px);
  display: grid;
  gap: clamp(14px, 1.8vh, 22px);
  max-height: min(58vh, 650px);
  overflow-y: auto;
  overscroll-behavior: contain;
  -ms-overflow-style: none;
  scrollbar-width: none;
}

.ranking-list::-webkit-scrollbar {
  width: 0;
  height: 0;
  display: none;
}

.ranking-list li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  border: 1px solid #c4d5eb;
  border-radius: 20px;
  background: #f8fbff;
  padding: 20px 28px;
  font-size: clamp(32px, 4.6vh, 48px);
}

.ranking-list strong {
  color: #0f3f77;
}

/* Responsive tweaks */
@media (max-width: 1100px), (max-height: 760px) {
  .teacher-toolbar {
    grid-template-columns: 1fr;
  }

  .teacher-title-block h1 {
    font-size: clamp(17px, 2.2vh, 24px);
  }
}

@media (max-width: 860px) {
  .teacher-shell {
    overflow: auto;
    height: auto;
    min-height: 100vh;
  }

  .teacher-control-row {
    grid-template-columns: 1fr;
  }

  .teacher-seat-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    grid-template-rows: repeat(12, minmax(68px, 1fr));
  }

  .seat-grid {
    grid-template-columns: repeat(3, minmax(80px, 1fr));
  }

  .inline-row {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .ranking-screen {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .ranking-side svg {
    width: 120px;
  }
}

/* Student gameplay overhaul */
body.student-page {
  margin: 0;
  padding: 0;
  overflow: hidden;
  display: block;
  place-items: normal;
  background: radial-gradient(circle at 20% 10%, #d5e8ff 0%, #e6f1ff 35%, #edf3fb 100%);
}

.student-shell {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  max-height: 100vh;
  max-width: none !important;
  border-radius: 0;
  border: none;
  box-shadow: none;
  margin: 0;
  padding: clamp(8px, 1.2vh, 14px);
  display: grid;
  grid-template-rows: 1fr auto;
  gap: clamp(6px, 1vh, 10px);
  overflow: hidden;
}

.student-header {
  border: 1px solid #cad9ed;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.93);
  padding: clamp(10px, 1.3vh, 14px);
  display: grid;
  gap: 4px;
}

.student-header h1 {
  margin: 0;
  font-size: clamp(20px, 2.7vh, 30px);
}

.student-header p {
  margin: 0;
  font-size: clamp(12px, 1.45vh, 16px);
}

.student-status {
  position: fixed;
  top: 10px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 45;
  margin: 0;
  padding: 8px 12px;
  border-radius: 10px;
  border: 1px solid #c6d8ef;
  background: rgba(255, 255, 255, 0.96);
  color: #234368;
  font-weight: 600;
  font-size: clamp(12px, 1.5vh, 16px);
  box-shadow: var(--shadow-soft);
}

.student-panel {
  min-height: 0;
  border: 1px solid #c8d8ea;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.95);
  padding: clamp(10px, 1.35vh, 16px);
  box-shadow: var(--shadow-soft);
  display: grid;
  grid-template-rows: auto auto 1fr auto;
  gap: clamp(8px, 1vh, 12px);
  overflow: hidden;
}

.student-panel h2 {
  margin: 0;
  font-size: clamp(20px, 2.8vh, 34px);
}

#seatSelectionSection .seat-grid {
  min-height: 0;
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  grid-template-rows: repeat(6, minmax(0, 1fr));
  gap: clamp(6px, 0.9vh, 10px);
  margin-bottom: 0;
}

#seatSelectionSection .seat {
  min-height: 0;
  height: 100%;
  font-size: clamp(12px, 1.65vh, 20px);
  white-space: nowrap;
}

#passengerWaitingScreen {
  place-items: center;
  text-align: center;
  align-content: center;
}

.waiting-note {
  font-size: clamp(20px, 3.2vh, 40px);
  color: #254a73;
  font-weight: 700;
  margin: 0;
}

#attendantBoardScreen {
  grid-template-rows: auto auto 1fr;
}

.attendant-board-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.attendant-board-header h2 {
  margin: 0;
}

.attendant-seat-grid {
  min-height: 0;
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  grid-template-rows: repeat(6, minmax(0, 1fr));
  gap: clamp(6px, 0.9vh, 10px);
}

.attendant-seat {
  width: 100%;
  height: 100%;
  border: 1px solid #b7c7dd;
  border-radius: 12px;
  font-size: clamp(12px, 1.7vh, 20px);
  font-weight: 700;
  letter-spacing: 0.2px;
  text-transform: uppercase;
}

.attendant-seat.red {
  background: #f3d8d8;
  color: #752323;
}

.attendant-seat.green {
  background: #cff0d6;
  color: #14572f;
  border-color: #86c39a;
}

.attendant-seat.engaged {
  background: #dbe9ff;
  color: #1f4e9a;
  border-color: #89afe7;
}

#conversationScreen {
  grid-template-rows: auto auto 1fr auto;
}

#conversationScreen.line-only-phase {
  grid-template-rows: auto 1fr;
}

.conversation-topbar {
  display: flex;
  justify-content: flex-end;
}

.conversation-line {
  justify-self: center;
  width: min(90vw, 1100px);
  min-height: clamp(98px, 16vh, 170px);
  border-radius: 999px;
  border: 1px solid #9bb9de;
  font-size: clamp(22px, 3.4vh, 40px);
  font-weight: 700;
  padding: 18px 30px;
  line-height: 1.25;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: linear-gradient(180deg, #2e74d3 0%, #1959b2 100%);
  transition: filter 0.12s ease;
}

.conversation-line:hover:enabled {
  background: linear-gradient(180deg, #2e74d3 0%, #1959b2 100%);
  border-color: #9bb9de;
  filter: brightness(1.03);
}

.conversation-line.locked-line {
  background: #9ca9bc;
  border-color: #8896ab;
}

.selection-row {
  min-height: 0;
  display: grid;
  grid-template-columns: 1fr;
  gap: clamp(8px, 1vh, 12px);
  align-items: stretch;
  justify-items: center;
}

.selection-row.drink-only-phase {
  width: 100%;
  height: 100%;
  align-content: center;
  justify-content: center;
}

.selection-panel {
  min-height: 0;
  width: min(100%, 1180px);
  border: 1px solid #c5d4e8;
  border-radius: 12px;
  background: #f8fbff;
  padding: clamp(8px, 1.1vh, 12px);
  position: relative;
  display: grid;
  grid-template-rows: 1fr;
  gap: 8px;
}

.selection-panel h3 {
  margin: 0;
  font-size: clamp(16px, 2.2vh, 24px);
}

#drinkPanel {
  width: min(100%, 980px);
  min-height: min(70vh, 640px);
  grid-template-rows: 1fr;
}

#conversationScreen.line-only-phase .conversation-line {
  grid-row: 2;
  align-self: center;
}

.corner-grid {
  min-height: 0;
  width: min(100%, 1080px);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: 1fr 1fr;
  gap: clamp(7px, 1vh, 12px);
}

.choice-card {
  min-height: clamp(140px, 24vh, 240px);
  aspect-ratio: 1.15 / 1;
  border: 1px solid #c1d2e7;
  border-radius: 12px;
  background: #fff;
  padding: 8px;
  display: grid;
  grid-template-rows: 1fr;
  min-height: 0;
}

.choice-card span {
  display: none;
}

.choice-card.selected {
  border-color: #3776ce;
  box-shadow: inset 0 0 0 2px #4f8ee3;
}

.choice-card.locked {
  filter: grayscale(1);
}

.tray-wrap {
  min-height: 0;
  position: relative;
  display: grid;
  place-items: center;
}

.meal-tray {
  width: 74%;
  height: 74%;
  margin: 0 auto;
}

.tray-base {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.tray-item {
  position: absolute;
  width: 95%;
  height: 90%;
  object-fit: contain;
}

.meal-item {
  transform: translateY(-2%);
}

.meal-item-chicken {
  transform: translateY(-2%) scale(0.93);
}

.drink-wrap {
  min-height: auto;
  display: grid;
  place-items: center;
  height: auto;
  overflow: hidden;
}

.drink-choice-image {
  width: auto;
  height: auto;
  max-width: 66%;
  max-height: 66%;
  object-fit: contain;
  display: block;
  transform: translateY(0);
}

.drink-choice span {
  display: none;
}

.drink-choice {
  aspect-ratio: 1 / 1;
  width: 56%;
  min-height: clamp(72px, 9.4vh, 100px);
  grid-template-rows: 1fr;
  justify-self: center;
  align-self: center;
  padding: 4px;
}

.meal-choice {
  width: 74%;
  min-height: clamp(50px, 6.8vh, 70px);
  aspect-ratio: 1.45 / 1;
  padding: 0.45cm;
  justify-self: center;
  align-self: center;
}

.meal-choice .tray-wrap {
  align-items: center;
}

.meal-choice .meal-tray {
  transform: translateY(0);
}

.lock-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: rgba(95, 107, 125, 0.42);
  border-radius: 12px;
  font-size: clamp(15px, 2vh, 24px);
  color: #fff;
  font-weight: 700;
  backdrop-filter: grayscale(1);
}

#minigameScreen {
  grid-template-rows: auto auto 1fr auto;
}

.minigame-arena {
  min-height: 0;
  border: 1px solid #c4d4e8;
  border-radius: 14px;
  background: radial-gradient(circle at center, #ffffff 0%, #f4f8ff 100%);
  position: relative;
  overflow: hidden;
}

.minigame-meal-layout {
  position: absolute;
  left: 50%;
  top: 53%;
  width: min(86vw, 940px);
  aspect-ratio: 1.42 / 1;
  transform: translate(-50%, -50%);
}

.tray-image {
  position: absolute;
  left: 50%;
  bottom: 4%;
  width: 100%;
  transform: translateX(-50%);
}

.food-svg {
  position: absolute;
  left: 50%;
  top: 46%;
  width: 95%;
  transform: translate(-50%, -50%);
}

.drink-image {
  position: absolute;
  left: -22%;
  top: 34%;
  width: 32%;
  transform: translate(-50%, -50%);
  object-fit: contain;
}

.target-dot {
  position: absolute;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #1ec84c;
  transform: translate(-50%, -50%);
  z-index: 8;
}

.target-ring {
  position: absolute;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: 2px solid #24c84e;
  transform: translate(-50%, -50%) scale(9);
  z-index: 7;
}

#backLink {
  align-self: end;
  justify-self: start;
  color: #1e4f96;
  font-weight: 600;
}

.student-lock-overlay {
  position: fixed;
  inset: 0;
  z-index: 35;
  display: grid;
  place-items: center;
  background: rgba(23, 40, 63, 0.45);
  backdrop-filter: grayscale(0.65);
}

.student-lock-card {
  width: min(84vw, 520px);
  padding: clamp(16px, 2.2vh, 24px);
  border-radius: 14px;
  border: 1px solid #d2dded;
  background: rgba(255, 255, 255, 0.97);
  box-shadow: 0 18px 32px rgba(8, 26, 52, 0.25);
  text-align: center;
}

.student-lock-card h2 {
  margin: 0 0 8px;
  font-size: clamp(24px, 4.2vh, 42px);
}

.student-lock-card p {
  margin: 0;
  font-size: clamp(14px, 2.1vh, 24px);
  color: #35557a;
}

@media (max-width: 980px), (max-height: 760px) {
  .student-shell {
    padding: 8px;
    gap: 8px;
  }

  .student-header h1 {
    font-size: clamp(18px, 2.2vh, 24px);
  }

  .choice-card span {
    font-size: clamp(10px, 1.25vh, 14px);
  }

  .minigame-meal-layout {
    width: min(90vw, 700px);
    top: 56%;
  }

  .conversation-line {
    width: min(94vw, 920px);
    min-height: clamp(88px, 14vh, 148px);
    font-size: clamp(19px, 2.8vh, 30px);
  }
}
