:root {
  color-scheme: dark;
  font: 17px/1.5 Nunito, "Arial Rounded MT Bold", system-ui, sans-serif;
  background: #071f17;
  color: #fff7df;
  --muted: #dddacc;
  --line: #718875;
  --panel: #174633;
  --inset: #0a2b20;
  --accent: #ffdb83;
  --rose: #ff9c9a;
  --cranberry: #a81f3d;
  --gold-edge: #b67933;
  --shadow: #04190f;
  --headline: Nunito, "Arial Rounded MT Bold", system-ui, sans-serif;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body {
  margin: 0; min-height: 100dvh;
  background:
    radial-gradient(circle, #ffedb518 1px, transparent 1.4px) 0 0 / 26px 26px,
    radial-gradient(ellipse at 18% 0%, #226947 0, transparent 67%),
    radial-gradient(ellipse at 100% 100%, #471824 0, transparent 57%),
    #071f17;
}
main { max-width: 800px; margin: auto; padding: clamp(16px, 4vw, 48px); }
main:has(#home:not([hidden]), #screen:not([hidden])) { max-width: 1180px; }
header {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  border-bottom: 1px solid #f4e1aa36; padding-bottom: 13px; margin-bottom: clamp(22px, 5vw, 60px);
}
.brand { color: var(--accent); text-decoration: none; font: 1000 1.3rem/1 var(--headline); letter-spacing: -.06em; }
#view-label, p, figcaption { color: var(--muted); }
#view-label:not(:empty) { border: 1px solid var(--line); border-radius: 99px; padding: 4px 10px; font-size: .77rem; font-weight: 750; }
h1, h2, p { margin: 0 0 12px; }
h1, h2 { font-family: var(--headline); font-weight: 900; }
h1 { font-size: clamp(2rem, 6vw, 4rem); line-height: 1; letter-spacing: -.055em; overflow-wrap: anywhere; }
h2 { font-size: 1.35rem; letter-spacing: -.027em; overflow-wrap: anywhere; }
#home { display: grid; grid-template-columns: 1.18fr 1fr; gap: clamp(18px, 4vw, 55px); align-items: center; padding-block: clamp(5px, 2.6vw, 34px); }
.home-intro h1 {
  font-size: clamp(3.65rem, 9.8vw, 7.4rem); font-weight: 1000; letter-spacing: -.07em;
  text-shadow: 0 5px 0 #163320, 0 8px 0 #08271a;
}
.home-intro h1 > span:first-child { color: var(--accent); }
.home-intro h1 .home-bang {
  display: inline-block; color: #ff797e; transform: rotate(9deg);
  text-shadow: 0 5px 0 #74162a, 0 8px 0 #08271a;
}
.home-intro > p { max-width: 28ch; font-size: clamp(1.08rem, 2.3vw, 1.45rem); margin-bottom: 23px; }
.home-round {
  position: relative; isolation: isolate;
  width: min(100%, 420px); aspect-ratio: 1; margin-inline: auto;
  display: grid; place-items: center;
}
.home-round::before {
  content: ''; position: absolute; z-index: -1; inset: 5%; border-radius: 50%;
  background: radial-gradient(circle, #e9b86b2e, #e9b86b12 64%, transparent 65%);
  box-shadow: inset 0 0 0 1px #ffdb8333;
}
.home-round::after {
  content: ''; position: absolute; z-index: -1; inset: 14%; border-radius: 50%;
  border: 1px dashed #ffdb835c; transform: rotate(-12deg);
}
.hero-camera {
  position: relative; width: 76%; aspect-ratio: 1.52; border-radius: 12% / 18%;
  transform: rotate(8deg);
  border: 2px solid #ffd587;
  background:
    linear-gradient(0deg, #ce8d43 0%, #f7cc77 10%, transparent 11% 68%, #facd7a 69%, #ffe5a5 94%, #fff0bb),
    radial-gradient(circle at 1px 1px, #fd827144 1px, transparent 1.5px) 0 0 / 5px 5px,
    linear-gradient(150deg, #cc3f56, #871c35 90%);
  box-shadow: 0 7px 0 #794124, 0 17px 25px #04180eb5;
}
.hero-camera::before,
.hero-camera::after {
  content: ''; position: absolute; bottom: 100%;
  border-radius: 7px 7px 0 0;
  background: linear-gradient(#ffebad, #d2964a);
}
.hero-camera::before { left: 35.5%; width: 29%; height: 17%; clip-path: polygon(12% 0, 88% 0, 100% 100%, 0 100%); }
.hero-camera::after { right: 12%; width: 13%; height: 8%; background: linear-gradient(#f18484, #a8213e); }
.camera-lens {
  position: absolute; inset: 50% auto auto 50%; transform: translate(-50%, -50%);
  width: 45%; aspect-ratio: 1; border-radius: 50%; border: 2px solid #281918;
  background:
    radial-gradient(ellipse at 38% 37%, #fff4c9b0 0 5%, transparent 6%),
    radial-gradient(circle closest-side at center,
      #386866 0%, #245056 39%, #0f252e 68%, #163239 69% 73%, #976136 74% 78%, transparent 79%),
    conic-gradient(from -40deg, #462a22, #f3ce84, #775044, #d0995b, #462a22);
  box-shadow: 3px 6px 0 #411728, 4px 8px 10px #330d1c87;
}
.camera-flash {
  position: absolute; top: 8%; right: 9%; width: 18%; height: 17%; border: 2px solid #805239; border-radius: 5px;
  background: repeating-linear-gradient(90deg, #fff0bf 0 3px, #d4ac68 4px 5px);
  box-shadow: 1px 2px #bd8249;
}
.sample-prompt {
  position: absolute; z-index: 1; display: grid; inset: 11% auto auto 2%; margin: 0;
  background: #fff6dc; color: #401828; border-radius: 14px; padding: 9px 17px;
  transform: rotate(-9deg); box-shadow: 0 4px 0 #d6ad65, 0 7px 15px #1021199e;
}
.sample-prompt span { color: #7f3448; font-size: .68rem; font-weight: 900; letter-spacing: .13em; text-transform: uppercase; }
.sample-prompt strong { font-size: clamp(1.1rem, 2.6vw, 1.65rem); line-height: 1.2; font-weight: 1000; }
.round-spark { position: absolute; z-index: 2; color: #ffdb83; line-height: 1; text-shadow: 0 0 10px #ffca686a; }
.round-spark-top { top: 17%; right: 11%; font-size: clamp(1rem, 3.5vw, 2.25rem); }
.round-spark-bottom { bottom: 15%; left: 12%; font-size: clamp(.8rem, 2vw, 1.5rem); }
form, .panel { display: grid; gap: 12px; margin: 18px 0; }
form > button { justify-self: start; }
.panel, figure, #join {
  background: var(--panel); border: 1px solid var(--line); border-radius: 17px;
  box-shadow: 0 5px 0 var(--shadow); padding: clamp(12px, 3vw, 21px);
}
label { display: grid; gap: 4px; font-weight: 650; }
input { width: 100%; min-height: 46px; padding: 9px; border: 1px solid var(--line); border-radius: 10px; color: inherit; background: var(--inset); font: inherit; }
input[name=room] { text-transform: uppercase; }
button, .button {
  display: inline-flex; align-items: center; justify-content: center; min-height: 44px; border-radius: 13px;
  border: 1px solid transparent; background: var(--accent); color: #3c2413;
  box-shadow: 0 3px 0 var(--gold-edge); font: inherit; font-weight: 900; padding: 7px 14px; text-decoration: none; cursor: pointer;
}
button:not(:disabled):active, .button:active { transform: translateY(2px); box-shadow: 0 1px 0 var(--shadow); }
button:disabled { opacity: .55; cursor: default; }
#send-photo:disabled { cursor: default; }
button:focus-visible, a:focus-visible, input:focus-visible { outline: 2px solid var(--rose); outline-offset: 3px; }
.secondary { background: var(--panel); color: #fff7df; border-color: var(--line); box-shadow: 0 3px 0 var(--shadow); }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.home-intro .actions > * { padding: 11px 19px; }
.home-intro .actions .secondary { background: var(--cranberry); border-color: #f67c85; box-shadow: 0 3px 0 #601527; }
#notice { padding: 10px; background: #4b252b; color: #ffe2df; border-radius: 7px; }
#screen { text-align: center; }
.eyebrow { font-weight: 800; text-transform: uppercase; letter-spacing: .09em; font-size: .75rem; }
.room-code { color: var(--accent); font-size: clamp(3rem, 14vw, 8.5rem); letter-spacing: .04em; font-family: ui-monospace, monospace; }
#screen-url { overflow-wrap: anywhere; }
.timer { font-size: clamp(1.8rem, 6vw, 4rem); font-weight: 900; color: var(--accent); font-variant-numeric: tabular-nums; }
.timer:empty { display: none; }
#podium { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 175px), 1fr)); gap: 12px; }
#podium .podium-select {
  display: block; width: 100%; padding: 0; border: 2px solid transparent;
  background: var(--inset); border-radius: 10px; box-shadow: none; cursor: zoom-in;
}
#podium .podium-select:is(:hover, [aria-pressed="true"]) { border-color: var(--accent); }
#podium .podium-select[aria-pressed="true"] { cursor: zoom-out; }
#podium-focus {
  padding: clamp(8px, 2vw, 16px);
  border: 1px solid var(--line); border-radius: 15px; background: var(--panel);
}
.podium-focus-bar {
  display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap;
  gap: 6px 12px; padding-bottom: 8px; text-align: left;
}
#podium-focus-caption { color: var(--accent); font-weight: 900; margin: 0; overflow-wrap: anywhere; }
#podium-focus-image {
  display: block; width: 100%; height: clamp(180px, 55dvh, 720px); object-fit: contain;
  border-radius: 9px; background: var(--inset);
}
.has-featured-photo #screen-prompt { font-size: clamp(1.2rem, 3vw, 2rem); }
.has-featured-photo #podium { grid-template-columns: repeat(auto-fit, minmax(min(100%, 85px), 1fr)); }
.has-featured-photo #podium figure { padding: 6px; margin: 8px 0 0; }
.has-featured-photo #podium img { height: clamp(55px, 11dvh, 100px); }
.has-featured-photo #podium figcaption { padding: 3px 0 0; font-size: .75rem; }
figure { margin: 14px 0; }
figure img { display: block; width: 100%; height: clamp(130px, 38vw, 300px); object-fit: contain; background: var(--inset); border-radius: 9px; }
figure img:not([src]) { display: none; }
figcaption { padding-block: 8px; overflow-wrap: anywhere; }
.photo-preview {
  display: grid; width: 100%; justify-items: center; gap: 4px;
  border: 1px solid var(--line); background: var(--inset); color: var(--accent); padding: 5px; box-shadow: none;
}
.photo-preview:not(:disabled) { cursor: zoom-in; }
#arrival-order { margin: 14px 0; }
#arrival-order summary { cursor: pointer; font-weight: 700; }
#arrival-list { margin: 6px 0 0; padding-inline-start: 24px; color: var(--muted); overflow-wrap: anywhere; }
#arrival-list li:first-child { color: var(--accent); }
#arrival-list li + li { margin-top: 5px; }
#arrival-list button { margin-inline-start: 5px; padding-inline: 8px; font-size: .85rem; }
#photo-inspector {
  width: min(94vw, 1000px); max-height: 94dvh; padding: clamp(8px, 2vw, 20px);
  border: 1px solid var(--line); border-radius: 17px; background: var(--panel); color: inherit;
}
#photo-inspector[open] { display: flex; flex-direction: column; }
#photo-inspector::backdrop { background: #05150ee6; }
.inspector-header {
  display: flex; justify-content: space-between; align-items: center;
  gap: 8px; flex-wrap: wrap; margin-bottom: 8px;
}
.inspector-header h2, .inspector-header form { margin: 0; }
#inspector-status:empty { display: none; }
#inspector-viewport { min-height: 0; max-height: 72dvh; overflow: auto; background: var(--inset); }
#inspector-image { display: block; max-width: 100%; max-height: 72dvh; height: auto; margin: auto; object-fit: contain; }
#inspector-viewport.zoomed #inspector-image { width: 170%; max-width: none; max-height: none; margin: 0; }
#inspector-actions { justify-content: flex-end; padding-block: 10px 3px; }
#inspector-skip { border-color: var(--rose); }
#screen-roster { display: flex; justify-content: center; gap: 7px; flex-wrap: wrap; list-style: none; padding: 0; margin-top: 23px; }
#screen-roster li { padding: 5px 11px; background: var(--panel); border: 1px solid var(--line); border-radius: 99px; overflow-wrap: anywhere; }
@media (max-width: 640px) {
  #home { grid-template-columns: 1fr; }
  .home-round { width: min(100%, 310px); }
  .inspector-header h2 { font-size: 1.08rem; }
}
