@import url('https://fonts.googleapis.com/css2?family=Poppins:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap');

* { /* este es el selector general para que no se pegue al borde a la pantalla*/
box-sizing: border-box;
margin: 0;
padding: 0;

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

}

body {
    background: rgb(10, 10, 10);
    font-family: "Poppins", sans-serif;
    font-size: 1.2rem;
    min-height: 100vh; /*esto es para que ocupe el 100% de la pantalla*/
    padding: 20px;

}

.grid-container > * {/*el > se pone para que afecte a todos los hijos*/
    box-shadow: 10px 6px 37px -13px rgba(51, 51, 51, 0.74);
    border-radius: 10px;
    padding: 10px;
    text-align: center;
    font-weight: 500;
}

/*Los puntos de ruptura o breakpoints de CSS para los diferentes dispositivos son:
Moviles: 576px-320px (en horizontal o vertical)
Tablets: 768px
Portatiles: 992px
Sobremesa: 1200px*/

.grid-container {
    display: grid;/*para maquetar una web lo mejor es primero poner grid y ya dentro de grid meter los flex*/
    gap: 10px;/*es el espacio entre uno y otro*/
    grid-template-rows: 100px auto auto auto auto auto auto 50px;/*asegura que el main ocupe espacio suficiente*/
    grid-template-columns: 1fr; /*define que toda la estructura se acomode en una sola columna*/    
    grid-template-areas:/*podemos anidar para meter propiedades dentro de esta*/
        "header"
        "main1"
        "main2"
        "main3"
        "main4"
        "main5"
        "footer";
}

.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 10px 15px;
    background: rgb(10, 10, 10);
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 100;
}

.logo {
    width: 40px;
    height: 40px;
    margin-left: 10px;
    border-radius: 50%;
    box-shadow: 0 0 15px 5px rgb(0, 255, 0);
}

.navbar {
    display: flex;
    flex-direction: row;
    gap: 8px;
    font-size: 12px;
}

.navbar a {
    position: relative;
    font-size: 12px;
    color: white;
    font-weight: 500;
    text-decoration: none;
    margin-left: 5px;
}

.navbar a::before{
    content: '';
    position: absolute;
    top: 100%;
    left: 0;
    width: 0%;
    height: 2px;
    background: rgb(0, 255, 0);
    transition: .3s;
}
.navbar a:hover::before {
    width: 100%;
}

.main1 {
    grid-area: main1;
    background-color: rgb(10, 10, 10);
    padding: 20px; /*para que el contenido no esté pegado a los bordes*/
    color: white; /*evita que el div desaparezca si no tiene contenido*/
    min-height: 300px;
}

