:root {
  --surface: #0f1f3a;
  --panel: #12254a;
  --text: #e9edf5;
  --muted: #b7c4d6;
  --accent: #5aa4ff;
  --accent-2: #7cd4ff;
  --border: #1f355c;
  --success: #6df3c5;
  --shadow: 0 20px 60px rgba(0, 0, 0, 0.35);
  --radius: 16px;
  --radius-sm: 12px;
  font-family: "Inter", system-ui, -apple-system, sans-serif;
  color: var(--text);
  background: var(--bg);
}
*,*::before,*::after {
  box-sizing: border-box;
}
html {
  height: 100%;
  background: #0a1426;
  overflow-x: hidden;
}

/* Barre de défilement personnalisée */
::-webkit-scrollbar {
  width: 12px;
}

::-webkit-scrollbar-track {
  background: rgba(15, 31, 58, 0.5);
  border-left: 1px solid rgba(90, 164, 255, 0.1);
}

::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, var(--accent), var(--accent-2));
  border-radius: 10px;
  border: 2px solid rgba(15, 31, 58, 0.5);
  box-shadow: 0 0 10px rgba(90, 164, 255, 0.3);
  transition: all 0.3s ease;
}

::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, var(--accent-2), var(--accent));
  box-shadow: 0 0 15px rgba(90, 164, 255, 0.5);
  border-color: rgba(90, 164, 255, 0.3);
}

/* Pour Firefox */
* {
  scrollbar-width: thin;
  scrollbar-color: var(--accent) rgba(15, 31, 58, 0.5);
}
body {
  margin: 0;
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
  height: 100%;
  text-rendering: optimizeLegibility;
  font-size: clamp(0.875rem, 0.8rem + 0.4vw, 0.95rem);
  background: linear-gradient(135deg, #0a1426 0%, #1a2f4a 25%, #0f1f3a 50%, #1a2f4a 75%, #0a1426 100%);
  background-size: 400% 400%;
  background-attachment: fixed;
  animation: gradientShift 20s ease infinite;
  position: relative;
  overflow-x: hidden;
  width: 100%;
}

body::before {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: 
    radial-gradient(circle at 20% 50%, rgba(90, 164, 255, 0.2) 0%, transparent 50%),
    radial-gradient(circle at 80% 80%, rgba(124, 212, 255, 0.18) 0%, transparent 50%),
    radial-gradient(circle at 40% 20%, rgba(90, 164, 255, 0.15) 0%, transparent 50%),
    radial-gradient(circle at 60% 70%, rgba(109, 243, 197, 0.1) 0%, transparent 40%);
  z-index: -2;
  pointer-events: none;
  animation: pulseGlow 8s ease-in-out infinite;
}

body::after {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: 
    repeating-linear-gradient(0deg, transparent, transparent 2px, rgba(90, 164, 255, 0.04) 2px, rgba(90, 164, 255, 0.04) 4px),
    repeating-linear-gradient(90deg, transparent, transparent 2px, rgba(124, 212, 255, 0.04) 2px, rgba(124, 212, 255, 0.04) 4px);
  z-index: -2;
  pointer-events: none;
  opacity: 0.6;
}

@keyframes gradientShift {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

@keyframes pulseGlow {
  0%, 100% { 
    opacity: 1;
    transform: scale(1);
  }
  50% { 
    opacity: 0.8;
    transform: scale(1.1);
  }
}

@keyframes gridMove {
  0% { transform: translate(0, 0); }
  100% { transform: translate(20px, 20px); }
}

/* Particules animées */
.particles {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  pointer-events: none;
  overflow: hidden;
}

.particle {
  position: absolute;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(90, 164, 255, 0.4), transparent);
  animation: float 15s infinite ease-in-out;
}

.particle:nth-child(1) {
  width: 300px;
  height: 300px;
  top: 10%;
  left: 10%;
  animation-delay: 0s;
  animation-duration: 20s;
}

.particle:nth-child(2) {
  width: 200px;
  height: 200px;
  top: 60%;
  left: 70%;
  animation-delay: -5s;
  animation-duration: 18s;
}

.particle:nth-child(3) {
  width: 250px;
  height: 250px;
  top: 30%;
  left: 50%;
  animation-delay: -10s;
  animation-duration: 22s;
}

.particle:nth-child(4) {
  width: 180px;
  height: 180px;
  top: 80%;
  left: 20%;
  animation-delay: -7s;
  animation-duration: 16s;
}

.particle:nth-child(5) {
  width: 220px;
  height: 220px;
  top: 50%;
  left: 85%;
  animation-delay: -12s;
  animation-duration: 19s;
}

@keyframes float {
  0%, 100% {
    transform: translate(0, 0) scale(1);
    opacity: 0.3;
  }
  25% {
    transform: translate(50px, -50px) scale(1.1);
    opacity: 0.5;
  }
  50% {
    transform: translate(-30px, 30px) scale(0.9);
    opacity: 0.4;
  }
  75% {
    transform: translate(30px, 50px) scale(1.05);
    opacity: 0.45;
  }
}

/* Formes géométriques animées */
.geometric-shapes {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  pointer-events: none;
  overflow: hidden;
}

.shape {
  position: absolute;
  border: 2px solid rgba(90, 164, 255, 0.2);
  animation: rotateFloat 25s infinite linear;
}

.shape:nth-child(1) {
  width: 150px;
  height: 150px;
  top: 15%;
  left: 15%;
  border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%;
  animation-duration: 30s;
}

.shape:nth-child(2) {
  width: 100px;
  height: 100px;
  top: 70%;
  left: 75%;
  border-radius: 50%;
  animation-duration: 25s;
  animation-direction: reverse;
}

.shape:nth-child(3) {
  width: 120px;
  height: 120px;
  top: 40%;
  left: 60%;
  clip-path: polygon(50% 0%, 0% 100%, 100% 100%);
  border: none;
  background: linear-gradient(135deg, rgba(90, 164, 255, 0.1), rgba(124, 212, 255, 0.05));
  animation-duration: 35s;
}

@keyframes rotateFloat {
  0% {
    transform: translate(0, 0) rotate(0deg);
    opacity: 0.3;
  }
  50% {
    transform: translate(100px, -100px) rotate(180deg);
    opacity: 0.5;
  }
  100% {
    transform: translate(0, 0) rotate(360deg);
    opacity: 0.3;
  }
}

a {
  color: inherit;
  text-decoration: none;
}
h1,h2,h3 {
  margin: 0 0 10px;
  line-height: 1.2;
}
p {
  margin: 0 0 14px;
  color: var(--muted);
}
/* Prevent body scroll when menu is open */
body.no-scroll {
  overflow: hidden;
  position: fixed;
  width: 100%;
}

.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px clamp(20px, 4vw, 48px);
  background: #0c1428;
  backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  transition: transform 0.3s ease-in-out;
}

