/* ==========================================================================
   FUBAR Creative — Work page: The Order Room / Build Archive
   Scope: work.html only. Does not restyle the global header, footer, or logo.
   Color system: FUBAR Creative approved palette only (Visual Identity, Phase 2).
   ========================================================================== */

/* Fonts: DM Sans is provided by the site's tokens/fonts.css (self-hosted,
   loaded once per page via styles.css) — no @font-face blocks here. */

:root {
  /* Core brand colors */
  --fc-black: #000000;
  --fc-white: #ffffff;
  --fc-signal: #94F511;          /* Signal Neon — active states, CTAs, focus */
  --fc-green: #6EDD03;           /* Main green object color */
  --fc-green-secondary: #53B002;
  --fc-green-dark: #398601;
  --fc-shadow-green: #246000;
  --fc-shadow-deep: #153F00;

  /* Grays */
  --fc-gray-900: rgb(45, 45, 45);
  --fc-gray-800: rgb(65, 65, 65);
  --fc-gray-700: rgb(80, 80, 80);
  --fc-gray-600: rgb(100, 100, 100);
  --fc-gray-500: rgb(125, 125, 125);

  /* Supporting digital surfaces — canonical values from the
     FUBAR Creative Design System (v.01) token set */
  --fc-page-black: #0A0B0A;   /* Ink — site background */
  --fc-card-black: #121412;   /* card surface */
  --fc-raised: #141614;       /* Carbon — secondary surface */
  --fc-border: #2A2D2A;       /* Line — borders / dividers */
  --fc-body-gray: #B8BEB6;    /* body text on dark */
  --fc-muted: #9AA09A;        /* muted / secondary text */

  --fc-font: "DM Sans", "Segoe UI", Arial, sans-serif;

  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
}

/* ---------- Base ---------- */

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
}

.fubar-game {
  color: var(--fc-body-gray);
  font-family: var(--fc-font, "DM Sans", sans-serif);
  font-size: 1rem;
  line-height: 1.6;
  overflow-x: hidden; /* horizontal scroll lives only inside the district stage */
}

.fubar-game img { max-width: 100%; }

.fubar-game h1, .fubar-game h2, .fubar-game h3 {
  color: var(--fc-white);
  line-height: 1.15;
  margin: 0;
}

/* Visible focus — Signal Neon, per brand accessibility rules */
.fubar-game :focus-visible {
  outline: 2px solid var(--fc-signal);
  outline-offset: 2px;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* ---------- Buttons ---------- */

.fubar-game .btn {
  display: inline-block;
  font-family: var(--fc-font);
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 0.7rem 1.4rem;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease,
              border-color 0.15s ease, box-shadow 0.15s ease;
}

.fubar-game .btn--primary {
  background: var(--fc-signal);
  color: var(--fc-black);
  border: 1px solid var(--fc-signal);
}
.fubar-game .btn--primary:hover {
  background: var(--fc-green);
  border-color: var(--fc-green);
  box-shadow: 0 0 14px rgba(148, 245, 17, 0.35); /* small glow: buttons only */
}

.fubar-game .btn--ghost {
  background: transparent;
  color: var(--fc-white);
  border: 1px solid var(--fc-border);
}
.fubar-game .btn--ghost:hover {
  border-color: var(--fc-signal);
  color: var(--fc-signal);
}

/* ---------- Hero ---------- */

.work-hero {
  padding: clamp(2.25rem, 5vw, 3.75rem) clamp(1rem, 4vw, 3rem) 1.25rem;
  max-width: 60rem;
}

.eyebrow {
  color: var(--fc-signal);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.3em;
  margin: 0 0 1rem;
}
.eyebrow__divider { color: var(--fc-gray-700); }

.work-hero__title {
  font-size: clamp(2rem, 4.4vw, 3.15rem);
  font-weight: 700;
  letter-spacing: -0.01em;
}
.signal-word { color: var(--fc-signal); } /* one highlighted word per headline, per brand rule */

.work-hero__body {
  max-width: 42rem;
  margin: 0.85rem 0 1.35rem;
  font-size: 1.0625rem;
}

.work-hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

/* ---------- Filters ---------- */

.work-filters {
  padding: 1rem clamp(1rem, 4vw, 3rem) 1.5rem;
  border-top: 1px solid var(--fc-border);
}

.work-filters__label {
  color: var(--fc-muted);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.25em;
  margin: 0 0 0.75rem;
}

.work-filters__chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.chip {
  background: var(--fc-card-black);
  color: var(--fc-body-gray);
  border: 1px solid var(--fc-border);
  border-radius: 999px; /* pill shape reserved for badges / tags / chips */
  font-family: var(--fc-font);
  font-size: 0.8125rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  padding: 0.45rem 1.1rem;
  cursor: pointer;
  transition: border-color 0.15s ease, color 0.15s ease, background-color 0.15s ease;
}
.chip:hover {
  border-color: var(--fc-gray-600);
  color: var(--fc-white);
}
.chip[aria-pressed="true"] {
  background: var(--fc-raised);
  border-color: var(--fc-signal);
  color: var(--fc-signal);
}

.work-filters__status {
  color: var(--fc-muted);
  font-size: 0.8125rem;
  margin: 0.75rem 0 0;
  min-height: 1.2em;
}

/* ---------- Build District ---------- */

.district {
  padding: 0 clamp(1rem, 4vw, 3rem) 1.25rem;
}

.district__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.75rem;
}

.district__title {
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--fc-gray-500);
}

.district__controls { display: flex; gap: 0.5rem; }

.stage-btn {
  width: 2.75rem;
  height: 2.75rem;
  background: var(--fc-card-black);
  color: var(--fc-white);
  border: 1px solid var(--fc-border);
  border-radius: var(--radius-sm);
  font-size: 1.1rem;
  cursor: pointer;
  transition: border-color 0.15s ease, color 0.15s ease;
}
.stage-btn:hover {
  border-color: var(--fc-signal);
  color: var(--fc-signal);
}

