/* v10 motion layer: headline weights, one continuous moving sky, smooth scroll,
   app-store buttons, and the horizontal app-screen gallery. */

/* ---------- type: Poppins comes from fonts/poppins.css (shared by all landing pages) ---------- */
h1,
h2,
h3 {
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.08;
}
.hero9 h1 {
  font-size: clamp(36px, 5vw, 68px);
  max-width: 900px;
}
h2,
.final h2 {
  font-weight: 700;
}
.btn {
  font-weight: 600;
}

/* ---------- one continuous sky behind the whole page ---------- */
html {
  background: #fcf7ec;
}
body,
.final,
.journey10,
.footer {
  background: transparent;
}
.header {
  background: rgba(253, 249, 241, 0.7);
  border-bottom-color: rgba(20, 22, 20, 0.06);
}
.sky {
  --sky-a: #fcf7ec;
  --sky-b: #fcf7ec;
  --tile: 150vh;
  position: fixed;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
  background: linear-gradient(180deg, var(--sky-a) 0%, var(--sky-b) 100%);
}
.sky .cloud {
  position: absolute;
  left: -12vw;
  right: -12vw;
  top: 0;
  height: calc(var(--tile) * 2);
  background-repeat: repeat-y;
  background-size: 100% var(--tile);
  will-change: transform;
  animation: sky-drift 28s ease-in-out infinite alternate;
}
/* every gradient fades out well inside its tile, so the repeat has no seam */
.sky .c1 {
  background-image:
    radial-gradient(38vw 28vh at 18% 25%, rgba(255, 255, 255, 0.95), transparent 70%),
    radial-gradient(30vw 22vh at 78% 70%, rgba(255, 255, 255, 0.8), transparent 70%);
}
.sky .c2 {
  background-image:
    radial-gradient(34vw 26vh at 84% 24%, rgba(255, 252, 244, 0.85), transparent 70%),
    radial-gradient(28vw 24vh at 24% 76%, rgba(255, 253, 247, 0.8), transparent 70%);
  animation-duration: 36s;
  animation-direction: alternate-reverse;
}
.sky .c3 {
  background-image:
    radial-gradient(24vw 18vh at 56% 46%, rgba(255, 255, 255, 0.75), transparent 70%),
    radial-gradient(20vw 14vh at 10% 86%, rgba(255, 252, 245, 0.8), transparent 70%);
  animation-duration: 44s;
}
@keyframes sky-drift {
  from {
    translate: -3vw 0;
  }
  to {
    translate: 3vw 0;
  }
}

/* ---------- green shapes: floating loops ---------- */
/* Each shape drifts around its own closed path (no back-and-forth) and turns as
   it goes, out of step with the others. landing.js still adds a small scroll
   parallax through the separate `translate` property, so the two combine. */
.blobs .bf,
.halo {
  animation: float-loop-1 22s ease-in-out infinite;
}
.blobs .bf:nth-child(3n + 2),
.halo.b {
  animation-name: float-loop-2;
  animation-duration: 26s;
}
.blobs .bf:nth-child(3n) {
  animation-name: float-loop-3;
  animation-duration: 30s;
}
.blobs .bf:nth-child(2n) {
  animation-delay: -9s;
}
.blobs .bf:nth-child(4n + 1) {
  animation-delay: -17s;
}
@keyframes float-loop-1 {
  0%,
  100% {
    transform: translate(0, 0) rotate(0deg) scale(1);
  }
  25% {
    transform: translate(110px, -70px) rotate(28deg) scale(1.08, 0.95);
  }
  50% {
    transform: translate(40px, -150px) rotate(-14deg) scale(0.95, 1.06);
  }
  75% {
    transform: translate(-90px, -60px) rotate(22deg) scale(1.05);
  }
}
@keyframes float-loop-2 {
  0%,
  100% {
    transform: translate(0, 0) rotate(0deg) scale(1);
  }
  25% {
    transform: translate(-100px, 60px) rotate(-30deg) scale(0.95, 1.07);
  }
  50% {
    transform: translate(-140px, -50px) rotate(16deg) scale(1.06, 0.95);
  }
  75% {
    transform: translate(-30px, -110px) rotate(-24deg) scale(1);
  }
}
@keyframes float-loop-3 {
  0%,
  100% {
    transform: translate(0, 0) rotate(0deg) scale(1);
  }
  33% {
    transform: translate(90px, 100px) rotate(36deg) scale(1.07);
  }
  66% {
    transform: translate(-80px, 130px) rotate(-26deg) scale(0.94, 1.05);
  }
}

