@font-face {
  font-family: "Anton";
  src: url("/assets/fonts/anton-latin-400-normal.woff2") format("woff2");
  font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "JetBrains Mono";
  src: url("/assets/fonts/jetbrains-mono-latin-400-normal.woff2") format("woff2");
  font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "JetBrains Mono";
  src: url("/assets/fonts/jetbrains-mono-latin-700-normal.woff2") format("woff2");
  font-weight: 700; font-style: normal; font-display: swap;
}

:root {
  --bg: #0D0A07;
  --wall: #5A4E42;
  --floor: #3A3128;
  --screen: #EFEAE0;
  --ember: #FF6B2C;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  background: var(--bg);
  color: var(--screen);
  font-family: "JetBrains Mono", ui-monospace, "Courier New", monospace;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
.mono { font-family: "JetBrains Mono", monospace; }
button { font-family: inherit; }

.noscript-banner {
  position: fixed; inset: 0; z-index: 99998;
  background: var(--bg); color: var(--ember);
  display: flex; align-items: center; justify-content: center;
  text-align: center; padding: 2rem; font-size: 1.2rem;
}

/* ---------- overlays ---------- */
.grain-overlay {
  position: fixed; inset: 0; z-index: 500; pointer-events: none;
  filter: url(#grain-filter);
  opacity: 0.5;
  mix-blend-mode: overlay;
}
.vignette {
  position: fixed; inset: 0; z-index: 499; pointer-events: none;
  background: radial-gradient(ellipse at 50% 45%, transparent 40%, rgba(0,0,0,0.55) 100%);
}
.room-light {
  position: fixed; inset: 0; z-index: 5; pointer-events: none;
  background: radial-gradient(circle 220px at var(--lx, 50%) var(--ly, 50%), rgba(239,234,224,0.10), transparent 70%);
  opacity: 0;
  transition: opacity 0.4s ease;
}
.room-light.is-active { opacity: 1; }
@media (hover: none) {
  .room-light { display: none; }
}

/* ---------- ashtray widget ---------- */
.ashtray-widget {
  position: fixed; bottom: 1rem; left: 1rem; z-index: 40;
  display: flex; align-items: center; gap: 0.5rem;
  background: rgba(13,10,7,0.75); border: 1px solid rgba(239,234,224,0.15);
  padding: 0.4rem 0.7rem; font-size: 0.68rem; letter-spacing: 0.03em;
  color: var(--screen);
}
.ashtray-icon {
  width: 20px; height: 14px; border-radius: 40%;
  background: #1a1512; border: 1px solid rgba(239,234,224,0.3);
  display: flex; align-items: center; justify-content: center; gap: 1px;
  overflow: hidden;
}
.ashtray-butts { display: flex; gap: 1px; }
.ashtray-butts span {
  width: 2px; height: 8px; background: #cfc6b8; display: inline-block;
}
.ashtray-label { opacity: 0.75; }
.ashtray-toast {
  position: fixed; bottom: 3.2rem; left: 1rem; z-index: 41;
  background: rgba(13,10,7,0.92); border: 1px solid rgba(239,234,224,0.2);
  padding: 0.5rem 0.8rem; font-size: 0.72rem; max-width: 240px;
  animation: toast-in 0.3s ease, toast-out 0.3s ease 3.2s forwards;
}
@keyframes toast-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: translateY(0); } }
@keyframes toast-out { to { opacity: 0; transform: translateY(-4px); } }

/* ---------- room / scroll zoom ---------- */
.room-zoom {
  position: relative;
  height: 320vh;
}
.room-stage {
  position: sticky; top: 0; left: 0; right: 0;
  height: 100svh; overflow: hidden;
  display: flex; align-items: center; justify-content: center;
  background: var(--bg);
}
.room-photo {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; object-position: 50% 50%;
  transform-origin: 63% 47%;
  will-change: transform, filter;
  filter: brightness(0.85) saturate(0.85);
}
.hotspot {
  position: absolute; z-index: 3;
  width: 34px; height: 34px; border-radius: 50%;
  background: transparent; border: none; cursor: pointer;
  transition: opacity 0.3s ease;
}
.hotspot--outlet { left: 12%; top: 42%; }
.hotspot--bottle { left: 63%; top: 66%; }
.hotspot-tip {
  position: absolute; bottom: 120%; left: 50%; transform: translateX(-50%);
  background: rgba(13,10,7,0.92); color: var(--screen);
  font-size: 0.68rem; white-space: nowrap; padding: 0.3rem 0.5rem;
  opacity: 0; pointer-events: none; transition: opacity 0.2s ease;
}
.hotspot:hover .hotspot-tip, .hotspot:focus-visible .hotspot-tip { opacity: 1; }

