:root { 
  --bg: #0f172a; 
  --card: #111827; 
  --text: #e5e7eb; 
  --muted: #9ca3af; 
  --brand: #38bdf8; 
  --brand-2: #7c3aed; 
  --brand-3: #FFFF00; 
  --brand-4: #FF7F00; 
  --brand-5: #10b981;
  --success: #10b981;
  --warning: #f59e0b;
  --error: #ef4444;
  --info: #3b82f6;
  --shadow-sm: 0 2px 8px rgba(0,0,0,0.08);
  --shadow-md: 0 4px 16px rgba(0,0,0,0.12);
  --shadow-lg: 0 8px 32px rgba(0,0,0,0.16);
  --shadow-xl: 0 12px 48px rgba(0,0,0,0.24);
  --glow-brand: 0 0 24px color-mix(in srgb, var(--brand) 30%, transparent);
  --transition-fast: 0.15s ease;
  --transition-base: 0.25s ease;
  --transition-slow: 0.4s cubic-bezier(0.2, 0.9, 0.26, 1);
  /* RGB color values for transparency usage */
  --brand-rgb: 56, 189, 248;
  --brand-2-rgb: 124, 58, 237;
  --card-rgb: 17, 24, 39;
}

/* OVERRIDE: Boutons transparents avec contour */
.btn-primary, .btn.btn-primary {
  background: transparent !important;
  color: var(--brand) !important;
  border-color: var(--brand) !important;
  box-shadow: none !important;
}
.btn-primary:hover, .btn.btn-primary:hover {
  background: color-mix(in srgb, var(--brand) 10%, transparent) !important;
  color: var(--brand) !important;
  border-color: var(--brand) !important;
}
.btn-secondary, .btn.btn-secondary {
  background: transparent !important;
  border-color: color-mix(in srgb, var(--text) 30%, transparent) !important;
}
@media (prefers-color-scheme: light) { :root { --bg: #ffffff; --card: #f3f4f6; --text: #0f172a; --muted: #4b5563; --brand: #0284c7; --brand-2: #6d28d9; } }
/* Override when thème clair est forcé via classe */
:root.light { --bg: #ffffff; --card: #f3f4f6; --text: #0f172a; --muted: #4b5563; --brand: #0284c7; --brand-2: #6d28d9; }
* { box-sizing: border-box; }
html { 
  scroll-behavior: smooth; 
  scroll-padding-top: 100px;
}
body { 
  margin: 0; 
  font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, "Apple Color Emoji", "Segoe UI Emoji"; 
  background: var(--bg); 
  color: var(--text);
  line-height: 1.6;
  letter-spacing: 0.01em;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
a { color: inherit; text-decoration: none; }
.container { width: 100%; max-width: 1600px; margin: 0 auto; padding: 0 16px; }

/* Header/Nav */
header { position: sticky; top: 0; z-index: 10; backdrop-filter: blur(8px); background: color-mix(in srgb, var(--bg) 70%, transparent); border-bottom: 1px solid color-mix(in srgb, var(--text) 10%, transparent); }
.nav { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; letter-spacing: 0.4px; }
.logo { width: 28px; height: 28px; border-radius: 6px; background: linear-gradient(135deg, var(--brand), var(--brand-4)); display: inline-block; }
nav ul { list-style: none; display: flex; gap: 18px; margin: 0; padding: 0; }
nav a { padding: 8px 10px; border-radius: 8px; color: var(--muted); }
nav a:hover, nav a:focus { color: var(--text); background: color-mix(in srgb, var(--text) 10%, transparent); }

/* --- Sidebar gauche (desktop) --- */
.with-sidebar header { display: none; }
/* Top bar style: transform the old left sidebar into a horizontal top bar */
.sidebar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 76px;
  padding: 8px 24px;
  background: linear-gradient(180deg,
    color-mix(in srgb, var(--card) 94%, transparent),
    color-mix(in srgb, var(--card) 92%, transparent)
  );
  border-bottom: 1px solid color-mix(in srgb, var(--brand) 12%, transparent);
  z-index: 60;
  backdrop-filter: blur(12px) saturate(120%);
  box-shadow: 0 6px 24px rgba(0,0,0,0.12);
  display: flex;
  align-items: center;
}
.sidebar .sidebar-inner { 
  display: flex; 
  flex-direction: row; 
  align-items: center; 
  width: 100%; 
  justify-content: space-between; 
  gap: 24px; 
}

/* Brand name à gauche */
.sidebar-brand {
  flex-shrink: 0;
  padding-right: 24px;
}

.brand-name {
  font-size: 1.2rem;
  font-weight: 800;
  color: #ffffff !important;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  white-space: nowrap;
}

/* Masquer l'ancien header avec avatar */
.sidebar-header,
.sidebar-avatar-wrapper,
.sidebar-avatar-main,
.sidebar-name,
.sidebar-divider,
footer .sidebar-socials {
  display: flex !important;
  gap: 16px;
  justify-content: center;
  align-items: center;
}

footer .sidebar-socials .social-link {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  color: var(--muted);
  background: color-mix(in srgb, var(--text) 5%, transparent);
  transition: all 0.3s ease;
}

footer .sidebar-socials .social-link:hover {
  color: var(--brand);
  background: color-mix(in srgb, var(--brand) 15%, transparent);
  transform: translateY(-2px);
}

footer .sidebar-socials svg {
  width: 20px;
  height: 20px;
}

/* Avatar wrapper (topbar) */
.sidebar-avatar-wrapper {
  position: relative;
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Conteneur des vagues */
.avatar-waves {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 86px;
  height: 86px;
  pointer-events: none;
  opacity: 0;
  animation: waves-appear 1.2s ease-out 0.3s forwards;
}

@keyframes waves-appear {
  from {
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.8);
  }
  to {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
  }
}

/* Vagues individuelles - cercles élégants et subtils */
.wave {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  border: 1.5px solid transparent;
  opacity: 0;
}

/* Cercle intérieur - rotation lente */
.wave-1 {
  border-color: color-mix(in srgb, var(--brand) 55%, transparent);
  animation: 
    elegant-spin 15s linear infinite,
    elegant-fade 5s ease-in-out infinite;
  box-shadow: 
    0 0 18px color-mix(in srgb, var(--brand) 12%, transparent),
    inset 0 0 12px color-mix(in srgb, var(--brand) 8%, transparent);
  filter: blur(0.5px);
  border-width: 1.2px;
}

/* Cercle extérieur - rotation inverse */
.wave-2 {
  border-color: color-mix(in srgb, var(--brand-4) 45%, transparent);
  animation: 
    elegant-spin 20s linear infinite reverse,
    elegant-fade 7s ease-in-out infinite 1.5s;
  box-shadow: 
    0 0 15px color-mix(in srgb, var(--brand-4) 10%, transparent),
    inset 0 0 10px color-mix(in srgb, var(--brand-4) 6%, transparent);
  filter: blur(0.6px);
  transform: scale(1.06);
  border-width: 1px;
}

@keyframes elegant-spin {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

@keyframes elegant-fade {
  0%, 100% {
    opacity: 0.3;
  }
  50% {
    opacity: 0.65;
  }
}

/* Photo principale centrée */
.sidebar-avatar-main {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  overflow: hidden;
  background: color-mix(in srgb, var(--card) 62%, transparent);
  border: 3px solid var(--brand);
  box-shadow: 
    0 10px 32px rgba(2,6,23,0.5),
    0 0 40px color-mix(in srgb, var(--brand) 30%, transparent),
    inset 0 2px 6px rgba(255,255,255,0.1);
  position: relative;
  z-index: 2;
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.sidebar-avatar-main::before {
  content: '';
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  background: conic-gradient(
    from 0deg,
    var(--brand),
    var(--brand-4),
    var(--brand-2),
    var(--brand-3),
    var(--brand)
  );
  z-index: -1;
  animation: avatar-rotate 8s linear infinite;
  opacity: 0.6;
  filter: blur(8px);
}

@keyframes avatar-rotate {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.sidebar-avatar-main img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease, filter 0.4s ease;
}

.sidebar-avatar-main:hover {
  transform: scale(1.08) translateY(-4px);
  box-shadow: 
    0 16px 48px rgba(2,6,23,0.7),
    0 0 60px color-mix(in srgb, var(--brand) 50%, transparent);
  border-color: var(--brand-4);
}

.sidebar-avatar-main:hover img {
  transform: scale(1.1);
  filter: saturate(1.2) brightness(1.05);
}

.sidebar-avatar-main:hover::before {
  filter: blur(12px);
  opacity: 1;
}

/* Nom centré sous la photo */
.sidebar-name {
  display: flex;
  flex-direction: column;
  font-weight: 800;
  letter-spacing: 0.5px;
  line-height: 1.05;
}
.sidebar-name .firstname { font-size: 0.82rem; opacity: 0.95; color: var(--text); }
.sidebar-name .lastname { font-size: 0.95rem; color: var(--brand); text-shadow: 0 0 12px color-mix(in srgb, var(--brand) 24%, transparent); }

.topline { display: flex; align-items: center; justify-content: space-between; gap: 10px; }

/* Ancien style mini-avatar (gardé pour compatibilité) */
.sidebar-mini-avatar {
  width: 60px; height: 60px; border-radius: 50%; overflow: hidden; flex: 0 0 auto;
  background: color-mix(in srgb, var(--card) 62%, transparent); display: inline-block;
  border: 2px solid color-mix(in srgb, var(--text) 8%, transparent);
  box-shadow: 0 10px 32px rgba(2,6,23,0.5), 0 0 28px color-mix(in srgb, var(--brand) 10%, transparent), inset 0 2px 6px rgba(255,255,255,0.02);
  position: relative;
  isolation: isolate;
  transition: transform .28s cubic-bezier(.2,.9,.26,1), box-shadow .28s ease;
}
.sidebar-mini-avatar img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .28s ease, filter .28s ease; }

/* colorful conic ring behind the avatar */
.sidebar-mini-avatar::before {
  content: '';
  position: absolute; inset: -12px; z-index: -1;
  border-radius: 50%;
  background: conic-gradient(from 90deg, var(--brand), var(--brand-2), var(--brand-3), var(--brand-4), var(--brand));
  filter: blur(12px) saturate(150%);
  opacity: 0.96;
  transform: rotate(0deg) scale(1);
  transition: transform 650ms cubic-bezier(.2,.9,.26,1), opacity 220ms ease, filter 300ms ease;
}

/* subtle radial highlight overlay */
.sidebar-mini-avatar::after {
  content: '';
  position: absolute; inset: -6px; border-radius: 50%; pointer-events: none;
  background: radial-gradient(circle at 30% 25%, color-mix(in srgb, #fff 10%, transparent), transparent 30%), radial-gradient(closest-side at 60% 60%, color-mix(in srgb, var(--brand) 22%, transparent), transparent 65%);
  opacity: 0.95; mix-blend-mode: screen; transition: opacity .28s ease, transform .28s ease;
}

.sidebar-mini-avatar:hover { transform: translateY(-4px) scale(1.02); box-shadow: 0 18px 56px rgba(2,6,23,0.6), 0 0 48px color-mix(in srgb, var(--brand) 16%, transparent); }
.sidebar-mini-avatar:hover img { transform: scale(1.06); filter: saturate(1.06) contrast(1.02); }
.sidebar-mini-avatar:hover::before { filter: blur(14px) saturate(170%); transform: rotate(6deg) scale(1.03); opacity: 1; }
.sidebar-mini-avatar:hover::after { transform: scale(1.04); opacity: 1; }

/* slow spin animation for the conic ring */
.sidebar-mini-avatar.ring::before { animation: avatar-spin 9s linear infinite; }
@keyframes avatar-spin { from { transform: rotate(0deg) scale(1); } to { transform: rotate(360deg) scale(1); } }

.sidebar-mini-avatar.ring { box-shadow: 0 16px 64px rgba(2,6,23,0.6), 0 0 36px color-mix(in srgb, var(--brand) 10%, transparent); }

@media (max-width: 860px) {
  .sidebar-avatar-main { width: 70px; height: 70px; }
  .sidebar-avatar-wrapper { width: 80px; height: 80px; }
  .avatar-waves { width: 100px; height: 100px; }
  .sidebar-mini-avatar { width: 48px; height: 48px; }
}

@media (prefers-reduced-motion: reduce) {
  .wave { animation: none; }
  .sidebar-avatar-main::before { animation: none; }
  .sidebar-mini-avatar::before, .sidebar-mini-avatar.ring::before, .sidebar-mini-avatar::after { animation: none; transition: none; }
}
.sidebar-subtitle { color: var(--muted); font-size: .8rem; }
.sidebar-divider { height: 1px; background: color-mix(in srgb, var(--text) 10%, transparent); margin: 6px 0 4px; }
.side-nav { flex: 1; display: flex; align-items: center; justify-content: center; padding: 4px 8px; }
.side-nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 12px; align-items: center; }
.side-nav li { display: flex; }
.side-nav a {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 8px 12px;
  border-radius: 10px;
  color: var(--muted);
  transition: all var(--transition-base);
  font-size: 0.85rem;
  border: 1px solid transparent;
  position: relative;
  font-weight: 600;
  text-align: center;
}

.side-nav .icon {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 2px;
}

.side-nav .icon svg {
  width: 22px;
  height: 22px;
  color: currentColor;
}

.side-nav a::before {
  display: none;
}

.side-nav a:hover::before {
  display: none;
}

.side-nav a:hover, .side-nav a:focus { 
  color: var(--text); 
  background: transparent;
  transform: translateY(-2px); 
  border-color: #ffffff;
  box-shadow: 0 4px 12px rgba(255, 255, 255, 0.1);
}

.side-nav a.active {
  color: #fff;
  background: transparent;
  border-color: #ffffff;
  font-weight: 700;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(255, 255, 255, 0.15);
}

.side-nav a.active::before {
  display: none;
}

.side-nav a.active::after { 
  display: none;
}

.side-nav .icon { 
  opacity: 1; 
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  z-index: 1;
}
.side-nav .icon svg {
  width: 19px;
  height: 19px;
  color: currentColor;
  transition: all var(--transition-base);
  filter: drop-shadow(0 2px 4px rgba(0,0,0,0.1));
}

/* Theme toggle button in sidebar */
.sidebar-theme-btn {
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  border-radius: 12px;
  border: 1px solid color-mix(in srgb, var(--text) 15%, transparent);
  background: color-mix(in srgb, var(--card) 80%, transparent);
  color: var(--text);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-base);
  margin-left: 12px;
  position: relative;
}

.sidebar-theme-btn:hover {
  background: color-mix(in srgb, var(--text) 10%, transparent);
  border-color: var(--brand);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.sidebar-theme-btn .theme-icon {
  width: 22px;
  height: 22px;
  stroke: var(--text);
  position: absolute;
  transition: all var(--transition-base);
}

.sidebar-theme-btn .sun-icon {
  opacity: 0;
  transform: rotate(-90deg) scale(0.5);
}

.sidebar-theme-btn .moon-icon {
  opacity: 1;
  transform: rotate(0deg) scale(1);
}

html.light .sidebar-theme-btn .sun-icon {
  opacity: 1;
  transform: rotate(0deg) scale(1);
}

html.light .sidebar-theme-btn .moon-icon {
  opacity: 0;
  transform: rotate(90deg) scale(0.5);
}

.sidebar-theme-btn:hover .theme-icon {
  transform: rotate(20deg) scale(1.1);
}

html.light .sidebar-theme-btn:hover .sun-icon {
  transform: rotate(20deg) scale(1.1);
}

html.light .sidebar-theme-btn:hover .moon-icon {
  transform: rotate(110deg) scale(0.5);
}
.side-nav a:hover .icon svg {
  transform: scale(1.15) rotate(-5deg);
}
.side-nav a.active .icon svg {
  color: #fff;
  transform: scale(1.1);
  filter: drop-shadow(0 2px 6px rgba(0,0,0,0.3));
}
.sidebar-theme { display: grid; place-items: center; margin: 8px 0 4px; }
.sidebar-socials { display: flex; gap: 8px; justify-content: center; margin-top: 4px; }
.sidebar .social-link { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; color: var(--text); text-decoration: none; border: 1px solid color-mix(in srgb, var(--text) 12%, transparent); background: color-mix(in srgb, var(--card) 70%, transparent); transition: transform .15s ease, background .2s ease, border-color .2s ease; }
.sidebar .social-link:hover { transform: translateY(-2px); background: color-mix(in srgb, var(--brand) 14%, var(--card)); border-color: color-mix(in srgb, var(--brand) 30%, transparent); }
.theme-toggle { font-size: 16px; }
.header-toggle { width: 36px; height: 36px; }

/* Remove global left-offset so content can be centered; keep top padding. */
.with-sidebar main { margin-left: 270px; }
.with-sidebar footer { margin-left: 0 !important; }
/* Make main occupy the remaining width to the right of the fixed sidebar
  so that a centered .container inside main is visually centered in that area. */
.with-sidebar main { padding-top: 24px; width: calc(100vw - 270px); box-sizing: border-box; }
/* Centrer le conteneur à l'intérieur de la zone main (à droite de la sidebar) */
.with-sidebar .container { max-width: 1100px; width: 100%; margin: 0 auto; padding: 0 16px; box-sizing: border-box; }

/* Responsive: revenir à la barre du haut en mobile */
@media (max-width: 860px) {
  .with-sidebar header { display: block; }
  .sidebar { display: none; }
  .with-sidebar main, .with-sidebar footer { margin-left: 0; }
  .with-sidebar main { padding-top: 16px; }
  .with-sidebar .container { max-width: 100%; padding-left: 16px; padding-right: 16px; margin: 0 auto; }
}

/* Mobile improvements: overlay sidebar and mobile header */
@media (max-width: 860px) {
  /* Sidebar hidden by default; will slide in when .sidebar-open is added on body */
  .sidebar { position: fixed; left: 0; top: 0; bottom: 0; transform: translateX(-110%); width: 78%; max-width: 360px; display: block; transition: transform .28s cubic-bezier(.2,.9,.26,1); z-index: 150; }
  body.sidebar-open .sidebar { transform: translateX(0); }

  /* Dark translucent backdrop when sidebar open */
  .mobile-nav-backdrop { position: fixed; inset: 0; background: rgba(2,6,23,0.5); opacity: 0; pointer-events: none; transition: opacity .28s ease; z-index: 140; }
  body.sidebar-open .mobile-nav-backdrop { opacity: 1; pointer-events: auto; }

  /* Mobile header bar injected by JS */
  .mobile-header { position: fixed; left: 0; right: 0; top: 0; height: 56px; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 8px 12px; background: color-mix(in srgb, var(--card) 90%, transparent); border-bottom: 1px solid color-mix(in srgb, var(--text) 6%, transparent); z-index: 160; }
  .mobile-header .mh-left { display:flex; align-items:center; gap:10px; }
  .mobile-header .mh-title { font-weight:800; font-size:1rem; }
  .mobile-header .mh-toggle { width:44px; height:44px; border-radius:10px; display:grid; place-items:center; background: color-mix(in srgb, var(--card) 72%, transparent); border: 1px solid color-mix(in srgb, var(--text) 8%, transparent); }

  /* Ensure main content does not go under the header */
  .with-sidebar main { padding-top: 72px; }

  /* touch-friendly buttons */
  .btn, .pill { padding: 12px 14px; min-height: 44px; }
  
  /* Hero responsive */
  .hero {
    padding: 60px 24px;
    max-width: 100%;
  }
  
  .hero h1 {
    font-size: clamp(32px, 8vw, 48px);
  }
  
  .hero-subtitle {
    font-size: 1.1rem;
  }
  
  .hero-description {
    font-size: 1rem;
  }
  
  .hero-stats {
    flex-direction: column;
    gap: 20px;
    padding: 16px 20px;
  }
  
  .stat-divider {
    width: 60%;
    height: 1px;
  }
  
  .hero-badges .badge {
    font-size: 0.85rem;
    padding: 8px 14px;
  }
  
  .scroll-indicator {
    margin-top: 32px;
  }

  /* Projects grid single column on small screens to keep readability */
  .projects { grid-template-columns: 1fr !important; gap: 14px; }

  /* increase spacing in cards for legibility on small screens */
  .card { padding: 18px; }

  /* Make the preview image responsive and not overflow */
  .preview { width: 100%; aspect-ratio: 4 / 3; }
}

/* Hero */
#accueil { 
  padding: 0; 
  min-height: calc(100vh - 76px);
  display: flex; 
  align-items: center; 
  justify-content: center;
  position: relative;
  margin-left: -32px;
  margin-right: -32px;
  width: calc(100% + 64px);
  max-width: none;
}

#accueil .container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
}

.hero { 
  width: 100%; 
  max-width: 960px; 
  margin: 0 auto;
  display: flex; 
  flex-direction: column; 
  align-items: center; 
  justify-content: center;
  text-align: center;
  padding: 80px 32px; 
  z-index: 2;
}
.hero-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
}

/* Hero avatar - Grande photo pour la page d'accueil */
.hero-avatar-wrapper {
  position: relative;
  width: 200px;
  height: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
}

@keyframes hero-avatar-appear {
  from {
    opacity: 0;
    transform: scale(0.6) translateY(-30px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

.hero-avatar {
  width: 200px;
  height: 200px;
  border-radius: 50%;
  overflow: hidden;
  background: color-mix(in srgb, var(--card) 70%, transparent);
  border: 5px solid #ffffff;
  box-shadow: 
    0 20px 60px rgba(0, 0, 0, 0.4);
  position: relative;
  z-index: 2;
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.hero-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease, filter 0.4s ease;
}

.hero-avatar:hover {
  transform: scale(1.05);
  box-shadow: 
    0 30px 80px rgba(0, 0, 0, 0.6);
  border-color: #ffffff;
}

.hero-avatar:hover img {
  transform: scale(1.08);
  filter: saturate(1.2) brightness(1.05);
}

/* Hero name - Grand titre avec le nom */
.hero-name {
  font-size: 3.5rem;
  font-weight: 800;
  margin: 0;
  background: linear-gradient(135deg, #93c5fd, #7c3aed);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: 0.02em;
  line-height: 1.1;
}

/* Hero role - Sous-titre avec icône bouclier */
.hero-role {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text);
  margin: 8px 0 16px;
  padding: 0;
}

.shield-icon {
  color: var(--brand);
  flex-shrink: 0;
}

/* Hero description - Texte descriptif */
.hero-description {
  font-size: 1.05rem;
  line-height: 1.7;
  color: var(--muted);
  max-width: 720px;
  margin: 0 0 32px;
}

.highlight-blue {
  color: var(--brand);
  font-weight: 600;
}

.highlight-green {
  color: var(--success);
  font-weight: 600;
}

/* Hero CTA Group - Boutons d'action */
.hero-cta-group {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: center;
  align-items: center;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 28px;
  border-radius: 8px;
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  transition: all 0.3s ease;
  cursor: pointer;
  border: 2px solid transparent;
  text-decoration: none;
}

.btn svg {
  flex-shrink: 0;
}

.btn-primary {
  background: var(--brand);
  color: #fff;
  box-shadow: 0 4px 16px color-mix(in srgb, var(--brand) 40%, transparent);
}

.btn-primary:hover {
  background: color-mix(in srgb, var(--brand) 90%, #fff);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px color-mix(in srgb, var(--brand) 50%, transparent);
}

.btn-secondary {
  background: transparent;
  color: var(--text);
  border-color: color-mix(in srgb, var(--text) 30%, transparent);
}

.btn-secondary:hover {
  background: color-mix(in srgb, var(--brand) 10%, transparent);
  border-color: var(--brand);
  color: var(--brand);
  transform: translateY(-2px);
}

@media (max-width: 860px) {
  .hero-avatar-wrapper {
    width: 150px;
    height: 150px;
  }
  .hero-avatar {
    width: 150px;
    height: 150px;
    border-width: 4px;
  }
  .hero-name {
    font-size: 2.5rem;
  }
  .hero-role {
    font-size: 1rem;
  }
  .hero-description {
    font-size: 0.95rem;
  }
  .hero-cta-group {
    flex-direction: column;
    width: 100%;
  }
  .btn {
    width: 100%;
    justify-content: center;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero-avatar-wrapper { animation: none; }
  .hero-avatar:hover { transform: scale(1.02); }
}

/* Anciens styles à supprimer ou adapter */
.hero-avatar-rings,
.hero-ring,
.hero-ring-1,
.hero-ring-2,
.hero-ring-3 {
  display: none; /* Masquer les anciens anneaux */
}

/* Status badge */
.hero-status-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 18px;
  background: color-mix(in srgb, var(--success) 15%, var(--card));
  border: 1px solid color-mix(in srgb, var(--success) 30%, transparent);
  border-radius: 999px;
  color: var(--success);
  font-size: 0.9rem;
  font-weight: 600;
  backdrop-filter: blur(12px);
  box-shadow: 0 4px 12px color-mix(in srgb, var(--success) 15%, transparent);
  animation: status-pulse 2s ease-in-out infinite;
}

@keyframes status-pulse {
  0%, 100% { box-shadow: 0 4px 12px color-mix(in srgb, var(--success) 15%, transparent); }
  50% { box-shadow: 0 4px 20px color-mix(in srgb, var(--success) 30%, transparent); }
}

.status-dot {
  width: 8px;
  height: 8px;
  background: var(--success);
  border-radius: 50%;
  animation: dot-pulse 2s ease-in-out infinite;
}

@keyframes dot-pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.6; transform: scale(1.2); }
}

/* Hero title */
.hero h1 { 
  font-size: clamp(42px, 7vw, 72px); 
  line-height: 1.1; 
  margin: 20px 0 16px; 
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #ffffff;
  text-shadow: 0 4px 24px rgba(0,0,0,0.4), 0 2px 8px rgba(0,0,0,0.3);
  background: linear-gradient(135deg, #ffffff 0%, var(--brand) 100%);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-size: 200% 200%;
  animation: gradientShift 8s ease infinite;
}

@keyframes gradientShift {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}

.hero-subtitle {
  font-size: clamp(1.1rem, 2vw, 1.4rem);
  font-weight: 600;
  color: var(--brand);
  margin: 0 0 16px;
  text-shadow: 0 2px 8px rgba(0,0,0,0.4);
  opacity: 1;
  transition: all 0.3s ease;
}

/* Textes fixes sans animation par défaut */
.hero-text-fixed {
  opacity: 1 !important;
  clip-path: none !important;
}

/* Effet de surbrillance (highlight) au survol pour le subtitle */
.hero-subtitle.hero-text-fixed {
  padding: 8px 16px;
  border-radius: 8px;
  cursor: default;
  position: relative;
  display: inline-block;
}

.hero-subtitle.hero-text-fixed:hover {
  background: linear-gradient(135deg, 
    color-mix(in srgb, var(--brand) 25%, transparent),
    color-mix(in srgb, var(--brand-4) 20%, transparent)
  );
  text-shadow: 
    0 0 20px var(--brand),
    0 0 40px color-mix(in srgb, var(--brand) 60%, transparent),
    0 2px 8px rgba(0,0,0,0.4);
  box-shadow: 
    0 4px 20px color-mix(in srgb, var(--brand) 30%, transparent),
    inset 0 1px 0 rgba(255,255,255,0.2);
  transform: scale(1.03);
  border: 1px solid color-mix(in srgb, var(--brand) 40%, transparent);
}

.hero-subtitle.light-bulb-animation {
  animation: lightPulse 0.5s ease-in-out;
}

/* Style pour le lien dans hero-subtitle */
.hero-subtitle-link {
  color: var(--brand);
  text-decoration: none;
  transition: all 0.3s ease;
  font-weight: 600;
}

.hero-subtitle-link:hover {
  text-shadow: 
    0 0 20px var(--brand),
    0 0 40px color-mix(in srgb, var(--brand) 60%, transparent);
  filter: brightness(1.2);
}

@keyframes lightPulse {
  0%, 100% { 
    filter: brightness(1);
    transform: scale(1);
  }
  50% { 
    filter: brightness(1.5);
    transform: scale(1.02);
  }
}

.hero-description {
  margin: 0 0 20px; 
  color: var(--muted); 
  font-size: 1.1rem; 
  max-width: 650px;
  line-height: 1.65;
  text-shadow: 0 2px 8px rgba(0,0,0,0.5);
  opacity: 1;
  clip-path: none;
  transition: all 0.4s ease;
  cursor: default;
}

/* Effet de perspective 3D au survol pour la description */
.hero-description.hero-text-fixed {
  padding: 16px 20px;
  border-radius: 12px;
  background: color-mix(in srgb, var(--card) 40%, transparent);
  border: 1px solid color-mix(in srgb, var(--text) 10%, transparent);
  backdrop-filter: blur(8px);
  transform-style: preserve-3d;
  perspective: 1000px;
}

.hero-description.hero-text-fixed:hover {
  background: linear-gradient(135deg,
    color-mix(in srgb, var(--card) 70%, transparent),
    color-mix(in srgb, var(--brand) 10%, transparent)
  );
  border-color: color-mix(in srgb, var(--brand-4) 30%, transparent);
  box-shadow: 
    0 8px 32px color-mix(in srgb, var(--brand) 20%, transparent),
    0 16px 64px rgba(0,0,0,0.4),
    inset 0 1px 0 rgba(255,255,255,0.15);
  transform: translateY(-4px) rotateX(2deg);
  color: var(--text);
  text-shadow: 
    0 0 10px color-mix(in srgb, var(--brand-4) 40%, transparent),
    0 2px 8px rgba(0,0,0,0.5);
}

/* Mise en forme du texte dans la description hero */
.hero-description .description-highlight {
  color: var(--brand);
  font-weight: 700;
  position: relative;
  text-shadow: 0 0 20px color-mix(in srgb, var(--brand) 30%, transparent);
}

.hero-description .highlight-tech {
  color: var(--brand-4);
  font-weight: 600;
  position: relative;
}

.hero-description strong {
  color: var(--brand-4);
  font-weight: 800;
  background: linear-gradient(120deg, 
    transparent 0%, 
    color-mix(in srgb, var(--brand) 15%, transparent) 50%, 
    transparent 100%
  );
  padding: 2px 6px;
  border-radius: 6px;
  text-shadow: 0 0 12px color-mix(in srgb, var(--brand-4) 30%, transparent);
}

/* Hero Statistics */
.hero-stats {
  display: flex;
  gap: 32px;
  margin: 32px 0;
  justify-content: center;
  flex-wrap: wrap;
}

.stat-item {
  text-align: center;
  padding: 16px 24px;
  border-radius: 12px;
  background: color-mix(in srgb, var(--card) 60%, transparent);
  border: 1px solid color-mix(in srgb, var(--text) 8%, transparent);
  transition: all var(--transition-base);
  min-width: 120px;
}

.stat-item:hover {
  transform: translateY(-4px);
  border-color: var(--brand);
  background: color-mix(in srgb, var(--card) 80%, transparent);
  box-shadow: 0 8px 24px rgba(0,0,0,0.12);
}

.stat-item.stat-filter {
  cursor: pointer;
  user-select: none;
}

.stat-item.stat-filter.active {
  background: linear-gradient(135deg, 
    color-mix(in srgb, var(--brand) 20%, transparent),
    color-mix(in srgb, var(--brand-2) 15%, transparent));
  border-color: var(--brand);
  box-shadow: 0 4px 16px rgba(var(--brand-rgb), 0.3);
  transform: translateY(-2px);
}

.stat-item.stat-filter.active .stat-number {
  color: var(--brand);
  text-shadow: 0 0 30px color-mix(in srgb, var(--brand) 50%, transparent);
}

.stat-item.stat-filter.active .stat-label {
  color: var(--brand-2);
  font-weight: 600;
}

.stat-number {
  font-size: 2rem;
  font-weight: 800;
  color: var(--brand);
  line-height: 1;
  margin-bottom: 8px;
  text-shadow: 0 0 20px color-mix(in srgb, var(--brand) 30%, transparent);
}

.stat-label {
  font-size: 0.85rem;
  color: var(--muted);
  font-weight: 500;
  letter-spacing: 0.3px;
}

.hero-description.reveal-animation {
  animation: slideReveal 1.2s ease-out forwards;
}

@keyframes slideReveal {
  0% {
    clip-path: inset(0 100% 0 0);
    opacity: 0.3;
  }
  100% {
    clip-path: inset(0 0% 0 0);
    opacity: 1;
  }
}
.hero-meta { 
  display: flex; 
  flex-wrap: wrap; 
  gap: 10px; 
  margin: 16px 0 24px; 
  padding: 0; 
  list-style: none; 
  justify-content: center;
}
.hero-meta li { 
  padding: 8px 16px; 
  border-radius: 999px; 
  background: color-mix(in srgb, var(--card) 85%, transparent); 
  border: 1px solid color-mix(in srgb, var(--text) 15%, transparent); 
  color: var(--text); 
  font-size: .95rem;
  backdrop-filter: blur(8px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.25);
}
/* Hero stats section */
.hero-stats {
  display: flex;
  align-items: center;
  gap: 32px;
  margin: 24px 0 32px;
  padding: 20px 32px;
  background: color-mix(in srgb, var(--card) 70%, transparent);
  border: 1px solid color-mix(in srgb, var(--text) 12%, transparent);
  border-radius: 16px;
  backdrop-filter: blur(12px);
  box-shadow: 0 8px 24px rgba(0,0,0,0.2);
}

.stat-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.stat-number {
  font-size: clamp(1.8rem, 3vw, 2.4rem);
  font-weight: 900;
  background: linear-gradient(135deg, var(--brand), var(--brand-4));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1;
}

.stat-label {
  font-size: 0.85rem;
  color: var(--muted);
  font-weight: 500;
  white-space: nowrap;
}

.stat-divider {
  width: 1px;
  height: 40px;
  background: color-mix(in srgb, var(--text) 15%, transparent);
}

.cta { 
  display: flex; 
  gap: 16px; 
  flex-wrap: wrap; 
  justify-content: center;
  margin-top: 32px;
}
.btn { 
  padding: 14px 28px; 
  border-radius: 12px; 
  border: 1px solid color-mix(in srgb, var(--text) 14%, transparent); 
  color: var(--text); 
  background: color-mix(in srgb, var(--card) 60%, transparent); 
  cursor: pointer;
  font-size: 1rem;
  font-weight: 600;
  backdrop-filter: blur(12px);
  transition: all var(--transition-base);
  box-shadow: 0 4px 16px rgba(0,0,0,0.2);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  position: relative;
  overflow: hidden;
}

.btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, transparent, color-mix(in srgb, var(--brand) 10%, transparent));
  opacity: 0;
  transition: opacity var(--transition-base);
}

.btn:hover::before {
  opacity: 1;
}

.btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(0,0,0,0.35);
  border-color: color-mix(in srgb, var(--brand) 50%, transparent);
}

.btn svg {
  transition: transform var(--transition-base);
}

.btn:hover svg {
  transform: translateX(4px);
}

.btn.primary { 
  background: linear-gradient(135deg, var(--brand), var(--brand-4)); 
  border-color: transparent;
  color: #0b1020;
  font-weight: 700;
  box-shadow: 0 4px 20px color-mix(in srgb, var(--brand) 35%, transparent);
}
.btn.primary:hover {
  box-shadow: 0 8px 32px color-mix(in srgb, var(--brand) 50%, transparent);
  transform: translateY(-3px) scale(1.02);
}

.btn.secondary {
  border-color: color-mix(in srgb, var(--text) 20%, transparent);
}
.preview { aspect-ratio: 4 / 3; border-radius: 14px; background: linear-gradient(135deg, color-mix(in srgb, var(--brand) 30%, var(--card)), var(--card)); border: 1px solid color-mix(in srgb, var(--text) 10%, transparent); display: grid; place-items: center; color: color-mix(in srgb, var(--text) 70%, transparent); }
 .preview img { width: 100%; height: 100%; object-fit: cover; border-radius: 12px; display: block; }

/* Hero badges */
.hero-badges { 
  display: flex; 
  gap: 12px; 
  margin: 20px 0; 
  flex-wrap: wrap;
  justify-content: center;
}
.hero-badges .badge { 
  padding: 10px 20px; 
  border-radius: 999px; 
  background: color-mix(in srgb, var(--card) 75%, transparent);
  border: 1px solid color-mix(in srgb, var(--text) 18%, transparent);
  color: var(--text); 
  font-weight: 600; 
  font-size: 0.95rem; 
  box-shadow: 0 4px 16px rgba(0,0,0,0.25);
  backdrop-filter: blur(12px);
  transition: all var(--transition-base);
}

.hero-badges .badge:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0,0,0,0.35);
  border-color: color-mix(in srgb, var(--brand) 40%, transparent);
}

