/* @import url('https://fonts.googleapis.com/css2?family=Hanken+Grotesk:ital,wght@0,100..900;1,100..900&family=Hedvig+Letters+Serif:opsz@12..24&family=Indie+Flower&display=swap'); */

@import url('https://fonts.googleapis.com/css2?family=Fraunces:ital,opsz,wght@0,9..144,100..900;1,9..144,100..900&family=Hanken+Grotesk:ital,wght@0,100..900;1,100..900&family=Indie+Flower&display=swap');

*, *::before, *::after {
  box-sizing: border-box;
}

:root {
  --background: var(--color-bridal-heath);
  --background-dark: var(--color-mirage);
  --text-color: #222;
  --font-serif: 'Fraunces', serif;
  --font-sans-serif: 'Hanken Grotesk', sans-serif;
  --color-green: 2, 89, 28;
  --color-red: 255, 99, 71;
  --color-blue: 48, 79, 254;
  --color-purple: 108, 99, 255;
  --color-yellow: 255, 180, 0;
  --color-black: 51, 60, 60;
  --color-white: 255, 255, 255;
  --project-backgroud-opacity: 0.4;
  --project-item-opacity: 0.8;

  --color-bridal-heath: #FFFBF6;
  --color-mirage: #14142B;
}

.moon {
  display: none;
  visibility: hidden;
}

.sun {
  display: block;
  visibility: visible;
}

.dark-mode {
  --background: var(--color-mirage);
  --text-color: var(--color-bridal-heath);
  --project-backgroud-opacity: 0.3;
  --project-item-opacity: 0.2;

  .sun {
    display: none;
    visibility: hidden;
  }

  .moon {
    display: block;
    visibility: visible;
  }

  .emoji-sticker {
    background: currentColor;
  }
}

* {
  margin: 0;
  font-size: 10px;
}

body {
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  font-family: "Hanken Grotesk", sans-serif;
  font-optical-sizing: auto;
  font-weight: normal;
  font-style: normal;
  font-variation-settings: "slnt" 0;

  background-color: var(--background);
  color: var(--text-color);
}

.container {
  max-width: 92rem;
  margin: 0 auto;
}

.toggle {
  position: absolute;
  top: 12px;
  right: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1.05;
  padding: 0;
  border-radius: 100%;
  width: 4rem;
  height: 4rem;
  outline: none;
  cursor: pointer;
  background: none;
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, .1), 0 4px 6px -2px rgba(0, 0, 0, .05);
  fill: var(--text-color);
  background-color: var(--background);
}

header,
.header {
  margin-top: 8rem;
  margin-bottom: 5rem;
  text-align: center;
}

.header.container {
  max-width: 72rem;
}

.header__mobile {
  display: none;
  visibility: hidden;
}

.about {
  font-family: var(--font-serif);
  font-weight: normal;
  font-style: normal;
  text-align: left;

  p {
    line-height: 1.8;
    margin-bottom: 1.3rem;
  }
}

.about__colour-picker,
.about__colour-picker option {
  font-family: var(--font-sans-serif);
  font-size: 1.8rem;
  border: none;
  background: none;
  color: currentColor;
  border-bottom: 0.2rem dashed currentColor;
}

.about__colour-picker option {
  color: #333333;
}

.your-favorite,
.favorite {
  font-size: 2rem;
  transition: textDecoration 300ms linear;
}

.your-favorite {
  font-family: "Indie Flower", cursive;
  font-size: 3.2rem;
  display: none;
  visibility: hidden;
}

.your-favorite--shown {
  position: absolute;
  transform: translate(-100px, 32px);
  display: inline-block;
  visibility: visible;
  color: #FF6347;
  font-weight: 900;
}

.favorite--strike-out {
  text-decoration: line-through;
  text-decoration-color:  #FF6347;
}

.project-note {
  margin-top: 8rem;
}

.projects {
  text-align: center;
  padding: 8rem 0;
  margin: 8rem 0;
}

.projects__container {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  margin: 0 auto;
  gap: 3rem;
  max-width: 102rem;
  padding-inline: 3rem;
}

.project--full-width { 
  grid-column: 1 / -1;
}

.projects--green {
  background-color: rgb(var(--color-green), var(--project-backgroud-opacity));
}

.projects--blue {
  background-color: rgb(var(--color-blue), var(--project-backgroud-opacity));
}

.projects--purple {
  background-color: rgb(var(--color-purple), var(--project-backgroud-opacity));
}

.projects--black {
  background-color: rgb(var(--color-black), var(--project-backgroud-opacity));
}

.projects--red {
  background-color: rgb(var(--color-red), var(--project-backgroud-opacity));
}

.projects--yellow {
  background-color: rgb(var(--color-yellow), var(--project-backgroud-opacity));
}

