:root {
  --home-ease: cubic-bezier(0.22, 0.8, 0.22, 1);
  /* A 260ms critically damped spring (framer-motion spring(), bounce 0), as a CSS curve. */
  --home-settle: 300ms linear(0, 0.3315, 0.6844, 0.8694, 0.9496, 0.9814, 0.9933, 0.9977, 1, 1);
  --landing-reveal-duration: 360ms;
  --landing-reveal-travel: 10px;
}

.home-header {
  z-index: 20;
  height: 72px;
}

.home-header .header-inner {
  position: fixed;
  inset-inline: 0;
  top: 0;
  z-index: 20;
  background: var(--surface);
}

.home-nav-panel {
  display: contents;
}

.home-header .home-menu-toggle,
.home-header .mobile-download-cta,
.home-header .menu-download,
.hero .hero-download,
.hero-mobile-art,
.showcase .gallery-mobile {
  display: none;
}

.period {
  position: relative;
  isolation: isolate;
}

.period.has-pill::before {
  position: absolute;
  inset-block: 3px;
  left: 0;
  z-index: -1;
  box-sizing: border-box;
  width: var(--pill-width);
  content: '';
  background: white;
  border: 1px solid var(--line);
  border-radius: inherit;
  box-shadow: 0 1px 3px #11172912;
  transform: translateX(var(--pill-x));
}

.period.has-pill button[aria-pressed='true'] {
  background: transparent;
  border-color: transparent;
  box-shadow: none;
}
@media (prefers-reduced-motion: no-preference) {
  .period.has-pill::before {
    transition: transform 220ms var(--home-ease), width 220ms var(--home-ease);
  }
}

.preview-stage {
  content-visibility: auto;
}

/* Desktop cards animate their own hover sequence (home.js), so the shared hover zoom stays off. */
@media (min-width: 901px) {
  .feature:hover .preview-stage {
    transform: none;
  }
}

.preview-interactive-tabs,
.preview-background-restore,
.preview-style-set[data-style-repeat] {
  display: none;
}

.preview-edit-before {
  position: absolute;
  inset: 0;
  opacity: 0;
}

.preview-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;

  /* The clip is the photo's centre square; contain lines it up with the photo underneath. */
  object-fit: contain;
  opacity: 0;
}

[data-preview-video] .preview-video {
  opacity: 1;
}

[data-feature-preview='create'] .preview-cursor {
  z-index: 2;
}

@media (min-width: 901px) and (hover: hover) and (pointer: fine) {
  [data-preview-ready] {
    z-index: 2;
    pointer-events: none;
  }

  [data-preview-ready] .preview-static-tabs {
    display: none;
  }

  [data-preview-ready] .preview-interactive-tabs {
    --preview-tab-padding: calc(2 * var(--preview-unit));

    z-index: 1;
    display: flex;
    pointer-events: auto;
    isolation: isolate;
  }

  .preview-active-pill {
    position: absolute;
    inset-block: var(--preview-tab-padding);
    inset-inline-start: var(--preview-tab-padding);
    z-index: -1;
    width: calc(50% - var(--preview-tab-padding));
    background: white;
    border: 1px solid var(--line);
    border-radius: inherit;
  }

  .preview-interactive-tabs button {
    padding: 0;
    color: var(--muted);
    background: transparent;
    border: 0;
    border-radius: inherit;
  }

  .preview-interactive-tabs button[aria-pressed='true'] {
    color: var(--ink);
  }

  [data-preview-mode='video'] .preview-active-pill {
    translate: 100% 0;
  }

  [data-preview-cursor='video'] .preview-cursor {
    translate: calc(90 * var(--preview-unit)) 0;
  }

  [data-preview-mode='image'] .preview-play {
    opacity: 0;
  }
}

@media (min-width: 901px) and (hover: hover) and (pointer: fine) and (prefers-reduced-motion: no-preference) {
  .feature-preview {
    --feature-preview-motion: 280ms var(--home-ease);
  }

  [data-feature-preview='create'] :is(.preview-video, .preview-play) {
    transition: opacity var(--feature-preview-motion);
  }

  [data-preview-marquee] .preview-style-track {
    animation: preview-style-marquee 12s linear infinite reverse paused;
  }

  [data-preview-marquee] .preview-style-column:nth-child(2) .preview-style-track {
    animation-duration: 18s;
    animation-direction: normal;
  }

  .preview-style-set[data-style-repeat] {
    position: absolute;
    inset-inline: 0;
    display: grid;
  }

  [data-style-repeat='before'] {
    bottom: calc(100% + var(--preview-style-gap));
  }

  [data-style-repeat='after'] {
    top: calc(100% + var(--preview-style-gap));
  }

  .feature:hover [data-preview-marquee][data-preview-in-view] .preview-style-track {
    animation-play-state: running;
  }

  @keyframes preview-style-marquee {
    from {
      translate: 0 0;
    }

    to {
      translate: 0 calc(-100% - var(--preview-style-gap));
    }
  }

  .preview-background-restore {
    position: absolute;
    inset-block: 0;
    inset-inline: 48.4% 0;
    display: block;
    clip-path: inset(0 100% 0 0);
    background: url('https://r2.starryai.com/public/marketing/site/2026-12-01/home/feature-background-before-456w.webp') left center / 200% 100%
      no-repeat;
  }
}

.home-header .float-cta,
.composer-options {
  display: none;
}

.home-prompt {
  position: relative;
}

.home-prompt .composer-submit {
  display: inline-flex;
  flex: none;
  gap: 6px;
  align-items: center;
  height: 44px;
  padding: 0 14px 0 20px;
  margin-left: auto;
  font-size: 15px;
  font-weight: 600;
  color: white;
  white-space: nowrap;
  background: var(--purple);
  border-radius: 999px;
}

.home-prompt .composer-submit:hover {
  background: #4207ab;
}

.art-trigger {
  display: block;
  padding: 0;
  text-align: inherit;
  background: transparent;
  border: 0;
  border-radius: 20px;
}

.showcase .gallery {
  overflow: visible;
}

.art-trigger:focus-visible {
  outline-offset: -4px;
}

.gallery-details {
  width: min(1064px, calc(100% - 48px));
  max-width: none;
  height: min(772px, calc(100dvh - 48px));
  max-height: none;
  padding: 0;
  overflow: hidden;
  color: var(--ink);
  background: white;
  border: 0;
  border-radius: 20px;
}

.gallery-details::backdrop {
  background: rgb(0 0 0 / 20%);
  backdrop-filter: blur(6px);
}

html {
  scroll-behavior: auto;
  scrollbar-gutter: stable;
}

html:has(.gallery-details[open], .marketing-login-dialog[open]) {
  overflow: hidden;
}

html[data-restore-scroll] {
  overflow-anchor: none;
}

html[data-restore-scroll] .home-header * {
  transition: none;
}

.art-layout {
  display: grid;
  grid-template:
    'stage profile' auto
    'stage sidebar' minmax(0, 1fr) / minmax(0, 1fr) min(360px, 40%);
  height: 100%;
}

.art-stage {
  position: relative;
  grid-area: stage;
  overflow: hidden;
  isolation: isolate;
}

.art-stage::before {
  position: absolute;
  inset: -20%;
  z-index: -1;
  content: '';
  background: var(--art-image) center / cover;
  filter: blur(40px);
}

.art-stage > img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.review-card > picture {
  display: block;
  align-self: start;
}

.art-sidebar {
  display: flex;
  flex-direction: column;
  grid-area: sidebar;
  gap: 20px;
  justify-content: space-between;
  padding: 0 24px 24px;
  overflow: auto;
  font-size: 14px;
  font-weight: 500;
  border-left: 1px solid var(--line);
}

.art-info {
  border-top: 1px solid var(--line);
}

.art-row {
  padding-block: 20px;
  border-bottom: 1px solid var(--line);
}