.nav__brand {
  font-weight: 700;
  letter-spacing: 0.5px;
  display: flex;
  align-items: center;
  height: 100%;
  line-height: 1;
}

.nav nav {
  display: flex;
  gap: 18px;
}

.nav nav a {
  padding: 8px 10px;
  border-radius: 10px;
  font-weight: 500;
  transition: color 0.2s ease, background 0.2s ease;
  color: var(--muted);
}

.nav nav a:hover,
.nav nav a.active {
  color: var(--text);
  background: rgba(90, 164, 255, 0.12);
}

.nav__toggle {
  display: none;
  background: transparent;
  border: none;
  padding: 8px;
  cursor: pointer;
  z-index: 1001;
  position: relative;
  width: 40px;
  height: 40px;
  justify-content: center;
  align-items: center;
  flex-direction: column;
}
.nav__toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text);
  margin: 3px 0;
  transition: transform 0.3s ease, opacity 0.3s ease;
  border-radius: 2px;
}
.nav__toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(7px, 7px);
}
.nav__toggle.active span:nth-child(2) {
  opacity: 0;
}
.nav__toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(7px, -7px);
}
main {
}

.section {
  padding: clamp(40px, 8vw, 120px) clamp(16px, 4vw, 80px);
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
  box-sizing: border-box;
}
.will-reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.reveal {
  opacity: 1;
  transform: translateY(0);
}

/* Ensure skill bars are always visible and not affected by reveal animations */
.skill__bar-fill,
.apropos__skill-bar-fill,
.modal__skill-bar-fill {
  opacity: 1 !important;
  visibility: visible !important;
}
.section__header {
  max-width: 720px;
  margin: 0 auto 32px;
  text-align: center;
}
.eyebrow {
  display: inline-block;
  padding: 6px 12px;
  border-radius: 999px;
  background: none;
   color: var(--accent);
   font-weight: 600;
  font-size: 14px;
   letter-spacing: 0.4px;
  text-transform: none;
 }
.lead {
  font-size: clamp(15px, 1.5vw, 18px);
}
.hero {
  display: flex;
  align-items: center;
  position: relative;
  min-height: 90vh;
  padding-top: clamp(40px, 6vw, 80px);
  padding-bottom: clamp(60px, 12vw, 160px);
}
.hero__content {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  width: 100%;
}
.hero__header {
  display: flex;
  align-items: center;
  gap: 24px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 10px;
}
.hero__photo {
  flex-shrink: 0;
}
.hero__portrait {
  width: 150px;
  height: 200px;
  border-radius: 20px;
  object-fit: cover;
  border: 4px solid rgba(90, 164, 255, 0.3);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5), 0 0 0 0 rgba(90, 164, 255, 0.4);
  animation: portraitGlow 3s ease-in-out infinite;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.hero__portrait:hover {
  transform: scale(1.05);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5), 0 0 30px rgba(90, 164, 255, 0.6);
}
@keyframes portraitGlow {
  0%, 100% {
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5), 0 0 0 0 rgba(90, 164, 255, 0.4);
  }
  50% {
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5), 0 0 20px rgba(90, 164, 255, 0.5);
  }
}
.hero__name {
  font-size: clamp(32px, 7vw, 60px);
  color: var(--text);
  font-weight: 800;
  margin: 0;
}
.hero__title {
  font-size: clamp(24px, 5vw, 48px);
  color: var(--muted);
   font-weight: 600;
  margin: 10px 0 20px 0;
}
.hero__description {
  max-width: 600px;
  font-size: 16px;
  color: var(--muted);
  margin-bottom: 40px;
}
.hero__visual, .portrait, .badge, .stats {
  display: none;
}
.hero__actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin: 18px 0;
}
.scroll-down-indicator {
    position: absolute;
    bottom: 20px;
     left: 50%;
    transform: translateX(-50%);
    display: block;
    padding: 20px;
    opacity: 0.8;
    transition: opacity 0.2s ease;
}
.scroll-down-indicator:hover {
    opacity: 1;
}
.mouse {
    width: 30px;
    height: 50px;
    border: 2px solid var(--accent);
     border-radius: 15px;
    position: relative;
    animation: pulse 2s infinite;
 }
.wheel {
    width: 4px;
    height: 10px;
    background: var(--accent);
    border-radius: 50%;
    position: absolute;
    top: 8px;
     left: 50%;
    transform: translateX(-50%);
    animation: scroll 1.5s infinite;
 }
