/* Les couleurs, polices et composants viennent de styles.css. */
.gallery-hero { position: relative; isolation: isolate; overflow: hidden; padding: 85px 0 65px; }
.gallery-hero .paint-one { z-index: -1; right: -220px; top: -270px; opacity: .15; }
.gallery-hero h1 { max-width: 930px; font-size: clamp(3.2rem, 6.7vw, 6rem); }
.gallery-hero .hero-text { max-width: 670px; }
.gallery-hint { color: var(--muted); font-size: .86rem; margin: 28px 0 0; }
.gallery-section { padding: 0 0 65px; }
.gallery-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px 26px; align-items: start; }
.artwork-card { min-width: 0; border: 1px solid var(--line); border-radius: 20px; padding: 12px; background: #fff; box-shadow: 0 12px 28px rgba(66,37,79,.06); transition: transform .2s, box-shadow .2s; }
.artwork-card:hover { transform: translateY(-5px); box-shadow: var(--shadow); }
.artwork-link { display: block; text-decoration: none; border-radius: 12px; }
.artwork-link:focus-visible { outline: 3px solid var(--blue); outline-offset: 5px; }
/* Hauteur naturelle : les portraits et les paysages restent visibles au complet. */
.artwork-image { position: relative; background: var(--paper-soft); }
.artwork-image img { display: block; width: 100%; height: auto; object-fit: contain; }
.artwork-banner { display: table; margin-bottom: 10px; padding: 7px 16px; border-radius: 0 20px 20px 0; color: white; font-size: .74rem; font-weight: 800; box-shadow: 0 3px 12px #261d2b26; }
.artwork-banner.sold { background: #a62748; }
.artwork-banner.exhibited { background: #086582; }
.artwork-banner.unavailable { background: #514658; }
.artwork-zoom { display: block; padding: 8px 10px; text-align: right; font-size: .7rem; font-weight: 700; }
.artwork-caption { padding: 20px 8px 8px; }
.artwork-caption h2 { font-size: 1.75rem; line-height: 1.12; letter-spacing: -.02em; margin: 0 0 9px; }
.artwork-caption p { margin: 0; color: var(--muted); font-size: .86rem; }
.artwork-dialog { width: min(1100px, calc(100% - 24px)); max-width: none; max-height: calc(100dvh - 24px); padding: 58px 20px 22px; border: 0; border-radius: 20px; color: var(--ink); background: var(--paper); box-shadow: var(--shadow); }
.artwork-dialog::backdrop { background: rgba(26, 18, 31, .88); }
body.artwork-open { overflow: hidden; }
.lightbox-close, .lightbox-prev, .lightbox-next { font: inherit; cursor: pointer; color: var(--ink); background: #fff; border: 1px solid var(--line); border-radius: 999px; min-width: 44px; min-height: 44px; }
.lightbox-close { position: absolute; top: 9px; right: 14px; padding: 6px 16px; font-size: .82rem; font-weight: 700; }
.lightbox-stage { display: grid; grid-template-columns: 44px minmax(0, 1fr) 44px; align-items: center; gap: 12px; }
.lightbox-image { display: block; height: min(60dvh, 670px); width: 100%; object-fit: contain; }
.lightbox-caption { text-align: center; padding: 18px 20px 0; }
.lightbox-counter { color: var(--muted); font-size: .74rem; margin: 0 0 7px; }
.lightbox-caption h2 { font-size: clamp(1.6rem, 4vw, 2.6rem); margin: 0 0 8px; }
.lightbox-caption p { margin-bottom: 4px; }
.lightbox-status { font-size: .85rem; font-weight: 800; color: #a62748; }
.lightbox-status:empty, #lightbox-details:empty { display: none; }
.artwork-dialog button:focus-visible { outline: 3px solid var(--blue); outline-offset: 3px; }
@media (max-width: 900px) { .gallery-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; } }
@media (max-width: 540px) { .gallery-hero { padding: 55px 0 40px; } .gallery-grid { grid-template-columns: 1fr; gap: 24px; } .gallery-hero h1 { font-size: clamp(2.8rem, 12vw, 4rem); } .lightbox-stage { gap: 5px; } .artwork-dialog { padding-inline: 8px; } .lightbox-caption { padding-inline: 4px; } .lightbox-image { height: 48dvh; } }
@media (prefers-reduced-motion: reduce) { .artwork-card { transition: none; } }

.lightbox-actions { display: flex; justify-content: center; flex-wrap: wrap; gap: 12px; margin-top: 20px; }
.lightbox-actions .button { font: inherit; font-size: .85rem; text-align: center; }
.lightbox-original:disabled { color: #625a65; background: #e4e0e5; box-shadow: none; cursor: not-allowed; transform: none; }
@media (max-width: 540px) { .lightbox-actions .button { width: 100%; justify-content: center; } }
