.sticky-cta {
  display: none;
}

/* Use the hero's compact breakpoint; desktop fallback layouts stay unchanged. */
@media (max-width: 959px), (max-width: 1200px) and (pointer: coarse) {
  body[data-phase="ready"][data-scroll-layout="stacked"][data-sticky-cta] {
    padding-bottom: var(--sticky-cta-height, calc(80px + env(safe-area-inset-bottom, 0px)));
  }

  body[data-phase="ready"][data-scroll-layout="stacked"] .sticky-cta:not([hidden]) {
    position: fixed;
    inset: auto 0 0;
    z-index: 130;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px max(16px, env(safe-area-inset-right, 0px))
      calc(12px + env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px));
    border-top: 1px solid var(--glass-border);
    background: var(--bg-outer);
    color: var(--text-color);
    font: 400 16px/1.4 var(--font-main);
  }

  .sticky-cta p {
    flex: 1 1 0;
    min-width: 0;
    margin: 0;
    color: var(--muted-color);
    overflow-wrap: anywhere;
  }

  .sticky-cta-actions {
    display: flex;
    flex: 0 1 68%;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 8px;
    min-width: 0;
  }

  .sticky-cta-actions > a,
  .sticky-cta-actions > button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 44px;
    min-height: 44px;
    max-width: 100%;
    padding: 10px 12px;
    border: 1px solid var(--accent);
    border-radius: var(--radius);
    background: var(--accent);
    color: var(--ink);
    font: 700 16px/1.35 var(--font-main);
    text-align: center;
    text-decoration: none;
    overflow-wrap: anywhere;
    cursor: pointer;
    touch-action: manipulation;
  }

  .sticky-cta-actions > .sticky-cta-notify {
    background: var(--bg-outer);
    color: var(--text-color);
  }

  .sticky-cta-actions > [hidden],
  body:has(dialog[open]) .sticky-cta,
  body:has(#bag-toggle[aria-expanded="true"]) .sticky-cta {
    display: none !important;
  }

  .sticky-cta :focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 3px;
  }
}

/* No entrance animation, including when the device requests reduced motion. */
@media (prefers-reduced-motion: reduce) {
  .sticky-cta,
  .sticky-cta * {
    animation: none;
    transition: none;
  }
}
