:root {
  --primary: #00ffdd;
  --black: #0f0f0f;
  --white: #fff;
  --gray: #7a7a7a;
}

* {
  margin: 0;
  padding: 0;
  text-decoration: none;
  box-sizing: border-box;
}

::-webkit-scrollbar {
  width: 5px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background-color: var(--white);
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Inter", sans-serif;
  background-color: var(--black);
  color: var(--white);
}

.container {
  width: 100%;
  margin-right: auto;
  margin-left: auto;
  padding: 1.5rem 6rem;
}

header {
  position: fixed;
  top: 0;
  width: 100%;
  height: 10vh;
  z-index: 9999;
  transition: transform 0.3s ease-in-out;
  mix-blend-mode: difference;
}


header .container .content {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

header .container .content .logo {
  display: flex;
  justify-content: center;
  align-items: center;
}

header .container .content .logo a {
  font: italic bold 1.5rem "IBM Plex Sans", sans-serif;
  color: var(--white);
}

header .container .content nav {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 4rem;
}

header.aos-init.aos-animate.hidden {
  transform: translateY(-100%);
}

header .container .content nav a {
  display: flex;
  flex-direction: column;
  font: 600 1rem "IBM Plex Sans", sans-serif;
  color: var(--white);
  transition: 0.2s linear;
}

header .container .content nav a::after {
  content: "";
  display: block;
  border-bottom: 2px solid #fff;
  transform: scaleX(0);
  transition: 0.2s linear;
}

header .container .content nav a:hover::after {
  transform: scaleX(1);
  transition: 0.2s linear;
}

header .container .content .extra-nav {
  display: flex;
  align-items: center;
}

header .container .content .extra-nav a {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 0.4rem 2rem;
  border: 2px solid #fff;
  border-radius: 16px;
  font: 500 1rem "IBM Plex Sans", sans-serif;
  color: #fff;
  overflow: hidden;
  mix-blend-mode: difference;
}

header .container .content .extra-nav a::before {
  content: "";
  display: block;
  position: absolute;
  background: var(--primary);
  border-radius: 50%;
  padding: 2px;
  transform: scale(0);
  transition: transform 0.1s linear;
}

header .container .content .extra-nav a:hover::before {
  transform: scale(70);
  transition: transform 0.1s linear;
}

header .container .content .extra-nav a span {
  position: relative;
  transition: color 0.3s linear;
}

header .container .content .extra-nav a:hover span {
  color: var(--black);
  transition: color 0.3s linear;
}

.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  overflow: hidden;
}

.hero .container .content {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.hero .container .content .shape-1 {
  position: absolute;
  width: 200px;
  height: 200px;
  background-color: #fff;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 30%;
  animation: shape-1 60s infinite;
}

.hero .container .content .shape-2 {
  position: absolute;
  width: 300px;
  height: 50px;
  background-color: #fff;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 30%;
  animation: shape-2 120s infinite;
}

.hero .container .content .line {
  position: absolute;
  width: 100%;
  height: 4%;
  transform: rotate(45deg);
  background-color: #fff;
  top: 0;
  right: -100%;
  filter: blur(50px);
  animation: line 50s infinite;
}


.row-2 svg {
  width: 100%;
  height: 150px; 
  font-family: "IBM Plex Sans", sans-serif; 
}

.row-2 svg text {
  text-transform: uppercase;
  font-size: 20rem;
  fill: transparent; 
  stroke: white; 
  stroke-width: 2;
  animation: stroke 5s infinite alternate;
}

@keyframes stroke {
  0% {
    stroke: #5ce1e6;
    stroke-width: 0;
    stroke-dashoffset: 25%;
    stroke-dasharray: 0 50%;
  }
  70% {
    stroke: white;
  }
  80% {
    stroke: #5ce1e6;
    stroke-width: 3;
  }
  100% {
    stroke: white;
    stroke-width: 0;
    stroke-dashoffset: -25%;
    stroke-dasharray: 50% 0;
  }
}

@keyframes line {
  from {
    right: -100%;
    top: 0;
    opacity: 30%;
  }

  to {
    right: 100%;
    top: 100%;
    opacity: 0;
  }
}

@keyframes shape-1 {
  0% {
    left: 0;
    top: 0;
  }
  25% {
    left: 50%;
    top: 50%;
  }
  50% {
    left: 30%;
    top: 80%;
  }
  75% {
    left: 20%;
    top: 50%;
  }
  100% {
    left: 0;
    top: 0;
  }
}

@keyframes shape-2 {
  0% {
    left: 0;
    top: 0;
  }
  25% {
    left: 40%;
    top: 70%;
  }
  50% {
    left: 20%;
    top: 50%;
  }
  75% {
    left: 50%;
    top: 100%;
  }
  100% {
    left: 0;
    top: 0;
  }
}

.hero .container .content .text {
  display: flex;
  flex-direction: column;
  margin-bottom: 2rem;
}

.hero .container .content .text h1 {
  font: bolder 8rem "IBM Plex Sans", sans-serif;
  line-height: 8rem;
}

.hero .container .content .text .row-2 {
  margin-left: -7rem;
}

.hero .container .content .text .row-2 {
  color: var(--black);
  -webkit-text-stroke-width: 1px;
  -webkit-text-stroke-color: var(--white);
}

.hero .container .content .arrow {
  position: absolute;
  bottom: 4rem;
  cursor: pointer;
  border: 2px solid var(--white);
  border-radius: 50%;
  fill: var(--white);
  width: 75px;
  height: 75px;
  animation: arrow 2s infinite alternate;
  transition: 0.2s linear;
  z-index: 10;
}

.hero .container .content .arrow:hover {
  background-color: var(--primary);
  fill: var(--black);
  transition: 0.2s linear;
}

@keyframes arrow {
  from {
    transform: translateY(0px);
    opacity: 0;
  }

  to {
    transform: translateY(1.5rem);
    opacity: 1;
  }
}

.hero .container .content .short-info {
  position: absolute;
  bottom: 5rem;
  padding: 0 6rem;
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 5;
}

.hero .container .content .short-info .left-side,
.hero .container .content .short-info .right-side {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

.hero .container .content .short-info .left-side h1 {
  font-size: 1.2rem;
}

.hero .container .content .short-info .left-side p {
  color: var(--gray);
  font: bold 0.9rem "IBM Plex Sans", sans-serif;
}

.hero .container .content .short-info .right-side p {
  color: var(--gray);
  font-weight: bold;
}

.hero .container .content .short-info .right-side h1 {
  display: flex;
  align-items: center;
  height: 25px;
  gap: 0.2rem;
  font: bold 0.9rem "IBM Plex Sans", sans-serif;
}

.hero .container .content .short-info .right-side h1 .pulse {
  position: relative;
  width: 6px;
  height: 20px;
  background: #ff6a00;
  border-radius: 6px;
}

.hero .container .content .short-info .right-side h1 .pulse::after {
  content: "";
  position: absolute;
  width: 6px;
  height: 20px;
  background: #ff6a00;
  border-radius: 6px;
  animation: pulse 1.5s infinite;
}


.skill {
  padding: 4rem 0; 
  min-height: 100vh; 
  overflow: hidden; }
.skill .container .content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4rem; 
}

.skill .container .content .title {
  font: italic bold 3rem "IBM Plex Sans", sans-serif; 
  color: var(--white); 
  text-align: center; 
}

.skill .container .content .skills {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr)); /* 6 colonnes par défaut */
  gap: 1.5rem; /* Espacement entre les icônes */
  width: 80%; /* Largeur de la grille */
}

.skill .container .content .skills .skill-box {
  padding: 1rem;
  border: 2px solid var(--white); /* Bordure blanche */
  border-radius: 16px; /* Coins arrondis */
  display: flex;
  justify-content: center;
  align-items: center;
  background-color: var(--black); /* Fond noir */
  filter: grayscale(100); /* Icônes en noir et blanc par défaut */
  transition: all 0.3s ease; /* Animation fluide */
}

