:root {
  font-family:Inter,"Segoe UI",Arial,sans-serif;
  color:#13335f;
  background:#f7fbff;
  font-size:14px;
  line-height:1.55;
  --blue:#0874f8;
  --ink:#0c2b59;
  --muted:#657b97;
  --line:#deebf7;
  --pale:#eef7ff;
  --shadow:0 8px 35px #173e7210
}
* {
  box-sizing:border-box
}
body {
  margin:0
}
button,input,select,textarea {
  font:inherit
}
button,a {
  -webkit-tap-highlight-color:transparent
}
button {
  cursor:pointer
}
button:disabled {
  cursor:default;
  opacity:.55
}
a {
  color:var(--blue);
  text-underline-offset:3px
}
button:focus-visible,a:focus-visible,input:focus-visible,textarea:focus-visible,select:focus-visible {
  outline:3px solid #80b9ff;
  outline-offset:3px
}
h1,h2,h3,p {
  margin:0
}
h1 {
  font-size:clamp(32px,4vw,51px);
  line-height:1.13;
  letter-spacing:-1.4px;
  color:var(--ink)
}
h1 em {
  font-style:normal;
  color:var(--blue)
}
h2 {
  font-size:21px;
  line-height:1.4
}
h3 {
  font-size:15px
}
p {
  margin:12px 0;
  color:var(--muted)
}
small,.small {
  font-size:12px
}
.muted {
  color:var(--muted)
}
.eyebrow {
  font-size:11px;
  font-weight:700;
  letter-spacing:1px;
  text-transform:uppercase;
  color:#588ab6
}
.container {
  max-width:1240px;
  padding:0 28px 42px;
  margin:auto;
  min-height:65vh
}
.header {
  background:#fff;
  border-bottom:1px solid var(--line)
}
.header-inner {
  max-width:1240px;
  margin:auto;
  padding:17px 28px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:22px
}
.brand {
  font-weight:800;
  font-size:17px;
  letter-spacing:-.3px;
  color:#10376d;
  text-decoration:none;
  display:flex;
  align-items:center;
  gap:10px;
  white-space:nowrap
}
.brand span {
  font-size:9px;
  letter-spacing:.3px;
  color:#0874e2;
  background:#d9efff;
  padding:3px 6px;
  border-radius:3px
}
.header nav {
  display:flex;
  gap:24px;
  align-items:center
}
.header nav a {
  font-size:12px;
  color:#294e78;
  text-decoration:none;
  position:relative;
  padding:8px 0
}
.header nav a.active {
  color:var(--blue)
}
.header nav a.active:after {
  content:'';
  position:absolute;
  bottom:-15px;
  left:-5px;
  right:-5px;
  height:2px;
  background:var(--blue)
}
.header-actions {
  display:flex;
  gap:9px;
  align-items:center
}
.button {
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:7px;
  border:1px solid var(--blue);
  background:var(--blue);
  color:white;
  padding:11px 19px;
  border-radius:8px;
  text-decoration:none;
  font-size:12px;
  font-weight:600;
  line-height:1.45;
  transition:background .15s
}
.button:hover {
  background:#0063db
}
.button.secondary {
  background:white;
  color:#076ae0;
  border-color:#bdd9f5
}
.button.secondary:hover {
  background:var(--pale)
}
.button.full {
  width:100%
}
.actions {
  display:flex;
  gap:15px;
  align-items:center;
  flex-wrap:wrap
}
.actions a {
  font-size:12px
}
.test-banner {
  font-size:11px;
  padding:8px 0;
  color:#8092a7;
  border-bottom:1px dashed var(--line)
}
.hero {
  display:grid;
  grid-template-columns:1.2fr 1fr;
  align-items:center;
  gap:35px;
  min-height:405px;
  padding:36px 0;
  background:radial-gradient(ellipse at 80% 45%,#e4f5ff,transparent 65%)
}
.hero h1 {
  margin:15px 0 20px;
  font-size:clamp(39px,4.3vw,59px)
}
.hero-lead {
  font-size:18px;
  line-height:1.5;
  margin-bottom:25px
}
.hero .button {
  padding:14px 25px;
  font-size:14px
}
.hero-tree {
  position:relative;
  display:grid;
  place-items:center;
  min-width:0
}
.hero-tree .quiz-tree {
  max-width:345px;
  width:100%;
  filter:drop-shadow(0 15px 12px #0089e41b)
}
.hero-caption {
  font-size:11px;
  letter-spacing:.5px;
  color:#5d8bb6;
  position:absolute;
  bottom:5px
}
.snow {
  position:absolute;
  color:#7ebce7;
  font-size:36px
}
.s1 {
  top:50px;
  left:8px
}
.s2 {
  right:20px;
  bottom:110px;
  font-size:50px
}
.info-grid {
  display:grid;
  grid-template-columns:repeat(3,1fr);
  gap:16px;
  margin:10px 0 25px
}
.info-card {
  display:flex;
  gap:18px;
  padding:22px 18px;
  background:#f4faff;
  border:1px solid #d6e8f6;
  border-radius:10px
}
.info-card p {
  font-size:12px;
  margin:8px 0 0;
  line-height:1.7
}
.info-icon {
  flex-shrink:0;
  width:49px;
  height:49px;
  background:#e2f1ff;
  border-radius:11px;
  color:#1680dc;
  font-size:29px;
  display:grid;
  place-items:center
}
.info-card:nth-child(odd) .info-icon {
  background:#e2f6e9;
  color:#35705a
}
.panel {
  background:white;
  border:1px solid var(--line);
  border-radius:13px;
  padding:25px;
  box-shadow:var(--shadow);
  min-width:0;
  margin-bottom:20px
}
.panel-heading {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  margin-bottom:17px
}
.panel-heading a {
  font-size:12px;
  white-space:nowrap
}
.landing-bottom {
  display:grid;
  grid-template-columns:1.6fr 1fr;
  gap:20px
}
.steps {
  display:grid;
  grid-template-columns:repeat(3,1fr);
  gap:25px;
  margin-top:25px
}
.steps>div {
  position:relative
}
.steps>div:not(:last-child):after {
  content:'→';
  position:absolute;
  right:-20px;
  top:8px;
  color:#69a6dd;
  font-size:22px
}
.steps span {
  display:grid;
  place-items:center;
  width:32px;
  height:32px;
  border-radius:50%;
  background:#e4f3ff;
  color:var(--blue);
  font-weight:700;
  margin-bottom:12px
}
.steps h3 {
  font-size:12px
}
.steps p {
  font-size:11px
}
.footer {
  max-width:1240px;
  margin:0 auto;
  padding:28px;
  border-top:1px solid var(--line);
  display:flex;
  justify-content:space-between;
  gap:24px;
  align-items:start;
  color:#7e93ac;
  font-size:10px
}
.footer .brand {
  font-size:13px;
  flex-wrap:wrap;
  gap:5px
}
.footer .brand span {
  font-size:8px
}
.footer-links {
  display:flex;
  gap:13px;
  flex-wrap:wrap;
  max-width:480px
}
.footer a {
  color:#6985a3;
  font-size:10px
}
.page-heading {
  margin:35px 0 25px
}
.page-heading h1 {
  font-size:36px;
  margin-top:8px
}
.page-heading p {
  max-width:800px
}
.account-nav {
  display:flex;
  gap:8px;
  flex-wrap:wrap;
  margin:18px 0 26px
}
.account-nav button {
  background:none;
  border:1px solid var(--line);
  padding:8px 13px;
  border-radius:7px;
  font-size:11px;
  color:var(--muted)
}
.account-nav button.active {
  background:var(--blue);
  color:white;
  border-color:var(--blue)
}
.game-heading {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:30px;
  margin-bottom:25px
}
.game-heading h1 {
  font-size:38px;
  margin-top:10px
}
.game-heading p {
  font-size:12px;
  margin-bottom:0
}
.timeline {
  display:flex;
  gap:6px;
  overflow-x:auto;
  max-width:650px;
  padding:8px 3px 12px
}
.day {
  border:0;
  background:none;
  min-width:43px;
  padding:0;
  color:#7892ac
}
.day>span {
  width:35px;
  height:35px;
  border-radius:50%;
  background:#eaf0f7;
  border:1px solid #d6e0eb;
  display:grid;
  place-items:center;
  font-size:13px;
  margin:auto auto 6px
}
.day small {
  font-size:9px;
  white-space:nowrap
}
.day.current>span {
  box-shadow:0 0 0 3px #1983ff25;
  border-color:var(--blue)
}
.day.accepted>span {
  background:var(--blue);
  color:white;
  border-color:var(--blue)
}
.day.available>span {
  background:#e2f2ff;
  color:var(--blue);
  border-color:#99caff
}
.day.partial>span {
  background:#fff0d1;
  color:#ab6f13;
  border-color:#e5c681
}
.day.rejected>span {
  background:#f5e8e8;
  color:#bd6666
}
.metrics {
  display:grid;
  grid-template-columns:repeat(4,minmax(0,1fr));
  gap:14px;
  margin:22px 0
}
.metrics article {
  background:white;
  border:1px solid var(--line);
  border-radius:10px;
  padding:17px 21px
}
.metrics span {
  display:block;
  font-size:11px;
  color:var(--muted)
}
.metrics strong {
  font-size:30px;
  font-weight:600;
  line-height:1.4
}
.metrics small {
  font-size:13px;
  font-weight:400;
  color:#86a2ba
}
.game-layout {
  display:grid;
  grid-template-columns:minmax(0,1.8fr) minmax(260px,1fr);
  gap:27px;
  align-items:start
}
.question-panel {
  padding:29px
}
.question-heading {
  display:flex;
  gap:17px;
  align-items:center;
  margin-bottom:21px
}
.question-heading h2 {
  font-size:20px
}
.question-heading .eyebrow {
  margin:0 0 4px
}
.question-text {
  font-size:17px;
  line-height:1.6;
  white-space:pre-line;
  color:#294f7b;
  margin-bottom:24px
}
.demo-note {
  font-size:10px;
  color:#8a9bae;
  margin-top:-12px;
  margin-bottom:18px
}
.tree-panel {
  background:linear-gradient(135deg,#eff8ff,#f8fcff);
  border:1px solid var(--line);
  border-radius:13px;
  padding:23px 15px;
  text-align:center;
  min-width:0
}
.tree-panel .panel-heading {
  padding:0 12px;
  margin-bottom:0;
  font-size:12px;
  color:var(--muted)
}
.tree-panel .quiz-tree {
  width:100%;
  max-width:315px;
  display:block;
  margin:auto
}
.tree-panel p {
  font-size:11px;
  margin:3px 0 12px
}
.tree-legend {
  display:flex;
  justify-content:center;
  gap:13px;
  font-size:10px;
  color:#6793af
}
.tree-star {
  fill:#f9fcff;
  stroke:#69b9ef;
  stroke-width:3
}
.tree-star.lit {
  fill:#2c96fc;
  stroke:#9ae5ff
}
.ball circle {
  fill:#eafaf7;
  stroke:#70bcae;
  stroke-width:1
}
.ball path {
  stroke:#398f82;
  fill:none;
  stroke-width:1
}
.ball text {
  text-anchor:middle;
  font-size:8px;
  fill:#378579
}
.ball.accepted circle {
  fill:#007bf0;
  stroke:#8dd5ff
}
.ball.accepted text {
  fill:white;
  font-size:12px
}
.ball.partial circle {
  fill:#ffe1a0;
  stroke:#d9a644
}
.ball.partial text {
  fill:#8f6722;
  font-size:12px
}
.ball.rejected circle {
  fill:#c8dcd7
}
.ball.rejected text {
  fill:#7d9993
}
.tree-doc rect {
  fill:#faffff;
  stroke:#8acfe7;
  stroke-width:2
}
.tree-doc text {
  font-size:8px;
  text-anchor:middle;
  fill:#5da5d5
}
.tree-doc path {
  stroke:#b2d4e8;
  stroke-width:2
}
.contacts {
  display:flex;
  gap:18px;
  flex-wrap:wrap;
  margin-top:23px;
  padding-top:17px;
  border-top:1px solid var(--line);
  font-size:11px
}
.question-actions {
  display:flex;
  justify-content:space-between;
  gap:15px;
  margin-top:20px
}
.result {
  display:flex;
  justify-content:space-between;
  padding:15px;
  border-radius:8px;
  background:#eaf4ff;
  margin:15px 0
}
.result.accepted {
  background:#e5f7ec;
  color:#337452
}
.result.partial {
  background:#fff5df;
  color:#9b7018
}
.result.rejected {
  background:#fff0ec;
  color:#b3654b
}
.answer-text {
  white-space:pre-wrap;
  overflow-wrap:anywhere;
  padding:16px;
  background:#f5f9fd;
  border-radius:8px;
  margin:18px 0
}
.badge {
  display:inline-block;
  padding:4px 8px;
  border-radius:6px;
  background:#e8f3ff;
  color:#4381b5;
  font-size:10px;
  white-space:nowrap
}
.badge.accepted,.badge.verified {
  background:#e7f6ee;
  color:#38785a
}
.badge.partial,.badge.unverified,.badge.pending {
  background:#fff4db;
  color:#9b782e
}
.badge.rejected,.badge.excluded {
  background:#faece8;
  color:#a35947
}
.notice {
  background:#edf6ff;
  color:#54779b;
  border:1px solid #dcebf8;
  border-radius:8px;
  padding:14px 17px;
  margin:18px 0;
  font-size:12px;
  overflow-wrap:anywhere
}
.notice .button {
  margin-top:10px
}
.two-columns {
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:21px
}
.copy-line {
  display:flex;
  gap:10px;
  margin:20px 0
}
.copy-line input {
  flex:1;
  min-width:0;
  background:#f6faff;
  border:1px solid var(--line);
  border-radius:7px;
  padding:12px;
  font-size:12px
}
.table-wrap {
  overflow-x:auto;
  width:100%
}
table {
  border-collapse:collapse;
  width:100%;
  text-align:left;
  font-size:12px
}
th {
  color:#7d94ac;
  font-weight:500;
  font-size:10px;
  white-space:nowrap;
  padding:11px;
  border-bottom:1px solid var(--line)
}
td {
  padding:14px 11px;
  border-bottom:1px solid #ecf2f8;
  vertical-align:middle
}
tr:last-child td {
  border-bottom:0
}
th:first-child,td:first-child {
  padding-left:0
}
th:last-child,td:last-child {
  padding-right:0
}
.own {
  background:#eff8ff
}
.rank {
  display:inline-grid;
  place-items:center;
  width:25px;
  height:25px;
  border-radius:50%;
  background:#edf2f8;
  font-size:11px
}
.rank-1 {
  background:#ffe390;
  color:#89620b
}
.rank-2 {
  background:#e2e8ef;
  color:#708098
}
.rank-3 {
  background:#f5dfd0;
  color:#a5795a
}
.neutral-avatar {
  display:inline-grid;
  place-items:center;
  width:27px;
  height:27px;
  border-radius:50%;
  background:#e9f4ff;
  margin-right:9px;
  color:#7aa3c5;
  font-size:13px
}
.field {
  display:flex;
  flex-direction:column;
  gap:7px;
  margin-bottom:16px;
  font-size:12px;
  min-width:0
}
.field span {
  font-weight:600
}
.field input,.field select,.field textarea,.filters input,.filters select {
  width:100%;
  border:1px solid #cbdfef;
  border-radius:7px;
  background:#fff;
  padding:11px 12px;
  color:#294e77;
  min-width:0
}
.field textarea {
  min-height:125px;
  resize:vertical
}
.field input::placeholder,.filters input::placeholder {
  color:#98aabb
}
.form-grid {
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:0 20px
}
.checkbox {
  display:flex;
  gap:9px;
  align-items:start;
  font-size:11px;
  color:#69809a;
  margin:15px 0
}
.checkbox input {
  margin-top:3px;
  accent-color:var(--blue);
  width:15px;
  height:15px;
  flex-shrink:0
}
.choice {
  display:flex;
  gap:14px;
  align-items:center;
  border:1px solid #dce9f6;
  border-radius:8px;
  margin:12px 0;
  padding:16px;
  color:#3e6086;
  font-size:13px
}
.choice:has(input:checked) {
  background:#eff7ff;
  border-color:#68aaff
}
.choice input {
  accent-color:var(--blue);
  width:17px;
  height:17px;
  flex-shrink:0
}
.choice.removed {
  color:#9aafc3;
  text-decoration:line-through;
  background:#f5f8fb
}
fieldset {
  border:0;
  padding:0;
  margin:0;
  min-width:0
}
legend {
  font-size:11px;
  color:var(--muted);
  margin-bottom:8px
}
.form-error {
  color:#af473a;
  font-size:12px;
  padding:10px 0;
  white-space:pre-line
}
.form-error:empty {
  display:none
}
.document-links {
  font-size:10px;
  margin-top:20px;
  line-height:1.9
}
.narrow {
  max-width:620px
}
.login-code {
  font-variant-numeric:tabular-nums;
  color:var(--blue);
  white-space:nowrap
}
.admin-layout {
  display:grid;
  grid-template-columns:190px minmax(0,1fr);
  gap:28px;
  margin-top:25px
}
.admin-nav {
  border-right:1px solid var(--line);
  padding:15px 18px 15px 0
}
.admin-nav .eyebrow {
  font-size:9px;
  margin:10px 0 20px
}
.admin-nav button {
  display:flex;
  gap:13px;
  align-items:center;
  width:100%;
  border:0;
  background:none;
  padding:12px 13px;
  border-radius:7px;
  text-align:left;
  color:#6882a0;
  font-size:12px;
  margin-bottom:5px
}
.admin-nav button span {
  font-size:18px;
  width:20px;
  text-align:center
}
.admin-nav button.active {
  color:white;
  background:var(--blue)
}
.admin-nav>p:last-child {
  padding:15px 10px;
  font-size:10px;
  line-height:1.8
}
.admin-main {
  min-width:0
}
.admin-main .page-heading {
  margin:10px 0 25px
}
.admin-main .page-heading h1 {
  font-size:33px
}
.admin-main .metrics strong {
  font-size:26px
}
.admin-main .metrics article {
  padding:15px
}
.filters {
  display:flex;
  gap:12px;
  margin-bottom:18px
}
.filters input {
  flex:1
}
.filters select {
  width:175px
}
.document-cards {
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:15px
}
.document-cards .panel {
  padding:20px
}
.document-cards .actions {
  gap:9px
}
.document-cards .actions a {
  font-size:10px
}
.document-cards .button {
  font-size:11px;
  padding:8px 12px
}
.option-row {
  display:flex;
  align-items:center;
  gap:10px;
  margin-bottom:9px
}
.option-row input[type=checkbox] {
  accent-color:var(--blue);
  width:17px;
  height:17px;
  flex-shrink:0
}
.option-row input[name=option] {
  flex:1;
  min-width:0;
  padding:11px;
  border:1px solid #cbdfef;
  border-radius:7px
}
.option-row button {
  border:0;
  background:#eff5fa;
  color:#8297af;
  font-size:22px;
  border-radius:5px;
  width:30px;
  height:33px
}
.option-row input[type=checkbox]:checked+input {
  border-color:#61b38d;
  background:#f3fbf6
}
.empty {
  text-align:center;
  padding:35px 15px;
  color:#91a4b9;
  font-size:12px
}
.empty>span {
  display:block;
  font-size:28px;
  margin-bottom:8px
}
.legal-content {
  line-height:1.9;
  font-size:13px
}
.document-paragraph {
  white-space:pre-wrap;
  overflow-wrap:anywhere;
  color:#496788;
  margin:0 0 15px
}
.document-heading {
  margin: 26px 0 14px;
  color: var(--ink);
  font-size: 19px;
}
.document-text {
  white-space:pre-wrap;
  overflow-wrap:anywhere
}
.legal-table {
  min-width:760px
}
.legal-table td {
  border:1px solid var(--line);
  white-space:pre-wrap;
  padding:12px;
  vertical-align:top;
  font-size:11px
}
.legal-content>.small {
  overflow-wrap:anywhere
}
.loading {
  display:flex;
  align-items:center;
  justify-content:center;
  gap:20px;
  min-height:80vh;
  color:var(--muted)
}
dialog {
  border:1px solid var(--line);
  border-radius:14px;
  padding:27px;
  width:590px;
  max-width:calc(100vw - 28px);
  max-height:92vh;
  color:var(--ink);
  background:#fff;
  box-shadow:0 20px 120px #12375740
}
dialog::backdrop {
  background:#17375866;
  backdrop-filter:blur(3px)
}
.modal-header {
  display:flex;
  align-items:start;
  justify-content:space-between;
  gap:15px;
  margin-bottom:20px
}
.modal-header h2 {
  font-size:22px
}
.close {
  border:0;
  background:none;
  color:#8295aa;
  font-size:24px;
  line-height:1;
  padding:2px 5px
}
.auth-tabs {
  display:flex;
  gap:20px;
  margin-bottom:24px;
  border-bottom:1px solid var(--line)
}
.auth-tabs button {
  border:0;
  background:none;
  color:#8096ac;
  padding:8px 0;
  font-size:12px
}
.auth-tabs button.active {
  color:var(--blue);
  border-bottom:2px solid var(--blue)
}
#toast {
  display:none;
  position:fixed;
  left:50%;
  bottom:24px;
  transform:translateX(-50%);
  z-index:100;
  background:#174b83;
  color:white;
  border-radius:9px;
  padding:13px 22px;
  font-size:12px;
  box-shadow:0 7px 30px #17375835;
  max-width:calc(100vw - 30px)
}
#toast.visible {
  display:block
}
#toast.error {
  background:#a65042
}
@media(min-width:1600px) {
  .container,.header-inner,.footer {
    max-width:1360px
  }
  .hero {
    min-height:440px
  }
  .hero-tree .quiz-tree {
    max-width:375px
  }
}
@media(max-width:1100px) {
  .brand {
    font-size:14px
  }
  .brand span {
    font-size:8px
  }
  .header nav {
    gap:15px
  }
  .header-actions .button {
    padding:9px 12px;
    font-size:11px
  }
  .game-heading {
    align-items:start;
    flex-direction:column;
    gap:15px
  }
  .timeline {
    max-width:100%;
    width:100%;
    justify-content:space-between
  }
  .game-heading h1 {
    font-size:36px
  }
  .admin-layout {
    grid-template-columns:165px minmax(0,1fr);
    gap:20px
  }
  .admin-main .metrics {
    grid-template-columns:repeat(2,1fr)
  }
  .hero h1 {
    font-size:47px
  }
  .hero .eyebrow {
    font-size:9px
  }
  .footer {
    flex-wrap:wrap
  }
}
@media(max-width:800px) {
  .header-inner {
    flex-wrap:wrap;
    gap:12px 20px
  }
  .header nav {
    order:3;
    width:100%;
    gap:25px;
    border-top:1px solid #f0f5fa;
    padding-top:9px
  }
  .header nav a.active:after {
    bottom:-8px
  }
  .header-actions {
    margin-left:auto
  }
  .brand {
    font-size:15px
  }
  .hero {
    gap:10px;
    min-height:330px
  }
  .hero h1 {
    font-size:39px
  }
  .hero-lead {
    font-size:15px
  }
  .hero .button {
    font-size:12px;
    padding:12px 18px
  }
  .hero-tree .quiz-tree {
    max-width:280px
  }
  .info-grid {
    gap:10px
  }
  .info-card {
    display:block;
    padding:16px
  }
  .info-icon {
    margin-bottom:10px;
    width:40px;
    height:40px;
    font-size:24px
  }
  .info-card h3 {
    font-size:13px
  }
  .info-card p {
    font-size:11px
  }
  .landing-bottom {
    grid-template-columns:1fr
  }
  .game-layout {
    grid-template-columns:minmax(0,1.5fr) minmax(210px,1fr);
    gap:17px
  }
  .question-panel {
    padding:22px
  }
  .question-heading {
    gap:12px
  }
  .question-heading .info-icon {
    margin:0
  }
  .question-heading h2 {
    font-size:17px
  }
  .question-text {
    font-size:15px
  }
  .metrics article {
    padding:14px
  }
  .metrics strong {
    font-size:27px
  }
  .two-columns {
    grid-template-columns:1fr
  }
  .admin-layout {
    grid-template-columns:1fr;
    gap:12px
  }
  .admin-nav {
    display:flex;
    gap:5px;
    border:0;
    padding:0;
    overflow-x:auto
  }
  .admin-nav>p {
    display:none
  }
  .admin-nav button {
    width:auto;
    white-space:nowrap;
    padding:9px 12px;
    font-size:11px
  }
  .admin-nav button span {
    display:none
  }
  .admin-main .metrics {
    grid-template-columns:repeat(4,1fr)
  }
  .document-cards {
    gap:12px
  }
  .footer {
    padding-top:24px
  }
}
@media(max-width:570px) {
  .container {
    padding:0 16px 30px
  }
  .header-inner {
    padding:15px 16px;
    gap:12px 8px
  }
  .brand {
    font-size:12px;
    gap:5px;
    white-space:normal
  }
  .brand span {
    font-size:7px;
    padding:3px 4px
  }
  .header-actions {
    gap:5px
  }
  .header-actions .button {
    padding:7px 9px;
    font-size:10px;
    max-width:110px;
    overflow:hidden;
    text-overflow:ellipsis;
    white-space:nowrap
  }
  .header nav {
    gap:23px
  }
  .header nav a {
    font-size:11px
  }
  .hero {
    grid-template-columns:1fr;
    padding:28px 0 16px;
    gap:12px
  }
  .hero h1 {
    font-size:41px;
    margin:12px 0 18px
  }
  .hero-lead {
    font-size:16px
  }
  .hero .eyebrow {
    font-size:9px;
    max-width:300px;
    line-height:1.8
  }
  .hero-tree {
    max-width:290px;
    justify-self:center;
    width:100%
  }
  .hero-tree .quiz-tree {
    max-width:230px
  }
  .hero-caption {
    font-size:9px;
    bottom:0
  }
  .snow {
    font-size:24px
  }
  .s1 {
    top:20px
  }
  .s2 {
    bottom:65px;
    right:3px;
    font-size:32px
  }
  .info-grid {
    grid-template-columns:1fr;
    margin-top:15px
  }
  .info-card {
    display:flex;
    gap:15px;
    padding:17px
  }
  .info-card .info-icon {
    margin:0
  }
  .info-card h3 {
    font-size:14px
  }
  .info-card p {
    font-size:12px
  }
  .panel {
    padding:20px;
    margin-bottom:16px
  }
  .panel h2 {
    font-size:19px
  }
  .steps {
    gap:20px
  }
  .steps h3 {
    font-size:11px
  }
  .steps p {
    font-size:10px
  }
  .steps>div:not(:last-child):after {
    right:-17px
  }
  .test-banner {
    font-size:9px;
    line-height:1.6
  }
  .account-nav {
    gap:5px;
    margin-bottom:22px
  }
  .account-nav button {
    font-size:10px;
    padding:7px 10px
  }
  .game-heading h1 {
    font-size:34px
  }
  .timeline {
    justify-content:start;
    gap:7px
  }
  .day {
    min-width:41px
  }
  .day>span {
    height:32px;
    width:32px
  }
  .metrics {
    grid-template-columns:1fr 1fr;
    gap:9px;
    margin:18px 0
  }
  .metrics strong {
    font-size:27px
  }
  .metrics span {
    font-size:10px
  }
  .metrics article {
    padding:13px 15px
  }
  .game-layout {
    grid-template-columns:1fr
  }
  .question-panel {
    padding:20px
  }
  .question-heading h2 {
    font-size:19px
  }
  .question-text {
    font-size:15px;
    margin:17px 0 22px
  }
  .choice {
    font-size:12px;
    padding:15px 12px;
    gap:11px
  }
  .question-actions {
    gap:9px
  }
  .question-actions .button {
    padding:10px 12px;
    font-size:11px
  }
  .tree-panel {
    padding:20px
  }
  .tree-panel .quiz-tree {
    max-width:260px
  }
  .copy-line {
    flex-direction:column
  }
  .copy-line input {
    width:100%
  }
  .page-heading h1 {
    font-size:30px
  }
  .admin-main .metrics {
    grid-template-columns:1fr 1fr
  }
  .form-grid,.document-cards {
    grid-template-columns:1fr
  }
  .admin-nav {
    padding-bottom:5px
  }
  .admin-nav button {
    padding:9px 11px
  }
  .filters {
    flex-direction:column;
    gap:8px
  }
  .filters select {
    width:100%
  }
  .document-cards .actions {
    gap:12px
  }
  .footer {
    padding:22px 16px;
    gap:15px
  }
  .footer .brand {
    font-size:12px
  }
  .footer-links {
    gap:9px 13px
  }
  .footer>span {
    width:100%
  }
  .contacts {
    gap:10px 15px;
    font-size:10px
  }
  .table-wrap table {
    font-size:11px
  }
  .table-wrap td,.table-wrap th {
    padding:11px 8px
  }
  .neutral-avatar {
    display:none
  }
  .result {
    font-size:12px
  }
  .notice {
    font-size:11px
  }
  .modal-header h2 {
    font-size:20px
  }
  dialog {
    padding:22px
  }
  .field {
    font-size:11px
  }
  .document-links {
    font-size:9px
  }
}
@media(prefers-reduced-motion:reduce) {
  * {
    transition:none!important;
    scroll-behavior:auto!important
  }
}