/* District + Order Room preview: stacked by default, side-by-side on
   wide screens (matches the approved split-view mockup). */
.district__layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

@media (min-width: 1200px) {
  .district__layout {
    grid-template-columns: minmax(0, 1.2fr) minmax(340px, 0.8fr);
    /* start, not stretch: the viewport must hug the artwork's height so the
       camera-anchored avatar stays in proportion to the scene */
    align-items: start;
  }
}

/* ---------- Order Room preview panel ---------- */

.room-preview {
  display: none; /* revealed on wide screens; narrow screens open the room directly */
}

@media (min-width: 1200px) {
  .room-preview {
    display: flex;
    flex-direction: column;
    padding: 1.75rem;
    background: linear-gradient(180deg, var(--fc-page-black) 0%, var(--fc-black) 100%);
    border: 1px solid var(--fc-border);
    border-top: 2px solid var(--fc-shadow-green); /* signal rail, matching the room wall */
    border-radius: var(--radius-lg);
  }
}

.room-preview__eyebrow {
  color: var(--fc-signal);
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.25em;
  margin: 0 0 1rem;
}
.room-preview__eyebrow span { color: var(--fc-gray-700); }

.room-preview__title {
  font-size: 1.6rem;
  font-weight: 700;
}

.room-preview__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  list-style: none;
  margin: 0.9rem 0 0;
  padding: 0;
}
.room-preview__tags li {
  background: var(--fc-card-black);
  border: 1px solid var(--fc-border);
  border-radius: 999px;
  color: var(--fc-body-gray);
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 0.25rem 0.8rem;
}

.room-preview__scene {
  display: block;
  width: 100%;
  height: auto;
  margin-top: 1.25rem;
  border: 1px solid var(--fc-border);
  border-radius: var(--radius-md);
}

.room-preview__desc {
  margin: 1.25rem 0 0;
  font-size: 0.9375rem;
}

.room-preview__actions {
  margin-top: auto;
  padding-top: 1.5rem;
}

/* The camera: wraps the scrolling viewport. The avatar anchors here, so
   scrolling the world can never carry him off-screen. */
.district__frame {
  position: relative;
  min-width: 0; /* grid item — let the viewport inside shrink and scroll */
}

/* Mouse presence lights the street's border — the same signal ring the
   keyboard focus shows. Applied via the frame so hovering the overlay
   arrows or the scrollbar keeps it lit. */
.district__frame:hover .district__viewport {
  outline: 2px solid var(--fc-signal);
  outline-offset: 2px;
}

/* The viewport is the only horizontally scrollable element on the page. */
.district__viewport {
  position: relative;
  overflow-x: auto;
  overflow-y: hidden;
  border: 1px solid var(--fc-border);
  border-radius: var(--radius-lg);
  background:
    linear-gradient(180deg, var(--fc-black) 0%, var(--fc-page-black) 55%, var(--fc-card-black) 100%);
  scrollbar-color: var(--fc-gray-800) var(--fc-black);
}

/* ---------- Cinematic stage: rendered art + interactive hotspots ---------- */

.stage {
  position: relative;
  /* Scale with the column (still pannable), never beyond native art size —
     in the split view this frames the whole street like the mockup. */
  width: clamp(1536px, 180%, 2000px); /* ten-building street pans left-right */
  margin: 0 auto;
}

.stage__art {
  display: block;
  width: 100%;
  height: auto;
  /* Subtle lift so every department name reads while keeping the
     premium dark atmosphere; active building pops via its neon overlay. */
  filter: brightness(1.13) contrast(1.02);
}

/* Invisible storefront buttons positioned over the art (percent-based,
   so they track the image at any scale). */
.hotspot {
  position: absolute;
  z-index: 2; /* below the walking-figure layer, so glow never covers him */
  padding: 0;
  background: transparent;
  border: 2px solid transparent;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
}

/* Green light-up: a screen-blended glow that brightens the artwork
   itself, so the building appears lit rather than outlined. */
.hotspot::before {
  content: "";
  position: absolute;
  inset: -6%;
  border-radius: inherit;
  background: radial-gradient(ellipse at 50% 42%,
    rgba(148, 245, 17, 0.30) 0%,
    rgba(110, 221, 3, 0.12) 55%,
    transparent 78%);
  mix-blend-mode: screen;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

/* Hover / keyboard focus: highlight the building's outer edges only */
.hotspot:hover,
.hotspot:focus-visible {
  border-color: var(--fc-signal);
  box-shadow: 0 0 18px rgba(148, 245, 17, 0.35);
}

/* Selected building: edges plus interior light-up */
.hotspot.is-active,
.hotspot.is-lit {
  border-color: var(--fc-signal);
  box-shadow:
    0 0 22px rgba(148, 245, 17, 0.28),
    inset 0 0 34px rgba(148, 245, 17, 0.08); /* medium glow: selected only */
}

/* Selected building keeps its light, breathing slowly */
.hotspot.is-active::before,
.hotspot.is-lit::before {
  opacity: 1;
  animation: hotspot-breathe 3.2s ease-in-out infinite;
}

@keyframes hotspot-breathe {
  0%, 100% { opacity: 1; }
  50%      { opacity: 0.65; }
}

/* No HTML name plates — the artwork carries its own painted signage.
   Building names live in the hotspots' aria-labels. */

/* Filtered-out storefronts recede behind a dark veil */
.hotspot.is-dimmed {
  background: rgba(0, 0, 0, 0.6);
  border-color: transparent;
  box-shadow: none;
}
.hotspot.is-dimmed:hover,
.hotspot.is-dimmed:focus-visible {
  background: rgba(0, 0, 0, 0.25);
  border-color: var(--fc-signal);
}

/* ---------- Live avatar layer ---------- */
/* Anchored to the viewport (the camera), not the stage (the world):
   the street scrolls behind him while his walk cycle plays — the classic
   side-scroller rig. The canvas shows the current motion clip with its
   flat gray studio background keyed out in real time. */
.avatar {
  position: absolute;
  left: 4.5%;    /* left of frame — classic side-scroller framing */
  bottom: 12%;   /* feet on the sidewalk, in front of the storefronts */
  height: 18.9%; /* human scale against these storefront doors (bumped ~11%) */
  aspect-ratio: 9 / 16;
  z-index: 6;
  pointer-events: none;
}

.avatar canvas {
  display: block;
  width: 100%;
  height: 100%;
}

/* Contact shadow + faint green ground reflection, per the compositing
   notes in the avatar reference sheet */
.avatar::after {
  content: "";
  position: absolute;
  left: 6%;
  right: 6%;
  bottom: -2.5%;
  height: 6%;
  background:
    radial-gradient(ellipse at center, rgba(0, 0, 0, 0.55) 0%, transparent 68%);
}

/* Motion-source videos stay loaded and playable but out of sight */
.avatar-src {
  position: absolute;
  width: 2px;
  height: 2px;
  opacity: 0.01;
  pointer-events: none;
}

/* ---------- Camera-fixed street arrows ---------- */

.stage-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 7;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}
.stage-nav--left  { left: 0.6rem; }
.stage-nav--right { right: 0.6rem; }