/* Scroll indicator */
.scroll-indicator {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  margin-top: 48px;
  color: var(--muted);
  font-size: 0.85rem;
  opacity: 0.7;
  animation: scroll-bounce 2s ease-in-out infinite;
}

@keyframes scroll-bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(8px); }
}

.scroll-indicator svg {
  opacity: 0.6;
}

/* Sections */
section { padding: 48px 0; }
.section-title { font-size: 1.85rem; margin: 0 0 20px; }

/* Certifications page */
/* Header de la section certifications - Même style que compétences */
.certifications-header {
  position: relative;
  text-align: center;
  padding: 2.5rem 2rem;
  margin-bottom: 2.5rem;
  background: var(--card);
  border-radius: 16px;
  border: 1px solid color-mix(in srgb, var(--text) 10%, transparent);
  overflow: hidden;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
}

.certifications-header::before {
  content: none;
}

.certifications-header::after {
  content: none;
}

.certifications-title {
  font-size: 2.5rem;
  font-weight: 800;
  margin: 0 0 0.5rem;
  color: var(--text);
  position: relative;
  z-index: 1;
}

.certifications-title .title-icon {
  display: inline-block;
  font-size: 1.2em;
  margin-right: 0.3rem;
}

.certifications-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 28px;
  margin: 40px 0;
  padding-bottom: 80px;
}

.cert-card {
  display: flex;
  flex-direction: column;
  gap: 16px;
  transition: all var(--transition-base);
  position: relative;
  overflow: hidden;
}

.cert-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--brand), var(--brand-4));
  opacity: 0;
  transition: opacity var(--transition-base);
}

.cert-card:hover::before {
  opacity: 1;
}

.cert-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 40px rgba(0,0,0,0.15);
  border-color: color-mix(in srgb, var(--brand) 20%, transparent);
}

.cert-header {
  display: flex;
  gap: 16px;
  align-items: flex-start;
}

.cert-icon {
  width: 56px;
  height: 56px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--brand), var(--brand-4));
  color: #0b1020;
  flex-shrink: 0;
}

.cert-meta {
  flex: 1;
}

.cert-meta h3 {
  font-size: 1.1rem;
  margin: 0 0 4px;
  font-weight: 700;
  line-height: 1.3;
}

.cert-org {
  font-size: 0.85rem;
  color: var(--muted);
  font-weight: 500;
}

.cert-body {
  flex: 1;
}

.cert-body p {
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--muted);
  margin: 0 0 16px;
}

.cert-skills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.skill-tag {
  padding: 4px 10px;
  background: color-mix(in srgb, var(--brand) 12%, var(--card));
  border: 1px solid color-mix(in srgb, var(--brand) 20%, transparent);
  border-radius: 4px;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--brand);
  transition: all 0.3s ease;
}

.skill-tag:hover {
  background: color-mix(in srgb, var(--brand) 20%, var(--card));
  border-color: var(--brand);
  transform: translateY(-2px);
}

.cert-footer {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  padding-top: 16px;
  border-top: 1px solid color-mix(in srgb, var(--text) 6%, transparent);
}

.cert-date {
  font-size: 0.85rem;
  color: var(--muted);
}

.cert-status {
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 600;
  transition: all 0.2s ease;
}

.cert-status:hover {
  transform: scale(1.05);
}

.status-obtained {
  background: color-mix(in srgb, #10b981 12%, var(--card));
  color: #10b981;
  border: 1px solid color-mix(in srgb, #10b981 20%, transparent);
}

.status-progress {
  background: color-mix(in srgb, #f59e0b 12%, var(--card));
  color: #f59e0b;
  border: 1px solid color-mix(in srgb, #f59e0b 20%, transparent);
}

.status-planned {
  background: color-mix(in srgb, #3b82f6 12%, var(--card));
  color: #3b82f6;
  border: 1px solid color-mix(in srgb, #3b82f6 20%, transparent);
}

/* Diploma placeholder styles */
.cert-diploma {
  margin: 16px 0;
  padding: 0;
  background: color-mix(in srgb, var(--card) 100%, white 3%);
  border: 1px solid color-mix(in srgb, var(--text) 10%, transparent);
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.3s ease;
  overflow: hidden;
  position: relative;
}

.cert-diploma:hover {
  border-color: color-mix(in srgb, var(--brand) 40%, transparent);
  transform: scale(1.02);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

.cert-diploma::after {
  content: '🔍 Cliquer pour agrandir';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
  color: white;
  padding: 12px;
  text-align: center;
  font-size: 0.85rem;
  font-weight: 500;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.cert-diploma:hover::after {
  opacity: 1;
}

.diploma-placeholder {
  display: none;
}

.cert-diploma img {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  max-height: 200px;
}

/* Diploma modal styles */
.diploma-modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.9);
  z-index: 10000;
  justify-content: center;
  align-items: center;
  padding: 20px;
  animation: fadeIn 0.3s ease;
}

.diploma-modal.active {
  display: flex;
}

.diploma-modal-content {
  position: relative;
  max-width: 90%;
  max-height: 90vh;
  animation: slideIn 0.3s ease;
}

.diploma-modal-content img {
  max-width: 100%;
  max-height: 90vh;
  width: auto;
  height: auto;
  border-radius: 8px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.diploma-modal-close {
  position: absolute;
  top: -40px;
  right: 0;
  background: rgba(255, 255, 255, 0.2);
  border: none;
  color: white;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  transition: all 0.3s ease;
  backdrop-filter: blur(10px);
}

.diploma-modal-close:hover {
  background: rgba(255, 255, 255, 0.3);
  transform: rotate(90deg);
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes slideIn {
  from { 
    opacity: 0;
    transform: scale(0.9) translateY(20px);
  }
  to { 
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

/* Responsive diploma modal */
@media (max-width: 768px) {
  /* On small screens keep a compact top bar with smaller avatar */
  .sidebar { height: 64px; padding: 6px 12px; }
  .sidebar-avatar-main { width: 44px; height: 44px; }
  .sidebar-avatar-wrapper { width: 56px; height: 56px; }
  .avatar-waves { width: 80px; height: 80px; }
  .sidebar-mini-avatar { width: 48px; height: 48px; }
}

/* Push main content below the topbar when using the sidebar-as-topbar layout */
body.with-sidebar main { 
  padding-top: 76px;
  margin-left: auto !important;
  margin-right: auto !important;
  max-width: 1400px !important;
  width: 100% !important;
  padding-left: 32px;
  padding-right: 32px;
}

main {
  margin-left: auto !important;
  margin-right: auto !important;
  width: 100% !important;
  max-width: 1400px !important;
  padding-left: 32px;
  padding-right: 32px;
}

.container {
  max-width: 100% !important;
  padding-left: 24px !important;
  padding-right: 24px !important;
}

@media (max-width: 860px) {
  .diploma-modal-close {
    top: 10px;
    right: 10px;
    position: fixed;
  }
  
  .cert-diploma img {
    max-height: 180px;
  }
  
  .cert-diploma::after {
    font-size: 0.8rem;
    padding: 10px;
  }
}

.cert-summary {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  margin: 0;
  padding: 32px;
  background: color-mix(in srgb, var(--card) 95%, transparent);
  border-top: 1px solid color-mix(in srgb, var(--text) 10%, transparent);
  backdrop-filter: blur(12px);
  z-index: 100;
  box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.1);
}

.cert-summary h3 {
  margin: 0 0 24px;
  font-size: 1.3rem;
  text-align: center;
}

.summary-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 24px;
}

.summary-item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px;
  background: var(--card);
  border-radius: 12px;
  border: 1px solid color-mix(in srgb, var(--text) 8%, transparent);
}

.summary-icon {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  flex-shrink: 0;
}

.summary-icon.success {
  background: color-mix(in srgb, var(--success) 15%, var(--card));
  color: var(--success);
}

.summary-icon.progress {
  background: color-mix(in srgb, var(--warning) 15%, var(--card));
  color: var(--warning);
}

.summary-icon.planned {
  background: color-mix(in srgb, var(--info) 15%, var(--card));
  color: var(--info);
}

.summary-content {
  flex: 1;
}

.summary-number {
  font-size: 1.8rem;
  font-weight: 900;
  line-height: 1;
  margin-bottom: 4px;
}

.summary-label {
  font-size: 0.9rem;
  color: var(--muted);
  font-weight: 500;
}

/* Header de la section compétences - Design premium */
.competences-header {
  position: relative;
  text-align: center;
  padding: 2.5rem 2rem;
  margin-bottom: 2.5rem;
  background: var(--card);
  border-radius: 16px;
  border: 1px solid color-mix(in srgb, var(--text) 10%, transparent);
  overflow: hidden;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
}

.competences-header::before {
  content: none;
}

.competences-header::after {
  content: none;
}

@keyframes rotate {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@keyframes shimmer {
  0%, 100% { opacity: 0; }
  50% { opacity: 0.3; }
}

.title-decoration {
  display: none;
}

.competences-title {
  font-size: 2.5rem;
  font-weight: 800;
  margin: 0 0 0.5rem;
  color: var(--text);
  position: relative;
  z-index: 1;
}

.title-wrapper {
  display: inline;
}

.title-text {
  color: var(--text);
}

.title-underline {
  display: none;
}

.competences-title .title-icon {
  display: inline-block;
  font-size: 1.2em;
  margin-right: 0.3rem;
}

.competences-description {
  font-size: 1rem;
  line-height: 1.6;
  color: var(--muted);
  margin: 0;
  position: relative;
  z-index: 1;
}

.description-highlight {
  color: var(--text);
  font-weight: 500;
}

.competences-stats {
  display: flex;
  justify-content: center;
  margin-top: 32px;
  position: relative;
  z-index: 1;
}

.stat-badge {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 24px 40px;
  background: color-mix(in srgb, var(--card) 85%, transparent);
  backdrop-filter: blur(16px) saturate(120%);
  border-radius: 20px;
  border: 2px solid color-mix(in srgb, var(--brand) 25%, transparent);
  box-shadow: 
    0 6px 24px color-mix(in srgb, var(--brand) 12%, transparent),
    inset 0 1px 0 rgba(255,255,255,0.2);
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  position: relative;
  overflow: hidden;
}

.stat-badge::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: linear-gradient(
    45deg,
    transparent 30%,
    color-mix(in srgb, var(--brand) 10%, transparent) 50%,
    transparent 70%
  );
  animation: shimmer-badge 2s ease-in-out infinite;
}

@keyframes shimmer-badge {
  0%, 100% { transform: translateX(-100%) translateY(-100%); }
  50% { transform: translateX(100%) translateY(100%); }
}

.stat-badge:hover {
  transform: translateY(-6px) scale(1.05);
  box-shadow: 
    0 12px 36px color-mix(in srgb, var(--brand) 20%, transparent),
    inset 0 1px 0 rgba(255,255,255,0.3);
  border-color: color-mix(in srgb, var(--brand) 40%, transparent);
}

.stat-icon {
  font-size: 2.5rem;
  filter: drop-shadow(0 4px 12px color-mix(in srgb, var(--brand) 40%, transparent));
  animation: float 3s ease-in-out infinite;
}

@keyframes float {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-8px); }
}

.stat-number {
  font-size: 2.4rem;
  font-weight: 900;
  background: linear-gradient(135deg, var(--brand), var(--brand-4), var(--brand-2));
  background-size: 200% 200%;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1;
  animation: gradient-shift 3s ease infinite;
  position: relative;
  z-index: 1;
}

.stat-label {
  font-size: 0.9rem;
  color: var(--text);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  opacity: 0.8;
  position: relative;
  z-index: 1;
}

/* Center section titles specifically for competence/outils sections */
#competences .section-title, #outils .section-title, #competences .muted, #outils .muted { text-align: center; }

/* ========================================
   OUTILS HEADER - Design Premium (identique à compétences)
   ======================================== */

.outils-header {
  text-align: center;
  max-width: 900px;
  margin: 0 auto 50px;
  padding: 50px 40px;
  background: linear-gradient(135deg, 
    color-mix(in srgb, var(--brand) 10%, transparent),
    color-mix(in srgb, var(--brand-4) 6%, transparent),
    color-mix(in srgb, var(--brand-2) 4%, transparent)
  );
  border-radius: 28px;
  border: 2px solid color-mix(in srgb, var(--brand) 18%, transparent);
  box-shadow: 
    0 12px 48px color-mix(in srgb, var(--brand) 12%, transparent),
    0 4px 16px color-mix(in srgb, var(--brand) 8%, transparent),
    inset 0 1px 0 rgba(255,255,255,0.15),
    inset 0 -1px 0 color-mix(in srgb, var(--brand) 10%, transparent);
  position: relative;
  overflow: hidden;
}

.outils-header::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, 
    color-mix(in srgb, var(--brand) 20%, transparent) 0%, 
    transparent 70%
  );
  animation: rotate 25s linear infinite;
  opacity: 0.4;
}

.outils-header::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(
    45deg,
    transparent 30%,
    color-mix(in srgb, var(--brand) 5%, transparent) 50%,
    transparent 70%
  );
  animation: shimmer 3s ease-in-out infinite;
  pointer-events: none;
}

.outils-title {
  font-size: clamp(2.4rem, 5.5vw, 3.2rem);
  font-weight: 900;
  margin: 0 0 28px;
  position: relative;
  z-index: 1;
  letter-spacing: -0.03em;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.outils-title .title-text {
  background: linear-gradient(135deg, var(--brand), var(--brand-4), var(--brand-2), var(--brand));
  background-size: 200% 200%;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: gradient-shift 4s ease infinite;
}

.outils-title .title-icon {
  display: inline-block;
  font-size: 1.4em;
  animation: pulse-icon 2.5s ease-in-out infinite;
  filter: drop-shadow(0 6px 12px rgba(255, 160, 0, 0.5));
}

.outils-description {
  font-size: 1.12rem;
  line-height: 1.85;
  color: var(--text);
  opacity: 0.95;
  margin: 0 0 32px;
  max-width: 750px;
  margin-left: auto;
  margin-right: auto;
  position: relative;
  z-index: 1;
}

.outils-description .description-highlight {
  color: var(--brand);
  font-weight: 700;
  position: relative;
  text-shadow: 0 0 20px color-mix(in srgb, var(--brand) 30%, transparent);
}

.outils-description strong {
  color: var(--brand-4);
  font-weight: 800;
  background: linear-gradient(120deg, 
    transparent 0%, 
    color-mix(in srgb, var(--brand) 15%, transparent) 50%, 
    transparent 100%
  );
  padding: 3px 6px;
  border-radius: 6px;
  text-shadow: 0 0 12px color-mix(in srgb, var(--brand-4) 30%, transparent);
}

.outils-stats {
  display: flex;
  justify-content: center;
  margin-top: 32px;
  position: relative;
  z-index: 1;
}

.outils-stats .stat-badge {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 24px 40px;
  background: color-mix(in srgb, var(--card) 85%, transparent);
  backdrop-filter: blur(16px) saturate(120%);
  border-radius: 20px;
  border: 2px solid color-mix(in srgb, var(--brand) 25%, transparent);
  box-shadow: 
    0 6px 24px color-mix(in srgb, var(--brand) 12%, transparent),
    inset 0 1px 0 rgba(255,255,255,0.2);
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  position: relative;
  overflow: hidden;
}

.outils-stats .stat-badge::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: linear-gradient(
    45deg,
    transparent 30%,
    color-mix(in srgb, var(--brand) 10%, transparent) 50%,
    transparent 70%
  );
  animation: shimmer-badge 2s ease-in-out infinite;
}

.outils-stats .stat-badge:hover {
  transform: translateY(-6px) scale(1.05);
  box-shadow: 
    0 12px 36px color-mix(in srgb, var(--brand) 20%, transparent),
    inset 0 1px 0 rgba(255,255,255,0.3);
  border-color: color-mix(in srgb, var(--brand) 40%, transparent);
}

.outils-stats .stat-icon {
  font-size: 2.5rem;
  filter: drop-shadow(0 4px 12px color-mix(in srgb, var(--brand) 40%, transparent));
  animation: float 3s ease-in-out infinite;
}

.outils-stats .stat-number {
  font-size: 2.4rem;
  font-weight: 900;
  background: linear-gradient(135deg, var(--brand), var(--brand-4), var(--brand-2));
  background-size: 200% 200%;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1;
  animation: gradient-shift 3s ease infinite;
  position: relative;
  z-index: 1;
}

.outils-stats .stat-label {
  font-size: 0.9rem;
  color: var(--text);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  opacity: 0.8;
  position: relative;
  z-index: 1;
}

/* ========================================
   END OUTILS HEADER
   ======================================== */

/* ========================================
   COMPETENCES GRID - Design Premium
   ======================================== */

.competences-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 28px;
  margin-top: 40px;
  padding: 0;
}

/* Skill Card - Carte de compétence premium */
.skill-card {
  position: relative;
  background: linear-gradient(135deg, 
    color-mix(in srgb, var(--card) 95%, transparent),
    color-mix(in srgb, var(--card) 85%, transparent)
  );
  border: 2px solid color-mix(in srgb, var(--text) 8%, transparent);
  border-radius: 20px;
  padding: 28px 24px;
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  overflow: hidden;
  cursor: default;
}

.skill-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(
    135deg,
    color-mix(in srgb, var(--brand) 0%, transparent) 0%,
    color-mix(in srgb, var(--brand) 3%, transparent) 50%,
    color-mix(in srgb, var(--brand) 0%, transparent) 100%
  );
  opacity: 0;
  transition: opacity 0.4s ease;
  pointer-events: none;
}

.skill-card:hover::before {
  opacity: 1;
}

.skill-card:hover {
  transform: translateY(-8px) scale(1.02);
  border-color: color-mix(in srgb, var(--brand) 35%, transparent);
  box-shadow: 
    0 20px 50px color-mix(in srgb, var(--brand) 18%, transparent),
    0 8px 20px color-mix(in srgb, var(--brand) 10%, transparent),
    inset 0 1px 0 rgba(255, 255, 255, 0.15);
}

/* Coloration uniforme pour toutes les catégories */
.skill-card[data-type="d"]:hover,
.skill-card[data-type="r"]:hover {
  border-color: var(--brand);
  box-shadow: 
    0 20px 50px rgba(56, 189, 248, 0.2),
    0 8px 20px rgba(56, 189, 248, 0.12);
}

.skill-card[data-type="d"] .progress-fill,
.skill-card[data-type="r"] .progress-fill {
  background: linear-gradient(90deg, var(--brand) 0%, var(--brand-2) 50%, var(--brand-3) 100%);
  box-shadow: 0 2px 12px rgba(56, 189, 248, 0.4);
}

.skill-card[data-type="d"] .skill-percent,
.skill-card[data-type="r"] .skill-percent {
  background: linear-gradient(135deg, var(--brand) 0%, var(--brand-2) 100%);
  color: #ffffff;
}

.skill-card[data-type="d"] .skill-category,
.skill-card[data-type="r"] .skill-category {
  color: var(--brand);
}

.skill-card[data-type="d"] .skill-glow,
.skill-card[data-type="r"] .skill-glow {
  background: radial-gradient(circle, 
    rgba(56, 189, 248, 0.35),
    transparent 70%
  );
}

.skill-card-inner {
  display: flex;
  flex-direction: column;
  gap: 18px;
  position: relative;
  z-index: 1;
}

/* Icon wrapper avec effet de glow */
.skill-icon-wrapper {
  position: relative;
  width: 72px;
  height: 72px;
  margin: 0 auto;
}

.skill-icon {
  width: 72px;
  height: 72px;
  border-radius: 16px;
  object-fit: cover;
  display: block;
  box-shadow: 
    0 8px 24px rgba(0, 0, 0, 0.15),
    inset 0 1px 0 rgba(255, 255, 255, 0.2);
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  position: relative;
  z-index: 2;
}

