/* ---------MAIN CODE--------- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    text-decoration: none;
    border: none;
    outline: none;
    scroll-behavior: smooth;
    font-family: "Optima", sans-serif;
}
:root {
    --bg-color: #374785;          /*#374785 = dark blue*/   /*A*/
    --second-bg-color: #495ca7;   /*#495ca7 = med blue*/    /*A*/
    --text-color: white;          /*white*/                 /*A*/
    --main-color: #A8D0E6;        /*#A8D0E6 = light blue*/  /*A*/
    --icon-color: pink;           /*pink*/                  /*A*/
}
html {
    font-size: 60%;
    overflow-x: hidden;
}
body {
    background: var(--bg-color);
    color: var(--text-color);
}
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 3rem 12% 3rem;
    background: rgba(0,0,0,0.3);
    backdrop-filter: blur(10px);
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 5;
}
.logo {
    font-size: 3rem;
    color: var(--text-color);
    font-weight: 800;
    cursor: pointer;
    transition: 0.3s ease;
}
.logo:hover {transform: scale(1.1);}
.logo span{text-shadow: 0 0 25px var(--icon-color);}
.navbar {
    display: flex;
    justify-content: center;
    align-items: center;
}
.navbar a {
    font-size: 1.8rem;
    color: var(--text-color);
    margin-left: 4rem;
    font-weight: 500;
    transition: 0.3s ease;
    border-bottom: 3px solid transparent;
}
.navbar a:hover, 
.navbar a.active {
    color: var(--icon-color);
    border-bottom: 3px solid var(--icon-color);
}
#menu-icon {                    /* Dropdown menu icon */
    font-size: 3.6rem; 
    color: var(--icon-color);
    display: none;
    cursor: pointer;
}
.navbar.active {display: block;}
section {
    min-height: 100vh;
    padding: 10rem 12%;
}


/* --------HOME CONTENT-------- */
.home {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15rem;
}
.home-content {
    display: flex;
    flex-direction: column;
    align-items: baseline;
    text-align: left;
    justify-content: center;
    margin-top: 3rem;
}
span {color: var(--main-color);}
.logo span {color: var(--icon-color);}
.home-content h1 {
    font-size: 7rem;    /* Hi, it's Reese! */
    font-weight: 700;
    margin-top: 1.5rem;
    line-height: 1;
}
.home-content h3 {      /* I'm a... */
    font-size: 3.5rem;
    font-style: italic;
    margin-bottom: 2rem;
    margin-top: 1rem;
}
.home-img {border-radius: 50%;}
.home-img img {
    position: relative;
    top: 3rem;
    width: 32vw;
    border-radius: 50%;
    box-shadow: 0 0 25px var(--icon-color);
    cursor: pointer;
    transition: 0.4s ease-in-out;
}
.home-img img:hover {
    box-shadow: 0 0 25px var(--icon-color),
                0 0 50px var(--icon-color),
                0 0 100px rgb(248, 215, 220);
}
.home-content p {
    font-size: 2.25rem; /* Summary */
    font-weight: 500;
    line-height: 1.8;
    max-width: 1000px;
}


/* ---SOCIAL MEDIA ICON ANIMATIONS--- */
.social-icons a {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 4.5rem;
    height: 4.5rem;
    background: transparent;
    border: 2px solid var(--icon-color);
    font-size: 2.5rem;
    border-radius: 50%;
    color: var(--icon-color);
    margin: 3rem 1.5rem 3rem 0;
    transition: 0.3s ease-in-out;
}
.social-icons a:hover {
    color: black;
    transform: scale(1.3)translateY(-5px);
    box-shadow: 0 0 25px var(--icon-color);
    background-color: var(--icon-color);
}
.btn {
    display: inline-block;
    padding: 1rem 2rem;
    background-color: var(--icon-color);
    box-shadow: 0 0 25px var(--icon-color);
    border-radius: 4rem;
    font-size: 1.6rem;
    color: var(--text-color);
    border: 2px solid transparent;
    letter-spacing: 0.1rem;
    font-weight: 600;
    transition: 0.3s ease-in-out;
    cursor: pointer;
}
.btn:hover {
    transform: scale(1.05);
    box-shadow: 0 0 50px var(--icon-color);
}
.btn-group {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}
.btn-group a:nth-of-type(2) {
    background-color: white;
    color: var(--icon-color);
    border: 2px solid var(--icon-color);
    box-shadow: 0 0 25px transparent;
}
.btn-group a:nth-of-type(2):hover {
    box-shadow: 0 0 25px var(--icon-color);
    background-color: var(--icon-color);
    color: black;
}


