/* Estilos generales */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    scroll-behavior: smooth;
}

body {
    font-family: 'Poppins', sans-serif;
    background: linear-gradient(135deg, #eef2f3, #d1d8e0);
    color: #333;
}

/* Contenedor principal */
.container {
    display: flex;
    min-height: 100vh;
}

/* Sidebar */
.sidebar {
    position: fixed;
    top: 0;
    left: 0;
    margin-top: 60px;
    width: 260px;
    height: 100%;
    background: #e7e0e0;
    color: #ffffffa2;
    padding: 20px;
    box-shadow: 3px 0 10px rgba(0, 0, 0, 0.2);
    transition: transform 0.8s ease-in-out;
     overflow-y: auto;
}

/* Botón de menú móvil */
.menu-btn {
    display: none;
    position: fixed;
    top: 20px;
    left: 20px;
    background: #007bff;
    color: white;
    border: none;
    padding: 12px;
    border-radius: 50%;
    cursor: pointer;
    z-index: 100;
    transition: 0.3s;
}

.menu-btn:hover {
    background: #0056b3;
}

/* Estilo del contenedor principal */
.proyecto-container {
    flex: 1;
    max-width: 1200px;
    margin-left: 350px;
    padding: 30px;
    background: #fff;
    border-radius: 12px;
    opacity: 0;
    transform: translateY(320px);
    animation: fadeInUp 2s ease-out forwards;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
    transition: margin-left 0.3s ease-in-out;
}

/* Estilos del header */
.proyecto-header {
    text-align: center;
    margin-bottom: 20px;
    animation: fadeInDown 1s ease-in-out;
}

.proyecto-header h1 {
  font-size: 2.2em;
  margin-top: 50px; /* 👈 Aumentar margen superior */
  color: #007bff;
  text-transform: uppercase;
  font-weight: bold;
}

.proyecto-fecha {
    color: #777;
    margin-top: 10px;
    font-size: 1.3em;
}

/* Imagen destacada */
.proyecto-imagen-destacada img {
    width: 100%;
    height: auto;
    max-height: 450px;
    object-fit: cover;
    border-radius: 12px;
    margin-bottom: 30px;
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp 1.5s ease-in-out forwards;
    animation-delay: 0.5s;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    transition: transform 0.7s ease-in-out;
    
    /* Efecto de desvanecimiento a negro desde abajo */
    -webkit-mask-image: linear-gradient(to top, #000 30%, rgba(0, 0, 0, 0.633) 85%);
    mask-image: linear-gradient(to top, #000 40%, rgba(0, 0, 0, 0) 95%);
}


/* Bloques de contenido */
.proyecto-bloque {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 40px;
    gap: 25px;
    opacity: 0;
    transform: translateY(200px);
    animation: fadeInUp 2s ease-in-out forwards;
}
.proyecto-bloque:nth-child(1) { animation-delay: 0.9s; }
.proyecto-bloque:nth-child(2) { animation-delay: 0.9s; }
.proyecto-bloque:nth-child(3) { animation-delay: 1.2s; }
.proyecto-bloque:nth-child(4) { animation-delay: 1.4s; }

.proyecto-texto {
    flex: 1;
    font-size: 1em;
    line-height: 1.7;
    padding: 25px;
    border-radius: 12px;
    transition: transform 0.8s ease-in-out;
}


.proyecto-imagen {
    flex: 1;
    text-align: center;
}

.proyecto-imagen img {
    width: 100%;
    height: auto;
    border-radius: 12px;
    transition: transform 0.8s ease-in-out, box-shadow 0.3s ease;
}

.proyecto-imagen img:hover {
    transform: scale(1.02);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

/* Invertir orden */
.inverso {
    flex-direction: row-reverse;
}

/* Bloque full-width */
.proyecto-bloque-full {
    margin-bottom: 40px;
    opacity: 0;
    transform: translateY(120px);
    animation: fadeInUp 1.2s ease-in-out forwards;
}

.proyecto-bloque-full p {
    font-size: 1.1em;
    line-height: 1.9;
    text-align: justify;
    padding: 25px;
    border-radius: 12px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
}

/* Imagen final */
.proyecto-imagen-final img {
    width: 100%;
    height: auto;
    border-radius: 12px;
    margin-top: 40px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

/* Botones */
.proyecto-botones {
    display: flex;
    justify-content: center;
    gap: 25px;
    margin-top: 50px;
}

.btn-pdf, .btn-ubicacion {
    background: linear-gradient(135deg, #007bff, #0056b3);
    color: #fff;
    padding: 14px 24px;
    text-decoration: none;
    border-radius: 8px;
    font-size: 1.1em;
    font-weight: bold;
    transition: background 0.3s ease, transform 0.2s ease;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.btn-pdf:hover, .btn-ubicacion:hover {
    background: linear-gradient(135deg, #0056b3, #003d82);
    transform: scale(1.07);
}

/* Animaciones */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(120px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive */
@media (max-width: 1024px) {
    .proyecto-container {
        margin-left: 260px;
    }
}

@media (max-width: 768px) {
    .container {
        flex-direction: column;
    }

    .sidebar {
        transform: translateX(-100%);
        width: 230px;
    }

    .menu-btn {
        display: block;
    }

    .sidebar.active {
        transform: translateX(0);
    }

    .proyecto-container {
        margin-left: 0;
        padding: 20px;
    }

    .proyecto-bloque {
        flex-direction: column;
        text-align: center;
    }

    .inverso {
        flex-direction: column;
    }
}




/**SIIDE BAR SIDE BAR/


/* Sidebar - Más Proyectos Destacados */
.sidebar {
    width: 300px;
    background: #f8f9fa;
    padding: 15px;
    border-radius: 10px;
    box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.1);
}

.sidebar h3 {
    text-align: center;
    font-size: 20px;
    margin-bottom: 10px;
    color: #333;
}

#sidebarProyectos {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

/* Estilos para cada card */
.sidebar-card {
    background: white;
    border-radius: 8px;
    padding: 10px;
    box-shadow: 0px 2px 5px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s ease-in-out;
    text-align: center;
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp 0.8s ease-out forwards;
}
.sidebar-card:nth-child(1) { animation-delay: 0.2s; }
.sidebar-card:nth-child(2) { animation-delay: 0.4s; }
.sidebar-card:nth-child(3) { animation-delay: 0.6s; }
.sidebar-card:nth-child(4) { animation-delay: 0.8s; }
.sidebar-card:nth-child(5) { animation-delay: 1s; }

/* Para el título del sidebar */
.sidebar h3 {
    text-align: center;
    font-size: 20px;
    margin-bottom: 10px;
    color: #333;

    /* Animación */
    opacity: 0;
    transform: translateY(-20px);
    animation: fadeInUp 1s ease-out forwards;
    animation-delay: 0.1s;
}


.sidebar-card:hover {
    transform: translateY(-5px);
}

.sidebar-img {
    width: 100%;
    height: 150px;
    object-fit: cover;
    border-radius: 8px;
}
.sidebar-img:hover{
    transform: scale(1.05);
    transition: all 0.3s ease-in-out;
}
.sidebar-card h4 {
    font-size: 16px;
    margin: 8px 0;
    color: #444;
}

.btn-ver {
    display: inline-block;
    padding: 8px 12px;
    margin-top: 5px;
    background-color: #007bff;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    font-size: 14px;
    transition: background 0.3s;
}

.btn-ver:hover {
    background-color: #0056b3;
}

    /**DETALLES DE CARDGADO*/ 
  /**DETALLES DE CARDGADO*/ 
  /**DETALLES DE CARDGADO*/ 
/* Estilo para el loader */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}