.skill-card:hover .skill-icon {
  transform: scale(1.12) rotate(-5deg);
  box-shadow: 
    0 12px 32px rgba(0, 0, 0, 0.25),
    inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.skill-glow {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 100px;
  height: 100px;
  background: radial-gradient(circle, 
    color-mix(in srgb, var(--brand) 25%, transparent),
    transparent 70%
  );
  opacity: 0;
  transition: opacity 0.4s ease;
  z-index: 1;
  pointer-events: none;
}

.skill-card:hover .skill-glow {
  opacity: 1;
}

/* Content section */
.skill-content {
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.skill-name {
  font-size: 1.22rem;
  font-weight: 800;
  color: var(--text);
  margin: 0;
  letter-spacing: -0.01em;
  transition: color 0.3s ease;
}

.skill-card:hover .skill-name {
  color: var(--brand);
}

.skill-category {
  font-size: 0.82rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  opacity: 0.75;
  transition: all 0.3s ease;
}

.skill-card:hover .skill-category {
  opacity: 1;
}

/* Progress section */
.skill-progress {
  display: flex;
  align-items: center;
  gap: 14px;
}

.progress-bar {
  flex: 1;
  height: 10px;
  background: color-mix(in srgb, var(--text) 8%, transparent);
  border-radius: 999px;
  overflow: hidden;
  position: relative;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1);
}

.progress-fill {
  height: 100%;
  width: var(--value, 0%);
  background: linear-gradient(90deg, var(--brand), var(--brand-4), var(--brand-2));
  border-radius: 999px;
  position: relative;
  transition: width 1s cubic-bezier(0.34, 1.56, 0.64, 1);
  box-shadow: 0 2px 8px color-mix(in srgb, var(--brand) 30%, transparent);
}

.progress-shine {
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.4),
    transparent
  );
  animation: progress-shine 2s ease-in-out infinite;
}

@keyframes progress-shine {
  0% { left: -100%; }
  50%, 100% { left: 200%; }
}

.skill-percent {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 52px;
  padding: 6px 12px;
  font-size: 0.92rem;
  font-weight: 900;
  background: linear-gradient(135deg, var(--brand), var(--brand-4));
  color: #ffffff;
  border-radius: 12px;
  box-shadow: 
    0 4px 12px color-mix(in srgb, var(--brand) 25%, transparent),
    inset 0 1px 0 rgba(255, 255, 255, 0.25);
  transition: all 0.3s ease;
  letter-spacing: -0.02em;
}

.skill-card:hover .skill-percent {
  transform: scale(1.08);
  box-shadow: 
    0 6px 16px color-mix(in srgb, var(--brand) 35%, transparent),
    inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

/* Responsive adjustments */
@media (max-width: 1400px) {
  .competences-grid {
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 24px;
  }
}

@media (max-width: 1000px) {
  .competences-grid {
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 20px;
  }
  
  .skill-card {
    padding: 24px 20px;
  }
  
  .skill-icon-wrapper,
  .skill-icon {
    width: 64px;
    height: 64px;
  }
  
  .skill-name {
    font-size: 1.12rem;
  }
}

@media (max-width: 760px) {
  .competences-grid {
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 18px;
  }
  
  .skill-card {
    padding: 20px 16px;
  }
  
  .skill-icon-wrapper,
  .skill-icon {
    width: 56px;
    height: 56px;
  }
  
  .skill-name {
    font-size: 1.05rem;
  }
  
  .progress-bar {
    height: 8px;
  }
  
  .skill-percent {
    min-width: 48px;
    padding: 5px 10px;
    font-size: 0.85rem;
  }
}

@media (max-width: 480px) {
  .competences-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
}

/* ========================================
   END COMPETENCES GRID
   ======================================== */

/* Center the filter buttons row */
#competences .filters, #outils .filters { display: flex; justify-content: center; gap: 12px; margin: 14px 0 6px; flex-wrap: wrap; }

.tools { display: grid; /* 5 cards per row on wide screens */ grid-template-columns: repeat(5, minmax(220px, 1fr)); gap: 28px; align-items: start; }
.tool-item { 
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  position: relative;
  padding: 28px 20px;
  background: linear-gradient(145deg, 
    color-mix(in srgb, var(--card) 100%, white 15%),
    color-mix(in srgb, var(--card) 100%, white 8%));
  border: 1px solid color-mix(in srgb, var(--text) 6%, transparent);
  border-radius: 16px;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
  cursor: pointer;
}

.tool-item:hover {
  transform: translateY(-8px);
  border-color: color-mix(in srgb, var(--brand) 30%, transparent);
  box-shadow: 
    0 12px 32px rgba(0, 0, 0, 0.1),
    0 4px 12px rgba(0, 0, 0, 0.06);
  background: linear-gradient(145deg, 
    color-mix(in srgb, var(--card) 100%, white 18%),
    color-mix(in srgb, var(--card) 100%, white 10%));
}

.tools .card.project { display: flex; flex-direction: column; gap: 18px; padding: 28px; align-items: flex-start; min-height: 380px; position: relative; overflow: hidden; background: var(--card); border: 1px solid color-mix(in srgb, var(--text) 8%, transparent); border-radius: 14px; width: 100%; }
.tools .skill-icon, .tools .tool-icon { 
  width: 72px; 
  height: 72px; 
  border-radius: 16px; 
  display: inline-flex; 
  align-items: center; 
  justify-content: center; 
  font-size: 36px; 
  background: linear-gradient(135deg, 
    rgba(var(--brand-rgb), 0.08) 0%,
    rgba(var(--brand-2-rgb), 0.12) 100%);
  border: 1px solid rgba(var(--brand-rgb), 0.15);
  box-shadow: 0 2px 8px rgba(var(--brand-rgb), 0.06);
  transition: all 0.3s ease;
  object-fit: cover;
}

.tool-item:hover .skill-icon,
.tool-item:hover .tool-icon {
  transform: translateY(-3px);
  border-color: rgba(var(--brand-rgb), 0.3);
  box-shadow: 0 6px 18px rgba(var(--brand-rgb), 0.15);
  background: linear-gradient(135deg, 
    rgba(var(--brand-rgb), 0.12) 0%,
    rgba(var(--brand-2-rgb), 0.16) 100%);
}

.tools .tool-name { 
  font-weight: 700; 
  margin-top: 16px;
  font-size: 1.05rem;
  color: var(--text);
  transition: color 0.3s ease;
}

.tool-item:hover .tool-name {
  color: var(--brand);
}

.tools .bar { 
  width: 90%; 
  height: 12px; 
  border-radius: 999px; 
  overflow: hidden;
  background: color-mix(in srgb, var(--text) 8%, transparent);
  margin-top: 20px;
  position: relative;
}

.tools .bar > span { 
  height: 100%; 
  display: block; 
  background: linear-gradient(90deg, 
    var(--brand) 0%, 
    var(--brand-2) 50%,
    var(--brand-3) 100%); 
  width: var(--value, 50%);
  border-radius: 999px;
  transition: all 0.4s ease;
}

.tool-item:hover .bar > span {
  background: linear-gradient(90deg, 
    var(--brand-2) 0%, 
    var(--brand-3) 50%,
    var(--brand) 100%);
}

/* Slightly larger bars and more internal space for tools/cards so the
   percentage can sit comfortably under the bar without shifting the grid */
.tools .tool-item { padding: 28px 20px; }
.tools .card.project { padding: 32px; }

/* Percentage label under the bar for tools/competences */
.tools .percent {
  display: block;
  margin-top: 8px;
  text-align: center;
  font-weight: 800;
  color: var(--text);
  background: transparent;
  font-size: 0.95rem;
}

/* Percent badge: uniform brand color for all */
.tools .percent {
  display: inline-block;
  padding: 6px 10px;
  border-radius: 999px;
  font-weight: 800;
  font-size: 0.95rem;
  color: #ffffff;
  background: linear-gradient(135deg, var(--brand) 0%, var(--brand-2) 100%);
  box-shadow: 0 6px 18px rgba(56, 189, 248, 0.2);
  min-width: 48px;
  text-align: center;
  transition: transform .28s cubic-bezier(.2,.9,.26,1), opacity .28s ease;
  transform: translateY(6px);
  opacity: 0;
}

/* Visible state triggers the simple rise + fade-in animation */
.tools .percent.visible {
  transform: translateY(0);
  opacity: 1;
}

/* Category hover effects */
.tool-item[data-type="r"]:hover {
  border-color: var(--brand);
}

.tool-item[data-type="r"] .tools .skill-icon,
.tool-item[data-type="r"] .tools .tool-icon {
  border-color: rgba(56, 189, 248, 0.3);
  background: linear-gradient(135deg, 
    rgba(56, 189, 248, 0.1) 0%,
    rgba(124, 58, 237, 0.15) 100%);
}

.tool-item[data-type="r"]:hover .tools .skill-icon,
.tool-item[data-type="r"]:hover .tools .tool-icon {
  border-color: var(--brand);
  background: linear-gradient(135deg, 
    rgba(56, 189, 248, 0.15) 0%,
    rgba(124, 58, 237, 0.2) 100%);
}

.tool-item[data-type="d"]:hover {
  border-color: var(--brand);
}

.tool-item[data-type="d"] .tools .skill-icon,
.tool-item[data-type="d"] .tools .tool-icon {
  border-color: rgba(56, 189, 248, 0.3);
  background: linear-gradient(135deg, 
    rgba(56, 189, 248, 0.1) 0%,
    rgba(124, 58, 237, 0.15) 100%);
}

.tool-item[data-type="d"]:hover .tools .skill-icon,
.tool-item[data-type="d"]:hover .tools .tool-icon {
  border-color: var(--brand);
  background: linear-gradient(135deg, 
    rgba(56, 189, 248, 0.15) 0%,
    rgba(124, 58, 237, 0.2) 100%);
}

/* ensure cards stack correctly and avoid overlap; lift hovered card */
.tools .card.project { z-index: 0; }
.tools .card.project:hover { z-index: 5; transform: translateY(-6px); box-shadow: 0 30px 80px rgba(2,6,23,0.6); }

/* Tool items animation on appear */
.tool-item {
  animation: tool-appear 0.6s ease-out backwards;
}

@keyframes tool-appear {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.tool-item:nth-child(1) { animation-delay: 0.05s; }
.tool-item:nth-child(2) { animation-delay: 0.1s; }
.tool-item:nth-child(3) { animation-delay: 0.15s; }
.tool-item:nth-child(4) { animation-delay: 0.2s; }
.tool-item:nth-child(5) { animation-delay: 0.25s; }
.tool-item:nth-child(6) { animation-delay: 0.3s; }
.tool-item:nth-child(7) { animation-delay: 0.35s; }
.tool-item:nth-child(8) { animation-delay: 0.4s; }
.tool-item:nth-child(9) { animation-delay: 0.45s; }
.tool-item:nth-child(10) { animation-delay: 0.5s; }
.tool-item:nth-child(11) { animation-delay: 0.55s; }
.tool-item:nth-child(12) { animation-delay: 0.6s; }
.tool-item:nth-child(13) { animation-delay: 0.65s; }
.tool-item:nth-child(14) { animation-delay: 0.7s; }
.tool-item:nth-child(15) { animation-delay: 0.75s; }
.tool-item:nth-child(16) { animation-delay: 0.8s; }
.tool-item:nth-child(17) { animation-delay: 0.85s; }
.tool-item:nth-child(18) { animation-delay: 0.9s; }
.tool-item:nth-child(19) { animation-delay: 0.95s; }
.tool-item:nth-child(20) { animation-delay: 1s; }
.tool-item:nth-child(21) { animation-delay: 1.05s; }
.tool-item:nth-child(22) { animation-delay: 1.1s; }
.tool-item:nth-child(23) { animation-delay: 1.15s; }
.tool-item:nth-child(24) { animation-delay: 1.2s; }
.tool-item:nth-child(25) { animation-delay: 1.25s; }
.tool-item:nth-child(26) { animation-delay: 1.3s; }
.tool-item:nth-child(27) { animation-delay: 1.35s; }

/* === Skill Categories Styling === */
.skills-categories {
  margin-top: 40px;
}

.skill-category {
  margin-bottom: 40px;
  padding: 28px;
  border-radius: 16px;
  background: var(--card);
  border: 1px solid color-mix(in srgb, var(--text) 8%, transparent);
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.skill-category:hover {
  transform: translateY(-2px);
  border-color: color-mix(in srgb, var(--brand) 15%, transparent);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
}

.category-header {
  margin-bottom: 24px;
  padding-bottom: 12px;
  border-bottom: 1px solid color-mix(in srgb, var(--text) 8%, transparent);
}

.category-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.5rem;
  font-weight: 700;
  margin: 0;
  color: var(--text);
}

.category-icon {
  font-size: 1.5rem;
  opacity: 0.9;
}

.skill-category .grid.tools {
  margin-top: 0;
}

/* === Parcours Section in Profil === */
.parcours-section {
  margin-top: 80px;
  margin-bottom: 60px;
}

.parcours-header {
  text-align: center;
  margin-bottom: 48px;
}

.parcours-main-title {
  font-size: clamp(2.5rem, 5vw, 3.5rem);
  font-weight: 800;
  margin: 16px 0 24px;
  background: linear-gradient(135deg, var(--brand), var(--brand-4));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

@media (max-width: 860px) {
  .skill-category {
    padding: 24px;
    margin-bottom: 40px;
  }
  
  .category-title {
    font-size: 1.5rem;
  }
  
  .category-icon {
    font-size: 1.6rem;
  }
  
  .parcours-section {
    margin-top: 60px;
  }
}

.tool-item:nth-child(28) { animation-delay: 1.4s; }
.tool-item:nth-child(29) { animation-delay: 1.45s; }
.tool-item:nth-child(30) { animation-delay: 1.5s; }

@keyframes tool-appear {
  from {
    opacity: 0;
    transform: translateY(40px) scale(0.9) rotateX(-10deg);
    filter: blur(4px);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1) rotateX(0deg);
    filter: blur(0);
  }
}

/* Remove misleading "clickable entire card" cursor; only explicit buttons open content */
.tools .card.project:focus { outline: 2px solid color-mix(in srgb, var(--brand) 30%, transparent); outline-offset: 4px; }

@media (max-width: 1400px) {
  /* 4 columns on large but not huge screens */
  .tools { grid-template-columns: repeat(4, minmax(200px, 1fr)); gap: 24px; }
}

@media (max-width: 1000px) {
  /* 3 columns on medium screens */
  .tools { grid-template-columns: repeat(3, minmax(180px, 1fr)); gap: 20px; }
  .tools .card.project { padding: 20px; min-height: 320px; }
}

@media (max-width: 760px) {
  /* 2 columns on small screens */
  .tools { grid-template-columns: repeat(2, minmax(160px, 1fr)); gap: 18px; }
  .tools .card.project { padding: 14px; min-height: 220px; }
  .tools .skill-icon, .tools .tool-icon { 
    width: 64px; 
    height: 64px; 
    font-size: 28px;
    border-radius: 16px;
  }
  .tools .tool-name { 
    font-size: 1rem;
    margin-top: 14px;
  }
  .tools .bar { 
    height: 12px;
    width: 100%;
    margin-top: 16px;
  }
  .tool-item { 
    padding: 24px 16px;
    border-radius: 20px;
  }
  .pill.project-filter { 
    padding: 12px 24px; 
    font-size: 0.9rem;
    border-radius: 14px;
  }
}

@media (max-width: 480px) {
  /* single column on very small screens */
  .tools { grid-template-columns: 1fr; gap: 16px; }
  .tool-item { 
    padding: 28px 20px;
    border-radius: 18px;
  }
  .tools .skill-icon, .tools .tool-icon { 
    width: 72px; 
    height: 72px; 
    font-size: 32px;
  }
  .tools .tool-name { 
    font-size: 1.1rem;
  }
  .pill.project-filter { 
    padding: 10px 20px; 
    font-size: 0.9rem;
    border-radius: 12px;
  }
}

/* space between section title and the small counter */
/* larger, more visible gap between section title and the small counter */
#competences .section-title + .muted.small,
#outils .section-title + .muted.small,
#projectCount,
#projectCountCompetences,
#projectCountOutils {
  display: block;
  margin: 16px 0;
  text-align: center;
  font-size: 0.9rem;
  color: var(--muted);
  font-weight: 500;
}
.grid { display: grid; gap: 16px; }
.card { background: var(--card); border: 1px solid color-mix(in srgb, var(--text) 10%, transparent); border-radius: 12px; padding: 16px; }
.muted { color: var(--muted); }

/* Compétences */
.skills { grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); }
.skill { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.skill-title { display: inline-flex; align-items: center; gap: 8px; }
.skill-icon { width: 22px; height: 22px; display: inline-block; }
.bar { height: 8px; width: 56%; background: color-mix(in srgb, var(--text) 10%, transparent); border-radius: 999px; overflow: hidden; }
.bar > span { display: block; height: 100%; background: linear-gradient(90deg, var(--brand), var(--brand-4)); width: var(--value, 50%); }

/* Projets - 3 colonnes max */
.projects { 
  grid-template-columns: repeat(auto-fit, minmax(340px, 1fr)); 
  max-width: 1400px;
  margin: 0 auto;
}
.project .thumb { aspect-ratio: 16 / 9; border-radius: 10px; background: linear-gradient(135deg, color-mix(in srgb, var(--brand) 22%, var(--card)), var(--card)); border: 1px solid color-mix(in srgb, var(--text) 10%, transparent); margin-bottom: 10px; }

/* ==================================================================== */
/* Veille page styles (moved from veille.html)                            */
/* ==================================================================== */
/* ===================================
   VEILLE PAGE PREMIUM STYLES
   =================================== */

.veille-container { 
  max-width: 1200px; 
  margin: 0 auto; 
  padding: 2rem 1rem; 
}

/* Veille Hero Section */
.veille-hero { 
  display: grid; 
  grid-template-columns: 1fr 400px; 
  gap: 3rem; 
  align-items: center;
  margin-bottom: 3rem;
}

.veille-header-content {
  position: relative;
}

.veille-title {
  font-size: 2.5rem;
  font-weight: 800;
  margin: 0 0 0.5rem;
  background: linear-gradient(135deg, var(--text), color-mix(in srgb, var(--text) 70%, var(--brand)));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.veille-subtitle {
  font-size: 1.3rem;
  font-weight: 600;
  margin: 0 0 1rem;
  color: var(--brand);
}

.veille-hero p.lead { 
  margin: 0 0 2rem; 
  color: var(--muted); 
  line-height: 1.6;
  font-size: 1rem;
}

/* Veille Stats Grid */
.veille-stats { 
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin: 2rem 0;
}

.veille-stat { 
  display: flex;
  align-items: center;
  gap: 1rem;
  background: rgba(var(--card-rgb), 0.6);
  backdrop-filter: blur(10px);
  padding: 1rem;
  border-radius: 12px;
  border: 1px solid rgba(var(--brand-rgb), 0.15);
  transition: all 0.3s ease;
  animation: stat-appear 0.6s ease-out backwards;
}

.veille-stat:nth-child(1) { animation-delay: 0.1s; }
.veille-stat:nth-child(2) { animation-delay: 0.15s; }
.veille-stat:nth-child(3) { animation-delay: 0.2s; }
.veille-stat:nth-child(4) { animation-delay: 0.25s; }
.veille-stat:nth-child(5) { animation-delay: 0.3s; }
.veille-stat:nth-child(6) { animation-delay: 0.35s; }

@keyframes stat-appear {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.veille-stat:hover {
  transform: translateY(-4px);
  border-color: rgba(var(--brand-rgb), 0.3);
  box-shadow: 0 8px 24px rgba(var(--brand-rgb), 0.15);
}

.stat-icon {
  font-size: 2rem;
  flex-shrink: 0;
}

.stat-content {
  display: flex;
  flex-direction: column;
  gap: 0.125rem;
}

.stat-number { 
  font-weight: 800; 
  color: var(--brand); 
  display: block;
  font-size: 1.5rem;
  line-height: 1;
}

.stat-label {
  font-size: 0.85rem;
  color: var(--muted);
  font-weight: 500;
}

/* Hero Badges */
.hero-badges { 
  display: flex; 
  gap: 0.75rem; 
  flex-wrap: wrap;
  margin-top: 2rem;
}

.badge-link {
  text-decoration: none;
  transition: transform 0.3s ease;
}

.badge-link:hover {
  transform: translateY(-2px);
}

.hero-badges .badge { 
  padding: 0.5rem 1rem;
  background: rgba(var(--brand-rgb), 0.1);
  border: 1px solid rgba(var(--brand-rgb), 0.25);
  border-radius: 999px;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text);
  transition: all 0.3s ease;
  cursor: pointer;
}

.hero-badges .badge:hover {
  background: rgba(var(--brand-rgb), 0.2);
  border-color: var(--brand);
  box-shadow: 0 4px 12px rgba(var(--brand-rgb), 0.2);
}

/* Preview Image */
.preview {
  position: relative;
}

.preview-image {
  position: relative;
  border-radius: 20px;
  overflow: hidden;
  border: 2px solid rgba(var(--brand-rgb), 0.2);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  transition: all 0.4s ease;
}

.preview-image:hover {
  transform: scale(1.02);
  box-shadow: 0 25px 70px rgba(var(--brand-rgb), 0.3);
}

.preview-image img {
  width: 100%;
  height: auto;
  display: block;
}

/* Preview Images Column - 3 images empilées */
.preview-images-column {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.preview-image-item {
  position: relative;
  overflow: hidden;
  flex: 1;
  border-left: 2px solid rgba(var(--brand-rgb), 0.3);
  transition: all 0.3s ease;
}

.preview-image-item:first-child {
  border-top-left-radius: 20px;
  border-top-right-radius: 20px;
  border-top: 2px solid rgba(var(--brand-rgb), 0.3);
}

.preview-image-item:last-child {
  border-bottom-left-radius: 20px;
  border-bottom-right-radius: 20px;
  border-bottom: 2px solid rgba(var(--brand-rgb), 0.3);
}

.preview-image-item:not(:last-child) {
  border-bottom: 1px solid rgba(var(--brand-rgb), 0.15);
}

.preview-image-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease, filter 0.3s ease;
  filter: brightness(0.95);
}

.preview-image-item:hover img {
  transform: scale(1.05);
  filter: brightness(1.05);
}

.preview-images-column {
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  border-radius: 20px;
  border-right: 2px solid rgba(var(--brand-rgb), 0.3);
}

/* Colonnes latérales pour pilotes et circuits */
.veille-sidebar-columns {
  position: fixed !important;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  pointer-events: none;
  z-index: 1000;
  transform: none !important;
  animation: none !important;
  transition: none !important;
  opacity: 1 !important;
}

.veille-sidebar-columns * {
  transform: none !important;
  animation: none !important;
  transition: opacity 0.3s ease, transform 0.3s ease !important;
}

.veille-sidebar-columns > * {
  pointer-events: auto;
}

.veille-sidebar {
  position: fixed !important;
  top: 120px;
  width: 140px;
  max-height: calc(100vh - 160px);
  overflow-y: auto;
  padding: 16px 12px;
  background: rgba(var(--card-rgb), 0.6);
  backdrop-filter: blur(10px);
  border-radius: 16px;
  border: 1px solid rgba(var(--brand-rgb), 0.2);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
  z-index: 1001;
  scrollbar-width: thin;
  scrollbar-color: rgba(var(--brand-rgb), 0.3) transparent;
  will-change: auto;
}

/* Force stable positioning */
body.transitioning .veille-sidebar-columns,
body.transitioning .veille-sidebar,
body.transitioning .sidebar-lightbox {
  transform: none !important;
  animation: none !important;
  opacity: 1 !important;
}

.veille-sidebar::-webkit-scrollbar {
  width: 6px;
}

.veille-sidebar::-webkit-scrollbar-track {
  background: transparent;
}

.veille-sidebar::-webkit-scrollbar-thumb {
  background: rgba(var(--brand-rgb), 0.3);
  border-radius: 3px;
}

.veille-sidebar::-webkit-scrollbar-thumb:hover {
  background: rgba(var(--brand-rgb), 0.5);
}

.veille-sidebar-left {
  left: 20px;
}

.veille-sidebar-right {
  right: 20px;
}

.sidebar-title {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--brand);
  margin: 0 0 12px 0;
  text-align: center;
  padding-bottom: 8px;
  border-bottom: 2px solid rgba(var(--brand-rgb), 0.3);
}

.sidebar-images-grid {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.sidebar-image-item {
  position: relative;
  overflow: hidden;
  border-radius: 8px;
  cursor: pointer;
  border: 1px solid rgba(var(--brand-rgb), 0.2);
  transition: all 0.3s ease;
  aspect-ratio: 1;
}

.sidebar-image-item:hover {
  transform: scale(1.05);
  border-color: rgba(var(--brand-rgb), 0.5);
  box-shadow: 0 4px 12px rgba(var(--brand-rgb), 0.3);
}

.sidebar-image-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.3s ease;
}

.sidebar-image-item:hover img {
  transform: scale(1.1);
}

/* Sidebar Lightbox - renamed to avoid conflicts */
.sidebar-lightbox {
  display: none;
  position: fixed !important;
  z-index: 99999 !important;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.95);
  backdrop-filter: blur(10px);
  align-items: center;
  justify-content: center;
  flex-direction: column;
  transform: none !important;
  animation: none !important;
  transition: none !important;
  opacity: 1 !important;
}

.sidebar-lightbox * {
  transform: none !important;
  animation: none !important;
}

.sidebar-lightbox-content {
  max-width: 90%;
  max-height: 85vh;
  object-fit: contain;
  border-radius: 12px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
  animation: zoomIn 0.3s ease;
}

@keyframes zoomIn {
  from {
    transform: scale(0.8);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}

.sidebar-lightbox-close {
  position: absolute;
  top: 30px;
  right: 50px;
  color: #fff;
  font-size: 48px;
  font-weight: bold;
  cursor: pointer;
  transition: all 0.3s ease;
  z-index: 100000;
}

.sidebar-lightbox-close:hover {
  color: var(--brand);
  transform: scale(1.2) rotate(90deg);
}

.sidebar-lightbox-caption {
  margin-top: 20px;
  color: #fff;
  font-size: 1.1rem;
  text-align: center;
  padding: 12px 24px;
  background: rgba(var(--brand-rgb), 0.2);
  border-radius: 8px;
  backdrop-filter: blur(10px);
}

/* Original Lightbox for other uses */
.lightbox {
  display: none;
  position: fixed;
  z-index: 9999;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.95);
  backdrop-filter: blur(10px);
  animation: fadeIn 0.3s ease;
}

.lightbox.active {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.lightbox-content {
  max-width: 90%;
  max-height: 85vh;
  object-fit: contain;
  border-radius: 12px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
  animation: zoomIn 0.3s ease;
}

@keyframes zoomIn {
  from {
    transform: scale(0.8);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}

.lightbox-close {
  position: absolute;
  top: 30px;
  right: 50px;
  color: #fff;
  font-size: 48px;
  font-weight: bold;
  cursor: pointer;
  transition: all 0.3s ease;
  z-index: 10000;
}

.lightbox-close:hover {
  color: var(--brand);
  transform: scale(1.2) rotate(90deg);
}

.lightbox-caption {
  margin-top: 20px;
  color: #fff;
  font-size: 1.1rem;
  text-align: center;
  padding: 12px 24px;
  background: rgba(var(--brand-rgb), 0.2);
  border-radius: 8px;
  backdrop-filter: blur(10px);
}

/* Responsive */
@media (max-width: 1600px) {
  .veille-sidebar {
    width: 120px;
  }
  
  .veille-sidebar-left {
    left: 15px;
  }
  
  .veille-sidebar-right {
    right: 15px;
  }
}

@media (max-width: 1400px) {
  .veille-sidebar {
    display: none;
  }
}

/* Veille Grid */
.veille-grid { 
  display: grid; 
  grid-template-columns: 1fr 320px; 
  gap: 2rem; 
  margin-top: 2rem;
}

/* Card Styles */
.card { 
  background: rgba(var(--card-rgb), 0.6);
  backdrop-filter: blur(10px);
  padding: 1.5rem;
  border-radius: 16px;
  border: 1px solid rgba(var(--brand-rgb), 0.15);
  transition: all 0.3s ease;
}

.card:hover {
  border-color: rgba(var(--brand-rgb), 0.3);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}

.card h2 { 
  margin: 0 0 1rem;
  font-size: 1.4rem;
  font-weight: 700;
}

.card ul { 
  margin: 0; 
  padding-left: 1.5rem;
}

.card li {
  margin-bottom: 0.75rem;
  font-weight: 600;
}

.card li p {
  margin: 0.5rem 0 0;
  font-weight: 400;
  color: var(--muted);
}

/* Gallery */
.gallery { 
  display: grid; 
  grid-template-columns: repeat(2, 1fr); 
  gap: 1rem;
  margin-top: 1rem;
}

.gallery figure { 
  margin: 0; 
  border-radius: 12px; 
  overflow: hidden; 
  background: rgba(var(--card-rgb), 0.4);
  border: 1px solid rgba(var(--brand-rgb), 0.15);
  transition: all 0.3s ease;
  cursor: pointer;
}

.gallery figure:hover {
  transform: translateY(-4px);
  border-color: rgba(var(--brand-rgb), 0.3);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}

.gallery img { 
  width: 100%; 
  height: 180px; 
  object-fit: cover; 
  display: block;
  transition: transform 0.3s ease;
}

.gallery figure:hover img {
  transform: scale(1.05);
}

.gallery figcaption { 
  padding: 0.75rem; 
  font-size: 0.85rem; 
  color: var(--muted);
}

/* Sources Section */
.sources-category {
  margin-bottom: 24px;
}

.sources-subtitle {
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--text);
  margin: 0 0 16px;
  padding-bottom: 12px;
  border-bottom: 2px solid color-mix(in srgb, var(--brand) 20%, transparent);
  display: flex;
  align-items: center;
  gap: 8px;
}

.sources-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

#sources .tool-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem;
  border-radius: 12px;
  background: rgba(var(--card-rgb), 0.6);
  border: 1px solid rgba(var(--brand-rgb), 0.15);
  transition: all 0.3s ease;
  text-decoration: none;
  color: var(--text);
}

