*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --orb-base: 96px;
  --orb-hover: 400px;
  --transition: 0.62s cubic-bezier(0.22, 1, 0.36, 1);
  --bg: #f8f8f8;
  --intro-duration: 1.45s;
  --intro-text-duration: 0.6s;
  --intro-ease: cubic-bezier(0.22, 1, 0.36, 1);
  --orb-reveal-duration: 0.65s;
  --orb-overlay-outer-ratio: 0.92;
  --orb-overlay-scale: calc(1 / var(--orb-overlay-outer-ratio));
}

html,
body {
  width: 100%;
  height: 100%;
  overflow: hidden;
  font-family: "Avenir Next", "Segoe UI", system-ui, sans-serif;
  background: var(--bg);
  color: #2a2a2a;
}

.loader {
  position: fixed;
  inset: 0;
  z-index: 200;
  padding: 24px;
  background: #fff;
  transition:
    opacity var(--intro-duration) var(--intro-ease),
    filter var(--intro-duration) var(--intro-ease);
}

.loader-center {
  position: absolute;
  top: 50%;
  left: 50%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: min(92vw, 820px);
  transform: translate(-50%, -50%);
}

.loader-stage {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
}

.loader.is-preloading .loader-intro {
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
}

.loader-preload {
  width: min(100%, 360px);
  margin-inline: auto;
  text-align: center;
  transition: opacity 0.5s var(--intro-ease);
}

.loader-preload.is-hiding {
  opacity: 0;
}

.loader-preload-label {
  margin-bottom: 18px;
  font-size: 0.95rem;
  letter-spacing: 0.01em;
  color: rgba(0, 0, 0, 0.45);
}

.loader-preload-track {
  height: 3px;
  border-radius: 999px;
  overflow: hidden;
  background: rgba(0, 0, 0, 0.08);
}

.loader-preload-bar {
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: #007aff;
  transition: width 0.28s var(--intro-ease);
}

.loader-preload-value {
  margin-top: 12px;
  font-size: 0.82rem;
  font-variant-numeric: tabular-nums;
  color: rgba(0, 0, 0, 0.35);
}

.loader-skip {
  position: absolute;
  bottom: max(28px, env(safe-area-inset-bottom, 0px));
  left: 50%;
  transform: translateX(-50%);
  border: none;
  background: none;
  padding: 10px 14px;
  font-family: "Avenir Next", "Segoe UI", system-ui, sans-serif;
  font-size: 0.9rem;
  color: rgba(0, 0, 0, 0.15);
  cursor: pointer;
  transition: color 0.2s ease;
}

.loader-skip:hover {
  color: rgba(0, 0, 0, 0.28);
}

.loader.is-exiting {
  opacity: 0;
  filter: blur(14px);
  pointer-events: none;
}

.loader[hidden] {
  display: none;
}

.loader-text {
  margin: 0 auto;
  width: 100%;
  max-width: min(92vw, 820px);
  font-family: "SF Mono", "Menlo", "Consolas", monospace;
  font-size: clamp(1.15rem, 3.6vw, 2.35rem);
  font-weight: 500;
  line-height: 1.45;
  letter-spacing: -0.02em;
  color: #000;
  text-align: center;
  transition:
    opacity var(--intro-text-duration) var(--intro-ease),
    filter var(--intro-text-duration) var(--intro-ease);
}

.loader-text.is-transitioning {
  opacity: 0;
  filter: blur(14px);
}

.loader-cursor {
  display: inline-block;
  width: 0.08em;
  height: 1.05em;
  margin-left: 0.06em;
  vertical-align: -0.12em;
  background: #007aff;
}

.loader-cursor.is-blinking {
  animation: loader-cursor-blink 0.85s step-end infinite;
}

.loader-cursor.is-done {
  opacity: 0;
  animation: none;
}

@keyframes loader-cursor-blink {
  50% {
    opacity: 0;
  }
}

