/* ===================================================
   App landing page components
   Load after style.css. Set the app colour on <body>:
     <body class="landing" style="--accent: #a78bfa">
   Copy templates/app-landing.html to start a new page.
=================================================== */

/* ---------------------------------------------------
   Hero
--------------------------------------------------- */
.lp-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  align-items: center;
  gap: 48px;
  min-height: min(calc(100svh - var(--header-height)), 900px);
  padding-block: clamp(48px, 8vw, 96px);
}

.lp-hero .eyebrow {
  color: var(--accent);
}

.lp-hero__title {
  margin-top: 24px;
  font-size: clamp(3rem, 7vw, 6rem);
}

.lp-hero .lead {
  margin-top: 28px;
}

.lp-hero__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 28px;
  margin-top: 40px;
}

.lp-hero__note {
  margin-top: 20px;
  color: var(--text-faint);
  font-size: 0.875rem;
}

.lp-hero__visual {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 560px;
  isolation: isolate;
}

.lp-hero__visual::before {
  content: "";
  position: absolute;
  inset: 5% 0;
  z-index: -1;
  background: radial-gradient(
    closest-side,
    color-mix(in srgb, var(--accent) 30%, transparent),
    transparent
  );
}

.lp-hero__visual > * {
  width: min(52%, 300px);
  aspect-ratio: 13 / 20;
  object-fit: cover;
  border-radius: 28px;
  box-shadow: 0 40px 80px -24px rgba(0, 0, 0, 0.8);
}

.lp-hero__visual > * + * {
  position: absolute;
  right: 4%;
  bottom: 2%;
  width: min(38%, 220px);
  border-radius: 22px;
  outline: 6px solid var(--bg);
}

@media (max-width: 900px) {
  .lp-hero {
    grid-template-columns: 1fr;
    min-height: 0;
  }

  .lp-hero__visual {
    min-height: 0;
    padding-block: 16px 40px;
  }

  .lp-hero__visual > * + * {
    right: 6%;
  }
}

/* ---------------------------------------------------
   Store buttons
--------------------------------------------------- */
.store-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.store-button {
  gap: 12px;
  min-height: 56px;
  padding: 0 24px 0 20px;
  text-align: left;
}

.store-button svg {
  width: 22px;
  height: 22px;
}

.store-button small {
  display: block;
  font-size: 0.68rem;
  font-weight: 400;
  letter-spacing: 0.04em;
  line-height: 1.2;
  opacity: 0.7;
}

.store-button strong {
  display: block;
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.2;
}

/* ---------------------------------------------------
   Feature gallery
--------------------------------------------------- */
.lp-gallery {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 40px 20px;
  list-style: none;
}

.lp-shot img,
.lp-shot video {
  display: block;
  width: 100%;
  aspect-ratio: 13 / 20;
  object-fit: cover;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--bg-card);
  transition: transform 0.6s var(--ease);
}

.lp-shot:hover img,
.lp-shot:hover video {
  transform: translateY(-6px);
}

.lp-shot figcaption {
  margin-top: 18px;
}