/* ---------- tablets merge: scroll-driven (landing10-motion.js sets the styles) ---------- */
.scene9.scrub .tab,
.scene9.scrub .one {
  transition: none;
}
/* the scene now follows the scroll, so a replay button has nothing to do */
.scene9.scrub .replay9 {
  display: none;
}

/* ---------- order journey: scroll-driven (landing10-motion.js sets --k and .on) ---------- */
.journey10.scrub .jrow .fill {
  transition: none;
}
.journey10.scrub .jstep .jshot,
.journey10.scrub .jstep .jcard,
.journey10.scrub .jstep b,
.journey10.scrub .jstep p {
  opacity: calc(0.25 + 0.75 * var(--k, 0));
  translate: 0 calc((1 - var(--k, 0)) * 36px);
}
.journey10.scrub .jstep .jshot {
  scale: calc(0.94 + 0.06 * var(--k, 0));
}
.journey10.scrub .jstep .jdot,
.journey10.scrub.go .jstep .jdot {
  background: #fff;
  color: var(--ink);
  box-shadow: 0 0 0 1px var(--line);
  transition:
    background-color 0.25s,
    color 0.25s,
    box-shadow 0.25s,
    scale 0.25s;
  transition-delay: 0s;
}
.journey10.scrub .jstep.on .jdot {
  background: var(--green);
  color: #fff;
  box-shadow: 0 0 0 6px rgba(73, 124, 0, 0.14);
  scale: 1.06;
}

/* the otter face is 160x121; several old rules force it into a square box */
img[src$="face-happy.webp"] {
  object-fit: contain;
}

/* ---------- waving mascot ---------- */
/* The paw is cut from body-wave.webp into its own layer (otter-wave-paw.webp) at
   the same size, so it lines up exactly and rotates around the wrist. */
.otter-fig {
  position: relative;
  display: block;
  width: 118px;
  animation: otter-bob 2.6s ease-in-out infinite;
}
.otter-fig img {
  display: block;
  width: 100%;
}
.otter-fig .o-paw {
  position: absolute;
  inset: 0;
  transform-origin: 80.5% 39%;
  animation: paw-wave 2.6s ease-in-out infinite;
}
@keyframes paw-wave {
  0%,
  44%,
  100% {
    rotate: 0deg;
  }
  8% {
    rotate: -18deg;
  }
  17% {
    rotate: 12deg;
  }
  26% {
    rotate: -16deg;
  }
  35% {
    rotate: 8deg;
  }
}
@keyframes otter-bob {
  0%,
  100% {
    translate: 0 0;
  }
  50% {
    translate: 0 -4px;
  }
}

/* floating button: the face bobs and a small paw waves every few seconds */
.agent .agent-face {
  width: 44px;
  animation: face-nod 5s ease-in-out infinite;
}
.agent .agent-paw {
  position: absolute;
  left: -9px;
  top: -10px;
  width: 26px;
  transform-origin: 37% 83%;
  animation: paw-hello 5s ease-in-out infinite;
  filter: drop-shadow(0 2px 3px rgba(20, 22, 20, 0.25));
}
.agent:hover .agent-paw,
.agent:focus-visible .agent-paw {
  animation-duration: 1.6s;
}
@keyframes paw-hello {
  0%,
  40%,
  100% {
    rotate: 0deg;
  }
  6% {
    rotate: -22deg;
  }
  13% {
    rotate: 14deg;
  }
  20% {
    rotate: -20deg;
  }
  27% {
    rotate: 10deg;
  }
  33% {
    rotate: -6deg;
  }
}
@keyframes face-nod {
  0%,
  40%,
  100% {
    rotate: 0deg;
    translate: 0 0;
  }
  10% {
    rotate: -6deg;
    translate: 0 -2px;
  }
  22% {
    rotate: 5deg;
    translate: 0 -1px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .otter-fig,
  .otter-fig .o-paw,
  .agent .agent-face,
  .agent .agent-paw {
    animation: none;
  }
}

/* ---------- smooth scroll (Lenis) ---------- */
html.lenis,
html.lenis body {
  height: auto;
}
html.lenis {
  scroll-behavior: auto;
}
.lenis.lenis-stopped {
  overflow: clip;
}
.lenis [data-lenis-prevent] {
  overscroll-behavior: contain;
}

/* ---------- store buttons: under the app gallery heading, every screen size ---------- */
.store {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  margin: 22px auto 0;
}
.sb {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  min-height: 50px;
  padding: 7px 16px 7px 12px;
  border-radius: 13px;
  background: #0b0c0b;
  color: #fff;
  text-align: left;
  box-shadow: 0 6px 18px rgba(20, 22, 20, 0.16);
}
.sb svg {
  width: 24px;
  height: 24px;
  flex: none;
}
.sb small {
  display: block;
  font-size: 10.5px;
  line-height: 1.15;
  opacity: 0.82;
}
.sb b {
  display: block;
  font-size: 17px;
  font-weight: 650;
  line-height: 1.1;
  letter-spacing: -0.01em;
}
.sb[aria-disabled="true"] {
  cursor: default;
}
.sb .soon {
  position: absolute;
  top: -9px;
  right: -8px;
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--lime);
  color: var(--ink);
  font-size: 10.5px;
  font-weight: 700;
}

