
/**
 * Comtechzone Premium Gallery
 *
 * Automatic album slideshow.
 * Compact album titles and photo counts.
 * Full-width group viewer.
 * Independent mouse and touch scrolling.
 * Responsive fullscreen lightbox.
 *
 * @package Comtechzone_Theme
 * @author Comtechzone
 * @version 3.3.0
 */


/* ==========================================
   01. DESIGN VARIABLES
========================================== */

.ctz-gallery-page {
    --ctz-gallery-primary: #0b2038;
    --ctz-gallery-secondary: #176bba;
    --ctz-gallery-heading: #102c46;
    --ctz-gallery-text: #334155;
    --ctz-gallery-muted: #64748b;
    --ctz-gallery-border: #dce6f0;
    --ctz-gallery-surface: #f0f5fa;
    --ctz-gallery-background: #ffffff;
    --ctz-gallery-gold: #c6a46c;
    --ctz-gallery-gap: clamp(14px, 2vw, 24px);
    --ctz-gallery-radius: 10px;
    --ctz-gallery-header-offset: 100px;

    width: 100%;
    min-width: 0;
    background: #ffffff;
    color: var(--ctz-gallery-text);
}

.ctz-gallery-page [hidden],
.ctz-gallery-lightbox [hidden] {
    display: none !important;
}


/* ==========================================
   02. ACCESSIBLE PAGE TITLE
========================================== */

.ctz-gallery-page > .screen-reader-text {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    clip-path: inset(50%);
    white-space: nowrap;
    border: 0;
}


/* ==========================================
   03. GALLERY INTRODUCTION
========================================== */

.ctz-gallery-page .ctz-gallery-intro-section {
    padding-top: clamp(20px, 3vw, 36px);
    padding-bottom: 0;
}

.ctz-gallery-introduction {
    width: 100%;
    max-width: 1100px;
    margin: 0;
    color: var(--ctz-gallery-text);
    font-size: 15px;
    line-height: 1.85;
    overflow-wrap: anywhere;
}

.ctz-gallery-introduction > :first-child {
    margin-top: 0;
}

.ctz-gallery-introduction > :last-child {
    margin-bottom: 0;
}

.ctz-gallery-introduction p {
    margin-bottom: 16px;
}

.ctz-gallery-introduction h2,
.ctz-gallery-introduction h3,
.ctz-gallery-introduction h4 {
    margin: 24px 0 12px;
    color: var(--ctz-gallery-heading);
    line-height: 1.4;
}

.ctz-gallery-introduction a {
    color: var(--ctz-gallery-secondary);
    text-decoration: underline;
    text-underline-offset: 4px;
}

.ctz-gallery-introduction img {
    max-width: 100%;
    height: auto;
}

.ctz-gallery-introduction ul,
.ctz-gallery-introduction ol {
    margin-block: 16px;
    padding-inline-start: 24px;
}

.ctz-gallery-introduction ul {
    list-style: disc;
}

.ctz-gallery-introduction ol {
    list-style: decimal;
}

.ctz-gallery-introduction .wp-block-table {
    max-width: 100%;
    overflow-x: auto;
}


/* ==========================================
   04. MAIN GALLERY SECTION
========================================== */

.ctz-gallery-page .ctz-gallery-listing-section {
    position: relative;
    padding-top: clamp(22px, 3vw, 38px);
    padding-bottom: clamp(30px, 4vw, 54px);
    background: #ffffff;
}

.ctz-gallery-page
.ctz-gallery-listing-section--first {
    padding-top: clamp(22px, 3vw, 38px);
}


/* ==========================================
   05. MAIN ALBUM GRID
========================================== */

.ctz-gallery-album-grid {
    --ctz-gallery-image-ratio: 4 / 3;
    --ctz-gallery-image-fit: cover;

    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    align-items: stretch;
    gap: var(--ctz-gallery-gap, 24px);
    width: 100%;
    min-width: 0;
}

.ctz-gallery-album-grid.ctz-gallery-album-columns-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.ctz-gallery-album-grid.ctz-gallery-album-columns-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.ctz-gallery-album-grid.ctz-gallery-album-columns-4 {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}


/* ==========================================
   06. ALBUM CARD
========================================== */

.ctz-gallery-album-card {
    position: relative;
    display: block;
    width: 100%;
    min-width: 0;
    margin: 0;
    padding: 0;
    background: #ffffff;
    border: 1px solid #dce6f0;
    border-radius: 12px;
    box-shadow: 0 6px 24px rgba(11, 32, 56, 0.07);
    transition:
        border-color 220ms ease,
        box-shadow 220ms ease;
}

.ctz-gallery-album-card:hover {
    border-color: #9cb9d4;
    box-shadow: 0 12px 32px rgba(11, 32, 56, 0.12);
}

.ctz-gallery-album-card[open] {
    grid-column: 1 / -1;
}

.ctz-gallery-album-card:not([open])
> .ctz-gallery-album-panel {
    display: none;
}


/* ==========================================
   07. ALBUM TRIGGER
========================================== */

.ctz-gallery-album-trigger {
    display: flex;
    flex-direction: column;
    width: 100%;
    height: 100%;
    min-width: 0;
    margin: 0;
    padding: 0;
    overflow: hidden;
    border-radius: 11px;
    list-style: none;
    cursor: pointer;
}

.ctz-gallery-album-card[open]
> .ctz-gallery-album-trigger {
    height: auto;
}

.ctz-gallery-album-trigger::-webkit-details-marker {
    display: none;
}

.ctz-gallery-album-trigger::marker {
    content: "";
}

.ctz-gallery-album-trigger:focus-visible {
    outline: 3px solid #176bba;
    outline-offset: 4px;
}


/* ==========================================
   08. AUTOMATIC SLIDESHOW IMAGE
========================================== */

.ctz-gallery-album-media {
    position: relative;
    display: block;
    width: 100%;
    aspect-ratio: var(--ctz-gallery-image-ratio, 4 / 3);
    overflow: hidden;
    isolation: isolate;
    background: #edf3f8;
    border-radius: 11px 11px 0 0;
}

.ctz-gallery-album-media > img,
.ctz-gallery-album-media .ctz-gallery-album-image {
    display: block;
    width: 100%;
    height: 100%;
    max-width: 100%;
    margin: 0;
    padding: 0;
    object-fit: var(--ctz-gallery-image-fit, cover);
    object-position: center;
    opacity: 1;
    transition: opacity 250ms ease;
}

