/* ═══════════════════════════════════════════════
   VARIABLES & RESET
════════════════════════════════════════════════ */
:root {
  --bg: #0a0a0f;
  --bg-2: #111118;
  --bg-card: #16161f;
  --border: rgba(255, 255, 255, 0.07);
  --border-hover: rgba(255, 255, 255, 0.18);
  --text: #e8e6f0;
  --text-muted: #7a7890;
  --accent: #c8f060;
  /* vert électrique */
  --accent-2: #7b5ef8;
  /* violet */
  --accent-glow: rgba(200, 240, 96, 0.15);

  --font-display: 'Syne', sans-serif;
  --font-body: 'DM Sans', sans-serif;

  --radius: 12px;
  --radius-lg: 20px;
  --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);

  --max-width: 1100px;
  --section-gap: 120px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.7;
  overflow-x: hidden;
}

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

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

/* ═══════════════════════════════════════════════
   UTILITAIRES
════════════════════════════════════════════════ */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 2rem;
}

.section {
  padding: var(--section-gap) 0;
}

.section__header {
  display: flex;
  align-items: baseline;
  gap: 1rem;
  margin-bottom: 3.5rem;
}

.section__number {
  font-family: var(--font-display);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  color: var(--accent);
  opacity: 0.7;
}

.section__title {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text);
}

/* Tags / Badges */
.tag {
  display: inline-block;
  padding: 0.3em 0.85em;
  margin: 0.2rem 0.3rem 0.2rem 0;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.03em;
  background: rgba(200, 240, 96, 0.1);
  color: var(--accent);
  border: 1px solid rgba(200, 240, 96, 0.2);
}

.formation p {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--accent);
  margin-bottom: 0.6rem;
}

.enplus {
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
}

.enplus p {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--accent-2);
  margin-bottom: 0.6rem;
}

.tag-more {
  display: inline-block;
  padding: 0.3em 0.85em;
  margin: 0.2rem 0.3rem 0.2rem 0;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.03em;
  background: rgba(123, 94, 248, 0.1);
  color: var(--accent-2);
  border: 1px solid rgba(123, 94, 248, 0.2);
}

.tag--dark {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-muted);
  border-color: var(--border);
}

.tag-more--dark {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-muted);
  border-color: var(--border);
}

/* Boutons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75em 1.6em;
  border-radius: 999px;
  font-family: var(--font-body);
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition);
  white-space: nowrap;
}

.btn--primary {
  background: var(--accent);
  color: #0a0a0f;
  border: 1px solid var(--accent);
  margin-right: 2rem;
}

.btn--primary:hover {
  background: #d6f570;
  box-shadow: 0 0 24px var(--accent-glow);
  transform: translateY(-2px);
}

.btn--ghost {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border);
  margin-left: 2rem;
}

.btn--ghost:hover {
  border-color: var(--border-hover);
  background: rgba(255, 255, 255, 0.04);
  transform: translateY(-2px);
}

.btn--sm {
  padding: 0.55em 1.2em;
  font-size: 0.82rem;
}

.btn--disabled {
  opacity: 0.4;
  cursor: not-allowed;
  pointer-events: none;
}

/* ═══════════════════════════════════════════════
   NAVIGATION
════════════════════════════════════════════════ */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.2rem 2.5rem;
  background: rgba(10, 10, 15, 0.7);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  transition: background var(--transition);
}

.nav__logo {
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.nav__logo .dot {
  color: var(--accent);
}

.nav__links {
  display: flex;
  gap: 2.5rem;
  list-style: none;
}

.nav__links a {
  font-size: 0.88rem;
  font-weight: 400;
  color: var(--text-muted);
  letter-spacing: 0.02em;
  transition: color var(--transition);
  position: relative;
}

.nav__links a::after {
  content: '';
  position: absolute;
  bottom: -3px;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--accent);
  transition: width var(--transition);
}

.nav__links a:hover {
  color: var(--text);
}

.nav__links a:hover::after {
  width: 100%;
}

/* ═══════════════════════════════════════════════
   HERO
════════════════════════════════════════════════ */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  padding: 8rem 2rem 4rem;
}

/* Texture grain */
.hero__noise {
  position: absolute;
  inset: -50%;
  width: 200%;
  height: 200%;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.04'/%3E%3C/svg%3E");
  pointer-events: none;
  opacity: 0.6;
}

/* Halo lumineux en fond */
.hero::before {
  content: '';
  position: absolute;
  top: -20%;
  left: 50%;
  transform: translateX(-50%);
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(123, 94, 248, 0.12) 0%, transparent 70%);
  pointer-events: none;
}

.hero::after {
  content: '';
  position: absolute;
  bottom: -10%;
  right: -5%;
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(200, 240, 96, 0.07) 0%, transparent 70%);
  pointer-events: none;
}

.hero__content {
  max-width: 750px;
  text-align: center;
  position: relative;
  z-index: 1;
  animation: fadeUp 0.9s ease both;
}

.hero__tag {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1.5rem;
  padding: 0.4em 1em;
  border: 1px solid rgba(200, 240, 96, 0.25);
  border-radius: 999px;
  background: rgba(200, 240, 96, 0.06);
}

.hero__title {
  font-family: var(--font-display);
  font-size: clamp(3.5rem, 10vw, 7.5rem);
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 1.5rem;
}

.hero__title--line {
  display: block;
}

.hero__title--line.accent {
  color: var(--accent);
}

.hero__subtitle {
  font-size: clamp(1rem, 2.5vw, 1.15rem);
  color: var(--text-muted);
  line-height: 1.7;
  margin-bottom: 2.5rem;
  font-weight: 300;
}

.hero__cta {
  display: flex;
  gap: 1rem;
  
  justify-content: center;
  flex-wrap: wrap;
}

