* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

#section-about,
#section-projects,
#section-contact {
  padding: 8rem 2rem;
  margin: 0 auto;
}

.menuButton {
  display: none;
}

h1 {
  font-size: clamp(2rem, 4vw, 5.6rem) !important;
}

h3 {
  font-size: clamp(1.6rem, 1.67vw, 2.4rem) !important;
}

p {
  font-size: clamp(1.1rem, 1.5vw, 1.8rem);
  line-height: 1.6;
}

:root {
  --background: #f4f5f2;
  --headerColour: #e9ebe6;
  --primaryText: #1b1f1a;
  --bodyText: #495057;
  --primaryAccent: #3b7a57;
  --buttonText: rgba(255, 255, 255, 0.8);
  --secondaryAccent: #1f4735;
  --borders: #7c8a79;
  --year: #ced4da;
  --webDev: #93c5fd;
  --uiux: #bae6fd;
  --tagColor: #343a40;
  --iconFill: #1b1f1a;
}

.darkmode {
  --background: #121212; /* deep neutral charcoal */
  --headerColour: #0c0c0c;
  --primaryText: #e5e5e5; /* soft light gray for high contrast */
  --bodyText: #c5c6c7; /* slightly dimmer gray for paragraphs */
  --primaryAccent: #58a6ff; /* vivid blue accent for links/buttons */
  --buttonText: #ffffff; /* bright white for button text */
  --secondaryAccent: #9d79f2; /* elegant violet secondary highlight */
  --borders: #575b5f; /* muted border gray */
  --year: #9ca3af; /* subtle gray for dates/timestamps */
  --webDev: #34d399; /* teal-green tag color */
  --uiux: #f472b6; /* pinkish tag color for contrast */
  --tagColor: #e5e7eb; /* light gray for tag text */
  --iconFill: #e5e7eb;
}

.text {
  font-family: "Inter", sans-serif;
  text-align: center;
}

.heading {
  font-family: "Montserrat", sans-serif;
  text-align: center;
}

.webDev {
  background-color: var(--webDev);
  padding: 0.3rem 0.6rem;
  border-radius: 20px;
}

.uiux {
  background-color: var(--uiux);
  padding: 0.3rem 0.6rem;
  border-radius: 20px;
}

body {
  font-size: 62.5%;
  color: var(--primaryText);
  background-color: var(--background);
}

.header {
  top: 0;
  padding: 0.8rem 1.6rem;
  width: 100%;
  height: 4.2rem;
  display: flex;
  flex-wrap: wrap;
  align-content: start;
  justify-content: space-between;
  transition: background-color 0.3s ease, box-shadow 0.3s ease,
    transform 0.3s ease, opacity 0.3s ease;
  transform: translateY(-10px);
  opacity: 0.95;
}

.header.sticky {
  position: fixed;
  background-color: var(--headerColour);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  transform: translateY(0); /* Slide down smoothly */
  opacity: 1;
  z-index: 1000;
}

.nav {
  padding: 0.6rem 1.2rem;
  flex: 1;
  align-self: center;
  justify-self: center;
}

.nav .mainbar {
  list-style: none;
  display: flex;
  gap: 1.8rem;
  flex-wrap: wrap;
  align-content: center;
}

.navItem:any-link,
.navItem:visited {
  text-decoration: none;
  display: block;
  font-size: 1.2rem;
  font-weight: 500;
  color: var(--primaryText);
  transition: all 0.1s;
}

.navItem:hover {
  color: var(--primaryAccent);
  transform: scale(1.05);
}

.header h1 {
  font-size: 2.6rem;
  display: block;
}

#theme-switch {
  background: none;
  border: none;
  height: 3rem;
  width: 3rem;
  border-radius: 50%;
  background-color: rgba(0, 0, 0, 0);
  display: flex;
  justify-content: center;
  align-items: center;
  transition: all 0.1s;
  top: 20px;
}

#theme-switch:hover {
  cursor: pointer;
  transform: scale(1.1);
}

#theme-switch svg {
  outline: none;
  border: none;
}

#theme-switch svg:last-child {
  display: none;
}

.darkmode #theme-switch svg:first-child {
  display: none;
}

.darkmode #theme-switch svg:last-child {
  display: block;
}

.sidebar {
  display: none;
  padding: 1.6rem 3.2rem;
  position: fixed;
  top: 0;
  left: 0;
  height: 100vh;
  width: 15rem;
  z-index: 1001;
  background-color: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(20px);
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.4);
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-start;
  gap: 1.6em;
}

.sidebar li {
  width: 100%;
  text-align: right;
  list-style: none;
}
.sidebar li a {
  width: 100%;
  text-align: right;
}

#section-home {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2.4rem;
}

#section-home .headline {
  color: var(--primaryText);
  font-size: 3.2rem;
}

#section-home .tagline {
  color: var(--primaryAccent);
  font-size: 3rem;
}

#section-home .img {
  width: 20rem;
  height: 20rem;
  justify-self: center;
}

#section-home .img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: bottom;
  border-radius: 50%;
  border: 5px solid var(--borders);
  transition: all 0.15s;
}

