body,
html {
  margin: 0;
  padding: 0;
  height: 100%;
  width: 100%;
  font-family: "Poppins", sans-serif;
  background: black;
}

main {
  padding: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.hrefDesc {
  text-decoration: none;
  color: white;
  border-bottom: 1px solid #be5e0f;
}
.hrefDesc {
  text-decoration: none;
  color: white;
  border-bottom: 1px solid #be5e0f;
  transition: color 0.3s ease, border-color 0.3s ease;
}

.hrefDesc:hover {
  color: #fb923c;
  border-color: #fb923c;
}

/* Scrollbar */
::-webkit-scrollbar {
  width: 8px;
  transition: width 0.2s ease;
}

::-webkit-scrollbar-track {
  background: #222;
}

::-webkit-scrollbar-thumb {
  background: #444;
  border-radius: 10px;
  transition: background-color 0.3s ease, transform 0.2s ease;
}

::-webkit-scrollbar-thumb:hover {
  background: #666;
  transform: scale(1.1);
}

/* Animation début site */
.before-appear {
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.6s ease-out;
}

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

body {
  opacity: 0;
  transition: opacity 1s ease-out;
}

body.loaded {
  opacity: 1;
}

.navbar {
  position: fixed;
  top: 0;
  width: 100%;
  padding: 16px 40px;
  backdrop-filter: blur(8px);
  z-index: 100;
}

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

.nav-links {
  list-style: none;
  display: flex;
  gap: 30px;
}

.nav-links a {
  text-decoration: none;
  color: white;
  font-weight: 400;
  transition: color 0.2s ease-in-out;
  position: relative;
  /* use will-change pour meilleures perfs */
  will-change: color;
}

.nav-links a:hover {
  color: #fb923c;
}

.nav-links a:hover::after {
  width: 100%;
}

@media (max-width: 768px) {
  .navbar {
    padding: 10px 20px 0 0;
    font-size: 0.9rem;
    text-align: center;
  }
}

.main-content {
  padding: 10px 0 0;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 95vh;
  color: white;
}

.profile-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.profile-picture {
  width: 200px;
  height: 200px;
  border-radius: 50%;
  object-fit: cover;
  border: 6px solid #fb923c;
  margin-bottom: 25px;
  box-shadow: 0 10px 25px rgba(251, 146, 60, 0.3);
}

.username {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 8px;
  background: linear-gradient(90deg, #fb923c, #e67e22);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.description {
  position: relative;
  font-size: 1.2rem;
  color: #ccc;
  margin-bottom: 30px;
  padding-bottom: 12px;
}

.description::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 40px;
  height: 2px;
  background: linear-gradient(90deg, #fb923c, #e67e22);
}

.action-buttons {
  display: flex;
  gap: 20px;
  margin-bottom: 30px;
}

.action-btn {
  padding: 10px 14px;
  border-radius: 35px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.3s ease;
}

.cv-btn {
  background: linear-gradient(135deg, #fb923c, #e67e22);
  color: white;
}

.cv-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(251, 146, 60, 0.4);
}

.contact-btn {
  background: transparent;
  color: white;
  border: 3px solid #fb923c;
}

.contact-btn:hover {
  background: rgba(251, 146, 60, 0.15);
  transform: translateY(-2px);
}

.icons {
  display: flex;
  gap: 20px;
}

.icon {
  font-size: 2.5rem;
  color: #bbbbbb;
  transition: all 0.3s ease;
}

.icon:hover {
  transform: translateY(-4px);
}

/* Github icon hover color */
.github-icon:hover {
  color: white;
}

/* LinkedIn icon hover color */
.linkedin-icon:hover {
  color: #0077b5; /* LinkedIn blue */
}

.buymeacoffee-icon:hover {
  color: #5b3c28;
}

/* Section Projets */
.projects-section {
  min-height: 95vh;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  background-color: black;
}

.container {
  width: 100%;
  max-width: 1200px;
  margin: 5rem auto 0;
}

.section-title {
  color: white;
  font-size: 2rem;
  font-weight: 600;
  margin-bottom: 50px;
  text-align: center;
  position: relative;
  padding-bottom: 15px;
}

.section-title::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 70px;
  height: 3px;
  background: linear-gradient(90deg, #fb923c, #e67e22);
}

.projects-container {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  margin-bottom: 4rem;
}

/* Card Projet */
.project-card {
  border-radius: 16px;
  overflow: visible;
  transform: translateY(40px);
  opacity: 0;
  transition: all 0.6s cubic-bezier(0.22, 1, 0.36, 1);
  margin: 0 1rem 2rem 1rem;
}

.project-card-inner {
  background-color: #0c0e14;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 20px 30px rgba(0, 0, 0, 0.3);
  transition: transform 0.5s cubic-bezier(0.22, 1, 0.36, 1);
  height: 100%;
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.project-card:hover .project-card-inner {
  transform: translateY(-10px);
  box-shadow: 0 30px 50px rgba(0, 0, 0, 0.5);
  border-color: rgba(230, 126, 34, 0.2);
}

/* Image */
.project-image {
  width: 100%;
  height: 200px;
  position: relative;
  overflow: hidden;
}

.project-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.8s ease;
}

.project-card:hover .project-image img {
  transform: scale(1.05);
}

.project-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.4s ease;
}

.project-card:hover .project-overlay {
  opacity: 1;
}

/* Contenu */
.project-content {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
}

.project-title {
  font-size: 1.4rem;
  font-weight: 700;
  margin: 0;
  color: #fff;
}

.tech-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tech-stack span {
  background: rgba(230, 126, 34, 0.15);
  padding: 4px 12px;
  font-size: 0.75rem;
  border-radius: 9999px;
  color: #fb923c;
  font-weight: 500;
  transition: all 0.3s ease;
}

.project-card:hover .tech-stack span {
  background: rgba(230, 126, 34, 0.25);
}

.project-description {
  font-size: 0.95rem;
  line-height: 1.6;
  color: #94a3b8;
  flex-grow: 1;
}

.expand-btn {
  align-self: flex-start;
  padding: 0;
  background: none;
  border: none;
  color: #e67e22;
  font-size: 0.9rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 500;
  transition: all 0.3s ease;
}

.expand-btn .fa-chevron-right {
  font-size: 0.7rem;
  transition: transform 0.3s ease;
}

.expand-btn:hover {
  color: #fb923c;
}

.expand-btn:hover .fa-chevron-right {
  transform: translateX(4px);
}

/* Boutons */
.project-buttons {
  display: flex;
  gap: 12px;
}

.btn {
  padding: 10px 20px;
  border-radius: 8px;
  text-decoration: none;
  color: white;
  font-weight: 600;
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: all 0.3s ease;
}

.github-btn {
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(5px);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.github-btn:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
}

.demo-btn {
  background: #e67e22;
  border: 1px solid #e67e22;
  font-weight: semibold;
  cursor: pointer;
}

.demo-btn:hover {
  background: #f39c12;
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(230, 126, 34, 0.4);
}

/* About Section */
.about-section {
  padding: 50px 20px;
  color: white;
}

.projects-btnOthers {
  display: flex;
  justify-content: center;
  margin-top: -2rem;
}

.about-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 40px;
  flex-wrap: wrap;
}