/* ------ROLE TYPING ANIMATION------ */
.text-animation {
    font-size: 34px;
    font-weight: 600;
    min-width: 280px;
}
.text-animation span {position: relative;}
.text-animation span::before {
    content: "Data Analyst";
    color: var(--icon-color);
    animation: words 20s infinite;
}
.text-animation span::after {
    content: "";
    background-color: var(--bg-color);
    position: absolute;
    width: calc(100% + 8px);
    height: 100%;
    border-left: 3px solid var(--bg-color);
    right: -8px;
    animation: cursor 0.6s infinite, typing 20s steps(14) infinite;
}
@keyframes cursor {
    to {border-left: 2px solid var(--icon-color);}
}
@keyframes words {
    0%, 25% {content: "Computer Science Major";}
    26%, 50% {content: "Mathematics Minor";}
    51%, 75% {content: "Data Scientist";}
    76%, 100% {content: "Data Analyst";}
}
@keyframes typing {
    12.5%, 18.75%, 37.5%, 43.75%, 62.5%, 68.75%, 87.5%, 93.75% {width: 0;}
    6.25%, 25%, 31.25%, 50%, 56.25%, 75%, 81.25% {width: calc(100% + 8px);}
}


/* ----------PROJECTS---------- */
.projects {
    background: var(--second-bg-color);
    padding: 8rem;
    margin-bottom: 10px; /* Margin below projects */
}
.projects-box {
    background-size: cover;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    height: 50%;
}
.projects .heading {margin-bottom: 4rem;} /* Margin under 'PROJECTS' title */
.projects .subheading {font-size: 2.8rem;}
.projects-box img {
    width: 100%;
    height: auto;
    max-height: 180px;
    object-fit: cover;  /* prevents image from distorting */
    border-radius: 2rem;
}
.wrapper {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 3rem;
    margin-bottom: 0;
}
.project-item {
    min-height: 100px;
    max-width: 600px;
    background: var(--bg-color);
    border: 3px solid var(--main-color);
    border-radius: 2rem;
    margin: 0 2rem;
    padding: 25px 50px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    gap: 1.5rem;
    transition: 0.4s ease-in-out;
    text-decoration: none;          /* Remove default link styling */
    color: inherit;                 /* Ensure the text color is inherited */
}
.project-item:hover {
    border: 3px solid var(--main-color);
    transform: translateY(-10px) scale(1.03);
    box-shadow: 0 0 50px var(--main-color);
}
.project-item h2 {         /* Certificate */
    font-size: 24px;
    color: var(--icon-color);
    text-align: left;
    margin-bottom: 1rem;
    margin-top: 1rem;
}
.project-item p {           /* Additional styles for <a> tag */
    text-decoration: none;  /* Remove default link styling */
    color: inherit;         /* Ensure the text color is inherited */
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1.5rem;
    font-size: 19px;
    color: white;
    text-align: left;
}
.skill {
    display: inline-block;
    padding: 0.5rem 1rem;
    background-color: var(--main-color);    /* main = light blue */
    border-radius: 1rem;
    font-size: 14px;
    color: var(--text-color);
    border: 2px solid transparent;
    letter-spacing: 0.1rem;
    font-weight: 600;
}
.skill:hover {
    transform: scale(1.05);
    box-shadow: 0 0 50px var(--main-color); /* main = light blue */
}
.skill-group {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}


