:root {
  --vv-petrol-950: #01090d;
  --vv-petrol-900: #021318;
  --vv-petrol-800: #06252c;
  --vv-cyan: #16d6dc;
  --vv-cyan-soft: rgba(73, 229, 232, .32);
}

html.vv-intro-active { overflow: hidden; }
.vv-intro[hidden] { display: none !important; }

.vv-intro {
  position: fixed;
  inset: 0;
  z-index: 2147483000;
  display: none;
  overflow: hidden;
  color: #fff;
  background:
    radial-gradient(ellipse 61% 12% at 55% 68%, rgba(6, 156, 176, .40), transparent 76%),
    radial-gradient(ellipse 50% 73% at 61% 28%, #074358 0%, #022738 37%, transparent 82%),
    linear-gradient(120deg, #021022, #051b2b 57%, #031124);
  isolation: isolate;
}

.vv-intro[data-state="playing"],
.vv-intro[data-state="leaving"] { display: block; }

.vv-intro::before,
.vv-intro::after {
  content: "";
  position: absolute;
  pointer-events: none;
}

.vv-intro::before {
  z-index: 7;
  inset: 0;
  box-shadow: inset 0 0 13vw rgba(0, 7, 19, .57), inset 0 -11vh 23vh rgba(0, 8, 18, .40);
}

.vv-intro::after {
  z-index: 6;
  inset: 0;
  opacity: .24;
  background: radial-gradient(ellipse at center, transparent 38%, rgba(0, 4, 6, .76) 100%);
}

.vv-intro__stage {
  position: absolute;
  inset: 0;
  overflow: hidden;
  perspective: 1000px;
  transform-style: preserve-3d;
}

.vv-intro__ambiente {
  position: absolute;
  z-index: 0;
  inset: 0;
  overflow: hidden;
  background:
    radial-gradient(ellipse 44% 7% at 50% 68%, rgba(54, 236, 238, .31) 0, rgba(16, 157, 168, .16) 32%, rgba(3, 58, 67, .06) 61%, transparent 100%),
    radial-gradient(ellipse 82% 25% at 50% 69%, rgba(4, 64, 74, .22), transparent 72%);
  opacity: 0;
  animation: vv-studio-awake 2s cubic-bezier(.22,.72,.18,1) both;
}

.vv-intro__ambiente::before,
.vv-intro__ambiente::after {
  content: "";
  position: absolute;
  top: 57%;
  bottom: -8%;
  width: 36vw;
  opacity: 0;
  filter: blur(10px);
  background: linear-gradient(156deg, transparent 0 45%, rgba(80, 226, 228, .055) 52%, rgba(28, 136, 147, .025) 66%, transparent 74%);
  animation: vv-edge-beam 2.4s .55s ease-out both;
}

.vv-intro__ambiente::before {
  left: -5vw;
  clip-path: polygon(0 0, 8% 0, 100% 100%, 82% 100%);
}

.vv-intro__ambiente::after {
  right: -5vw;
  clip-path: polygon(92% 0, 100% 0, 18% 100%, 0 100%);
  transform: scaleX(-1);
}

.vv-intro__piso {
  position: absolute;
  z-index: 1;
  /* Align the floor's lit edge with the sculpture and its canvas reflection. */
  top: 68%;
  left: 50%;
  width: min(146vw, 2100px);
  height: 57%;
  overflow: hidden;
  transform-origin: 50% 0;
  transform: translateX(-50%) perspective(720px) rotateX(62deg) scaleY(0);
  opacity: 0;
  clip-path: polygon(27% 0, 73% 0, 100% 100%, 0 100%);
  mask-image: linear-gradient(90deg, transparent 7%, #000 37% 63%, transparent 93%);
  background:
    radial-gradient(ellipse 28% 32% at 50% 0, rgba(67, 225, 228, .16), transparent 74%),
    linear-gradient(90deg, rgba(1, 12, 16, .94), rgba(7, 35, 41, .84) 34%, rgba(10, 44, 50, .76) 50%, rgba(7, 35, 41, .84) 66%, rgba(1, 12, 16, .94));
  box-shadow: inset 0 1px rgba(128, 249, 249, .48);
  will-change: transform, opacity, filter;
  animation: vv-floor-unfold 2s cubic-bezier(.15,.77,.21,1) both;
}

.vv-intro__piso::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(73deg, transparent 0 14.8%, rgba(83, 230, 232, .16) 15%, transparent 15.3%),
    linear-gradient(107deg, transparent 0 14.8%, rgba(83, 230, 232, .16) 15%, transparent 15.3%),
    radial-gradient(ellipse 22% 66% at 50% 4%, rgba(87, 230, 232, .09), transparent 72%);
  opacity: 0;
  animation: vv-floor-edges 1.2s .72s ease-out both;
}

.vv-intro__piso::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(132, 249, 248, .16), transparent 1.5%, transparent 72%, rgba(0, 5, 7, .5));
  mix-blend-mode: screen;
}