.content1 {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.left-section1 {
    flex: 1;
}

.main-title {
    font-size: 50px;
    font-weight: bold;
    text-align: left;
    margin-top: auto;
    margin-bottom: 10px;
    color: rgb(0, 255, 0);
}

.typewriter {
    font-size: 1.2rem;
    font-family: 'Courier New', 'Courier New', Courier, monospace;
    text-align: left;
    overflow: hidden;
    white-space: nowrap; /*maniente el texto en una linea*/
    border-right: 4px solid rgb(0, 255, 0, 0.75); /*crea el cursor parpadeante*/
    width: 46ch;
    max-width: 100%;
    animation: typing 12s steps(46) infinite, blink 0.7s infinite alternate; /*anima el texto como una maquina de escribir escribiendo y borrando infinitamente*/
    position: relative;
}

@keyframes typing {
    0% { width: 0; }
    50% {width: 46ch; }
    100% { width: 0; }
}
@keyframes blink {
    50% { border-color: transparent; }
}

@keyframes erase {
    0% { width: 46ch; }
    100% { width: 0;}
}
.social-buttons {
    display: flex;
    justify-content: left;
    gap: 15px;
    margin-top: 20px;
    position: static;
}

.btn {
    padding: 0.5px 0.5px;
    border-radius: 5px;
    font-size: 1rem;
    text-decoration: none;
    font-weight: bold;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.social-btn {
    color: white;
    padding: 10px 10px;
    transition: background-color 0.3s, transform 0.3s;
}

.github { background: #333; }
.linkedin { background: #0077b5; }
.instagram { background: #E1306C; }

.social-btn:hover {
    opacity: 0.8;
    transform: scale(1.1)
}

.download-btn {
    display: block;
    text-align: center;
    background: rgb(0, 255, 0);
    color: white;
    padding: 12px 20px;
    margin: 20px 0;
    width: 200px;
    border-radius: 5px;
    font-size: 1rem;
    font-weight: bold;
    transition: background-color 0.3s, transform 0.3s;
}

.download-btn:hover {
    background: rgb(0, 0, 0);
    color: rgb(0, 255, 0);
    transform: scale(1.1);
}

.right-section1 {
    flex: 1;
}

.profile-img {
    max-width: 350px;
    height: auto;
    border-radius: 10px;
    box-shadow: 0 0 15px 5px rgb(0, 255, 0, 0.8);
}

.main2 {
    grid-area: main2;
    background-color: rgb(10, 10, 10);
    padding: 20px; /*para que el contenido no esté pegado a los bordes*/
    color: white; /*evita que el div desaparezca si no tiene contenido*/
    min-height: 300px;
}

.about-text {
    font-size: 1rem;
    line-height: 1.6;
    text-align: left;
    margin-top: 20px;
    color: white;
}

.about-text:first-of-type {
    margin-top: none;
}

.about-text a {
    color: rgb(0, 255, 0);
    text-decoration: none;
}

.about-text a:hover {
    text-decoration: underline;
}

.main3 {
    grid-area: main3;
    background-color: rgb(10, 10, 10);
    padding: 40px 20px; /*40px para el superior y 20 para el inferior para que el contenido no esté pegado a los bordes*/
    color: white; /*evita que el div desaparezca si no tiene contenido*/
    min-height: 300px;
}

.project {
    background-color: rgb(20, 20, 20);
    border-radius: 10px;
    margin-bottom: 50px;
    display: flex;
    flex-direction: row;
    gap: 20px;
    padding: 20px;
    box-shadow: 0 0 15px 5px rgb(0, 255, 0, 0.5);
    justify-content: space-between;
}

.project-thumbnail {
    flex: 1;
    max-width: 100%;
    border-radius: 10px;
    overflow: hidden;
    padding: 10px;
}

.project-thumbnail video {
    width: 100%;
    height: auto;
    max-height: 200px;
    border-radius: 10px;
}

.project-details {
    flex: 2;
    display: flex;
    flex-direction: column;
    gap: 15px;
    padding: 10px;
}

.project-title {
    font-size: 2rem;
    font-weight: bold;
    color: rgb(0, 255, 0);
    margin-bottom: 10px;
}

.project-description {
    font-size: 1.1rem;
    color: white;
    line-height: 1.5;
}

.technologies {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
    margin-top: 10px;
}

.tech-btn {
    background-color: transparent;
    color: white;
    padding: 10px 20px;
    border-radius: 5px;
    font-size: 1rem;
    font-weight: bold;
    cursor: pointer;
    transition: transform 0.3s ease-in-out, background-color 0.3s;
    display: inline-block;
    text-align: center;
}

.tech-btn:hover {
    background-color: rgb(0, 0, 0);
    color: rgb(0, 255, 0);
    transform: scale(1.1);
}

.project-github {
    background-color: rgb(33, 33, 33);
    color: white;
    padding: 12px 20px;
    border-radius: 5px;
    text-align: center;
    font-size: 1.1rem;
    font-weight: bold;
    display: inline-block;
    text-decoration: none;
    margin-top: 15px;
    transition: background-color 0.3s, transform 0.3s;
}

.project-github:hover {
    background-color: rgb(0, 255, 0);
    transform: scale(1.1);
}

.main4 {
    grid-area: main4;
    background-color: rgb(10, 10, 10);
    padding: 20px; /*para que el contenido no esté pegado a los bordes*/
    color: white; /*evita que el div desaparezca si no tiene contenido*/
    min-height: 500px;
}

.skills-row {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.skills-column {
    flex: 1;
    padding: 20px;
    background-color: rgb(20, 20, 20);
    border-radius: 10px;
    box-shadow: 0 0 15px 5px rgb(0, 255, 0, 0.2);
    margin-bottom: 20px;
    max-width: 100%;
}

.skills-block {
    margin-bottom: 30px;
    padding: 20px;
    background-color: rgb(20, 20, 20);
    border-radius: 10px;
    box-shadow: 0 0 15px 5px rgb(0, 255, 0, 0.8);
}

.skills-category-title {
    font-size: 1.8rem;
    font-weight: 600;
    margin-bottom: 15px;
    color: rgb(0, 255, 0);
}

.skills-tags {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px;
}

.tech-btn {
    background-color: transparent;
    border: 2px solid rgb(0, 255, 0);
    color: white;
    padding: 10px 10px;
    border-radius: 5px;
    font-size: 1rem;
    font-weight: bold;
    cursor: pointer;
    transition: background-color 0.3s, transform 0.3s;
}

.tech-btn:hover {
    background-color: rgb(0, 0, 0);
    color: rgb(0, 255, 0);
    transform: scale(1.05);
}

.main5 {
    grid-area: main5;
    background-color: rgb(10, 10, 10);
    padding: 20px; /*para que el contenido no esté pegado a los bordes*/
    color: white; /*evita que el div desaparezca si no tiene contenido*/
    min-height: 300px;
}

.left-section {
    text-align: center;
    margin-bottom: 40px;
}

.main-title {
    font-size: 2.5rem;
    color: rgb(0, 255, 0);
    font-weight: bold;
}

.content {
    display: flex;
    flex-direction: column;
}

.section-header {
    text-align: center;
    margin-bottom: 40px;
}

.section-title {
    font-size: 2.5rem;
    color: rgb(0, 255, 0);
    font-weight: bold;
}

.section-subtitle {
    font-size: 1.2rem;
    color: white;
    font-weight: normal;
}

.certifications {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
    width: 100%;
    grid-template-rows: auto auto;
    justify-items: center;
}

.certification-card {
    background-color: #333;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 0 10px rgb(0, 255, 0, 0.8);
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    width: 250px;
    transition: transform 0.3s ease-in-out;
}

.certification-card:hover {
    transform: scale(1.1);
}

.certification-title {
    font-size: 1rem;
    color: rgb(0, 255, 0);
    font-weight: bold;
    margin-bottom: 10px;
}

.certification-institution {
    font-size: 0.8rem;
    color: white;
    margin-bottom: 5px;
}

.certification-date {
    font-size: 0.8rem;
    color: #aaaaaa;
    margin-bottom: 10px;
}

.credential-link {
    color: rgb(0, 255, 0);
    font-size: 0.8rem;
    text-decoration: none;
    margin-top: 10px;
}

.credential-link:hover {
    text-decoration: underline;
}

.footer {
    grid-area: footer;
    background-color: rgb(10, 10, 10);
    padding: 20px; /*para que el contenido no esté pegado a los bordes*/
    color: white; /*evita que el div desaparezca si no tiene contenido*/
    min-height: 300px;
    font-size: 0.8rem;
}

.footer h2 {
    font-size: 1rem;
}

.footer-content {
    display: flex;
    align-items: center;
    flex-direction: row;
    justify-content: center;
    padding: 20px 20px;
    gap: 20px;
    flex-wrap: wrap;

}

.contact-info {
    flex: 1;
    padding: 20px;
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    width: 250px;
    max-width: 100%;
    transition: transform 0.3s ease-in-out;
    font-size: 0.8rem;

}

.tech-used {
    flex: 1;
    padding: 20px;
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    width: 250px;
    max-width: 100%;
    transition: transform 0.3s ease-in-out;
    font-size: 0.8rem;
}

.contact-info h3, .tech-used h3 {
    font-size: 1rem;
}

.contact-info p, .tech-used p {
    font-size: 0.8rem;
}

h2 {
    color: rgb(0, 255, 0);
}
.section {
    padding-top: 80px; /* Esto es el espacio que se agrega sobre cada sección */
    scroll-margin-top: 80px; /* Esto asegura que cuando se hace scroll a una sección con anclaje no se tape con la navbar */
}

.main1, .main2, .main3, .main4, .main5, .footer {
    /* Esta propiedad asegura que el desplazamiento sea adecuado */
    padding-top: 80px; /* Añade un espaciado extra */
}

@media (max-width:768px) { 
    .header {
        padding: 10px;
    }
    
    .navbar{
        display: flex;
        flex-direction: row;
        align-items: center;
        width: 100%;
        padding: 10px 0;
    }

    .navbar.active {
        display: flex;
    }

    .navbar a {
        font-size: 12px;
        margin-left: 5px;
    }

    .menu-toggle {
        display: block;
        cursor: pointer;
        font-size: 24px;
        color: white;
    }

    .logo {
        width: 40px;
        height: 40px;
        margin-left: 10px;
    }

    .content1 {
        text-align: center;
        width: 100%;
        padding: 10px;
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .social-buttons {
        display: flex;
        justify-content: center;
        align-items: center;
        flex-wrap: wrap;
        gap: 15px;
        width: 100%;
    }

    .download-btn {
        display: flex;
        justify-content: center;
        align-items: center;
        margin: 20px auto;
    }

    .right-section1 {
        order: 1;
        margin-top: 20px;
    }

    .typewriter {
        display: none;
    }

    .project {
        flex-direction: column;
        align-items: center;
    }

    .project-thumbnail video {
        max-width: 100%;
        height: auto;
    }
}

@media (max-width:576px) { 
    .grid-container {
        display: flex;
        flex-direction: column;
        align-items: center;
        overflow-x: hidden;
        width: 100%;
    }

    .certifications {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 20px;
    }

    .certification-card {
        width: 90%;
        max-width: 300px;
    }

    .social-buttons {
        display: flex;
        justify-content: center;
        align-items: center;
        flex-wrap: wrap;
        gap: 15px;
        width: 100%;
    }

    .download-btn {
        display: flex;
        justify-content: center;
        align-items: center;
        margin: 20px auto;
    }

    .right-section1 {
        order: 1;
        width: 100%;
        display: flex;
        justify-content: center;
    }

    .typewriter {
        display: none;
    }

    .content1 {
        text-align: center;
        width: 100%;
        padding: 10px;
    }

    .main-title {
        font-size: 2rem;
    }

    .tech-btn {
        padding: 8px 15px;
    }

    .project {
        width: 100%;
        padding: 10px;
    }

    .project-details {
        width: 100%;
        text-align: center;
    }

    .header {
        padding: 10px;
    }

    .body {
        overflow-x: hidden;
    }

    .footer-content {
        flex-direction: column;
        align-items: center;
        gap: 15px;
    }
}
