/* =========================================
   GALLERY KICKER / EYEBROW
========================================= */

.velo-gallery-grid .velo-kicker {
    position: relative;

    width: fit-content;
    margin: 0 0 30px;
    padding-bottom: 16px;

    font-family: "Jura", Arial, sans-serif;
    font-size: clamp(2rem, 2.5vw, 2.75rem);
    font-weight: 800;
    line-height: 1;
    letter-spacing: 0.24em;
    text-transform: uppercase;

    color: #008fe8;
}

.velo-gallery-grid .velo-kicker::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;

    width: 86px;
    height: 3px;

    border-radius: 999px;

    background: linear-gradient(
        90deg,
        #007cff 0%,
        #00b8ff 68%,
        rgba(255, 255, 255, 0) 100%
    );

    box-shadow:
        0 0 8px rgba(0, 140, 255, 0.36),
        0 0 18px rgba(69, 217, 255, 0.2);
}

/* =========================================
   GALLERY GRID - SMALL SQUARE PHOTOS
========================================= */

.velo-gallery-grid__items {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: clamp(16px, 1.6vw, 24px);
}

/* Every gallery item uses the same square size */
.velo-gallery-grid__item,
.velo-gallery-grid__item:nth-child(n) {
    position: relative;
    overflow: hidden;
    isolation: isolate;

    grid-column: auto;
    grid-row: auto;

    width: 100%;
    aspect-ratio: 1 / 1;
    min-width: 0;
    margin: 0;

    border: 1px solid rgba(210, 230, 244, 0.92);
    border-radius: 12px;

    background: #eaf3f9;

    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.94),
        0 14px 38px rgba(7, 16, 31, 0.07);

    transition:
        transform 0.35s ease,
        border-color 0.35s ease,
        box-shadow 0.35s ease;
}

/* Images completely fill each square */
.velo-gallery-grid__item img {
    display: block;

    width: 100%;
    height: 100%;

    object-fit: cover;
    object-position: center;

    transform: scale(1.01);

    transition:
        transform 0.6s cubic-bezier(0.2, 0.7, 0.2, 1),
        filter 0.45s ease;
}

/* Hover overlay */
.velo-gallery-grid__item::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 1;

    background:
        linear-gradient(
            180deg,
            rgba(255, 255, 255, 0.02) 0%,
            rgba(7, 16, 31, 0.08) 65%,
            rgba(7, 16, 31, 0.38) 100%
        );

    opacity: 0.25;
    pointer-events: none;

    transition: opacity 0.35s ease;
}

.velo-gallery-grid__item::after {
    content: "View Project";

    position: absolute;
    left: 16px;
    bottom: 16px;
    z-index: 2;

    padding: 9px 12px;

    font-family: "Jura", Arial, sans-serif;
    font-size: 0.66rem;
    font-weight: 800;
    line-height: 1;
    letter-spacing: 0.12em;
    text-transform: uppercase;

    color: #ffffff;
    background: rgba(7, 16, 31, 0.68);

    border: 1px solid rgba(255, 255, 255, 0.34);
    border-radius: 4px;

    backdrop-filter: blur(10px);

    opacity: 0;
    transform: translateY(8px);

    transition:
        opacity 0.3s ease,
        transform 0.3s ease;
}

/* Hover */
.velo-gallery-grid__item:hover {
    transform: translateY(-6px);

    border-color: rgba(69, 217, 255, 0.48);

    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.96),
        0 22px 48px rgba(7, 16, 31, 0.12),
        0 0 32px rgba(69, 217, 255, 0.14);
}

.velo-gallery-grid__item:hover img {
    transform: scale(1.07);
    filter: saturate(1.08) contrast(1.04);
}

.velo-gallery-grid__item:hover::before {
    opacity: 0.65;
}

.velo-gallery-grid__item:hover::after {
    opacity: 1;
    transform: translateY(0);
}

/* =========================================
   TABLET
========================================= */

@media (max-width: 1024px) {
    .velo-gallery-grid__items {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

/* =========================================
   SMALL TABLET
========================================= */

@media (max-width: 760px) {
    .velo-gallery-grid__items {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 16px;
    }
}

/* =========================================
   MOBILE
========================================= */

@media (max-width: 480px) {
    .velo-gallery-grid__items {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 12px;
    }

    .velo-gallery-grid__item,
    .velo-gallery-grid__item:nth-child(n) {
        aspect-ratio: 1 / 1;
        border-radius: 8px;
    }

    .velo-gallery-grid__item::after {
        left: 10px;
        bottom: 10px;
        padding: 7px 9px;
        font-size: 0.56rem;
    }
}

/* =========================================
   TOUCH DEVICES
========================================= */

@media (hover: none) {
    .velo-gallery-grid__item::after {
        opacity: 1;
        transform: none;
    }
}