#sources .tool-item:hover {
  background: rgba(var(--card-rgb), 0.8);
  border-color: rgba(var(--brand-rgb), 0.3);
  transform: translateX(4px);
}

#sources .tool-item .skill-icon {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  object-fit: cover;
  display: block;
  flex-shrink: 0;
}

#sources .tool-item .tool-name { 
  font-weight: 600; 
  font-size: 0.95rem;
}

/* Responsive Design */
@media (max-width: 900px) { 
  .veille-hero { 
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  
  .preview-image {
    max-width: 500px;
    margin: 0 auto;
  }
  
  .veille-stats {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .veille-grid { 
    grid-template-columns: 1fr;
  }
  
  .gallery img { 
    height: 160px;
  }
}

@media (max-width: 520px) {
  .veille-container {
    padding: 1.5rem 1rem;
  }
  
  .veille-title {
    font-size: 2rem;
  }
  
  .veille-subtitle {
    font-size: 1.1rem;
  }
  
  .veille-stats { 
    grid-template-columns: 1fr;
    gap: 0.75rem;
  }
  
  .veille-stat {
    padding: 0.875rem;
  }
  
  .stat-number {
    font-size: 1.25rem;
  }
  
  .gallery {
    grid-template-columns: 1fr;
  }
}

/* end veille page styles */

/* Reveal animation used by the page's revealOnScroll logic */
.reveal { opacity: 0; transform: translateY(12px); transition: opacity .7s ease, transform .7s cubic-bezier(.2,.9,.26,1); will-change: opacity, transform; }
.reveal.visible { opacity: 1; transform: none; }

/* ===================================
   PROJECTS PAGE PREMIUM STYLES
   =================================== */

/* Projects Premium Header */
.projects-header {
  position: relative;
  text-align: center;
  padding: 2.5rem 2rem;
  margin-bottom: 2.5rem;
  background: var(--card);
  border-radius: 16px;
  border: 1px solid color-mix(in srgb, var(--text) 10%, transparent);
  overflow: hidden;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
}

.header-icon-badge {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  display: inline-block;
  animation: float 3s ease-in-out infinite;
}

@keyframes float {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-10px); }
}

.projects-title {
  font-size: 2.5rem;
  font-weight: 800;
  margin: 0 0 0.5rem;
  color: var(--text);
  position: relative;
  z-index: 1;
}

.header-subtitle {
  font-size: 1rem;
  color: var(--muted);
  margin-bottom: 1.5rem;
}

.projects-stats {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
  margin-top: 1.5rem;
  flex-wrap: wrap;
  position: relative;
  z-index: 1;
}

.stat-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
}

.stat-number {
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--brand);
}

.stat-label {
  font-size: 0.85rem;
  color: var(--muted);
  font-weight: 500;
}

.stat-divider {
  width: 1px;
  height: 40px;
  background: color-mix(in srgb, var(--text) 15%, transparent);
}

/* Project Cards - Same style as Certification Cards */
.project-card {
  display: flex;
  flex-direction: column;
  gap: 16px;
  transition: all var(--transition-base);
  position: relative;
  overflow: hidden;
}

.project-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--brand), var(--brand-4));
  opacity: 0;
  transition: opacity var(--transition-base);
}

.project-card:hover::before {
  opacity: 1;
}

.project-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(0,0,0,0.2);
}

.project-header {
  display: flex;
  gap: 16px;
  align-items: flex-start;
}

.project-icon {
  width: 56px;
  height: 56px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--brand), var(--brand-4));
  color: #0b1020;
  flex-shrink: 0;
}

.project-meta {
  flex: 1;
}

.project-view-btn {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  border: 1px solid color-mix(in srgb, var(--text) 15%, transparent);
  background: var(--card);
  color: var(--text);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  flex-shrink: 0;
}

.project-view-btn:hover {
  background: var(--brand);
  border-color: var(--brand);
  color: #ffffff;
  transform: scale(1.1);
}

.project-view-btn svg {
  pointer-events: none;
}

.project-meta h3 {
  font-size: 1.1rem;
  margin: 0 0 4px;
  font-weight: 700;
  line-height: 1.3;
}

.project-category {
  font-size: 0.85rem;
  color: var(--muted);
  font-weight: 500;
}

.project-body {
  flex: 1;
}

.project-thumb {
  width: 100%;
  height: 140px;
  border-radius: 12px;
  background-size: cover;
  background-position: center;
  margin-bottom: 16px;
  border: 1px solid color-mix(in srgb, var(--text) 8%, transparent);
}

/* Cartes sans texte - réduire la hauteur */
.project-card.no-text .project-thumb {
  height: 100px;
}

.project-body p {
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--muted);
  margin: 0 0 16px;
}

.project-skills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.project-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 12px;
  border-top: 1px solid color-mix(in srgb, var(--text) 8%, transparent);
}

.project-date {
  font-size: 0.85rem;
  color: var(--muted);
}

.project-status {
  padding: 4px 12px;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 600;
}

.status-progress {
  background: color-mix(in srgb, var(--warning) 15%, var(--card));
  color: var(--warning);
  border: 1px solid color-mix(in srgb, var(--warning) 25%, transparent);
}

.btn-link {
  font-size: 0.9rem;
  color: var(--brand);
  font-weight: 600;
  text-decoration: none;
  transition: all 0.3s ease;
}

.btn-link:hover {
  color: var(--brand-4);
  transform: translateX(4px);
}

/* Filters styling */
.filters {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin: 2rem 0 1rem;
  flex-wrap: wrap;
}

.pill.project-filter {
  position: relative;
  padding: 10px 24px;
  border-radius: 12px;
  border: 1px solid color-mix(in srgb, var(--text) 15%, transparent);
  background: var(--card);
  color: var(--text);
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.pill.project-filter:hover {
  transform: translateY(-2px);
  border-color: var(--brand);
  box-shadow: 
    0 6px 16px rgba(var(--brand-rgb), 0.15),
    0 2px 8px rgba(0, 0, 0, 0.1);
  color: var(--brand);
}

.pill.project-filter.active {
  background: linear-gradient(135deg, var(--brand) 0%, var(--brand-2) 100%);
  color: #ffffff;
  border-color: transparent;
  font-weight: 700;
  box-shadow: 
    0 8px 20px rgba(var(--brand-rgb), 0.4),
    0 4px 12px rgba(0, 0, 0, 0.15);
}

.pill.project-filter.active:hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 
    0 10px 28px rgba(var(--brand-rgb), 0.5),
    0 6px 16px rgba(0, 0, 0, 0.2);
}

@keyframes ripple-pulse {
  0%, 100% { 
    transform: translate(-50%, -50%) scale(1);
    opacity: 0.3;
  }
  50% { 
    transform: translate(-50%, -50%) scale(1.2);
    opacity: 0.6;
  }
}

@keyframes pulse-glow {
  0%, 100% { 
    box-shadow: 
      0 16px 50px rgba(var(--brand-rgb), 0.6),
      0 8px 25px rgba(var(--brand-rgb), 0.4),
      0 0 60px rgba(var(--brand-rgb), 0.3),
      0 0 0 6px rgba(var(--brand-rgb), 0.15),
      inset 0 3px 0 rgba(255, 255, 255, 0.4);
  }
  50% { 
    box-shadow: 
      0 20px 60px rgba(var(--brand-rgb), 0.7),
      0 10px 30px rgba(var(--brand-rgb), 0.5),
      0 0 80px rgba(var(--brand-rgb), 0.4),
      0 0 0 8px rgba(var(--brand-rgb), 0.2),
      inset 0 3px 0 rgba(255, 255, 255, 0.5);
  }
}

@keyframes gradient-shift-filter {
  0%, 100% { background-position: 0% center; }
  50% { background-position: 100% center; }
}

.pill.project-filter.active:hover {
  transform: translateY(-6px) scale(1.08);
  box-shadow: 
    0 20px 60px rgba(var(--brand-rgb), 0.7),
    0 10px 30px rgba(var(--brand-rgb), 0.5),
    0 0 80px rgba(var(--brand-rgb), 0.4),
    0 0 0 8px rgba(var(--brand-rgb), 0.2),
    inset 0 3px 0 rgba(255, 255, 255, 0.5);
}

/* Projects grid */
.projects {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 2rem;
}

/* Project cards animation */
.project-card {
  animation: project-appear 0.6s ease-out backwards;
}

.project-card:nth-child(1) { animation-delay: 0.05s; }
.project-card:nth-child(2) { animation-delay: 0.1s; }
.project-card:nth-child(3) { animation-delay: 0.15s; }
.project-card:nth-child(4) { animation-delay: 0.2s; }
.project-card:nth-child(5) { animation-delay: 0.25s; }
.project-card:nth-child(6) { animation-delay: 0.3s; }
.project-card:nth-child(7) { animation-delay: 0.35s; }
.project-card:nth-child(8) { animation-delay: 0.4s; }

@keyframes project-appear {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Shine effect on project thumbnails */
.project-thumb {
  position: relative;
  width: 100%;
  height: 200px;
  background: color-mix(in srgb, var(--text) 5%, var(--card));
  border-radius: 12px;
  overflow: hidden;
  margin-bottom: 12px;
  border: 1px solid color-mix(in srgb, var(--text) 8%, transparent);
}

.project-thumb::after {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 50%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.2),
    transparent
  );
  transition: left 0.6s ease;
}

.project-card:hover .project-thumb::after {
  left: 150%;
}

/* Responsive */
@media (max-width: 768px) {
  .projects-header {
    padding: 2rem 1.5rem;
  }
  
  .projects-title {
    font-size: 2rem;
  }
  
  .projects {
    grid-template-columns: 1fr;
  }
  
  .project-thumb {
    height: 160px;
  }
}

/* ===================================
   PARCOURS PAGE PREMIUM STYLES
   =================================== */

/* Parcours Premium Header */
.parcours-header {
  position: relative;
  text-align: center;
  padding: 4rem 3rem 3.5rem;
  margin-bottom: 3rem;
  background: 
    linear-gradient(135deg, 
      rgba(var(--brand-rgb), 0.08) 0%,
      rgba(var(--card-rgb), 0.6) 50%,
      rgba(var(--brand-2-rgb), 0.08) 100%);
  border-radius: 32px;
  border: 2px solid rgba(var(--brand-rgb), 0.2);
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2),
              0 0 0 1px rgba(255, 255, 255, 0.1) inset;
}

.parcours-header::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, 
    transparent 0%,
    var(--brand) 20%, 
    var(--brand-2) 50%, 
    var(--brand-3) 80%,
    transparent 100%);
  background-size: 200% 100%;
  animation: shimmer-flow 3s linear infinite;
  box-shadow: 0 0 20px rgba(var(--brand-rgb), 0.5);
}

@keyframes shimmer-flow {
  0% { background-position: -200% center; }
  100% { background-position: 200% center; }
}

.parcours-header::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(
    circle at 30% 50%,
    rgba(var(--brand-rgb), 0.1),
    transparent 60%
  ),
  radial-gradient(
    circle at 70% 50%,
    rgba(var(--brand-2-rgb), 0.1),
    transparent 60%
  );
  pointer-events: none;
  animation: glow-pulse 6s ease-in-out infinite;
}

@keyframes glow-pulse {
  0%, 100% { opacity: 0.5; }
  50% { opacity: 1; }
}

.header-float-decoration {
  position: absolute;
  top: 20px;
  right: 30px;
  width: 200px;
  height: 200px;
  background: radial-gradient(circle, 
    rgba(var(--brand-rgb), 0.2) 0%,
    rgba(var(--brand-2-rgb), 0.15) 40%,
    transparent 70%);
  border-radius: 50%;
  filter: blur(60px);
  animation: float-rotate 12s ease-in-out infinite;
  pointer-events: none;
}

@keyframes float-rotate {
  0%, 100% { 
    transform: translate(0, 0) rotate(0deg) scale(1); 
  }
  33% { 
    transform: translate(-30px, 30px) rotate(120deg) scale(1.2); 
  }
  66% { 
    transform: translate(20px, -20px) rotate(240deg) scale(0.9); 
  }
}

.header-icon-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 90px;
  height: 90px;
  background: linear-gradient(135deg, 
    rgba(var(--brand-rgb), 0.25), 
    rgba(var(--brand-2-rgb), 0.25));
  border: 3px solid rgba(var(--brand-rgb), 0.4);
  border-radius: 24px;
  font-size: 40px;
  margin: 0 auto 1.75rem;
  box-shadow: 
    0 10px 40px rgba(var(--brand-rgb), 0.3),
    0 0 0 6px rgba(var(--brand-rgb), 0.08),
    0 0 0 12px rgba(var(--brand-rgb), 0.04),
    inset 0 2px 0 rgba(255, 255, 255, 0.2);
  animation: pulse-badge-3d 4s ease-in-out infinite;
  position: relative;
  z-index: 1;
  backdrop-filter: blur(10px);
}

.header-icon-badge::before {
  content: '';
  position: absolute;
  inset: -3px;
  background: linear-gradient(135deg, var(--brand), var(--brand-2), var(--brand-3));
  border-radius: 24px;
  z-index: -1;
  opacity: 0;
  transition: opacity 0.4s ease;
  animation: rotate-border 8s linear infinite;
}

@keyframes rotate-border {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.header-icon-badge:hover::before {
  opacity: 0.6;
}

@keyframes pulse-badge-3d {
  0%, 100% { 
    transform: scale(1) translateY(0);
    box-shadow: 
      0 10px 40px rgba(var(--brand-rgb), 0.3),
      0 0 0 6px rgba(var(--brand-rgb), 0.08),
      0 0 0 12px rgba(var(--brand-rgb), 0.04);
  }
  50% { 
    transform: scale(1.08) translateY(-5px);
    box-shadow: 
      0 15px 50px rgba(var(--brand-rgb), 0.4),
      0 0 0 8px rgba(var(--brand-rgb), 0.12),
      0 0 0 16px rgba(var(--brand-rgb), 0.06);
  }
}

.parcours-title {
  font-size: 4.5rem;
  font-weight: 900;
  margin: 0 0 1rem;
  background: linear-gradient(135deg, 
    var(--brand) 0%, 
    var(--brand-2) 40%,
    var(--brand-3) 70%,
    var(--brand-2) 100%);
  background-size: 200% auto;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  position: relative;
  z-index: 1;
  letter-spacing: -1.5px;
  animation: title-gradient 5s ease-in-out infinite;
  filter: drop-shadow(0 8px 30px rgba(var(--brand-rgb), 0.5));
  text-shadow: 0 0 50px rgba(var(--brand-rgb), 0.4);
}

@keyframes title-gradient {
  0%, 100% { background-position: 0% center; }
  50% { background-position: 100% center; }
}

.header-subtitle {
  font-size: 1.2rem;
  color: color-mix(in srgb, var(--text) 70%, transparent);
  margin: 0 0 2.5rem;
  position: relative;
  z-index: 1;
  font-weight: 500;
  letter-spacing: 0.3px;
}

/* Parcours Stats Section */
.parcours-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.5rem;
  margin-top: 2rem;
  position: relative;
  z-index: 1;
}

.stat-item {
  position: relative;
  padding: 1.75rem 1.5rem;
  background: linear-gradient(135deg, 
    rgba(var(--card-rgb), 0.6) 0%,
    rgba(var(--card-rgb), 0.4) 100%);
  border: 1.5px solid rgba(var(--brand-rgb), 0.25);
  border-radius: 20px;
  text-align: center;
  backdrop-filter: blur(10px);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1),
              inset 0 1px 0 rgba(255, 255, 255, 0.1);
  overflow: hidden;
}

.stat-item::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--brand), var(--brand-2), var(--brand-3));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.stat-item:hover::before {
  transform: scaleX(1);
}

.stat-item:hover {
  transform: translateY(-5px);
  border-color: rgba(var(--brand-rgb), 0.5);
  box-shadow: 0 15px 40px rgba(var(--brand-rgb), 0.25),
              inset 0 1px 0 rgba(255, 255, 255, 0.15);
}

.stat-number {
  display: block;
  font-size: 2.75rem;
  font-weight: 900;
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1;
  margin-bottom: 0.75rem;
  filter: drop-shadow(0 2px 10px rgba(var(--brand-rgb), 0.3));
  transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.stat-item:hover .stat-number {
  transform: scale(1.1);
}

.stat-label {
  display: block;
  font-size: 0.875rem;
  color: color-mix(in srgb, var(--text) 70%, transparent);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.75px;
  line-height: 1.4;
  transition: color 0.3s ease;
}

.stat-item:hover .stat-label {
  color: var(--text);
}

.stat-divider {
  display: none;
}

/* Header Tags & Highlights */
.header-tags {
  display: flex;
  justify-content: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-top: 2rem;
  position: relative;
  z-index: 1;
}

.header-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.6rem 1.2rem;
  background: linear-gradient(135deg, 
    rgba(var(--brand-rgb), 0.15),
    rgba(var(--brand-2-rgb), 0.15));
  border: 1px solid rgba(var(--brand-rgb), 0.3);
  border-radius: 12px;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text);
  backdrop-filter: blur(10px);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.header-tag:hover {
  transform: translateY(-2px);
  background: linear-gradient(135deg, 
    rgba(var(--brand-rgb), 0.25),
    rgba(var(--brand-2-rgb), 0.25));
  border-color: rgba(var(--brand-rgb), 0.5);
  box-shadow: 0 8px 20px rgba(var(--brand-rgb), 0.2);
}

.header-tag .tag-icon {
  font-size: 1.1rem;
  line-height: 1;
}

/* Timeline Progress Bar */
.timeline-progress {
  position: relative;
  margin-top: 2.5rem;
  padding: 1.5rem;
  background: rgba(var(--card-rgb), 0.4);
  border-radius: 16px;
  border: 1px solid rgba(var(--brand-rgb), 0.2);
  backdrop-filter: blur(10px);
  z-index: 1;
}

.progress-label {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
  font-size: 0.9rem;
  font-weight: 600;
  color: color-mix(in srgb, var(--text) 80%, transparent);
}

.progress-bar-container {
  position: relative;
  height: 12px;
  background: rgba(var(--card-rgb), 0.6);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.2);
}

.progress-bar {
  height: 100%;
  background: linear-gradient(90deg, 
    var(--brand) 0%, 
    var(--brand-2) 50%,
    var(--brand-3) 100%);
  background-size: 200% 100%;
  border-radius: 8px;
  position: relative;
  animation: progress-shimmer 2s ease-in-out infinite;
  box-shadow: 0 0 15px rgba(var(--brand-rgb), 0.5);
}

.progress-bar::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(90deg,
    transparent 0%,
    rgba(255, 255, 255, 0.3) 50%,
    transparent 100%);
  animation: progress-flow 1.5s linear infinite;
}

@keyframes progress-shimmer {
  0%, 100% { background-position: 0% center; }
  50% { background-position: 100% center; }
}

@keyframes progress-flow {
  from { transform: translateX(-100%); }
  to { transform: translateX(100%); }
}

/* Column Headers with Icons */
.col-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 2px solid rgba(var(--brand-rgb), 0.2);
}

.col-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  background: linear-gradient(135deg, rgba(var(--brand-rgb), 0.15), rgba(var(--brand-2-rgb), 0.15));
  border: 1px solid rgba(var(--brand-rgb), 0.25);
  border-radius: 12px;
  font-size: 24px;
  flex-shrink: 0;
}

.col-header .parcours-section-title {
  margin: 0;
  font-size: 1.5rem;
  font-weight: 700;
}

/* Enhanced Parcours Cards */
.parcours-card {
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, 
    rgba(var(--card-rgb), 0.9) 0%, 
    rgba(var(--card-rgb), 0.8) 100%) !important;
  backdrop-filter: blur(15px);
  border: 1.5px solid rgba(var(--brand-rgb), 0.2) !important;
  border-radius: 18px !important;
  transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1),
              0 0 0 1px rgba(255, 255, 255, 0.08) inset;
  padding: 20px !important;
}

.parcours-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, 
    transparent 0%,
    var(--brand) 30%, 
    var(--brand-2) 70%,
    transparent 100%);
  opacity: 0;
  transition: opacity 0.35s ease;
}

.parcours-card:hover::before {
  opacity: 1;
}

.card-glow-effect {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 150%;
  height: 150%;
  background: radial-gradient(circle at center, 
    rgba(var(--brand-rgb), 0.08) 0%, 
    rgba(var(--brand-2-rgb), 0.05) 40%,
    transparent 70%);
  opacity: 0;
  transition: opacity 0.5s ease;
  transform: translate(-50%, -50%);
  pointer-events: none;
  z-index: 0;
}

.parcours-card:hover .card-glow-effect {
  opacity: 1;
}

.card-shine {
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(var(--brand-rgb), 0.12),
    transparent
  );
  transition: left 0.7s ease;
  pointer-events: none;
  z-index: 1;
}

.parcours-card:hover .card-shine {
  left: 100%;
}

.parcours-card:hover {
  transform: translateY(-5px);
  box-shadow: 
    0 15px 40px rgba(var(--brand-rgb), 0.2),
    0 8px 20px rgba(0, 0, 0, 0.15),
    0 0 0 1px rgba(var(--brand-rgb), 0.15) inset;
  border-color: rgba(var(--brand-rgb), 0.35) !important;
}

.experience-card:hover,
.formation-card:hover {
  transform: translateY(-6px) scale(1.01);
  box-shadow: 
    0 12px 40px rgba(var(--brand-rgb), 0.2),
    0 0 0 1px rgba(var(--brand-rgb), 0.1);
}

/* Company/School Info Section */
.company-info {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  margin: 1rem 0;
  padding: 0.75rem 1rem;
  background: linear-gradient(
    135deg,
    rgba(var(--brand-rgb), 0.08),
    rgba(var(--brand-2-rgb), 0.08)
  );
  border-left: 3px solid rgba(var(--brand-rgb), 0.4);
  border-radius: 8px;
  flex-wrap: wrap;
}

.company-name {
  font-weight: 700;
  font-size: 1rem;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.location {
  font-size: 0.9rem;
  color: color-mix(in srgb, var(--text) 70%, transparent);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* Enhanced Timeline Details */
.timeline-details {
  margin-top: 1rem;
}

.details-content {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.details-content p {
  margin: 0;
  padding: 0.5rem 0.75rem;
  background: rgba(var(--card-rgb), 0.5);
  border-left: 2px solid rgba(var(--brand-rgb), 0.3);
  border-radius: 6px;
  font-size: 0.95rem;
  line-height: 1.5;
}

.details-content strong {
  color: var(--brand);
  font-weight: 600;
}

/* Enhanced Badge Styles */
.parcours-badges .badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.4rem 0.9rem;
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 600;
}

.parcours-badges .badge.date {
  background: linear-gradient(135deg, rgba(var(--brand-rgb), 0.15), rgba(var(--brand-2-rgb), 0.15));
  border: 1px solid rgba(var(--brand-rgb), 0.3);
}

.parcours-badges .badge.status-obtenu {
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.25), rgba(220, 38, 38, 0.25));
  border: 1px solid rgba(239, 68, 68, 0.4);
  color: #ef4444;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
  .parcours-header {
    padding: 2.5rem 1.5rem;
  }
  
  .parcours-title {
    font-size: 2.5rem;
    letter-spacing: -0.5px;
  }
  
  .header-subtitle {
    font-size: 1rem;
  }
  
  .header-icon-badge {
    width: 70px;
    height: 70px;
    font-size: 32px;
  }
  
  .parcours-stats {
    gap: 1rem;
    grid-template-columns: 1fr;
  }
  
  .stat-item {
    padding: 1.25rem 1rem;
  }
  
  .stat-number {
    font-size: 2rem;
  }
  
  .header-tags {
    gap: 0.5rem;
  }
  
  .header-tag {
    padding: 0.5rem 1rem;
    font-size: 0.85rem;
  }
  
  .timeline-progress {
    padding: 1rem;
    margin-top: 2rem;
  }
  
  .progress-label {
    font-size: 0.8rem;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
  }
  
  .company-info {
    flex-direction: column;
    gap: 0.75rem;
    align-items: flex-start;
  }
  
  .col-header {
    gap: 0.75rem;
  }
  
  .col-icon {
    width: 40px;
    height: 40px;
    font-size: 20px;
  }
}

/* Gallery hover / focus polish */
.gallery figure { position: relative; overflow: hidden; cursor: zoom-in; }
.gallery img { transition: transform .28s ease, filter .28s ease, box-shadow .28s ease; }
.gallery figure:hover img, .gallery figure:focus img { transform: scale(1.04); filter: saturate(1.06); box-shadow: 0 18px 60px rgba(2,6,23,0.6); }
.gallery figure:focus { outline: 3px solid color-mix(in srgb, var(--brand) 20%, transparent); outline-offset: 6px; }

/* Make the small TOC inside the hero sticky to improve scanability */
.veil-toc { align-self: start; position: sticky; top: 22px; }

/* Tools thumb should look like project thumbs */
.tools .thumb { width: 100%; aspect-ratio: 16 / 9; border-radius: 12px; background-color: color-mix(in srgb, var(--card) 90%, transparent); border: 1px solid color-mix(in srgb, var(--text) 8%, transparent); margin-bottom: 12px; display: block; background-size: cover; background-position: center; }

/* If a thumb contains a simple emoji/icon (.tool-icon), center it without breaking image thumbs */
.tools .thumb:has(.tool-icon) { display: grid; place-items: center; background-size: auto 60%; }
.tools .thumb .tool-icon { font-size: 40px; line-height:1; }

.tools .tool-name { margin-top: 8px; }
.tools .thumb { margin-bottom: 16px; }

/* progress row: percent left, bar right (used in competence cards) */
.progress-row { display:flex; align-items:center; gap:12px; width:100%; }
.progress-row .percent { min-width:72px; text-align:left; font-weight:900; color: #071022; background: linear-gradient(135deg, #facc15, #f59e0b); padding:8px 12px; border-radius:12px; box-shadow: 0 6px 18px rgba(2,6,23,0.12); }
.progress-row .bar-wrap { flex:1; }
.progress-row .bar-wrap .bar { height:14px; border-radius:999px; overflow:hidden; background: color-mix(in srgb, var(--text) 6%, transparent); }
.progress-row .bar-wrap .bar > span { height:100%; display:block; background: linear-gradient(90deg, var(--brand), var(--brand-4)); width: var(--value,50%); }

/* Contact */
form { display: grid; gap: 12px; }
input, textarea { width: 100%; padding: 10px 12px; border-radius: 10px; border: 1px solid color-mix(in srgb, var(--text) 14%, transparent); background: transparent; color: var(--text); font: inherit; }
textarea { min-height: 120px; resize: vertical; }

/* ===========================
   PROFIL PAGE STYLES
   =========================== */

/* Premium Header for Profil Page */
.profil-header {
  position: relative;
  text-align: center;
  padding: 3.5rem 3rem 3rem;
  margin-bottom: 3rem;
  background: 
    radial-gradient(circle at top right, rgba(var(--brand-rgb), 0.12) 0%, transparent 50%),
    radial-gradient(circle at bottom left, rgba(var(--brand-2-rgb), 0.12) 0%, transparent 50%),
    linear-gradient(135deg, 
      rgba(var(--card-rgb), 0.85) 0%, 
      rgba(var(--card-rgb), 0.7) 50%,
      rgba(var(--card-rgb), 0.85) 100%);
  border-radius: 35px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.18);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.35),
              0 15px 40px rgba(var(--brand-rgb), 0.15),
              inset 0 1px 0 rgba(255, 255, 255, 0.15),
              inset 0 -1px 0 rgba(0, 0, 0, 0.2);
  /* NO animation - header stays static */
}

