/* =========================================
   VARIABLES Y CONFIGURACIÓN BASE
   ========================================= */
:root {
    --petroleo: #1a3a3a;
    --naranja: #f08233;
    --blanco: #ffffff;
    --gris: #f8f9fa;
}

* { 
    margin: 0; 
    padding: 0; 
    box-sizing: border-box; 
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif; 
}

html { 
    scroll-behavior: smooth; 
}

body { 
    background: var(--blanco); 
    color: #333;
    line-height: 1.6;
}

/* =========================================
   NAVEGACIÓN (HEADER)
   ========================================= */
header {
    background: white; 
    padding: 12px 5%; 
    position: fixed; 
    width: 100%; 
    top: 0; 
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.navbar { 
    display: flex; 
    justify-content: space-between; 
    align-items: center; 
}

.header-logos { 
    display: flex; 
    gap: 20px; 
    align-items: center; 
}

.logo-nav { 
    height: 45px; 
    width: auto; 
    max-width: 150px; 
    object-fit: contain; 
}

.nav-links { 
    display: flex; 
    list-style: none; 
}

.nav-links a { 
    text-decoration: none; 
    color: var(--petroleo); 
    margin-left: 25px; 
    font-weight: 600; 
    font-size: 0.9rem;
    transition: 0.3s;
}

.nav-links a:hover {
    color: var(--naranja);
}

.btn-mail { 
    background: var(--naranja); 
    color: white !important; 
    padding: 8px 18px; 
    border-radius: 5px; 
}

/* =========================================
   ANIMACIÓN CENTRAL (SOLO LOGO ELEGANTE)
   ========================================= */
.hero-animation { 
    height: 20vh; 
    display: flex; 
    justify-content: center; 
    align-items: center; 
    padding-top: 60px; 
}

.quantum-zone { 
    position: relative; 
    width: 300px; 
    height: 300px; 
    display: flex; 
    justify-content: center; 
    align-items: center; 
}

.floating-logo { 
    width: 110px; /* Un poco más grande al no haber anillo */
    z-index: 2; 
    /* Movimiento fluido: Flotación + Cambio de Brillo */
    animation: elegantFloat 5s ease-in-out infinite;
    filter: drop-shadow(0 5px 15px rgba(0,0,0,0.1));
}

/* Eliminamos la clase .core-orbit del CSS ya que no la queremos */
.core-orbit {
    display: none;
}

@keyframes elegantFloat {
    0% {
        transform: translateY(0) rotate(0deg);
        filter: drop-shadow(0 5px 15px rgba(0,0,0,0.1)) brightness(1);
    }
    33% {
        transform: translateY(-15px) rotate(2deg);
        filter: drop-shadow(0 20px 25px rgba(240, 130, 51, 0.2)) brightness(1.1);
    }
    66% {
        transform: translateY(5px) rotate(-2deg);
        filter: drop-shadow(0 5px 15px rgba(0,0,0,0.1)) brightness(1);
    }
    100% {
        transform: translateY(0) rotate(0deg);
        filter: drop-shadow(0 5px 15px rgba(0,0,0,0.1)) brightness(1);
    }
}

/* =========================================
   IMAGEN HERO
   ========================================= */
.hero-image { 
    height: 550px; 
    background: url('PortadaInGenias.jpg') center/cover; 
}

.overlay { 
    background: rgba(26, 58, 58, 0.75); 
    height: 100%; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    color: white; 
    text-align: center;
}

.overlay h1 {
    font-size: 2.5rem;
    letter-spacing: 1px;
}

/* =========================================
   GRID DE PROYECTOS (CARDS)
   ========================================= */
.projects-section { 
    padding: 80px 8%; 
    background: var(--gris); 
}

.title { 
    text-align: center; 
    margin-bottom: 50px; 
    color: var(--petroleo); 
    font-size: 2.2rem; 
}

.grid { 
    display: grid; 
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); 
    gap: 35px; 
}

