:root { --night:#0b1420; --fir:#1d3a2f; --moss:#3f5e3a; --fog:#8fa3a8; --moon:#cfe0e8; --lamp:#ffd58a; --nv:#7cff8a; --red:#d6252b;
  --gs-bg:#12202c; --gs-text:#cfe0e8; --gs-accent:#ffd58a; --gs-link:#8fa3a8; }
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; height: 100%; overflow: hidden; background: var(--night); color: var(--moon);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif, "Noto Color Emoji"; overscroll-behavior: none; }
body { user-select: none; -webkit-user-select: none; }
button { font: inherit; color: inherit; cursor: pointer; }
.plain { padding: 2rem; max-width: 40rem; margin: auto; }
#game { position: fixed; inset: 0; width: 100%; height: 100%; display: block; touch-action: none; }
[hidden] { display: none !important; }

/* night vision over the canvas while the camera is up */
#nv { position: fixed; inset: 0; pointer-events: none; opacity: 0; transition: opacity .15s;
  background:
    repeating-linear-gradient(0deg, rgba(0,0,0,.16) 0 1px, transparent 1px 3px),
    radial-gradient(ellipse at center, rgba(124,255,138,.34) 0%, rgba(60,200,90,.42) 55%, rgba(0,30,8,.9) 100%);
  mix-blend-mode: multiply; }
body.vf #nv { opacity: 1; }
body.vf #game { filter: brightness(1.5) contrast(1.08) blur(var(--blur, 0px)); }
#danger { position: fixed; inset: 0; pointer-events: none; opacity: 0; transition: opacity .12s;
  box-shadow: inset 0 0 90px 30px rgba(214,37,43,.75); }
body.shake #game { animation: shake .5s; }
@keyframes shake { 0%,100% { transform: none } 15% { transform: translate(-14px,8px) rotate(-3deg) } 35% { transform: translate(12px,-10px) rotate(3deg) } 55% { transform: translate(-8px,6px) rotate(-2deg) } 75% { transform: translate(5px,-3px) } }

#hud { position: fixed; inset: 0; pointer-events: none; }
#top { position: absolute; top: calc(8px + env(safe-area-inset-top)); left: 64px; right: 64px; text-align: center; text-shadow: 0 1px 4px #000; }
#clock { font-size: 22px; font-weight: 700; font-variant-numeric: tabular-nums; letter-spacing: .04em; }
#clock small { font-size: 12px; font-weight: 500; opacity: .75; margin-left: 4px; }
#stats { display: flex; gap: 10px; justify-content: center; font-size: 13px; opacity: .95; flex-wrap: wrap; }
#roll.full { color: var(--lamp); font-weight: 700; }
#feed { position: absolute; top: calc(70px + env(safe-area-inset-top)); left: 10px; font-size: 12px; line-height: 1.5; opacity: .85; text-shadow: 0 1px 3px #000; max-width: 62%; }
#feed div { animation: fade 7s forwards; }
@keyframes fade { 0%,80% { opacity: 1 } 100% { opacity: 0 } }
#marks i { position: absolute; width: 0; height: 0; }
#marks i::before { content: ""; position: absolute; left: -9px; top: -9px; width: 18px; height: 18px; border-radius: 50%; border: 2px solid var(--moon); box-sizing: border-box; }
#marks i.sound::before { animation: ripple 1.6s ease-out forwards; }
#marks i.sound::after { content: ""; position: absolute; left: -4px; top: -4px; width: 8px; height: 8px; border-radius: 50%; background: var(--moon); animation: fade 1.6s forwards; }
@keyframes ripple { from { transform: scale(.4); opacity: 1 } to { transform: scale(3.2); opacity: 0 } }
#marks i.sig::before { border-color: var(--nv); background: rgba(124,255,138,.25); left: -6px; top: -6px; width: 12px; height: 12px; }
#marks i.phone::before { border-color: #9fe8ff; background: #9fe8ff; animation: blink .5s infinite alternate; }
@keyframes blink { to { opacity: .25 } }
#marks i span { position: absolute; top: 9px; left: -40px; width: 80px; text-align: center; font-style: normal; font-size: 10px; color: var(--nv); text-shadow: 0 1px 3px #000; white-space: nowrap; }
#marks i.phone span { color: #9fe8ff; }

