/* Paleta de colores y variables */
:root {
    --color-principal: #000000;
    --color-secundario: #8f7e7e;
    --color-resalte: #00ffff;
    --color-texto: #fff;
    --sombra-clara: rgba(0, 255, 255, 0.5);
    --sombra-oscura: rgba(0, 0, 0, 0.8);
}

/* Estilos Generales */
html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--color-principal);
    color: var(--color-texto);
    font-family: 'Poppins', sans-serif;
    margin: 0;
    padding: 0;
    overflow-x: hidden;
    line-height: 1.6;
}

a {
    text-decoration: none;
    color: inherit;
}

/* Header y Navegación */
header {
    background-color: var(--sombra-oscura);
    padding: 10px 0;
    position: fixed;
    width: 100%;
    z-index: 1000;
}

.contenedor-nav {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.orden {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
}

.or {
    color: var(--color-secundario);
    margin: 0 15px;
    font-size: 1rem;
    font-weight: 500;
    opacity: 0.8;
    transition: color 0.3s ease, transform 0.3s ease-in-out;
}

.or:hover {
    color: var(--color-texto);
    transform: scale(1.1);
}

.incono_flotante {
    margin-left: 20px;
    transition: transform 0.3s ease-in-out;
}

.github-icon {
    color: var(--color-texto);
    font-size: 2em;
}

.github-icon:hover {
    transform: scale(1.4);
}

/* Sección de Inicio (Home) */
#home {
    background-image: url(src/tierra.png);
    background-repeat: no-repeat;
    background-position: center bottom;
    background-size: cover;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    padding-top: 80px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.contenedor {
    max-width: 800px;
    padding: 20px;
    position: relative;
    z-index: 10;
}

.contenedor h1 {
    font-size: clamp(2.5rem, 8vw, 4rem);
    font-weight: 700;
    margin-bottom: 0.5em;
    text-shadow: 2px 2px 6px var(--sombra-oscura);
}

.contenedor p {
    font-size: clamp(1rem, 2vw, 1.2rem);
    font-weight: 300;
    margin: 0.5em 0 1.5em;
    text-shadow: 1px 1px 3px var(--sombra-oscura);
}

.botones-home {
    display: flex;
    gap: 20px;
    justify-content: center;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.botton01 {
    padding: 15px 30px;
    border: 1px solid var(--color-texto);
    color: var(--color-texto);
    border-radius: 10px;
    font-size: 0.9em;
    font-weight: 500;
    background-color: transparent;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.3s ease-in-out;
}

.botton01:hover {
    transform: scale(1.05);
}

.contenedor_imag {
    position: absolute;
    bottom: -10%;
    right: -20%;
    width: 60%;
    max-width: 800px;
    opacity: 0.1;
    z-index: 1;
}

.ima01 {
    width: 100%;
    height: auto;
    animation: flotar 5s ease-in-out infinite;
}

@keyframes flotar {
    0% { transform: translateY(0); }
    50% { transform: translateY(-20px); }
    100% { transform: translateY(0); }
}

/* Sección Sobre Mí */
.sobre_mi {
    padding: 80px 20px;
    text-align: center;
}

.contenido-sobre-mi {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 40px;
}

.tex {
    width: 100%;
    max-width: 450px;
    background-color: rgba(0, 0, 0, 0.5);
    border-radius: 8px;
    padding: 30px;
    text-align: start;
}

.foto {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    background-image: url(rrc_inco/yop.jpg);
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    margin: 0 auto 20px;
}

.tex h1 {
    font-size: 1.6em;
    font-weight: 600;
    margin-bottom: 0.5em;
    text-align: center;
}

.tex p {
    font-size: 1em;
    line-height: 1.6;
    font-weight: 300;
    text-align: left;
}

.todo {
    background-color: rgba(0, 0, 0, 0.5);
    border-radius: 8px;
    padding: 30px;
    text-align: center;
    width: 100%;
    max-width: 450px;
}

.todo h1 {
    font-size: 1.6em;
    font-weight: 600;
    margin-bottom: 0.5em;
}

#palabra-cambiante {
    font-size: 1em;
    font-weight: 500;
    color: var(--color-resalte);
    margin-bottom: 20px;
}

.habilidades-iconos {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px;
    margin-top: 20px;
}

.sobre_mi img {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    filter: grayscale(80%);
    transition: transform 0.3s ease-in-out, filter 0.3s ease-in-out;
    object-fit: contain;
}

.sobre_mi img:hover {
    transform: scale(1.1);
    filter: grayscale(0%);
}

/* Sección de Proyectos */
#proyectos {
    padding: 80px 20px;
    text-align: center;
}

