/* Estilos para la galería fotográfica - gallery-styles.css */

/* Estilos generales para la galería */
.gallery-container {
    padding: 20px 0;
    position: relative;
}

.gallery-header {
    margin-bottom: 30px;
}

.gallery-info {
    margin-bottom: 25px;
}

.gallery-description {
    font-size: 16px;
    line-height: 1.6;
    margin-bottom: 25px;
    color: #333;
}

/* ESTILOS MODERNOS PARA LA BARRA DE METADATOS */
.gallery-meta-container {
    margin: 20px 0;
    background: #ffffff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    padding: 0;
    overflow: hidden;
    transition: all 0.3s ease;
}

.gallery-meta-items {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
}

.meta-item {
    padding: 12px 20px;
    display: flex;
    align-items: center;
    color: #555;
    font-size: 14px;
    transition: all 0.2s ease;
}

    .meta-item i {
        margin-right: 10px;
        color: #3498db;
        font-size: 16px;
    }

.meta-divider {
    width: 1px;
    height: 20px;
    background-color: #eaeaea;
}

.meta-season {
    background-color: #f8f9fa;
    margin-left: auto;
}

    .meta-season i {
        color: #e67e22;
    }

/* Estilos para etiquetas */
.gallery-tags {
    display: flex;
    flex-wrap: wrap;
    margin: 15px 0;
    gap: 8px;
}

.gallery-tag {
    display: inline-flex;
    align-items: center;
    background: #f8f9fa;
    color: #555;
    padding: 6px 12px;
    border-radius: 30px;
    font-size: 13px;
    text-decoration: none;
    transition: all 0.2s ease;
}

    .gallery-tag i {
        margin-right: 5px;
        color: #3498db;
        font-size: 12px;
    }

    .gallery-tag:hover {
        background: #3498db;
        color: #fff;
        transform: translateY(-2px);
        box-shadow: 0 3px 8px rgba(0,0,0,0.1);
        text-decoration: none;
    }

        .gallery-tag:hover i {
            color: #fff;
        }

/* Efectos hover para los meta items */
.meta-item:hover {
    background-color: #f8f9fa;
}

/* NUEVO DISEÑO DEL VISOR DE IMÁGENES */
.modern-gallery {
    margin-bottom: 50px;
    position: relative;
}

/* Visor principal */
.gallery-main-viewer {
    background-color: #f8f9fa;
    border-radius: 8px;
    overflow: hidden;
    position: relative;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    margin-bottom: 15px;
}

.gallery-main-image {
    position: relative;
    height: 500px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #000;
    border-radius: 6px;
    overflow: hidden;
}

    .gallery-main-image img {
        max-height: 100%;
        max-width: 100%;
        object-fit: contain;
        transition: transform 0.3s ease;
    }

    .gallery-main-image:hover img {
        transform: scale(1.02);
    }

.gallery-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(0, 0, 0, 0.7);
    color: #fff;
    padding: 15px;
    font-size: 14px;
    transform: translateY(100%);
    transition: transform 0.3s ease;
    z-index: 2;
}

.gallery-main-image:hover .gallery-caption {
    transform: translateY(0);
}

/* Controles de navegación */
.gallery-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 50px;
    height: 50px;
    background: rgba(255, 255, 255, 0.8);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #333;
    font-size: 18px;
    cursor: pointer;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    z-index: 5;
    transition: all 0.2s ease;
}

    .gallery-nav:hover {
        background: rgba(255, 255, 255, 0.95);
        box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    }

.gallery-nav-prev {
    left: 15px;
}

.gallery-nav-next {
    right: 15px;
}

/* Carrusel de miniaturas */
.gallery-thumbs {
    padding: 15px;
    background-color: #f8f9fa;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    position: relative;
}

.gallery-thumbs-container {
    display: flex;
    overflow-x: auto;
    scroll-behavior: smooth;
    padding: 10px 0;
    scrollbar-width: thin;
    scrollbar-color: #ccc #f8f9fa;
}

    /* Fix para el panel dentro del contenedor de miniaturas */
    .gallery-thumbs-container > div {
        display: flex;
        flex-wrap: nowrap;
    }

    .gallery-thumbs-container::-webkit-scrollbar {
        height: 6px;
    }

    .gallery-thumbs-container::-webkit-scrollbar-track {
        background: #f8f9fa;
    }

    .gallery-thumbs-container::-webkit-scrollbar-thumb {
        background-color: #ccc;
        border-radius: 6px;
    }

.gallery-thumb {
    flex: 0 0 auto;
    width: 80px;
    height: 60px;
    margin-right: 10px;
    border-radius: 4px;
    overflow: hidden;
    cursor: pointer;
    position: relative;
    border: 2px solid transparent;
    transition: all 0.2s ease;
}

    .gallery-thumb.active {
        border-color: #0056b3;
    }

    .gallery-thumb:hover {
        transform: translateY(-2px);
        box-shadow: 0 3px 8px rgba(0, 0, 0, 0.15);
    }

    .gallery-thumb img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

/* Contador de imágenes */
.gallery-counter {
    position: absolute;
    top: 15px;
    right: 15px;
    background: rgba(0, 0, 0, 0.6);
    color: #fff;
    padding: 5px 10px;
    border-radius: 20px;
    font-size: 12px;
    z-index: 5;
}

/* Botón de pantalla completa */
.gallery-fullscreen {
    position: absolute;
    top: 15px;
    right: 70px;
    background: rgba(0, 0, 0, 0.6);
    color: #fff;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 5;
    transition: all 0.2s ease;
}

    .gallery-fullscreen:hover {
        background: rgba(0, 0, 0, 0.8);
    }

/* Animación de carga */
.gallery-loading {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
}

    .gallery-loading:after {
        content: "";
        width: 40px;
        height: 40px;
        border: 4px solid #f3f3f3;
        border-top: 4px solid #0056b3;
        border-radius: 50%;
        animation: spin 1s linear infinite;
    }

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

/* Estilos para galerías relacionadas */
.related-galleries {
    padding-top: 30px;
    margin-top: 30px;
    border-top: 1px solid #eee;
}

.related-gallery-card {
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    margin-bottom: 30px;
    height: 100%;
    overflow: hidden;
}

    .related-gallery-card:hover {
        transform: translateY(-5px);
        box-shadow: 0 10px 20px rgba(0, 0, 0, 0.15);
    }

.related-gallery-image {
    height: 180px;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    position: relative;
}

.related-gallery-info {
    padding: 15px;
}

.related-gallery-title {
    font-size: 15px;
    font-weight: 600;
    margin-bottom: 8px;
    color: #333;
    line-height: 1.4;
    max-height: 2.8em;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.related-gallery-date {
    font-size: 12px;
    color: #666;
}

/* Responsive */
@media (max-width: 768px) {
    .gallery-main-image {
        height: 350px;
    }

    .gallery-nav {
        width: 40px;
        height: 40px;
        font-size: 16px;
    }

    .gallery-thumb {
        width: 60px;
        height: 45px;
    }

    .meta-divider {
        display: none;
    }

    .meta-item {
        padding: 10px 15px;
        flex: 1 1 auto;
        justify-content: center;
    }

    .meta-season {
        flex-basis: 100%;
        margin-left: 0;
        border-top: 1px solid #eaeaea;
    }

    .related-gallery-image {
        height: 150px;
    }
}