.stage-arrow {
  width: 2.5rem;
  height: 2.5rem;
  background: rgba(0, 0, 0, 0.72);
  border: 1px solid var(--fc-border);
  border-radius: var(--radius-sm);
  color: var(--fc-white);
  font-size: 1.35rem;
  line-height: 1;
  cursor: pointer;
  transition: border-color 0.15s ease, color 0.15s ease;
}
.stage-arrow:hover,
.stage-arrow:focus-visible {
  border-color: var(--fc-signal);
  color: var(--fc-signal);
}

/* ---------- Custom street scrollbar ---------- */
/* Replaces the native bar so its end arrows can jump to the street's
   ends. Overlays the dark road at the bottom of the frame. */

.district__viewport { scrollbar-width: none; }
.district__viewport::-webkit-scrollbar { display: none; }

.street-scroll {
  position: absolute;
  left: 0.6rem;
  right: 0.6rem;
  bottom: 8px;
  height: 16px;
  z-index: 7;
  display: flex;
  align-items: center;
  gap: 8px;
}

.street-scroll__btn {
  flex: 0 0 auto;
  width: 24px;
  height: 16px;
  padding: 0;
  background: rgba(0, 0, 0, 0.72);
  border: 1px solid var(--fc-border);
  border-radius: 3px;
  color: var(--fc-white);
  font-size: 13px;
  line-height: 1;
  cursor: pointer;
  transition: border-color 0.15s ease, color 0.15s ease;
}
.street-scroll__btn:hover,
.street-scroll__btn:focus-visible {
  border-color: var(--fc-signal);
  color: var(--fc-signal);
}

.street-scroll__track {
  position: relative;
  flex: 1 1 auto;
  height: 8px;
  background: rgba(0, 0, 0, 0.55);
  border: 1px solid rgba(42, 45, 42, 0.85);
  border-radius: 4px;
}

.street-scroll__thumb {
  position: absolute;
  top: 0;
  height: 6px;
  min-width: 24px;
  background: var(--fc-gray-800);
  border: 1px solid var(--fc-gray-600);
  border-radius: 3px;
  cursor: grab;
  transition: background-color 0.15s ease, border-color 0.15s ease;
}
.street-scroll__thumb:hover,
.street-scroll__thumb:focus-visible {
  background: var(--fc-shadow-green);
  border-color: var(--fc-signal);
}
.street-scroll__thumb:active { cursor: grabbing; }

/* ---------- Quick-access strip (non-game navigation) ---------- */

/* Matches the approved bar: compact name boxes in one row, descriptions
   as plain captions beneath each box. */
.service-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 0.75rem 0.5rem;
  margin-top: 1rem;
}

.service-bar__item {
  flex: 1 1 0;
  min-width: 6.75rem;
  max-width: 11rem; /* wrapped rows keep compact boxes, like the mock */
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.55rem;
  text-align: center;
}
.service-bar__item--all,
.service-bar__item--reset { flex: 0 0 auto; min-width: 0; }

.service-bar__btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 3.1rem; /* room for two text rows — no overflow past the border */
  background: var(--fc-black);
  border: 1px solid var(--fc-border);
  border-radius: var(--radius-sm);
  color: var(--fc-white);
  font-family: var(--fc-font);
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  line-height: 1.35;
  text-align: center;
  padding: 0.45rem 0.6rem;
  cursor: pointer;
  transition: border-color 0.15s ease, color 0.15s ease;
}
.service-bar__btn:hover,
.service-bar__btn:focus-visible { border-color: var(--fc-gray-600); }
.service-bar__btn.is-active {
  border-color: var(--fc-signal);
  color: var(--fc-signal);
}

.service-bar__ico { margin-right: 0.4rem; }

.service-bar__btn--icon {
  width: 2.6rem;
  font-size: 0.9rem;
  padding: 0.55rem 0;
}

.service-bar__sub {
  color: var(--fc-muted);
  font-size: 0.72rem;
  line-height: 1.4;
  max-width: 9.5rem;
}

/* ---------- Build Archive strip (below the stage) ---------- */

.archive-title {
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--fc-gray-500);
  margin: 2rem 0 1rem;
}
.archive-title__sub { color: var(--fc-muted); font-weight: 500; }

/* ---------- Building row ---------- */

.building-row {
  display: flex;
  align-items: stretch;
  gap: 1.25rem;
  list-style: none;
  margin: 0;
  padding: 0 0 0.75rem;
  overflow-x: auto;
  scrollbar-color: var(--fc-gray-800) var(--fc-black);
}

