/* =============================================================================
   SUVA — Gallery page (/gallery). Uses tokens from styles.css.
   ========================================================================== */
.breadcrumb { font-size: calc(.875rem + 1px); color: var(--muted); }
.breadcrumb ol { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; }
.breadcrumb a { color: var(--muted); }
.breadcrumb a:hover { color: var(--teal-ink); }
.breadcrumb [aria-current="page"] { color: var(--pink-ink); font-weight: 600; }
.breadcrumb svg { width: .85rem; height: .85rem; color: #cbd5e1; }

.gallery-hero { background: var(--light-pink); }
.gallery-hero .container { padding-block: clamp(2rem, 5vw, 3.25rem); }
.gallery-hero h1 { margin: 1rem 0 .5rem; }
.gallery-hero p { color: var(--text); max-width: 48rem; }
.gallery-hero .badge { margin-top: 1rem; }

.gallery-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.5rem; }
.gallery-item {
    background: #fff; border: 1px solid var(--border); border-radius: var(--r-card);
    overflow: hidden; box-shadow: var(--shadow-xs);
    transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
}
.gallery-item:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.gallery-item__media { position: relative; line-height: 0; border-bottom: 1px solid var(--border-soft); }
.gallery-item__media img { width: 100%; height: auto; display: block; }
.gallery-item__tag {
    position: absolute; top: .6rem; right: .6rem; z-index: 1;
    background: rgba(255,255,255,.94); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px);
    color: var(--pink-ink); font-size: calc(.68rem + 1px); font-weight: 700; letter-spacing: .05em; text-transform: uppercase;
    padding: .25rem .6rem; border-radius: var(--r-pill); box-shadow: var(--shadow-xs);
}
/* Before / After pair — two separate photos normalised to the same square crop
   so they always align, regardless of the source aspect ratios. */
.gallery-item__media--pair { display: grid; grid-template-columns: 1fr 1fr; gap: 3px; background: var(--border); }
.ba-half { position: relative; overflow: hidden; background: var(--bg-alt); }
.ba-half img { width: 100%; height: 100%; aspect-ratio: 1/1; object-fit: cover; display: block; }
.ba-half__label {
    position: absolute; top: .45rem; left: .45rem; z-index: 1;
    font-size: calc(.62rem + 1px); font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
    padding: .2rem .5rem; border-radius: var(--r-pill); color: #fff;
    background: rgba(26,43,60,.82);
}
.ba-half__label--after { background: var(--teal-cta); }

/* Graphic clinical images — blurred + desaturated until the viewer opts in.
   (Blood tones are toned down via saturate(); blur hides detail until reveal.) */
.gallery-item.is-sensitive .gallery-item__media img {
    filter: blur(16px) saturate(.55);
    transform: scale(1.06); /* hides blurred edge bleed */
    transition: filter .35s var(--ease), transform .35s var(--ease);
}
.gallery-item.is-sensitive.is-revealed .gallery-item__media img {
    filter: blur(0) saturate(.9);
    transform: none;
}
.gallery-item__reveal {
    position: absolute; inset: 0; z-index: 2; display: flex; flex-direction: column;
    align-items: center; justify-content: center; gap: .3rem; cursor: pointer;
    background: rgba(26,43,60,.45); border: 0; color: #fff; text-align: center;
    padding: 1rem; line-height: 1.3; /* parent sets line-height:0 for the image; reset it here */
    transition: opacity .3s var(--ease), visibility .3s;
}
.gallery-item__reveal svg { width: 1.6rem; height: 1.6rem; margin-bottom: .1rem; }
.gallery-item__reveal b { font-size: calc(.9rem + 1px); font-weight: 600; }
.gallery-item__reveal span { font-size: calc(.78rem + 1px); opacity: .85; }
.gallery-item__reveal:hover { background: rgba(26,43,60,.55); }
.gallery-item.is-revealed .gallery-item__reveal { opacity: 0; visibility: hidden; }
@media (prefers-reduced-motion: reduce) {
    .gallery-item.is-sensitive .gallery-item__media img { transition: none; }
}

.gallery-item__body { padding: 1rem 1.25rem 1.15rem; display: flex; align-items: center; gap: .7rem; }
.gallery-item__num { width: 2.2rem; height: 2.2rem; border-radius: 10px; background: var(--light-pink); color: var(--pink-ink);
    font-weight: 700; font-size: calc(.9rem + 1px); display: grid; place-items: center; flex: none; }
.gallery-item__text { display: flex; flex-direction: column; }
.gallery-item__body h3 { font-size: calc(1.05rem + 1px); line-height: 1.3; margin: 0; }
.gallery-item__cat { font-size: calc(.78rem + 1px); color: var(--pink-ink); font-weight: 600; margin-top: .1rem; }

.gallery-note { margin-top: 2rem; padding: 1rem 1.25rem; background: var(--bg-alt); border: 1px solid var(--border);
    border-radius: 12px; font-size: calc(.85rem + 1px); color: var(--muted); display: flex; gap: .65rem; align-items: flex-start; }
.gallery-note svg { width: 1.15rem; height: 1.15rem; flex: none; color: var(--teal-ink); margin-top: .1rem; }

/* CTA (shared split) -------------------------------------------------------- */
.cta-split { position: relative; overflow: hidden; border-radius: var(--r-panel); background: var(--soft-teal);
    border: 1px solid var(--border); padding: clamp(1.75rem, 4vw, 2.75rem);
    display: flex; align-items: center; justify-content: space-between; gap: 2rem; flex-wrap: wrap; }
.cta-split__lotus { position: absolute; left: -1.5rem; bottom: -2rem; width: 11rem; opacity: .4; pointer-events: none; }
.cta-split__text { position: relative; z-index: 1; }
.cta-split__text h2 { margin-bottom: .35rem; }
.cta-split__text p { color: var(--text); margin: 0; }
.cta-split__actions { position: relative; z-index: 1; display: flex; gap: .7rem; flex-wrap: wrap; }

@media (max-width: 720px) {
    .gallery-grid { grid-template-columns: 1fr; }
    .cta-split { flex-direction: column; align-items: flex-start; }
    .cta-split__actions { width: 100%; }
    .cta-split__actions .btn { flex: 1 1 auto; }
}
