/* Sections container */
.container {
    padding: 5rem 10vw;
    background-color: var(--background);
    position: relative;
}

.line   {
    position: relative;
    background: var(--box-line-color);
    width: 100vw;
    height: 1px;
}

/* Hero section */
#hero {
    padding-top: 80px;
    position: sticky;
    top: 0px; 
    height: fit-content;
    overflow-y: auto; 
}

#hero h1 {
    font-family: 'Montserrat Underline';
    font-weight: bold;
    font-size: 5.5rem;
    margin-top: 7rem ;
    padding-left: 2px;
}

#hero h2 {
    font-size: 2.125rem;
    font-weight: 400;
    color: var(--subtitle-color);
    margin-bottom: 10rem;
}

.cta a {
    text-decoration: none;
    color: var(--text-color);
    font-size: 1.375rem;
    border: var(--border-box);
    padding: .5rem 2rem;
    margin-right: 5rem;
    position: relative;
    z-index: 1;
}

@keyframes mechanical-tick {
    0%, 45%   { transform: translateY(0);}
    50%, 95%  { transform: translateY(4px);}
    100%      { transform: translateY(0);}
}

.arrow-down {
    text-align: center;
    font-size: 3rem;
    color: var(--box-line-color);
    margin-top: 4rem;
    animation: mechanical-tick 1.3s linear infinite;
}
/* End of Hero */

/* About section */
.about-box {
    border: var(--border-box);
    padding: 4rem 5rem;
    display: flex;
    margin: 5rem 0;
}

.about-description {
    font-size: 1.875rem;
    color: var(--subtitle-color);
    width: 50%;
    line-height: 150%;
}

.about-img {
    width: 400px;
    margin-left: 6rem;
}
/* End of about */

/* Projects Section */
#project-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    grid-auto-rows: 1fr;
}

.project-box {
    display: flex;
    flex-direction: column;
    border: var(--border-box);
    padding: 1rem;
    min-width: 0;
}

.project-box .thumbnail {
    width: 100%;
}

.project-box p {
    color: var(--subtitle-color);
    font-size: 1.125rem;
}

.project-box-line {
    background-color: var(--box-line-color);
    height: 1px;
    margin: 1rem -1rem;
}   

.cta-row {
    display: flex;
    gap: 4rem;
}

.repo-icon {
    width: 80px;
}

.cta-row a, 
.unavailable-url {
    text-decoration: none;
    color: var(--text-color);
    border: var(--border-box);
    padding: .5rem 1.5rem;
    border-radius: 2px;
    font-weight: bold;
}

.desktop-only {
    display: inline-block; 
}

/* Hide the disabled warning */
.keyboard-warning {
    display: none; 

}

.projects-cta {
    text-decoration: none;
    color: var(--text-color);
    border: var(--border-box);
    padding: 1rem 2rem;
    display: block;
    margin-top: 5rem;
    width: fit-content;
}
/* End of Projects */

/* Education Section */
.education-container {
    border: var(--border-box);
}

#education h3 {
    font-size: 2rem;
    margin: 5rem 5rem 0;
}

#education h4 {
    font-size: 1.5rem;
    margin-left: 5rem;
    color: var(--subtitle-color);
}

#certs-list {
    list-style-type: none;
    display: grid;
    grid-template-columns: 1fr 1fr 1fr 1fr;
    gap: 1.5rem;
    margin: 2rem 5rem 5rem;
}

#certs-list a {
    display: flex;
    flex-direction: column;
    list-style-type: none;
    border: var(--border-box);
    text-decoration: none;
    color:var(--text-color);
    padding: 1rem; 
}

#certs-list img, 
.cert-grid img {
    height: 1.5rem;
    max-width: fit-content;
    margin-bottom: 1rem;
}

#certs-list p {
    padding-bottom: 3px;
}
/* End of eduction */

/* Contact section */
.contact-box {
    border: var(--border-box);
    width: 30vw;
}

.contact-line{
    background-color: var(--box-line-color);
    height: 1px;
}

#contact input, textarea {
    background: transparent;
    border: none;
    color: var(--subtitle-color);
    margin: 0;
    padding: .75rem 1rem;
    font-size: 1.25rem;
    width: 100%;
    box-sizing: border-box;
    outline: none;
}

