.rbv-feed-preview {
    overflow-wrap: anywhere;
}

.rbv-feed-hidden,
.rbv-photo-grid > [hidden],
.rbv-photo-dialog [hidden] {
    display: none !important;
}

.rbv-feed-disclosure,
.cff .cff-readmore {
    background: transparent;
    border: 0;
    border-radius: .2em;
    color: #205c31;
    cursor: pointer;
    font: inherit;
    font-weight: 700;
    line-height: 1.5;
    text-align: start;
    text-decoration: underline;
    text-underline-offset: .16em;
}

.rbv-feed-disclosure {
    display: inline-block;
    margin: .15em 0 0;
    min-block-size: 28px;
    padding: 0 .15em;
}

.rbv-feed-disclosure:hover,
.cff .cff-readmore:hover {
    color: #133e21;
}

.rbv-feed-disclosure:focus-visible,
.cff .cff-readmore:focus-visible,
.rbv-photo-thumb:focus-visible,
.rbv-photo-dialog :is(button, a):focus-visible {
    outline: 3px solid #d39528;
    outline-offset: 2px;
}

.rbv-photo-grid.rbv-photo-grid {
    --rbv-tile: clamp(90px, 22vw, 180px);
    display: grid;
    grid-auto-rows: var(--rbv-tile);
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 4px;
    align-items: stretch;
    margin-block: .8rem;
    overflow: hidden;
    border-radius: 8px;
}

.rbv-photo-grid.rbv-photo-grid[data-rbv-photo-layout="3"] {
    grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
}

.rbv-photo-grid[data-rbv-photo-layout="3"] > .rbv-photo-thumb:first-child {
    grid-row: span 2;
}

.rbv-photo-grid.rbv-photo-grid > .rbv-photo-thumb {
    display: block;
    position: relative;
    isolation: isolate;
    inline-size: 100%;
    block-size: 100%;
    min-inline-size: 0;
    min-block-size: 0;
    margin: 0;
    padding: 0;
    overflow: hidden;
    border: 0;
    border-radius: 0;
    background: #e5eae5;
    cursor: zoom-in;
}

.rbv-photo-grid.rbv-photo-grid > .rbv-photo-thumb > img {
    display: block;
    inline-size: 100%;
    block-size: 100%;
    max-inline-size: none;
    max-block-size: none;
    margin: 0;
    border-radius: 0;
    object-fit: cover;
    object-position: center 42%;
}

.rbv-photo-grid > .rbv-photo-thumb:focus-visible {
    outline-offset: -4px;
    z-index: 1;
}

.rbv-photo-more {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    background: rgb(11 24 17 / 63%);
    color: #fff;
    font-size: clamp(1.6rem, 5vw, 2.6rem);
    font-weight: 750;
}

.rbv-photo-dialog {
    inline-size: min(920px, calc(100% - 24px));
    max-inline-size: none;
    max-block-size: calc(100% - 24px);
    max-block-size: calc(100dvh - 24px);
    margin: auto;
    padding: 0;
    overflow: auto;
    overscroll-behavior: contain;
    border: 1px solid #546657;
    border-radius: 14px;
    color: #f7fbf7;
    background: #142018;
    box-shadow: 0 22px 75px rgb(0 0 0 / 45%);
}

.rbv-photo-dialog:not([open]) {
    display: none !important;
}

.rbv-photo-dialog::backdrop {
    background: rgb(7 12 8 / 80%);
}

.rbv-photo-dialog-inner {
    display: grid;
    grid-template-rows: auto minmax(0, 1fr) auto;
    gap: .6rem;
    padding: clamp(.65rem, 2vw, 1.15rem);
}

.rbv-photo-dialog-bar,
.rbv-photo-controls {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .5rem;
}

.rbv-photo-caption {
    margin: 0;
    font-size: 1rem;
    font-weight: 700;
    color: inherit;
}

.rbv-photo-stage {
    display: grid;
    place-items: center;
    min-block-size: min(52vh, 400px);
    text-align: center;
    border-radius: 8px;
    background: #0c140e;
}

.rbv-photo-image {
    display: block;
    max-inline-size: 100%;
    max-block-size: calc(100vh - 178px);
    max-block-size: calc(100dvh - 178px);
    inline-size: auto;
    block-size: auto;
    object-fit: contain;
    margin: 0;
}

.rbv-photo-dialog :is(button, .rbv-photo-original) {
    font: inherit;
    font-weight: 700;
    line-height: 1.2;
}

.rbv-photo-dialog button {
    min-inline-size: 4.5em;
    min-block-size: 44px;
    margin: 0;
    padding: .55em .85em;
    border: 1px solid #7e9782;
    border-radius: 6px;
    color: #fff;
    background: #294434;
    cursor: pointer;
}

.rbv-photo-dialog button:hover {
    background: #386348;
}

.rbv-photo-dialog .rbv-photo-original {
    color: #c9ebc5;
    text-decoration: underline;
}

.rbv-photo-loading,
.rbv-photo-error {
    margin: 1rem;
    color: #f7fbf7;
}

@media (max-width: 480px) {
    .rbv-photo-grid.rbv-photo-grid {
        --rbv-tile: clamp(86px, 24vw, 122px);
    }
}