.ctz-gallery-album-media.ctz-album-image-changing
.ctz-gallery-album-image {
    opacity: 0;
}


/* ==========================================
   09. ALBUM PHOTO COUNT

   Photo count remains outside the image.
========================================== */

.ctz-gallery-page
.ctz-gallery-album-media
.ctz-gallery-album-count {
    display: none !important;
}

.ctz-gallery-page
.ctz-gallery-album-title-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 8px;
    width: 100%;
    min-width: 0;
}

.ctz-gallery-page
.ctz-gallery-album-title-row
.ctz-gallery-album-count {
    position: static !important;
    inset: auto !important;
    z-index: auto;

    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;

    gap: 5px;
    min-height: 24px;
    margin: 0;
    padding: 4px 8px;

    background: #edf4fa;
    border: 1px solid #dce6f0;
    border-radius: 5px;

    color: #174c7c;
    font-size: 11px !important;
    font-weight: 600;
    line-height: 1.4;
    white-space: nowrap;
    box-shadow: none;
}

.ctz-gallery-album-count svg {
    display: block;
    width: 13px;
    height: 13px;
    flex-shrink: 0;
    color: #176bba;
}


/* ==========================================
   10. SLIDESHOW PROGRESS
========================================== */

.ctz-gallery-album-progress {
    position: absolute;
    bottom: 0;
    inset-inline: 0;
    z-index: 4;
    width: 100%;
    height: 3px;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.3);
    pointer-events: none;
}

.ctz-gallery-album-progress-bar {
    display: block;
    width: 100%;
    height: 100%;
    background: #c6a46c;
    transform: scaleX(0);
    transform-origin: left center;
}

[data-ctz-album-progress] {
    transform-origin: left center;
}

@keyframes ctzAlbumProgress {
    from {
        transform: scaleX(0);
    }

    to {
        transform: scaleX(1);
    }
}


/* ==========================================
   11. ALBUM HOVER OVERLAY
========================================== */

.ctz-gallery-album-overlay {
    position: absolute;
    inset: 0;
    z-index: 2;

    display: flex;
    align-items: center;
    justify-content: center;

    background: linear-gradient(
        145deg,
        rgba(11, 32, 56, 0.08),
        rgba(11, 32, 56, 0.4)
    );

    opacity: 0;
    pointer-events: none;
    transition: opacity 220ms ease;
}

.ctz-gallery-album-trigger:hover
.ctz-gallery-album-overlay,
.ctz-gallery-album-trigger:focus-visible
.ctz-gallery-album-overlay {
    opacity: 1;
}

.ctz-gallery-album-overlay-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    background: #ffffff;
    border: 2px solid #e8ce9f;
    border-radius: 10px;
    color: #0b2038;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
}

.ctz-gallery-album-overlay-icon svg {
    width: 23px;
    height: 23px;
}


/* ==========================================
   12. COMPACT ALBUM CONTENT
========================================== */

.ctz-gallery-album-content {
    position: relative;

    display: flex;
    flex: 1;
    flex-direction: column;
    justify-content: space-between;

    gap: 10px;
    min-width: 0;
    padding: 14px 16px 12px;

    background:
        radial-gradient(
            circle at 100% 100%,
            rgba(23, 107, 186, 0.05),
            transparent 65%
        ),
        #ffffff;
}

.ctz-gallery-album-content::before {
    position: absolute;
    top: 0;
    inset-inline-start: 16px;
    width: 32px;
    height: 3px;
    background: #c6a46c;
    content: "";
}

.ctz-gallery-page
.ctz-gallery-album-title {
    display: block;
    flex: 1 1 140px;
    min-width: 0;
    margin: 0;

    color: #102c46;
    font-size: 14px !important;
    font-weight: 600 !important;
    line-height: 1.5 !important;
    letter-spacing: 0;

    overflow-wrap: anywhere;
}


/* ==========================================
   13. VIEW PHOTOS LINK
========================================== */

.ctz-gallery-album-action {
    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 8px;
    width: 100%;
    padding-top: 9px;

    border-top: 1px solid #e6edf4;
    color: #176bba;

    font-size: 11px;
    font-weight: 600;
    line-height: 1.5;
}

.ctz-gallery-album-action svg {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    transition: transform 180ms ease;
}

.ctz-gallery-album-trigger:hover
.ctz-gallery-album-action svg {
    transform: translateX(3px);
}


/* ==========================================
   14. SLIDESHOW CONTROL
========================================== */

.ctz-gallery-slideshow-toolbar {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    margin-bottom: 14px;
}

.ctz-gallery-page .ctz-gallery-slideshow-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    gap: 8px;
    min-height: 38px;
    margin: 0;
    padding: 8px 13px;

    background: #f4f8fc;
    border: 1px solid #dce6f0;
    border-radius: 6px;

    color: #102c46;
    font-family: inherit;
    font-size: 12px;
    font-weight: 600;
    line-height: 1.4;

    cursor: pointer;
}

.ctz-gallery-slideshow-toggle::before {
    width: 9px;
    height: 11px;
    border-inline: 3px solid currentColor;
    content: "";
}

.ctz-gallery-slideshow-toggle[aria-pressed="true"]::before {
    width: 0;
    height: 0;
    border: 0;
    border-top: 6px solid transparent;
    border-bottom: 6px solid transparent;
    border-inline-start: 9px solid currentColor;
}

.ctz-gallery-page
.ctz-gallery-slideshow-toggle:hover {
    background: #e8f0f8;
    border-color: #a9c2d9;
}


/* ==========================================
   15. ALBUM FALLBACK PANEL
========================================== */

.ctz-gallery-album-panel {
    width: 100%;
    min-width: 0;
    padding: 20px;
    background: #f0f5fa;
}

.ctz-gallery-album-panel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 18px;
}

.ctz-gallery-album-panel-title {
    margin: 0;
    color: #102c46;
    font-size: 15px;
    font-weight: 600;
    line-height: 1.5;
    overflow-wrap: anywhere;
}

.ctz-gallery-album-close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;

    width: 38px;
    height: 38px;
    padding: 0;

    background: #ffffff;
    border: 1px solid #dce6f0;
    border-radius: 6px;
    color: #102c46;
    cursor: pointer;
}

