/* Base - Palette Sophistiquée et Minimaliste */
:root {
  --background: #f8f7f4; /* Fond ivoire clair */
  --foreground: #2c2c2c; /* Texte gris foncé presque noir */
  --card: #ffffff; /* Cartes blanches */
  --card-foreground: #2c2c2c; /* Texte des cartes */
  --popover: #ffffff;
  --popover-foreground: #2c2c2c;
  --primary: #b8a088; /* Beige doré */
  --primary-foreground: #ffffff;
  --secondary: #d4c8b8; /* Beige clair */
  --secondary-foreground: #2c2c2c;
  --muted: #f0ede8; /* Beige très clair */
  --muted-foreground: #6c6c6c; /* Gris moyen */
  --accent: #b8a088; /* Beige doré */
  --accent-foreground: #ffffff;
  --destructive: #d64545;
  --destructive-foreground: #ffffff;
  --border: #e6e1d9; /* Beige grisé clair */
  --input: #e6e1d9;
  --ring: #b8a088;
  --primary-dark: #9d8b7b;
  --primary-light: #d4c8b8;
  --radius: 0.5rem;
  --font-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-serif: "Playfair Display", Georgia, Cambria, "Times New Roman", Times, serif;
  --font-mono: "Fira Code", Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
}

html[data-theme="dark"] {
  --background: #1a1812;
  --foreground: #ece4cb;
  --card: #252218;
  --card-foreground: #ece4cb;
  --popover: #252218;
  --popover-foreground: #ece4cb;
  --primary: #626247;
  --primary-dark: #4a4a35;
  --primary-light: #7a7a5a;
  --primary-foreground: #ece4cb;
  --secondary: #300941;
  --secondary-foreground: #ece4cb;
  --muted: #2a2820;
  --muted-foreground: #9a9680;
  --accent: #626247;
  --accent-foreground: #ece4cb;
  --border: #3a372c;
  --input: #3a372c;
  --ring: #7a7a5a;
}

@import url("https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap");
@import url("https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,400;0,500;0,600;0,700;1,400&display=swap");
@import url("https://fonts.googleapis.com/css2?family=Fira+Code:wght@400;500;600&display=swap");

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-sans);
  background-color: var(--background);
  color: var(--foreground);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background-image: radial-gradient(circle at 20% 30%, rgba(184, 160, 136, 0.03) 0%, transparent 50%),
    radial-gradient(circle at 80% 70%, rgba(212, 200, 184, 0.03) 0%, transparent 50%);
  background-attachment: fixed;
}

img {
  max-width: 100%;
  height: auto;
}

a {
  color: var(--foreground);
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover {
  color: var(--primary);
}

ul {
  list-style: none;
}

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

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-serif);
  font-weight: 500;
  line-height: 1.2;
  margin-bottom: 1rem;
  color: var(--foreground);
  letter-spacing: -0.01em;
}

.page-title {
  font-size: 3rem;
  margin-bottom: 1.5rem;
  position: relative;
  display: inline-block;
  font-weight: 500;
}

.page-title::after {
  content: "";
  position: absolute;
  bottom: -0.5rem;
  left: 0;
  width: 40%;
  height: 2px;
  background: var(--primary);
  border-radius: 2px;
}

.section-title {
  font-size: 2.5rem;
  margin-bottom: 1.5rem;
  text-align: center;
  position: relative;
  display: inline-block;
  padding-bottom: 0.5rem;
  font-weight: 500;
}

.section-title::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 2px;
  background: var(--primary);
  border-radius: 2px;
}

.section-description {
  font-size: 1.125rem;
  color: var(--muted-foreground);
  max-width: 42rem;
  margin: 0 auto 2rem;
  text-align: center;
  font-weight: 300;
}

/* Badge */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.375rem 1rem;
  border-radius: 9999px;
  background-color: var(--muted);
  border: 1px solid var(--border);
  font-size: 0.875rem;
  font-weight: 500;
  margin-bottom: 1rem;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
}

.badge-dot {
  position: relative;
  display: inline-block;
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 50%;
  background-color: var(--primary);
}

.badge-dot::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background-color: var(--primary);
  animation: ping 1.5s cubic-bezier(0, 0, 0.2, 1) infinite;
}

@keyframes ping {
  75%,
  100% {
    transform: scale(2);
    opacity: 0;
  }
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.625rem 1.25rem;
  border-radius: var(--radius);
  font-weight: 500;
  font-size: 0.875rem;
  line-height: 1.5;
  cursor: pointer;
  transition: all 0.3s ease;
  border: none;
  position: relative;
  overflow: hidden;
  z-index: 1;
  letter-spacing: 0.02em;
}

.btn::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(255, 255, 255, 0.1);
  transform: translateX(-100%);
  transition: transform 0.6s ease;
  z-index: -1;
}

.btn:hover::before {
  transform: translateX(0);
}

.btn-primary {
  background-color: var(--primary);
  color: var(--primary-foreground);
  box-shadow: 0 2px 4px rgba(184, 160, 136, 0.2);
}

.btn-primary:hover {
  background-color: #9d8b7b;
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(184, 160, 136, 0.3);
}

.btn-outline {
  background-color: transparent;
  border: 1px solid var(--primary);
  color: var(--primary);
}

.btn-outline:hover {
  background-color: var(--primary);
  color: var(--primary-foreground);
  transform: translateY(-2px);
  box-shadow: 0 2px 4px rgba(184, 160, 136, 0.2);
}

.btn-block {
  width: 100%;
}

/* Header */
.header {
  position: sticky;
  top: 0;
  z-index: 50;
  width: 100%;
  border-bottom: 1px solid var(--border);
  background-color: rgba(248, 247, 244, 0.9);
  backdrop-filter: blur(8px);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03);
}

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

.logo {
  font-family: var(--font-serif);
  font-size: 1.25rem;
  font-weight: 500;
  display: flex;
  align-items: center;
  letter-spacing: 0.02em;
}

.logo-image {
  width: 40px;
  height: 40px;
  object-fit: contain;
  transition: transform 0.3s ease;
}

.logo:hover .logo-image {
  transform: scale(1.1);
}

.nav-desktop {
  display: none;
}

.nav-list {
  display: flex;
  gap: 2rem;
}

.nav-item {
  position: relative;
}

.nav-link {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--foreground);
  transition: all 0.3s ease;
  padding: 0.5rem 0;
  letter-spacing: 0.02em;
}

.nav-link:hover,
.nav-item.active .nav-link {
  color: var(--primary);
}

.nav-item.active::after {
  content: "";
  position: absolute;
  bottom: -1.3125rem;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--primary);
  border-radius: 2px 2px 0 0;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* Menu mobile */
