/* Hallmark · component: product presentation · genre: editorial · theme: existing Emonse.
   Pre-emit critique: P4 H4 E4 S5 R5 V4.
   2026-09-28: remove duplicate captions; keep the product and its controls in focus. */
:root {
  --product-paper: #eeece8;
  --product-surface: #f8f7f3;
  --product-ink: #222641;
  --product-muted: #626570;
  --product-line: #c7c8c3;
  --product-focus: #365e82;
  --product-error: #942e2e;
  --product-backdrop: #090b0dd9;
}
html.product-modal-open {
  overflow-y: hidden;
}
/* 2026-09-28: direct links expose both products without replaying the slate film. */
.product-jumps {
  display: flex;
  flex-wrap: wrap;
  gap: 16px 48px;
  padding: 40px var(--gutter) 0;
  background: var(--product-paper);
  color: var(--product-ink);
  scroll-margin-top: 88px;
}
.product-jumps a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 44px;
  padding-block: 10px;
  border-bottom: 1px solid var(--product-line);
  font-size: 14px;
}
.product-jumps a > span:first-child {
  transform-origin: left center;
  transition: transform 180ms var(--ease);
}
.product {
  padding: 66px var(--gutter) 0;
  background: var(--product-paper);
  color: var(--product-ink);
  scroll-margin-top: 0;
}
.product [hidden] {
  display: none !important;
}
.product-heading {
  display: flex;
  justify-content: flex-end;
  gap: 20px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--product-line);
}
.product-heading p {
  margin: 0;
  font-size: 10px;
  letter-spacing: 0.14em;
  line-height: 1.6;
}
.product-collection {
  color: var(--product-muted);
  text-align: right;
}
.product-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 38px;
  padding-block: 32px 56px;
}
.product-gallery,
.coin-gallery,
.product-info {
  min-width: 0;
}
.product-figure {
  margin: 0;
  position: relative;
  /* 2026-09-27: let the product sit on the page without a separate pale panel. */
  background: var(--product-paper);
  aspect-ratio: 1;
  display: grid;
  place-items: center;
}
#product-image {
  display: block;
  width: 84%;
  height: 84%;
  object-fit: contain;
  mix-blend-mode: multiply;
  transition: opacity 180ms ease;
}
.product-gallery[aria-busy='true'] #product-image {
  opacity: 0.5;
}
/* Hallmark · component: shape selector · theme: existing Emonse.
   Pre-emit critique: P4 H4 E4 S5 R5 V4. Labels animate; selected borders carry state. */