.lp-shot span {
  color: var(--accent);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.lp-shot h3 {
  margin-top: 6px;
  font-family: var(--font-display);
  font-size: 1.6rem;
  font-weight: 400;
  line-height: 1.1;
}

@media (max-width: 960px) {
  .lp-gallery {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 520px) {
  .lp-gallery {
    grid-auto-flow: column;
    grid-auto-columns: 72%;
    grid-template-columns: none;
    margin-inline: calc(-1 * var(--gutter));
    padding-inline: var(--gutter);
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-padding-inline: var(--gutter);
    scrollbar-width: none;
  }

  .lp-gallery::-webkit-scrollbar {
    display: none;
  }

  .lp-gallery > li {
    scroll-snap-align: start;
  }
}

/* ---------------------------------------------------
   How it works
--------------------------------------------------- */
.lp-how {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  align-items: center;
  gap: clamp(48px, 8vw, 120px);
}

.lp-how__visual img,
.lp-how__visual video {
  display: block;
  width: min(100%, 380px);
  margin-inline: auto;
  aspect-ratio: 13 / 20;
  object-fit: cover;
  border-radius: 28px;
  box-shadow: 0 40px 80px -24px rgba(0, 0, 0, 0.8);
}

.lp-how .heading {
  margin-top: 20px;
}

.lp-steps {
  margin-top: 48px;
  list-style: none;
}

.lp-steps li {
  display: grid;
  grid-template-columns: 56px 1fr;
  gap: 16px;
  padding-block: 28px;
  border-top: 1px solid var(--line);
}

.lp-steps li:last-child {
  border-bottom: 1px solid var(--line);
}

.lp-steps > li > span {
  color: var(--text-faint);
  font-size: 0.8rem;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.14em;
  line-height: 2.2;
}

.lp-steps h3 {
  font-family: var(--font-display);
  font-size: 1.75rem;
  font-weight: 400;
  line-height: 1.15;
}

.lp-steps p {
  margin-top: 6px;
  color: var(--text-muted);
}

@media (max-width: 860px) {
  .lp-how {
    grid-template-columns: 1fr;
  }

  .lp-how__visual {
    order: 2;
  }
}

/* ---------------------------------------------------
   Final call to action
--------------------------------------------------- */
.lp-cta-section {
  padding-bottom: var(--section-space);
}

.lp-cta {
  position: relative;
  padding: clamp(56px, 9vw, 112px) var(--gutter);
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--bg-card);
  text-align: center;
  isolation: isolate;
}

.lp-cta::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: radial-gradient(
    60% 90% at 50% 100%,
    color-mix(in srgb, var(--accent) 24%, transparent),
    transparent 70%
  );
}

.lp-cta .heading {
  max-width: 12em;
  margin: 20px auto 0;
}

.lp-cta .lead {
  margin: 20px auto 0;
}

.lp-cta .store-buttons {
  justify-content: center;
  margin-top: 40px;
}

/* ---------------------------------------------------
   FAQ
--------------------------------------------------- */
.lp-faq {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  gap: 48px;
}

.lp-faq .heading {
  margin-top: 20px;
}

.lp-faq details {
  border-bottom: 1px solid var(--line);
}

.lp-faq details:first-child {
  border-top: 1px solid var(--line);
}

.lp-faq summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding-block: 24px;
  font-size: 1.1rem;
  font-weight: 500;
  list-style: none;
  cursor: pointer;
}

.lp-faq summary::-webkit-details-marker {
  display: none;
}

.lp-faq summary::after {
  content: "+";
  flex-shrink: 0;
  color: var(--text-muted);
  font-size: 1.5rem;
  font-weight: 300;
  transition: transform 0.3s var(--ease);
}

.lp-faq details[open] summary::after {
  transform: rotate(45deg);
}

.lp-faq details p {
  max-width: 36em;
  padding-bottom: 24px;
  color: var(--text-muted);
}

.lp-faq details a {
  color: var(--text);
  text-decoration: underline;
  text-underline-offset: 3px;
}

@media (max-width: 860px) {
  .lp-faq {
    grid-template-columns: 1fr;
  }
}

/* ---------------------------------------------------
   Ad film (click to play with sound, see setupAdVideo)
--------------------------------------------------- */
.lp-ad {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--bg-card);
  box-shadow: 0 50px 100px -40px color-mix(in srgb, var(--accent) 35%, transparent);
}

.lp-ad video {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.lp-ad__play {
  position: absolute;
  inset: 0;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 14px;
  border: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.55), rgba(0, 0, 0, 0.1) 60%);
  color: #fff;
  font: inherit;
  cursor: pointer;
}

.lp-ad__icon {
  display: grid;
  place-items: center;
  width: clamp(64px, 9vw, 96px);
  aspect-ratio: 1;
  border-radius: 50%;
  background: var(--accent);
  color: var(--bg);
  box-shadow: 0 0 0 0 color-mix(in srgb, var(--accent) 50%, transparent);
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease);
}

.lp-ad__icon svg {
  width: 40%;
  margin-left: 6%;
}

.lp-ad__play:hover .lp-ad__icon,
.lp-ad__play:focus-visible .lp-ad__icon {
  transform: scale(1.06);
  box-shadow: 0 0 0 14px color-mix(in srgb, var(--accent) 22%, transparent);
}

.lp-ad__label {
  font-size: 0.95rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.5);
}

.lp-ad.is-playing .lp-ad__play {
  display: none;
}

/* ---------------------------------------------------
   Showreel (landscape clips with tabs, see setupReel)
--------------------------------------------------- */
.lp-reel__screen {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--bg-card);
  box-shadow: 0 50px 100px -40px color-mix(in srgb, var(--accent) 35%, transparent);
}

