.gallery-catalog-card { margin-bottom: 13px; }
.gallery-main { color: var(--ink); padding-block: 14px 25px; }
.gallery-main h1 { font: inherit; font-size: clamp(24px, 6.8vw, 32px); font-weight: 780; line-height: 1.11; letter-spacing: -.03em; text-wrap: balance; margin: 0 0 13px; }
.gallery-main h2 { font: inherit; font-size: 22px; font-weight: 740; line-height: 1.13; letter-spacing: -.025em; }
.gallery-main .button { min-height: 48px; border-radius: 14px; white-space: normal; text-align: center; }
.gallery-main :focus-visible, .gallery-catalog-card:focus-visible { outline: 2px solid var(--red); outline-offset: 2px; }
.gallery-main :is(h1, #gallery-fact, #gallery-picker-title):focus { outline: none; }
.gallery-main ::selection { background: #ffd9d4; color: var(--ink); }

.gallery-cover { height: 149px; position: relative; isolation: isolate; overflow: hidden; background: #e4dcf6; }
.gallery-cover img { position: absolute; object-fit: cover; }
.gallery-cover-rooks, .gallery-cover-starry, .gallery-cover-girl { border: 3px solid #fff; border-radius: 9px; box-shadow: 0 3px 11px #29203926; }
.gallery-cover-rooks { width: 29%; height: 109%; bottom: -23%; left: 9%; transform: rotate(-12deg); }
.gallery-cover-starry { width: 45%; height: 82%; bottom: -3%; left: 27%; transform: rotate(-3deg); }
.gallery-cover-girl { width: 28%; height: 106%; right: 11%; bottom: -17%; transform: rotate(13deg); }
.gallery-cover .gallery-cover-push { width: 25%; height: 65%; object-fit: contain; right: 0; bottom: -8%; }
.gallery-intro .gallery-cover, .gallery-finish .gallery-cover { border-radius: 19px; margin-bottom: 19px; height: 170px; }
.gallery-speech { background: #efeff1; padding: 13px; border-radius: 15px; display: flex; gap: 10px; align-items: flex-start; }
.gallery-speech strong { display: block; margin-bottom: 3px; }
.gallery-speech p, .gallery-fact-copy { line-height: 1.45; }
.gallery-push { flex: 0 0 40px; object-fit: contain; }
.gallery-actions { display: grid; gap: 8px; margin-top: 13px; }
.gallery-secondary { background: #ebebed; color: var(--ink); }

.gallery-progress { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; font-size: 13px; }
.gallery-segments { display: flex; flex: 1; gap: 4px; max-width: 125px; margin-inline: auto; }
.gallery-segments i { height: 4px; flex: 1; border-radius: 3px; background: #dddde2; }
.gallery-segments i.earned { background: var(--red); }
.gallery-segments i.active { background: #ed9d96; }
.gallery-xp { display: inline-flex; align-items: center; gap: 5px; width: fit-content; border-radius: 9px; padding: 6px 9px; background: #ffe3dd; color: #862116; font-weight: 750; }
.gallery-artwork { margin: 0; padding: 7px; border-radius: 16px; background: #edebef; }
.gallery-picture { position: relative; width: fit-content; max-width: 100%; margin-inline: auto; }
.gallery-picture img { display: block; max-width: 100%; height: auto; max-height: 253px; object-fit: contain; border-radius: 10px; }
.gallery-spot { display: grid; place-items: center; position: absolute; left: var(--spot-x); top: var(--spot-y); transform: translate(-50%, -50%); width: 44px; height: 44px; border: 0; border-radius: 50%; color: #fff; background: transparent; }
.gallery-spot span, .gallery-artwork figcaption b { display: inline-grid; place-items: center; width: 26px; height: 26px; border: 2px solid #fff; border-radius: 50%; background: #242126; color: #fff; font-size: 13px; font-weight: 750; }
.gallery-spot:hover span, .gallery-spot:focus-visible span { background: var(--red); }
.gallery-artwork figcaption { display: flex; flex-wrap: wrap; justify-content: center; gap: 5px 10px; padding-block: 7px 2px; font-size: 12px; }
.gallery-artwork figcaption span { display: inline-flex; align-items: center; gap: 4px; }
.gallery-artwork figcaption b { width: 17px; height: 17px; border: none; font-size: 10px; }
.gallery-artwork .gallery-chosen { color: var(--muted); }
.gallery-instruction { margin: 10px 0; color: var(--muted); font-size: 14px; text-align: center; }
.gallery-options { display: grid; gap: 7px; margin-top: 11px; }
.gallery-options button { display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: 46px; padding: 8px 12px; background: #fff; border: 1px solid var(--line); border-radius: 12px; color: var(--ink); text-align: left; font: inherit; font-weight: 660; line-height: 1.25; }
.gallery-options button:hover, .gallery-secondary:hover { background: #e3e2e7; }
.gallery-options svg { flex-shrink: 0; }

.gallery-fact { margin-top: 13px; border-radius: 15px; padding: 14px 15px; background: #eeebf4; }
.gallery-reaction { display: flex; gap: 8px; align-items: center; margin: -4px 0 7px; font-size: 15px; font-weight: 740; }
.gallery-credit { margin-top: 5px; font-size: 13px; color: #565063; }
.gallery-fact-copy { margin-top: 9px; }
.gallery-source { display: inline-flex; align-items: center; gap: 5px; margin-top: 6px; min-height: 32px; font-size: 13px; color: #514365; text-decoration: underline; text-underline-offset: 3px; }
.gallery-source svg { transform: rotate(-38deg); }
.gallery-picker { margin-top: 15px; }
.gallery-choices { display: grid; gap: 6px; margin-top: 9px; }
.gallery-choices label { display: flex; align-items: center; gap: 9px; min-height: 45px; padding: 7px 10px; background: #eeedef; border-radius: 11px; cursor: pointer; }
.gallery-choices input { width: 20px; height: 20px; flex-shrink: 0; margin: 0; accent-color: var(--red); }
.gallery-choices label:has(input:checked) { background: #ffe3dd; }
.gallery-summary { color: var(--muted); line-height: 1.4; margin-bottom: 11px; }

.gallery-filters { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 13px; }
.gallery-filters button { padding: 7px 10px; min-height: 44px; border: 0; border-radius: 11px; background: #ebebee; color: var(--ink); font: inherit; font-weight: 660; font-size: 13px; }
.gallery-filters button[aria-pressed="true"] { background: var(--ink); color: #fff; }
.gallery-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.gallery-card { overflow: hidden; border-radius: 13px; border: 1px solid var(--line); background: #fff; color: var(--ink); }
.gallery-card img { display: block; width: 100%; aspect-ratio: 4/3; object-fit: cover; object-position: 50% 39%; }
.gallery-card > span { display: block; padding: 8px 9px 10px; }
.gallery-card strong { display: block; line-height: 1.2; font-size: 14px; }
.gallery-card small { display: block; color: var(--muted); margin-top: 4px; font-size: 12px; }
.gallery-empty { border-radius: 15px; background: #eeebf4; padding: 15px; }
.gallery-empty p { margin: 8px 0 14px; line-height: 1.4; }

@media (prefers-reduced-motion: no-preference) {
  .gallery-fact, .gallery-picker, .gallery-question-side { animation: gallery-reveal 240ms cubic-bezier(.2,.7,.2,1) both; }
  @keyframes gallery-reveal { from { opacity: .65; transform: translateY(5px); } }
}
@media (max-width: 355px) {
  .gallery-picture img { max-height: 216px; }
  .gallery-progress { gap: 7px; }
  .gallery-artwork figcaption { gap: 4px 6px; }
}
