*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --primary-color: #111312;
  --secondary-color: #19191c;
  --dark-color: #474056;
  --light-color: #dabfff;
  --text-color: #f6e8f9;
  --accent-color: #aed9e0;
  --light-bg: #faf3dd;
  --border-color: #ffa69e;
  --shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

html,
body {
  font-family: "Sniglet", system-ui;
  font-size: 16px;
  line-height: 1.6;
  scroll-behavior: smooth;
  background-color: var(--primary-color);
  color: var(--light-bg);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background:
    radial-gradient(
      circle at top left,
      rgba(174, 217, 224, 0.16),
      transparent 22%
    ),
    radial-gradient(
      circle at bottom right,
      rgba(255, 166, 158, 0.14),
      transparent 24%
    );
  pointer-events: none;
  z-index: -1;
}

.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition:
    opacity 0.7s ease,
    transform 0.7s ease;
  will-change: opacity, transform;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

#scrollTopBtn {
  position: fixed;
  right: 24px;
  bottom: 24px;
  width: 48px;
  height: 48px;
  border: none;
  border-radius: 50%;
  background: transparent;
  color: var(--border-color);
  border: 2px solid;
  border-color: var(--border-color);
  font-size: 1.3rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.25);
  opacity: 0;
  transform: translateY(20px);
  transition:
    opacity 0.3s ease,
    transform 0.3s ease,
    background 0.2s ease;
  z-index: 10001;
}

#scrollTopBtn.active {
  opacity: 1;
  transform: translateY(0);
}

a {
  text-decoration: none;
}

ul {
  list-style: none;
}

img {
  width: 100%;
  max-width: 200px;
}

.container {
  font-family: "Sniglet", system-ui;
  background: var(--secondary-color);
  backdrop-filter: blur(50px);
  color: var(--text-color);
  max-width: 1500px;
  display: flex;
  margin: 30px auto;
  padding: 30px;
  border-radius: 10px;
}
.container__title {
  margin-bottom: 20px;
  writing-mode: vertical-rl;
  background-color: rgba(47, 58, 52, 0.3);
  padding: 20px 0;
  border-radius: 8px;
}

/* body background */
.background__image img {
  width: 100%;
  max-width: 5000px;
  position: fixed;
  top: 0;
  left: 0;
  z-index: 0;
  opacity: 50%;
}
/* Header */
.header {
  padding: 100px;
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center;
  position: relative;
  text-align: center;
  color: var(--text-color);
  z-index: 1;
}

.header__content-start {
  font-size: 3rem;
  z-index: 2;
}

.header__content-title {
  margin-top: 18px;
  font-size: 1.5rem;
  color: var(--accent-color);
  letter-spacing: 0.02em;
  min-height: 1.5em;
  margin-left: 10px;
  min-width: 400px;
  text-align: left;
  z-index: 2;
}

.header__content-decorator {
  z-index: 3;
  position: absolute;
  bottom: 0;
  margin-bottom: 0;
  max-height: 70px;
  width: 100%;
}

/* Profile */
.profile {
  position: relative;
  background-color: var(--secondary-color);
  z-index: 2;
}

.profile__container {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 50px;
  margin-top: 0px;
  z-index: 1;
}

.profile__content {
  margin: 30px 20px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  z-index: 1;
}

.profile__content-image {
  position: relative;
  width: 250px;
  height: 250px;
  background: var(--primary-color);
  border-radius: 64% 36% 48% 52% / 46% 52% 48% 54%;
  box-shadow: 2px 1px 15px rgba(207, 142, 142, 0.4);
  overflow: hidden;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1;
}

.profile__content-image:hover {
  border-radius: 67% 33% 48% 52% / 51% 44% 56% 49%;
}

.profile__content-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  display: block;
  cursor: default;
  opacity: 80%;
  filter: saturate(70%);
}

.profile__content-name {
  color: var(--text-color);
  font-size: 1.5rem;
  padding-top: 10px;
}

.profile__about {
  z-index: 2;
}

.profile__about-title {
  text-decoration: underline;
  color: var(--text-color);
  margin-bottom: 20px;
  font-size: 1.2rem;
  font-style: italic;
}

.profile__about-text {
  color: var(--border-color);
  font-size: 1rem;
  width: 80%;
  max-width: 700px;
}

/* Menu */
.navbar {
  margin: 10px 0;
  padding: 15px 20px;
  background-color: var(--secondary-color);
  position: sticky;
  z-index: 2000;
  top: 20px;
  display: flex;
  flex-direction: row;
  justify-content: center;
  box-shadow: 0px 14px 20px rgba(0, 0, 0, 1);
}

.navbar__resume-link {
  color: var(--accent-color);
  animation: pulse 3s ease-in infinite;
}

.navbar__resume-link:hover {
  color: var(--border-color);
  border-bottom: 2px solid var(--border-color);
}

@keyframes pulse {
  0% {
    opacity: 0;
  }

  75% {
    transform: scale(2);
    opacity: 1;
  }

  100% {
    transform: scale(1);
    opacity: 0;
  }
}