#vf { position: absolute; left: 50%; top: 50%; transform: translate(-50%,-50%); color: var(--nv); font: 600 11px ui-monospace, Menlo, monospace; letter-spacing: .08em; }
#vf .c { position: absolute; width: 26px; height: 26px; border: 3px solid var(--nv); transition: border-color .1s; }
#vf.locked .c { border-color: #fff; }
#vf .tl { left: 0; top: 0; border-right: 0; border-bottom: 0 } #vf .tr { right: 0; top: 0; border-left: 0; border-bottom: 0 }
#vf .bl { left: 0; bottom: 0; border-right: 0; border-top: 0 } #vf .br { right: 0; bottom: 0; border-left: 0; border-top: 0 }
#vf-top { position: absolute; top: 8px; left: 12px; right: 12px; display: flex; justify-content: space-between; }
#vf-top b { color: #ff5a5f; animation: blink 1s infinite alternate; }
#vf-focus { position: absolute; bottom: 8px; left: 12px; right: 12px; display: flex; gap: 8px; align-items: center; }
#vf-focus .bar { flex: 1; height: 6px; border: 1px solid var(--nv); } #vf-focus .bar i { display: block; height: 100%; width: 0; background: var(--nv); }
#vf.locked #vf-focus .bar i { background: #fff; }
#vf.snap { animation: snap .18s; } @keyframes snap { 0% { background: rgba(255,255,255,.85) } 100% { background: transparent } }

#banner { position: absolute; top: 24%; left: 0; right: 0; text-align: center; font: 800 22px/1.2 Georgia, serif; letter-spacing: .03em; color: var(--lamp); text-shadow: 0 2px 10px #000; opacity: 0; transition: opacity .5s; padding: 0 20px; }
#banner.on { opacity: 1; }
#toast { position: absolute; bottom: calc(190px + env(safe-area-inset-bottom)); left: 50%; transform: translateX(-50%); background: rgba(8,14,22,.82); border: 1px solid rgba(207,224,232,.25); border-radius: 10px; padding: 8px 14px; font-size: 14px; text-align: center; max-width: 86%; opacity: 0; transition: opacity .25s; }
#toast.on { opacity: 1; } #toast b { color: var(--lamp); }
#warn { position: absolute; top: 34%; left: 0; right: 0; text-align: center; font: 900 26px system-ui, sans-serif; color: #fff; text-shadow: 0 0 14px var(--red), 0 2px 4px #000; opacity: 0; }
#warn.on { opacity: 1; animation: pulse .25s infinite alternate; } @keyframes pulse { to { transform: scale(1.06) } }
#prompt { position: absolute; top: calc(130px + env(safe-area-inset-top)); left: 0; right: 0; text-align: center; font-size: 14px; font-weight: 600; color: var(--nv); text-shadow: 0 1px 4px #000; }
#keys { position: absolute; bottom: 10px; left: 0; right: 0; text-align: center; font-size: 12px; opacity: .6; text-shadow: 0 1px 3px #000; }
body.touch #keys { display: none; }
#stick { position: absolute; width: 96px; height: 96px; margin: -48px 0 0 -48px; border-radius: 50%; border: 2px solid rgba(207,224,232,.3); display: none; }
#stick i { position: absolute; left: 50%; top: 50%; width: 40px; height: 40px; margin: -20px; border-radius: 50%; background: rgba(207,224,232,.35); }
#touch button { position: absolute; pointer-events: auto; border: 1px solid rgba(207,224,232,.35); background: rgba(8,14,22,.55); border-radius: 50%; width: 48px; height: 48px; font-size: 20px; padding: 0; touch-action: none; }
#t-pause { top: calc(8px + env(safe-area-inset-top)); left: 8px; }
#t-light { top: calc(8px + env(safe-area-inset-top)); right: 8px; }
#t-light.off { opacity: .45; }
#touch #t-cam { right: 14px; bottom: calc(96px + env(safe-area-inset-bottom)); width: 72px; height: 72px; font-size: 26px; display: none; }
#touch #t-cam small { display: block; font-size: 10px; margin-top: -2px; }
#touch #t-cam.on { background: rgba(124,255,138,.28); border-color: var(--nv); }
#touch #t-shoot { right: 96px; bottom: calc(26px + env(safe-area-inset-bottom)); width: 84px; height: 84px; background: rgba(255,255,255,.14); border: 3px solid #fff; display: none; }
#touch #t-lens { right: 22px; bottom: calc(30px + env(safe-area-inset-bottom)); width: 56px; height: 56px; font: 700 17px ui-monospace, Menlo, monospace; color: var(--nv); border-color: var(--nv); }
#touch #t-lens[hidden] { display: none; }
#touch #t-plant { right: 18px; bottom: calc(24px + env(safe-area-inset-bottom)); width: 64px; height: 64px; font-size: 13px; line-height: 1.05; color: var(--lamp); border-color: var(--lamp); display: none; }
#touch #t-plant small { display: block; font-size: 9px; opacity: .85; }
body.touch #touch #t-plant:not([hidden]) { display: block; }
#marks i.cam::before { border-color: var(--lamp); background: rgba(255,213,138,.2); left: -6px; top: -6px; width: 12px; height: 12px; }
#marks i.cam span { color: var(--lamp); }
#marks i.cam.got::before { background: var(--lamp); animation: blink .5s infinite alternate; }
#vf.tele .c { width: 34px; height: 34px; }
#t-shoot i { display: block; width: 62px; height: 62px; margin: auto; border-radius: 50%; background: #fff; }
#t-shoot:active i { transform: scale(.88); background: var(--lamp); }
body.touch #touch #t-cam, body.touch #touch #t-shoot:not([hidden]) { display: block; }
body:not(.touch) #t-pause, body:not(.touch) #t-light, body:not(.touch) #touch #t-lens { display: none; }