.building-row > li { display: flex; flex: 0 0 auto; }

/* A building is a semantic button styled as architecture. */
.building {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  text-align: left;
  width: 240px;
  min-height: 220px;
  padding: 1.25rem;
  background:
    /* window grid */
    repeating-linear-gradient(90deg,
      transparent 0 18px, rgba(42, 45, 42, 0.55) 18px 20px),
    repeating-linear-gradient(0deg,
      transparent 0 26px, rgba(42, 45, 42, 0.55) 26px 28px),
    linear-gradient(180deg, var(--fc-raised) 0%, var(--fc-card-black) 70%, var(--fc-black) 100%);
  border: 1px solid var(--fc-border);
  border-radius: var(--radius-md) var(--radius-md) 0 0;
  color: var(--fc-body-gray);
  font-family: var(--fc-font);
  cursor: pointer;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease, opacity 0.2s ease;
}

.building:hover,
.building:focus-visible {
  border-color: var(--fc-signal);
  box-shadow: 0 0 18px rgba(148, 245, 17, 0.22); /* medium glow: featured/interactive only */
  transform: translateY(-4px);
}

/* Rooftop signal bar — lights up on hover/active */
.building__roof {
  align-self: flex-start;
  width: 2.5rem;
  height: 3px;
  background: var(--fc-shadow-green);
  border-radius: 2px;
  margin-bottom: auto;
  transition: background-color 0.2s ease, box-shadow 0.2s ease;
}
.building:hover .building__roof,
.building:focus-visible .building__roof,
.building.is-active .building__roof {
  background: var(--fc-signal);
  box-shadow: 0 0 8px rgba(148, 245, 17, 0.6);
}

.building__label {
  color: var(--fc-muted);
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  margin: 1.5rem 0 0.35rem;
}

.building__title {
  color: var(--fc-white);
  font-size: 1.2rem;
  font-weight: 700;
  line-height: 1.25;
}

.building__tags {
  color: var(--fc-gray-500);
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  margin-top: 0.35rem;
}

.building__cta {
  margin-top: 1rem;
  color: var(--fc-signal);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  opacity: 0;
  transition: opacity 0.2s ease;
}
.building:hover .building__cta,
.building:focus-visible .building__cta { opacity: 1; }

/* Selected project keeps its neon edge (2px = active state, per brand rule) */
.building.is-active {
  border: 2px solid var(--fc-signal);
}

/* Category buildings: shorter, quieter structures that filter the district */
.building--category {
  width: 190px;
  min-height: 210px;
  background:
    repeating-linear-gradient(0deg,
      transparent 0 22px, rgba(42, 45, 42, 0.45) 22px 24px),
    linear-gradient(180deg, var(--fc-gray-900) 0%, var(--fc-card-black) 80%);
}
.building--category .building__title {
  font-size: 0.95rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.building--category[aria-pressed="true"] {
  border-color: var(--fc-signal);
}
.building--category[aria-pressed="true"] .building__roof {
  background: var(--fc-signal);
}

/* Filtered-out buildings stay visible but recede. */
.building.is-dimmed {
  opacity: 0.3;
}
.building.is-dimmed:hover,
.building.is-dimmed:focus-visible {
  opacity: 0.75;
}

.district__hint {
  color: var(--fc-muted);
  font-size: 0.8125rem;
  margin: 0.75rem 0 0;
}

/* ---------- Project Room ---------- */

.project-room {
  padding: 2rem clamp(1rem, 4vw, 3rem) 3rem;
}

.project-room__topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 2rem;
}

.project-room__eyebrow {
  color: var(--fc-muted);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.25em;
  margin: 0;
}

.project-room__header { max-width: 46rem; }

.project-room__title {
  font-size: clamp(1.75rem, 4vw, 2.75rem);
  font-weight: 700;
}

.project-room__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  list-style: none;
  margin: 1rem 0 0;
  padding: 0;
}
.project-room__tags li {
  background: var(--fc-card-black);
  border: 1px solid var(--fc-border);
  border-radius: 999px;
  color: var(--fc-body-gray);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 0.3rem 0.9rem;
}

.project-room__desc {
  margin: 1.25rem 0 0;
  font-size: 1.0625rem;
}

/* Cinematic room view (art from the approved mockups, when available) */
.project-room__scene {
  display: block;
  width: 100%;
  max-width: 560px;
  height: auto;
  margin-top: 2rem;
  border: 1px solid var(--fc-border);
  border-radius: var(--radius-lg);
}

/* Room panel wall */
.project-room__panels {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.25rem;
  margin-top: 2.5rem;
  padding: 2rem;
  background:
    linear-gradient(180deg, var(--fc-page-black) 0%, var(--fc-black) 100%);
  border: 1px solid var(--fc-border);
  border-radius: var(--radius-lg);
  border-top: 2px solid var(--fc-shadow-green); /* signal rail across the room wall */
}

.room-panel {
  background: var(--fc-card-black);
  border: 1px solid var(--fc-border);
  border-radius: var(--radius-md);
  padding: 1.25rem;
}

.room-panel__label {
  color: var(--fc-muted);
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  margin: 0 0 0.9rem;
}

/* Placeholder frame for future real assets */
.room-panel__frame {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 170px;
  background:
    repeating-linear-gradient(45deg,
      transparent 0 14px, rgba(42, 45, 42, 0.4) 14px 15px),
    var(--fc-raised);
  border: 1px dashed var(--fc-border);
  border-radius: var(--radius-sm);
  color: var(--fc-gray-500);
  font-size: 0.8125rem;
  letter-spacing: 0.06em;
  text-align: center;
  padding: 1rem;
}

.room-panel__note {
  color: var(--fc-muted);
  font-size: 0.8125rem;
  margin: 0.9rem 0 0;
}

/* Color palette swatches */
.room-panel__swatches {
  display: flex;
  gap: 0.6rem;
  margin-top: 0.25rem;
}
.swatch {
  width: 3rem;
  height: 3rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--fc-border);
}