.skill .container .content .skills .skill-box:hover {
  filter: grayscale(0); /* Icônes en couleur au survol */
  transform: scale(1.05); /* Légère mise à l'échelle */
  border-color: var(--primary); /* Bordure violette au survol */
}

.skill .container .content .skills .skill-box img {
  width: 100%; /* Taille des icônes */
  height: auto; /* Conserver les proportions */
  max-width: 80px; /* Limiter la taille maximale */
}

@keyframes pulse {
  0% {
    transform: scale(1);
    opacity: 1;
  }
  100% {
    transform: scale(2);
    opacity: 0;
  }
}
.about {
  position: relative;
  margin: 4rem 0;
  min-height: 100vh;
  overflow: hidden;
}

.about .container .content {
  display: flex;
  flex-direction: column;
  align-items: start;
  height: 100vh;
  width: 100%;
}

.about .container .content .title {
  display: flex;
  flex-direction: column;
  width: 100%; /* Prend toute la largeur */
  margin-bottom: 2rem; /* Espace sous le titre */
}

.about .container .content .title h2 {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 2.5rem;
  color: var(--gray);
  margin-top: 6rem;
}

.about .container .content .title h2 hr {
  width: 90px;
  padding: 2px;
  border: none;
  background-color: var(--gray);
  margin-top: 4px;
}

.about .container .content .title h1 {
  font: italic bold 3.5rem "IBM Plex Sans", sans-serif;
}

/* Nouveau conteneur pour la photo et le texte */
.profile-and-text {
  display: flex;
  align-items: center;
  gap: 8rem; /* Espace entre la photo et le texte */
  width: 100%;
  margin-top: 2rem; /* Ajuste selon tes besoins */
}

/* Ajustements pour la photo */
.profile-container {
  width: 60%; /* Largeur de la photo */
  height: auto;
  display: flex;
  justify-content: flex-start; 
}

.profile-container .profile {
  width: 100%;
  height: auto;
  background: var(--gray);
  border-radius: 64px;
  overflow: hidden;
}

.profile-container .profile img {
  width: 100%;
  height: auto;
}

/* Ajustements pour le texte */
.about-me {
  width: 70%; /* Largeur du texte */
  padding-left: 0; /* Supprime le padding gauche */
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 3rem;
}

.about-me p {
  font-weight: 500;
  font-style: italic;
  line-height: 1.4rem;
}

.about-me button {
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1rem;
  width: 45%;
  padding: 12px;
  background-color: var(--black);
  border: 2px solid #ffffff;
  border-radius: 32px;
  font-weight: bold;
  color: var(--white);
  transition: all 0.2s linear;
}

.about-me button:hover {
  color: var(--black);
  background-color: var(--primary);
}

.about-me button .arrow {
  width: 20px;
  transform: rotate(135deg);
  fill: var(--white);
  transition: all 0.2s linear;
}

.about-me button:hover .arrow {
  transform: rotate(180deg);
  fill: var(--black);
  transition: all 0.2s linear;
}

.about .container .content .text-wrapper {
  position: absolute;
  bottom: 2rem;
  left: 0;
  display: flex;
  gap: 2rem;
}

.about .container .content .text-wrapper .text {
  display: flex;
  flex-shrink: 0;
  gap: 2rem;
  animation: marquee 8s linear infinite;
}

.about .container .content .text-wrapper .text h1 {
  font: italic bold 9rem "IBM Plex Sans", sans-serif;
  white-space: nowrap;
}

.about .container .content .text-wrapper .text h1 span {
  color: transparent;
  -webkit-text-stroke-width: 2px;
  -webkit-text-stroke-color: var(--white);
}

@keyframes marquee {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(-100%);
  }
}

@keyframes marquee {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(-100%);
  }
}
.project .projects .desc h1 {
  font: italic bold 2rem "IBM Plex Sans", sans-serif;
  margin-bottom: 1rem;
  align-items: center;
}

.project .projects .desc p {
  font-size: 2rem;
  color: var(--gray);
}

.project .projects .desc p strong {
  font-weight: bold;
  align-items: center;
  color: var(--white);
}

.project .projects .desc p .tool {
  display: inline-block;
  background-color: var(--gray);
  color: var(--black);
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
  margin: 0 0.5rem;
}

.project,
.contact {
  margin: 4rem 0;
  min-height: 100vh;
  overflow: hidden;
}

.project .container .content {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.project .container .content .header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.project .container .content .header button {
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1rem;
  width: 15%;
  padding: 12px;
  background-color: var(--black);
  border: 2px solid #ffffff;
  border-radius: 32px;
  font-weight: bold;
  color: var(--white);
  transition: all 0.2s linear;
}

.project .container .content .header button:hover {
  color: var(--black);
  background-color: var(--primary);
}

.project .container .content .header button .arrow {
  width: 20px;
  transform: rotate(135deg);
  fill: var(--white);
  transition: all 0.2s linear;
}

.project .container .content .header button:hover .arrow {
  transform: rotate(180deg);
  fill: var(--black);
  transition: all 0.2s linear;
}

.project .container .content .header .title {
  display: flex;
  flex-direction: column;
  align-items: end;
  font: italic bold 1.5rem "IBM Plex Sans", sans-serif;
}

.project .container .content .header .title .row-1 {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  text-align: end;
  color: var(--gray);
}

.project .container .content .header .title .row-1 hr {
  width: 75px;
  padding: 2px;
  border: none;
  background-color: var(--gray);
  margin-top: 4px;
}

.project .container .content .header .title .row-2 {
  font-size: 3rem;
}

.project .container .content .project-area {
  position: relative;
  display: flex;
  height: 350px;
  gap: 1rem;
}

/* Removed rule that brightened non-hovered projects when the whole project-area was hovered.
   Keeping only per-card hover rules so that only the hovered project changes to color. */

.project .container .content .project-area .projects {
  position: relative;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 33%;
  height: 100%;
  background: var(--gray);
  border-radius: 64px;
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease; 
}

.project .container .content .project-area .projects:hover {
  transform: scale(1.05);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3); 
}

.project .container .content .project-area .projects img {
  filter: grayscale(100); 
  transition: filter 0.3s ease, transform 0.3s ease; 
}

.project .container .content .project-area .projects:hover img {
  filter: grayscale(0); 
  transform: scale(1.1); 
}

.project .container .content .project-area .projects .desc {
  position: absolute;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  opacity: 0;
  transition: opacity 0.2s linear;
}

.project .container .content .project-area .projects .desc h1 {
  font: italic bold 4rem "IBM Plex Sans", sans-serif;
}

.project .container .content .project-area .projects .desc p {
  text-align: center;
  width: 75%;
}

.project .container .content .project-area .projects:hover .desc {
  opacity: 1;
  transition: opacity 0.2s linear;
}
.contact .container .content {
  display: flex;
  flex-direction: column;
  height: 100vh;
  gap: 2rem;
}

.contact .container .content .title {
  text-align: center;
  font: italic bold 1.3rem "IBM Plex Sans", sans-serif;
}

.contact .container .content .title h2 {
  color: var(--gray);
}

.contact .container .content .title h1 {
  font-size: 4rem;
}

.contact .container .content .contact-area {
  display: flex;
  height: 80%;
}