.slate-stage {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 132px;
  gap: 18px;
  align-items: center;
}
.slate-shapes {
  display: grid;
  gap: 3px;
  border-left: 1px solid var(--product-line);
  padding-left: 14px;
}
.slate-shapes > p {
  margin: 0 0 9px;
  font-size: 9px;
  letter-spacing: 0.12em;
  color: var(--product-muted);
}
.slate-shapes button {
  display: flex;
  align-items: center;
  gap: 10px;
  text-align: left;
  min-width: 0;
  min-height: 74px;
  padding: 10px 4px;
  color: var(--product-muted);
  border-bottom: 1px solid transparent;
}
.slate-shapes svg {
  flex: 0 0 28px;
  width: 28px;
  height: 28px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.3;
}
.slate-shapes button > span {
  display: block;
  transform-origin: left center;
  transition: transform 180ms var(--ease);
}
.slate-shapes strong,
.slate-shapes small {
  display: block;
  white-space: nowrap;
  font-weight: 400;
}
.slate-shapes strong {
  font-size: 12px;
}
.slate-shapes small {
  margin-top: 5px;
  font-size: 10px;
}
.slate-shapes button[aria-pressed='true'] {
  color: var(--product-ink);
  border-color: var(--product-ink);
}
.slate-shapes button:focus-visible {
  outline: 2px solid var(--product-focus);
  outline-offset: 2px;
}
.slate-shapes button:active > span {
  transform: scale(0.98);
}
.product-gallery[data-state='loading'] .slate-shapes {
  opacity: 0.7;
}
.product-gallery[data-state='error'] .slate-shapes {
  border-left-color: var(--product-error);
}
@media (hover: hover) {
  .slate-shapes button:hover > span {
    transform: scale(1.04);
  }
}
@media (max-width: 600px) {
  .slate-stage {
    grid-template-columns: minmax(0, 1fr) 94px;
    gap: 6px;
  }
  .slate-shapes {
    padding-left: 9px;
  }
  .slate-shapes button {
    flex-direction: column;
    align-items: flex-start;
    gap: 5px;
    min-height: 68px;
    padding: 8px 0;
  }
  .slate-shapes svg {
    width: 22px;
    height: 22px;
    flex-basis: 22px;
  }
  .slate-shapes strong {
    font-size: 11px;
  }
  .slate-shapes small {
    font-size: 10px;
    margin-top: 3px;
  }
  .slate-shapes > p {
    font-size: 8px;
    letter-spacing: 0.06em;
  }
}
@media (prefers-reduced-motion: reduce) {
  .slate-shapes button > span {
    transition: none;
  }
  .slate-shapes button:hover > span {
    transform: none;
  }
}
.product-model {
  position: absolute;
  inset: 0;
}
.product-model model-viewer {
  width: 100%;
  height: 100%;
  --poster-color: transparent;
}
.product-model-tools {
  margin-top: 18px;
}
.product-model-tools > div {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.product-model-tools button {
  border: 1px solid var(--product-line);
  padding: 10px 14px;
  min-height: 44px;
  min-width: 44px;
  font-size: 12px;
}
.product-model-tools p,
.product-model-tools small {
  font-size: 11px;
  color: var(--product-muted);
  line-height: 1.7;
}
.product-model-tools small {
  display: block;
}
.product-scenarios {
  margin-top: 28px;
}
.product-scenarios > p {
  font-size: 10px;
  letter-spacing: 0.14em;
  color: var(--product-muted);
  margin: 0 0 12px;
}
.product-scenarios > div {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(80px, 1fr));
  gap: 8px;
}
.product-scenarios button {
  min-width: 0;
  text-align: left;
  border-bottom: 1px solid transparent;
  padding-bottom: 8px;
}
.product-scenarios button[aria-pressed='true'] {
  border-color: var(--product-ink);
}
.product-scenarios img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  object-fit: cover;
  margin-bottom: 8px;
}
.product-scenarios span {
  font-size: 10px;
  line-height: 1.4;
  display: block;
}
#product-image.is-example {
  width: 100%;
  height: 100%;
  mix-blend-mode: normal;
}
#product-lightbox-image.is-example {
  mix-blend-mode: normal;
}
.product-zoom {
  position: absolute;
  right: 12px;
  bottom: 12px;
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 50%;
  background: var(--product-ink);
  color: var(--product-surface);
}
.product-zoom svg {
  transition: transform 200ms var(--ease);
  pointer-events: none;
}
.product-zoom:disabled {
  opacity: 0.45;
  cursor: wait;
}
.product-views {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 24px;
}
.product-views button {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 9px 16px 9px 9px;
  min-height: 64px;
  border: 1px solid var(--product-line);
  color: var(--product-muted);
  font-size: 12px;
}
.product-views button[aria-pressed='true'] {
  border-color: var(--product-ink);
  color: var(--product-ink);
  background: var(--product-surface);
}
.product-views img {
  width: 44px;
  height: 44px;
  object-fit: contain;
  mix-blend-mode: multiply;
}
.product button:focus-visible,
.product a:focus-visible,
.product-lightbox button:focus-visible {
  outline: 2px solid var(--product-focus);
  outline-offset: 4px;
}
.product button:active:not(:disabled),
.product-lightbox button:active {
  transform: translateY(1px);
}
.product-gallery-status {
  min-height: 1.5em;
  margin: 12px 0 0;
  font-size: 12px;
  color: var(--product-muted);
}
.product-gallery-status:empty {
  min-height: 0;
  margin: 0;
}
.product-gallery[data-state='error'] .product-gallery-status {
  color: var(--product-error);
}
.product-gallery[data-state='error'] .product-figure {
  outline: 1px solid var(--product-error);
}
.product h2 {
  font-family: var(--display);
  font-style: normal;
  font-size: clamp(36px, 4.2vw, 72px);
  line-height: 1.06;
  font-weight: 400;
  letter-spacing: -0.055em;
  overflow-wrap: anywhere;
  min-width: 0;
  margin: 0 0 28px;
}
.product-intro {
  font-size: 19px;
  line-height: 1.6;
  margin: 0 0 18px;
}
.product-description {
  max-width: 49ch;
  font-size: 13px;
  line-height: 1.85;
  color: var(--product-muted);
  margin: 0;
}
.product-specs {
  margin: 32px 0;
}
.product-specs > div {
  border-color: var(--product-line);
  padding: 14px 0;
  font-size: 12px;
}
.product-specs dt {
  color: var(--product-muted);
}
.product-personalisation {
  border-left: 2px solid var(--product-ink);
  padding-left: 19px;
  margin-block: 30px;
}
.product-personalisation > p {
  margin: 0 0 4px;
  font-size: 17px;
  font-family: var(--display);
}
.product-personalisation > span {
  color: var(--product-muted);
  font-size: 12px;
}
.product-buy {
  width: 100%;
  min-height: 56px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 20px;
  background: var(--product-ink);
  color: var(--product-surface);
  font-size: 13px;
}
.product-buy:disabled {
  cursor: not-allowed;
  opacity: 0.6;
}
.product-purchase > p {
  font-size: 11px;
  line-height: 1.7;
  color: var(--product-muted);
  margin: 12px 0 0;
}
.product-lightbox {
  border: 0;
  padding: 20px;
  /* 2026-09-27: the magnifier should open a substantially larger product view. */
  width: min(1440px, calc(100vw - 32px));
  max-height: calc(100dvh - 24px);
  background: var(--product-paper);
  color: var(--product-ink);
}
.product-lightbox::backdrop {
  background: var(--product-backdrop);
}
.product-lightbox-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.product-lightbox h2 {
  font-family: var(--display);
  font-style: normal;
  font-size: 16px;
  letter-spacing: -0.02em;
  line-height: 1.4;
  margin: 0;
  overflow-wrap: anywhere;
}
.product-lightbox button {
  min-height: 44px;
  padding: 10px;
  border: 1px solid var(--product-line);
  font-size: 12px;
}
#product-lightbox-image {
  width: 100%;
  height: calc(100dvh - 152px);
  object-fit: contain;
  display: block;
  mix-blend-mode: multiply;
}
/* Keep every coin image square and preserve its photographic background. */
#coin-image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  transition: opacity 180ms ease;
}
.coin-gallery[aria-busy='true'] #coin-image {
  opacity: 0.5;
}
/* 2026-09-28: use the same full-width thumbnails for slate and coin; the 110px slate cap was too small. */
.gallery-views {
  display: grid;
  grid-template-columns: repeat(var(--gallery-columns, 4), minmax(0, 1fr));
  gap: 12px;
  margin-top: 18px;
}
/* Five round views share the full gallery width without bringing back fixed thumbnail caps. */
.gallery-views--five {
  --gallery-columns: 5;
}
.gallery-views button {
  padding: 0 0 10px;
  border-bottom: 1px solid transparent;
  min-width: 0;
  text-align: left;
}
.gallery-views button[aria-pressed='true'] {
  border-color: var(--product-ink);
}
.gallery-views img {
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  object-fit: contain;
  display: block;
}
.gallery-views span {
  display: inline-block;
  margin-top: 9px;
  font-size: 11px;
  white-space: normal;
  transform-origin: left center;
  transition: transform 180ms var(--ease);
}
.coin-example-note {
  margin: 14px 0 0;
  color: var(--product-muted);
  font-size: 11px;
  line-height: 1.7;
  max-width: 60ch;
}
.coin-gallery[data-state='error'] .product-gallery-status {
  color: var(--product-error);
}
.coin-availability {
  margin-top: 28px;
  padding-top: 14px;
  border-top: 1px solid var(--product-line);
}
.coin-availability > p {
  margin-top: 0;
}
#coin-lightbox-image {
  display: block;
  width: 100%;
  height: calc(100dvh - 172px);
  object-fit: contain;
}
.product-lightbox > p {
  color: var(--product-muted);
  font-size: 11px;
  margin-bottom: 0;
}
@media (hover: hover) {
  .gallery-views button:hover span,
  .product-jumps a:hover > span:first-child {
    transform: scale(1.04);
  }
  .product-views button:hover,
  .product-lightbox button:hover {
    background: var(--product-paper);
    color: var(--product-ink);
  }
  .product-zoom:hover:not(:disabled) svg {
    transform: scale(1.1);
  }
}
@media (min-width: 900px) {
  .product {
    padding-top: 78px;
  }
  .product-layout {
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
    gap: clamp(48px, 7vw, 120px);
    padding-block: 52px 72px;
  }
  .product-gallery,
  .coin-gallery {
    align-self: start;
    position: sticky;
    top: 116px;
  }
  .product-info {
    padding-top: 6px;
  }
}
@media (max-width: 374px) {
  .gallery-views {
    gap: 8px;
  }
  .product-heading {
    flex-direction: column;
    gap: 6px;
  }
  .product-collection {
    text-align: left;
  }
  .product-views {
    gap: 8px;
  }
  .product-views button {
    padding-right: 12px;
    gap: 9px;
  }
}
@media (prefers-reduced-motion: reduce) {
  #product-image,
  #coin-image,
  .gallery-views span,
  .product-jumps a > span:first-child,
  .product-zoom svg {
    transition: none;
  }
  .product-zoom:hover:not(:disabled) svg {
    transform: none;
  }
  .gallery-views button:hover span,
  .product-jumps a:hover > span:first-child {
    transform: none;
  }
  html {
    scroll-behavior: auto;
  }
}