#contact textarea {
    font-family: 'Montserrat';
    resize: none;
}

#contact button {
    margin-top: 2rem;
    background: transparent;
    padding: 1rem 2rem;
    color: var(--text-color);
    border: var(--border-box);
    font-size: 1rem;
}

#contact button:hover {
    box-shadow: 2px 2px 4px var(--box-line-color);
}
/* End opf contact*/

/* Responsive design */
@media (max-width: 1024px) {
    /* Hero section */
    #hero h1 {
        font-size: 5rem;
    }

    #hero h2 {
        font-size: 2rem;
        font-weight: 400;
    }
    /* End of Hero */

    /* About section */
    .about-box {
        border: var(--border-box);
        padding: 2rem 2.5rem;
        display: flex;
        margin: 5rem 0;
    }

    .about-description {
        font-size: 1.375rem;
        width: 60%;
    }

    .about-img {
        width: 275px;
        margin-left: 1.5rem;
    }
    /* End of about */

    /* Projects Section */
    #project-container {
        display: flex;
        flex-direction: column;
    }

    .project-box p {
        font-size: 1rem;
    }

    .desktop-only {
        display: none; 
    }

    .keyboard-warning {
        display: inline-block;
        padding: 0.5rem 1rem; 
        font-size: 0.9rem;
        color: var(--box-line-color); 
        border: var(--border-box); 
    }
    /* End of Projects */

    /* Education Section */
    #education h3 {
        font-size: 2.125rem;
    }

    #certs-list {
        grid-template-columns: 1fr 1fr ;
    }
    /* End of eduction */

    /* Contact section */
    .contact-box {
        width: 40vw;
    }

    .contact-line{
        background-color: var(--box-line-color);
        height: 1px;
    }
    /* End opf contact*/
}

@media (max-width: 768px) {
    /* Hero section */
    #hero h1 {
        font-size: 3.5rem;
    }

    #hero h2 {
        font-size: 1.375rem;
    }
    /* End of Hero */

    /* About section */
    .about-box {
        display: flex;
        flex-direction: column;
    }

    .about-description {
        font-size: 1.875rem;
        width: 100%;
    }

    .about-img {
        width: 70%;
        margin: 15%;
    }
    /* End of about */

    /* Projects Section */
    .project-box p {
        font-size: 1rem;
    }

    .keyboard-warning {
        font-size: 0.75rem !important; 
    }
    /* End of Projects */

    /* Education Section */
    #certs-list {
        gap: 1rem;
    }

    #certs-list p {
        font-size: .875rem;
    }
    /* End of eduction */

    /* Contact section */
    .contact-box {
        width: 60vw;
    }
    /* End opf contact*/
}

@media (max-width: 480px) {
    .container  {
        padding: 3rem 5vw;
    }
    
    /* Hero section */
    #hero h1 {
        font-size: 2.25rem;
    }

    #hero h2 {
        font-size: .9rem;
    }

    .cta a {
        font-size: 1rem;
        margin-right: 1rem;
    }
    /* End of Hero */

    /* About section */
    .about-box {
        display: flex;
        flex-direction: column;
        margin: 3rem 0;
        padding: 2rem 1.5rem;
    }

    .about-description {
        font-size: 1.25rem;
    }
    /* End of about */

    /* Projects Section */
    .project-box {
        padding: .5rem;
    }

    .cta-row {
        gap: 1rem;
    }

    .project-box a {
        font-size: .875rem;
    }

    .project-box p {
        font-size: 1rem;
    }

    .project-box-line {
        margin: 1rem -.5rem;
    }   

    .unavailable-url {
        font-size: .75rem !important;
    }
    /* End of Projects */

    /* Education Section */
    #education h3 {
        font-size: 1.5rem;
        margin: 3rem 0 0 1rem  ;
    }

    #education h4 {
        font-size: 1.125rem;
        margin: 0 1rem 3rem;
    }

    #certs-list {
        gap: 1rem;
        margin: 2rem 1rem 3rem;
        display: flex;
        flex-direction: column;
        width: 75%;
    }

    #certs-list p {
        font-size: 1rem;
    }
    /* End of eduction */

    /* Contact section */
    .contact-box {
        width: 80vw;
    }
    /* End opf contact*/
}
/* End of responsive */