/* ==============================
   GALLERY LAYOUT
   ============================== */

.gallery-page {
    max-width: 1200px;
    margin: 80px auto;
    padding: 0 20px;
    text-align: center;
}

/* Titel */
.page-title {
    font-family: 'Great Vibes', cursive;
    font-size: 36px;
    color: #d4af37;
    margin-bottom: 20px;
}

/* Subtitel (show titel) */
.show-title,
.sub-title {
    font-family: 'Montserrat', sans-serif;
    font-size: 22px;
    font-weight: 700;
    color: #d4af37;
    text-align: center;
    margin: 30px 0 15px;
}

/* ==============================
   ALBUM LIST (buttons)
   ============================== */

.album-list {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
    margin: 18px 0 6px;
}

.album-link {
    display: inline-block;
    padding: 10px 14px;
    border: 1px solid rgba(212,175,55,0.40);
    border-radius: 12px;
    color: #d4af37;
    text-decoration: none;
    background: rgba(0,0,0,0.35);
    transition: transform 0.12s ease, border-color 0.12s ease;
}

.album-link:hover {
    transform: translateY(-1px);
    border-color: rgba(212,175,55,0.75);
    text-decoration: underline;
}

/* ==============================
   SORT CONTROLS
   ============================== */

.pg-sort {
    max-width: 920px;
    margin: 0 auto 14px;
    display: flex;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
}

.pg-sort-link {
    display: inline-block;
    padding: 8px 12px;
    border: 1px solid rgba(212,175,55,0.35);
    border-radius: 12px;
    color: #d4af37;
    text-decoration: none;
    background: rgba(0,0,0,0.30);
    transition: transform 0.12s ease, border-color 0.12s ease;
    font-size: 14px;
}

.pg-sort-link:hover {
    transform: translateY(-1px);
    border-color: rgba(212,175,55,0.80);
    text-decoration: underline;
}

.pg-sort-link.is-active {
    border-color: rgba(212,175,55,0.95);
    box-shadow: 0 0 10px rgba(212,175,55,0.20);
}

/* ==============================
   MAIN IMAGE (large)
   ============================== */

/* Wrap + pijlen buiten de foto */
.pg-main-wrap {
    max-width: 920px;
    margin: 0 auto 16px;
    position: relative;
}

/* Main container */
.gallery-main {
    max-width: 920px;
    margin: 18px auto 18px;
    display: flex;
    justify-content: center;

    /* nodig voor lichtbundels */
    position: relative;
    overflow: hidden;
    border-radius: 18px;
}

/* jouw class (compat) */
.gallery-main-image,
.gallery-main img {
    width: 100%;
    max-height: 520px;
    object-fit: contain;
    display: block;

    border-radius: 18px;
    border: 1px solid rgba(212,175,55,0.28);
    background: rgba(0,0,0,0.55);
    box-shadow: 0 0 18px rgba(0,0,0,0.45);

    /* fade bij wisselen */
    transition: opacity 0.25s ease;

    /* stacking voor beams */
    position: relative;
    z-index: 2;
}

.gallery-main-image.is-fading { opacity: 0.25; }

/* Pijlen naast main foto (desktop groot) */
.pg-main-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 60px;
    height: 60px;
    font-size: 28px;

    border-radius: 999px;
    border: 1px solid rgba(212,175,55,0.35);
    background: rgba(0,0,0,0.55);
    color: #d4af37;

    cursor: pointer;
    z-index: 6;
    display: grid;
    place-items: center;
}

.pg-main-arrow.left { left: -58px; }
.pg-main-arrow.right { right: -58px; }

.pg-main-arrow:hover { border-color: rgba(212,175,55,0.85); }

/* ==============================
   LIGHT BEAMS (X-shape)
   - Left beam: /  (points to upper-right)
   - Right beam: \ (points to upper-left)
   - Move towards each other and cross in the center
   ============================== */

.gallery-main::before,
.gallery-main::after {
    content: "";
    position: absolute;
    bottom: -30%;
    width: 70%;
    height: 180%;

    pointer-events: none;
    z-index: 3;

    /* beam look */
    background: linear-gradient(
        90deg,
        transparent 0%,
        rgba(255,255,255,0.00) 35%,
        rgba(255,255,255,0.18) 45%,
        rgba(212,175,55,0.25) 55%,
        rgba(255,255,255,0.12) 62%,
        transparent 75%
    );

    filter: blur(1.5px);
    mix-blend-mode: screen;
    transform-origin: bottom center;
}

/* Left beam: / */
.gallery-main::before {
    left: -65%;
    opacity: 0.55;
    transform: rotate(-18deg);
    animation: ccBeamLeftX 7s ease-in-out infinite;
}

