/* ==========================================================================
   MT. WIZARD STUDIOS — THE FREEPLAY CABINET
   The stylesheet for /freeplaycabinet/ only. Tokens first, then layout
   top-to-bottom of the page. It lives at the site root so its asset urls
   (below) stay relative to /assets/.

   The other branches have their own stylesheets and do not share this one:
     style.css      — the studio hub at /
     reliquary.css  — /analog-reliquary/
     operator.css   — /operator-required/
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. DESIGN TOKENS
   -------------------------------------------------------------------------- */
:root {
  /* Ink & surfaces */
  --ink: #050505;
  --panel: #0d0b14;
  --panel-deep: #080711;
  --panel-lit: #14101f;

  /* Brand color (from the seal, poster, and cartridge art) */
  --cream: #f5ead0;
  --cream-dim: rgba(245, 234, 208, 0.68);
  --cream-faint: rgba(245, 234, 208, 0.42);
  --orange: #f4a12f;
  --orange-bright: #ffb948;
  --orange-deep: #b86f14;
  --blue: #3a6fb5;
  --violet: #7b2fd0;
  --magenta: #d64fa8;
  --mint: #7de8a7;

  /* Lines & borders */
  --line: rgba(245, 234, 208, 0.16);
  --line-strong: rgba(245, 234, 208, 0.3);
  --border-w: 2px;
  --radius: 3px;

  /* Glow strength */
  --glow-orange: 0 0 10px rgba(244, 161, 47, 0.4), 0 0 22px rgba(160, 48, 220, 0.22);
  --glow-soft: 0 0 18px rgba(244, 161, 47, 0.14);
  --shadow-panel: 0 6px 30px rgba(0, 0, 0, 0.55);
  --shadow-chunk: 4px 4px 0 rgba(0, 0, 0, 0.6);

  /* Type */
  --font-pixel: "Press Start 2P", "Courier New", Courier, monospace;
  --font-mono: ui-monospace, "Cascadia Mono", Consolas, "Courier New", monospace;

  /* Spacing scale */
  --sp-1: 6px;
  --sp-2: 12px;
  --sp-3: 20px;
  --sp-4: 32px;
  --sp-5: 52px;
  --sp-6: 84px;

  /* Motion */
  --t-fast: 140ms ease-out;
  --t-slow: 9s ease-in-out;

  /* Layout */
  --site-w: 1080px;
}

/* --------------------------------------------------------------------------
   2. BASE
   -------------------------------------------------------------------------- */
* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  overflow-x: clip;
}

body {
  min-height: 100vh;
  margin: 0;
  overflow-x: clip;
  color: var(--cream);
  background: var(--ink);
  font-family: var(--font-mono);
  font-size: 16px;
  line-height: 1.6;
}

img {
  max-width: 100%;
  height: auto;
}

/* The hidden attribute must always win over author display rules. */
[hidden] {
  display: none !important;
}

/* Ghost of the studio seal on the back wall of the room */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image:
    linear-gradient(rgba(5, 5, 8, 0.82), rgba(5, 5, 8, 0.92)),
    url("assets/mw-seal.jpg.jpeg");
  background-position: center 10%;
  background-repeat: no-repeat;
  background-size: min(150vmin, 1100px) auto;
  z-index: -2;
}

/* Faint stage lighting */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  background:
    radial-gradient(circle at 18% 0%, rgba(58, 111, 181, 0.14), transparent 42%),
    radial-gradient(circle at 85% 100%, rgba(123, 47, 208, 0.14), transparent 44%),
    radial-gradient(circle at 50% 108%, rgba(214, 79, 168, 0.08), transparent 40%);
  pointer-events: none;
  z-index: -1;
}

/* --------------------------------------------------------------------------
   3. SHARED PIECES
   -------------------------------------------------------------------------- */
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  top: -60px;
  left: var(--sp-3);
  z-index: 20;
  padding: 10px 16px;
  background: var(--orange);
  color: #1a0e02;
  font-family: var(--font-pixel);
  font-size: 0.6rem;
  text-decoration: none;
  border: var(--border-w) solid var(--cream);
  transition: top var(--t-fast);
}