.contact .container .content .contact-area .left-side {
  width: 50%;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.contact .container .content .contact-area .left-side h1 {
  font: 500 5rem "IBM Plex Sans", sans-serif;
  margin-top: .5rem;
  transform: scale(1, 1.5);
}

.contact .container .content .contact-area .left-side h1:nth-child(2) {
  margin-left: 30%;
}


.contact .container .content .contact-area .right-side {
  width: 40%;
  height: 100%;
}

.contact .container .content .contact-area .right-side form {
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 1rem;
}

.contact .container .content .contact-area .right-side form input {
  padding: 1rem;
  border: none;
  border-bottom: 2px solid var(--white);
  outline: none;
  color: var(--white);
  font-size: 1.2rem;
  background: transparent;
}

.contact .container .content .contact-area .right-side form input::placeholde,
.contact .container .content .contact-area .right-side form textarea::placeholder {
  font-size: 1.2rem;
  font-weight: bold;
}

.contact .container .content .contact-area .right-side form textarea {
  resize: none;
  height: 150px;
  padding: 1rem;
  border: none;
  border-bottom: 2px solid var(--white);
  outline: none;
  color: var(--white);
  font-size: 1.2rem;
  background: transparent;
}

.contact .container .content .contact-area .right-side form button {
  cursor: pointer;
  padding: .7rem;
  margin-bottom: 1rem;
  border: 2px solid var(--white);
  border-radius: 16px;
  font: bold 1.2rem "IBM Plex Sans", sans-serif;
  background: var(--black);
  color: var(--white);
  transition: .2s linear;
}

.contact .container .content .contact-area .right-side form button:hover {
  background-color: var(--primary);
  color: var(--black);
  transition: .2s linear;
}

footer {
  min-height: 20vh;
}

footer .container .content {
  footer {
  min-height: 20vh;
}

footer .container .content {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 1rem;
}

footer .container .content h1 {
  font: italic bold 1.5rem "IBM Plex Sans", sans-serif;
}

footer .container .content .social {
  display: flex;
  align-items: center;
  gap: 1rem;
}

footer .container .content .social .logo {
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
  width: 40px;
  height: 40px;
  background: var(--black);
  border: 2px solid var(--white);
  border-radius: 50%;
  fill: var(--white);
  transition: 0.2s linear;
}

footer .container .content .social .logo:hover {
  background-color: var(--primary);
  fill: var(--black);
  transition: 0.2s linear;


}

footer .container .content .social p {
  font-weight: bold;
}
display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 1rem;
}

footer .container .content h1 {
  font: italic bold 1.5rem "IBM Plex Sans", sans-serif;
}

footer .container .content .social {
  display: flex;
  align-items: center;
  gap: 1rem;
}

footer .container .content .social .logo {
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
  width: 40px;
  height: 40px;
  background: var(--black);
  border: 2px solid var(--white);
  border-radius: 50%;
  fill: var(--white);
  transition: 0.2s linear;
}

footer .container .content .social .logo:hover {
  background-color: var(--primary);
  fill: var(--black);
  transition: 0.2s linear;


}

footer .container .content .social p {
  font-weight: bold;
}

/*---------------------------------------------------------*/
.all-projects {
  padding: 4rem 0;
  min-height: 100vh;
  background-color: var(--black);
}

.all-projects .container .content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
}

.all-projects h1 {
  font: italic bold 3rem "IBM Plex Sans", sans-serif;
  color: var(--white);
  text-align: center;
}

.project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 2.5rem;
  width: 100%;
  padding: 0 1rem;
  margin-top: 1.5rem;
}

/* Add subtle separator between categories */
.category-section:not(:last-child)::after {
  content: '';
  display: block;
  width: 100%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(0,255,221,0.2), transparent);
  margin-top: 3rem;
}

/* Hover effect for category titles */
.category-title:hover {
  color: var(--primary);
  transition: color 0.3s ease;
}

.category-title:hover::before {
  background: linear-gradient(180deg, var(--white), var(--primary));
  box-shadow: 0 0 25px rgba(0,255,221,0.6);
  transition: all 0.3s ease;
}

/* Add subtle animation to category sections */
.category-section {
  opacity: 0;
  transform: translateY(30px);
  animation: fadeInUp 0.8s ease forwards;
}

.category-section:nth-child(2) { animation-delay: 0.1s; }
.category-section:nth-child(3) { animation-delay: 0.2s; }
.category-section:nth-child(4) { animation-delay: 0.3s; }
.category-section:nth-child(5) { animation-delay: 0.4s; }

@keyframes fadeInUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Enhanced project grid with better spacing */
.project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 2.5rem;
  width: 100%;
  padding: 0 1rem;
  margin-top: 1.5rem;
}

/* Add subtle separator between categories */
.category-section:not(:last-child)::after {
  content: '';
  display: block;
  width: 100%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(0,255,221,0.2), transparent);
  margin-top: 3rem;
}

.project-card {
  position: relative;
  cursor: pointer;
  background: linear-gradient(180deg, rgba(255,255,255,0.03), rgba(255,255,255,0.01));
  border-radius: 16px;
  overflow: hidden;
  transition: transform 0.35s cubic-bezier(.2,.9,.2,1), box-shadow 0.35s ease;
  aspect-ratio: 4 / 3; /* keeps cards proportionate */
  min-height: 220px;
  box-shadow: 0 8px 30px rgba(0,0,0,0.5);
  border: 1px solid rgba(255,255,255,0.04);
  /* subtle glass/neon base */
  backdrop-filter: blur(4px) saturate(120%);
}

.project-card:hover {
  transform: translateY(-8px) scale(1.01);
  box-shadow: 0 18px 50px rgba(0,255,221,0.08), 0 8px 30px rgba(0,0,0,0.6);
}

.project-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: grayscale(100%);
  transition: filter 0.35s ease, transform 0.45s ease;
  transform: scale(1);
}

.project-card:hover img {
  filter: grayscale(0%);
  transform: scale(1.05); /* subtle zoom only for hovered card */
}

/* neon outline for card on focus/hover to match theme */
.project-card::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 16px;
  pointer-events: none;
  box-shadow: inset 0 0 0 1px rgba(0,255,221,0.03);
  transition: box-shadow 0.35s ease, transform 0.35s ease;
}
.project-card:hover::before {
  box-shadow: inset 0 0 0 1px rgba(0,255,221,0.06), 0 0 30px rgba(0,255,221,0.04);
}

/* Desc overlay: frosted bar at bottom with title and tools */
.project-card .desc {
  position: absolute;
  left: 1rem;
  right: 1rem;
  bottom: 1rem;
  padding: 0.9rem 1rem;
  background: linear-gradient(180deg, rgba(0,0,0,0.28), rgba(0,0,0,0.55));
  border-radius: 12px;
  color: var(--white);
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  transform: translateY(8px);
  opacity: 0.98;
  transition: transform 0.28s ease, opacity 0.28s ease;
  z-index: 8;
}

.project-card:hover .desc {
  transform: translateY(0);
  opacity: 1;
}

.project-card .desc h1 {
  font: italic 700 1.1rem "IBM Plex Sans", sans-serif;
  margin: 0;
  color: var(--white);
}

.project-card .desc p {
  font-size: 0.85rem;
  color: rgba(255,255,255,0.85);
  margin: 0;
}

/* Tools as compact pills inside the overlay */
.project-card .desc .tool {
  display: inline-block;
  background: rgba(255,255,255,0.06);
  color: var(--white);
  padding: 0.22rem 0.6rem;
  border-radius: 999px;
  margin-right: 0.4rem;
  font-size: 0.78rem;
  border: 1px solid rgba(255,255,255,0.03);
}

.github-button {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background-color: rgba(0, 0, 0, 0.7);
  border-radius: 50%;
  padding: 0.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background-color 0.3s ease;
  z-index: 10; /* Pour s'assurer qu'il est au-dessus de l'image */
}

.github-button:hover {
  background-color: rgba(0, 0, 0, 0.9);
}

.github-button img {
  width: 24px;
  height: 24px;
  filter: invert(1); /* Pour rendre le logo GitHub blanc */
}

/* New: github-link (box-icon) styling for project cards in projects.html
   Only the hovered project's icon should change to the primary LED color */
.project-card .github-link {
  position: absolute;
  top: 0.8rem;
  right: 0.8rem;
  z-index: 10;
  background: rgba(0,0,0,0.65);
  border-radius: 50%;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.18s ease, background 0.18s ease;
}

