/*
 * Pick or Pass waitlist page (/pick-or-pass). Loaded only on that page. It wears the game's own
 * 8-bit look from the Pick or Pass brand kit rather than Flipwise's, under the regular site header
 * and footer. Every rule is scoped under .pop so nothing leaks into the rest of the site if Turbo
 * keeps this stylesheet around after a visitor navigates away.
 *
 * Brand kit rules followed here: Press Start 2P for display text (all caps), VT323 for body copy,
 * black outlines, hard unblurred shadows, no rounded corners, green = pick, red = pass, and
 * stepped (choppy) motion.
 */

@font-face {
  font-family: "Press Start 2P";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/pick_or_pass/press-start-2p-7b91d7fe.woff2") format("woff2");
}

@font-face {
  font-family: "VT323";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/pick_or_pass/vt323-9627bd66.woff2") format("woff2");
}

.pop {
  --pop-night: #0d0b1e;
  --pop-panel: #150f33;
  --pop-cream: #fff4e0;
  --pop-muted: #cfd3e6;
  --pop-paper: #fbf6e9;
  --pop-paper-ink: #1d1a22;
  --pop-green: #2ee66b;
  --pop-green-btn: #22c45a;
  --pop-red: #ff3b4f;
  --pop-red-btn: #e8323f;
  --pop-yellow: #ffd23f;
  --pop-yellow-dark: #b88a00;
  --pop-black: #000;
  --pop-pixel: "Press Start 2P", "Courier New", monospace;
  --pop-vt: "VT323", "Courier New", monospace;

  color: var(--pop-cream);
  background: var(--pop-night);
  font-family: var(--pop-vt);
  font-size: 22px;
  line-height: 1.25;
  -webkit-font-smoothing: none;
}

.pop *:focus-visible { outline: 4px solid var(--pop-yellow); outline-offset: 3px; }

/* The title screen: the 8-bit thrift store behind the marquee logo. */
.pop-hero {
  position: relative;
  min-height: calc(100svh - 4rem);
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-items: center;
  background: var(--pop-night) url("/assets/pick_or_pass/store-ec013e21.webp") center bottom / cover no-repeat;
  border-bottom: 4px solid var(--pop-black);
  overflow: hidden;
}
@media (min-width: 1024px) { .pop-hero { min-height: calc(100svh - 5rem); } }

.pop-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 50% 35%, rgba(13, 11, 30, .35), rgba(13, 11, 30, .82) 75%);
}

.pop-wrap {
  position: relative;
  width: 100%;
  max-width: 1080px;
  margin-inline: auto;
  padding-block: 40px 56px;
  padding-inline: max(16px, env(safe-area-inset-left, 0px)) max(16px, env(safe-area-inset-right, 0px));
  display: grid;
  justify-items: center;
  grid-template-columns: minmax(0, 1fr);
  gap: 22px;
  text-align: center;
}

.pop-presents { width: min(420px, 82%); height: auto; }

.pop-title { margin: 0; }
.pop-logo {
  display: block;
  width: min(880px, 100%);
  height: auto;
  margin-inline: auto;
  animation: pop-bob 1.2s steps(1) infinite;
}
@keyframes pop-bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-4px); } }

.pop-tagline {
  margin: 0;
  font-family: var(--pop-pixel);
  font-size: clamp(12px, 2.6vw, 24px);
  line-height: 1.5;
  color: var(--pop-yellow);
  text-shadow: 0 3px 0 var(--pop-yellow-dark), 3px 6px 0 var(--pop-black), 3px 0 0 var(--pop-black),
               -3px 0 0 var(--pop-black), 0 -3px 0 var(--pop-black);
  text-wrap: balance;
}

.pop-pitch {
  max-width: 60ch;
  margin: 0;
  font-size: clamp(24px, 3.2vw, 30px);
  text-shadow: 2px 2px 0 var(--pop-black);
  text-wrap: balance;
}
.pop-pick { color: var(--pop-green); }
.pop-pass { color: var(--pop-red); }

/* Waitlist card: the game's dark panel with the yellow ring. */
.pop-card {
  width: min(620px, 100%);
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 16px;
  padding: 30px 26px 26px;
  text-align: left;
  background: var(--pop-panel);
  border: 4px solid var(--pop-black);
  outline: 4px solid var(--pop-yellow);
  outline-offset: -10px;
  box-shadow: 10px 10px 0 rgba(0, 0, 0, .6);
  scroll-margin-top: 100px;
}

.pop-full {
  justify-self: start;
  padding: 6px 8px;
  font-family: var(--pop-pixel);
  font-size: 10px;
  letter-spacing: .08em;
  color: #fff;
  background: var(--pop-red-btn);
  border: 3px solid var(--pop-black);
  text-shadow: 2px 2px 0 var(--pop-black);
  animation: pop-blink 1.4s steps(1) infinite;
}
@keyframes pop-blink { 0%, 70% { opacity: 1; } 71%, 100% { opacity: .35; } }

