/* ===== Veil of Fear: Last Signal — outer shell =====
   Night fog palette, one amber "signal" accent. Red is reserved for Greywood. */
:root {
  --night: #0c1115;
  --night-2: #141b21;
  --fog: #d6dcdf;
  --mist: #8c989e;
  --line: rgba(214, 220, 223, .16);
  --signal: #e2a63b;
  --alert: #c2453a;
  --paper: #ece6d8;
  --ink: #d6dcdf; --dim: #8c989e; --accent: #e2a63b;
  --os-bg: #f2f2f0; --os-ink: #1f2226; --os-line: #d9d9d4; --os-dim: #7a7d82;
  --bubble-me: #3d7be0; --bubble-them: #e6e6e3;
  --serif: 'Spectral', Georgia, serif;
  --sans: 'Golos Text', 'Segoe UI', system-ui, sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; background: var(--night); color: var(--fog); font-family: var(--sans); overflow: hidden; }
button { font: inherit; cursor: pointer; }
:focus-visible { outline: 2px solid var(--signal); outline-offset: 2px; }
.hidden { display: none !important; }
.small { font-size: 14px; }
.dim { color: var(--mist); }

/* grain + vignette */
.grain { pointer-events: none; position: fixed; inset: 0; z-index: 50;
  background: radial-gradient(ellipse at center, transparent 58%, rgba(0,0,0,.5) 100%); }
.grain::after { content: ''; position: absolute; inset: -50%; opacity: .06;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: grain 1s steps(4) infinite; }
@keyframes grain { 0%{transform:translate(0,0)} 25%{transform:translate(-3%,2%)} 50%{transform:translate(2%,-3%)} 75%{transform:translate(-2%,-1%)} }
@media (prefers-reduced-motion: reduce) { .grain::after, .sig-1 i:first-child { animation: none !important; } }

/* signal meter: the game's signature mark */
.sig { display: inline-flex; align-items: flex-end; gap: 2px; height: 14px; }
.sig i { width: 3px; background: rgba(214,220,223,.22); border-radius: 1px; }
.sig i:nth-child(1) { height: 25%; } .sig i:nth-child(2) { height: 50%; } .sig i:nth-child(3) { height: 75%; } .sig i:nth-child(4) { height: 100%; }
.sig-1 i:first-child { background: var(--signal); animation: flicker 6s infinite; }
.sig-big { height: 22px; gap: 3px; } .sig-big i { width: 5px; }
@keyframes flicker { 0%, 92%, 100% { opacity: 1; } 94% { opacity: .2; } 96% { opacity: 1; } 97% { opacity: .35; } }

/* screens */
.screen { position: fixed; inset: 0; display: none; opacity: 0; transition: opacity .8s; }
.screen.active { display: flex; opacity: 1; }
.screen.fading { opacity: 0; }

.big-btn { background: var(--signal); color: #1a1408; border: none; padding: 12px 28px; font-size: 16px; font-weight: 600; border-radius: 3px; transition: background .2s; }
.big-btn:hover { background: #f0b950; }
.small-btn { padding: 8px 20px; font-size: 14px; }
.link-btn { background: none; border: none; color: inherit; text-decoration: underline; text-underline-offset: 3px; opacity: .75; }
.link-btn:hover { opacity: 1; }

/* HUD: goal on the left, tools on the right */
#hud { position: fixed; top: 0; left: 0; right: 0; z-index: 40; display: flex; justify-content: space-between; align-items: center; gap: 16px;
  padding: 10px 16px; background: linear-gradient(rgba(12,17,21,.92), rgba(12,17,21,0)); pointer-events: none; }
#hud > * { pointer-events: auto; }
.hud-goal { display: flex; align-items: center; gap: 10px; font-size: 14px; color: var(--mist); min-width: 0; }
.hud-goal b { color: var(--fog); font-weight: 500; }
.hud-actions { display: flex; gap: 6px; flex: none; }
.hud-btn { background: rgba(20,27,33,.85); color: var(--fog); border: 1px solid var(--line); padding: 6px 12px; font-size: 13px; border-radius: 3px; }
.hud-btn:hover { border-color: var(--fog); }
.hud-lang { min-width: 40px; }

/* title */
#scr-title { align-items: center; justify-content: center; overflow-y: auto; }
.title-bg { position: absolute; inset: 0; background: url(../img/life_11_road.jpg) center/cover; filter: grayscale(.35) brightness(.45); }
.title-bg::after { content: ''; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(12,17,21,.97) 0%, rgba(12,17,21,.88) 42%, rgba(12,17,21,.35) 100%); }
.title-grid { position: relative; width: min(1100px, 100%); padding: 40px 32px; display: grid; grid-template-columns: minmax(0, 1fr) 260px; gap: 48px; align-items: end; max-height: 100%; }
.brand { display: flex; align-items: center; gap: 12px; font-family: var(--serif); font-size: 20px; color: var(--mist); letter-spacing: .02em; }
h1 { font-family: var(--serif); font-weight: 300; font-size: clamp(56px, 9vw, 112px); line-height: .95; margin: 8px 0 14px; color: var(--fog); letter-spacing: -.01em; }
.tagline { font-family: var(--serif); font-size: 20px; color: var(--mist); margin: 0 0 34px; max-width: 38ch; }
.steps { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 22px; max-width: 520px; }
.steps li { display: grid; grid-template-columns: 30px 1fr; gap: 14px; align-items: start; }
.step-n { width: 30px; height: 30px; border-radius: 50%; border: 1px solid var(--line); display: flex; align-items: center; justify-content: center; font-size: 14px; color: var(--signal); }
.step-t { font-weight: 500; font-size: 16px; margin: 4px 0 6px; }
.step-d { color: var(--mist); font-size: 14px; line-height: 1.5; margin-bottom: 10px; }
.lang-pick { display: flex; gap: 8px; }
.lang-btn { background: transparent; border: 1px solid var(--line); color: var(--mist); padding: 7px 16px; border-radius: 3px; }
.lang-btn.on { color: var(--night); background: var(--fog); border-color: var(--fog); }
.qr-card { background: rgba(20,27,33,.9); border: 1px solid var(--line); border-radius: 4px; padding: 18px; text-align: center; }
.qr-title { font-family: var(--serif); font-size: 18px; margin-bottom: 12px; }
#qr { display: inline-block; background: #fff; padding: 8px; line-height: 0; border-radius: 2px; }
#qr img { width: 150px; height: 150px; image-rendering: pixelated; }
.qr-card p { margin: 10px 0 0; line-height: 1.4; }
#nb-link { color: var(--fog); word-break: break-all; font-size: 12px; }
@media (max-width: 820px) { .title-grid { grid-template-columns: 1fr; align-items: start; gap: 28px; padding-top: 60px; } .qr-card { max-width: 300px; } }