.project-card .github-link box-icon {
  width: 22px;
  height: 22px;
  fill: var(--white);
  transition: fill 0.18s ease, transform 0.18s ease;
}

/* On hover of the individual project card only, change the icon color to primary */
.project-card .github-link:active,
.project-card .github-link:focus,
.project-card .github-link:focus-visible {
  /* slight lift when interacting (keyboard or click) */
  transform: translateY(-2px);
}

.project-card .github-link:active box-icon,
.project-card .github-link:focus box-icon,
.project-card .github-link:focus-visible box-icon {
  /* icon becomes LED color on click/focus */
  fill: var(--primary);
  transform: scale(1.05);
  filter: drop-shadow(0 0 10px rgba(0, 255, 221, 0.35));
}

/* NEW: Neon effect when cursor hovers the GitHub icon itself
   Only the icon (and its immediate container) responds to hover, not the whole card */
.project-card .github-link:hover {
  background: rgba(0,0,0,0.9);
  transform: translateY(-2px) scale(1.02);
}

.project-card .github-link:hover box-icon {
  fill: var(--primary);
  transform: scale(1.12);
  filter: drop-shadow(0 0 20px rgba(0, 255, 221, 0.45));
}



.project-card .desc {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 1.4rem 1.6rem;
  background: linear-gradient(180deg, transparent 0%, rgba(0,0,0,0.6) 40%, rgba(0,0,0,0.9) 100%);
  color: var(--white);
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.35s ease, transform 0.35s ease;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.project-card:hover .desc {
  opacity: 1;
  transform: translateY(0);
}

.project-card .desc h1 {
  font: italic bold 1.25rem "IBM Plex Sans", sans-serif;
  margin: 0;
  color: var(--white);
  letter-spacing: 0.5px;
}

.project-card .desc p {
  font-size: 0.95rem;
  color: var(--gray);
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  align-items: center;
}

.project-card .desc p .tool {
  display: inline-block;
  background: transparent;
  color: var(--white);
  padding: 0.2rem 0.6rem;
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 12px;
  margin: 0 0.25rem 0.25rem 0;
  font-size: 0.85rem;
  font-weight: 600;
}

.project-card .github-button {
  position: absolute;
  top: 0.8rem;
  right: 0.8rem;
  z-index: 5;
}

/* Expand (+) button (top-left) */
.project-card .expand-btn,
.projects .expand-btn {
  position: absolute;
  top: 0.8rem;
  left: 0.8rem;
  z-index: 12;
  background: rgba(0,0,0,0.65);
  color: var(--white);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.2rem;
  cursor: pointer;
  border: 2px solid rgba(255,255,255,0.06);
  transition: transform 0.18s ease, background 0.18s ease, box-shadow 0.18s ease;
}

.project-card .expand-btn:hover,
.projects .expand-btn:hover {
  /* Keep button background dark but add neon outline and glow instead of full fill */
  background: rgba(0,0,0,0.78);
  color: var(--primary);
  transform: scale(1.06) translateY(-2px);
  border: 1px solid rgba(0,255,221,0.9);
  box-shadow:
    0 0 8px rgba(0,255,221,0.18), /* soft glow */
    0 0 18px rgba(0,255,221,0.12),
    inset 0 0 6px rgba(0,255,221,0.04);
}

/* Project detail modal */
.project-modal {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 99999;
}

.project-modal.open {
  display: flex;
}

.project-modal .backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.65);
  backdrop-filter: blur(6px) saturate(120%);
}

.project-modal .panel {
  position: relative;
  /* make the modal panel a bit larger on wide screens so content breathes more */
  width: min(1200px, 98%);
  max-height: 90vh;
  overflow: hidden;
  background: linear-gradient(180deg, rgba(8,8,8,0.95), rgba(6,6,6,0.98));
  border-radius: 18px;
  padding: 1.8rem;
  box-shadow: 0 24px 70px rgba(0,255,221,0.07), 0 10px 36px rgba(0,0,0,0.6);
  border: 1px solid rgba(0,255,221,0.06);
  display: grid;
  /* keep a comfortable right column but slightly more room overall */
  /* slightly reduce image area width so screenshots fit better; right column keeps controls */
  grid-template-columns: 0.92fr 420px;
  gap: 1.4rem;
}

.project-modal .panel .left {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  overflow: hidden;
}

.project-modal .panel .right {
  padding: 0.8rem;
  overflow-y: auto;
}

.project-modal .panel .title {
  text-align: center;
  font: italic bold 2.2rem "IBM Plex Sans", sans-serif;
  color: var(--white);
  text-shadow: 0 0 12px rgba(0,255,221,0.12);
}

.project-modal .panel .description {
  color: var(--gray);
  line-height: 1.6;
}

.project-modal .tools {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.6rem;
}

.project-modal .tools .tool {
  background: var(--primary);
  color: var(--black);
  padding: 0.3rem 0.7rem;
  border-radius: 16px;
  font-weight: 700;
  box-shadow: 0 0 14px rgba(0,255,221,0.14);
}

/* Carousel */
.project-modal .carousel {
  position: relative;
  width: 100%;
  /* Increased height to show images better */
  height: 400px;
  border-radius: 12px;
  overflow: hidden;
  background: #111;
}

/* Fit images to container without cropping */
.project-modal .carousel img,
.project-modal .carousel video {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 100%;
  height: 100%;
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  display: block;
}

/* Video controls styling */
.project-modal .carousel video {
  background: #000;
}

.project-modal .carousel video::-webkit-media-controls-panel {
  background: rgba(0,0,0,0.7);
}

.project-modal .carousel video::-webkit-media-controls-play-button {
  background-color: var(--primary);
  border-radius: 50%;
}

.project-modal .carousel video::-webkit-media-controls-current-time-display,
.project-modal .carousel video::-webkit-media-controls-time-remaining-display {
  color: var(--white);
}

/* For slides that use the modal-slide class ensure they are centered and clipped by overflow */
.project-modal .carousel img.modal-slide {
  display: block;
}

.project-modal .carousel .nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  gap: 0.5rem;
}

.project-modal .carousel .prev { left: 0.8rem; }
.project-modal .carousel .next { right: 0.8rem; }

