/* ==========================================================================
   HERO EXCLUSIVO E INDEPENDIENTE PARA PROYECTOS (PROYECTOS.CSS)
   ========================================================================== */
/* ==========================================================================
   ESTILOS HERO PROYECTOS (IMAGEN HTML REAL Y NITIDEZ MÁXIMA)
   ========================================================================== */
.proj-hero-section {
    position: relative;
    padding: 140px 0 45px 0;
    color: #ffffff;
    overflow: hidden;
    width: 100%;
}

.proj-hero-bg-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    pointer-events: none;
}

.proj-hero-bg-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center center;
}

.proj-hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, rgba(5, 19, 41, 0.9) 0%, rgba(5, 19, 41, 0.4) 30%, rgba(5, 19, 41, 0.05) 70%);
    z-index: 2;
}

.proj-hero-section .container {
    position: relative;
    z-index: 3;
}

.proj-hero-content {
    max-width: 700px;
    margin-bottom: 30px;
}

.proj-hero-tagline {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 8px;
}

.proj-hero-tagline .proj-gold-line {
    display: block;
    width: 35px;
    height: 3px;
    background-color: #ffc107;
}

.proj-hero-tagline .proj-tag-text {
    font-size: 0.82rem;
    font-weight: 800;
    letter-spacing: 1.5px;
    color: #ffc107;
}

.proj-hero-title {
    font-size: 2.6rem;
    font-weight: 900;
    line-height: 1.15;
    margin: 12px 0;
    letter-spacing: -0.5px;
    color: #ffffff;
}

.proj-hero-title .proj-text-gold {
    color: #ffc107;
}

.proj-hero-desc {
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.85);
    line-height: 1.5;
}

/* Grilla de Stats: Por defecto 4 columnas en Escritorio */
.proj-stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 15px;
    padding-top: 25px;
    border-top: 1px solid rgba(255, 255, 255, 0.15);
}

.proj-stat-item {
    display: flex;
    align-items: center;
    gap: 12px;
    background: rgba(255, 255, 255, 0.03);
    padding: 10px;
    border-radius: 8px;
}

.proj-stat-icon {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    background: linear-gradient(90deg, rgba(5, 19, 41, 0.92) 0%, rgba(5, 19, 41, 0.5) 60%, rgba(5, 19, 41, 0.2) 100%);
    border: 1px solid rgba(255, 193, 7, 0.3);
    color: #ffc107;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    flex-shrink: 0;
}

.proj-stat-info {
    display: flex;
    flex-direction: column;
}

.proj-stat-number {
    font-size: 1.1rem;
    font-weight: 900;
    color: #ffffff;
    line-height: 1.2;
}

.proj-stat-text {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.75);
    white-space: nowrap;
}

/* ==========================================================================
   ADAPTACIÓN RESPONSIVE: 2 COLUMNAS EXACTAS (SIN !IMPORTANT)
   ========================================================================== */
@media (max-width: 992px) {
    .proj-stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
}

@media (max-width: 576px) {
    .proj-stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .proj-hero-title {
        font-size: 2rem;
    }

    .proj-stat-item {
        padding: 8px;
        gap: 8px;
    }

    .proj-stat-icon {
        width: 34px;
        height: 34px;
        font-size: 0.85rem;
    }

    .proj-stat-number {
        font-size: 0.9rem;
    }

    .proj-stat-text {
        font-size: 0.65rem;
        white-space: normal;
        line-height: 1.1;
    }
}

/* Catálogo y Grid de Proyectos */
.proyectos-catalog {
    padding: 60px 0;
}

.proyectos-grid-wrapper {
    display: flex;
    flex-direction: column;
}

.proyectos-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 25px;
    margin-bottom: 40px;
}

.proyecto-card {
    background-color: var(--white, #ffffff);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(3, 18, 41, 0.06);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    width: calc((100% - 50px) / 3);
    max-width: 360px;
    flex-grow: 0;
    flex-shrink: 0;
    border: 1px solid rgba(3, 18, 41, 0.06);
}

.proyecto-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 12px 30px rgba(3, 18, 41, 0.12);
}

.proyecto-img-box {
    position: relative;
    height: 210px;
    overflow: hidden;
    background-color: #031229;
}

.proyecto-img-box img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.proyecto-card:hover .proyecto-img-box img {
    transform: scale(1.06);
}