.project {
  display: flex;
  flex-direction: row;
  gap: 3rem;
  background: rgb(var(--color-white), var(--project-item-opacity));
  flex: 1;
  box-shadow: 0px 1rem 1.5rem -0.3rem rgba(0,0,0,0.1);
  padding: 2.5rem;
}

.project__image {
  width: 31rem;
  object-fit: cover;
  border-radius: 1.2rem;
} 

.project__title {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.1rem;
}

.project__title h3,
.project__title h3 a {
  font-size: 2.2rem;
  color: currentColor;
  text-decoration: none;
  font-weight: 700;
  font-family: var(--font-serif);
}

.project__content p {
  font-size: 1.8rem;
  text-align: left;
}

.project__links {
  display: flex;
  margin-top: auto;
}

.project__link {
  font-size: 1.8rem;
  font-weight: 600;
  color: currentColor;
  text-decoration: none;
  text-align: left;
}

.work {
  display: flex;
  flex-wrap: nowrap;
  gap: 5rem;
  margin-bottom: 8rem;
}

.work__info {
  max-width: 60rem;
}

.article--previous {
  margin-bottom: 3rem;
}

.skills {
  flex: 1;
}

.work__item {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 2rem;
  margin-bottom: 1.2rem;
}

.work__period {
  width: 100px;
  line-height: 1.8;
  font-weight: 700;
  font-size: 1.8rem;
  font-family: var(--font-sans-serif);
}

.work__summary {
  font-size: 1.8rem;
  font-family: var(--font-serif);
}

.previous {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 2rem;
  margin-bottom: 1.1rem;
}

.h3.previous__title {
  width: 10rem;
  margin-bottom: 0;
}

.button__previous {
  background: none;
  border: 0;
  padding: 0;
  display: flex;
  align-items: center;
  color: currentColor;
}

.button__title {
  font-size: 1.8rem;
  font-family: var(--font-sans-serif);
}

.button__icon {
  position: absolute;
  right: -3rem;
  transform: rotate(180deg);
  transition: transform 200ms linear;
}

footer {
  /* background-color: var(--color-mirage); */
  color: var(--text-color);
  padding: 4rem 0;
  margin-top: 8rem;
  border-top: 1px dotted var(--color-bridal-heath);
  /* box-shadow: 0px -10px 53px 3px #FFFBF6; */
  /* box-shadow: 0px 30px 40px 15px var(--color-bridal-heath); */
  /* box-shadow: 0px 10px 30px 5px var(--color-mirage); */
}

.h1 {
  font-size: 4rem;
  font-weight: 700;
  font-family: var(--font-serif);
}

.h2 {
  font-size: 3rem;
  margin-bottom: 0.5rem;
  font-family: var(--font-serif);
}

.h3 {
  font-size: 2rem;
  margin-bottom: 0.3rem;
  font-family: var(--font-serif);
}

p,
.p {
  font-size: 1.8rem;
  line-height: 1.8;
  margin-bottom: 2.4rem;
  font-family: var(--font-sans-serif);
  font-weight: normal;
  font-style: normal;
}

.summary {
  margin-bottom: 1.1rem;
}

.emoji-sticker {
  font-size: 2rem;
  border-radius: 0.6rem;
  padding: 0.2rem;
  margin-inline: 0.3rem;
}

ul.list {
  column-gap: 0.3rem;
  padding: 0;
  margin: 0;
  margin-bottom: 2.4rem;
}

ul.list--about {
  display: flex;
  flex-wrap: wrap;
  list-style: none;
  justify-content: left;
}

ul.list--skills {
  display: flex;
  flex-wrap: wrap;
  list-style: none;
  column-gap: 1rem;
}


ul li {
  font-size: 1.8rem;
  line-height: 1.8;
  font-family: var(--font-sans-serif);
  font-weight: normal;
  font-style: normal;
}

svg path {
  stroke: currentColor;
}

.link {
  font-size: 1.8rem;
  line-height: 1.8;
  margin-bottom: 2.4rem;
  font-family: var(--font-serif);
  font-weight: 700;
  font-style: normal;
  text-decoration: none; 
  color: currentColor;
}

.work .work__items {
  max-height: 0;
  overflow: hidden;
  transition: max-height 200ms linear;
}

.button__title--expand {
  display: inline-block;
}

.button__title--collapse,
.work-history--shown .button__title--expand {
  /* max-height: 0; */
  display: none;
}

.work-history--shown .button__title--collapse,
.work-history--shown .work__items {
  display: inline-block;
}

.work-history--shown .work__items {
  max-height: 500px;
}

.work-history--shown .button__icon {
  transform: rotate(0deg);
}

/* Articles */
.article__back {
  display: flex;
  align-items: center;
  margin-bottom: 2rem;
  transform: translate(-1rem);
}

