/* All rules are scoped to this gallery. The editor and saved content stay intact. */
.dng-source-section .dng-source-inner {
    display: block !important;
}
.dng-source-section .dng-source-inner > .dng-original {
    display: none !important;
}
.dng-layout {
    --dng-ready: 1;
    --dng-blue: #1d4ed8;
    display: grid;
    grid-template-columns: minmax(0, 0.78fr) minmax(0, 1.75fr);
    align-items: start;
    gap: clamp(24px, 4vw, 52px);
    width: 100%;
    max-width: 100%;
    margin: 0;
    padding: 0;
    text-align: left;
}
.dng-layout, .dng-layout * {
    box-sizing: border-box;
}
.dng-intro {
    min-width: 0;
    border-top: 3px solid var(--dng-blue);
    padding-top: 22px;
}
.dng-layout .dng-intro h1,
.dng-layout .dng-intro h2,
.dng-layout .dng-intro h3 {
    color: #1e293b;
    font-size: clamp(27px, 2.7vw, 36px);
    font-weight: 750;
    line-height: 1.2;
    letter-spacing: -0.025em;
    margin: 0 0 20px;
}
.dng-layout .dng-intro p,
.dng-layout .dng-intro ul,
.dng-layout .dng-intro ol,
.dng-layout .dng-intro blockquote {
    color: #526075;
    font-size: 17px;
    line-height: 1.75;
    margin: 0 0 16px;
}
.dng-gallery {
    min-width: 0;
    max-width: 100%;
    margin: 0;
    border: 0;
    outline-offset: 5px;
}
.dng-frame {
    position: relative;
    display: grid;
    place-items: center;
    width: 100%;
    aspect-ratio: 16 / 10;
    overflow: hidden;
    isolation: isolate;
    background: #edf1f6;
    border: 1px solid #e0e6ef;
    border-radius: 14px;
    touch-action: pan-y pinch-zoom;
}
.dng-gallery img.dng-main-image {
    display: block !important;
    position: absolute !important;
    inset: 0 !important;
    width: 100% !important;
    height: 100% !important;
    max-width: 100% !important;
    max-height: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    object-fit: contain !important;
    object-position: center !important;
    transform: none !important;
    box-shadow: none !important;
}
.dng-image-error .dng-main-image {
    opacity: 0;
}
.dng-unavailable {
    position: relative;
    padding: 24px;
    color: #526075;
    text-align: center;
    font-size: 16px;
}
.dng-controls {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 18px;
    margin: 14px 0 12px;
}
.dng-gallery button.dng-arrow {
    appearance: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 44px;
    width: 44px;
    height: 44px;
    min-height: 44px;
    padding: 0;
    margin: 0;
    border: 1px solid #d5deeb;
    border-radius: 50%;
    background: #fff;
    color: #1e3a70;
    font-family: Arial, sans-serif;
    font-size: 32px;
    font-weight: 400;
    line-height: 1;
    cursor: pointer;
    box-shadow: none;
    transition: background-color 120ms, color 120ms, border-color 120ms;
}
.dng-arrow span {
    display: block;
    margin-top: -3px;
}
.dng-gallery button.dng-arrow:hover {
    background: var(--dng-blue);
    border-color: var(--dng-blue);
    color: #fff;
}
.dng-counter {
    min-width: 60px;
    color: #526075;
    font-family: inherit;
    font-size: 14px;
    font-weight: 650;
    font-variant-numeric: tabular-nums;
    line-height: 1.4;
    text-align: center;
}
.dng-thumbnails {
    position: relative;
    display: flex;
    flex-wrap: nowrap;
    gap: 8px;
    width: 100%;
    min-width: 0;
    max-width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 4px 2px 10px;
    margin: 0;
    overscroll-behavior-x: contain;
    scrollbar-width: thin;
    scrollbar-color: #c3cfdf transparent;
}
.dng-gallery button.dng-thumbnail {
    appearance: none;
    position: relative;
    display: block;
    flex: 0 0 88px;
    width: 88px;
    height: 64px;
    min-height: 0;
    margin: 0;
    padding: 3px;
    border: 2px solid transparent;
    border-radius: 8px;
    background: transparent;
    box-shadow: none;
    cursor: pointer;
}
.dng-gallery button.dng-thumbnail[aria-pressed="true"] {
    border-color: var(--dng-blue);
    background: #fff;
}
.dng-gallery .dng-thumbnail img {
    display: block !important;
    position: static !important;
    width: 100% !important;
    height: 100% !important;
    max-width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 3px !important;
    object-fit: contain !important;
    object-position: center !important;
    transform: none !important;
    box-shadow: none !important;
    background: #edf1f6;
}
.dng-gallery:focus-visible,
.dng-gallery button:focus-visible {
    outline: 3px solid #1d4ed8;
    outline-offset: 3px;
}
.dng-gallery .dng-caption {
    margin: 0 0 12px;
    color: #526075;
    font-size: 14px;
    line-height: 1.6;
    text-align: center;
}
.dng-layout [hidden] {
    display: none !important;
}
@media (max-width: 900px) {
    .dng-layout {
        grid-template-columns: minmax(0, 1fr);
        gap: 22px;
    }
    .dng-intro {
        padding-top: 17px;
    }
    .dng-layout .dng-intro h1,
    .dng-layout .dng-intro h2,
    .dng-layout .dng-intro h3 {
        margin-bottom: 12px;
    }
    .dng-layout .dng-intro p:last-child {
        margin-bottom: 0;
    }
}
@media (max-width: 540px) {
    .dng-frame {
        aspect-ratio: 4 / 3;
        border-radius: 10px;
    }
    .dng-layout .dng-intro p {
        font-size: 16px;
        line-height: 1.65;
    }
    .dng-gallery button.dng-thumbnail {
        flex-basis: 72px;
        width: 72px;
        height: 56px;
    }
    .dng-controls {
        margin: 12px 0 8px;
    }
}
@media (max-height: 520px) and (orientation: landscape) {
    .dng-frame {
        height: 62vh;
        height: 62svh;
        max-height: 340px;
        aspect-ratio: auto;
    }
}
/* On a short touch phone, size the frame from its height instead of stretching
   its background across the page. Keep one stable frame for every photograph. */
@media (max-width: 1024px) and (max-height: 520px) and (orientation: landscape) and (hover: none) and (pointer: coarse) {
    .dng-frame {
        width: min(100%, 87vh, 420px);
        width: min(100%, 87svh, 420px);
        height: auto;
        max-height: none;
        aspect-ratio: 3 / 2;
        margin-inline: auto;
        border-radius: 10px;
    }
    .dng-controls {
        margin: 8px 0;
    }
}
@media (prefers-reduced-motion: reduce) {
    .dng-layout *, .dng-layout *::before, .dng-layout *::after {
        scroll-behavior: auto !important;
        transition: none !important;
    }
}