.menu-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: var(--radius);
  background-color: var(--muted);
  border: 1px solid var(--border);
  color: var(--foreground);
  cursor: pointer;
  transition: all 0.3s ease;
  z-index: 60; /* Augmenter le z-index pour s'assurer qu'il est au-dessus du menu mobile */
}

.menu-toggle:hover {
  background-color: var(--primary);
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 2px 4px rgba(184, 160, 136, 0.2);
}

.menu-toggle:active {
  transform: translateY(0);
}

.menu-toggle svg {
  width: 20px;
  height: 20px;
  display: block;
}

.theme-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: var(--radius);
  background-color: var(--muted);
  border: 1px solid var(--border);
  color: var(--foreground);
  cursor: pointer;
  transition: all 0.3s ease;
}

.theme-toggle:hover {
  background-color: var(--primary);
  color: var(--primary-foreground);
  transform: translateY(-2px);
  box-shadow: 0 2px 4px rgba(184, 160, 136, 0.2);
}

.theme-toggle:active {
  transform: translateY(0);
}

.theme-toggle-icon {
  font-size: 1rem;
  line-height: 1;
}

.mobile-menu {
  display: none;
  position: absolute;
  left: 0;
  right: 0;
  top: 4rem;
  z-index: 55;
  border-bottom: 1px solid var(--border);
  background-color: rgba(248, 247, 244, 0.95);
  padding: 1rem;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
  backdrop-filter: blur(8px);
}

html[data-theme="dark"] .header {
  background-color: rgba(26, 24, 18, 0.92);
}

html[data-theme="dark"] .mobile-menu {
  background-color: rgba(26, 24, 18, 0.95);
}

html[data-theme="dark"] .terminal-body {
  background-color: #17150f;
}

.mobile-menu.active {
  display: block;
}

.mobile-nav-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.mobile-nav-link {
  display: block;
  padding: 0.75rem 1rem;
  border-radius: var(--radius);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--foreground);
  transition: all 0.3s ease;
  border-left: 2px solid transparent;
  letter-spacing: 0.02em;
}

.mobile-nav-link:hover,
.mobile-nav-item.active .mobile-nav-link {
  background-color: var(--muted);
  color: var(--primary);
  border-left: 2px solid var(--primary);
}

/* Section Header */
.section-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  margin-bottom: 4rem;
  position: relative;
}

/* Hero Section */
.hero {
  padding: 6rem 0 8rem;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  top: -50px;
  right: -50px;
  width: 300px;
  height: 300px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(184, 160, 136, 0.05) 0%, transparent 70%);
  z-index: -1;
}

.hero::after {
  content: "";
  position: absolute;
  bottom: -100px;
  left: -100px;
  width: 400px;
  height: 400px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(212, 200, 184, 0.05) 0%, transparent 70%);
  z-index: -1;
}

.hero-grid {
  display: grid;
  gap: 3rem;
  grid-template-columns: 1fr;
  position: relative;
  align-items: center; /* Assurer l'alignement vertical */
}

.hero-content {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  position: relative;
  z-index: 1;
  max-width: 100%; /* Assurer que le contenu ne déborde pas */
}

.hero-title {
  font-size: 4.5rem;
  line-height: 1.2;
  color: var(--foreground);
  font-weight: 500;
  margin-bottom: 0.5rem; /* Ajuster l'espacement */
}

.hero-description {
  font-size: 1.25rem;
  color: var(--muted-foreground);
  max-width: 32rem;
  font-weight: 300;
  line-height: 1.7;
  margin-bottom: 0.5rem; /* Ajuster l'espacement */
}

.hero-actions {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-top: 1rem;
  align-items: flex-start; /* Aligner les boutons à gauche */
}

.hero-terminal {
  position: relative;
  height: 400px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background-color: var(--card);
  overflow: hidden;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.05);
  transform: perspective(1000px) rotateY(-5deg);
  transition: transform 0.3s ease;
}

.hero-terminal:hover {
  transform: perspective(1000px) rotateY(0);
}

.terminal-header {
  display: flex;
  align-items: center;
  padding: 0 1rem;
  height: 2.5rem;
  background-color: var(--muted);
  border-bottom: 1px solid var(--border);
}

.terminal-dots {
  display: flex;
  gap: 0.5rem;
}

.terminal-dot {
  width: 0.75rem;
  height: 0.75rem;
  border-radius: 50%;
}

.terminal-dot.red {
  background-color: #ff5f56;
}

.terminal-dot.yellow {
  background-color: #ffbd2e;
}

.terminal-dot.green {
  background-color: #27c93f;
}

.terminal-title {
  margin-left: 1rem;
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--muted-foreground);
  font-family: var(--font-mono);
}

.terminal-body {
  padding: 1rem;
  height: calc(100% - 2.5rem);
  overflow: auto;
  background-color: #2c2c2c;
  color: #f0f0f0;
}

.terminal-code {
  font-family: var(--font-mono);
  font-size: 0.875rem;
  white-space: pre-wrap;
  color: #f0f0f0;
}

/* Technologies Section */
.technologies {
  padding: 5rem 0;
  position: relative;
  overflow: hidden;
}

.technologies::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 200px;
  background: linear-gradient(180deg, var(--background), transparent);
  z-index: 1;
}

.tech-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
  position: relative;
  z-index: 2;
  justify-content: center; /* Centrer la grille */
}

.tech-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center; /* Centrer le contenu verticalement */
  gap: 1rem;
  padding: 2rem;
  background-color: var(--card);
  border-radius: var(--radius);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.03);
  transition: all 0.3s ease;
  border: 1px solid var(--border);
  height: 100%; /* Assurer une hauteur uniforme */
}

.tech-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 4rem;
  height: 4rem;
  border-radius: 9999px;
  background-color: var(--muted);
  padding: 1rem;
  transition: all 0.3s ease;
}

.tech-icon img {
  width: 100%;
  height: 100%;
  object-fit: contain; /* Assurer que l'image s'adapte correctement */
}

.tech-name {
  font-weight: 500;
  font-size: 1rem;
  color: var(--foreground);
}

/* About Section */
.about {
  padding: 5rem 0;
  position: relative;
}

.about-grid {
  display: grid;
  gap: 4rem;
  grid-template-columns: 1fr;
  margin-bottom: 5rem;
}

.about-image {
  position: relative;
  aspect-ratio: 1;
  overflow: hidden;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.05);
}

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

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

.about-content {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.about-title {
  font-size: 2.5rem;
  position: relative;
  display: inline-block;
  padding-bottom: 0.5rem;
  font-weight: 500;
}

.about-title::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 60px;
  height: 2px;
  background: var(--primary);
  border-radius: 2px;
}

.about-content p {
  font-weight: 300;
  line-height: 1.8;
  color: var(--muted-foreground);
}

.about-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 1rem;
}

