:root {
  /* Colors */
  --main-clr: #ff7aa6;
  --white: #fff;

  /* Font Sizing */
  --font-size-heading: 6rem;

  --font-size-heading-max: calc(var(--font-size-heading) * 1.5);

  --font-size-head: calc(var(--font-size-heading) * 0.85);

  --font-size-subtitle: calc(var(--font-size-heading) * 0.66);

  --font-size-subhead: calc(var(--font-size-heading) * 0.43);

  --font-size-sub: calc(var(--font-size-heading) * 0.3);

  --font-size-link: calc(var(--font-size-heading) * 0.17);

  --font-size-text: 1rem;

  --font-size-small: 0.85rem;

  /*utility */
  --nav-padding: 1.5rem 3rem;
  --button-padding: 1rem 3rem;
  --section-padding: 1.5rem;

  --border-rad: 5px;
  --border-rad-medium: 15px;

  --transition-normal: 0.3s ease-in-out;
  --box-shadow-black: 0px 4px 15px rgba(0, 0, 0, 0.3);
  --box-shadow-white: 0px 4px 15px rgba(255, 255, 255, 0.75);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: "Roboto Mono", monospace;
}

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
}

body {
  background-color: #202020;
  position: relative;
  overflow-x: hidden;
  overflow-y: hidden;
}

a {
  text-decoration: none;
  color: #ffffff;
}

textarea {
  resize: none;
}

/* Navigation Bar */
.header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--nav-padding);
}

.navbar ul {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 1.5rem;
  list-style: none;
}

.navlink a {
  text-decoration: none;
  transition: var(--transition-normal);
  font-size: 1.6rem;
}

.navlink a:hover {
  transition: var(--transition-normal);
  color: var(--main-clr);
}

#toggle-menu {
  display: none;
  border: none;
  padding: 0.25rem;
  background-color: transparent;
  cursor: pointer;
  color: var(--white);
  transition: var(--transition-normal);
}

#toggle-menu:hover {
  color: var(--main-clr);
  transition: var(--transition-normal);
}

#toggle-menu i {
  font-size: var(--font-size-subhead);
}

#toggle-menu-close {
  display: none;
  border: none;
  padding: 0.25rem;
  background-color: transparent;
  cursor: pointer;
  color: var(--white);
  transition: var(--transition-normal);
}

#toggle-menu-close:hover {
  color: var(--main-clr);
  transition: var(--transition-normal);
}

#toggle-menu-close i {
  font-size: var(--font-size-sub);
}

.mobile-menu-active {
  position: fixed;
  width: 250px;
  height: 100svh;
  top: 0;
  right: 0;
  z-index: 999;
  background-color: var(--main-clr);
  transition: var(--transition-normal);
  padding: 1rem;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  justify-content: flex-start;
  gap: 1rem;
}

.mobile-menu-inactive {
  position: fixed;
  width: 250px;
  height: 100svh;
  top: 0;
  right: -250px;
  z-index: 999;
  background-color: var(--main-clr);
  transition: var(--transition-normal);
  padding: 1rem;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  justify-content: flex-start;
  gap: 1rem;
}

/* Main Section */
.main {
  background: linear-gradient(rgba(0, 0, 0, 0.9), rgba(0, 0, 0, 0.2)),
    url("/images/digitalization-3.jpg");
  background-size: cover;
  background-repeat: no-repeat;
  background-position: center;
}

.main-container {
  min-height: 70vh;
  width: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 2rem;
  align-items: center;
}

.main-text {
  animation: moveInLeftText;
  animation-duration: 7.5s, 7500ms;
}

.main-text h1 {
  font-size: var(--font-size-head);
  color: var(--white);
}

.main-text p {
  color: var(--main-clr);
  font-size: var(--font-size-sub);
}

.main-text h3 {
  color: var(--main-clr);
  font-weight: 700;
  font-size: var(--font-size-subhead);
  text-align: center;
}

.logo-container h2 {
  color: var(--white);
  font-size: var(--font-size-subhead);
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 0.25rem;
}

.logo-container h2:hover {
  color: var(--main-clr);
}

.mobile-menu-active .logo-container h2 {
  font-size: var(--font-size-sub);
}

.mobile-menu-inactive .logo-container h2 {
  font-size: var(--font-size-sub);
}

.logo-text:hover {
  cursor: pointer;
  color: #ff7aa6;
}

.button {
  width: max-content;
  display: flex;
  align-items: center;
  gap: 0.25rem;
  justify-content: center;
  padding: var(--button-padding);
  border-radius: var(--border-rad);
  background-color: var(--main-clr);
  border: 1px solid white;
  position: relative;
  animation: moveInBottom;
  animation-duration: 7.5s, 7500ms;
  transition: var(--transition-normal);
  box-shadow: var(--box-shadow-black);
  font-size: var(--font-size-text);
}