.art-row:last-child {
  border: 0;
}

.art-profile,
.art-label {
  display: flex;
  gap: 12px;
  align-items: center;
}

.art-profile {
  grid-area: profile;
  padding: 24px 24px 20px;
  font-size: 14px;
  border-left: 1px solid var(--line);
}

.art-profile form,
.art-label button {
  margin-left: auto;
}

.art-profile strong {
  font-weight: 600;
}

/* Creator initial in a brand-tinted circle. */
.art-avatar {
  display: grid;
  flex: none;
  place-items: center;
  width: 40px;
  height: 40px;
  font-size: 16px;
  font-weight: 600;
  color: var(--purple);
  background: #f1ebfd;
  border-radius: 50%;
}

.art-label {
  color: var(--text);
}

.art-sidebar p {
  margin-top: 4px;
}

.art-profile button,
.art-sidebar button {
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  background: transparent;
  border: 0;
  border-radius: 6px;
}

.art-profile button:hover,
.art-sidebar button:hover {
  background: var(--surface-hover);
}

.art-sidebar button[data-copied] {
  background: var(--surface-hover);
}

.art-remix {
  flex-shrink: 0;
  min-height: 48px;
}

@media (min-width: 901px) {
  .hero-art::before {
    position: absolute;
    top: 14%;
    left: 43%;
    width: clamp(96px, 9vw, 144px);
    aspect-ratio: 413 / 304;
    content: '';
    background: image-set(
        url('https://r2.starryai.com/public/marketing/site/2026-12-01/gallery-boat-256w.webp') 1x,
        url('https://r2.starryai.com/public/marketing/site/2026-12-01/gallery-boat-620w.webp') 2x
      )
      center / cover;
    border-radius: 2px;
    translate: -50% 0;
  }
}

/* Keep the original composition at 1440px and spread its anchors on wider screens. */
@media (min-width: 1440px) {
  .hero-art {
    width: 100%;
  }

  .art-garden {
    left: 5.56%;
  }

  .art-floral {
    right: 5.56%;
    left: auto;
  }

  .art-green {
    left: 71.88%;
  }

  .art-product {
    left: 56.81%;
  }

  .art-cyber {
    left: 20.63%;
  }

  .art-anime {
    right: -33px;
    left: auto;
  }

  .art-portrait {
    left: -8px;
  }
}

@media (min-width: 901px) {
  .hero-scroll {
    margin-top: -72px;
  }

  .hero-scroll .hero {
    min-height: 100svh;
    padding-block: 72px 0;
  }
}

.hero-art .hero-art-extra {
  display: none;
}

@media (min-width: 901px) and (prefers-reduced-motion: no-preference) {
  /* The art sequence plays over 0.8 screens of scrolling (was 2), so the next section arrives sooner. */
  .hero-scroll {
    height: 180svh;
  }

  .hero-scroll .hero {
    position: sticky;
    top: 0;
    height: 100svh;
  }

  .hero-scroll .hero-art {
    --detail-scale: calc(var(--hero-exit, 0) * var(--hero-exit, 0));

    /* Frame the opening crop while preserving the original 1.8-to-0.88 zoom ratio. */
    scale: calc(1.13 / 1.8 * (1.8 - 0.92 * var(--hero-exit, 0)));
    animation: hero-art-arrival 500ms var(--home-ease) backwards;
  }

  /* Keep smaller pieces legible as the canvas pulls back. */
  .hero-scroll .hero-art::before {
    scale: calc(1 + 0.38 * var(--detail-scale));
    translate: -50% calc(-130px * var(--detail-scale));
  }

  .hero-scroll .hero-art :is(.art-green, .art-portrait, .art-product) {
    scale: calc(1 + 0.65 * var(--detail-scale));
  }

  .hero-scroll .hero-art :is(.art-garden, .art-anime, .art-floral, .art-cyber) {
    scale: calc(1 + var(--medium-art-enlargement, 0.35) * var(--detail-scale));
  }

  /* The extra pieces start outside the opening crop and enter with the canvas. */
  .hero-art .hero-art-extra {
    display: block;
  }

  .hero-art .art-shell {
    top: 4%;
    right: 106%;
    width: min(24vw, 420px, 45svh);
  }

  .hero-art .art-room {
    top: 31%;
    left: 113%;
    width: min(23vw, 390px, 42svh);
  }

  .hero-art .art-ceramic {
    top: 71%;
    right: 120%;
    width: min(17vw, 288px, 28svh);
  }

  .hero-art .art-space {
    top: 72%;
    left: 125%;
    width: min(14vw, 242px, 28svh);
  }

  /* Inner artwork is visible in the opening crop; the outer pieces enter as it widens. */
  .hero-scroll .hero-art .art-green {
    top: calc(22.23% + 40px);
    left: 66%;
    transform: translateY(calc(-55px * var(--detail-scale)));
    translate: 0 calc(-100px * var(--detail-scale));
  }

  .hero-scroll .hero-art .art-anime {
    translate: 0 calc(95px * var(--detail-scale));
  }

  .hero-scroll .hero-art .art-cyber {
    top: max(calc(70% + 48px), calc(50% + 318px));
    left: 24%;
    translate: 0 calc(215px * var(--hero-exit, 0));
  }

  .hero-scroll .hero-art .art-product {
    translate: 0 calc(255px * var(--hero-exit, 0));
  }
}

@media (min-width: 901px) and (max-width: 1800px) and (prefers-reduced-motion: no-preference) {
  .hero-scroll .hero-art .art-floral {
    translate: calc(180px * var(--hero-exit, 0)) calc(330px * var(--hero-exit, 0));
  }
}

@media (min-width: 901px) and (max-width: 1600px) and (prefers-reduced-motion: no-preference) {
  .hero-scroll .hero-art :is(.art-garden, .art-green, .art-anime) {
    translate: 0 calc(-205px * var(--hero-exit, 0));
  }

  .hero-scroll .hero-art .art-portrait {
    translate: calc(-54px * var(--hero-exit, 0)) calc(365px * var(--hero-exit, 0));
  }
}

@media (min-width: 901px) and (max-width: 1350px) and (prefers-reduced-motion: no-preference) {
  .hero-scroll .hero-art {
    --medium-art-enlargement: 0.15;
  }
}

@media (min-width: 901px) and (max-width: 1100px) and (prefers-reduced-motion: no-preference) {
  .hero-scroll .hero-art .art-garden {
    width: 154px;
    translate: 0 calc(-250px * var(--hero-exit, 0));
  }

  .hero-scroll .hero-art .art-green {
    translate: 0 calc(-32px - 205px * var(--hero-exit, 0));
  }

  .hero-scroll .hero-art .art-anime {
    width: 174px;
  }

  .hero-scroll .hero-art .art-floral {
    width: 145px;
    translate: calc(30px + 150px * var(--hero-exit, 0)) calc(145px + 200px * var(--hero-exit, 0));
  }
}

@media (min-width: 901px) and (max-width: 1439px) {
  .hero-scroll .art-garden {
    left: 3%;
  }

  .hero-scroll .art-floral {
    right: 3%;
    left: auto;
  }

  .hero-scroll .art-green {
    left: 72%;
    display: block;
  }

  .hero-scroll .art-anime {
    right: -3%;
    left: auto;
    display: block;
  }

  .hero-scroll .art-portrait {
    left: -8px;
  }
}

@media (min-width: 901px) {
  .hero-art .art-garden {
    top: 11.5%;
  }

  .hero-art .art-floral {
    top: 61.4%;
  }

  .hero-art .art-green {
    top: 4.5%;
  }

  .hero-art .art-product {
    top: 79.8%;
  }

  .hero-art .art-cyber {
    top: 77.1%;
  }

  .hero-art .art-anime {
    top: 19.8%;
  }

  .hero-art .art-portrait {
    top: 67.6%;
  }
}

