@font-face {
  font-family: 'Archivo';
  font-style: normal;
  font-weight: 400 900;
  font-display: swap;
  src: url('/fonts/archivo-latin.woff2') format('woff2');
}

html,
body {
  margin: 0;
  height: 100%;
  background: #060807;
  color: #eaf0ec;
  font-family: 'Archivo', 'Archivo Black', system-ui, -apple-system, sans-serif;
  -webkit-font-smoothing: antialiased;
  overscroll-behavior: none;
}

/* Disable the iOS tap highlight + text selection for an app-like feel. */
* {
  -webkit-tap-highlight-color: transparent;
}

floored-app {
  display: block;
  min-height: 100%;
}

/* Hero loading splash: black → logo reveal (Runway), then fades into the app. */
#splash {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: #0b0d0c;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.45s ease;
}

#splash.hide {
  opacity: 0;
  pointer-events: none;
}

/* Returning from an OAuth redirect (e.g. #strava=connected) — skip the boot
   animation entirely; the user is mid-flow, not freshly launching. */
html.no-splash #splash {
  display: none;
}

#splash-logo {
  position: relative;
  width: min(82vw, 400px);
  aspect-ratio: 3 / 4;
}

/* Feather the rectangular video edges into the black so they're invisible;
   the shimmer lives on the F/gauge inside the clip itself. */
#splash-logo video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  -webkit-mask-image: radial-gradient(ellipse 58% 52% at 50% 50%, #000 56%, transparent 82%);
  mask-image: radial-gradient(ellipse 58% 52% at 50% 50%, #000 56%, transparent 82%);
}

@media (prefers-reduced-motion: reduce) {
  #splash-logo video {
    display: none;
  }
}

/* Brand moment: the promise, stated plainly, as the splash settles. */
#splash-tag {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 12vh;
  text-align: center;
  pointer-events: none;
}

#splash-tag .ff-kicker {
  display: block;
  margin-bottom: 7px;
  font-weight: 800;
  font-size: 13px;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  color: #eaf0ec;
  opacity: 0;
  animation: ff-rise 0.55s ease-out 0.5s both;
}

#splash-tag .ff-free {
  display: block;
  font-weight: 800;
  font-size: 18px;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: #aab5ae;
  opacity: 0;
  animation: ff-rise 0.55s ease-out 0.9s both;
}

#splash-tag .ff-forever {
  display: block;
  margin-top: 5px;
  font-weight: 900;
  font-size: 56px;
  line-height: 1;
  letter-spacing: 0.01em;
  text-transform: uppercase;
  /* lime → amber gradient fill = the color pop on FOREVER */
  background: linear-gradient(100deg, #b6ff3d 0%, #ffb23e 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
  filter: drop-shadow(0 0 20px rgba(182, 255, 61, 0.35));
  opacity: 0;
  transform: scale(0.55);
  animation: ff-pop 0.55s cubic-bezier(0.18, 1.5, 0.3, 1) 1.3s both;
}

@keyframes ff-rise {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

@keyframes ff-pop {
  0% {
    opacity: 0;
    transform: scale(0.55);
  }
  65% {
    opacity: 1;
    transform: scale(1.09);
  }
  100% {
    opacity: 1;
    transform: scale(1);
  }
}

@media (prefers-reduced-motion: reduce) {
  #splash-tag .ff-kicker,
  #splash-tag .ff-free,
  #splash-tag .ff-forever {
    animation: none;
    opacity: 1;
    transform: none;
  }
}