.screen { position: fixed; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 16px; overflow-y: auto;
  background: radial-gradient(ellipse at 50% 30%, rgba(29,58,47,.5), rgba(11,20,32,.9) 70%); }
#end { justify-content: flex-start; background: rgba(11,20,32,.94); }
.card { width: 100%; max-width: 420px; text-align: center; }
.kicker { margin: 0; font-size: 12px; letter-spacing: .25em; text-transform: uppercase; color: var(--fog); }
h1 { font: 900 44px/1.02 Georgia, "Times New Roman", serif; margin: 8px 0 10px; color: #fff; text-shadow: 0 0 30px rgba(124,255,138,.35); }
.tag { font-size: 17px; margin: 0 0 20px; color: var(--moon); }
.big { display: block; width: 100%; min-height: 58px; border-radius: 14px; border: 0; background: var(--lamp); color: #1a1408; font-size: 20px; font-weight: 800; }
.big:hover { filter: brightness(1.08); }
.sub { font-size: 13px; color: var(--fog); margin: 10px 0 0; }
.row { display: flex; gap: 8px; justify-content: center; margin-top: 12px; }
.ghost { min-height: 44px; padding: 0 16px; border-radius: 12px; border: 1px solid rgba(207,224,232,.35); background: rgba(8,14,22,.5); font-size: 14px; }
.ghost:hover { border-color: var(--moon); }
.hint { font-size: 12px; color: var(--fog); margin-top: 14px; min-height: 2.6em; }
#album { display: flex; align-items: center; justify-content: center; gap: 10px; width: 100%; min-height: 48px; margin-top: 12px; padding: 4px 8px; border: 0; background: none; font-size: 13px; color: var(--fog); }
#album .thumbs { display: flex; padding-left: 8px; }
#album img { width: 30px; height: 40px; object-fit: cover; border: 2px solid #fff; margin-left: -8px; transform: rotate(-4deg); background: #0c1f12; }
#album img:nth-child(even) { transform: rotate(3deg); }
#album b { color: var(--lamp); }
#album u { text-decoration: none; border-bottom: 1px solid rgba(207,224,232,.5); }
#album-new { display: block; width: 100%; min-height: 44px; margin: 0 0 10px; border-radius: 12px; border: 1px solid rgba(124,255,138,.55); background: rgba(8,14,22,.5); color: #7cff8a; font-size: 14px; font-weight: 700; }
#album-new[hidden], #album[hidden] { display: none; }
#album-view { z-index: 15; justify-content: flex-start; background: rgba(11,20,32,.96); }
#album-view h2 { font: 900 26px Georgia, serif; margin: 8px 0 0; color: #fff; }
#album-view .big { margin: 14px 0 24px; }
#album-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px 12px; margin-top: 14px; }
#album-grid figure { margin: 0; background: #efe9da; color: #15120c; padding: 6px 6px 8px; box-shadow: 0 6px 18px #000; transform: rotate(-1.2deg); font: 600 11px/1.35 system-ui, sans-serif; text-align: left; }
#album-grid figure:nth-child(even) { transform: rotate(1deg); }
#album-grid figure:first-child { grid-column: 1 / -1; justify-self: center; width: 62%; }
#album-grid img, #album-grid figure > i { display: block; width: 100%; aspect-ratio: 3/4; object-fit: cover; background: #0c1f12; margin-bottom: 6px; }
#album-grid b { font: 900 15px Georgia, serif; }
#album-grid .empty { background: none; box-shadow: none; border: 2px dashed rgba(207,224,232,.3); color: var(--fog); text-align: center; }
#album-grid .empty > i { background: none; }

/* the tabloid */
.paper { width: 100%; max-width: 460px; background: #efe9da; color: #15120c; padding: 12px 14px 14px; margin-top: calc(8px + env(safe-area-inset-top)); box-shadow: 0 10px 40px #000; font-family: Georgia, "Times New Roman", serif; flex: none; }
.mast { display: flex; align-items: center; justify-content: space-between; gap: 6px; border-bottom: 4px double #15120c; padding-bottom: 6px; font: 700 9px system-ui, sans-serif; letter-spacing: .08em; }
.mast span { flex: 1; } .mast span:last-child { text-align: right; }
.mast b { font: 900 17px/1 Impact, Haettenschweiler, "Arial Narrow Bold", sans-serif; color: #fff; background: var(--red); padding: 5px 9px 3px; letter-spacing: .02em; text-transform: uppercase; transform: rotate(-1.5deg); white-space: nowrap; }
#headline { font: 900 30px/1 Impact, Haettenschweiler, "Arial Narrow Bold", sans-serif; text-transform: uppercase; margin: 10px 0 4px; }
#subhead { margin: 0 0 8px; font-size: 14px; font-style: italic; }
#lead { margin: 0; display: flex; gap: 10px; align-items: flex-end; }
#lead img { width: 46%; aspect-ratio: 3/4; object-fit: cover; border: 1px solid #15120c; background: #0c1f12; }
#lead figcaption { font-size: 13px; line-height: 1.35; flex: 1; }
#lead figcaption b { display: block; font: 900 40px/1 Impact, sans-serif; color: var(--red); }
#shots { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin-top: 10px; }
#shots div { position: relative; font: 600 9px/1.2 system-ui, sans-serif; }
#shots img { width: 100%; aspect-ratio: 3/4; object-fit: cover; border: 1px solid #15120c; display: block; background: #0c1f12; }
#shots .stamp { position: absolute; top: 28%; left: -4%; right: -4%; text-align: center; color: var(--red); border: 2px solid var(--red); transform: rotate(-14deg); font: 900 9px Impact, sans-serif; background: rgba(239,233,218,.85); padding: 2px 0; letter-spacing: .04em; }
#ranks { margin: 10px 0 4px; padding-left: 22px; font: 14px/1.5 system-ui, sans-serif; }
#ranks li.me { font-weight: 800; }
#left { margin: 6px 0; padding: 6px 8px; border: 1px dashed #15120c; font: 13px/1.4 system-ui, sans-serif; }
#left b { text-transform: uppercase; letter-spacing: 0.06em; color: #d6252b; margin-right: 4px; }
#bf-score { margin: 4px 0 0; font-size: 13px; font-style: italic; border-top: 1px solid #15120c; padding-top: 6px; }
.after { margin: 12px 0 24px; flex: none; }
#vote p { margin: 14px 0 6px; font-size: 14px; }
#door { margin-top: 10px; font-size: 13px; }
#door button { width: 100%; min-height: 44px; font-size: 13px; white-space: normal; }
#door p { margin: 8px 0 0; }
#door a { color: var(--lamp); }
.opts { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 4px; }
.opts button { flex: none; min-height: 44px; padding: 0 12px; border-radius: 10px; border: 1px solid rgba(207,224,232,.35); background: rgba(8,14,22,.5); font-size: 13px; white-space: nowrap; }
[data-wefav-row] a { color: var(--lamp); }
[data-wefav-row] { margin-top: 12px; font-size: 13px; }
[data-wefav-mark] { display: block; margin-top: 12px; opacity: .8; }

.how { position: fixed; inset: 12px; max-width: 560px; margin: auto; z-index: 20; overflow-y: auto; background: #12202c; border: 1px solid rgba(207,224,232,.3); border-radius: 14px; padding: 18px 18px 22px; font-size: 14px; line-height: 1.5; user-select: text; -webkit-user-select: text; }
.how h2 { font: 800 20px Georgia, serif; margin: 0 40px 8px 0; color: #fff; } .how h3 { margin: 14px 0 4px; font-size: 13px; letter-spacing: .12em; text-transform: uppercase; color: var(--lamp); }
.how p, .how ul, .how dl { margin: 0 0 8px; } .how ul { padding-left: 18px; } .how dt { font-weight: 700; margin-top: 6px; } .how dd { margin: 0; color: var(--fog); }
.how-close { position: sticky; float: right; top: 0; width: 44px; height: 44px; border-radius: 50%; border: 1px solid rgba(207,224,232,.35); background: #0b1420; font-size: 22px; }
@media (min-width: 800px) { h1 { font-size: 56px; } #toast { bottom: 120px; } #headline { font-size: 34px; } }

/* Bigfoot's own HUD, and rooms */
body.bigfoot #touch #t-cam, body.bigfoot #touch #t-light, body.bigfoot #touch #t-shoot, body.bigfoot #touch #t-lens, body.bigfoot #touch #t-plant { display: none !important; }
#bf-bar { display: none; position: absolute; right: calc(8px + env(safe-area-inset-right)); bottom: calc(18px + env(safe-area-inset-bottom)); width: 176px; flex-wrap: wrap; gap: 8px; justify-content: flex-end; pointer-events: auto; }
body.bigfoot #bf-bar { display: flex; }
#bf-bar button { position: relative; width: 82px; height: 50px; border-radius: 12px; border: 1px solid rgba(207,224,232,.4); background: rgba(8,14,22,.72); font-size: 14px; font-weight: 700; line-height: 1.1; touch-action: none; }
#bf-bar button small { display: block; font-size: 10px; font-weight: 500; opacity: .7; }
#bf-bar button.grab { width: 100%; height: 62px; font-size: 18px; border-color: var(--red); }
#bf-bar button.grab.lit { background: var(--red); box-shadow: 0 0 18px rgba(214,37,43,.8); }
#bf-bar button.on { background: var(--moss); border-color: var(--nv); }
#bf-bar button.wait { opacity: .45; }
#bf-bar button.wait::after { content: attr(data-cd); position: absolute; right: 5px; top: 3px; font-size: 11px; color: var(--lamp); }
#marks i.prey::before { border-color: var(--lamp); background: rgba(255,213,138,.3); left: -6px; top: -6px; width: 12px; height: 12px; }
#marks i.prey span { color: var(--lamp); }
#mp-back { position: fixed; z-index: 60; left: calc(10px + env(safe-area-inset-left)); top: calc(10px + env(safe-area-inset-top)); padding: 10px 14px; border-radius: 10px; border: 1px solid rgba(255,255,255,.25); background: rgba(10,12,20,.9); font-size: 14px; }
.mp-lobby { --mp-bg: rgba(11,20,32,.86); --mp-card: #12202c; --mp-ink: #cfe0e8; --mp-dim: #8fa3a8; --mp-accent: #ffd58a; --mp-accent-ink: #1b1505; }
#again:disabled { opacity: .6; font-size: 15px; }
#bf-score.me { font-weight: 700; }
.paper img:not([src]) { visibility: hidden; }

/* tonight's sighting */
.wide { display: block; width: 100%; margin-top: 12px; border-color: rgba(255,213,138,.6); color: var(--lamp); font-weight: 700; font-size: 15px; }
#nightly-sub { margin-top: 6px; }
#nightly-end { margin-bottom: 14px; --gs-accent: #ffd58a; --gs-hi: #7cff8a; }
#nightly-line { margin: 0 0 8px; font-size: 15px; line-height: 1.4; } #nightly-line b { color: var(--lamp); }
#boards { z-index: 15; justify-content: flex-start; background: rgba(11,20,32,.96); --gs-accent: #ffd58a; --gs-hi: #7cff8a; }
#boards h2 { font: 900 26px Georgia, serif; margin: 8px 0 0; color: #fff; }
#boards .gs-panel, #nightly-panel .gs-panel { margin: 12px 0; text-align: left; }
#boards .big { margin: 14px 0 24px; }
