/* ============================================================
   YUCE ENGIN — style.css (Enhanced)
   Architecture : Custom properties → Reset → Layout → Components → Animations → Responsive
   ============================================================ */

/* ─── FONTS ───────────────────────────────────────────────── */
/* Police d'affichage = Inter 700/800 (chargée via Google Fonts dans le <head>).
   L'ancien @font-face 'Stack Sans Headline' pointait vers un fichier absent → retiré. */

/* ─── CUSTOM PROPERTIES ──────────────────────────────────── */
:root {
  /* Colors */
  --clr-bg:        #050505;
  --clr-surface:   #0c0c0c;
  --clr-text:      #f0f0f0;
  --clr-muted:     #a0a0a0;
  --clr-accent:    #E5D1A4;
  --clr-line:      rgba(255, 255, 255, 0.08);

  /* Typography */
  --font-display: 'Inter', sans-serif;
  --font-body:    'Inter', sans-serif;

  /* Spacing */
  --space-sm:  15px;
  --space-md:  40px;
  --space-lg:  60px;
  --space-xl:  100px;
  --px:        6vw;

  /* Border radius */
  --r-sm:   4px;
  --r-md:   20px;
  --r-lg:   50px;
  --r-full: 50%;

  /* Transitions */
  --t-fast:   0.3s ease;
  --t-smooth: 0.5s ease;

  /* Carousel */
  --carousel-slide-w: min(850px, 85vw);
}

/* ─── LIGHT THEME ────────────────────────────────────────── */
[data-theme="light"] {
  --clr-bg:     #F2F0EB;
  --clr-surface:#e8e5df;
  --clr-text:   #1a1a1a;
  --clr-muted:  #5a5a5a;
  --clr-accent: #7d6029; /* or assombri pour passer WCAG AA (~5:1) sur fond clair */
  --clr-line:   rgba(0, 0, 0, 0.1);
}

/* Header light : fond clair au lieu du gradient noir */
[data-theme="light"] .main-header {
  background: linear-gradient(180deg, rgba(242,240,235,0.96) 0%, transparent 100%);
}

/* Lang button light : plus sombre pour contraste sur fond clair */
[data-theme="light"] .lang-btn {
  border-color: #7a6535;
  color: #7a6535;
}
[data-theme="light"] .lang-btn:hover {
  background: #7a6535;
  color: #fff;
}

/* Section travaux light : séparateurs et couleurs hardcodées en blanc → remplacées */
[data-theme="light"] .project-row {
  border-bottom-color: rgba(0,0,0,0.1);
}
[data-theme="light"] .project-number {
  color: rgba(0,0,0,0.5);
}
[data-theme="light"] .case-flag {
  color: #7a6535;
  border-color: rgba(122,101,53,0.45);
}
[data-theme="light"] .project-row:hover .project-tag {
  border-color: rgba(122,101,53,0.4);
}

/* Label section "Travaux sélectionnés" light */
[data-theme="light"] .section-label {
  color: #7a6535;
}

/* Footer / email light */
[data-theme="light"] 

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

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
}

body {
  background-color: var(--clr-bg);
  color: var(--clr-text);
  font-family: var(--font-body);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  transition: background-color var(--t-smooth), color var(--t-smooth);
}

img {
  display: block;
  max-width: 100%;
}

/* ─── ACCESSIBILITÉ : focus clavier visible ──────────────── */
:focus-visible {
  outline: 2px solid var(--clr-accent);
  outline-offset: 3px;
  border-radius: 3px;
}
a:focus-visible,
button:focus-visible,
.project-row:focus-visible {
  outline: 2px solid var(--clr-accent);
  outline-offset: 4px;
}
/* on n'affiche pas le contour pour les clics souris */
:focus:not(:focus-visible) { outline: none; }

/* ─── ACCESSIBILITÉ : prefers-reduced-motion ─────────────── */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
  /* éléments purement décoratifs et animés : on les retire */
  .particles-canvas,
  .interactive-glow,
  .noise-overlay { display: none !important; }
  .preloader { display: none !important; }
}

a {
  color: inherit;
  text-decoration: none;
}

ul, ol {
  list-style: none;
}

