/* =========================================================
   TOKENS
   ========================================================= */
:root {
  --bg:        #1b1220;
  --bg-soft:   #241729;
  --surface:   #2e1c34;
  --surface-2: #35223c;

  --rose:      #eaa9c4;
  --rose-deep: #d67aa8;
  --lilac:     #b58ee0;
  --lilac-deep:#8f63c2;

  --cream:     #f7ecf1;
  --muted:     #c7b3c2;

  --font-display: 'Cormorant Garamond', serif;
  --font-body: 'Poppins', sans-serif;

  --radius-lg: 28px;
  --radius-md: 18px;
  --radius-sm: 12px;

  --shadow: 0 20px 45px rgba(0,0,0,0.35);
}

/* =========================================================
   RESET & BASE
   ========================================================= */
* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--cream);
  font-family: var(--font-body);
  line-height: 1.6;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
ul { list-style: none; }
img { max-width: 100%; display: block; }

::selection { background: var(--rose-deep); color: var(--bg); }

/* Curseur lumineux */
.glow-cursor {
  position: fixed;
  width: 260px;
  height: 260px;
  border-radius: 50%;
  pointer-events: none;
  background: radial-gradient(circle, rgba(234,169,196,0.16), transparent 70%);
  transform: translate(-50%, -50%);
  z-index: 2;
  transition: opacity 0.3s ease;
}

/* =========================================================
   TYPO GÉNÉRALE
   ========================================================= */
h1, h2, h3, .logo, .section-title {
  font-family: var(--font-display);
  font-weight: 600;
}

.section-eyebrow {
  font-family: var(--font-body);
  font-size: 0.78rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--rose);
  margin-bottom: 8px;
}
.section-eyebrow.light { color: var(--cream); opacity: 0.85; }

.section-title {
  font-size: clamp(2rem, 4vw, 2.7rem);
  font-style: italic;
  color: var(--cream);
  margin-bottom: 46px;
}
.section-title.light { color: var(--bg); }

/* =========================================================
   NAVBAR
   ========================================================= */
.navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 6%;
  transition: background-color 0.4s ease, box-shadow 0.4s ease, padding 0.4s ease;
}
.navbar.scrolled {
  background: rgba(27, 18, 32, 0.85);
  backdrop-filter: blur(14px);
  box-shadow: 0 10px 30px rgba(0,0,0,0.3);
  padding: 12px 6%;
}

.logo {
  font-family: var(--font-display);
  font-size: 1.6rem;
  font-style: italic;
  font-weight: 600;
  color: var(--cream);
}
.logo span { color: var(--rose); }

.nav-menu ul {
  display: flex;
  align-items: center;
  gap: 34px;
}

.nav-link {
  position: relative;
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--muted);
  transition: color 0.3s ease;
}
.nav-link::after {
  content: "";
  position: absolute;
  left: 0; bottom: -6px;
  width: 0%;
  height: 2px;
  background: var(--rose);
  transition: width 0.3s ease;
}
.nav-link:hover,
.nav-link.active-link { color: var(--cream); }
.nav-link:hover::after,
.nav-link.active-link::after { width: 100%; }

.nav-cta {
  padding: 8px 20px;
  border: 1px solid var(--rose);
  border-radius: 30px;
  color: var(--cream) !important;
}
.nav-cta::after { display: none; }
.nav-cta:hover { background: var(--rose); color: var(--bg) !important; }

.burger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  z-index: 110;
}
.burger span {
  width: 26px;
  height: 2px;
  background: var(--cream);
  transition: transform 0.3s ease, opacity 0.3s ease;
}
.burger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.burger.open span:nth-child(2) { opacity: 0; }
.burger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* =========================================================
   HERO
   ========================================================= */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 120px 6% 60px;
  overflow: hidden;
}