@media (min-width: 901px) {
  .home-header .header-inner {
    --wide: min(100%, 1440px);
    --pill: min(1064px, calc(100% - 48px));
    --scroll-progress: var(--nav-progress, 0);
    --p: calc(var(--scroll-progress) * var(--scroll-progress) * (3 - 2 * var(--scroll-progress)));

    top: calc(16px * var(--p));
    column-gap: 0;
    width: calc(var(--wide) + (var(--pill) - var(--wide)) * var(--p));
    min-height: calc(72px - 6px * var(--p));
    padding-inline: calc(var(--gutter) + (32px - var(--gutter)) * var(--p))
      calc(var(--gutter) + (12px - var(--gutter)) * var(--p));
    border: 1px solid transparent;
    border-radius: calc(40px * var(--p));
  }

  .home-header .header-inner::before {
    position: absolute;
    inset: -1px;
    pointer-events: none;
    content: '';
    border: 1px solid var(--line);
    border-radius: inherit;
    box-shadow: var(--shadow-card);
    opacity: var(--p);
  }

  .home-header .main-nav {
    margin-left: 48px;
  }

  .home-header .login {
    height: 40px;
    min-height: 40px;
    padding-inline: 16px;
  }

  /* Always in view beside Login, so starting is one click from anywhere on the page. */
  .home-header .float-cta {
    display: inline-flex;
    flex-shrink: 0;
    height: 40px;
    min-height: 40px;
    padding-inline: 17px;
    margin-left: 8px;
    white-space: nowrap;
    border-width: 0;
  }


  .home-prompt {
    display: block;
    height: 66px;
    padding: 12px;
    transition: height 380ms var(--home-ease), border-color 220ms ease, box-shadow 220ms ease;
  }

  .home-prompt.is-active {
    height: 134px;
    border-color: var(--purple);
    box-shadow: inset 0 0 0 1px var(--purple);
  }

  .home-prompt > input {
    display: block;
    width: calc(100% - 180px);
    height: 40px;
  }

  .home-prompt .composer-submit {
    position: absolute;
    right: 12px;
    bottom: 12px;
  }

  .home-prompt .composer-options {
    position: absolute;
    top: 80px;
    right: 180px;
    bottom: 12px;
    left: 12px;
    display: flex;
    gap: 8px;
    align-items: flex-start;
    overflow: clip;
    visibility: hidden;
    opacity: 0;
    transition: opacity 170ms ease, visibility 170ms;
  }

  .home-prompt.is-active .composer-options {
    visibility: visible;
    opacity: 1;
    transition-delay: 60ms, 0s;
  }

  .home-prompt.is-active .composer-options:focus-within {
    overflow: visible;
  }

  .composer-error {
    grid-column: 1/-1;
    font-size: 14px;
    color: var(--error);
  }

  .home-prompt .composer-error:not([hidden]) {
    position: absolute;
    inset-inline: 0;
    top: 100%;
  }

  .home-prompt .composer-options :is(button, .attach-control) {
    font-size: 14px;
    font-weight: 500;
    color: var(--ink);
    cursor: pointer;
  }

  .composer-icon,
  .composer-tabs {
    display: inline-flex;
    flex: none;
    align-items: center;
    height: 40px;
    background: var(--surface-hover);
    border-radius: 99px;
  }

  .composer-icon {
    justify-content: center;
    width: 40px;
    list-style: none;
  }

  .attach-control {
    position: relative;
  }

  .attach-control input {
    position: absolute;
    inset: 0;
    width: 100%;
    cursor: pointer;
    opacity: 0;
  }

  .attach-control:focus-within {
    outline: 2px solid var(--purple);
  }

  .composer-tabs {
    justify-content: space-between;
    min-width: 182px;
    padding: 2px;
  }

  .home-prompt .composer-tabs button {
    height: 36px;
    padding: 8px 12px;
    white-space: nowrap;
    background: transparent;
    border-radius: 99px;
  }

  .home-prompt .composer-tabs button[aria-pressed='true'] {
    background: white;
    box-shadow: 0 1px 4px #03071226;
  }

  .closing img {
    margin-bottom: 32px;
  }

  .period {
    min-height: 40px;
    margin-bottom: 24px;
  }

  .pricing h2 {
    margin-bottom: 54px;
  }

  .plans {
    min-height: 472px;
  }

  .faq {
    column-gap: 20px;
    padding-bottom: 200px;
  }

  .faq-list summary {
    min-height: 61px;
  }

  .closing p {
    margin-bottom: 32px;
  }

  .faq-list details p {
    line-height: 20px;
  }

  .closing {
    padding-top: 0;
  }

  .review-card {
    width: min(846px, 100%);
  }

  .review-controls {
    margin-top: 54px;
  }

  .gallery-stats {
    width: min(1064px, 84%);
    min-height: 68px;
  }
}
@media (max-width: 650px) {
  .gallery-details {
    position: fixed;
    inset: auto 0 0;
    width: 100%;
    height: auto;
    max-height: min(760px, calc(100dvh - 24px));
    margin: 0;
    border-radius: 20px 20px 0 0;
  }

  .art-layout {
    grid-template:
      'profile' auto
      'stage' clamp(160px, 42dvh, 320px)
      'sidebar' minmax(0, 1fr) / minmax(0, 1fr);
    height: auto;
    max-height: inherit;
  }

  .art-profile {
    padding: 8px 16px;
    border-left: 0;
  }

  .art-profile button {
    width: 44px;
    height: 44px;
  }

  .art-sidebar {
    padding: 16px;
    padding-bottom: max(16px, env(safe-area-inset-bottom));
    border-left: 0;
  }

  .art-info {
    border-top: 0;
  }
}
@media (max-width: 900px) and (prefers-reduced-motion: no-preference) {
  .hero,
  .pr-hero {
    --word-start: 64ms;
    --word-step: 28ms;
    --hero-copy-delay: calc(var(--word-start) + var(--last-word) * var(--word-step) + 120ms);
    --hero-action-delay: calc(var(--hero-copy-delay) + 80ms);
  }

  .reveal-enter,
  .hero-content > :where(.trust, p, .home-prompt, .hero-download, .hero-web),
  .hero :where(.hero-word, .hero-art, .hero-mobile-art),
  .pr-hero
    :where(
      .hero-word,
      .pr-eyebrow,
      .pr-intro,
      .pr-hero-actions,
      .pr-hero-center > .app-first-download,
      .pr-upload,
      .pr-trust,
      .pr-hero-art
    ) {
    animation: landing-reveal var(--landing-reveal-duration) var(--home-ease)
      var(--reveal-delay, 0ms) backwards;
  }

  .reveal-pending:not(:focus-within) {
    opacity: 0;
  }

  .hero-word {
    --reveal-delay: calc(var(--word-start) + var(--word-index) * var(--word-step));

    display: inline-block;
  }

  .hero-content > p,
  .pr-hero .pr-intro {
    --reveal-delay: var(--hero-copy-delay);
  }

  .hero-content > :is(.home-prompt, .hero-download, .hero-web),
  .pr-hero
    :is(.pr-hero-actions, .pr-hero-center > .app-first-download, .pr-upload, .pr-trust) {
    --reveal-delay: var(--hero-action-delay);
  }

  .pr-hero-art {
    --reveal-delay: calc(var(--hero-action-delay) + 160ms);
  }

  .hero-mobile-art {
    --reveal-delay: calc(var(--hero-action-delay) + 160ms);
  }

  .restored-viewport
    .hero
    :is(.hero-word, .trust, p, .home-prompt, .hero-download, .hero-web, .hero-art, .hero-mobile-art):not(
      .reveal-enter
    ) {
    animation: none;
  }

  @keyframes landing-reveal {
    from {
      opacity: 0;
      translate: 0 var(--landing-reveal-travel);
    }
  }

  /* Phone gallery images rise like the desktop gallery's cards. */
  .gallery-mobile .art-trigger.reveal-enter,
  .pr-gallery .art-trigger.reveal-enter {
    animation: gallery-rise 700ms var(--home-ease) var(--reveal-delay, 0ms) backwards;
  }

  @keyframes gallery-rise {
    from {
      opacity: 0;
      translate: 0 48px;
    }
  }
}