.domains-grid {
  display: grid;
  grid-template-columns: repeat(1, 1fr);
  gap: 2rem;
}

.domain-card {
  padding: 2rem;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background-color: var(--card);
  height: 100%;
  transition: all 0.3s ease;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.03);
  position: relative;
  overflow: hidden;
}

.domain-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 3px;
  height: 100%;
  background: var(--primary);
  border-radius: 3px 0 0 3px;
}

.domain-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.05);
  border-color: var(--primary);
}

.domain-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  margin-bottom: 1rem;
  color: var(--primary);
}

.domain-title {
  font-size: 1.25rem;
  margin-bottom: 0.75rem;
  color: var(--foreground);
  font-family: var(--font-serif);
  font-weight: 500;
}

.domain-description {
  color: var(--muted-foreground);
  font-weight: 300;
  line-height: 1.7;
}

/* Skills Section */
.skills {
  padding: 5rem 0;
  position: relative;
}

.skills-tabs {
  margin-bottom: 5rem;
}

.tabs-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
  margin-bottom: 2rem;
}

.tab-button {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 1rem;
  border-radius: var(--radius);
  background-color: var(--card);
  border: 1px solid var(--border);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--foreground);
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.03);
}

.tab-button::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, rgba(184, 160, 136, 0.05), rgba(212, 200, 184, 0.05));
  transform: translateX(-100%);
  transition: transform 0.6s ease;
  z-index: 0;
}

.tab-button:hover::before,
.tab-button.active::before {
  transform: translateX(0);
}

.tab-button:hover,
.tab-button.active {
  border-color: var(--primary);
  color: var(--foreground);
  font-weight: 600;
}

.tab-button.active {
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
}

.tab-button i {
  z-index: 1;
}

.tab-button span {
  z-index: 1;
}

.tab-pane {
  display: none;
}

.tab-pane.active {
  display: block;
}

.card {
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background-color: var(--card);
  overflow: hidden;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.05);
}

.card-header {
  padding: 2rem 2rem 0;
}

.card-title {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 1.5rem;
  margin-bottom: 0.75rem;
  color: var(--foreground);
  font-family: var(--font-serif);
  font-weight: 500;
}

.card-description {
  color: var(--muted-foreground);
  font-size: 0.95rem;
  font-weight: 300;
}

.card-content {
  padding: 2rem;
}

/* Skills Timeline - Horizontal Layout */
.skills-timeline {
  position: relative;
  padding: 3rem 0;
}

.timeline-track {
  position: absolute;
  top: 2rem;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--border) 0%, var(--primary) 50%, var(--border) 100%);
  z-index: 0;
}

.skills-container {
  display: flex;
  justify-content: space-between;
  gap: 1.5rem;
  position: relative;
  z-index: 1;
  overflow-x: auto;
  padding: 0 1rem;
}

.timeline-skill {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.25rem;
  flex: 1;
  min-width: 120px;
}

.skill-point {
  width: 1rem;
  height: 1rem;
  border-radius: 50%;
  background-color: var(--card);
  border: 3px solid var(--primary);
  box-shadow: 0 0 0 4px var(--background);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  cursor: pointer;
}

.timeline-skill:hover .skill-point {
  transform: scale(1.3);
  box-shadow: 0 0 20px rgba(157, 139, 120, 0.6), 0 0 0 4px var(--background);
}

.skill-label {
  font-size: 0.9rem;
  font-weight: 500;
  text-align: center;
  color: var(--foreground);
  line-height: 1.3;
  opacity: 0;
  transform: translateY(10px);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  max-width: 100%;
}

.timeline-skill:hover .skill-label {
  opacity: 1;
  transform: translateY(0);
}

.skill-expanded {
  display: flex;
  gap: 0.5rem;
  justify-content: center;
  opacity: 0;
  transform: translateY(15px);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.timeline-skill:hover .skill-expanded {
  opacity: 1;
  transform: translateY(0);
}

/* Ancien design - gardé pour compatibilité */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.5rem;
}

.skill-card {
  display: flex;
  align-items: center;
  padding: 1.75rem 1.5rem;
  background-color: var(--card);
  border-radius: 1rem;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  min-height: 120px;
}

.skill-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.08);
  border-color: var(--primary);
}

.skill-card-header {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 0.875rem;
}

.skill-dots {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.dot {
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 50%;
  background-color: var(--border);
  transition: all 0.3s ease;
}

.dot.filled {
  background-color: var(--primary);
  box-shadow: 0 0 8px rgba(157, 139, 120, 0.4);
}

.skill-name {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--foreground);
}

/* Legacy skills-list styles */
.skills-list {
  display: grid;
  gap: 1.5rem;
}

.skill-row {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding: 1rem;
  border-radius: var(--radius);
  background: rgba(184, 160, 136, 0.03);
  border: 1px solid var(--border);
  transition: all 0.3s ease;
}

.skill-row:hover {
  background: rgba(184, 160, 136, 0.08);
  border-color: var(--primary);
}

.skill-item {
  display: grid;
  gap: 0.5rem;
}

.skill-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
}

.skill-name {
  font-weight: 600;
  color: var(--foreground);
  font-size: 0.95rem;
}

.skill-percentage {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--primary);
  background: rgba(184, 160, 136, 0.1);
  padding: 0.25rem 0.75rem;
  border-radius: 999px;
}

.skill-bar {
  height: 8px;
  background-color: var(--muted);
  border-radius: 9999px;
  overflow: hidden;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1);
}

.skill-progress {
  height: 100%;
  background: linear-gradient(90deg, var(--primary), rgba(184, 160, 136, 0.8));
  border-radius: 9999px;
  position: relative;
  box-shadow: 0 0 10px rgba(184, 160, 136, 0.3);
  animation: skill-fill 1s ease-out forwards;
}

.skill-progress::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0), rgba(255, 255, 255, 0.3), rgba(255, 255, 255, 0));
  animation: shimmer 2s infinite;
}

@keyframes skill-fill {
  from {
    width: 0 !important;
  }
}

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

.certifications {
  margin-top: 5rem;
}

.certifications-grid {
  display: grid;
  grid-template-columns: repeat(1, 1fr);
  gap: 2rem;
}

.certification-card {
  transition: all 0.3s ease;
}

.certification-card:hover {
  transform: translateY(-5px);
}

.certification-period {
  font-size: 0.875rem;
  color: var(--muted-foreground);
  margin-bottom: 0.5rem;
  font-weight: 300;
}

/* Projects Section */
.projects {
  padding: 5rem 0;
  position: relative;
}

/* Projects Section - Category Tabs */
.category-tabs-container {
  margin-bottom: 3rem;
}

.category-tabs-container .tabs-list {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1rem;
  margin-bottom: 2rem;
}