.lp-reel__screen video {
  width: 100%;
  aspect-ratio: 1280 / 752;
  object-fit: cover;
}

.lp-reel__tabs {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin-top: 24px;
}

.lp-reel__tabs button {
  position: relative;
  display: grid;
  gap: 6px;
  padding: 16px 0 0;
  border: 0;
  border-top: 1px solid var(--line-strong);
  background: none;
  color: var(--text-muted);
  text-align: left;
  cursor: pointer;
  transition: color 0.3s var(--ease);
}

.lp-reel__tabs button:hover,
.lp-reel__tabs button[aria-pressed="true"] {
  color: var(--text);
}

.lp-reel__index {
  color: var(--text-faint);
  font-size: 0.75rem;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.14em;
}

.lp-reel__name {
  font-family: var(--font-display);
  font-size: clamp(1.25rem, 2.2vw, 1.6rem);
  line-height: 1.1;
}

.lp-reel__progress {
  position: absolute;
  top: -1px;
  left: 0;
  width: var(--progress, 0%);
  height: 1px;
  background: var(--accent);
}

@media (max-width: 640px) {
  .lp-reel__tabs {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* ---------------------------------------------------
   Before / after comparison (see setupCompare)
--------------------------------------------------- */
.lp-compare {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  align-items: center;
  gap: clamp(48px, 8vw, 120px);
}

.lp-compare .heading {
  margin-top: 20px;
}

.lp-compare__lead {
  margin-top: 24px;
}

.compare {
  --pos: 50%;
  position: relative;
  width: min(100%, 440px);
  margin-inline: auto;
  overflow: hidden;
  border-radius: 28px;
  box-shadow: 0 40px 80px -24px rgba(0, 0, 0, 0.8);
  touch-action: pan-y;
  user-select: none;
}

.compare img {
  width: 100%;
  aspect-ratio: 13 / 20;
  object-fit: cover;
  pointer-events: none;
}

.compare__before {
  position: absolute;
  inset: 0;
  height: 100%;
  clip-path: inset(0 calc(100% - var(--pos)) 0 0);
}

.compare__handle {
  position: absolute;
  top: 0;
  bottom: 0;
  left: var(--pos);
  width: 2px;
  margin-left: -1px;
  background: var(--text);
  pointer-events: none;
}

.compare__handle::after {
  content: "‹ ›";
  position: absolute;
  top: 50%;
  left: 50%;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--text);
  color: var(--bg);
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  transform: translate(-50%, -50%);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}

.compare__label {
  position: absolute;
  top: 16px;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(11, 11, 12, 0.6);
  color: var(--text);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  pointer-events: none;
}

.compare__label--before {
  left: 16px;
}

.compare__label--after {
  right: 16px;
}

.compare__range {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  opacity: 0;
  cursor: ew-resize;
}

.compare:has(.compare__range:focus-visible) {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
}

.style-strip {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 10px;
  margin-top: 40px;
  list-style: none;
}

.style-strip img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  object-position: top;
  border-radius: 12px;
}

.style-strip span {
  display: block;
  margin-top: 8px;
  color: var(--text-muted);
  font-size: 0.75rem;
  line-height: 1.3;
}

@media (max-width: 860px) {
  .lp-compare {
    grid-template-columns: 1fr;
  }

  .style-strip {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

/* ---------------------------------------------------
   Marquee wall ("Made with Vimi AI")
--------------------------------------------------- */
.lp-wall .section-head {
  margin-bottom: 56px;
}

.marquee {
  display: grid;
  gap: 16px;
  overflow: hidden;
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}

.marquee__track {
  display: flex;
  gap: 16px;
  width: max-content;
  list-style: none;
  animation: marquee 60s linear infinite;
}

.marquee__track--reverse {
  animation-direction: reverse;
}

.marquee:hover .marquee__track {
  animation-play-state: paused;
}

.marquee__track img {
  width: clamp(150px, 16vw, 220px);
  aspect-ratio: 13 / 20;
  object-fit: cover;
  border-radius: 16px;
}

@keyframes marquee {
  to {
    transform: translateX(calc(-50% - 8px));
  }
}

@media (prefers-reduced-motion: reduce) {
  .marquee {
    overflow-x: auto;
  }

  .marquee__track {
    animation: none;
  }
}
