/* ═══════════════════════════════════════════════
   Gallery & Lightbox Styles
   ═══════════════════════════════════════════════ */

/* ═══ GALLERY GRID ═══ */
.gallery {
    display: grid;
    gap: 1rem;
    margin: 2rem 0;
}

.gallery--grid.gallery--cols-2 { grid-template-columns: repeat(2, 1fr); }
.gallery--grid.gallery--cols-3 { grid-template-columns: repeat(3, 1fr); }
.gallery--grid.gallery--cols-4 { grid-template-columns: repeat(4, 1fr); }
.gallery--masonry { columns: 3; gap: 1rem; }
.gallery--masonry .gallery-item { break-inside: avoid; margin-bottom: 1rem; }

.gallery-item {
    position: relative;
    border-radius: 4px;
    overflow: hidden;
    background: #f0f0f0;
    cursor: pointer;
    aspect-ratio: 4 / 3;
}

.gallery-item-inner {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.gallery-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.gallery-item:hover .gallery-img {
    transform: scale(1.08);
}

.gallery-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 45, 51, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.35s ease;
}

.gallery-item:hover .gallery-overlay {
    opacity: 1;
}

.gallery-overlay-content {
    transform: translateY(10px);
    transition: transform 0.35s ease;
}

.gallery-item:hover .gallery-overlay-content {
    transform: translateY(0);
}

.gallery-view-btn {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.8);
    background: rgba(255, 255, 255, 0.1);
    color: white;
    font-size: 1.1rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
    backdrop-filter: blur(4px);
}

.gallery-view-btn:hover {
    background: var(--gold);
    border-color: var(--gold);
    color: var(--navy);
    transform: scale(1.1);
}

/* ═══ EMPTY GALLERY ═══ */
.gallery-empty {
    grid-column: 1 / -1;
    text-align: center;
    padding: 4rem 2rem;
    background: white;
    border-radius: 8px;
    border: 1px dashed var(--border);
}

.gallery-empty-inner i {
    font-size: 3rem;
    color: var(--text-muted);
    opacity: 0.4;
    margin-bottom: 1rem;
    display: block;
}

.gallery-empty-inner p {
    color: var(--text-muted);
    font-size: 0.95rem;
}

/* ═══ HERO SLIDESHOW ═══ */
.hero-slideshow {
    position: absolute;
    inset: 0;
    overflow: hidden;
}

.hero-slide {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    opacity: 0;
    transition: opacity 1.2s ease-in-out;
    transform: scale(1.05);
}

.hero-slide.active {
    opacity: 1;
}

.hero-dots {
    position: absolute;
    bottom: 100px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
    z-index: 10;
}

.hero-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.5);
    background: transparent;
    cursor: pointer;
    transition: all 0.3s;
    padding: 0;
}

.hero-dot.active {
    background: var(--gold);
    border-color: var(--gold);
}

.hero-dot:hover {
    border-color: var(--gold);
}

/* ═══ LIGHTBOX ═══ */
.lightbox {
    position: fixed;
    inset: 0;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.35s ease;
}

.lightbox.active {
    opacity: 1;
    pointer-events: all;
}

.lightbox-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 10, 12, 0.95);
    backdrop-filter: blur(8px);
}

.lightbox-content {
    position: relative;
    z-index: 2;
    max-width: 90vw;
    max-height: 80vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox-img {
    max-width: 100%;
    max-height: 80vh;
    object-fit: contain;
    border-radius: 4px;
    opacity: 0;
    transition: opacity 0.3s;
}

.lightbox-img.loaded {
    opacity: 1;
}

.lightbox-loading {
    position: absolute;
    display: none;
}

.lightbox.loading .lightbox-loading {
    display: block;
}

.spinner {
    width: 48px;
    height: 48px;
    border: 3px solid rgba(255, 107, 0, 0.2);
    border-top-color: var(--gold);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.lightbox-close {
    position: absolute;
    top: 20px;
    left: 20px;
    width: 44px;
    height: 44px;
    border: none;
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.1rem;
    z-index: 10;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox-close:hover {
    background: var(--gold);
    color: var(--navy);
}

.lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 50px;
    height: 50px;
    border: none;
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.2rem;
    z-index: 10;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(4px);
}

.lightbox-nav:hover {
    background: var(--gold);
    color: var(--navy);
}

.lightbox-prev { right: 20px; }
.lightbox-next { left: 20px; }

.lightbox-info {
    position: absolute;
    bottom: 100px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
    text-align: center;
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.85rem;
}

.lightbox-counter {
    display: block;
    margin-bottom: 4px;
    font-weight: 600;
    color: var(--gold);
}

.lightbox-filename {
    display: block;
    font-size: 0.8rem;
    opacity: 0.7;
}

/* Lightbox thumbnails */
.lightbox-thumbnails {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
    display: flex;
    gap: 6px;
    max-width: 80vw;
    overflow-x: auto;
    padding: 8px;
    scrollbar-width: none;
}

.lightbox-thumbnails::-webkit-scrollbar { display: none; }

.lb-thumb {
    width: 56px;
    height: 42px;
    border-radius: 4px;
    overflow: hidden;
    cursor: pointer;
    border: 2px solid transparent;
    opacity: 0.5;
    transition: all 0.3s;
    flex-shrink: 0;
}

.lb-thumb.active {
    border-color: var(--gold);
    opacity: 1;
}

.lb-thumb:hover {
    opacity: 0.8;
}

.lb-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* ═══ SERVICE GALLERY SECTION ═══ */
.service-gallery-section {
    padding: 4rem 0;
    background: var(--cream);
}

.service-gallery-section .section-header {
    margin-bottom: 3rem;
}

/* ═══ PARTNERS EMPTY STATE ═══ */
.partners-empty {
    text-align: center;
    padding: 3rem;
    color: var(--text-muted);
}

/* ═══ ANIMATIONS ═══ */
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes fadeUp { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }

/* ═══ RESPONSIVE ═══ */
@media (max-width: 1024px) {
    .gallery--grid.gallery--cols-4 { grid-template-columns: repeat(3, 1fr); }
    .gallery--masonry { columns: 2; }
}

@media (max-width: 768px) {
    .gallery--grid.gallery--cols-3,
    .gallery--grid.gallery--cols-4 { grid-template-columns: repeat(2, 1fr); }
    .gallery--masonry { columns: 2; }
    .lightbox-nav { width: 40px; height: 40px; font-size: 1rem; }
    .lightbox-prev { right: 10px; }
    .lightbox-next { left: 10px; }
    .lightbox-close { top: 10px; left: 10px; width: 38px; height: 38px; }
    .hero-dots { bottom: 80px; }
}

@media (max-width: 480px) {
    .gallery--grid.gallery--cols-2,
    .gallery--grid.gallery--cols-3,
    .gallery--grid.gallery--cols-4 { grid-template-columns: 1fr; }
    .gallery--masonry { columns: 1; }
    .lightbox-thumbnails { display: none; }
    .lightbox-info { bottom: 30px; }
}