.category-tab {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius);
  background-color: var(--card);
  border: 1px solid var(--border);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--foreground);
  cursor: pointer;
  transition: all 0.3s ease;
  overflow: hidden;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.03);
}

.category-tab::before {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--primary);
  transform: scaleX(0);
  transform-origin: center;
  transition: transform 0.3s ease;
}

.category-tab:hover {
  color: var(--foreground);
  border-color: var(--primary);
  background-color: var(--card);
}

.category-tab:hover::before {
  transform: scaleX(0.5);
}

.category-tab.active {
  color: var(--foreground);
  border-color: var(--primary);
  background-color: var(--card);
  font-weight: 600;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
}

.category-tab.active::before {
  transform: scaleX(1);
}

/* Media queries pour les onglets de catégorie */
@media (max-width: 640px) {
  .category-tabs-container .tabs-list {
    flex-direction: column;
    width: 100%;
    gap: 0.5rem;
  }

  .category-tab {
    width: 100%;
    padding: 0.875rem 1rem;
  }
}

@media (min-width: 641px) and (max-width: 768px) {
  .category-tabs-container .tabs-list {
    flex-wrap: wrap;
    justify-content: center;
  }

  .category-tab {
    flex: 1 0 calc(50% - 0.75rem);
    max-width: calc(50% - 0.75rem);
  }
}

.no-results {
  text-align: center;
  padding: 3rem;
  color: var(--muted-foreground);
  font-size: 1rem;
  font-weight: 300;
}

.search-container {
  margin-bottom: 3rem;
}

.search-input-wrapper {
  position: relative;
}

.search-icon {
  position: absolute;
  left: 1rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--muted-foreground);
}

.search-input {
  width: 100%;
  padding: 1rem 1rem 1rem 3rem;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background-color: var(--card);
  color: var(--foreground);
  font-size: 0.95rem;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.03);
  transition: all 0.3s ease;
}

.search-input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 2px rgba(184, 160, 136, 0.1);
}

.form-input,
.form-textarea {
  padding: 1rem;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background-color: var(--card);
  color: var(--foreground);
  font-size: 0.95rem;
  width: 100%;
  transition: all 0.3s ease;
}

.form-input:focus,
.form-textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 2px rgba(184, 160, 136, 0.1);
}

.form-textarea {
  resize: vertical;
  min-height: 120px;
}

/* Toast */
.toast {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  z-index: 100;
  width: 100%;
  max-width: 24rem;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background-color: var(--card);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
  transform: translateY(100%);
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
}

.toast.active {
  transform: translateY(0);
  opacity: 1;
  visibility: visible;
}

.toast-content {
  display: flex;
  align-items: flex-start;
  padding: 1.5rem;
}

.toast-icon {
  flex-shrink: 0;
  color: #4caf50;
  margin-right: 1rem;
  margin-top: 0.25rem;
}

.toast-message {
  flex-grow: 1;
}

.toast-title {
  font-size: 1rem;
  font-weight: 500;
  margin-bottom: 0.25rem;
  color: var(--foreground);
}

.toast-description {
  font-size: 0.875rem;
  color: var(--muted-foreground);
  font-weight: 300;
}

/* Footer */
.footer {
  margin-top: auto;
  border-top: 1px solid var(--border);
  background-color: var(--muted);
  padding: 4rem 0 2rem;
  position: relative;
}

.footer::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--primary);
  opacity: 0.7;
}

.footer-grid {
  display: grid;
  gap: 3rem;
  grid-template-columns: 1fr;
}

.footer-title {
  font-family: var(--font-serif);
  font-size: 1.25rem;
  margin-bottom: 1.5rem;
  color: var(--foreground);
  position: relative;
  display: inline-block;
  padding-bottom: 0.5rem;
  font-weight: 500;
}

.footer-title::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 40px;
  height: 2px;
  background: var(--primary);
  border-radius: 2px;
}

.footer-description {
  color: var(--muted-foreground);
  font-weight: 300;
  line-height: 1.7;
}

.footer-nav {
  display: grid;
  gap: 0.75rem;
}

.footer-nav a {
  color: var(--muted-foreground);
  transition: all 0.3s ease;
  padding: 0.25rem 0;
  font-weight: 300;
}

.footer-nav a:hover {
  color: var(--primary);
  transform: translateX(5px);
}

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

.social-icons a {
  color: var(--muted-foreground);
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  background-color: var(--card);
  border: 1px solid var(--border);
}

.social-icons a:hover {
  color: var(--primary);
  transform: translateY(-3px);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
  border-color: var(--primary);
}

.footer-bottom {
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border);
  text-align: center;
  font-size: 0.875rem;
  color: var(--muted-foreground);
  font-weight: 300;
}

/* Loading Screen */
.loading-screen {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--background);
}

.loading-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3rem;
}