/* Before / after cleanup list */
.cleanup-list {
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: 0.875rem;
}
.cleanup-list li {
  display: flex;
  gap: 0.6rem;
  padding: 0.45rem 0;
  border-bottom: 1px solid var(--fc-border);
}
.cleanup-list li:last-child { border-bottom: 0; }
.cleanup-list .mark {
  flex: 0 0 auto;
  font-weight: 700;
}
.cleanup-list .mark--before { color: var(--fc-gray-600); }
.cleanup-list .mark--after  { color: var(--fc-green); }

/* ---------- Closing CTA ---------- */

/* Conversion band: a designed full-width panel, not copy floating in
   empty black. Two columns on desktop, stacked on mobile. */
.work-cta {
  padding: 2.25rem clamp(1rem, 4vw, 3rem) 2.5rem;
}

.work-cta__band {
  position: relative;
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 2.5rem;
  align-items: center;
  padding: 2.2rem 2.5rem;
  background: linear-gradient(180deg, var(--fc-raised) 0%, var(--fc-card-black) 100%);
  border: 1px solid var(--fc-border);
  border-radius: 12px;
  overflow: hidden;
}

/* thin neon accent along the top edge — the band's one signal detail */
.work-cta__band::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--fc-signal), rgba(148, 245, 17, 0.12));
}

.work-cta__title {
  margin: 0;
  font-size: clamp(1.4rem, 3vw, 2rem);
}

.work-cta__body {
  margin: 0.85rem 0 0;
  max-width: 34rem;
}

.work-cta__actions {
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
  justify-self: end;
  width: 100%;
  max-width: 16.5rem;
}

.work-cta__actions .btn { text-align: center; justify-content: center; }

.work-cta__micro {
  margin: 0.15rem 0 0;
  font-size: 0.75rem;
  color: var(--fc-muted);
  text-align: center;
}

/* ==========================================================================
   MOBILE — the district simplifies into swipeable project cards.
   Category buildings hide (chips cover filtering); decorative layers hide.
   ========================================================================== */

@media (max-width: 820px) {

  .district__controls { display: none; }

  /* Mobile skips the cinematic stage entirely — cards only. */
  .district__viewport { display: none; }

  .building-row {
    align-items: stretch;
    gap: 1rem;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 0.75rem;
  }

  .building-row > li {
    flex: 0 0 85%;
    max-width: 320px;
    scroll-snap-align: start;
  }

  li:has(> .building--category) { display: none; }

  .building {
    width: 100%;
    min-height: 200px;
    border-radius: var(--radius-md);
    transform: none;
  }
  .building:hover,
  .building:focus-visible { transform: none; }

  .building__cta { opacity: 1; } /* no hover on touch — always show the action */

  .district__hint {
    font-size: 0.75rem;
  }

  .project-room__panels {
    padding: 1.25rem;
    grid-template-columns: 1fr;
  }
}

/* Fallback for browsers without :has() — hide category buildings via class */
@media (max-width: 820px) {
  .building-item--category { display: none; }
}

/* ==========================================================================
   REDUCED MOTION
   ========================================================================== */

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .building:hover,
  .building:focus-visible { transform: none; }
}

/* ==========================================================================
   MODALS — intro modal + project overlay
   ========================================================================== */

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

body.has-dialog { overflow: hidden; }

.modal {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.25rem;
}

.modal[hidden] { display: none; }

.modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(2px);
}

.modal__panel {
  position: relative;
  z-index: 1;
  width: min(34rem, 100%);
  max-height: calc(100vh - 3rem);
  overflow-y: auto;
  background: var(--fc-card-black);
  border: 1px solid var(--fc-border);
  border-radius: 12px;
  padding: 2rem;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.7);
}

.modal__panel--wide { width: min(52rem, 100%); }

.modal__title {
  margin: 0.5rem 0 0.75rem;
  font-size: clamp(1.35rem, 3vw, 1.75rem);
  font-weight: 700;
  color: var(--fc-white);
  letter-spacing: -0.01em;
}

.modal__body {
  margin: 0 0 1.25rem;
  color: var(--fc-body-gray);
  line-height: 1.6;
}

.modal__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.modal__close {
  position: absolute;
  top: 0.9rem;
  right: 0.9rem;
  width: 2.5rem;
  height: 2.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  line-height: 1;
  color: var(--fc-body-gray);
  background: var(--fc-raised);
  border: 1px solid var(--fc-border);
  border-radius: 8px;
  cursor: pointer;
}

.modal__close:hover,
.modal__close:focus-visible {
  color: var(--fc-signal);
  border-color: var(--fc-signal);
}

.modal__scene {
  display: block;
  width: 100%;
  border-radius: 8px;
  border: 1px solid var(--fc-border);
  margin: 0 0 1rem;
}

/* The FUBAR ads are vertical (9:16) — cap the player's height and
   center it instead of letting a portrait video fill the wide panel. */
.modal__video {
  display: block;
  max-width: 100%;
  max-height: min(62vh, 34rem);
  margin: 0.5rem auto 1rem;
  border-radius: 8px;
  border: 1px solid var(--fc-border);
  background: var(--fc-black);
}

.modal__video[hidden] { display: none; }

.overlay-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 0 0 0.25rem;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.overlay-meta__dept { color: var(--fc-signal); }

.overlay-meta__type,
.overlay-meta__ba {
  color: var(--fc-muted);
  border: 1px solid var(--fc-border);
  border-radius: 4px;
  padding: 0.1rem 0.45rem;
}

/* Captioned work gallery inside the project overlay (real client builds) */
.overlay-gallery {
  list-style: none;
  margin: 0.25rem 0 0.5rem;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr));
  gap: 1rem;
}

.overlay-gallery[hidden] { display: none; }

