/* The black opening holds at GO. The project field enters only on activation. */
.opening-intro {
  --opening-width: min(2000px, calc(100vw - 96px));
  --opening-mark: clamp(256px, 28vw, 416px);
  --opening-heading: min(clamp(104px, 14.4vw, 224px), calc((100svh - 250px) / 2.79));
  --opening-gap: clamp(28px, 4vw, 64px);
  --go-width: clamp(240px, 23vw, 360px);
  --go-height: clamp(100px, 10vw, 144px);
  --opening-line: .93;
  --opening-ease: cubic-bezier(.22, 1, .36, 1);
  position: fixed;
  inset: 0;
  z-index: 160;
  overflow: hidden;
  background: #000;
  color: #fff;
  opacity: 1;
  transform: scale(1);
  transform-origin: center;
  outline: none;
}
.opening-words { position: absolute; inset: 0; display: grid; place-items: center; }
.opening-words > span {
  grid-area: 1 / 1;
  font-family: var(--display-font);
  font-size: clamp(96px, 14.5vw, 208px);
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: -.04em;
  line-height: .9;
  opacity: 0;
  transition: opacity 280ms ease;
}
.opening-intro[data-phase='ready'] [data-word='ready'],
.opening-intro[data-phase='one'] [data-word='one'],
.opening-intro[data-phase='two'] [data-word='two'] { opacity: 1; }
.opening-brand { position: absolute; inset: 0; pointer-events: none; }
.opening-mark {
  position: absolute;
  left: 50%;
  top: 50%;
  width: var(--opening-mark);
  height: auto;
  transform: translate(-50%, -50%);
  filter: invert(1);
  mix-blend-mode: screen;
  opacity: 0;
  transition: opacity 650ms ease, transform 2s var(--opening-ease);
}
.opening-intro:is([data-phase='logo'], [data-phase='shift'], [data-phase='brand'], [data-phase='go'], [data-phase='enter']) .opening-mark { opacity: 1; }
.opening-intro:is([data-phase='shift'], [data-phase='brand'], [data-phase='go'], [data-phase='enter']) .opening-mark {
  transform: translate(-50%, -50%) translateX(calc((var(--opening-mark) - var(--opening-width)) / 2));
}
.opening-copy {
  position: absolute;
  left: calc(50% - var(--opening-width) / 2 + var(--opening-mark) + var(--opening-gap));
  top: 50%;
  width: calc(var(--opening-width) - var(--opening-mark) - var(--opening-gap));
  transform: translateY(-50%);
  opacity: 0;
  transition: opacity 700ms ease;
}
.opening-copy h2 {
  margin: 0;
  font-family: var(--display-font);
  font-size: calc(var(--opening-heading) * .85);
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: -.04em;
  line-height: var(--opening-line);
}
.opening-copy h2 span { display: block; }
.opening-copy p { max-width: 64ch; margin: 28px 0 0; font-size: clamp(17px, 1.65vw, 24px); font-weight: 500; line-height: 1.4; color: #c8c8c8; text-wrap: balance; }
.opening-intro:is([data-phase='brand'], [data-phase='go'], [data-phase='enter']) .opening-copy { opacity: 1; }
.opening-intro[data-phase='go'] :is(.opening-mark, .opening-copy) { transition-duration: 300ms; }
.opening-action {
  position: absolute;
  right: 0;
  top: calc(var(--opening-heading) * .85 * var(--opening-line) * 2);
  height: calc(var(--opening-heading) * .85 * var(--opening-line));
  display: flex;
  align-items: center;
}
.opening-go {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
  width: var(--go-width);
  height: var(--go-height);
  padding: 16px 24px;
  border: 2px solid #fff;
  border-radius: 4px;
  background: #fff;
  color: #000;
  font-family: var(--display-font);
  font-size: clamp(44px, 4.5vw, 64px);
  font-weight: 900;
  line-height: 1;
  letter-spacing: -.04em;
  text-transform: uppercase;
  pointer-events: auto;
  transition: background 180ms ease, color 180ms ease;
}
.opening-go-label { display: block; }
.opening-go-arrow { width: 48px; height: 48px; flex: 0 0 auto; }
.opening-go::after { content: ''; position: absolute; inset: -2px; border: 2px solid #fff; border-radius: 4px; opacity: 0; pointer-events: none; }
.opening-intro[data-phase='go'] .opening-go { animation: go-arrive 420ms ease both, go-breathe 2000ms ease-in-out 500ms infinite; }
.opening-intro[data-phase='go'] .opening-go-label { animation: go-label 2000ms ease-in-out 500ms infinite; }
.opening-intro[data-phase='go'] .opening-go-arrow { animation: go-arrow 1600ms cubic-bezier(.4,0,.2,1) 500ms infinite; }
.opening-intro[data-phase='go'] .opening-go::after { animation: go-ring 2000ms ease-out 500ms infinite; }
.opening-go:hover { animation: none !important; background: #000; color: #fff; }
.opening-go:hover :is(.opening-go-label, .opening-go-arrow), .opening-go:hover::after { animation: none !important; }
.opening-go:focus-visible { outline: 2px solid #fff; outline-offset: 7px; }
.opening-go:disabled { opacity: 1; cursor: default; }
.opening-paused :is(.opening-go, .opening-go-label, .opening-go-arrow), .opening-paused .opening-go::after { animation-play-state: paused !important; }
@keyframes go-arrive { from { opacity: 0; } to { opacity: 1; } }
@keyframes go-breathe { 0%, 100% { background-color: #fff; } 50% { background-color: #cfcfcf; } }
@keyframes go-label { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.1); } }
@keyframes go-arrow { 0%, 100% { transform: translateX(-4px); } 50% { transform: translateX(10px); } }
@keyframes go-ring { 0% { transform: scale(1); opacity: .65; } 75%, 100% { transform: scale(1.12,1.2); opacity: 0; } }
.opening-intro[data-phase='enter'] {
  opacity: 0;
  transform: scale(2);
  pointer-events: none;
  transition: opacity 450ms ease, transform 1100ms var(--opening-ease);
  will-change: opacity, transform;
}
.opening-skip {
  position: absolute;
  bottom: 25px;
  right: var(--edge);
  border: 0;
  padding: 12px 0 12px 16px;
  min-height: 44px;
  background: transparent;
  color: #9c9c9c;
  font-size: 13px;
  line-height: 1.3;
  text-decoration: underline;
  text-underline-offset: 5px;
  text-decoration-color: #555;
  transition: color 180ms ease;
}
.opening-skip:hover { color: #fff; }
.opening-skip:focus-visible { outline: 2px solid #fff; outline-offset: 6px; color: #fff; }
#site-content[inert] .cover-visual { animation-play-state: paused; }
.entry-staged #project-plane { transform: scale(.55); opacity: .2; transform-origin: center; }
.entry-staged.entry-revealing #project-plane {
  transform: scale(1);
  opacity: 1;
  transition: transform 2000ms cubic-bezier(.4, 0, .2, 1), opacity 1600ms ease;
  will-change: transform, opacity;
}
@media (max-width: 1100px) {
  .opening-intro {
    --opening-line: .96;
    --opening-width: calc(100vw - 48px);
    --opening-mark-height: calc(var(--opening-mark) * 225 / 255);
    --opening-heading: min(clamp(104px, 14.4vw, 224px), calc((100svh - var(--opening-mark-height) - 260px) / 2.88));
    --opening-copy-height: calc(var(--opening-heading) * 2.448 + 165px);
  }
  .opening-intro:is([data-phase='shift'], [data-phase='brand'], [data-phase='go'], [data-phase='enter']) .opening-mark {
    transform: translate(-50%, -50%) translateX(calc((var(--opening-mark) - var(--opening-width)) / 2)) translateY(calc((var(--opening-copy-height) + 24px) / -2));
  }
  .opening-copy {
    left: 24px;
    width: var(--opening-width);
    top: calc(50% + (var(--opening-mark-height) + 24px - var(--opening-copy-height)) / 2);
    transform: none;
  }

}
@media (max-width: 600px) {
  .opening-intro {
    --opening-width: calc(100vw - 40px);
    --opening-mark: clamp(128px, 36vw, 180px);
    --opening-heading: min(clamp(72px, 20vw, 116px), calc((100vw - 40px) / 4.1), calc((100svh - var(--opening-mark-height) - 260px) / 2.88));
    --opening-gap: 18px;
    --go-width: clamp(100px, 36vw, 180px);
    --go-height: max(56px, calc(var(--opening-heading) * .85 * .9));
  }
  .opening-copy { left: 20px; }
  .opening-words > span { font-size: clamp(62px, 17.5vw, 106px); }

  .opening-copy p { font-size: 15px; line-height: 1.45; margin-top: 21px; }

  .opening-go { gap: 10px; font-size: 30px; padding: 8px 12px; }
  .opening-go-arrow { width: 24px; height: 24px; }
  .opening-skip { right: 24px; bottom: 18px; }
}
/* Short landscape screens keep the enlarged mark beside the title. */
@media (max-width: 1100px) and (max-height: 650px) and (min-aspect-ratio: 4/3) {
  .opening-intro {
    --opening-mark: min(clamp(256px, 28vw, 416px), 50svh);
    --opening-heading: min(clamp(104px, 14.4vw, 224px), calc((100svh - 204px) / 2.88), calc((var(--opening-width) - var(--opening-mark) - var(--opening-gap)) / 4.1));
  }
  .opening-intro:is([data-phase='shift'], [data-phase='brand'], [data-phase='go'], [data-phase='enter']) .opening-mark {
    transform: translate(-50%, -50%) translateX(calc((var(--opening-mark) - var(--opening-width)) / 2)) translateY(-35px);
  }
  .opening-intro { --go-width: clamp(140px, 23vw, 240px); --go-height: max(48px, calc(var(--opening-heading) * .85 * .86)); }
  .opening-go { gap: 12px; font-size: clamp(28px, 4vw, 42px); padding: 6px 14px; }
  .opening-go-arrow { width: 28px; height: 28px; }
  .opening-copy {
    left: calc(50% - var(--opening-width) / 2 + var(--opening-mark) + var(--opening-gap));
    width: calc(var(--opening-width) - var(--opening-mark) - var(--opening-gap));
    top: calc(50% - 35px);
    transform: translateY(-50%);
  }
}
@media (prefers-reduced-motion: reduce) {
  .opening-intro, .opening-intro *, .entry-staged #project-plane { transition: none; }
}
html[data-motion='reduce'] .opening-intro, html[data-motion='reduce'] .opening-intro *, html[data-motion='reduce'] .entry-staged #project-plane { transition: none; }
