:root {
    --primary-dark: #050A18;
    --accent-blue: #00A8E8;
    --shield-blue: #003366;
    --text-grey: #e0e0e0;
    --white: #ffffff;
}

* { margin: 0; padding: 0; box-sizing: border-box; font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif; }

body { 
    background-color: var(--primary-dark); 
    color: var(--text-grey); 
    line-height: 1.6;
    /* Aplicamos la imagen de fondo del logo */
    background-image: 
        linear-gradient(rgba(5, 10, 24, 0.85), rgba(5, 10, 24, 0.85)), 
        url('logo.png'); 
    background-size: cover;
    background-position: center;
    background-attachment: fixed; /* Esto crea el efecto de profundidad al hacer scroll */
    background-repeat: no-repeat;
}

/* Ajuste para que las secciones no tapen el fondo general si tienen colores sólidos */
section { 
    padding: 80px 10%; 
    background-color: transparent !important; 
}

.bg-alt { 
    /* En lugar de un color sólido, usamos una transparencia ligera para diferenciar secciones */
    /*background-color: rgba(11, 20, 38, 0.6) !important */
    backdrop-filter: blur(2px); /* Opcional: añade un desenfoque elegante */
}

/* HEADER & NAV */
header { background: rgba(5, 10, 24, 0.95); padding: 1rem 5%; position: fixed; width: 100%; top: 0; z-index: 1000; border-bottom: 1px solid var(--shield-blue); display: flex; justify-content: space-between; align-items: center; }
.logo-container { display: flex; align-items: center; gap: 10px; }
.logo-img { height: 50px; }
.logo-text { font-weight: bold; color: white; font-size: 1.2rem; }
.nav-links a { color: var(--white); text-decoration: none; margin-left: 20px; font-weight: 500; transition: 0.3s; }
.nav-links a:hover { color: var(--accent-blue); }

/* HERO SECTION */
.hero { 
    height: 100vh; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    text-align: center; 
    padding: 0 20px; 
    background: transparent; /* Quitamos el degradado duplicado */
    margin-top: 60px; 
}
.hero-content h1 { font-size: 3rem; color: var(--white); margin-bottom: 1rem; text-transform: uppercase; letter-spacing: 2px; }
.hero-content span { color: var(--accent-blue); }
.hero-content p { font-size: 1.2rem; max-width: 800px; margin: 0 auto 2rem auto; }
.btn { background: var(--accent-blue); color: var(--primary-dark); padding: 10px 30px; text-decoration: none; font-weight: bold; border-radius: 5px; transition: 0.3s; }
.btn:hover { background: var(--white); }

/* SECCIONES GENERALES */
section { padding: 80px 10%; }
.bg-alt { background-color: #0b1426; }
h2 { color: var(--white); font-size: 2.5rem; margin-bottom: 40px; border-left: 5px solid var(--accent-blue); padding-left: 15px; }

/* SERVICIOS */
.services-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 30px; }
.service-card { background: #0b1426; padding: 30px; border: 1px solid var(--shield-blue); border-radius: 8px; transition: 0.3s; }
.service-card:hover { transform: translateY(-5px); border-color: var(--accent-blue); box-shadow: 0 0 15px rgba(0, 168, 232, 0.2); }
.service-card h3 { color: var(--accent-blue); margin-bottom: 15px; }

/* PERFIL */
.about-container { display: flex; flex-wrap: wrap; gap: 40px; align-items: center; }
.about-text strong { color: var(--accent-blue); }
.spacer { margin-bottom: 20px; }

/* PORTFOLIO */
.portfolio-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 20px; }
.project-card { background: #1c2536; padding: 20px; border-radius: 5px; }
.project-desc { font-size: 0.9rem; margin-top: 10px; }
.tag { background: var(--shield-blue); color: var(--white); padding: 2px 8px; font-size: 0.8rem; border-radius: 4px; }

/* FOOTER */
footer { background: #02040a; text-align: center; padding: 20px; border-top: 1px solid var(--shield-blue); margin-top: 50px; }
.footer-note { font-size: 0.8rem; color: #666; margin-top: 20px; }

/* UTILIDADES */
.text-accent { color: var(--accent-blue); }

/* RESPONSIVE */
@media (max-width: 768px) {
    .hero-content h1 { font-size: 2rem; }
    header { flex-direction: column; }
    .nav-links { margin-top: 10px; }
}

/* MEJORAS EN TARJETAS DE SERVICIO */
.service-tag {
    background: var(--shield-blue);
    color: var(--accent-blue);
    font-size: 0.7rem;
    font-weight: bold;
    text-transform: uppercase;
    display: inline-block;
    padding: 2px 10px;
    border-radius: 20px;
    margin-bottom: 15px;
    border: 1px solid var(--accent-blue);
}

.service-card {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
}

.service-card.highlight {
    border: 1px solid var(--accent-blue);
    background: linear-gradient(145deg, #0b1426, #050a18);
}

.service-features {
    list-style: none;
    margin: 20px 0;
    padding: 0;
    font-size: 0.9rem;
}

.service-features li {
    margin-bottom: 8px;
    padding-left: 5px;
    border-left: 2px solid var(--shield-blue);
}

.service-bonus {
    margin-top: auto;
    font-size: 0.85rem;
    color: var(--white);
    background: rgba(0, 168, 232, 0.1);
    padding: 10px;
    border-radius: 4px;
    border-left: 3px solid #00ff88; /* Verde éxito para el bono */
}

/* RESPONSIVE AJUSTE */
.services-grid {
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
}

/* NUEVOS ESTILOS PARA MODALES Y BLOG */
.btn-sm {
    background: transparent;
    border: 1px solid var(--accent-blue);
    color: var(--accent-blue);
    padding: 8px 15px;
    border-radius: 4px;
    cursor: pointer;
    margin-top: 15px;
    transition: 0.3s;
}

.btn-sm:hover {
    background: var(--accent-blue);
    color: var(--primary-dark);
}

.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(5, 10, 24, 0.9);
    backdrop-filter: blur(5px);
}

.modal-content {
    background-color: #0b1426;
    margin: 5% auto;
    padding: 40px;
    border: 1px solid var(--accent-blue);
    width: 80%;
    max-width: 800px;
    border-radius: 15px;
    max-height: 80vh;
    overflow-y: auto;
    position: relative;
}

.close {
    position: absolute;
    right: 20px;
    top: 10px;
    color: var(--white);
    font-size: 30px;
    cursor: pointer;
}

.blog-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
    font-size: 0.9rem;
}

.blog-table th, .blog-table td {
    border: 1px solid var(--shield-blue);
    padding: 12px;
    text-align: left;
}

.blog-table th {
    background: rgba(0, 168, 232, 0.1);
    color: var(--accent-blue);
}

/* Estilo específico para la cabecera de secciones */
.section-header {
    margin-bottom: 50px;
    text-align: left;
}

.section-header h2 {
    margin-bottom: 10px; /* Ajuste para que el párrafo quede cerca del título */
}

.section-header p {
    color: var(--accent-blue);
    font-weight: 500;
    text-transform: uppercase;
    font-size: 0.9rem;
    letter-spacing: 1px;
}
/* --- BUSCA O REEMPLAZA ESTE BLOQUE EN TU estilos.css --- */

.close {
    position: absolute;
    right: 20px;
    top: 10px;
    color: var(--white);
    font-size: 30px;
    cursor: pointer; /* Indica visualmente que es un botón */
    transition: color 0.3s ease; /* Suaviza el cambio de color */
}

.close:hover {
    color: var(--accent-blue); /* Cambia al azul corporativo al pasar el mouse */
}