/* Amboras-scale store cover-flow — screenshots are 16:10 (1280×800) */

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.hero-coverflow {
  position: relative;
  width: 100%;
  max-width: none;
  margin: 0 auto;
  padding: 0;
  overflow: visible;
  touch-action: pan-y;
}

.hero-coverflow-stage {
  position: relative;
  width: 100%;
  height: clamp(360px, 52vh, 580px);
  perspective: 1800px;
  perspective-origin: 50% 42%;
  transform-style: preserve-3d;
  overflow: visible;
  touch-action: pan-y;
  cursor: grab;
}

.hero-coverflow-stage.is-dragging {
  cursor: grabbing;
}

.hero-coverflow-stage::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: 2%;
  width: min(70%, 720px);
  height: 48px;
  transform: translateX(-50%);
  background: radial-gradient(ellipse at center, rgba(34, 197, 94, 0.18) 0%, transparent 70%);
  filter: blur(18px);
  pointer-events: none;
  z-index: 0;
}

.hero-coverflow-card {
  position: absolute;
  top: 50%;
  left: 50%;
  width: min(62vw, 820px);
  transform-style: preserve-3d;
  transition:
    transform 0.45s cubic-bezier(0.22, 1, 0.36, 1),
    opacity 0.45s ease,
    filter 0.45s ease;
  will-change: transform, opacity;
  text-decoration: none;
  color: inherit;
  outline: none;
  border-radius: 16px;
  backface-visibility: hidden;
  cursor: pointer;
  -webkit-user-drag: none;
  user-select: none;
}

.hero-coverflow-card:focus-visible {
  box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.55);
}

.hero-coverflow-card[data-offset="0"] {
  z-index: 5;
  opacity: 1;
  filter: none;
  transform: translate3d(-50%, -52%, 80px) rotateY(0deg) scale(1);
  pointer-events: auto;
}

.hero-coverflow-card[data-offset="-1"] {
  z-index: 3;
  opacity: 0.78;
  filter: brightness(0.72) saturate(0.9);
  transform: translate3d(-50%, -50%, -120px) translateX(-68%) rotateY(34deg) scale(0.84);
  pointer-events: auto;
}

.hero-coverflow-card[data-offset="1"] {
  z-index: 3;
  opacity: 0.78;
  filter: brightness(0.72) saturate(0.9);
  transform: translate3d(-50%, -50%, -120px) translateX(68%) rotateY(-34deg) scale(0.84);
  pointer-events: auto;
}

.hero-coverflow-card[data-offset="-2"] {
  z-index: 1;
  opacity: 0.42;
  filter: brightness(0.55) saturate(0.75);
  transform: translate3d(-50%, -50%, -240px) translateX(-112%) rotateY(44deg) scale(0.7);
  pointer-events: auto;
}

.hero-coverflow-card[data-offset="2"] {
  z-index: 1;
  opacity: 0.42;
  filter: brightness(0.55) saturate(0.75);
  transform: translate3d(-50%, -50%, -240px) translateX(112%) rotateY(-44deg) scale(0.7);
  pointer-events: auto;
}

.hero-coverflow-card[data-offset="hide"] {
  z-index: 0;
  opacity: 0;
  pointer-events: none;
  transform: translate3d(-50%, -50%, -360px) scale(0.55);
}

.hero-coverflow-browser {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  background: #0a0e0c;
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow:
    0 30px 80px rgba(0, 0, 0, 0.55),
    0 2px 0 rgba(255, 255, 255, 0.04) inset;
}

.hero-coverflow-card[data-offset="0"] .hero-coverflow-browser {
  box-shadow:
    0 40px 100px rgba(0, 0, 0, 0.65),
    0 0 0 1px rgba(255, 255, 255, 0.08),
    0 0 60px rgba(34, 197, 94, 0.08);
}

.hero-coverflow-browser .hero-browser-chrome {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.02));
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.hero-coverflow-browser .hero-browser-dots {
  display: flex;
  gap: 6px;
  flex-shrink: 0;
}

.hero-coverflow-browser .hero-browser-dots span {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.18);
}