/* ─── GRAIN OVERLAY ──────────────────────────────────────── */
.noise-overlay {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 10000;
  opacity: 0.05;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ─── CURSOR GLOW ────────────────────────────────────────── */
.interactive-glow {
  position: fixed;
  width: 700px;
  height: 700px;
  background: radial-gradient(circle, rgba(229, 209, 164, 0.22) 0%, transparent 65%);
  border-radius: var(--r-full);
  filter: blur(90px);
  z-index: -1;
  pointer-events: none;
  transform: translate(-50%, -50%);
  will-change: left, top;
}

/* ─── PRELOADER ──────────────────────────────────────────── */
.preloader {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  pointer-events: none;
}

.curtain-panel {
  height: 100%;
  width: 50%;
  background-color: var(--clr-surface);
  display: flex;
  align-items: center;
  overflow: hidden;
}

.left-panel  { justify-content: flex-end; padding-right: 10px; border-right: 1px solid #222; }
.right-panel { justify-content: flex-start; padding-left: 10px; }

.letter {
  font-family: var(--font-display);
  font-size: clamp(3rem, 6vw, 6rem);
  font-weight: 700;
  color: var(--clr-accent);
  display: inline-block;
  opacity: 0;
  transform: translateY(50px);
}

/* ────────────────────────────────────────────────────────────
   HERO — Améliorations ciblées
──────────────────────────────────────────────────────────── */

/* Badge disponibilité */
.hero-avail {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #7ebb8a;
}
.hero-avail__dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #7ebb8a;
  box-shadow: 0 0 0 0 rgba(126, 187, 138, 0.5);
  animation: pulse-dot 2.2s ease-in-out infinite;
}
@keyframes pulse-dot {
  0%, 100% { box-shadow: 0 0 0 0 rgba(126,187,138,0.5); }
  50%       { box-shadow: 0 0 0 6px rgba(126,187,138,0); }
}

/* Photo : glow ambient + outline fin */

.profile-photo-circle::before {
  content: '';
  position: absolute;
  inset: -18px;
  border-radius: var(--r-full);
  background: radial-gradient(circle, rgba(229,209,164,0.18) 0%, transparent 70%);
  z-index: 0;
  animation: photo-glow 4s ease-in-out infinite alternate;
}
.profile-photo-circle::after {
  content: '';
  position: absolute;
  inset: -1px;
  border-radius: var(--r-full);
  border: 1px solid rgba(229,209,164,0.2);
  z-index: 2;
  pointer-events: none;
}
.profile-photo-circle img,
.profile-photo-circle picture {
  position: relative;
  z-index: 1;
  border-radius: var(--r-full);
  display: block;
}
@keyframes photo-glow {
  from { opacity: 0.6; transform: scale(0.97); }
  to   { opacity: 1.0; transform: scale(1.03); }
}

/* Skills — tags visuels */


/* ════════════════════════════════════════════════════════════
   HERO V2 — Portrait centré / Ghost text / Barre basse
════════════════════════════════════════════════════════════ */
.hero-v2 {
  position: relative;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  overflow: visible;
  padding: 80px var(--px) 120px;
}

/* Ghost text fond */
.hv2-ghost {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0;
  pointer-events: none;
  z-index: 0;
  user-select: none;
}
.hv2-ghost__line {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(6rem, 18vw, 16rem);
  text-transform: uppercase;
  letter-spacing: -0.02em;
  color: var(--clr-text);
  opacity: 0.06;
  line-height: 0.9;
  white-space: nowrap;
}
.hv2-ghost__line--top { align-self: flex-start; padding-left: 2vw; }
.hv2-ghost__line--bot { align-self: flex-end;   padding-right: 2vw; }

/* Portrait */
.hv2-portrait-wrap {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  width: fit-content;
  margin: 0 auto;
}

/* Conteneur interne (frame + badge + coins) */
.hv2-portrait-inner {
  position: relative;
  display: flex;
  justify-content: center;
  width: 100%;
}
.hv2-portrait-frame {
  position: relative;
  width: clamp(240px, 26vw, 380px);
  aspect-ratio: 3/4;
  border-radius: 16px;
  overflow: hidden;
  background: transparent;
  flex-shrink: 0;
}
.hv2-portrait-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  display: block;
}

/* Nom en dehors du cadre */
.hv2-portrait-name {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(3rem, 8vw, 7.5rem);
  letter-spacing: -0.03em;
  text-transform: uppercase;
  color: var(--clr-text);
  white-space: nowrap;
  text-align: center;
  margin-top: 16px;
  line-height: 1;
  width: 100%;
  overflow: visible;
}


/* Approche inline sous les tags */
.hv2-approach {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 8px;
  margin-top: 24px;
  max-width: 40ch;
}

/* Tags expertise sous le nom */
.hv2-expertise-tags {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 10px;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--clr-muted);
  opacity: 0.6;
}
.hv2-expertise-tags__sep {
  color: var(--clr-accent);
  opacity: 0.5;
}

/* Dégradé bas de la photo */
.hv2-portrait-fade { display: none; }

/* Badge circulaire */
.hv2-badge {
  position: absolute;
  bottom: -18px;
  right: -18px;
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: var(--clr-surface);
  border: 1px solid rgba(229,209,164,0.25);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  z-index: 3;
}
.hv2-badge__year {
  font-size: 0.48rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--clr-muted);
}
.hv2-badge__dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #7ebb8a;
  box-shadow: 0 0 0 0 rgba(126,187,138,0.5);
  animation: pulse-dot 2.2s ease-in-out infinite;
}
.hv2-badge__status {
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--clr-accent);
}

/* Barre basse */
.hv2-bottom {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  padding: 24px 6vw;
  border-top: 1px solid var(--clr-line);
  background: linear-gradient(to top, rgba(5,5,5,0.92) 0%, transparent 100%);
  z-index: 4;
}

.hv2-col {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.hv2-col--center { position: absolute; left: 50%; transform: translateX(-50%); align-items: center; text-align: center; border-left: none; border-right: none; padding: 0; }
.hv2-col--right  { align-items: flex-end; }

.hv2-col__label {
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--clr-accent);
  opacity: 0.75;
}
.hv2-col__list {
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.hv2-col__list li {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--clr-text);
}
.hv2-col__text {
  font-size: 0.85rem;
  line-height: 1.6;
  color: var(--clr-muted);
  max-width: 36ch;
}

/* CTA pill */
.hv2-cta-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--clr-accent);
  color: var(--clr-bg);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 14px 28px;
  border-radius: var(--r-lg);
  transition: box-shadow var(--t-fast), transform var(--t-fast);
  white-space: nowrap;
}
.hv2-cta-pill:hover {
  box-shadow: 0 10px 30px rgba(229,209,164,0.25);
  transform: translateY(-2px);
}


