@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;600&display=swap');

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

body {
  background: linear-gradient(160deg, #deeef8 0%, #c2dff0 40%, #a8cfe8 100%);
  min-height: 100vh;
  font-family: 'Outfit', sans-serif;
  color: #1a2e3d;
}

/* ===== HEADER ===== */
header {
  position: sticky;
  top: 0;
  background: rgba(200,228,245,0.88);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(40,100,160,0.15);
  padding: 16px 40px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  z-index: 100;
}

header h1 {
  font-weight: 300;
  font-size: 18px;
  letter-spacing: 4px;
  text-transform: uppercase;
  color: #1a2e3d;
}

header h1 span {
  font-size: 0.65em;
  opacity: 0.6;
}

/* ===== NAVIGATION ===== */
.nav-links {
  display: flex;
  gap: 12px;
}

.btn-nav,
.btn-retour {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: rgba(20,80,140,0.85);
  text-decoration: none;
  font-size: 13px;
  letter-spacing: 1px;
  border: 1px solid rgba(20,80,140,0.25);
  padding: 7px 18px;
  border-radius: 40px;
  transition: all 0.3s;
  background: rgba(20,80,140,0.07);
}

.btn-nav:hover,
.btn-retour:hover {
  background: rgba(20,80,140,0.14);
  border-color: rgba(20,80,140,0.45);
}

/* ===== HERO ===== */
.hero {
  max-width: 860px;
  margin: 72px auto 56px;
  padding: 0 32px;
  text-align: center;
}

.hero-tag {
  display: inline-block;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: rgba(20,80,140,0.7);
  border: 1px solid rgba(20,80,140,0.2);
  padding: 5px 16px;
  border-radius: 40px;
  margin-bottom: 32px;
}

.hero h2 {
  font-size: clamp(20px, 3.5vw, 32px);
  font-weight: 300;
  line-height: 1.5;
  letter-spacing: 1px;
  color: #0f1e2e;
  margin-bottom: 20px;
}

.hero h2 em {
  font-style: normal;
  color: #1060a8;
}

.hero-sub {
  font-size: 16px;
  font-weight: 300;
  line-height: 1.8;
  color: rgba(26,46,61,0.65);
  max-width: 640px;
  margin: 0 auto;
}

/* ===== SEPARATEUR ===== */
.sep {
  width: 60px;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(20,80,140,0.3), transparent);
  margin: 0 auto 56px;
}

/* ===== SECTION TITLE ===== */
.section-title {
  text-align: center;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: rgba(20,80,140,0.5);
  margin-bottom: 48px;
}

/* ===== CARDS ===== */
.cards {
  max-width: 1100px;
  margin: 0 auto 80px;
  padding: 0 32px;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}

.card {
  background: rgba(255,255,255,0.5);
  border: 1px solid rgba(20,80,140,0.12);
  border-radius: 12px;
  padding: 28px 28px 24px;
  transition: border-color 0.3s, background 0.3s;
}

.card:hover {
  border-color: rgba(20,80,140,0.3);
  background: rgba(255,255,255,0.7);
}

.card-title {
  font-size: 16px;
  font-weight: 600;
  color: #0f1e2e;
  margin-bottom: 16px;
  letter-spacing: 0.5px;
}

.card-text {
  font-size: 15px;
  font-weight: 300;
  line-height: 1.75;
  color: rgba(26,46,61,0.75);
}

.card-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.card-list li {
  font-size: 15px;
  font-weight: 300;
  line-height: 1.6;
  color: rgba(26,46,61,0.75);
  padding-left: 16px;
  position: relative;
}

.card-list li::before {
  content: '–';
  position: absolute;
  left: 0;
  color: rgba(20,80,140,0.4);
}

/* Carte "a venir" */
.card.coming {
  border-style: dashed;
  border-color: rgba(20,80,140,0.2);
  background: rgba(255,255,255,0.25);
}

.card.coming .card-title {
  color: rgba(15,30,46,0.6);
}

.card.coming .card-list li {
  color: rgba(26,46,61,0.5);
}

.badge-coming {
  display: inline-block;
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: rgba(20,80,140,0.6);
  border: 1px solid rgba(20,80,140,0.2);
  padding: 2px 8px;
  border-radius: 20px;
  margin-left: 10px;
  vertical-align: middle;
}

/* ===== CTA ===== */
.cta {
  text-align: center;
  padding: 0 32px 80px;
}

.btn-cta {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: rgba(20,80,140,0.9);
  text-decoration: none;
  font-size: 15px;
  letter-spacing: 1.5px;
  border: 1px solid rgba(20,80,140,0.35);
  padding: 14px 36px;
  border-radius: 40px;
  transition: all 0.3s;
  background: rgba(20,80,140,0.08);
  backdrop-filter: blur(10px);
}