/* ---------- app gallery: phones in a row ---------- */
.gal {
  --phw: clamp(180px, min(22vw, calc((100svh - 330px) * 0.46)), 270px);
  padding: 96px 0 40px;
}
.gal-head,
.gal-head h2 {
  text-align: center;
}
.gal-head .sub {
  max-width: 520px;
  margin: 14px auto 0;
}
.gal-head .tag {
  margin-top: 14px;
}
/* default (no JS, reduced motion): a plain swipeable row */
.gal-view {
  margin-top: 40px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}
.gal-view::-webkit-scrollbar {
  display: none;
}
.gal-track {
  display: flex;
  gap: clamp(20px, 3vw, 40px);
  width: max-content;
  padding: 24px calc(50vw - var(--phw) / 2) 32px;
  list-style: none;
}
.gal-track li {
  flex: none;
  width: var(--phw);
  scroll-snap-align: center;
  transform-origin: 50% 50%;
  will-change: transform;
}
.gal-track figure {
  margin: 0;
}
.ph-frame {
  position: relative;
  padding: calc(var(--phw) * 0.035);
  border-radius: calc(var(--phw) * 0.17);
  background: #111311;
  box-shadow:
    0 0 0 1.5px #2b2e2b inset,
    0 30px 60px -18px rgba(20, 30, 10, 0.35),
    0 12px 24px -12px rgba(20, 30, 10, 0.25);
}
.ph-frame::before {
  content: "";
  position: absolute;
  z-index: 1;
  top: calc(var(--phw) * 0.06);
  left: 50%;
  width: 30%;
  height: calc(var(--phw) * 0.075);
  border-radius: 999px;
  background: #111311;
  translate: -50% 0;
}
.ph-frame img {
  width: 100%;
  border-radius: calc(var(--phw) * 0.135);
  background: #fff;
}
.gal-track figcaption {
  margin-top: 14px;
  text-align: center;
  font-size: 14px;
  font-weight: 600;
  color: var(--ink-2);
}
.gal-note {
  margin-top: 6px;
  text-align: center;
  font-size: 12.5px;
  color: var(--faint);
}

/* its own sideways scroller, independent of the page scroll; phones curve away */
.gal-view {
  perspective: 1500px;
  cursor: grab;
  overscroll-behavior-x: contain;
}
.gal-view.drag {
  cursor: grabbing;
  scroll-snap-type: none;
  user-select: none;
}
.gal-view img {
  -webkit-user-drag: none;
  pointer-events: none;
}
.gal-track {
  transform-style: preserve-3d;
}
.gal-nav {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-top: 4px;
}
.gal-nav button {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.8);
  box-shadow:
    inset 0 0 0 1px #d6d9d5,
    0 4px 14px rgba(20, 30, 10, 0.08);
  transition:
    background-color 0.15s,
    opacity 0.15s;
}
.gal-nav button:hover {
  background: #fff;
}
.gal-nav button:disabled {
  opacity: 0.35;
  cursor: default;
}
.gal-nav svg {
  width: 20px;
  height: 20px;
}
@media (max-width: 760px) {
  .gal {
    --phw: clamp(170px, calc((100svh - 330px) * 0.46), 230px);
  }
  .gal-head h2 {
    font-size: 30px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .blobs .bf,
  .halo {
    animation: none;
  }
  .sky .cloud {
    animation: none;
    transform: none !important;
  }
}