.skip-link:focus-visible {
  top: var(--sp-2);
}

/* Small stamped machine label, e.g. CARTRIDGE BAY */
.panel-label {
  margin: 0;
  font-family: var(--font-pixel);
  font-size: 0.5rem;
  letter-spacing: 0.22em;
  color: var(--cream-faint);
}

/* Status chip, e.g. RELEASED */
.chip {
  display: inline-block;
  padding: 6px 10px 5px;
  font-family: var(--font-pixel);
  font-size: 0.55rem;
  letter-spacing: 0.1em;
  border: var(--border-w) solid var(--line-strong);
  border-radius: var(--radius);
  color: var(--cream-dim);
}

.chip--released {
  background: var(--orange);
  border-color: var(--orange-bright);
  color: #201102;
}

.chip--vacant {
  background: transparent;
  border-color: var(--line);
  color: var(--cream-faint);
}

/* Square pixel LED */
.led {
  display: inline-block;
  width: 8px;
  height: 8px;
  margin-right: 2px;
  background: var(--mint);
  box-shadow: 0 0 6px rgba(125, 232, 167, 0.8);
  animation: led-breathe 3.4s ease-in-out infinite;
}

@keyframes led-breathe {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.68; }
}

/* Bordered pixel link used on panels */
.panel-link {
  display: inline-block;
  padding: 12px 16px 11px;
  font-family: var(--font-pixel);
  font-size: 0.58rem;
  letter-spacing: 0.12em;
  color: var(--orange);
  text-decoration: none;
  border: var(--border-w) solid var(--line);
  border-radius: var(--radius);
  background: var(--panel-deep);
  transition: border-color var(--t-fast), color var(--t-fast), background var(--t-fast);
}

.panel-link:hover {
  color: var(--orange-bright);
  border-color: var(--orange);
  background: var(--panel-lit);
}

/* Focus */
:focus-visible {
  outline: 2px solid var(--orange-bright);
  outline-offset: 3px;
}

/* --------------------------------------------------------------------------
   4. SERVICE STRIP
   -------------------------------------------------------------------------- */
.service-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px 20px;
  padding: 12px clamp(16px, 3vw, 32px);
  border-bottom: var(--border-w) solid var(--line);
  background: rgba(8, 7, 17, 0.82);
  font-family: var(--font-pixel);
  font-size: 0.5rem;
  letter-spacing: 0.16em;
}

.service-strip p {
  margin: 0;
}

.service-strip__id {
  color: var(--cream-dim);
}

.service-strip__status {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 6px 10px;
  color: var(--cream-faint);
}

.service-strip__status .led + span {
  color: var(--mint);
}

.service-strip__sep {
  color: var(--cream-faint);
}

/* Back to the studio hub. Reads as the strip's own text until it is used.
   The padding is what makes an 8px pixel-font line a tappable target. */
.service-strip__home,
.footer__home {
  display: inline-block;
  padding: 8px 0;
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color var(--t-fast), border-color var(--t-fast);
}

.service-strip__home:hover,
.service-strip__home:focus-visible,
.footer__home:hover,
.footer__home:focus-visible {
  color: var(--orange);
  border-bottom-color: var(--orange);
}

/* --------------------------------------------------------------------------
   5. MARQUEE
   -------------------------------------------------------------------------- */
.marquee {
  padding: clamp(28px, 5vh, 56px) var(--sp-3) var(--sp-4);
  display: flex;
  justify-content: center;
}