.profil-header::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, 
    transparent 0%,
    var(--brand) 10%, 
    var(--brand-2) 50%, 
    var(--brand-3) 90%,
    transparent 100%);
  /* NO animation - top line stays static */
  box-shadow: 0 2px 25px rgba(var(--brand-rgb), 0.6);
}

.header-float-decoration {
  position: absolute;
  top: 25px;
  right: 25px;
  width: 180px;
  height: 180px;
  background: radial-gradient(circle at center, 
    rgba(var(--brand-rgb), 0.18), 
    rgba(var(--brand-2-rgb), 0.12) 35%,
    rgba(var(--brand-3-rgb), 0.08) 60%,
    transparent 75%);
  border-radius: 50%;
  /* NO animation - decoration stays static */
  filter: blur(40px);
}

@keyframes float-pulse {
  0%, 100% { 
    transform: translateY(0px) scale(1); 
    opacity: 0.6; 
  }
  33% { 
    transform: translateY(-35px) scale(1.3); 
    opacity: 1; 
  }
  66% { 
    transform: translateY(-15px) scale(0.9); 
    opacity: 0.8; 
  }
}

.header-content {
  position: relative;
  z-index: 1;
  margin-bottom: 2rem;
}

.header-content .quality-photo {
  width: 125px;
  height: 125px;
  border-radius: 50%;
  overflow: hidden;
  margin: 0 auto 1.75rem;
  border: 5px solid rgba(var(--brand-rgb), 0.45);
  box-shadow: 0 20px 60px rgba(var(--brand-rgb), 0.45),
              0 10px 30px rgba(0, 0, 0, 0.35),
              0 0 0 10px rgba(var(--brand-rgb), 0.12),
              0 0 0 20px rgba(var(--brand-rgb), 0.06),
              inset 0 0 20px rgba(0, 0, 0, 0.2);
  background: linear-gradient(135deg, 
    rgba(var(--brand-rgb), 0.25), 
    rgba(var(--brand-2-rgb), 0.25));
  transition: all 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
  position: relative;
  /* NO animation - photo stays static */
}

.header-content .quality-photo::before {
  content: '';
  position: absolute;
  inset: -5px;
  border-radius: 50%;
  background: linear-gradient(135deg, 
    var(--brand) 0%, 
    var(--brand-2) 50%, 
    var(--brand-3) 100%);
  z-index: -1;
  opacity: 0;
  transition: opacity 0.6s ease;
  /* NO animation - border stays static */
}

.header-content .quality-photo:hover::before {
  opacity: 0.8;
}

.header-content .quality-photo:hover {
  transform: scale(1.15);
  border-width: 6px;
  box-shadow: 0 30px 80px rgba(var(--brand-rgb), 0.7),
              0 15px 40px rgba(var(--brand-2-rgb), 0.5),
              0 0 0 10px rgba(var(--brand-rgb), 0.25),
              0 0 0 20px rgba(var(--brand-rgb), 0.15),
              inset 0 0 30px rgba(255, 255, 255, 0.1);
}

.header-content .quality-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: all 0.6s ease;
}

.header-content .quality-photo:hover img {
  transform: scale(1.12) rotate(2deg);
  filter: brightness(1.15) contrast(1.1) saturate(1.1);
}

.header-icon-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 70px;
  height: 70px;
  margin-bottom: 1rem;
  font-size: 2rem;
  background: linear-gradient(135deg, rgba(var(--brand-rgb), 0.2), rgba(var(--brand-2-rgb), 0.2));
  border: 2px solid rgba(var(--brand-rgb), 0.3);
  border-radius: 50%;
  box-shadow: 0 5px 20px rgba(var(--brand-rgb), 0.3);
  /* Animation removed - icon stays static */
}

.profil-title {
  font-size: 2.3rem;
  font-weight: 900;
  margin-bottom: 0;
  background: linear-gradient(135deg, 
    var(--brand) 0%, 
    var(--brand-2) 50%,
    var(--brand-3) 100%);
  background-size: 200% auto;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: -0.4px;
  filter: drop-shadow(0 3px 15px rgba(var(--brand-rgb), 0.4));
  animation: color-shift 4s ease-in-out infinite;
}

@keyframes color-shift {
  0%, 100% { background-position: 0% center; }
  50% { background-position: 100% center; }
}

/* Section CV avec GIF et boutons */
.cv-section {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 2rem;
  align-items: center;
  margin-top: 2rem;
  padding: 2rem;
  background: linear-gradient(135deg, 
    rgba(var(--card-rgb), 0.4), 
    rgba(var(--card-rgb), 0.2));
  border-radius: 20px;
  border: 1px solid rgba(var(--brand-rgb), 0.2);
}

.cv-gif-container {
  width: 200px;
  height: 200px;
  border-radius: 20px;
  overflow: hidden;
  border: 3px solid rgba(var(--brand-rgb), 0.4);
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3),
              0 0 0 1px rgba(255, 255, 255, 0.1) inset;
  background: rgba(var(--card-rgb), 0.6);
  backdrop-filter: blur(10px);
}

.cv-gif {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.cv-buttons-container {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.cv-buttons-container .btn {
  width: 100%;
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1.5rem;
}

.cv-buttons-container .btn-icon {
  font-size: 1.25rem;
  flex-shrink: 0;
  min-width: 24px;
  text-align: center;
}

.cv-buttons-container .btn span:not(.btn-icon) {
  flex: 1;
}

.btn-view {
  background: transparent;
  color: var(--text);
  border: 2px solid transparent;
  background-image: 
    linear-gradient(var(--background), var(--background)),
    linear-gradient(135deg, var(--brand), var(--brand-2));
  background-origin: border-box;
  background-clip: padding-box, border-box;
}

.btn-view:hover {
  background-image: 
    linear-gradient(var(--background), var(--background)),
    linear-gradient(135deg, var(--brand), var(--brand-2));
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(var(--brand-rgb), 0.3);
}

.btn-download {
  background: linear-gradient(135deg, var(--brand), var(--brand-2)) !important;
  color: white !important;
  border: none !important;
}

.btn-download:hover {
  transform: translateY(-2px) !important;
  box-shadow: 0 8px 25px rgba(var(--brand-rgb), 0.4) !important;
}

.header-subtitle {
  font-size: 1rem;
  color: var(--muted);
  font-style: italic;
}

.stat-badges-container {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  justify-content: center;
  margin-top: 1.5rem;
}

.stat-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.6rem 1.2rem;
  background: linear-gradient(135deg, 
    rgba(var(--card-rgb), 0.85) 0%, 
    rgba(var(--card-rgb), 0.75) 100%);
  backdrop-filter: blur(20px);
  border: 1.5px solid rgba(var(--brand-rgb), 0.3);
  border-radius: 50px;
  font-weight: 600;
  font-size: 0.82rem;
  color: var(--text);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2),
              0 1px 3px rgba(0, 0, 0, 0.15),
              inset 0 1px 0 rgba(255, 255, 255, 0.08);
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
  position: relative;
  overflow: hidden;
}

.stat-badge::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, 
    rgba(var(--brand-rgb), 0.12), 
    rgba(var(--brand-2-rgb), 0.12));
  opacity: 0;
  transition: opacity 0.3s ease;
}

.stat-badge:hover::before {
  opacity: 1;
}

.stat-badge:hover {
  border-color: rgba(var(--brand-rgb), 0.5);
  box-shadow: 0 6px 24px rgba(var(--brand-rgb), 0.3),
              0 2px 6px rgba(0, 0, 0, 0.2),
              inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.stat-icon {
  font-size: 1.15rem;
  /* NO filter, NO transition, NO animation - completely static */
  flex-shrink: 0;
  position: relative;
  z-index: 1;
}

.stat-text {
  white-space: nowrap;
  position: relative;
  z-index: 1;
  letter-spacing: 0.015em;
  line-height: 1.3;
}

/* About Card */
.profil-card {
  position: relative;
  background: linear-gradient(135deg, 
    rgba(var(--card-rgb), 0.8) 0%,
    rgba(var(--card-rgb), 0.7) 30%,
    rgba(var(--card-rgb), 0.7) 70%,
    rgba(var(--card-rgb), 0.8) 100%);
  backdrop-filter: blur(28px);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 28px;
  padding: 0;
  margin-bottom: 2.5rem;
  overflow: hidden;
  box-shadow: 0 25px 70px rgba(0, 0, 0, 0.3),
              0 10px 30px rgba(0, 0, 0, 0.2),
              0 0 0 1px rgba(255, 255, 255, 0.08) inset;
  transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.profil-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.4),
              0 15px 40px rgba(var(--brand-rgb), 0.15),
              0 0 0 1px rgba(255, 255, 255, 0.12) inset;
  border-color: rgba(255, 255, 255, 0.2);
}

.profil-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, 
    transparent 0%,
    var(--brand) 15%, 
    var(--brand-2) 50%, 
    var(--brand-3) 85%,
    transparent 100%);
  background-size: 200% 100%;
  animation: shimmer 5s linear infinite;
  box-shadow: 0 0 15px rgba(var(--brand-rgb), 0.5);
}

.card-pattern {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: 
    radial-gradient(circle at 10% 15%, rgba(var(--brand-rgb), 0.06) 0%, transparent 50%),
    radial-gradient(circle at 90% 85%, rgba(var(--brand-2-rgb), 0.06) 0%, transparent 50%),
    radial-gradient(circle at 50% 50%, rgba(var(--brand-3-rgb), 0.03) 0%, transparent 60%);
  pointer-events: none;
  animation: pattern-shift 15s ease-in-out infinite;
}

@keyframes pattern-shift {
  0%, 100% { opacity: 0.5; }
  50% { opacity: 1; }
}

.card-glow {
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle at center, 
    rgba(var(--brand-rgb), 0.15) 0%, 
    rgba(var(--brand-2-rgb), 0.1) 30%,
    transparent 60%);
  opacity: 0;
  transition: opacity 0.7s ease;
  pointer-events: none;
}

.profil-card:hover .card-glow {
  opacity: 1;
  animation: rotate-glow 15s linear infinite;
}

@keyframes rotate-glow {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.card-border-glow {
  position: absolute;
  inset: -2px;
  border-radius: 24px;
  padding: 2px;
  background: linear-gradient(45deg, var(--brand), var(--brand-2), var(--brand-3));
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  mask-composite: exclude;
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

.profil-card:hover .card-border-glow {
  opacity: 0.6;
}

.card-content {
  position: relative;
  z-index: 1;
  padding: 2.75rem 3rem;
}

/* Info Badges */
.info-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.875rem;
  margin-bottom: 2rem;
  justify-content: center;
}

.info-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.65rem 1.15rem;
  background: rgba(var(--brand-rgb), 0.08);
  border: 1px solid rgba(var(--brand-rgb), 0.2);
  border-radius: 50px;
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text);
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.info-badge:hover {
  background: rgba(var(--brand-rgb), 0.15);
  border-color: rgba(var(--brand-rgb), 0.4);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(var(--brand-rgb), 0.2);
}

.badge-icon {
  font-size: 1.05rem;
}

.badge-text {
  font-weight: 500;
  letter-spacing: 0.01em;
}

/* Profile Intro */
.profil-intro {
  text-align: center;
  margin-bottom: 2.5rem;
  padding: 0 1rem;
}

.intro-text {
  font-size: 1.12rem;
  line-height: 1.85;
  margin-bottom: 0;
  color: rgba(var(--text-rgb), 0.95);
}

/* Content Grid */
.profil-content-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.content-block {
  position: relative;
  padding: 1.75rem;
  background: rgba(var(--card-rgb), 0.5);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  transition: all 0.3s ease;
}

.content-block:hover {
  background: rgba(var(--card-rgb), 0.7);
  border-color: rgba(var(--brand-rgb), 0.5);
  transform: translateY(-3px);
}

.block-icon {
  font-size: 2rem;
  margin-bottom: 1rem;
  filter: drop-shadow(0 0 10px rgba(var(--brand-rgb), 0.4));
}

.block-title {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
  color: var(--brand);
}

.content-block .profil-text {
  font-size: 1rem;
  line-height: 1.7;
  margin-bottom: 0;
}

/* Skills Tags */
.skills-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  justify-content: center;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.skill-tag {
  display: inline-block;
  padding: 0.5rem 1rem;
  background: linear-gradient(135deg, rgba(var(--brand-rgb), 0.15), rgba(var(--brand-2-rgb), 0.15));
  border: 1px solid rgba(var(--brand-rgb), 0.3);
  border-radius: 20px;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text);
  transition: all 0.3s ease;
  cursor: default;
}

.skill-tag:hover {
  background: linear-gradient(135deg, rgba(var(--brand-rgb), 0.25), rgba(var(--brand-2-rgb), 0.25));
  border-color: var(--brand);
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(var(--brand-rgb), 0.3);
}

.profil-text {
  font-size: 1.02rem;
  line-height: 1.85;
  margin-bottom: 1.5rem;
  color: rgba(var(--text-rgb), 0.92);
  letter-spacing: 0.01em;
}

.profil-text:last-child {
  margin-bottom: 0;
}

.profil-text strong {
  font-weight: 700;
  color: var(--text);
}

.highlight-name {
  font-weight: 700;
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  position: relative;
  display: inline-block;
  padding-bottom: 2px;
}

.highlight-name::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--brand), var(--brand-2), var(--brand-3));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.profil-text:hover .highlight-name::after {
  transform: scaleX(1);
}

.text-brand {
  color: var(--brand-2);
  font-weight: 600;
  position: relative;
  text-shadow: 0 0 20px rgba(var(--brand-2-rgb), 0.2);
}

/* Responsive adjustments for about card */
@media (max-width: 768px) {
  .card-content {
    padding: 2rem 1.75rem;
  }
  
  .profil-text {
    font-size: 0.98rem;
    line-height: 1.8;
  }
  
  .info-badges {
    gap: 0.7rem;
  }
  
  .info-badge {
    padding: 0.6rem 1rem;
    font-size: 0.85rem;
  }
  
  .intro-text {
    font-size: 1.05rem;
  }
}

@media (max-width: 480px) {
  .card-content {
    padding: 1.75rem 1.25rem;
  }
  
  .profil-text {
    font-size: 0.95rem;
    line-height: 1.75;
  }
  
  .info-badge {
    font-size: 0.82rem;
    padding: 0.55rem 0.9rem;
  }
  
  .intro-text {
    font-size: 1rem;
  }
  
  .profil-content-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
  
  .content-block {
    padding: 1.25rem;
  }
  
  .block-icon {
    font-size: 1.75rem;
  }
}

/* CV Download Button */
.cta-download {
  text-align: center;
  margin: 3rem 0;
}

.btn-download {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 2.5rem;
  font-size: 1.1rem;
  font-weight: 600;
  transition: all 0.3s ease;
}

.btn-download .btn-icon {
  font-size: 1.4rem;
  transition: transform 0.3s ease;
}

.btn-download:hover .btn-icon {
  transform: translateY(-3px);
}

/* ===========================
   QUALITIES SECTION
   =========================== */

.qualities-section {
  margin: 4rem 0;
  padding: 3.5rem 2rem;
  background: linear-gradient(135deg, 
    rgba(var(--brand-rgb), 0.04) 0%, 
    rgba(var(--brand-2-rgb), 0.06) 50%,
    rgba(var(--brand-rgb), 0.04) 100%);
  border-radius: 28px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  position: relative;
  overflow: hidden;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
}

.qualities-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, 
    var(--brand) 0%, 
    var(--brand-2) 25%,
    var(--brand-3) 50%, 
    var(--brand-2) 75%,
    var(--brand) 100%);
  background-size: 200% 100%;
  animation: shimmer 4s linear infinite;
}

.qualities-section::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(var(--brand-rgb), 0.08) 0%, transparent 70%);
  transform: translate(-50%, -50%);
  pointer-events: none;
  animation: pulse-glow 6s ease-in-out infinite;
}

@keyframes pulse-glow {
  0%, 100% { opacity: 0.5; transform: translate(-50%, -50%) scale(1); }
  50% { opacity: 1; transform: translate(-50%, -50%) scale(1.1); }
}

.qualities-header {
  text-align: center;
  margin-bottom: 3.5rem;
  position: relative;
  z-index: 1;
}

.qualities-icon-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 70px;
  height: 70px;
  margin-bottom: 1.5rem;
  font-size: 2rem;
  background: linear-gradient(135deg, 
    rgba(var(--brand-rgb), 0.25), 
    rgba(var(--brand-2-rgb), 0.25));
  border: 3px solid rgba(var(--brand-rgb), 0.4);
  border-radius: 50%;
  box-shadow: 
    0 5px 20px rgba(var(--brand-rgb), 0.4),
    inset 0 2px 10px rgba(255, 255, 255, 0.1);
  animation: pulse-badge 4s ease-in-out infinite;
  position: relative;
}

.qualities-icon-badge::before {
  content: '';
  position: absolute;
  inset: -3px;
  border-radius: 50%;
  background: linear-gradient(45deg, var(--brand), var(--brand-2), var(--brand-3));
  z-index: -1;
  animation: rotate-border 3s linear infinite;
  opacity: 0.6;
}

@keyframes rotate-border {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.qualities-title {
  font-size: 2.2rem;
  font-weight: 800;
  margin-bottom: 1rem;
  background: linear-gradient(135deg, var(--brand) 0%, var(--brand-2) 50%, var(--brand-3) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: -0.5px;
  text-shadow: 0 0 30px rgba(var(--brand-rgb), 0.5);
}

.qualities-subtitle {
  font-size: 1.1rem;
  color: var(--muted);
  font-style: italic;
  font-weight: 300;
}

.qualities-container {
  position: relative;
  max-width: 1200px;
  margin: 0 auto;
  z-index: 1;
}

.qualities-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 2.5rem;
}

.quality-bubble {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2rem 1.5rem;
  background: rgba(var(--card-rgb), 0.7);
  backdrop-filter: blur(15px);
  border: 2px solid rgba(255, 255, 255, 0.12);
  border-radius: 24px;
  transition: all 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
  cursor: pointer;
  overflow: hidden;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.quality-bubble::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, 
    rgba(var(--brand-rgb), 0.18) 0%, 
    rgba(var(--brand-2-rgb), 0.18) 100%);
  opacity: 0;
  transition: opacity 0.5s ease;
  border-radius: 26px;
}

.quality-bubble::after {
  content: '';
  position: absolute;
  inset: -2px;
  border-radius: 28px;
  background: linear-gradient(45deg, 
    transparent 30%, 
    rgba(var(--brand-rgb), 0.4) 50%, 
    transparent 70%);
  background-size: 200% 200%;
  opacity: 0;
  transition: opacity 0.5s ease;
  animation: shimmer-border 3s linear infinite;
}

@keyframes shimmer-border {
  0% { background-position: 200% 50%; }
  100% { background-position: -200% 50%; }
}

.bubble-shine {
  position: absolute;
  top: -100%;
  left: -100%;
  width: 300%;
  height: 300%;
  background: conic-gradient(
    from 0deg,
    transparent 0%,
    rgba(255, 255, 255, 0.15) 50%,
    transparent 100%
  );
  opacity: 0;
  transition: opacity 0.5s ease;
  pointer-events: none;
}

.quality-bubble:hover {
  transform: translateY(-15px) scale(1.05) rotateX(5deg);
  border-color: rgba(var(--brand-rgb), 0.7);
  box-shadow: 
    0 25px 60px rgba(var(--brand-rgb), 0.5),
    0 0 0 1px rgba(var(--brand-rgb), 0.3),
    inset 0 2px 20px rgba(var(--brand-rgb), 0.1);
}

.quality-bubble:hover::before {
  opacity: 1;
}

.quality-bubble:hover::after {
  opacity: 1;
}

.quality-bubble:hover .bubble-shine {
  opacity: 1;
  animation: shine-rotate 3s linear infinite;
}

@keyframes shine-rotate {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.quality-icon {
  position: relative;
  z-index: 1;
  font-size: 2.75rem;
  margin-bottom: 1rem;
  filter: drop-shadow(0 0 15px rgba(var(--brand-rgb), 0.6));
  transition: all 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.quality-photo {
  width: 70px;
  height: 70px;
  border-radius: 50%;
  overflow: hidden;
  margin: 0 auto 1rem;
  border: 3px solid rgba(var(--brand-rgb), 0.5);
  box-shadow: 0 0 25px rgba(var(--brand-rgb), 0.6);
  background: linear-gradient(135deg, rgba(var(--brand-rgb), 0.2), rgba(var(--brand-2-rgb), 0.2));
}

.quality-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: all 0.5s ease;
}

.quality-bubble:hover .quality-photo {
  transform: scale(1.15);
  border-color: var(--brand);
  box-shadow: 0 0 35px rgba(var(--brand-rgb), 1), 0 0 50px rgba(var(--brand-2-rgb), 0.5);
}

.quality-bubble:hover .quality-photo img {
  transform: scale(1.1);
  filter: brightness(1.1);
}

.quality-bubble:hover .quality-icon {
  transform: scale(1.35) rotateY(360deg);
  filter: drop-shadow(0 0 30px rgba(var(--brand-rgb), 1));
}

.quality-label {
  position: relative;
  z-index: 1;
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 0.6rem;
  transition: all 0.4s ease;
  letter-spacing: 0.3px;
}

.quality-bubble:hover .quality-label {
  color: var(--brand);
  transform: scale(1.08);
  text-shadow: 0 0 20px rgba(var(--brand-rgb), 0.6);
}

.quality-description {
  position: relative;
  z-index: 1;
  font-size: 0.875rem;
  color: var(--muted);
  text-align: center;
  line-height: 1.5;
  opacity: 0.75;
  transition: all 0.4s ease;
  max-width: 200px;
}

.quality-bubble:hover .quality-description {
  opacity: 1;
  color: var(--text);
  transform: translateY(2px);
}

/* Couleurs spécifiques pour chaque bulle avec dégradés */
.quality-bubble.discipline:hover {
  border-color: rgba(56, 189, 248, 0.7);
  box-shadow: 
    0 25px 60px rgba(56, 189, 248, 0.5),
    0 0 0 1px rgba(56, 189, 248, 0.3);
}

.quality-bubble.motivation:hover {
  border-color: rgba(124, 58, 237, 0.7);
  box-shadow: 
    0 25px 60px rgba(124, 58, 237, 0.5),
    0 0 0 1px rgba(124, 58, 237, 0.3);
}

.quality-bubble.rigoureux:hover {
  border-color: rgba(255, 255, 0, 0.7);
  box-shadow: 
    0 25px 60px rgba(255, 255, 0, 0.4),
    0 0 0 1px rgba(255, 255, 0, 0.3);
}

.quality-bubble.ecoute:hover {
  border-color: rgba(16, 185, 129, 0.7);
  box-shadow: 
    0 25px 60px rgba(16, 185, 129, 0.5),
    0 0 0 1px rgba(16, 185, 129, 0.3);
}

.quality-bubble.curieux:hover {
  border-color: rgba(245, 158, 11, 0.7);
  box-shadow: 
    0 25px 60px rgba(245, 158, 11, 0.5),
    0 0 0 1px rgba(245, 158, 11, 0.3);
}

.quality-bubble.creatif:hover {
  border-color: rgba(236, 72, 153, 0.7);
  box-shadow: 
    0 25px 60px rgba(236, 72, 153, 0.5),
    0 0 0 1px rgba(236, 72, 153, 0.3);
}

.quality-bubble.autodidacte:hover {
  border-color: rgba(99, 102, 241, 0.7);
  box-shadow: 
    0 25px 60px rgba(99, 102, 241, 0.5),
    0 0 0 1px rgba(99, 102, 241, 0.3);
}

.quality-bubble.perseverant:hover {
  border-color: rgba(239, 68, 68, 0.7);
  box-shadow: 
    0 25px 60px rgba(239, 68, 68, 0.5),
    0 0 0 1px rgba(239, 68, 68, 0.3);
}

/* Animation d'apparition des bulles améliorée */
@keyframes bubble-appear {
  from {
    opacity: 0;
    transform: translateY(50px) scale(0.85) rotateX(-15deg);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1) rotateX(0deg);
  }
}

.quality-bubble {
  animation: bubble-appear 0.8s ease-out backwards;
  perspective: 1000px;
}

.quality-bubble:nth-child(1) { animation-delay: 0.1s; }
.quality-bubble:nth-child(2) { animation-delay: 0.15s; }
.quality-bubble:nth-child(3) { animation-delay: 0.2s; }
.quality-bubble:nth-child(4) { animation-delay: 0.25s; }
.quality-bubble:nth-child(5) { animation-delay: 0.3s; }
.quality-bubble:nth-child(6) { animation-delay: 0.35s; }
.quality-bubble:nth-child(7) { animation-delay: 0.4s; }
.quality-bubble:nth-child(8) { animation-delay: 0.45s; }

/* Responsive adjustments */
@media (max-width: 1024px) {
  .qualities-grid {
    grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
    gap: 2rem;
  }
}

@media (max-width: 768px) {
  .qualities-section {
    padding: 2.5rem 1.5rem;
  }
  
  .qualities-header {
    margin-bottom: 2.5rem;
  }
  
  .qualities-title {
    font-size: 1.8rem;
  }
  
  .qualities-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
  }
  
  .quality-bubble {
    padding: 2rem 1.25rem;
  }
  
  .quality-icon {
    font-size: 2.75rem;
  }
  
  .quality-label {
    font-size: 1.1rem;
  }
  
  .quality-description {
    font-size: 0.85rem;
  }
}

@media (max-width: 480px) {
  .qualities-grid {
    grid-template-columns: 1fr;
  }
  
  .quality-bubble {
    padding: 2.25rem 1.75rem;
  }
  
  .quality-icon {
    font-size: 3rem;
  }
}

/* BTS Section */
.bts-info-section {
  text-align: center;
  margin: 4rem 0 3rem;
  padding: 2rem;
  background: linear-gradient(135deg, 
    rgba(var(--brand-rgb), 0.03) 0%, 
    rgba(var(--brand-2-rgb), 0.03) 100%);
  border-radius: 16px;
}

.bts-title {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 1rem;
  color: var(--brand);
}

.bts-description {
  font-size: 1.1rem;
  line-height: 1.8;
  color: var(--muted);
  max-width: 900px;
  margin: 0 auto;
}

/* BTS Options Cards */
.bts-options-grid {
  gap: 2rem;
  margin-top: 2rem;
}

.bts-option-card {
  position: relative;
  background: rgba(var(--card-rgb), 0.5);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  padding: 0;
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.bts-option-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
}

.option-header {
  padding: 2rem 2rem 1.5rem;
  text-align: center;
  background: linear-gradient(135deg, 
    rgba(var(--brand-rgb), 0.1) 0%, 
    rgba(var(--brand-2-rgb), 0.05) 100%);
  border-bottom: 2px solid rgba(var(--brand-rgb), 0.2);
}

.option-icon {
  font-size: 3rem;
  margin-bottom: 1rem;
  filter: drop-shadow(0 0 10px rgba(var(--brand-rgb), 0.3));
}

.option-title {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  color: var(--brand);
}

.option-subtitle {
  font-size: 0.95rem;
  color: var(--muted);
  font-style: italic;
}

.option-content {
  padding: 2rem;
}

.option-description {
  font-size: 1.05rem;
  line-height: 1.7;
  margin-bottom: 2rem;
  color: var(--text);
}

.competences-block,
.debouches-block {
  margin-bottom: 2rem;
}

.competences-block:last-child,
.debouches-block:last-child {
  margin-bottom: 0;
}