/* ----------EXPERIENCE---------- */
.heading {
    font-size: 5rem;
    text-align: center;
    margin: 5rem 0;
}
.experience {
    padding: 8rem;
    background: var(--bg-color);
}
.experience h2 {margin-bottom: 3rem;}
.timeline-items {
    max-width: 1300px;  /* Width of boxes */
    margin: auto;       /* Margin auto in center */
    display: flex;
    flex-wrap: wrap;
    position: relative;
    padding-bottom: 5rem;
}
.timeline-items::before {
    content: "";
    position: absolute;
    width: 5px;
    height: 100%;
    background-color: var(--main-color);
    left: calc(50% - 1px);
}
.timeline-item {
    margin-bottom: 2.5rem;
    width: 100%;
    position: relative;
}
.timeline-item {margin-bottom: 0;}
.timeline-item:nth-child(1),
.timeline-item:nth-child(3) {
    padding-left: 0;                   /* On LEFT side of line */
    padding-right: calc(50% + 30px);   /* Space btwn box and line */
    text-align: right;
}
.timeline-item:nth-child(2),
.timeline-item:nth-child(4) {
    padding-right: 0;                 /* On RIGHT side of line */
    padding-left: calc(50% + 30px);   /* Space btwn box and line */
    text-align: left;
}
.timeline-dot {
    height: 21px;
    width: 21px;
    background-color: var(--main-color);
    box-shadow: 0 0 25px var(--main-color),
                0 0 50px var(--main-color);
    position: absolute;
    left: calc(50% - 9px);
    transform: translateX(-50%);
    border-radius: 50%;
    top: 60%;
    transform: translateY(-50%);
}
.timeline-date {
    font-size: 20px;
    font-weight: 500;
    color: var(--icon-color);
    margin: 6px 0 15px;
}
.timeline-content {
    background-color: var(--bg-color);
    border: 3px solid var(--main-color);
    padding: 25px 50px;                      /* Padding in box */
    border-radius: 4rem;
    box-shadow: 0 0 10px var(--main-color);
    cursor: pointer;
    transition: 0.3s ease-in-out;
}
.timeline-content {
    transform: scale(1.05);
    box-shadow: 0 0 25px var(--main-color);
}
.timeline-content h3 {
    font-size: 24px;
    color: var(--icon-color);
    margin: 0 0 5px;
    font-weight: 500;
}
.timeline-content h4 {
    font-size: 20px;
    color: var(--icon-color);
    margin: 0 0 5px;
    font-weight: 500;
}
.timeline-content p {
    color: white;
    font-size: 19px;
    font-weight: 300;
    line-height: 20px;
}
::-webkit-scrollbar {width: 15px;}
::-webkit-scrollbar-thumb {background-color: var(--main-color);}
::-webkit-scrollbar-track {background-color: var(--bg-color);}


/* ----------CERTIFICATES---------- */
.certificates {
    background: var(--second-bg-color);
    padding: 8rem;
    margin-bottom: 10px; /* Margin below certificates */
}
.certificates-box {
    background-size: cover;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
}
.certificates .heading {margin-bottom: 4rem;} /* Margin under 'CERTIFICATES' title */
.certificates .subheading {
    margin-bottom: 4rem;
    font-size: 2.8rem;
}
.certificates-box img {
    width: 20rem;
    height: 20rem;
    border-radius: 50%;
    border: 3px solid var(--main-color);
    box-shadow: 0 0 25px var(--main-color);
}
.wrapper {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 3rem;
    margin-bottom: 0;
}
.certificate-item {
    min-height: 100px;
    max-width: 600px;
    background: var(--bg-color);
    border: 3px solid var(--main-color);
    border-radius: 2rem;
    margin: 0 2rem;
    padding: 25px 50px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    gap: 1.5rem;
    transition: 0.4s ease-in-out;
    text-decoration: none;          /* Remove default link styling */
    color: inherit;                 /* Ensure the text color is inherited */
}
.certificate-item:hover {
    border: 3px solid var(--main-color);
    transform: translateY(-10px) scale(1.03);
    box-shadow: 0 0 50px var(--main-color);
}
.certificate-item h2 {         /* Certificate */
    font-size: 24px;
    color: var(--icon-color);
    margin-bottom: -10px;
    text-align: center;
}
.certificate-item p {          /* Completion date */
    font-size: 20px;
    color: var(--icon-color);
    margin-bottom: 1rem;
}
.certificate-item ul li {      /* Bullet points */
    font-size: 19px;
    color: white;
    text-align: left;
}
.certificate-item a {          /* Additional styles for <a> tag */
    text-decoration: none;     /* Remove default link styling */
    color: inherit;            /* Ensure the text color is inherited */
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1.5rem;
}