.btn-cta:hover {
  background: rgba(20,80,140,0.16);
  border-color: rgba(20,80,140,0.55);
}

/* ===== PARTICULES ===== */
canvas#particles,
canvas#bg-particles {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

.page-content {
  position: relative;
  z-index: 1;
}

/* ===== LIGHTBOX IMAGE ===== */
#lightbox {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(10,20,35,0.88);
  backdrop-filter: blur(8px);
  z-index: 500;
  align-items: center;
  justify-content: center;
  cursor: zoom-out;
}

#lightbox.open {
  display: flex;
}

#lightbox img {
  max-width: 90vw;
  max-height: 90vh;
  border-radius: 8px;
  box-shadow: 0 8px 48px rgba(0,0,0,0.6);
  cursor: default;
}

#lightbox-close {
  position: absolute;
  top: 20px;
  right: 28px;
  color: rgba(255,255,255,0.7);
  font-size: 28px;
  font-weight: 300;
  cursor: pointer;
  line-height: 1;
  transition: color 0.2s;
  background: none;
  border: none;
  font-family: 'Outfit', sans-serif;
}

#lightbox-close:hover {
  color: #fff;
}

/* ===== VIGNETTE ILLUSTREE ===== */
.card-thumb {
  display: block;
  margin-top: 14px;
  border-radius: 6px;
  overflow: hidden;
  cursor: zoom-in;
  border: 1px solid rgba(20,80,140,0.15);
  transition: border-color 0.3s, box-shadow 0.3s;
}

.card-thumb:hover {
  border-color: rgba(20,80,140,0.4);
  box-shadow: 0 4px 16px rgba(20,80,140,0.15);
}

.card-thumb img {
  width: 100%;
  height: auto;
  display: block;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 600px) {
  header { padding: 14px 20px; }
  .hero { margin: 48px auto 40px; }
  .cards { grid-template-columns: 1fr; }
  .nav-links { gap: 8px; }
  .btn-nav { font-size: 11px; padding: 6px 13px; }
}

/* ===== VIDEOS (videos_cartomaestro.html) ===== */
.page-intro {
  text-align: center;
  margin-bottom: 56px;
}

.page-intro h2 {
  font-size: 28px;
  font-weight: 300;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: #0f1e2e;
  margin-bottom: 10px;
}

.page-intro p {
  font-size: 14px;
  color: rgba(26,46,61,0.5);
  letter-spacing: 1px;
}

.section { margin-bottom: 60px; }

.section-title-row {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 28px;
}

.section-title-row h3 {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: #0f1e2e;
}

.section-title-row .badge {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  padding: 3px 12px;
  border-radius: 20px;
  border: 1px solid;
}

.badge-arbopix { color: #3a7a20; border-color: rgba(58,122,32,0.3); background: rgba(58,122,32,0.08); }
.badge-carto   { color: #1060a8; border-color: rgba(16,96,168,0.3); background: rgba(16,96,168,0.08); }
.badge-equip   { color: #8a5a10; border-color: rgba(138,90,16,0.3); background: rgba(138,90,16,0.08); }
.badge-backoffice { color: #6a3a90; border-color: rgba(106,58,144,0.3); background: rgba(106,58,144,0.08); }

.section-divider {
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(20,80,140,0.15) 30%, rgba(20,80,140,0.15) 70%, transparent);
  margin-bottom: 28px;
}

.subsection { margin-bottom: 32px; }

.subsection-label {
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: rgba(26,46,61,0.45);
  margin-bottom: 16px;
  padding-left: 2px;
}

.videos-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 20px;
}

.video-card {
  background: rgba(255,255,255,0.5);
  border: 1px solid rgba(20,80,140,0.12);
  border-radius: 12px;
  overflow: hidden;
  transition: all 0.3s;
  cursor: pointer;
}

.video-card:hover {
  background: rgba(255,255,255,0.7);
  border-color: rgba(20,80,140,0.3);
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(20,80,140,0.12);
}

.video-thumb {
  position: relative;
  width: 100%;
  padding-top: 56.25%;
  background: #c2dff0;
  overflow: hidden;
}

.video-thumb iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: none;
  display: block;
}

.video-thumb .play-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(20,80,140,0.15);
  transition: background 0.3s;
  cursor: pointer;
}

.video-thumb .play-overlay:hover { background: rgba(20,80,140,0.05); }

