/*
 * DOM-BUD frontend preset.
 * Every selector is scoped to the shortcode wrapper to avoid theme-wide effects.
 */
.mkfg-gallery.dombud-gallery,
.mkfg-gallery.dombud-gallery * {
    box-sizing: border-box;
}

.mkfg-gallery.dombud-gallery {
    --db-dark: #1d2021;
    --db-dark-deep: #151718;
    --db-gold: #ba8b3d;
    --db-gold-dark: #a47a36;
    --db-white: #ffffff;
    --db-bg: #f7f7f5;
    --db-muted: #6f7172;
    --db-border: #e6e4df;
    width: 100%;
    max-width: var(--mkfg-max-width, 1600px);
    min-width: 0;
    margin-top: 0;
    margin-bottom: 0;
    padding-inline: clamp(32px, 6vw, 110px);
    background: transparent;
    color: var(--db-dark);
    font-family: "Inter", Arial, sans-serif;
    font-weight: 400;
}

.mkfg-gallery.dombud-gallery.mkfg-gallery--centered {
    margin-left: auto;
    margin-right: auto;
}

.mkfg-gallery.dombud-gallery .mkfg-filters {
    display: flex;
    flex-wrap: wrap;
    align-items: stretch;
    justify-content: var(--mkfg-filter-alignment, center);
    width: 100%;
    max-width: 100%;
    min-width: 0;
    margin: 0 0 clamp(22px, 3vw, 38px);
    padding: 0;
    gap: var(--mkfg-filter-gap, 8px);
}