.hero-coverflow-browser .hero-browser-dots span:nth-child(1) { background: #ff5f57; }
.hero-coverflow-browser .hero-browser-dots span:nth-child(2) { background: #febc2e; }
.hero-coverflow-browser .hero-browser-dots span:nth-child(3) { background: #28c840; }

.hero-coverflow-browser .hero-browser-address {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 0.72rem;
  color: rgba(167, 185, 173, 0.95);
  background: rgba(0, 0, 0, 0.35);
  padding: 5px 12px;
  border-radius: 999px;
  flex: 1;
  min-width: 0;
  direction: ltr;
}

.hero-coverflow-browser .hero-store-url {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hero-coverflow-browser .hero-live-pill {
  font-size: 0.62rem;
  font-weight: 700;
  color: #042713;
  background: #4ade80;
  padding: 4px 10px;
  border-radius: 999px;
  flex-shrink: 0;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* Exact 16:10 to match store WebPs — fills frame with no letterbox */
.hero-coverflow-shot {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 10;
  background: #0a0a0f;
  overflow: hidden;
}

.hero-coverflow-shot img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  display: block;
  pointer-events: none;
}

.hero-coverflow-preview-cue {
  position: absolute;
  left: 50%;
  bottom: 18px;
  z-index: 4;
  display: flex;
  align-items: center;
  justify-content: center;
  transform: translate(-50%, 8px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
  background: none;
}

.hero-coverflow-preview-cue span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  border-radius: 999px;
  background: rgba(34, 197, 94, 0.96);
  color: #042713;
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.45);
  white-space: nowrap;
}

@media (hover: hover) and (pointer: fine) {
  .hero-coverflow-card.is-center:hover .hero-coverflow-preview-cue {
    opacity: 1;
    transform: translate(-50%, 0);
  }
}

.hero-coverflow-card.is-center:focus-visible .hero-coverflow-browser {
  outline: 2px solid #86efac;
  outline-offset: 3px;
}

.hero-coverflow-caption {
  margin: 1.1rem 1rem 0;
  text-align: center;
  font-size: 0.9rem;
  color: rgba(148, 163, 156, 1);
  line-height: 1.5;
}

.hero-coverflow-dots {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-top: 1rem;
}

.hero-coverflow-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  border: 0;
  padding: 0;
  background: rgba(255, 255, 255, 0.22);
  cursor: pointer;
  transition: background 0.2s ease, transform 0.2s ease;
}

.hero-coverflow-dot[aria-current="true"] {
  background: #4ade80;
  transform: scale(1.3);
}

.hero-coverflow-dot:focus-visible {
  outline: 2px solid #86efac;
  outline-offset: 2px;
}

.hero-coverflow-swipe-hint {
  display: none;
  text-align: center;
  font-size: 0.75rem;
  color: rgba(148, 163, 156, 0.85);
  margin-top: 0.35rem;
}

@media (max-width: 1100px) {
  .hero-coverflow-card {
    width: min(72vw, 680px);
  }

  .hero-coverflow-stage {
    height: clamp(320px, 48vh, 480px);
  }
}

@media (max-width: 760px) {
  .hero-coverflow-stage {
    height: clamp(220px, 40vw + 120px, 300px);
    perspective: 1100px;
  }

  .hero-coverflow-card {
    width: min(90vw, 400px);
  }

  .hero-coverflow-card[data-offset="-1"] {
    transform: translate3d(-50%, -50%, -80px) translateX(-42%) rotateY(24deg) scale(0.9);
  }

  .hero-coverflow-card[data-offset="1"] {
    transform: translate3d(-50%, -50%, -80px) translateX(42%) rotateY(-24deg) scale(0.9);
  }

  .hero-coverflow-card[data-offset="-2"],
  .hero-coverflow-card[data-offset="2"] {
    opacity: 0;
    pointer-events: none;
  }

  .hero-coverflow-caption {
    font-size: 0.78rem;
    padding: 0 12px;
  }

  .hero-coverflow-swipe-hint {
    display: block;
    margin-top: 0.55rem;
  }

  .hero-coverflow-browser .hero-browser-chrome {
    padding: 8px 10px;
  }

  .hero-coverflow-browser .hero-live-pill {
    font-size: 0.55rem;
    padding: 3px 8px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero-coverflow-card {
    transition: none;
  }
}