/* Right beam: \ */
.gallery-main::after {
    right: -65%;
    opacity: 0.45;
    transform: rotate(18deg);
    animation: ccBeamRightX 7s ease-in-out infinite;
}

/* Move left beam from left -> right */
@keyframes ccBeamLeftX {
    0%   { left: -75%; opacity: 0.08; }
    20%  { opacity: 0.55; }
    50%  { left: 15%;  opacity: 0.50; }  /* kruisen in midden */
    80%  { opacity: 0.55; }
    100% { left: 115%; opacity: 0.08; }
}

/* Move right beam from right -> left */
@keyframes ccBeamRightX {
    0%   { right: -75%; opacity: 0.06; }
    20%  { opacity: 0.45; }
    50%  { right: 15%;  opacity: 0.45; } /* kruisen in midden */
    80%  { opacity: 0.45; }
    100% { right: 115%; opacity: 0.06; }
}

/* ==============================
   THUMBS: HORIZONTAL GRID CAROUSEL (2 rows)
   ============================== */

.thumb-grid-wrap {
    max-width: 920px;
    margin: 0 auto;
    position: relative;
}

/* Horizontaal scrollend grid (2 rijen) */
.thumb-grid-scroll {
    height: 250px;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 14px;

    border-radius: 18px;
    border: 1px solid rgba(212,175,55,0.22);
    background: rgba(0,0,0,0.35);

    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: 160px;
    grid-template-rows: repeat(2, 110px);
    gap: 14px;

    scroll-behavior: smooth;
    scrollbar-width: thin;
}

/* Thumb item als button */
.thumb-btn {
    padding: 0;
    border: 1px solid rgba(212,175,55,0.18);
    border-radius: 14px;
    background: transparent;
    cursor: pointer;
    overflow: hidden;
    transition: transform 0.12s ease, border-color 0.12s ease;
}

.thumb-btn:hover {
    transform: translateY(-2px);
    border-color: rgba(212,175,55,0.55);
}

.thumb-btn.is-active {
    border-color: rgba(212,175,55,0.95);
    box-shadow: 0 0 10px rgba(212,175,55,0.25);
}

.thumb-btn img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Pijltjes bij thumbs */
.thumb-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 42px;
    height: 42px;
    border-radius: 999px;
    border: 1px solid rgba(212,175,55,0.35);
    background: rgba(0,0,0,0.55);
    color: #d4af37;
    cursor: pointer;
    z-index: 5;
    display: grid;
    place-items: center;
}

.thumb-arrow.left { left: -18px; }
.thumb-arrow.right { right: -18px; }

.thumb-arrow:hover { border-color: rgba(212,175,55,0.85); }

/* ==============================
   BACKWARDS COMPAT (oude classes)
   ============================== */

.gallery-thumbs {
    display: flex;
    gap: 14px;
    overflow-x: auto;
    padding: 15px 10px;
    justify-content: center;
}

.gallery-thumb {
    height: 100px;
    cursor: pointer;
    border: 2px solid transparent;
    border-radius: 10px;
    transition: 0.2s ease;
    flex-shrink: 0;
}

.gallery-thumb:hover { transform: scale(1.05); }
.gallery-thumb.active { border-color: #d4af37; }

/* ==============================
   RESPONSIVE
   ============================== */

@media (max-width: 1000px) {
    .pg-main-arrow.left { left: -44px; }
    .pg-main-arrow.right { right: -44px; }
}

@media (max-width: 800px) {
    .gallery-main {
        max-width: 100%;
        border-radius: 14px;
    }

    .gallery-main-image,
    .gallery-main img {
        max-height: 420px;
        border-radius: 14px;
    }

    .thumb-grid-wrap { max-width: 100%; }

    .thumb-grid-scroll {
        height: 230px;
        grid-auto-columns: 140px;
        grid-template-rows: repeat(2, 100px);
        border-radius: 14px;
        padding: 12px;
        gap: 12px;
    }

    .thumb-arrow.left { left: -10px; }
    .thumb-arrow.right { right: -10px; }

    .pg-main-arrow.left { left: -10px; }
    .pg-main-arrow.right { right: -10px; }
}

/* Mobiel: main pijlen kleiner + beams subtieler */
@media (max-width: 600px) {
    .pg-main-arrow {
        width: 36px;
        height: 36px;
        font-size: 18px;
    }
    .pg-main-arrow.left { left: -6px; }
    .pg-main-arrow.right { right: -6px; }

    .gallery-main::before,
    .gallery-main::after {
        opacity: 0.35;
        filter: blur(1.2px);
    }
}

@media (max-width: 480px) {
    .page-title { font-size: 32px; }

    .show-title,
    .sub-title { font-size: 18px; }

    .thumb-grid-scroll {
        height: 220px;
        grid-auto-columns: 130px;
        grid-template-rows: repeat(2, 95px);
    }
}