.marquee__panel {
  position: relative;
  width: min(var(--site-w), 100%);
  padding: clamp(28px, 4.5vw, 54px) var(--sp-3) clamp(26px, 4vw, 46px);
  text-align: center;
  border: var(--border-w) solid var(--line-strong);
  border-radius: var(--radius);
  background:
    radial-gradient(ellipse 90% 130% at 50% -30%, rgba(244, 161, 47, 0.16), transparent 60%),
    radial-gradient(ellipse 70% 100% at 50% 115%, rgba(123, 47, 208, 0.14), transparent 62%),
    linear-gradient(180deg, #100d1c 0%, var(--panel-deep) 100%);
  box-shadow: var(--shadow-panel), var(--glow-soft);
  overflow: hidden;
  animation: marquee-backlight var(--t-slow) infinite;
}

/* Scanlines across the lit marquee glass */
.marquee__panel::after {
  content: "";
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    0deg,
    rgba(255, 255, 255, 0.025) 0 1px,
    transparent 1px 3px
  );
  pointer-events: none;
}

@keyframes marquee-backlight {
  0%, 100% { box-shadow: var(--shadow-panel), 0 0 18px rgba(244, 161, 47, 0.14); }
  50% { box-shadow: var(--shadow-panel), 0 0 26px rgba(244, 161, 47, 0.24); }
}

.marquee__wordmark {
  display: block;
  width: 224px;
  margin: 0 auto var(--sp-3);
  image-rendering: pixelated;
  image-rendering: crisp-edges;
  filter: drop-shadow(0 0 10px rgba(245, 234, 208, 0.28));
}

.marquee__title {
  margin: 0 0 var(--sp-3);
  font-family: var(--font-pixel);
  font-weight: 400;
  font-size: clamp(1.3rem, 4.2vw, 2.5rem);
  line-height: 1.45;
  letter-spacing: 0.06em;
  color: var(--orange);
  text-shadow:
    0 0 12px rgba(244, 161, 47, 0.5),
    0 0 30px rgba(160, 48, 220, 0.3),
    3px 3px 0 rgba(0, 0, 0, 0.85);
}

.marquee__tagline {
  margin: 0;
  font-family: var(--font-pixel);
  font-size: clamp(0.5rem, 1.4vw, 0.7rem);
  letter-spacing: 0.3em;
  line-height: 2;
  color: var(--cream-dim);
}

/* --------------------------------------------------------------------------
   6. CABINET DECK
   -------------------------------------------------------------------------- */
.deck {
  padding: var(--sp-2) var(--sp-3) var(--sp-5);
  display: flex;
  justify-content: center;
}

.deck__frame {
  width: min(var(--site-w), 100%);
  padding: clamp(20px, 3.4vw, 40px);
  border: var(--border-w) solid var(--line-strong);
  border-radius: var(--radius);
  background: linear-gradient(180deg, var(--panel) 0%, var(--panel-deep) 100%);
  box-shadow: var(--shadow-panel);
}

.deck__grid {
  display: grid;
  grid-template-columns: minmax(280px, 360px) 1fr;
  gap: clamp(24px, 4vw, 48px);
  align-items: start;
}

.deck__grid > * {
  min-width: 0;
}

/* --- Cartridge bay ------------------------------------------------------- */
.bay {
  margin: 0;
}

.bay__label {
  margin-bottom: var(--sp-2);
}

.bay__window {
  position: relative;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  border: var(--border-w) solid var(--line);
  border-radius: var(--radius);
  background:
    radial-gradient(ellipse 120% 90% at 50% 0%, rgba(58, 111, 181, 0.1), transparent 55%),
    linear-gradient(180deg, #0a0913 0%, #06050c 100%);
  box-shadow:
    inset 0 0 34px rgba(0, 0, 0, 0.9),
    inset 0 2px 0 rgba(245, 234, 208, 0.06);
}

/* Scanlines on the bay glass */
.bay__window::after {
  content: "";
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    0deg,
    rgba(255, 255, 255, 0.02) 0 1px,
    transparent 1px 3px
  );
  pointer-events: none;
}

/* The cartridge PNG carries large transparent margins; oversize and
   re-center it so the visible cartridge fills the window. */
.bay__cart {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 132%;
  max-width: none;
  transform: translate(-51.5%, -43.6%);
  image-rendering: pixelated;
  image-rendering: crisp-edges;
  filter:
    drop-shadow(0 0 16px rgba(0, 0, 0, 0.9))
    drop-shadow(0 0 26px rgba(244, 161, 47, 0.16));
}