.pop-card h2 {
  margin: 0;
  font-family: var(--pop-pixel);
  font-size: clamp(18px, 3.4vw, 26px);
  line-height: 1.6;
  color: var(--pop-yellow);
  text-shadow: 0 3px 0 var(--pop-yellow-dark), 3px 6px 0 var(--pop-black), 2px 0 0 var(--pop-black),
               -2px 0 0 var(--pop-black), 0 -2px 0 var(--pop-black);
  text-wrap: balance;
}
.pop-card p { margin: 0; }
.pop-lede, .pop-fine { color: var(--pop-muted); }

.pop-join { display: grid; grid-template-columns: minmax(0, 1fr); gap: 10px; }
.pop-row { display: flex; flex-wrap: wrap; gap: 12px; }

.pop-sr {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* Hidden from people and screen readers; only form-filling bots reach it. */
.pop-trap { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

.pop-input {
  flex: 1 1 260px;
  min-width: 0;
  padding: 8px 12px;
  font-family: var(--pop-vt);
  font-size: 28px;
  color: var(--pop-paper-ink);
  background: var(--pop-paper);
  border: 4px solid var(--pop-black);
  border-radius: 0;
  box-shadow: inset 4px 4px 0 rgba(0, 0, 0, .12);
}
.pop-input::placeholder { color: #8a8490; }
.pop-input[aria-invalid="true"] { border-color: var(--pop-red); background: #fff0f1; }

.pop-btn {
  flex: 0 0 auto;
  padding: 14px 22px;
  font-family: var(--pop-pixel);
  font-size: 16px;
  letter-spacing: .04em;
  color: #fff;
  background: var(--pop-green-btn);
  border: 4px solid var(--pop-black);
  border-radius: 0;
  cursor: pointer;
  text-shadow: 3px 3px 0 var(--pop-black);
  box-shadow: inset 4px 4px 0 rgba(255, 255, 255, .35), inset -4px -4px 0 rgba(0, 0, 0, .3), 6px 6px 0 var(--pop-black);
}
.pop-btn:hover { filter: brightness(1.08); }
.pop-btn:active {
  transform: translate(4px, 4px);
  box-shadow: inset 4px 4px 0 rgba(255, 255, 255, .35), inset -4px -4px 0 rgba(0, 0, 0, .3), 2px 2px 0 var(--pop-black);
}
.pop-btn:disabled { filter: grayscale(.6); cursor: wait; }

.pop-error {
  margin: 0;
  font-family: var(--pop-pixel);
  font-size: 10px;
  line-height: 1.7;
  text-transform: uppercase;
  color: var(--pop-red);
  text-shadow: 2px 2px 0 var(--pop-black);
}

.pop-fine { font-size: 20px; }

/* Signed up: a verdict box, popping in like the game's CHA-CHING! */
.pop-done { display: grid; justify-items: start; gap: 14px; }
.pop-done-box {
  padding: 18px 20px;
  background: var(--pop-green-btn);
  border: 6px solid var(--pop-black);
  box-shadow: inset 5px 5px 0 rgba(255, 255, 255, .35), inset -5px -5px 0 rgba(0, 0, 0, .3), 10px 10px 0 var(--pop-black);
  transform: rotate(-2deg);
  animation: pop-in .45s cubic-bezier(.2, 1.6, .4, 1) both;
}
@keyframes pop-in { 0% { transform: scale(0) rotate(-2deg); } 100% { transform: scale(1) rotate(-2deg); } }
.pop-done-big {
  margin: 0;
  font-family: var(--pop-pixel);
  font-size: clamp(18px, 4vw, 30px);
  line-height: 1.3;
  color: #fff;
  text-shadow: 4px 4px 0 var(--pop-black), -2px -2px 0 var(--pop-black), 2px -2px 0 var(--pop-black), -2px 2px 0 var(--pop-black);
}
.pop-done-sub {
  margin: 10px 0 0;
  font-family: var(--pop-pixel);
  font-size: 10px;
  color: var(--pop-yellow);
  text-shadow: 2px 2px 0 var(--pop-black);
}
.pop-again { color: var(--pop-muted); text-decoration: underline; font-size: 22px; }
.pop-again:hover { color: var(--pop-cream); }

@media (max-width: 520px) {
  .pop { font-size: 21px; }
  .pop-wrap { padding-block: 28px 44px; gap: 18px; }
  .pop-card { padding: 26px 18px 20px; }
  .pop-btn { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  .pop-logo, .pop-full, .pop-done-box { animation: none; }
}