.ctz-gallery-album-close:hover {
    background: #0b2038;
    border-color: #0b2038;
    color: #ffffff;
}

.ctz-gallery-album-close[hidden] {
    display: none !important;
}


/* ==========================================
   16. FULL WIDTH ALBUM MODE
========================================== */

body.ctz-album-view-active
.ctz-gallery-page {
    width: 100%;
    max-width: none !important;
    min-width: 0;
    margin: 0 !important;
    padding: 0 !important;
    overflow: visible;
}

body.ctz-album-view-active
.ctz-gallery-page
.ctz-gallery-listing-section {
    width: 100%;
    max-width: none !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: visible;
}

body.ctz-album-view-active
.ctz-gallery-page
.ctz-gallery-listing-section
> .ctz-container {
    box-sizing: border-box;
    width: 100% !important;
    max-width: none !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: visible;
}


/* ==========================================
   17. FULL SCREEN GROUP VIEWER
========================================== */

.ctz-gallery-page
.ctz-gallery-album-viewer {
    position: relative;

    display: flex !important;
    flex-direction: column;

    box-sizing: border-box;

    width: 100% !important;
    max-width: none !important;

    height: calc(
        100vh - var(--ctz-gallery-header-offset, 100px)
    );

    height: calc(
        100dvh - var(--ctz-gallery-header-offset, 100px)
    );

    min-height: 240px;
    min-width: 0;

    margin: 0 !important;
    padding: 0 !important;

    overflow: hidden;

    background: #f0f5fa;
    border: 0;
    border-radius: 0;
    box-shadow: none;
}

.ctz-gallery-page
.ctz-gallery-album-viewer[hidden] {
    display: none !important;
}


/* ==========================================
   18. ALBUM DIALOG COMPATIBILITY
========================================== */

.ctz-gallery-album-dialog:not([open]) {
    display: none !important;
}

.ctz-gallery-album-dialog[open] {
    position: fixed;
    inset: 0;

    box-sizing: border-box;

    width: 100%;
    height: 100vh;
    height: 100dvh;

    max-width: none;
    max-height: none;

    margin: 0;
    padding: 0;
    overflow: hidden;

    background: #f0f5fa;
    border: 0;
}

.ctz-gallery-album-dialog-shell {
    display: flex;
    flex-direction: column;

    width: 100%;
    height: 100%;
    min-height: 0;
    min-width: 0;

    overflow: hidden;
}


/* ==========================================
   19. GROUP VIEWER HEADER
========================================== */

.ctz-gallery-album-dialog-header {
    position: relative;

    display: flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: space-between;

    gap: 16px;
    min-height: 64px;
    padding: 12px clamp(16px, 3vw, 40px);

    background:
        repeating-linear-gradient(
            90deg,
            transparent 0,
            transparent 29px,
            rgba(255, 255, 255, 0.035) 29px,
            rgba(255, 255, 255, 0.035) 30px
        ),
        repeating-linear-gradient(
            0deg,
            transparent 0,
            transparent 29px,
            rgba(255, 255, 255, 0.035) 29px,
            rgba(255, 255, 255, 0.035) 30px
        ),
        linear-gradient(
            120deg,
            #0b2038,
            #174c7c
        );

    border-bottom: 3px solid #c6a46c;
    color: #ffffff;
    z-index: 2;
}

.ctz-gallery-album-dialog-heading {
    display: flex;
    flex: 1;
    flex-direction: column;
    gap: 3px;
    min-width: 0;
}

.ctz-gallery-page
.ctz-gallery-album-dialog-title,
.ctz-gallery-album-dialog-title {
    margin: 0;
    color: #ffffff;
    font-size: 16px !important;
    font-weight: 600;
    line-height: 1.5;
    letter-spacing: 0;
    overflow-wrap: anywhere;
}

.ctz-gallery-album-dialog-counter {
    display: block;
    color: #e8ce9f;
    font-size: 12px;
    font-weight: 500;
    line-height: 1.5;
}


/* ==========================================
   20. BACK TO GALLERY BUTTON
========================================== */

.ctz-gallery-page
.ctz-gallery-album-dialog-close,
.ctz-gallery-album-dialog-close {
    display: inline-flex;
    flex-shrink: 0;
    align-items: center;
    justify-content: center;

    min-height: 40px;
    margin: 0;
    padding: 9px 15px;

    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.35);
    border-radius: 6px;

    color: #ffffff;
    font-family: inherit;
    font-size: 12px;
    font-weight: 600;
    line-height: 1.4;

    cursor: pointer;

    transition:
        background-color 180ms ease,
        border-color 180ms ease,
        color 180ms ease;
}

.ctz-gallery-page
.ctz-gallery-album-dialog-close:hover,
.ctz-gallery-album-dialog-close:hover {
    background: #ffffff;
    border-color: #ffffff;
    color: #0b2038;
}


/* ==========================================
   21. MOUSE AND TOUCH SCROLLING
========================================== */

.ctz-gallery-album-viewer
.ctz-gallery-album-dialog-content,
.ctz-gallery-album-dialog
.ctz-gallery-album-dialog-content {
    position: relative;

    display: block;
    flex: 1 1 0%;

    box-sizing: border-box;

    width: 100%;
    max-width: none;
    min-width: 0;
    min-height: 0;
    height: auto;

    margin: 0;
    padding: clamp(16px, 2.5vw, 36px);

    overflow-x: hidden !important;
    overflow-y: auto !important;

    overscroll-behavior-y: contain;

    scrollbar-width: auto;
    scrollbar-color: #7993ac #e3eaf1;
    scrollbar-gutter: stable;

    touch-action: pan-y pinch-zoom;
    -webkit-overflow-scrolling: touch;

    background:
        radial-gradient(
            circle at 1px 1px,
            rgba(23, 107, 186, 0.055) 1px,
            transparent 0
        ),
        #f0f5fa;

    background-size: 22px 22px;
}

.ctz-gallery-album-dialog-content::-webkit-scrollbar {
    width: 10px;
}

.ctz-gallery-album-dialog-content::-webkit-scrollbar-track {
    background: #e3eaf1;
}

.ctz-gallery-album-dialog-content::-webkit-scrollbar-thumb {
    background: #7993ac;
    border: 2px solid #e3eaf1;
    border-radius: 10px;
}

.ctz-gallery-album-dialog-content::-webkit-scrollbar-thumb:hover {
    background: #174c7c;
}