/* Media Queries */
@media (min-width: 640px) {
  .hero-actions {
    flex-direction: row;
  }

  .tech-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .domains-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .certifications-grid {
    grid-template-columns: repeat(2, 1fr);
  }

@media (max-width: 640px) {
  .projects-grid {
    grid-template-columns: 1fr;
  }
}
  .category-tabs-container .tabs-list {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 641px) {
  .category-tabs-container .tabs-list {
    justify-content: center;
  }
}

@media (min-width: 768px) {
  .nav-desktop {
    display: block;
  }

  .menu-toggle {
    display: none;
  }

  .hero-grid {
    grid-template-columns: 1fr 1fr;
    align-items: center;
  }

  .about-grid {
    grid-template-columns: 1fr 1fr;
    align-items: center;
  }

  .tabs-list {
    grid-template-columns: repeat(4, 1fr);
  }

  .domains-grid {
    grid-template-columns: repeat(4, 1fr);
  }

  .certifications-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .contact-grid {
    grid-template-columns: 1fr 1fr;
  }

  .footer-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (min-width: 1024px) {
  .hero-title {
    font-size: 4rem;
  }
}

/* Modification de l'image principale du modal pour supporter les formats portrait */
.modal-image {
  position: relative;
  aspect-ratio: 16 / 9; /* Ratio d'aspect standard pour le modal */
  max-height: 60vh; /* Hauteur maximale relative à la hauteur de la fenêtre */
  overflow: hidden;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  margin-bottom: 2rem;
  display: flex;
  justify-content: center;
  align-items: center;
  background-color: var(--card);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.05);
}

.modal-image img {
  width: 100%;
  height: 100%;
  object-fit: contain; /* Contient l'image entière tout en préservant les proportions */
  transition: transform 0.3s ease;
}

/* Modification de l'image des cartes de projet pour supporter les formats portrait */
.project-image {
  position: relative;
  aspect-ratio: 16 / 10; /* Ratio d'aspect plus flexible */
  overflow: hidden;
  background-color: var(--card);
  display: flex;
  justify-content: center;
  align-items: center;
  border-radius: var(--radius) var(--radius) 0 0;
}

.project-image img {
  width: 100%;
  height: 100%;
  object-fit: cover; /* Couvre tout l'espace disponible */
  transition: transform 0.5s ease;
}

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

/* Ajout des styles pour les vidéos dans les projets */
.project-video-container,
.modal-video-container,
.gallery-video-container {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  display: flex;
  justify-content: center;
  align-items: center;
}

.project-video,
.modal-video,
.gallery-video {
  width: 100%;
  height: 100%;
  object-fit: cover; /* Couvre tout l'espace disponible */
  background-color: var(--card);
}

.project-image.video-container {
  background-color: var(--card);
}

.video-controls {
  position: absolute;
  bottom: 1rem;
  right: 1rem;
  display: flex;
  gap: 0.75rem;
  z-index: 5;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.project-video-container:hover .video-controls,
.modal-video-container:hover .video-controls,
.gallery-video-container:hover .video-controls {
  opacity: 1;
}

.video-control-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  background-color: rgba(0, 0, 0, 0.5);
  color: white;
  border: none;
  cursor: pointer;
  transition: all 0.3s ease;
  z-index: 10;
}

.video-control-btn:hover {
  background-color: var(--primary);
  transform: scale(1.1);
}

/* Améliorer la visibilité du bouton de lecture */
.video-play-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 4rem;
  height: 4rem;
  border-radius: 50%;
  background-color: rgba(184, 160, 136, 0.8);
  color: white;
  border: none;
  cursor: pointer;
  transition: all 0.3s ease;
  z-index: 10;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.video-play-btn:hover {
  transform: scale(1.1);
  background-color: var(--primary);
}

/* Nouvel overlay pour le bouton de lecture */
.video-play-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 3; /* Entre les contrôles vidéo et l'overlay du projet */
  pointer-events: none; /* Permet de cliquer à travers */
  background: rgba(0, 0, 0, 0.1);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.project-video-container:hover .video-play-overlay,
.modal-video-container:hover .video-play-overlay,
.gallery-video-container:hover .video-play-overlay {
  opacity: 1;
}

.video-play-overlay .video-play-btn {
  pointer-events: auto; /* Rétablit les événements de clic sur le bouton */
}

/* Ajuster l'overlay du projet pour qu'il soit au-dessus des contrôles vidéo */
.project-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.7), transparent);
  opacity: 0;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 1.5rem;
  transition: opacity 0.3s ease;
  z-index: 4; /* Au-dessus des contrôles vidéo et du bouton de lecture */
}

/* Ajouter cette règle pour afficher l'overlay au survol */
.project-image:hover .project-overlay {
  opacity: 1;
}

/* Styles pour le mode plein écran */
.fullscreen-video-container {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background-color: rgba(0, 0, 0, 0.95);
  display: none;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(10px);
  transition: all 0.3s ease;
}

.fullscreen-video-container.active {
  display: flex;
}

.fullscreen-video-wrapper {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.video-fullscreen {
  max-width: 95vw;
  max-height: 95vh;
  width: auto;
  height: auto;
  object-fit: contain;
  background: transparent;
  transition: all 0.3s ease;
  box-shadow: 0 0 30px rgba(0, 0, 0, 0.3);
}

.fullscreen-close {
  position: absolute;
  top: 1.5rem;
  right: 1.5rem;
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
  background-color: rgba(0, 0, 0, 0.5);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  border: none;
  z-index: 1001;
}

.fullscreen-close:hover {
  background-color: var(--primary);
  transform: scale(1.1);
}

/* Ajouter un style pour le fond de la vidéo en plein écran */
.fullscreen-video-container::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, rgba(184, 160, 136, 0.05), transparent 70%);
  opacity: 0.5;
  z-index: -1;
}

/* Styles pour les vidéos dans le lightbox */
.lightbox-video-container {
  position: relative;
  width: 100%;
  max-width: 90vw;
  max-height: 80vh;
}

.lightbox-video {
  max-width: 100%;
  max-height: 80vh;
  width: auto;
  height: auto;
}

/* Ajustements pour la galerie */
.modal-gallery {
  margin-top: 3rem;
  display: block;
  width: 100%;
}

.project-gallery-section {
  width: 100%;
}

.gallery-item {
  position: relative;
  aspect-ratio: 1 / 1; /* Format carré pour les miniatures */
  overflow: hidden;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.03);
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover; /* Couvre tout l'espace disponible */
  background-color: var(--card);
  transition: transform 0.3s ease;
}

.gallery-item:hover img {
  transform: scale(1.05);
}

/* Améliorer le style des éléments de la galerie pour indiquer qu'ils sont cliquables */
.gallery-item {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  cursor: pointer;
  transition: all 0.3s ease;
}

.gallery-item:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.05);
  border-color: var(--primary);
}

.gallery-item::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0);
  width: 40px;
  height: 40px;
  background-color: var(--primary);
  border-radius: 50%;
  opacity: 0;
  transition: all 0.3s ease;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='15 3 21 3 21 9'%3E%3C/polyline%3E%3Cpolyline points='9 21 3 21 3 15'%3E%3C/polyline%3E%3Cline x1='21' y1='3' x2='14' y2='10'%3E%3C/line%3E%3Cline x1='3' y1='21' x2='10' y2='14'%3E%3C/line%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
  background-size: 20px;
  z-index: 5;
}

.gallery-item:hover::after {
  transform: translate(-50%, -50%) scale(1);
  opacity: 1;
}

/* Ajouter des styles pour rendre les vidéos plus visibles et interactives */
.gallery-video-container {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  display: flex;
  justify-content: center;
  align-items: center;
  background-color: var(--card);
}

.gallery-video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background-color: var(--card);
}

/* Améliorer la visibilité des contrôles vidéo */
.gallery-item .video-controls {
  opacity: 0;
  transition: opacity 0.3s ease;
}

.gallery-item:hover .video-controls {
  opacity: 1;
}

/* Rendre le bouton de lecture plus visible */
.gallery-item .video-play-overlay {
  opacity: 0;
  transition: opacity 0.3s ease;
}

.gallery-item:hover .video-play-overlay {
  opacity: 1;
}

/* Ajouter un indicateur visuel pour les vidéos */
.gallery-item:has(.gallery-video-container)::before {
  content: "";
  position: absolute;
  top: 10px;
  right: 10px;
  width: 24px;
  height: 24px;
  background-color: var(--primary);
  border-radius: 50%;
  z-index: 5;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolygon points='5 3 19 12 5 21 5 3'%3E%3C/polygon%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
  background-size: 16px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* Désactiver l'effet de zoom sur les vidéos */
.gallery-item:has(.gallery-video-container)::after {
  display: none;
}

/* Améliorer le style des contrôles vidéo */
.video-control-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  background-color: rgba(0, 0, 0, 0.5);
  color: white;
  border: none;
  cursor: pointer;
  transition: all 0.3s ease;
  z-index: 10;
}

