/* Shared conversion, localized showcase, QR, and sticky mobile CTA styles. */

.home-walkthrough-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}

.home-walkthrough-actions .home-walkthrough-link {
  margin-top: 0;
}

.home-walkthrough-link.primary-link {
  border-color: #d8ef98;
  background: #d8ef98;
  color: #123024;
}

.home-walkthrough-link.primary-link:hover {
  background: #e5f7af;
  color: #0b2219;
}

/* Desktop QR download card (hidden on mobile where direct store taps convert better). */
.desktop-qr-card {
  display: inline-flex;
  align-items: center;
  gap: 16px;
  margin-top: 24px;
  padding: 12px 16px 12px 12px;
  border: 1px solid rgba(216, 239, 152, 0.28);
  border-radius: 16px;
  background: rgba(8, 38, 28, 0.88);
  color: #f4f0e6;
  max-width: 100%;
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.24);
}

.desktop-qr-card img {
  display: block;
  width: 88px;
  height: 88px;
  flex: 0 0 88px;
  border-radius: 10px;
  background: #fffdf7;
  padding: 4px;
}

.desktop-qr-card strong {
  display: block;
  color: #fffdf7;
  font-size: 14px;
  font-weight: 720;
  line-height: 1.3;
}

.desktop-qr-card span {
  display: block;
  margin-top: 4px;
  color: rgba(244, 240, 230, 0.74);
  font-size: 12.5px;
  line-height: 1.45;
  max-width: 28ch;
}

.editorial-qr-card {
  margin-top: 16px;
  border-color: #405331;
  background: #08261c;
}

/* OS-aware button priority when site.js detects iOS or Android. */
html[data-platform="android"] .home-hero-actions,
html[data-platform="android"] .seo-cta-section,
html[data-platform="android"] .editorial-stores,
html[data-platform="android"] .store-row,
html[data-platform="android"] .plant-clinic-cta-buttons {
  display: flex;
  flex-wrap: wrap;
}

.is-store-preferred {
  order: -1;
}

/* Localized 3-card product showcase on non-English homepages. */
.locale-screen-strip {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(14px, 2.2vw, 24px);
  margin-top: 12px;
  padding-top: 24px;
  border-top: 1px solid rgba(244, 240, 230, 0.14);
}

.locale-screen-card {
  margin: 0;
  overflow: hidden;
  border: 1px solid rgba(216, 239, 152, 0.2);
  border-radius: 20px;
  background: #061c14;
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.28);
  transition: transform 200ms ease, border-color 200ms ease;
}

.locale-screen-card:hover {
  transform: translateY(-3px);
  border-color: rgba(216, 239, 152, 0.48);
}

.locale-screen-card img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 9 / 16;
  object-fit: cover;
}

/* Download landing page layout */
.download-hub-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(260px, 0.85fr);
  gap: clamp(24px, 4vw, 48px);
  align-items: center;
}

.download-hub-facts {
  display: grid;
  gap: 10px;
  margin: 22px 0 0;
  padding: 0;
  list-style: none;
  color: rgba(245, 241, 232, 0.82);
  font-size: 15px;
}

.download-hub-facts li {
  display: flex;
  gap: 10px;
  align-items: flex-start;
}

.download-hub-facts li::before {
  content: "";
  width: 7px;
  height: 7px;
  flex: 0 0 7px;
  margin-top: 8px;
  border-radius: 50%;
  background: #c8e37d;
}

.download-qr-panel {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 14px;
  padding: 28px 24px;
  border: 1px solid rgba(200, 227, 125, 0.34);
  border-radius: 20px;
  background: rgba(13, 29, 18, 0.88);
  box-shadow: 0 20px 48px rgba(0, 0, 0, 0.28);
}

.download-qr-panel img {
  width: 176px;
  height: 176px;
  border-radius: 14px;
  background: #fffdf7;
  padding: 8px;
}

.download-qr-panel strong {
  color: #fffdf7;
  font-size: 16px;
}

.download-qr-panel span {
  color: rgba(245, 241, 232, 0.72);
  font-size: 13.5px;
  max-width: 28ch;
}

/* Sticky mobile app download bar (mobile viewports only, shown after scroll). */
.mobile-app-bar {
  display: none;
}

@media (max-width: 860px) {
  .desktop-qr-card,
  .download-qr-panel {
    display: none;
  }

  .download-hub-grid {
    grid-template-columns: 1fr;
  }

  .mobile-app-bar {
    position: fixed;
    inset-inline: 12px;
    bottom: max(12px, env(safe-area-inset-bottom));
    z-index: 60;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border: 1px solid rgba(216, 239, 152, 0.36);
    border-radius: 16px;
    background: rgba(5, 28, 20, 0.96);
    color: #fffdf7;
    box-shadow: 0 14px 36px rgba(0, 0, 0, 0.44);
    backdrop-filter: blur(14px);
    transform: translateY(140%);
    opacity: 0;
    pointer-events: none;
    transition: transform 220ms ease, opacity 220ms ease;
  }

  .mobile-app-bar.is-visible {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }

  .mobile-app-bar.is-dismissed {
    display: none;
  }

  .mobile-app-bar__icon {
    width: 36px;
    height: 36px;
    flex: 0 0 36px;
    border-radius: 9px;
  }

  .mobile-app-bar__copy {
    min-width: 0;
    flex: 1 1 auto;
    line-height: 1.22;
  }

  .mobile-app-bar__copy strong {
    display: block;
    color: #fffdf7;
    font-size: 13.5px;
    font-weight: 760;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .mobile-app-bar__copy small {
    display: block;
    color: rgba(244, 240, 230, 0.74);
    font-size: 11.5px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .mobile-app-bar__cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 38px;
    padding: 0 14px;
    border-radius: 10px;
    background: #d8ef98;
    color: #123024 !important;
    font-size: 13px;
    font-weight: 760;
    text-decoration: none !important;
    white-space: nowrap;
    flex: 0 0 auto;
  }

  .mobile-app-bar__close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    padding: 0;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: rgba(244, 240, 230, 0.72);
    font-size: 18px;
    line-height: 1;
    cursor: pointer;
    flex: 0 0 auto;
  }

  .mobile-app-bar__close:hover,
  .mobile-app-bar__close:focus-visible {
    color: #fffdf7;
    background: rgba(255, 255, 255, 0.1);
  }
}

@media (max-width: 760px) {
  .locale-screen-strip {
    grid-template-columns: repeat(3, minmax(190px, 1fr));
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    padding-bottom: 8px;
    margin-inline: -4px;
    padding-inline: 4px;
  }

  .locale-screen-card {
    scroll-snap-align: start;
    border-radius: 16px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .locale-screen-card,
  .mobile-app-bar {
    transition: none !important;
    transform: none;
  }
}
