/* Stage tokens from the reference site; --stage and --ink change with the sender's background. */
:root {
  --stage: #e0ceba;
  --ink: #464239;
  --slip: #393b39;
  --focus: #756555;
  --reset: #9b8a76;
  --reset-hover: #64584b;
  --slip-font: 'Courier New', monospace;
  font-family: Arial, sans-serif;
  color: var(--ink);
  background: var(--stage);
  font-synthesis: none;
}
* { box-sizing: border-box; }
html, body { background: var(--stage); }
body { margin: 0; }
main {
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding-bottom: 24px;
}
.experience { flex: 0 0 auto; position: relative; width: min(736px, 125vw); max-width: none; }
.scene { position: relative; width: 100%; aspect-ratio: 736 / 440; isolation: isolate; transition: opacity 150ms cubic-bezier(.23, 1, .32, 1); }
.frame { position: absolute; inset: 0; display: block; width: 100%; height: 100%; opacity: 0; pointer-events: none; overflow: hidden; }
.scene[data-frame="0"] .frame:nth-child(1),
.scene[data-frame="1"] .frame:nth-child(2),
.scene[data-frame="2"] .frame:nth-child(3),
.scene[data-frame="3"] .frame:nth-child(4) { opacity: 1; }
.fortune-copy { font-family: var(--slip-font); font-weight: 400; fill: var(--slip); text-anchor: middle; letter-spacing: 0; pointer-events: none; }
.cookie-hit {
  position: absolute; top: 15%; left: 26%; width: 48%; height: 65%;
  border: 0; background: none; cursor: pointer; touch-action: manipulation;
  border-radius: 45%; -webkit-tap-highlight-color: transparent;
}
.cookie-hit:disabled { cursor: default; }
.cookie-hit:focus-visible { outline: 1px dashed var(--focus); outline-offset: 8px; }
.scene[data-state="open"] .cookie-hit, .scene[data-state="opening"] .cookie-hit { pointer-events: none; }
.scene[data-state="resetting"] { opacity: 0; }
.again {
  position: absolute; top: 91%; left: 50%; transform: translateX(-50%);
  display: grid; place-items: center; width: 40px; height: 40px; padding: 0;
  color: var(--ink); background: transparent; border: 1px solid var(--reset); border-radius: 50%;
  cursor: pointer; touch-action: manipulation; -webkit-tap-highlight-color: transparent;
}
.again svg { display: block; width: 20px; height: 20px; }
.again:focus-visible { outline: 1px solid var(--focus); outline-offset: 5px; }
.again[hidden] { display: none; }
.line { min-height: 20px; margin: 40px 16px 0; font-size: 14px; text-align: center; }
.get-app {
  margin-top: 20px; padding: 12px 22px; border-radius: 999px;
  color: var(--stage); background: var(--ink); font-size: 15px; text-decoration: none;
}
.get-app:focus-visible { outline: 1px solid var(--focus); outline-offset: 4px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
@media (hover: hover) and (pointer: fine) { .again:hover { border-color: var(--reset-hover); } }
@media (max-width: 480px) { .experience { width: 130vw; } .again { top: 95%; } }
@media (prefers-reduced-motion: reduce) { .scene { transition: none; } }