.video-control-btn:hover {
  background-color: var(--primary);
  transform: scale(1.1);
}

/* Améliorer l'affichage des projets en grille */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
}

/* Assurer que les cartes de projet ont une hauteur cohérente */
.project-card {
  display: flex;
  flex-direction: column;
  height: 100%;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background-color: var(--card);
  overflow: hidden;
  transition: all 0.3s ease;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.03);
  position: relative;
}

.project-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.08);
  border-color: var(--primary);
}

/* Assurer que le contenu prend l'espace disponible */
.project-content {
  flex: 1;
  padding: 2rem;
  display: flex;
  flex-direction: column;
  position: relative;
}

.project-content::before {
  content: "";
  position: absolute;
  top: 0;
  left: 2rem;
  right: 2rem;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--primary), transparent);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.project-card:hover .project-content::before {
  opacity: 1;
}

.project-title {
  font-family: var(--font-serif);
  font-size: 1.25rem;
  margin-bottom: 0.75rem;
  color: var(--foreground);
  transition: color 0.3s ease;
  font-weight: 500;
}

.project-card:hover .project-title {
  color: var(--primary);
}

.project-description {
  flex-grow: 1;
  color: var(--muted-foreground);
  font-size: 0.95rem;
  line-height: 1.7;
  font-weight: 300;
}

.project-tags {
  margin-top: auto;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1.5rem;
}

.tag {
  display: inline-flex;
  align-items: center;
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  background-color: var(--muted);
  color: var(--foreground);
  font-size: 0.75rem;
  font-weight: 500;
  transition: all 0.3s ease;
}

.tag:hover {
  background-color: var(--primary);
  color: white;
  transform: translateY(-2px);
}

.project-footer {
  padding: 1.5rem 2rem;
  border-top: 1px solid var(--border);
  display: flex;
  gap: 1rem;
  background-color: var(--muted);
  transition: background-color 0.3s ease;
}

.project-card:hover .project-footer {
  background-color: var(--card);
}

.project-technologies {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
}

.tech-item {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 6px;
  background-color: var(--muted);
  overflow: hidden;
  transition: all 0.3s ease;
  cursor: pointer;
  border: 1px solid var(--border);
}

.tech-item:hover {
  background-color: rgba(184, 160, 136, 0.15);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  border-color: var(--primary);
}

.tech-logo {
  width: 32px;
  height: 32px;
  object-fit: contain;
}

/* Section des technologies dans les détails du projet */
.project-technologies-section {
  margin-top: 5rem;
  padding-top: 3rem;
  border-top: 1px solid var(--border);
}

.project-technologies-container {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 1rem;
}

.tech-badge {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem;
  border-radius: var(--radius);
  background-color: var(--muted);
  border: 1px solid var(--border);
  transition: all 0.3s ease;
  cursor: pointer;
  min-width: 80px;
  text-align: center;
}

.tech-badge:hover {
  background-color: rgba(184, 160, 136, 0.15);
  border-color: var(--primary);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.tech-badge-logo {
  width: 32px;
  height: 32px;
  object-fit: contain;
}

.tech-badge-name {
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--foreground);
  line-height: 1.2;
}

/* Lightbox */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: none;
  align-items: center;
  justify-content: center;
  background-color: rgba(0, 0, 0, 0.9);
}

.lightbox.active {
  display: flex;
}

.lightbox-content {
  position: relative;
  max-width: 90%;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.lightbox-image {
  max-width: 90vw;
  max-height: 85vh;
  object-fit: contain;
  border: 2px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 0 30px rgba(0, 0, 0, 0.5);
  transition: transform 0.3s ease;
}

.lightbox-caption {
  color: white;
  text-align: center;
  margin-top: 1.5rem;
  font-size: 1rem;
  background-color: rgba(0, 0, 0, 0.5);
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius);
  font-weight: 300;
}

.lightbox-close {
  position: absolute;
  top: 1.5rem;
  right: 1.5rem;
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
  background-color: rgba(0, 0, 0, 0.5);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  z-index: 10;
  border: none;
}

.lightbox-close:hover {
  background-color: var(--primary);
  transform: scale(1.1);
}

.lightbox-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
  background-color: rgba(0, 0, 0, 0.5);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  z-index: 10;
  border: none;
}

.lightbox-nav:hover {
  background-color: var(--primary);
  transform: translateY(-50%) scale(1.1);
}

.lightbox-prev {
  left: 1.5rem;
}

.lightbox-next {
  right: 1.5rem;
}

/* Project Modal */
.project-modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
}

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

.modal-overlay {
  position: fixed;
  inset: 0;
  background-color: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(4px);
}

.modal-container {
  position: relative;
  width: 100%;
  max-width: 48rem;
  max-height: 90vh;
  overflow: auto;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background-color: var(--card);
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

.modal-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.5rem;
  border-bottom: 1px solid var(--border);
  background-color: var(--card);
}

.modal-title {
  font-family: var(--font-serif);
  font-size: 1.5rem;
  margin-bottom: 0;
  color: var(--foreground);
  font-weight: 500;
}

.modal-close {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: var(--radius);
  background-color: transparent;
  border: none;
  color: var(--foreground);
  cursor: pointer;
  transition: all 0.3s ease;
}

.modal-close:hover {
  background-color: var(--muted);
  color: var(--primary);
}

.modal-content {
  padding: 2rem;
}

/* Modifier les styles pour les tags dans le modal */
.modal-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 2rem;
}

.modal-tags .tag {
  display: inline-flex;
  align-items: center;
  padding: 0.375rem 0.875rem;
  border-radius: 9999px;
  background-color: var(--muted);
  color: var(--foreground);
  font-size: 0.75rem;
  font-weight: 500;
  transition: all 0.3s ease;
}

.modal-tags .tag:hover {
  background-color: var(--primary);
  color: white;
  transform: translateY(-2px);
}

/* Ajouter un style pour les tags de compétence MMI */
.modal-tags .tag[data-type="competence"] {
  background-color: rgba(184, 160, 136, 0.1);
  color: var(--primary);
  border: 1px solid var(--primary);
}

.modal-tags .tag[data-type="competence"]:hover {
  background-color: var(--primary);
  color: white;
}

/* Styles pour les images en portrait */
.modal-image {
  max-height: 70vh;
  width: auto;
}

.modal-image img {
  max-height: 100%;
  width: auto;
  margin: 0 auto;
  object-fit: contain;
}

.project-image.portrait {
  aspect-ratio: 3 / 4; /* Ratio portrait */
}