.competences-block h5,
.debouches-block h5 {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 1rem;
  color: var(--brand-2);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.competences-list,
.debouches-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.competences-list li,
.debouches-list li {
  position: relative;
  padding-left: 1.75rem;
  margin-bottom: 0.75rem;
  font-size: 1rem;
  line-height: 1.6;
  color: var(--text);
}

.competences-list li::before,
.debouches-list li::before {
  content: '▸';
  position: absolute;
  left: 0;
  color: var(--brand);
  font-weight: 700;
  font-size: 1.2rem;
}

.debouches-list li::before {
  content: '✓';
  color: var(--brand-2);
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .profil-header {
    padding: 2.5rem 1.5rem;
  }
  
  .header-content .quality-photo {
    width: 95px;
    height: 95px;
  }
  
  .profil-title {
    font-size: 1.75rem;
  }
  
  .stat-badges-container {
    flex-direction: column;
    gap: 0.7rem;
  }
  
  .stat-badge {
    width: 100%;
    justify-content: center;
    padding: 0.65rem 1.2rem;
    font-size: 0.83rem;
  }
  
  .stat-icon {
    font-size: 1.1rem;
  }
  
  .stat-text {
    white-space: normal;
    text-align: center;
  }
  
  .cv-section {
    grid-template-columns: 1fr;
    gap: 1.5rem;
    padding: 1.5rem;
  }
  
  .cv-gif-container {
    width: 180px;
    height: 180px;
    margin: 0 auto;
  }
  
  .cv-buttons-container {
    width: 100%;
  }
  
  .profil-card {
    padding: 1.5rem;
  }
  
  .bts-options-grid {
    grid-template-columns: 1fr;
  }
  
  .option-header {
    padding: 1.5rem 1rem 1rem;
  }
  
  .option-content {
    padding: 1.5rem;
  }
}

@media (max-width: 480px) {
  .profil-header {
    padding: 2rem 1rem;
  }
  
  .header-content .quality-photo {
    width: 85px;
    height: 85px;
    border-width: 3px;
  }
  
  .profil-title {
    font-size: 1.5rem;
  }
  
  .stat-badge {
    font-size: 0.8rem;
    padding: 0.6rem 1.1rem;
  }
  
  .stat-icon {
    font-size: 1.05rem;
  }
}

/* Footer */
footer { 
  position: relative; 
  padding: 32px 0; 
  border-top: 1px solid color-mix(in srgb, var(--text) 10%, transparent); 
  color: var(--muted);
  width: 100%;
  background: var(--card);
  display: flex;
  justify-content: center;
  align-items: center;
  margin-left: 0 !important;
}

.footer-content {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 32px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 20px;
  width: 100%;
}

footer .container {
  max-width: 1400px !important;
  margin: 0 auto !important;
  padding-left: 32px !important;
  padding-right: 32px !important;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
}

.footer-line { 
  display: flex; 
  align-items: center; 
  justify-content: center;
  text-align: center;
  font-size: 0.95rem;
  color: var(--muted);
}

.footer-socials {
  display: flex;
  gap: 16px;
  align-items: center;
  justify-content: center;
}

/* Aussi pour les footer qui utilisent sidebar-socials */
footer .sidebar-socials {
  display: flex;
  gap: 16px;
  align-items: center;
  justify-content: center;
}

.footer-socials .social-link,
footer .sidebar-socials .social-link {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text);
  text-decoration: none;
  border: 1px solid color-mix(in srgb, var(--text) 12%, transparent);
  background: color-mix(in srgb, var(--card) 70%, transparent);
  transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.footer-socials .social-link:hover,
footer .sidebar-socials .social-link:hover {
  transform: translateY(-3px);
  background: color-mix(in srgb, var(--brand) 14%, var(--card));
  border-color: var(--brand);
  color: var(--brand);
}

/* Anciens styles footer (gardés pour compatibilité) */
.footer-cta { display: grid; place-items: center; margin: 14px 0 6px; }
.footer-cta-btn { padding: 12px 16px; border-radius: 999px; font-weight: 600; }
.socials { display: flex; gap: 10px; justify-content: center; margin-top: 6px; }
.socials a { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; color: var(--text); text-decoration: none; border: 1px solid color-mix(in srgb, var(--text) 12%, transparent); background: color-mix(in srgb, var(--card) 70%, transparent); transition: transform .15s ease, background .2s ease, border-color .2s ease; }
.socials a:hover { transform: translateY(-2px); background: color-mix(in srgb, var(--brand) 14%, var(--card)); border-color: color-mix(in srgb, var(--brand) 30%, transparent); }

/* Responsive */
@media (max-width: 860px) {
  .footer-content {
    flex-direction: column;
    text-align: center;
  }
  .footer-socials {
    justify-content: center;
  }
}

/* Responsive */
@media (max-width: 860px) {
  #accueil { min-height: calc(100dvh - 140px); }
  .hero { grid-template-columns: 1fr; padding: 64px 16px; }
}

/* --- Améliorations typo et boutons --- */
:root { --radius: 12px; }

h1, h2, h3 { letter-spacing: 0.2px; }
h2.section-title { font-weight: 700; position: relative; padding-left: 10px; }
h2.section-title::before {
  content: "";
  position: absolute;
  left: 0; top: 8px; bottom: 8px; width: 4px;
  border-radius: 4px;
  background: linear-gradient(180deg, var(--brand), var(--brand-4));
}

/* Reduce vertical gap between project title and subtitle inside project cards */
.card.project h3 { margin: 0 0 6px; }
.card.project p.muted { margin: 0 0 10px; }

.card { border-radius: var(--radius); transition: transform .2s ease, border-color .2s ease; }
.card:hover { transform: translateY(-3px); border-color: color-mix(in srgb, var(--text) 18%, transparent); }

.btn { transition: transform .15s ease, box-shadow .2s ease, background .2s ease; }
.btn:hover { transform: translateY(-1px); box-shadow: 0 8px 20px color-mix(in srgb, var(--brand) 20%, transparent); }
.btn.primary { color: #0b1020; font-weight: 600; }

/* --- Améliorations Projets --- */
.project .thumb { position: relative; overflow: hidden; }
.project .thumb::after {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(1200px 1200px at var(--mx,50%) var(--my,50%), color-mix(in srgb, var(--brand) 14%, transparent), transparent 40%);
  opacity: 0; transition: opacity .2s ease;
}
.project:hover .thumb::after { opacity: 1; }

/* alternate status-like button used in project cards */
.btn.status-alt { background: linear-gradient(135deg, #f3f4f6, #e5e7eb); color: #071022; border-color: transparent; font-weight: 700; padding: 10px 14px; border-radius: 999px; box-shadow: 0 6px 18px rgba(2,6,23,0.12); display: inline-flex; align-items: center; justify-content: center; }
.btn.status-alt:hover { transform: translateY(-2px); box-shadow: 0 10px 28px rgba(2,6,23,0.16); }

/* Modal for project details */
.modal-backdrop { position: fixed; inset: 0; background: rgba(2,6,23,0.6); display: none; align-items: center; justify-content: center; z-index: 120; }
.modal-backdrop.open { display: flex; }
.modal { width: min(620px, 90%); max-height: 86vh; overflow: auto; background: var(--card); border-radius: 12px; padding: 18px; box-shadow: 0 30px 80px rgba(2,6,23,0.6); border: 1px solid color-mix(in srgb, var(--text) 8%, transparent); }
.modal .modal-header { display:flex; align-items:center; justify-content:space-between; gap: 12px; margin-bottom: 12px; }
.modal .modal-title { font-size: 1.15rem; font-weight: 800; }
.modal .modal-body { color: var(--muted); }
.modal .modal-thumb { width: 100%; height: 220px; border-radius: 10px; background-size: cover; background-position: center; margin-bottom: 12px; }
.modal-close { background: transparent; border: none; font-size: 22px; line-height: 1; cursor: pointer; color: var(--muted); }

@media (prefers-reduced-motion: reduce) {
  .btn.status-alt, .modal, .modal-backdrop { transition: none !important; }
}

/* unify project buttons size so adding more keeps layout consistent */
.projects .btn { min-width: 140px; text-align: center; display: inline-flex; align-items: center; justify-content: center; }

/* Détails des projets (même logique que timeline) */
.project .timeline-details {
  overflow: clip; max-height: 0; opacity: 0;
  transition: max-height .35s ease, opacity .3s ease;
  margin-top: 8px; color: var(--muted);
}
.project[aria-expanded="true"] .timeline-details {
  max-height: 400px; opacity: 1;
}

/* --- Apparition au scroll --- */
.reveal { opacity: 0; transform: translateY(16px); transition: opacity .6s ease, transform .6s ease; }
.reveal.visible { opacity: 1; transform: translateY(0); }

/* --- Lien de navigation actif --- */
nav a.active { color: var(--text); background: color-mix(in srgb, var(--brand) 24%, transparent); }

/* --- Bouton Top --- */
#toTop {
    position: fixed; right: 20px; bottom: 20px; z-index: 20;
    width: 44px; height: 44px; border-radius: 50%;
    display: grid; place-items: center;
    color: #0b1020; background: linear-gradient(135deg, var(--brand), var(--brand-4));
    border: none; cursor: pointer; box-shadow: 0 10px 24px color-mix(in srgb, var(--brand) 24%, transparent);
    opacity: 0; pointer-events: none; transition: opacity .25s ease, transform .2s ease;
  }
  #toTop.show { opacity: 1; pointer-events: auto; }
  #toTop:hover { transform: translateY(-2px); }

/* --- Timeline --- */
.timeline { position: relative; display: grid; gap: 16px; }
.timeline-line {
  position: absolute; left: 20px; top: 0; bottom: 0; width: 2px;
  background: color-mix(in srgb, var(--text) 14%, transparent);
}
.timeline-item { position: relative; padding-left: 56px; }
.timeline-dot {
  position: absolute; left: 12px; top: 22px; width: 16px; height: 16px; border-radius: 50%;
  background: linear-gradient(135deg, var(--brand), var(--brand-4));
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--brand) 20%, transparent);
}
.timeline-content h3 { margin: 0 0 6px; }
.timeline-content .muted { margin: 0; }
.timeline-item { cursor: pointer; }
.timeline-item:focus { outline: 2px solid color-mix(in srgb, var(--brand) 40%, transparent); outline-offset: 2px; }
.timeline-details { 
  overflow: clip; max-height: 0; opacity: 0; 
  transition: max-height .35s ease, opacity .3s ease; 
  margin-top: 8px; color: var(--muted);
}
.timeline-item[aria-expanded="true"] .timeline-details {
  max-height: 400px; opacity: 1;
}

/* Two-column parcours layout (Formation left / Expériences right) */
.parcours-grid {
  display: grid;
  /* make side columns wider when possible and reduce gutter so cards visually expand */
  grid-template-columns: minmax(360px, 1fr) 28px minmax(360px, 1fr);
  gap: 18px 20px;
  align-items: start;
  position: relative;
}

/* Stacked card-style parcours (matches attached design) */
.parcours-stack { display: block; }
.parcours-section-title { font-size: 1.5rem; margin: 18px 0 12px; text-align: left; color: color-mix(in srgb, var(--brand-4) 85%, var(--text)); }
.parcours-list { display: grid; gap: 12px; }
.parcours-card { display: flex; gap: 16px; align-items: flex-start; padding: 18px; border-radius: 14px; background: color-mix(in srgb, var(--card) 80%, transparent); border: 1px solid color-mix(in srgb, var(--text) 6%, transparent); }
.parcours-icon { 
  width: 60px; 
  height: 60px; 
  border-radius: 14px; 
  display: grid; 
  place-items: center; 
  font-size: 26px; 
  color: #fff; 
  flex: 0 0 60px; 
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.parcours-card:hover .parcours-icon {
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

.parcours-icon.bg-blue { 
  background: linear-gradient(135deg, var(--brand), var(--brand-2)); 
  box-shadow: 0 4px 12px rgba(var(--brand-rgb), 0.25);
}
.parcours-icon.bg-green { 
  background: linear-gradient(135deg, #10b981, #059669); 
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.25);
}
.parcours-icon.bg-amber { 
  background: linear-gradient(135deg, #f59e0b, #fb923c); 
  box-shadow: 0 4px 12px rgba(245, 158, 11, 0.25);
}
.parcours-icon.bg-red { 
  background: linear-gradient(135deg, #ef4444, #dc2626); 
  box-shadow: 0 4px 12px rgba(239, 68, 68, 0.25);
}
.parcours-body { flex: 1 1 auto; position: relative; z-index: 2; }
.parcours-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.parcours-title { 
  margin: 0; 
  font-size: 1.1rem; 
  font-weight: 700; 
  background: linear-gradient(135deg, #3b82f6, #2563eb);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  position: relative;
  z-index: 2;
}
.parcours-badges { display: inline-flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.badge { 
  display: inline-block; 
  padding: 6px 12px; 
  border-radius: 8px; 
  font-size: .78rem; 
  font-weight: 600; 
  color: #fff; 
  background: rgba(var(--card-rgb), 0.6); 
  border: 1px solid rgba(var(--brand-rgb), 0.25); 
  transition: all 0.25s ease;
}
.badge.date { 
  background: linear-gradient(135deg, rgba(var(--brand-rgb), 0.3), rgba(var(--brand-2-rgb), 0.3)); 
  color: var(--text); 
  border-color: rgba(var(--brand-rgb), 0.35);
}
.badge.status { 
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.25), rgba(5, 150, 105, 0.25)); 
  color: #10b981; 
  border-color: rgba(16, 185, 129, 0.4);
  font-weight: 600;
}
.badge.status-current { 
  background: linear-gradient(135deg, rgba(251, 146, 60, 0.25), rgba(249, 115, 22, 0.25)); 
  color: #f97316; 
  border-color: rgba(249, 115, 22, 0.4);
  font-weight: 700;
}
.badge.status-obtenu { 
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.25), rgba(220, 38, 38, 0.25)); 
  color: #ef4444; 
  border-color: rgba(239, 68, 68, 0.4);
  font-weight: 700;
}
.badges { display: flex; gap: 8px; align-items: center; margin: 8px 0; }

/* semantic badges: status and type colors */
.badge.status-termine { background: linear-gradient(135deg, #60a5fa, #0284c7); color: #072038; }
.badge.status-en-cours { background: linear-gradient(135deg, #86efac, #34d399); color: #052014; }
.badge.status-en-projet { background: linear-gradient(135deg, #ef4444, #dc2626); color: #0b1020; }
.badge.type-reseau { background: linear-gradient(135deg, color-mix(in srgb, var(--brand-4) 80%, #fb923c), #fb923c); color: #071022; }
.badge.type-dev { background: linear-gradient(135deg, color-mix(in srgb, var(--brand-2) 80%, #8b5cf6), var(--brand-2)); color: #071022; }

/* project card layout tweaks: place button centered at bottom and keep badges spaced */
.card.project { display: flex; flex-direction: column; height: 100%; }
.card.project .card-body { display: block; }
.card.project .card-footer { margin-top: auto; display: flex; justify-content: center; gap: 12px; padding-top: 12px; }
.card.project .card-footer .btn { margin: 0; }
.parcours-card .muted { 
  margin: 10px 0 0; 
  position: relative;
  z-index: 2;
  line-height: 1.6;
  font-size: 0.95rem;
}
.parcours-card .timeline-details { 
  margin-top: 12px; 
  position: relative;
  z-index: 2;
  padding: 12px 14px;
  background: rgba(var(--card-rgb), 0.4);
  border-left: 2px solid rgba(var(--brand-rgb), 0.3);
  border-radius: 6px;
  line-height: 1.65;
  font-size: 0.92rem;
}
.parcours-card[aria-expanded="true"] { 
  box-shadow: 0 18px 45px rgba(var(--brand-rgb), 0.25),
              0 10px 25px rgba(0, 0, 0, 0.15); 
  transform: translateY(-6px); 
  border-color: rgba(var(--brand-rgb), 0.4) !important;
}

@media (max-width: 860px) {
  .parcours-card { flex-direction: row; padding: 12px; }
  .parcours-section-title { text-align: center; }
  .parcours-icon { width: 56px; height: 56px; font-size: 20px; }
  .parcours-grid { grid-template-columns: 1fr; gap: 12px; }
}
.parcours-grid::before {
  content: "";
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  top: 12px;
  bottom: 12px;
  width: 6px; /* more visible central gutter */
  background: linear-gradient(180deg, color-mix(in srgb, var(--brand) 60%, transparent), color-mix(in srgb, var(--brand-4) 60%, transparent));
  opacity: 0.14;
  border-radius: 6px;
  z-index: 0;
}
.parcours-col { display: grid; gap: 18px; z-index: 1; }
.parcours-col.left { grid-column: 1 / 2; }
.parcours-col.right { grid-column: 3 / 4; }

/* Each timeline-item becomes a card aligned within its column */
.parcours-grid .timeline-item { padding: 18px; text-align: left; position: relative; transition: transform .28s cubic-bezier(.2,.9,.26,1), box-shadow .2s ease; }

/* layout title + meta on one row for compact header */
.parcours-grid .timeline-item .timeline-content { padding-left: 0; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.parcours-grid .timeline-content h3 { margin: 0; font-size: 1.02rem; }
.parcours-grid .timeline-meta { text-align: right; min-width: 8rem; }
.parcours-grid .timeline-date { margin: 0; font-size: .85rem; color: var(--muted); }

/* Dots sit visually beside the card edge pointing to the center line */
.parcours-grid .timeline-dot { left: auto; right: -22px; top: 18px; position: absolute; width: 14px; height: 14px; border-radius: 50%; box-shadow: 0 0 0 6px color-mix(in srgb, var(--brand) 16%, transparent); background: linear-gradient(135deg,var(--brand),var(--brand-4)); transition: transform .2s ease; }
.parcours-col.left .timeline-dot { right: -22px; }
.parcours-col.right .timeline-dot { left: -22px; }

/* Status badge sits toward the center - nudge outside edge slightly */
.parcours-grid .cert-badge {
  position: absolute; top: 12px; right: -6px; z-index: 2;
  padding: 6px 10px; border-radius: 999px; font-weight: 700; font-size: .75rem; text-transform: uppercase;
  background: linear-gradient(135deg,var(--brand),var(--brand-4)); color: #0b1020; box-shadow: 0 6px 18px color-mix(in srgb, var(--brand) 20%, transparent);
}
.parcours-col.right .parcours-grid .cert-badge, .parcours-col.right .cert-badge { right: auto; left: -6px; }

/* subtle stagger: move left column slightly left, right slightly right */
.parcours-col.left .timeline-item { transform: translateX(-14px); margin-right: 12px; width: calc(100% + 24px); }
.parcours-col.right .timeline-item { transform: translateX(14px); margin-left: 12px; width: calc(100% + 24px); }
.parcours-grid .timeline-item:hover { transform: translateX(0) scale(1.01); box-shadow: 0 10px 30px rgba(0,0,0,0.25); }

@media (max-width: 760px) {
  .parcours-grid { grid-template-columns: 1fr; }
  .parcours-grid::before { display: none; }
  .parcours-col.left, .parcours-col.right { grid-column: 1 / -1; }
  .parcours-grid .timeline-dot { left: 12px; right: auto; top: 18px; }
  .parcours-grid .cert-badge { right: 12px; }
}

/* Alternance gauche/droite */
.timeline.alt { grid-template-columns: 1fr; gap: 28px; position: relative; }
@media (min-width: 760px) {
  .timeline.alt { grid-template-columns: 1fr; }
  .timeline.alt .timeline-line { left: 50%; transform: translateX(-1px); }
  .timeline.alt .timeline-item { padding-left: 0; padding-right: 40px; }
  .timeline.alt .timeline-item { width: 49%; max-width: 49%; }
  .timeline.alt .timeline-item:nth-child(odd) {
    justify-self: start; padding-left: 40px; padding-right: 0;
  }
  .timeline.alt .timeline-item:nth-child(even) {
    justify-self: end;
  }
  /* Point bleu au bord intérieur (collé à la ligne centrale), identique pour les deux côtés */
  .timeline.alt .timeline-item .timeline-dot { left: auto; right: auto; }
  .timeline.alt .timeline-item:nth-child(odd) .timeline-dot { right: -6px; }
  .timeline.alt .timeline-item:nth-child(even) .timeline-dot { left: -6px; }
  .timeline.alt .timeline-item:nth-child(even) .timeline-content h3,
  .timeline.alt .timeline-item:nth-child(even) .timeline-content p,
  .timeline.alt .timeline-item:nth-child(even) .timeline-details { text-align: right; }
  .timeline.alt .timeline-dot { left: calc(50% - 8px); }

  /* Badge statut: on place des badges "inline" centrés sur la ligne via JS */
  .timeline.alt .timeline-item { position: relative; }
  .timeline.alt .cert-inline {
    position: absolute; left: 50%; transform: translateX(-50%);
    display: inline-block; padding: 4px 10px; border-radius: 999px;
    font-size: 0.75rem; font-weight: 700; letter-spacing: .3px; text-transform: uppercase;
    background: linear-gradient(135deg, var(--brand), var(--brand-4)); color: #0b1020;
    box-shadow: 0 4px 14px color-mix(in srgb, var(--brand) 30%, transparent);
    white-space: nowrap;
  }
}

/* Plus d'espace dans les cartes timeline */
.timeline-item.card { padding: 24px; text-align: center; }
.timeline-item .timeline-content, .timeline-item .timeline-details { text-align: center; }
.timeline-item .timeline-content h3 { margin-top: 0; margin-bottom: 8px; }
.timeline-item .timeline-content .muted { margin: 0; }
.timeline-details { margin-top: 12px; }

/* Révélation progressive des items timeline (slide in) */
.timeline.alt .timeline-item { opacity: 0; transform: translateY(16px); transition: opacity .5s ease, transform .5s ease; }
@media (min-width: 760px) {
  .timeline.alt .timeline-item:nth-child(odd) { transform: translate(-12px, 16px); }
  .timeline.alt .timeline-item:nth-child(even) { transform: translate(12px, 16px); }
}
.timeline.alt .timeline-item.is-visible { opacity: 1; transform: translate(0, 0); }


/* --- Bouton thème flottant (en haut à droite) --- */
.theme-fab {
  position: fixed; top: 16px; right: 16px; z-index: 60;
  display: inline-grid; grid-auto-flow: column; align-items: center; gap: 10px;
  padding: 8px 10px; border-radius: 999px; border: 1px solid color-mix(in srgb, var(--text) 14%, transparent);
  background: color-mix(in srgb, var(--card) 80%, transparent); color: var(--text); cursor: pointer;
  backdrop-filter: blur(8px);
}
.theme-fab .icon { font-size: 16px; }
.theme-fab .track {
  width: 38px; height: 18px; border-radius: 999px; position: relative;
  background: color-mix(in srgb, var(--text) 14%, transparent);
}
.theme-fab .thumb {
  position: absolute; top: 2px; left: 2px; width: 14px; height: 14px; border-radius: 50%;
  background: linear-gradient(135deg, var(--brand), var(--brand-4)); transition: transform .2s ease;
}
html.light .theme-fab .thumb { transform: translateX(20px); }
.theme-fab:hover { transform: translateY(-1px); }

/* Détails timeline mise en page */
.two-cols { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; }
.timeline-details h4 { margin: 8px 0; }
.timeline-details h5 { margin: 6px 0; font-size: 1rem; }
.timeline-details ul { margin: 6px 0 0 18px; padding: 0; }
.timeline-details li { margin: 4px 0; }

@media (max-width: 640px) {
  .timeline-line { left: 14px; }
  .timeline-item { padding-left: 48px; }
  .timeline-dot { left: 6px; }
}

.project .thumb {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.project:hover .thumb {
  transform: scale(1.05);
  box-shadow: 0 6px 20px rgba(0,0,0,0.3);
}

/* --- Thème: bouton discret --- */
#themeToggle { margin-left: 10px; }

/* --- Modal projet --- */
.modal { position: fixed; inset: 0; z-index: 40; display: none; }
.modal[aria-hidden="false"] { display: block; }
.modal-backdrop { position: absolute; inset: 0; background: rgba(0,0,0,0.5); backdrop-filter: blur(2px); }
.modal-dialog {
  position: relative; z-index: 1; width: min(680px, 92%);
  margin: 8vh auto 0; padding: 16px; border-radius: 12px;
  background: var(--card); border: 1px solid color-mix(in srgb, var(--text) 10%, transparent);
  box-shadow: 0 24px 60px rgba(0,0,0,0.35);
}
.modal-close { position: absolute; right: 10px; top: 10px; border: 0; background: transparent; color: var(--text); font-size: 24px; cursor: pointer; }
.modal-content { color: var(--muted); }


/* --- Fond animé moderne --- */
body {
  background: radial-gradient(1200px 800px at 10% -10%, color-mix(in srgb, var(--brand) 8%, var(--bg)), var(--bg)),
              radial-gradient(1000px 800px at 110% 10%, color-mix(in srgb, var(--brand-4) 8%, transparent), transparent),
              var(--bg);
}

/* Accessibility & transitions: smoother expand/collapse and keyboard focus */
.timeline-details {
  transition: max-height .36s cubic-bezier(.2,.9,.26,1), opacity .28s ease;
  will-change: max-height, opacity;
}

.parcours-card:focus-visible,
.timeline-item:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--brand) 36%, transparent);
  outline-offset: 4px;
}

.parcours-body { min-width: 0; }

@media (prefers-reduced-motion: reduce) {
  .timeline-details { transition: none !important; }
  .parcours-card, .timeline-item { transition: none !important; }
}

body::before, body::after {
  content: ""; position: fixed; inset: -20%; z-index: -1; filter: blur(60px); opacity: .18;
  background: radial-gradient(600px 600px at 20% 20%, var(--brand), transparent 60%);
}
body::after {
  background: radial-gradient(600px 600px at 80% 10%, var(--brand-4), transparent 60%);
}

/* --- Header/Cartes en glass --- */
header { backdrop-filter: blur(10px); background: color-mix(in srgb, var(--bg) 55%, transparent); }
.card { background: color-mix(in srgb, var(--card) 80%, transparent); backdrop-filter: blur(6px); }

/* --- Boutons modernes --- */
.btn {
  position: relative; overflow: hidden; border: 1px solid color-mix(in srgb, var(--text) 16%, transparent);
}
.btn.primary {
  background: linear-gradient(135deg, color-mix(in srgb, var(--brand) 85%, transparent), color-mix(in srgb, var(--brand-4) 85%, transparent));
  border: none; color: #0b1020;
}
.btn.primary::after {
  content: ""; position: absolute; inset: -20%; background: radial-gradient(240px 240px at var(--mx,50%) var(--my,50%), rgba(255,255,255,.25), transparent 60%);
  opacity: 0; transition: opacity .2s ease;
}
.btn.primary:hover::after { opacity: .9; }

/* --- Nav underline animé --- */
nav a { position: relative; }
nav a::after {
  content: ""; position: absolute; left: 10px; right: 10px; bottom: 6px; height: 2px; border-radius: 2px;
  background: linear-gradient(90deg, var(--brand), var(--brand-4)); transform: scaleX(0); transform-origin: left; transition: transform .25s ease;
}
nav a:hover::after, nav a.active::after { transform: scaleX(1); }


/* --- Barre de progression lecture --- */
.scroll-progress {
  position: fixed; left: 0; top: 0; height: 3px; width: 100%; transform-origin: left;
  transform: scaleX(0); z-index: 50;
  background: linear-gradient(90deg, var(--brand), var(--brand-4));
}

/* --- Titre h1 dégradé animé --- */
.hero h1 {
  color: #ffffff;
}

/* Effet machine à écrire pour le titre d'accueil */
#typeTitle {
  position: relative;
}
#typeTitle::after {
  content: "";
  position: absolute; right: -6px; top: 50%; transform: translateY(-50%);
  width: 2px; height: 1.2em; background: currentColor; opacity: 0.8;
  animation: caret-blink 1s steps(1) infinite;
}
@keyframes caret-blink {
  0%, 50% { opacity: 0; }
  51%, 100% { opacity: 1; }
}
@keyframes title-shine {
  0% { background-position: 0% 0; }
  100% { background-position: 200% 0; }
}

/* --- Cartes projets prêtes pour tilt --- */
.project.card { transition: transform .12s ease; will-change: transform; }

/* --- Goutte de fond (hero) --- */
#accueil { position: relative; overflow: hidden; z-index: 0; }

/* Hero GIF Background */
.hero-background {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
}
.hero-gif {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.35;
  animation: hero-gif-fade 1.2s ease-out;
  filter: brightness(0.9) contrast(1.1);
}
@keyframes hero-gif-fade {
  from { opacity: 0; }
  to { opacity: 0.35; }
}
.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(10, 14, 26, 0.55) 0%, rgba(17, 24, 39, 0.45) 50%, rgba(10, 14, 26, 0.60) 100%);
  z-index: 1;
}

#accueil .bg-droplet {
  position: absolute; inset: -10% -10% auto auto; right: -6%; top: -8%;
  width: 520px; height: 520px;
  z-index: -1; pointer-events: none; opacity: 0.18; filter: blur(2px) saturate(120%);
  background: radial-gradient(circle at 40% 30%, var(--brand) 0%, #38bdf8 40%, #FF7F00 42%, var(--brand-4) 100%);
  border-radius: 58% 42% 60% 40% / 58% 60% 40% 42%; /* forme organique/goutte */
  transform: rotate(18deg);
  animation: bg-droplet-float 14s ease-in-out infinite;
}
@keyframes bg-droplet-float {
  0%, 100% { transform: translate3d(0,0,0) rotate(18deg) scale(1); opacity: 0.18; }
  25%      { transform: translate3d(-10px, 12px, 0) rotate(14deg) scale(1.02); opacity: 0.20; }
  50%      { transform: translate3d(-18px, 4px, 0) rotate(20deg) scale(1.03); opacity: 0.19; }
  75%      { transform: translate3d(-8px, 10px, 0) rotate(16deg) scale(1.01); opacity: 0.18; }
}
@media (prefers-reduced-motion: reduce) {
  #accueil .bg-droplet { animation: none; }
}

/* Ensure hero content is above */
.hero { position: relative; z-index: 1; }
.hero .bg-droplet, .hero .bg-droplet2 { position: absolute; z-index: 0; }
.hero .hero-content { position: relative; z-index: 1; }

/* --- Layout élargi --- */
.container { max-width: 1280px; }
#accueil { padding: 72px 0 28px; }
.hero h1 { font-size: clamp(32px, 5.6vw, 56px); }
.hero p { font-size: 1.1rem; }

/* --- Gouttes de fond dynamiques (pilotées par CSS vars) --- */
#accueil { --dx: 0px; --dy: 0px; --rot: 18deg; --scale: 1; }
#accueil .bg-droplet,
#accueil .bg-droplet2 { will-change: transform; }
#accueil .bg-droplet {
  transform: translate(var(--dx), var(--dy)) rotate(var(--rot)) scale(var(--scale));
}
#accueil .bg-droplet2 {
  position: absolute; left: -8%; bottom: -14%; width: 380px; height: 380px; z-index: 0;
  pointer-events: none; opacity: 0.16; filter: blur(2px) saturate(120%);
  background: radial-gradient(circle at 40% 30%, var(--brand-4) 0%, #FF7F00 40%, #38bdf8 42%, var(--brand) 100%);
  border-radius: 44% 56% 52% 48% / 60% 40% 60% 40%;
  transform: translate(calc(var(--dx) * -0.4), calc(var(--dy) * -0.4)) rotate(calc(var(--rot) * -1)) scale(calc(1 + (var(--scale) - 1) * 0.6));
}

/* --- Gouttes de fond: morphing + déplacement (CSS only) --- */
#accueil .bg-droplet,
#accueil .bg-droplet2 { animation-play-state: running; }
#accueil .bg-droplet {
  opacity: 0.26;
  animation: blob-morph 18s ease-in-out infinite, blob-move 22s ease-in-out infinite;
}
#accueil .bg-droplet2 {
  opacity: 0.20;
  animation: blob-morph-2 20s ease-in-out infinite, blob-move-2 26s ease-in-out infinite;
}
@keyframes blob-morph {
  0%   { border-radius: 58% 42% 60% 40% / 58% 60% 40% 42%; transform: translate(0,0) rotate(16deg) scale(1.00); }
  25%  { border-radius: 64% 36% 58% 42% / 52% 62% 38% 48%; transform: translate(-14px, 10px) rotate(12deg) scale(1.03); }
  50%  { border-radius: 52% 48% 62% 38% / 64% 36% 54% 46%; transform: translate(-22px, 0px) rotate(20deg) scale(1.06); }
  75%  { border-radius: 60% 40% 46% 54% / 40% 60% 44% 56%; transform: translate(-10px, 12px) rotate(14deg) scale(1.02); }
  100% { border-radius: 58% 42% 60% 40% / 58% 60% 40% 42%; transform: translate(0,0) rotate(16deg) scale(1.00); }
}
@keyframes blob-move {
  0%, 100% { transform: translate(0,0); }
  33%      { transform: translate(-16px, 8px); }
  66%      { transform: translate(-24px, -6px); }
}
@keyframes blob-morph-2 {
  0%   { border-radius: 44% 56% 52% 48% / 60% 40% 60% 40%; transform: translate(0,0) rotate(-10deg) scale(1.00); }
  25%  { border-radius: 56% 44% 44% 56% / 48% 52% 58% 42%; transform: translate(12px, -12px) rotate(-6deg) scale(1.04); }
  50%  { border-radius: 48% 52% 60% 40% / 56% 44% 50% 50%; transform: translate(18px, -4px) rotate(-14deg) scale(1.06); }
  75%  { border-radius: 40% 60% 44% 56% / 58% 42% 60% 40%; transform: translate(8px, -10px) rotate(-8deg) scale(1.02); }
  100% { border-radius: 44% 56% 52% 48% / 60% 40% 60% 40%; transform: translate(0,0) rotate(-10deg) scale(1.00); }
}
@keyframes blob-move-2 {
  0%, 100% { transform: translate(0,0); }
  40%      { transform: translate(10px, -14px); }
  80%      { transform: translate(18px, -6px); }
}
@media (prefers-reduced-motion: reduce) {
  #accueil .bg-droplet, #accueil .bg-droplet2 { animation: none !important; }
}

/* --- Nouvelles sections: Certifications & Outils --- */
/* --- Projets: header/filters --- */
#projets-header { padding-top: 32px; }
.filters { display: flex; flex-wrap: wrap; gap: 10px; margin: 10px 0 6px; justify-content: center; }
.pill { padding: 6px 10px; border-radius: 999px; border: 1px solid color-mix(in srgb, var(--text) 14%, transparent); background: color-mix(in srgb, var(--card) 70%, transparent); color: var(--text); cursor: pointer; }
.pill.active { border-color: transparent; }
.project-filter[data-filter="all"].active { /* Toutes -> green */
  background: linear-gradient(135deg, #34d399 0%, #10b981 100%);
  color: #071022; border-color: transparent; box-shadow: 0 12px 26px rgba(6,95,70,0.08);
}
.project-filter[data-filter="r"].active { /* Réseaux -> orange */
  background: linear-gradient(135deg, #fb923c 0%, #f97316 100%);
  color: #071022; border-color: transparent; box-shadow: 0 12px 26px rgba(68,44,0,0.08);
}
.project-filter[data-filter="d"].active { /* Développement -> violet */
  background: linear-gradient(135deg, #8b5cf6 0%, #6d28d9 100%);
  color: #071022; border-color: transparent; box-shadow: 0 12px 26px rgba(73,38,125,0.08);
}

/* Projects: professional / personal filters */
.project-filter[data-filter="pro"].active {
  /* professional -> cyan/teal */
  background: linear-gradient(135deg, #06b6d4 0%, #0ea5a6 100%);
  color: #071022; border-color: transparent; box-shadow: 0 12px 26px rgba(6,95,110,0.08);
}
.project-filter[data-filter="perso"].active {
  /* personal -> magenta/purple */
  background: linear-gradient(135deg, #ec4899 0%, #8b5cf6 100%);
  color: #071022; border-color: transparent; box-shadow: 0 12px 26px rgba(120,40,100,0.08);
}
.small { font-size: .9rem; }

/* Centrage du header projets */
#projets-header .container { text-align: center; }
#projets-header .section-title { margin-bottom: 8px; }

.certifications { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 20px; }
.certification { text-align: center; position: relative; overflow: hidden; }
.cert-icon { font-size: 2.5rem; margin-bottom: 12px; display: block; }
.cert-badge {
  position: absolute; top: 12px; right: 12px; padding: 4px 8px; border-radius: 12px;
  font-size: 0.75rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.5px;
  background: linear-gradient(135deg, var(--brand), var(--brand-4)); color: #0b1020;
}
.certification:hover { transform: translateY(-6px) scale(1.02); }
.certification:hover .cert-icon { animation: cert-bounce 0.6s ease-in-out; }
@keyframes cert-bounce {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.1); }
}

.tools { grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; }
.tool-item {
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  padding: 20px 12px; border-radius: 12px; background: color-mix(in srgb, var(--card) 60%, transparent);
  backdrop-filter: blur(8px); border: 1px solid color-mix(in srgb, var(--text) 8%, transparent);
  transition: all 0.3s cubic-bezier(.34,1.56,.64,1); cursor: pointer;
}
.tool-icon { font-size: 28px; margin-bottom: 8px; width: 48px; height: 48px; display: grid; place-items: center; }
.tool-item .skill-icon { width: 48px; height: 48px; display: block; margin-bottom: 8px; }
.tool-item span { font-size: 0.9rem; font-weight: 500; color: var(--muted); }
.tool-item:hover {
  transform: translateY(-4px) scale(1.05);
  background: color-mix(in srgb, var(--brand) 12%, var(--card));
  border-color: color-mix(in srgb, var(--brand) 30%, transparent);
}
.tool-item:hover .tool-icon { animation: tool-spin 0.8s ease-in-out; }
/* Harmoniser: icônes des compétences tournent aussi au survol */
.tool-item:hover .skill-icon { animation: tool-spin 0.8s ease-in-out; }
/* Barres de progression à l'intérieur des tool-item */
.tool-item .bar { width: 100%; margin-top: 10px; }
.tool-item .skill-title { display: inline-flex; align-items: center; gap: 8px; }
.tool-name { margin-top: 4px; font-size: 0.95rem; color: var(--text); text-align: center; }

/* Animation de progression au survol des tool-item */
/* Désactiver l'animation de la barre au survol */
.tool-item:hover .bar > span { animation: none; }

/* Espace supplémentaire en bas pour la section veille */
#veille-technologique { padding-bottom: 96px; }
@keyframes tool-spin {
  0% { transform: rotate(0deg) scale(1); }
  50% { transform: rotate(180deg) scale(1.1); }
  100% { transform: rotate(360deg) scale(1); }
}

/* Styles pour la page veille: galerie carrée */
/* Sujet: rendu en texte dégradé, centré et visible */
#accueil .subject-title {
  display: block;
  font-size: clamp(32px, 5vw, 48px);
  line-height: 1.05;
  margin: 0 0 12px;
  font-weight: 800;
  background: linear-gradient(90deg, var(--brand), var(--brand-4));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-align: left;
}

/* Révélation en cascade : enfants d'une section .reveal */
.reveal > * { opacity: 0; transform: translateY(12px); transition: opacity .48s ease, transform .48s ease; }
.reveal.visible > * { opacity: 1; transform: none; }

.gallery { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; margin-top: 12px; }
.gallery-item { overflow: hidden; padding: 0; position: relative; }
.gallery-item.square { aspect-ratio: 1 / 1; }
.img-square { position: absolute; inset: 0; width: 100%; height: 100%; overflow: hidden; }
.img-square img { width: 100%; height: 100%; object-fit: cover; display: block; }
.gallery-item figcaption { position: absolute; left: 0; right: 0; bottom: 0; padding: 10px 12px; color: var(--text); font-size: .95rem; background: linear-gradient(180deg, rgba(0,0,0,0) 0%, rgba(0,0,0,0.55) 100%); }


/* Sources: cartes cliquables */
.source-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 12px; margin-top: 12px; }
.source {
  display: flex;
  align-items: center;
  justify-content: center; /* center content horizontally */
  padding: 14px 12px;
  text-decoration: none;
  color: inherit;
  transition: transform .12s ease, box-shadow .12s ease;
  text-align: center;
}

.source-name { font-weight: 700; }
.source .external { margin-left: 6px; color: var(--muted); font-weight: 600; }
.source:hover { transform: translateY(-6px); box-shadow: 0 12px 36px rgba(0,0,0,0.35); }

@media (max-width: 860px) {
  .team-badges { justify-content: flex-start; }
  .team-badge { padding: 6px 10px; min-width: 72px; }
  .gallery-item img { height: auto; }
  .img-square { aspect-ratio: 1 / 1; }
}

/* Hero extras next to title */
.hero-extras { display: flex; gap: 16px; margin-top: 14px; align-items: start; }
.hero-extras .brief { padding: 12px; max-width: 360px; }
.hero-extras .brief ul { margin: 8px 0 0 16px; }

/* F1 decorative images */
.f1-decorative-left,
.f1-decorative-right {
  animation: f1-float 3s ease-in-out infinite;
}

.f1-decorative-left {
  animation-delay: 0s;
}

.f1-decorative-right {
  animation-delay: 1.5s;
}

@keyframes f1-float {
  0%, 100% {
    transform: translateY(-50%) translateX(0);
  }
  50% {
    transform: translateY(-50%) translateX(-5px);
  }
}

@media (max-width: 1200px) {
  .f1-decorative-left,
  .f1-decorative-right {
    display: none;
  }
}
.hero-extras .hero-cta { display: flex; gap: 10px; align-items: center; }

/* Side teasers fixed during scroll */
.side-teasers { position: absolute; right: -120px; top: 40%; display: flex; flex-direction: column; gap: 12px; transform: rotate(-90deg); transform-origin: right top; }
.side-teasers .teaser { background: color-mix(in srgb, var(--card) 70%, transparent); padding: 8px 12px; border-radius: 8px; color: var(--muted); font-weight: 700; }

/* F1 track styles removed per user request. Restore original block to re-enable. */
@media (max-width: 860px) {
  .hero-extras { flex-direction: column; }
  .side-teasers { display: none; }
}

/* Lightbox pour la galerie */
.lightbox { position: fixed; inset: 0; display: grid; place-items: center; z-index: 100; pointer-events: none; opacity: 0; transition: opacity .18s ease; }
.lightbox.open { pointer-events: auto; opacity: 1; }
.lightbox-backdrop { position: absolute; inset: 0; background: rgba(0,0,0,0.75); }
.lightbox-stage { position: relative; z-index: 101; max-width: 92%; max-height: 84%; display: grid; place-items: center; }
.lightbox-stage img { max-width: 90vw; max-height: 80vh; width: auto; height: auto; border-radius: 10px; box-shadow: 0 20px 40px rgba(0,0,0,0.6); }
.lightbox-close, .lightbox-prev, .lightbox-next { position: absolute; z-index: 102; border: none; background: color-mix(in srgb, var(--card) 80%, transparent); color: var(--text); padding: 8px 12px; border-radius: 8px; cursor: pointer; backdrop-filter: blur(6px); }
.lightbox-close { top: 18px; right: 18px; font-size: 22px; }
.lightbox-prev { left: 12px; top: 50%; transform: translateY(-50%); }
.lightbox-next { right: 12px; top: 50%; transform: translateY(-50%); }
.lightbox-close:hover, .lightbox-prev:hover, .lightbox-next:hover { transform: translateY(-2px); }

@media (max-width: 640px) {
  .lightbox-prev, .lightbox-next { display: none; }
  .lightbox-stage img { border-radius: 6px; }
}

/* --- Section Contact --- */
/* ===================================
   CONTACT PAGE PREMIUM STYLES
   =================================== */

/* Contact Premium Header */
.contact-header {
  position: relative;
  text-align: center;
  padding: 3rem 2rem;
  margin-bottom: 3rem;
  background: linear-gradient(
    135deg,
    rgba(var(--brand-rgb), 0.03),
    rgba(var(--brand-2-rgb), 0.03)
  );
  border-radius: 24px;
  border: 1px solid rgba(var(--brand-rgb), 0.15);
  overflow: hidden;
}

.contact-header::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(
    circle at 50% 0%,
    rgba(var(--brand-rgb), 0.12),
    transparent 70%
  );
  animation: pulse-glow 4s ease-in-out infinite;
  pointer-events: none;
}

.contact-title {
  font-size: 2.5rem;
  font-weight: 800;
  margin: 0 0 0.75rem;
  background: linear-gradient(135deg, var(--text), color-mix(in srgb, var(--text) 70%, var(--brand)));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  position: relative;
  z-index: 1;
}

/* Contact Grid */
#contact { min-height: calc(100dvh - 120px); }
.contact-grid { 
  display: grid; 
  grid-template-columns: 1fr 1fr; 
  gap: 3rem; 
  align-items: start;
  margin-top: 2rem;
}

/* Contact Info Section */
.contact-info {
  position: sticky;
  top: 100px;
}

.info-title {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 1rem;
}

.contact-methods { 
  margin-top: 2rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.contact-method {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1.25rem;
  border-radius: 16px;
  background: rgba(var(--card-rgb), 0.6);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(var(--brand-rgb), 0.15);
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  position: relative;
  overflow: hidden;
}

.contact-method::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(var(--brand-rgb), 0.1),
    transparent
  );
  transition: left 0.6s ease;
}

.contact-method:hover::before {
  left: 100%;
}

.contact-method:hover {
  transform: translateX(8px) scale(1.02);
  background: rgba(var(--card-rgb), 0.8);
  border-color: rgba(var(--brand-rgb), 0.3);
  box-shadow: 0 8px 24px rgba(var(--brand-rgb), 0.15);
}

.method-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: all 0.3s ease;
}

.email-icon {
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.2), rgba(37, 99, 235, 0.2));
  color: rgb(59, 130, 246);
}

.phone-icon {
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.2), rgba(22, 163, 74, 0.2));
  color: rgb(34, 197, 94);
}

.location-icon {
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.2), rgba(220, 38, 38, 0.2));
  color: rgb(239, 68, 68);
}