.about-text {
  flex: 1;
  font-size: 1.1rem;
  line-height: 1.8;
  color: #ccc;
}

.about-text strong {
  color: #fb923c;
}

.about-item {
  margin-bottom: 30px;
}

.about-item h3 {
  font-size: 1.5rem;
  margin-bottom: 10px;
}

.about-item ul {
  list-style: none;
  padding: 0;
  color: #ccc;
}

.about-item li {
  font-size: 1.1rem;
  margin-bottom: 10px;
}

.about-image {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: center;
}

.about-photo {
  width: 100%;
  max-width: 300px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid #fb923c;
  margin-bottom: 20px;
  box-shadow: 0 10px 25px rgba(251, 146, 60, 0.3);
}

.icon-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
}

.icon-title i {
  color: #fb923c;
  font-size: 1.1rem;
}

@media (max-width: 768px) {
  .about-content {
    flex-direction: column;
    text-align: center;
  }

  .about-image {
    order: -1;
    max-width: 50%;
  }
  .about-text {
    font-size: 1rem;
    text-align: left;
    line-height: 1.6;
    padding: 0 10px;
  }

  .about-text p {
    text-align: center;
  }
}
.container2 {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto 0;
}
/* Contact */
.contact-section {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
}

.contact-container {
  max-width: 600px;
  margin: 0 auto;
}

