/* --------------------------------------------------------------------------
   Galería pública
   -------------------------------------------------------------------------- */

.photogallery-page {
    --photogallery-line: var(--bs-border-color-translucent);
    --photogallery-surface: var(--bs-card-bg);
    --photogallery-muted: var(--bs-secondary-color);

    display: grid;
    width: 100%;
    grid-template-columns: minmax(0, 1fr);
    gap: 1.5rem;
}

.photogallery-page > * {
    min-width: 0;
}

/* --------------------------------------------------------------------------
   Hero editorial
   -------------------------------------------------------------------------- */

.photogallery-page .photogallery-hero {
    position: relative;
    display: grid;
    min-height: 27rem;
    grid-template-columns: minmax(0, 1.05fr) minmax(24rem, 0.95fr);
    overflow: hidden;
    color: #fff;
    background:
        radial-gradient(
            circle at 86% 8%,
            color-mix(in srgb, var(--any-brand-secondary) 52%, transparent) 0,
            transparent 30%
        ),
        linear-gradient(
            135deg,
            color-mix(in srgb, var(--any-surface-primary) 82%, #000) 0%,
            var(--any-surface-primary) 58%,
            color-mix(in srgb, var(--any-brand-secondary) 72%, var(--any-surface-primary)) 100%
        );
    box-shadow: var(--bs-box-shadow-lg);
}

.photogallery-page .photogallery-hero::before,
.photogallery-page .photogallery-hero::after {
    position: absolute;
    border: 1px solid rgb(255 255 255 / 0.14);
    border-radius: 50%;
    content: '';
    pointer-events: none;
}

.photogallery-page .photogallery-hero::before {
    width: 24rem;
    height: 24rem;
    top: -17rem;
    left: 28%;
}

.photogallery-page .photogallery-hero::after {
    width: 38rem;
    height: 38rem;
    right: -27rem;
    bottom: -25rem;
}

.photogallery-page .photogallery-hero__content {
    position: relative;
    z-index: 2;
    align-self: center;
    padding: clamp(2rem, 5vw, 4.5rem);
}

.photogallery-page .photogallery-eyebrow {
    display: block;
    margin-bottom: 0.65rem;
    color: rgb(255 255 255 / 0.74);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.photogallery-page .photogallery-hero h1 {
    max-width: 11ch;
    margin: 0;
    color: #fff;
    font-size: clamp(2.5rem, 5vw, 4.5rem);
    font-weight: 800;
    letter-spacing: -0.045em;
    line-height: 0.96;
}

.photogallery-page .photogallery-hero__content > p {
    max-width: 38rem;
    margin: 1.25rem 0 0;
    color: rgb(255 255 255 / 0.82);
    font-size: 1rem;
    line-height: 1.65;
}

.photogallery-page .photogallery-hero__stats {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
    margin-top: 1.75rem;
}

.photogallery-page .photogallery-hero__stats > div {
    min-width: 7rem;
    padding: 0.75rem 0.9rem;
    border: 1px solid rgb(255 255 255 / 0.2);
    border-radius: var(--bs-border-radius-lg);
    background: rgb(0 0 0 / 0.16);
    backdrop-filter: blur(0.5rem);
}

.photogallery-page .photogallery-hero__stats strong,
.photogallery-page .photogallery-hero__stats span {
    display: block;
}

.photogallery-page .photogallery-hero__stats strong {
    color: #fff;
    font-size: 1.25rem;
    font-weight: 700;
    line-height: 1.2;
}

.photogallery-page .photogallery-hero__stats span {
    margin-top: 0.15rem;
    color: rgb(255 255 255 / 0.68);
    font-size: 0.75rem;
}

.photogallery-page .photogallery-hero__action {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    margin-top: 1.5rem;
    padding: 0.7rem 1rem;
    border-color: #fff;
    color: var(--any-surface-primary);
    background: #fff;
    font-weight: 600;
}

.photogallery-page .photogallery-hero__action:hover,
.photogallery-page .photogallery-hero__action:focus,
.photogallery-page .photogallery-hero__action:active {
    border-color: var(--any-brand-secondary);
    color: #fff;
    background: var(--any-brand-secondary);
    box-shadow: 0 0 0 0.2rem rgb(255 255 255 / 0.2);
}

.photogallery-page .photogallery-hero__visual {
    position: relative;
    z-index: 1;
    min-height: 27rem;
}

.photogallery-page .photogallery-hero__photo {
    position: absolute;
    overflow: hidden;
    margin: 0;
    border: 0.3rem solid rgb(255 255 255 / 0.88);
    border-radius: var(--bs-border-radius-xl);
    background: var(--bs-dark);
    box-shadow: 0 1.5rem 3rem rgb(0 0 0 / 0.28);
}

.photogallery-page .photogallery-hero__photo img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.photogallery-page .photogallery-hero__photo--1 {
    z-index: 3;
    width: min(28rem, 78%);
    height: 17rem;
    right: 7%;
    top: 18%;
    transform: rotate(2deg);
}

.photogallery-page .photogallery-hero__photo--2 {
    z-index: 2;
    width: 16rem;
    height: 11rem;
    right: 45%;
    bottom: 5%;
    transform: rotate(-7deg);
}

.photogallery-page .photogallery-hero__photo--3 {
    z-index: 4;
    width: 13rem;
    height: 9rem;
    right: 2%;
    bottom: 4%;
    transform: rotate(7deg);
}

.photogallery-page .photogallery-hero__empty-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    display: grid;
    width: 8rem;
    height: 8rem;
    place-items: center;
    border: 1px solid rgb(255 255 255 / 0.24);
    border-radius: 50%;
    color: rgb(255 255 255 / 0.72);
    font-size: 3rem;
    background: rgb(0 0 0 / 0.12);
    transform: translate(-50%, -50%);
}

/* --------------------------------------------------------------------------
   Filtros y resumen de resultados
   -------------------------------------------------------------------------- */

.photogallery-page .photogallery-toolbar {
    border-color: var(--photogallery-line);
    background: var(--photogallery-surface);
    box-shadow: var(--bs-box-shadow-sm);
    scroll-margin-top: 5rem;
}

.photogallery-page .photogallery-toolbar .card-body {
    display: grid;
    grid-template-columns: minmax(18rem, 0.9fr) minmax(26rem, 1.1fr);
    gap: 1.5rem 2rem;
    align-items: end;
}

.photogallery-page .photogallery-toolbar__heading {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.photogallery-page .photogallery-toolbar__heading p {
    color: var(--photogallery-muted);
    font-size: 0.875rem;
}

.photogallery-page .photogallery-view-switch {
    display: inline-flex;
    grid-column: 1 / -1;
    justify-self: start;
    padding: 0.25rem;
    border: 1px solid var(--photogallery-line);
    border-radius: 999px;
    background: var(--any-state-bg);
}

.photogallery-page .photogallery-view-switch__item {
    display: inline-flex;
    min-height: 2.5rem;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.55rem 0.9rem;
    border-radius: 999px;
    color: var(--photogallery-muted);
    font-size: 0.875rem;
    font-weight: 700;
    text-decoration: none;
    white-space: nowrap;
    transition:
        color 0.15s ease,
        background-color 0.15s ease,
        box-shadow 0.15s ease;
}

.photogallery-page a.photogallery-view-switch__item:link,
.photogallery-page a.photogallery-view-switch__item:visited {
    color: var(--photogallery-muted);
}

.photogallery-page a.photogallery-view-switch__item:hover,
.photogallery-page a.photogallery-view-switch__item:focus-visible {
    color: var(--any-link-color);
    background: var(--any-hover-bg);
}

.photogallery-page .photogallery-view-switch__item:focus-visible {
    outline: 2px solid var(--any-link-color);
    outline-offset: 2px;
}

.photogallery-page a.photogallery-view-switch__item.is-active:link,
.photogallery-page a.photogallery-view-switch__item.is-active:visited,
.photogallery-page a.photogallery-view-switch__item.is-active:hover,
.photogallery-page a.photogallery-view-switch__item.is-active:focus-visible,
.photogallery-page a.photogallery-view-switch__item.is-active:active {
    color: #fff;
    background: var(--any-surface-primary);
    box-shadow: var(--bs-box-shadow-sm);
}

.photogallery-page .photogallery-view-switch__count {
    display: inline-flex;
    min-width: 1.45rem;
    min-height: 1.45rem;
    align-items: center;
    justify-content: center;
    padding: 0.1rem 0.4rem;
    border-radius: 999px;
    color: currentColor;
    background: var(--bs-secondary-bg);
    font-size: 0.72rem;
}

.photogallery-page .photogallery-view-switch__item.is-active .photogallery-view-switch__count {
    background: rgb(255 255 255 / 0.18);
}

.photogallery-page .photogallery-filter {
    display: grid;
    grid-template-columns: minmax(13rem, 1fr) auto auto;
    gap: 0.75rem;
    align-items: end;
}

.photogallery-page .photogallery-filter__field {
    min-width: 0;
}

.photogallery-page .photogallery-filter .form-label {
    margin-bottom: 0.35rem;
    color: var(--photogallery-muted);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.photogallery-page .photogallery-filter .btn {
    display: inline-flex;
    min-height: 2.375rem;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
    white-space: nowrap;
}

.photogallery-page .photogallery-result {
    display: flex;
    grid-column: 1 / -1;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--photogallery-line);
    color: var(--photogallery-muted);
    font-size: 0.875rem;
}

.photogallery-page .photogallery-result strong {
    display: inline-flex;
    padding: 0.35rem 0.7rem;
    border-radius: 999px;
    color: var(--any-section-icon-color);
    background: var(--any-section-icon-bg);
    font-size: 0.75rem;
    font-weight: 700;
}

/* --------------------------------------------------------------------------
   Mosaico fotográfico
   -------------------------------------------------------------------------- */

.photogallery-page .photogallery-grid {
    display: grid;
    grid-auto-flow: dense;
    grid-auto-rows: clamp(11rem, 14vw, 14rem);
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.85rem;
}

.photogallery-page .photogallery-tile {
    position: relative;
    min-width: 0;
    padding: 0;
    overflow: hidden;
    border: 0;
    border-radius: var(--bs-border-radius-lg);
    color: #fff;
    background: var(--bs-tertiary-bg);
    box-shadow: var(--bs-box-shadow-sm);
    cursor: pointer;
    text-align: left;
    isolation: isolate;
}

.photogallery-page .photogallery-tile--featured {
    grid-row: span 2;
}

.photogallery-page .photogallery-tile--left {
    grid-column: 1 / span 2;
}

.photogallery-page .photogallery-tile--center {
    grid-column: 2 / span 2;
}

.photogallery-page .photogallery-tile--right {
    grid-column: 3 / span 2;
}

.photogallery-page .photogallery-tile img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.28s ease;
}

.photogallery-page .photogallery-tile__shade {
    position: absolute;
    inset: 0;
    z-index: 1;
    background: linear-gradient(180deg, rgb(0 0 0 / 0.08) 30%, rgb(0 0 0 / 0.84) 100%);
    transition: background-color 0.2s ease;
}

.photogallery-page .photogallery-tile__category {
    position: absolute;
    z-index: 2;
    top: 0.75rem;
    left: 0.75rem;
    max-width: calc(100% - 1.5rem);
    padding: 0.3rem 0.6rem;
    overflow: hidden;
    border: 1px solid rgb(255 255 255 / 0.22);
    border-radius: 999px;
    color: #fff;
    background: rgb(0 0 0 / 0.44);
    font-size: 0.75rem;
    font-weight: 700;
    text-overflow: ellipsis;
    white-space: nowrap;
    backdrop-filter: blur(0.45rem);
}

.photogallery-page .photogallery-tile__caption {
    position: absolute;
    z-index: 2;
    right: 0;
    bottom: 0;
    left: 0;
    display: grid;
    gap: 0.35rem;
    padding: 2.75rem 0.9rem 0.85rem;
}

.photogallery-page .photogallery-tile__caption strong {
    overflow: hidden;
    color: #fff;
    font-size: 0.875rem;
    font-weight: 700;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.photogallery-page .photogallery-tile__caption > span {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    color: rgb(255 255 255 / 0.72);
    font-size: 0.75rem;
}

.photogallery-page .photogallery-tile:hover img,
.photogallery-page .photogallery-tile:focus-visible img {
    transform: scale(1.045);
}

.photogallery-page .photogallery-tile:hover .photogallery-tile__shade,
.photogallery-page .photogallery-tile:focus-visible .photogallery-tile__shade {
    background-color: color-mix(in srgb, var(--any-surface-primary) 12%, transparent);
}

.photogallery-page .photogallery-tile:focus-visible {
    outline: 0;
    box-shadow:
        inset 0 0 0 3px var(--any-hover-border),
        0 0 0 0.25rem color-mix(in srgb, var(--any-hover-border) 28%, transparent);
}

/* --------------------------------------------------------------------------
   Estado vacío y paginación
   -------------------------------------------------------------------------- */

.photogallery-page .photogallery-empty {
    border-color: var(--photogallery-line);
    background: var(--photogallery-surface);
    box-shadow: var(--bs-box-shadow-sm);
}

.photogallery-page .photogallery-empty .card-body {
    display: grid;
    justify-items: center;
    padding-block: clamp(3rem, 8vw, 5rem) !important;
    text-align: center;
}

.photogallery-page .photogallery-empty__icon {
    display: grid;
    width: 4.5rem;
    height: 4.5rem;
    place-items: center;
    margin-bottom: 1rem;
    border-radius: 50%;
    color: var(--any-section-icon-color);
    background: var(--any-section-icon-bg);
    font-size: 1.6rem;
}

.photogallery-page .photogallery-empty p {
    max-width: 36rem;
    margin: 0 0 1.25rem;
    color: var(--photogallery-muted);
}

.photogallery-page .photogallery-pagination {
    padding: 0.35rem 0 0.5rem;
}

.photogallery-page .photogallery-pagination .page-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
}

/* --------------------------------------------------------------------------
   Visor inmersivo
   -------------------------------------------------------------------------- */

.photogallery-viewer {
    overflow: hidden;
    border: 0;
    border-radius: var(--bs-border-radius-xl);
    background: var(--bs-modal-bg);
    box-shadow: 0 1.75rem 4rem rgb(0 0 0 / 0.38);
}

.photogallery-viewer .photogallery-viewer__header {
    padding: 1rem 1.25rem;
    border-bottom: 0;
    color: #fff;
    background: var(--any-surface-primary);
}

.photogallery-viewer .photogallery-viewer__title {
    display: flex;
    align-items: center;
    gap: 0.8rem;
}

.photogallery-viewer .photogallery-viewer__title-icon {
    display: grid;
    width: 2.75rem;
    height: 2.75rem;
    flex: 0 0 2.75rem;
    place-items: center;
    border-radius: 50%;
    color: #fff;
    background: rgb(255 255 255 / 0.18);
    font-size: 1.1rem;
}

.photogallery-viewer .photogallery-eyebrow {
    display: block;
    margin-bottom: 0.15rem;
    color: rgb(255 255 255 / 0.68);
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.11em;
    text-transform: uppercase;
}

.photogallery-viewer .modal-title {
    color: #fff;
}

.photogallery-viewer .photogallery-viewer__stage {
    position: relative;
    display: grid;
    min-height: 18rem;
    place-items: center;
    padding: 0;
    background:
        radial-gradient(circle at center, rgb(255 255 255 / 0.08), transparent 58%),
        color-mix(in srgb, var(--bs-dark) 88%, #000);
}

.photogallery-viewer .photogallery-viewer__image {
    display: block;
    max-width: 100%;
    max-height: min(68vh, 52rem);
    object-fit: contain;
}

.photogallery-viewer .photogallery-viewer__nav {
    position: absolute;
    z-index: 2;
    top: 50%;
    display: grid;
    width: 3rem;
    height: 3rem;
    place-items: center;
    padding: 0;
    border: 1px solid rgb(255 255 255 / 0.28);
    border-radius: 50%;
    color: #fff;
    background: rgb(0 0 0 / 0.52);
    font-size: 1.25rem;
    backdrop-filter: blur(0.4rem);
    transform: translateY(-50%);
    transition:
        background-color 0.15s ease,
        border-color 0.15s ease,
        opacity 0.15s ease;
}

.photogallery-viewer .photogallery-viewer__nav:hover,
.photogallery-viewer .photogallery-viewer__nav:focus-visible {
    border-color: var(--any-brand-secondary);
    background: var(--any-surface-primary);
    outline: 0;
}

.photogallery-viewer .photogallery-viewer__nav:disabled {
    opacity: 0.25;
    cursor: not-allowed;
}

.photogallery-viewer .photogallery-viewer__nav--previous {
    left: 1rem;
}

.photogallery-viewer .photogallery-viewer__nav--next {
    right: 1rem;
}

.photogallery-viewer .photogallery-viewer__footer {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 1rem 1.5rem;
    align-items: center;
    padding: 1rem 1.25rem;
    background: var(--bs-modal-bg);
}

.photogallery-viewer .photogallery-viewer__meta {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.65rem 1rem;
    width: 100%;
    margin: 0;
}

.photogallery-viewer .photogallery-viewer__meta > div {
    min-width: 0;
}

.photogallery-viewer .photogallery-viewer__meta dt {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    margin-bottom: 0.15rem;
    color: var(--bs-secondary-color);
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.photogallery-viewer .photogallery-viewer__meta dt i {
    color: var(--any-link-color);
    font-size: 0.9rem;
}

.photogallery-viewer .photogallery-viewer__meta dd {
    margin: 0;
    overflow: hidden;
    color: var(--bs-emphasis-color);
    font-size: 0.875rem;
    font-weight: 600;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.photogallery-viewer .photogallery-viewer__actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-end;
    gap: 0.5rem;
}

.photogallery-viewer .photogallery-viewer__actions form {
    margin: 0;
}

.photogallery-viewer .photogallery-viewer__actions .btn {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
}

.photogallery-viewer .photogallery-viewer__actions .badge {
    color: #fff;
    background: var(--any-surface-primary);
}

.photogallery-viewer .photogallery-viewer__likes-summary {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    color: var(--bs-secondary-color);
    font-size: 0.875rem;
    font-weight: 600;
}

.photogallery-viewer .photogallery-viewer__status {
    flex-basis: 100%;
    min-height: 1.2rem;
    color: var(--bs-secondary-color);
    font-size: 0.75rem;
    text-align: right;
}

.photogallery-viewer .photogallery-viewer__status[data-status='success'] {
    color: var(--bs-success-text-emphasis);
}

.photogallery-viewer .photogallery-viewer__status[data-status='error'] {
    color: var(--bs-danger-text-emphasis);
}

/* --------------------------------------------------------------------------
   Responsive
   -------------------------------------------------------------------------- */

@media (max-width: 1199.98px) {
    .photogallery-page .photogallery-hero {
        grid-template-columns: minmax(0, 1fr) minmax(20rem, 0.8fr);
    }

    .photogallery-page .photogallery-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .photogallery-page .photogallery-tile--left,
    .photogallery-page .photogallery-tile--center,
    .photogallery-page .photogallery-tile--right {
        grid-column: span 2;
    }
}

@media (max-width: 991.98px) {
    .photogallery-page .photogallery-hero {
        grid-template-columns: minmax(0, 1fr);
    }

    .photogallery-page .photogallery-hero__content {
        padding-bottom: 1rem;
    }

    .photogallery-page .photogallery-hero__visual {
        min-height: 18rem;
    }

    .photogallery-page .photogallery-hero__photo--1 {
        width: min(32rem, 68%);
        height: 15rem;
        right: 12%;
        top: 3%;
    }

    .photogallery-page .photogallery-hero__photo--2 {
        left: 8%;
        right: auto;
    }

    .photogallery-page .photogallery-toolbar .card-body {
        grid-template-columns: minmax(0, 1fr);
    }

    .photogallery-page .photogallery-filter {
        grid-template-columns: minmax(13rem, 1fr) auto auto;
    }

    .photogallery-viewer .photogallery-viewer__footer {
        grid-template-columns: 1fr;
    }

    .photogallery-viewer .photogallery-viewer__actions {
        justify-content: flex-start;
    }

    .photogallery-viewer .photogallery-viewer__status {
        text-align: left;
    }
}

@media (max-width: 767.98px) {
    .photogallery-page .photogallery-grid {
        grid-auto-rows: 12rem;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 0.65rem;
    }

    .photogallery-page .photogallery-filter {
        grid-template-columns: 1fr 1fr;
    }

    .photogallery-page .photogallery-filter__field {
        grid-column: 1 / -1;
    }

    .photogallery-viewer .photogallery-viewer__meta {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 575.98px) {
    .photogallery-page {
        gap: 1rem;
    }

    .photogallery-page .photogallery-hero {
        min-height: auto;
    }

    .photogallery-page .photogallery-hero__content {
        padding: 1.5rem;
    }

    .photogallery-page .photogallery-hero h1 {
        font-size: clamp(2.35rem, 13vw, 3.35rem);
    }

    .photogallery-page .photogallery-hero__stats {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .photogallery-page .photogallery-hero__stats > div {
        min-width: 0;
        padding: 0.65rem;
    }

    .photogallery-page .photogallery-hero__visual {
        min-height: 13rem;
    }

    .photogallery-page .photogallery-hero__photo--1 {
        width: 76%;
        height: 11rem;
        right: 10%;
    }

    .photogallery-page .photogallery-hero__photo--2 {
        display: none;
    }

    .photogallery-page .photogallery-hero__photo--3 {
        width: 8rem;
        height: 5.5rem;
        right: 3%;
        bottom: 2%;
    }

    .photogallery-page .photogallery-toolbar .card-body {
        padding: 1.25rem !important;
    }

    .photogallery-page .photogallery-toolbar__heading {
        align-items: flex-start;
    }

    .photogallery-page .photogallery-filter {
        grid-template-columns: minmax(0, 1fr);
    }

    .photogallery-page .photogallery-view-switch {
        display: grid;
        width: 100%;
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .photogallery-page .photogallery-view-switch__item {
        gap: 0.35rem;
        padding-inline: 0.45rem;
        font-size: 0.8rem;
    }

    .photogallery-page .photogallery-filter__field {
        grid-column: auto;
    }

    .photogallery-page .photogallery-filter .btn {
        width: 100%;
    }

    .photogallery-page .photogallery-result {
        align-items: flex-start;
        flex-direction: column;
        gap: 0.55rem;
    }

    .photogallery-page .photogallery-grid {
        grid-auto-rows: 15rem;
        grid-template-columns: minmax(0, 1fr);
    }

    .photogallery-page .photogallery-tile--featured {
        grid-column: auto;
        grid-row: auto;
    }

    .photogallery-page .photogallery-pagination__label {
        display: none;
    }

    .photogallery-page .photogallery-pagination__page--distant {
        display: none;
    }

    .photogallery-viewer {
        border-radius: 0;
    }

    .photogallery-viewer .photogallery-viewer__header {
        padding: 0.85rem 1rem;
    }

    .photogallery-viewer .photogallery-viewer__title-icon {
        width: 2.4rem;
        height: 2.4rem;
        flex-basis: 2.4rem;
    }

    .photogallery-viewer .photogallery-viewer__stage {
        min-height: 50vh;
    }

    .photogallery-viewer .photogallery-viewer__image {
        max-height: 58vh;
    }

    .photogallery-viewer .photogallery-viewer__nav {
        width: 2.65rem;
        height: 2.65rem;
    }

    .photogallery-viewer .photogallery-viewer__nav--previous {
        left: 0.65rem;
    }

    .photogallery-viewer .photogallery-viewer__nav--next {
        right: 0.65rem;
    }

    .photogallery-viewer .photogallery-viewer__footer {
        align-content: start;
        padding: 1rem;
    }

    .photogallery-viewer .photogallery-viewer__meta {
        grid-template-columns: 1fr;
    }

    .photogallery-viewer .photogallery-viewer__actions,
    .photogallery-viewer .photogallery-viewer__actions form,
    .photogallery-viewer .photogallery-viewer__actions .btn {
        width: 100%;
    }

    .photogallery-viewer .photogallery-viewer__actions .btn {
        justify-content: center;
    }
}

@media (prefers-reduced-motion: reduce) {
    .photogallery-page .photogallery-tile img,
    .photogallery-viewer .photogallery-viewer__nav {
        transition: none;
    }
}