.hero-blobs { position: absolute; inset: 0; z-index: 0; }
.blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(70px);
  opacity: 0.55;
  animation: float 14s ease-in-out infinite;
}
.blob-rose {
  width: 420px; height: 420px;
  background: var(--rose-deep);
  top: -80px; right: 8%;
}
.blob-lilac {
  width: 380px; height: 380px;
  background: var(--lilac-deep);
  bottom: -100px; left: 4%;
  animation-delay: -6s;
}
@keyframes float {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(30px, -40px) scale(1.08); }
}

.hero-inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  align-items: center;
  gap: 40px;
  max-width: 1180px;
  margin: 0 auto;
  width: 100%;
}

.eyebrow {
  font-size: 0.85rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--rose);
  margin-bottom: 14px;
  opacity: 0;
  transform: translateY(20px);
  animation: heroIn 0.8s ease forwards;
  animation-delay: 0.1s;
}

.hero-text h1 {
  font-size: clamp(2.6rem, 6vw, 4.4rem);
  font-style: italic;
  line-height: 1.05;
  color: var(--cream);
  opacity: 0;
  transform: translateY(20px);
  animation: heroIn 0.8s ease forwards;
  animation-delay: 0.25s;
}
.hero-text h1 .dot { color: var(--rose); }

.role {
  margin-top: 22px;
  font-size: 1.15rem;
  font-weight: 500;
  color: var(--lilac);
  min-height: 1.6em;
  opacity: 0;
  transform: translateY(20px);
  animation: heroIn 0.8s ease forwards;
  animation-delay: 0.4s;
}
.cursor-blink {
  display: inline-block;
  margin-left: 2px;
  animation: blink 1s steps(1) infinite;
  color: var(--rose);
}
@keyframes blink { 50% { opacity: 0; } }

.hero-desc {
  margin-top: 18px;
  max-width: 440px;
  color: var(--muted);
  font-size: 1rem;
  opacity: 0;
  transform: translateY(20px);
  animation: heroIn 0.8s ease forwards;
  animation-delay: 0.55s;
}

.hero-buttons {
  margin-top: 34px;
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  opacity: 0;
  transform: translateY(20px);
  animation: heroIn 0.8s ease forwards;
  animation-delay: 0.7s;
}

@keyframes heroIn {
  to { opacity: 1; transform: translateY(0); }
}

/* Boutons */
.btn {
  position: relative;
  overflow: hidden;
  display: inline-block;
  padding: 14px 30px;
  border-radius: 30px;
  font-size: 0.92rem;
  font-weight: 500;
  transition: transform 0.3s ease, box-shadow 0.3s ease, background 0.3s ease;
  cursor: pointer;
}
.btn-primary {
  background: linear-gradient(135deg, var(--rose-deep), var(--lilac-deep));
  color: var(--cream);
}
.btn-primary:hover {
  transform: translateY(-4px);
  box-shadow: 0 14px 30px rgba(214, 122, 168, 0.35);
}
.btn-outline {
  border: 1px solid var(--muted);
  color: var(--cream);
}
.btn-outline:hover {
  border-color: var(--rose);
  color: var(--rose);
  transform: translateY(-4px);
}
.btn-small {
  padding: 10px 22px;
  font-size: 0.85rem;
  border: 1px solid var(--rose);
  color: var(--cream);
}
.btn-small:hover { background: var(--rose); color: var(--bg); }

.ripple {
  position: absolute;
  border-radius: 50%;
  background: rgba(255,255,255,0.35);
  transform: scale(0);
  animation: rippleAnim 0.6s linear;
  pointer-events: none;
}
@keyframes rippleAnim { to { transform: scale(3); opacity: 0; } }

/* Photo hero */
.hero-photo {
  position: relative;
  justify-self: center;
  width: min(320px, 70vw);
  aspect-ratio: 1 / 1;
  opacity: 0;
  transform: scale(0.85);
  animation: photoIn 0.9s ease forwards;
  animation-delay: 0.35s;
}
@keyframes photoIn { to { opacity: 1; transform: scale(1); } }