/* Explicit states prevent Hello Elementor from injecting its red button theme. */
.mkfg-gallery.dombud-gallery .mkfg-filter,
.mkfg-gallery.dombud-gallery .mkfg-filter:visited {
    display: inline-flex;
    flex: 0 1 auto;
    align-items: center;
    justify-content: center;
    min-width: 0;
    min-height: 42px;
    max-width: 100%;
    margin: 0;
    padding: var(--mkfg-filter-padding-y, 0) var(--mkfg-filter-padding-x, 17px);
    overflow: visible;
    border: var(--mkfg-filter-border-width, 1px) solid var(--mkfg-filter-border, #dad8d2) !important;
    border-radius: var(--mkfg-filter-radius, 0) !important;
    background: var(--mkfg-filter-background, transparent) !important;
    background-color: var(--mkfg-filter-background, transparent) !important;
    box-shadow: none !important;
    color: var(--mkfg-filter-text, var(--db-dark)) !important;
    font-family: "Inter", Arial, sans-serif;
    font-size: var(--mkfg-filter-font-size, 10px);
    font-weight: var(--mkfg-filter-font-weight, 700);
    line-height: 1.2;
    letter-spacing: 0.08em;
    text-align: center;
    text-decoration: none !important;
    text-transform: uppercase;
    overflow-wrap: anywhere;
    white-space: normal;
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    transition: color 180ms ease, background-color 180ms ease, border-color 180ms ease;
}

.mkfg-gallery.dombud-gallery .mkfg-filter:hover,
.mkfg-gallery.dombud-gallery .mkfg-filter:focus,
.mkfg-gallery.dombud-gallery .mkfg-filter:active {
    border-color: var(--mkfg-filter-hover-background, var(--db-dark)) !important;
    border-radius: var(--mkfg-filter-radius, 0) !important;
    background: var(--mkfg-filter-hover-background, var(--db-dark)) !important;
    background-color: var(--mkfg-filter-hover-background, var(--db-dark)) !important;
    box-shadow: none !important;
    color: var(--mkfg-filter-hover-text, var(--db-white)) !important;
    text-decoration: none !important;
}

.mkfg-gallery.dombud-gallery .mkfg-filter.is-active,
.mkfg-gallery.dombud-gallery .mkfg-filter.is-active:hover,
.mkfg-gallery.dombud-gallery .mkfg-filter.is-active:focus,
.mkfg-gallery.dombud-gallery .mkfg-filter.is-active:active,
.mkfg-gallery.dombud-gallery .mkfg-filter[aria-pressed="true"],
.mkfg-gallery.dombud-gallery .mkfg-filter[aria-pressed="true"]:hover,
.mkfg-gallery.dombud-gallery .mkfg-filter[aria-pressed="true"]:focus,
.mkfg-gallery.dombud-gallery .mkfg-filter[aria-pressed="true"]:active {
    border-color: var(--mkfg-filter-active-background, var(--db-dark)) !important;
    border-bottom-color: var(--db-gold) !important;
    border-bottom-width: 2px !important;
    border-radius: var(--mkfg-filter-radius, 0) !important;
    background: var(--mkfg-filter-active-background, var(--db-dark)) !important;
    background-color: var(--mkfg-filter-active-background, var(--db-dark)) !important;
    box-shadow: none !important;
    color: var(--mkfg-filter-active-text, var(--db-white)) !important;
    text-decoration: none !important;
}

.mkfg-gallery.dombud-gallery .mkfg-filter:focus,
.mkfg-gallery.dombud-gallery .mkfg-lightbox-trigger:focus,
.mkfg-gallery.dombud-gallery .mkfg-lightbox button:focus {
    outline: 0;
}

.mkfg-gallery.dombud-gallery .mkfg-filter:focus-visible,
.mkfg-gallery.dombud-gallery .mkfg-lightbox-trigger:focus-visible,
.mkfg-gallery.dombud-gallery .mkfg-lightbox button:focus-visible {
    outline: 2px solid var(--db-gold) !important;
    outline-offset: 2px;
}

.mkfg-gallery.dombud-gallery .mkfg-lightbox-trigger:focus-visible {
    outline-offset: -4px;
}

.mkfg-gallery.dombud-gallery .mkfg-grid {
    display: grid;
    align-content: start;
    grid-template-columns: repeat(var(--mkfg-columns-desktop, 3), minmax(0, 1fr));
    width: 100%;
    max-width: 100%;
    min-width: 0;
    margin: 0;
    padding: 0;
    gap: var(--mkfg-gap-desktop, clamp(12px, 1.4vw, 22px));
}

.mkfg-gallery.dombud-gallery[data-layout="masonry"] .mkfg-grid {
    display: block;
    column-count: var(--mkfg-columns-desktop, 3);
    column-gap: var(--mkfg-gap-desktop, clamp(12px, 1.4vw, 22px));
}

.mkfg-gallery.dombud-gallery .mkfg-item {
    position: relative;
    width: 100%;
    max-width: 100%;
    min-width: 0;
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    opacity: 1;
    transform: translateY(0);
    transition: opacity 180ms ease, transform 220ms cubic-bezier(.22, 1, .36, 1);
}

.mkfg-gallery.dombud-gallery[data-layout="masonry"] .mkfg-item {
    display: inline-block;
    width: 100%;
    margin: 0 0 var(--mkfg-gap-desktop, clamp(12px, 1.4vw, 22px));
    break-inside: avoid;
    vertical-align: top;
}

.mkfg-gallery.dombud-gallery .mkfg-item.is-hiding {
    opacity: 0;
    transform: translateY(5px);
    pointer-events: none;
}

.mkfg-gallery.dombud-gallery .mkfg-item.is-filter-leaving {
    transition-duration: 90ms, 90ms;
}

.mkfg-gallery.dombud-gallery .mkfg-item[hidden] {
    display: none;
}

.mkfg-gallery.dombud-gallery .mkfg-media {
    position: relative;
    width: 100%;
    max-width: 100%;
    min-width: 0;
    margin: 0;
    overflow: hidden;
    border: 0;
    border-radius: var(--mkfg-image-radius, 0);
    background: var(--db-bg);
    box-shadow: none;
}

.mkfg-gallery.dombud-gallery[data-layout="grid"] .mkfg-media {
    min-height: 0;
    aspect-ratio: var(--mkfg-aspect-ratio, 4 / 3);
}

.mkfg-gallery.dombud-gallery .mkfg-media::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 1;
    border-radius: inherit;
    background: var(--mkfg-hover-overlay, rgba(21, 23, 24, 0.18));
    opacity: 0;
    pointer-events: none;
    transition: opacity 300ms ease;
}

.mkfg-gallery.dombud-gallery .mkfg-media:hover::after {
    opacity: 1;
}

