:root {
  --black: #0a0a0c;
  --black-soft: #111214;
  --cobalt-start: #3b4ff0;
  --cobalt-end: #0a0a0c;
  --silver: #b8b8b8;
  --silver-dim: #6f6f6f;
  --silver-bright: #e6e6e6;
  --ease-signature: cubic-bezier(0.16, 1, 0.3, 1);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  height: 100%;
  background: var(--black);
  color: var(--silver);
  font-family: "Helvetica Neue", Arial, sans-serif;
  overflow-x: hidden;
}

.stage {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

/* signature gradient bars, echoing the logo */
.bar {
  position: fixed;
  top: 0;
  width: 6px;
  height: 100vh;
  background: linear-gradient(to bottom, var(--cobalt-start), var(--cobalt-end));
  opacity: 0.55;
  transition: opacity 1.4s var(--ease-signature);
  z-index: 1;
}
.bar-left { left: 4%; }
.bar-right { right: 4%; }
.stage[data-unfolded="true"] .bar { opacity: 1; }

/* nav */
.nav {
  position: fixed;
  top: 32px;
  right: 6%;
  display: flex;
  gap: 28px;
  opacity: 0;
  transform: translateY(-8px);
  transition: opacity 1s var(--ease-signature) 0.4s, transform 1s var(--ease-signature) 0.4s;
  z-index: 3;
}

/* Mobile nav + back-link fix (site-wide): keeps the top nav from colliding
   with each chamber's "Back to the Studio" link on narrow screens.
   !important on back-link only because each chamber page still carries its
   own local .back-link rule that would otherwise win the cascade. */
@media (max-width: 600px) {
  .nav { top: 24px !important; gap: 8px !important; }
  .nav .nav-link { font-size: 9px !important; }
  .back-link { top: 74px !important; font-size: 10px !important; }
}
@media (max-width: 640px) {
  .nav { gap: 14px; top: 22px; }
  .nav-link { font-size: 10px !important; }
}
.stage[data-unfolded="true"] .nav {
  opacity: 1;
  transform: translateY(0);
}
.nav-link {
  color: var(--silver);
  text-decoration: none;
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  padding-bottom: 4px;
  border-bottom: 1px solid transparent;
  transition: color 0.4s ease, border-color 0.4s ease;
}
.nav-link:hover,
.nav-link[data-active="true"] {
  color: var(--silver-bright);
  border-bottom: 1px solid var(--cobalt-start);
}

/* seed: the logo itself, still and small, then it unfolds into full presence */
.seed {
  position: relative;
  width: min(70vw, 420px);
  z-index: 2;
  display: flex;
  justify-content: center;
  max-height: 0;
  overflow: hidden;
  transition: max-height 1.8s var(--ease-signature);
}
.stage[data-unfolded="true"] .seed {
  max-height: 500px;
}
.logo-mark {
  width: 55%;
  opacity: 0;
  filter: brightness(0.85);
  transform: scale(0.85);
  transition: opacity 1.8s var(--ease-signature),
              transform 1.8s var(--ease-signature),
              filter 1.8s var(--ease-signature),
              width 1.8s var(--ease-signature);
}
.stage[data-unfolded="true"] .logo-mark {
  width: 100%;
  opacity: 1;
  filter: brightness(1);
  transform: scale(1);
}

/* wordmark block */
.wordmark-block {
  position: relative;
  z-index: 2;
  text-align: center;
  margin-top: 32px;
}
.eyebrow {
  font-size: 11px;
  letter-spacing: 0.35em;
  text-transform: uppercase;
  color: var(--silver-dim);
  margin: 0 0 18px;
  opacity: 0;
  transition: opacity 1.2s ease 0.8s;
}
.stage[data-unfolded="true"] .eyebrow { opacity: 1; }

.welcome-line {
  font-size: 11px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--silver-dim);
  margin: 0 0 16px;
}

.thesis {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
  font-size: clamp(28px, 4vw, 46px);
  letter-spacing: 0.04em;
  color: var(--silver-bright);
  margin: 0;
  opacity: 0.85;
}

.tagline {
  font-size: 15px;
  letter-spacing: 0.01em;
  color: var(--silver-dim);
  margin: 14px auto 0;
  max-width: 480px;
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 1s var(--ease-signature) 0.6s, transform 1s var(--ease-signature) 0.6s;
}
.stage[data-unfolded="true"] .tagline {
  opacity: 0.85;
  transform: translateY(0);
}

/* orbiting doorways */
.doorways {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: min(90vw, 640px);
  height: 100%;
  list-style: none;
  margin: 0;
  padding: 0;
  pointer-events: none;
  z-index: 2;
}
.doorways li {
  position: absolute;
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--silver);
  opacity: 0;
  transition: opacity 1.4s ease;
  animation: drift 14s ease-in-out infinite;
}
.stage[data-unfolded="true"] .doorways li { opacity: 0.85; }

.doorways li:nth-child(1) { top: 20%; left: 4%;  animation-delay: 0s; }
.doorways li:nth-child(2) { top: 28%; right: 2%; animation-delay: -3s; }
.doorways li:nth-child(3) { bottom: 30%; left: 0%;  animation-delay: -6s; }
.doorways li:nth-child(4) { bottom: 22%; right: 6%; animation-delay: -9s; }
.doorways li:nth-child(5) { top: 50%; left: -4%; animation-delay: -11s; }

@keyframes drift {
  0%, 100% { transform: translate(0, 0); }
  50% { transform: translate(6px, -10px); }
}

/* the first cue: a real, obvious click target */
.cue {
  position: absolute;
  bottom: 64px;
  left: 50%;
  transform: translateX(-50%);
  background: none;
  border: 1px solid var(--silver-dim);
  border-radius: 999px;
  cursor: pointer;
  padding: 14px 28px;
  display: flex;
  align-items: center;
  gap: 10px;
  z-index: 3;
  transition: opacity 0.8s ease, border-color 0.3s ease, background 0.3s ease;
}
.cue:hover {
  border-color: var(--cobalt-start);
  background: rgba(59, 79, 240, 0.08);
}
.cue-dot {
  display: block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--silver-bright);
  animation: pulse 4s ease-in-out infinite;
}
.cue-label {
  font-size: 11px;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--silver-bright);
}
.stage[data-unfolded="true"] .cue {
  opacity: 0;
  pointer-events: none;
}

@keyframes pulse {
  0%, 100% { opacity: 0.35; transform: scale(1); }
  50% { opacity: 1; transform: scale(1.4); }
}

/* accessibility: visible focus states matching the brand */
a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--cobalt-start);
  outline-offset: 4px;
}

/* respect reduced motion: graceful static alternative */
@media (prefers-reduced-motion: reduce) {
  .logo-mark,
  .eyebrow,
  .tagline,
  .nav,
  .bar,
  .cue {
    transition-duration: 0.3s !important;
    animation: none !important;
  }
  .doorways li {
    animation: none !important;
  }
}

@media (max-width: 640px) {
  .doorways {
    position: static;
    left: auto;
    transform: none;
    width: 100%;
    height: auto;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 14px 20px;
    margin-top: 28px;
    padding: 0 24px;
  }
  .doorways li {
    position: static;
    animation: none;
  }
  .bar { width: 4px; }
  .thesis { font-size: 24px; }
  .tagline { font-size: 13px; padding: 0 16px; }
}