.photo-ring {
  position: absolute;
  inset: -18px;
  border: 2px dashed var(--rose);
  border-radius: 50%;
  animation: spin 24s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.photo-placeholder,
.photo-real {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
}
.photo-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: linear-gradient(150deg, var(--surface), var(--surface-2));
  border: 1px solid rgba(255,255,255,0.08);
  color: var(--muted);
  font-size: 0.9rem;

}
.photo-placeholder span { font-size: 2.4rem; }

.scroll-hint {
  position: absolute;
  bottom: 26px;
  left: 50%;
  transform: translateX(-50%);
  width: 24px;
  height: 40px;
  border: 2px solid var(--muted);
  border-radius: 20px;
  z-index: 1;
}
.scroll-hint span {
  position: absolute;
  top: 6px;
  left: 50%;
  width: 4px;
  height: 8px;
  background: var(--rose);
  border-radius: 2px;
  transform: translateX(-50%);
  animation: scrollDot 1.8s ease infinite;
}
@keyframes scrollDot {
  0% { top: 6px; opacity: 1; }
  70% { top: 20px; opacity: 0; }
  100% { top: 6px; opacity: 0; }
}

/* Pétales flottantes générées en JS */
.petal {
  position: fixed;
  top: -20px;
  border-radius: 60% 0 60% 0;
  pointer-events: none;
  z-index: 2;
  opacity: 0.7;
  animation: petalFall linear forwards;
}
@keyframes petalFall {
  to { transform: translateY(110vh) translateX(var(--drift, 40px)) rotate(320deg); opacity: 0; }
}

/* =========================================================
   SECTIONS GÉNÉRALES
   ========================================================= */
.section {
  padding: 110px 6%;
  max-width: 1180px;
  margin: 0 auto;
}
.section-alt {
  max-width: none;
  background: var(--bg-soft);
}
.section-alt > * { max-width: 1180px; margin-left: auto; margin-right: auto; }
.section-alt .formations-grid,
.section-alt .projets-grid { margin-left: auto; margin-right: auto; }

.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal.is-visible { opacity: 1; transform: translateY(0); }

/* =========================================================
   À PROPOS
   ========================================================= */
.apropos-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 50px;
  align-items: start;
}
.apropos-texte p { color: var(--muted); margin-bottom: 18px; }

.info-card {
  background: var(--surface);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: var(--radius-md);
  padding: 30px;
}
.info-row {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 14px 0;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
.info-row:last-child { border-bottom: none; }
.info-label { color: var(--rose); font-size: 0.85rem; letter-spacing: 0.05em; }
.info-value { color: var(--cream); font-weight: 500; text-align: right; }

/* =========================================================
   FORMATIONS
   ========================================================= */
.formations-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 26px;
}
.formation-card {
  background: var(--surface);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: var(--radius-md);
  padding: 34px 28px;
  transition: transform 0.35s ease, box-shadow 0.35s ease, border-color 0.35s ease;
}
.formation-card:hover {
  transform: translateY(-8px);
  border-color: var(--rose);
  box-shadow: var(--shadow);
}
.formation-icon { font-size: 1.8rem; margin-bottom: 14px; }
.formation-card h3 { font-size: 1.4rem; margin-bottom: 10px; color: var(--cream); }
.formation-card p { color: var(--muted); font-size: 0.92rem; margin-bottom: 18px; }
.badge {
  display: inline-block;
  padding: 5px 14px;
  border-radius: 20px;
  background: rgba(234,169,196,0.15);
  color: var(--rose);
  font-size: 0.78rem;
  font-weight: 500;
}

/* =========================================================
   COMPÉTENCES
   ========================================================= */
.competences-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}
.competence-card {
  background: var(--surface);
  border-radius: var(--radius-md);
  padding: 26px 28px;
  border: 1px solid rgba(255,255,255,0.06);
}
.competence-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 14px;
}
.competence-head h3 { font-size: 1.25rem; color: var(--cream); }
.competence-percent { color: var(--rose); font-weight: 600; font-family: var(--font-body); }

