.p-size-label { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 12px; }
.p-size-label b { color: var(--ink); }
#p-size-summary { color: var(--muted); font-size: 13px; font-variant-numeric: tabular-nums; }
.p-sizetable { scroll-margin-block-start: 20px; }
.p-sizetable .specs { font-variant-numeric: tabular-nums; }
.p-sizetable tbody th { background: transparent; }
.p-sizetable tbody th small { display: block; color: var(--muted); font-size: 11px; font-weight: 400; }
.p-sizetable [data-size] {
  display: inline-flex; align-items: center; justify-content: space-between; gap: 6px;
  min-width: 62px; min-height: 32px; border: 1px solid var(--line); border-radius: 5px;
  background: var(--white); color: var(--ink); padding: 2px 9px; font-weight: 600;
}
.p-sizetable [data-size]:hover { border-color: var(--bark); }
.p-sizetable [data-size] svg { visibility: hidden; width: 15px; height: 15px; }
.p-sizetable tr.selected { background: #fbefda; }
.p-sizetable tr.selected th { box-shadow: inset 3px 0 var(--amber-ink); }
.p-sizetable [data-size].on { color: white; background: var(--bark); border-color: var(--bark); }
.p-sizetable [data-size].on svg { visibility: visible; }

.p-photo-open {
  position: absolute; inset: auto 10px 10px auto; z-index: 2;
  display: inline-flex; align-items: center; gap: 7px; min-height: 40px; padding: 6px 12px;
  background: var(--white); color: var(--ink); border: 1px solid var(--line); border-radius: 99px;
  box-shadow: 0 1px 5px #231b1514; font-size: 13px; font-weight: 600; cursor: zoom-in;
}
.p-photo-open svg { width: 17px; height: 17px; }
.p-photo-open:hover { border-color: var(--bark); }
.modal.open:has(.p-photo-viewer) { align-items: center; padding: 16px; }
.modal.open:has(.p-photo-viewer) .modal-box {
  display: grid; width: min(100%, 1480px); max-width: none; height: min(94dvh, 1100px);
  max-height: 100%; padding: 0; overflow: hidden; border-radius: var(--r-lg);
}
.modal:has(.p-photo-viewer) #modal-body { display: grid; min-height: 0; }
.modal:has(.p-photo-viewer) .modal-x { width: 44px; height: 44px; top: 6px; right: 8px; z-index: 1; }
.p-photo-viewer { min-height: 0; display: grid; grid-template-rows: auto minmax(0, 1fr) auto; }
.p-photo-viewer h3 {
  margin: 0; padding: 14px 62px 12px 20px; align-self: center;
  font: 600 clamp(17px, 2.2vw, 23px)/1.3 var(--cond); color: var(--ink);
}
.p-photo-stage { min-width: 0; min-height: 0; overflow: auto; overscroll-behavior: contain; background: white; }
.p-photo-surface { display: block; width: 100%; height: 100%; border: 0; background: white; padding: 0; cursor: zoom-in; }
.p-photo-surface:focus-visible { outline-offset: -3px; }
.p-photo-surface img { display: block; width: 100%; height: 100%; object-fit: contain; }
.p-photo-surface[aria-pressed="true"] { width: max(100%, var(--photo-width)); height: max(100%, var(--photo-height)); cursor: zoom-out; }
.p-photo-nav { display: flex; align-items: center; justify-content: center; gap: 12px; padding: 8px 12px; }
.p-photo-nav button { display: grid; place-items: center; width: 44px; height: 44px; border: 1px solid var(--line); border-radius: 50%; background: var(--white); color: var(--ink); }
.p-photo-nav button:hover { border-color: var(--bark); }
.p-photo-nav svg { width: 20px; height: 20px; }
.p-photo-nav span { font-size: 14px; font-variant-numeric: tabular-nums; }
@media (max-width: 639px) {
  .modal.open:has(.p-photo-viewer) { padding: 0; }
  .modal.open:has(.p-photo-viewer) .modal-box {
    height: 100dvh; border-radius: 0; padding: env(safe-area-inset-top) 0 env(safe-area-inset-bottom);
  }
  .modal:has(.p-photo-viewer) .modal-x { top: calc(3px + env(safe-area-inset-top)); }
}