.contact-form {
  background-color: #222;
  padding: 30px;
  border-radius: 10px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.form-group {
  margin-bottom: 20px;
  display: flex;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 12px;
  border: 1px solid #444;
  border-radius: 6px;
  font-family: "Poppins", sans-serif;
  background-color: #333;
  color: #ddd;
  transition: border-color 0.3s, background-color 0.3s;
}

.form-group input:focus,
.form-group textarea:focus {
  border-color: #fb923c;
  outline: none;
  background-color: #444;
}

.submit-btn {
  background-color: #ff8929;
  color: white;
  border: none;
  padding: 12px 25px;
  border-radius: 6px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.submit-btn:hover {
  background-color: #da6200;
  transform: translateY(-2px);
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.25);
}

.submit-msg-status {
  margin-left: 10px;
  font-size: 0.9rem;
  text-align: center;
  color: #fb923c;
}

.contact-info {
  margin-top: 40px;
  text-align: center;
  color: #ddd;
  font-size: 1rem;
  line-height: 1.5;
}

.direct-email-label {
  font-style: italic;
  color: #aaa;
  margin-bottom: 10px;
}

.direct-email {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  color: #ccc;
  font-weight: 600;
  background-color: rgba(255, 153, 0, 0.1);
  padding: 10px 18px;
  border-radius: 8px;
  transition: background-color 0.2s, transform 0.2s;
}

.direct-email:hover {
  background-color: #be5e0f;
  color: #f0f0f0;
  transform: translateY(-2px);
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.25);
}

.direct-email a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s;
}

/* Responsive Styles */
@media (max-width: 768px) {
  .contact-section {
    padding: 40px 20px;
  }

  .contact-container {
    max-width: 100%;
    margin: 0;
  }

  .contact-form {
    padding: 20px;
  }

  .form-group {
    margin-bottom: 15px;
  }

  .submit-btn {
    padding: 10px 20px;
  }

  .contact-info {
    margin-top: 20px;
  }
}

@media (max-width: 480px) {
  .contact-section {
    padding: 30px 15px;
  }

  .contact-form {
    padding: 15px;
  }

  .submit-btn {
    padding: 8px 18px;
  }

  .direct-email {
    font-size: 14px;
    padding: 8px 16px;
  }
}

/* Footer */
.footer {
  background-color: rgba(10, 10, 10, 0.4);
  color: #f5f5f5;
  padding: 2.5rem 0 1rem;
  position: relative;
  margin-top: 5rem;
}

.footer::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(251, 146, 60, 0.3) 15%,
    rgba(251, 146, 60, 0.8) 50%,
    rgba(251, 146, 60, 0.3) 85%,
    transparent 100%
  );
}

.footer-container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.footer-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
}

.footer-logo h3 {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  background: linear-gradient(90deg, #ffffff, #fb923c);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.footer-logo p {
  font-size: 0.875rem;
  color: #94a3b8;
}

.footer-nav {
  display: flex;
  gap: 1.5rem;
}

.footer-nav a {
  text-decoration: none;
  color: white;
  font-weight: 400;
  transition: color 0.2s linear;
  position: relative;
  /* use will-change pour meilleures perfs */
  will-change: color;
}

.footer-nav a::after {
  content: "";
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background-color: #fb923c;
  transition: width 0.18s cubic-bezier(0.4, 0, 0.2, 1);
  will-change: width;
}

.footer-nav a:hover {
  color: #fb923c;
}

.footer-nav a:hover::after {
  width: 100%;
}

.footer-social {
  display: flex;
  gap: 1rem;
}

.footer-social a {
  color: #d1d5db;
  font-size: 1.1rem;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.05);
  text-decoration: none;
}

.footer-social a:hover {
  transform: translateY(-3px);
}

.footer-social a:nth-child(1):hover {
  color: #fff;
  background-color: #333;
}

.footer-social a:nth-child(2):hover {
  color: #fff;
  background-color: #0077b5;
}

.footer-social a:nth-child(3):hover {
  color: #fff;
  background-color: #7a4a28;
}

.footer-social a:nth-child(4):hover {
  color: #fff;
  background-color: #d14836;
}