.button:hover {
  transition: var(--transition-normal);
  transform: translateY(-4px);
  box-shadow: var(--box-shadow-white);
  background-color: transparent;
  box-shadow: 0 0 15px 5px rgba(255, 255, 255, 0.7);
}

.button-learn {
  font-family: "Roboto Mono", monospace;
  font-size: 1rem;
  font-weight: 400;
  color: #ffffff;
  text-decoration: none;
  text-transform: uppercase;
}

.bar {
  height: 115px;
  background-color: var(--white);
  border: solid 1px var(--white);
}

.sidebar-left {
  position: fixed;
  bottom: 0;
  left: 25px;
  color: #d7d7d9;
  animation: moveInLeft;
  animation-duration: 7000ms;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1.25rem;
  font-size: 20px;
  z-index: 1;
}

.sidebar-right {
  position: fixed;
  bottom: 0;
  right: 25px;
  color: #d7d7d9;
  animation: moveInRight;
  animation-duration: 7000ms;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1.25rem;
  z-index: 2;
}

.sidebar-right a {
  display: block;
  transform: rotate(90deg);
  display: block;
  margin-bottom: 280px;
  width: 20px;
  font-weight: 400;
  font-size: 20px;
  transition: var(--transition-normal);
}

.sidebar-right a:hover {
  transition: var(--transition-normal);
  color: var(--main-clr);
}

.fa-brands {
  color: white;
}

.fa-brands:hover {
  color: #ff7aa6;
  transform: translateY(-3px);
}

/* About Me Section */
.aboutme {
  width: 100%;
  padding: var(--section-padding);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
  gap: 2rem;
  margin-top: 7rem;
}

.about-me {
  flex-direction: column;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
}

.about-me h2 {
  width: 70%;
  font-size: var(--font-size-head);
  color: var(--main-clr);
}

.about-me p {
  font-size: 1.4rem;
  color: var(--white);
  line-height: 1.5;
  font-weight: 300;
  width: 70%;
}

.about-me strong {
  font-weight: 600;
  font-style: italic;
}

.about-me-photo {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
}

.about-me-photo img {
  width: 350px;
  border-radius: var(--border-rad-medium);
  border: solid 2px var(--white);
  height: auto;
  object-fit: contain;
}

/* Skills Section */
.skills-section {
  flex-direction: column;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  margin-top: 7rem;
}

.skills h2 {
  font-size: var(--font-size-head);
  color: var(--main-clr);
  align-items: center;
  text-align: center;
  justify-content: center;
}

.skills-list-type {
  display: grid;
  margin-top: 65px;
  grid-template-columns: 1fr 1fr 1fr;
  grid-template-rows: 1fr 1fr 1fr;
  justify-items: center;
  align-items: center;
  width: 100%;
  display: flex;
  gap: 80px;
  cursor: pointer;
}

.skills-list {
  list-style: none;
  font-size: 1.6rem;
  color: #7c7c7c;
}

.skills-list:hover {
  color: #ffc0cb;
  transform: rotate(8deg) scale(1.2);
}

.projects-title {
  font-size: var(--font-size-head);
  color: var(--main-clr);
  align-items: center;
  text-align: center;
  justify-content: center;
  margin-top: 180px;
}

#projects p {
  font-size: 1.6rem;
}

.contact-section {
  background-color: #646464;
  color: #ffffff;
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 90px auto;
  max-width: 800px;
  box-sizing: border-box;
  border-radius: 10px;
  box-shadow: 0px 4px 15px rgba(0, 0, 0, 0.1);
}

.contact-content {
  max-width: 1000px;
  margin: 0 auto;
}

.contact-header {
  margin-bottom: 60px;
}

.contact-title,
.get-in-touch {
  color: #ff7aa6;
  margin: 0;
  font-size: var(--font-size-head);
  text-align: center;
}

.contact-statement {
  color: #ffffff;
  margin-top: 20px;
  font-size: 1.6rem;
}

.form {
  width: 100%;
  display: flex;
  justify-content: center;
}

.contact-form {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  width: 100%;
  margin: 0 auto;
  padding: 30px;
}

.form-group {
  position: relative;
}

.form-input,
textarea {
  width: 70%;
  padding: 15px 38px;
  border: 1px solid #d7d7d9;
  border-radius: 5px;
  font-size: 1.6rem;
  color: #ffffff;
  background-color: #333;
  box-sizing: border-box;
}