.mkfg-gallery.dombud-gallery .mkfg-lightbox-trigger,
.mkfg-gallery.dombud-gallery .mkfg-lightbox-trigger:visited,
.mkfg-gallery.dombud-gallery .mkfg-lightbox-trigger:hover,
.mkfg-gallery.dombud-gallery .mkfg-lightbox-trigger:focus,
.mkfg-gallery.dombud-gallery .mkfg-lightbox-trigger:active {
    position: relative;
    z-index: 0;
    display: block;
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    border: 0 !important;
    border-radius: inherit !important;
    background: transparent !important;
    background-color: transparent !important;
    box-shadow: none !important;
    color: inherit !important;
    text-decoration: none !important;
}

.mkfg-gallery.dombud-gallery .mkfg-lightbox-trigger:focus-visible {
    z-index: 3;
}

.mkfg-gallery.dombud-gallery .mkfg-image {
    display: block;
    width: 100%;
    max-width: 100%;
    height: auto;
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: inherit;
    box-shadow: none;
    opacity: 1;
    transform: scale(1);
    transform-origin: center;
    transition: transform 300ms ease, opacity 220ms ease;
}

.mkfg-gallery.dombud-gallery[data-layout="grid"] .mkfg-media .mkfg-image {
    height: 100%;
    object-fit: var(--mkfg-object-fit, cover);
}

.mkfg-gallery.dombud-gallery[data-layout="masonry"] .mkfg-image {
    height: auto;
    object-fit: initial;
}

.mkfg-gallery.dombud-gallery .mkfg-media:hover .mkfg-image {
    opacity: var(--mkfg-hover-opacity, 1);
    transform: scale(var(--mkfg-hover-scale, 1.015));
}

.mkfg-gallery.dombud-gallery .mkfg-caption {
    max-width: 100%;
    margin: 0;
    color: var(--db-dark);
    font-family: "Inter", Arial, sans-serif;
    font-size: 13px;
    font-weight: 500;
    line-height: 1.5;
    overflow-wrap: anywhere;
}

.mkfg-gallery.dombud-gallery .mkfg-caption--below {
    padding: 10px 0 0;
    color: var(--db-muted);
}

.mkfg-gallery.dombud-gallery .mkfg-caption--overlay {
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 2;
    padding: 14px 16px;
    background: rgba(21, 23, 24, 0.78);
    color: var(--db-white);
    opacity: 0;
    transform: translateY(5px);
    transition: opacity 220ms ease, transform 220ms ease;
    pointer-events: none;
}

.mkfg-gallery.dombud-gallery .mkfg-media:hover .mkfg-caption--overlay,
.mkfg-gallery.dombud-gallery .mkfg-lightbox-trigger:focus-visible + .mkfg-caption--overlay {
    opacity: 1;
    transform: translateY(0);
}

.mkfg-gallery.dombud-gallery .mkfg-lightbox[hidden] {
    display: none;
}

.mkfg-gallery.dombud-gallery .mkfg-lightbox {
    position: fixed;
    inset: 0;
    z-index: 999999;
    display: grid;
    grid-template-columns: minmax(52px, 7vw) minmax(0, 1fr) minmax(52px, 7vw);
    align-items: center;
    width: 100vw;
    max-width: none;
    height: 100vh;
    height: 100dvh;
    margin: 0;
    padding: clamp(52px, 7vh, 84px) 0 clamp(24px, 4vh, 48px);
    overflow: hidden;
    border: 0;
    border-radius: 0;
    background: rgba(15, 16, 17, 0.94);
    color: var(--db-white);
    font-family: "Inter", Arial, sans-serif;
    box-shadow: none;
}

.mkfg-gallery.dombud-gallery .mkfg-lightbox-content {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    width: 100%;
    min-width: 0;
    max-height: calc(100vh - 100px);
    max-height: calc(100dvh - 100px);
}

.mkfg-gallery.dombud-gallery .mkfg-lightbox-image {
    display: block;
    width: auto;
    max-width: 100%;
    height: auto;
    max-height: calc(100vh - 148px);
    max-height: calc(100dvh - 148px);
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    object-fit: contain;
}

