/* Reusable product-page sections (web/templates/sections.html, 2026-11-08).
   Loaded only on pages whose product has sections; built on app.css's tokens. */

/* Reassurance under the main buttons */
.sx-free { margin: 8px 0 0; text-align: center; font-size: 14px; color: var(--muted); }
.title-card .sx-free { margin-bottom: 12px; }

/* The product grid's columns may shrink below their content: the swipe rows
   (round cards, "Try another artist") scroll inside them instead of widening the page. */
.product > * { min-width: 0; }

/* Round cards (the artists): 4 a row at every width, so all 8 show without swiping (owner
   2026-11-08); the picked one sits on a tinted tile with a ring, a bold label and a check. */
.picks.round { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 4px; padding: 2px 0 6px; }
.picks.round .pick { min-width: 0; }
.picks.round .pick > span { position: relative; display: grid; grid-template-columns: minmax(0, 1fr); justify-items: center; gap: 5px; background: none; border: 2px solid transparent; border-radius: 18px; padding: 6px 5px; height: auto; transition: background .15s, border-color .15s; }
.picks.round .pick img { width: 100%; max-width: 82px; height: auto; aspect-ratio: 1; border-radius: 50%; border: 3px solid var(--cream); box-shadow: 0 0 0 1px var(--line); transition: box-shadow .15s; }
.picks.round .pick b { font: 600 13px/1.2 var(--sans); padding: 0; margin: 0 -5px; white-space: nowrap; text-align: center; justify-self: stretch; }
.picks.round .pick:hover img { box-shadow: 0 0 0 2px var(--burgundy); }
.picks.round .pick input:checked + span { background: var(--blush); border-color: var(--burgundy); box-shadow: none; }
.picks.round .pick input:checked + span img { box-shadow: 0 0 0 3px var(--burgundy); }
.picks.round .pick input:checked + span b { color: var(--burgundy); font-weight: 700; }
.picks.round .pick input:checked + span::after { content: ""; position: absolute; top: 4px; right: 4px; width: 22px; height: 22px; border-radius: 50%; box-shadow: 0 0 0 2px var(--cream);
  background: var(--burgundy) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M3.5 8.5l3 3 6-7' fill='none' stroke='white' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 14px no-repeat; }
.picks.round .pick input:focus-visible + span { outline: 2px solid var(--burgundy); outline-offset: 2px; }
@media (max-width: 400px) { .picks.round .pick b { font-size: 12px; } }
@media (max-width: 360px) { .picks.round .pick b { font-size: 11px; letter-spacing: -.1px; } }
.sx-note { margin: 4px 0 0; padding: 10px 14px; border-radius: 14px; background: var(--lightcream); border: 1px solid var(--line); font-size: 15px; line-height: 1.4; min-height: 44px; }
.sx-note .sx-tag { font-family: var(--serif); font-style: italic; color: var(--ink); }
.sx-note .sx-best { display: block; margin-top: 2px; font-size: 13px; font-weight: 700; letter-spacing: .04em; color: var(--burgundy); }

/* Photo tips */
.sx-tips { margin: 12px 0 0; padding: 10px 14px; border: 1px dashed var(--line); border-radius: 14px; background: var(--cream); font-size: 14px; }
.sx-tips summary { cursor: pointer; font-weight: 600; display: flex; align-items: center; gap: 8px; list-style: none; }
.sx-tips summary::-webkit-details-marker { display: none; }
.sx-tips summary::after { content: "+"; margin-left: auto; color: var(--burgundy); font-size: 20px; line-height: 1; }
.sx-tips[open] summary::after { content: "−"; }
.sx-tips ul { margin: 8px 0 2px; padding-left: 20px; color: var(--muted); display: grid; gap: 4px; }
#slots.sx-flash { animation: sx-flash 1.4s ease; border-radius: 18px; }
@keyframes sx-flash { 0%, 100% { box-shadow: 0 0 0 0 rgba(104, 31, 37, 0); } 30% { box-shadow: 0 0 0 4px rgba(104, 31, 37, .35); } }

/* Four trust badges */
.badges.sx-four { grid-template-columns: repeat(2, 1fr); row-gap: 14px; }
@media (min-width: 560px) { .badges.sx-four { grid-template-columns: repeat(4, 1fr); } }
.badges .b4 { background: #e2eaf3; color: #2b4a74; }
.badges.sx-four a { color: inherit; text-decoration: underline; text-decoration-color: var(--line); text-underline-offset: 3px; }

/* Result screen: try another artist */
.sx-another { margin: 18px 0 0; padding: 14px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--cream); }
.sx-another-title { margin: 0 0 10px; font-weight: 700; text-align: center; }
.sx-another-title small { display: block; font-weight: 500; color: var(--muted); font-size: 13px; }
.sx-another-list { display: flex; gap: 10px; overflow-x: auto; padding: 2px 2px 6px; scrollbar-width: none; justify-content: flex-start; }
.sx-another-list::-webkit-scrollbar { display: none; }
.sx-another-card { flex: 0 0 72px; border: 0; background: none; padding: 0; cursor: pointer; font: inherit; color: var(--ink); text-align: center; }
.sx-another-card img { width: 64px; height: 64px; border-radius: 50%; box-shadow: 0 0 0 1px var(--line); display: block; margin: 0 auto; }
.sx-another-card b { display: block; font-size: 12px; font-weight: 600; padding-top: 5px; }
.sx-another-card:hover img, .sx-another-card:focus-visible img { box-shadow: 0 0 0 3px var(--burgundy); }
.sx-another-card:focus-visible { outline: none; }

/* Section shell */
.sx-sec { margin: 44px 0 0; }
.sx-sec > h2, .sx-final h2 { font-size: 28px; text-align: center; text-wrap: balance; margin: 0; }
.sx-lede { margin: 6px auto 0; max-width: 520px; text-align: center; color: var(--muted); text-wrap: balance; }

/* Before/after sliders: a swipe row; drag the handle, or tap to move the line */
.sx-row { display: grid; grid-auto-flow: column; grid-auto-columns: min(80%, 320px); gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 16px 2px 8px; scrollbar-width: thin; }
@media (min-width: 960px) { .sx-row { grid-auto-flow: row; grid-template-columns: repeat(4, 1fr); grid-auto-columns: auto; overflow: visible; } }
.sx-card { margin: 0; scroll-snap-align: start; display: grid; gap: 8px; min-width: 0; }
.sx-ba { --pos: 50%; position: relative; aspect-ratio: 1; max-width: 100%; border-radius: 18px; overflow: hidden; background: var(--lightcream); box-shadow: 0 6px 18px -10px rgba(45, 33, 29, .35); cursor: pointer; user-select: none; -webkit-user-select: none; }
.sx-ba img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; pointer-events: none; }
.sx-ba .after { clip-path: inset(0 0 0 var(--pos)); }
.sx-ba.ease .after { transition: clip-path .3s ease; }
.sx-ba.ease .sx-handle { transition: left .3s ease; }
.sx-handle { position: absolute; top: 0; bottom: 0; left: var(--pos); width: 44px; margin-left: -22px; cursor: ew-resize; touch-action: none; display: grid; place-items: center; }
.sx-handle::before { content: ""; position: absolute; top: 0; bottom: 0; left: 21px; width: 2px; background: #fff; box-shadow: 0 0 6px rgba(0, 0, 0, .35); }
.sx-handle i { position: relative; width: 34px; height: 34px; border-radius: 50%; background: #fff; box-shadow: 0 2px 8px rgba(0, 0, 0, .3); }
.sx-handle i::before, .sx-handle i::after { content: ""; position: absolute; top: 50%; width: 0; height: 0; border: 6px solid transparent; margin-top: -6px; }
.sx-handle i::before { left: 4px; border-right-color: var(--burgundy); }
.sx-handle i::after { right: 4px; border-left-color: var(--burgundy); }
.sx-ba.drag .sx-handle i, .sx-ba.focus .sx-handle i { box-shadow: 0 0 0 3px var(--burgundy), 0 2px 8px rgba(0, 0, 0, .3); }
.sx-range { position: absolute; width: 1px; height: 1px; opacity: 0; overflow: hidden; clip-path: inset(50%); }
.sx-corner { position: absolute; top: 10px; padding: 3px 9px; border-radius: 999px; background: rgba(255, 252, 247, .92); color: var(--ink); font-size: 12px; font-weight: 700; letter-spacing: .04em; pointer-events: none; }
.sx-corner.l { left: 10px; }
.sx-corner.r { right: 10px; }
.sx-card figcaption { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; padding: 0 4px; }
.sx-card figcaption b { font: 600 17px/1.2 var(--serif); }

/* Gift ideas */
.sx-gift-grid { display: grid; grid-auto-flow: column; grid-auto-columns: min(70%, 260px); gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 16px 2px 8px; }
@media (min-width: 960px) { .sx-gift-grid { grid-auto-flow: row; grid-template-columns: repeat(4, 1fr); overflow: visible; } }
.sx-gift { scroll-snap-align: start; background: var(--cream); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; display: grid; grid-template-rows: auto 1fr; min-width: 0; }
.sx-gift img { width: 100%; aspect-ratio: 1; object-fit: cover; display: block; }
.sx-gift-body { padding: 12px 14px 14px; display: grid; gap: 6px; align-content: start; }
.sx-gift h3 { margin: 0; font: 600 18px/1.2 var(--serif); }
.sx-gift p { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.45; }
.sx-gift .pillbtn { justify-self: start; margin-top: 4px; }

/* Meet the artists */
.sx-meet-list { list-style: none; margin: 16px auto 0; padding: 0; display: grid; gap: 10px; max-width: 980px; }
@media (min-width: 760px) { .sx-meet-list { grid-template-columns: 1fr 1fr; } }
.sx-meet-list li { display: grid; grid-template-columns: 60px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 10px 14px; background: var(--cream); border: 1px solid var(--line); border-radius: 16px; }
.sx-meet-list img { width: 60px; height: 60px; border-radius: 50%; }
.sx-meet-list b { font: 600 17px/1.2 var(--serif); }
.sx-meet-list p { margin: 2px 0 0; font-size: 14px; color: var(--muted); line-height: 1.4; }

/* How it works */
.sx-steps ol { list-style: none; counter-reset: sx; margin: 16px auto 0; padding: 0; display: grid; gap: 12px; max-width: 980px; }
@media (min-width: 760px) { .sx-steps ol { grid-template-columns: repeat(3, 1fr); } }
.sx-steps li { counter-increment: sx; display: grid; grid-template-columns: 40px minmax(0, 1fr); column-gap: 12px; padding: 16px; background: var(--cream); border: 1px solid var(--line); border-radius: var(--radius); }
.sx-steps li::before { content: counter(sx); grid-row: span 2; width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; background: var(--burgundy); color: #fff; font-weight: 700; }
.sx-steps b { font-size: 16px; }
.sx-steps span { color: var(--muted); font-size: 14px; line-height: 1.45; }

/* Review photos (the customers' own photos of what they received) */
.review .rv-photo { display: block; width: 100%; height: auto; aspect-ratio: 1; object-fit: cover; border-radius: 12px; margin: 0 0 12px; }
@media (max-width: 639px) {
  .review.with-photo { display: grid; grid-template-columns: 88px minmax(0, 1fr); column-gap: 12px; align-items: start; }
  .review.with-photo .rv-photo { grid-row: span 4; width: 88px; margin: 0; }
}

/* Closing call to action */
.sx-final { margin: 40px 0 48px; padding: 30px 18px; text-align: center; border-radius: var(--radius); background: var(--blush); border: 1px solid var(--line); display: grid; gap: 10px; justify-items: center; }
.sx-final p { margin: 0; color: var(--muted); max-width: 460px; text-wrap: balance; }
.sx-final .btn { min-width: min(100%, 320px); }
.sx-final-in .sticky-go { display: none; }