.hero__scroll-hint {
  position: absolute;
  bottom: 2.5rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  color: var(--text-muted);
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  z-index: 1;
}

.hero__scroll-line {
  width: 1px;
  height: 40px;
  background: linear-gradient(to bottom, var(--text-muted), transparent);
  animation: scrollPulse 2s ease infinite;
}

/* ═══════════════════════════════════════════════
   À PROPOS
════════════════════════════════════════════════ */
.about {
  background: var(--bg-2);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.about__grid {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 5rem;
  align-items: center;
}

.about__intro {
  font-size: 1.15rem;
  font-weight: 400;
  color: var(--text);
  margin-bottom: 1.2rem;
  line-height: 1.8;
}

.about__text p {
  color: var(--text-muted);
  margin-bottom: 1.2rem;
}

.about__stack {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 2rem;
}

.about__card {
  position: relative;
}

.about__card-inner {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  transition: border-color var(--transition);
}

.about__card-inner:hover {
  border-color: var(--border-hover);
}

.about__avatar {
  font-family: var(--font-display);
  font-size: 3.5rem;
  font-weight: 800;
  color: var(--text-muted);
  letter-spacing: -0.03em;
}

/* ═══════════════════════════════════════════════
   PROJETS
════════════════════════════════════════════════ */
.projects__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
}

.project-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  transition: border-color var(--transition), transform var(--transition), box-shadow var(--transition);
  position: relative;
  overflow: hidden;
}

.project-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--accent-2), var(--accent));
  opacity: 0;
  transition: opacity var(--transition);
}

.project-card:hover {
  border-color: var(--border-hover);
  transform: translateY(-4px);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
}

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

.project-card__status {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--text-muted);
  letter-spacing: 0.04em;
}

.status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 6px var(--accent);
  animation: blink 2s ease infinite;
}

.status-dot--wip {
  background: #f0a060;
  box-shadow: 0 0 6px rgba(240, 160, 96, 0.6);
}

.project-card__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.project-card__number {
  font-family: var(--font-display);
  font-size: 2.5rem;
  font-weight: 800;
  color: rgba(255, 255, 255, 0.05);
  line-height: 1;
  letter-spacing: -0.03em;
}

.project-card__tags {
  display: flex;
  gap: 0.4rem;
  margin-left: 3rem;
  flex-wrap: wrap;
}

.project-card__title {
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text);
}

.project-card__desc {
  color: var(--text-muted);
  font-size: 0.92rem;
  line-height: 1.7;
  flex: 1;
}

.projet2 {
  margin-top: 2.5rem;
}

.project-card__footer {
  margin-top: auto;
  padding-top: 0.5rem;
  flex-wrap: wrap;
}

/* ═══════════════════════════════════════════════
   CV
════════════════════════════════════════════════ */
.cv-section {
  background: var(--bg-2);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.cv__wrapper {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.cv__viewer {
  width: 100%;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--bg-card);
  position: relative;
}

.cv__iframe {
  width: 100%;
  height: 75vh;
  min-height: 500px;
  border: none;
  display: block;
}

.cv__fallback {
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
  padding: 3rem;
  text-align: center;
  color: var(--text-muted);
}

/* Si l'iframe échoue (pas de PDF) on affiche le fallback via JS */
.cv__iframe.hidden+.cv__fallback {
  display: flex;
}

.cv__actions {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

/* ═══════════════════════════════════════════════
   CONTACT
════════════════════════════════════════════════ */
.contact__content {
  max-width: 540px;
}

.contact__intro {
  color: var(--text-muted);
  font-size: 1.05rem;
  margin-bottom: 2rem;
}

.contact__email {
  display: inline-block;
  font-family: var(--font-display);
  font-size: clamp(1.4rem, 4vw, 2.2rem);
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.02em;
  margin-bottom: 2.5rem;
  border-bottom: 2px solid var(--accent);
  padding-bottom: 0.2em;
  transition: color var(--transition);
}

.contact__email:hover {
  color: var(--accent);
}

.contact__links {
  display: flex;
  gap: 1.5rem;
}

.contact__link {
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-muted);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  transition: color var(--transition);
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.contact__link::after {
  content: '↗';
  font-size: 0.8em;
  transition: transform var(--transition);
}

.contact__link:hover {
  color: var(--text);
}

.contact__link:hover::after {
  transform: translate(2px, -2px);
}

/* ═══════════════════════════════════════════════
   FOOTER
════════════════════════════════════════════════ */
.footer {
  padding: 2.5rem 0;
  border-top: 1px solid var(--border);
  text-align: center;
  color: var(--text-muted);
  font-size: 0.82rem;
}

/* ═══════════════════════════════════════════════
   ANIMATIONS
════════════════════════════════════════════════ */
@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes scrollPulse {

  0%,
  100% {
    opacity: 0.4;
  }

  50% {
    opacity: 1;
  }
}

@keyframes blink {

  0%,
  100% {
    opacity: 1;
  }

  50% {
    opacity: 0.3;
  }
}

/* ═══════════════════════════════════════════════
   RESPONSIVE
════════════════════════════════════════════════ */
@media (max-width: 768px) {
  :root {
    --section-gap: 80px;
  }

  .nav {
    padding: 1rem 1.25rem;
  }

  .nav__links {
    gap: 1.5rem;
  }

  .nav__links a {
    font-size: 0.82rem;
  }

  .hero {
    padding: 7rem 1.25rem 4rem;
  }

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

  .about__visual {
    display: none;
  }

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

  .cv__iframe {
    height: 60vh;
  }

  .cv__actions {
    flex-direction: column;
  }
}

@media (max-width: 480px) {
  .nav__links {
    display: none;
  }

  .hero__cta {
    flex-direction: column;
    align-items: center;
  }
}