.room-copy {
  position: absolute; left: 6%; bottom: 14%; z-index: 3;
  max-width: 60ch;
}
.room-title {
  font-family: "Anton", ui-sans-serif, sans-serif;
  text-transform: uppercase;
  font-size: clamp(2.4rem, 8vw, 5rem);
  letter-spacing: 0.02em;
  margin: 0;
  color: var(--screen);
  text-shadow: 0 4px 24px rgba(0,0,0,0.6);
}
.room-tagline {
  margin: 0.4rem 0 0;
  font-size: 0.85rem;
  opacity: 0.7;
}
.scroll-cue {
  position: absolute; bottom: 1.5rem; left: 50%; transform: translateX(-50%);
  z-index: 3; font-size: 0.65rem; letter-spacing: 0.25em; text-transform: uppercase;
  opacity: 0.4;
}

/* ---------- MackOS ---------- */
.mackos { position: relative; min-height: 100svh; }
.menubar {
  position: sticky; top: 0; z-index: 30;
  height: 30px; display: flex; align-items: center;
  background: rgba(13,10,7,0.85); backdrop-filter: blur(6px);
  border-bottom: 1px solid rgba(239,234,224,0.1);
  padding: 0 0.9rem; font-size: 0.72rem;
  gap: 1.2rem;
}
.menubar-logo { font-weight: 700; }
.menubar-menu { display: flex; gap: 1rem; opacity: 0.55; }
.menubar-status { margin-left: auto; display: flex; gap: 0.9rem; opacity: 0.75; }
.menubar-battery::before { content: "batt "; opacity: 0.5; }

.desktop {
  position: relative; min-height: calc(100svh - 30px - 64px);
  overflow: hidden;
}
.desktop-wallpaper {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; filter: brightness(0.9) saturate(0.9);
}
.hotspot--banana { left: 78%; top: 16%; width: 60px; height: 40px; z-index: 200; }
.hotspot--banana.is-eaten { display: none; }

