.gallery-page { background:#faf8f4; }
.gallery-page .gallery-heading { padding-block:52px 44px;text-align:center; }
.gallery-page .gallery-heading h1 { font-size:clamp(2.8rem,5vw,4.2rem);font-weight:400;letter-spacing:-.035em;line-height:1.08;margin:16px 0 24px; }
.gallery-page .gallery-heading p { max-width:580px;margin:auto;font-size:1.125rem;line-height:1.7; }
.gallery-page .gallery-section { padding-block:0 70px; }
.gallery-page .gallery-section h2 { font-size:clamp(1.75rem,3vw,2.5rem);margin:0 0 32px;font-weight:400; }
.gallery-opening,.gallery-grid { display:grid;gap:32px; }
.gallery-opening { grid-template-columns:repeat(2,minmax(0,1fr));margin-bottom:48px; }
.gallery-grid { grid-template-columns:repeat(3,minmax(0,1fr));gap:48px 32px; }
.gallery-piece { display:block;min-width:0;aspect-ratio:1;overflow:hidden; }
.gallery-piece img { display:block;width:100%;height:100%;object-fit:contain;mix-blend-mode:multiply;transition:transform .35s ease; }
.gallery-piece:hover img { transform:scale(1.035); }
.gallery-piece:focus-visible { outline:2px solid #745b35;outline-offset:5px; }
.gallery-rings .gallery-piece:nth-child(3n+2) { transform:translateY(22px); }
.gallery-neckwear { margin-top:40px; }
.gallery-necklace { width:60%;max-width:760px;margin:70px auto 0; }
#design-dialog { width:min(1100px,calc(100vw - 48px));max-height:calc(100dvh - 48px);padding:56px 32px 32px;border:0;background:#faf8f4;color:#29261f;overflow:auto; }
#design-dialog::backdrop { background:rgb(20 18 15 / .72); }
.gallery-close { position:absolute;top:10px;right:18px;border:0;background:transparent;padding:10px;cursor:pointer;font:inherit;font-size:1rem; }
.gallery-close span { font-size:1.4rem;margin-left:8px; }
.design-layout { display:grid;grid-template-columns:minmax(0,1.3fr) minmax(0,1fr);gap:36px;align-items:center; }
.design-image-area img { width:100%;height:auto;max-height:70dvh;object-fit:contain;mix-blend-mode:multiply;display:block; }
#design-name { font-size:clamp(2rem,4vw,3.5rem);font-weight:400;line-height:1.1;margin:0 0 22px; }
#design-description { font-size:1.125rem;line-height:1.7;margin:0 0 30px; }
#design-enquiry { display:inline-block;font-size:1rem;white-space:normal; }
.design-controls { display:flex;align-items:center;justify-content:space-between;gap:12px;margin-top:40px; }
.design-controls button { border:0;background:transparent;min-height:44px;padding:8px 0;font:inherit;font-size:.9375rem;cursor:pointer; }
#design-count { font-size:.8125rem;white-space:nowrap; }
.gallery-home-link { text-align:center;margin:36px 0; }
@media(max-width:760px) {
 .gallery-page .gallery-heading { padding-block:48px 44px; }
 .gallery-page .gallery-heading p { font-size:1rem; }
 .gallery-opening { grid-template-columns:1fr;gap:16px;margin-bottom:28px; }
 .gallery-grid { grid-template-columns:repeat(2,minmax(0,1fr));gap:22px 14px; }
 .gallery-rings .gallery-piece:nth-child(n) { transform:none; }
 .gallery-rings .gallery-piece:last-child { grid-column:1/-1;width:calc((100% - 14px)/2);justify-self:center; }
 .gallery-pendants .gallery-piece:first-child { grid-column:1/-1; }
 .gallery-necklace { width:100%;margin-top:32px; }
 .gallery-neckwear { margin-top:0; }
 .gallery-page .gallery-section { padding-bottom:40px; }
 #design-dialog { width:calc(100vw - 24px);max-height:calc(100dvh - 24px);padding:48px 20px 24px; }
 .design-layout { grid-template-columns:1fr;gap:20px; }
 .design-image-area img { max-height:43dvh; }
 #design-name { margin-bottom:12px; }
 #design-description { font-size:1rem;margin-bottom:20px; }
 .design-controls { margin-top:20px; }
}
@media(prefers-reduced-motion:reduce) { .gallery-piece img { transition:none; } }
.design-image-area { overflow:hidden; }
.design-image-area img { transform:scale(1.18); }

/* A shared paper surface and darken blending replace pale background differences
   without applying a colour filter to the gemstone and metal photography. */
body.gallery-page,#design-dialog { background:var(--jewellery-paper,#f5f5f2); }
.gallery-piece,.design-image-area { background:var(--jewellery-paper,#f5f5f2);isolation:isolate; }
.gallery-piece img,.design-image-area img { mix-blend-mode:darken; }
.gallery-piece img { transform:scale(1.14); }
.gallery-piece:hover img { transform:scale(1.17); }
.gallery-necklace img { transform:none; }
.gallery-necklace .gallery-piece:hover img { transform:scale(1.025); }
.design-image-area { touch-action:pan-y pinch-zoom; }
@media(max-width:760px) {
 .gallery-opening { grid-template-columns:repeat(2,minmax(0,1fr));gap:14px;margin-bottom:22px; }
 .gallery-rings .gallery-piece:last-child { grid-column:auto;width:100%; }
 .gallery-pendants .gallery-piece:first-child { grid-column:auto; }
 .gallery-pendants .gallery-piece:last-child { grid-column:1/-1;width:calc((100% - 14px)/2);justify-self:center; }
}
