/* 🔄 Reset & base */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

html, body {
  height: 100%;
  font-family: 'Segoe UI', sans-serif;
  color: #333;
}

body {
  padding-left: 1rem;
  padding-right: 1rem;
  opacity: 0;
  transition: opacity 0.8s ease;
}

body.loaded {
  opacity: 1;
}

.page-wrapper {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 2rem;
  box-sizing: border-box;
}

section {
  scroll-margin-top: 80px;
}

/* 🎯 Typography */

h1, h2 {
  font-weight: 700;
}

h1 {
  font-size: clamp(2rem, 6vw, 3.5rem);
  color: #f0f0f0;
  margin-bottom: 0.5rem;
  line-height: 1.2;
}

h2 {
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  color: #f0f0f0;
  margin-bottom: 1.5rem;
}

h3 {
  font-size: clamp(1.2rem, 3vw, 2rem);
  margin-bottom: 0.5rem;
}

p {
  font-size: clamp(1rem, 2.5vw, 1.3rem);
  line-height: 1.6;
}

/* 🌌 Fond SVG */

.svg-ciel {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  z-index: -3;
  pointer-events: none;
}

.svg-dune-front {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 20vh;
  transform-origin: bottom center;
  transition: transform 0.4s ease-out;
  z-index: -2;
  pointer-events: none;
}

/* HERO */

.hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  padding: 10rem 2rem 1rem;
  text-align: center;
  background-color: transparent;
}

.hero p {
  color: #f0f0f0;
  margin-top: 0.5rem;
  line-height: 1.4;
  font-size: clamp(1rem, 3vw, 1.5rem);
}

.hero-logo {
  width: auto;
  height: clamp(180px, 40vh, 351px);
  max-height: 351px;
  mix-blend-mode: lighten;
  filter: drop-shadow(0 2px 6px rgba(255,255,255,0.2));
  margin: 1rem 0;
  z-index: 0;
}

.hero strong {
  display: block;
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 600;
  color: #ffffff;
  text-shadow: 0 2px 6px rgba(0,0,0,0.6);
  margin-top: 1rem;
  letter-spacing: 0.05em;
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 1.2s ease-out, transform 1.2s ease-out;
}

.hero strong.visible {
  opacity: 1;
  transform: translateY(0);
}

/* HEADER / TOPBAR */

.topbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 72px;
  z-index: 9997;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1.2rem;
  background: transparent;
  box-shadow: none;
  transition: transform 0.3s ease;
  transform: translateZ(0);
  will-change: transform;
  isolation: isolate;
}

.topbar.hide {
  transform: translateY(-100%);
}

.topbar-wave {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
}

.topbar-wave svg {
  display: block;
  width: 100%;
  height: 100%;
}

.logo-link,
.burger {
  position: relative;
  z-index: 1;
}

.logo-link {
  display: flex;
  align-items: center;
  margin-top: -20px;
  gap: 0.75rem;
  text-decoration: none;
}

.logo-icon {
  width: 36px;
  height: 36px;
  object-fit: contain;
  display: block;
}

.logo-text {
  font-size: 1.25rem;
  font-weight: 600;
  color: #ffffff;
  letter-spacing: 0.05em;
}

/* Burger */

.burger {
  cursor: pointer;
  z-index: 1000;
}

.burger svg {
  width: 48px;
  height: 48px;
}

.burger svg .line {
  fill: none;
  stroke: #ffffff;
  stroke-width: 6;
  stroke-linecap: round;
  transition: all 0.3s ease;
}

.burger.open .top {
  transform: rotate(45deg);
  transform-origin: 50% 50%;
}

.burger.open .middle {
  opacity: 0;
}

.burger.open .bottom {
  transform: rotate(-45deg);
  transform-origin: 50% 50%;
}

.burger:hover {
  transform: scale(1.1);
}

/* OVERLAY + MENU LATÉRAL */

.menu-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(2px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
  z-index: 9998;
}