.vv-intro__canvas {
  position: absolute;
  z-index: 3;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.vv-intro__fallback {
  position: absolute;
  z-index: 3;
  width: min(76vw, 52vh);
  left: 50%;
  top: 68%;
  transform: translate(-50%, -92%);
  mask-image: radial-gradient(ellipse at 50% 52%, black 52%, transparent 76%);
}

.vv-intro__wordmark {
  position: absolute;
  z-index: 5;
  top: 86%;
  left: 50%;
  display: flex;
  align-items: baseline;
  gap: .3em;
  margin: 0;
  color: rgba(231, 246, 247, .88);
  font: 560 clamp(13px, 1.2vw, 18px)/1 system-ui, -apple-system, "Segoe UI", sans-serif;
  letter-spacing: .42em;
  white-space: nowrap;
  opacity: 0;
  transform: translate(-47%, 10px);
  text-shadow: 0 2px 18px rgba(0, 0, 0, .82);
  pointer-events: none;
  animation: vv-wordmark-in 6.35s linear both;
}

.vv-intro__wordmark b { color: #45e2e3; font-weight: 720; }

.vv-intro__skip {
  position: absolute;
  z-index: 10;
  right: max(20px, env(safe-area-inset-right));
  bottom: max(20px, env(safe-area-inset-bottom));
  min-width: 44px;
  min-height: 44px;
  padding: 0 16px;
  border: 1px solid rgba(183, 226, 236, .28);
  border-radius: 6px;
  background: rgba(2, 17, 22, .56);
  color: rgba(237, 249, 252, .84);
  font: 600 13px/1 system-ui, sans-serif;
  letter-spacing: .04em;
  cursor: pointer;
  backdrop-filter: blur(12px);
  transition: border-color .2s ease, background-color .2s ease, transform .2s ease;
  animation: vv-skip-in .5s .45s ease both;
}

.vv-intro__skip:hover { border-color: rgba(64, 222, 227, .7); background: rgba(7, 43, 49, .76); transform: translateY(-2px); }
.vv-intro__skip:active { transform: translateY(0) scale(.98); }
.vv-intro__skip:focus-visible { outline: 2px solid #5feaec; outline-offset: 3px; }

.vv-intro[data-state="leaving"] { animation: vv-curtain-out .74s cubic-bezier(.42,0,.92,.5) both; }

@keyframes vv-studio-awake {
  0% { opacity: 0; filter: blur(12px); }
  46% { opacity: .54; }
  100% { opacity: 1; filter: blur(0); }
}

@keyframes vv-edge-beam {
  0% { opacity: 0; }
  48% { opacity: .6; }
  100% { opacity: 1; }
}

@keyframes vv-floor-unfold {
  0% { opacity: 0; transform: translateX(-50%) perspective(720px) rotateX(62deg) scaleY(0); filter: brightness(.3); }
  28% { opacity: .42; }
  72% { opacity: 1; filter: brightness(.88); }
  100% { opacity: 1; transform: translateX(-50%) perspective(720px) rotateX(62deg) scaleY(1); filter: brightness(1); }
}

@keyframes vv-floor-edges {
  from { opacity: 0; filter: blur(4px); }
  to { opacity: 1; filter: blur(0); }
}

@keyframes vv-wordmark-in {
  0%, 78% { opacity: 0; transform: translate(-47%, 10px); letter-spacing: .54em; }
  87%, 100% { opacity: 1; transform: translate(-47%, 0); letter-spacing: .42em; }
}

@keyframes vv-skip-in {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes vv-curtain-out {
  0% { opacity: 1; filter: blur(0); }
  55% { opacity: .74; }
  100% { opacity: 0; filter: blur(10px); visibility: hidden; }
}

@media (max-width: 640px) {
  .vv-intro__piso { width: 190vw; }
  .vv-intro__wordmark { top: 86%; font-size: 13px; letter-spacing: .34em; }
  .vv-intro__skip { right: 16px; bottom: 16px; }
}

@media (orientation: landscape) and (max-height: 520px) {
  .vv-intro__wordmark { display: none; }
}

@media print {
  html.vv-intro-active { overflow: visible; }
  #vv-intro { display: none !important; }
}

@media (prefers-reduced-motion: reduce) {
  .vv-intro { display: none !important; }
  .vv-intro *,
  .vv-intro::before,
  .vv-intro::after { animation: none !important; transition: none !important; }
}
