:root {
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: #2c1a21;
  background: #fff8fa;
  font-synthesis: none;
  --green-900: #5b1835;
  --green-700: #a83261;
  --green-100: #f7dce7;
  --coral: #e15f76;
  --coral-dark: #bd3656;
  --gold: #c49b48;
  --ink: #2c1a21;
  --muted: #75666c;
  --line: #eadde2;
  --surface: #ffffff;
  --canvas: #fff8fa;
  --danger: #b1263d;
  --shadow: 0 14px 40px rgba(74, 20, 45, 0.12);
}

* { box-sizing: border-box; }
html, body { min-height: 100%; margin: 0; }
body { min-width: 320px; }
button, input, select, textarea { font: inherit; letter-spacing: 0; }
button, a { -webkit-tap-highlight-color: transparent; }
button { cursor: pointer; }
button:disabled { cursor: not-allowed; opacity: .5; }
h1, h2, p { margin-top: 0; }
h1, h2 { letter-spacing: 0; }

input, select, textarea {
  width: 100%; border: 1px solid #dbcbd1; border-radius: 6px; background: #fff; color: var(--ink);
  padding: 11px 12px; outline: none; transition: border-color .15s, box-shadow .15s;
}
input:focus, select:focus, textarea:focus { border-color: var(--green-700); box-shadow: 0 0 0 3px rgba(168, 50, 97, .14); }
input:not([type="radio"]):disabled, select:disabled, textarea:disabled {
  cursor: not-allowed; opacity: 1; background: #e7e5e6; color: #675d61; border-color: #c9c3c5;
}
textarea { resize: vertical; line-height: 1.45; }
label { display: grid; gap: 7px; color: #4f3b43; font-size: .85rem; font-weight: 650; }

.button {
  min-height: 42px; border: 0; border-radius: 6px; padding: 0 16px; display: inline-flex; align-items: center;
  justify-content: center; gap: 8px; font-weight: 700; text-decoration: none; transition: transform .15s, background .15s;
}
.button:not(:disabled):active { transform: translateY(1px); }
.button svg { width: 18px; height: 18px; }
.button.primary { background: var(--green-700); color: white; }
.button.primary:hover:not(:disabled) { background: var(--green-900); }
.button.quiz-toggle-button {
  min-width: 250px; min-height: 72px; padding: 0 28px 0 14px; gap: 14px; border: 1px solid #79173e;
  box-shadow: 0 7px 0 #79173e, 0 16px 30px rgba(91, 24, 53, .24); font-size: 1.18rem; transform: translateY(-4px);
}
.button.open-quiz-button { background: #b52b62; }
.button.close-quiz-button { background: #b1263d; border-color: #721528; box-shadow: 0 7px 0 #721528, 0 16px 30px rgba(91, 24, 53, .24); }
.button.quiz-toggle-button:hover:not(:disabled) { background: #92204e; box-shadow: 0 4px 0 #651231, 0 11px 22px rgba(91, 24, 53, .22); transform: translateY(-1px); }
.button.close-quiz-button:hover:not(:disabled) { background: #8e1e32; }
.button.quiz-toggle-button:active:not(:disabled) { box-shadow: 0 1px 0 #651231, 0 4px 10px rgba(91, 24, 53, .18); transform: translateY(3px); }
.button.quiz-toggle-button:focus-visible { outline: 4px solid rgba(181, 43, 98, .28); outline-offset: 6px; }
.launch-icon { width: 44px; height: 44px; flex: 0 0 44px; display: grid; place-items: center; border-radius: 50%; background: white; color: #9a1f50; }
.close-quiz-button .launch-icon { color: var(--danger); }
.button .launch-icon svg { width: 22px; height: 22px; }
.button.secondary { color: var(--green-900); background: white; border: 1px solid #dccbd2; }
.button.secondary:hover:not(:disabled) { background: #fff1f5; }
.button.danger { color: white; background: var(--danger); }
.button.wide { width: 100%; }

.icon-button {
  width: 44px; height: 44px; flex: 0 0 44px; display: inline-grid; place-items: center; border: 1px solid #dccbd2;
  border-radius: 6px; background: white; color: var(--green-900);
}
.icon-button:hover:not(:disabled) { background: #fff0f5; }
.icon-button svg { width: 20px; }
.icon-button.small { width: 34px; height: 34px; flex-basis: 34px; }
.icon-button.small svg { width: 17px; }
.danger-icon { color: var(--danger); }

.eyebrow { color: var(--coral); text-transform: uppercase; font-weight: 800; font-size: .72rem; letter-spacing: .12em; margin-bottom: 8px; }
.notice { display: flex; align-items: center; gap: 8px; padding: 11px 13px; border: 1px solid #e5d5db; border-radius: 6px; background: #fff2f6; color: #604851; font-size: .9rem; }
.notice.success { background: #dff5e8; color: #175c3a; border-color: #a9ddbf; }
.notice.locked-notice { min-height: 64px; gap: 12px; padding: 16px 18px; background: #f9e5ed; color: var(--green-900); border-color: #d8aabd; font-size: 1rem; font-weight: 650; line-height: 1.45; }
.notice.locked-notice svg { width: 24px; height: 24px; flex: 0 0 24px; }
.error-banner {
  position: fixed; z-index: 1000; top: max(16px, env(safe-area-inset-top)); left: 50%;
  width: min(620px, calc(100% - 32px)); min-height: 72px; padding: 13px 18px;
  display: grid; grid-template-columns: 44px minmax(0, 1fr); align-items: center; gap: 13px;
  border: 1px solid #d67b89; border-radius: 8px; background: #fffafb; color: #712234;
  box-shadow: 0 18px 44px rgba(83, 18, 39, .28), 0 4px 12px rgba(83, 18, 39, .16);
  transform: translateX(-50%); animation: error-banner-in .2s ease-out both; pointer-events: none;
}
.error-banner-icon { width: 44px; height: 44px; display: grid; place-items: center; border-radius: 50%; background: #a72e46; color: white; }
.error-banner-icon svg { width: 24px; height: 24px; }
.error-banner-content { min-width: 0; display: grid; gap: 3px; line-height: 1.35; }
.error-banner-content strong { color: #571728; font-size: .83rem; text-transform: uppercase; }
.error-banner-content > span { overflow-wrap: anywhere; font-size: .95rem; font-weight: 650; }
@keyframes error-banner-in { from { opacity: 0; transform: translate(-50%, -14px); } to { opacity: 1; transform: translate(-50%, 0); } }
.loading { min-height: 180px; display: flex; align-items: center; justify-content: center; gap: 12px; color: var(--muted); }
.spinner { width: 24px; height: 24px; border: 3px solid #ead5dd; border-top-color: var(--green-700); border-radius: 50%; animation: spin .7s linear infinite; }
.spinner.small { width: 17px; height: 17px; border-width: 2px; border-color: rgba(255,255,255,.45); border-top-color: white; }
@keyframes spin { to { transform: rotate(360deg); } }

/* Guest welcome */
.welcome-page { min-height: 100dvh; display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(360px, .75fr); background: white; }
.welcome-visual {
  position: relative; min-height: 100dvh; padding: clamp(24px, 4vw, 58px); color: white;
  background-image: linear-gradient(90deg, rgba(68, 10, 39, .86) 0%, rgba(88, 15, 48, .42) 52%, rgba(88, 15, 48, .12) 100%), url('/assets/venue-background.jpg');
  background-size: cover; background-position: 58% center;
  display: flex; flex-direction: column; justify-content: space-between;
}
.brand, .quiz-brand, .admin-logo { display: flex; align-items: center; gap: 9px; font-weight: 800; }
.brand svg { color: #ff91ad; }
.welcome-copy { max-width: 650px; padding-bottom: 8vh; }
.welcome-copy .eyebrow { color: #ffb2c5; }
.welcome-copy h1 { max-width: 620px; margin-bottom: 18px; font-family: Georgia, 'Times New Roman', serif; font-size: clamp(2.8rem, 6vw, 5.8rem); line-height: .98; font-weight: 500; }
.welcome-copy > p:last-child { font-size: 1.05rem; font-weight: 650; }
.welcome-form-wrap { display: grid; align-items: center; padding: clamp(28px, 5vw, 80px); }
.welcome-form { width: 100%; max-width: 390px; margin: auto; display: grid; gap: 17px; }
.welcome-form h2 { font-size: 1.7rem; margin: 0; }
.welcome-form > p { color: var(--muted); line-height: 1.55; margin-bottom: 3px; }
.welcome-form input, .welcome-form select { min-height: 48px; font-size: 1rem; }
.guest-name-control { position: relative; }
.guest-name-backdrop { position: absolute; z-index: 1; inset: 0; padding: 0 12px; display: flex; align-items: center; gap: 8px; overflow: hidden; border: 1px solid #c9c3c5; border-radius: 6px; background: rgba(231, 229, 230, .97); color: #675d61; font-size: .88rem; font-weight: 700; white-space: nowrap; pointer-events: none; }
.guest-name-backdrop svg { width: 17px; height: 17px; flex: 0 0 17px; }
.welcome-form .button:disabled { opacity: 1; background: #aaa4a7; color: #f8f6f7; border-color: #aaa4a7; box-shadow: none; transform: none; }

/* Guest quiz */
.guest-shell, .admin-loading { min-height: 100dvh; display: grid; place-items: center; padding: 24px; }
.quiz-page { min-height: 100dvh; background: var(--canvas); display: grid; grid-template-rows: auto 4px 1fr auto; }
.quiz-header { height: 68px; padding: 0 clamp(18px, 4vw, 46px); display: flex; align-items: center; justify-content: space-between; background: white; border-bottom: 1px solid var(--line); }
.quiz-brand { color: var(--green-900); }
.quiz-brand svg { color: var(--coral); }
.timer { min-width: 92px; padding: 8px 12px; border-radius: 6px; display: flex; justify-content: center; align-items: center; gap: 7px; background: #fbe7ef; color: var(--green-900); font-variant-numeric: tabular-nums; font-weight: 800; }
.timer.urgent { color: #9c3029; background: #ffebe7; animation: pulse 1s ease-in-out infinite alternate; }
@keyframes pulse { to { box-shadow: 0 0 0 3px rgba(219, 101, 79, .18); } }
.progress-track { background: #efdae2; height: 4px; }
.progress-track span { display: block; height: 100%; background: var(--coral); transition: width .25s; }
.question-stage { width: min(760px, calc(100% - 36px)); margin: auto; padding: 44px 0 36px; align-self: center; }
.question-meta { display: flex; justify-content: space-between; min-height: 24px; color: var(--muted); font-size: .82rem; font-weight: 700; }
.save-state { display: flex; align-items: center; gap: 4px; }
.save-state.saved { color: var(--green-700); }
.save-state.error { color: var(--danger); }
.question-stage h1 { margin: 18px 0 30px; font-size: clamp(1.55rem, 3vw, 2.35rem); line-height: 1.2; }
.answer-list { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.answer {
  width: 100%; min-height: 76px; padding: 13px 46px 13px 14px; border: 1px solid #e3d5da; border-radius: 7px;
  background: white; color: var(--ink); display: grid; grid-template-columns: 38px 1fr; gap: 12px; align-items: center;
  text-align: left; position: relative; font-weight: 650; line-height: 1.35;
}
.answer:hover { border-color: #cf8da7; background: #fffafb; }
.answer.selected { border-color: var(--green-700); box-shadow: 0 0 0 2px rgba(168, 50, 97, .14); background: #fff3f7; }
.answer-letter { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; background: #f3e8ec; color: #6f5962; font-weight: 800; }
.answer.selected .answer-letter { background: var(--green-700); color: white; }
.answer-check { position: absolute; right: 16px; color: var(--green-700); opacity: 0; }
.answer.selected .answer-check { opacity: 1; }
.quiz-footer { min-height: 78px; padding: 14px clamp(18px, 4vw, 46px); display: flex; justify-content: space-between; align-items: center; background: white; border-top: 1px solid var(--line); }
.question-dots { display: flex; flex-wrap: wrap; justify-content: center; gap: 7px; max-width: 45%; }
.question-dots span { width: 7px; height: 7px; border-radius: 50%; background: #e2d4d9; }
.question-dots span.answered { background: #cf8da7; }
.question-dots span.current { width: 20px; border-radius: 4px; background: var(--coral); }

.modal-backdrop { position: fixed; inset: 0; background: rgba(51, 15, 32, .66); display: grid; place-items: center; padding: 20px; z-index: 10; }
.modal { width: min(440px, 100%); border-radius: 8px; background: white; box-shadow: var(--shadow); padding: 28px; }
.modal h2 { margin-bottom: 10px; }
.modal p { color: var(--muted); line-height: 1.5; }
.modal-actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 24px; }
.modal.action-confirmation { width: min(480px, 100%); border-top: 5px solid var(--green-700); }
.modal-mark { width: 52px; height: 52px; margin-bottom: 20px; display: grid; place-items: center; border-radius: 50%; }
.modal-mark svg { width: 25px; height: 25px; }
.modal-mark.open-mark { color: #175c3a; background: #dff5e8; }
.modal-mark.close-mark { color: var(--danger); background: #fff0f1; }

.result-page { min-height: 100dvh; padding: 28px; display: grid; place-items: center; background: var(--green-900); background-image: radial-gradient(circle at 50% 0, rgba(244, 111, 145, .26), transparent 42%); }
.result-panel { width: min(480px, 100%); padding: clamp(30px, 6vw, 52px); border-radius: 8px; background: white; text-align: center; box-shadow: var(--shadow); }
.result-mark { width: 70px; height: 70px; margin: 0 auto 24px; display: grid; place-items: center; border-radius: 50%; background: #ffebe7; color: var(--coral); }
.result-panel h1 { margin-bottom: 30px; font-family: Georgia, serif; font-size: 2.1rem; font-weight: 500; }
.score-block { display: flex; align-items: baseline; justify-content: center; gap: 9px; }
.score-block strong { color: var(--green-900); font-size: 5rem; line-height: 1; }
.score-block span { color: var(--muted); }
.result-time { margin: 20px 0; display: flex; justify-content: center; align-items: center; gap: 7px; font-weight: 750; }
.result-note { margin: 30px 0 22px; color: var(--muted); }

/* Admin */
.login-page { min-height: 100dvh; padding: 24px; display: grid; place-items: center; background: #faedf2; }
.login-panel { width: min(420px, 100%); padding: 38px; border-radius: 8px; background: white; box-shadow: var(--shadow); display: grid; gap: 15px; }
.login-panel .admin-logo { color: var(--green-900); margin-bottom: 28px; }
.login-panel .eyebrow { margin-bottom: -8px; }
.login-panel h1 { font-size: 1.8rem; margin-bottom: 8px; }
.admin-shell { min-height: 100dvh; display: grid; grid-template-columns: 236px 1fr; background: var(--canvas); }
.admin-sidebar { position: sticky; top: 0; height: 100dvh; padding: 24px 16px 18px; background: var(--green-900); color: white; display: flex; flex-direction: column; }
.admin-logo { min-height: 40px; padding: 0 10px; }
.admin-logo svg { width: 22px; color: #ff91ad; }
.admin-sidebar nav { display: grid; gap: 5px; margin-top: 46px; }
.admin-sidebar nav button, .logout-button {
  border: 0; border-radius: 6px; background: transparent; color: #f0cedb; padding: 11px 12px; display: flex; align-items: center; gap: 11px; text-align: left; font-weight: 650;
}
.admin-sidebar nav button:hover, .admin-sidebar nav button.active { background: rgba(255,255,255,.1); color: white; }
.admin-sidebar nav svg, .logout-button svg { width: 19px; }
.logout-button { margin-top: auto; }
.admin-mobile-header, .admin-mobile-tabs { display: none; }
.admin-main { min-width: 0; }
.admin-content { width: min(1120px, calc(100% - 64px)); margin: 0 auto; padding: 44px 0 80px; }
.page-heading { display: flex; align-items: center; justify-content: space-between; gap: 24px; margin-bottom: 30px; }
.page-heading h1 { font-size: 2rem; margin: 0; }
.page-heading .eyebrow { margin-bottom: 5px; }
.status-actions { display: flex; align-items: center; gap: 10px; }
.status { display: inline-flex; align-items: center; white-space: nowrap; border-radius: 999px; padding: 5px 10px; font-size: .75rem; font-weight: 800; }
.status-draft { background: #f0e8eb; color: #66545b; }
.status-open { background: #d8f2e3; color: #175c3a; }
.status-completed { background: #f8dee8; color: #81284c; }
.status-closed, .status-timed_out { background: #ffe8e3; color: #9c382f; }
.status-active { background: #fff0c9; color: #765612; }
.status-pending { background: #f0e8eb; color: #66545b; }
.settings-band { margin-top: 22px; padding: 24px 0 30px; border-bottom: 1px solid var(--line); }
.section-title { display: flex; align-items: center; gap: 9px; margin-bottom: 20px; }
.section-title svg { width: 20px; color: var(--green-700); }
.section-title h2, .questions-heading h2 { margin: 0; font-size: 1.15rem; }
.settings-grid { display: grid; grid-template-columns: 2fr 1fr; gap: 18px; max-width: 740px; }
.questions-heading { display: flex; align-items: center; justify-content: space-between; margin: 34px 0 16px; }
.questions-heading p { margin: 4px 0 0; color: var(--muted); font-size: .85rem; }
.editor-list { display: grid; gap: 14px; }
.question-editor { border: 1px solid var(--line); border-radius: 8px; background: white; padding: 22px; }
.question-editor-head { display: grid; grid-template-columns: 30px minmax(0, 1fr) auto; align-items: center; gap: 12px; }
.question-number { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; color: white; background: var(--green-700); font-size: .82rem; font-weight: 800; }
.question-prompt { min-width: 0; }
.reorder-controls { display: flex; gap: 6px; }
.options-editor { margin: 20px 0 0; padding: 0; border: 0; }
.options-editor legend { width: 100%; margin-bottom: 10px; font-size: .83rem; color: #4f3b43; font-weight: 700; }
.options-editor legend span { color: var(--muted); font-weight: 500; margin-left: 7px; }
.option-editor { display: grid; grid-template-columns: 22px minmax(0, 1fr) 34px; align-items: center; gap: 8px; min-height: 50px; margin-top: 3px; padding: 4px; }
.option-editor > input:not([type=radio]) { min-width: 0; }
.option-editor > input[type=radio] { appearance: none; width: 18px; height: 18px; padding: 0; border: 2px solid #ad929c; border-radius: 50%; }
.option-editor > input[type=radio]:checked { border: 5px solid var(--green-700); }
.text-button { margin: 12px 0 0 34px; border: 0; background: none; color: var(--green-700); display: flex; align-items: center; gap: 5px; font-size: .82rem; font-weight: 750; }
.text-button svg { width: 16px; }
.save-bar { position: sticky; bottom: 0; margin-top: 24px; padding: 14px 0; display: flex; justify-content: flex-end; background: rgba(255,248,250,.94); backdrop-filter: blur(7px); }

.guest-add-form { max-width: 740px; margin-bottom: 24px; padding-bottom: 26px; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: end; gap: 10px; border-bottom: 1px solid var(--line); }
.guest-add-form .button { min-height: 42px; }
.people-table table { min-width: 900px; }
.people-table .action-column { width: 82px; text-align: right; }

.metrics-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; margin-bottom: 22px; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; background: var(--line); }
.metrics-row > div { padding: 19px 22px; background: white; display: flex; flex-direction: column; gap: 5px; }
.metrics-row span { color: var(--muted); font-size: .78rem; font-weight: 650; }
.metrics-row strong { color: var(--green-900); font-size: 1.65rem; }
.results-tools { max-width: 360px; position: relative; margin-bottom: 16px; }
.results-tools svg { position: absolute; left: 12px; top: 12px; width: 18px; color: #806a73; }
.results-tools input { padding-left: 40px; }
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 8px; background: white; }
table { width: 100%; min-width: 760px; border-collapse: collapse; }
th, td { height: 57px; padding: 8px 16px; border-bottom: 1px solid #f0e5e9; text-align: left; font-size: .87rem; }
th { height: 44px; color: var(--muted); background: #faf2f5; font-size: .73rem; text-transform: uppercase; }
tbody tr:last-child td { border-bottom: 0; }
.rank-cell { width: 76px; text-align: center; font-weight: 800; }
.medal { width: 29px; height: 29px; display: inline-grid; place-items: center; border-radius: 50%; color: white; }
.medal-1 { background: var(--gold); }.medal-2 { background: #8d7d84; }.medal-3 { background: #a7684b; }
.empty-state { min-height: 290px; border: 1px dashed #dbcbd1; border-radius: 8px; display: grid; place-content: center; justify-items: center; text-align: center; color: var(--muted); }
.empty-state svg { width: 35px; height: 35px; color: var(--gold); margin-bottom: 14px; }
.empty-state h2 { color: var(--ink); font-size: 1.1rem; margin-bottom: 5px; }

.qr-layout { display: grid; grid-template-columns: minmax(320px, 1fr) minmax(280px, .8fr); gap: clamp(32px, 6vw, 80px); align-items: center; }
.qr-preview { min-height: 570px; display: grid; place-items: center; padding: 40px; background: #f5e4eb; }
.qr-print-card { width: min(380px, 100%); aspect-ratio: 4 / 5; padding: 34px; background: white; box-shadow: 0 8px 28px rgba(74,20,45,.13); display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; }
.qr-print-card > svg { color: var(--coral); width: 28px; height: 28px; }
.qr-print-card h2 { margin: 15px 0 20px; font-family: Georgia, serif; font-weight: 500; font-size: 1.55rem; }
.qr-print-card img { width: min(260px, 80%); aspect-ratio: 1; }
.qr-print-card p { margin: 17px 0 0; color: var(--green-900); font-weight: 800; }
.qr-actions { max-width: 410px; }
.qr-actions h2 { font-size: 1.45rem; }
.qr-actions > p { color: var(--muted); line-height: 1.55; margin-bottom: 25px; }
.qr-actions label { margin-bottom: 18px; }
.url-field { display: flex; gap: 7px; }

@media (max-width: 860px) {
  .welcome-page { grid-template-columns: 1fr; grid-template-rows: minmax(350px, 54dvh) auto; }
  .welcome-visual { min-height: 0; padding: 24px; background-position: 62% center; }
  .welcome-copy { padding: 0; }
  .welcome-copy h1 { font-size: clamp(2.5rem, 11vw, 4.2rem); max-width: 560px; }
  .welcome-form-wrap { padding: 34px 24px 46px; }
  .admin-shell { display: block; padding-top: 62px; }
  .admin-sidebar { display: none; }
  .admin-mobile-header { position: fixed; inset: 0 0 auto; height: 62px; z-index: 8; padding: 0 15px; display: flex; align-items: center; justify-content: space-between; background: var(--green-900); color: white; }
  .admin-mobile-tabs { position: sticky; top: 62px; z-index: 7; height: 55px; display: grid; grid-template-columns: repeat(3, 1fr); border-bottom: 1px solid var(--line); background: white; }
  .admin-mobile-tabs button { min-width: 0; padding: 0 3px; border: 0; background: white; color: var(--muted); display: flex; align-items: center; justify-content: center; gap: 4px; font-size: .72rem; font-weight: 750; }
  .admin-mobile-tabs button.active { color: var(--green-700); box-shadow: inset 0 -3px var(--coral); }
  .admin-mobile-tabs svg { width: 17px; }
  .admin-content { width: min(100% - 32px, 720px); padding-top: 30px; }
  .qr-layout { grid-template-columns: 1fr; }
  .qr-preview { min-height: 500px; }
}

@media (max-width: 620px) {
  .answer-list { grid-template-columns: 1fr; }
  .question-stage { width: min(100% - 28px, 620px); padding: 28px 0; }
  .question-stage h1 { margin: 12px 0 22px; }
  .answer { min-height: 66px; }
  .question-dots { max-width: 36%; }
  .modal-actions { flex-direction: column-reverse; }
  .modal-actions .button { width: 100%; }
  .page-heading { align-items: flex-start; flex-direction: column; }
  .status-actions { width: 100%; display: grid; grid-template-columns: auto minmax(0, 1fr); }
  .button.quiz-toggle-button { width: 100%; min-width: 0; min-height: 68px; padding: 0 16px 0 11px; font-size: 1.08rem; }
  .launch-icon { width: 40px; height: 40px; flex-basis: 40px; }
  .settings-grid { grid-template-columns: 1fr; }
  .guest-add-form { grid-template-columns: 1fr; }
  .guest-add-form .button { width: 100%; }
  .metrics-row { grid-template-columns: 1fr; }
  .metrics-row > div { flex-direction: row; align-items: center; justify-content: space-between; }
  .question-editor { padding: 16px; }
  .question-editor-head { grid-template-columns: 28px minmax(0, 1fr) auto; gap: 8px; }
  .question-number { width: 28px; height: 28px; }
  .reorder-controls { gap: 4px; }
  .reorder-controls .icon-button.small { width: 30px; height: 30px; flex-basis: 30px; }
  .questions-heading { gap: 14px; }
  .questions-heading .button { padding: 0 11px; }
  .qr-preview { min-height: 0; padding: 20px; }
  .login-panel { padding: 28px 22px; }
}

@media print {
  body * { visibility: hidden; }
  .qr-print-card, .qr-print-card * { visibility: visible; }
  .qr-print-card { position: fixed; inset: 0; margin: auto; width: 160mm; box-shadow: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