@media (min-width: 901px) and (prefers-reduced-motion: no-preference) {
  .hero-content,
  .pr-hero {
    --word-start: 80ms;
    --word-step: 40ms;
    --word-duration: 500ms;
    --headline-end: calc(
      var(--word-start) + var(--last-word) * var(--word-step) + var(--word-duration)
    );
  }

  .reveal-enter,
  .hero-content > :where(.trust, p, .home-prompt),
  .pr-hero :where(.pr-eyebrow, .pr-intro, .pr-hero-actions, .pr-upload, .pr-trust) {
    animation: desktop-landing-reveal 500ms cubic-bezier(0.23, 1, 0.32, 1) var(--reveal-delay, 0ms)
      backwards;
  }

  .hero-word {
    display: inline-block;
    animation: headline-word var(--word-duration) cubic-bezier(0.25, 0.1, 0.25, 1) backwards;
    animation-delay: calc(var(--word-start) + var(--word-index) * var(--word-step));
  }
  @keyframes headline-word {
    from {
      filter: blur(10px);
      opacity: 0;
      transform: translateY(20%);
    }
  }

  .hero-content > p,
  .pr-hero .pr-intro {
    animation-delay: var(--headline-end);
  }

  .hero-content > :is(.home-prompt, .hero-download, .hero-web),
  .pr-hero :is(.pr-hero-actions, .pr-upload) {
    animation-delay: calc(var(--headline-end) + 100ms);
  }

  /* Product pages: their artwork arrives like the homepage canvas. */
  .pr-hero-art,
  .pr-hero-upload > :is(.pr-star, .pr-compare) {
    animation: hero-art-arrival 500ms var(--home-ease) backwards;
  }

  .reveal-pending:not(:focus-within) {
    opacity: 0;
  }

  /* What a reload lands on rises out of a soft blur, in the headline words' language. */
  .reveal-in-view {
    animation: reload-reveal 700ms cubic-bezier(0.23, 1, 0.32, 1) var(--reveal-delay, 0ms) backwards;
  }

  @keyframes reload-reveal {
    from {
      filter: blur(6px);
      opacity: 0;
      translate: 0 24px;
    }
  }

  .restored-viewport
    .hero
    :is(.hero-word, .trust, p, .home-prompt, .hero-download, .hero-web, .hero-art, .hero-mobile-art) {
    animation: none;
  }
  @keyframes desktop-landing-reveal {
    from {
      opacity: 0;
      translate: 0 16px;
    }
  }

  @keyframes hero-art-arrival {
    from {
      opacity: 0;
      transform: scale(1.025);
    }
  }
}

@media (prefers-reduced-motion: no-preference) {
  .nav-dropdown[open] .nav-menu {
    animation: home-settle var(--home-settle) both;
  }
  @keyframes home-settle {
    from {
      opacity: 0;
      transform: translateY(6px);
    }

    to {
      opacity: 1;
      transform: none;
    }
  }
  @media (hover: hover) and (pointer: fine) {
    /* Cover the cards' hover overhang while keeping the fade at its original height. */
    .showcase .gallery::after {
      inset-inline: -1%;
      bottom: -9px;
      box-sizing: content-box;
      background-repeat: no-repeat;
      background-origin: padding-box;
      border-bottom: 8px solid white;
    }

    .gallery .art-trigger {
      transition: scale 650ms
        linear(
          0,
          0.008,
          0.032 2%,
          0.13 4.4%,
          0.26 6.6%,
          0.681 13%,
          0.891 17.1%,
          0.968,
          1.028,
          1.073,
          1.103 25.2%,
          1.114,
          1.119,
          1.12,
          1.115 31.4%,
          1.098 34.4%,
          1.042 41.6%,
          1.017 45.4%,
          0.998 49.5%,
          0.988 53.9%,
          0.986 60.4%,
          1.001 80.9% 100%
        );
    }

    .gallery .art-trigger:not(.card-waiting, .card-entering):hover {
      scale: 1.015;
    }
  }
}

@media (width > 650px) and (prefers-reduced-motion: no-preference) {
  .showcase:has(.card-entering) {
    clip-path: inset(-100vmax -100vmax 0);
  }

  .showcase:has(.card-entering)::after {
    position: absolute;
    inset: auto calc(50% - 50vw) 0;
    height: 40px;
    pointer-events: none;
    content: '';
    background: linear-gradient(transparent, white);
  }

  .gallery-desktop .card-waiting:where(:not(:focus-visible)),
  .pr-gallery .gallery .card-waiting:where(:not(:focus-visible)),
  .gallery-waiting .art-trigger:where(:not(.card-entering, .card-settled, :focus-visible)) {
    opacity: 0;
  }

  .gallery-desktop .card-entering,
  .pr-gallery .gallery .card-entering {
    animation: gallery-entry var(--entry-duration) var(--home-ease) var(--entry-delay) backwards;
  }

  .gallery-desktop .card-entering:focus-visible,
  .pr-gallery .gallery .card-entering:focus-visible {
    animation-duration: 0s;
    animation-delay: 0s;
  }

  @keyframes gallery-entry {
    from {
      opacity: 0;
      transform: translateY(var(--entry-y));
    }

    to {
      opacity: 1;
      transform: none;
    }
  }

  /* Rising cards stay behind the fade instead of showing below it.
     overflow clips on whole pixels; a clip-path edge anti-aliases and leaks a 1px line of card. */
  .showcase .gallery-desktop:has(.card-entering),
  .pr-gallery .gallery:has(.card-entering) {
    overflow-y: clip;
  }

  /* The fade is in place from the start. The stats pill rises in with the desktop card rise,
     starting as the last card starts (home.js sets --gallery-stats-delay). */
  .gallery-waiting + .gallery-stats {
    visibility: hidden;
    opacity: 0;
  }

  .gallery-desktop:not(.gallery-waiting) + .gallery-stats,
  .pr-gallery .gallery:not(.gallery-waiting) + .gallery-stats {
    animation: gallery-stats-entry 700ms var(--home-ease) var(--gallery-stats-delay, 0ms) backwards;
  }

  /* translate, not transform: the pill is centred with transform. */
  @keyframes gallery-stats-entry {
    from {
      opacity: 0;
      translate: 0 48px;
    }
  }
}

.faq-list summary::before,
.faq-list summary::after,
.faq-list details[open] summary::after {
  position: absolute;
  top: 50%;
  right: 20px;
  width: 20px;
  height: 20px;
  content: '';
  background: url('https://r2.starryai.com/public/marketing/site/2026-12-01/faq-minus.svg') center/contain no-repeat;
  transform: translateY(-50%);
}

/* The plus's upright bar turns down onto the flat one, on the answer's clock (home.js faqDuration). */
.faq-list summary::before {
  transition: transform 280ms var(--home-ease);
  transform: translateY(-50%) rotate(90deg);
}

/* Once it lands it fades, so two overlapping anti-aliased bars do not read as a bolder minus. */
.faq-list details[open]:not([data-faq-closing]) summary::before {
  opacity: 0;
  transition: transform 280ms var(--home-ease), opacity 80ms linear 200ms;
  transform: translateY(-50%) rotate(180deg);
}

.preview-stage img.preview-icon {
  width: calc(var(--icon-size) * var(--preview-unit));
  height: auto;
}

/* A shadow below the faded last row leaves a hard seam. */
.gallery > div > .art-trigger:where(:last-child) img {
  box-shadow: none;
}