.navbar__contact {
  margin-left: 50px;
  display: flex;
  flex-direction: row;
  justify-content: center;
  gap: 20px;
}

.navbar__contact i {
  color: var(--accent-color);
  font-size: 20px;
}

.navbar__contact i:hover {
  color: var(--border-color);
  transform: scale(1.4);
}

/* Skills */
.skills__list {
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  justify-content: center;
  margin: 0 auto;
  gap: 30px;
}

.skills__list h3 {
  font-size: small;
}

.skills__list-item {
  box-shadow: 1px 5px 10px rgba(75, 78, 43, 0.3);
  border-radius: 15px;
  text-align: center;
  height: 80px;
  width: 100px;
  max-width: 100px;
  transition: all 0.2s ease-in-out;
}

.skills__list-item:hover {
  box-shadow: 1px 5px 10px rgba(75, 78, 43, 1);
  scale: 1.05;
}

/* Projects */
.projects__list {
  display: grid;
  grid-template-columns: repeat(5, 150px);
  justify-content: center;
  gap: 50px;
  margin: 0 auto;
  margin-top: 100px;
}

.projects__list article {
  perspective: 900px;
}

.projects__list-modal {
  display: flex;
  margin-bottom: 50px;
  align-items: center;
  justify-content: center;
  text-align: center;
  border-radius: 40px;
  height: 150px;
  padding: 1rem;
  color: var(--accent-color);
  font-size: 1.3rem;
  font-weight: bolder;
  background-color: rgba(255, 255, 255, 0.04);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(10px);
  transition:
    transform 0.35s ease,
    box-shadow 0.35s ease,
    background-color 0.35s ease;
  will-change: transform;
  opacity: 0.85;
  content-visibility: hidden;
}

.projects__list-modal:hover {
  transform: translateY(-8px) scale(1.03);
  box-shadow: inset 100px 100px 100px 100px rgba(25, 25, 28, 0.9);
  background-color: rgba(255, 255, 255, 0.08);
  content-visibility: visible;
}

.projects__list #a-1 a {
  background: url("../images/discordbot.png") top center/cover no-repeat;
}
.projects__list #a-2 a {
  background: url("../images/dataset.png") top center/cover no-repeat;
}
.projects__list #a-3 a {
  background: url("../images/doctor.png") top center/cover no-repeat;
}
.projects__list #a-4 a {
  background: url("../images/speech.png") top center/cover no-repeat;
}
.projects__list #a-5 a {
  background: url("../images/nlp.png") top center/cover no-repeat;
}
.projects__list #a-6 a {
  background: url("../images/imagecap.png") top center/cover no-repeat;
}

.modal {
  font-family: "Sniglet", system-ui;
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.76);
  z-index: 10000;
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

.modal.show {
  display: flex;
  pointer-events: auto;
}

.modal.visible {
  opacity: 1;
}

.modal__content {
  background: var(--secondary-color);
  padding: 2rem;
  border-radius: 18px;
  max-width: 1000px;
  height: auto;
  max-height: 1000px;
  overflow-y: auto;
  position: relative;
  animation: slideIn 0.5s ease;
}

.modal__content p {
  text-align: left;
  max-width: 600px;
  line-height: 1.8rem;
  color: var(--text-color);
}

.modal__content-title {
  text-align: center;
  font-weight: bolder;
  font-size: 1.5rem;
  margin-bottom: 20px;
  color: var(--text-color);
}

.modal__close-button {
  color: var(--light-color);
  font-size: 1.8rem;
  cursor: pointer;
}

.modal__content-icon {
  color: var(--accent-color);
  font-size: 2rem;
  margin: 0 5px;
  margin-top: 20px;
}

.pg-btn {
  color: var(--accent-color);
  font-size: 1.2rem;
}

.modal__content-icon:hover {
  color: var(--border-color);
}

.modal__close-button {
  position: absolute;
  top: 5px;
  right: 20px;
  font-size: 36px;
  cursor: pointer;
  color: #999;
}

.modal__close-button:hover {
  color: var(--border-color);
}

/* Playgrounds */

.playgrounds__list {
  display: flex;
  flex-direction: column;
}

.playground {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 90px;
  margin: 50px 100px;
}

.playground:nth-child(even) {
  flex-direction: row-reverse;
}

.playground iframe {
  width: 100%;
  max-width: 500px;
  height: 600px;
  border: none;
  border-radius: 18px;
  box-shadow: var(--shadow);
}

.playground-content {
  width: 30%;
  margin-left: 20px;
  line-height: 1.9rem;
  color: var(--text-color);
}

.playground-content h3 {
  font-size: 1.5rem;
  margin-bottom: 30px;
  text-align: center;
}

.project-links {
  display: flex;
  flex-direction: column;
  margin-top: 40px;
}
.project-links a {
  color: var(--accent-color);
}