#section-home .img img:hover {
  transform: scale(1.03);
  box-shadow: 0 0 15px rgba(0, 0, 0, 0.5);
}

#section-home .desc {
  font-size: 1.2rem;
  width: 40rem;
}

#section-about {
  display: flex;
  align-items: center;
  justify-content: space-evenly;
}

#section-about .desc {
  width: 50rem;
  display: flex;
  flex-direction: column;
  align-items: left;
  gap: 0.8rem;
}

#section-about .heading,
#section-projects .head,
#section-contact .heading {
  text-align: left;
  font-size: 4.8rem;
}

#section-about .desc .content {
  font-size: 1.2rem;
  text-align: left;
  width: 50rem;
  color: var(--bodyText);
  letter-spacing: 1px;
  line-height: 1.3;
}

#section-about .skills {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: repeat(2, 1fr);
  column-gap: 0.8rem;
  row-gap: 0.8rem;
}

#section-about .skill {
  font-size: 1rem;
  color: var(--borders);
  border: 1px solid var(--borders);
  padding: 0.2rem 0.4rem;
  border-radius: 5px;
  transition: all 0.1s;
}
#section-about .skill:hover {
  transform: scale(1.1);
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.2);
  cursor: pointer;
}

#section-projects {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

#section-projects .desc .content {
  font-size: 1.2rem;
  text-align: left;
  width: 75rem;
  color: var(--bodyText);
  letter-spacing: 1px;
  line-height: 1.3;
}

#section-projects .wrapper {
  display: flex;
  justify-self: center;
  align-items: center;
  gap: 1.6rem;
}

#section-projects .card {
  text-decoration: none;
  width: 24rem;
  padding: 0.8rem 1.6rem;
  display: flex;
  flex-direction: column;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
  border-radius: 20px;
  align-items: center;
  gap: 0.4rem;
  transition: all 0.15s;
}

#section-projects .card .link {
  text-decoration: none;
  text-align: center;
  font-family: "Inter", sans-serif;
}

#section-projects .card:hover {
  transform: scale(1.02);
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
  cursor: pointer;
}

.card .type-time {
  display: flex;
  width: 21.5rem;
  justify-content: space-between;
}

.card .type {
  color: var(--tagColor);
  font-size: 1rem;
}

.card .time {
  text-align: center;
  padding: 0.25rem 0.8rem;
  border-radius: 20px;
  background-color: var(--year);
  font-size: 1rem;
}

.card .heading {
  width: 21.5rem;
  font-weight: 500;
  text-align: left;
  font-size: 1.6rem;
}

.card .text {
  width: 21.5rem;
  text-align: left;
  font-size: 1rem;
}

#section-projects .card .img {
  width: 22rem;
  height: 10rem;
  justify-self: center;
  overflow: hidden;
}

#section-projects .card .img img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

#section-contact {
  display: flex;
  justify-content: space-evenly;
  align-items: center;
}

#section-contact .desc {
  display: flex;
  flex-direction: column;
  gap: 1.6rem;
}

#section-contact .content {
  text-align: left;
  font-size: 1.2rem;
  width: 30rem;
}

#section-contact h3 {
  font-size: 2.4rem;
  font-family: "Montserrat", sans-serif;
}

#section-contact .socials {
  padding-top: 1rem;
  display: flex;
  gap: 2.4rem;
  justify-self: center;
}

#section-contact .socials .icon {
  width: 2rem;
  fill: var(--iconFill);
}

#section-contact .socialitem:any-link,
#section-contact .socialitem:visited {
  transition: all 0.1s;
}

#section-contact .socialitem:hover {
  transform: scale(1.1);
}

.download:any-link,
.downlaod:visited {
  font-size: 1.2rem;
  letter-spacing: 0.1px;
  text-decoration: none;
  font-family: "Montserrat", sans-serif;
  transition: all 0.1s;
}

.download:hover {
  font-weight: 500;
  transform: scale(1.01);
}

.btn {
  width: 8rem;
  padding: 0.3rem 0.6rem;
  font-size: 1.2rem;
  background-color: var(--primaryAccent);
  color: var(--buttonText);
  border: none;
  border-radius: 10px;
}

.btn:hover {
  background-color: var(--secondaryAccent);
  cursor: pointer;
}

form {
  display: flex;
  flex-direction: column;
  gap: 3.2rem;
}

.custom-input {
  color: var(--bodyText);
  border-radius: 0;
  font-size: 1.2rem;
  padding: 0.2rem 0.4rem;
  width: 30rem;
  border: none;
  border-bottom: 1px solid var(--borders);
  background-color: rgba(0, 0, 0, 0);
}

.custom-input:focus {
  border: none;
  outline: none;
  border-bottom: 2px solid black;
}

.space {
  padding-top: 10rem;
}

#status {
  text-align: left;
  padding-top: 1rem;
  font-size: 1rem;
}

.site-footer {
  text-align: center;
  color: #777;
  padding: 2rem 1rem;
  background: #f8f8f8; /* or match your theme */
}

.site-footer p {
  font-size: 1.1rem;
}

.site-footer a {
  color: inherit;
  text-decoration: underline;
}