.background {
  position: fixed;
  inset: 0;
  z-index: 0;
  background-color: var(--bg);
  background-image: url("../assets/background.jpg?v=1783102666637");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.scene {
  position: fixed;
  inset: 0;
  z-index: 1;
  overflow: hidden;
  opacity: 0;
  filter: blur(18px);
  transition:
    opacity var(--intro-duration) var(--intro-ease),
    filter var(--intro-duration) var(--intro-ease);
}

.scene.is-introduced {
  opacity: 1;
  filter: blur(0);
}

.scene:not(.is-ready) .orb {
  transition: none;
}

.orb {
  position: absolute;
  left: 0;
  top: 0;
  cursor: pointer;
  border-radius: 50%;
  overflow: visible;
  transform: translate3d(0, 0, 0) translate(-50%, -50%) scale(1);
  transform-origin: center center;
  backface-visibility: hidden;
  z-index: 1;
}

.scene.is-ready .orb {
  will-change: transform;
}

.orb.is-hovered {
  z-index: 10;
}

.orb:not(.is-visible) {
  pointer-events: none;
}

.orb-shell {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  overflow: visible;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
  transform-origin: center center;
  transition: box-shadow var(--transition);
}

.scene.is-introduced .orb:not(.is-visible) .orb-shell {
  opacity: 0;
  filter: blur(16px);
}

.orb.is-visible .orb-shell {
  animation: orb-blur-in var(--orb-reveal-duration) var(--intro-ease) forwards;
}

@keyframes orb-blur-in {
  0% {
    opacity: 0;
    filter: blur(16px);
  }

  100% {
    opacity: 1;
    filter: blur(0);
  }
}

.orb.is-hovered .orb-shell {
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.07);
}

.orb-media {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  overflow: hidden;
  background: #d4d4d4;
}

.orb-poster,
.orb-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
  transform: translateZ(0);
}

.orb-poster {
  z-index: 1;
  opacity: 1;
}

.orb-video {
  z-index: 2;
  opacity: 0;
  transition: opacity 0s;
}

.orb.is-video-active:not(.has-no-video) .orb-video {
  opacity: 1;
}

.orb.has-no-video .orb-poster,
.orb.has-no-video .orb-video {
  display: none;
}

.orb-overlay {
  position: absolute;
  left: 50%;
  top: 50%;
  width: calc(100% * var(--orb-overlay-scale));
  height: calc(100% * var(--orb-overlay-scale));
  transform: translate(-50%, -50%);
  border-radius: 50%;
  pointer-events: none;
  z-index: 3;
  background: url("../assets/orb-overlay.png?v=1783115762866") center / 100% 100% no-repeat;
}

.scene.is-opening-lightbox {
  opacity: 0.35;
  transition: opacity 0.55s ease;
}

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  pointer-events: none;
}

.lightbox[hidden] {
  display: none;
}

.lightbox.is-interactive {
  pointer-events: auto;
}

.lightbox-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(4, 6, 12, 0.92);
  opacity: 0;
  transition: opacity 0.55s ease 0.2s;
}

.lightbox.is-active .lightbox-backdrop {
  opacity: 1;
}

.lightbox-morph {
  position: fixed;
  left: 0;
  top: 0;
  width: 0;
  height: 0;
  transform: translate(-50%, -50%);
  z-index: 2;
  overflow: hidden;
  border-radius: 50%;
  opacity: 1;
  background: #000;
  pointer-events: none;
  transition:
    left 0.72s cubic-bezier(0.34, 1.08, 0.64, 1),
    top 0.72s cubic-bezier(0.34, 1.08, 0.64, 1),
    width 0.72s cubic-bezier(0.34, 1.08, 0.64, 1),
    height 0.72s cubic-bezier(0.34, 1.08, 0.64, 1),
    border-radius 0.72s cubic-bezier(0.34, 1.08, 0.64, 1),
    opacity 0.4s ease;
}

.lightbox-morph.is-hidden {
  opacity: 0;
  pointer-events: none;
}

.lightbox-morph-video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.lightbox-content {
  position: fixed;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  z-index: 3;
  max-width: 92vw;
  max-height: 85vh;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.45s ease;
}

.lightbox.is-revealed .lightbox-content {
  opacity: 1;
  pointer-events: auto;
}

.lightbox-media {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #000;
  border-radius: 8px;
  overflow: hidden;
}

.lightbox-video {
  width: 100%;
  height: 100%;
  border-radius: 8px;
  background: #000;
  display: block;
  object-fit: contain;
}

.lightbox-close {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  width: 36px;
  height: 36px;
  border: none;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.55);
  color: #fff;
  font-size: 1.4rem;
  line-height: 1;
  cursor: pointer;
}

.lightbox-close:hover {
  background: rgba(0, 0, 0, 0.75);
}

.lightbox-title {
  margin-top: 12px;
  text-align: center;
  font-size: 0.95rem;
  color: #e8ecf4;
  opacity: 0.85;
}

@media (prefers-reduced-motion: reduce) {
  .loader,
  .loader-text,
  .scene {
    transition: none;
  }

  .loader-cursor,
  .orb.is-visible .orb-shell {
    animation: none;
  }

  .scene.is-introduced .orb:not(.is-visible) .orb-shell {
    opacity: 1;
    filter: blur(0);
  }

  .lightbox-morph,
  .lightbox-backdrop,
  .lightbox-content,
  .scene.is-opening-lightbox {
    transition: none;
  }
}

@media (max-width: 768px) {
  :root {
    --orb-base: 62px;
    --orb-hover: 280px;
  }
}