.family-shop { background: #eee8f0; }
.shop-header { display: flex; align-items: flex-start; justify-content: space-between; flex-wrap: wrap; gap: 1rem; }
.shop-header .section-intro { margin-bottom: 0; max-width: 55ch; }
.shop-media-jump { margin-top: .7rem; }
.shop-basket { white-space: nowrap; gap: .6rem; }
.shop-basket span { border-radius: 99px; background: #e7dceb; padding-inline: .5rem; }
.shop-basket-actions { display: flex; flex-wrap: wrap; gap: .6rem; }
.shop-filters { display: flex; flex-wrap: wrap; gap: .5rem; margin: 1.6rem 0 1rem; }
.shop-filters button { min-height: 44px; border: 1px solid #ad9bb7; border-radius: 99px; padding: .5rem .9rem; background: #fffaf8; color: var(--ink); font: inherit; cursor: pointer; }
.shop-filters button[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: #fff; }
.shop-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .85rem; margin-top: 1rem; }
.shop-card { display: flex; flex-direction: column; overflow: hidden; border: 1px solid #e0d5e4; border-radius: 16px; background: #fffdfa; }
.shop-card img { display: block; width: 100%; height: auto; aspect-ratio: 3 / 2; object-fit: cover; background: #ead9c1; }
.shop-card-body { display: flex; flex: 1; flex-direction: column; align-items: flex-start; padding: clamp(1rem, 2vw, 1.4rem); gap: .65rem; }
.shop-card h3 { margin: 0; font: 1.65rem/1.12 var(--serif); }
.shop-format { color: #594169; font-size: .81rem; font-weight: 700; }
.shop-description { color: #493950; line-height: 1.5; }
.shop-price { margin-top: auto; padding-top: .3rem; font-size: 1.22rem; font-weight: 780; }
.shop-card .button { width: 100%; text-align: center; }
.shop-isbn { display: flex; align-items: baseline; gap: .42rem; font-size: .88rem; min-height: 32px; cursor: pointer; }
.shop-isbn input { margin: 0; accent-color: var(--violet); }
.shop-format-choice { display: grid; gap: .3rem; width: 100%; font-size: .88rem; font-weight: 680; }
.shop-format-choice select { width: 100%; min-height: 44px; border: 1px solid #ad9bb7; border-radius: 8px; background: white; color: var(--ink); font: inherit; padding-inline: .5rem; }
.shop-format-choice select:focus-visible { outline: 3px solid #9460cc; outline-offset: 2px; }
.shop-links { display: flex; flex-wrap: wrap; gap: .65rem 1.2rem; }
.shop-media { margin-top: clamp(3rem, 7vw, 5rem); border-top: 1px solid #d9cade; padding-top: clamp(2rem, 5vw, 3.75rem); }
.shop-media h2 { max-width: none; }
.shop-media-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .85rem; }
.shop-media-card { display: grid; grid-template-rows: auto 1fr; overflow: hidden; border: 1px solid #e0d5e4; border-radius: 16px; background: #fffdfa; }
.shop-phone { position: relative; isolation: isolate; aspect-ratio: 4 / 3; background: #ead9c1; }
.shop-media-photo,
.shop-phone-video { position: absolute; inset: 0; display: block; width: 100%; height: 100%; object-fit: cover; }
.shop-phone--audio .shop-media-photo { object-position: 50% 46%; }
.shop-phone-video { opacity: 0; pointer-events: none; clip-path: polygon(38.85% 19.15%, 73.4% 23.05%, 71.45% 51.9%, 36.9% 47.65%); }
.shop-phone[data-started] .shop-phone-video { opacity: 1; }
.shop-phone--audio { --play-x: 78%; --play-y: 58.45%; }
.shop-phone--video { --play-x: 55.7%; --play-y: 35.6%; }
.shop-phone-play {
  position: absolute; left: var(--play-x); top: var(--play-y); translate: -50% -50%;
  display: grid; place-items: center; width: clamp(44px, 12%, 70px); aspect-ratio: 1;
  padding: 0; border: 1px solid #fffaf880; border-radius: 50%;
  background: var(--violet); color: #fffaf1; cursor: pointer;
}
.shop-phone-play::before {
  content: ""; position: absolute; inset: -3px; border: 2px solid var(--lime); border-radius: inherit;
  pointer-events: none; animation: shop-phone-pulse 2.1s ease-out infinite;
}
.shop-phone-play > span {
  width: 32%; aspect-ratio: 1; background: currentColor; translate: 12% 0;
  clip-path: polygon(5% 0, 100% 50%, 5% 100%);
}
.shop-phone:hover .shop-phone-play,
.shop-phone-play:focus-visible,
.shop-phone-play:active { background: var(--lime); color: var(--ink); border-color: var(--lime); }
.shop-phone[data-playing] .shop-phone-play::before { animation: none; opacity: 0; }
.shop-phone[data-playing] .shop-phone-play > span { translate: 0; clip-path: polygon(0 0, 34% 0, 34% 100%, 66% 100%, 66% 0, 100% 0, 100% 100%, 0 100%); }
.shop-phone--video[data-playing] .shop-phone-play { opacity: 0; }
.shop-phone--video[data-playing] .shop-phone-play:focus-visible { opacity: 1; }
.shop-phone-wave {
  position: absolute; left: 79.35%; top: 70.85%; translate: -50% -50%; rotate: -7.5deg;
  display: none; align-items: center; justify-content: space-between; width: 24.2%; height: 8.3%;
  padding: 1% .25%; border-radius: 4px; background: #242019; pointer-events: none;
}
.shop-phone[data-started] .shop-phone-wave { display: flex; }
.shop-phone-wave > i { flex: 0 0 1.45%; min-width: 1px; border-radius: 99px; height: var(--amplitude); background: #d9c7a5; }
.shop-phone-wave > i[data-played] { background: var(--lime); }
@keyframes shop-phone-pulse { 0% { scale: .96; opacity: .85; } 75%, 100% { scale: 1.37; opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .shop-phone-play::before { animation: none; opacity: 0; } }
.shop-media-detail { display: grid; grid-template-columns: minmax(0, 1fr) minmax(72px, min(25%, 100px)); gap: .85rem; padding: clamp(1rem, 3vw, 1.5rem); }
.shop-media-detail > div { display: flex; flex-direction: column; align-items: flex-start; }
.shop-media-detail .button { max-width: 100%; margin-top: auto; padding-inline: clamp(.65rem, 1.55vw, 1.15rem); white-space: nowrap; }
.shop-media-detail h3 { margin: 0; font: 1.65rem/1.12 var(--serif); }
.shop-media-detail p { margin-block: .5rem .75rem; }
.shop-qr { display: block; align-self: center; border: 1px solid #e0d5e4; border-radius: 8px; overflow: hidden; }
.shop-qr img { display: block; width: 100%; height: auto; }
.shop-demo { width: min(40rem, calc(100% - 2rem)); }
.shop-demo-player { margin-top: 1.25rem; }
.shop-demo-player audio, .shop-demo-player video { display: block; width: 100%; border-radius: 10px; }
.shop-demo-player video { height: auto; aspect-ratio: 4 / 3; background: var(--ink); }
.shop-demo-transcript { margin-top: 1rem; }
.shop-demo-transcript p { margin-top: .5rem; }
.shop-dialog { box-sizing: border-box; width: min(40rem, calc(100% - 1.5rem)); max-height: calc(100% - 1.5rem); overflow-y: auto; margin: auto; padding: clamp(1rem, 4vw, 2rem); border: 1px solid #dfd2e3; color: var(--ink); background: #fffdfa; border-radius: 18px; }
.shop-dialog::backdrop { background: #1f102cb3; }
.shop-dialog-header { display: flex; align-items: flex-start; justify-content: space-between; gap: .7rem; }
.shop-dialog h2 { font-size: clamp(1.85rem, 5vw, 2.65rem); overflow-wrap: anywhere; }
.shop-dialog-intro { margin: 1rem 0; }
.shop-basket-list { margin: 0; padding: 0; list-style: none; }
.shop-line { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: .5rem; padding-block: .65rem; border-block-start: 1px solid #e0d5e4; }
.shop-line-name { display: flex; flex-wrap: wrap; gap: 0 .55rem; }
.shop-quantity { display: flex; align-items: center; gap: .3rem; }
.shop-quantity button { display: grid; place-items: center; min-width: 44px; min-height: 44px; padding: .25rem; border: 1px solid #ad9bb7; background: #fffaf8; border-radius: 8px; color: var(--ink); font: inherit; cursor: pointer; }
.shop-quantity button:disabled { opacity: .5; cursor: default; }
.shop-quantity span { min-width: 2ch; text-align: center; font-variant-numeric: tabular-nums; }
.shop-subtotal { margin-block: 1rem; font-weight: 740; }
.shop-sr { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
@media (max-width: 1000px) { .shop-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 720px) {
  .shop-media-grid { grid-template-columns: 1fr; }
  .shop-media-detail .button { white-space: normal; text-align: center; }
}
@media (max-width: 540px) { .shop-grid { grid-template-columns: 1fr; } }