.project-modal .carousel .nav button {
  background: rgba(0,0,0,0.6);
  border: 2px solid rgba(255,255,255,0.06);
  color: var(--white);
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.project-modal .panel .right .meta {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

/* Github link positioned top-right of the panel */
.project-modal .panel .github-top-right {
  position: absolute;
  top: 0.8rem;
  right: 0.8rem;
  z-index: 30;
}

/* Description heading and scrollable tools area */
.project-modal .meta .desc-heading {
  font: italic bold 1.25rem "IBM Plex Sans", sans-serif;
  color: var(--white);
}

.project-modal .meta .desc-text {
  color: var(--gray);
  max-height: 180px;
  overflow-y: auto;
  line-height: 1.6;
  padding-right: 0.4rem;
}

.project-modal .meta .tools {
  margin-top: 0.6rem;
  max-height: 140px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.project-modal .meta .tools .tool {
  background: rgba(255,255,255,0.06);
  color: var(--white);
  padding: 0.4rem 0.8rem;
  border-radius: 12px;
  font-weight: 600;
}

.project-modal .close-btn {
  position: absolute;
  top: 0.8rem;
  right: 0.8rem;
  z-index: 20;
  background: var(--primary);
  color: var(--black);
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: none;
  font-size: 1.2rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 18px rgba(0,255,221,0.45);
  transition: transform 0.12s ease, box-shadow 0.12s ease, opacity 0.12s ease;
}

.project-modal .close-btn:hover {
  transform: scale(1.06);
  box-shadow: 0 0 28px rgba(0,255,221,0.6);
}

@media (max-width: 900px) {
  .project-modal .panel { grid-template-columns: 1fr; }
  /* on small screens the frame should be a bit tighter */
  .project-modal .carousel { height: 140px; }
}

/* When image is toggled to expanded state increase the carousel height to show more and add a subtle transform */
.project-modal.image-expanded .carousel {
  height: min(70vh, 78vh);
}

.project-modal.image-expanded .carousel img {
  transform: translate(-50%, -50%) scale(1.02);
  transition: transform 260ms ease;
}

/* Hide the right column controls a bit less aggressively on image expand, keep them accessible below if overflow occurs */
.project-modal.image-expanded .panel {
  max-height: 95vh;
}

/* Tools slider: horizontal scroll with neon/led styling */
.project-modal .tools {
  display: flex;
  gap: 0.8rem;
  overflow-x: auto;
  padding: 0.5rem 0;
  -webkit-overflow-scrolling: touch;
  margin: 1rem 0;
}

.project-modal .tools::-webkit-scrollbar { height: 8px; }
.project-modal .tools::-webkit-scrollbar-thumb { 
  background: var(--primary);
  border-radius: 8px;
  box-shadow: 0 0 10px rgba(0, 255, 221, 0.2);
}

.project-modal .tools .tool {
  background: var(--primary);
  color: var(--black);
  padding: 0.5rem 1.2rem;
  border-radius: 24px;
  font-weight: 700;
  white-space: nowrap;
  border: none;
  box-shadow: 0 0 15px rgba(0, 255, 221, 0.2);
  transition: all 0.2s ease;
}

.project-modal .tools .tool:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 20px rgba(0, 255, 221, 0.4);
}

/* Position close button on the right and github icon on the left */
.project-modal .close-btn {
  right: 0.8rem;
}
.project-modal .panel .github-top-right {
  left: 0.8rem;
}

/* neon close button and github - softer glow */
.project-modal .close-btn {
  position: absolute;
  z-index: 30;
  width: 40px;
  height: 40px;
  background: transparent;
  color: var(--primary);
  font-size: 1.8rem;
  border: 1px solid var(--primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 0 5px rgba(0, 255, 221, 0.3);
  text-shadow: 0 0 3px var(--primary);
  transition: all 0.2s ease;
}

.project-modal .close-btn:hover {
  color: var(--primary);
  border-color: var(--primary);
  box-shadow: 0 0 8px rgba(0, 255, 221, 0.4);
  text-shadow: 0 0 4px var(--primary);
}

/* Add neon effect to github button too */
.project-modal .panel .github-top-right .download-button {
  background: transparent;
  border: 1px solid var(--primary);
  border-radius: 50%;
  padding: 0.5rem;
  box-shadow: 0 0 5px rgba(0, 255, 221, 0.3);
  transition: all 0.2s ease;
}

.project-modal .panel .github-top-right .download-button:hover {
  border-color: var(--primary);
  box-shadow: 0 0 8px rgba(0, 255, 221, 0.4);
}

.project-modal .panel .github-top-right .download-button box-icon {
  fill: var(--primary);
  filter: drop-shadow(0 0 2px var(--primary));
}


/* Apply same polished styles to the 3 recent projects on the homepage (.projects) */
.project .container .content .project-area .projects {
  position: relative;
  cursor: pointer;
  background: var(--black);
  border-radius: 24px;
  overflow: hidden;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  aspect-ratio: 9 / 3;
  min-height: 130px;
  box-shadow: 0 8px 32px rgba(0, 255, 221, 0.15);
}

.project .container .content .project-area .projects::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border-radius: 24px;
  border: 2px solid transparent;
  background: linear-gradient(135deg, var(--primary), transparent 50%);
  -webkit-mask: linear-gradient(#fff 0 0) padding-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  opacity: 0;
  transition: all 0.4s ease;
}

.project .container .content .project-area .projects:hover {
  transform: translateY(-8px);
  box-shadow: 0 12px 48px rgba(0, 255, 221, 0.3);
}

.project .container .content .project-area .projects:hover::before {
  opacity: 1;
}

.project .container .content .project-area .projects .github-link {
  position: absolute;
  top: 1rem;
  right: 1rem;
  z-index: 10;
  background: rgba(0, 0, 0, 0.7);
  border-radius: 50%;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  opacity: 0;
  transform: translateY(-10px);
}

.project .container .content .project-area .projects:hover .github-link {
  opacity: 1;
  transform: translateY(0);
}

.project .container .content .project-area .projects .github-link box-icon {
  fill: var(--white);
  width: 24px;
  height: 24px;
  transition: all 0.3s ease;
}

.project .container .content .project-area .projects .github-link:hover {
  background: var(--primary);
  transform: scale(1.1);
}

.project .container .content .project-area .projects .github-link:hover box-icon {
  fill: var(--black);
}

.project .container .content .project-area .projects img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: grayscale(100%);
  transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.project .container .content .project-area .projects:hover img {
  filter: grayscale(0%);
  transform: scale(1.05);
}

.project .container .content .project-area .projects .project-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(
    180deg, 
    rgba(0, 0, 0, 0) 0%,
    rgba(0, 0, 0, 0.7) 70%, 
    rgba(0, 0, 0, 0.9) 100%
  );
  opacity: 0;
  transition: all 0.4s ease;
}

.project .container .content .project-area .projects:hover .project-overlay {
  opacity: 1;
}

.project .container .content .project-area .projects .desc {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 2rem;
  color: var(--white);
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 2;
}

.project .container .content .project-area .projects:hover .desc {
  opacity: 1;
  transform: translateY(0);
}

.project .container .content .project-area .projects .desc h1 {
  font: italic bold 1.5rem "IBM Plex Sans", sans-serif;
  margin: 0;
  margin-bottom: 1rem;
  color: var(--white);
  text-shadow: 0 0 10px rgba(0, 255, 221, 0.3);
}

.project .container .content .project-area .projects .desc .tools-container {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.project .container .content .project-area .projects .desc .tool {
  font-size: 0.85rem;
  color: var(--black);
  background: var(--primary);
  padding: 0.3rem 0.8rem;
  border-radius: 20px;
  font-weight: 600;
  transition: all 0.3s ease;
  box-shadow: 0 0 15px rgba(0, 255, 221, 0.3);
}

.project .container .content .project-area .projects:hover .desc .tool {
  transform: scale(1.05);
}


.back-to-home {
  margin-top: 2rem;
}

.back-button {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  background-color: var(--white);
  color: var(--black);
  border-radius: 32px;
  font: bold 1rem "IBM Plex Sans", sans-serif;
  text-decoration: none;
  transition: background-color 0.3s ease;
}

.back-button:hover {
  background-color: var(--primary);
}

/*----------------------------------------------------------------*/
/* Styles pour la page "Hidden Me" */
.hidden-me {
  padding: 4rem 0;
  min-height: 100vh;
  background-color: var(--black);
}

/* Styles pour les sections */
.section {
  display: flex;
  align-items: center;
  gap: 2rem; /* Espace entre l'image et la description */
  margin-bottom: 4rem; /* Espace entre les sections */
}

.section .image,
.section .description {
  flex: 2; /* Prend 50% de la largeur */
}

.section .image img {
  width: 400px; /* Largeur fixe pour toutes les images */
  height: 400px; /* Hauteur fixe pour toutes les images */
  aspect-ratio: 1; /* Garantit que les images sont carrées */
   /* object-fit: cover;      Remplit le carré sans déformation */
  border-radius: 16px;
  filter: grayscale(100%);
  transition: filter 0.3s ease;
}

.section .image:hover img {
  filter: grayscale(0%);
}

.section .description {
  padding: 2rem;
}

.section .description h2 {
  font: italic bold 4rem "IBM Plex Sans", sans-serif;
  color: var(--primary);
  margin-bottom: 1rem;
}

.section .description p {
  font-size: 1rem;
  color: var(--white);
  line-height: 1.6;
}

/* Alternance des sections */
.section:nth-child(odd) {
  flex-direction: row; /* Photo à gauche, description à droite */
}

.section:nth-child(even) {
  flex-direction: row-reverse; /* Description à gauche, photo à droite */
}

/* Bouton de téléchargement */
.download-button {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  background-color: var(--primary);
  color: var(--white);
  border-radius: 32px;
  font: bold 1rem "IBM Plex Sans", sans-serif;
  text-decoration: none;
  transition: background-color 0.3s ease;
}

.download-button:hover {
  background-color: var(--white);
  color: var(--black);
}

.download-button box-icon {
  width: 20px;
  height: 20px;
}

/* Bouton pour retourner à la page d'accueil */
.back-to-home {
  display: flex;
  justify-content: center;
  margin-top: 4rem;
}

.back-button {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  background-color: var(--white);
  color: var(--black);
  border-radius: 32px;
  font: bold 1rem "IBM Plex Sans", sans-serif;
  text-decoration: none;
  transition: background-color 0.3s ease;
}

.back-button:hover {
  background-color: var(--primary);
}
/* ------------------------------------------------------------------*/
.download-button {
  display: inline-flex;
  align-items: center;
  gap: 2rem;
  padding: 0.75rem 1.5rem;
  background-color: var(--black);
  border: 2px solid #ffffff;
  color: var(--white);
  border-radius: 32px;
  font: bold 1rem "IBM Plex Sans", sans-serif;
  text-decoration: none;
  transition: background-color 0.3s ease;
}

.download-button:hover {
  background-color: var(--primary);
  color: var(--black);
  transition: .2s linear;
}

.download-button box-icon {
  width: 20px;
  height: 20px;
}

/* Styles pour la section des réseaux sociaux */
.social-media {
  padding: 4rem 0;
  background-color: var(--black);
}

.social-media .container .content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
}

.social-media h2 {
  font: italic bold 2rem "IBM Plex Sans", sans-serif;
  color: var(--gray);
}

.social-links {
  display: flex;
  gap: 2rem;
  justify-content: center;
  flex-wrap: wrap;
}

.social-link {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem 2rem;
  background-color: var(--black);
  border: 2px solid var(--white);
  border-radius: 32px;
  color: var(--white);
  font: bold 1rem "IBM Plex Sans", sans-serif;
  transition: all 0.3s ease;
}

.social-link:hover {
  background-color: var(--primary);
  color: var(--black);
  transform: translateY(-5px);
}

.social-link box-icon {
  fill: var(--white);
}

.social-link:hover box-icon {
  fill: var(--black);
}

/* Style pour le bouton retour à l'accueil */
.back-to-home {
  display: flex;
  justify-content: center;
  margin: 4rem 0;
}

.home-button {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem 2rem;
  background-color: var(--black);
  border: 2px solid var(--white);
  border-radius: 32px;
  color: var(--white);
  font: bold 1rem "IBM Plex Sans", sans-serif;
  transition: all 0.3s ease;
}

.home-button:hover {
  background-color: var(--primary);
  color: var(--black);
  transform: translateY(-5px);
}

.home-button box-icon {
  fill: var(--white);
}

.home-button:hover box-icon {
  fill: var(--black);
}

/* ============================================
   RESPONSIVE MEDIA QUERIES - MOBILE & TABLET
   ============================================ */

/* Tablet - Large (1024px - 1200px) */
@media (max-width: 1200px) {
  .container {
    padding: 1.5rem 4rem;
  }

  .hero .container .content h1 {
    font-size: 3.5rem;
  }

  .hero .container .content .row-2 {
    font-size: 3.5rem;
  }

  .project .container .content .header .title .row-1,
  .project .container .content .header .title .row-2 {
    font-size: 2.5rem;
  }
}

/* Tablet - Medium (768px - 1024px) */
@media (max-width: 1024px) {
  .container {
    padding: 1.5rem 3rem;
  }

  header .container .content nav {
    gap: 1.5rem;
  }

  header .container .content nav a {
    font-size: 0.9rem;
  }

  .hero .container .content h1 {
    font-size: 3rem;
  }

  .hero .container .content .row-2 {
    font-size: 3rem;
  }

  .hero .container .content p {
    font-size: 1rem;
    width: 80%;
  }

  .project .container .content .project-area {
    height: 300px;
    gap: 0.8rem;
  }

  .project .container .content .project-area .projects .desc h1 {
    font-size: 1.2rem;
  }

  .project .container .content .project-area .projects .desc .tool {
    font-size: 0.75rem;
    padding: 0.25rem 0.6rem;
  }

  .skill .container .content .skills {
    grid-template-columns: repeat(auto-fit, minmax(80px, 1fr));
    gap: 1.5rem;
  }

  .skill .container .content .skill-box {
    width: 80px;
    height: 80px;
  }

  .section .image img {
    width: 300px;
    height: 300px;
  }

  .section .description h2 {
    font-size: 3rem;
  }
}

/* Mobile - Large (600px - 768px) */
@media (max-width: 768px) {
  .container {
    padding: 1rem 2rem;
  }

  header .container .content {
    flex-direction: column;
    gap: 1rem;
  }

  header .container .content nav {
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
  }

  .hero {
    height: auto;
    min-height: 100vh;
    padding: 8rem 0 4rem;
  }

  .hero .container .content {
    gap: 2rem;
  }

  .hero .container .content h1 {
    font-size: 2.5rem;
  }

  .hero .container .content .row-2 {
    font-size: 2.5rem;
  }

  .hero .container .content p {
    font-size: 0.95rem;
    width: 100%;
  }

  .hero .container .content .btn {
    padding: 0.8rem 2rem;
    font-size: 0.9rem;
  }

  .project .container .content .header .title .row-1,
  .project .container .content .header .title .row-2 {
    font-size: 2rem;
  }

  .project .container .content .project-area {
    flex-direction: column;
    height: auto;
    gap: 1.5rem;
  }

  .project .container .content .project-area .projects {
    width: 100%;
    min-height: 200px;
  }

  .project .container .content .project-area .projects .desc {
    padding: 1.5rem;
  }

  .project .container .content .project-area .projects .desc h1 {
    font-size: 1.1rem;
  }

  .skill .container .content h1 {
    font-size: 2rem;
  }
}

/* Tablet - Large (1024px - 1200px) */
@media (max-width: 1200px) {
  .container {
    padding: 1.5rem 4rem;
  }

  .hero .container .content h1 {
    font-size: 3.5rem;
  }

  .hero .container .content .row-2 {
    font-size: 3.5rem;
  }

  .project .container .content .header .title .row-1,
  .project .container .content .header .title .row-2 {
    font-size: 2.5rem;
  }
}

/* Tablet - Medium (768px - 1024px) */
@media (max-width: 1024px) {
  .container {
    padding: 1.5rem 3rem;
  }

  header .container .content nav {
    gap: 1.5rem;
  }

  header .container .content nav a {
    font-size: 0.9rem;
  }

  .hero .container .content h1 {
    font-size: 3rem;
  }

  .hero .container .content .row-2 {
    font-size: 3rem;
  }

  .hero .container .content p {
    font-size: 1rem;
    width: 80%;
  }

  .project .container .content .project-area {
    height: 300px;
    gap: 0.8rem;
  }

  .project .container .content .project-area .projects .desc h1 {
    font-size: 1.2rem;
  }

  .project .container .content .project-area .projects .desc .tool {
    font-size: 0.75rem;
    padding: 0.25rem 0.6rem;
  }

  .skill .container .content .skills {
    grid-template-columns: repeat(auto-fit, minmax(80px, 1fr));
    gap: 1.5rem;
  }

  .skill .container .content .skill-box {
    width: 80px;
    height: 80px;
  }

  .section .image img {
    width: 300px;
    height: 300px;
  }

  .section .description h2 {
    font-size: 3rem;
  }
}

/* Tablet - Medium (768px - 1024px) */
@media (max-width: 1024px) {
  .container {
    padding: 1.5rem 3rem;
  }

  header .container .content nav {
    gap: 1.5rem;
  }

  header .container .content nav a {
    font-size: 0.9rem;
  }

  .hero .container .content h1 {
    font-size: 3rem;
  }

  .hero .container .content .row-2 {
    font-size: 3rem;
  }

  .hero .container .content p {
    font-size: 1rem;
    width: 80%;
  }

  .project .container .content .project-area {
    height: 300px;
    gap: 0.8rem;
  }

  .project .container .content .project-area .projects .desc h1 {
    font-size: 1.2rem;
  }

  .project .container .content .project-area .projects .desc .tool {
    font-size: 0.75rem;
    padding: 0.25rem 0.6rem;
  }

  .skill .container .content .skills {
    grid-template-columns: repeat(auto-fit, minmax(80px, 1fr));
    gap: 1.5rem;
  }

  .skill .container .content .skill-box {
    width: 80px;
    height: 80px;
  }

  .section .image img {
    width: 300px;
    height: 300px;
  }

  .section .description h2 {
    font-size: 3rem;
  }
}

/* Tablet - Medium (768px - 1024px) */
@media (max-width: 1024px) {
  .container {
    padding: 1.5rem 3rem;
  }

  header .container .content nav {
    gap: 1.5rem;
  }

  header .container .content nav a {
    font-size: 0.9rem;
  }

  .hero .container .content h1 {
    font-size: 3rem;
  }

  .hero .container .content .row-2 {
    font-size: 3rem;
  }

  .hero .container .content p {
    font-size: 1rem;
    width: 80%;
  }

  .project .container .content .project-area {
    height: 300px;
    gap: 0.8rem;
  }

  .project .container .content .project-area .projects .desc h1 {
    font-size: 1.2rem;
  }

  .project .container .content .project-area .projects .desc .tool {
    font-size: 0.75rem;
    padding: 0.25rem 0.6rem;
  }

  .skill .container .content .skills {
    grid-template-columns: repeat(auto
    gap: 1.5rem;
  }

  header .container .content nav a {
    font-size: 0.9rem;
  }

  .hero .container .content h1 {
    font-size: 3rem;
  }

  .hero .container .content .row-2 {
    font-size: 3rem;
  }

  .hero .container .content p {
    font-size: 1rem;
    width: 80%;
  }

  .project .container .content .project-area {
    height: 300px;
    gap: 0.8rem;
  }

  .project .container .content .project-area .projects .desc h1 {
    font-size: 1.2rem;
  }

  .project .container .content .project-area .projects .desc .tool {
    font-size: 0.75rem;
    padding: 0.25rem 0.6rem;
  }

  .skill .container .content .skills {
    grid-template-columns: repeat(auto-fit, minmax(80px, 1fr));
    gap: 1.5rem;
  }

  .skill .container .content .skill-box {
    width: 80px;
    height: 80px;
  }

  .section .image img {
    width: 300px;
    height: 300px;
  }

  .section .description h2 {
    font-size: 3rem;
  }
}

/* Mobile - Large (600px - 768px) */
@media (max-width: 768px) {
  .container {
    padding: 1rem 2rem;
  }

  header .container .content {
    flex-direction: column;
    gap: 1rem;
  }

  header .container .content nav {
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
  }

  .hero {
    height: auto;
    min-height: 100vh;
    padding: 8rem 0 4rem;
  }

  .hero .container .content {
    gap: 2rem;
  }

  .hero .container .content h1 {
    font-size: 2.5rem;
  }

  .hero .container .content .row-2 {
    font-size: 2.5rem;
  }

  .hero .container .content p {
    font-size: 0.95rem;
    width: 100%;
  }

  .hero .container .content .btn {
    padding: 0.8rem 2rem;
    font-size: 0.9rem;
  }

  .project .container .content .header .title .row-1,
  .project .container .content .header .title .row-2 {
    font-size: 2rem;
  }

  .project .container .content .project-area {
    flex-direction: column;
    height: auto;
    gap: 1.5rem;
  }

  .project .container .content .project-area .projects {
    width: 100%;
    min-height: 200px;
  }

  .project .container .content .project-area .projects .desc {
    padding: 1.5rem;
  }

  .project .container .content .project-area .projects .desc h1 {
    font-size: 1.1rem;
  }

  .skill .container .content h1 {
    font-size: 2rem;
  }
}

/* Tablet - Large (1024px - 1200px) */
@media (max-width: 1200px) {
  .container {
    padding: 1.5rem 4rem;
  }

  .hero .container .content h1 {
    font-size: 3.5rem;
  }

  .hero .container .content .row-2 {
    font-size: 3.5rem;
  }

  .project .container .content .header .title .row-1,
  .project .container .content .header .title .row-2 {
    font-size: 2.5rem;
  }
}

/* Tablet - Medium (768px - 1024px) */
@media (max-width: 1024px) {
  .container {
    padding: 1.5rem 3rem;
  }

  header .container .content nav {
    gap: 1.5rem;
  }

  header .container .content nav a
  .skill .container .content .skills {
    grid-template-columns: repeat(auto-fit, minmax(70px, 1fr));
    gap: 1rem;
  }

  .skill .container .content .skill-box {
    width: 70px;
    height: 70px;
  }

  .contact .container .content .title h2 {
    font-size: 2rem;
  }

  .contact .container .content .title h1 {
    font-size: 3rem;
  }

  .contact .container .content .contact-area {
    flex-direction: column;
  }

  .contact .container .content .contact-area .left-side h1 {
    font-size: 2rem;
  }

  .section {
    flex-direction: column !important;
    gap: 1.5rem;
  }

  .section .image img {
    width: 100%;
    max-width: 350px;
    height: auto;
  }

  .section .description {
    padding: 1rem;
  }

  .section .description h2 {
    font-size: 2.5rem;
  }

  .project-modal .panel {
    padding: 1.2rem;
  }

  .project-modal .panel .title {
    font-size: 1.5rem;
  }

  .project-modal .carousel {
    height: 250px;
  }
}

/* Mobile - Medium (480px - 600px) */
@media (max-width: 600px) {
  .container {
    padding: 1rem 1.5rem;
  }

  header {
    height: auto;
    padding: 1rem 0;
  }

  header .container .content .logo a {
    font-size: 1.2rem;
  }

  header .container .content nav a {
    font-size: 0.85rem;
    padding: 0.4rem 0.8rem;
  }

  .hero .container .content h1 {
    font-size: 2rem;
  }

  .hero .container .content .row-2 {
    font-size: 2rem;
  }

  .hero .container .content p {
    font-size: 0.9rem;
  }

  .hero .container .content .btn {
    padding: 0.7rem 1.5rem;
    font-size: 0.85rem;
  }

  .project .container .content .header .title .row-1,
  .project .container .content .header .title .row-2 {
    font-size: 1.8rem;
  }

  .project .container .content .project-area .projects {
    min-height: 180px;
  }

  .project .container .content .project-area .projects .desc h1 {
    font-size: 1rem;
  }

  .project .container .content .project-area .projects .desc .tool {
    font-size: 0.7rem;
    padding: 0.2rem 0.5rem;
  }

  .skill .container .content h1 {
    font-size: 1.8rem;
  }

  .skill .container .content .skills {
    grid-template-columns: repeat(auto-fit, minmax(60px, 1fr));
    gap: 0.8rem;
  }

  .skill .container .content .skill-box {
    width: 60px;
    height: 60px;
  }

  .contact .container .content .title h2 {
    font-size: 1.5rem;
  }

  .contact .container .content .title h1 {
    font-size: 2.5rem;
  }

  .contact .container .content .contact-area .left-side h1 {
    font-size: 1.5rem;
  }

  .contact .container .content .contact-area .right-side form input,
  .contact .container .content .contact-area .right-side form textarea {
    font-size: 0.9rem;
    padding: 0.8rem;
  }

  .contact .container .content .contact-area .right-side form button {
    padding: 0.7rem 1.5rem;
    font-size: 0.9rem;
  }

  .section .image img {
    max-width: 280px;
  }

  .section .description h2 {
    font-size: 2rem;
  }

.category-section {
  margin: 4rem 0;
  width: 100%;
}

.category-title {
  font: italic bold 2.5rem "IBM Plex Sans", sans-serif;
  color: var(--white);
  text-align: left;
  margin-bottom: 2rem;
  padding-left: 2rem;
  position: relative;
}

.category-title::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 4px;
  height: 60%;
  background: linear-gradient(180deg, var(--primary), var(--white));
  border-radius: 2px;
}

@media (max-width: 768px) {
  .category-title {
    font-size: 2rem;
    padding-left: 1.5rem;
  }
}

@media (max-width: 480px) {
  .category-title {
    font-size: 1.5rem;
    padding-left: 1rem;
  }
}
  .section .description p {
    font-size: 0.9rem;
  }

  .project-modal .panel {
    padding: 1rem;
  }

  .project-modal .panel .title {
    font-size: 1.3rem;
  }

  .project-modal .carousel {
    height: 200px;
  }

  .project-modal .carousel .nav button {
    width: 36px;
    height: 36px;
    font-size: 1.2rem;
  }
}

/* Mobile - Small (320px - 480px) */
@media (max-width: 480px) {
  .container {
    padding: 1rem;
  }

  header .container .content .logo img {
    width: 35px;
    height: 35px;
  }

  header .container .content .logo a {
    font-size: 1rem;
  }

  header .container .content nav {
    gap: 0.5rem;
  }

  header .container .content nav a {
    font-size: 0.75rem;
    padding: 0.3rem 0.6rem;
  }

  .hero .container .content h1 {
    font-size: 1.5rem;
  }

  .hero .container .content .row-2 {
    font-size: 1.5rem;
  }

  .hero .container .content p {
    font-size: 0.85rem;
  }

  .hero .container .content .btn {
    padding: 0.6rem 1.2rem;
    font-size: 0.8rem;
  }

  .project .container .content .header .title .row-1,
  .project .container .content .header .title .row-2 {
    font-size: 1.5rem;
  }

  .project .container .content .project-area {
    gap: 1rem;
  }

  .project .container .content .project-area .projects {
    min-height: 150px;
  }

  .project .container .content .project-area .projects .desc {
    padding: 1rem;
  }

  .project .container .content .project-area .projects .desc h1 {
    font-size: 0.9rem;
  }

  .project .container .content .project-area .projects .desc .tool {
    font-size: 0.65rem;
    padding: 0.15rem 0.4rem;
  }

  .project .container .content .project-area .projects .github-link,
  .project .container .content .project-area .projects .expand-btn {
    width: 32px;
    height: 32px;
    font-size: 1rem;
  }

  .skill .container .content h1 {
    font-size: 1.5rem;
  }

  .skill .container .content .skills {
    grid-template-columns: repeat(auto-fit, minmax(50px, 1fr));
    gap: 0.6rem;
  }

  .skill .container .content .skill-box {
    width: 50px;
    height: 50px;
  }

  .contact .container .content .title h2 {
    font-size: 1.2rem;
  }

  .contact .container .content .title h1 {
    font-size: 2rem;
  }

  .contact .container .content .contact-area .left-side h1 {
    font-size: 1.2rem;
  }

  .contact .container .content .contact-area .right-side form input,
  .contact .container .content .contact-area .right-side form textarea {
    font-size: 0.85rem;
    padding: 0.7rem;
  }

  .contact .container .content .contact-area .right-side form button {
    padding: 0.6rem 1.2rem;
    font-size: 0.85rem;
  }

  footer .container .content h1 {
    font-size: 1rem;
  }

  .section .image img {
    max-width: 100%;
  }

  .section .description h2 {
    font-size: 1.5rem;
  }

  .section .description p {
    font-size: 0.85rem;
  }

  .project-modal .panel {
    width: 95%;
    padding: 0.8rem;
  }

  .project-modal .panel .title {
    font-size: 1.1rem;
  }

  .project-modal .carousel {
    height: 180px;
  }

  .project-modal .carousel .nav {
    display: none;
  }

  .project-modal .close-btn {
    width: 32px;
    height: 32px;
    font-size: 1.4rem;
  }

  .project-modal .meta .desc-text {
    font-size: 0.85rem;
  }

  .project-modal .tools .tool {
    font-size: 0.75rem;
    padding: 0.3rem 0.8rem;
  }

  .project-grid {
    padding: 0 1rem;
    gap: 1.5rem;
  }

  .project-card .desc h1 {
    font-size: 0.95rem;
  }

  .project-card .desc p {
    font-size: 0.75rem;
  }

  .project-card .desc .tool {
    font-size: 0.7rem;
    padding: 0.18rem 0.5rem;
  }
}

/* ============================================
   CROSS-BROWSER COMPATIBILITY FIXES
   ============================================ */

/* Fix for Safari backdrop-filter */
@supports (-webkit-backdrop-filter: none) or (backdrop-filter: none) {
  .project-modal .backdrop {
    -webkit-backdrop-filter: blur(6px) saturate(120%);
    backdrop-filter: blur(6px) saturate(120%);
  }

  .project-card {
    -webkit-backdrop-filter: blur(4px) saturate(120%);
    backdrop-filter: blur(4px) saturate(120%);
  }
}

/* Fallback for browsers that don't support backdrop-filter */
@supports not ((-webkit-backdrop-filter: none) or (backdrop-filter: none)) {
  .project-modal .backdrop {
    background: rgba(0,0,0,0.85);
  }

  .project-card {
    background: linear-gradient(180deg, rgba(255,255,255,0.05), rgba(255,255,255,0.02));
  }
}

/* Fix for iOS Safari smooth scrolling */
@supports (-webkit-overflow-scrolling: touch) {
  body {
    -webkit-overflow-scrolling: touch;
  }

  .project-modal .panel .right {
    -webkit-overflow-scrolling: touch;
  }
}

/* Fix for Firefox scrollbar */
@-moz-document url-prefix() {
  * {
    scrollbar-width: thin;
    scrollbar-color: var(--white) transparent;
  }
}

/* Prevent text selection on buttons and interactive elements */
button, .btn, .expand-btn, .github-link, .close-btn {
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}

/* Smooth font rendering across browsers */
body {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

/* Fix for transform flickering in Chrome/Safari */
.project-card,
.projects,
.expand-btn,
.github-link {
  -webkit-transform: translateZ(0);
  -moz-transform: translateZ(0);
  -ms-transform: translateZ(0);
  transform: translateZ(0);
  -webkit-backface-visibility: hidden;
  -moz-backface-visibility: hidden;
  backface-visibility: hidden;
}

/* Ensure images don't drag on mobile */
img {
  -webkit-user-drag: none;
  -khtml-user-drag: none;
  -moz-user-drag: none;
  -o-user-drag: none;
  user-drag: none;
}

/* Fix for iOS input zoom */
@media screen and (max-width: 768px) {
  input[type="text"],
  input[type="email"],
  textarea {
    font-size: 16px !important;
  }
}

/* Landscape orientation fixes for mobile */
@media (max-width: 768px) and (orientation: landscape) {
  .hero {
    min-height: auto;
    padding: 6rem 0 3rem;
  }

  .project .container .content .project-area {
    flex-direction: row;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  .project .container .content .project-area .projects {
    min-width: 300px;
  }
}

/* Print styles */
@media print {
  header {
    position: relative;
  }

  .expand-btn,
  .github-link,
  .project-modal {
    display: none !important;
  }

  .project-card,
  .projects {
    break-inside: avoid;
  }
}