.ctz-gallery-album-viewer
.ctz-gallery-album-panel--fullscreen,
.ctz-gallery-album-dialog
.ctz-gallery-album-panel--fullscreen {
    display: block !important;

    width: 100%;
    max-width: none;
    min-width: 0;
    min-height: 0;
    height: auto;

    margin: 0;
    padding: 0;

    overflow: visible;
    background: transparent;
    border: 0;
}

.ctz-gallery-album-panel--fullscreen
.ctz-gallery-album-panel-header {
    display: none;
}


/* ==========================================
   22. SHARED PHOTO GRID
========================================== */

.ctz-gallery-grid {
    --ctz-gallery-image-ratio: 4 / 3;
    --ctz-gallery-image-fit: cover;

    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    align-items: stretch;

    gap: var(--ctz-gallery-gap, 24px);

    width: 100%;
    min-width: 0;
}

.ctz-gallery-grid.ctz-gallery-columns-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.ctz-gallery-grid.ctz-gallery-columns-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.ctz-gallery-grid.ctz-gallery-columns-4 {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}


/* ==========================================
   23. FULL WIDTH GROUP PHOTO GRID
========================================== */

.ctz-gallery-album-viewer
.ctz-gallery-grid,
.ctz-gallery-album-dialog
.ctz-gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));

    align-items: start;
    align-content: start;

    gap: clamp(14px, 2vw, 28px);

    width: 100%;
    max-width: none;
    height: auto;
    min-width: 0;
    min-height: 0;

    overflow: visible;
}


/* ==========================================
   24. IMAGE ASPECT RATIOS
========================================== */

.ctz-gallery-ratio-square {
    --ctz-gallery-image-ratio: 1 / 1;
}

.ctz-gallery-ratio-standard {
    --ctz-gallery-image-ratio: 4 / 3;
}

.ctz-gallery-ratio-landscape {
    --ctz-gallery-image-ratio: 3 / 2;
}

.ctz-gallery-ratio-wide {
    --ctz-gallery-image-ratio: 16 / 9;
}

.ctz-gallery-ratio-portrait {
    --ctz-gallery-image-ratio: 3 / 4;
}

.ctz-gallery-fit-cover {
    --ctz-gallery-image-fit: cover;
}

.ctz-gallery-fit-contain {
    --ctz-gallery-image-fit: contain;
}


/* ==========================================
   25. SHARED PHOTO CARD
========================================== */