.play-btn {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: rgba(255,255,255,0.6);
  backdrop-filter: blur(8px);
  border: 2px solid rgba(20,80,140,0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s;
}

.play-overlay:hover .play-btn {
  background: rgba(255,255,255,0.85);
  border-color: rgba(20,80,140,0.6);
  transform: scale(1.1);
}

.play-btn svg { width: 20px; height: 20px; fill: #1060a8; margin-left: 3px; }

.video-info { padding: 14px 16px 16px; }

.video-title { font-size: 13px; font-weight: 400; color: #0f1e2e; line-height: 1.4; }

.video-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-top: 8px;
  font-size: 11px;
  color: rgba(20,80,140,0.6);
  text-decoration: none;
  letter-spacing: 0.5px;
  transition: color 0.2s;
}

.video-link:hover { color: rgba(20,80,140,1); }
.video-link svg { width: 11px; height: 11px; stroke: currentColor; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* Lightbox video */
.lightbox-inner {
  position: relative;
  width: 90vw;
  max-width: 900px;
}

.lightbox-close {
  position: absolute;
  top: -40px;
  right: 0;
  background: none;
  border: none;
  color: rgba(255,255,255,0.8);
  font-size: 28px;
  cursor: pointer;
  line-height: 1;
  transition: color 0.2s;
}

.lightbox-close:hover { color: #fff; }

.lightbox-video {
  position: relative;
  padding-top: 56.25%;
  border-radius: 10px;
  overflow: hidden;
  background: #000;
}

.lightbox-video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: none; }

.lightbox-title {
  margin-top: 12px;
  text-align: center;
  font-size: 13px;
  font-weight: 300;
  color: rgba(255,255,255,0.7);
  letter-spacing: 1px;
}

@media (max-width: 600px) {
  .page-content { padding: 32px 16px 60px; }
}

/* ===== PROJET (surcharges hero) ===== */
.hero-projet h2 {
  font-size: clamp(22px, 4vw, 36px);
  margin-bottom: 32px;
}

.hero-projet .hero-sub {
  font-size: 20px;
}

.hero-projet {
  margin-bottom: 80px;
}

/* ===== PROJET (blocs specifiques) ===== */
.cadre-terrain {
  max-width: 860px;
  margin: 0 auto 56px;
  padding: 32px 40px;
  background: rgba(255,255,255,0.45);
  border-left: 3px solid rgba(20,80,140,0.35);
  border-radius: 0 10px 10px 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.cadre-accroche {
  font-size: 18px;
  font-weight: 600;
  color: #0f1e2e;
  letter-spacing: 0.3px;
}

.cadre-terrain p:not(.cadre-accroche) {
  font-size: 16px;
  font-weight: 300;
  line-height: 1.85;
  color: rgba(26,46,61,0.75);
}

.card-versus {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: rgba(20,80,140,0.45);
  margin-bottom: 10px;
}

.promesse {
  max-width: 860px;
  margin: 0 auto 80px;
  padding: 0 32px;
}

.promesse-inner {
  background: rgba(255,255,255,0.45);
  border: 1px solid rgba(20,80,140,0.2);
  border-radius: 12px;
  padding: 40px 48px;
  text-align: center;
}

.promesse-inner p {
  font-size: clamp(15px, 2.5vw, 20px);
  font-weight: 300;
  line-height: 1.7;
  color: #0f1e2e;
  letter-spacing: 0.3px;
}

.promesse-inner p em {
  font-style: normal;
  color: #1060a8;
}

/* ===== BORDEREAUX (blocs specifiques) ===== */
.avantages {
  max-width: 860px;
  margin: 0 auto 56px;
  padding: 0 32px;
}

.avantages-inner {
  background: rgba(255,255,255,0.45);
  border: 1px solid rgba(20,80,140,0.15);
  border-radius: 12px;
  padding: 36px 44px;
}

.av-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.av-list li {
  font-size: 15px;
  font-weight: 300;
  line-height: 1.7;
  color: rgba(26,46,61,0.8);
  padding-left: 20px;
  position: relative;
}

.av-list li::before {
  content: '–';
  position: absolute;
  left: 0;
  color: rgba(20,80,140,0.4);
}

.pour-qui {
  max-width: 860px;
  margin: 0 auto 80px;
  padding: 0 32px;
}

.pour-qui-inner {
  background: rgba(255,255,255,0.35);
  border: 1px solid rgba(20,80,140,0.12);
  border-radius: 12px;
  padding: 32px 44px;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px 32px;
}

.pour-qui-item {
  font-size: 15px;
  font-weight: 300;
  line-height: 1.7;
  color: rgba(26,46,61,0.7);
  padding-left: 16px;
  position: relative;
}

.pour-qui-item::before {
  content: '–';
  position: absolute;
  left: 0;
  color: rgba(20,80,140,0.35);
}

@media (max-width: 600px) {
  .pour-qui-inner { grid-template-columns: 1fr; }
  .avantages-inner { padding: 24px 20px; }
  .pour-qui-inner { padding: 24px 20px; }
  .promesse-inner { padding: 28px 24px; }
}