.progress-track {
  width: 100%;
  height: 8px;
  border-radius: 10px;
  background: rgba(255,255,255,0.08);
  overflow: hidden;
}
.progress-fill {
  height: 100%;
  width: 0%;
  border-radius: 10px;
  background: linear-gradient(90deg, var(--rose-deep), var(--lilac));
  transition: width 1.3s cubic-bezier(.22,1,.36,1);
}
.competence-niveau {
  display: inline-block;
  margin-top: 10px;
  font-size: 0.8rem;
  color: var(--muted);
}

/* =========================================================
   PROJETS
   ========================================================= */
.projets-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 30px;
}
.projet-card {
  background: var(--surface);
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid rgba(255,255,255,0.06);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  will-change: transform;
}
.projet-card:hover { box-shadow: var(--shadow); }

.projet-image { position: relative; height: 240px; overflow: hidden; }
.projet-image img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform 0.5s ease;
}
.projet-card:hover .projet-image img { transform: scale(1.06); }
.projet-tag {
  position: absolute;
  top: 16px; left: 16px;
  background: rgba(27,18,32,0.75);
  backdrop-filter: blur(6px);
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 0.75rem;
  color: var(--rose);
}

.projet-body { padding: 26px 28px 30px; }
.projet-body h3 { font-size: 1.5rem; font-style: italic; color: var(--cream); margin-bottom: 6px; }
.projet-body > p { color: var(--lilac); font-size: 0.9rem; margin-bottom: 12px; }
.projet-desc { color: var(--muted) !important; font-size: 0.92rem; margin-bottom: 22px !important; }

/* =========================================================
   CONTACT
   ========================================================= */
#contact { padding-top: 60px; padding-bottom: 100px; }
.contact-card {
  background: linear-gradient(135deg, var(--rose-deep), var(--lilac-deep));
  border-radius: var(--radius-lg);
  padding: 60px 8%;
  text-align: center;
  color: var(--bg);
}
.contact-text { max-width: 460px; margin: 0 auto 32px; color: rgba(27,18,32,0.85); }

.contact-qr {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  background: rgba(255,255,255,0.18);
  padding: 20px 26px;
  border-radius: var(--radius-md);
  margin-bottom: 34px;
}
.contact-qr img { border-radius: 10px; }
.contact-qr p { font-size: 0.8rem; color: rgba(27,18,32,0.8); }

.reseaux {
  display: flex;
  justify-content: center;
  gap: 26px;
  flex-wrap: wrap;
}
.lien-reseau {
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--bg);
  transition: transform 0.3s ease, opacity 0.3s ease;
}
.lien-reseau:hover { transform: translateY(-4px); opacity: 0.75; }

/* =========================================================
   FOOTER & BACK TO TOP
   ========================================================= */
.footer {
  text-align: center;
  padding: 30px;
  color: var(--muted);
  font-size: 0.8rem;
}

.back-to-top {
  position: fixed;
  right: 26px;
  bottom: 26px;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: none;
  background: var(--rose-deep);
  color: var(--cream);
  font-size: 1.1rem;
  cursor: pointer;
  opacity: 0;
  pointer-events: none;
  transform: translateY(10px);
  transition: opacity 0.3s ease, transform 0.3s ease;
  z-index: 90;
}
.back-to-top.visible { opacity: 1; pointer-events: auto; transform: translateY(0); }
.back-to-top:hover { background: var(--lilac-deep); }

/* =========================================================
   RESPONSIVE
   ========================================================= */
@media (max-width: 960px) {
  .hero-inner { grid-template-columns: 1fr; text-align: center; }
  .hero-text { order: 2; }
  .hero-photo { order: 1; margin: 0 auto 20px; }
  .hero-desc { margin-left: auto; margin-right: auto; }
  .hero-buttons { justify-content: center; }

  .apropos-grid { grid-template-columns: 1fr; }
  .formations-grid { grid-template-columns: repeat(2, 1fr); }
  .competences-grid { grid-template-columns: 1fr; }
}

