@import url("display-scale.css");
:root { color-scheme: dark; font-family: var(--font-sans); color: #faf8ff; background: #201039; }
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { width: 100%; height: 100%; margin: 0; overflow: hidden; }
body { -webkit-font-smoothing: antialiased; }
button, a, summary { -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-decoration: none; }
button { color: inherit; font: inherit; cursor: pointer; }
#wormhole { display: block; width: 100%; height: 100%; position: fixed; inset: 0; touch-action: none; }
#wormholeCharacter { display: block; width: 100%; height: 100%; position: fixed; inset: 0; pointer-events: none; opacity: 0; transition: opacity 1s ease; }
#exitVeil { display: block; width: 100%; height: 100%; position: fixed; inset: 0; z-index: 8; pointer-events: none; }
.character-ready #wormholeCharacter { opacity: var(--character-opacity, 1); }
.skull-encounter #wormholeCharacter { transition: none; }
.shade { position: fixed; inset: 0; pointer-events: none; background: linear-gradient(180deg, rgba(11,4,25,.12), transparent 16%, transparent 84%, rgba(11,4,25,.18)); }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.topbar { position: fixed; z-index: 3; top: 24px; left: 30px; right: 30px; display:flex; align-items:center; justify-content:space-between; text-shadow: 0 2px 18px #230a47; }
@font-face{font-family:'Space Grotesk';src:url('assets/fonts/SpaceGrotesk-Variable.woff2') format('woff2');font-weight:300 700;font-style:normal;font-display:swap}
.wormhole-brand-lockup{position:fixed;top:36px;left:5%;display:flex;align-items:flex-end;gap:20px;min-width:0;text-shadow:none}
.wormhole-brand { display:flex; align-items:center; font-size:20px; font-weight:700; letter-spacing:-1px; }
.wormhole-brand-caption{font:400 var(--fs-xs)/1 var(--font-sans);letter-spacing:.1px;color:var(--muted)}
.topbar>.back{margin-left:auto}
@media(max-width:740px){.wormhole-brand-lockup{gap:14px}.wormhole-brand-caption{font-size:var(--fs-xs)}}
@media(max-width:650px){.wormhole-brand{font-size:18px}}
@media(max-width:600px){.wormhole-brand-caption{display:none}}
@media(max-width:480px){.wormhole-brand-lockup{gap:10px}}
@media(max-width:1100px) and (min-height:521px),(aspect-ratio < 4/3){.wormhole-brand-lockup{top:clamp(24px,4svh,56px);left:5%}}
@media(min-width:1101px) and (min-height:521px) and (min-aspect-ratio:4/3){.wormhole-brand-lockup{--home-unit:clamp(.85px,min(.0694444444vw,.1111111111svh),3px);top:calc(36 * var(--home-unit));gap:calc(20 * var(--home-unit))}.wormhole-brand{font-size:calc(20 * var(--home-unit));letter-spacing:calc(-1 * var(--home-unit))}.wormhole-brand-caption{font-size:max(11px, calc(10 * var(--home-unit)));letter-spacing:calc(.1 * var(--home-unit))}}
@media(max-height:520px) and (min-aspect-ratio:4/3){.wormhole-brand-lockup{left:4%;top:18px;gap:12px}.wormhole-brand-caption{display:none}}
.back { display: flex; align-items: center; gap: 9px; font-size: 11px; letter-spacing: .1em; opacity: .68; padding: 10px 0; transition: opacity .2s, color .2s; }
.back:hover { opacity: 1; }
.footer { position: fixed; z-index: 3; left: 30px; right: 30px; bottom: 24px; display: flex; justify-content: flex-end; text-shadow: 0 2px 16px #230a47; pointer-events: none; }
.caption { position: fixed; left: 50%; bottom: 34px; transform: translateX(-50%); opacity: 0; transition: opacity 1s; pointer-events: none; }
.caption p { margin: 0; color: #e6dcf2; font-size: 11px; letter-spacing: .08em; white-space: nowrap; }
.hint-visible .caption { opacity: .65; }
.controls { display: flex; align-items: center; gap: 6px; pointer-events: auto; }
.controls button, .more-controls summary { border: 1px solid #ffffff18; background: #25154118; border-radius: 40px; padding: 9px 13px; min-height: 36px; font-size: 11px; color: #faf8ffb3; backdrop-filter: blur(8px); transition: background .2s, border-color .2s, color .2s; }
.controls button:hover, .more-controls summary:hover { background: #ffffff18; border-color: #ffffff60; color: white; }
.control-icon { display: block; width: 17px; height: 17px; flex: 0 0 auto; fill: none; stroke: #d5c7ff; stroke-width: 1.35; stroke-linecap: round; stroke-linejoin: round; filter: drop-shadow(0 0 4px #aa8dff70); transition: stroke .2s, filter .2s; }
.home-icon { width: 19px; height: 19px; }
.back:hover .control-icon, .controls button:hover .control-icon { stroke: #a6efff; filter: drop-shadow(0 0 6px #77ddffb0); }
.controls #fullscreen { display: inline-flex; align-items: center; justify-content: center; gap: 8px; }
.more-controls { position: relative; }
.more-controls summary { display: flex; align-items: center; justify-content: center; list-style: none; cursor: pointer; min-width: 36px; padding: 5px 10px; font-size: 18px; line-height: 1; }
.more-controls summary::-webkit-details-marker { display: none; }
.more-menu { position: absolute; bottom: calc(100% + 10px); right: 0; min-width: 126px; padding: 6px; border: 1px solid #ffffff24; border-radius: 12px; background: #160d29ec; box-shadow: 0 8px 30px #0004; }
.more-menu button, .more-menu a { display: block; width: 100%; padding: 11px 12px; text-align: left; white-space: nowrap; border: 0; border-radius: 7px; font-size: 11px; color: #faf8ffb3; background: transparent; }
.more-menu a:hover { color: white; background: #ffffff18; }
a:focus-visible, button:focus-visible, summary:focus-visible { outline: 2px solid white; outline-offset: 4px; }
.loading { position: fixed; inset: 0; display: flex; align-items: center; justify-content: center; flex-direction: column; gap: 10px; background: #201039; font-size: 12px; letter-spacing: .2em; transition: opacity .6s, visibility .6s; }
.loading span { width: 5px; height: 5px; border-radius: 50%; background: #c6a3fa; box-shadow: 0 0 24px 9px #9672d04d; }
.loading.is-hidden { opacity: 0; visibility: hidden; pointer-events: none; }
@media (max-width: 600px) {
  .topbar { top: 14px; left: 20px; right: 20px; }
   .topbar .brand-wordmark { width: 106px; }
  .footer { left: 20px; right: 20px; bottom: 20px; }
  .caption { bottom: 76px; width: calc(100% - 40px); text-align: center; }
  .caption p { font-size: var(--fs-xs); white-space: normal; line-height: 1.6; }
  .controls button, .more-controls summary { min-height: 44px; }
  .more-controls summary { min-width: 44px; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition: none !important; } }
.portal-embedded, .portal-embedded body { background: transparent; }
.credits-dialog{position:fixed;inset:0;width:100%;max-width:none;height:100%;max-height:none;margin:0;padding:0;border:0;background:var(--ink)}
.credits-dialog::backdrop{background:var(--ink)}
.credits-dialog iframe{display:block;width:100%;height:100%;border:0}
.portal-embedded .topbar, .portal-embedded .footer, .portal-embedded .shade { opacity: 0; visibility: hidden; transition: opacity .55s, visibility .55s; }
.portal-embedded #wormholeCharacter { opacity: 0; visibility: hidden; }
.portal-embedded .loading { display: none; }
.portal-embedded.portal-arrived .topbar, .portal-embedded.portal-arrived .footer, .portal-embedded.portal-arrived .shade { opacity: 1; visibility: visible; }
.portal-embedded.portal-arrived.character-ready #wormholeCharacter { opacity: var(--character-opacity, 1); visibility: visible; }
.portal-embedded .topbar .back { visibility: hidden; }
.wormhole-exiting .topbar, .wormhole-exiting .footer, .wormhole-exiting:not(.skull-encounter) #wormholeCharacter { opacity: 0 !important; pointer-events: none; transition: opacity .35s ease; }

.wormhole-map, .wormhole-brand-lockup .experience-brand-art, .transition-controls, .transition-instruction { zoom: var(--display-scale); }
