:root {
  color-scheme: light;
  --ink: #30241a;
  --muted: #664f3d;
  --paper: #f7eddd;
  --stage: #254437;
  --peach: #f7d6c4;
  --amber: #f8d694;
  --white: #fffaf0;
  --line: 2px solid var(--ink);
  font-family: "PingFang SC", "Microsoft YaHei", "Noto Sans CJK SC", system-ui, sans-serif;
}
*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
body {
  margin: 0;
  color: var(--ink);
  background-color: var(--paper);
  background-image: repeating-linear-gradient(0deg, transparent 0 31px, #8d572010 31px 32px);
}
h1, h2, p { margin: 0; }
a { color: inherit; }
button, input, textarea { font: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 3px solid #9b4428; outline-offset: 4px; }
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5em;
  min-height: 40px;
  border: 1px solid var(--ink);
  border-radius: 7px;
  color: var(--ink);
  padding: 7px 14px;
  background: var(--white);
  text-decoration: none;
  font-size: 14px;
  font-weight: 700;
}
.button:hover { background: var(--peach); }
.button.primary { background: var(--amber); }
.button.primary:hover { background: #fee5b4; }
.button:disabled { opacity: .45; cursor: default; }
.eyebrow {
  display: flex;
  align-items: center;
  gap: .55em;
  width: fit-content;
  font-size: clamp(13px, 1.15vw, 18px);
  font-weight: 800;
  letter-spacing: .15em;
}
.ink-dot {
  display: inline-block;
  width: .57em;
  height: .57em;
  border-radius: 50%;
  background: var(--ink);
}
.burst {
  display: inline-block;
  width: .65em;
  height: .65em;
  flex: 0 0 auto;
  margin-inline-start: .16em;
  vertical-align: .15em;
  background: #a64e30;
  clip-path: polygon(50% 0,61% 28%,72% 20%,70% 44%,91% 35%,83% 54%,100% 56%,75% 78%,79% 85%,54% 83%,54% 100%,46% 100%,46% 83%,21% 85%,25% 78%,0 56%,17% 54%,9% 35%,30% 44%,28% 20%,39% 28%);
}
.wall-shell {
  width: min(100%, 1920px);
  min-height: 100svh;
  margin: 0 auto;
  padding: clamp(22px, 4.5vh, 64px) clamp(16px, 5.7vw, 108px) clamp(18px, 3vh, 40px);
  display: grid;
  grid-template-rows: auto minmax(290px, 1fr) auto;
  gap: clamp(16px, 3vh, 38px);
}
.wall-footer, .host-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}
.wall-header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(140px, 30%) auto;
  align-items: center;
  gap: clamp(14px, 2.1vw, 36px);
}
.event-brand {
  display: flex;
  align-items: center;
  gap: .65em;
  flex-wrap: wrap;
  color: #963e24;
  font-size: clamp(13px, 1.5vw, 22px);
  font-weight: 800;
  letter-spacing: .12em;
}
.event-brand .ink-dot { background: currentColor; }
.event-edition {
  color: var(--muted);
  letter-spacing: .06em;
  padding-left: .65em;
  border-left: 1px solid #ab8265;
}
.wall-mascot {
  display: block;
  width: 100%;
  height: clamp(142px, 27vh, 275px);
  object-fit: contain;
  object-position: center;
}
h1 {
  font-size: clamp(44px, 6.5vw, 115px);
  font-weight: 950;
  letter-spacing: -.05em;
  line-height: 1.13;
  margin-block: .1em .12em;
}
.wall-sub {
  color: var(--muted);
  font-size: clamp(15px, 1.55vw, 27px);
  line-height: 1.5;
  font-weight: 650;
}
.qr-box {
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  gap: 3px;
  padding: 8px 8px 10px;
  border: var(--line);
  border-radius: 12px;
  box-shadow: 4px 4px var(--ink);
  background: #fff;
  text-decoration: none;
  font-size: clamp(12px, 1.15vw, 19px);
  letter-spacing: .06em;
}
.qr-box img {
  display: block;
  width: clamp(80px, 10vw, 164px);
  height: auto;
  aspect-ratio: 1;
}
.stage {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  display: grid;
  align-items: stretch;
  border: var(--line);
  border-radius: 15px;
  box-shadow: 6px 7px var(--ink);
  background-color: var(--stage);
  background-image: linear-gradient(#eae2c522 1px, transparent 1px), linear-gradient(90deg, #eae2c522 1px, transparent 1px);
  background-size: 36px 36px;
}
.lanes, .wall-empty, .spotlight, .still-list { grid-area: 1 / 1; }
.lanes {
  min-width: 0;
  display: grid;
  grid-template-rows: repeat(3,minmax(0,1fr));
  gap: clamp(6px, 1vh, 13px);
  padding-block: clamp(13px, 4vh, 45px);
  overflow: hidden;
}
.lane { min-width: 0; overflow: hidden; display: flex; align-items: center; }
.track { position: relative; display: flex; gap: clamp(15px, 2vw, 30px); width: max-content; will-change: transform; }
.bubble {
  display: grid;
  flex: 0 0 auto;
  gap: .17em;
  width: max-content;
  max-width: min(44vw, 49rem);
  border: var(--line);
  border-radius: 10px;
  background: var(--white);
  box-shadow: 3px 3px var(--ink);
  padding: .43em .72em .52em;
  font-size: clamp(15px, 2vw, 34px);
  line-height: 1.25;
  overflow-wrap: anywhere;
}
.bubble.tone-1 { background: var(--amber); }
.bubble.tone-2 { background: var(--peach); }
.bubble strong { font-weight: 880; }
.bubble p {
  font-size: .82em;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}
.wall-empty {
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 14px;
  padding: 28px;
  text-align: center;
  color: #fff2d7;
  font-size: clamp(25px, 3vw, 49px);
  font-weight: 850;
}
.wall-empty .burst, .join-result .burst { width: 1em; height: 1em; margin: 0; }
.wall-empty .burst { background: var(--amber); }
.still-list { display: none; }
.spotlight {
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: clamp(12px, 1.7vw, 28px);
  padding: clamp(24px, 4vw, 72px);
  background: #f9e4ba;
  overflow-wrap: anywhere;
}
.spotlight h2 { font-size: clamp(28px, 5vw, 80px); letter-spacing: -.04em; line-height: 1.11; }
.spotlight p:not(.eyebrow) { font-size: clamp(20px, 2.8vw, 48px); font-weight: 700; line-height: 1.4; }
.spotlight small { font-size: clamp(13px, 1.25vw, 20px); font-weight: 650; }
.wall-footer { color: var(--muted); font-size: clamp(12px, 1.1vw, 17px); font-weight: 750; }
.live-detail, .wall-actions, .control-buttons { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.current-status { display: inline-flex; align-items: center; gap: 7px; }
.current-status::before {
  content: "";
  width: 9px;
  height: 9px;
  border: 1px solid var(--ink);
  border-radius: 50%;
  background: #bbac98;
}
.current-status[data-state="open"]::before { background: #8ab582; }
.current-status[data-state="error"]::before { background: #ff9d9a; }
.clock { color: var(--ink); font-variant-numeric: tabular-nums; letter-spacing: .04em; }
.phone-shell, .host-shell { width: min(100% - 32px, 530px); margin: 0 auto; padding: clamp(28px, 6vw, 82px) 0 42px; }
.phone-shell { padding-top: clamp(23px, 5vw, 55px); }
.phone-header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px 0;
}
.phone-header .event-brand, .phone-header .wall-sub { grid-column: 1 / -1; }
.phone-header h1 { grid-area: 2 / 1; font-size: clamp(30px, 8.7vw, 58px); }
.phone-mascot {
  grid-area: 2 / 2;
  width: clamp(88px, 27vw, 145px);
  height: auto;
  object-fit: contain;
  align-self: end;
}
.phone-shell .paper { margin-top: 19px; }
.paper {
  padding: clamp(16px, 3vw, 27px);
  border: var(--line);
  border-radius: 12px;
  box-shadow: 4px 5px var(--ink);
  background: var(--white);
}
label { display: block; font-size: 15px; font-weight: 800; margin-bottom: 7px; }
input, textarea {
  display: block;
  width: 100%;
  border: 1px solid #938276;
  border-radius: 6px;
  padding: 11px 12px;
  font-size: 16px;
  color: var(--ink);
  background: #fffdf8;
}
input { margin-bottom: 17px; }
textarea { resize: vertical; min-height: 108px; }
.field-meta { display: flex; justify-content: space-between; gap: 10px; margin: 9px 0 18px; color: var(--muted); font-size: 12px; }
.submit { width: 100%; min-height: 48px; font-size: 16px; }
.join-result { text-align: center; padding: 16px 4px; }
.join-result .burst { font-size: 56px; }
.join-result h2 { margin: 12px 0 5px; }
.join-result p, .read-note { color: var(--muted); font-size: 14px; line-height: 1.65; }
.feedback { color: #923d23; font-size: 14px; line-height: 1.45; margin: 0 0 12px; }
.host-shell { width: min(100% - 32px, 1120px); }
.host-header { margin-bottom: 21px; }
.host-header h1 { font-size: clamp(44px, 7vw, 80px); }
.login { max-width: 430px; margin-bottom: 18px; }
.controls { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 13px; margin-bottom: 20px; }
.host-columns { display: grid; grid-template-columns: 1.25fr 1fr; gap: 16px; align-items: start; }
.section-heading { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.section-heading span { color: var(--muted); font-size: 14px; flex: 0 0 auto; }
.message-list { list-style: none; padding: 0; margin: 12px 0 0; }
.message-list li { padding: 13px 0; border-top: 1px solid #e8dac6; overflow-wrap: anywhere; }
.message-list li p { margin: 4px 0 8px; line-height: 1.5; }
.message-list li .button { margin: 3px 7px 0 0; min-height: 32px; padding: 4px 9px; }
.message-list .message-hidden { color: var(--muted); }
.message-list .message-empty { color: var(--muted); font-size: 14px; }
#resume { margin-top: 12px; }
@media (max-width: 680px) {
  .wall-shell { padding-inline: 14px; gap: 16px; grid-template-rows: auto minmax(280px, 1fr) auto; }
  .wall-footer { gap: 9px; }
  .wall-header { grid-template-columns: minmax(0, 1fr) auto; gap: 12px; }
  .wall-mascot { display: none; }
  .wall-header h1 { font-size: clamp(31px, 8vw, 53px); }
  .wall-header .wall-sub { font-size: 13px; }
  .wall-header .qr-box { box-shadow: 3px 3px var(--ink); padding: 4px 4px 7px; }
  .qr-box img { width: 72px; }
  .wall-actions, .live-detail { gap: 6px 8px; }
  .wall-actions .button { padding: 5px 8px; min-height: 32px; font-size: 12px; }
  .bubble { max-width: 72vw; }
  .host-columns { grid-template-columns: 1fr; }
  .host-header .event-brand { letter-spacing: .04em; }
}
@media (prefers-reduced-motion: reduce) {
  .lanes { visibility: hidden; }
  .still-list {
    display: grid;
    z-index: 1;
    align-content: center;
    gap: 12px;
    padding: 16px;
  }
  .still-list .bubble { max-width: 100%; }
}

.person-fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  column-gap: 12px;
}
.person-fields > div { min-width: 0; }
.vote-panel .section-heading { margin-bottom: 8px; }
.vote-panel .section-heading span { font-size: 12px; }
.award-panel { margin-bottom: 20px; }
.award-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin-top: 12px; }
.award-grid h3 { margin: 8px 0; }
.award-grid p { overflow-wrap: anywhere; }
.award-ranked { font-weight: 800; }
.award-actions { margin-top: 16px; }
.award-panel .feedback { margin-top: 10px; }
.prize-screen {
  grid-area: 1 / 1;
  z-index: 3;
  display: grid;
  align-content: center;
  padding: clamp(24px, 4vw, 65px);
  background: #f9e4ba;
}
.prize-screen h2 { font-size: clamp(25px, 4vw, 60px); }
.prize-screen .award-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.prize-screen .award-grid section { border-top: 2px solid var(--ink); padding-top: 8px; }
.prize-screen h3 { color: #963e24; font-size: clamp(16px, 2.2vw, 32px); }
.prize-screen p { font-weight: 750; font-size: clamp(13px, 1.7vw, 25px); line-height: 1.45; }
@media (max-width: 680px) {
  .award-panel .award-grid, .prize-screen .award-grid { grid-template-columns: 1fr; gap: 8px; }
}

.vote-link { margin-top: 12px; }

.person-picker, .person-option {
  width: 100%;
  text-align: left;
  font: inherit;
  color: var(--ink);
  border: 1px solid #938276;
  background: #fffdf8;
  border-radius: 8px;
  padding: 9px;
}
.person-picker { min-height: 64px; margin-bottom: 17px; }
.person-picker:hover, .person-option:hover, .person-option[aria-current] { background: #f8ebcd; }
.person-heading { display: flex; align-items: center; min-width: 0; }
.person-heading > :last-child { min-width: 0; overflow-wrap: anywhere; }
.person-portrait {
  --avatar-size: 36px;
  position: relative;
  flex: 0 0 var(--avatar-size);
  height: var(--avatar-size);
  margin-right: .5em;
  border-radius: 50%;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: #ead8b6;
  color: #6b452a;
  font-size: calc(var(--avatar-size) * .42);
  font-weight: 800;
}
.person-portrait img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; background: #f0dfc2; }
.person-picker small, .person-option small { display: block; color: var(--muted); margin-top: 2px; }
.person-dialog {
  width: min(92vw, 520px);
  max-height: min(82vh, 690px);
  max-height: min(82dvh, 690px);
  color: var(--ink);
  background: var(--white);
  border: var(--line);
  border-radius: 12px;
  padding: 18px;
}
.person-dialog::backdrop { background: #22160e99; }
.person-dialog[open] { display: flex; flex-direction: column; }
.person-dialog h2 { font-size: 22px; }
.picker-filters { flex-shrink: 0; margin-top: 12px; }
.picker-filters input { margin-bottom: 10px; }
.picker-filters select { width: 100%; min-height: 42px; background: #fffdf8; border: 1px solid #938276; border-radius: 6px; padding: 6px 8px; color: var(--ink); font: inherit; }
.person-list { list-style: none; padding: 2px; margin: 10px 0 0; min-height: 0; overflow-y: auto; overscroll-behavior: contain; }
.person-list li + li { margin-top: 6px; }
.person-list .message-empty { padding: 10px 0; }
.bubble .person-portrait { --avatar-size: clamp(28px, 3.1vw, 49px); }
.spotlight .person-portrait { --avatar-size: clamp(56px, 8vw, 120px); }
.prize-screen .person-heading p { margin-block: 4px; }
