/* BODY STYLES */
body {
  margin: 0;
  font-family: "Raleway", sans-serif;
  background-color: #e6def3;
  color: #271b1c;
  text-align: center;
  padding-top: 100px;
}
/* Heading */
h2 {
  font-family: "Quicksand", sans-serif;
  font-weight: 600;
  margin-bottom: 1rem;
}
h3,
h4 {
  font-family: "Quicksand", sans-serif;
  font-weight: 500;
  margin-top: 2rem;
  margin-bottom: 1rem;
}
/* Paragraphs */
p {
  font-family: "Raleway", sans-serif;
  font-size: 1rem;
  line-height: 1.6;
}
/* Extras */
.section {
  padding-top: 150px;
}
/* View all posts/my thoughts */
.view-all {
  text-align: center;
  margin-top: 2rem;
}
.view-link {
  text-decoration: none;
  color: #271b1c;
  transition: color 0.3s ease;
}
.view-link:hover {
  color: #634c88;
}

/* Navigation */
header.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background-color: rgba(230, 222, 243, 0.3);
  transition: all 0.3s ease;
  backdrop-filter: blur(10px);
}
header.navbar:hover {
  background-color: rgba(230, 222, 243, 0.8);
}

.logo img {
  height: 100px;
  padding: 10px;
  width: auto;
}

nav {
  padding: 2rem;
}
nav ul {
  list-style: none;
  display: flex;
  gap: 2.5rem;
  padding: 10px;
  margin: 0;
}
nav a {
  text-decoration: none;
  color: #271b1c;
  font-family: "Quicksand", sans-serif;
  font-weight: 400;
  font-size: 1.2rem;
  transition: color 0.3s ease;
}
nav a:hover {
  color: #634c88;
}

/* HOME/MAIN PAGE */
/* Hero/intro */
.hero {
  padding: 5rem 1rem 2rem;
  display: flex;
  justify-content: center;
  flex-direction: column;
  align-items: center;
}
.hero h1 {
  font-size: 6rem;
  font-weight: 700;
  font-family: "Quicksand", sans-serif;
  white-space: nowrap;
  border-right: 3px solid #271b1c;
  display: inline-block;
  overflow: hidden;
  width: 0;
  animation: typing 2s steps(6, end) forwards, blink 0.8s step-end infinite;
  margin: 0;
}
.hero p {
  width: 500px;
  text-align: center;
  margin: auto;
}
.intro {
  display: flex;
  justify-content: center;
  align-items: center;
  background-color: #e6def3;
}
.rectangle-container {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  background-color: #fcfcfc;
  width: 100%;
  height: 250px;
  max-width: 1000px;
}
.intro-text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  text-align: left;
  height: 100%;
  padding: 0 30px;
  margin-top: 24px;
}
.intro-img {
  display: flex;
  justify-content: right;
  align-items: center;
  height: 100%;
}
.mobile-intro-img {
  display: none;
}
.intro-img img {
  width: 230px;
  height: auto;
  object-fit: cover;
  display: block;
}

/* Cursor blink HELLO! */
.cursor {
  display: inline-block;
  animation: blink 0.8s step-end infinite;
}

/* Arrow leading to About*/
.arrow {
  padding-bottom: 5rem;
}
.scroll-down {
  display: inline-block;
  margin-top: 2rem;
  animation: bounce 2s infinite;
}
.scroll-down img {
  width: 40px;
  height: auto;
  transition: transform 0.5s ease;
}
.scroll-down:hover img {
  transform: translateY(5px);
}

/* About me section */
.about {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 30px;
  padding: 40px 20px;
  max-width: 1000px;
  margin: 0 auto;
}
.about img {
  width: 300px;
  height: auto;
  object-fit: cover;
  border-radius: 0;
}
.about p {
  max-width: 600px;
  line-height: 1.6;
  font-size: 1rem;
  text-align: left;
}
#about {
  margin-top: 100px;
  scroll-margin-top: 100px;
}