.ctz-gallery-card {
    position: relative;

    display: flex;
    flex-direction: column;

    width: 100%;
    min-width: 0;
    height: 100%;

    margin: 0;
    padding: 0;
    overflow: hidden;

    background: var(--ctz-gallery-background, #ffffff);
    border: 1px solid var(--ctz-gallery-border, #dce6f0);
    border-radius: var(--ctz-gallery-radius, 10px);

    box-shadow: 0 4px 18px rgba(11, 32, 56, 0.05);

    transition:
        border-color 180ms ease,
        box-shadow 180ms ease;
}

.ctz-gallery-card:hover {
    border-color: #9cb9d4;
    box-shadow: 0 8px 25px rgba(11, 32, 56, 0.1);
}

.ctz-gallery-card--image-only {
    align-self: start;
    height: auto;
}

.ctz-gallery-card::before,
.ctz-gallery-card::after {
    display: none;
    content: none;
}

.ctz-gallery-album-viewer
.ctz-gallery-album-photo,
.ctz-gallery-album-dialog
.ctz-gallery-album-photo {
    height: auto;
    padding: 6px;
    background: #ffffff;
    border-radius: 9px;
}


/* ==========================================
   26. PHOTO MEDIA
========================================== */

.ctz-gallery-card-media {
    position: relative;
    display: block;
    flex-shrink: 0;

    width: 100%;
    min-width: 0;

    aspect-ratio: var(--ctz-gallery-image-ratio, 4 / 3);

    margin: 0;
    padding: 0;
    overflow: hidden;

    background: var(--ctz-gallery-surface, #f0f5fa);
}

.ctz-gallery-album-photo
.ctz-gallery-card-media {
    border-radius: 5px;
}

.ctz-gallery-card-media > .ctz-gallery-image,
.ctz-gallery-image-link > .ctz-gallery-image {
    display: block;

    width: 100%;
    height: 100%;
    max-width: 100%;

    margin: 0;

    object-fit: var(--ctz-gallery-image-fit, cover);
    object-position: center;

    transition: transform 300ms ease;
}

.ctz-gallery-album-viewer
.ctz-gallery-card-media,
.ctz-gallery-album-dialog
.ctz-gallery-card-media {
    background: #ffffff;
}

.ctz-gallery-album-viewer
.ctz-gallery-image,
.ctz-gallery-album-dialog
.ctz-gallery-image {
    object-fit: contain;
}


/* ==========================================
   27. CLICKABLE PHOTO
========================================== */

.ctz-gallery-image-link {
    position: relative;
    display: block;

    width: 100%;
    height: 100%;

    overflow: hidden;

    color: inherit;
    text-decoration: none;
    cursor: zoom-in;
}

.ctz-gallery-image-link:focus-visible {
    outline: 3px solid #176bba;
    outline-offset: -4px;
}

@media (hover: hover) and (pointer: fine) {

    .ctz-gallery-fit-cover
    .ctz-gallery-image-link:hover
    .ctz-gallery-image {
        transform: scale(1.035);
    }

    .ctz-gallery-album-viewer
    .ctz-gallery-image-link:hover
    .ctz-gallery-image,
    .ctz-gallery-album-dialog
    .ctz-gallery-image-link:hover
    .ctz-gallery-image {
        transform: none;
    }

}


/* ==========================================
   28. PHOTO EXPAND OVERLAY
========================================== */

.ctz-gallery-image-overlay {
    position: absolute;
    inset: 0;

    display: flex;
    align-items: center;
    justify-content: center;

    background: rgba(11, 32, 56, 0.22);

    opacity: 0;
    pointer-events: none;

    transition: opacity 200ms ease;
}

.ctz-gallery-image-link:hover
.ctz-gallery-image-overlay,
.ctz-gallery-image-link:focus-visible
.ctz-gallery-image-overlay {
    opacity: 1;
}

.ctz-gallery-expand-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    width: 42px;
    height: 42px;

    background: #ffffff;
    border: 1px solid #e8ce9f;
    border-radius: 8px;

    color: #0b2038;
}

.ctz-gallery-expand-icon svg {
    width: 20px;
    height: 20px;
}


/* ==========================================
   29. PHOTO CAPTIONS
========================================== */

.ctz-gallery-card-content {
    display: flex;
    flex: 1;
    flex-direction: column;
    align-items: flex-start;

    min-width: 0;
    margin: 0;
    padding: 13px 15px;

    background: transparent;
    text-align: start;
}

.ctz-gallery-image-title {
    margin: 0;

    color: var(--ctz-gallery-heading, #102c46);
    font-size: 14px;
    font-weight: 600;
    line-height: 1.5;

    overflow-wrap: anywhere;
}

.ctz-gallery-image-description {
    width: 100%;
    margin: 0;

    color: var(--ctz-gallery-muted, #64748b);
    font-size: 13px;
    line-height: 1.7;

    overflow-wrap: anywhere;
}

.ctz-gallery-image-title
+ .ctz-gallery-image-description {
    margin-top: 8px;
}

.ctz-gallery-image-description p {
    margin: 0 0 10px;
}

.ctz-gallery-image-description > :last-child {
    margin-bottom: 0;
}

.ctz-gallery-album-viewer
.ctz-gallery-card-content,
.ctz-gallery-album-dialog
.ctz-gallery-card-content {
    padding: 10px;
}


/* ==========================================
   30. GROUPED GALLERY COMPATIBILITY
========================================== */

.ctz-gallery-groups {
    display: flex;
    flex-direction: column;
    gap: 28px;
    width: 100%;
}

.ctz-gallery-group {
    width: 100%;
    min-width: 0;
}

.ctz-gallery-group-heading {
    margin-bottom: 16px;
    padding: 10px 14px;

    background: #f0f5fa;
    border-inline-start: 3px solid #c6a46c;
}

.ctz-gallery-page .ctz-gallery-group-title {
    margin: 0;
    color: #102c46;
    font-size: 15px;
    font-weight: 600;
    line-height: 1.5;
}


/* ==========================================
   31. PAGINATION
========================================== */

.ctz-gallery-page .ctz-gallery-pagination {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 100%;
    margin: 0;
    padding: 0 20px 30px;
}

.ctz-gallery-pagination ul.page-numbers {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;

    gap: 8px;
    margin: 0;
    padding: 0;

    list-style: none;
}

.ctz-gallery-pagination ul.page-numbers li {
    margin: 0;
    padding: 0;
    list-style: none;
}

.ctz-gallery-pagination a.page-numbers,
.ctz-gallery-pagination span.page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-width: 40px;
    min-height: 40px;
    padding: 8px 12px;

    background: #ffffff;
    border: 1px solid #dce6f0;
    border-radius: 6px;

    color: #102c46;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.5;

    text-decoration: none;
}

.ctz-gallery-pagination a.page-numbers:hover,
.ctz-gallery-pagination span.page-numbers.current {
    background: #0b2038;
    border-color: #0b2038;
    color: #ffffff;
}

.ctz-gallery-pagination span.page-numbers.dots {
    min-width: 24px;
    padding-inline: 4px;
    border: 0;
}


/* ==========================================
   32. EMPTY GALLERY
========================================== */

.ctz-gallery-page .ctz-gallery-empty-section {
    padding-block: clamp(30px, 5vw, 60px);
}

.ctz-gallery-empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    gap: 16px;

    width: 100%;
    min-height: 180px;
    padding: 28px;

    background: #f0f5fa;
    border: 1px dashed #b8c9d9;
    border-radius: 12px;

    text-align: center;
}

.ctz-gallery-empty-state svg {
    width: 40px;
    height: 40px;
    color: #176bba;
}

.ctz-gallery-empty-state p {
    margin: 0;
    color: #64748b;
    font-size: 14px;
    line-height: 1.7;
}


/* ==========================================
   33. FULLSCREEN PHOTO LIGHTBOX
========================================== */

.ctz-gallery-lightbox {
    position: fixed !important;
    inset: 0 !important;

    box-sizing: border-box;

    width: 100% !important;
    height: 100vh !important;
    height: 100dvh !important;

    max-width: none !important;
    max-height: none !important;

    margin: 0 !important;
    padding: 0 !important;

    overflow: hidden;

    background: #070d15;
    border: 0;
    border-radius: 0;

    color: #ffffff;

    overscroll-behavior: contain;
    z-index: 99999;
}

.ctz-gallery-lightbox:not([open]) {
    display: none !important;
}

.ctz-gallery-lightbox[open] {
    display: block !important;
}

.ctz-gallery-lightbox::backdrop {
    background: #070d15;
}


/* ==========================================
   34. PAGE SCROLL MANAGEMENT
========================================== */

body.ctz-lightbox-open,
body.ctz-gallery-scroll-locked {
    overflow: hidden !important;
}

body.ctz-album-view-active:not(.ctz-lightbox-open):not(.ctz-gallery-scroll-locked) {
    overscroll-behavior: auto;
}


/* ==========================================
   35. FULLSCREEN IMAGE CONTAINER
========================================== */

.ctz-lightbox-container {
    position: relative;

    display: flex;
    flex-direction: column;
    align-items: center;

    gap: 0;

    box-sizing: border-box;

    width: 100%;
    height: 100%;
    min-height: 0;
    min-width: 0;

    padding: 0;
    overflow: hidden;
}


/* ==========================================
   36. MAXIMUM AVAILABLE IMAGE AREA
========================================== */

.ctz-lightbox-image-area {
    position: relative;

    display: flex;
    flex: 1 1 0%;
    align-items: center;
    justify-content: center;

    box-sizing: border-box;

    width: 100%;
    height: auto;
    min-width: 0;
    min-height: 0;

    padding: 8px 54px;

    overflow: hidden;
    touch-action: pan-y pinch-zoom;
}


/* ==========================================
   37. RESPONSIVE FULLSCREEN IMAGE
========================================== */

.ctz-lightbox-image {
    display: block;

    width: 100% !important;
    height: 100% !important;

    max-width: 100% !important;
    max-height: 100% !important;

    min-width: 0;
    min-height: 0;

    margin: 0 !important;
    padding: 0;

    background: transparent;

    object-fit: contain !important;
    object-position: center;

    border: 0;
    border-radius: 0;
}

.ctz-lightbox-image:not([src]),
.ctz-lightbox-image[src=""] {
    visibility: hidden;
}


/* ==========================================
   38. FULLSCREEN CONTROLS
========================================== */

.ctz-lightbox-close,
.ctz-lightbox-prev,
.ctz-lightbox-next {
    position: absolute;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    width: 44px;
    height: 44px;
    min-width: 44px;
    min-height: 44px;

    margin: 0;
    padding: 0;

    background: rgba(7, 13, 21, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.4);
    border-radius: 50%;

    color: #ffffff;
    cursor: pointer;

    z-index: 10;

    transition:
        background-color 180ms ease,
        border-color 180ms ease;
}

.ctz-lightbox-close:hover,
.ctz-lightbox-prev:hover,
.ctz-lightbox-next:hover {
    background: #176bba;
    border-color: #ffffff;
}

.ctz-lightbox-close svg,
.ctz-lightbox-prev svg,
.ctz-lightbox-next svg {
    display: block;
    flex-shrink: 0;
    width: 23px;
    height: 23px;
}

.ctz-lightbox-prev:disabled,
.ctz-lightbox-next:disabled {
    opacity: 0.35;
    cursor: not-allowed;
}

.ctz-lightbox-close {
    top: max(12px, env(safe-area-inset-top));
    inset-inline-end: 14px;
}

.ctz-lightbox-prev,
.ctz-lightbox-next {
    top: 50%;
    transform: translateY(-50%);
}

.ctz-lightbox-prev {
    inset-inline-start: 8px;
}

.ctz-lightbox-next {
    inset-inline-end: 8px;
}


/* ==========================================
   39. FULLSCREEN CAPTION
========================================== */

.ctz-lightbox-caption {
    position: relative;

    display: flex;
    flex: 0 0 auto;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;

    gap: 6px 14px;

    box-sizing: border-box;

    width: 100%;
    max-width: none;
    max-height: 25vh;
    max-height: 25dvh;

    margin: 0;
    padding: 8px 16px;
    padding-bottom: max(8px, env(safe-area-inset-bottom));

    overflow-x: hidden;
    overflow-y: auto;

    overscroll-behavior: contain;

    background: #0b1624;
    border-top: 1px solid rgba(255, 255, 255, 0.12);

    text-align: center;
}

.ctz-lightbox-title {
    flex-basis: 100%;
    margin: 0;

    color: #ffffff;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.4;

    overflow-wrap: anywhere;
}

.ctz-lightbox-description {
    flex-basis: 100%;
    max-width: 1100px;
    margin: 0;

    color: #cbd5e1;
    font-size: 12px;
    line-height: 1.5;

    white-space: pre-line;
    overflow-wrap: anywhere;
}

.ctz-lightbox-counter {
    display: inline-block;
    margin: 0;

    color: #e8ce9f;
    font-size: 12px;
    font-weight: 500;
    line-height: 1.5;
}

.ctz-lightbox-counter:empty {
    display: none;
}


/* ==========================================
   40. FULLSCREEN SLIDESHOW CONTROL
========================================== */

.ctz-gallery-lightbox
.ctz-lightbox-play-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    gap: 9px;
    min-height: 36px;

    margin: 0;
    padding: 7px 12px;

    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 6px;

    color: #ffffff;
    font-family: inherit;
    font-size: 12px;
    font-weight: 600;
    line-height: 1.4;

    cursor: pointer;
}

.ctz-gallery-lightbox
.ctz-lightbox-play-toggle:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: #e8ce9f;
}