.project-image.landscape {
  aspect-ratio: 16 / 9; /* Ratio paysage */
}

/* Assurer que les images en portrait s'affichent correctement dans un conteneur paysage */
.gallery-item.portrait img {
  object-position: center; /* Centrer l'image */
}

/* Amélioration de l'alignement du footer */
.footer-grid {
  display: grid;
  gap: 3rem;
  grid-template-columns: 1fr;
  align-items: start; /* Aligner les éléments en haut */
}

.footer-info,
.footer-links,
.footer-social {
  display: flex;
  flex-direction: column;
  align-items: flex-start; /* Aligner le contenu à gauche */
}

/* Media Queries améliorées pour l'alignement responsive */
@media (min-width: 768px) {
  .hero-grid {
    grid-template-columns: 1fr 1fr;
    align-items: center;
    gap: 4rem; /* Augmenter l'espace entre les colonnes */
  }

  .hero-actions {
    flex-direction: row;
    align-items: center;
  }

  .tech-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 2.5rem; /* Augmenter l'espace entre les éléments */
  }

  .footer-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 4rem; /* Augmenter l'espace entre les colonnes */
  }
}

@media (min-width: 1024px) {
  .hero-title {
    font-size: 4rem;
  }

  .hero-description {
    font-size: 1.35rem;
  }

  .tech-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 3rem; /* Augmenter encore l'espace pour les grands écrans */
  }
}

.footer-logo {
  display: flex;
  align-items: center;
  margin-bottom: 1rem;
}

.footer-logo .logo-image {
  width: 40px;
  height: 40px;
  object-fit: contain;
}

/* Modifier les styles pour afficher le titre de l'image au survol dans la galerie */
.gallery-item-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.3), transparent);
  display: flex;
  align-items: flex-end;
  justify-content: flex-start;
  padding: 1rem;
  opacity: 0;
  transition: opacity 0.3s ease;
  z-index: 4;
}

.gallery-item:hover .gallery-item-overlay {
  opacity: 1;
}

.gallery-item-title {
  color: white;
  font-size: 0.875rem;
  font-weight: 500;
  background-color: rgba(0, 0, 0, 0.5);
  padding: 0.5rem 0.75rem;
  border-radius: var(--radius);
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  transform: translateY(10px);
  transition: transform 0.3s ease;
}

.gallery-item:hover .gallery-item-title {
  transform: translateY(0);
}

/* S'assurer que l'overlay n'interfère pas avec les contrôles vidéo */
.gallery-item:has(.gallery-video-container) .gallery-item-overlay {
  z-index: 2;
}

/* Ajouter un écart entre les actions et la description du projet dans le modal */
.modal-actions {
  display: flex;
  gap: 1rem;
  margin-bottom: 2rem; /* Ajouter une marge en bas pour créer l'écart */
  margin-top: 2rem; /* Marge en haut pour créer l'écart avec les détails */
}

/* Ajouter un écart entre les détails du projet et les boutons d'action dans le modal */
.modal-details-with-margin {
  margin-bottom: 3rem; /* Ajouter une marge en bas des détails du projet */
}

/* Espacement supplémentaire pour la section des actions du modal */
.project-actions-section {
  margin-top: 1.5rem;
}

/* Ajouter un écart entre la description courte et les détails du projet */
.project-short-description {
  margin-bottom: 1.5rem;
}

/* Ajouter ces styles pour améliorer la disposition des projets dans le modal */

/* Styles pour l'en-tête du projet */
.project-header {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  margin-bottom: 2.5rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--border);
}

.project-short-description {
  font-size: 1.125rem;
  color: var(--foreground);
  line-height: 1.7;
  font-weight: 400;
}

/* Header du projet avec description courte */
.project-header {
  margin-bottom: 1.5rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--border);
}

.project-short-description {
  color: var(--muted-foreground);
  font-size: 1rem;
  line-height: 1.7;
  font-style: italic;
  position: relative;
  padding-left: 1rem;
  border-left: 2px solid var(--primary);
}

/* Section des competences/tags du projet */
.project-tags-section {
  margin-bottom: 2rem;
  padding: 1.25rem;
  background-color: rgba(184, 160, 136, 0.05);
  border-radius: var(--radius);
  border: 1px solid var(--border);
}

.project-tags-section .section-subtitle {
  margin-bottom: 1rem;
}

