/**
 * Galería Departamental V13 - Estilos Optimizados (Versión Estable)
 * Parte del sistema de diseño premium de Asomaría.
 * Ajuste: Eliminando border-radius (bordes rectos por preferencia del usuario).
 */

.hero-galeria-v13 {
    padding: 25px 0 0px; 
    background: #FDFBFA;
    text-align: center;
    position: relative;
    overflow: hidden; 
}

.hero-galeria-v13 .insignia-v13 {
    display: inline-block;
    padding: 5px 16px;
    background: #D4A017;
    color: white;
    font-size: 0.65rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 2px;
    border-radius: 0; 
    margin-bottom: 10px;
    box-shadow: 0 8px 20px rgba(212, 160, 23, 0.2);
    position: relative; 
    z-index: 6;
}

.hero-galeria-v13 h1 {
    font-family: 'Playfair Display', serif;
    font-size: clamp(1.8rem, 4vw, 2.8rem);
    line-height: 1.1;
    font-weight: 900;
    margin-bottom: 10px;
    color: #1A2B3C;
    position: relative; 
    z-index: 6;
}

.hero-galeria-v13 h1 span { 
    color: #D4A017; 
    font-style: italic; 
}

.hero-galeria-v13 p {
    font-size: 1.05rem;
    max-width: 750px;
    margin: 0 auto;
    opacity: 0.85;
    font-family: 'Outfit', sans-serif;
    position: relative; 
    z-index: 6;
    line-height: 1.5;
}

.v13-hero-watermark-gal {
    font-family: 'Outfit', sans-serif;
    font-size: clamp(8rem, 22vw, 15rem);
    color: #f7f1e6;
    width: 100%; 
    text-align: center;
    position: absolute; 
    top: 50%; 
    left: 50%; 
    transform: translate(-50%, -50%);
    z-index: 1; 
    font-weight: 900; 
    pointer-events: none; 
    opacity: 0.7;
}

.section-galeria-v13-main {
    padding-top: 0px !important;
    background: #FFFFFF;
    position: relative;
    z-index: 20;
}

.breadcrumb-asomaria {
    font-size: 0.85rem; 
    font-family: 'Outfit', sans-serif; 
    color: #D4A017;
    margin-bottom: 5px; 
    font-weight: 700; 
    text-transform: uppercase;
}

.btn-volver-asomaria-pill {
    display: inline-flex; 
    align-items: center;
    padding: 8px 0; 
    border: none;
    background: transparent;
    color: #1A2B3C; 
    font-size: 0.72rem; 
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 2px;
    text-decoration: none !important;
    transition: all 0.3s ease;
    position: relative;
}

.btn-volver-asomaria-pill i {
    font-size: 0.9rem;
    margin-right: 10px;
    transition: transform 0.3s ease;
    color: #D4A017;
}

.btn-volver-asomaria-pill::after {
    content: '';
    position: absolute;
    bottom: 5px;
    left: 25px;
    width: 0;
    height: 2px;
    background: #D4A017;
    transition: width 0.3s ease;
}

.btn-volver-asomaria-pill:hover {
    color: #D4A017 !important;
}

.btn-volver-asomaria-pill:hover i {
    transform: translateX(-5px);
}

.btn-volver-asomaria-pill:hover::after {
    width: calc(100% - 25px);
}

.title-section-center { 
    text-align: center; 
    margin-bottom: 10px; 
}

.title-section-center h2 {
    font-family: 'Playfair Display', serif; 
    font-weight: 900;
    font-size: 2.5rem;
    color: #1A2B3C; 
    text-transform: uppercase; 
    margin: 0 !important;
}

.accent-line-gold { 
    width: 60px; 
    height: 3px; 
    background: #D4A017; 
    margin: 5px auto 5px; 
}

/* Cajas Premium Estables SIN BORDES REDONDEADOS */
.card-album-premium {
    position: relative; 
    background: #fff; 
    border-radius: 0; /* Bordes rectos */
    overflow: hidden;
    border: 1px solid rgba(0,0,0,0.05); 
    transition: all 0.5s ease;
    box-shadow: 0 10px 30px rgba(0,0,0,0.02);
}

.card-album-premium:hover { 
    transform: translateY(-10px); 
    box-shadow: 0 25px 50px rgba(26, 43, 60, 0.1); 
    border-color: #D4A017; 
}

.img-album-container { 
    position: relative; 
    aspect-ratio: 16/10; 
    overflow: hidden; 
    border-radius: 0; /* Bordes rectos */
}

.img-album-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.8s cubic-bezier(0.2, 0.6, 0.2, 1);
    border-radius: 0 !important;
}

.card-album-premium:hover .img-album-container img {
    transform: scale(1.1);
}

.photo-count-badge { 
    position: absolute; 
    top: 15px; 
    right: 15px; 
    background: rgba(212, 160, 23, 0.9); 
    backdrop-filter: blur(4px); 
    color: white; 
    padding: 6px 14px; 
    border-radius: 0; /* Sin bordes redondeados */
    font-size: 0.65rem; 
    font-weight: 800; 
    z-index: 5; 
}

.album-title-box { 
    padding: 10px 15px; 
    text-align: center; 
}

.album-title-box h3 {
    font-size: 0.95rem;
    font-weight: 700;
    color: #1A2B3C;
    margin: 0;
}

.masonry-grid-v13 { 
    display: block !important; /* Masonry requiere block, no flex */
    column-count: 3 !important;
    column-gap: 25px !important;
    width: 100% !important;
    padding: 10px 0 !important;
}

.masonry-item {
    display: inline-block !important; /* Evita que el item se parta entre columnas */
    width: 100% !important;
    margin-bottom: 25px !important;
    break-inside: avoid !important;
    -webkit-column-break-inside: avoid !important;
    padding: 0 !important;
}

.masonry-item img {
    width: 100% !important;
    height: auto !important; /* CLAVE: permite alturas variables */
    display: block !important;
    border-radius: 0 !important;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    transition: transform 0.5s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.masonry-item:hover img {
    transform: scale(1.03);
    box-shadow: 0 20px 40px rgba(212, 160, 23, 0.2);
}

/* RESPONSIVE FLUIDO */
@media (max-width: 992px) {
    .masonry-grid-v13 { column-count: 2 !important; }
}
@media (max-width: 576px) {
    .masonry-grid-v13 { column-count: 1 !important; }
}

.galeria-masonry { background: #FDFBFA; }

/* AJUSTES RESPONSIVE */
@media (max-width: 992px) {
    .masonry-grid-v13 { column-count: 2; }
}

@media (max-width: 768px) {
    .hero-galeria-v13 { padding: 40px 15px 0px; }
    .hero-galeria-v13 h1 { font-size: 1.8rem; margin-bottom: 12px; }
    .section-galeria-v13-main { 
        padding-top: 0px !important; 
    }
}

@media (max-width: 576px) {
    .masonry-grid-v13 { column-count: 1; }
}
