/* Print shop (public/js/shop.js) — used on the host's Prints page and the guest page. */
.sh { max-width: 1040px; margin: 0 auto; }
.sh-head { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 10px; margin: 4px 0 14px; }
.sh-head > b { font-family: var(--serif); font-size: 22px; text-align: center; }
.sh-back { justify-self: start; background: none; border: 0; color: var(--ink-2); font: inherit; font-weight: 600; cursor: pointer; padding: 8px 4px; }
.sh-basket-btn { justify-self: end; display: inline-flex; align-items: center; gap: 6px; background: var(--surface); border: 1px solid var(--line); border-radius: 99px; padding: 8px 14px; font: inherit; font-weight: 600; cursor: pointer; color: var(--ink); }
.sh-basket-btn span { display: inline-grid; place-items: center; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 99px; background: var(--honey); color: #2a221b; font-size: 12px; }

.sh-hero { display: grid; grid-template-columns: 1fr; gap: 0; border-radius: 22px; overflow: hidden; background: linear-gradient(135deg, var(--honey-soft), #f6e7cf); margin: 4px 0 8px; box-shadow: var(--shadow); }
@media (min-width: 760px) { .sh-hero { grid-template-columns: 1fr 1.15fr; align-items: stretch; } }
.sh-hero-txt { padding: 26px 24px 22px; display: flex; flex-direction: column; justify-content: center; }
.sh-kick { font-size: 12px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: var(--honey-ink); }
.sh-hero h2 { font-family: var(--serif); font-size: clamp(30px, 4.4vw, 44px); line-height: 1.05; margin: 8px 0 10px; }
.sh-hero p { color: var(--ink-2); margin: 0; max-width: 460px; }
.sh-trust { list-style: none; padding: 0; margin: 16px 0 0; display: flex; flex-wrap: wrap; gap: 8px; }
.sh-trust li { font-size: 13px; font-weight: 700; color: var(--ink); background: rgba(255,255,255,.7); padding: 6px 12px 6px 28px; border-radius: 99px; position: relative; }
.sh-trust li::before { content: ""; position: absolute; left: 11px; top: 50%; width: 9px; height: 5px; border-left: 2px solid var(--ok); border-bottom: 2px solid var(--ok); transform: translateY(-70%) rotate(-45deg); }
.sh-hero-cv { width: 100%; aspect-ratio: 4 / 3; display: block; order: -1; }
@media (min-width: 760px) { .sh-hero-cv { order: 0; height: 100%; aspect-ratio: auto; min-height: 300px; } }
.sh-banner { position: relative; margin: 0 0 16px; border-radius: 20px; overflow: hidden; display: flex; align-items: center; gap: 18px; padding: 14px; isolation: isolate; background: #2a221b; }
.sh-banner::before { content: ""; position: absolute; inset: -30px; z-index: -2; background: var(--cover) center / cover; filter: blur(26px) saturate(1.15); opacity: .85; }
.sh-banner::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, rgba(25,18,12,.55), rgba(25,18,12,.25)); }
.sh-banner img { flex: none; width: clamp(110px, 30vw, 190px); aspect-ratio: 4 / 3; object-fit: cover; border-radius: 12px; border: 3px solid rgba(255,255,255,.9); box-shadow: 0 10px 30px rgba(0,0,0,.35); }
.sh-banner div { color: #fff; min-width: 0; }
.sh-banner small { display: block; font-size: 11.5px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; opacity: .9; }
.sh-banner b { display: block; font-family: var(--serif); font-size: clamp(22px, 4vw, 32px); font-weight: 500; line-height: 1.1; margin-top: 4px; }
.sh-banner span { display: block; font-size: 14px; opacity: .9; margin-top: 4px; }
.sh-free { display: flex; align-items: center; gap: 14px; margin: 16px 0 0; padding: 14px 16px; border-radius: 16px; background: var(--surface); border: 1.5px solid var(--honey); text-decoration: none; color: var(--ink); }
.sh-free .grow { flex: 1; min-width: 0; }
.sh-free b { display: block; }
.sh-free small { color: var(--ink-2); }
.sh-free-n { flex: none; display: grid; place-items: center; width: 48px; height: 48px; border-radius: 14px; background: var(--honey); color: #2a221b; font-weight: 800; font-size: 18px; }
@media (max-width: 520px) { .sh-free .btn { display: none; } }
.sh-group { margin-top: 26px; }
.sh-group h3 { font-family: var(--serif); font-size: 26px; margin: 0; }
.sh-group > p { margin: 2px 0 12px; }
.sh-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 14px; }
.sh-tile { display: flex; flex-direction: column; text-align: left; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 0 0 12px; overflow: hidden; cursor: pointer; font: inherit; color: var(--ink); transition: transform .15s, box-shadow .15s; }
.sh-tile { position: relative; text-decoration: none; }
.sh-badge { position: absolute; top: 10px; left: 10px; background: var(--honey); color: #2a221b; font-size: 12px; font-weight: 700; padding: 3px 9px; border-radius: 99px; }
.sh-tile:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.sh-tile-cv { width: 100%; aspect-ratio: 1; display: block; background: var(--surface-2); }
.sh-tile { height: 100%; }
/* The price always sits in the same place: pinned to the tile's bottom-right corner (tiles in a row are the same height). */
.sh-tile-foot { position: static; flex: 1; display: block; padding: 10px 12px 0; min-height: 66px; }
.sh-tile-txt { display: block; min-width: 0; padding-right: 76px; }
.sh-tile-txt b { display: block; font-size: 15px; }
.sh-tile-txt small { display: block; margin-top: 2px; color: var(--ink-2); font-size: 13px; }
.sh-tag { position: absolute; right: 12px; bottom: 12px; text-align: right; line-height: 1.05; }
.sh-tag b { display: block; font-size: 21px; font-weight: 800; color: var(--ink); letter-spacing: -.01em; }
.sh-tag small { display: block; font-size: 11px; font-weight: 700; color: var(--ink-2); text-transform: uppercase; letter-spacing: .06em; }

.sh-product { display: grid; grid-template-columns: 1fr; gap: 18px; }
@media (min-width: 860px) { .sh-product { grid-template-columns: 1.15fr 1fr; align-items: start; } .sh-stage { position: sticky; top: 76px; } }
.sh-stage { border-radius: 18px; overflow: hidden; background: var(--surface-2); box-shadow: var(--shadow); }
.sh-mock { width: 100%; aspect-ratio: 1; display: block; }
.sh-stage { position: relative; }
.sh-views { position: absolute; left: 50%; bottom: 14px; transform: translateX(-50%); display: flex; gap: 4px; padding: 4px; border-radius: 99px; background: rgba(255,255,255,.88); box-shadow: 0 4px 14px rgba(0,0,0,.15); }
.sh-views button { border: 0; background: none; font: inherit; font-weight: 700; font-size: 14px; padding: 7px 16px; border-radius: 99px; cursor: pointer; color: var(--ink-2); }
.sh-views button.on { background: var(--ink); color: #fff; }
.sh-panel h2 { font-family: var(--serif); font-size: 26px; margin: 0; }
.sh-panel h2 .muted { font-family: var(--sans); font-size: 18px; font-weight: 500; }
.sh-price { font-size: 26px; font-weight: 700; margin: 4px 0 6px; }
.sh-price small { font-size: 14px; font-weight: 500; color: var(--ink-2); }
.sh-cm { white-space: nowrap; }
.sh-opt { margin: 16px 0 0; }
.sh-opt > span { display: block; font-weight: 700; font-size: 14px; margin-bottom: 8px; }
.sh-opt > span em { font-style: normal; font-weight: 500; color: var(--ink-2); margin-left: 4px; }
.sh-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.sh-chip { display: inline-flex; flex-direction: column; align-items: center; gap: 1px; padding: 9px 14px; border-radius: 12px; border: 1.5px solid var(--line); background: var(--surface); font: inherit; font-weight: 600; cursor: pointer; color: var(--ink); min-height: 44px; justify-content: center; }
.sh-chip small { font-weight: 500; color: var(--ink-2); font-size: 12px; }
.sh-chip.on { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.sh-swatches { display: flex; flex-wrap: wrap; gap: 10px; }
.sh-sw { width: 36px; height: 36px; border-radius: 50%; border: 2px solid var(--surface); background: var(--c); box-shadow: 0 0 0 1.5px var(--line); cursor: pointer; padding: 0; }
.sh-sw.on { box-shadow: 0 0 0 2.5px var(--ink); }
.sh-slots { display: grid; grid-template-columns: repeat(auto-fill, minmax(64px, 1fr)); gap: 8px; margin-bottom: 10px; }
.sh-slot { position: relative; aspect-ratio: 1.414; border-radius: 8px; border: 1.5px solid var(--line); background: var(--surface-2); padding: 0; overflow: hidden; cursor: pointer; }
.sh-slot img { width: 100%; height: 100%; object-fit: cover; display: block; }
.sh-slot i { font-style: normal; font-size: 20px; color: var(--muted); }
.sh-slot small { position: absolute; left: 0; right: 0; bottom: 0; font-size: 10.5px; font-weight: 700; color: #fff; background: linear-gradient(transparent, rgba(0,0,0,.6)); padding: 6px 4px 2px; }
.sh-slot.on { border-color: var(--ink); box-shadow: 0 0 0 1.5px var(--ink); }
.sh-crop { width: fit-content; max-width: 100%; margin: 0 auto; position: relative; border-radius: 12px; overflow: hidden; touch-action: none; cursor: grab; user-select: none; background: #111; }
.sh-crop:active { cursor: grabbing; }
.sh-crop img { display: block; width: auto; height: auto; max-width: 100%; max-height: 320px; pointer-events: none; }
.sh-win { position: absolute; box-shadow: 0 0 0 2px #fff, 0 0 0 4000px rgba(20,16,12,.55); border-radius: 2px; pointer-events: none; }
.sh-q { margin-top: 14px; padding: 10px 12px; border-radius: 12px; font-size: 14px; font-weight: 600; }
.sh-q.great, .sh-q.good { background: var(--ok-soft); color: var(--ok); }
.sh-q.soft { background: var(--honey-soft); color: var(--honey-ink); }
.sh-q.low { background: var(--bad-soft); color: var(--bad); }
.sh-buy { display: flex; gap: 10px; align-items: center; margin-top: 18px; }
.sh-buy .grow { flex: 1; }
.sh-qty { display: inline-flex; align-items: center; border: 1.5px solid var(--line); border-radius: 12px; overflow: hidden; background: var(--surface); }
.sh-qty button { width: 40px; height: 44px; border: 0; background: none; font-size: 20px; cursor: pointer; color: var(--ink); }
.sh-qty span { min-width: 26px; text-align: center; font-weight: 700; }
.sh-qty.sm button { width: 32px; height: 34px; font-size: 17px; }

.sh-lines { display: grid; gap: 10px; }
.sh-line { display: flex; gap: 14px; align-items: center; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 10px; }
.sh-line .grow { flex: 1; min-width: 0; }
.sh-line-cv { width: 88px; height: 88px; border-radius: 10px; flex: none; background: var(--surface-2); }
.sh-line-p { white-space: nowrap; }
.sh-line-acts { display: flex; align-items: center; gap: 14px; margin-top: 6px; flex-wrap: wrap; }
.linkish { background: none; border: 0; padding: 0; font: inherit; font-size: 14px; color: var(--ink-2); text-decoration: underline; cursor: pointer; }
.sh-sums { margin: 16px 2px 0; display: grid; gap: 4px; color: var(--ink-2); font-size: 15px; }
.sh-sums div { display: flex; justify-content: space-between; }
.sh-total { display: flex; justify-content: space-between; align-items: baseline; margin: 16px 2px 12px; font-size: 16px; }
.sh-total b { font-size: 24px; }

.sh-pick-back { position: fixed; inset: 0; z-index: 90; background: rgba(31, 27, 22, .5); display: grid; place-items: center;
  padding: max(16px, env(safe-area-inset-top)) max(16px, env(safe-area-inset-right)) max(16px, env(safe-area-inset-bottom)) max(16px, env(safe-area-inset-left)); }
.sh-pick { width: min(760px, 100%); max-height: 88dvh; display: flex; flex-direction: column; background: var(--surface, #fff); border-radius: 20px; box-shadow: 0 20px 60px rgba(0,0,0,.3); overflow: hidden; }
.sh-pick-h { display: flex; justify-content: space-between; align-items: center; padding: 14px 16px; border-bottom: 1px solid var(--line); }
.sh-pick-body { overflow: auto; padding: 12px; }
.sh-pick-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(104px, 1fr)); gap: 6px; }
.sh-pick-grid button { aspect-ratio: 1; padding: 0; border: 0; border-radius: 8px; overflow: hidden; cursor: pointer; background: var(--surface-2); }
.sh-pick-grid img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* the guest page: the shop opens over the album */
.sh-sheet { position: fixed; inset: 0; z-index: 60; overflow: auto; padding: max(12px, env(safe-area-inset-top)) max(16px, env(safe-area-inset-right)) 40px max(16px, env(safe-area-inset-left));
  background: radial-gradient(1200px 500px at 10% -10%, #f8e6c8 0%, transparent 60%), radial-gradient(900px 500px at 110% 20%, #f3dcd0 0%, transparent 55%), linear-gradient(#fbf6ee, #f6efe4);
  background-attachment: fixed; }
.sh-sheet::before { content: ""; position: fixed; inset: 0; pointer-events: none; opacity: .05;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='56' height='97' viewBox='0 0 56 97'%3E%3Cpath d='M28 1 55 16.5v31L28 63 1 47.5v-31z M28 64v33' fill='none' stroke='%23a06a1a' stroke-width='1.2'/%3E%3C/svg%3E"); }
.sh-sheet .sh-tile, .sh-sheet .sh-line { background: rgba(255,255,255,.88); }
.sh-sheet-close { position: sticky; top: 0; display: flex; justify-content: flex-start; z-index: 2; margin-bottom: 4px; }
.sh-open-card { display: flex; align-items: center; gap: 14px; padding: 13px 16px; border-radius: 14px; background: var(--honey-soft); color: var(--honey-ink); border: 0; width: 100%; text-align: left; font: inherit; cursor: pointer; margin: 12px 0 0; }
.sh-open-card .grow { flex: 1; min-width: 0; }
.sh-open-card b { display: block; font-size: 15.5px; color: var(--ink); }
.sh-open-card small { display: block; font-size: 13.5px; line-height: 1.35; }
.sh-open-card .ico { flex: none; display: grid; place-items: center; width: 44px; height: 44px; border-radius: 12px; background: var(--surface); }
.sh-open-card .chev { font-size: 24px; line-height: 1; }

/* 6×4 prints: the chosen photos, and ticks in the picker */
.sh-multi { display: grid; grid-template-columns: repeat(auto-fill, minmax(62px, 1fr)); gap: 6px; }
.sh-mph { position: relative; aspect-ratio: 1; border-radius: 8px; overflow: hidden; background: var(--surface-2); }
.sh-mph img { width: 100%; height: 100%; object-fit: cover; display: block; }
.sh-mph button { position: absolute; top: 3px; right: 3px; width: 22px; height: 22px; border-radius: 50%; border: 0; background: rgba(20,15,10,.7); color: #fff; font-size: 15px; line-height: 1; cursor: pointer; padding: 0; }
.sh-pick-grid button { position: relative; }
.sh-pick-grid button i { position: absolute; top: 6px; right: 6px; width: 24px; height: 24px; border-radius: 50%; border: 2px solid #fff; background: rgba(0,0,0,.25); box-shadow: 0 1px 3px rgba(0,0,0,.3); }
.sh-pick-grid button.on { outline: 3px solid var(--honey); outline-offset: -3px; }
.sh-pick-grid button.on i { background: var(--honey); }
.sh-pick-grid button.on i::after { content: ""; position: absolute; left: 7px; top: 4px; width: 5px; height: 10px; border: solid #2a221b; border-width: 0 2px 2px 0; transform: rotate(45deg); }

.sh-incl { list-style: none; padding: 0; margin: 10px 0 0; display: grid; gap: 6px; }
.sh-incl li { position: relative; padding-left: 24px; font-size: 14px; font-weight: 600; }
.sh-incl li::before { content: ""; position: absolute; left: 4px; top: 5px; width: 9px; height: 5px; border-left: 2px solid var(--ok); border-bottom: 2px solid var(--ok); transform: rotate(-45deg); }

.sh-order { align-items: flex-start; }
.sh-window { margin-top: 10px; padding: 10px 12px; border-radius: 12px; background: var(--honey-soft); }
.sh-window b { display: block; font-size: 14px; }
.sh-window small { color: var(--ink-2); }
.sh-addr .field { display: block; margin-bottom: 10px; }
.sh-addr .field span { display: block; font-size: 13px; font-weight: 600; margin-bottom: 4px; }
.sh-addr .input { width: 100%; }