/* Coins décoratifs */
.hv2-corner {
  position: absolute;
  width: 20px;
  height: 20px;
  z-index: 4;
}
.hv2-corner--tl { top: -8px;  left: -8px;  border-top: 1px solid var(--clr-accent); border-left: 1px solid var(--clr-accent); }
.hv2-corner--tr { top: -8px;  right: -8px; border-top: 1px solid var(--clr-accent); border-right: 1px solid var(--clr-accent); }

/* Lignes déco verticales latérales */
.hv2-deco-line {
  position: absolute;
  top: 0; bottom: 0;
  width: 1px;
  background: linear-gradient(to bottom, transparent, rgba(229,209,164,0.3), transparent);
  display: flex;
  align-items: center;
  z-index: 1;
}
.hv2-deco-line--left  { left: -40px; }
.hv2-deco-line--right { right: -40px; }
.hv2-deco-line__label {
  writing-mode: vertical-rl;
  font-size: 0.55rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--clr-muted);
  opacity: 0.5;
  white-space: nowrap;
}

/* Responsive mobile */
/* ── Hero V2 responsive ────────────────────────────── */
@media (max-width: 768px) {

  /* Hero section */
  .hero-v2 {
    padding: 80px var(--px) 140px;
    justify-content: flex-start;
  }

  /* Ghost text plus petit */
  .hv2-ghost__line {
    font-size: clamp(3.5rem, 20vw, 7rem);
  }

  /* Portrait */
  .hv2-portrait-frame {
    width: min(72vw, 300px);
  }

  /* Badge repositionné */
  .hv2-badge {
    bottom: -14px;
    right: -14px;
    width: 68px;
    height: 68px;
  }

  /* Nom : plus petit, pas de débordement */
  .hv2-portrait-name {
    font-size: clamp(2.4rem, 13vw, 5rem);
    white-space: normal;
    word-break: break-word;
    text-align: center;
  }

  /* Tags expertise */
  .hv2-expertise-tags {
    font-size: 0.62rem;
    gap: 8px;
  }

  /* Approche */
  .hv2-approach {
    margin-top: 16px;
    max-width: 100%;
    padding: 0 8px;
  }

  /* Lignes déco latérales : masquées sur mobile */
  .hv2-deco-line {
    display: none;
  }

  /* Barre basse : CTA centré */
  .hv2-bottom {
    justify-content: center;
    padding: 16px var(--px);
  }

  /* CTA pill plus compact */
  .hv2-cta-pill {
    font-size: 0.75rem;
    padding: 12px 22px;
  }
}

@media (max-width: 390px) {
  .hv2-portrait-frame { width: 82vw; }
  .hv2-portrait-name  { font-size: 2.2rem; }
  .hv2-ghost__line    { font-size: 3rem; }
}


/* ─── HEADER ─────────────────────────────────────────────── */
.main-header {
  position: fixed;
  inset: 0 0 auto;
  padding: 30px var(--px);
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 1000;
  background: linear-gradient(180deg, rgba(0,0,0,0.75) 0%, transparent 100%);
  backdrop-filter: blur(10px);
  pointer-events: none;
}

.main-header > * { pointer-events: auto; }

.logo {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.5rem;
  color: var(--clr-text);
  transition: color var(--t-fast);
  transform-origin: center;
  will-change: transform;
}

.logo:hover { color: var(--clr-accent); }
.dot         { color: var(--clr-accent); }

.main-header nav {
  display: flex;
  align-items: center;
  gap: var(--space-md);
}

.nav-links {
  display: flex;
  gap: var(--space-md);
}

.nav-links a {
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-weight: 500;
  color: var(--clr-text);
  position: relative;
  transition: color var(--t-fast);
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--clr-accent);
  transition: width var(--t-fast);
}

.nav-links a:hover         { color: var(--clr-accent); }
.nav-links a:hover::after  { width: 100%; }

/* ─── LANG BUTTON ───────────────────────────────────────── */
.lang-btn {
  background: transparent;
  border: 1px solid var(--clr-accent);
  color: var(--clr-accent);
  font-family: var(--font-body);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  padding: 4px 10px;
  border-radius: var(--r-sm);
  cursor: pointer;
  transition: background var(--t-fast), color var(--t-fast);
  line-height: 1;
}

.lang-btn:hover {
  background: var(--clr-accent);
  color: var(--clr-bg);
}

/* ─── THEME SWITCH ───────────────────────────────────────── */
.switch-wrapper {
  display: flex;
  align-items: center;
  margin-left: 20px;
}

/* Sun / Moon pill toggle */
.darkmode-input {
  width: 0;
  height: 0;
  visibility: hidden;
  position: absolute;
}

.darkmode-label {
  width: 100px;
  height: 48px;
  position: relative;
  display: block;
  background: #e8e0cc;
  border-radius: 200px;
  box-shadow: inset 0px 4px 12px rgba(0,0,0,0.3), inset 0px -4px 12px rgba(255,255,255,0.3);
  cursor: pointer;
  transition: background 0.3s;
  flex-shrink: 0;
}