.home-prompt .composer-submit img {
  filter: brightness(0) invert(1);
}

.home-header .nav-dropdown[open] summary img {
  transform: rotate(180deg);
}
@media (max-width: 900px) {
  /* When the first sentence wraps, the second continues on its line instead of leaving a lone word. */
  .feature p br {
    display: none;
  }
}
@media (min-width: 901px) {
  .review-heart {
    top: 47px;
    width: min(17.23vw, 248px);
  }

  .review-star {
    bottom: 64px;
    width: min(13.4vw, 193px);
  }
}

/* Parallax: while the reviews section passes through the viewport, the heart drifts
   further than the star, so they read as two depths. Linear, tied to scroll. */
@media (min-width: 901px) and (prefers-reduced-motion: no-preference) {
  @supports (view-timeline: --reviews-pass block) {
    .reviews {
      /* stylelint-disable-next-line property-no-unknown */
      view-timeline: --reviews-pass block;
    }

    /* About 25% and 15% off the page's scroll speed over the section's pass,
       each turning slowly the opposite way so they read as floating objects. */
    .review-heart {
      --review-drift: 240px;
      --review-turn: -6deg;
    }

    .review-star {
      --review-drift: 140px;
      --review-turn: 10deg;
    }

    .reviews .review-decoration {
      animation: review-drift auto linear both;
      /* stylelint-disable-next-line property-no-unknown */
      animation-timeline: --reviews-pass;
    }

    @keyframes review-drift {
      from {
        rotate: var(--review-turn);
        translate: 0 var(--review-drift);
      }

      to {
        rotate: calc(-1 * var(--review-turn));
        translate: 0 calc(-1 * var(--review-drift));
      }
    }
  }
}

/* Keep controls interactive during transitions. The spring is sampled once at prerender. */
@media (prefers-reduced-motion: no-preference) {
  .gallery-details[open] {
    animation: art-enter 420ms var(--home-ease) both;
  }
  @keyframes art-enter {
    from {
      opacity: 0;
      transform: translateY(18px) scale(0.965);
    }

    to {
      opacity: 1;
      transform: none;
    }
  }

  @media (max-width: 650px) {
    .gallery-details[open] {
      animation: art-drawer-enter 360ms cubic-bezier(0.32, 0.72, 0, 1) both;
    }

    @keyframes art-drawer-enter {
      from {
        transform: translateY(100%);
      }

      to {
        transform: translateY(0);
      }
    }
  }

  .gallery-details[open]::backdrop {
    animation: scrim-in 320ms ease both;
  }

  .gallery-details[data-closing]::backdrop {
    animation: scrim-out 240ms ease both;
  }
  @keyframes scrim-in {
    from {
      opacity: 0;
    }

    to {
      opacity: 1;
    }
  }
  @keyframes scrim-out {
    from {
      opacity: 1;
    }

    to {
      opacity: 0;
    }
  }

  .period button,
  .composer-tabs button,
  .composer-icon {
    transition: background-color 150ms ease, color 150ms ease;
  }
}

.preview-style-gallery {
  inset-inline: auto;
  left: 50%;
  grid-template-columns: repeat(3, 1fr);
  gap: calc(20 * var(--preview-unit));
  width: calc(634 * var(--preview-unit));
  transform: translateX(-50%);
}

.preview-style-column {
  --preview-style-gap: calc(20 * var(--preview-unit));
}

.preview-style-column:nth-child(2) {
  transform: none;
}

.preview-shot {
  outline: calc(6 * var(--preview-unit)) solid #fff6;
}

@media (min-width: 901px) {
  .pricing {
    scroll-margin-top: 24px;
  }

  .composer-options {
    min-width: 0;
  }
}
@media (prefers-reduced-motion: no-preference) {
  .art-trigger,
  .composer-submit,
  :where(.home-header) .button,
  .art-remix,
  .controls button {
    --home-control-transitions: transform 140ms cubic-bezier(0.23, 1, 0.32, 1),
      background-color 150ms ease, border-color 150ms ease;

    transition: var(--home-control-transitions);
  }

  .art-trigger:active,
  .composer-submit:enabled:active,
  .home-header .button:active,
  .art-remix:active,
  .controls button:enabled:active {
    transform: scale(0.98);
  }

  .home-header summary img {
    transition: transform 160ms cubic-bezier(0.23, 1, 0.32, 1);
  }
}

.review-copy {
  display: grid;
  isolation: isolate;
}

.review-copy .review-card {
  grid-area: 1 / 1;
}

.plans .price {
  font-variant-numeric: tabular-nums;
}

.plan-art {
  flex: none;
}

.plan-benefit-mobile {
  display: none;
}

.review-slides .review-card {
  pointer-events: none;
  visibility: hidden;
}

.review-slides .review-card.is-current {
  z-index: 1;
  pointer-events: auto;
  visibility: visible;
}

.review-slides .review-card.is-leaving {
  visibility: visible;
}

.review-slides .review-card.is-front {
  z-index: 2;
}

.price-digits {
  display: inline-flex;
  white-space: pre;
  vertical-align: top;
}

.price-digit {
  display: inline-grid;
  width: 1ch;
  overflow: clip;
}

.price-digit::before,
.price-digit::after {
  grid-area: 1 / 1;
  transition: transform 160ms cubic-bezier(0.3, 0, 0.2, 1);
}

.price-digit::before {
  content: attr(data-annual-digit);
}

.price-digit::after {
  content: attr(data-month-digit);
  transform: translateY(100%);
}

[data-price-period='monthly'] .price-digit::before {
  transform: translateY(-100%);
}

[data-price-period='monthly'] .price-digit::after {
  transform: translateY(0);
}

.plans .billing {
  display: grid;
}

.plans .billing > span,
.plans .billing::before,
.plans .billing::after {
  grid-area: 1 / 1;
}

.plans .billing::before {
  visibility: hidden;
  content: attr(data-annual-billing) / '';
}

.plans .billing::after {
  visibility: hidden;
  content: attr(data-monthly-billing) / '';
}

.faq-list details[open] summary {
  padding-bottom: 20px;
}

.faq-answer {
  overflow: clip;
}

@media (min-width: 901px) {
  .faq-answer {
    margin-block-start: -12px;
  }
}

.faq-list details p {
  padding-bottom: 20px;
  margin-block: 0;
}

@media (prefers-reduced-motion: reduce) {
  .home-prompt,
  .home-prompt .composer-options,
  .faq-list summary::before,
  .faq-list details[open]:not([data-faq-closing]) summary::before,
  .price-digit::before,
  .price-digit::after {
    transition: none;
  }
}

@media (max-width: 650px) {
  :is(.features, .showcase, .reviews, .pricing, .faq) h2 {
    font-size: 30px;
    font-weight: 500;
    line-height: 40px;
    letter-spacing: -1.2px;
  }

  :is(.reviews-inner, .closing) > p {
    font-size: 16px;
    font-weight: 500;
    line-height: 22px;
    letter-spacing: -0.01em;
  }

  .closing p {
    margin: 16px 0 24px;
  }
}

