/* ------------------------------------------------------------
   Online store page (pay-online.html)
   ------------------------------------------------------------ */
.header--solid { border-color: var(--color-border); }
.store__hero { padding-bottom: var(--space-10); }
.store__head { max-width: 760px; display: grid; gap: var(--space-5); }
.store__head .lead { max-width: 60ch; }
.store__head .secure { margin-top: 0; }
.store__steps {
  list-style: none;
  padding: 0;
  margin: var(--space-12) 0 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
  gap: var(--space-4);
}
.store__steps li {
  display: flex;
  gap: var(--space-4);
  align-items: flex-start;
  padding: var(--space-5);
  border-radius: var(--radius-lg);
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  max-width: none;
}
.store__steps span,
.store__ready span {
  flex: none;
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--color-text);
  color: var(--color-text-inverse);
  font-family: var(--font-display);
  font-weight: 600;
}
.store__steps strong, .store__ready strong { display: block; font-size: var(--text-sm); margin-bottom: 2px; }
.store__steps small, .store__ready small { display: block; color: var(--color-text-muted); font-size: var(--text-xs); line-height: 1.5; }

/* Package families: A/A1, B/B1, C/C1 */
.store__families { display: grid; gap: var(--space-6); }
.store__family {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 2fr);
  gap: var(--space-8);
  align-items: start;
  padding: var(--space-8);
  border-radius: var(--radius-xl);
  background: var(--tint);
  border: 1px solid rgba(31, 29, 34, 0.06);
}
.store__family-head { display: grid; gap: var(--space-3); }
.store__family-head .eyebrow { margin: 0; }
.store__family-head .muted { max-width: 34ch; }
.store__pair {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-5);
  align-items: stretch;
}
.store__family--movie .store__pair { grid-template-columns: minmax(0, 1fr); max-width: 420px; }
.store__pkg { background: var(--color-surface); padding-top: var(--space-8); }
.store__pkg.pkg--featured { background: var(--color-text); color: var(--color-text-inverse); }
.store__pkg .pkg__desc { min-height: 0; }
.pkg__plus {
  display: inline-block;
  align-self: flex-start;
  margin-top: var(--space-3);
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(31, 29, 34, 0.07);
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: 0.04em;
}
.pkg--featured .pkg__plus { background: rgba(251, 249, 246, 0.14); }
.pkg__list {
  list-style: none;
  padding: 0;
  margin: var(--space-5) 0 0;
  display: grid;
  gap: var(--space-2);
  flex: 1;
  align-content: start;
}
.pkg__list li { display: flex; gap: var(--space-2); align-items: flex-start; font-size: var(--text-sm); max-width: none; }
.pkg__list svg { flex: none; width: 18px; height: 18px; padding: 3px; border-radius: 50%; background: var(--tint, var(--pastel-mint)); color: #1f1d22; margin-top: 2px; }
.pkg--featured .pkg__list svg { background: var(--pastel-butter); }
.store__pkg .store__buy { margin-top: var(--space-6); justify-content: center; width: 100%; }
.pkg--featured .store__buy { --btn-bg: #fbf9f6; --btn-fg: #1f1d22; }
.is-selected { outline: 3px solid var(--color-text); outline-offset: 3px; }
.pkg--featured.is-selected { outline-color: var(--pastel-butter); }

/* Specialty products D to N */
.store__spec {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 230px), 1fr));
  gap: var(--space-4);
}
.spec {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  padding: var(--space-5);
  border-radius: var(--radius-lg);
  background: var(--color-surface);
  border: 1px solid var(--color-border);
}
.spec__code { font-size: var(--text-xs); font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--color-text-muted); }
.spec__name { font-family: var(--font-display); font-weight: 600; font-size: var(--text-lg); letter-spacing: -0.01em; }
.spec__desc { font-size: var(--text-sm); color: var(--color-text-muted); flex: 1; }
.spec .store__buy { margin-top: var(--space-3); justify-content: space-between; width: 100%; }

