/* Corporate Blue v2.2 — WordPress gallery viewer */
.entry .gallery img.yrh-lightbox-trigger,
.entry .wp-block-gallery img.yrh-lightbox-trigger,
.entry .blocks-gallery-grid img.yrh-lightbox-trigger,
.entry .tiled-gallery img.yrh-lightbox-trigger {
    cursor: zoom-in;
    transition: filter .2s ease, transform .2s ease;
}
.entry .gallery img.yrh-lightbox-trigger:hover,
.entry .wp-block-gallery img.yrh-lightbox-trigger:hover,
.entry .blocks-gallery-grid img.yrh-lightbox-trigger:hover,
.entry .tiled-gallery img.yrh-lightbox-trigger:hover { filter: brightness(.93); }
.entry img.yrh-lightbox-trigger:focus-visible,
.entry a:has(img.yrh-lightbox-trigger):focus-visible { outline: 3px solid #318cd4; outline-offset: 3px; }
body.yrh-lightbox-open { overflow: hidden !important; }
.yrh-lightbox[hidden], .yrh-lightbox [hidden] { display: none !important; }
.yrh-lightbox {
    position: fixed;
    inset: 0;
    z-index: 1000000;
    display: flex;
    flex-direction: column;
    padding: env(safe-area-inset-top, 0) env(safe-area-inset-right, 0) env(safe-area-inset-bottom, 0) env(safe-area-inset-left, 0);
    color: #fff;
    background: rgba(6, 17, 32, .96);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    font-family: inherit;
    line-height: 1.5;
}
.yrh-lightbox button { font: inherit; cursor: pointer; }
.yrh-lightbox-topbar {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 12px clamp(16px, 3vw, 40px);
    min-height: 68px;
}
.yrh-lightbox-counter { color: #e1ecf9; font-size: 15px; font-weight: 600; font-variant-numeric: tabular-nums; }
.yrh-lightbox-close,
.yrh-lightbox-arrow {
    display: grid;
    place-items: center;
    width: 48px;
    height: 48px;
    padding: 0;
    border: 1px solid rgba(255,255,255,.20);
    border-radius: 50%;
    background: rgba(255,255,255,.12);
    color: #fff;
    transition: background .18s ease, transform .18s ease;
}
.yrh-lightbox button:hover { background: rgba(35, 133, 210, .85); transform: scale(1.04); }
.yrh-lightbox button:focus-visible { outline: 3px solid #80caff; outline-offset: 3px; }
.yrh-lightbox svg { display: block; width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.yrh-lightbox-stage {
    flex: 1 1 auto;
    min-height: 0;
    display: grid;
    grid-template-columns: minmax(44px, 80px) minmax(0, 1fr) minmax(44px, 80px);
    gap: 8px;
    align-items: center;
    justify-items: center;
    padding: 0 12px;
}
.yrh-lightbox-figure { min-width: 0; min-height: 0; margin: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; width: 100%; height: 100%; }
.yrh-lightbox-image {
    display: block;
    width: auto;
    height: auto;
    max-width: 100%;
    max-height: calc(100vh - 186px);
    max-height: calc(100dvh - 186px);
    object-fit: contain;
    border-radius: 6px;
    box-shadow: 0 18px 60px rgba(0,0,0,.40);
    opacity: 0;
    transition: opacity .16s ease;
}
.yrh-lightbox-image.is-loaded { opacity: 1; }
.yrh-lightbox-arrow { width: 48px; height: 48px; }
.yrh-lightbox-caption { max-width: min(900px, 100%); color: #e7ecf3; text-align: center; font-size: 14px; overflow-wrap: anywhere; }
.yrh-lightbox-hint { flex: 0 0 auto; text-align: center; color: #a8bfda; font-size: 12px; padding: 12px 16px 18px; }
@media (max-width: 640px) {
    .yrh-lightbox-topbar { padding: 8px 14px; min-height: 56px; }
    .yrh-lightbox-stage { grid-template-columns: 36px minmax(0, 1fr) 36px; gap: 2px; padding: 0 6px; }
    .yrh-lightbox-close, .yrh-lightbox-arrow { width: 36px; height: 36px; }
    .yrh-lightbox svg { width: 20px; height: 20px; }
    .yrh-lightbox-image { max-height: calc(100vh - 154px); max-height: calc(100dvh - 154px); }
    .yrh-lightbox-caption { font-size: 12px; }
    .yrh-lightbox-hint { font-size: 11px; padding-bottom: 10px; }
}
@media (prefers-reduced-motion: reduce) {
    .yrh-lightbox *, .entry .gallery img.yrh-lightbox-trigger,
    .entry .wp-block-gallery img.yrh-lightbox-trigger { transition: none !important; }
}