.linkedin-icon {
  background: linear-gradient(135deg, rgba(14, 165, 233, 0.2), rgba(2, 132, 199, 0.2));
  color: rgb(14, 165, 233);
}

.contact-method:hover .method-icon {
  transform: scale(1.1) rotate(5deg);
}

.method-content {
  flex: 1;
}

.method-content h4 {
  margin: 0 0 0.25rem;
  font-size: 1rem;
  font-weight: 600;
}

.method-content p {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.method-content a {
  color: var(--brand);
  text-decoration: none;
  font-size: 0.9rem;
  transition: color 0.3s ease;
}

.method-content a:hover {
  color: var(--brand-4);
  text-decoration: underline;
}

/* Contact Form Premium */
.contact-form {
  background: rgba(var(--card-rgb), 0.4);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(var(--brand-rgb), 0.15);
  border-radius: 24px;
  padding: 2rem;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.form-header {
  margin-bottom: 0.5rem;
}

.form-header h3 {
  font-size: 1.5rem;
  font-weight: 700;
  margin: 0 0 0.5rem;
}

.form-header p {
  margin: 0;
  font-size: 0.95rem;
}

.form-group {
  position: relative;
  display: flex;
  flex-direction: column;
}

.form-group input,
.form-group textarea {
  padding: 1rem 3rem 1rem 1rem;
  border: 2px solid rgba(var(--brand-rgb), 0.2);
  border-radius: 12px;
  background: rgba(var(--card-rgb), 0.6);
  backdrop-filter: blur(8px);
  color: var(--text);
  font: inherit;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  font-size: 1rem;
}

.form-group textarea {
  resize: vertical;
  min-height: 120px;
}

.form-group label {
  position: absolute;
  left: 1rem;
  top: 1rem;
  color: var(--muted);
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  pointer-events: none;
  transform-origin: left;
  font-size: 1rem;
  background: transparent;
  padding: 0 0.25rem;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 4px rgba(var(--brand-rgb), 0.1);
  background: rgba(var(--card-rgb), 0.8);
}

.form-group input:focus + label,
.form-group textarea:focus + label,
.form-group input:not(:placeholder-shown) + label,
.form-group textarea:not(:placeholder-shown) + label {
  transform: translateY(-2rem) scale(0.85);
  color: var(--brand);
  background: var(--bg);
  padding: 0 0.5rem;
  left: 0.75rem;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  opacity: 0;
}

.input-icon {
  position: absolute;
  right: 1rem;
  top: 1rem;
  font-size: 1.25rem;
  opacity: 0.5;
  pointer-events: none;
  transition: all 0.3s ease;
}

.textarea-icon {
  top: 1rem;
}

.form-group input:focus ~ .input-icon,
.form-group textarea:focus ~ .input-icon {
  opacity: 1;
  transform: scale(1.1);
}

.form-submit {
  position: relative;
  overflow: hidden;
  margin-top: 1rem;
  padding: 1rem 2rem;
  font-size: 1rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.btn-icon {
  font-size: 1.25rem;
}

.btn-loading {
  display: none;
}

.form-submit.loading .btn-text,
.form-submit.loading .btn-icon {
  display: none;
}

.form-submit.loading .btn-loading {
  display: inline;
}

.form-submit.loading {
  pointer-events: none;
  opacity: 0.7;
}

/* Form Notice */
.form-notice {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 1rem;
  background: rgba(var(--brand-rgb), 0.08);
  border: 1px solid rgba(var(--brand-rgb), 0.2);
  border-radius: 12px;
  margin-top: 0.5rem;
}

.form-notice svg {
  flex-shrink: 0;
  margin-top: 0.125rem;
  color: var(--brand);
}

.form-notice p {
  margin: 0;
  font-size: 0.9rem;
  color: var(--muted);
  line-height: 1.5;
}

/* Animations */
.contact-method {
  animation: contact-appear 0.6s ease-out backwards;
}

.contact-method:nth-child(1) { animation-delay: 0.1s; }
.contact-method:nth-child(2) { animation-delay: 0.2s; }
.contact-method:nth-child(3) { animation-delay: 0.3s; }
.contact-method:nth-child(4) { animation-delay: 0.4s; }

@keyframes contact-appear {
  from {
    opacity: 0;
    transform: translateX(-30px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* Responsive */
@media (max-width: 768px) {
  #contact {
    min-height: auto;
  }

  .contact-header {
    padding: 2rem 1.5rem;
  }

  .contact-title {
    font-size: 2rem;
  }

  .contact-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .contact-info {
    position: relative;
    top: 0;
  }

  .contact-form {
    padding: 1.5rem;
  }

  .form-group input,
  .form-group textarea {
    padding: 0.875rem 2.5rem 0.875rem 0.875rem;
  }

  .input-icon {
    right: 0.75rem;
    top: 0.875rem;
  }
}


/* --- Override fort: mouvement visible des gouttes --- */
#accueil .bg-droplet {
  animation: droplet-orbit 14s ease-in-out infinite !important;
}
#accueil .bg-droplet2 {
  animation: droplet-orbit-2 18s ease-in-out infinite !important;
}
@keyframes droplet-orbit {
  0%   { transform: translate(0, 0) rotate(12deg) scale(1.02); }
  20%  { transform: translate(-28px, 18px) rotate(8deg)  scale(1.05); }
  40%  { transform: translate(-52px, -10px) rotate(16deg) scale(1.08); }
  60%  { transform: translate(-34px, 16px) rotate(10deg) scale(1.04); }
  80%  { transform: translate(-12px, -8px) rotate(14deg) scale(1.03); }
  100% { transform: translate(0, 0) rotate(12deg) scale(1.02); }
}
@keyframes droplet-orbit-2 {
  0%   { transform: translate(0, 0) rotate(-10deg) scale(1.00); }
  25%  { transform: translate(24px, -20px) rotate(-6deg)  scale(1.04); }
  50%  { transform: translate(40px, -10px) rotate(-14deg) scale(1.06); }
  75%  { transform: translate(20px, -22px) rotate(-8deg)  scale(1.03); }
  100% { transform: translate(0, 0) rotate(-10deg) scale(1.00); }
}


/* --- Gouttes: version rapide avec rebond --- */
#accueil .bg-droplet { animation: droplet-bounce-1 8s cubic-bezier(.34,1.56,.64,1) infinite !important; }
#accueil .bg-droplet2 { animation: droplet-bounce-2 10s cubic-bezier(.34,1.56,.64,1) infinite !important; }

@keyframes droplet-bounce-1 {
  0%   { transform: translate(0, 0)          rotate(12deg) scale(1.02); }
  12%  { transform: translate(-24px, 28px)    rotate(10deg) scale(1.03, 0.98); }
  20%  { transform: translate(-24px, 10px)    rotate(11deg) scale(1.04, 1.02); }
  32%  { transform: translate(-46px, -18px)   rotate(16deg) scale(1.07); }
  40%  { transform: translate(-46px, 4px)     rotate(14deg) scale(1.05, 0.97); }
  55%  { transform: translate(-30px, 22px)    rotate(11deg) scale(1.04); }
  68%  { transform: translate(-12px, -16px)   rotate(15deg) scale(1.03, 1.01); }
  82%  { transform: translate(-6px, 10px)     rotate(13deg) scale(1.02, 0.99); }
  100% { transform: translate(0, 0)           rotate(12deg) scale(1.02); }
}

@keyframes droplet-bounce-2 {
  0%   { transform: translate(0, 0)           rotate(-10deg) scale(1.00); }
  15%  { transform: translate(22px, -26px)    rotate(-8deg)  scale(1.03, 0.98); }
  25%  { transform: translate(22px, -8px)     rotate(-9deg)  scale(1.04, 1.02); }
  40%  { transform: translate(36px, -18px)    rotate(-14deg) scale(1.06); }
  50%  { transform: translate(36px, 2px)      rotate(-12deg) scale(1.04, 0.98); }
  66%  { transform: translate(18px, -22px)    rotate(-9deg)  scale(1.03); }
  82%  { transform: translate(10px, -6px)     rotate(-11deg) scale(1.02, 1.00); }
  100% { transform: translate(0, 0)           rotate(-10deg) scale(1.00); }
}


/* --- Gouttes améliorées: traînées + particules --- */
#accueil .bg-droplet {
  width: 320px; height: 320px; opacity: 0.22;
  animation: droplet-wall-1 6.5s cubic-bezier(.22,.76,.24,1) infinite both !important;
  position: relative;
}
#accueil .bg-droplet2 {
  width: 220px; height: 220px; opacity: 0.20;
  animation: droplet-wall-2 7.5s cubic-bezier(.22,.76,.24,1) infinite both !important;
  position: relative;
}

/* Traînées lumineuses */
#accueil .bg-droplet::before,
#accueil .bg-droplet2::before {
  content: ""; position: absolute; inset: -20px;
  background: radial-gradient(circle at 50% 50%, var(--brand) 0%, transparent 70%);
  opacity: 0.3; filter: blur(15px); z-index: -1;
  animation: trail-glow-1 6.5s cubic-bezier(.22,.76,.24,1) infinite both;
}
#accueil .bg-droplet2::before {
  background: radial-gradient(circle at 50% 50%, var(--brand-4) 0%, transparent 70%);
  animation: trail-glow-2 7.5s cubic-bezier(.22,.76,.24,1) infinite both;
}

/* Particules qui s'échappent */
#accueil .bg-droplet::after,
#accueil .bg-droplet2::after {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(circle at 30% 30%, rgba(255,255,255,0.8) 0%, transparent 40%);
  border-radius: inherit; opacity: 0;
  animation: particle-burst-1 6.5s cubic-bezier(.22,.76,.24,1) infinite both;
}
#accueil .bg-droplet2::after {
  background: radial-gradient(circle at 70% 70%, rgba(255,255,255,0.6) 0%, transparent 50%);
  animation: particle-burst-2 7.5s cubic-bezier(.22,.76,.24,1) infinite both;
}

@keyframes trail-glow-1 {
  0%   { transform: translate(0, 0) scale(1); opacity: 0.3; }
  20%  { transform: translate(-24px, 28px) scale(1.1); opacity: 0.4; }
  40%  { transform: translate(-46px, -18px) scale(1.2); opacity: 0.5; }
  60%  { transform: translate(-30px, 22px) scale(1.1); opacity: 0.4; }
  80%  { transform: translate(-12px, -16px) scale(1.05); opacity: 0.3; }
  100% { transform: translate(0, 0) scale(1); opacity: 0.3; }
}

@keyframes trail-glow-2 {
  0%   { transform: translate(0, 0) scale(1); opacity: 0.25; }
  25%  { transform: translate(22px, -26px) scale(1.1); opacity: 0.35; }
  50%  { transform: translate(36px, -18px) scale(1.2); opacity: 0.4; }
  75%  { transform: translate(18px, -22px) scale(1.1); opacity: 0.3; }
  100% { transform: translate(0, 0) scale(1); opacity: 0.25; }
}

@keyframes particle-burst-1 {
  0%, 85% { opacity: 0; transform: scale(1); }
  90%     { opacity: 0.8; transform: scale(1.3); }
  95%     { opacity: 0.4; transform: scale(1.6); }
  100%    { opacity: 0; transform: scale(2); }
}

@keyframes particle-burst-2 {
  0%, 80% { opacity: 0; transform: scale(1); }
  85%     { opacity: 0.6; transform: scale(1.2); }
  90%     { opacity: 0.3; transform: scale(1.4); }
  100%    { opacity: 0; transform: scale(1.8); }
}