@keyframes slideIn {
  from {
    transform: translateY(-50px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

/* Responsive */

@media (max-width: 1200px) {
  .projects__list {
    display: grid;
    grid-template-columns: repeat(4, 150px);
  }

  /* Skill */
  .skills__list {
    display: grid;
    grid-template-columns: repeat(7, 100px);
  }
  /* Skill */
  .skills__list {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    margin: 0 auto;
    gap: 30px;
  }
}

@media (max-width: 992px) {
  .projects__list {
    display: grid;
    grid-template-columns: repeat(3, 150px);
  }
  .header__content-start {
    font-size: 2.5rem;
  }


  .playground, .playground:nth-child(even) {
    flex-direction: column-reverse;
    margin: 30px 10px;
    gap: 20px;
  }

  .playground-content {
    margin: 0;
    width: 70%;
    font-size: 0.9rem;
    border-top: 1px solid var(--border-color);
  }

  .playground-content h3 {
    font-size: 1.2rem;
    margin-bottom: 10px;
  }

  .playground iframe {
    max-width: 500px;
    max-height: 500px;
  }
}

@media (max-width: 768px) {
  /* Header */
  .header {
    padding: 70px;
  }

  .header__content-start {
    font-size: 2rem;
    z-index: 1;
  }

  .header__content-title {
    margin-top: 5px;
    font-size: 1rem;
    color: var(--accent-color);
    letter-spacing: 0.02em;
    min-height: 1.5em;
    min-width: 250px;
    text-align: left;
    z-index: 1;
  }

  /* Profile */
  .profile__container {
    display: flex;
    flex-direction: column;
    gap: 50px;
  }

  .profile__content-name {
    font-size: 1.4rem;
  }

  .profile__content-image img {
    width: 100%;
    margin: 0;
  }

  .profile__about-title {
    font-size: 1rem;
    margin-bottom: 20px;
  }

  .profile__about-text {
    font-size: 0.9rem;
    line-height: 1.2rem;
  }

  .profile__about {
    margin-left: 50px;
    padding-bottom: 40px;
  }

  /* Menu */
  .navbar {
    margin: 20px 0;
    padding: 10px 20px;
    position: sticky;
    top: 20px;
  }

  .navbar__contact {
    margin-left: 0px;
    display: flex;
    flex-direction: row;
    justify-content: center;
    gap: 10px;
  }
  .navbar__contact i {
    color: var(--accent-color);
    font-size: 15px;
  }

  .navbar__resume a {
    font-size: 0.8rem;
    margin-right: 50px;
  }

  .projects__list {
    display: grid;
    grid-template-columns: repeat(2, 150px);
  }

  .modal__content {
    font-size: 0.8rem;
    max-width: 400px;
    max-height: 600px;
  }

  .modal__content-title {
    font-size: 1.2rem;

  }
  .modal__content-icon {
    font-size: 0.9rem;
    margin-bottom: 20px;
  }

  .modal__close-button {
    font-size: 1.3rem;
  }



  .playground-content {
    margin: 0;
    width: 70%;
    font-size: 0.9rem;
    border-top: 1px solid var(--border-color);
  }

  .playground-content h3 {
    font-size: 1.2rem;
    margin-bottom: 10px;
  }

  .playground iframe {
    max-width: 400px;
    max-height: 600px;
  }
}

@media (max-width: 576px) {
  .header {
    padding: 70px;
    display: flex;
    flex-direction: column;
  }

  .header__content-start {
    font-size: 1.5rem;
    z-index: 1;
  }
  .header__content-title {
    margin-top: 5px;
    font-size: 1rem;
    color: var(--accent-color);
    letter-spacing: 0.02em;
    min-height: 2rem;
    min-width: 250px;
    text-align: start;
    z-index: 1;
    margin-bottom: 20px;
  }
  .container {
    max-width: 1500px;
    display: flex;
    flex-direction: column;
    margin: 30px auto;
    padding: 30px;
    border-radius: 10px;
  }
  .container__title {
    margin-bottom: 40px;
    writing-mode: horizontal-tb;
    background-color: rgba(47, 58, 52, 0.3);
    padding: 0;
    border-radius: 8px;
    height: 30px;
    text-align: center;
    font-size: 1.2rem;
  }
  .profile {
    position: relative;
  }

  .profile__about-title {
    font-size: 0.9rem;
    font-weight: bold;
  }

  .profile__about-text {
    font-size: 1rem;
    max-width: 700px;
  }

  .projects__list {
    grid-template-columns: repeat(2, 150px);
    gap: 0px;
    margin: 0 auto;
    margin-top: 10px;
  }

  .projects__list-modal {
    display: flex;
    margin-bottom: 50px;
    align-items: center;
    justify-content: center;
    text-align: center;
    border-radius: 40px;
    height: 100px;
    max-width: 100px;
    color: var(--accent-color);
    font-size: 0.9rem;
    font-weight: bolder;
    content-visibility: hidden;
    opacity: 90%;
  }

  .projects__list-modal:hover {
    box-shadow: inset 100px 100px 100px 100px rgba(25, 25, 28, 0.9);
    scale: 1.05;
    content-visibility: visible;
  }

  /* Skill */
  .skills__list {
    display: grid;
    grid-template-columns: repeat(3, 90px);
    margin: 0;
  }
}
