:root {
  color-scheme: light;
  --bg: #f7f7f2;
  --panel: #ffffff;
  --text: #1d2523;
  --muted: #65706d;
  --line: #dce2df;
  --accent: #0d766e;
  --accent-dark: #075f59;
  --danger: #b42318;
  --ok: #137333;
  --shadow: 0 18px 42px rgba(31, 42, 39, 0.12);
}

* {
  box-sizing: border-box;
}

body {
  min-height: 100vh;
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: Arial, Helvetica, sans-serif;
  letter-spacing: 0;
}

button,
input {
  font: inherit;
}

.page {
  width: min(100%, 460px);
  min-height: 100vh;
  margin: 0 auto;
  padding: 20px 14px 28px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.wide-page {
  width: min(100%, 760px);
}

.panel {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
  padding: 22px 16px;
}

.topline {
  margin: 0 0 8px;
  color: var(--accent);
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
}

h1 {
  margin: 0 0 18px;
  font-size: clamp(26px, 8vw, 36px);
  line-height: 1.05;
}

.list-title {
  text-align: center;
  font-size: clamp(34px, 12vw, 64px);
  margin-bottom: 28px;
}

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

.field {
  display: grid;
  gap: 7px;
  margin-bottom: 14px;
}

label {
  color: #34413e;
  font-size: 14px;
  font-weight: 700;
}

input {
  width: 100%;
  min-height: 48px;
  border: 1px solid #c9d2cf;
  border-radius: 8px;
  padding: 12px 13px;
  background: #fff;
  color: var(--text);
  outline: none;
}

input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(13, 118, 110, 0.15);
}

input:disabled {
  background: #edf1ef;
  color: #53605d;
}

.btn {
  width: 100%;
  min-height: 50px;
  border: 0;
  border-radius: 8px;
  background: var(--accent);
  color: white;
  font-weight: 800;
  cursor: pointer;
}

.btn:hover {
  background: var(--accent-dark);
}

.btn.secondary {
  background: #2b3532;
}

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

.btn:disabled {
  cursor: wait;
  opacity: 0.75;
}

.message {
  min-height: 24px;
  margin: 12px 0 0;
  font-size: 14px;
  line-height: 1.35;
}

.message.error {
  color: var(--danger);
}

.message.ok {
  color: var(--ok);
}

.qr-box {
  display: grid;
  justify-items: center;
  gap: 16px;
}

.qr-box img {
  width: min(78vw, 320px);
  height: auto;
  border: 10px solid white;
  border-radius: 8px;
}

.student-list {
  list-style: none;
  display: grid;
  gap: 10px;
  margin: 18px 0 0;
  padding: 0;
}

.student-list li {
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  border-bottom: 1px solid var(--line);
  font-size: 18px;
  font-weight: 700;
}

.admin-actions {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}

.status-line {
  margin: 0 0 16px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f9fbfa;
  color: var(--muted);
}

@media (min-width: 560px) {
  .page {
    padding: 34px 20px;
  }

  .panel {
    padding: 28px;
  }

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