/* Badge de categoría superpuesto en la esquina superior izquierda de la imagen */
.proyecto-category-badge {
    position: absolute;
    top: 15px;
    left: 15px;
    background-color: var(--navy-blue, #031229);
    color: var(--primary-yellow, #ffc107);
    font-size: 0.7rem;
    font-weight: 800;
    text-transform: uppercase;
    padding: 5px 10px;
    border-radius: 4px;
    letter-spacing: 0.5px;
    z-index: 2;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 193, 7, 0.3);
}

.proyecto-info {
    padding: 22px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.proyecto-info h3 {
    font-size: 1.05rem;
    font-weight: 800;
    color: var(--navy-blue, #031229);
    margin-bottom: 10px;
    line-height: 1.35;
}

/* Fila de metadatos (Fecha y Ubicación) estilo referencia */
.proyecto-meta-row {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 12px;
    font-size: 0.76rem;
    color: #666666;
    font-weight: 600;
}

.proyecto-meta-item {
    display: flex;
    align-items: center;
    gap: 5px;
}

.proyecto-meta-item i {
    color: var(--primary-yellow, #ffc107);
}

.proyecto-desc {
    font-size: 0.82rem;
    color: #555555;
    margin-bottom: 16px;
    line-height: 1.5;
    flex-grow: 1;
}

/* Sub-grilla interna de estadísticas (2 columnas sin duración) */
.proyecto-stats-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
    background-color: #f8f9fa;
    padding: 10px;
    border-radius: 6px;
    margin-bottom: 18px;
    border: 1px solid #eaeaea;
}

.proyecto-stat-box {
    display: flex;
    align-items: center;
    gap: 8px;
}

.proyecto-stat-box i {
    font-size: 0.95rem;
    color: var(--navy-blue, #031229);
    width: 20px;
    text-align: center;
}

.proyecto-stat-box div {
    display: flex;
    flex-direction: column;
}

.p-stat-val {
    font-size: 0.78rem;
    font-weight: 800;
    color: var(--navy-blue, #031229);
    line-height: 1.2;
}

.p-stat-lbl {
    font-size: 0.65rem;
    color: #777777;
    white-space: nowrap;
}

/* Enlace inferior de la tarjeta ("Ver proyecto completo") */
.proyecto-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 0.8rem;
    font-weight: 800;
    color: var(--navy-blue, #031229);
    text-decoration: none;
    transition: color 0.3s ease;
    margin-top: auto;
    padding-top: 5px;
}

.proyecto-link i {
    font-size: 0.75rem;
    color: var(--primary-yellow, #ffc107);
    transition: transform 0.3s ease;
}

.proyecto-link:hover {
    color: var(--primary-yellow, #ffc107);
}

.proyecto-link:hover i {
    transform: translateX(4px);
}

/* ==========================================================================
   ADAPTACIÓN RESPONSIVE (PROYECTOS.CSS - 1 COLUMNA ANCHA Y ESPACIOSA EN MÓVIL)
   ========================================================================== */
@media (max-width: 1200px) {
    .proyecto-card {
        width: calc((100% - 15px) / 2);
        max-width: none;
    }
}

@media (max-width: 992px) {
    .proyecto-card {
        width: calc((100% - 15px) / 2);
        max-width: none;
    }
}

/* En móviles: 1 sola columna maximizando el ancho horizontal y optimizando el contenido */
@media (max-width: 576px) {
    .proyectos-grid {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 15px;
        padding: 0 4px;
    }

    .proyecto-card {
        width: 100% !important;
        max-width: 100% !important;
        margin-bottom: 0;
    }

    .proyecto-card * {
        box-sizing: border-box;
        max-width: 100%;
    }

    .proyecto-info {
        padding: 16px 14px;
    }

    .proyecto-info h3 {
        font-size: 1rem;
        line-height: 1.3;
        word-break: break-word;
        overflow-wrap: break-word;
    }

    .proyecto-desc, 
    .proyecto-spec {
        font-size: 0.82rem;
        line-height: 1.4;
    }

    .equipos-bottom-cta {
        flex-direction: column;
        text-align: center;
    }

    .equipos-bottom-cta .btn {
        width: 100%;
    }
}

/* ==========================================================================
   DISEÑO MEJORADO PARA EL BANNER CTA INFERIOR (PROYECTOS.CSS)
   ========================================================================== */
.equipos-bottom-cta {
    background: linear-gradient(135deg, var(--navy-blue, #031229) 0%, #0d2347 100%);
    border: 1px solid rgba(255, 193, 7, 0.25);
    border-radius: 12px;
    padding: 30px 40px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 30px;
    box-shadow: 0 10px 30px rgba(3, 18, 41, 0.15);
    position: relative;
    overflow: hidden;
    margin-top: 20px;
}

.equipos-bottom-cta::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background-color: var(--primary-yellow, #ffc107);
}

.cta-content-wrapper {
    display: flex;
    align-items: center;
    gap: 20px;
}

.cta-icon-box {
    width: 55px;
    height: 55px;
    border-radius: 10px;
    background: rgba(255, 193, 7, 0.1);
    border: 1px solid rgba(255, 193, 7, 0.3);
    color: var(--primary-yellow, #ffc107);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    flex-shrink: 0;
}

.cta-text-box {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.cta-title {
    font-size: 1.15rem;
    font-weight: 800;
    color: var(--white, #ffffff);
    letter-spacing: -0.3px;
}

.cta-desc {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.4;
}

.equipos-bottom-cta .btn-navy {
    background-color: var(--primary-yellow, #ffc107);
    color: var(--navy-blue, #031229);
    border: none;
    font-weight: 800;
    padding: 14px 28px;
    border-radius: 8px;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    transition: all 0.3s ease;
    white-space: nowrap;
    box-shadow: 0 4px 15px rgba(255, 193, 7, 0.3);
}

.equipos-bottom-cta .btn-navy:hover {
    background-color: #e0a800;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 193, 7, 0.4);
}

.equipos-bottom-cta .btn-navy i {
    transition: transform 0.3s ease;
}

.equipos-bottom-cta .btn-navy:hover i {
    transform: translateX(4px);
}

/* Adaptación Responsive para el Banner CTA */
@media (max-width: 992px) {
    .equipos-bottom-cta {
        flex-direction: column;
        align-items: flex-start;
        padding: 25px 20px;
        gap: 20px;
    }

    .equipos-bottom-cta .btn-navy {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 576px) {
    .cta-content-wrapper {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
}

/* ==========================================================================
    ESTILOS DEL MODAL DE PROYECTOS (PROYECTOS.CSS)
    ========================================================================== */
.proyecto-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.75);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    backdrop-filter: blur(5px);
}

.proyecto-modal-overlay.activo {
    opacity: 1;
    visibility: visible;
}

.proyecto-modal-container {
    background-color: var(--white, #ffffff);
    width: 90%;
    max-width: 800px;
    max-height: 90vh;
    overflow-y: auto;
    border-radius: 12px;
    padding: 30px;
    position: relative;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
    transform: translateY(20px);
    transition: transform 0.3s ease;
}

.proyecto-modal-overlay.activo .proyecto-modal-container {
    transform: translateY(0);
}

.proyecto-modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: transparent;
    border: none;
    font-size: 2rem;
    line-height: 1;
    cursor: pointer;
    color: #333;
    transition: color 0.2s ease;
}

.proyecto-modal-close:hover {
    color: #000;
}

.proyecto-modal-content {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.proyecto-modal-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #111;
    margin: 0;
}

.proyecto-modal-desc {
    font-size: 0.95rem;
    line-height: 1.6;
    color: #555;
}

.proyecto-modal-specs {
    font-size: 0.88rem;
    font-weight: 600;
    color: #222;
    background-color: #f8f9fa;
    padding: 10px 15px;
    border-radius: 6px;
    border-left: 4px solid var(--gold, #d4af37);
}

/* Galería optimizada para escritorio (Grid limpio de 3 columnas) */
.proyecto-modal-gallery {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin-top: 15px;
}

.modal-img-item {
    border-radius: 8px;
    overflow: hidden;
    height: 150px;
    background-color: #eee;
}

.modal-img-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}

.modal-img-item img:hover {
    transform: scale(1.05);
}

/* Versión Slider Nativo optimizada para Tablets y Móviles */
@media (max-width: 768px) {
    .proyecto-modal-container {
        padding: 20px;
        width: 95%;
    }

    .proyecto-modal-gallery {
        display: flex;
        grid-template-columns: none;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        gap: 12px;
        padding-bottom: 12px;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: thin;
        scrollbar-color: var(--gold, #d4af37) transparent;
        scroll-padding-left: 0px;
    }

    .proyecto-modal-gallery::-webkit-scrollbar {
        height: 4px;
    }

    .proyecto-modal-gallery::-webkit-scrollbar-thumb {
        background: var(--gold, #d4af37);
        border-radius: 4px;
    }

    .modal-img-item {
        flex: 0 0 85%;
        scroll-snap-align: center;
        height: 210px;
        aspect-ratio: 16 / 10;
        box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    }

    .proyecto-modal-title {
        font-size: 1.25rem;
    }
}