/* Skills */
.skill {
  float: left;
  text-align: center;
  justify-content: center;
  width: 25%;
  margin-bottom: 10px;
  padding: 0 20px;
}
.skill img {
  width: 100px;
  height: auto;
  display: block;
  margin: 0 auto;
}
.skills {
  display: flex;
  justify-content: center;
  flex-wrap: wrap; /*allows wrapping on small screens */
  margin: 0 auto;
  padding: 20px 0;
}
.skills p {
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.95rem;
  color: #271b1c;
  margin: 0.5rem auto;
  max-width: 400px;
}
.skills:after {
  content: "";
  display: table;
  clear: both;
}

/* Projects */
.projects {
  display: grid;
  grid-template-columns: repeat(3, 1fr); /* 3 by 2 */
}
.project {
  padding: 10px;
}
.project p {
  font-family: "IBM Plex Mono", monospace;
  font-size: medium;
}
.project:hover img {
  opacity: 0.5;
  transition: 0.5s ease;
}
.project img {
  width: 300px;
  height: 240px;
}

/* Journal Page */
.journal-section {
  background-color: #271b1c;
  padding: 3rem 1rem;
  color: #271b1c;
  text-align: center;
}
.journal-container {
  display: grid;
  grid-template-columns: 2fr 1fr;
  align-items: stretch;
  gap: 40px;
  max-width: 1000px;
  margin: 2rem auto;
}
.journal-post {
  background-color: #fcfcfc;
  padding: 20px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.recent-post img {
  width: 100%;
  height: auto;
  margin-bottom: 1rem;
}
.journal-post h3 {
  font-size: 1.2rem;
  margin: 2rem;
}
.journal-post.small-post {
  flex: 1;
  padding: 1.5rem;
}
.post-footer {
  display: flex;
  justify-content: space-between;
  font-size: 0.9rem;
  color: #271b1c;
}
.journal-right-column {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 100%;
  gap: 20px;
}
.post-footer span {
  font-family: "IBM Plex Mono", monospace;
  font-size: medium;
}

/* Contact */
.contact {
  font-family: "Quicksand", sans-serif;
  font-weight: 500;
  font-size: 30px;
  text-align: center;
  padding: 12rem 2rem;
  color: #271b1c;
}
.contact p {
  font-family: "Quicksand", sans-serif;
  font-weight: 500;
  font-size: 2rem;
  margin-bottom: 1.5rem;
  line-height: 1.4;
}
.contact-button {
  display: inline-block;
  padding: 0.75rem 2rem;
  background-color: #271b1c;
  color: #e6def3;
  text-decoration: none;
  font-weight: 500;
  border: none;
  border-radius: 3px;
  transition: background-color 0.4s ease;
}
.contact-button:hover {
  background-color: #634c88;
}

/* Footer (ALL PAGES) */
footer {
  margin-top: 3rem;
  text-align: center;
}
.footer-container {
  background-color: #fcfcfc;
  margin: 24px;
  padding: 2rem 3rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  text-align: left;
}
.footer-left img {
  width: 100px;
}
.footer-right {
  text-align: center;
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
  color: #271b1c;
}
.footer-right h2 {
  margin-top: 0;
}
.footer-links {
  display: flex;
  gap: 1rem;
}
.footer-links a {
  font-family: "Quicksand", sans-serif;
  font-weight: 500;
  font-size: 20px;
  text-decoration: none;
  color: #271b1c;
  transition: color 0.3s ease;
}
.footer-links a:hover {
  color: #634c88;
}
.footer-bottom {
  font-size: 0.9rem;
  margin-top: 1.5rem;
  color: #271b1c;
}

/* 404 PAGE */
.not-found {
  text-align: center;
  padding: 100px 20px;
  font-family: "Quicksand", sans-serif;
  position: relative;
  overflow: hidden;
}
.not-found a {
  color: #634c88;
  text-decoration: underline;
}
.error-code {
  font-size: 5rem;
  font-weight: 700;
  color: #634c88;
  margin: 0;
}
.error-message {
  font-size: 2rem;
  font-weight: 700;
  color: #271b1c;
  margin: 10px 0 30px 0;
}
.bug-img {
  width: 80px;
  position: absolute;
  top: 60%;
  left: -100px;
  animation: crawl-turning-beetle 20s linear infinite alternate;
  transform-origin: center center;
}

/* PROJECTS PAGE */
.projects-page {
  max-width: 900px;
  margin: 2rem auto;
  padding: 0 1rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
.project-card {
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  background-color: #e6def3;
}
.project-card,
.accordion-content {
  text-align: left;
}
/* View Project/code */
.project-links {
  text-align: center;
  margin-top: 1rem;
}
.project-links a {
  display: inline-block;
  color: #271b1c;
  text-decoration: none;
  font-weight: 500;
}
.project-links a:hover {
  color: #634c88;
}
/* Accordion button */
.accordion-btn {
  width: 100%;
  padding: 1rem;
  font-size: 1.2rem;
  font-weight: 600;
  text-align: left;
  background-color: #e6def3;
  color: #271b1c;
  border: none;
  cursor: pointer;
  transition: background 0.3s ease;
}
.accordion-btn:hover {
  background-color: #dcd5e7;
}
/* Accordion content - hidden by default */
.accordion-content {
  display: none;
  padding: 1rem;
  background-color: #fcfcfc;
  border-top: 1px solid #ddd;
}
.accordion-content a {
  display: inline-block;
  margin-top: 1rem;
  color: #271b1c;
  text-decoration: none;
  font-weight: 500;
}
.accordion-content a:hover {
  color: #634c88;
}
.accordion-content img {
  display: block;
  margin: 1rem auto;
  max-width: 50%;
  height: auto;
}

/* APD Flyers images */
.apd-row {
  display: flex;
  flex-wrap: wrap;
  padding: 0 4px;
}
.apd-column {
  display: block;
  margin: auto;
  flex: 25%;
  max-width: 25%;
  padding: 0 4px;
}
.apd-column img {
  display: block;
  margin: 1rem auto;
  max-width: 250px;
  height: auto;
}

/* JOURNAL PAGE */
.blog-index {
  display: grid;
  gap: 2rem;
  padding: 2rem 1rem;
}
.blog-card {
  background-color: #fcfcfc;
  padding: 1.5rem;
  border-radius: 12px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
  transition: transform 0.2s;
  text-align: center;
}
.blog-card:hover {
  transform: translateY(-5px);
}
.blog-card a {
  text-decoration: none;
  color: inherit;
}
.blog-card h3 {
  text-align: center;
}
.blog-card .post-excerpt {
  text-align: left;
}
.post-date {
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.9rem;
  color: #634c88;
  text-align: center;
}
.blog-post {
  padding: 2rem 1rem;
}
.blog-post h1 {
  text-align: center;
}
.blog-post p {
  text-align: left;
  max-width: 700px;
  margin: 0 auto 1.5rem auto;
}

/* BREADCRUMBS */
.breadcrumbs {
  font-size: 0.9rem;
  margin: 1rem 2rem;
  font-family: "IBM Plex Mono", monospace;
}
.breadcrumbs a {
  text-decoration: none;
  color: #634c88;
}
.breadcrumbs span {
  color: #271b1c;
}

/* Animations */

/* HOME/MAIN PAGE */
/* Arrow Scroll smooth */
html {
  scroll-behavior: smooth;
}
/* Arrow moves */
@keyframes bounce {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(10px);
  }
}

/* Hello blinking cursor */
@keyframes typing {
  from {
    width: 0;
  }
  to {
    width: 6ch;
  }
}
@keyframes blink {
  50% {
    border-color: transparent;
  }
}

/* Beetle crawling zigzag */
@keyframes crawl-turning-beetle {
  0% {
    transform: translate(0vw, 0vh) rotate(0deg);
  }
  20% {
    transform: translate(20vw, -10vh) rotate(315deg); /* Up-right */
  }
  40% {
    transform: translate(40vw, 10vh) rotate(45deg); /* Down-right */
  }
  60% {
    transform: translate(60vw, -8vh) rotate(315deg);
  }
  80% {
    transform: translate(80vw, 12vh) rotate(45deg);
  }
  100% {
    transform: translate(100vw, 0vh) rotate(0deg); /* Right end */
  }
}

/* MEDIA QUERIES */
/* Hide from desktop */
#hamburger {
  display: none;
}