.ctz-lightbox-play-toggle::before {
    display: block;
    width: 9px;
    height: 12px;
    border-inline: 3px solid currentColor;
    content: "";
}

.ctz-lightbox-play-toggle[aria-pressed="true"]::before {
    width: 0;
    height: 0;
    border: 0;
    border-top: 6px solid transparent;
    border-bottom: 6px solid transparent;
    border-inline-start: 10px solid currentColor;
}


/* ==========================================
   41. PASSWORD PROTECTED GALLERY
========================================== */

.ctz-gallery-page .ctz-gallery-protected {
    padding-block: 40px;
}

.ctz-gallery-protected .ctz-content {
    max-width: 760px;
    margin-inline: auto;
}

.ctz-gallery-protected .post-password-form {
    padding: clamp(20px, 3vw, 32px);
    background: #f0f5fa;
    border: 1px solid #dce6f0;
    border-radius: 12px;
}

.ctz-gallery-protected input[type="password"] {
    width: 100%;
    max-width: 360px;
    min-height: 46px;
    padding: 10px 14px;

    background: #ffffff;
    border: 1px solid #b8c9d9;
    border-radius: 6px;

    color: #334155;
    font: inherit;
}

.ctz-gallery-protected input[type="submit"] {
    min-height: 46px;
    margin-top: 10px;
    padding: 10px 24px;

    background: #0b2038;
    border: 1px solid #0b2038;
    border-radius: 6px;

    color: #ffffff;
    font: inherit;
    cursor: pointer;
}


/* ==========================================
   42. KEYBOARD ACCESSIBILITY
========================================== */

.ctz-gallery-page a:focus-visible,
.ctz-gallery-page button:focus-visible,
.ctz-gallery-page input:focus-visible,
.ctz-gallery-album-dialog-content:focus-visible {
    outline: 2px solid #176bba;
    outline-offset: 3px;
}

.ctz-gallery-page
.ctz-gallery-image-link:focus-visible {
    outline-offset: -4px;
}

.ctz-gallery-lightbox button:focus-visible,
.ctz-gallery-page
.ctz-gallery-album-dialog-close:focus-visible {
    outline: 2px solid #ffffff;
    outline-offset: 4px;
}


/* ==========================================
   43. LARGE DESKTOP
========================================== */

@media (min-width: 1800px) {

    .ctz-gallery-album-viewer
    .ctz-gallery-grid,
    .ctz-gallery-album-dialog
    .ctz-gallery-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

}


/* ==========================================
   44. TABLET RESPONSIVE
========================================== */