.mkfg-gallery.dombud-gallery .mkfg-lightbox-caption {
    max-width: min(800px, 100%);
    margin: 14px 0 0;
    padding: 0 16px;
    color: var(--db-white);
    font-family: "Inter", Arial, sans-serif;
    font-size: 13px;
    font-weight: 500;
    line-height: 1.5;
    text-align: center;
    overflow-wrap: anywhere;
}

.mkfg-gallery.dombud-gallery .mkfg-lightbox button,
.mkfg-gallery.dombud-gallery .mkfg-lightbox button:hover,
.mkfg-gallery.dombud-gallery .mkfg-lightbox button:focus,
.mkfg-gallery.dombud-gallery .mkfg-lightbox button:active {
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    background-color: transparent !important;
    box-shadow: none !important;
    color: var(--db-white) !important;
    font-family: "Inter", Arial, sans-serif;
    line-height: 1;
    text-decoration: none !important;
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    transition: color 180ms ease, opacity 180ms ease;
}

.mkfg-gallery.dombud-gallery .mkfg-lightbox button:hover,
.mkfg-gallery.dombud-gallery .mkfg-lightbox button:focus-visible,
.mkfg-gallery.dombud-gallery .mkfg-lightbox button:active {
    color: var(--db-gold) !important;
}

.mkfg-gallery.dombud-gallery .mkfg-lightbox-close {
    position: absolute;
    top: 16px;
    right: clamp(18px, 3vw, 42px);
    z-index: 2;
    width: 44px;
    height: 44px;
    padding: 0;
	font-size: 36px;
	font-weight: 400;
}

.mkfg-gallery.dombud-gallery .mkfg-lightbox-prev,
.mkfg-gallery.dombud-gallery .mkfg-lightbox-next {
    align-self: stretch;
    min-width: 52px;
    padding: 12px;
}

.mkfg-gallery.dombud-gallery .mkfg-lightbox-prev span,
.mkfg-gallery.dombud-gallery .mkfg-lightbox-next span {
    display: block;
    width: 18px;
    height: 18px;
    border-bottom: 1.5px solid currentColor;
    border-left: 1.5px solid currentColor;
}

.mkfg-gallery.dombud-gallery .mkfg-lightbox-prev span {
    transform: rotate(45deg);
}

.mkfg-gallery.dombud-gallery .mkfg-lightbox-next span {
    transform: rotate(225deg);
}

.mkfg-gallery.dombud-gallery .mkfg-visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    overflow: hidden;
    border: 0;
    clip: rect(0, 0, 0, 0);
    clip-path: inset(50%);
    white-space: nowrap;
}

@media (max-width: 1050px) {
    .mkfg-gallery.dombud-gallery .mkfg-grid {
        grid-template-columns: repeat(var(--mkfg-columns-tablet, 2), minmax(0, 1fr));
        gap: var(--mkfg-gap-tablet, 16px);
    }

    .mkfg-gallery.dombud-gallery[data-layout="masonry"] .mkfg-grid {
        column-count: var(--mkfg-columns-tablet, 2);
        column-gap: var(--mkfg-gap-tablet, 16px);
    }

    .mkfg-gallery.dombud-gallery[data-layout="masonry"] .mkfg-item {
        margin-bottom: var(--mkfg-gap-tablet, 16px);
    }
}