@keyframes scroll {
    0% {
        opacity: 1;
        transform: translate(-50%, 0);
    }
    100% {
        opacity: 0;
        transform: translate(-50%, 15px);
     }
}
@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(90, 164, 255, 0.4);
     }
    70% {
        box-shadow: 0 0 0 10px rgba(90, 164, 255, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(90, 164, 255, 0);
    }
}
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 18px;
  border-radius: 12px;
  font-weight: 600;
  cursor: pointer;
  border: 1px solid transparent;
  transition: transform 0.15s ease, box-shadow 0.2s ease, border 0.2s ease, background 0.2s ease;
}
.btn.primary {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #0a1426;
  box-shadow: var(--shadow);
}
.btn.ghost {
  border-color: rgba(90, 164, 255, 0.4);
  color: var(--text);
  background: rgba(90, 164, 255, 0.08);
}
.btn:hover {
  transform: translateY(-1px);
}
.btn.full {
  width: 100%;
}
.about__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 18px;
  max-width: 1000px;
  margin: 0 auto;
}
.about__card {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  background: var(--surface);
  box-shadow: var(--shadow);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.about__card:hover {
  transform: translateY(-2px);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.45);
}
.about__card ul {
  padding-left: 18px;
  margin: 0;
  color: var(--muted);
}
.about__card li {
  margin-bottom: 8px;
}
.about__card.highlight {
  background: linear-gradient(135deg, rgba(90, 164, 255, 0.15), var(--surface));
  border-color: rgba(90, 164, 255, 0.35);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.45);
}
.projects .cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
  max-width: 1000px;
  margin: 0 auto;
}
.card {
  padding: 18px;
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
  display: block;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.45);
}
.card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(90, 164, 255, 0.12), transparent);
  opacity: 0;
  transition: opacity 0.2s ease;
}
.card:hover::after {
  opacity: 1;
}
.ap-projects .cards {
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}
.card--ap {
  border-color: rgba(124, 212, 255, 0.55);
  background: linear-gradient(135deg, rgba(90, 164, 255, 0.14), rgba(10, 20, 40, 0.6));
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.5);
}
.card--ap .pill {
  background: rgba(124, 212, 255, 0.25);
  color: #e9f7ff;
}
.card__icon {
  font-size: 20px;
  margin-bottom: 8px;
}
.pill {
  display: inline-block;
  margin-right: 8px;
  margin-top: 8px;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(90, 164, 255, 0.14);
  color: var(--accent-2);
  font-weight: 600;
  font-size: 11px;
}
.skills .section__header {
  text-align: center;
  margin-left: auto;
  margin-right: auto;
}
.skills .skill-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 14px;
  max-width: 1000px;
  margin: 0 auto;
}
.skill {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 12px;
  padding: 16px;
  border-radius: var(--radius-sm);
  background: var(--surface);
  border: 1px solid var(--border);
  transition: transform 0.2s ease;
}
.skill:hover {
  transform: translateY(-2px);
}
.skill__icon {
  font-size: 18px;
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: rgba(90, 164, 255, 0.12);
  flex-shrink: 0;
}
.skill__content {
  flex: 1;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.skill__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
  width: 100%;
}
.skill__header h3 {
  margin: 0;
  font-size: 16px;
  color: var(--text);
}
.skill__percent {
  font-size: 14px;
  font-weight: 600;
  color: var(--accent-2);
}
.skill__bar {
  width: 100%;
  height: 8px;
  background: rgba(90, 164, 255, 0.1);
  border-radius: 999px;
  overflow: hidden;
  margin-bottom: 10px;
  position: relative;
  max-width: 100%;
}
.skill__bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  border-radius: 999px;
  width: 0%;
  transition: width 1.5s ease-out;
  position: relative;
  overflow: hidden;
}
.skill__bar-fill::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  animation: shimmer 2s infinite;
}
@keyframes shimmer {
  0% {
    transform: translateX(-100%);
  }
  100% {
    transform: translateX(100%);
  }
}
.contact__form {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px;
  background: var(--panel);
  max-width: 640px;
  margin: 0 auto;
  box-shadow: var(--shadow);
}
.form__row {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 14px;
}
label {
  font-weight: 600;
  color: var(--text);
}
input,textarea {
  width: 100%;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 12px 14px;
  color: var(--text);
  font-size: 15px;
  transition: border 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}
textarea {
  resize: none;
}
input:focus,textarea:focus {
  outline: none;
  border-color: var(--accent-2);
  background: rgba(90, 164, 255, 0.05);
  box-shadow: 0 0 0 3px rgba(90, 164, 255, 0.15);
}
.form__feedback {
  min-height: 20px;
  color: var(--success);
  font-weight: 600;
  margin-top: 8px;
}
.form__char-count {
  font-size: 0.85em;
  color: var(--muted);
  text-align: right;
  margin-top: 4px;
}
#submit-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}
.footer {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  border-top: 1px solid var(--border);
  padding: 12px clamp(20px, 4vw, 48px);
  color: var(--muted);
  display: flex;
  gap: 16px;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  background: #0c1428;
  backdrop-filter: blur(14px);
}
.footer p {
  margin: 0;
  display: flex;
  align-items: center;
  height: 100%;
  line-height: 1;
}
.footer__links {
  display: flex;
  align-items: center;
}
.footer__links a {
  margin-left: 12px;
  color: var(--text);
  font-weight: 600;
}
@media (max-width: 780px) {
  .nav nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: auto;
    max-height: 100vh;
    background: rgba(12, 20, 40, 0.98);
    backdrop-filter: blur(20px);
    flex-direction: column;
    padding: 80px 24px 24px;
    box-shadow: none;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateX(100%);
    transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s ease, max-height 0.3s ease;
    z-index: 1000;
    overflow-y: auto;
    gap: 0;
    align-items: flex-start;
    justify-content: flex-start;
  }
  .nav nav.open {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateX(0);
  }
  .nav nav a {
    padding: 16px 20px;
    border-radius: var(--radius-sm);
    font-size: 18px;
    width: 100%;
    text-align: left;
    border-bottom: 1px solid rgba(90, 164, 255, 0.1);
  }
  .nav nav a:last-child {
    border-bottom: none;
  }
  .nav nav a:hover,
  .nav nav a.active {
    background: rgba(90, 164, 255, 0.15);
    transform: translateX(4px);
  }
  .nav__toggle {
    display: flex;
  }
  main {
    padding-top: 40px;
  }
}