.form-label {
  position: absolute;
  top: 10px;
  left: 10px;
  color: #d7d7d9;
  transition: all 0.3s ease;
  pointer-events: none;
}

.form-input:focus+.form-label,
.form-input:not(:placeholder-shown)+.form-label {
  top: -8px;
  left: 8px;
  font-size: 12px;
  color: #ff7aa6;
}

.button-form {
  width: max-content;
  font-size: 1rem;
  justify-content: center;
  padding: 15px 30px;
  border-radius: 5px;
  cursor: pointer;
  background-color: #ff88b0eb;
  color: #ffffff;
  border: 2px solid white;
  position: relative;
  margin-top: 20px;
  animation: moveInBottom;
  animation-duration: 7.5s, 7500ms;
  transition: background-color 0.3s ease;
  box-shadow: 0px 4px 15px rgba(0, 0, 0, 0.239);
}

.button-form:hover {
  transform: translateY(-4px);
  box-shadow: #ffffff;
  background-color: rgb(115, 115, 115);
  border: 2px solid white;
  box-shadow: 0 0 15px 5px rgba(255, 255, 255, 0.7);
}

.footer-logo-text {
  font-size: 1.3rem;
  margin-top: 50px;
  font-family: "Roboto Mono", monospace;
  color: #ffffff;
  text-align: center;
}

.footer-logo-text:hover {
  cursor: pointer;
  color: #ff7aa6;
}

.copyright {
  font-family: monospace;
  font-weight: 600;
  font-size: 18px;
  text-align: center;
  color: #d7d7d9;
  margin-bottom: 20px;
}

.back-to-top-btn {
  position: fixed;
  bottom: 20px;
  right: 100px;
  z-index: 1000;
}

.back-to-top-link {
  background-color: #ff7aa6;
  color: #ffffff;
  padding: 10px 15px;
  border-radius: 5px;
  text-decoration: none;
  display: flex;
  align-items: center;
  border: 2px solid white;
  box-shadow: 0px 4px 15px rgba(0, 0, 0, 0.349);
}

.back-to-top-link:hover {
  background-color: #e0e0e047;
  box-shadow: 0px 4px 15px rgba(255, 255, 255, 0.705);
}

.back-to-top-link i {
  margin-left: 12px;
}

#projects {
  font-family: "Roboto Mono", monospace;
}

.projects-section {
  align-items: center;
}

.container {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  flex-direction: column;
  margin: 0 auto;
}

.container:hover img {
  opacity: 0.3;
}

.container:hover .middle {
  opacity: 1;
}

img {
  cursor: pointer;
}

img:hover {
  opacity: 0.3;
}

.middle {
  transition: 0.3s ease;
  opacity: 0;
  position: absolute;
  top: 55%;
  left: 50%;
  transform: translate(-50%, -50%);
}

.text {
  background-color: #1e1e1eb4;
  color: white;
  font-size: 16px;
  padding: 1rem 2rem;
  border-radius: 5px;
}

.text:hover {
  cursor: pointer;
  background-color: #000000;
}

.project-label {
  font-size: 1.8rem;
  color: #646464;
  margin-top: 100px;
}

.featured-project {
  font-size: 1.4rem;
  font-weight: 550;
  color: #ff8eb3;
  margin-top: 1.25rem;
}

.project-info {
  color: #d7d7d9;
  margin: 2rem 0;
  font-size: 1.3rem;
  padding: 0 230px;
}

.programming-language {
  font-size: 1.4rem;
  color: #d7d7d9;
  margin-top: 3rem;
  font-weight: 300;
}

.dice-duel-pic {
  /* width: 60rem; */
  width: 100%;
  /* Make the image responsive */
  max-width: 600px;
  /* Set a max width for larger screens */
  margin-top: 2rem;
}

.projects-feature-dice {
  /* padding: 0 5rem 0 2.5rem; */
  text-align: center;
  padding: 0 2rem;
}

.view-code {
  color: #d7d7d9;
  font-weight: 600;
}

.view-code:hover {
  cursor: pointer;
  color: #ff7aa6;
}

#myLinks a {
  display: none;
}

/* Media Queries for Desktop Screens */

/* Media Queries for Tablets */
/* Media Queries for Responsive Adjustments */

/* Main */
@media (min-width: 1200px) {

  /* Tablet Styles */
  .projects-section {
    grid-template-columns: 1fr 1fr;
  }

  /* Adjust styles as needed */
}