.overlay-gallery__item {
  display: flex;
  flex-direction: column;
  background: var(--fc-raised);
  border: 1px solid var(--fc-border);
  border-radius: 8px;
  overflow: hidden;
}

.overlay-gallery__item img {
  display: block;
  width: 100%;
  height: 11rem;
  object-fit: contain;
  background: var(--fc-white);
  padding: 0.5rem;
  box-sizing: border-box;
}

/* Reversed (white/gold on transparent) art needs a dark ground to read */
.overlay-gallery__item--dark img { background: #171412; }

/* Photography and screenshots fill their frame edge to edge */
.overlay-gallery__item--photo img {
  object-fit: cover;
  padding: 0;
  background: var(--fc-black);
}

/* Portrait pieces (documents, flyers) get a taller frame to stay legible */
.overlay-gallery__item--tall img { height: 22rem; }

.overlay-gallery__caption {
  padding: 0.55rem 0.75rem 0.65rem;
  font-size: 0.75rem;
  line-height: 1.4;
  color: var(--fc-muted);
  border-top: 1px solid var(--fc-border);
}

/* ==========================================================================
   DEPARTMENT ROOM — interior, clickable objects, empty state
   ========================================================================== */

.room-interior {
  position: relative;
  margin: 1.5rem 0;
  min-height: 22rem;
  aspect-ratio: 16 / 9;      /* matches the generated room art */
  max-height: 36rem;
  border: 1px solid var(--fc-border);
  border-radius: 12px;
  overflow: hidden;
  /* Stand-in interior until assets/img/rooms/<slug>.jpg exists:
     dark walls, a green signal wash, and a receding floor. */
  background:
    linear-gradient(180deg, rgba(148, 245, 17, 0.05) 0%, rgba(10, 11, 10, 0) 30%),
    linear-gradient(180deg, var(--fc-raised) 0%, var(--fc-card-black) 58%, #0D0F0D 58%, #090B09 100%);
}

.room-interior::before {
  /* floor line where wall meets ground */
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 58%;
  height: 1px;
  background: var(--fc-border);
}

.room-interior__bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Once real art is behind them, the interactive cards need contrast:
   a soft bottom scrim sits over the image, under the objects. */
.room-interior::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0) 55%, rgba(0, 0, 0, 0.55) 100%);
  pointer-events: none;
}

.room-interior__objects {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem;
  align-items: flex-end;
  justify-content: center;
  padding: 2.5rem 1.5rem 2.25rem;
}

.room-interior__objects[hidden] { display: none; }

.room-object {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.6rem;
  width: min(13rem, 42vw);
  padding: 1.1rem 1rem 0.9rem;
  background: rgba(18, 20, 18, 0.88);
  border: 1px solid var(--fc-border);
  border-radius: 8px;
  color: var(--fc-body-gray);
  font: inherit;
  cursor: pointer;
  transition: transform 160ms ease, border-color 160ms ease, box-shadow 160ms ease;
}

.room-object:hover,
.room-object:focus-visible {
  transform: translateY(-4px);
  border-color: var(--fc-signal);
  box-shadow: 0 0 0 1px var(--fc-signal), 0 12px 34px rgba(148, 245, 17, 0.12);
}

.room-object__icon {
  width: 3.2rem;
  height: 2.2rem;
  border: 1px solid var(--fc-green-dark);
  border-radius: 4px;
  background:
    linear-gradient(135deg, rgba(148, 245, 17, 0.16), rgba(148, 245, 17, 0.02));
}

.room-object__label {
  font-weight: 600;
  color: var(--fc-white);
  font-size: 0.95rem;
  text-align: center;
}

.room-object__tip {
  font-size: 0.78rem;
  color: var(--fc-muted);
  text-align: center;
}

.room-object:hover .room-object__tip,
.room-object:focus-visible .room-object__tip { color: var(--fc-signal); }

.room-empty {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2rem 1.5rem;
  text-align: center;
  /* readable over the room art without hiding it */
  background: rgba(5, 6, 5, 0.6);
  backdrop-filter: blur(2px);
}

.room-empty[hidden] { display: none; }

.room-empty .room-empty__body { max-width: 30rem; }

.room-empty__title {
  margin: 0 0 0.6rem;
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--fc-white);
}

.room-empty__body {
  margin: 0;
  color: var(--fc-body-gray);
  line-height: 1.6;
}

/* ==========================================================================
   VIEW ALL PROJECTS — fallback grid
   ========================================================================== */

.projects-grid {
  max-width: 72rem;
  margin: 0 auto;
  padding: 1.5rem 1.5rem 4rem;
}

.projects-grid__title {
  margin: 1rem 0 1.25rem;
  font-size: clamp(1.5rem, 3.5vw, 2rem);
  font-weight: 700;
  color: var(--fc-white);
}

.projects-grid__tools {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
}

.projects-grid__filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.projects-grid__search { flex: 1 1 14rem; max-width: 20rem; }

.projects-grid__search input {
  width: 100%;
  padding: 0.55rem 0.9rem;
  font: inherit;
  font-size: 0.9rem;
  color: var(--fc-white);
  background: var(--fc-raised);
  border: 1px solid var(--fc-border);
  border-radius: 8px;
}

.projects-grid__search input:focus-visible {
  outline: 2px solid var(--fc-signal);
  outline-offset: 1px;
}

.projects-grid__cards {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(17rem, 1fr));
  gap: 1.25rem;
}

.grid-card {
  display: flex;
  flex-direction: column;
  background: var(--fc-card-black);
  border: 1px solid var(--fc-border);
  border-radius: 12px;
  overflow: hidden;
  transition: border-color 160ms ease, transform 160ms ease;
}

.grid-card:hover { border-color: var(--fc-gray-600); transform: translateY(-3px); }

.grid-card__thumb {
  aspect-ratio: 16 / 9;
  display: flex;
  align-items: center;
  justify-content: center;
  background:
    linear-gradient(135deg, rgba(148, 245, 17, 0.06), rgba(10, 11, 10, 0)),
    var(--fc-raised);
  border-bottom: 1px solid var(--fc-border);
}