/* Responsive Images */
img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Mobile optimizations */
@media (max-width: 540px) {
  .hero__visual {
    order: -1;
  }
  .hero__portrait {
    width: clamp(120px, 30vw, 180px);
    height: clamp(120px, 30vw, 180px);
  }
  .hero__name {
    font-size: clamp(28px, 8vw, 48px);
  }
  .hero__title {
    font-size: clamp(20px, 6vw, 36px);
  }
  .section__header {
    padding: 0 clamp(8px, 2vw, 16px);
  }
  .btn {
    padding: 10px 16px;
    font-size: 14px;
  }
  main {
    padding-bottom: 100px;
  }
}

/* Tablet optimizations */
@media (min-width: 541px) and (max-width: 780px) {
  .hero__portrait {
    width: clamp(150px, 25vw, 200px);
    height: clamp(150px, 25vw, 200px);
  }
}

/* Prevent horizontal overflow */
* {
  max-width: 100%;
}

.container,
.wrapper,
section {
  overflow-x: hidden;
}

/* Styles pour les modales de projets */
.modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.modal--active {
  opacity: 1;
  visibility: visible;
}

.modal__overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(10, 20, 38, 0.85);
  backdrop-filter: blur(8px);
}

.modal__content {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  max-width: 800px;
  width: 90%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6);
  transform: scale(0.9) translateY(20px);
  transition: transform 0.3s ease;
  z-index: 10001;
}

.modal--active .modal__content {
  transform: scale(1) translateY(0);
}

.modal__close {
  position: absolute;
  top: 20px;
  right: 20px;
  background: rgba(90, 164, 255, 0.1);
  border: 1px solid rgba(90, 164, 255, 0.3);
  border-radius: 50%;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  color: var(--text);
  cursor: pointer;
  transition: all 0.2s ease;
  z-index: 10;
}

.modal__close:hover {
  background: rgba(90, 164, 255, 0.2);
  border-color: var(--accent);
  transform: rotate(90deg);
}

.modal__header {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 32px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--border);
  background: linear-gradient(135deg, rgba(90, 164, 255, 0.08), rgba(124, 212, 255, 0.04));
}

.modal__icon {
  font-size: 48px;
  width: 80px;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-sm);
  background: rgba(90, 164, 255, 0.15);
  flex-shrink: 0;
}

.modal__title {
  font-size: 28px;
  color: var(--text);
  font-weight: 700;
  margin: 0 0 8px 0;
}

.modal__date {
  font-size: 14px;
  color: var(--accent);
  font-weight: 600;
  margin: 0;
}

.modal__body {
  padding: 32px;
}

.modal__section {
  margin-bottom: 32px;
}

.modal__section:last-child {
  margin-bottom: 0;
}

.modal__section h3 {
  font-size: 20px;
  color: var(--accent-2);
  font-weight: 600;
  margin: 0 0 16px 0;
  padding-bottom: 8px;
  border-bottom: 2px solid rgba(90, 164, 255, 0.2);
}

.modal__section ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.modal__section li {
  padding: 12px 0;
  padding-left: 24px;
  position: relative;
  color: var(--muted);
  line-height: 1.6;
}

.modal__section li::before {
  content: "▸";
  position: absolute;
  left: 0;
  color: var(--accent);
  font-weight: bold;
}

.modal__filters {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.modal__filter-item {
  background: rgba(90, 164, 255, 0.06);
  border: 1px solid rgba(90, 164, 255, 0.2);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
}

.modal__filter-item strong {
  display: block;
  color: var(--text);
  font-weight: 600;
  margin-bottom: 6px;
  font-size: 14px;
}

.modal__filter-item code {
  display: block;
  background: rgba(0, 0, 0, 0.2);
  padding: 8px 12px;
  border-radius: 6px;
  color: var(--accent-2);
  font-family: 'Courier New', monospace;
  font-size: 13px;
  word-break: break-all;
}

.modal__skills {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.modal__skill-item {
  width: 100%;
}

.modal__skill-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.modal__skill-name {
  font-size: 14px;
  color: var(--text);
  font-weight: 500;
}

.modal__skill-percent {
  font-size: 13px;
  font-weight: 600;
  color: var(--accent-2);
}

.modal__skill-bar {
  width: 100%;
  height: 8px;
  background: rgba(90, 164, 255, 0.1);
  border-radius: 999px;
  overflow: hidden;
  position: relative;
}

.modal__skill-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  border-radius: 999px;
  width: 0%;
  transition: width 1.5s ease-out;
  position: relative;
  overflow: hidden;
}

.modal__skill-bar-fill::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  animation: shimmer 2s infinite;
}

