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

html,
body {
  margin: 0;
  padding: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: #07090a;
  color: #f6f4ef;
  font-family: system-ui, -apple-system, "Segoe UI", "Helvetica Neue", sans-serif;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

.page {
  position: relative;
  width: 100%;
  min-height: 100dvh;
  min-height: 100vh;
  overflow: hidden;
}

.bg {
  position: absolute;
  inset: 0;
  background: #07090a url("background.webp") center / cover no-repeat;
  transform: scale(1);
  transform-origin: center center;
  animation: bg-breathe 36s ease-in-out infinite alternate;
}

.overlay {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(
      ellipse 58% 52% at 50% 48%,
      rgba(0, 0, 0, 0.52) 0%,
      rgba(0, 0, 0, 0.38) 42%,
      rgba(0, 0, 0, 0.62) 100%
    ),
    linear-gradient(
      180deg,
      rgba(0, 0, 0, 0.42) 0%,
      rgba(0, 0, 0, 0.18) 38%,
      rgba(0, 0, 0, 0.58) 100%
    );
  box-shadow: inset 0 0 140px 48px rgba(0, 0, 0, 0.55);
}

.stage {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 100dvh;
  min-height: 100vh;
  padding-top: max(1.25rem, env(safe-area-inset-top));
  padding-right: max(0.5rem, env(safe-area-inset-right));
  padding-bottom: max(1.25rem, env(safe-area-inset-bottom));
  padding-left: max(0.5rem, env(safe-area-inset-left));
  gap: clamp(0.75rem, 2.4vh, 2rem);
}

.title {
  margin: 0;
  max-width: 100%;
  padding: 0 0.35rem;
  font-size: clamp(20px, 6.2vw, 48px);
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-align: center;
  line-height: 1.15;
  white-space: nowrap;
  color: #f7f4ee;
  text-shadow: 0 2px 28px rgba(0, 0, 0, 0.55), 0 0 2px rgba(0, 0, 0, 0.4);
  animation: fade-in 900ms ease-out both;
}

.countdown {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr) auto minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: start;
  justify-items: center;
  column-gap: clamp(0.02rem, 0.6vw, 0.9rem);
  width: 100%;
  max-width: 42rem;
  padding: clamp(0.4rem, 1.4vw, 1.35rem) clamp(0.15rem, 0.8vw, 1.5rem);
  border-radius: 28px;
  background: rgba(6, 8, 8, 0.22);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  animation: fade-in 1100ms ease-out both;
}

.unit {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 0;
  width: 100%;
}

.digits {
  display: block;
  font-size: clamp(28px, 11vw, 90px);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum" 1;
  line-height: 0.92;
  letter-spacing: 0;
  text-align: center;
  color: #ffffff;
  text-shadow:
    0 2px 24px rgba(0, 0, 0, 0.45),
    0 0 48px rgba(255, 255, 255, 0.08);
}

.sep {
  display: block;
  width: 0.28em;
  font-size: clamp(28px, 11vw, 90px);
  font-weight: 400;
  line-height: 0.92;
  text-align: center;
  color: rgba(255, 255, 255, 0.38);
  text-shadow: 0 2px 18px rgba(0, 0, 0, 0.4);
  transform: translateY(-0.02em);
}

.label {
  margin-top: clamp(0.28rem, 1.1vw, 0.7rem);
  font-size: clamp(6px, 1.55vw, 13px);
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(247, 244, 238, 0.72);
  white-space: nowrap;
}

.arrived {
  margin: 0;
  font-size: clamp(40px, 11vw, 160px);
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-align: center;
  line-height: 0.95;
  color: #ffffff;
  text-shadow:
    0 2px 28px rgba(0, 0, 0, 0.5),
    0 0 60px rgba(255, 255, 255, 0.1);
  animation: fade-in 900ms ease-out both;
}

.arrived[hidden],
.countdown[hidden] {
  display: none !important;
}

@media (min-width: 768px) {
  .title {
    font-size: clamp(50px, 5vw, 76px);
    letter-spacing: 0.2em;
    padding-left: 0.55rem;
  }

  .digits,
  .sep {
    font-size: clamp(72px, 11vw, 190px);
  }

  .label {
    font-size: clamp(11px, 1.05vw, 15px);
    letter-spacing: 0.28em;
  }

  .countdown {
    width: auto;
    max-width: none;
    column-gap: clamp(0.4rem, 1.1vw, 1.15rem);
    padding: 1.2rem 1.6rem;
  }
}

@media (max-width: 360px) {
  .title {
    font-size: clamp(18px, 5.6vw, 28px);
    letter-spacing: 0.06em;
  }

  .digits,
  .sep {
    font-size: clamp(26px, 10vw, 42px);
  }

  .label {
    letter-spacing: 0.04em;
    font-size: 6px;
  }

  .countdown {
    column-gap: 0;
    padding-left: 0.1rem;
    padding-right: 0.1rem;
  }
}

@media (max-height: 700px) {
  .stage {
    gap: 0.6rem;
  }

  .countdown {
    padding-top: 0.35rem;
    padding-bottom: 0.35rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .bg,
  .title,
  .countdown,
  .arrived {
    animation: none;
  }

  .bg {
    transform: none;
  }
}

@keyframes fade-in {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

@keyframes bg-breathe {
  from {
    transform: scale(1);
  }
  to {
    transform: scale(1.03);
  }
}