.proyectos-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px;
    margin-top: 40px;
}

.proyecto-item {
    border: 1px solid var(--color-texto);
    border-radius: 8px;
    padding: 30px;
    min-height: 270px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.proyecto-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.4);
}

.proyecto-item h1 {
    font-size: 1.6em;
    font-weight: 600;
    margin-top: 15px;
    margin-bottom: 0.5em;
    text-align: center; /* Alineación de títulos centrada */
}

.proyecto-item p {
    font-size: 0.9em;
    font-weight: 300;
    line-height: 1.5;
    margin-bottom: 1em;
    text-align: center; /* ¡Aquí está el cambio! Párrafo alineado al centro */
}

.nexus, .formulario {
    object-fit: cover;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.nexus {
    width: 80px;
    height: 80px;
    border-radius: 10px;
    margin-bottom: 15px;
    box-shadow: 0 0 15px var(--sombra-clara);
}

.nexus:hover {
    transform: scale(1.1);
    box-shadow: 0 0 25px var(--color-resalte);
}

.formulario {
    width: 150px;
    height: 150px;
    border-radius: 8px;
    margin-bottom: 15px;
    box-shadow: 0 0 15px var(--sombra-clara);
}

.formulario:hover {
    transform: scale(1.05);
    box-shadow: 0 0 25px var(--color-resalte);
}

.boton-repositorio {
    display: inline-block;
    margin-top: auto;
}

.botton02 {
    border: 1px solid var(--color-texto);
    color: var(--color-texto);
    border-radius: 10px;
    font-size: 1em;
    font-weight: 500;
    padding: 10px 20px;
    background-color: transparent;
    cursor: pointer;
    transition: background-color 0.3s ease, color 0.3s ease, transform 0.3s ease-in-out;
}

.botton02:hover {
    transform: scale(1.05);
}

.github-icon01 {
    font-size: 1.2em;
    margin-right: 10px;
}

/* Sección de Contacto */
.contacto-section {
    padding: 60px 20px;
    text-align: center;
}

.contacto-container {
    max-width: 700px;
    margin: 0 auto;
}

.contacto-container h2 {
    font-size: 1.6em;
    font-weight: 700;
    margin-bottom: 15px;
    color: var(--color-resalte);
}

.contacto-container p.contacto-description {
    font-size: 1.1em;
    font-weight: 400;
    line-height: 1.5;
    margin-bottom: 25px;
    color: #eee;
}

.contacto-ways {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 30px;
    margin-top: 25px;
    flex-wrap: wrap;
}

.contacto-option {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1em;
    font-weight: 500;
    transition: transform 0.3s ease-in-out;
}

.contacto-option:hover {
    transform: scale(1.1);
}

.contacto-option i {
    font-size: 1.6em;
    color: var(--color-resalte);
}

.contacto-option a {
    color: var(--color-texto);
    text-decoration: none;
}

/* Media Queries para responsividad */
@media (max-width: 768px) {
    .orden {
        justify-content: center;
    }
    .or {
        margin: 0 10px;
    }
    .botones-home {
        flex-direction: column;
        gap: 15px;
        width: 100%;
    }
    .botton01 {
        width: 100%;
    }
    .contenedor_imag {
        position: static;
        width: 80%;
        max-width: none;
        opacity: 0.2;
        margin: 20px auto 0;
    }
    .contenido-sobre-mi {
        flex-direction: column;
    }
    .tex, .todo {
        width: 100%;
        max-width: none;
    }
    .tex {
        text-align: center;
    }
    .tex p {
        text-align: center;
    }
    .proyectos-grid {
        grid-template-columns: 1fr;
    }
    .proyecto-item {
        width: 100%;
        min-height: auto;
    }
    .contacto-ways {
        flex-direction: column;
    }
}