/* Tablet */
@media (max-width: 1024px) {
  /* Navigation */
  .navbar-options {
    display: none;
    position: absolute;
    background-color: rgba(230, 222, 243, 0.8);
    backdrop-filter: blur(10px);
    top: 124px;
    right: 0;
    width: 100%;
    padding: 1rem;
  }

  .navbar-options.active {
    display: block;
  }
  .navbar-options ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 1rem;
  }
  .navbar-options ul li a {
    text-decoration: none;
    font-size: 1.2rem;
    color: #271b1c;
  }
  #hamburger {
    display: block;
    font-size: 2rem;
    cursor: pointer;
    margin-right: 32px;
  }

  /* Hero/Intro */
  .hero p {
    width: 100%;
  }

  /* Skill Home/Main */
  .skill {
    width: 250px;
  }

  /* Projects Home/Main */
  .projects {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    padding: 2rem;
    align-items: center;
  }

  .project p {
    padding: 10px;
    align-items: center;
  }

  .project img {
    width: 300px;
    height: 250px;
    align-items: center;
  }
}

/* Mobile phones */
@media (max-width: 768px) {
  /* Navigation */
  .navbar-options {
    display: none;
    position: absolute;
    background-color: rgba(230, 222, 243, 0.9);
    backdrop-filter: blur(10px);
    top: 124px;
    right: 0;
    width: 100%;
    padding: 1rem;
  }
  .navbar-options.active {
    display: block;
  }
  .navbar-options ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 1rem;
  }
  .navbar-options ul li a {
    text-decoration: none;
    font-size: 1.2rem;
    color: #271b1c;
    transition: color 0.3s ease;
  }
  .navbar-options ul li a:hover {
    color: #634c88;
  }
  #hamburger {
    display: block;
    font-size: 2rem;
    cursor: pointer;
    margin-right: 32px;
  }

  /* Hero/Intro Main */
  .hero {
    text-align: center;
  }
  .hero h1 {
    font-size: 3rem;
    width: auto;
    border-right: none;
  }
  .hero p {
    width: 100%;
  }
  .rectangle-container {
    position: relative;
    display: flex;
    flex-direction: column;
    height: auto;
    gap: 1rem;
    background-color: #fcfcfc;
    padding: 28px 0;
  }
  .content-container {
    display: flex;
    flex-direction: column;
    align-items: center;
  }
  .mobile-intro-img {
    display: block;
    width: 100%;
    height: auto;
  }
  .mobile-intro-img img {
    width: 350px;
    height: auto;
  }
  .intro-img {
    display: none;
  }
  .intro-text {
    margin: 0 3rem;
  }
  .intro-text:nth-child(1),
  .currently {
    order: 1;
  }
  .intro-text:nth-child(2),
  .fueled {
    order: 2;
  }

  /* About Home/Main */
  .about {
    flex-direction: column;
    text-align: center;
  }
  .about img {
    width: 80%;
    max-width: 300px;
  }
  .about p {
    text-align: left;
    font-size: 1rem;
    padding: 0 1rem;
  }

  /* Projects Home/Main */
  .projects {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    gap: 1rem;
    padding: 1rem;
  }
  .project {
    min-width: 80%;
    flex: 0 0 auto;
    scroll-snap-align: center;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
  }
  .project img {
    width: 300px;
    height: 240px;
    border-radius: 8px 8px 0 0;
  }
  .project h3,
  .project p {
    padding: 0 1rem;
  }
  .view-link {
    display: block;
    text-align: center;
    margin-top: 1rem;
  }

  /* Skills Home/Main */
  .skill {
    width: 300px;
  }

  /* Journal Home/Main */
  .journal-container {
    display: flex;
    flex-direction: column;
  }
  .journal-right-column {
    display: flex;
    flex-direction: column;
    gap: 20px;
  }
  .journal-post h3 {
    margin: 1rem 0;
  }

  /* Projects */
  .accordion-content img {
    max-width: 70%;
  }

  .apd-column {
    flex: 100%; /* apd projects imgs stack on top*/
    max-width: 100%;
  }

  /* Footer */
  .footer-container {
    flex-direction: column;
  }
}
