/* Graham's Shop Manager — Gallery Frontend */

.grahams-gallery-page {
    width: 100%;
    max-width: 100%;
    overflow-x: clip;
}

.grahams-gallery-hero {
    padding-top: 138px;
    padding-bottom: 82px;
}

.grahams-gallery-hero__inner {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: end;
    gap: 60px;
}

.grahams-gallery-hero__copy {
    max-width: 960px;
}

.grahams-gallery-hero__eyebrow,
.grahams-gallery-cta__eyebrow {
    color: var(--grahams-light);
}

.grahams-gallery-hero h1 {
    max-width: 900px;
}

.grahams-gallery-hero__intro {
    max-width: 560px;
    margin: 26px 0 0;
    color: var(--grahams-light);
    font-size: 15px;
    line-height: 1.8;
}

.grahams-gallery-hero__note {
    margin: 0 0 8px;
    color: var(--grahams-light);
    font-size: 9px;
    font-weight: 600;
    line-height: 1;
    letter-spacing: .16em;
    text-transform: uppercase;
}

.grahams-gallery {
    padding-top: 74px;
    padding-bottom: 92px;
}

.grahams-gallery-page--media-only .grahams-gallery {
    padding-top: 0;
    padding-bottom: 0;
}

.grahams-gallery__grid {
    width: 100%;
    column-count: 3;
    column-gap: 16px;
}

.grahams-gallery__item {
    position: relative;
    display: block;
    width: 100%;
    min-width: 0;
    min-height: 0;
    margin: 0 0 16px;
    padding: 0;
    overflow: hidden;
    border: 0;
    background: var(--grahams-cream-soft);
    cursor: zoom-in;
    appearance: none;
    break-inside: avoid;
    page-break-inside: avoid;
    vertical-align: top;
}

.grahams-gallery__item img,
.grahams-gallery__video-preview {
    display: block;
    width: 100%;
    height: auto;
    max-width: 100%;
    object-fit: initial;
    object-position: initial;
    transition: transform .8s var(--grahams-ease), filter .4s ease;
}

.grahams-gallery__video-preview {
    background: var(--grahams-ink);
}

.grahams-gallery__item-shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(24,23,21,0) 58%, rgba(24,23,21,.26) 100%);
    opacity: 0;
    transition: opacity .4s ease;
    pointer-events: none;
}

.grahams-gallery__item-icon,
.grahams-gallery__play {
    position: absolute;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--grahams-cream);
    border: 1px solid rgba(246,241,232,.56);
    border-radius: 50%;
    background: rgba(24,23,21,.28);
    pointer-events: none;
}

.grahams-gallery__item-icon {
    right: 18px;
    bottom: 17px;
    width: 38px;
    height: 38px;
    font-size: 13px;
    opacity: 0;
    transform: translateY(8px);
    transition: opacity .35s ease, transform .35s var(--grahams-ease);
}

.grahams-gallery__play {
    top: 50%;
    left: 50%;
    width: 58px;
    height: 58px;
    transform: translate(-50%, -50%);
    backdrop-filter: blur(5px);
}

.grahams-gallery__play span {
    margin-left: 3px;
    font-size: 15px;
}

.grahams-gallery__item:hover img,
.grahams-gallery__item:hover .grahams-gallery__video-preview,
.grahams-gallery__item:focus-visible img,
.grahams-gallery__item:focus-visible .grahams-gallery__video-preview {
    transform: scale(1.015);
}

.grahams-gallery__item:hover .grahams-gallery__item-shade,
.grahams-gallery__item:focus-visible .grahams-gallery__item-shade {
    opacity: 1;
}

.grahams-gallery__item:hover .grahams-gallery__item-icon,
.grahams-gallery__item:focus-visible .grahams-gallery__item-icon {
    opacity: 1;
    transform: translateY(0);
}

.grahams-gallery__empty {
    margin: 0;
    padding: 70px 0;
    color: var(--grahams-muted);
    text-align: center;
}

.grahams-gallery-cta {
    padding-top: 86px;
    padding-bottom: 88px;
}

.grahams-gallery-cta__inner {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: end;
    gap: 70px;
}

.grahams-gallery-cta h2 {
    max-width: 720px;
}

.grahams-gallery-cta__actions {
    display: flex;
    align-items: center;
    gap: 28px;
}

.grahams-gallery-cta__link {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--grahams-cream);
    font-size: 10px;
    font-weight: 600;
    line-height: 1;
    letter-spacing: .14em;
    text-decoration: none;
    text-transform: uppercase;
}