/* Checkout: what to have ready */
.store__order {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: var(--space-12);
  align-items: start;
}
.store__ready {
  padding: var(--space-6);
  border-radius: var(--radius-xl);
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  display: grid;
  gap: var(--space-5);
}
.store__ready ul { list-style: none; padding: 0; margin: 0; display: grid; gap: var(--space-3); }
.store__ready li { display: flex; gap: var(--space-4); align-items: flex-start; padding: var(--space-3) var(--space-4); border-radius: var(--radius-md); max-width: none; }
.store__ready li.is-key { background: var(--pastel-butter); color: #1f1d22; }
.store__ready li.is-key small { color: rgba(31, 29, 34, 0.7); }
.store__ready .secure { margin: 0; }

@media (min-width: 1000px) {
  .store__spec { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
  .store__family { grid-template-columns: 1fr; gap: var(--space-6); padding: var(--space-6); }
  .store__order { grid-template-columns: 1fr; gap: var(--space-8); }
}
@media (max-width: 560px) {
  .store__pair { grid-template-columns: 1fr; gap: var(--space-8); }
}

/* Product photos on specialty cards */
.spec__img {
  position: relative;
  margin: calc(-1 * var(--space-5)) calc(-1 * var(--space-5)) var(--space-2);
  height: 200px;
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  overflow: hidden;
  background: #fff;
  display: grid;
  place-items: center;
}
[data-theme='dark'] .spec__img { background: var(--color-surface-2); }
.spec__img img { position: absolute; inset: 0; width: 100%; height: 100%; padding: 12px; object-fit: contain; transition: transform 600ms var(--ease-out); }
.spec:hover .spec__img img { transform: scale(1.05); }
.spec__img--letter { background: linear-gradient(135deg, var(--pastel-lilac), var(--pastel-sky)); }
.spec__img--letter span { font-family: var(--font-display); font-weight: 600; font-size: 4rem; color: rgba(31, 29, 34, 0.55); }
.pkg__grip {
  margin: var(--space-4) 0 0;
  display: grid;
  gap: var(--space-2);
  padding: var(--space-3);
  border-radius: var(--radius-md);
  background: #fff;
  border: 1px solid var(--color-border);
}
.pkg__grip-imgs { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-2); }
.pkg__grip-imgs img { width: 100%; height: auto; aspect-ratio: 875 / 533; object-fit: contain; border-radius: var(--radius-sm); }
.pkg__grip figcaption { font-size: var(--text-xs); font-weight: 600; color: #5b5762; line-height: 1.35; text-align: center; }
.spec__img--cover img { padding: 0; object-fit: cover; object-position: center 25%; }

/* Buy button celebration */
.store__buy { position: relative; overflow: visible; isolation: isolate; }
.store__buy::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: #fff;
  opacity: 0;
  pointer-events: none;
}
.store__buy.is-launch::after { animation: shutter 500ms var(--ease-out) forwards; }
.store__buy.is-launch { animation: buyPop 500ms var(--ease-out); }
.pkg.is-launch, .spec.is-launch { animation: cardGlow 900ms var(--ease-out); }
@keyframes shutter { 0% { opacity: 0.95; } 100% { opacity: 0; } }
@keyframes buyPop { 0% { transform: scale(1); } 35% { transform: scale(0.96); } 70% { transform: scale(1.04); } 100% { transform: scale(1); } }
@keyframes cardGlow {
  0% { box-shadow: 0 0 0 0 rgba(251, 235, 195, 0.9); }
  100% { box-shadow: 0 0 0 28px rgba(251, 235, 195, 0); }
}
.confetti { position: absolute; left: 50%; top: 50%; width: 0; height: 0; pointer-events: none; z-index: 2; }
.confetti i {
  position: absolute;
  left: -5px;
  top: -5px;
  width: 12px;
  height: 12px;
  border-radius: 3px;
  box-shadow: 0 1px 2px rgba(31, 29, 34, 0.15);
  opacity: 0;
  animation: confettiFly 1100ms cubic-bezier(0.15, 0.7, 0.3, 1) var(--d) forwards;
}
@keyframes confettiFly {
  0% { opacity: 1; transform: translate(0, 0) rotate(0) scale(0.6); }
  60% { opacity: 1; }
  100% { opacity: 0; transform: translate(var(--x), calc(var(--y) + 60px)) rotate(var(--r)) scale(1); }
}
@media (prefers-reduced-motion: reduce) {
  .store__buy.is-launch, .pkg.is-launch, .spec.is-launch, .store__buy.is-launch::after { animation: none; }
}