.menu-overlay.visible {
  opacity: 1;
  pointer-events: auto;
}

.side-menu {
  position: fixed;
  top: 0;
  right: 0;
  width: 260px;
  height: 100%;
  background-color: #1a1a2e;
  backdrop-filter: blur(6px);
  box-shadow: -4px 0 12px rgba(0,0,0,0.2);
  padding: 2rem 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  transform: translateX(100%);
  transition: transform 0.4s ease;
  z-index: 9999;
}

.side-menu.open {
  transform: translateX(0);
}

.side-menu ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.side-menu li a {
  font-family: 'Segoe UI', sans-serif;
  font-size: 1.1rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #ffffff;
  text-decoration: none;
  padding: 0.5rem 0.75rem;
  border-radius: 0.25rem;
  transition: background-color 0.3s ease, color 0.3s ease;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.menu-icon {
  width: 20px;
  height: 20px;
  stroke: #ffffff;
  margin-right: 0.5rem;
  transition: stroke 0.3s ease;
  flex-shrink: 0;
}

.side-menu li a:hover {
  background-color: rgba(255, 255, 255, 0.1);
  color: #00aaff;
}

.side-menu li a:hover .menu-icon {
  stroke: #00aaff;
}

body.menu-open {
  overflow: hidden;
  padding-right: 17px;
}

/* 🧱 Projects */

.projects {
  padding: 3rem 2rem;
  max-width: 1200px;
  margin: 0 auto;
  text-align: center;
  position: relative;
}

.projects h2 {
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  color: #f0f0f0;
  margin-bottom: 2rem;
}

.project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  justify-items: center;
  position: relative;
}

.card {
  text-decoration: none !important;
  color: #ffffff !important;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  background-color: #003366;
  border-radius: 1rem;
  padding: 2rem;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  transition: transform 0.3s ease;
  max-width: 100%;
  position: relative;
  z-index: 10;
}

.card:hover {
  transform: translateY(-5px);
  box-shadow: 0 6px 16px rgba(0,0,0,0.2);
}

.card img {
  width: 100%;
  border-radius: 0.75rem;
  object-fit: cover;
  margin-bottom: 1rem;
  transition: transform 0.4s ease;
}

.card:hover img {
  transform: scale(1.05);
}

.card h3 {
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-size: clamp(1.3rem, 3vw, 1.8rem);
  font-weight: 700;
  line-height: 1.3;
  margin-bottom: 0.5rem;
}