.modal__code-container {
  margin-top: 16px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1px solid rgba(90, 164, 255, 0.2);
  background: linear-gradient(135deg, #0a1426 0%, #0f1f3a 100%);
  box-shadow: inset 0 2px 8px rgba(0, 0, 0, 0.3);
}

.modal__code {
  margin: 0;
  padding: 24px;
  background: transparent;
  color: #e9edf5;
  font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
  font-size: 13px;
  line-height: 1.7;
  overflow-x: auto;
  max-height: 500px;
}

.modal__code code {
  display: block;
  white-space: pre-wrap;
  color: #e9edf5;
  background: transparent;
  padding: 0;
  font-family: inherit;
  font-size: inherit;
}

.modal__code .php-tag { color: #7cd4ff; font-weight: 600; }
.modal__code .php-keyword { color: #ff6b9d; font-weight: 600; }
.modal__code .php-function { color: #5aa4ff; }
.modal__code .php-variable { color: #ffd93d; }
.modal__code .php-string { color: #6df3c5; }
.modal__code .php-comment { color: #6a7b8c; font-style: italic; }

.modal__image-section {
  margin-bottom: 32px;
  text-align: center;
}

.modal__image {
  max-width: 100%;
  height: auto;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

.modal__image-caption {
  margin-top: 12px;
  font-size: 13px;
  color: var(--muted);
  font-style: italic;
}

@media (max-width: 780px) {
  .modal__content {
    width: 95%;
    max-height: 95vh;
  }
  .modal__header {
    flex-direction: column;
    text-align: center;
    padding: 24px;
  }
  .modal__body {
    padding: 24px;
  }
  .modal__title {
    font-size: 24px;
  }
}

/* Styles pour la page projets */
.summary {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  background: linear-gradient(135deg, rgba(90, 164, 255, 0.08), rgba(124, 212, 255, 0.04));
  box-shadow: var(--shadow);
  margin-bottom: 48px;
}

.summary__header {
  margin-bottom: 24px;
}

.summary__title {
  margin: 0 0 6px;
  color: var(--accent-2);
  font-weight: 700;
  font-size: 18px;
}

.summary__subtitle {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
}

.summary__links {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 12px;
}

.summary__link {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 18px;
  border-radius: var(--radius-sm);
  background: rgba(90, 164, 255, 0.06);
  border: 1px solid rgba(90, 164, 255, 0.2);
  transition: all 0.3s ease;
  text-decoration: none;
  color: inherit;
}

.summary__link:hover {
  transform: translateY(-2px);
  border-color: var(--accent);
  box-shadow: 0 8px 24px rgba(90, 164, 255, 0.2);
}

.summary__link-icon {
  font-size: 28px;
  flex-shrink: 0;
}

.summary__link-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.summary__link-title {
  display: block;
  font-weight: 600;
  color: var(--text);
  font-size: 16px;
}

.summary__link-desc {
  display: block;
  font-size: 13px;
  color: var(--muted);
}

.summary__link-arrow {
  font-size: 20px;
  color: var(--accent);
  transition: transform 0.3s ease;
}

.summary__link:hover .summary__link-arrow {
  transform: translateX(4px);
}

.semester-section {
  margin-bottom: 48px;
}

.semester-title {
  font-size: 20px;
  color: var(--accent-2);
  font-weight: 600;
  margin: 0 0 20px 0;
  padding-bottom: 12px;
  border-bottom: 2px solid rgba(90, 164, 255, 0.2);
}

.project-modal-trigger {
  cursor: pointer;
}

/* Styles pour la page à propos */
.apropos__hero {
  display: flex;
  align-items: center;
  gap: 32px;
  margin-bottom: 48px;
  padding-bottom: 32px;
  border-bottom: 1px solid var(--border);
  flex-wrap: wrap;
}

.apropos__photo {
  flex-shrink: 0;
}

.apropos__portrait {
  width: 150px;
  height: 200px;
  border-radius: 20px;
  object-fit: cover;
  border: 4px solid rgba(90, 164, 255, 0.3);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.apropos__name {
  font-size: clamp(36px, 6vw, 48px);
  color: var(--text);
  font-weight: 800;
  margin-bottom: 8px;
}

.apropos__title {
  font-size: 20px;
  color: var(--accent);
  font-weight: 600;
  margin-bottom: 4px;
}

.apropos__subtitle {
  font-size: 16px;
  color: var(--muted);
}

.apropos__content {
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.apropos__section {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow);
}

.apropos__section-title {
  font-size: 24px;
  color: var(--accent-2);
  font-weight: 700;
  margin-bottom: 20px;
  padding-bottom: 12px;
  border-bottom: 2px solid rgba(90, 164, 255, 0.2);
}

.apropos__text {
  color: var(--muted);
  line-height: 1.7;
}

.apropos__text strong {
  color: var(--text);
  font-weight: 600;
}

.apropos__timeline {
  display: flex;
  flex-direction: column;
  gap: 24px;
  position: relative;
  padding-left: 32px;
}

.apropos__timeline::before {
  content: "";
  position: absolute;
  left: 8px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: linear-gradient(to bottom, var(--accent), var(--accent-2));
}

.apropos__timeline-item {
  position: relative;
}

.apropos__timeline-marker {
  position: absolute;
  left: -32px;
  top: 4px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--accent);
  border: 3px solid var(--surface);
}

.apropos__timeline-content h3 {
  font-size: 18px;
  color: var(--text);
  font-weight: 600;
  margin-bottom: 4px;
}

.apropos__timeline-date {
  color: var(--accent);
  font-weight: 600;
  font-size: 14px;
  margin-bottom: 4px;
  display: block;
}

.apropos__skills {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
}

.apropos__skill-card {
  background: rgba(90, 164, 255, 0.06);
  border: 1px solid rgba(90, 164, 255, 0.2);
  border-radius: var(--radius-sm);
  padding: 20px;
}

.apropos__skill-icon {
  font-size: 32px;
  margin-bottom: 12px;
}

.apropos__skill-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}

.apropos__skill-card h3 {
  font-size: 18px;
  color: var(--accent-2);
  font-weight: 600;
  margin: 0;
}

.apropos__skill-percent {
  font-size: 14px;
  font-weight: 600;
  color: var(--accent-2);
}

.apropos__skill-bar {
  width: 100%;
  height: 10px;
  background: rgba(90, 164, 255, 0.1);
  border-radius: 999px;
  overflow: hidden;
  margin-bottom: 12px;
}

.apropos__skill-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  border-radius: 999px;
  width: 0%;
  transition: width 1.5s ease-out;
}

.apropos__experience {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.apropos__experience-card {
  background: rgba(90, 164, 255, 0.08);
  border: 1px solid rgba(90, 164, 255, 0.3);
  border-radius: var(--radius-sm);
  padding: 20px;
}

.apropos__experience-card.highlight {
  background: rgba(90, 164, 255, 0.12);
  border-color: var(--accent);
}

.apropos__experience-card h3 {
  font-size: 18px;
  color: var(--accent-2);
  font-weight: 600;
  margin-bottom: 8px;
}

.apropos__interests {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}

.apropos__interest-item {
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding: 28px;
  background: linear-gradient(135deg, rgba(90, 164, 255, 0.08), rgba(124, 212, 255, 0.04));
  border: 1px solid rgba(90, 164, 255, 0.2);
  border-radius: var(--radius);
}

.apropos__interest-icon {
  font-size: 48px;
  flex-shrink: 0;
}

.apropos__interest-item h3 {
  font-size: 20px;
  color: var(--accent-2);
  font-weight: 700;
  margin-bottom: 8px;
}

.apropos__project {
  background: rgba(90, 164, 255, 0.06);
  border: 1px solid rgba(90, 164, 255, 0.2);
  border-radius: var(--radius-sm);
  padding: 20px;
}

.apropos__actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  margin-top: 40px;
  flex-wrap: wrap;
}

/* Styles pour la page CV */
.cv {
  max-width: 900px;
}

.cv__header {
  text-align: center;
  margin-bottom: 48px;
  padding-bottom: 32px;
  border-bottom: 1px solid var(--border);
}

.cv__name {
  font-size: clamp(36px, 6vw, 48px);
  color: var(--text);
  font-weight: 800;
  margin-bottom: 8px;
}

.cv__title {
  font-size: 20px;
  color: var(--accent);
  font-weight: 600;
  margin-bottom: 4px;
}

.cv__subtitle {
  font-size: 16px;
  color: var(--muted);
}

.cv__preview {
  margin: 24px auto 0;
  max-width: 860px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.cv__preview-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  padding: 16px;
  background: rgba(90, 164, 255, 0.06);
  border: 1px solid rgba(90, 164, 255, 0.2);
  border-radius: var(--radius-sm);
}

.cv__preview-text {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}

.cv__preview-text strong {
  color: var(--text);
  font-weight: 600;
}

.cv__preview-iframe-container {
  width: 100%;
  height: 800px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.cv__preview-iframe {
  width: 100%;
  height: 100%;
  border: none;
}

.cv__actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  margin-top: 40px;
  flex-wrap: wrap;
}
/* ====== PAGE AP / ATELIERS PRO ====== */

.ap-section {
  min-height: calc(100vh - 140px);
  display: flex;
  align-items: flex-start;
  justify-content: center;
}

.ap-wrapper {
  width: 100%;
  max-width: 960px;
  margin: 40px auto 80px;
  padding: 32px 36px;
  border-radius: var(--radius);
  background: linear-gradient(145deg, rgba(10, 20, 40, 0.96), rgba(18, 37, 74, 0.96));
  border: 1px solid rgba(90, 164, 255, 0.28);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

/* En‑tête AP */

.ap-header {
  margin-bottom: 28px;
  text-align: left;
}

.ap-title {
  font-size: clamp(26px, 3vw, 32px);
  color: var(--text);
  font-weight: 700;
  margin: 6px 0 6px;
}

.ap-subtitle {
  margin: 0;
  color: var(--muted);
  max-width: 640px;
}

/* Accès rapide */

.ap-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-top: 14px;
}

.ap-chips-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
  margin-right: 4px;
}

.ap-chip {
  display: inline-flex;
  align-items: center;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 13px;
  background: rgba(90, 164, 255, 0.12);
  border: 1px solid rgba(90, 164, 255, 0.35);
  color: var(--text);
  transition: background 0.2s ease, transform 0.12s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.ap-chip:hover {
  background: rgba(90, 164, 255, 0.22);
  border-color: var(--accent-2);
  box-shadow: 0 10px 30px rgba(90, 164, 255, 0.35);
  transform: translateY(-1px);
}

/* Blocs AP */

.ap-block {
  margin-top: 26px;
  padding-top: 18px;
  border-top: 1px solid rgba(90, 164, 255, 0.18);
}

.ap-block:first-of-type {
  border-top: none;
  padding-top: 0;
}

.ap-block-title {
  font-size: 20px;
  color: var(--accent-2);
  font-weight: 600;
  margin: 0 0 4px;
}

.ap-block-subtitle {
  margin: 0 0 14px;
  color: var(--muted);
}

/* Contexte */

.ap-context-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
  margin-top: 10px;
}

.ap-context-grid h3 {
  margin-bottom: 6px;
  color: var(--text);
}

/* Boutons */

.ap-actions {
  margin-top: 16px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.ap-btn {
  padding-inline: 16px;
  font-size: 14px;
}

/* Tableau des missions */

.ap-table-wrap {
  margin-top: 14px;
  overflow-x: auto;
}

.ap-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
}

.ap-table thead th {
  padding: 10px 8px;
  text-align: left;
  border-bottom: 1px solid rgba(90, 164, 255, 0.4);
  color: var(--muted);
  font-weight: 600;
}

.ap-table tbody td {
  padding: 10px 8px;
  vertical-align: top;
}

.ap-table tbody tr:nth-child(even) {
  background: rgba(255, 255, 255, 0.02);
}

.ap-table ul {
  margin: 0;
  padding-left: 18px;
}

/* Bloc Trello */

.ap-trello {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.ap-trello-main p {
  margin-bottom: 0;
}

/* Responsive AP */

@media (max-width: 900px) {
  .ap-wrapper {
    margin: 24px 12px 80px;
    padding: 24px 18px;
  }
}

@media (max-width: 700px) {
  .ap-section {
    min-height: auto;
  }

  .ap-header {
    text-align: left;
  }

  .ap-chips {
    align-items: flex-start;
  }

  .ap-chips-label {
    flex-basis: 100%;
    margin-bottom: 2px;
  }

  .ap-trello {
    flex-direction: column;
  }

  .ap-table thead {
    display: none;
  }

  .ap-table,
  .ap-table tbody,
  .ap-table tr,
  .ap-table td {
    display: block;
    width: 100%;
  }

  .ap-table tbody tr {
    border-bottom: 1px solid rgba(90, 164, 255, 0.25);
    margin-bottom: 12px;
    padding-bottom: 6px;
  }

  .ap-table tbody td {
    padding: 4px 0;
  }
}
/* ====== Cartes "tableau" des missions AP ====== */

.ap-missions-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
  margin-top: 18px;
}

.ap-mission-card {
  position: relative;
  padding: 18px 18px 14px;
  border-radius: var(--radius-sm);
  background: linear-gradient(145deg, rgba(15, 31, 58, 0.96), rgba(10, 20, 40, 0.9));
  border: 1px solid rgba(90, 164, 255, 0.28);
  box-shadow: var(--shadow);
  overflow: hidden;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.ap-mission-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 0 0, rgba(90, 164, 255, 0.18), transparent 60%);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

.ap-mission-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 26px 80px rgba(0, 0, 0, 0.6);
  border-color: var(--accent-2);
}

.ap-mission-card:hover::after {
  opacity: 1;
}

/* En‑tête mission */

.ap-mission-header {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 10px;
}

.ap-mission-badge {
  flex-shrink: 0;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(109, 243, 197, 0.12);
  border: 1px solid rgba(109, 243, 197, 0.6);
  color: var(--success);
  font-weight: 600;
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.ap-mission-title {
  margin: 0 0 2px;
  font-size: 16px;
  color: var(--text);
}

.ap-mission-tagline {
  margin: 0;
  font-size: 13px;
  color: var(--muted);
}

/* Corps mission */

.ap-mission-body h4 {
  margin: 6px 0 4px;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--accent-2);
}

.ap-mission-body ul {
  margin: 0;
  padding-left: 18px;
  color: var(--muted);
  font-size: 13px;
}

.ap-mission-body li + li {
  margin-top: 4px;
}

/* Pied de carte */

.ap-mission-footer {
  margin-top: 10px;
  padding-top: 8px;
  border-top: 1px dashed rgba(90, 164, 255, 0.35);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.ap-mission-label {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
}

.ap-mission-footer .ap-btn {
  padding: 8px 14px;
  font-size: 13px;
}

/* Responsive */

@media (max-width: 600px) {
  .ap-mission-footer {
    flex-direction: column;
    align-items: flex-start;
  }

  .ap-mission-footer .ap-btn {
    width: 100%;
    justify-content: center;
  }
}

/* Tableau des missions AP dans une carte type apropos__section */

.ap-missions-section {
  margin-top: 32px;
}

.ap-missions-title {
  font-size: 22px;
  color: var(--accent-2);
  font-weight: 700;
  margin: 0 0 6px;
}

.ap-missions-subtitle {
  margin: 0 0 16px;
  color: var(--muted);
}

.ap-table-wrap {
  overflow-x: auto;
}

.ap-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
}

.ap-table thead th {
  padding: 10px 8px;
  text-align: left;
  border-bottom: 1px solid rgba(90, 164, 255, 0.35);
  color: var(--muted);
  font-weight: 600;
}

.ap-table tbody td {
  padding: 10px 8px;
  vertical-align: top;
}

.ap-table tbody tr:nth-child(even) {
  background: rgba(255, 255, 255, 0.02);
}

.ap-table ul {
  margin: 0;
  padding-left: 18px;
}

/* Mobile : tableau "empilé" */

@media (max-width: 700px) {
  .ap-table thead {
    display: none;
  }

  .ap-table,
  .ap-table tbody,
  .ap-table tr,
  .ap-table td {
    display: block;
    width: 100%;
  }

  .ap-table tbody tr {
    border-bottom: 1px solid rgba(90, 164, 255, 0.25);
    margin-bottom: 12px;
    padding-bottom: 8px;
  }

  .ap-table tbody td {
    padding: 4px 0;
  }
}

/* Réduire l'espace sous le header sur la page AP */
main.ap-main {
  padding-top: 10px;   /* au lieu de 40px */
}

/* Diminuer un peu le padding haut de la section AP */
main.ap-main .section.ap-section {
  padding-top: 24px;   /* au lieu du clamp(40px, 8vw, 120px) global */
  padding-bottom: 48px;
}

@media (max-width: 780px) {
  main.ap-main {
    padding-top: 20px;  /* sur mobile, un peu plus pour ne pas coller au menu */
  }
}


.fallback-nav__list {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 1.25rem;
    list-style: none;
    margin: 0;
    padding: 100;
}
.fallback-nav__list a {
    text-decoration: none;
}
/* Responsive mobile */
@media (max-width: 768px) {
    .fallback-nav__list {
        gap: 0.75rem;
        flex-wrap: wrap;
    }
}


/* Conteneur global blog (même esprit apropos) */
.blog-shell {
  max-width: 1200px;
  margin: 0 auto;
}

.blog-head {
  margin-bottom: 20px;
}

/* Grille desktop */
.blog-layout {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr) 300px;
  gap: 18px;
  align-items: start;
}

/* Sticky sidebars */
.blog-side {
  position: sticky;
  top: 90px; /* compense ton header fixed */
}

/* Zone centrale */
.blog-content {
  min-width: 0;
}

/* Liste d'articles */
.blog-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

/* ===== Blog layout : contenu + sidebar droite ===== */
.blog-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 18px;
  align-items: start;
}

.blog-side {
  position: sticky;
  top: 90px;
}

/* Carte article */
.blog-post {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
  box-shadow: var(--shadow);
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}

.blog-post:hover {
  transform: translateY(-2px);
  border-color: rgba(124, 212, 255, 0.45);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.45);
}

.blog-post__meta {
  color: var(--muted);
  font-size: 13px;
  margin-bottom: 8px;
}

.blog-post__title {
  margin: 0 0 8px;
  font-size: clamp(20px, 2.2vw, 28px);
  color: var(--text);
}

.blog-post__excerpt {
  color: var(--muted);
}

/* Widgets */
.blog-widget-title {
  font-size: 16px;
  color: var(--accent-2);
  margin-bottom: 10px;
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(90, 164, 255, 0.2);
}

/* Tablette / mobile */
@media (max-width: 1024px) {
  .blog-layout {
    grid-template-columns: 1fr;
  }

  .blog-side {
    position: static;
    top: auto;
  }
}

@media (max-width: 640px) {
  .blog-post {
    padding: 14px;
  }

  .blog-post__title {
    font-size: 20px;
  }
}

/* ==========================================================================
   ARTICLE DÉTAILLÉ (SINGLE POST)
   ========================================================================== */

.article-container {
  max-width: 800px;
  margin: 40px auto;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}

/* En-tête de l'article */
.article-header {
  padding: 40px 40px 20px;
  border-bottom: 1px solid rgba(90, 164, 255, 0.1);
  background: linear-gradient(180deg, rgba(90, 164, 255, 0.05) 0%, transparent 100%);
}

.article-category {
  color: var(--accent);
  text-transform: uppercase;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 2px;
  margin-bottom: 12px;
  display: block;
}

.article-title {
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  line-height: 1.2;
  margin-bottom: 20px;
  color: var(--text);
}

.article-meta {
  display: flex;
  align-items: center;
  gap: 20px;
  color: var(--muted);
  font-size: 0.9rem;
}

/* Corps de l'article */
.article-body {
  padding: 40px;
  font-size: 1.1rem;
  line-height: 1.8;
  color: #d1d9e6; /* Un texte légèrement plus clair que var(--muted) pour la lecture */
}

/* Titres dans le contenu */
.article-body h2, 
.article-body h3 {
  color: var(--accent-2);
  margin-top: 2.5rem;
  margin-bottom: 1rem;
}

.article-body h2 {
  border-left: 4px solid var(--accent);
  padding-left: 15px;
}

/* Citations stylisées */
.article-body blockquote {
  margin: 30px 0;
  padding: 20px 30px;
  background: rgba(90, 164, 255, 0.05);
  border-radius: var(--radius-sm);
  border-left: 4px solid var(--accent-2);
  font-style: italic;
  color: var(--text);
}

/* Images dans l'article */
.article-body img {
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  margin: 2rem 0;
  box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

/* Listes */
.article-body ul, 
.article-body ol {
  margin-bottom: 1.5rem;
  padding-left: 20px;
}

.article-body li {
  margin-bottom: 10px;
}

/* Liens internes */
.article-body a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 4px;
  transition: color 0.2s ease;
}

.article-body a:hover {
  color: var(--accent-2);
}

/* Responsive */
@media (max-width: 640px) {
  .article-header, 
  .article-body {
    padding: 24px;
  }
}


.article-shell {
    padding-top: 100px; /* Compense la hauteur de la barre nav fixed */
    max-width: 900px;
    margin: 0 auto;
    padding-inline: 20px;
}

.article-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: center;
    align-items: center;
    margin: 20px 0 40px;
}

.article-meta span {
    background: rgba(90, 164, 255, 0.05); /* Ton bleu accent très léger */
    border: 1px solid var(--border);
    padding: 4px 12px;
    border-radius: 100px;
    font-size: 0.75rem;
    color: var(--muted);
    font-weight: 500;
}

/* On cache les points (·) qui ne servent plus avec les badges */
.article-meta span:nth-child(2n) {
    display: none; 
}

/* On met en avant la date */
.article-meta span:nth-child(2) {
    border-color: var(--accent);
    color: var(--accent-2);
}