/* Minimal overrides that Tailwind utilities cannot express ergonomically. */

html {
  scroll-behavior: smooth;
}

/* Hide native disclosure on selects in Safari to match Tailwind look */
select {
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%235c6478' stroke-width='2.5'%3E%3Cpath d='M6 9l6 6 6-6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0 center;
  background-size: 12px;
  padding-right: 18px;
}

/* Smoother focus-ring across all interactive elements */
:focus-visible {
  outline: 2px solid #ff6a3d;
  outline-offset: 2px;
  border-radius: 6px;
}

/* Reduce the heavy halo Tailwind adds to native focus */
input:focus,
select:focus,
button:focus {
  outline: none;
}

/* ─────────────────────────────────────────────────────────
   Scroll-reveal animations.
   Elements opt in with [data-reveal]; the IO at the bottom of
   index.html toggles .is-visible when they enter the viewport.
   Supports staggered children via [data-reveal-delay="<ms>"].
───────────────────────────────────────────────────────── */
@keyframes guidoo-reveal-up {
  0% {
    opacity: 0;
    transform: translateY(28px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Hide reveal targets ONLY if JS is running (html.js-reveal added by inline script).
   Users without JS, and tools that read the page before JS runs, see full content. */
.js-reveal [data-reveal] {
  opacity: 0;
  will-change: opacity, transform;
}

.js-reveal [data-reveal].is-visible {
  animation: guidoo-reveal-up 0.9s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  animation-delay: var(--reveal-delay, 0s);
}

[data-reveal-delay="100"].is-visible {
  animation-delay: 0.1s;
}
[data-reveal-delay="150"].is-visible {
  animation-delay: 0.15s;
}
[data-reveal-delay="200"].is-visible {
  animation-delay: 0.2s;
}
[data-reveal-delay="300"].is-visible {
  animation-delay: 0.3s;
}
[data-reveal-delay="400"].is-visible {
  animation-delay: 0.4s;
}
[data-reveal-delay="500"].is-visible {
  animation-delay: 0.5s;
}

/* Hero Ken Burns — slow zoom on background photo */
.hero-photo {
  animation: guidoo-ken-burns 22s ease-in-out infinite alternate;
}
@keyframes guidoo-ken-burns {
  0% {
    transform: scale(1) translateX(0);
  }
  100% {
    transform: scale(1.08) translateX(-1.5%);
  }
}

/* Respect user accessibility preference */
@media (prefers-reduced-motion: reduce) {
  .js-reveal [data-reveal],
  .js-reveal [data-reveal].is-visible,
  .hero-photo {
    opacity: 1 !important;
    transform: none !important;
    animation: none !important;
  }
}

/* ─────────────────────────────────────────────────────────
   App-flow walkthrough — phone mockup + scroll-linked steps
───────────────────────────────────────────────────────── */
.flow-step-num {
  font-family: "Plus Jakarta Sans", "Inter", sans-serif;
  font-weight: 800;
  font-size: 4rem;
  line-height: 1;
  color: rgba(255, 106, 61, 0.16);
  display: inline-block;
  letter-spacing: -0.02em;
}

@media (min-width: 1024px) {
  .flow-step-num {
    font-size: 6rem;
  }
}

.flow-step {
  transition: transform 0.4s ease;
}

.flow-step-num {
  transition: color 0.4s ease, transform 0.4s ease;
}

.flow-step.is-current .flow-step-num {
  color: rgba(255, 106, 61, 1);
  transform: translateY(-2px);
}

/* Phone frame */
.phone-frame {
  position: relative;
  width: 300px;
  height: 600px;
  background: #0b0f1a;
  border-radius: 44px;
  padding: 11px;
  box-shadow:
    0 30px 60px -15px rgba(11, 15, 26, 0.4),
    0 0 0 1px rgba(255, 255, 255, 0.04) inset,
    0 0 0 2px rgba(11, 15, 26, 0.1);
}

.phone-notch {
  position: absolute;
  top: 11px;
  left: 50%;
  transform: translateX(-50%);
  width: 110px;
  height: 26px;
  background: #0b0f1a;
  border-radius: 0 0 16px 16px;
  z-index: 10;
}

.phone-screen {
  position: relative;
  width: 100%;
  height: 100%;
  background: #fff;
  border-radius: 34px;
  overflow: hidden;
}

.screen {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  padding-top: 40px;
  opacity: 0;
  transform: translateY(8px) scale(0.985);
  transition:
    opacity 0.55s cubic-bezier(0.16, 1, 0.3, 1),
    transform 0.55s cubic-bezier(0.16, 1, 0.3, 1);
  pointer-events: none;
}

.screen.is-active {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}

.screen-status {
  position: absolute;
  top: 14px;
  left: 0;
  right: 0;
  display: flex;
  justify-content: space-between;
  padding: 0 22px;
  font-size: 10px;
  font-weight: 700;
  color: #0b0f1a;
  letter-spacing: 0.02em;
  z-index: 5;
}

.screen-caret {
  display: inline-block;
  width: 1.5px;
  height: 14px;
  background: #ff6a3d;
  margin-left: 1px;
  vertical-align: middle;
  animation: guidoo-caret 1s steps(2, end) infinite;
}

@keyframes guidoo-caret {
  to {
    opacity: 0;
  }
}

/* Progress dots below phone */
.phone-dots {
  position: absolute;
  bottom: -36px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
}

.phone-dot {
  width: 8px;
  height: 8px;
  border-radius: 9999px;
  background: rgba(11, 15, 26, 0.15);
  transition: all 0.3s ease;
}

.phone-dot.is-active {
  width: 28px;
  background: #ff6a3d;
}

/* ─────────────────────────────────────────────────────────
   Stat counters — tabular numerals so the digit width doesn't
   jitter as the count animates.
───────────────────────────────────────────────────────── */
[data-counter] {
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum";
}