.external-icon {
  font-size: 1rem;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.card:hover .external-icon {
  opacity: 1;
}

.card p {
  font-size: clamp(1.1rem, 2.5vw, 1.3rem);
  line-height: 1.6;
  color: #f0f0f0;
  text-shadow: 0 1px 3px rgba(0,0,0,0.6);
}

/* slide avis */

.slider-wrapper {
  padding: 3rem 2rem;
  max-width: 800px;
  margin: 0 auto;
}

.djinn-slider {
  position: relative;
  width: 100%;
  max-width: 800px;
  margin: 0 auto;
  padding: 3rem 2rem;
  background-color: #003366;
  border-radius: 1rem;
  box-shadow: 0 0 10px rgba(0,0,0,0.1);
  box-sizing: border-box;
  height: 220px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.djinn-slide {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 100%;
  padding: 1rem 1.5rem;
  text-align: center;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 1s ease-in-out;
}

.djinn-slide.active {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.stars {
  font-size: clamp(1.2rem, 2.5vw, 1.5rem);
  color: gold;
  margin-bottom: 0.5rem;
}

.djinn-slide p {
  font-size: clamp(1rem, 2.5vw, 1.2rem);
  font-style: italic;
  line-height: 1.6;
  margin-bottom: 0.5rem;
  color: #f0f0f0;
  text-shadow: 0 1px 3px rgba(0,0,0,0.6);
}

.djinn-slide span {
  font-size: 0.95rem;
  color: #aaa;
}
/* Process */

.process-section {
  padding: 4rem 2rem;
  text-align: center;
  background-color: transparent;
}

.process-section h2 {
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  color: #f0f0f0;
  margin-bottom: 2rem;
}

.process-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 2rem;
  max-width: 1200px;
  margin: 0 auto;
}

.process-step {
  background-color: #003366;
  border-radius: 1rem;
  padding: 2rem 1.5rem;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  transition: transform 0.3s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
}

.process-step:hover {
  transform: translateY(-5px);
  box-shadow: 0 6px 16px rgba(0,0,0,0.2);
}

.step-number {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background-color: #00aaff;
  color: #ffffff;
  font-weight: 700;
  font-size: 1.3rem;
}

.process-step p {
  color: #f0f0f0;
  font-size: clamp(1rem, 2.5vw, 1.2rem);
  line-height: 1.5;
  text-shadow: 0 1px 3px rgba(0,0,0,0.6);
}
/* 📬 Contact (logo + mail + réseaux) */

.contact {
  text-align: center;
  padding: 60px 20px;
  color: #f5f7ff;
}

.contact h2 {
  font-family: "Playfair Display", serif;
  font-size: 2rem;
  margin-bottom: 25px;
}

.contact-logo {
  max-width: 150px;
  margin-bottom: 15px;
}

.contact-mail {
  font-size: 1.2rem;
  color: #9ec3ff;
  text-decoration: none;
  font-weight: 500;
}

.contact-mail:hover {
  text-decoration: underline;
}

.contact-social {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  margin-top: 2rem;
}

.contact-social img {
  width: clamp(40px, 5vw, 64px);
  height: auto;
  object-fit: contain;
  transition: transform 0.3s ease, filter 0.3s ease;
  filter: drop-shadow(0 1px 3px rgba(0,0,0,0.4));
}

.contact-social img:hover {
  transform: scale(1.1);
  filter: drop-shadow(0 2px 6px rgba(0,0,0,0.6));
}
.contact-social-svg svg {
  width: clamp(40px, 5vw, 64px);
  height: auto;
}
/* 🦶 Footer */

.footer {
  background: transparent;
  color: #ffffff;
  padding: 2rem 1rem;
  margin-top: 4rem;
  text-align: center;
}


.footer-content {
  width: 100%;
  padding: 1rem 2rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  text-align: center;
}

.footer p {
  font-size: 1rem;
  margin: 0;
}

/* 📱 Mobile */

@media (max-width: 600px) {
  body {
    padding-left: 0;
    padding-right: 0;
  }

  .projects {
    padding: 2rem 1rem;
    display: grid;
    justify-items: center;
  }

  .card {
    width: 100%;
    max-width: 400px;
    padding: 1rem;
  }

  .contact {
    padding-left: 1rem;
    padding-right: 1rem;
  }
}

/* 🖥️ Ultra-wide */

@media (min-width: 1200px) {
  .contact {
    max-width: 800px;
    margin: 0 auto;
  }
}

/* Skills */

.skills-section {
  padding: 4rem 2rem;
  background-color: transparent;
  text-align: center;
}

.skills-section h2 {
  font-size: clamp(2rem, 5vw, 3rem);
  color: #f0f0f0;
  margin-bottom: 2rem;
}

.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 2rem;
  justify-items: stretch;
}


.skill-card {
  background-color: #003366;
  color: #f0f0f0;
  padding: 2rem;
  border-radius: 1rem;
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
  max-width: 100%;
  transition: transform 0.3s ease;
}

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

.skill-card h3 {
  font-size: clamp(1.5rem, 4vw, 2rem);
  margin-bottom: 1rem;
}

.skill-card p {
  font-size: clamp(1rem, 2.5vw, 1.2rem);
  line-height: 1.6;
}

/* Sécurité : SVG & z-index */

.svg-ciel,
.svg-dune-front,
.svg-dune-back {
  pointer-events: none;
}