/* Vacant slot view */
.bay__vacant {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--sp-3);
  padding: var(--sp-3);
  text-align: center;
}

.bay__socket {
  width: 68%;
  height: 30px;
  border: var(--border-w) solid rgba(245, 234, 208, 0.22);
  border-radius: var(--radius);
  background:
    repeating-linear-gradient(
      90deg,
      rgba(245, 234, 208, 0.14) 0 6px,
      transparent 6px 12px
    ),
    linear-gradient(180deg, #030308 0%, #0b0a14 100%);
  box-shadow:
    inset 0 4px 10px rgba(0, 0, 0, 0.95),
    0 1px 0 rgba(245, 234, 208, 0.08);
}

.bay__vacant-title {
  margin: 0;
  font-family: var(--font-pixel);
  font-size: 0.72rem;
  line-height: 1.9;
  letter-spacing: 0.14em;
  color: var(--cream-dim);
}

.bay__vacant-sub {
  margin: 0;
  font-family: var(--font-pixel);
  font-size: 0.5rem;
  letter-spacing: 0.26em;
  color: var(--cream-faint);
}

/* --- Catalog readout ----------------------------------------------------- */
.readout__label {
  margin-bottom: var(--sp-3);
}

.readout__catalog {
  margin: 0 0 var(--sp-2);
  font-family: var(--font-pixel);
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  color: var(--orange);
}

.readout__title {
  margin: 0 0 var(--sp-3);
  font-family: var(--font-pixel);
  font-weight: 400;
  font-size: clamp(1.35rem, 3vw, 1.9rem);
  line-height: 1.35;
  letter-spacing: 0.04em;
  color: var(--cream);
  text-shadow:
    0 0 14px rgba(245, 234, 208, 0.22),
    3px 3px 0 rgba(0, 0, 0, 0.8);
}

.readout__status {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px 14px;
  margin: 0 0 var(--sp-3);
}

.readout__meta {
  font-family: var(--font-pixel);
  font-size: 0.55rem;
  letter-spacing: 0.16em;
  color: var(--cream-dim);
}

.readout__tagline {
  margin: 0 0 var(--sp-2);
  font-family: var(--font-pixel);
  font-size: 0.62rem;
  line-height: 1.9;
  letter-spacing: 0.16em;
  color: var(--magenta);
  text-shadow: 0 0 12px rgba(214, 79, 168, 0.35);
}

.readout__desc {
  margin: 0 0 var(--sp-4);
  max-width: 46ch;
  font-size: 1rem;
  line-height: 1.65;
  color: var(--cream-dim);
}

.readout__action {
  border-top: var(--border-w) dashed var(--line);
  padding-top: var(--sp-3);
}

.play-button {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  padding: 20px 30px 18px;
  font-family: var(--font-pixel);
  font-size: clamp(0.72rem, 1.6vw, 0.9rem);
  letter-spacing: 0.08em;
  text-decoration: none;
  color: #201102;
  background: linear-gradient(180deg, var(--orange-bright) 0%, var(--orange) 55%, #e08d18 100%);
  border: var(--border-w) solid var(--orange-bright);
  border-radius: var(--radius);
  box-shadow: var(--shadow-chunk), var(--glow-orange);
  transition: transform var(--t-fast), box-shadow var(--t-fast), filter var(--t-fast);
}

.play-button__glyph {
  font-family: var(--font-mono);
  font-size: 0.85em;
}

.play-button:hover {
  filter: brightness(1.07);
  transform: translate(-1px, -1px);
  box-shadow: 5px 5px 0 rgba(0, 0, 0, 0.6), var(--glow-orange);
}

.play-button:active {
  transform: translate(2px, 2px);
  box-shadow: 1px 1px 0 rgba(0, 0, 0, 0.6), var(--glow-orange);
}

.play-button:focus-visible {
  outline: 3px solid var(--cream);
  outline-offset: 4px;
}

.play-note {
  margin: var(--sp-2) 0 0;
  font-family: var(--font-pixel);
  font-size: 0.5rem;
  letter-spacing: 0.14em;
  line-height: 1.9;
  color: var(--cream-faint);
}

.vacant-note {
  margin: 0;
  font-family: var(--font-pixel);
  font-size: 0.5rem;
  letter-spacing: 0.14em;
  line-height: 1.9;
  color: var(--cream-faint);
}

/* --- Slot selector ------------------------------------------------------- */
.selector {
  margin-top: clamp(24px, 3.4vw, 40px);
  border-top: var(--border-w) solid var(--line);
  padding-top: var(--sp-3);
}

.selector__label {
  margin-bottom: var(--sp-2);
}

.selector__row {
  display: flex;
  align-items: stretch;
  gap: clamp(10px, 1.6vw, 18px);
}

.selector__arrow {
  flex: 0 0 auto;
  width: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: var(--border-w) solid var(--line);
  border-radius: var(--radius);
  background: var(--panel-deep);
  cursor: pointer;
  transition: border-color var(--t-fast), background var(--t-fast);
}

.selector__arrow img {
  width: 30px;
  image-rendering: pixelated;
  image-rendering: crisp-edges;
}

.selector__arrow--right img {
  transform: scaleX(-1);
}

.selector__arrow:hover:not(:disabled) {
  border-color: var(--mint);
  background: var(--panel-lit);
}

.selector__arrow:disabled {
  opacity: 0.35;
  cursor: default;
}

.selector__rail {
  flex: 1 1 auto;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(10px, 1.6vw, 18px);
  margin: 0;
  padding: 0;
  list-style: none;
}

.selector__item {
  display: block;
  min-width: 0;
}

.slot {
  width: 100%;
  height: 100%;
  min-width: 0;
  display: grid;
  gap: 7px;
  justify-items: start;
  padding: 14px 16px 12px;
  text-align: left;
  border: var(--border-w) solid var(--line);
  border-radius: var(--radius);
  background: var(--panel-deep);
  color: var(--cream-dim);
  cursor: pointer;
  transition: border-color var(--t-fast), background var(--t-fast), transform var(--t-fast);
}

.slot:disabled {
  cursor: default;
}

.slot:hover:not(:disabled):not(.is-selected) {
  border-color: var(--line-strong);
  background: var(--panel-lit);
}

.slot__no {
  font-family: var(--font-pixel);
  font-size: 0.6rem;
  letter-spacing: 0.14em;
  color: var(--orange);
}

.slot__name {
  font-family: var(--font-pixel);
  font-size: 0.55rem;
  letter-spacing: 0.1em;
  line-height: 1.6;
  color: var(--cream);
}

.slot__state {
  font-family: var(--font-pixel);
  font-size: 0.5rem;
  letter-spacing: 0.2em;
  color: var(--cream-faint);
}

.slot__state--inbay {
  color: var(--mint);
}

.slot.is-selected {
  border-color: var(--orange);
  background: var(--panel-lit);
  box-shadow: 0 0 14px rgba(244, 161, 47, 0.18), inset 0 0 0 1px rgba(244, 161, 47, 0.28);
}

.slot--vacant .slot__no {
  color: var(--cream-faint);
}

.slot--vacant .slot__name {
  color: var(--cream-faint);
}

/* --------------------------------------------------------------------------
   7. STUDIO PANEL
   -------------------------------------------------------------------------- */
.studio {
  padding: 0 var(--sp-3) var(--sp-5);
  display: flex;
  justify-content: center;
}

.studio__grid {
  width: min(var(--site-w), 100%);
  display: grid;
  grid-template-columns: minmax(240px, 320px) 1fr;
  gap: clamp(28px, 5vw, 64px);
  align-items: center;
  padding: clamp(20px, 3.4vw, 40px);
  border: var(--border-w) solid var(--line);
  border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(13, 11, 20, 0.9) 0%, rgba(8, 7, 17, 0.9) 100%);
  box-shadow: var(--shadow-panel);
}

.studio__art {
  margin: 0;
}

.studio__art img {
  display: block;
  width: 100%;
  border: var(--border-w) solid var(--line);
  border-radius: var(--radius);
  filter: brightness(0.92) saturate(0.96);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
}

.studio__title {
  margin: var(--sp-2) 0 var(--sp-3);
  font-family: var(--font-pixel);
  font-weight: 400;
  font-size: clamp(0.95rem, 2.2vw, 1.35rem);
  line-height: 1.6;
  letter-spacing: 0.06em;
  color: var(--cream);
  text-shadow: 2px 2px 0 rgba(0, 0, 0, 0.8);
}

.studio__statement {
  margin: 0 0 var(--sp-4);
  max-width: 52ch;
  font-size: 1rem;
  line-height: 1.7;
  color: var(--cream-dim);
}

.studio__links {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-2);
}