.grahams-gallery-cta__link span {
    font-size: 14px;
    font-weight: 400;
    transition: transform .3s ease;
}

.grahams-gallery-cta__link:hover span {
    transform: translate(2px, -2px);
}

.grahams-gallery-page.is-gallery-motion-ready .grahams-gallery__item {
    opacity: 0;
    transform: translate3d(0,18px,0);
    transition: opacity .75s var(--grahams-ease), transform .75s var(--grahams-ease);
}

.grahams-gallery-page.is-gallery-motion-ready .grahams-gallery__item.is-visible {
    opacity: 1;
    transform: translate3d(0,0,0);
}

.grahams-gallery-lightbox {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 28px;
}

.grahams-gallery-lightbox.is-open {
    display: flex;
}

.grahams-gallery-lightbox__backdrop {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    padding: 0;
    border: 0;
    background: rgba(12,11,10,.94);
    cursor: zoom-out;
}

.grahams-gallery-lightbox__dialog {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    width: min(94vw,1500px);
    height: min(88vh,980px);
}

.grahams-gallery-lightbox__figure {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    margin: 0;
}

.grahams-gallery-lightbox__figure img,
.grahams-gallery-lightbox__figure video {
    display: none;
    width: auto;
    height: auto;
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    background: #000;
    box-shadow: 0 26px 80px rgba(0,0,0,.34);
}

.grahams-gallery-lightbox__figure video {
    width: min(100%, 1200px);
}

.grahams-gallery-lightbox__close,
.grahams-gallery-lightbox__nav {
    position: absolute;
    z-index: 3;
    width: 48px;
    height: 48px;
    padding: 0;
    border: 1px solid rgba(246,241,232,.34);
    border-radius: 50%;
    background: rgba(24,23,21,.44);
    color: var(--grahams-cream);
    font-weight: 300;
    line-height: 1;
    cursor: pointer;
}

.grahams-gallery-lightbox__close {
    top: 0;
    right: 0;
    font-size: 28px;
}

.grahams-gallery-lightbox__nav {
    top: 50%;
    font-size: 34px;
    transform: translateY(-50%);
}

.grahams-gallery-lightbox__nav--prev {
    left: 0;
}

.grahams-gallery-lightbox__nav--next {
    right: 0;
}

body.grahams-gallery-lock {
    overflow: hidden;
}

@media (max-width: 1000px) {
    .grahams-gallery__grid {
        column-count: 2;
        column-gap: 12px;
    }

    .grahams-gallery__item {
        margin-bottom: 12px;
    }

    .grahams-gallery-cta__inner {
        grid-template-columns: 1fr;
        gap: 42px;
    }
}

@media (max-width: 700px) {
    .grahams-gallery-hero {
        padding-top: 104px;
        padding-bottom: 56px;
    }

    .grahams-gallery-hero__inner {
        grid-template-columns: 1fr;
        gap: 28px;
    }

    .grahams-gallery-hero__note {
        margin: 0;
    }

    .grahams-gallery {
        padding-top: 12px;
        padding-bottom: 58px;
    }

    .grahams-gallery__grid {
        column-count: 2;
        column-gap: 8px;
    }

    .grahams-gallery__item {
        margin-bottom: 8px;
    }

    .grahams-gallery__item-icon {
        display: none;
    }

    .grahams-gallery__play {
        width: 46px;
        height: 46px;
    }

    .grahams-gallery-cta {
        padding-top: 68px;
        padding-bottom: 70px;
    }

    .grahams-gallery-cta__actions {
        align-items: flex-start;
        flex-direction: column;
    }

    .grahams-gallery-lightbox {
        padding: 14px;
    }

    .grahams-gallery-lightbox__dialog {
        width: 100%;
        height: 84vh;
    }

    .grahams-gallery-lightbox__close {
        top: 4px;
        right: 4px;
    }

    .grahams-gallery-lightbox__nav {
        top: auto;
        bottom: 4px;
        transform: none;
    }

    .grahams-gallery-lightbox__nav--prev {
        left: 4px;
    }

    .grahams-gallery-lightbox__nav--next {
        right: 4px;
    }
}

@media (max-width: 480px) {
    .grahams-gallery__grid {
        column-count: 1;
    }
}

@media (prefers-reduced-motion: reduce) {
    .grahams-gallery-page.is-gallery-motion-ready .grahams-gallery__item {
        opacity: 1;
        transform: none;
        transition: none;
    }

    .grahams-gallery__item img,
    .grahams-gallery__video-preview,
    .grahams-gallery__item-icon,
    .grahams-gallery-cta__link span {
        transition: none !important;
    }
}
