.gallery{

max-width:1200px;

margin:auto;

padding:60px 20px;

}

.gallery-hero{

text-align:center;

padding:60px 20px;

}

.gallery-hero h1{

font-size:3rem;

margin-bottom:15px;

}

.gallery-viewer {

    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;

    margin: 0 auto;
    max-width: 1200px;

}

.gallery-viewer img {

    max-width: 100%;
    max-height: 75vh;

    width: auto;
    height: auto;

    border-radius: 16px;

    object-fit: contain;

    box-shadow: 0 15px 35px rgba(0,0,0,.25);

    background: #111;

}

.gallery-arrow {

    position: absolute;

    top: 50%;
    transform: translateY(-50%);

    width: 56px;
    height: 56px;

    border: none;
    border-radius: 50%;

    background: rgba(0,0,0,.55);

    color: white;

    font-size: 2rem;

    cursor: pointer;

    transition: .25s;

    z-index: 10;

}

.gallery-arrow:hover{

    background: rgba(13,92,143,.90);

    transform: translateY(-50%) scale(1.1);

}

.gallery-arrow.prev{

    left:20px;

}

.gallery-arrow.next{

    right:20px;

}

#gallery-image{

    transition: opacity .35s ease;

}

.fade{

    opacity:0;

}

/* ==========================================
   Photo Information
   ========================================== */

.gallery-caption {

    max-width: 900px;

    margin: 0 auto;

    text-align: center;

}

.gallery-caption h2 {

    margin-bottom: 12px;

}

.gallery-details {

    display: flex;

    flex-wrap: wrap;

    justify-content: center;

    gap: 10px 20px;

    margin: 10px 0 14px;

}

.gallery-detail {

    display: inline-flex;

    align-items: center;

    gap: 6px;

    font-size: 0.95rem;

    color: #555;

}

.gallery-detail strong {

    color: #243447;

}

.gallery-caption p {

    max-width: 700px;

    margin-left: auto;

    margin-right: auto;

    line-height: 1.6;

}

/* Mobile */

@media (max-width: 600px) {

    .gallery-details {

        flex-direction: column;

        align-items: center;

        gap: 7px;

    }

}

.thumbnail-container{

display:flex;

gap:12px;

overflow-x:auto;

padding:15px 0;

}

.thumbnail-container img{

width:120px;

height:80px;

object-fit:cover;

cursor:pointer;

border-radius:8px;

opacity:.7;

transition:.3s;

}

.thumbnail-container img:hover{

opacity:1;

transform:scale(1.05);

}

.thumbnail-container img.active{

opacity:1;

outline:3px solid #0d5c8f;

}

/* ==========================================
   Gallery Thumbnails
   ========================================== */

.thumbnail-container {

    display: flex;

    gap: 12px;

    overflow-x: auto;

    padding: 20px 5px;

    margin: 0 auto;

    max-width: 1000px;

    scrollbar-width: thin;

}

.thumbnail-container img {

    flex: 0 0 auto;

    width: 110px;

    height: 75px;

    object-fit: cover;

    border-radius: 8px;

    cursor: pointer;

    opacity: .65;

    transition:
        opacity .2s ease,
        transform .2s ease;

}

.thumbnail-container img:hover {

    opacity: 1;

    transform: translateY(-3px);

}

.thumbnail-container img.active {

    opacity: 1;

    outline: 3px solid #0d5c8f;

    outline-offset: 2px;

}


/* ==========================================
   Touch Behavior
   ========================================== */

.gallery-viewer img {

    touch-action: pan-y;

}


/* ==========================================
   Mobile
   ========================================== */

@media (max-width: 600px) {

    .thumbnail-container img {

        width: 85px;

        height: 60px;

    }

}

/* ==========================================
   Gallery Controls
   ========================================== */

.gallery-controls {

    display: flex;

    justify-content: center;

    align-items: center;

    gap: 12px;

    margin: 25px 0;

}

.gallery-controls button {

    border: none;

    border-radius: 8px;

    padding: 11px 18px;

    background: #0d5c8f;

    color: white;

    font-size: .95rem;

    font-weight: 600;

    cursor: pointer;

    transition:
        background .2s ease,
        transform .2s ease;

}

.gallery-controls button:hover {

    background: #08466d;

    transform: translateY(-2px);

}


/* ==========================================
   Fullscreen Button
   ========================================== */

.gallery-fullscreen {

    position: absolute;

    right: 20px;
    bottom: 20px;

    width: 48px;
    height: 48px;

    border: none;

    border-radius: 50%;

    background: rgba(0,0,0,.60);

    color: white;

    font-size: 1.5rem;

    cursor: pointer;

    z-index: 10;

    transition:
        background .2s ease,
        transform .2s ease;

}

.gallery-fullscreen:hover {

    background: rgba(13,92,143,.95);

    transform: scale(1.08);

}


/* ==========================================
   Fullscreen Gallery
   ========================================== */

.gallery-viewer:fullscreen {

    width: 100vw;
    height: 100vh;

    background: #111;

    display: flex;

    align-items: center;
    justify-content: center;

    padding: 30px;

}

.gallery-viewer:fullscreen img {

    max-width: 95vw;
    max-height: 95vh;

    width: auto;
    height: auto;

    object-fit: contain;

}

.gallery-viewer:fullscreen .gallery-arrow {

    position: fixed;

}

.gallery-viewer:fullscreen .gallery-fullscreen {

    position: fixed;

}

.gallery-error {

    max-width: 700px;

    margin: 60px auto;

    padding: 40px;

    text-align: center;

    border-radius: 12px;

    background: #f5f5f5;

}

.gallery-error h2 {

    margin-bottom: 12px;

}

.gallery-details:empty {
    display: none;
}

.gallery-caption h2:empty,
.gallery-caption p:empty {
    display: none;
}

@media (max-width: 600px) {

    .gallery-caption {
        padding: 0 10px;
    }

    .gallery-caption h2 {
        font-size: 1.5rem;
    }

    .gallery-detail {
        font-size: 0.9rem;
    }

}
.gallery-submit-cta {
    max-width: 760px;
    margin: 45px auto 0;
    padding: 32px;
    text-align: center;
    border: 1px solid #ddd;
    border-radius: 8px;
    background: #f7f7f7;
}

.gallery-submit-cta h2 {
    margin-bottom: 10px;
}

.gallery-submit-cta p {
    margin-bottom: 20px;
}

.gallery-submit-cta .button-primary {
    display: inline-block;
    padding: 13px 24px;
    border-radius: 5px;
    background: var(--secondary, #0d5c8f);
    color: #fff;
    font-weight: 700;
}
