/* ============================================
   ESTILOS PARA LA SECCIÓN DE OBRAS
   ============================================ */

/* Hero de Obras */
.hero-obras {
    position: relative;
    height: 400px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    text-align: center;
    overflow: hidden;
    margin-bottom: 3rem;
}

.hero-obras::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: 
        url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1200 600"><defs><pattern id="grid" width="50" height="50" patternUnits="userSpaceOnUse"><path d="M 50 0 L 0 0 0 50" fill="none" stroke="rgba(255,255,255,0.1)" stroke-width="1"/></pattern></defs><rect width="1200" height="600" fill="rgba(0,0,0,0.1)"/><rect width="1200" height="600" fill="url(%23grid)"/></svg>');
    animation: moveBackground 20s linear infinite;
}

@keyframes moveBackground {
    0% { transform: translateX(0); }
    100% { transform: translateX(50px); }
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.3);
}

.hero-content {
    position: relative;
    z-index: 2;
    animation: fadeInDown 0.8s ease-out;
}

.hero-title {
    font-size: clamp(2rem, 5vw, 3.5rem);
    font-weight: 700;
    margin-bottom: 1rem;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
    letter-spacing: 1px;
}

.hero-subtitle {
    font-size: clamp(1rem, 2vw, 1.3rem);
    font-weight: 300;
    margin: 0;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
    letter-spacing: 0.5px;
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Contenido principal */
.main-content {
    min-height: 100vh;
    padding-bottom: 3rem;
}

/* Sección de obra destacada */
.obra-destacada {
    background-color: #f8f9fa;
    padding: 2rem 0;
    border-bottom: 1px solid #e9ecef;
}

.titulo-obra {
    color: #1a1a1a;
    font-size: clamp(1.5rem, 3vw, 2.5rem);
    font-weight: 700;
    margin-bottom: 1.5rem;
    position: relative;
    padding-bottom: 1rem;
}

.titulo-obra::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 50px;
    height: 4px;
    background: linear-gradient(90deg, #667eea, #764ba2);
    border-radius: 2px;
}

.descripcion-obra {
    color: #495057;
    font-size: 1.05rem;
    line-height: 1.8;
    margin-bottom: 1.5rem;
    text-align: justify;
}

/* Info de la obra */
.info-obra {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    border-left: 4px solid #667eea;
    transition: all 0.3s ease;
}

.info-obra:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
    transform: translateY(-2px);
}

.info-item {
    font-size: 0.95rem;
    color: #495057;
    display: flex;
    align-items: flex-start;
}

.info-item i {
    min-width: 24px;
    margin-top: 2px;
}

/* Galería de obras */
.galeria-obras {
    margin-top: 3rem;
    padding-top: 2rem;
}

.galeria-obras h3 {
    color: #1a1a1a;
    font-weight: 700;
    font-size: 1.8rem;
    position: relative;
    padding-bottom: 1rem;
}

.galeria-obras h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 4px;
    background: linear-gradient(90deg, #667eea, #764ba2);
    border-radius: 2px;
}

/* Imágenes de obra */
.imagen-obra {
    position: relative;
    overflow: hidden;
    border-radius: 8px;
    cursor: pointer;
    aspect-ratio: 4/3;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.imagen-obra:hover {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
    transform: translateY(-5px);
}

.imagen-obra-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.imagen-obra:hover .imagen-obra-img {
    transform: scale(1.05);
}

.overlay-imagen {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(102, 126, 234, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.imagen-obra:hover .overlay-imagen {
    opacity: 1;
}

.overlay-imagen i {
    color: white;
    font-size: 2rem;
    animation: zoomIn 0.3s ease;
}

@keyframes zoomIn {
    from {
        transform: scale(0.8);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

/* Modal de imágenes */
.modal-content {
    background-color: #f8f9fa;
    border: none;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
}

.modal-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
}

.modal-header .btn-close {
    filter: brightness(0) invert(1);
}

.modal-title {
    font-weight: 700;
    font-size: 1.3rem;
}

.modal-body {
    padding: 2rem;
}

.modal-body img {
    max-height: 600px;
    object-fit: contain;
}

/* Responsividad */
@media (max-width: 768px) {
    .hero-obras {
        height: 250px;
    }

    .hero-title {
        font-size: 1.8rem;
    }

    .hero-subtitle {
        font-size: 0.95rem;
    }

    .titulo-obra {
        font-size: 1.3rem;
    }

    .descripcion-obra {
        font-size: 0.95rem;
    }

    .galeria-obras h3 {
        font-size: 1.4rem;
    }

    .imagen-obra {
        aspect-ratio: 16/9;
    }

    .info-obra {
        margin-top: 2rem;
    }
}

@media (max-width: 576px) {
    .hero-obras {
        height: 200px;
        margin-bottom: 2rem;
    }

    .hero-title {
        font-size: 1.5rem;
    }

    .titulo-obra {
        font-size: 1.1rem;
    }

    .galeria-obras {
        margin-top: 2rem;
    }

    .galeria-obras h3 {
        font-size: 1.2rem;
    }
}

/* Animaciones adicionales */
@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.obra-destacada {
    animation: slideInUp 0.6s ease-out 0.2s both;
}

/* Transiciones suaves */
* {
    transition: background-color 0.3s ease, color 0.3s ease;
}