/* --------------------------------------------------------------------------
   RELEASE CREDITS PAGE
   -------------------------------------------------------------------------- */
.credits {
  display: flex;
  justify-content: center;
  padding: var(--sp-2) var(--sp-3) var(--sp-5);
}

.credits__panel {
  width: min(780px, 100%);
  padding: clamp(24px, 4vw, 48px);
  border: var(--border-w) solid var(--line-strong);
  border-radius: var(--radius);
  background: linear-gradient(180deg, var(--panel) 0%, var(--panel-deep) 100%);
  box-shadow: var(--shadow-panel);
}

.credits__header {
  padding-bottom: var(--sp-4);
  border-bottom: var(--border-w) solid var(--line);
}

.credits__title {
  margin: var(--sp-2) 0 0;
  font-family: var(--font-pixel);
  font-weight: 400;
  font-size: clamp(0.95rem, 2.5vw, 1.35rem);
  line-height: 1.8;
  color: var(--cream);
  text-shadow: 2px 2px 0 rgba(0, 0, 0, 0.8);
}

.credits__entry {
  padding: var(--sp-4) 0;
}

.credits__entry p {
  max-width: 64ch;
  color: var(--cream-dim);
}

.credits__entry a:not(.panel-link) {
  color: var(--orange);
}

.credits__role {
  margin: 0 0 var(--sp-2);
  font-family: var(--font-pixel);
  font-size: 0.5rem;
  letter-spacing: 0.18em;
}