.grid-card__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.grid-card__thumb-mark {
  font-weight: 700;
  letter-spacing: 0.28em;
  color: var(--fc-gray-700);
}

.grid-card__body {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  padding: 1.1rem 1.2rem 1.3rem;
  flex: 1;
}

.grid-card__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin: 0;
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.grid-card__dept { color: var(--fc-signal); }

.grid-card__type,
.grid-card__ba {
  color: var(--fc-muted);
  border: 1px solid var(--fc-border);
  border-radius: 4px;
  padding: 0.08rem 0.4rem;
}

.grid-card__title {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--fc-white);
}

.grid-card__desc {
  margin: 0;
  font-size: 0.88rem;
  line-height: 1.55;
  color: var(--fc-body-gray);
  flex: 1;
}

.grid-card__open { align-self: flex-start; margin-top: 0.35rem; }

.grid-empty {
  max-width: 30rem;
  margin: 2rem auto;
  padding: 3rem 1.5rem;
  text-align: center;
  border: 1px dashed var(--fc-border);
  border-radius: 12px;
}

.grid-empty .grid-empty__cta { margin-top: 1.25rem; display: inline-block; }

/* Room footer holds three actions on wide screens; let them wrap cleanly */
.project-room__footer { flex-wrap: wrap; gap: 0.75rem; }

/* Department rooms leave the legacy panel container empty — collapse it */
.project-room__panels:empty { display: none; }

@media (max-width: 820px) {
  /* Flex items refuse to shrink below their content unless told —
     without min-width:0 a wide gallery pushes the panel past the phone. */
  .modal__panel { padding: 1.4rem; min-width: 0; max-width: 100%; }
  .modal__video, .modal__scene { max-width: 100%; }
  .overlay-gallery { grid-template-columns: 1fr; }
  .room-interior__objects {
    /* In flow on phones (not absolute): the interior grows with its
       stacked objects instead of clipping them. */
    position: static;
    min-height: 16rem;
    padding: 1.5rem 1rem 2rem;
  }
  /* The 16:9 ratio forces width = ratio x min-height (455px) on a 375px
     phone — drop the ratio and let the room size to its content. */
  .room-interior { min-height: 16rem; aspect-ratio: auto; }
  .room-object { width: 100%; max-width: 20rem; }
  .projects-grid { padding: 1rem 1rem 3rem; }

  /* The stage is hidden on small screens — its camera chrome (custom
     scrollbar, arrow stacks) must go with it or it overflows the page. */
  .district__frame { display: none; }
}

/* ==========================================================================
   SHOWROOM POLISH PASS — layout, active-building panel, progress row,
   utility row, transitions, modal upgrades, mobile directory
   ========================================================================== */

/* The preview aside is gone — the district frame runs full width. */
.district__layout { display: block; }

/* --- Active-building panel (bottom-right of the frame; the character
       keeps to the left, so nothing important is covered) --- */
.building-panel {
  position: absolute;
  right: 4.25rem;             /* clear of the right arrow stack */
  bottom: 2.4rem;
  z-index: 7;
  width: min(19rem, 44%);
  padding: 1rem 1.1rem 1.05rem;
  background: rgba(10, 11, 10, 0.82);
  border: 1px solid var(--fc-border);
  border-radius: 8px;
  backdrop-filter: blur(6px);
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.55);
}

.building-panel[hidden] { display: none; }

.building-panel__name {
  margin: 0 0 0.3rem;
  font-size: 1rem;
  font-weight: 700;
  color: var(--fc-white);
  letter-spacing: 0.01em;
}

/* // as a tight, intentional accent bound to the department name — sits
   directly before the name, reads as one unit, never floats away. */
.ttl-slash {
  color: var(--fc-white);
  font-weight: 700;
  margin-right: 0.22em;
  letter-spacing: 0;
}

.building-panel__desc {
  margin: 0 0 0.75rem;
  font-size: 0.8rem;
  line-height: 1.5;
  color: var(--fc-body-gray);
}

.building-panel__actions {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.building-panel__btn { padding: 0.45rem 0.95rem; font-size: 0.78rem; }

.building-panel__link {
  background: none;
  border: none;
  padding: 0;
  font: inherit;
  font-size: 0.75rem;
  color: var(--fc-muted);
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
}

.building-panel__link:hover,
.building-panel__link:focus-visible { color: var(--fc-signal); }

/* --- District progress: counter + twelve clickable segments --- */
.district-progress {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-top: 0.8rem;
}

.district-progress__label {
  flex: 0 0 auto;
  min-width: 13rem;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--fc-muted);
  white-space: pre;
}

.district-progress__bar {
  flex: 1;
  display: flex;
  gap: 4px;
}

.district-progress__seg {
  flex: 1;
  height: 6px;
  padding: 0;
  border: none;
  border-radius: 3px;
  background: var(--fc-border);
  cursor: pointer;
  transition: background 160ms ease, transform 160ms ease;
}

.district-progress__seg:hover { background: var(--fc-gray-600); transform: scaleY(1.5); }

.district-progress__seg.is-active {
  background: var(--fc-signal);
  box-shadow: 0 0 8px rgba(148, 245, 17, 0.5);
}

/* --- Compact utility row (desktop) --- */
.district-utility {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.4rem;
}

/* --- Hotspots as lit directory signs: a "View Room" plate appears on
       hover/focus at the base of the building --- */
.hotspot::after {
  content: "View Room";
  position: absolute;
  left: 50%;
  bottom: -2.1rem;
  transform: translateX(-50%) translateY(-4px);
  padding: 0.28rem 0.7rem;
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  white-space: nowrap;
  color: var(--fc-black);
  background: var(--fc-signal);
  border-radius: 4px;
  box-shadow: 0 6px 18px rgba(148, 245, 17, 0.35);
  opacity: 0;
  pointer-events: none;
  transition: opacity 160ms ease, transform 160ms ease;
}

