/*
 * PALETA DE COLORES:
 * Púrpura Fuerte (CTA): #5328E9 
 * Morado Secundario (Hover/Brillo): #9360FF 
 * Violeta Neutro (Texto General): #785A9D 
 * Azul Oscuro (Fondo de Tarjeta): #386B87 
 * Gris Oscuro (Líneas/Bordes): #2C3046 
 * Fondo Principal: #000000 (Negro Absoluto)
 */

/* 1. VARIABLES Y RESET BÁSICO */
:root {
    --primary-accent: #5328E9;
    --secondary-accent: #9360FF;
    --text-color: #8ab4f8;
    --card-bg: #386B87;
    --metal-dark: #1E2429;
    --metal-medium: #2C3238;
    --metal-light: #384047;
    --main-bg: var(--metal-dark); /* El fondo general será el más oscuro */
    --light-text: #EAEAEA; 
    --divider-color: rgba(83, 40, 233, 0.3); /* Asegura que el color sea consistente */
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background: linear-gradient(145deg, #2c3238 10%, #1e2429 50%, #384047 90%);
    color: var(--text-color);
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    background: linear-gradient(145deg, var(--metal-medium) 10%, var(--metal-dark) 50%, var(--metal-light) 90%);
    background-size: 400% 400%; /* Habilita el estiramiento para la animación */
    animation: gradientMove 25s ease infinite; /* Aplica la animación */
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    background: radial-gradient(circle at 50% 60%, rgba(64,145,255,0.15), transparent 70%);
    mix-blend-mode: overlay;
    z-index: -10;
}

body::after {
    content: "";
    position: fixed; /* 'fixed' para que la textura no se mueva con el scroll */
    inset: 0;
    /* Patrón de líneas cruzadas sutiles (simulación de textura Forerunner) */
    background-image:
        linear-gradient(120deg, rgba(255, 255, 255, 0.05) 1px, transparent 1px),
        linear-gradient(60deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
    background-size: 80px 80px;
    mix-blend-mode: overlay;
    z-index: -11; /* Detrás del 'before' y del contenido */
}

/* 2. CLASES GENERALES DE TIPOGRAFÍA Y SECCIONES */
.section-padding {
    padding: 80px 5%;
    max-width: 1500px;
    margin: 0 auto;
}

@keyframes gradientMove {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.section-title {
    color: var(--light-text);
    font-size: 2.5em;
    margin-bottom: 50px;
    border-bottom: 3px solid var(--primary-accent);
    display: inline-block;
    padding-bottom: 5px;
    text-align: center;
    margin: 0 0 50px;
}

.hero-section,
.about-section,
.projects-section,
.skills-section {
    text-align: center; /* ¡Aseguramos que el padre centre el contenido! */
}

.primary-accent {
    color: var(--primary-accent);
}

.light-text {
    color: var(--light-text);
}


/* 3. CABECERA Y NAVEGACIÓN */
.header {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px 5%;
    border-bottom: 1px solid rgba(83, 40, 233, 0.3);
    position: sticky;
    top: 0;
    z-index: 1000;
    background-color: rgba(0, 0, 0, 0.95);
    box-shadow: 0 0 50px rgba(83, 40, 233, 0.1);
}

.logo {
    margin-right: auto;
    font-size: 1.8em;
    font-weight: 300;
    letter-spacing: 2px;
}

.nav-link {
    color: var(--text-color);
    text-decoration: none;
    margin-left: 25px;
    padding: 5px 0;
    transition: color 0.3s, border-bottom 0.3s;
}

.nav-link:hover {
    color: var(--secondary-accent);
}

.navbar {
    margin-left: auto;
}

/* 4. BOTONES (Call to Action) */
.cta-button {
    text-decoration: none;
    padding: 10px 20px;
    border-radius: 6px;
    font-weight: 700;
    transition: all 0.3s ease;
}

.cta-contact-link {
    background: var(--primary-accent);
    color: var(--light-text);
    padding: 8px 15px;
    border-radius: 6px;
    box-shadow: 0 0 10px rgba(83, 40, 233, 0.5); 
    margin-left: 25px;
    font-weight: 700;
    transition: all 0.3s ease;
}

.cta-contact-link:hover {
    background: var(--secondary-accent);
    box-shadow: 0 0 15px var(--secondary-accent);
}

.primary-button {
    background: var(--primary-accent);
    color: var(--light-text);
    box-shadow: 0 0 10px rgba(83, 40, 233, 0.5); 
}

.primary-button:hover {
    background: var(--secondary-accent);
    box-shadow: 0 0 15px var(--secondary-accent);
}

.secondary-button {
    background: none;
    color: var(--secondary-accent);
    border: 2px solid var(--secondary-accent);
    padding: 8px 18px; /* Ajustamos el padding para que sea visualmente coherente */
    text-transform: uppercase;
    font-size: 0.9em;
    border-radius: 6px;
}

.secondary-button:hover {
    background: var(--secondary-accent);
    color: var(--main-bg);
    border-color: var(--secondary-accent);
    box-shadow: 0 0 10px var(--secondary-accent);
}


/* 5. SECCIÓN HERO (INTRODUCCIÓN) */
.hero-section {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    min-height: 70vh;
    justify-content: center;
}

.hero-title {
    font-size: 3.5em;
    margin-bottom: 10px;
    color: var(--light-text);
    text-align: left;
}

.hero-subtitle {
    font-size: 1.2em;
    margin-bottom: 30px;
}


/* 6. SECCIÓN PROYECTOS (GRID) */
.project-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.project-card {
    background-color: rgba(30, 36, 41, 0.4);
    padding: 30px;
    border-radius: 0;
    border: 1px solid var(--text-color);
    transition: transform 0.3s, box-shadow 0.3s, border-color 0.3s;
}

.project-card:hover {
    transform: translateY(-5px); /* Pequeño levantamiento */
    box-shadow: 0 0 15px var(--secondary-accent);
    border-color: var(--primary-accent); 
    background-color: rgba(30, 36, 41, 0.6);
}

.card-title {
    color: var(--light-text);
    margin-bottom: 10px;
    font-size: 1.5em;
    border-bottom: 1px dashed rgba(255, 255, 255, 0.1); 
    padding-bottom: 8px;
    margin-bottom: 15px;
}

.card-description {
    color: var(--text-color);
    margin-bottom: 25px;
    line-height: 1.5;
    font-size: 0.95em;
    padding-left: 15px;
    position: relative;
}

.card-description::before {
    content: "«"; /* Indicador de bloque de información */
    color: var(--primary-accent);
    position: absolute;
    left: 0;
    font-weight: 700;
}

/* 7. SECCIÓN HABILIDADES (Estilo HUD/Halo) */
.skill-grid-halo {
    display: flex;
    flex-wrap: wrap;
    gap: 25px;
    justify-content: center;
}

.skill-card-halo {
    background-color: rgba(56, 107, 135, 0.1);
    padding: 25px;
    width: 100%;
    max-width: 350px;
    min-height: 200px;
    border-radius: 4px;
    border: 1px solid var(--secondary-accent);
    box-shadow: 0 0 10px rgba(147, 96, 255, 0.4);
    transition: transform 0.3s, box-shadow 0.3s;
    font-weight: 300; 
    letter-spacing: 0.5px;
}

.skill-card-halo:hover {
    transform: scale(1.03);
    box-shadow: 0 0 20px var(--secondary-accent);
    background-color: rgba(56, 107, 135, 0.2);
}

.skill-name-halo {
    font-size: 1.3em;
    font-weight: 700;
    margin-bottom: 10px;
    letter-spacing: 1px;
    border-bottom: 2px dashed rgba(83, 40, 233, 0.5);
    padding-bottom: 5px;
}

.skill-level-halo {
    color: var(--light-text);
    font-size: 0.9em;
    margin-bottom: 15px;
    text-transform: uppercase;
    font-weight: 700;
    letter-spacing: 1.5px
}

.skill-level-halo strong {
    color: var(--secondary-accent);
}

.skill-detail-halo {
    font-size: 0.9em;
    margin-bottom: 8px;
    color: var(--text-color);
    font-weight: 400;
}

.skill-detail-halo strong {
    color: var(--primary-accent);
    font-weight: 700;
    margin-right: 5px;
}

/* Pequeño icono de triángulo o punto (Estilo HUD) */
.skill-detail-halo::before {
    content: "▹"; /* Un triángulo o flecha */
    color: var(--primary-accent);
    position: absolute;
    left: 0;
    font-weight: 700;
}


/* Media Query para asegurar la responsividad en pantallas pequeñas */
@media (max-width: 600px) {
    .skill-card-halo {
        max-width: 100%;
    }
}


/* 8. PIE DE PÁGINA */
.footer {
    text-align: center;
    padding: 30px 5%;
    border-top: 1px solid rgba(83, 40, 233, 0.3);
    font-size: 0.9em;
}

.about-section {
    background-color: #1e2429; /* Un fondo ligeramente diferente para contraste */
    border-top: 5px solid var(--primary-accent);
    /* border-bottom: 3px solid var(--primary-accent); */
    border-radius: 0;
}

.about-content {
    max-width: 900px;
    margin: 0 auto;
    padding: 30px 20px;
}

.about-text {
    font-size: 1.1em;
    line-height: 1.8;
    margin-bottom: 37px;
    color: var(--light-text);
    border-left: none;
    border-top: 1px dashed #8000FF;
    position: relative;
    text-align: left;
}

.about-text strong {
    /* Usaremos el color del acento secundario para las etiquetas */
    color: var(--secondary-accent); 
    font-weight: 700;
    letter-spacing: 0.5px;
}

.social-links a {
    color: var(--secondary-accent);
    text-decoration: none;
    margin: 0 10px;
}

.social-links a:hover {
    color: var(--light-text);
}

.hero-image-container {
    width: 300px;
    height: 330px;
    display: block;
    margin: 0 auto;
    border: 2px solid #8ab4f8;
    box-shadow: 0 0 15px rgba(138, 180, 248, 0.7);
    border-radius: 10px;
    overflow: hidden; 
}

.hero-image-content {
    width: 100%;
    height: auto; 
    object-fit: cover;
    width: 100%;
    height: 105%;
}

.Parte {
    display: flex;
    align-items: center;
    justify-content: space-around;
    text-align: left;
    width: 100%;
    margin-bottom: 30px;
}

.uno {
    max-width: 55%;
}

.dos {
    max-width: 35%; 
}

@media (max-width: 900px) {
    .Parte {
        flex-direction: column;
        text-align: center;
    }
    .uno, .dos {
        max-width: 100%;
        margin-bottom: 20px;
    }
    .hero-title {
        text-align: center;
        font-size: 2.5em;
    }
}

.contact-links {
    margin-bottom: 15px;
}

.contact-info {
    display: inline-block;
    margin: 0 15px;
    font-size: 1em;
    font-weight: 400;
    letter-spacing: 1px;
}

.contact-info a {
    color: var(--text-color);
    text-decoration: none;
    transition: color 0.3s;
}

.contact-info a:hover {
    color: var(--secondary-accent);
}

.social-links {
    margin-top: 10px;
}

/* 9. SECCIÓN CONTACTO (Terminal de Enlace) */
.contact-section {
    /* Fondo ligeramente diferente para contraste */
    background-color: var(--main-bg); 
    border-top: 3px solid var(--secondary-accent);
    text-align: center;
}

.contact-prompt {
    font-size: 1.1em;
    color: var(--text-color);
    margin-bottom: 40px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.6;
    text-align: center;
}

.contact-details-grid {
    display: flex;
    justify-content: center;
    gap: 30px;
    flex-wrap: wrap;
    padding-top: 20px;
}

.contact-item {
    background-color: rgba(56, 107, 135, 0.1);
    padding: 20px;
    border: 1px dashed var(--primary-accent);
    border-radius: 4px;
    width: 100%;
    max-width: 300px;
    transition: box-shadow 0.3s;
    text-align: center;
}

.contact-item:hover {
    box-shadow: 0 0 15px var(--primary-accent);
}

.contact-label {
    font-size: 0.9em;
    letter-spacing: 1.5px;
    margin-bottom: 5px;
}

.contact-value {
    font-size: 1.1em;
    font-weight: 700;
    word-break: break-all;
}

.footer .contact-links {
    display: none;
}