/* Phone and tablet header: burger menu sheet, and the download button that joins Login on scroll. */
@media (max-width: 900px) {
  .home-header {
    position: sticky;
    top: 0;
  }

  .home-header .header-inner {
    position: relative;
    column-gap: 8px;
    justify-content: space-between;
    width: 100%;
    padding-inline: var(--gutter);
  }

  .home-header .mobile-download-cta {
    display: inline-flex;
    min-width: 0;
    min-height: 40px;

    /* 16px sides from about 390px; a little less on the narrowest phones so words stay whole. */
    padding: 5px clamp(12px, 4.1vw, 16px);
    margin-inline-start: auto;
    font-size: 14px;
    line-height: 1.15;
    text-align: center;
    overflow-wrap: anywhere;
    pointer-events: none;
    touch-action: manipulation;
    visibility: hidden;
    opacity: 0;
  }

  .home-header.is-floating .mobile-download-cta {
    pointer-events: auto;
    visibility: visible;
    opacity: 1;
  }

  @media (prefers-reduced-motion: no-preference) {
    .home-header .mobile-download-cta {
      --mobile-cta-transition: 260ms cubic-bezier(0.25, 0.46, 0.45, 0.94);

      translate: 6px 0;
      transition: var(--home-control-transitions), opacity var(--mobile-cta-transition),
        translate var(--mobile-cta-transition), visibility 260ms;
    }

    .home-header.is-floating .mobile-download-cta {
      translate: 0;
    }
  }

  :where(#main, #features, #pricing) {
    scroll-margin-top: 72px;
  }

  .home-header .home-menu-toggle {
    display: inline-grid;
    flex: none;
    place-items: center;
    width: 44px;
    height: 44px;
    padding: 0;
    color: var(--ink);
    background: transparent;
    border: 0;
  }

  /* No blue tap flash on the menu's controls (same as the FAQ questions). */
  .home-header :is(.home-menu-toggle, .home-nav-panel a, .home-nav-panel summary, .login) {
    -webkit-tap-highlight-color: transparent;
  }

  .menu-icon {
    display: block;
  }

  .menu-icon path {
    stroke: currentcolor;
    stroke-linecap: round;
    stroke-width: 2;
    transition: opacity 150ms ease;
    transform-box: view-box;
  }

  /* Open: the outer bars swing in to cross and the middle one fades. */
  .menu-bar-top {
    transform-origin: 12px 7px;
  }

  .menu-bar-bottom {
    transform-origin: 12px 17px;
  }

  .home-menu-toggle[aria-expanded='true'] .menu-bar-top {
    rotate: 45deg;
    translate: 0 5px;
  }

  .home-menu-toggle[aria-expanded='true'] .menu-bar-middle {
    opacity: 0;
  }

  .home-menu-toggle[aria-expanded='true'] .menu-bar-bottom {
    rotate: -45deg;
    translate: 0 -5px;
  }

  @media (prefers-reduced-motion: no-preference) {
    .menu-icon path {
      transition: translate 340ms cubic-bezier(0.4, 0, 0.2, 1),
        rotate 340ms cubic-bezier(0.4, 0, 0.2, 1), opacity 200ms ease;
    }
  }

  .home-header .home-nav-panel {
    display: none;
  }

  /* A full-height sheet under the 72px header; home.js sets data-open and animates it in and out. */
  .home-header .home-nav-panel[data-open] {
    position: fixed;
    inset: 72px 0 0;
    display: flex;
    flex-direction: column;
    padding-bottom: env(safe-area-inset-bottom);
    overflow-y: auto;
    overscroll-behavior: contain;
    background: white;
    border-top: 1px solid var(--line);
  }

  .home-nav-panel .main-nav {
    display: flex;
    flex: 1 0 auto;
    flex-direction: column;
    gap: 24px;
    align-items: stretch;
    padding: 24px var(--gutter);
    font-size: 20px;
    line-height: 30px;
    letter-spacing: -0.01em;
  }

  .home-nav-panel .main-nav > * + * {
    padding-top: 24px;
    border-top: 1px solid var(--line);
  }

  .home-nav-panel .main-nav > a,
  .home-nav-panel .nav-dropdown summary {
    display: flex;
    gap: 6px;
    align-items: center;
    justify-content: space-between;
  }

  /* Same size as the burger icon, centred under it (the toggle pads its 24px icon by 10px). */
  .home-nav-panel .nav-dropdown summary img {
    width: 24px;
    height: 24px;
    margin-inline-end: 10px;
  }

  .home-nav-panel .nav-menu {
    position: static;
    display: flex;
    flex-direction: column;
    gap: 20px;
    width: auto;
    min-width: 0;
    max-width: none;
    padding: 24px 0 0;
    font-size: 16px;
    line-height: 24px;
    border: 0;
    border-radius: 0;
    box-shadow: none;
  }

  .home-nav-panel .nav-menu a {
    padding: 0;
    color: var(--muted);
  }

  /* The bottom actions: Download app, then Login, 12px apart. */
  .home-header .home-nav-panel[data-open] .menu-download {
    display: flex;
    flex: none;
    order: 1;
    margin: 24px var(--gutter) 0;
  }

  .home-nav-panel .login {
    flex: none;
    order: 2;
    min-height: 44px;
    margin: 12px var(--gutter) 24px;
  }

  /* While the menu is open, the header's download button gives way to the one in the sheet. */
  .home-header:has(.home-menu-toggle[aria-expanded='true']) .mobile-download-cta {
    pointer-events: none;
    visibility: hidden;
    opacity: 0;
  }

  .menu-open {
    overflow: hidden;
  }

  /* home.js opens and closes Features; the chevron turns on the same 400ms drawer curve. */
  .home-nav-panel .nav-dropdown[open] .nav-menu {
    animation: none;
  }

  .home-nav-panel .nav-dropdown:not(.is-open) summary img {
    transform: none;
  }

  @media (prefers-reduced-motion: no-preference) {
    .home-header .home-nav-panel summary img {
      transition: transform 400ms cubic-bezier(0.32, 0.72, 0, 1);
    }
  }
}

@media (max-width: 900px) {
  .hero {
    padding-block: 48px 32px;
  }

  .hero :is(.hero-art, .home-prompt) {
    display: none;
  }

  .hero-mobile-art img {
    width: 100%;
    height: auto;
    border-radius: 12px;
  }

  .hero .trust {
    flex-wrap: wrap;
    gap: 12px;
    font-size: 14px;
    line-height: 1.3;
  }

  .hero .avatars img {
    border-color: var(--line);
  }

  .hero .avatars img + img {
    margin-left: -6px;
  }

  .hero h1 {
    margin-block: 16px 20px;
    font-size: 40px;
    font-weight: 500;
    line-height: 52px;
    letter-spacing: -1.6px;
  }

  .hero-content > p {
    margin: 0;
    font-size: 16px;
    font-weight: 500;
    line-height: 22px;
    letter-spacing: -0.01em;
  }

  .hero .hero-download {
    display: flex;
    gap: 12px;
    min-height: 54px;
    margin-top: 24px;
    font-size: 18px;
    line-height: 1.4;
  }

  .hero .hero-web {
    display: flex;
    min-height: 54px;
    margin-top: 12px;
    font-size: 18px;
    line-height: 1.4;
  }

  .hero-mobile-art {
    --hero-art-gap: 8px;
    --hero-art-card: min(109px, calc((100vw - 2 * var(--gutter) - 2 * var(--hero-art-gap)) / 3));

    display: grid;
    grid-auto-columns: var(--hero-art-card);
    grid-auto-flow: column;
    gap: var(--hero-art-gap);
    align-items: center;
    width: 100%;
    padding-inline: var(--gutter);
    margin-top: 48px;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scrollbar-width: none;
    scroll-snap-type: x mandatory;
    scroll-padding-inline: var(--gutter);
  }

  .hero-mobile-art > picture {
    scroll-snap-align: start;
  }

  .hero-mobile-art[data-loop] {
    padding-inline: 0;
    scroll-padding-inline: 0;
  }

  .hero-mobile-art[data-loop] > picture {
    scroll-snap-align: center;
  }

  /* The art only glides by itself; swiping it fought the autoplay. */
  @media (prefers-reduced-motion: no-preference) {
    .hero-mobile-art[data-loop] {
      overflow-x: hidden;
    }
  }

  .hero-mobile-art[data-autoplay] {
    scroll-snap-type: none;
  }

  .hero-mobile-art:focus-visible {
    outline-offset: -2px;
  }

  @supports (animation-timeline: view(inline)) {
    @media (prefers-reduced-motion: no-preference) {
      .hero-mobile-art img {
        --hero-art-step: calc(var(--hero-art-card) + var(--hero-art-gap));

        animation: hero-art-scale auto ease-in-out both;
        /* stylelint-disable-next-line property-no-unknown */
        animation-timeline: view(inline);
        animation-range: cover calc(50% - var(--hero-art-step)) cover
          calc(50% + var(--hero-art-step));
      }

      @keyframes hero-art-scale {
        0%,
        100% {
          transform: scale(0.86);
        }

        50% {
          transform: scale(1);
        }
      }
    }
  }
}