.article__back-title {
  font-size: 2.4rem;
  font-weight: 700;
  font-family: var(--font-sans-serif);
  color: currentColor;
  text-decoration: none;
  margin-left: 0.7rem;
}

.article__header {
  margin-top: 8rem;
  margin-bottom: 3rem;
}

.article__title {
  font-family: var(--font-sans-serif);
  font-size: 3.8rem;
  font-weight: 400;
  display: flex;
  align-items: center;
  padding: 0 2rem;
}

.article__content {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 0 2rem;
}

.article__image-full {
  max-width: 96rem;
  margin: 0 auto;
  margin-bottom: 4rem;
  position: relative;
}

.article__svg {
  position: absolute;
  width: 100%;
  height: 100%;
  -webkit-mask: url('data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20viewBox%3D%220%200%20400%20200%22%3E%3Cpath%20d%3D%22M0%2C0H400A0%2C0%200%2C0%2C1%20400%2C0V200A0%2C0%200%2C0%2C1%20400%2C200H209A10%2C10%200%2C0%2C1%20199%2C190L199%2C180A10%2C10%200%2C0%2C0%20189%2C170L10%2C170A10%2C10%200%2C0%2C1%200%2C160V0A0%2C0%200%2C0%2C1%200%2C0Z%22%20fill%3D%22%23fff%22%20%2F%3E%3C%2Fsvg%3E') no-repeat center / contain;
          mask: url('data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20viewBox%3D%220%200%20400%20200%22%3E%3Cpath%20d%3D%22M0%2C0H400A0%2C0%200%2C0%2C1%20400%2C0V200A0%2C0%200%2C0%2C1%20400%2C200H209A10%2C10%200%2C0%2C1%20199%2C190L199%2C180A10%2C10%200%2C0%2C0%20189%2C170L10%2C170A10%2C10%200%2C0%2C1%200%2C160V0A0%2C0%200%2C0%2C1%200%2C0Z%22%20fill%3D%22%23fff%22%20%2F%3E%3C%2Fsvg%3E') no-repeat center / contain;
  fill: red;
}

.article__image-grid {
  max-width: 96rem;
  margin: 0 auto;
  display: grid;
  gap: 3rem;
  grid-template-columns: repeat(2, 1fr);
}

img {
  max-width: 100%;
  box-shadow: 0px 10px 35px -3px rgba(0,0,0,0.1);
}

.underline-hover {
  position: relative;
}

.underline-hover--dashed {
  border-bottom: 2px dashed currentColor;
}

.underline-hover::after {
  content: '';
  position: absolute;
  bottom: -2px; /* Adjust this value for spacing */
  left: 0;
  width: 0;
  height: 2px; /* Thickness of the underline */
  background-color: currentColor; /* Matches the text color */
  transition: width 0.3s ease; /* Smooth animation */
  z-index: 1; /* Ensure it appears above other elements */
}

.underline-hover:hover::after {
  width: 100%; /* Expands the underline */
}


@media (max-width: 920px) {
  .about {
    text-align: left;
    padding-top: 6rem;
  }

  .header.container {
    text-align: center; /* Center-align header content */
  }

  .projects__container {
    grid-template-columns: 1fr;
    gap: 3rem;
  }

  .container,
  .projects {
    margin: 4rem 0;
  }

  .container {
    padding: 4rem;
  }

  .header__mobile {
    display: inline-block;
    visibility: visible;
    font-size: 1.8rem;
    font-family: var(--font-sans);
    font-weight: 700;
  }

  ul.list {
    justify-content: flex-start;
  }

  .header {
    display: none;
    visibility: hidden;
  }

  .projects {
    padding: 3rem 0;
  }

  .project {
    flex-direction: column;
  }

  .project__image {
    width: unset;
    max-height: 32rem;
  }

  .work {
    flex-direction: column;
    flex-direction: column-reverse;
    gap: 3rem;
  }
}

/* Styles for screens 360px and below */
@media (max-width: 768px) {

  .header.container h1 {
    font-size: 24px; /* Adjust header font size */
  }

  .projects__container {
    grid-template-columns: 1fr;
    gap: 3rem;
    padding-inline: 2rem;
  }

  .container {
    margin: 2rem 0;
    padding: 2rem;
  }

  .about {
    padding-top: 6rem;
  }

  .work__item {
    flex-direction: column;
    gap: 0;
    align-items: flex-start;
  }

  
  .your-favorite--shown {
    position: relative;
    margin-right: 3px;
    transform: unset;
    font-size: 2rem;
  }

  .favorite--strike-out {
    display: none;
    visibility: hidden;
  }

  .article__title {
    padding: 0 2rem;
  }

  .article__image-grid {
    grid-template-columns: repeat(1, 1fr);
  }
}