/* Reusable frame for the original shelf scan: the artwork and pin geometry
   live in site.css and the component. The containing page owns its spacing. */
.shelf-scan { container-name: shelf-scan; container-type: inline-size; display: block; width: 100%; max-width: 100%; margin: 0; text-align: left; }
.hero2-scan { margin-top: clamp(28px, 4vh, 44px); }
.shelf-scan .stage2-pin { display: block; padding: 0; }
.shelf-scan .stage2-box { width: 100%; max-width: 100%; height: auto; aspect-ratio: 3 / 2; border-radius: 20px; box-shadow: none; cursor: default; }
.shelf-scan .stage2-rn { background: var(--card-2); }
.shelf-scan .stage2-tag, .shelf-scan .stage2-chip, .shelf-scan .stage2-end { transition: none; }
.shelf-scan .shelf2 { --z: 1.1; }
.shelf-scan .stage2-end { font-size: clamp(20px, 3.4cqw, 36px); }
.shelf-scan .stage2-chip { font-size: clamp(10px, 1.65cqw, 13px); line-height: 1.45; }
.shelf-scan-caption { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 4px 20px; padding: 9px 1px 0; color: var(--fg-3); font-size: 11px; line-height: 1.6; }
.shelf-scan-controls { display: flex; align-items: center; gap: 14px; margin-left: auto; }
.shelf-scan-controls[hidden] { display: none; }
.shelf-scan-controls button { display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding: 6px 2px; background: transparent; color: var(--fg-2); font: inherit; cursor: pointer; }
.shelf-scan-controls button:hover { color: var(--fg); }
.shelf-scan-controls button:focus-visible { outline: 2px solid var(--coral-text); outline-offset: 4px; border-radius: 3px; }
.shelf-scan.static .stage2-box, .shelf-scan-fallback .stage2-box, html:not(.js) .shelf-scan .stage2-box { aspect-ratio: auto; }
.shelf-scan-fallback .stage2-solo { margin-top: 0; }
@container shelf-scan (max-width: 700px) {
  .shelf-scan .stage2-rn { gap: 16px; }
  .shelf-scan .shelf2 { --z: 1; }
  .shelf-scan .names2 { gap: 3px; width: 92%; }
  .shelf-scan .names2 div { font-size: 10px; }
  .shelf-scan .names2 .am { gap: 3px; padding: 2px 4px; font-size: 9px; flex-wrap: wrap; justify-content: center; }
  .shelf-scan .scan2-pin { width: 96px; gap: 6px; padding: 4px 8px 4px 5px; }
  .shelf-scan .scan2-pin .vessel { height: 28px; }
  .shelf-scan .scan2-pin b { font-size: 10.5px; }
  .shelf-scan .scan2-pin small { display: none; }
  .shelf-scan .scan2-guide { inset: 16% 4% 34%; }
  .shelf-scan .scan2-top { top: 12px; }
  .shelf-scan .scan2-cam, .shelf-scan .scan2-reading, .shelf-scan .scan2-card { bottom: 10px; padding: 12px 14px 14px; border-radius: 22px; }
  .shelf-scan .scan2-cam p { font-size: 14px; }
  .shelf-scan .scan2-card b { font-size: 17px; }
  .shelf-scan .scan2-btn { height: 42px; font-size: 14px; }
}
@container shelf-scan (max-width: 420px) {
  .shelf-scan .stage2-box { border-radius: 14px; }
  .shelf-scan .stage2-rn { gap: 10px; padding-top: 14px; }
  .shelf-scan .stage2-end { font-size: 19px; }
  .shelf-scan .names2 { width: 94%; }
  .shelf-scan .names2 div { font-size: 8px; }
  .shelf-scan .names2 .am { font-size: 8px; padding: 2px 3px; }
  .shelf-scan .names2 .am i { display: none; }
  .shelf-scan .stage2-chip { bottom: 10px; padding: 6px 10px; }
  .shelf-scan .scan2-pin { width: 77px; gap: 3px; padding: 4px 5px; border-radius: 10px; }
  .shelf-scan .scan2-pin .vessel { height: 23px; }
  .shelf-scan .scan2-pin b { font-size: 9px; }
  .shelf-scan .scan2-top b { font-size: 12px; }
  .shelf-scan .scan2-eye { font-size: 9px; gap: 5px; }
  .shelf-scan .scan2-eye i { width: 6px; height: 6px; }
  .shelf-scan .scan2-cam, .shelf-scan .scan2-reading, .shelf-scan .scan2-card { bottom: 8px; width: calc(100% - 20px); padding: 9px 10px; gap: 5px; border-radius: 14px; }
  .shelf-scan .scan2-cam p { font-size: 12px; }
  .shelf-scan .scan2-switch span { height: 24px; font-size: 10px; padding: 0 9px; }
  .shelf-scan .scan2-btn { height: 32px; font-size: 11px; padding: 0 12px; }
  .shelf-scan .scan2-card b { font-size: 14px; }
  .shelf-scan .scan2-ghost { font-size: 11px; }
  .shelf-scan .scan2-actions { margin-top: 3px; }
}
@media (prefers-reduced-motion: reduce) {
  .shelf-scan .stage2-ph, .shelf-scan .stage2-rn { will-change: auto; }
}

.shelf-scan-caption-main { display: inline-flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.shelf-scan-caption a { display: inline-flex; align-items: center; gap: 7px; color: var(--fg-2); min-height: 40px; }
.shelf-scan-caption a:hover { color: var(--fg); text-decoration: underline; text-underline-offset: 3px; }
.shelf-scan-illustration { font-size: 9px; color: var(--fg-3); }