@media (width > 650px) and (max-width: 900px) {
  .hero-content {
    max-width: 480px;
  }

  .hero-content > p {
    margin-inline: auto;
  }

  .hero :is(.hero-download, .hero-web) {
    width: fit-content;
    padding-inline: 48px;
    margin-inline: auto;
  }

  .gallery-stats {
    width: min(640px, 100%);
  }

  .gallery-stats span {
    flex-direction: row;
    gap: 8px;
    font-size: 14px;
  }

  .gallery-stats strong {
    font-size: 20px;
  }

  .gallery-stats img {
    width: 20px;
    height: 20px;
  }

  .reviews-inner {
    width: min(848px, calc(100% - 2 * var(--gutter)));
  }

  .reviews h2 {
    max-width: 420px;
    margin-inline: auto;
    text-wrap: balance;
  }

  .review-heart {
    right: -20px;
  }

  .review-star {
    left: -12px;
  }

  .review-card {
    grid-template-columns: minmax(0, 232px) 1fr;
    gap: 40px;
    padding: 40px;
  }

  .review-card > :where(picture) > img {
    height: auto;
    aspect-ratio: 232 / 304;
  }

  .review-copy blockquote {
    font-size: 24px;
  }

  /* The sheet's two actions share one row instead of stretching across the tablet width. */
  .home-header .home-nav-panel[data-open] {
    display: grid;
    grid-template:
      'nav nav' 1fr
      'download login' auto / 1fr 1fr;
    column-gap: 12px;
  }

  .home-nav-panel .main-nav {
    grid-area: nav;
  }

  .home-header .home-nav-panel[data-open] .menu-download {
    grid-area: download;
    margin: 24px 0 24px var(--gutter);
  }

  .home-nav-panel .login {
    grid-area: login;
    margin: 24px var(--gutter) 24px 0;
  }

  .faq h2 {
    text-align: center;
  }

  /* "As featured on" sits centred above the logos, the same across tablet
     (landing.css switches to a left-aligned grid below 701px). */
  .home-footer .press {
    flex-direction: column;
    gap: 24px;
    align-items: center;
    padding-block: 80px;
  }

  .home-footer .press div {
    display: flex;
    gap: clamp(24px, 5vw, 72px);
    justify-content: center;
    width: auto;
  }

  .home-footer .press img {
    max-height: none;
  }

  /* Each plan sits on one row: the overview on the left, its benefits beside it. */
  .plans {
    grid-auto-rows: 1fr;
    max-width: none;
  }

  /* Content starts at the top of both columns; the spare height gathers above the button. */
  .plan {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 4px;
    min-height: 326px;
  }

  .plan-overview {
    grid-template-rows: auto auto auto 1fr;
    padding: 24px;
  }

  .plan .button {
    align-self: end;
  }

  /* Beside the overview, the panel takes the overview's corners so the card's right edge stays even. */
  .plan ul {
    gap: 16px;
    padding: 24px;
    margin: 0;
    border-radius: 17px;
  }

  .hero-mobile-art {
    --hero-art-card: max(109px, calc((100vw - 7 * var(--hero-art-gap)) / 6));
  }
}

@media (max-width: 900px) {
  @media (prefers-reduced-motion: no-preference) {
    .hero-mobile-art[data-loop] > picture {
      --hero-art-center-ratio: calc(160 / 109);
      --hero-art-fit-scale: calc(var(--hero-art-ratio) / var(--hero-art-center-ratio));
      --hero-art-inset: calc((1 - var(--hero-art-fit-scale)) * 50%);

      position: relative;
      height: calc(var(--hero-art-card) * var(--hero-art-center-ratio));
      clip-path: inset(var(--hero-art-inset) 0 round 12px);
    }

    /* Tablet shows more resting cards, so they share one square shape instead of each image's own,
       and the grow and shrink spread over a wider stretch (home.js reads --hero-art-reach too). */
    @media (width > 650px) {
      .hero-mobile-art[data-loop] > picture {
        --hero-art-fit-scale: calc(1 / var(--hero-art-center-ratio));
        --hero-art-reach: 1.5;
      }
    }

    .hero-mobile-art[data-loop] img {
      position: absolute;
      top: 0;
      left: 50%;
      display: block;
      width: calc(var(--hero-art-card) / var(--hero-art-fit-scale));
      max-width: none;
      height: 100%;
      border-radius: 0;
      object-fit: cover;
      transform: scale(var(--hero-art-fit-scale));
      translate: -50% 0;
      animation: none;
    }

    .hero-mobile-art[data-center-scale] > picture {
      clip-path: inset(
        calc(var(--hero-art-inset) * (1 - var(--hero-art-height-progress, 0))) 0 round 12px
      );
      transform: scale(calc(0.86 + 0.14 * var(--hero-art-focus, 0)));
      animation: none;
    }

    .hero-mobile-art[data-center-scale] img {
      transform: scale(
        calc(
          var(--hero-art-fit-scale) + (1 - var(--hero-art-fit-scale)) *
            var(--hero-art-height-progress, 0)
        )
      );
      animation: none;
    }

    @supports (animation-timeline: view(inline)) and (view-timeline: --hero-art-position inline) {
      .hero-mobile-art[data-loop]:not([data-center-scale]) > picture {
        --hero-art-step: calc(var(--hero-art-card) + var(--hero-art-gap));
        --hero-art-scale-range: calc(var(--hero-art-step) * var(--hero-art-reach, 1));
        --hero-art-height-range: calc(var(--hero-art-scale-range) * 1.35);
        --hero-art-height-ease: linear(
          0,
          0.03 7%,
          0.1 15%,
          0.25 28%,
          0.5,
          0.75 72%,
          0.9 85%,
          0.97 93%,
          1
        );

        animation: hero-art-scale auto ease-in-out both,
          hero-art-window auto var(--hero-art-height-ease) both;
        /* stylelint-disable-next-line property-no-unknown */
        animation-timeline: --hero-art-position;
        animation-range: cover calc(50% - var(--hero-art-scale-range)) cover
            calc(50% + var(--hero-art-scale-range)),
          cover calc(50% - var(--hero-art-height-range)) cover
            calc(50% + var(--hero-art-height-range));
        /* stylelint-disable-next-line property-no-unknown */
        view-timeline: --hero-art-position inline;
      }

      .hero-mobile-art[data-loop]:not([data-center-scale]) img {
        animation: hero-art-zoom auto var(--hero-art-height-ease) both;
        /* stylelint-disable-next-line property-no-unknown */
        animation-timeline: --hero-art-position;
        animation-range: cover calc(50% - var(--hero-art-height-range)) cover
          calc(50% + var(--hero-art-height-range));
      }

      @keyframes hero-art-window {
        0%,
        100% {
          clip-path: inset(var(--hero-art-inset) 0 round 12px);
        }

        50% {
          clip-path: inset(0 round 12px);
        }
      }

      @keyframes hero-art-zoom {
        0%,
        100% {
          transform: scale(var(--hero-art-fit-scale));
        }

        50% {
          transform: scale(1);
        }
      }
    }
  }
}