/* Tablet */
@media (max-width: 800px) {
  /* Tablet Styles */
  /* Adjust styles as needed */

  :root {
    --font-size-heading: 4rem;

    /*utility */
    --nav-padding: 1.5rem 2.5rem;
    --button-padding: 0.75rem 1.5rem;
  }

  .about-me h2 {
    width: 100%;
  }

  .about-me p {
    width: 100%;
    font-size: var(--font-size-sub);
  }

  .navbar {
    display: none;
  }

  #toggle-menu {
    display: inline-block;
  }

  #toggle-menu-close {
    display: inline-block;
  }

  .mobile-menu-active .logo-container h2 {
    font-size: var(--font-size-sub);
  }

  .mobile-menu-inactive .logo-container h2 {
    font-size: var(--font-size-sub);
  }

  .sidebar-right a {
    font-size: 15px;
    margin-bottom: 215px;
  }

  .aboutme {
    grid-template-columns: 1fr;
  }

  .about-me-photo img {
    width: 300px;
  }

  .about-me h2 {
    text-align: center;
  }

  .about-me p {
    text-align: center;
  }

  .sidebar-left {
    left: 10px;
  }

  .sidebar-right {
    right: 10px;
  }

  .skills-section {
    margin-top: 4rem;
    /* Reduce top margin to save space */
    gap: 0.5rem;
    /* Slightly reduce the gap between elements */
  }

  .skills-list {
    list-style: none;
    font-size: 1.8rem;
  }

  .skills h2 {
    font-size: calc(var(--font-size-head) - 1rem);
    /* Reduce font size slightly */
    text-align: center;
  }

  .skills-list-type {
    display: grid;
    grid-template-columns: 1fr 1fr;
    /* Switch to two columns */
    grid-template-rows: auto;
    /* Adjust rows automatically */
    gap: 40px;
    /* Reduce gap between grid items */
    width: 100%;
    justify-items: center;
    align-items: center;
    margin-top: 40px;
    /* Reduce top margin to bring grid closer */
  }
}

/* Cellphone */
@media (max-width: 500px) {
  /* Mobile Styles */

  .main-text h1 {
    font-size: var(--font-size-subtitle);
    text-align: center;
  }

  :root {
    --font-size-heading: 3rem;

    /*utility */
    --nav-padding: 1.75rem 2rem;
  }

  .skills-list-type {
    display: flex;
    flex-direction: column;
    margin-top: 65px;
    justify-items: center;
    align-items: center;
    width: 100%;
    gap: 40px;
    cursor: pointer;
  }

  .skills-list {
    list-style: none;
    font-size: 1.4rem;
    color: #7c7c7c;
  }

  /* Modify .projects-section for mobile */
  .projects-section {
    display: flex;
    flex-direction: column;
    /* Stack elements vertically */
    justify-content: space-between;
    padding: 10px;
  }

  /* Ensure .container comes underneath .projects-section */
  .projects-section,
  .container {
    margin-top: 20px;
    /* Add space between the sections */
  }

  .container,
  .projects-feature-dice {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2rem;
  }

  .dice-duel-pic {
    max-width: 100%;
    /* Ensure the image fits within its container */
    height: auto;
    /* Maintain aspect ratio */
  }

  .middle .text {
    margin-top: 10px;
  }

  .middle .text a {
    display: inline-block;
    background-color: #000;
    color: #fff;
    padding: 10px 20px;
    text-decoration: none;
    border-radius: 5px;
  }

  .projects-feature-dice {
    margin-top: 20px;
    padding: 0 10px;
    text-align: center;
  }

  #projects p {
    font-size: 1.2em;
    padding: 20px;
  }

  .featured-project,
  .project-label,
  .project-info,
  .programming-language {
    margin: 10px 0;
  }

  .view-code a {
    text-decoration: none;
  }

  .contact-section {
    margin: 20px auto;
    padding: 15px;
    max-width: 90%;
    box-shadow: none;
    border-radius: 10px;
  }

  .contact-content {
    max-width: 100%;
    padding: 0 15px;
  }

  .contact-header {
    margin-bottom: 40px;
  }

  .contact-title,
  .get-in-touch {
    font-size: 1.2em;
  }

  .contact-statement {
    font-size: 0.8em;
  }

  /* Form inputs are centered and don't touch the edges */
  .form {
    width: 100%;
  }

  .contact-form {
    width: 100%;
    max-width: 90%;
    /* Add some space to the sides */
    padding: 20px;
    margin: 0 auto;
    /* Center the form */
    box-sizing: border-box;
  }

  .form-input,
  textarea {
    width: 100%;
    /* Ensure inputs are full width */
    max-width: 400px;
    /* Limit the input size so it doesn’t stretch too wide */
    padding: 12px;
    font-size: 14px;
  }

  .button-form {
    width: auto;
    padding: 10px 20px;
    margin-top: 15px;
    font-size: 0.9rem;
  }
}