.darkmode-label::after {
  content: "";
  width: 40px;
  height: 40px;
  position: absolute;
  top: 4px;
  left: 4px;
  background: linear-gradient(180deg, #ffcc89, #d8860b);
  border-radius: 40px;
  box-shadow: 0px 4px 10px rgba(0,0,0,0.25);
  transition: 0.3s;
}

.darkmode-input:checked + .darkmode-label {
  background: #242424;
}

.darkmode-input:checked + .darkmode-label::after {
  left: calc(100% - 4px);
  transform: translateX(-100%);
  background: linear-gradient(180deg, #777, #3a3a3a);
}

.darkmode-label:active::after {
  width: 52px;
}

.toggle-sun,
.toggle-moon {
  position: absolute;
  width: 20px;
  height: 20px;
}

.toggle-sun {
  left: 13px;
  top: 13px;
  color: #7e7e7e;
}

.toggle-moon {
  right: 13px;
  top: 13px;
  color: #fff;
  animation: moonGlow 2.5s ease-in-out infinite;
}

/* Light mode (unchecked): sun glows, moon dims */
.darkmode-input:not(:checked) + .darkmode-label .toggle-sun {
  color: #fff;
  animation: sunGlow 2.5s ease-in-out infinite;
}

.darkmode-input:not(:checked) + .darkmode-label .toggle-moon {
  color: #7e7e7e;
  animation: none;
}

@keyframes sunGlow {
  0%, 100% { filter: drop-shadow(0 0 3px #ffcc89) drop-shadow(0 0 7px #d8860b); }
  50%       { filter: drop-shadow(0 0 7px #ffe5a8) drop-shadow(0 0 14px #ffaa00); }
}

@keyframes moonGlow {
  0%, 100% { filter: drop-shadow(0 0 3px #c8d8ff) drop-shadow(0 0 7px #8899cc); }
  50%       { filter: drop-shadow(0 0 7px #dce8ff) drop-shadow(0 0 14px #aabbee); }
}

/* ─── HERO ───────────────────────────────────────────────── */
.hero-section {
  min-height: 100svh;
  padding: 0 var(--px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  position: relative;
}

.hero-grid {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5vw;
}

.char {
  opacity: 0;
  display: inline-block;
  will-change: opacity;
}


/* Separator */
.vertical-separator {
  width: 1px;
  height: 400px;
  background-color: var(--clr-accent);
  opacity: 0.3;
  margin-right: var(--space-md);
  transform: scaleY(0);
  transform-origin: top;
  flex-shrink: 0;
}

/* Scroll indicator */
.hero-footer {
  position: absolute;
  bottom: 30px;
  left: var(--px);
}

.scroll-indicator {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  font-size: 0.8rem;
  text-transform: uppercase;
  color: var(--clr-muted);
  animation: bounce 2s ease-in-out infinite;
}

.line-down {
  width: 1px;
  height: 40px;
  background-color: var(--clr-muted);
}

/* ════════════════════════════════════════════
   HERO MINIMAL — section complète
════════════════════════════════════════════ */
.hero-minimal {
  position: relative;
  width: 100%;
  height: 65vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: transparent;
  margin-top:-100px;
}

/* ── Texte masque SVG ── */
.clip-wrap {
  position: relative;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.clip-svg {
  width: 100%;
  height: auto;
  display: block;
  overflow: visible;
}

.clip-fill {
  fill: url(#gradAnim);
}

/* ── Ligne de séparation au-dessus ── */
.minimal-rule {
  width: 1px;
  height: 60px;
  background: linear-gradient(to bottom, transparent, var(--clr-accent));
  margin-bottom: 40px;
  opacity: 0;
  animation: fadeIn 1s ease 0.4s forwards;
}

/* ── Sous-titre sous le texte masque ── */
.minimal-meta {
  display: flex;
  align-items: center;
  gap: 32px;
  margin-top: 48px;
  opacity: 0;
  animation: fadeIn 1s ease 0.8s forwards;
}

.minimal-stat {
  text-align: center;
}

.minimal-stat-number {
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  font-weight: 300;
  color: var(--clr-accent);
  line-height: 1;
  letter-spacing: -0.02em;
  display: block;
  will-change: transform, color;
}

.minimal-stat-label {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--clr-muted);
  margin-top: 6px;
  display: block;
}

.minimal-divider {
  width: 1px;
  height: 36px;
  background: rgba(255,255,255,0.12);
}

/* ── Scroll hint ── */


.minimal-scroll span {
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--clr-muted);
}

.scroll-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--clr-accent);
  animation: pulseDot 1.6s ease-in-out infinite;
}

/* ── Particules de fond ── */
.particles-canvas {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  opacity: 0.4;
}

/* ── Z-index stack ── */
.clip-wrap   { z-index: 1; }
.minimal-meta  { z-index: 1; }
.minimal-rule  { z-index: 1; }
.minimal-scroll { z-index: 1; }

/* ── Keyframes ── */
@keyframes fadeIn {
  to { opacity: 1; }
}

@keyframes pulseDot {
  0%, 100% { transform: scale(1);   opacity: 1; }
  50%       { transform: scale(1.6); opacity: 0.4; }
}

/* ── Responsive ── */
@media (max-width: 600px) {
  .minimal-meta { gap: 20px; }
  .minimal-stat-number { font-size: 1.4rem; }
}

/* ─── EDITORIAL PROFILE ──────────────────────────────────── */
.editorial-profile {
  flex: 0 0 auto;
  padding-right: 4vw;
  opacity: 0;
  transform: translateX(50px);
}

.profile-layout {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  text-align: right;
}

.profile-info-block {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  max-width: 300px;
}

.profile-identity h3 {
  font-family: 'Inter', sans-serif;
  font-weight: 800;
  letter-spacing: -0.02em;
  font-size: 5.5rem;
  line-height: 0.8;
  margin-top: -125px;
  margin-bottom: 10px;
  text-shadow: 0 0 30px rgba(229,209,164,0.35), 0 0 80px rgba(229,209,164,0.1);
}

.job-title {
  font-size: 1.1rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--clr-accent);
  font-weight: 600;
}

.profile-bio {
  font-size: 1.3rem;
  line-height: 1.5;
  color: var(--clr-muted);
  margin: 20px 0 30px;
}

.profile-photo-circle {
  width: 300px;
  height: 380px;
  flex-shrink: 0;
  -webkit-mask-image: linear-gradient(to bottom, black 50%, transparent 92%);
  mask-image: linear-gradient(to bottom, black 50%, transparent 92%);
  animation: float 6s ease-in-out infinite;
}

.profile-photo-circle img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  filter: grayscale(10%);
  transition: filter var(--t-smooth), transform var(--t-smooth);
}

.profile-photo-circle:hover img {
  filter: grayscale(0%);
  transform: scale(1.03);
}

/* Skills */
.clean-skills {
  display: flex;
  gap: var(--space-sm);
  margin-bottom: 30px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.clean-skills li {
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  color: var(--clr-muted);
  border: 1px solid var(--clr-line);
  padding: 5px 12px;
  border-radius: 20px;
  transition: border-color var(--t-fast), color var(--t-fast), background var(--t-fast);
}

.clean-skills li:hover {
  border-color: var(--clr-accent);
  color: var(--clr-accent);
  background: rgba(229,209,164,0.06);
}

.link-clean {
  color: var(--clr-accent);
  font-size: 1.2rem;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  flex-direction: row-reverse;
  transition: gap var(--t-fast);
}

.link-clean:hover { gap: 20px; }

/* ─── PROJECTS — EDITORIAL ───────────────────────────────── */
.projects-editorial {
  padding: var(--space-xl) var(--px);
}

.section-label {
  font-family: var(--font-body);
  font-size: 0.9rem;
  color: var(--clr-accent);
  text-transform: uppercase;
  letter-spacing: 2px;
  margin-bottom: 12px;
}

.section-divider {
  width: 100%;
  height: 1px;
  background: var(--clr-line);
  margin-bottom: 0;
}

.project-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 28px 0;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  position: relative;
  transition: padding-left 0.4s cubic-bezier(0.65, 0, 0.35, 1);
  color: inherit;
}

.project-row:hover  { padding-left: 20px; }

/* Feedback tactile mobile */
.project-row:active {
  transform: scale(0.985);
  background: rgba(229,209,164,0.03);
  transition: transform 0.1s ease, background 0.1s ease;
}

.project-row-left {
  display: flex;
  align-items: baseline;
  gap: 28px;
}

.project-number {
  font-family: var(--font-display);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 2px;
  min-width: 30px;
  color: rgba(229,209,164,0.6);
  transform-origin: left center;
  transition: color var(--t-fast);
  will-change: transform, color;
  transform-origin: left center;
}

.project-row:hover .project-number { color: var(--clr-accent); }

.project-name {
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 4vw, 2.8rem);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: -0.02em;
  line-height: 1;
  transition: color var(--t-fast);
  will-change: color;
}

.project-row:hover .project-name { color: var(--clr-accent); }

.project-row-right {
  display: flex;
  align-items: center;
  gap: 40px;
}

.project-tags {
  display: flex;
  gap: 10px;
  justify-content: flex-end;
}

.project-tag {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--clr-muted);
  border: 1px solid var(--clr-line);
  padding: 5px 12px;
  border-radius: var(--r-lg);
  white-space: nowrap;
  transition: border-color var(--t-fast), color var(--t-fast);
  will-change: transform, border-color, color;
}

.project-row:hover .project-tag {
  border-color: rgba(229,209,164,0.4);
  color: var(--clr-accent);
}

.project-arrow {
  font-size: 1.2rem;
  color: var(--clr-muted);
  transition: color var(--t-fast);
  will-change: transform;
}

.project-row:hover .project-arrow {
  color: var(--clr-accent);
}

.year-badge {
  font-size: 0.7rem;
  color: var(--clr-muted);
  letter-spacing: 1px;
  text-transform: uppercase;
}

.case-flag {
  font-size: 0.62rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--clr-accent);
  border: 1px solid rgba(229,209,164,0.4);
  border-radius: var(--r-lg);
  padding: 4px 11px;
  white-space: nowrap;
}

/* ─── FLOATING PREVIEW (Enhanced) ────────────────────────── */
.floating-preview {
  position: fixed;
  width: 320px;
  height: 200px;
  border-radius: 6px;
  overflow: hidden;
  pointer-events: none;
  z-index: 9999;
  opacity: 0;
  transform: scale(0.88) rotate(-2deg);
  transition: none;
  box-shadow: 0 20px 60px rgba(0,0,0,0.7);
  will-change: opacity, transform, left, top;
}

.floating-preview.visible {
  opacity: 1;
  transform: scale(1) rotate(-1deg);
}

.floating-preview img { 
  width: 100%; 
  height: 100%; 
  object-fit: cover; 
  will-change: transform;
}

/* ─── FOOTER ─────────────────────────────────────────────── */
.footer-section {
  padding: 150px var(--px) 50px;
  text-align: center;
}

.footer-content h2 {
  font-family: var(--font-display);
  font-size: clamp(3rem, 8vw, 6rem);
  line-height: 0.9;
  margin-bottom: 50px;
}

.email-link {
  font-size: 2rem;
  color: var(--clr-accent);
  border-bottom: 1px solid var(--clr-accent);
  padding-bottom: 5px;
  display: inline-block;
  transition: opacity var(--t-fast), transform 0.3s ease;
}


.social-links-minimal {
  margin-top: 80px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
}

.footer-bottom {
  margin-top: 100px;
  display: flex;
  justify-content: space-between;
  color: var(--clr-muted);
  font-size: 0.9rem;
  text-transform: uppercase;
}

/* ─── NORRIS HOVER LINKS ─────────────────────────────────── */
a.norris {
  font-family: var(--font-display);
  font-size: 3rem;
  text-transform: uppercase;
  display: block;
  white-space: nowrap;
  width: fit-content;
  overflow: hidden;
}

a.norris span {
  position: relative;
  display: inline-block;
  color: transparent;
  will-change: transform;
}

a.norris span::before,
a.norris span::after {
  position: absolute;
  left: 0;
  content: attr(data-char);
  transition: transform 0.25s ease-in-out, opacity 0.25s ease-in-out;
  transition-delay: calc(var(--index) * 25ms);
}

a.norris span::before { transform: translateY(0);     opacity: 1; color: var(--clr-muted);  }
a.norris span::after  { transform: translateY(3rem);  opacity: 0; color: var(--clr-accent); }

a.norris:hover span::before { transform: translateY(-3rem); opacity: 0; }
a.norris:hover span::after  { transform: translateY(0);     opacity: 1; }


/* ─── CAROUSEL ───────────────────────────────────────────── */
.mzaCarousel {
  position: relative;
  height: 80vh;
  width: 100%;
  overflow: hidden;
  touch-action: none;
}

.mzaCarousel-viewport {
  perspective: 1200px;
  height: 100%;
  width: 100%;
  position: relative;
  overflow: hidden;
}

.mzaCarousel-track {
  position: relative;
  height: 100%;
  width: 100%;
  transform-style: preserve-3d;
}

.mzaCarousel-slide {
  position: absolute;
  top: 50%;
  left: 50%;
  width: var(--carousel-slide-w);
  height: 450px;
  transition: opacity var(--t-fast);
  will-change: transform;
}

.mzaCard {
  width: 100%;
  height: 100%;
  border-radius: var(--r-md);
  overflow: hidden;
  background-size: cover;
  background-position: center;
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: var(--space-md);
  background-color: #111;
  border: 1px solid var(--clr-line);
}

.mzaCard::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
  z-index: 1;
}

.mzaCard-head,
.mzaCard-text,
.mzaCard-actions { position: relative; z-index: 2; }

.mzaCard-title { font-family: var(--font-display); text-transform: uppercase; }

.mzaBtn {
  background-color: var(--clr-accent);
  color: #000;
  border: none;
  font-family: var(--font-body);
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 12px 24px;
  border-radius: var(--r-lg);
  cursor: pointer;
  transition: transform var(--t-fast);
}

.mzaBtn:hover { transform: translateY(-2px); }

.mzaCarousel-dot {
  width: 10px;
  height: 10px;
  border-radius: var(--r-full);
  background: var(--clr-muted);
  border: none;
  cursor: pointer;
  transition: background var(--t-fast), transform var(--t-fast);
  margin: 0 5px;
}

.mzaCarousel-dot.active {
  background: var(--clr-accent);
  transform: scale(1.3);
}

.mzaCarousel-progress {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 3px;
  background: rgba(255,255,255,0.1);
}

.mzaCarousel-progressBar {
  display: block;
  height: 100%;
  width: 100%;
  background: var(--clr-accent);
  transform-origin: left;
  transform: scaleX(0);
}

/* ─── KEYFRAMES ──────────────────────────────────────────── */
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50%       { transform: translateY(-15px); }
}

@keyframes bounce {
  0%, 100% { transform: translateY(0); }
  50%       { transform: translateY(10px); }
}

@keyframes gradShift {
  0%   { x: -100%; }
  100% { x: 100%;  }
}

/* ─── RESPONSIVE ─────────────────────────────────────────── */
@media (max-width: 1024px) {
  .hero-grid {
    display: flex;
    justify-content: center;
    gap: var(--space-lg);
    flex-direction: column;
    align-items: center;
  }
}

/* Tablet */
@media (max-width: 968px) {
  :root { --px: 20px; }

  .hero-section {
    min-height: auto;
    padding: 100px var(--px) 40px;
  }

  .hero-minimal {
    height: auto;
    padding: 20px var(--px) 40px;
    margin-top: -40px;
  }

  .minimal-rule  { height: 36px; margin-bottom: 24px; }
  .minimal-meta  { margin-top: 24px; gap: 20px; }

  .hero-grid {
    flex-direction: column;
    gap: var(--space-md);
  }

  .hero-text-container {
    flex: none;
    text-align: center;
    padding-right: 0;
    width: 100%;
  }

  .hero-title {
    font-size: 4rem;
    align-items: center;
  }

  .typewriter-line.indent { margin-left: 0; }

  .vertical-separator {
    width: 100%;
    height: 1px;
    margin: 30px 0;
    transform: scaleX(0);
    transform-origin: center;
  }

  .editorial-profile {
    padding-right: 0;
    transform: none;
    width: 100%;
    display: flex;
    justify-content: center;
  }

  .profile-layout {
    flex-direction: column-reverse;
    align-items: center;
    text-align: center;
    gap: 30px;
  }

  .profile-info-block  { align-items: center; max-width: 100%; }
  .profile-identity h3 { margin-top: 0; font-size: 4rem; }
  .link-clean          { flex-direction: row; }
  .clean-skills        { justify-content: center; }
  .profile-photo-circle {
    width: min(300px, 80vw);
    height: auto;
    aspect-ratio: 300 / 380;
  }

  .footer-bottom {
    flex-direction: column;
    gap: 20px;
    text-align: center;
  }
}

/* ─── TABLET HERO vertical compact (Z Fold inner, tablettes) ── */
@media (min-width: 600px) and (max-width: 968px) {

  /* Hero remplit tout le viewport, DESIGN commence au scroll */
  .hero-section {
    min-height: 100svh;
    justify-content: flex-start;
    padding: 100px var(--px) 40px;
  }

  /* hero-grid s'étire pour remplir l'espace restant */
  .hero-grid {
    flex: 1;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    gap: 0;
    width: 100%;
  }

  .hero-text-container {
    flex: none;
    text-align: center;
    padding-right: 0;
    width: 100%;
    padding-bottom: 20px;
  }

  /* editorial-profile prend l'espace restant et centre son contenu */
  .editorial-profile {
    flex: 1;
    width: 100%;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transform: none;
  }

  /* Titre */
  .hero-title {
    font-size: clamp(5rem, 12vw, 8rem);
    align-items: center;
  }

  .typewriter-line.indent { margin-left: 0; }

  /* Description */
  /* CTA */
  .hero-cta-primary {
    margin-top: 24px;
    font-size: 1.1rem;
    padding: 18px 40px;
  }

  /* Séparateur masqué */
  .vertical-separator { display: none; }

  /* Profil */
  .profile-layout {
    flex-direction: column-reverse;
    align-items: center;
    text-align: center;
    gap: 20px;
    height: 100%;
    justify-content: center;
  }

  /* Photo : hauteur fixe pour laisser de la place au nom en dessous */
  .profile-photo-circle {
    flex: 0 0 auto;
    height: 48vh;
    width: auto;
    aspect-ratio: 300 / 380;
  }

  .profile-info-block  { align-items: center; flex-shrink: 0; gap: 6px; }
  .profile-identity h3 { font-size: 3.8rem; margin-top: 0; }
  .job-title           { font-size: 1rem; letter-spacing: 2px; }

  /* Masquer le surplus pour garder la lisibilité */
  .profile-bio  { display: none; }
  .clean-skills { display: none; }
  .link-clean   { display: none; }
}

/* Mobile L */
@media (max-width: 768px) {
  .letter             { font-size: 3rem; }
  .interactive-glow   { display: none; }
}

/* ─── BURGER ─────────────────────────────────────────── */
.burger {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 26px;
  height: 18px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  z-index: 1001;
  flex-shrink: 0;
}

.burger span {
  display: block;
  width: 100%;
  height: 2px;
  background: var(--clr-text);
  border-radius: 2px;
  transition: transform 0.35s cubic-bezier(0.65,0,0.35,1),
              opacity   0.25s ease,
              background 0.3s;
  transform-origin: center;
}

.burger.is-open span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.burger.is-open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.burger.is-open span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

/* ─── MOBILE NAV OVERLAY ─────────────────────────────── */
.mobile-nav {
  display: none;
  position: fixed;
  inset: 0;
  background: var(--clr-bg);
  z-index: 999;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s ease;
}

.mobile-nav.is-open {
  opacity: 1;
  pointer-events: auto;
}

.mobile-nav ul {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 48px;
  list-style: none;
}

.mobile-nav-link {
  font-family: var(--font-display);
  font-size: clamp(2.8rem, 12vw, 4.5rem);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--clr-text);
  opacity: 0;
  transform: translateY(20px);
  transition: color 0.3s, opacity 0.35s ease, transform 0.35s ease;
}

.mobile-nav.is-open .mobile-nav-link:nth-child(1) { opacity: 1; transform: translateY(0); transition-delay: 0.1s; }
.mobile-nav.is-open .mobile-nav-link:nth-child(2) { opacity: 1; transform: translateY(0); transition-delay: 0.17s; }
.mobile-nav.is-open .mobile-nav-link:nth-child(3) { opacity: 1; transform: translateY(0); transition-delay: 0.24s; }

.mobile-nav-link:hover { color: var(--clr-accent); }

/* Mobile M */
@media (max-width: 600px) {
  .main-header { padding: 15px 20px; }
  .logo        { font-size: 1.2rem; }
  .nav-links   { display: none; }
  .burger      { display: flex; }
  .mobile-nav  { display: flex; }
  .main-header nav { gap: 10px; }

  /* Flèche toujours visible sur touch */
  .project-arrow { color: var(--clr-accent); opacity: 1; }

  /* Zone de tap généreuse */
  .project-row { padding: 22px 0; min-height: 44px; }
  .darkmode-label { width: 80px; height: 38px; }
  .darkmode-label::after { width: 30px; height: 30px; top: 4px; left: 4px; }
  .toggle-sun, .toggle-moon { width: 17px; height: 17px; top: 10px; }
  .toggle-sun { left: 10px; top: 10px; }
  .toggle-moon { right: 10px; top: 10px; }
}

/* Mobile S — narrow (Z Fold cover, iPhone SE…) */
@media (max-width: 480px) {

  /* Hero */
  .hero-section {
    min-height: auto;
    padding: 90px 20px 32px;
  }

  .hero-minimal {
    height: auto;
    padding: 20px 20px 36px;
    margin-top: -40px;
  }

  .minimal-rule {
    height: 32px;
    margin-bottom: 20px;
  }

  .minimal-meta {
    margin-top: 24px;
    gap: 16px;
    flex-wrap: wrap;
    justify-content: center;
  }

  .hero-grid { gap: 28px; }

  .hero-text-container { text-align: center; }

  .hero-title {
    font-size: clamp(2.4rem, 11vw, 3.2rem);
    gap: 4px;
  }

  /* Séparateur horizontal supprimé visuellement */
  .vertical-separator { display: none; }

  /* Profil compact : photo à gauche, nom/titre à droite */
  .editorial-profile { width: 100%; padding: 0; }

  .profile-layout {
    flex-direction: row !important;
    align-items: center;
    justify-content: center;
    gap: 20px;
    text-align: left;
  }

  .profile-photo-circle {
    width: 100px;
    height: 126px;
    flex-shrink: 0;
    aspect-ratio: auto;
  }

  .profile-info-block {
    align-items: flex-start;
    max-width: calc(100% - 120px);
  }

  .profile-identity h3 {
    font-size: 2rem;
    margin-top: 0;
    line-height: 1;
  }

  .job-title   { font-size: 0.8rem; letter-spacing: 1px; }
  .profile-bio { display: none; }
  .clean-skills { display: none; }

  .link-clean {
    font-size: 0.85rem;
    margin-top: 8px;
  }

  /* Projets */
  .projects-editorial { padding: 60px 15px; }

  .project-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
    padding: 20px 0;
  }

  .project-row-left  { gap: 12px; width: 100%; }
  .project-row-right { width: 100%; justify-content: space-between; gap: 0; }

  .project-name { font-size: 1.8rem; white-space: normal; line-height: 1.2; }
  .year-badge   { font-size: 0.65rem; }
}

