/* RESET & BASE */
* { margin: 0; padding: 0; box-sizing: border-box; }
:root{ --accent:#ff5e57; }
body { font-family: 'Poppins', sans-serif; background:#f0f0f3; color:#111; line-height:1.6; transition: background .3s, color .3s; }
a { text-decoration: none; color: inherit; }
.container { width: 90%; max-width: 1200px; margin: auto; }

/* GLASS EFFECT */
.glass { background: rgba(255,255,255,0.15); backdrop-filter: blur(10px); border-radius: 15px; padding: 20px; box-shadow: 0 8px 32px rgba(0,0,0,0.1); transition: all .3s; }

/* HEADER */
.header { position: fixed; top: 0; width: 100%; z-index: 1000; padding: 12px 0; backdrop-filter: blur(10px); background: rgba(255,255,255,0.6); }
.nav { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.logo { font-weight: 700; font-size: 1.25rem; }
.nav-links { list-style: none; display: flex; gap: 25px; }
.nav-links li a { font-weight: 500; position: relative; }
.nav-links li a::after { content: ''; position: absolute; width: 0; height: 2px; background: var(--accent); bottom: -3px; left: 0; transition: .3s; }
.nav-links li a:hover::after { width: 100%; }

/* THEME SWITCH */
.theme-switch { display: inline-flex; align-items: center; cursor: pointer; }
.theme-switch input { display: none; }
.theme-switch .slider { display: inline-flex; align-items: center; justify-content: center; width: 50px; height: 25px; background: #ccc; border-radius: 50px; position: relative; transition: background .3s; }
.theme-switch .slider::before { content: ''; position: absolute; left: 3px; top: 3px; width: 19px; height: 19px; background: #fff; border-radius: 50%; transition: .3s; }
.theme-switch input:checked + .slider::before { transform: translateX(25px); }
.theme-switch .slider .sun, .theme-switch .slider .moon { position: absolute; font-size: 12px; }
.theme-switch .slider .sun { left: 5px; } .theme-switch .slider .moon { right: 5px; }

/* HERO */
.hero { padding-top: 90px; min-height: 100vh; display: flex; align-items: center; justify-content: center; position: relative; overflow: hidden; }
.hero-bg { position: absolute; inset: 0; background: linear-gradient(135deg, #ff5e57, #ffc371); z-index: -1; filter: blur(80px); }
.hero-content { text-align: center; }
.hero-content .avatar { width: 170px; height: 170px; border-radius: 50%; margin-bottom: 20px; border: 4px solid rgba(255,255,255,0.3); object-fit: cover; }
.hero-content h1 { font-size: 2.4rem; margin-bottom: 10px; }
.hero-content p { margin-bottom: 20px; font-size: 1.1rem; }
.hero-actions { display: flex; gap: 15px; justify-content: center; margin-bottom: 20px; flex-wrap: wrap; }
.btn { padding: 10px 24px; border-radius: 50px; font-weight: 600; transition: all .25s; cursor: pointer; border: none; }
.btn.primary { background: var(--accent); color: #fff; } .btn.primary:hover { transform: translateY(-1px); box-shadow: 0 6px 18px rgba(255,94,87,.35); }
.btn.ghost { background: transparent; border: 2px solid var(--accent); color: var(--accent); } .btn.ghost:hover { background: var(--accent); color: #fff; }

/* SOCIALS */
.socials { display: flex; justify-content: center; align-items: center; gap: 14px; margin-top: 8px; }
.social-link { display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px; border-radius: 50%; color: #111; transition: transform .2s ease, color .2s ease, background-color .2s ease; }
.social-link:hover { color: var(--accent); background-color: rgba(255,94,87,.12); transform: translateY(-1px); }
body.dark .social-link { color: #f0f0f0; } body.dark .social-link:hover { color: var(--accent); background-color: rgba(255,94,87,.18); }

/* SECTIONS */
.section { padding: 90px 0; } .section.alt { background: #f7f7f7; }
.section h2 { text-align: center; margin-bottom: 30px; font-size: 2rem; color: #111; }

/* GRID */
.grid { display: grid; gap: 20px; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.card { padding: 20px; text-align: center; border-radius: 15px; transition: transform .3s, box-shadow .3s; background: #fff; }
.card:hover { transform: translateY(-5px); box-shadow: 0 10px 30px rgba(0,0,0,0.1); }

/* ====== Section compétences dev (cartes) ====== */
#skills-dev h2 { margin-bottom: 16px; }
.skills-intro { max-width: 880px; margin: 12px auto 24px auto; text-align: center; color: #555; }
body.dark .skills-intro { color: #bbb; }

.skills-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 22px; }

.skill-card { display: flex; flex-direction: column; justify-content: space-between; align-items: center; background: #fff; border-radius: 14px; box-shadow: 0 10px 30px rgba(0,0,0,.08); overflow: hidden; min-height: 160px; transition: transform .2s ease, box-shadow .2s ease; }
.skill-card:hover { transform: translateY(-3px); box-shadow: 0 14px 36px rgba(0,0,0,.12); }

.skill-icon { width: 100%; height: 96px; display: flex; align-items: center; justify-content: center; padding: 10px 12px; }
.skill-icon img { display: block; max-width: 64px; max-height: 64px; width: auto; height: auto; object-fit: contain; }

.skill-label { width: 100%; padding: 12px 16px; text-align: center; font-weight: 700; letter-spacing: .02em; color: #333; border-top: none; background: #fff; }

/* DARK THEME */
body.dark { background: #111; color: #f0f0f0; }
body.dark .section.alt { background: #1a1a1a; }
body.dark .glass { background: rgba(255,255,255,0.05); box-shadow: 0 8px 32px rgba(0,0,0,0.6); }
body.dark .btn.ghost { border-color: var(--accent); color: var(--accent); }
body.dark .card { background: #151515; } body.dark .header { background: rgba(17,17,17,0.6); }

/* ===== BURGER BUTTON ===== */
.burger { display: none; flex-direction: column; justify-content: center; gap: 6px; width: 36px; height: 28px; background: transparent; border: 0; cursor: pointer; color: inherit; }
.burger span { display: block; height: 2px; width: 100%; background: currentColor; border-radius: 2px; transition: transform .3s ease, opacity .3s ease; }
.burger.toggle span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.burger.toggle span:nth-child(2) { opacity: 0; }
.burger.toggle span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

/* ===== MENU MOBILE ===== */
@media (max-width: 768px) {
  .burger { display: inline-flex; }
  .nav { position: relative; min-height: 60px; }
  .nav-links { position: fixed; top: 60px; right: 0; height: calc(100vh - 60px); width: min(80vw, 340px); background: rgba(255,255,255,0.96); backdrop-filter: blur(10px); box-shadow: -8px 0 24px rgba(0,0,0,0.1); padding: 20px; display: flex; flex-direction: column; gap: 16px; transform: translateX(100%); transition: transform .3s ease; z-index: 999; }
  body.dark .nav-links { background: rgba(17,17,17,0.96); box-shadow: -8px 0 24px rgba(0,0,0,0.4); }
  .nav-links.nav-active { transform: translateX(0); }
  .nav-links li a { padding: 8px 4px; font-size: 1.05rem; }
}

/* Évite le scroll quand le menu est ouvert */
.no-scroll { overflow: hidden; }

/* ===== Mode sombre spécifique aux compétences ===== */
body.dark .skill-card {
  background: #151515;            /* même ton que .card en dark */
  box-shadow: 0 14px 36px rgba(0,0,0,.6);
}

body.dark .skill-label {
  background: #151515;
  color: #eaeaea;                 /* texte plus clair */
  border-top: none;
}

/* Bordures/effet de séparation entre l’icône et le label si tu en veux une subtile */
.skill-card {
  border: 1px solid rgba(0,0,0,.06);
}
body.dark .skill-card {
  border: 1px solid rgba(255,255,255,.06);
}

/* Icônes — assurer le contraste en sombre si tes SVG sont foncés */
body.dark .skill-icon img {
  filter: brightness(1.15) contrast(1.05);
  /* Si tes SVG sont monochromes noirs, tu peux utiliser:
     filter: invert(1) hue-rotate(180deg);
     (à tester selon les fichiers) */
}

/* Effet hover cohérent en sombre */
body.dark .skill-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 16px 40px rgba(0,0,0,.75);
}
/* CONTACT FORM */
.contact-form input, .contact-form textarea { width: 100%; padding: 12px; margin-bottom: 15px; border: none; border-radius: 10px; background: #fff; box-shadow: inset 0 0 0 1px rgba(0,0,0,.05); }
.contact-form button { width: 100%; }

.skills-intro { color: #555; }
body.dark .skills-intro { color: #bbb; }

/* ===== Titres en mode sombre ===== */
body.dark .section h2 {
  color: #f5f5f5;           /* texte clair et contrasté */
}

/* Optionnel : harmoniser les titres principaux */
body.dark h1,
body.dark h2,
body.dark h3 {
  color: #f5f5f5;
}

/* Optionnel : renforcer l’accent visible sous les liens de navigation en sombre */
body.dark .nav-links li a::after {
  background: var(--accent); /* déjà défini, on s’assure qu’il reste bien visible */
}

/* Optionnel : léger glow pour les titres en sombre (à ajuster si besoin) */
body.dark .section h2 {
  text-shadow: 0 1px 0 rgba(0,0,0,.4);
}

/* Bouton secondaire (CV) */
.btn.secondary {
  background: #fff;
  color: #111;
  border: 2px solid var(--accent);
}
.btn.secondary:hover {
  background: var(--accent);
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(255,94,87,.35);
}

/* Variante en mode sombre */
body.dark .btn.secondary {
  background: #151515;
  color: #f0f0f0;
  border: 2px solid var(--accent);
}
body.dark .btn.secondary:hover {
  background: var(--accent);
  color: #fff;
}

/* Mise en page : une seule "colonne" centrée dans le hero */
.hero-cv-only {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0;               /* une seule action */
  margin-bottom: 20px;  /* même rythme visuel que le reste du hero */
}

/* ===== Variables (cohérence avec ton thème) ===== */
:root {
  --accent: #ff5e57;           /* déjà présent */
  --bg-card: #ffffff;
  --bg-alt: #f7f7f7;
  --text-strong: #111111;
  --text-muted: #666666;
  --border-soft: rgba(0,0,0,.08);
}
body.dark {
  --bg-card: #151515;
  --bg-alt: #1a1a1a;
  --text-strong: #f5f5f5;
  --text-muted: #aaaaaa;
  --border-soft: rgba(255,255,255,.12);
}

/* ===== Section "COMPÉTENCES" ===== */
#skills-extended h2 {
  text-align: center;
  margin-bottom: 26px;
  color: var(--text-strong);
}

/* Grille de catégories : fluide et responsive */
.skills-sections {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 20px;
}

/* Chaque groupe occupe 6 colonnes en desktop, 12 en mobile */
.skills-group {
  grid-column: span 6;
  background: var(--bg-card);
  border: 1px solid var(--border-soft);
  border-radius: 14px;
  padding: 18px 18px 14px;
  box-shadow: 0 8px 24px rgba(0,0,0,.06);
  transition: box-shadow .25s ease, transform .25s ease;
}
.skills-group:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 32px rgba(0,0,0,.10);
}

/* Titre de groupe */
.skills-group h3 {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 12px;
  color: var(--text-strong);
}

/* Liste des compétences */
.skills {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: 1fr;      /* une colonne par défaut */
  gap: 8px;
}

/* Ligne de compétence : puce accent, texte lisible */
.skills li {
  position: relative;
  padding-left: 22px;
  line-height: 1.45;
  color: var(--text-strong);
}
.skills li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 9px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 2px color-mix(in oklab, var(--accent) 35%, transparent);
}

/* Variante "muted" si besoin (non utilisée ici, utile pour notes) */
.skills li.muted { color: var(--text-muted); }

/* ===== Dark mode ===== */
/* Les variables gèrent déjà couleurs; on ajuste juste quelques effets */
body.dark .skills-group {
  box-shadow: 0 10px 28px rgba(0,0,0,.40);
}

/* ===== Responsive ===== */
@media (max-width: 1024px) {
  .skills-group { grid-column: span 6; }
}
@media (max-width: 768px) {
  .skills-group { grid-column: span 12; }
  .skills { grid-template-columns: 1fr; } /* une colonne en mobile pour la lisibilité */
}

/* ===== Optionnel : 2 colonnes dans les listes pour les groupes très longs (desktop uniquement) */
@media (min-width: 992px) {
  .skills-group:nth-child(1) .skills,
  .skills-group:nth-child(2) .skills {
    grid-template-columns: 1fr 1fr;  /* Réseaux & Systèmes en 2 colonnes */
  }
}

.projects-intro {
  text-align: center;
  margin-bottom: 20px;
  color: var(--text-muted);
}

.projects-filters {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-bottom: 30px;
  flex-wrap: wrap;
}

.filter-btn {
  padding: 8px 16px;
  border-radius: 20px;
  border: 2px solid var(--accent);
  background: transparent;
  color: var(--accent);
  font-weight: 600;
  cursor: pointer;
  transition: all .3s;
}
.filter-btn.active,
.filter-btn:hover {
  background: var(--accent);
  color: #fff;
}

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

.project-card {
  background: var(--bg-card);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(0,0,0,.08);
  transition: transform .3s ease;
}
.project-card:hover {
  transform: translateY(-4px);
}
.project-img {
  width: 100%;
  height: 160px;
  object-fit: cover;
}
.project-info {
  padding: 14px;
}
.project-info h3 {
  font-size: 1.1rem;
  margin-bottom: 6px;
}
.project-date {
  font-size: 0.85rem;
  color: var(--text-muted);
}
.project-lang {
  font-weight: 600;
  color: var(--accent);
  margin: 6px 0;
}
.project-desc {
  font-size: 0.9rem;
  color: var(--text-strong);
}
body.dark .project-card {
  background: #151515;
}

/* ===== Bouton retour en haut ===== */
.back-to-top {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 2px solid var(--accent);
  background: #fff;
  color: var(--accent);
  font-size: 20px;
  font-weight: 700;
  line-height: 1;
  display: grid;
  place-items: center;
  cursor: pointer;
  box-shadow: 0 10px 24px rgba(0,0,0,.18);
  opacity: 0;
  pointer-events: none;
  transform: translateY(8px);
  transition: opacity .25s ease, transform .25s ease, background .25s ease, color .25s ease;
  z-index: 1000;
}

.back-to-top:hover {
  background: var(--accent);
  color: #fff;
  transform: translateY(4px);
}

/* Visible */
.back-to-top.show {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

/* Mode sombre */
body.dark .back-to-top {
  background: #151515;
  color: var(--accent);
  box-shadow: 0 10px 24px rgba(0,0,0,.45);
}

/* Accessibilité : si l’utilisateur préfère réduire les animations */
@media (prefers-reduced-motion: reduce) {
  .back-to-top {
    transition: none;
  }
}

footer {
  text-align: center;
  padding: 16px 0;
  font-size: 0.95rem;
  color: var(--text-muted);
}

/* ===== Veille Technologique — layout ===== */
.feed-toolbar {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  align-items: center;
  margin-bottom: 16px;
}
@media (max-width: 720px) {
  .feed-toolbar { grid-template-columns: 1fr; }
}

.feed-filter { display: flex; gap: 10px; flex-wrap: wrap; }
.feed-filter-btn {
  padding: 8px 14px;
  border-radius: 999px;
  border: 2px solid var(--accent);
  background: transparent;
  color: var(--accent);
  font-weight: 600;
  cursor: pointer;
  transition: all .2s ease;
}
.feed-filter-btn:hover,
.feed-filter-btn.active { background: var(--accent); color: #fff; }

.feed-hint { color: var(--text-muted); font-size: .95rem; }

/* Grille des cartes */
.feed-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
}

/* Carte article */
.feed-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(0,0,0,.06);
  transition: transform .25s ease, box-shadow .25s ease;
  display: grid;
  grid-template-rows: 140px auto;
}
.feed-card:hover { transform: translateY(-3px); box-shadow: 0 12px 30px rgba(0,0,0,.1); }

.feed-thumb {
  width: 100%; height: 140px; object-fit: cover;
  background: #e9edf3; /* fallback si pas d’image */
}

.feed-body { padding: 14px; display: grid; gap: 8px; }
.feed-title { font-size: 1.02rem; font-weight: 700; line-height: 1.35; }
.feed-meta { font-size: .85rem; color: var(--text-muted); display: flex; gap: 8px; flex-wrap: wrap; }
.feed-excerpt { font-size: .92rem; color: inherit; }
.feed-actions { display: flex; justify-content: space-between; align-items: center; margin-top: 6px; }
.feed-source { font-size: .85rem; font-weight: 600; color: var(--accent); }
.feed-read {
  padding: 8px 12px; border-radius: 10px;
  border: 2px solid var(--accent); background: transparent; color: var(--accent);
  font-weight: 600; transition: all .2s ease;
}
.feed-read:hover { background: var(--accent); color: #fff; }

/* Skeleton (affiché avant le contenu) */
.skeleton { position: relative; overflow: hidden; }
.sk-img { height: 140px; background: linear-gradient(90deg, #ececec 25%, #f5f5f5 50%, #ececec 75%); background-size: 400% 100%; animation: shimmer 1.2s infinite; }
.sk-lines { padding: 14px; display: grid; gap: 8px; }
.sk-line { height: 12px; border-radius: 6px; background: linear-gradient(90deg, #ececec 25%, #f5f5f5 50%, #ececec 75%); background-size: 400% 100%; animation: shimmer 1.2s infinite; }
.sk-line.w60 { width: 60%; } .sk-line.w40 { width: 40%; } .sk-line.w80 { width: 80%; } .sk-line.w50 { width: 50%; }
@keyframes shimmer { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }

/* Erreur */
.feed-error {
  margin-top: 10px; background: var(--bg-card); border: 1px solid var(--border);
  border-radius: 12px; padding: 16px; text-align: center;
}

/* ===== Dark mode ===== */
body.dark .feed-card { background: #151515; }
body.dark .sk-img,
body.dark .sk-line { background: linear-gradient(90deg, #1d1d1d 25%, #222 50%, #1d1d1d 75%); }
body.dark .feed-hint { color: #bbb; }
body.dark .feed-read { color: var(--accent); border-color: var(--accent); }
body.dark .feed-read:hover { background: var(--accent); color: #fff; }

/* Utilitaire pour masquer des blocs (skeleton, etc.) */
.hidden { display: none !important; }

.socials {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 14px;
  margin-top: 8px;
}

.socials a img {
  width: 32px;
  height: 32px;
  transition: transform 0.2s ease;
}

.socials a:hover img {
  transform: scale(1.1);
}

/* ===== E4 — Carte & bouton ===== */
.e4-card {
  max-width: 880px;
  margin: 0 auto;
  padding: 22px 20px;
  border-radius: 16px;
}

.e4-header {
  text-align: center;
  margin-bottom: 14px;
}
.e4-title {
  font-size: 1.9rem;
  margin-bottom: 6px;
}
.e4-subtitle {
  color: var(--text-muted);
  font-size: 1.06rem;
}

/* Bouton principal */
.e4-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 20px;
  border-radius: 12px;
  background: var(--accent);
  color: #fff;
  font-weight: 700;
  text-decoration: none;
  transition: transform .18s ease, box-shadow .22s ease, background .18s ease;
  box-shadow: 0 8px 22px rgba(255,94,87,.35);
  margin: 10px auto 6px auto;
}
.e4-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 28px rgba(255,94,87,.45);
  background: color-mix(in oklab, var(--accent) 92%, #000);
}
.e4-btn:active {
  transform: translateY(-1px);
}
.e4-btn:focus-visible {
  outline: 3px solid color-mix(in oklab, var(--accent) 45%, #fff);
  outline-offset: 2px;
}

.e4-btn-icon {
  font-size: 1.2rem;
  line-height: 1;
}

/* Note sous le bouton */
.e4-note {
  text-align: center;
  margin-top: 8px;
  color: var(--text-muted);
  font-size: .95rem;
}

/* Mode sombre : héritage de tes variables */
body.dark .e4-subtitle,
body.dark .e4-note {
  color: #bbb;
}

/* Responsive */
@media (max-width: 560px) {
  .e4-title { font-size: 1.7rem; }
  .e4-subtitle { font-size: 1rem; }
}

/* ===== Utilitaire accessibilité ===== */
.sr-only {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0);
  white-space: nowrap; border: 0;
}

/* ===== SOCIALS (LinkedIn/GitHub) ===== */
.socials {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 14px;
  margin-top: 8px;
  flex-wrap: wrap;
}
.socials a {
  --size: 44px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  border-radius: 999px;
  background: #fff;
  color: #111;
  border: 1px solid var(--border-soft);
  box-shadow: 0 8px 18px rgba(0,0,0,.08);
  transition: transform .18s ease, background .18s ease, box-shadow .22s ease;
  font-weight: 600;
}
.socials a:hover {
  background: color-mix(in oklab, var(--accent) 8%, #fff);
  transform: translateY(-2px);
  box-shadow: 0 10px 24px rgba(0,0,0,.12);
}
.socials a:focus-visible {
  outline: 3px solid color-mix(in oklab, var(--accent) 45%, #fff);
  outline-offset: 2px;
}
.socials a img {
  width: 22px; height: 22px; display: block;
  filter: brightness(1) contrast(1.05);
}
body.dark .socials a {
  background: #151515;
  color: #f0f0f0;
  border-color: var(--border-soft);
  box-shadow: 0 8px 24px rgba(0,0,0,.45);
}
body.dark .socials a:hover {
  background: color-mix(in oklab, var(--accent) 12%, #151515);
}

/* ===== E4 — Carte & bouton ===== */
.e4-card {
  max-width: 880px;
  margin: 0 auto;
  padding: 22px 20px;
  border-radius: 16px;
}
.e4-header {
  text-align: center;
  margin-bottom: 8px;
}
.e4-title {
  font-size: 2rem;
  margin-bottom: 6px;
}
.e4-subtitle {
  color: var(--text-muted);
  font-size: 1.08rem;
}

/* Bouton principal */
.e4-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 20px;
  border-radius: 12px;
  background: var(--accent);
  color: #fff;
  font-weight: 700;
  text-decoration: none;
  transition: transform .18s ease, box-shadow .22s ease, background .18s ease;
  box-shadow: 0 8px 22px rgba(255,94,87,.35);
  margin: 12px auto 10px auto;
}
.e4-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 28px rgba(255,94,87,.45);
  background: color-mix(in oklab, var(--accent) 92%, #000);
}
.e4-btn:active {
  transform: translateY(-1px);
}
.e4-btn:focus-visible {
  outline: 3px solid color-mix(in oklab, var(--accent) 45%, #fff);
  outline-offset: 2px;
}
.e4-btn-icon {
  font-size: 1.2rem;
  line-height: 1;
}

/* Liste d’informations (format, session, annexe) */
.e4-meta {
  display: flex;
  justify-content: center;
  gap: 18px;
  flex-wrap: wrap;
  margin: 6px 0 0 0;
  padding: 0;
  list-style: none;
  color: var(--text-muted);
  font-size: .96rem;
}
.e4-meta li { display: inline-flex; gap: 6px; }

/* Mode sombre : héritage de tes variables */
body.dark .e4-subtitle,
body.dark .e4-meta { color: #bbb; }

/* Responsive */
@media (max-width: 560px) {
  .e4-title { font-size: 1.8rem; }
  .e4-subtitle { font-size: 1rem; }
}

/* ===== E4 Section ===== */
.e4-card {
  max-width: 880px;
  margin: 0 auto;
  padding: 24px;
  border-radius: 16px;
  text-align: center;
}
.e4-title {
  font-size: 2rem;
  margin-bottom: 6px;
}
.e4-subtitle {
  color: var(--text-muted);
  font-size: 1.08rem;
  margin-bottom: 16px;
}

/* Bouton animé */
.e4-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 24px;
  border-radius: 12px;
  background: var(--accent);
  color: #fff;
  font-weight: 700;
  text-decoration: none;
  box-shadow: 0 8px 22px rgba(255,94,87,.35);
  animation: pulse 1.8s infinite;
  transition: transform .18s ease, box-shadow .22s ease;
}
.e4-btn:hover {
  transform: scale(1.05);
  box-shadow: 0 12px 28px rgba(255,94,87,.45);
}
@keyframes pulse {
  0%, 100% { box-shadow: 0 8px 22px rgba(255,94,87,.35); }
  50% { box-shadow: 0 12px 32px rgba(255,94,87,.55); }
}
.e4-btn-icon {
  font-size: 1.3rem;
}

/* Viewer (iframe) */
.e4-viewer {
  margin-top: 20px;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(0,0,0,.08);
}
.e4-viewer iframe {
  width: 100%;
  height: 480px;
  border: none;
  background: #fff;
}
body.dark .e4-viewer iframe {
  background: #1a1a1a;
}
.e4-note {
  margin-top: 12px;
  font-size: .95rem;
  color: var(--text-muted);
}

/* Responsive */
@media (max-width: 640px) {
  .e4-viewer iframe { height: 320px; }
}

/* ===== E4 — Carte ===== */
.e4-card {
  max-width: 880px;
  margin: 0 auto;
  padding: 24px;
  border-radius: 16px;
  text-align: center;
}
.e4-title {
  font-size: 2rem;
  margin-bottom: 6px;
}
.e4-subtitle {
  color: var(--text-muted);
  font-size: 1.08rem;
  margin-bottom: 16px;
}

/* ===== Bouton animé ===== */
.e4-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 24px;
  border-radius: 12px;
  background: var(--accent);
  color: #fff;
  font-weight: 700;
  text-decoration: none;
  box-shadow: 0 8px 22px rgba(255,94,87,.35);
  animation: e4-pulse 1.8s infinite;
  transition: transform .18s ease, box-shadow .22s ease, background .18s ease;
  margin-bottom: 14px;
}
.e4-btn:hover {
  transform: scale(1.05);
  box-shadow: 0 12px 28px rgba(255,94,87,.45);
  background: color-mix(in oklab, var(--accent) 92%, #000);
}
.e4-btn:focus-visible {
  outline: 3px solid color-mix(in oklab, var(--accent) 45%, #fff);
  outline-offset: 2px;
}
@keyframes e4-pulse {
  0%, 100% { box-shadow: 0 8px 22px rgba(255,94,87,.35); }
  50%      { box-shadow: 0 12px 32px rgba(255,94,87,.55); }
}
.e4-btn-icon { font-size: 1.3rem; }

/* Variante secondaire (fallback) */
.e4-btn.secondary {
  background: #fff;
  color: var(--accent);
  border: 2px solid var(--accent);
  box-shadow: none;
  animation: none;
}
.e4-btn.secondary:hover {
  background: var(--accent);
  color: #fff;
}

/* ===== Viewer / Fallback ===== */
.e4-viewer {
  margin-top: 10px;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(0,0,0,.08);
}
.e4-object {
  width: 100%;
  height: 480px;