.credits__source {
  margin: 0 0 var(--sp-3);
  font-family: var(--font-pixel);
  font-weight: 400;
  font-size: clamp(0.75rem, 2vw, 1rem);
  line-height: 1.8;
  color: var(--orange);
}

.credits__links {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-2);
  margin-top: var(--sp-3);
}

.credits__note {
  margin: 0;
  padding-top: var(--sp-3);
  border-top: var(--border-w) dashed var(--line);
  font-size: 0.9rem;
  color: var(--cream-faint);
}

/* --------------------------------------------------------------------------
   7B. ANALOG RELIQUARY PORTAL
   The Signal Archive Seal is the doorway into the archive. Deliberately
   quiet: no banner, no caption, no neon. The mark is the invitation.
   Kept at or above 136px so the seal's ring text stays legible.
   -------------------------------------------------------------------------- */
.portal {
  display: flex;
  justify-content: center;
  padding: var(--sp-4) var(--sp-3) var(--sp-6);
}

.portal__seal {
  display: block;
  width: clamp(136px, 16vw, 168px);
  border-radius: 50%;
  filter: brightness(0.92);
  transition: filter var(--t-fast);
  /* Settles the seal off the poster ghost on the back wall so its ring
     text stays readable. Not a frame — it fades out before it is seen. */
  background: radial-gradient(
    circle,
    rgba(5, 5, 8, 0.92) 54%,
    rgba(5, 5, 8, 0) 74%
  );
}

.portal__seal img {
  display: block;
  width: 100%;
  height: auto;
}

.portal__seal:hover,
.portal__seal:focus-visible {
  filter: brightness(1.05) drop-shadow(0 0 9px rgba(217, 96, 31, 0.38));
}