/* intro */
#scr-intro { align-items: stretch; }
.intro-img { flex: 1.3; position: relative; overflow: hidden; }
.intro-img img { width: 100%; height: 100%; object-fit: cover; filter: brightness(.72) saturate(.8); animation: slowzoom 30s linear forwards; }
@keyframes slowzoom { to { transform: scale(1.08); } }
.intro-text { flex: 1; padding: 8vh 4vw 6vh; display: flex; flex-direction: column; justify-content: center; max-width: 600px; overflow-y: auto; }
.intro-text h2 { font-family: var(--serif); font-weight: 400; font-size: 36px; margin: 0 0 18px; }
.intro-text p { font-family: var(--serif); font-size: 18px; line-height: 1.65; margin: 0 0 12px; color: #c3cacd; }
.intro-text .paper { background: var(--paper); color: #2b2620; padding: 18px 20px 14px; border-radius: 2px; box-shadow: 0 10px 30px rgba(0,0,0,.45); transform: rotate(-.6deg); margin: 6px 0 4px; }
.intro-text .paper p { color: #2b2620; font-size: 17px; margin: 0 0 8px; }
.intro-text .paper p:last-child { text-align: right; margin: 0; }
.intro-text .big-btn { align-self: flex-start; margin-top: 22px; }
@media (max-width: 760px) { #scr-intro { flex-direction: column; } .intro-img { flex: 0 0 34vh; } }

/* laptop */
#scr-laptop { align-items: center; justify-content: center; background: radial-gradient(ellipse at center, var(--night-2) 0%, #06090b 75%); }
.bezel { width: min(96vw, calc(92vh * 16 / 10)); aspect-ratio: 16 / 10; background: #111; border-radius: 14px; padding: 14px; box-shadow: 0 0 80px rgba(120,150,200,.12), 0 30px 60px rgba(0,0,0,.8); }
.display { position: relative; width: 100%; height: 100%; overflow: hidden; border-radius: 3px; background: #000; color: var(--os-ink); font-size: 14px; }

/* lock screen */
.lock { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px;
  background: linear-gradient(rgba(0,0,0,.45), rgba(0,0,0,.65)), url(../img/life_09_rooftop.jpg) center/cover; color: #fff; }
.lock-avatar { width: 110px; height: 110px; border-radius: 50%; object-fit: cover; border: 2px solid rgba(255,255,255,.7); }
.lock-name { font-size: 20px; margin-bottom: 6px; }
#lock-form { display: flex; }
#pw { width: 220px; padding: 8px 12px; border: 1px solid rgba(255,255,255,.5); border-right: none; background: rgba(255,255,255,.18); color: #fff; font-size: 15px; outline: none; border-radius: 4px 0 0 4px; }
#pw::placeholder { color: rgba(255,255,255,.65); }
#pw-go { background: rgba(255,255,255,.25); color: #fff; border: 1px solid rgba(255,255,255,.5); border-radius: 0 4px 4px 0; padding: 0 12px; }
.pw-msg { min-height: 18px; font-size: 13px; color: #ffb3a8; }
.pw-hint { max-width: 320px; text-align: center; background: rgba(0,0,0,.45); padding: 8px 12px; border-radius: 4px; font-size: 13px; }
.lock .link-btn { color: #fff; font-size: 13px; }
.shake { animation: shake .4s; }
@keyframes shake { 20%,60%{transform:translateX(-8px)} 40%,80%{transform:translateX(8px)} }

/* desktop */
.desktop { position: absolute; inset: 0; background: url(../img/life_09_rooftop.jpg) center/cover; }
.menubar { position: absolute; top: 0; left: 0; right: 0; height: 26px; background: rgba(245,245,243,.82); backdrop-filter: blur(8px);
  display: flex; align-items: center; justify-content: space-between; padding: 0 12px; font-size: 13px; z-index: 5; }
.menubar .logo { font-weight: 700; }
.dock { position: absolute; bottom: 8px; left: 50%; transform: translateX(-50%); display: flex; gap: 6px; padding: 6px 8px;
  background: rgba(245,245,243,.55); backdrop-filter: blur(10px); border-radius: 12px; border: 1px solid rgba(255,255,255,.5); z-index: 6; }
.dock-item { position: relative; width: 50px; height: 50px; border-radius: 11px; border: none; display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 22px; transition: transform .15s; }
.dock-item:hover { transform: translateY(-4px); }
.dock-item.locked { filter: grayscale(1) brightness(.85); opacity: .55; cursor: not-allowed; }
.dock-item .badge { position: absolute; top: -5px; right: -5px; background: #e2402f; color: #fff; font-size: 11px; min-width: 19px; height: 19px; border-radius: 10px; padding: 0 5px; display: flex; align-items: center; justify-content: center; font-weight: 700; }
.dock-item .tip { position: absolute; bottom: 60px; left: 50%; transform: translateX(-50%); white-space: nowrap; background: rgba(30,30,32,.85); color: #fff; font-size: 12px; padding: 3px 8px; border-radius: 4px; opacity: 0; pointer-events: none; transition: .15s; }
.dock-item:hover .tip { opacity: 1; }

/* window */
.win { position: absolute; top: 40px; left: 4%; right: 4%; bottom: 76px; background: var(--os-bg); border-radius: 8px; box-shadow: 0 20px 50px rgba(0,0,0,.45); display: flex; flex-direction: column; overflow: hidden; z-index: 4; }
.win-bar { height: 32px; flex: none; display: flex; align-items: center; justify-content: center; position: relative; background: linear-gradient(#ececea, #dcdcd8); border-bottom: 1px solid #c9c9c4; font-size: 13px; font-weight: 700; color: #44474c; }
#win-close { position: absolute; right: 8px; top: 5px; width: 22px; height: 22px; border: none; background: transparent; color: #666; border-radius: 4px; }
#win-close:hover { background: #d0d0cb; }
.win-body { flex: 1; min-height: 0; display: flex; }

/* messages */
.chat-list { width: 270px; flex: none; border-right: 1px solid var(--os-line); overflow-y: auto; background: #f7f7f5; }
.chat-row { display: flex; gap: 10px; padding: 10px 12px; border-bottom: 1px solid #ebebe7; cursor: pointer; align-items: center; }
.chat-row:hover { background: #ececea; }
.chat-row.on { background: #dfe8f7; }
.ava { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; flex: none; background: #b9bcc2; color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 700; }
.chat-meta { flex: 1; min-width: 0; }
.chat-name { font-weight: 700; display: flex; justify-content: space-between; gap: 6px; }
.chat-name .when { font-weight: 400; font-size: 11px; color: var(--os-dim); }
.chat-last { font-size: 13px; color: var(--os-dim); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dot { width: 9px; height: 9px; border-radius: 50%; background: var(--bubble-me); flex: none; }
.conv { flex: 1; display: flex; flex-direction: column; min-width: 0; background: #fff; }
.conv-head { flex: none; padding: 10px 16px; border-bottom: 1px solid var(--os-line); font-weight: 700; text-align: center; }
.conv-body { position: relative; flex: 1; overflow-y: auto; padding: 14px 18px 24px; display: flex; flex-direction: column; gap: 4px; }
.day { align-self: center; font-size: 11px; color: var(--os-dim); margin: 12px 0 4px; }
.msg { max-width: 64%; padding: 7px 12px; border-radius: 16px; line-height: 1.35; position: relative; }
.msg.them { align-self: flex-start; background: var(--bubble-them); border-bottom-left-radius: 5px; }
.msg.me { align-self: flex-end; background: var(--bubble-me); color: #fff; border-bottom-right-radius: 5px; }
.msg .time { display: block; font-size: 10px; opacity: .6; margin-top: 2px; text-align: right; }
.msg.unread-mark { box-shadow: 0 0 0 2px rgba(61,123,224,.0); }
.voice { display: flex; align-items: center; gap: 10px; min-width: 230px; }
.voice-play { width: 30px; height: 30px; border-radius: 50%; border: none; background: rgba(255,255,255,.95); color: var(--bubble-me); flex: none; font-size: 12px; }
.voice-bars { flex: 1; height: 24px; display: flex; align-items: center; gap: 2px; }
.voice-bars i { flex: 1; background: rgba(255,255,255,.55); border-radius: 1px; }
.voice-bars i.on { background: #fff; }
.voice-dur { font-size: 12px; opacity: .85; min-width: 34px; text-align: right; }
.new-sep { align-self: stretch; text-align: center; font-size: 11px; color: #e2402f; border-top: 1px solid #f2b5ad; margin: 10px 0 4px; padding-top: 4px; }

/* photos */
.photos { flex: 1; overflow-y: auto; padding: 14px 18px; background: #fff; }
.photos h4 { margin: 0 0 2px; }
.photos .sub { color: var(--os-dim); font-size: 12px; margin-bottom: 12px; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 4px; }
.thumb { position: relative; aspect-ratio: 1; overflow: hidden; cursor: pointer; background: #ddd; }
.thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s; }
.thumb:hover img { transform: scale(1.04); }
.thumb .d { position: absolute; left: 0; right: 0; bottom: 0; font-size: 10px; color: #fff; padding: 3px 5px; background: linear-gradient(transparent, rgba(0,0,0,.6)); }
.thumb.vanish { animation: vanish 2.6s forwards; }
@keyframes vanish { 0%{filter:none} 15%{filter:contrast(3) hue-rotate(90deg); transform: translateX(3px)} 25%{filter:invert(1)} 35%{filter:none; transform:none} 60%{opacity:.6; filter:blur(2px) grayscale(1)} 100%{opacity:0; filter:blur(8px) grayscale(1)} }
.viewer { position: absolute; inset: 0; background: rgba(10,10,10,.96); z-index: 8; display: flex; flex-direction: column; color: #fff; }
.viewer-top { display: flex; justify-content: space-between; align-items: center; padding: 8px 14px; font-size: 13px; }
.viewer-top button { background: none; border: none; color: #fff; font-size: 13px; }
.viewer-stage { flex: 1; overflow: hidden; display: flex; align-items: center; justify-content: center; cursor: zoom-in; }
.viewer-stage.zoomed { cursor: zoom-out; }
.viewer-stage img { max-width: 100%; max-height: 100%; transition: transform .25s; }
.viewer-hint { text-align: center; font-size: 11px; opacity: .5; padding: 6px; }

/* find device */
.find { flex: 1; display: flex; }
.find-map { flex: 1; position: relative; background: #dfe6d8; overflow: hidden; }
.find-map svg { width: 100%; height: 100%; display: block; }
.find-card { width: 300px; flex: none; padding: 18px; border-left: 1px solid var(--os-line); background: #fafaf8; }
.find-card h4 { margin: 0 0 4px; font-size: 17px; }
.find-card .off { color: #d0402f; font-weight: 700; font-size: 13px; }
.find-card .lbl { color: var(--os-dim); font-size: 12px; margin-top: 16px; }
.find-card .val { margin-top: 3px; line-height: 1.4; }
.find-card button { margin-top: 20px; width: 100%; padding: 8px; border: 1px solid #c8c8c3; background: #fff; border-radius: 6px; }
.find-card .msgline { font-size: 12px; color: var(--os-dim); margin-top: 8px; }
.pin-pulse { animation: pulse 2s infinite; transform-origin: center; transform-box: fill-box; }
@keyframes pulse { 0%{opacity:.6; transform:scale(.6)} 100%{opacity:0; transform:scale(2.2)} }

/* notifications */
.notifs { position: absolute; top: 34px; right: 10px; z-index: 9; display: flex; flex-direction: column; gap: 8px; width: 300px; }
.notif { background: rgba(250,250,248,.95); border-radius: 8px; box-shadow: 0 8px 24px rgba(0,0,0,.3); padding: 10px 12px; font-size: 13px; animation: slidein .4s; cursor: pointer; }
.notif b { display: block; margin-bottom: 2px; }
.notif.alert { border-left: 4px solid #d0402f; }
@keyframes slidein { from { transform: translateX(120%); } to { transform: none; } }

/* glitch on display */
.display.glitch { animation: glitch .5s 3; }
@keyframes glitch { 0%{filter:none} 20%{filter:contrast(2) saturate(0)} 40%{transform:translateX(-4px)} 60%{filter:invert(.1); transform:translateX(3px)} 100%{filter:none; transform:none} }

/* locked app placeholder */
.locked-app { flex: 1; display: flex; align-items: center; justify-content: center; color: var(--os-dim); background: #fff; }

/* shared OS bits */
.dim-os { color: var(--os-dim); font-size: 13px; }
.small-os { font-size: 11px; }
.os-link { background: none; border: none; color: #2b6fd6; padding: 0; margin-bottom: 12px; font-size: 13px; }
.os-btn { background: #fff; border: 1px solid #c8c8c3; border-radius: 6px; padding: 7px 16px; margin: 6px 0; }
.os-btn:hover { background: #f0f0ec; }
.note-h { margin: 6px 0 10px; font-size: 20px; }

/* notes */
.notes-list { background: #fbf8ec; }
.note-row { padding: 10px 14px; border-bottom: 1px solid #ece6cf; cursor: pointer; }
.note-row:hover { background: #f4eed6; }
.note-row.on { background: #f7e7a6; }
.note-title { font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.note-meta { font-size: 12px; color: #8d8670; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.note-meta span { color: #6d6650; margin-right: 4px; }
.note-page { flex: 1; overflow-y: auto; padding: 18px 28px; background: #fffdf5; }
.note-date { text-align: center; font-size: 12px; color: #9a937b; margin-bottom: 8px; }
.note-body { white-space: pre-wrap; line-height: 1.6; font-size: 15px; }
.note-lock { margin-top: 12%; text-align: center; display: flex; flex-direction: column; gap: 8px; align-items: center; }
.note-lock-icon { font-size: 34px; }
.note-lock form { display: flex; gap: 6px; margin-top: 8px; }
.note-lock input { width: 260px; padding: 7px 10px; border: 1px solid #c8c3ad; border-radius: 6px; font: inherit; }
.note-lock button { border: 1px solid #c8c3ad; background: #fff; border-radius: 6px; padding: 0 14px; }
.note-msg { color: #c0392b; font-size: 13px; min-height: 18px; }

/* vidora */
.vidora { flex: 1; overflow-y: auto; padding: 16px 22px; background: #fff; }
.vid-head { display: flex; gap: 12px; align-items: center; padding-bottom: 12px; border-bottom: 1px solid var(--os-line); }
.vid-ava img { width: 52px; height: 52px; border-radius: 50%; object-fit: cover; }
.vid-name { font-weight: 700; font-size: 18px; }
.vid-sec { margin: 16px 0 8px; font-size: 14px; }
.vid-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 14px; }
.vid-card { cursor: pointer; }
.vid-thumb { position: relative; aspect-ratio: 16/9; background: #1b1b1d; border-radius: 6px; overflow: hidden; display: flex; align-items: center; justify-content: center; color: #8a8a8e; font-size: 12px; }
.vid-thumb img { width: 100%; height: 100%; object-fit: cover; }
.vid-thumb i { position: absolute; font-style: normal; color: #fff; background: rgba(0,0,0,.55); width: 36px; height: 36px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 13px; }
.vid-title { font-weight: 700; margin-top: 6px; font-size: 13px; }
.vid-detail { max-width: 720px; }
.vid-player { aspect-ratio: 16/9; background: #111; border-radius: 6px; overflow: hidden; display: flex; align-items: center; justify-content: center; }
.vid-player img { width: 100%; height: 100%; object-fit: cover; filter: brightness(.7); }
.vid-empty { color: #8a8a8e; }
.vid-progress { height: 4px; background: #e6e6e3; border-radius: 2px; overflow: hidden; margin: 6px 0 4px; }
.vid-progress i { display: block; height: 100%; width: 0; background: #c9302c; }
.vid-comment { padding: 8px 0; border-bottom: 1px solid #efefec; font-size: 13px; }
.vid-comment b { margin-right: 6px; }

/* browser */
.browser { flex: 1; display: flex; flex-direction: column; background: #fff; min-width: 0; }
.br-bar { flex: none; padding: 7px 12px; background: #ececea; border-bottom: 1px solid var(--os-line); }
.br-url { display: block; background: #fff; border: 1px solid #d3d3ce; border-radius: 14px; padding: 4px 12px; font-size: 12px; color: #555; }
.br-page { flex: 1; overflow-y: auto; padding: 16px 26px; }
.br-row { display: flex; flex-direction: column; gap: 1px; padding: 9px 0; border-bottom: 1px solid #efefec; cursor: pointer; }
.br-row:hover .br-title { text-decoration: underline; }
.br-title { color: #1a4fb8; font-size: 15px; }
.forum-crumbs { font-size: 12px; color: #8a6b4a; }
.forum-post { border: 1px solid #e3ddd3; background: #faf8f4; padding: 10px 14px; margin-bottom: 8px; line-height: 1.45; }
.forum-post.nora { border-color: #b9cdea; background: #f3f7fd; }
.forum-who { display: flex; justify-content: space-between; font-size: 12px; color: #7d756a; margin-bottom: 4px; }
.forum-who b { color: #4a3b2a; }
.forum-attach { margin-top: 6px; font-size: 12px; color: #a0522d; }

/* end of prologue */
#scr-end { align-items: center; justify-content: center; text-align: center; background: radial-gradient(ellipse at 50% 40%, var(--night-2), var(--night) 70%); }
.end-wrap { max-width: 640px; padding: 24px; }
.end-big { font-family: var(--serif); font-weight: 300; font-size: clamp(36px, 6vw, 60px); margin: 22px 0 10px; line-height: 1.05; }
.end-sub { font-family: var(--serif); font-size: 20px; color: var(--mist); margin: 0 0 36px; }
.end-label { color: var(--mist); font-size: 14px; margin: 0 0 6px; }
.end-next { font-size: 16px; margin: 0 0 22px; }
#btn-continue { margin-bottom: 10px; }
#end-5 { margin-top: 24px; }

/* modal (hints, notebook) */
.modal { position: fixed; inset: 0; z-index: 45; background: rgba(5,8,10,.7); display: flex; align-items: center; justify-content: center; }
.modal-box { background: var(--night-2); border: 1px solid var(--line); padding: 24px 28px; max-width: 480px; width: 90%; border-radius: 4px; }
.modal-box h3 { margin: 0 0 14px; font-family: var(--serif); font-weight: 400; font-size: 24px; }
.modal-box ol { padding-left: 20px; line-height: 1.55; }
.modal-box li { margin-bottom: 10px; }
.modal-box li:last-child { color: var(--fog); }
.modal-box .big-btn { margin-top: 10px; }

/* chapter card inside the laptop */
.chapter-card { position: absolute; inset: 0; z-index: 9; background: rgba(12,17,21,.97); color: var(--fog); display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 10%; animation: fadein 1s; }
.cc-label { color: var(--signal); font-size: 15px; margin-bottom: 14px; }
.cc-text { font-family: var(--serif); font-weight: 300; font-size: clamp(22px, 2.6vw, 30px); max-width: 680px; line-height: 1.35; margin: 0 0 18px; }
.cc-next { color: var(--mist); margin: 0 0 20px; }
@keyframes fadein { from { opacity: 0; } }
.mode-badge { margin: 14px 0 0; color: var(--signal); font-size: 13px; }
.lock-clock { position: absolute; top: 9%; left: 0; right: 0; text-align: center; text-shadow: 0 2px 12px rgba(0,0,0,.5); }
.lock-time { font-size: clamp(40px, 7vw, 72px); font-weight: 300; letter-spacing: .02em; line-height: 1; }
.lock-date { font-size: clamp(14px, 1.6vw, 18px); margin-top: 6px; opacity: .9; }
#scr-laptop { padding-top: 46px; }
.bezel { width: min(96vw, calc((100vh - 64px) * 16 / 10)); }

/* ===== chapter 2 ===== */
.hud-board { border-color: rgba(226,166,59,.6); color: var(--signal); }

/* mail */
.mail-folders { width: 150px; flex: none; background: #eef1f4; border-right: 1px solid var(--os-line); padding: 10px 6px; display: flex; flex-direction: column; gap: 2px; }
.mail-folder { display: flex; justify-content: space-between; border: none; background: none; padding: 7px 10px; border-radius: 5px; text-align: left; font-size: 14px; }
.mail-folder.on { background: #d6e2f3; font-weight: 600; }
.mail-list { width: 290px; flex: none; overflow-y: auto; border-right: 1px solid var(--os-line); background: #fafbfc; }
.mail-row { padding: 10px 14px; border-bottom: 1px solid #eceef0; cursor: pointer; }
.mail-row:hover { background: #f0f3f6; }
.mail-row.on { background: #dfe8f7; }
.mail-from { display: flex; justify-content: space-between; gap: 8px; }
.mail-subj { font-size: 13px; color: #444; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mail-read { flex: 1; overflow-y: auto; padding: 18px 26px; background: #fff; display: flex; flex-direction: column; }
.mail-body { margin-top: 16px; }

/* calls */
.calls { flex: 1; overflow-y: auto; padding: 16px 26px; background: #fff; }
.call-row { display: grid; grid-template-columns: 28px 1fr auto 60px; gap: 12px; align-items: center; padding: 10px 0; border-bottom: 1px solid #efefec; }
.call-ic { color: #2f9e4f; font-size: 16px; text-align: center; }
.call-row.missed .call-ic, .call-row.missed b { color: #c0392b; }
.call-who { display: flex; flex-direction: column; }
.call-dur { text-align: right; font-variant-numeric: tabular-nums; color: #444; }

/* news page */
.news-mast { display: flex; align-items: center; gap: 8px; font-family: var(--serif); font-size: 22px; border-bottom: 3px double #222; padding-bottom: 6px; margin-bottom: 8px; color: #1d1d1d; }
.gw-logo { width: 22px; height: 22px; color: #2e5e3e; }
.news-fig { margin: 8px 0 14px; }
.news-fig img { width: 100%; max-width: 640px; display: block; cursor: zoom-in; }
.news-fig figcaption { font-size: 12px; color: #666; margin-top: 4px; }

/* investigation board: the players' own wall, outside the laptop */
.board { position: fixed; inset: 0; z-index: 44; background: rgba(6,9,11,.82); display: flex; align-items: center; justify-content: center; padding: 60px 16px 20px; }
.board-box { position: relative; width: min(1080px, 100%); max-height: 100%; overflow-y: auto; background: #2a2622 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='c'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.8' numOctaves='3'/%3E%3CfeColorMatrix values='0 0 0 0 .16 0 0 0 0 .14 0 0 0 0 .12 0 0 0 .55 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23c)'/%3E%3C/svg%3E"); border: 1px solid #3c3630; border-radius: 4px; padding: 22px 26px 26px; color: var(--fog); }
.board-head { display: flex; justify-content: space-between; align-items: center; }
.board-head h2 { font-family: var(--serif); font-weight: 400; font-size: 30px; margin: 0; }
.board-close { background: none; border: 1px solid var(--line); color: var(--fog); width: 34px; height: 34px; border-radius: 3px; }
.board-intro { color: #b9b3aa; max-width: 70ch; line-height: 1.5; margin: 8px 0 18px; }
.board-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 18px; }
.board-card { position: relative; background: var(--paper); color: #2a251f; padding: 18px 16px 16px; border-radius: 2px; box-shadow: 0 8px 20px rgba(0,0,0,.4); display: flex; flex-direction: column; }
.board-card:nth-child(1) { transform: rotate(-.8deg); } .board-card:nth-child(2) { transform: rotate(.6deg); } .board-card:nth-child(3) { transform: rotate(-.4deg); }
.board-card::before { content: ''; position: absolute; top: -7px; left: 50%; width: 14px; height: 14px; margin-left: -7px; border-radius: 50%; background: #9c2f27; box-shadow: 0 2px 3px rgba(0,0,0,.4); }
.bc-top { display: flex; gap: 12px; align-items: center; }
.bc-ava { width: 56px; height: 56px; object-fit: cover; border-radius: 2px; filter: grayscale(.4); }
.bc-initial { display: flex; align-items: center; justify-content: center; background: #6a6258; color: #f1ece2; font-size: 24px; font-family: var(--serif); }
.bc-name { font-family: var(--serif); font-size: 20px; }
.bc-role { font-size: 13px; color: #6f665b; }
.bc-claim { font-family: var(--serif); font-size: 17px; line-height: 1.45; margin: 14px 0; flex: 1; }
.bc-slot { border: 1px dashed #b1a794; color: #8a8070; padding: 10px; text-align: center; font-size: 13px; margin-bottom: 10px; }
.board-btn { background: #2a251f; color: var(--paper); border: none; padding: 10px; border-radius: 2px; font-weight: 500; }
.board-btn:hover { background: #3d362e; }
.bc-msg { color: #a3352b; font-size: 13px; min-height: 18px; margin-top: 6px; }
.bc-truth { background: #2a251f; color: var(--paper); padding: 10px 12px; font-size: 14px; line-height: 1.45; }
.bc-truth span { display: block; color: var(--signal); font-size: 12px; margin-bottom: 4px; }
.board-card.solved .bc-claim { text-decoration: line-through; text-decoration-color: rgba(156,47,39,.7); text-decoration-thickness: 2px; }

.picker { position: absolute; inset: 60px 16px 20px; margin: auto; width: min(860px, calc(100% - 32px)); max-height: calc(100% - 80px); overflow-y: auto; background: var(--night-2); border: 1px solid var(--line); border-radius: 4px; padding: 22px 26px; z-index: 2; box-shadow: 0 20px 50px rgba(0,0,0,.6); }
.pk-group { font-size: 15px; font-weight: 500; color: var(--mist); margin: 18px 0 8px; }
.pk-items { display: flex; flex-wrap: wrap; gap: 8px; }
.pk-item { background: rgba(214,220,223,.06); border: 1px solid var(--line); color: var(--fog); padding: 8px 12px; border-radius: 3px; text-align: left; font-size: 13px; }
.pk-item:hover { border-color: var(--signal); }
.pk-photos .pk-item { width: 132px; padding: 4px; display: flex; flex-direction: column; gap: 4px; }
.pk-photos .pk-item img { width: 100%; aspect-ratio: 4/3; object-fit: cover; }
.pk-photos .pk-item span { font-size: 11px; color: var(--mist); }

/* ===== polish: laptop body ===== */
.bezel { position: relative; background: linear-gradient(#1b1e21, #121416); border: 1px solid #23272b; }
.bezel::after { content: ''; position: absolute; inset: 14px; pointer-events: none; z-index: 20; border-radius: 3px;
  background: linear-gradient(115deg, rgba(255,255,255,.05) 0%, rgba(255,255,255,0) 32%, rgba(255,255,255,0) 70%, rgba(255,255,255,.025) 100%); }
.webcam { position: absolute; top: 5px; left: 50%; width: 5px; height: 5px; margin-left: -2.5px; border-radius: 50%; background: #2b3034; box-shadow: inset 0 0 1px #000; z-index: 21; }
.webcam.on { background: #3ce06a; box-shadow: 0 0 8px #3ce06a, 0 0 16px rgba(60,224,106,.6); animation: camblink 1.6s infinite; }
@keyframes camblink { 50% { opacity: .55; } }

.menubar-left { display: flex; align-items: center; gap: 14px; }
.menu-app { font-weight: 600; }
.menubar-right { display: flex; align-items: center; gap: 12px; }
.menu-sync { color: #b3392f; font-weight: 600; font-variant-numeric: tabular-nums; }
.menu-sync::before { content: ''; display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: #c2453a; margin-right: 6px; animation: camblink 1s infinite; }
.win { border: 1px solid rgba(0,0,0,.18); box-shadow: 0 24px 60px rgba(0,0,0,.5), 0 2px 6px rgba(0,0,0,.2); }
.win-bar { background: linear-gradient(#f3f3f1, #e4e4e0); }
.dock { padding: 7px 10px; gap: 8px; box-shadow: 0 10px 30px rgba(0,0,0,.35); }
.dock-item { box-shadow: inset 0 1px 0 rgba(255,255,255,.35), 0 2px 5px rgba(0,0,0,.25); }
.notif { background: rgba(28,32,36,.92); color: #e9edef; border-radius: 10px; backdrop-filter: blur(10px); border: 1px solid rgba(255,255,255,.08); }
.notif b { color: #fff; }
.notif.alert { border-left: 3px solid var(--alert); }

/* chapter title card */
.chapter-title { position: fixed; inset: 0; z-index: 60; background: var(--night); display: flex; align-items: center; justify-content: center; cursor: pointer; animation: fadein .8s; }
.chapter-title.out { opacity: 0; transition: opacity .7s; }
.ct-inner { text-align: center; padding: 24px; max-width: 760px; }
.ct-label { color: var(--signal); font-size: 15px; margin-top: 18px; }
.ct-title { font-family: var(--serif); font-weight: 300; font-size: clamp(44px, 7vw, 84px); line-height: 1; margin: 6px 0 18px; }
.ct-line { font-family: var(--serif); font-size: 20px; color: var(--mist); margin: 0; }

/* chapter 3: photos */
.ph-tabs { display: flex; gap: 4px; margin-bottom: 14px; background: #ececea; padding: 3px; border-radius: 7px; width: max-content; }
.ph-tab { border: none; background: none; padding: 6px 14px; border-radius: 5px; font-size: 13px; color: #555; }
.ph-tab.on { background: #fff; color: #111; box-shadow: 0 1px 3px rgba(0,0,0,.15); }
.ph-note { color: #b3392f; font-size: 13px; margin: 0 0 12px; }
.deleted-thumb img { filter: grayscale(.6) brightness(.85); }
.restore-btn { position: absolute; top: 6px; right: 6px; border: none; background: rgba(255,255,255,.92); border-radius: 4px; font-size: 12px; padding: 4px 8px; color: #1a4fb8; }
.undelivered { align-self: flex-end; color: #c0392b; font-size: 11px; margin: -1px 4px 6px 0; }
.forum-attach.open { background: none; border: 1px solid #d9c3a8; border-radius: 3px; padding: 4px 10px; color: #a0522d; font-size: 12px; margin-top: 6px; }
.forum-attach.open:hover { background: #fbf2e6; }
.gw-badge { display: inline-flex; align-items: center; gap: 6px; color: #2e5e3e; font-weight: 600; font-size: 13px; margin: 0 0 8px; }
.news-mast { font-family: var(--serif); font-size: 26px; font-weight: 500; border-bottom: 3px double #222; padding-bottom: 6px; margin-bottom: 10px; color: #1d1d1d; }

/* plan viewer */
.plan-viewer { background: rgba(18,16,12,.97); }
.plan-wrap { flex: 1; display: flex; gap: 20px; align-items: center; justify-content: center; padding: 10px 24px 20px; overflow: auto; }
.plan-svg { width: min(70%, 820px); height: auto; box-shadow: 0 10px 40px rgba(0,0,0,.6); filter: sepia(.25) contrast(1.05); }
.plan-legend { list-style: none; padding: 16px 18px; margin: 0; background: #e7dcc3; color: #3b3226; font-family: var(--serif); font-size: 16px; line-height: 1.7; max-width: 300px; }
.plan-legend b { display: inline-block; width: 22px; }

/* chapter 3 board questions */
.board-old { margin-top: 26px; opacity: .55; transform: scale(.94); transform-origin: top center; }
.q-card .bc-name { font-size: 22px; }
.q-opts { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 8px; }
.q-opt { background: transparent; border: 1px solid #2a251f; color: #2a251f; padding: 7px 12px; border-radius: 2px; font-size: 14px; }
.q-opt:hover { background: #2a251f; color: var(--paper); }
.q-letter { width: 40px; font-family: var(--serif); font-size: 18px; padding: 5px 0; }
.board-link { background: none; border: none; color: #7a4a22; text-decoration: underline; text-underline-offset: 3px; padding: 4px 0; text-align: left; font-size: 13px; }

/* finale */
.final { position: fixed; inset: 0; z-index: 46; background: rgba(8,11,14,.94); display: flex; align-items: flex-start; justify-content: center; overflow-y: auto; padding: 60px 16px 40px; }
.final-box { width: min(900px, 100%); }
.final-box h2 { font-family: var(--serif); font-weight: 300; font-size: clamp(36px, 5vw, 56px); margin: 12px 0 6px; }
.final-lead { font-family: var(--serif); font-size: 19px; color: var(--mist); margin: 0 0 28px; max-width: 60ch; }
.final-box h3 { font-size: 16px; font-weight: 500; margin: 26px 0 12px; display: flex; gap: 12px; align-items: baseline; }
.final-count { color: var(--signal); font-size: 14px; font-weight: 400; }
.ftiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.ftile { background: var(--night-2); border: 1px solid var(--line); color: var(--fog); border-radius: 4px; padding: 6px; text-align: left; display: flex; flex-direction: column; gap: 6px; font-size: 12.5px; line-height: 1.35; }
.ftile img, .ft-ic { width: 100%; aspect-ratio: 16/10; object-fit: cover; border-radius: 2px; background: #1d252c; display: flex; align-items: center; justify-content: center; }
.ft-ic::before { font-size: 26px; color: var(--mist); }
.ft-voice::before { content: '♪'; } .ft-call::before { content: '☏'; } .ft-mail::before { content: '@'; } .ft-note::before { content: '✎'; }
.ftile.on { border-color: var(--signal); box-shadow: 0 0 0 1px var(--signal) inset; }
.ftile.on span:last-child { color: #fff; }
.fq { margin-bottom: 16px; }
.fq-t { font-family: var(--serif); font-size: 21px; margin-bottom: 8px; }
.fq-opts { display: flex; flex-wrap: wrap; gap: 8px; }
.fq-opt { background: transparent; border: 1px solid var(--line); color: var(--fog); padding: 8px 16px; border-radius: 3px; }
.fq-opt.on { background: var(--fog); color: var(--night); border-color: var(--fog); }
.final-msg { color: var(--signal); min-height: 20px; }

/* endings */
.ending { position: fixed; inset: 0; z-index: 70; background: #050708; display: flex; align-items: center; justify-content: center; padding: 24px; animation: fadein 1.2s; }
.ending-box { width: min(760px, 100%); text-align: center; display: flex; flex-direction: column; align-items: center; gap: 18px; }
.end-step, .end-after { font-family: var(--serif); font-weight: 300; font-size: clamp(22px, 3vw, 32px); line-height: 1.35; margin: 0; opacity: 0; transform: translateY(6px); transition: opacity 1.2s, transform 1.2s; }
.end-step.in, .end-after.in { opacity: 1; transform: none; }
.end-after { font-size: clamp(26px, 3.6vw, 40px); }
.end-voice { background: var(--night-2); border: 1px solid var(--line); border-radius: 14px; padding: 14px 20px; min-width: 300px; }
.ev-title { color: var(--mist); font-size: 13px; margin-bottom: 10px; }
.ev-row { display: flex; align-items: center; justify-content: center; gap: 12px; }
.ev-state { color: var(--alert); font-weight: 500; }
.end-voice.ok .ev-state { color: var(--signal); }
.sig-2 i:nth-child(-n+2), .sig-3 i:nth-child(-n+3), .sig-4 i { background: var(--signal); }
.end-listen { display: flex; flex-direction: column; align-items: center; gap: 22px; }
.end-listen img { width: 120px; height: 120px; border-radius: 50%; object-fit: cover; filter: grayscale(.3); box-shadow: 0 0 0 1px var(--line), 0 0 60px rgba(226,166,59,.12); }
.end-sub-line { font-family: var(--serif); font-size: clamp(20px, 2.6vw, 28px); line-height: 1.4; min-height: 3.2em; margin: 0; max-width: 34ch; opacity: 0; transition: opacity .6s; }
.end-sub-line.in { opacity: 1; }
.end-skip { color: var(--mist); font-size: 13px; }
.end-gw { color: #c2453a; font-size: 14px; letter-spacing: .02em; animation: gwflash 1.3s steps(2) forwards; }
@keyframes gwflash { 0% { opacity: 0; } 10% { opacity: 1; } 85% { opacity: 1; } 100% { opacity: 0; } }
.end-credits { margin-top: 20px; display: flex; flex-direction: column; align-items: center; gap: 4px; }
.end-credits p { margin: 0; }
.ec-title { font-family: var(--serif); font-size: 26px; margin-top: 10px; }
.end-reply { background: rgba(28,32,36,.92); border-left: 3px solid var(--alert); border-radius: 10px; padding: 12px 16px; text-align: left; min-width: 280px; opacity: 0; transition: opacity .8s; }
.end-reply.in { opacity: 1; }
.end-reply b { display: block; font-size: 13px; color: var(--mist); margin-bottom: 2px; font-weight: 500; }
.end-actions { display: flex; flex-direction: column; align-items: center; gap: 14px; margin-top: 10px; }
@media (prefers-reduced-motion: reduce) { .chapter-title, .ending { animation: none; } .end-step, .end-after { transition: none; } }

/* --- atmosphere pass --- */
.tagline { margin-bottom: 18px; }
.needs { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 32px; max-width: 520px; }
.needs span { font-size: 12.5px; color: var(--fog); padding: 5px 11px; border: 1px solid rgba(200,210,220,.16); border-radius: 999px; background: rgba(8,12,16,.45); }
#scr-laptop { position: relative; isolation: isolate; }
#scr-laptop::before { content: ''; position: absolute; inset: -30px; z-index: -2;
  background: url(../img/intro_boxes.jpg) center/cover; filter: blur(14px) brightness(.32) saturate(.7); }
#scr-laptop::after { content: ''; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: radial-gradient(ellipse 60% 55% at 50% 48%, rgba(120,150,200,.10), transparent 70%),
              radial-gradient(ellipse at center, transparent 40%, rgba(2,4,6,.85) 100%),
              linear-gradient(transparent 82%, rgba(30,22,16,.6)); }

/* saved game */
.resume { margin: 4px 0 12px; padding: 16px 18px; border: 1px solid rgba(224,168,90,.35); border-radius: 12px; background: rgba(224,168,90,.06); max-width: 420px; }
.resume-head { display: flex; align-items: center; gap: 10px; font-size: 15px; color: #ede5d8; }
.resume-head b { font-weight: 600; }
.resume-where { margin: 6px 0 14px; color: var(--mist); font-size: 14px; }
.resume-row { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; }
.resume-row .big-btn { margin: 0; }
.resume-sure { margin: 12px 0 0; font-size: 13px; color: #e0a85a; }
#t-saved { margin-top: 10px; max-width: 420px; }
#scr-title { align-items: flex-start; }
#scr-title .title-grid { margin: auto; max-height: none; }
.resume:not(.hidden) ~ #t-saved { display: none; }

/* sound toggle */
.hud-sound { min-width: 40px; }
.title-sound { position: absolute; top: 18px; right: 22px; z-index: 3; background: rgba(8,12,16,.5); color: var(--fog); border: 1px solid rgba(200,210,220,.18);
  border-radius: 999px; padding: 7px 14px; font-size: 13px; display: flex; align-items: center; gap: 8px; }
.title-sound:hover { border-color: var(--fog); }
.snd-ic { display: inline-flex; align-items: flex-end; gap: 2px; height: 12px; }
.snd-ic i { width: 3px; background: currentColor; border-radius: 1px; animation: snd 1.2s ease-in-out infinite; }
.snd-ic i:nth-child(1) { height: 5px; } .snd-ic i:nth-child(2) { height: 11px; animation-delay: .2s; } .snd-ic i:nth-child(3) { height: 7px; animation-delay: .4s; }
.snd-off .snd-ic i { animation: none; height: 2px !important; opacity: .6; }
@keyframes snd { 50% { transform: scaleY(.45); } }
@media (prefers-reduced-motion: reduce) { .snd-ic i { animation: none; } }

.snd-wait .snd-ic i { animation: none; opacity: .55; }
.title-sound.snd-wait { border-color: var(--signal); color: var(--signal); animation: sndpulse 2s ease-in-out infinite; }
@keyframes sndpulse { 50% { box-shadow: 0 0 0 6px rgba(226,166,59,0); } 0%, 100% { box-shadow: 0 0 0 0 rgba(226,166,59,.35); } }

/* ---- board button: easy to spot ---- */
#hud-board.hud-board { display: inline-flex; align-items: center; gap: 8px; background: var(--signal); color: #1a1408; border-color: var(--signal);
  font-weight: 600; font-size: 14px; padding: 7px 14px 7px 12px; box-shadow: 0 0 18px rgba(226,166,59,.35); }
#hud-board.hud-board:hover { background: #f0b950; }
#hud-board.hidden { display: none; }
.hb-pin { width: 10px; height: 10px; border-radius: 50%; background: #b8322a; box-shadow: inset -2px -2px 0 rgba(0,0,0,.25), 0 1px 2px rgba(0,0,0,.5); flex: none; }
.hb-count { background: rgba(0,0,0,.18); border-radius: 999px; padding: 1px 8px; font-size: 12px; }
#hud-board.hb-new { animation: hbpulse 1.4s ease-in-out infinite; }
#hud-board.hb-done .hb-count { background: rgba(0,0,0,.35); color: #fff; }
@keyframes hbpulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(226,166,59,.7); } 50% { box-shadow: 0 0 0 9px rgba(226,166,59,0); } }
.board-toast { position: fixed; top: 54px; right: 18px; z-index: 45; display: flex; align-items: center; gap: 10px; max-width: 360px;
  background: #f1ead9; color: #2a2620; padding: 10px 14px; border-radius: 3px; font-size: 13px; box-shadow: 0 8px 24px rgba(0,0,0,.5);
  transform: rotate(-1deg); animation: btin .35s ease; cursor: pointer; transition: opacity .5s, transform .5s; }
.board-toast.out { opacity: 0; transform: translateY(-8px) rotate(-1deg); }
@keyframes btin { from { opacity: 0; transform: translateY(-10px) rotate(-1deg); } }
@media (prefers-reduced-motion: reduce) { #hud-board.hb-new { animation: none; outline: 2px solid #fff; } .board-toast { animation: none; } }

/* ---- vote before chapter 2 ---- */
.vote-row { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-top: 10px; }
.vote-btn { background: #f1ead9; color: #2a2620; border: 0; border-radius: 3px; padding: 18px 16px 20px; text-align: left; display: flex; flex-direction: column; gap: 8px;
  box-shadow: 0 6px 18px rgba(0,0,0,.4); transition: transform .15s; cursor: pointer; }
.vote-btn:nth-child(1) { transform: rotate(-1deg); } .vote-btn:nth-child(3) { transform: rotate(1deg); }
.vote-btn:hover { transform: translateY(-3px) rotate(0); }
.vote-btn img, .vote-btn .bc-initial { width: 54px; height: 54px; border-radius: 50%; object-fit: cover; display: grid; place-items: center; background: #3a3530; color: #f1ead9; font-size: 22px; }
.vote-btn b { font-family: var(--serif); font-size: 20px; font-weight: 500; }
.vote-btn span { font-family: var(--serif); font-size: 15px; line-height: 1.4; color: #4a443b; }
@media (max-width: 760px) { .vote-row { grid-template-columns: 1fr; } }
.cc-sus { color: var(--signal); max-width: 620px; margin: 0 0 18px; font-size: 16px; }

/* ---- ghost_lens private message ---- */
.forum-pm { margin-top: 18px; border: 2px solid #c9a46a; background: #fffaf0; padding: 12px 16px 14px; line-height: 1.45; }
.pm-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; color: #6b4e24; }
.pm-new { background: #c0392b; color: #fff; font-size: 11px; padding: 2px 8px; border-radius: 999px; }
.pm-text { white-space: pre-line; }
.pm-cipher { margin: 10px 0; padding: 10px 12px; background: #2b2620; color: #f1e6cf; border-radius: 3px; display: flex; flex-direction: column; gap: 6px; }
.pm-cipher span { font-size: 11px; text-transform: uppercase; letter-spacing: .08em; color: #c9b48d; }
.pm-cipher code { font: 600 18px/1.4 ui-monospace, Consolas, monospace; letter-spacing: .12em; word-break: break-word; }
.pm-cipher .pm-dec { text-transform: none; letter-spacing: 0; font-size: 13px; color: #9fd49a; }
.pm-cipher .pm-dec b { font-family: ui-monospace, Consolas, monospace; letter-spacing: .1em; }
.pm-form { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.pm-form input { flex: 1; min-width: 200px; padding: 8px 10px; border: 1px solid #c8c3ad; border-radius: 6px; font: inherit; text-transform: uppercase; letter-spacing: .06em; }
.pm-form button { border: 1px solid #c8c3ad; background: #fff; border-radius: 6px; padding: 0 16px; }
.pm-form .note-msg { flex-basis: 100%; }

/* ---- Nimbus security app ---- */
.nimbus { padding: 22px 28px; max-width: 640px; }
.nb-top { display: flex; gap: 12px; align-items: center; margin-bottom: 18px; }
.nb-logo { width: 42px; height: 42px; border-radius: 10px; display: grid; place-items: center; font-size: 22px; color: #fff; background: linear-gradient(#9fb4ff,#5163d6); }
.nimbus h4 { margin: 14px 0 8px; font-size: 13px; color: #5f6770; font-weight: 600; text-transform: uppercase; letter-spacing: .05em; }
.nb-list { border: 1px solid var(--os-line); border-radius: 8px; overflow: hidden; }
.nb-dev { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-bottom: 1px solid var(--os-line); background: #fff; }
.nb-dev:last-child { border-bottom: 0; }
.nb-dev > div { flex: 1; }
.nb-dev.gw { background: #fff3f2; }
.nb-dev.gw b { color: #b3261e; }
.nb-dev.gw.out { background: #f3f6f3; }
.nb-dev.gw.out b { color: #6b7570; text-decoration: line-through; }
.nb-ic { width: 30px; height: 30px; border-radius: 7px; background: #e6e9ee; flex: none; position: relative; }
.nb-ic::after { content: ''; position: absolute; inset: 8px; border: 2px solid #6c7682; border-radius: 2px; }
.nb-phone::after { inset: 6px 10px; border-radius: 3px; }
.nb-gw { background: #f6d5d2; } .nb-gw::after { border-color: #b3261e; border-radius: 50%; }
.nb-end { border: 1px solid #b3261e; color: #b3261e; background: #fff; border-radius: 6px; padding: 6px 12px; font-size: 13px; }
.nb-need { color: #5f6770; font-size: 14px; margin: 14px 0 4px; }
.nb-form label { display: flex; flex-direction: column; gap: 4px; margin: 8px 0; font-size: 13px; color: #3d444c; }
.nb-form input { padding: 8px 10px; border: 1px solid #c9ced6; border-radius: 6px; font: inherit; }
.nb-form input.bad { border-color: #c0392b; background: #fff4f3; }
.nb-submit { margin-top: 10px; background: #5163d6; color: #fff; border: 0; border-radius: 6px; padding: 9px 16px; font-weight: 600; }
.nb-ok { margin-top: 16px; padding: 12px 14px; border-radius: 8px; background: #edf7ee; color: #24572b; font-size: 14px; line-height: 1.45; }
.menu-sync.paused { color: #7fc48a !important; }
.menu-sync.paused::before { background: #7fc48a; animation: none; }

/* Full game: buy link + key form (end of prologue and title screen) */
.key-box { margin: 18px auto 6px; max-width: 460px; text-align: left; display: flex; flex-direction: column; gap: 10px; }
.key-box .big-btn { display: inline-block; text-align: center; text-decoration: none; align-self: flex-start; }
.key-note { font-size: 13px; color: var(--mist); margin: 0; }
.key-label { font-size: 14px; margin: 8px 0 0; }
.key-form { display: flex; gap: 8px; }
.key-form input { flex: 1; min-width: 0; padding: 10px 12px; font: inherit; font-size: 15px; letter-spacing: .03em; color: inherit; background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.22); border-radius: 3px; }
.key-form input:focus { outline: none; border-color: var(--signal); }
.key-form button { flex: none; }
.key-msg { font-size: 13px; min-height: 1.2em; margin: 0; color: var(--mist); }
.key-msg.bad { color: #e07a6a; }
.key-msg.good { color: var(--signal); }
.modal .key-box { margin: 10px 0 14px; }