/* Interaction souris (attraction) */
#accueil:hover .bg-droplet {
  animation-play-state: paused;
  transform: translate(calc(var(--mouse-x, 0px) * 0.1), calc(var(--mouse-y, 0px) * 0.1)) !important;
  transition: transform 0.3s ease;
}
#accueil:hover .bg-droplet2 {
  animation-play-state: paused;
  transform: translate(calc(var(--mouse-x, 0px) * -0.08), calc(var(--mouse-y, 0px) * -0.08)) !important;
  transition: transform 0.3s ease;
}

@media (prefers-reduced-motion: reduce) {
  #accueil .bg-droplet, #accueil .bg-droplet2,
  #accueil .bg-droplet::before, #accueil .bg-droplet2::before,
  #accueil .bg-droplet::after, #accueil .bg-droplet2::after { animation: none !important; }
}

@keyframes droplet-wall-1 {
  0%   { transform: translate(-2vw, 0vh) rotate(10deg) scale(1.04, .96); }
  8%   { transform: translate(-4vw, 1vh) rotate(9deg)  scale(1.00, 1.00); }
  25%  { transform: translate(-14vw, -1vh) rotate(12deg) scale(1.02); }
  50%  { transform: translate(-26vw, -2vh) rotate(16deg) scale(1.05); }
  92%  { transform: translate(-4vw, 1vh) rotate(11deg) scale(1.00, 1.00); }
  100% { transform: translate(-2vw, 0vh) rotate(10deg) scale(1.06, .94); } /* squash rebond gauche */
}

@keyframes droplet-wall-2 {
  0%   { transform: translate(2vw, -1vh) rotate(-10deg) scale(1.02, .98); }
  10%  { transform: translate(4vw, -2vh) rotate(-9deg)  scale(1.00, 1.00); }
  35%  { transform: translate(16vw, -3vh) rotate(-12deg) scale(1.03); }
  55%  { transform: translate(24vw, -1vh) rotate(-14deg) scale(1.05); }
  92%  { transform: translate(4vw, -2vh) rotate(-11deg) scale(1.00, 1.00); }
  100% { transform: translate(2vw, -1vh) rotate(-10deg) scale(1.06, .94); } /* squash rebond droite */
}

@media (prefers-reduced-motion: reduce) {
  #accueil .bg-droplet, #accueil .bg-droplet2 { animation: none !important; }
}

/* Override: force 5 or 4 cards per row for .tools while preserving smaller breakpoints.
   This block is placed late to win over earlier duplicated rules. */
.tools { grid-template-columns: repeat(5, minmax(180px, 1fr)) !important; gap: 24px !important; }

@media (max-width: 1500px) {
  /* large screens: 4 cards */
  .tools { grid-template-columns: repeat(4, minmax(180px, 1fr)) !important; }
}

@media (max-width: 1000px) {
  /* medium: 3 cards */
  .tools { grid-template-columns: repeat(3, minmax(160px, 1fr)) !important; gap: 20px !important; }
}

@media (max-width: 760px) {
  /* small: 2 cards */
  .tools { grid-template-columns: repeat(2, minmax(140px, 1fr)) !important; gap: 18px !important; }
}

@media (max-width: 480px) {
  /* very small: single column */
  .tools { grid-template-columns: 1fr !important; gap: 16px !important; }
}


/* --- Nouvelles sections: Certifications & Outils --- */
.certifications { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 20px; }
.certification { text-align: center; position: relative; overflow: hidden; }
.cert-icon { font-size: 2.5rem; margin-bottom: 12px; display: block; }
.cert-badge {
  position: absolute; top: 12px; right: 12px; padding: 4px 8px; border-radius: 12px;
  font-size: 0.75rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.5px;
  background: linear-gradient(135deg, var(--brand), var(--brand-4)); color: #0b1020;
}
.certification:hover { transform: translateY(-6px) scale(1.02); }
.certification:hover .cert-icon { animation: cert-bounce 0.6s ease-in-out; }
@keyframes cert-bounce {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.1); }
}

.tools { grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 16px; }
.tool-item {
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  padding: 20px 12px; border-radius: 12px; background: color-mix(in srgb, var(--card) 60%, transparent);
  backdrop-filter: blur(8px); border: 1px solid color-mix(in srgb, var(--text) 8%, transparent);
  transition: all 0.3s cubic-bezier(.34,1.56,.64,1); cursor: pointer;
}
.tool-icon { font-size: 2rem; margin-bottom: 4px; }
.tool-item span { font-size: 0.9rem; font-weight: 500; color: var(--muted); }
.tool-item:hover {
  transform: translateY(-4px) scale(1.05);
  background: color-mix(in srgb, var(--brand) 12%, var(--card));
  border-color: color-mix(in srgb, var(--brand) 30%, transparent);
}
.tool-item:hover .tool-icon { animation: tool-spin 0.8s ease-in-out; }
@keyframes tool-spin {
  0% { transform: rotate(0deg) scale(1); }
  50% { transform: rotate(180deg) scale(1.1); }
  100% { transform: rotate(360deg) scale(1); }
}

/* --- Section Contact --- */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: start; }
.contact-info h3 { font-size: 1.4rem; margin-bottom: 12px; }
.contact-methods { margin-top: 24px; }
.contact-method {
  display: flex; align-items: center; gap: 16px; margin-bottom: 20px;
  padding: 16px; border-radius: 12px; background: color-mix(in srgb, var(--card) 40%, transparent);
  backdrop-filter: blur(6px); border: 1px solid color-mix(in srgb, var(--text) 6%, transparent);
  transition: all 0.3s ease;
}
.contact-method:hover {
  transform: translateX(8px);
  background: color-mix(in srgb, var(--brand) 8%, var(--card));
  border-color: color-mix(in srgb, var(--brand) 20%, transparent);
}
.method-icon { font-size: 1.5rem; }
.contact-method h4 { margin: 0 0 4px; font-size: 1rem; }
.contact-method p { margin: 0; color: var(--muted); font-size: 0.9rem; }

/* --- Formulaire Contact --- */
.contact-form { display: grid; gap: 20px; }
.form-group {
  position: relative; display: flex; flex-direction: column;
}
.form-group input, .form-group textarea {
  padding: 16px 12px 8px; border: 2px solid color-mix(in srgb, var(--text) 12%, transparent);
  border-radius: 12px; background: color-mix(in srgb, var(--card) 60%, transparent);
  backdrop-filter: blur(8px); color: var(--text); font: inherit;
  transition: all 0.3s cubic-bezier(.34,1.56,.64,1);
}
.form-group label {
  position: absolute; left: 12px; top: 16px; color: var(--muted);
  transition: all 0.3s cubic-bezier(.34,1.56,.64,1); pointer-events: none;
  transform-origin: left;
}
.form-group input:focus, .form-group textarea:focus {
  outline: none; border-color: var(--brand);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 20%, transparent);
}
.form-group input:focus + label, .form-group textarea:focus + label,
.form-group input:not(:placeholder-shown) + label, .form-group textarea:not(:placeholder-shown) + label {
  transform: translateY(-24px) scale(0.85); color: var(--brand);
}
.form-group input::placeholder, .form-group textarea::placeholder { opacity: 0; }

.form-submit {
  position: relative; overflow: hidden; margin-top: 8px;
}
.btn-loading { display: none; }
.form-submit.loading .btn-text { display: none; }
.form-submit.loading .btn-loading { display: inline; }
.form-submit.loading { pointer-events: none; }

@media (max-width: 768px) {
  .contact-grid { grid-template-columns: 1fr; gap: 32px; }
}

.timeline {
  position: relative;
  margin: 2rem auto;
  padding: 2rem 0;
  width: 90%;
}

.timeline::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 6px;
  background: orange; /* ta barre centrale */
  transform: translateX(-50%);
}

.timeline-item {
  position: relative;
  width: 48%; /* légèrement plus large */
  margin: 2rem 0;
}

.timeline-item.left {
  left: calc(50% - 52%); /* rapproche à gauche */
  text-align: right;
}

.timeline-item.right {
  left: 50%; /* commence pile après la barre */
  text-align: left;
}

.timeline-dot {
  position: absolute;
  top: 1rem;
  width: 18px;
  height: 18px;
  background: var(--brand);
  border-radius: 50%;
  border: 3px solid white;
  z-index: 2;
}

.timeline-item.left .timeline-dot {
  right: -38px; /* colle au bord gauche de la ligne */
}

.timeline-item.right .timeline-dot {
  left: -38px; /* colle au bord droit de la ligne */
}

.timeline-content {
  background: var(--surface-2);
  padding: 1rem;
  border-radius: 10px;
  box-shadow: var(--shadow-1);
}

/* ============================================
   MODAL PROJET - Fenêtre popup pour détails
   ============================================ */

.modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 9999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.modal.active {
  display: flex;
  animation: modalFadeIn 0.3s ease;
}

@keyframes modalFadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.modal-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(8px);
  cursor: pointer;
}

.modal-content {
  position: relative;
  width: 100%;
  max-width: 900px;
  max-height: 90vh;
  background: var(--card);
  border-radius: 20px;
  border: 1px solid color-mix(in srgb, var(--text) 10%, transparent);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  overflow: hidden;
  animation: modalSlideUp 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  z-index: 1;
}

@keyframes modalSlideUp {
  from {
    opacity: 0;
    transform: translateY(30px) scale(0.95);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.modal-close {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid color-mix(in srgb, var(--text) 15%, transparent);
  background: var(--card);
  color: var(--text);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  z-index: 10;
}

.modal-close:hover {
  background: #ef4444;
  border-color: #ef4444;
  color: #ffffff;
  transform: rotate(90deg);
}

.modal-body {
  display: flex;
  flex-direction: column;
  max-height: 90vh;
  overflow-y: auto;
}

.modal-image {
  width: 100%;
  height: 280px;
  background-size: cover;
  background-position: center;
  background-color: color-mix(in srgb, var(--text) 5%, var(--card));
  flex-shrink: 0;
}

.modal-info {
  padding: 32px;
}

.modal-title {
  font-size: 2rem;
  font-weight: 800;
  color: var(--text);
  margin: 0 0 8px;
}

.modal-category {
  display: inline-block;
  font-size: 0.9rem;
  color: var(--muted);
  font-weight: 600;
  margin-bottom: 20px;
}

.modal-description {
  font-size: 1.05rem;
  line-height: 1.7;
  color: var(--text);
  margin-bottom: 24px;
}

.modal-details {
  background: color-mix(in srgb, var(--brand) 5%, var(--card));
  border: 1px solid color-mix(in srgb, var(--brand) 15%, transparent);
  border-radius: 12px;
  padding: 20px;
  margin-bottom: 24px;
}

.modal-details h3 {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text);
  margin: 0 0 12px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.modal-details ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.modal-details li {
  padding: 8px 0;
  padding-left: 24px;
  position: relative;
  color: var(--muted);
  line-height: 1.6;
}

.modal-details li:before {
  content: "→";
  position: absolute;
  left: 0;
  color: var(--brand);
  font-weight: 700;
}

.modal-skills {
  margin-bottom: 24px;
}

.modal-skills h3 {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text);
  margin: 0 0 12px;
}

.modal-skills-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.modal-footer {
  padding-top: 20px;
  border-top: 1px solid color-mix(in srgb, var(--text) 10%, transparent);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}

/* ===== NOUVEAU DESIGN PAGE D'ACCUEIL ===== */

/* Masquer les anciens éléments */
.hero-avatar-rings,
.hero-ring {
  display: none !important;
}

/* Nouveau style avatar plus grand */
.hero-avatar-wrapper {
  width: 200px !important;
  height: 200px !important;
  margin-bottom: 20px !important;
}

.hero-avatar {
  width: 200px !important;
  height: 200px !important;
  border: 5px solid var(--brand) !important;
}

.hero-avatar::before {
  display: none !important;
}

/* Hero name - Grand titre avec le nom */
.hero-name {
  font-size: 3.5rem;
  font-weight: 800;
  margin: 0 0 12px;
  background: linear-gradient(135deg, #93c5fd, #7c3aed);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: 0.02em;
  line-height: 1.1;
}

/* Hero role - Sous-titre avec icône bouclier */
.hero-role {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text);
  margin: 8px 0 20px;
  padding: 0;
}

.shield-icon {
  color: var(--brand);
  flex-shrink: 0;
}

/* Hero description - Texte descriptif */
.hero-description {
  font-size: 1.05rem;
  line-height: 1.7;
  color: var(--muted);
  max-width: 720px;
  margin: 0 0 32px;
}

.highlight-blue {
  color: var(--brand);
  font-weight: 600;
}

.highlight-green {
  color: var(--success);
  font-weight: 600;
}

/* Hero CTA Group - Boutons d'action */
.hero-cta-group {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: center;
  align-items: center;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 28px;
  border-radius: 8px;
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  transition: all 0.3s ease;
  cursor: pointer;
  border: 2px solid transparent;
  text-decoration: none;
}

.btn svg {
  flex-shrink: 0;
}

.btn-primary {
  background: var(--brand);
  color: #fff;
  box-shadow: 0 4px 16px color-mix(in srgb, var(--brand) 40%, transparent);
}

.btn-primary:hover {
  background: color-mix(in srgb, var(--brand) 90%, #fff);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px color-mix(in srgb, var(--brand) 50%, transparent);
}

.btn-secondary {
  background: transparent;
  color: var(--text);
  border-color: color-mix(in srgb, var(--text) 30%, transparent);
}

.btn-secondary:hover {
  background: color-mix(in srgb, var(--brand) 10%, transparent);
  border-color: var(--brand);
  color: var(--brand);
  transform: translateY(-2px);
}

@media (max-width: 860px) {
  .hero-avatar-wrapper {
    width: 150px !important;
    height: 150px !important;
  }
  .hero-avatar {
    width: 150px !important;
    height: 150px !important;
    border-width: 4px !important;
  }
  .hero-name {
    font-size: 2.5rem;
  }
  .hero-role {
    font-size: 1rem;
  }
  .hero-description {
    font-size: 0.95rem;
  }
  .hero-cta-group {
    flex-direction: column;
    width: 100%;
  }
  .btn {
    width: 100%;
    justify-content: center;
  }
}

/* Responsive modal */
@media (max-width: 768px) {
  .modal-content {
    max-width: 95%;
    max-height: 95vh;
  }
  
  .modal-info {
    padding: 24px;
  }
  
  .modal-title {
    font-size: 1.5rem;
  }
  
  .modal-image {
    height: 200px;
  }
}

/* === Overview (home) === */
.section-head { text-align: left; max-width: 900px; margin: 0 auto 28px; }
.section-head h2 { margin: 8px 0 6px; font-size: clamp(1.5rem, 1.8vw, 2rem); }
.section-head .section-kicker { display: inline-flex; align-items: center; gap: 6px; padding: 6px 10px; border-radius: 999px; background: color-mix(in srgb, var(--brand) 15%, transparent); color: var(--brand); font-weight: 700; font-size: 0.8rem; letter-spacing: 0.04em; }
.overview-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; }
.overview-card { position: relative; overflow: hidden; }
.overview-card .card-top { display: flex; flex-direction: column; gap: 6px; margin-bottom: 12px; }
.overview-card h3 { margin: 4px 0; }
.chip-list { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; padding: 0; margin: 0; }
.chip { padding: 6px 10px; border-radius: 999px; background: color-mix(in srgb, var(--card) 70%, transparent); border: 1px solid color-mix(in srgb, var(--text) 10%, transparent); font-size: 0.85rem; color: var(--text); }
.impact-grid { margin-top: 24px; display: grid; grid-template-columns: repeat(auto-fit, minmax(220px,1fr)); gap: 12px; }
.impact-card { background: linear-gradient(145deg, color-mix(in srgb, var(--card) 90%, transparent), color-mix(in srgb, var(--card) 82%, transparent)); border: 1px solid color-mix(in srgb, var(--text) 12%, transparent); border-radius: 12px; padding: 14px 16px; box-shadow: var(--shadow-sm); }
.impact-label { font-size: 0.85rem; color: var(--muted); text-transform: uppercase; letter-spacing: 0.04em; }
.impact-value { font-size: 1.4rem; font-weight: 800; margin: 4px 0 6px; color: var(--text); }
.pill { display: inline-flex; align-items: center; gap: 6px; padding: 6px 10px; border-radius: 999px; font-size: 0.78rem; letter-spacing: 0.02em; border: 1px solid transparent; background: color-mix(in srgb, var(--text) 8%, transparent); color: var(--text); width: fit-content; }
.pill.success { background: linear-gradient(135deg, color-mix(in srgb, var(--brand-5) 55%, transparent), color-mix(in srgb, var(--brand) 35%, transparent)); color: #04101e; }
.pill.info { background: linear-gradient(135deg, color-mix(in srgb, var(--brand) 50%, transparent), color-mix(in srgb, var(--brand-2) 40%, transparent)); color: #04101e; }
.pill.warning { background: linear-gradient(135deg, color-mix(in srgb, var(--warning) 60%, transparent), color-mix(in srgb, var(--brand-4) 40%, transparent)); color: #180901; }

@media (max-width: 860px) {
  .impact-grid, .overview-grid { grid-template-columns: 1fr; }
  .section-head { text-align: left; }
}

/* ======================== Compétences Page Enhancements ======================== */

/* Category header with badge */
.category-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
  flex-wrap: wrap;
  gap: 12px;
}

.category-badge {
  font-size: 0.85rem;
  font-weight: 600;
  padding: 6px 14px;
  border-radius: 999px;
  background: linear-gradient(135deg, 
    rgba(var(--brand-rgb), 0.06) 0%, 
    rgba(var(--brand-2-rgb), 0.1) 100%);
  color: color-mix(in srgb, var(--brand) 90%, black);
  border: 1px solid rgba(var(--brand-rgb), 0.12);
}

/* Skill badges (levels) */
.skill-badge {
  font-size: 0.75rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 999px;
  margin-top: 8px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  display: inline-block;
}

.badge-beginner {
  background: linear-gradient(135deg, #e8f4fd 0%, #d0e9fc 100%);
  color: #1565c0;
  border: 1px solid #bbdefb;
}

.badge-intermediate {
  background: linear-gradient(135deg, #fff8e1 0%, #ffecb3 100%);
  color: #ef6c00;
  border: 1px solid #ffd54f;
}

.badge-advanced {
  background: linear-gradient(135deg, #f8e8fa 0%, #ead1ec 100%);
  color: #6a1b9a;
  border: 1px solid #ce93d8;
}

.badge-expert {
  background: linear-gradient(135deg, #f1f8e9 0%, #dcedc8 100%);
  color: #2e7d32;
  border: 1px solid #9ccc65;
}

/* Skill progress bars */
.skill-bar {
  width: 100%;
  height: 8px;
  background: color-mix(in srgb, var(--text) 5%, transparent);
  border-radius: 999px;
  overflow: hidden;
  margin-top: 12px;
  position: relative;
}

.skill-progress {
  height: 100%;
  background: linear-gradient(90deg, 
    color-mix(in srgb, var(--brand) 90%, white) 0%, 
    color-mix(in srgb, var(--brand-2) 90%, white) 50%,
    color-mix(in srgb, var(--brand-3) 90%, white) 100%);
  border-radius: 999px;
  transition: width 1s cubic-bezier(0.4, 0, 0.2, 1);
  animation: progressGlow 2s ease-in-out infinite;
  position: relative;
}

@keyframes progressGlow {
  0%, 100% {
    box-shadow: 0 0 6px rgba(var(--brand-rgb), 0.2);
  }
  50% {
    box-shadow: 0 0 12px rgba(var(--brand-rgb), 0.4);
  }
}

.tool-item:hover .skill-progress {
  background: linear-gradient(90deg, 
    color-mix(in srgb, var(--brand-2) 85%, white) 0%, 
    color-mix(in srgb, var(--brand-3) 85%, white) 50%,
    color-mix(in srgb, var(--brand) 85%, white) 100%);
}

/* Soft Skills Section */
.soft-skills-section {
  margin-top: 60px;
  padding-top: 40px;
  border-top: 1px solid color-mix(in srgb, var(--text) 8%, transparent);
}

.soft-skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 28px;
  margin-top: 32px;
}

.soft-skill-item {
  padding: 32px 24px;
  background: var(--card);
  border: 1px solid color-mix(in srgb, var(--text) 8%, transparent);
  border-radius: 16px;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
  text-align: center;
}

.soft-skill-item:hover {
  transform: translateY(-6px);
  border-color: color-mix(in srgb, var(--brand) 25%, transparent);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.1);
  background: color-mix(in srgb, var(--card) 100%, white 5%);
}

.soft-skill-icon {
  font-size: 3rem;
  margin-bottom: 16px;
  filter: grayscale(0.2);
  transition: all 0.3s ease;
}

.soft-skill-item:hover .soft-skill-icon {
  filter: grayscale(0);
  transform: scale(1.1);
}

.soft-skill-item h4 {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 12px;
  transition: color 0.3s ease;
}

.soft-skill-item:hover h4 {
  color: var(--brand);
}

.soft-skill-item p {
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--muted);
  margin: 0;
}

/* Dark mode adjustments for badges */
:root[data-theme="dark"] .badge-beginner {
  background: linear-gradient(135deg, #264b73 0%, #326a99 100%);
  color: #a8d5ff;
  border-color: #3d6f95;
}

:root[data-theme="dark"] .badge-intermediate {
  background: linear-gradient(135deg, #735e26 0%, #998332 100%);
  color: #ffd699;
  border-color: #95782d;
}

:root[data-theme="dark"] .badge-advanced {
  background: linear-gradient(135deg, #5e2673 0%, #833299 100%);
  color: #e6a8ff;
  border-color: #78409f;
}

:root[data-theme="dark"] .badge-expert {
  background: linear-gradient(135deg, #267348 0%, #32995e 100%);
  color: #a8ffc8;
  border-color: #3d8f62;
}

/* Responsive adjustments */
@media (max-width: 1200px) {
  .tools {
    grid-template-columns: repeat(4, minmax(200px, 1fr));
  }
}

@media (max-width: 960px) {
  .tools {
    grid-template-columns: repeat(3, minmax(180px, 1fr));
    gap: 20px;
  }
  
  .soft-skills-grid {
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
  }
}

@media (max-width: 768px) {
  .tools {
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
  }
  
  .tool-item {
    padding: 20px 16px;
  }
  
  .tools .skill-icon, 
  .tools .tool-icon {
    width: 56px;
    height: 56px;
  }
  
  .category-header {
    flex-direction: column;
    align-items: flex-start;
  }
  
  .soft-skills-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .tools {
    grid-template-columns: 1fr;
  }
}

/* ========================================
   PAGE D'ACCUEIL - DESIGN PROFESSIONNEL AÉRÉ
   ======================================== */

.container-pro {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 40px;
}

/* Hero Section avec Photo */
.hero-section {
  padding: 80px 0;
  border-bottom: 1px solid color-mix(in srgb, var(--text) 8%, transparent);
}

.hero-profile {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 60px;
  align-items: start;
}

.profile-image-wrapper {
  position: sticky;
  top: 120px;
}

.profile-img {
  width: 200px;
  height: 200px;
  border-radius: 12px;
  object-fit: cover;
  display: block;
  border: 1px solid color-mix(in srgb, var(--text) 10%, transparent);
}

.profile-content {
  padding-top: 8px;
}

.display-name {
  font-size: clamp(2.5rem, 4vw, 3.2rem);
  font-weight: 700;
  margin: 0 0 12px;
  color: var(--text);
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.role-title {
  font-size: clamp(1.2rem, 2vw, 1.4rem);
  color: var(--text);
  margin: 0 0 8px;
  font-weight: 500;
  opacity: 0.85;
}

.current-status {
  font-size: 0.95rem;
  color: var(--muted);
  margin: 0 0 32px;
  font-weight: 400;
}

.current-status a {
  color: var(--brand);
  text-decoration: none;
  border-bottom: 1px solid color-mix(in srgb, var(--brand) 30%, transparent);
  transition: border-color 0.2s ease;
}

.current-status a:hover {
  border-bottom-color: var(--brand);
}

.hero-description {
  margin-bottom: 32px;
}

.hero-description p {
  font-size: 1.05rem;
  line-height: 1.75;
  color: var(--text);
  margin: 0;
  opacity: 0.88;
}

.hero-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.btn-clean {
  display: inline-block;
  padding: 12px 24px;
  font-size: 0.9rem;
  font-weight: 500;
  text-decoration: none;
  border: 1px solid color-mix(in srgb, var(--text) 15%, transparent);
  border-radius: 6px;
  color: var(--text);
  background: transparent;
  transition: all 0.2s ease;
}

.btn-clean:hover {
  border-color: var(--text);
  background: color-mix(in srgb, var(--text) 4%, transparent);
}

.btn-clean.primary {
  background: var(--text);
  color: var(--bg);
  border-color: var(--text);
}

.btn-clean.primary:hover {
  background: var(--brand);
  border-color: var(--brand);
  color: #ffffff;
}

/* Stats Section */
.stats-section {
  padding: 80px 0;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 60px;
  flex-wrap: wrap;
  border-bottom: 1px solid color-mix(in srgb, var(--text) 8%, transparent);
}

.stat-item-clean {
  text-align: center;
}

.stat-value-clean {
  font-size: 3rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 8px;
  line-height: 1;
}

.stat-label-clean {
  font-size: 0.88rem;
  color: var(--muted);
  font-weight: 400;
  line-height: 1.4;
  max-width: 160px;
}

.stat-separator {
  width: 1px;
  height: 60px;
  background: color-mix(in srgb, var(--text) 12%, transparent);
}

/* Expertise Section */
.expertise-section {
  padding: 80px 0 100px;
}

.section-heading {
  font-size: 1.8rem;
  font-weight: 600;
  margin: 0 0 60px;
  color: var(--text);
  letter-spacing: -0.01em;
}

.expertise-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 48px;
}

.expertise-card {
  padding: 0;
  position: relative;
}

.expertise-number {
  font-size: 3.5rem;
  font-weight: 800;
  color: color-mix(in srgb, var(--text) 8%, transparent);
  margin: 0 0 16px;
  line-height: 1;
  letter-spacing: -0.02em;
}

.expertise-card h3 {
  font-size: 1.3rem;
  font-weight: 600;
  margin: 0 0 16px;
  color: var(--text);
  letter-spacing: -0.01em;
}

.expertise-card p {
  font-size: 0.95rem;
  line-height: 1.7;
  color: var(--muted);
  margin: 0;
}

/* Responsive */
@media (max-width: 968px) {
  .hero-profile {
    grid-template-columns: 160px 1fr;
    gap: 40px;
  }
  
  .profile-img {
    width: 160px;
    height: 160px;
  }
}

@media (max-width: 768px) {
  .container-pro {
    padding: 0 24px;
  }
  
  .hero-section {
    padding: 60px 0;
  }
  
  .hero-profile {
    grid-template-columns: 1fr;
    gap: 32px;
    text-align: center;
  }
  
  .profile-image-wrapper {
    position: static;
    display: flex;
    justify-content: center;
  }
  
  .profile-img {
    width: 180px;
    height: 180px;
  }
  
  .hero-actions {
    justify-content: center;
  }
  
  .stats-section {
    padding: 60px 0;
    gap: 40px;
  }
  
  .stat-separator {
    width: 1px;
    height: 50px;
  }
  
  .expertise-section {
    padding: 60px 0 80px;
  }
  
  .section-heading {
    margin-bottom: 40px;
    text-align: center;
  }
  
  .expertise-grid {
    grid-template-columns: 1fr;
    gap: 56px;
  }
}

@media (max-width: 580px) {
  .stats-section {
    flex-direction: column;
    gap: 32px;
    padding: 50px 0;
  }
  
  .stat-separator {
    width: 60px;
    height: 1px;
  }
  
  .hero-actions {
    flex-direction: column;
    width: 100%;
  }
  
  .btn-clean {
    text-align: center;
    width: 100%;
  }
}

@media (max-width: 480px) {
  .container-pro {
    padding: 0 20px;
  }
  
  .hero-section {
    padding: 40px 0;
  }
  
  .display-name {
    font-size: 2rem;
  }
  
  .role-title {
    font-size: 1.1rem;
  }
  
  .hero-description p {
    font-size: 0.98rem;
  }
  
  .section-heading {
    font-size: 1.5rem;
    margin-bottom: 32px;
  }
  
  .stat-value-clean {
    font-size: 2.5rem;
  }
  
  .expertise-number {
    font-size: 2.8rem;
  }
  
  .expertise-card h3 {
    font-size: 1.15rem;
  }
}