.portal__seal:focus-visible {
  outline: var(--border-w) solid var(--orange);
  outline-offset: 6px;
}

@media (prefers-reduced-motion: reduce) {
  .portal__seal {
    transition: none;
  }
}

/* --------------------------------------------------------------------------
   8. FOOTER
   -------------------------------------------------------------------------- */
.footer {
  border-top: var(--border-w) solid var(--line);
  background: rgba(5, 5, 8, 0.92);
}

.footer__inner {
  max-width: var(--site-w);
  margin: 0 auto;
  padding: var(--sp-4) var(--sp-3) var(--sp-5);
  text-align: center;
}

.footer__id {
  margin: 0 0 var(--sp-2);
  font-family: var(--font-pixel);
  font-size: 0.52rem;
  letter-spacing: 0.2em;
  line-height: 1.9;
  color: var(--cream-faint);
}

.footer__social {
  display: flex;
  justify-content: center;
  gap: var(--sp-4);
  margin-bottom: var(--sp-3);
}

.footer__social a {
  /* A one-glyph link is an 11px tap target unless it is given a box. */
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 44px;
  font-family: var(--font-pixel);
  font-size: 0.62rem;
  letter-spacing: 0.12em;
  color: var(--orange);
  text-decoration: none;
  text-shadow: 0 0 10px rgba(244, 161, 47, 0.3);
  transition: color var(--t-fast);
}

.footer__social a:hover {
  color: var(--cream);
}

.footer__legal {
  margin: 0 auto;
  max-width: 72ch;
  font-size: 0.85rem;
  line-height: 1.7;
  color: var(--cream-faint);
}

/* --------------------------------------------------------------------------
   9. RESPONSIVE
   -------------------------------------------------------------------------- */
@media (max-width: 900px) {
  .deck__grid {
    grid-template-columns: 1fr;
  }

  .bay {
    width: min(340px, 100%);
    margin: 0 auto;
  }

  .bay__label {
    text-align: center;
  }

  .studio__grid {
    grid-template-columns: 1fr;
  }

  .studio__art {
    width: min(300px, 100%);
    margin: 0 auto;
  }

  .studio__text {
    text-align: center;
  }

  .studio__statement {
    margin-left: auto;
    margin-right: auto;
  }

  .studio__links {
    justify-content: center;
  }
}

@media (max-width: 700px) {
  .service-strip {
    justify-content: center;
    text-align: center;
  }

  .marquee {
    padding-top: var(--sp-3);
  }

  .marquee__wordmark {
    width: 176px;
  }

  .marquee__title {
    font-size: clamp(1.05rem, 5.6vw, 1.3rem);
    line-height: 1.55;
  }

  .marquee__tagline {
    letter-spacing: 0.14em;
  }

  .readout__desc {
    margin-bottom: var(--sp-3);
  }

  .play-button {
    width: 100%;
    justify-content: center;
    text-align: center;
  }

  /* On phones the selector recomposes into a vertical slot list; the
     arrows go away because every slot is directly tappable. */
  .selector__arrow {
    display: none;
  }

  .selector__rail {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .slot {
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 12px;
    padding: 13px 14px 12px;
  }

  .slot__no {
    font-size: 0.55rem;
  }

  .slot__name {
    font-size: 0.5rem;
  }

  .slot__state {
    justify-self: end;
  }

  .footer__social {
    gap: var(--sp-3);
  }
}

@media (max-width: 420px) {
  .bay__vacant-title {
    font-size: 0.6rem;
  }

  .readout__title {
    font-size: 1.2rem;
  }
}

/* --------------------------------------------------------------------------
   10. REDUCED MOTION
   -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  .led,
  .marquee__panel {
    animation: none;
  }

  .skip-link,
  .panel-link,
  .play-button,
  .selector__arrow,
  .slot,
  .footer__social a {
    transition: none;
  }

  .play-button:hover,
  .play-button:active {
    transform: none;
  }
}
