/* playbgt.com shop: card hover, focus, tap and reveal layer (BGT-048 L3).
   Author: BGT Video Producer, original, 2026-11-16. Owned by Solid State Strategies.
   Visual layer only: no change to prices, titles, copy, links, Gumroad URLs or listings.
   Load after /shop/shop.css. Uses existing classes: .shop-grid, .shop-card, .shop-cover, .shop-buy,
   .shop-pass, .sc-card, .sc-best. */

.shop-card, .sc-card { --lift: 0px; position: relative; transform: translateY(var(--lift)); transition: transform 220ms cubic-bezier(.22,1,.36,1), box-shadow 220ms cubic-bezier(.22,1,.36,1), border-color 160ms ease-out; will-change: auto; }
.shop-card .shop-cover { transition: transform 420ms cubic-bezier(.22,1,.36,1), filter 220ms ease-out; transform-origin: 50% 60%; }

/* hover: only on devices that truly hover, so touch never gets a stuck lifted card */
@media (hover: hover) and (pointer: fine) {
  .shop-card:hover, .sc-card:hover { --lift: -4px; box-shadow: 0 14px 32px rgba(11,42,68,.16); border-color: rgba(20,40,70,.22); }
  .shop-card:hover .shop-cover { transform: scale(1.03); }
  .shop-card.shop-pass:hover { box-shadow: 0 16px 40px rgba(11,42,68,.2), 0 0 0 4px rgba(252,193,74,.28); }
  .sc-best:hover { box-shadow: 0 18px 44px rgba(11,42,68,.32); }
}
/* keyboard parity: the same lift and a visible ring when any link in the card has keyboard focus */
.shop-card:focus-within, .sc-card:focus-within { --lift: -4px; box-shadow: 0 14px 32px rgba(11,42,68,.16), 0 0 0 3px #123A5C; }
.shop-card:focus-within .shop-cover { transform: scale(1.03); }
.sc-best:focus-within { box-shadow: 0 18px 44px rgba(11,42,68,.32), 0 0 0 3px #FCC14A; }
.shop-card :focus-visible, .sc-card :focus-visible { outline: 3px solid #123A5C; outline-offset: 3px; }
.sc-best :focus-visible { outline-color: #FCC14A; }
/* cards whose focus came from a mouse click do not keep the ring */
.shop-card:focus-within:not(:has(:focus-visible)), .sc-card:focus-within:not(:has(:focus-visible)) { --lift: 0px; box-shadow: 0 2px 10px rgba(20,40,70,.06); }
.shop-card:focus-within:not(:has(:focus-visible)) .shop-cover { transform: none; }
/* tap feedback on touch */
.shop-card:active, .sc-card:active { transform: translateY(var(--lift)) scale(.99); transition-duration: 90ms; }
.shop-buy .bgt-btn { transition: transform 140ms ease-out, background-color 140ms ease-out; }
.shop-buy .bgt-btn:active { transform: scale(.97); }

/* reveal on scroll: only when the script has opted the page in (html.bgt-reveal), so no-JS shows everything */
.bgt-reveal .shop-card:not(.is-in), .bgt-reveal .sc-card:not(.is-in) { opacity: 0; transform: translateY(18px); }
.bgt-reveal .shop-card.is-in, .bgt-reveal .sc-card.is-in { opacity: 1; transition: opacity 420ms ease-out var(--rd, 0ms), transform 420ms cubic-bezier(.22,1,.36,1) var(--rd, 0ms), box-shadow 220ms, border-color 160ms; }
.bgt-reveal .shop-card.is-in.is-done, .bgt-reveal .sc-card.is-in.is-done { transition: transform 220ms cubic-bezier(.22,1,.36,1), box-shadow 220ms cubic-bezier(.22,1,.36,1), border-color 160ms ease-out; }

/* reduced motion: no movement, no scaling, no reveal; color and shadow feedback stay */
@media (prefers-reduced-motion: reduce) {
  .shop-card, .sc-card, .shop-card .shop-cover, .shop-buy .bgt-btn { transition: box-shadow 1ms, border-color 1ms !important; }
  .shop-card, .sc-card, .shop-card:hover, .sc-card:hover, .shop-card:focus-within, .sc-card:focus-within { --lift: 0px !important; }
  .shop-card .shop-cover, .shop-card:hover .shop-cover, .shop-card:focus-within .shop-cover { transform: none !important; }
  .shop-card:active, .sc-card:active, .shop-buy .bgt-btn:active { transform: none !important; }
  .bgt-reveal .shop-card, .bgt-reveal .sc-card { opacity: 1 !important; transform: none !important; }
}