mac-window {
  position: absolute;
  display: block;
  max-width: 88vw;
  max-height: 62vh;
}
.mw-frame {
  background: #16120e;
  border: 1px solid rgba(239,234,224,0.18);
  box-shadow: 0 18px 40px rgba(0,0,0,0.5);
  display: flex; flex-direction: column;
  width: 100%; height: 100%;
}
.mw-titlebar {
  display: flex; align-items: center; gap: 0.5rem;
  padding: 0.4rem 0.6rem;
  background: #1c1712;
  border-bottom: 1px solid rgba(239,234,224,0.1);
  cursor: grab; user-select: none;
  touch-action: none;
}
.mw-titlebar:active { cursor: grabbing; }
.mw-dot { width: 10px; height: 10px; border-radius: 50%; border: none; padding: 0; cursor: pointer; }
.mw-dot--close { background: #ff5f57; }
.mw-dot--min { background: #febc2e; }
.mw-dot--zoom { background: #28c840; }
.mw-title { margin-left: 0.3rem; font-size: 0.7rem; opacity: 0.7; }
.mw-body {
  flex: 1; overflow: auto; padding: 0.8rem;
  font-size: 0.78rem; color: var(--screen);
}
.mw-resize {
  position: absolute; right: 0; bottom: 0; width: 16px; height: 16px;
  cursor: nwse-resize; touch-action: none;
}
mac-window.is-minimized .mw-body { display: none; }
mac-window.is-minimized { height: auto !important; }
mac-window.is-closed { display: none; }

.textedit-body { margin: 0; white-space: pre; font-size: 0.72rem; line-height: 1.6; }
.chart-body { display: flex; flex-direction: column; gap: 0.5rem; align-items: center; }
.chart-caption { margin: 0; font-size: 0.65rem; opacity: 0.6; }
.notes-body { display: flex; flex-direction: column; align-items: center; gap: 0.6rem; text-align: center; }
.notes-paper {
  background: #cfc6b4; color: #2a241c;
  font-family: "Anton", sans-serif; text-transform: uppercase;
  border: none; padding: 1.4rem 1rem;
  transform: rotate(-2deg);
  box-shadow: 0 6px 16px rgba(0,0,0,0.4);
  cursor: pointer; font-size: 1.1rem;
  clip-path: polygon(2% 0%, 100% 3%, 98% 100%, 0% 97%);
}
.notes-hint { font-size: 0.65rem; opacity: 0.55; margin: 0; }
.notes-ca { font-size: 0.6rem; opacity: 0.8; word-break: break-all; text-align: center; min-height: 1.2em; }
.term-body { display: flex; flex-direction: column; height: 100%; font-size: 0.75rem; }
.term-output { flex: 1; overflow-y: auto; white-space: pre-wrap; color: var(--ember); }
.term-input-row { display: flex; gap: 0.4rem; margin-top: 0.4rem; }
.term-prompt { opacity: 0.5; }
.term-input { flex: 1; background: transparent; border: none; color: var(--screen); font-family: inherit; font-size: 0.75rem; outline: none; }
.booth-body { position: relative; height: 100%; }
.booth-feed { width: 100%; height: 100%; object-fit: cover; filter: grayscale(0.3) brightness(0.9); }
.booth-rec {
  position: absolute; top: 0.5rem; right: 0.5rem;
  background: rgba(0,0,0,0.6); color: #ff5f57;
  font-size: 0.6rem; padding: 0.15rem 0.4rem; letter-spacing: 0.1em;
}
.booth-rec::before { content: "\25CF "; }

.dock {
  position: sticky; bottom: 0; z-index: 30;
  display: flex; align-items: center; justify-content: center; gap: 0.6rem;
  height: 64px; background: rgba(13,10,7,0.85); backdrop-filter: blur(6px);
  border-top: 1px solid rgba(239,234,224,0.1);
}
.dock-icon {
  width: 38px; height: 38px; border-radius: 9px;
  background: #1c1712; border: 1px solid rgba(239,234,224,0.15);
  color: var(--screen);
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; transition: transform 0.15s ease;
}
.dock-icon:hover { transform: translateY(-4px); }
.dock-glyph { font-size: 0.65rem; font-weight: 700; letter-spacing: 0.02em; }
.dock-sep { width: 1px; height: 28px; background: rgba(239,234,224,0.15); margin: 0 0.2rem; }

.section {
  position: relative;
  max-width: 900px;
  margin: 0 auto;
  padding: 5rem 1.25rem;
}
.section-eyebrow {
  font-family: "Anton", ui-sans-serif, sans-serif;
  text-transform: uppercase;
  font-size: clamp(1.8rem, 6vw, 2.8rem);
  color: var(--screen);
  margin: 0 0 0.4rem;
  text-align: center;
}
.section-sub { text-align: center; opacity: 0.6; font-size: 0.85rem; margin: 0 0 2.5rem; }

/* ---------- evolution slider ---------- */
.evolution-section { text-align: center; }
.evo-stage { display: flex; flex-direction: column; align-items: center; gap: 0.6rem; }
.evo-frame {
  position: relative; width: min(80vw, 320px); aspect-ratio: 543 / 724;
  overflow: hidden; border: 1px solid rgba(239,234,224,0.15);
  background: #16120e;
}
.evo-img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  opacity: 0; transition: opacity 0.35s ease;
}
.evo-img.is-active { opacity: 1; }
.evo-year {
  font-family: "Anton", sans-serif; letter-spacing: 0.05em;
  font-size: 1.1rem; color: var(--ember);
}
.evo-slider {
  width: min(80vw, 320px); margin: 1.4rem auto 0.4rem; display: block;
  accent-color: var(--ember);
}
.evo-ticks {
  width: min(80vw, 320px); margin: 0 auto; display: flex; justify-content: space-between;
  font-size: 0.62rem; opacity: 0.5; text-transform: uppercase;
}
.btn {
  font-family: "JetBrains Mono", monospace; text-transform: lowercase; font-size: 0.8rem;
  letter-spacing: 0.05em; padding: 0.65rem 1.4rem; cursor: pointer; border-radius: 2px;
  margin-top: 1.75rem;
}
.btn-primary { background: var(--ember); color: #1a0f06; border: 1px solid var(--ember); }

/* ---------- roadmap ---------- */
.roadmap-section { text-align: center; }
.roadmap-stage {
  position: relative; max-width: 640px; margin: 0 auto;
  aspect-ratio: 1672 / 941; overflow: hidden;
  border: 1px solid rgba(239,234,224,0.12);
}
.roadmap-photo { width: 100%; height: 100%; object-fit: cover; filter: brightness(0.85); }
.roadmap-butts { position: absolute; inset: 0; }
.roadmap-butt {
  position: absolute; width: 4px; height: 10px; background: #cfc6b8;
  border-radius: 2px; opacity: 0.85;
}
.roadmap-chair {
  position: absolute; right: 8%; bottom: 10%; width: 44px; height: 40px;
  border: 2px solid rgba(239,234,224,0.5); border-radius: 4px;
  opacity: 0; transition: opacity 0.5s ease;
}
.roadmap-chair.is-visible { opacity: 1; }
.roadmap-phases {
  list-style: none; margin: 1.5rem 0 0; padding: 0;
  display: flex; flex-direction: column; gap: 0.4rem;
  font-size: 0.78rem; opacity: 0.5;
}
.roadmap-phase.is-active { opacity: 1; color: var(--ember); }

/* ---------- footer ---------- */
.footer { text-align: center; padding: 3rem 1.25rem 4rem; }
.footer-line { font-size: 0.85rem; margin: 0 0 0.4rem; }
.footer-fine { font-size: 0.68rem; opacity: 0.45; margin: 0; }

@media (min-width: 720px) {
  .desktop { min-height: calc(100svh - 30px - 64px); }
}

@media (prefers-reduced-motion: reduce) {
  .room-photo { transition: none !important; }
  .ashtray-toast { animation: none; }
  * { scroll-behavior: auto !important; }
}