@media (max-width: 1100px) {

    .ctz-gallery-page {
        --ctz-gallery-gap: 20px;
    }

    .ctz-gallery-album-grid.ctz-gallery-album-columns-4 {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

}

@media (max-width: 900px) {

    .ctz-gallery-page {
        --ctz-gallery-gap: 18px;
        --ctz-gallery-header-offset: 80px;
    }

    .ctz-gallery-album-grid,
    .ctz-gallery-album-grid.ctz-gallery-album-columns-2,
    .ctz-gallery-album-grid.ctz-gallery-album-columns-3,
    .ctz-gallery-album-grid.ctz-gallery-album-columns-4,
    .ctz-gallery-grid,
    .ctz-gallery-grid.ctz-gallery-columns-2,
    .ctz-gallery-grid.ctz-gallery-columns-3,
    .ctz-gallery-grid.ctz-gallery-columns-4,
    .ctz-gallery-album-viewer .ctz-gallery-grid,
    .ctz-gallery-album-dialog .ctz-gallery-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

}


/* ==========================================
   45. TOUCH SCREEN CONTROLS
========================================== */

@media (hover: none) {

    .ctz-gallery-image-overlay {
        align-items: flex-end;
        justify-content: flex-end;
        padding: 8px;
        background: transparent;
        opacity: 1;
    }

    .ctz-gallery-expand-icon {
        width: 32px;
        height: 32px;
        background: rgba(255, 255, 255, 0.94);
    }

    .ctz-gallery-expand-icon svg {
        width: 17px;
        height: 17px;
    }

}


/* ==========================================
   46. MOBILE RESPONSIVE
========================================== */

@media (max-width: 600px) {

    .ctz-gallery-page {
        --ctz-gallery-gap: 12px;
        --ctz-gallery-header-offset: 70px;
    }

    .ctz-gallery-page
    .ctz-gallery-intro-section {
        padding-top: 20px;
    }

    .ctz-gallery-page
    .ctz-gallery-listing-section,
    .ctz-gallery-page
    .ctz-gallery-listing-section--first {
        padding-top: 18px;
        padding-bottom: 28px;
    }

    .ctz-gallery-album-grid,
    .ctz-gallery-album-grid.ctz-gallery-album-columns-2,
    .ctz-gallery-album-grid.ctz-gallery-album-columns-3,
    .ctz-gallery-album-grid.ctz-gallery-album-columns-4 {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 12px;
    }

    .ctz-gallery-album-card {
        border-radius: 8px;
    }

    .ctz-gallery-album-trigger {
        border-radius: 7px;
    }

    .ctz-gallery-album-media {
        border-radius: 7px 7px 0 0;
    }

    .ctz-gallery-album-content {
        gap: 8px;
        padding: 11px 10px 10px;
    }

    .ctz-gallery-album-content::before {
        inset-inline-start: 10px;
        width: 24px;
        height: 2px;
    }

    .ctz-gallery-page
    .ctz-gallery-album-title-row {
        gap: 6px;
    }

    .ctz-gallery-page
    .ctz-gallery-album-title-row
    .ctz-gallery-album-title {
        flex-basis: 100% !important;
        font-size: 12px !important;
        line-height: 1.5 !important;
    }

    .ctz-gallery-page
    .ctz-gallery-album-title-row
    .ctz-gallery-album-count {
        min-height: 22px !important;
        padding: 3px 6px !important;
        font-size: 10px !important;
    }

    .ctz-gallery-album-count svg {
        width: 12px;
        height: 12px;
    }

    .ctz-gallery-album-action {
        padding-top: 8px;
        font-size: 10px;
    }

    .ctz-gallery-album-action svg {
        width: 14px;
        height: 14px;
    }

    .ctz-gallery-album-panel {
        padding: 12px;
    }

    .ctz-gallery-page
    .ctz-gallery-album-viewer {
        border-radius: 0;
    }

    .ctz-gallery-album-dialog-header {
        flex-wrap: wrap;
        gap: 8px;
        min-height: 60px;
        padding: 10px 12px;
    }

    .ctz-gallery-album-dialog-heading {
        flex-basis: 100%;
    }

    .ctz-gallery-page
    .ctz-gallery-album-dialog-title,
    .ctz-gallery-album-dialog-title {
        font-size: 14px !important;
    }

    .ctz-gallery-album-dialog-counter {
        font-size: 11px;
    }

    .ctz-gallery-page
    .ctz-gallery-album-dialog-close,
    .ctz-gallery-album-dialog-close {
        min-height: 36px;
        padding: 7px 12px;
        font-size: 11px;
    }

    .ctz-gallery-album-viewer
    .ctz-gallery-album-dialog-content,
    .ctz-gallery-album-dialog
    .ctz-gallery-album-dialog-content {
        padding: 12px;
        scrollbar-gutter: auto;
    }

    .ctz-gallery-grid,
    .ctz-gallery-grid.ctz-gallery-columns-2,
    .ctz-gallery-grid.ctz-gallery-columns-3,
    .ctz-gallery-grid.ctz-gallery-columns-4,
    .ctz-gallery-album-viewer .ctz-gallery-grid,
    .ctz-gallery-album-dialog .ctz-gallery-grid {
        grid-template-columns: minmax(0, 1fr);
        gap: 12px;
    }

    .ctz-gallery-album-viewer
    .ctz-gallery-album-photo,
    .ctz-gallery-album-dialog
    .ctz-gallery-album-photo {
        padding: 4px;
        border-radius: 7px;
    }

    .ctz-gallery-card-content {
        padding: 10px;
    }

    .ctz-gallery-image-title {
        font-size: 13px;
    }

    .ctz-gallery-image-description {
        font-size: 12px;
    }

    .ctz-gallery-pagination ul.page-numbers {
        gap: 6px;
    }

    .ctz-gallery-pagination a.page-numbers,
    .ctz-gallery-pagination span.page-numbers {
        min-width: 36px;
        min-height: 38px;
        padding: 7px 10px;
        font-size: 12px;
    }

    .ctz-lightbox-image-area {
        padding: 0;
    }

    .ctz-lightbox-close {
        top: max(8px, env(safe-area-inset-top));
        inset-inline-end: 8px;
    }

    .ctz-lightbox-prev {
        inset-inline-start: 5px;
    }

    .ctz-lightbox-next {
        inset-inline-end: 5px;
    }

    .ctz-lightbox-prev,
    .ctz-lightbox-next {
        background: rgba(0, 0, 0, 0.65);
    }

    .ctz-lightbox-prev svg,
    .ctz-lightbox-next svg {
        width: 20px;
        height: 20px;
    }

    .ctz-lightbox-caption {
        padding-inline: 10px;
    }

    .ctz-lightbox-title {
        font-size: 13px;
    }

    .ctz-lightbox-description {
        font-size: 12px;
    }

    .ctz-gallery-lightbox
    .ctz-lightbox-play-toggle {
        min-height: 44px;
        font-size: 12px;
    }

}


/* ==========================================
   47. SMALL MOBILE DEVICES
========================================== */

@media (max-width: 360px) {

    .ctz-gallery-album-grid,
    .ctz-gallery-album-grid.ctz-gallery-album-columns-2,
    .ctz-gallery-album-grid.ctz-gallery-album-columns-3,
    .ctz-gallery-album-grid.ctz-gallery-album-columns-4 {
        grid-template-columns: minmax(0, 1fr);
    }

    .ctz-gallery-page
    .ctz-gallery-album-title-row
    .ctz-gallery-album-title {
        font-size: 13px !important;
    }

}


/* ==========================================
   48. LANDSCAPE MOBILE
========================================== */

@media (max-height: 500px) and (orientation: landscape) {

    .ctz-gallery-page
    .ctz-gallery-album-viewer {
        min-height: 160px;
    }

    .ctz-gallery-album-dialog-header {
        min-height: 48px;
        padding-block: 6px;
    }

    .ctz-lightbox-caption {
        max-height: 30vh;
        max-height: 30dvh;
        padding-block: 4px;
    }

    .ctz-lightbox-image-area {
        padding-block: 0;
    }

}


/* ==========================================
   49. RIGHT TO LEFT SUPPORT
========================================== */

[dir="rtl"] .ctz-lightbox-prev svg,
[dir="rtl"] .ctz-lightbox-next svg,
[dir="rtl"] .ctz-gallery-album-action svg {
    transform: scaleX(-1);
}

[dir="rtl"] .ctz-gallery-album-progress-bar,
[dir="rtl"] [data-ctz-album-progress] {
    transform-origin: right center;
}

[dir="rtl"]
.ctz-gallery-album-trigger:hover
.ctz-gallery-album-action svg {
    transform: translateX(-3px) scaleX(-1);
}


/* ==========================================
   50. REDUCED MOTION
========================================== */

@media (prefers-reduced-motion: reduce) {

    .ctz-gallery-page *,
    .ctz-gallery-page *::before,
    .ctz-gallery-page *::after,
    .ctz-gallery-lightbox *,
    .ctz-gallery-lightbox *::before,
    .ctz-gallery-lightbox *::after {
        animation: none !important;
        transition: none !important;
        scroll-behavior: auto !important;
    }

    .ctz-gallery-album-progress {
        display: none;
    }

    .ctz-gallery-image-link:hover
    .ctz-gallery-image {
        transform: none;
    }

}


/* ==========================================
   51. HIGH CONTRAST ACCESSIBILITY
========================================== */

@media (forced-colors: active) {

    .ctz-gallery-card,
    .ctz-gallery-album-card,
    .ctz-gallery-album-count,
    .ctz-gallery-album-viewer,
    .ctz-gallery-expand-icon,
    .ctz-gallery-album-overlay-icon,
    .ctz-gallery-album-dialog-close,
    .ctz-lightbox-close,
    .ctz-lightbox-prev,
    .ctz-lightbox-next,
    .ctz-lightbox-play-toggle {
        border: 1px solid ButtonText;
    }

    .ctz-gallery-page a:focus-visible,
    .ctz-gallery-page button:focus-visible,
    .ctz-gallery-album-trigger:focus-visible,
    .ctz-gallery-lightbox button:focus-visible {
        outline: 2px solid Highlight;
    }

}


/* ==========================================
   52. PRINT SUPPORT
========================================== */

@media print {

    .ctz-gallery-page {
        background: #ffffff;
        color: #000000;
    }

    .ctz-gallery-page
    .ctz-gallery-listing-section {
        padding-block: 16px;
    }

    .ctz-gallery-album-grid,
    .ctz-gallery-album-grid.ctz-gallery-album-columns-2,
    .ctz-gallery-album-grid.ctz-gallery-album-columns-3,
    .ctz-gallery-album-grid.ctz-gallery-album-columns-4,
    .ctz-gallery-grid,
    .ctz-gallery-grid.ctz-gallery-columns-2,
    .ctz-gallery-grid.ctz-gallery-columns-3,
    .ctz-gallery-grid.ctz-gallery-columns-4,
    .ctz-gallery-album-viewer .ctz-gallery-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 16px;
    }

    .ctz-gallery-card,
    .ctz-gallery-album-card {
        break-inside: avoid;
        border: 1px solid #cccccc;
        box-shadow: none;
    }

    .ctz-gallery-page
    .ctz-gallery-album-viewer {
        height: auto !important;
        min-height: 0;
        overflow: visible;
        background: #ffffff;
        border: 0;
    }

    .ctz-gallery-album-viewer
    .ctz-gallery-album-dialog-content {
        flex: 0 0 auto;
        height: auto;
        overflow: visible !important;
    }

    .ctz-gallery-album-dialog-header,
    .ctz-gallery-album-dialog-content {
        background: #ffffff;
        color: #000000;
    }

    .ctz-gallery-page
    .ctz-gallery-album-dialog-title,
    .ctz-gallery-album-dialog-counter {
        color: #000000;
    }

    .ctz-gallery-card-media,
    .ctz-gallery-album-media {
        background: transparent;
    }

    .ctz-gallery-card-media .ctz-gallery-image,
    .ctz-gallery-album-image {
        object-fit: contain;
        transform: none;
    }

    .ctz-gallery-image-title,
    .ctz-gallery-image-description,
    .ctz-gallery-album-title,
    .ctz-gallery-album-count {
        color: #000000 !important;
    }

    .ctz-gallery-album-count {
        background: #ffffff !important;
        border-color: #cccccc !important;
    }

    .ctz-gallery-image-overlay,
    .ctz-gallery-album-overlay,
    .ctz-gallery-album-progress,
    .ctz-gallery-album-action,
    .ctz-gallery-slideshow-toolbar,
    .ctz-gallery-pagination,
    .ctz-gallery-album-dialog-close,
    .ctz-gallery-album-dialog,
    .ctz-gallery-lightbox {
        display: none !important;
    }

}


/* ==========================================
   END OF COMTECHZONE GALLERY CSS
========================================== */