.hotspot:hover::after,
.hotspot:focus-visible::after {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* --- Room objects: explicit "View Project" affordance on hover --- */
.room-object::before {
  content: "View Project \2192";
  order: 4;
  margin-top: 0.15rem;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--fc-signal);
  opacity: 0;
  transition: opacity 160ms ease;
}

.room-object:hover::before,
.room-object:focus-visible::before { opacity: 1; }

/* --- Project modal: purpose line + conversion footer --- */
.modal__purpose {
  margin: -0.5rem 0 1.1rem;
  padding-left: 0.85rem;
  border-left: 2px solid var(--fc-signal);
  font-size: 0.85rem;
  line-height: 1.55;
  color: var(--fc-muted);
}

.modal__purpose[hidden] { display: none; }

.modal__actions--footer {
  margin-top: 1.4rem;
  padding-top: 1.2rem;
  border-top: 1px solid var(--fc-border);
}

/* --- Room-entry transition: dark sweep + one neon scan line --- */
.room-transition {
  position: fixed;
  inset: 0;
  z-index: 55;                /* above content, below dialogs */
  background: rgba(0, 0, 0, 0);
  pointer-events: none;
}

.room-transition[hidden] { display: none; }

.room-transition.is-on {
  animation: rt-dim 720ms ease both;
}

.room-transition.is-on::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 2px;
  background: var(--fc-signal);
  box-shadow: 0 0 18px 2px rgba(148, 245, 17, 0.65);
  animation: rt-scan 720ms cubic-bezier(0.65, 0, 0.35, 1) both;
}

@keyframes rt-dim {
  0%   { background: rgba(0, 0, 0, 0); }
  40%  { background: rgba(0, 0, 0, 0.82); }
  60%  { background: rgba(0, 0, 0, 0.82); }
  100% { background: rgba(0, 0, 0, 0); }
}

@keyframes rt-scan {
  0%   { top: 0; opacity: 0; }
  15%  { opacity: 1; }
  85%  { opacity: 1; }
  100% { top: 100%; opacity: 0; }
}

/* --- Department directory: hidden on desktop (the buildings ARE the
       navigation); a tappable card grid on mobile --- */
@media (min-width: 821px) {
  .service-bar { display: none; }
}

@media (max-width: 820px) {
  .district-progress,
  .building-panel,
  .district__hint { display: none; }

  .district-utility { margin-top: 0.5rem; }

  .service-bar {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.7rem;
    margin-top: 1.2rem;
  }

  .service-bar__item { width: 100%; }

  .service-bar__item--all { grid-column: 1 / -1; }

  .service-bar__btn {
    width: 100%;
    min-height: 3.2rem;
    font-size: 0.85rem;
  }
  /* Mobile department card: name + a clear View Room action cue */
  .service-bar__btn--dept {
    flex-direction: column;
    gap: 0.3rem;
    padding: 0.7rem 0.6rem;
  }
  .service-bar__name { display: block; }
  .service-bar__viewroom {
    display: block;
    font-size: 0.62rem;
    letter-spacing: 0.14em;
    color: var(--fc-signal);
  }
}

/* ==========================================================================
   BOTTOM-OF-PAGE TIGHTENING — control footer, conversion band, footer
   ========================================================================== */

/* District control footer: attached to the showroom, not drifting below it */
.district-progress { margin-top: 0.6rem; }

.district__hint { margin: 0.55rem 0 0; }

.district-utility {
  margin-top: 0.9rem;
  padding-top: 0.9rem;
  border-top: 1px solid var(--fc-border);
}

/* --- Order Rooms plate: mounted sign inside the street scene that
       covers the artwork's outdated baked-in title block --- */
.stage__plate {
  position: absolute;
  left: 1.6%;
  top: 4.5%;
  width: 20%;
  min-width: 210px;
  max-width: 290px;
  padding: 0.8rem 1rem 0.9rem;
  z-index: 2;
  background: rgba(5, 7, 5, 0.96);
  border: 1px solid var(--fc-border);
  border-left: 2px solid var(--fc-signal);
  border-radius: 8px;
  backdrop-filter: blur(6px);
  pointer-events: none;
}

.stage__plate-label {
  margin: 0 0 0.3rem;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.22em;
  color: var(--fc-signal);
}

.stage__plate-title {
  margin: 0 0 0.4rem;
  font-size: clamp(1.1rem, 1.5vw, 1.5rem);
  font-weight: 700;
  color: var(--fc-white);
  letter-spacing: -0.01em;
}

.stage__plate-copy {
  margin: 0;
  font-size: 0.76rem;
  line-height: 1.45;
  color: var(--fc-body-gray);
}

/* Conversion band responsive behavior */
@media (max-width: 900px) {
  .work-cta__band {
    grid-template-columns: 1fr;
    gap: 1.5rem;
    padding: 1.8rem 1.5rem;
  }
  .work-cta__actions {
    justify-self: stretch;
    max-width: none;
  }
}

@media (max-width: 820px) {
  .work-cta { padding: 1.75rem 1rem 2rem; }
  .district-utility .btn { flex: 1 1 100%; text-align: center; }
}

/* ---------- Play gate (lazy-init) ---------- */

.game-gate {
  max-width: 660px;
  margin: 0 auto;
  padding: clamp(2.25rem, 5vw, 3.75rem) clamp(1rem, 4vw, 3rem);
  text-align: center;
}
.game-gate h1 {
  font-size: clamp(2rem, 4.4vw, 3.15rem);
  font-weight: 700;
  letter-spacing: -0.01em;
  margin: 0 0 0.85rem;
}
.game-gate p {
  margin: 0 0 1.35rem;
  font-size: 1.0625rem;
}
.game-gate .btn { margin: 0 0.4rem; }