:root {
  font-family:"Segoe UI",Arial,sans-serif;
  color:#f8f4e7;
  background:#0b221c;
  font-size:16px;
  color-scheme:dark;
  --blue:#f3d279;
  --ink:#fff7e3;
  --muted:#cbdbd0;
  --line:#66754e;
  --pale:#244235;
  --shadow:0 14px 42px #020a0759;
  --surface:#15352b;
  --dark:#0e261e;
  --burgundy:#823044;
}
body { background:radial-gradient(ellipse at 80% 8%, #225443 0, transparent 47%),#0b221c; }
#app { isolation:isolate; padding-bottom:24px; }
.header { background:#0a211bf5; }
.brand,.brand span,.header nav a,.footer,.account-nav button { color:var(--ink); }
.brand span,.account-nav button,.day>span,.admin-nav button,.auth-tabs button.active { background:#224134; }
.brand span { border:1px solid var(--line); }
.header nav a,.button,.actions a,.panel-heading a,.checkbox,.choice,.field,legend,.notice,.contacts,.steps h3,.steps p,.metrics span { font-size:.875rem; }
.eyebrow { color:#e5c884; font-size:.82rem; }
.button { background:var(--burgundy); border-color:#c48460; color:#fff5d9; }
.button:hover { background:#a53d53; }
.button.secondary { background:#183c31; color:var(--blue); border-color:#7a8660; }
.button.secondary:hover,.account-nav button:hover { background:#315543; }
.hero.festive-hero {
  min-height:410px;
  border-radius:22px;
  margin:26px 0 20px;
  padding:clamp(23px,4vw,55px);
  background:radial-gradient(ellipse at 76% 55%,#286652 0%,transparent 49%),linear-gradient(140deg,#311d26 0%,#122e26 60%,#0d231c 100%);
  border:1px solid #977447;
  box-shadow:var(--shadow);
}
.festive-hero h1 { font-family:Georgia,'Times New Roman',serif; font-size:clamp(2.1rem,5.2vw,4.15rem); letter-spacing:-.025em; }
.festive-hero h1 em { font-family:"Segoe UI",sans-serif; font-size:.52em; letter-spacing:0; }
.festive-hero .hero-lead { font-size:1.05rem; color:var(--muted); }
.panel,.metrics article,dialog,.tree-panel { background:var(--surface); color:var(--ink); }
.tree-panel { background:radial-gradient(ellipse at 50% 45%,#2c5840,#102b22); margin-bottom:20px; }
.footer { color:var(--muted); }
.footer p,.footer-links a,.test-banner,.contacts a { color:var(--muted); }
.test-banner { font-size:.8rem; }
.story-copy { white-space:pre-line; overflow-wrap:anywhere; }
.legend-panel { border-left:4px solid #b86b55; }
.legend-panel .story-copy { max-width:77ch; margin-top:12px; color:var(--muted); }
.story-episode { border-left:3px solid #d3aa60; padding:12px 16px; background:#253e30; border-radius:0 10px 10px 0; margin:15px 0; color:#e2ebdf; }
.steps { grid-template-columns:repeat(4,minmax(0,1fr)); }
.steps>div:not(:last-child):after { display:none; }
.steps span,.rank,.neutral-avatar { color:#402f13; background:#efd393; }
.prize-grid { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:14px; margin-top:12px; }
.prize-card { border-top:3px solid #ccab62; margin-bottom:14px; }
.prize-card h3 { overflow-wrap:anywhere; }
.prize-card .eyebrow { margin-top:0; }
.results-video iframe { display:block; width:100%; max-width:800px; aspect-ratio:16/9; border:0; }
.settings-panel h2:not(:first-of-type) { border-top:1px solid var(--line); padding-top:20px; margin-top:22px; }
.notice,.answer-text,.empty { background:#223e31; color:#f4ecd3; border-color:#607652; }
.completion,.fourth-notice { border-color:#d4aa64; }
.day { color:#c3d6c9; }
.day small { font-size:.68rem; }
.day>span,.choice,.field input,.field select,.field textarea,.filters input,.filters select,.copy-line input,.option-row input:not([type=checkbox]) { color:var(--ink); background:var(--dark); border-color:var(--line); min-width:0; }
.field>span,.field label,.checkbox,.question-text,.admin-nav button,.legal-table td { color:var(--ink); }
.choice:has(input:checked),.day.available>span,.day.current>span { background:#3d442b; color:#ffeab4; border-color:#e7c365; }
.choice.removed { background:#172c25; color:#9eb6a8; }
.day.accepted>span { color:#2c220d; }
.day.rejected>span { background:#642d3b; color:#ffdce2; }
.admin-nav button.active,.account-nav button.active { background:#405239; color:var(--blue); }
.table-wrap th,.table-wrap tr.own td { background:#243e32; color:#ffe8a7; }
.table-wrap td,.table-wrap td strong { color:var(--ink); }
.metrics small,.tree-panel .panel-heading,.tree-panel p,.auth-tabs button,.close { color:var(--muted); }
.form-error { color:#ffc0bc; }
button:focus-visible,a:focus-visible,input:focus-visible,textarea:focus-visible,select:focus-visible { outline-color:#ffe08c; }
.ball.locked circle { fill:#1d5140; stroke:#97b99c; opacity:.45; }
.ball.accepted circle { stroke:#ffe1aa; }
.ball.accepted.ornament-0 circle { fill:#b73049; }
.ball.accepted.ornament-1 circle { fill:#da9e36; }
.ball.accepted.ornament-2 circle { fill:#f3ead8; }
.ball.accepted.ornament-3 circle { fill:#208764; }
.ball.accepted.ornament-2 text,.ball.accepted.ornament-1 text { fill:#3a2b14; }
.tree-star { fill:#244138; stroke:#c6a664; }
.tree-star.lit { fill:#ffe587; stroke:#fff6cc; filter:drop-shadow(0 0 8px #ffc942); }
.glint { animation:glint 1.3s ease-out; }
@keyframes glint {
  0%,100% { filter:drop-shadow(0 0 4px #ffdf83); }
  38% { filter:drop-shadow(0 0 18px #fff3be) brightness(1.85); }
}
.weather { position:fixed; z-index:-1; inset:0; pointer-events:none; overflow:hidden; }
.falling-snow {
  position:absolute; inset:-180px 0 0; opacity:.35;
  background-image:radial-gradient(circle at 16px 25px,#f2fff1 1.5px,transparent 2px),
    radial-gradient(circle at 70px 90px,#fff 1px,transparent 1.8px),
    radial-gradient(circle at 120px 40px,#d5e9dc 1.4px,transparent 2px);
  background-size:130px 180px,200px 180px,270px 180px;
  animation:snowfall 16s linear infinite;
}
@keyframes snowfall { to { transform:translateY(180px); } }
.snowbank { height:calc(5px + var(--drift,0)*1px); position:absolute; bottom:0; width:100%; opacity:.55;
  background:radial-gradient(ellipse at 14% 110%,#fff 46%,transparent 48%),radial-gradient(ellipse at 59% 130%,#e2f2e9 56%,transparent 58%),radial-gradient(ellipse at 91% 115%,#edf5e8 40%,transparent 42%); }
.weather-1,.weather-2,.weather-3 { --drift:4; }
.weather-4,.weather-5,.weather-6 { --drift:8; }
.weather-7,.weather-8,.weather-9 { --drift:12; }
.weather-10,.weather-11,.weather-12 { --drift:16; }
@media(max-width:850px) { .prize-grid { grid-template-columns:repeat(2,minmax(0,1fr)); } }
@media(max-width:560px) {
  .steps { grid-template-columns:repeat(2,minmax(0,1fr)); gap:15px; }
  .header nav { gap:13px; flex-wrap:wrap; }
  .header nav a { font-size:.82rem; }
  .hero.festive-hero { min-height:0; }
  .prize-card { padding:15px; }
}
@media(prefers-reduced-motion:reduce) { .falling-snow,.glint { animation:none; } }