.project-tags-container {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.project-tags-container .tag {
  display: inline-flex;
  align-items: center;
  padding: 0.5rem 1rem;
  border-radius: var(--radius);
  background-color: var(--background);
  color: var(--foreground);
  font-size: 0.75rem;
  font-weight: 500;
  transition: all 0.3s ease;
  border: 1px solid var(--border);
  cursor: default;
}

.project-tags-container .tag:hover {
  background-color: var(--primary);
  color: white;
  border-color: var(--primary);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(184, 160, 136, 0.25);
}

.project-tags-container .tag[data-type="competence"] {
  background-color: rgba(184, 160, 136, 0.08);
  color: var(--primary);
  border: 1px solid rgba(184, 160, 136, 0.3);
  font-size: 0.7rem;
  padding: 0.4rem 0.75rem;
}

.project-tags-container .tag[data-type="competence"]::before {
  content: "";
  width: 6px;
  height: 6px;
  background-color: var(--primary);
  border-radius: 50%;
  margin-right: 0.5rem;
  flex-shrink: 0;
}

.project-tags-container .tag[data-type="competence"]:hover {
  background-color: var(--primary);
  color: white;
}

.project-tags-container .tag[data-type="competence"]:hover::before {
  background-color: white;
}

/* Styles pour la section details */
.project-details-section {
  margin-bottom: 2rem;
  padding: 1.5rem;
  background: linear-gradient(135deg, rgba(184, 160, 136, 0.03) 0%, rgba(184, 160, 136, 0.08) 100%);
  border-radius: var(--radius);
  border-left: 3px solid var(--primary);
  position: relative;
}

.project-details-section::before {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: 100px;
  height: 100px;
  background: radial-gradient(circle, rgba(184, 160, 136, 0.1) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
}

.section-subtitle {
  font-size: 1.1rem;
  color: var(--primary);
  margin-bottom: 1rem;
  font-weight: 600;
  font-family: var(--font-serif);
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.section-subtitle::after {
  content: "";
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, var(--primary) 0%, transparent 100%);
  min-width: 50px;
}

.section-subtitle svg {
  width: 18px;
  height: 18px;
  stroke: var(--primary);
}

.project-details-content {
  color: var(--foreground);
  font-size: 0.95rem;
  line-height: 1.9;
  font-weight: 400;
  text-align: justify;
  hyphens: auto;
}

.project-details-content p {
  margin-bottom: 1.25rem;
  text-align: justify;
  line-height: 1.9;
}

.project-details-content p:last-child {
  margin-bottom: 0;
}

.project-details-content strong {
  color: var(--primary);
  font-weight: 600;
  position: relative;
  cursor: pointer;
  border-bottom: 1px dashed var(--primary);
  transition: all 0.3s ease;
}

.project-details-content strong[data-competence] {
  position: relative;
}

.project-details-content strong[data-competence]:hover {
  background-color: rgba(184, 160, 136, 0.1);
  border-radius: 3px;
  padding: 2px 4px;
  transform: translateY(-1px);
}

.project-details-content strong[data-competence]::after {
  content: attr(data-competence);
  position: absolute;
  bottom: calc(100% + 12px);
  left: 50%;
  transform: translateX(-50%) translateY(10px);
  background-color: var(--primary);
  color: var(--background);
  padding: 1.4rem 2rem;
  border-radius: var(--radius);
  font-size: 1rem;
  font-weight: 500;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
  z-index: 1000;
  pointer-events: none;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
  min-width: 320px;
  max-width: 900px;
  white-space: normal;
  text-align: center;
  line-height: 1.7;
  word-break: break-word;
}

.project-details-content strong[data-competence]::before {
  content: "";
  position: absolute;
  bottom: calc(100% + 5px);
  left: 50%;
  transform: translateX(-50%);
  border-width: 8px;
  border-style: solid;
  border-color: var(--primary) transparent transparent transparent;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
  z-index: 1000;
}

.project-details-content strong[data-competence]:hover::after,
.project-details-content strong[data-competence]:hover::before {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

/* Styles pour la section actions */
.project-actions-section {
  margin-bottom: 2rem;
  padding: 1.25rem 1.5rem;
  background-color: var(--muted);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}

.project-actions-section .section-subtitle {
  margin-bottom: 0;
  font-size: 0.9rem;
}

.project-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.project-buttons .btn {
  padding: 0.6rem 1.25rem;
  font-size: 0.85rem;
  border-radius: 50px;
  transition: all 0.3s ease;
}

.project-buttons .btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 15px rgba(184, 160, 136, 0.3);
}

/* Styles pour la section galerie */
.project-gallery-section {
  margin-bottom: 1rem;
}

.project-gallery-section .section-subtitle {
  margin-bottom: 1.25rem;
  width: 100%;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1rem;
  width: 100%;
  padding-bottom: 0.5rem;
}

.gallery-grid .gallery-item {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  aspect-ratio: 4/3;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.gallery-grid .gallery-item:hover {
  transform: scale(1.03);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.gallery-grid .gallery-item img,
.gallery-grid .gallery-item video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.gallery-video-badge {
  position: absolute;
  top: 0.5rem;
  right: 0.5rem;
  width: 1.75rem;
  height: 1.75rem;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.55);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 6;
}

.gallery-video-controls {
  position: absolute;
  right: 0.5rem;
  bottom: 0.5rem;
  display: flex;
  gap: 0.5rem;
  z-index: 6;
  opacity: 0;
  transition: opacity 0.25s ease;
}

.gallery-item:hover .gallery-video-controls {
  opacity: 1;
}

.gallery-video-btn {
  width: 2rem;
  height: 2rem;
  border: none;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.55);
  color: #fff;
  cursor: pointer;
  transition: all 0.25s ease;
}

.gallery-video-btn:hover {
  background-color: var(--primary);
  transform: scale(1.06);
}

.gallery-grid .gallery-item .gallery-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 0.75rem;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.8) 0%, transparent 100%);
  color: white;
  font-size: 0.8rem;
  font-weight: 500;
  opacity: 0;
  transform: translateY(10px);
  transition: all 0.3s ease;
}

.gallery-grid .gallery-item:hover .gallery-overlay {
  opacity: 1;
  transform: translateY(0);
}

/* Ameliorer l'apparence du modal */
.modal-container {
  background-color: var(--card);
  border-radius: var(--radius);
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  max-width: 900px;
  border: 1px solid var(--border);
}

.modal-header {
  background: linear-gradient(135deg, var(--card) 0%, rgba(184, 160, 136, 0.05) 100%);
  border-bottom: 1px solid var(--border);
  padding: 1.75rem 2rem;
  position: relative;
}

.modal-header::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 2rem;
  right: 2rem;
  height: 2px;
  background: linear-gradient(90deg, var(--primary), transparent);
}

.modal-content {
  padding: 2rem;
  max-height: 70vh;
  overflow-y: auto;
}

.modal-content::-webkit-scrollbar {
  width: 6px;
}

.modal-content::-webkit-scrollbar-track {
  background: var(--muted);
  border-radius: 3px;
}

.modal-content::-webkit-scrollbar-thumb {
  background: var(--primary);
  border-radius: 3px;
}

.modal-title {
  font-size: 1.75rem;
  color: var(--foreground);
  font-weight: 600;
  font-family: var(--font-serif);
  letter-spacing: -0.5px;
}

.modal-description {
  color: var(--muted-foreground);
  font-size: 0.95rem;
  margin-top: 0.5rem;
  line-height: 1.6;
}

/* Responsive design pour les details du projet */
@media (max-width: 640px) {
  /* Skills Timeline responsive */
  .skills-timeline {
    padding: 2rem 0;
  }

  .timeline-track {
    top: 1.25rem;
  }

  .skills-container {
    flex-wrap: wrap;
    justify-content: center;
  }

  .timeline-skill {
    min-width: 100px;
    gap: 1rem;
  }

  .skill-label {
    font-size: 0.8rem;
  }

  .skill-point {
    width: 0.875rem;
    height: 0.875rem;
    border-width: 2px;
  }

  .skills-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .skill-card {
    padding: 1.5rem 1.25rem;
    min-height: 100px;
  }

  .tab-button span {
    display: none;
  }

  .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
  }

  .project-header,
  .project-details-section,
  .project-tags-section,
  .project-actions-section {
    padding: 1rem;
    margin-bottom: 1.25rem;
  }

  .section-subtitle {
    font-size: 0.95rem;
  }

  .project-tags-container .tag {
    font-size: 0.65rem;
    padding: 0.35rem 0.6rem;
  }

  .modal-content {
    padding: 1.25rem;
  }

  .modal-header {
    padding: 1.25rem;
  }

  .modal-title {
    font-size: 1.35rem;
  }

  .project-actions-section {
    flex-direction: column;
    align-items: flex-start;
  }

  .project-buttons .btn {
    width: 100%;
    justify-content: center;
  }
}

@media (min-width: 768px) {
  .gallery-grid {
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  }

  .project-details-section {
    padding: 1.75rem;
  }
}

@media (min-width: 1024px) {
  .modal-container {
    max-width: 950px;
  }

  .gallery-grid {
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  }
}