/* ----------CONTACT---------- */
.contact {
    background-color: var(--bg-color);
    padding: 8rem;
    margin-bottom: -40px;
}
.contact h2 {
    font-size: 5rem;
    margin-bottom: 3rem;
    color: var(--text-color);
}
.contact h2 span {color: var(--icon-color);}
.contact form {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 3rem;
    margin: 5rem auto;
    text-align: center;
}
.contact form .input-box {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
}
.contact form .input-box input,
.contact form textarea {
    width: 100%;
    padding: 2.5rem;
    font-size: 1.8rem;
    color: white;
    background: var(--second-bg-color);
    border-radius: 2rem;
    border: 2px solid var(--main-color);
    margin: 1.5rem 0;
    resize: none;
}
.contact form .input-box input::placeholder,
.contact form textarea::placeholder {
    color: var(--text-color);
}
.contact form .btn {margin-top: 2rem;}
.footer {
    position: relative;
    bottom: 0;
    width: 100%;
    padding: 40px 0;
    background-color: var(--second-bg-color);
}
.footer .social {
    text-align: center;
    padding-bottom: 25px;
    color: var(--main-color);
}
.footer .social a {
    font-size: 25px;
    color: var(--icon-color);
    border: 2px solid var(--icon-color);
    width: 42px;
    height: 42px;
    line-height: 42px;
    display: inline-block;
    text-align: center;
    border-radius: 50%;
    margin: 0 10px;
    transition: 0.3s ease-in-out;
}
.footer .social a:hover {
    transform: scale(1.2)translateY(-10px);
    background-color: var(--icon-color);
    color: black;
    box-shadow: 0 0 25px var(--icon-color);
}
.footer ul {
    margin-top: 0;
    padding: 0;
    font-size: 18px;
    line-height: 1.6;
    margin-bottom: 0;
    text-align: center;
}
.footer ul li a {
    color: white;
    border-bottom: 3px solid transparent;
    transition: 0.3s ease-in-out;
}
.footer ul li a:hover {
    border-bottom: 3px solid var(--icon-color);
}
.footer ul li {
    display: inline-block;
    padding: 0 15px;
}
.footer .copyright {
    margin-top: 50px;
    text-align: center;
    font-size: 16px;
    color: white;
}


/* -----------MEDIA------------ */
@media (max-width: 768px) {
    .projects-container {
        flex-direction: column;  /* Stack project boxes vertically */
        align-items: center;     /* Center align items */
    }
    .project-box {
        width: 100%;             /* Full width for stacked boxes */
        margin-bottom: 2.5rem;   /* Space between stacked boxes */
    }
}
@media (max-width: 991px) {
    header {padding: 2rem 3%;}
    section {padding: 10rem 3% 2rem;}
    .timeline-items::before {left: 7px;}
    .timeline-item {
        width: 100%;
        text-align: left;
        padding: 0 15px;
    }
    .timeline-dot {
        position: absolute;
        left: -1px; 
        top: 60%;
    }
    .timeline-item:nth-child(odd),
    .timeline-item:nth-child(even) {
        padding-left: 50px;
        padding-right: 40px;
        text-align: left;
    }
    .projects {padding-bottom: 7rem;}
    .certificates .wrapper {grid-template-columns: repeat(1, 1fr);}
    .certificates-box {padding-bottom: 17rem;}
    .contact form {flex-direction: column;}
    .footer {padding: 2rem 3%;}
}
@media(max-width:1050px) {
    #menu-icon {display: block;}  /* Display menu icon */
    .navbar {
        display: none;
        position: absolute;
        top: 100%;
        right: 0;
        width: fit-content;
        padding: 1rem 3%;
        background: rgba(0,0,0,0.3);
        box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
        backdrop-filter: blur(10px);
        z-index: 5;
        flex-direction: column;
    }
    .navbar.active {display: flex;}  /* Display menu icon when active */
    .navbar a {
        display: block;
        font-size: 2rem;
        margin: 3rem 0;
        color: white;
        transition: var(--bg-color) 0.3s;
    }
    .navbar a:hover {background-color: rgba(255, 255, 255, 0.2);}
    .home {
        flex-direction: column-reverse;
        margin: 5rem 4rem;
    }
    .home-content h3 {font-size: 2.6rem;}
    .home-content h1 {
        font-size: 8rem;
        margin-top: 3rem;
    }
    .home-content p {
        max-width: 600px;
        margin: 0 auto;
    }
    .home-img img {width: 56vw;}
    .services h2 {margin-bottom: 3rem;}
    .projects-container {grid-template-columns: repeat(1,1fr);}
}