@media (max-width: 767px) {
    .mkfg-gallery.dombud-gallery {
        padding-inline: 24px;
    }

    .mkfg-gallery.dombud-gallery .mkfg-filters {
        justify-content: flex-start;
        margin-bottom: 22px;
    }

    .mkfg-gallery.dombud-gallery .mkfg-filters--scroll {
        flex-wrap: nowrap;
        justify-content: flex-start;
        padding-bottom: 6px;
        overflow-x: auto;
        overflow-y: hidden;
        overscroll-behavior-inline: contain;
        scrollbar-width: thin;
        -webkit-overflow-scrolling: touch;
    }

    .mkfg-gallery.dombud-gallery .mkfg-filters--scroll .mkfg-filter {
        flex: 0 0 auto;
        max-width: calc(100vw - 48px);
    }

    .mkfg-gallery.dombud-gallery .mkfg-grid {
        grid-template-columns: repeat(var(--mkfg-columns-mobile, 1), minmax(0, 1fr));
        gap: var(--mkfg-gap-mobile, 12px);
    }

    .mkfg-gallery.dombud-gallery[data-layout="masonry"] .mkfg-grid {
        column-count: var(--mkfg-columns-mobile, 1);
        column-gap: var(--mkfg-gap-mobile, 12px);
    }

    .mkfg-gallery.dombud-gallery[data-layout="masonry"] .mkfg-item {
        margin-bottom: var(--mkfg-gap-mobile, 12px);
    }

    .mkfg-gallery.dombud-gallery .mkfg-lightbox {
        grid-template-columns: 48px minmax(0, 1fr) 48px;
        padding: 58px 0 22px;
    }

    .mkfg-gallery.dombud-gallery .mkfg-lightbox-prev,
    .mkfg-gallery.dombud-gallery .mkfg-lightbox-next {
        min-width: 48px;
        padding: 10px;
    }

    .mkfg-gallery.dombud-gallery .mkfg-lightbox-prev span,
    .mkfg-gallery.dombud-gallery .mkfg-lightbox-next span {
        width: 15px;
        height: 15px;
    }

    .mkfg-gallery.dombud-gallery .mkfg-lightbox-image {
        max-height: calc(100dvh - 142px);
    }
}

@media (max-width: 480px) {
    .mkfg-gallery.dombud-gallery {
        padding-inline: 18px;
    }

    .mkfg-gallery.dombud-gallery .mkfg-filters {
        gap: 6px;
    }

    .mkfg-gallery.dombud-gallery .mkfg-filters:not(.mkfg-filters--scroll) .mkfg-filter {
        flex: 1 1 calc(50% - 3px);
        min-height: 44px;
        padding-inline: 12px;
    }

    .mkfg-gallery.dombud-gallery .mkfg-filters--scroll .mkfg-filter {
        max-width: calc(100vw - 36px);
    }

    .mkfg-gallery.dombud-gallery .mkfg-lightbox {
        grid-template-columns: 44px minmax(0, 1fr) 44px;
    }

    .mkfg-gallery.dombud-gallery .mkfg-lightbox-prev,
    .mkfg-gallery.dombud-gallery .mkfg-lightbox-next {
        min-width: 44px;
        padding: 8px;
    }

    .mkfg-gallery.dombud-gallery .mkfg-lightbox-close {
        top: 8px;
        right: 8px;
    }

    .mkfg-gallery.dombud-gallery .mkfg-lightbox-caption {
        padding-inline: 8px;
        font-size: 12px;
    }
}

@media (max-width: 370px) {
    .mkfg-gallery.dombud-gallery {
        padding-inline: 14px;
    }

    .mkfg-gallery.dombud-gallery .mkfg-filters:not(.mkfg-filters--scroll) .mkfg-filter {
        flex-basis: 100%;
        width: 100%;
    }

    .mkfg-gallery.dombud-gallery .mkfg-filters--scroll .mkfg-filter {
        max-width: calc(100vw - 28px);
    }

    .mkfg-gallery.dombud-gallery .mkfg-lightbox {
        grid-template-columns: 40px minmax(0, 1fr) 40px;
    }

    .mkfg-gallery.dombud-gallery .mkfg-lightbox-prev,
    .mkfg-gallery.dombud-gallery .mkfg-lightbox-next {
        min-width: 40px;
        padding: 7px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .mkfg-gallery.dombud-gallery .mkfg-item,
    .mkfg-gallery.dombud-gallery .mkfg-image,
    .mkfg-gallery.dombud-gallery .mkfg-filter,
    .mkfg-gallery.dombud-gallery .mkfg-caption--overlay,
    .mkfg-gallery.dombud-gallery .mkfg-media::after,
    .mkfg-gallery.dombud-gallery .mkfg-lightbox button {
        transition: none !important;
        animation: none !important;
    }

    .mkfg-gallery.dombud-gallery .mkfg-media:hover .mkfg-image,
    .mkfg-gallery.dombud-gallery .mkfg-item.is-hiding {
        transform: none !important;
    }
}