@media (max-width: 650px) {
  .features {
    padding-block: 64px;
  }

  .features .section-head {
    margin-bottom: 24px;
  }

  .features h2 {
    max-width: 290px;
  }

  .features .section-head .controls {
    display: none;
  }

  .feature-track {
    --edge: var(--gutter);
    --gap: 16px;

    align-items: center;
    padding-block: 4px;
  }

  .feature {
    flex-basis: min(300px, 82vw);
  }

  .feature-preview {
    aspect-ratio: 300 / 306;
    border-radius: 16px;
  }

  .feature h3 {
    margin-top: 16px;
    line-height: 26px;
  }

  .feature p {
    margin-top: 8px;
    letter-spacing: -0.01em;
  }

  .showcase {
    padding-block: 48px 0;
  }

  .showcase h2 {
    margin-bottom: 24px;
    text-wrap: wrap;
  }

  .showcase .gallery-desktop {
    display: none;
  }

  .showcase .gallery-mobile {
    display: grid;
  }

  .gallery-mobile::after {
    display: none;
  }

  .gallery-mobile .art-trigger,
  .gallery-mobile img {
    border-radius: 12px;
  }

  .showcase .gallery-stats {
    position: static;
    grid-template-columns: 1fr;
    gap: 16px;
    width: calc(100% + 2 * var(--gutter));
    padding: 24px max(var(--gutter), 10vw);
    margin: 48px calc(-1 * var(--gutter)) 0;
    color: #99a1af;
    background: var(--ink);
    border-radius: 0;
    box-shadow: none;
    transform: none;
  }

  .gallery-stats span {
    flex-direction: row;
    gap: 12px;
    justify-content: flex-start;
    min-height: 36px;
    font-size: 16px;
    font-weight: 500;
    line-height: 24px;
    letter-spacing: -0.01em;
  }

  .gallery-stats span + span {
    border: 0;
  }

  .gallery-stats strong {
    font-size: 24px;
    letter-spacing: -0.02em;
  }

  .gallery-stats img {
    width: 24px;
    height: 24px;
  }

  .reviews {
    padding-block: 64px;
  }

  .reviews .review-decoration {
    display: none;
  }

  .reviews .rating {
    margin-bottom: 16px;
  }

  .reviews-inner > p {
    margin: 16px 0 24px;
  }

  .review-card {
    grid-template-rows: auto 1fr;
    border-radius: 20px;
  }

  .review-card > :where(picture) > img {
    border-radius: 12px;
  }

  .review-copy blockquote {
    font-size: 20px;
    line-height: 26px;
  }

  .review-copy figcaption {
    font-size: 16px;
    line-height: 20.8px;
    letter-spacing: -0.01em;
  }

  .review-copy figcaption span {
    margin-top: 4px;
    font-size: 14px;
    line-height: 18.2px;
  }

  .review-controls {
    margin-top: 24px;
  }

  .review-controls button {
    width: 54px;
    height: 40px;
  }

  .pricing {
    padding-block: 64px;
  }

  .pricing h2 {
    max-width: 294px;
    margin: 0 auto 24px;
  }

  .period {
    gap: 0;
    min-height: 40px;
    padding: 2px;
    margin-bottom: 24px;
  }

  .period button {
    min-height: 36px;
    padding: 4px 11px;
    line-height: 20px;
  }

  .period.has-pill::before {
    inset-block: 2px;
  }

  .plan {
    padding: 3px;
    overflow: clip;
    border-radius: 20px;
  }

  .plan-popular {
    padding: 2px;
  }

  .plan-overview {
    border-radius: 16px;
  }

  .plan h3 {
    min-height: 32px;
    line-height: 1.15;
  }

  .plan-icon {
    width: 32px;
    height: 32px;
  }

  .plan .price {
    margin-top: 16px;
    line-height: 28px;
    letter-spacing: -0.01em;
  }

  .plan .billing {
    font-weight: 500;
    line-height: 20px;
    letter-spacing: -0.01em;
  }

  .plan ul {
    line-height: 20px;
  }

  .plan-benefit-desktop {
    display: none;
  }

  .plan-benefit-mobile {
    display: inline;
  }

  .faq {
    gap: 24px;
    padding-block: 48px;
  }

  .faq-list summary {
    padding: 15px 44px 15px 15px;
    font-size: 16px;
    line-height: 24px;
    letter-spacing: -0.01em;
    -webkit-tap-highlight-color: transparent;
  }

  .faq-list summary::before,
  .faq-list summary::after,
  .faq-list details[open] summary::after {
    right: 15px;
  }

  .faq-list details[open] summary {
    padding-bottom: 15px;
  }

  .faq-list details p {
    padding-bottom: 8px;
    line-height: 22px;
  }

  .closing {
    padding-block: 64px;
    background: none;
  }

  .closing img {
    width: 80px;
    height: 80px;
    margin-bottom: 24px;
    border-radius: 25.24px;
  }

  .closing h2 {
    max-width: 290px;
    margin-inline: auto;
    font-size: 32px;
    font-weight: 500;
    line-height: 42px;
    letter-spacing: -1.28px;
  }

  .closing .button {
    width: 100%;
    min-height: 48px;
    line-height: 1.4;
    letter-spacing: -0.01em;
  }

  .home-footer .press {
    gap: 20px;
    align-items: center;
    padding-block: 48px 32px;
  }

  .home-footer .press p {
    font-size: 20px;
    line-height: 30px;
    letter-spacing: -0.02em;
  }

  .home-footer .press div {
    gap: 0;
    justify-items: center;
    min-height: 30px;
  }

  .home-footer .press img {
    width: min(100%, 80px);
  }

  .home-footer .press img:where(:nth-child(2)) {
    width: min(100%, 67px);
  }

  .home-footer .press img:where(:last-child) {
    justify-self: center;
    width: min(100%, 102px);
  }

  .home-footer .footer-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 32px 20px;
  }

  .home-footer .footer-brand {
    grid-column: 1 / -1;
  }

  .home-footer .footer-brand .brand {
    display: flex;
    width: fit-content;
  }

  .home-footer .brand img {
    width: 133px;
    height: 40px;
  }

  .home-footer .footer-brand p {
    margin-top: 12px;
    font-size: 16px;
    line-height: 22px;
    letter-spacing: -0.01em;
  }

  .home-footer nav {
    gap: 12px;
    font-size: 14px;
    line-height: 22px;
  }

  .home-footer .footer-title {
    margin-bottom: 0;
    font-size: inherit;
    line-height: inherit;
  }

  .home-footer .download {
    padding-block: 32px;
  }

  .home-footer .download p {
    margin-bottom: 12px;
    font-size: 16px;
    font-weight: 500;
    line-height: 22px;
    letter-spacing: -0.01em;
  }

  .home-footer .download-row {
    flex-direction: column;
    gap: 24px;
    align-items: flex-start;
  }

  .home-footer .download-links {
    display: grid;
    grid-template-columns: minmax(0, 8fr) minmax(0, 9fr);
    gap: 16px;
    width: min(100%, 322px);
  }

  .home-footer .download-links img {
    width: 100%;
  }

  .home-footer .footer-model-marks {
    height: 24px;
  }

  .home-footer .legal {
    gap: 16px;
    padding-top: 32px;
    font-size: 12px;
    line-height: 17px;
    letter-spacing: -0.01em;
  }

  .home-footer .legal div {
    gap: 8px 24px;
  }

  .home-footer .footer-wordmark {
    height: auto;
    aspect-ratio: 350 / 77;
    margin-top: 40px;
  }
}

/* The phone and tablet sheet ends with its own Download app button. */
@media (max-width: 900px) {
  .home-nav-panel .main-nav > .nav-get-app {
    display: none;
  }
}

/* Closing: on phones "Download app" leads and the web app follows (app-first.tsx). */
.closing-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
}

@media (max-width: 900px) {
  .closing-actions {
    flex-direction: column;
    width: min(100%, 360px);
    margin-inline: auto;
  }

  .closing-actions .button {
    justify-content: center;
    min-height: 54px;
  }
}