.footer-bottom {
  text-align: center;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.footer-bottom p {
  font-size: 0.8rem;
  color: #64748b;
}

@media (max-width: 768px) {
  .footer-content {
    flex-direction: column;
    gap: 1.5rem;
    text-align: center;
    margin-bottom: 2rem;
  }

  .footer-nav {
    justify-content: center;
  }

  .footer-social {
    justify-content: center;
  }

  .footer-container {
    padding: 0;
  }
}

/* Pop-up voir projet */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(8px);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
  z-index: 1000;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.modal-overlay.active {
  display: flex;
  opacity: 1;
}

/* Container */
.modal-container {
  background: linear-gradient(135deg, #0c0e14 0%, #1a1f2e 100%);
  border: 1px solid rgba(251, 146, 60, 0.15);
  border-radius: 20px;
  box-shadow: 0 32px 64px rgba(0, 0, 0, 0.8),
    0 0 0 1px rgba(255, 255, 255, 0.05);
  color: #fff;
  width: min(80vw, 750px); /* moins large */
  max-height: 90vh;
  overflow: hidden;
  display: grid;
  grid-template-rows: auto auto auto auto;
  transform: scale(0.95) translateY(20px);
  animation: modalIn 0.25s ease-out forwards;
}

@keyframes modalIn {
  to {
    transform: scale(1) translateY(0);
  }
}

/* Header */
.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 28px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background: linear-gradient(135deg, rgba(251, 146, 60, 0.05), transparent);
}

.modal-title {
  font-size: 1.4rem;
  font-style: italic;
  margin: 0;
}

.modal-close {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #94a3b8;
  font-size: 1.2rem;
  cursor: pointer;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  transition: all 0.25s ease;
}

.modal-close:hover {
  color: #fb923c;
  background: rgba(251, 146, 60, 0.1);
  border-color: rgba(251, 146, 60, 0.3);
  transform: scale(1.05);
}

/* Gallery */
.modal-gallery {
  position: relative;
  text-align: center;
}

.modal-gallery .gallery-image {
  cursor: zoom-in;
}

.gallery-main {
  position: relative;
  overflow: hidden;
}

.gallery-image {
  max-width: 100%;
  height: auto;
  object-fit: contain;
  display: inline-block;
  transition: transform 0.3s ease;
}

.gallery-image:hover {
  transform: scale(1.01);
}

.gallery-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(6px);
  border: 1px solid rgba(251, 146, 60, 0.2);
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: none;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: #fff;
  font-size: 1rem;
  transition: all 0.25s ease;
  z-index: 5;
}
.gallery-nav:hover {
  background: rgba(251, 146, 60, 0.25);
  border-color: rgba(251, 146, 60, 0.5);
  transform: translateY(-50%) scale(1.08);
}
.gallery-nav.prev {
  left: 12px;
}
.gallery-nav.next {
  right: 12px;
}

.gallery-indicators {
  position: absolute;
  bottom: 12px;
  left: 50%;
  transform: translateX(-50%);
  display: none;
  gap: 8px;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(6px);
  padding: 6px 12px;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.1);
}
.gallery-indicator {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.4);
  cursor: pointer;
  transition: all 0.25s ease;
}
.gallery-indicator.active {
  background: #fb923c;
  box-shadow: 0 0 8px rgba(251, 146, 60, 0.6);
  transform: scale(1.2);
}

/* Body */
.modal-body {
  padding: 20px 28px;
  overflow-y: visible; /* pas de scroll */
}

/* Tech */
.modal-tech-section {
  margin-bottom: 20px;
}
.tech-title {
  font-size: 0.9rem;
  color: #fb923c;
  font-weight: 700;
  margin: 0 0 10px 0;
  text-transform: uppercase;
  letter-spacing: 1px;
}
.modal-tech-section .tech-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.modal-tech-section .tech-stack span {
  background: rgba(230, 126, 34, 0.15);
  padding: 6px 12px;
  font-size: 0.85rem;
  border-radius: 20px;
  color: #fb923c;
  font-weight: 600;
  border: 1px solid rgba(230, 126, 34, 0.25);
}

/* Description + GitHub */
.modal-desc-actions {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
}

.modal-description {
  flex: 1;
}
.modal-description p {
  font-size: 1rem;
  line-height: 1.6;
  color: #e1e8f0;
  margin: 0;
}

.modal-actions {
  flex-shrink: 0;
}

.modal-actions .action-btn.github {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.15);
  padding: 10px 16px;
  border-radius: 10px;
  font-weight: 600;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.modal-actions .action-btn.github:hover {
  background: rgba(255, 255, 255, 0.15);
}

/* Responsive */
@media (max-width: 768px) {
  .modal-container {
    width: 95vw;
    max-height: 92vh;
  }
  .modal-header {
    padding: 16px 20px;
  }
  .modal-title {
    font-size: 1.3rem;
  }
  .modal-body {
    padding: 20px;
  }
  .modal-desc-actions {
    flex-direction: column;
  }
  .modal-actions {
    margin-top: 12px;
  }
}

/* Fullscreen Viewer */
.fullscreen-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.95);
  justify-content: center;
  align-items: center;
  z-index: 2000;
}

.fullscreen-overlay.active {
  display: flex;
}

.fullscreen-overlay img {
  max-width: 90%;
  max-height: 90%;
  border-radius: 8px;
  object-fit: contain;
}

.fullscreen-close {
  position: absolute;
  top: 20px;
  right: 30px;
  font-size: 2rem;
  color: white;
  background: none;
  border: none;
  cursor: pointer;
}

.fullscreen-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  font-size: 2.5rem;
  color: white;
  background: rgba(0, 0, 0, 0.5);
  border: none;
  cursor: pointer;
  padding: 10px;
  border-radius: 50%;
}

.fullscreen-nav.prev {
  left: 20px;
}
.fullscreen-nav.next {
  right: 20px;
}