@media (max-width: 720px) {
  .burger { display: flex; }

  .nav-menu {
    position: fixed;
    top: 0; right: -100%;
    width: min(78vw, 320px);
    height: 100vh;
    background: var(--bg-soft);
    box-shadow: -10px 0 30px rgba(0,0,0,0.35);
    transition: right 0.4s ease;
    padding: 100px 34px;
  }
  .nav-menu.open { right: 0; }
  .nav-menu ul { flex-direction: column; align-items: flex-start; gap: 28px; }
  .nav-cta { align-self: flex-start; }

  .formations-grid { grid-template-columns: 1fr; }
  .projets-grid { grid-template-columns: 1fr; }

  .section { padding: 80px 6%; }
  .contact-card { padding: 50px 7%; }
  .reseaux { gap: 18px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .blob, .photo-ring, .cursor-blink, .scroll-hint span, .petal,
  .eyebrow, .hero-text h1, .role, .hero-desc, .hero-buttons, .hero-photo {
    animation: none !important;
  }
  .reveal { opacity: 1; transform: none; transition: none; }
}


/* Container principal */
.education-container {
    display: flex;
    flex-direction: column;
    gap: 20px;
    max-width: 850px;
    margin: 0 auto;
    padding: 15px;
    background-color: #0f172a;
    font-family: 'Segoe UI', system-ui, sans-serif;
    box-sizing: border-box;
}

/* Style global de la carte */
.education-card {
    display: flex;
    align-items: center;
    background-color: #111827;
    border: 1px solid #1f2937;
    border-radius: 16px;
    overflow: hidden;
    padding: 16px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    cursor: pointer;
    box-sizing: border-box;
}

.education-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.4);
}

/* Bloc Image gauche */
.card-img-container {
    width: 130px;
    height: 100px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.card-img-container img {
    max-width: 80%;
    max-height: 80%;
    object-fit: contain;
}

/* Contenu Texte */
.card-body {
    flex-grow: 1;
    padding: 0 24px;
}

.card-body h3 {
    margin: 0 0 8px 0;
    font-size: 1.1rem;
    font-weight: 600;
    line-height: 1.4;
}

.card-body p {
    margin: 0;
    color: #9ca3af;
    font-size: 0.95rem;
    line-height: 1.5;
}

/* Flèche droite (Chevron) */
.card-arrow {
    font-size: 1.5rem;
    padding-left: 10px;
    font-weight: bold;
    flex-shrink: 0;
}

/* --- Variantes de couleurs --- */
.bg-green { background-color: #d1fae5; }
.title-green, .arrow-green { color: #10b981; }

.bg-orange { background-color: #ffedd5; }
.title-orange, .arrow-orange { color: #f97316; }

.bg-cyan { background-color: #e0f2fe; }
.title-cyan, .arrow-cyan { color: #06b6d4; }


/* ==========================================================================
   ⚡ MEDIA QUERIES (RESPONSIVE DESIGN)
   ========================================================================== */

/* Pour les tablettes et mobiles (Écrans inférieurs à 768px) */
@media screen and (max-width: 768px) {
    .education-card {
        flex-direction: column; /* Aligne l'image, le texte et la flèche à la verticale */
        align-items: flex-start; /* Aligne le contenu à gauche */
        gap: 16px;
        padding: 20px;
    }

    .card-img-container {
        width: 100%; /* L'image prend toute la largeur disponible sur mobile */
        height: 120px;
    }

    .card-body {
        padding: 0; /* Supprime les marges latérales devenues inutiles */
    }

    .card-body h3 {
        font-size: 1.05rem; /* Réduit légèrement le titre sur petit écran */
    }

    .card-arrow {
        align-self: flex-end; /* Place la flèche tout en bas à droite */
        padding-left: 0;
        transform: rotate(90deg); /* Optionnel : tourne la flèche vers le bas */
    }
}