/* Hide floating preview on touch devices */
@media (max-width: 1024px) {
  .floating-preview { display: none; }
}

/* ─── SERVICES & PROCESS ─────────────────────────────────── */
.services-section,
.process-section {
  max-width: 1400px;
  margin: 0 auto;
  padding: 90px clamp(24px, 8vw, 120px);
}
.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
  margin-top: 42px;
}
.service-card {
  border: 1px solid var(--clr-line);
  border-radius: 16px;
  padding: 32px 28px;
  background: var(--clr-surface);
  transition: border-color .3s ease, transform .3s ease;
}
.service-card:hover {
  border-color: var(--clr-accent);
  transform: translateY(-4px);
}
.service-num {
  font-family: var(--font-display);
  font-size: .82rem;
  font-weight: 700;
  letter-spacing: .12em;
  color: var(--clr-accent);
}
.service-card h3 {
  font-size: 1.4rem;
  font-weight: 600;
  margin: 14px 0 10px;
  letter-spacing: -.01em;
}
.service-card p {
  color: var(--clr-muted);
  line-height: 1.7;
  font-size: .98rem;
}
.process-steps {
  list-style: none;
  margin-top: 42px;
}
.process-step {
  display: grid;
  grid-template-columns: 88px 1fr;
  gap: 24px;
  align-items: start;
  padding: 30px 0;
  border-top: 1px solid var(--clr-line);
}
.process-step:last-child { border-bottom: 1px solid var(--clr-line); }
.process-num {
  font-family: var(--font-display);
  font-size: 2.1rem;
  font-weight: 800;
  line-height: 1;
  color: var(--clr-accent);
}
.process-step h3 {
  font-size: 1.3rem;
  font-weight: 600;
  margin-bottom: 8px;
  letter-spacing: -.01em;
}
.process-step p {
  color: var(--clr-muted);
  line-height: 1.7;
  max-width: 62ch;
}
@media (max-width: 768px) {
  .services-section,
  .process-section { padding: 64px clamp(20px, 6vw, 60px); }
  .services-grid { grid-template-columns: 1fr; }
  .process-step { grid-template-columns: 56px 1fr; gap: 16px; padding: 24px 0; }
  .process-num { font-size: 1.7rem; }
}
/* en-tête de section : neutralise la marge par défaut des <h2> */
h2.section-label { margin: 0; }

/* ─── MICRO-INTERACTIONS (flèches & liens) ───────────────── */
.link-clean .arrow,
.contact-link .arrow { display: inline-block; transition: transform .3s ease; }
.link-clean:hover .arrow,
.contact-link:hover .arrow { transform: translateX(5px); }
.hero-cta-primary { transition: transform .3s ease, opacity .3s ease; }
.hero-cta-primary:hover { transform: translateY(3px); }

.email-link:hover { transform: translateX(4px); }
@media (prefers-reduced-motion: reduce) {
  .link-clean .arrow, .contact-link .arrow, .hero-cta-primary, 
}