.card { 
    background: white; 
    border-radius: 15px; 
    overflow: hidden; 
    box-shadow: 0 10px 25px rgba(0,0,0,0.05); 
    transition: transform 0.3s;
}

.card:hover {
    transform: translateY(-8px);
}

.card-bg { 
    height: 180px; 
    background-size: cover; 
    background-position: center; 
}

.card-body { 
    padding: 25px; 
    text-align: center; 
}

.card-body h3 { 
    color: var(--petroleo); 
    margin-bottom: 15px; 
    font-size: 1.4rem;
}

.project-links { 
    display: flex; 
    flex-direction: column; 
    gap: 12px; 
    margin-top: 20px; 
}

.open-modal { 
    color: var(--naranja); 
    text-decoration: none; 
    font-weight: bold; 
    border: 2px solid var(--naranja); 
    padding: 10px; 
    border-radius: 8px; 
    transition: 0.3s; 
    font-size: 0.85rem;
}

.open-modal:hover { 
    background: var(--naranja); 
    color: white; 
}

/* =========================================
   MODALES Y GALERÍAS
   ========================================= */
.modal {
    position: fixed; 
    top: 0; 
    left: 0; 
    width: 100%; 
    height: 100%;
    background: rgba(0,0,0,0.92); 
    display: none; 
    justify-content: center; 
    align-items: center; 
    z-index: 2000;
}

.modal:target { 
    display: flex; 
}

.modal-content {
    background: white; 
    padding: 40px; 
    border-radius: 20px; 
    max-width: 950px; 
    width: 95%;
    max-height: 90vh; 
    overflow-y: auto; 
    position: relative;
}

.close { 
    position: absolute; 
    top: 20px; 
    right: 30px; 
    font-size: 40px; 
    text-decoration: none; 
    color: #333; 
    line-height: 1;
}

.instruction-text { 
    text-align: center; 
    color: #888; 
    font-size: 0.85rem; 
    margin-bottom: 20px; 
}

.gallery-grid {
    display: grid; 
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px; 
    margin-bottom: 30px;
}

.gallery-8 { 
    grid-template-columns: repeat(4, 1fr); 
}

.img-container {
    position: relative; 
    display: block; 
    overflow: hidden; 
    border-radius: 10px; 
    height: 160px;
    background: #eee;
}

.img-container img { 
    width: 100%; 
    height: 100%; 
    object-fit: cover; 
    transition: 0.5s ease; 
}

.img-overlay {
    position: absolute; 
    top: 0; 
    left: 0; 
    width: 100%; 
    height: 100%;
    background: rgba(240, 130, 51, 0.7);
    display: flex; 
    align-items: center; 
    justify-content: center;
    opacity: 0; 
    transition: 0.3s; 
    color: white; 
    font-size: 1.8rem;
}

.img-container:hover .img-overlay { 
    opacity: 1; 
}

.img-container:hover img { 
    transform: scale(1.15); 
}

.description { 
    line-height: 1.8; 
    color: #444; 
    text-align: center; 
    max-width: 700px;
    margin: 0 auto;
}

/* =========================================
   CONTACTO Y FOOTER
   ========================================= */
.contact-bar { 
    padding: 60px 5%; 
    text-align: center; 
    background: var(--petroleo); 
}

.contact-bar a { 
    color: var(--naranja); 
    text-decoration: none; 
    font-size: 1.6rem; 
    font-weight: bold; 
    transition: 0.3s;
}

.contact-bar a:hover {
    color: white;
}


.modal-footer .boton-tecnologico {
    display: inline-block;
    padding: 12px 25px;
    background-color: #1a1a2e; /* Fondo oscuro para resaltar */
    color: #00ffff;           /* Texto neón */
    border: 2px solid #00ffff;
    border-radius: 8px;
    text-decoration: none;
    font-weight: bold;
    transition: 0.3s;
}

.modal-footer .boton-tecnologico:hover {
    background-color: #00ffff;
    color: #1a1a2e;
    box-shadow: 0 0 15px rgba(0, 255, 255, 0.6);
}