/* =========================================================
   🎨 IRON TV PRO — main.css
   Version responsive optimisée 2025
   ========================================================= */

/* ---------- Variables ---------- */
:root {
  --bg: #fdfdfd;
  --text: #222;
  --muted: #666;
  --primary: #4f46e5;
  --secondary: #6d28d9;
  --accent: #eac66c;
  --light: #f5f5f5;
  --white: #fff;
  --radius: 1rem;
  --shadow: 0 8px 20px rgba(0,0,0,0.08);
}

/* ---------- Reset ---------- */
* { margin: 0; padding: 0; box-sizing: border-box; }
body {
  font-family: "Inter", system-ui, -apple-system, Segoe UI, Roboto, "Helvetica Neue", Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
}
img { max-width: 100%; height: auto; display: block; }

/* ---------- Typography ---------- */
.h1 { font-size: 2.5rem; margin-bottom: 1rem; }
.h2 { font-size: 2rem; margin-bottom: 1rem; }
.sub { color: var(--muted); margin: .5rem 0 2rem; }

/* ---------- Layout ---------- */
.container { width: 90%; max-width: 1200px; margin: 0 auto; }
.section { padding: 5rem 0; }
.section.alt { background: var(--light); }
.grid-3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px,1fr)); gap: 2rem; }

/* ---------- Header ---------- */
.header {
  position: sticky; top: 0; z-index: 1000;
  background: var(--white);
  box-shadow: var(--shadow);
}
.nav { display: flex; justify-content: space-between; align-items: center; padding: 1rem 0; }
.brand { display: flex; align-items: center; gap: .5rem; font-weight: 700; color: var(--primary); text-decoration: none; }
.logo { width: 40px; }
.menu { display: flex; gap: 1rem; }
.menu a { text-decoration: none; color: var(--text); font-weight: 500; }

/* Hamburger */
.hamburger { display: none; flex-direction: column; gap: .3rem; background: none; border: none; cursor: pointer; }
.hamburger span { width: 25px; height: 3px; background: var(--text); border-radius: 2px; }

/* ---------- Hero ---------- */
.hero {
  background: linear-gradient(135deg, #eef2ff, #f9fafb);
  text-align: center;
  padding: 6rem 1rem;
}
.badge-top {
  display: inline-block;
  background: var(--accent);
  color: var(--text);
  padding: .4rem .8rem;
  border-radius: 999px;
  font-size: .9rem;
  margin-bottom: 1rem;
}
.lead { font-size: 1.2rem; color: var(--muted); margin-bottom: 1rem; }
.clients { font-size: 1rem; margin-bottom: 2rem; color: var(--primary); font-weight: 600; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  padding: .8rem 1.5rem;
  border-radius: var(--radius);
  font-weight: 600;
  text-decoration: none;
  transition: 0.3s;
}
.btn--primary {
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: var(--white);
}
.btn--primary:hover { opacity: .9; }
.btn--ghost {
  border: 2px solid var(--primary);
  color: var(--primary);
}
.btn--ghost:hover { background: var(--primary); color: var(--white); }

/* ---------- Cards ---------- */
.card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 2rem;
  text-align: center;
  box-shadow: var(--shadow);
}
.card .icon { font-size: 2rem; margin-bottom: 1rem; }

/* ---------- Steps ---------- */
.steps { display: flex; gap: 2rem; justify-content: center; flex-wrap: wrap; margin: 2rem 0; }
.step { flex: 1; min-width: 200px; text-align: center; }
.step__num {
  display: inline-block;
  width: 40px; height: 40px; line-height: 40px;
  background: var(--primary);
  color: var(--white);
  border-radius: 50%;
  margin-bottom: .5rem;
  font-weight: 700;
}

/* ---------- Tarifs ---------- */
.tabs { display: flex; justify-content: center; margin-bottom: 2rem; gap: 1rem; flex-wrap: wrap; }
.tab-btn {
  background: var(--light);
  border: none;
  padding: .6rem 1.2rem;
  border-radius: var(--radius);
  cursor: pointer;
  font-weight: 600;
}
.tab-btn.active { background: var(--primary); color: var(--white); }
.tab-content { display: none; transition: opacity 0.4s ease; }
.tab-content.active { display: block; opacity: 1; }

.pricing { display: grid; gap: 2rem; grid-template-columns: repeat(auto-fit, minmax(250px,1fr)); }
.p-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 2rem;
  text-align: center;
  box-shadow: var(--shadow);
  position: relative;
  transition: transform .3s ease, box-shadow .3s ease;
}
.p-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}
.p-name { font-weight: 600; color: var(--muted); }
.p-price { font-size: 1.8rem; font-weight: 700; margin: 1rem 0; }
.p-feats { list-style: disc; text-align: left; margin: 1rem 0 1.2rem 1.3rem; color: var(--muted); }
.p-feats li { margin: .35rem 0; }
.p-card--recommended { border: 2px solid var(--accent); }
.badge {
  position: absolute; top: 10px; right: 10px;
  background: var(--accent);
  padding: .3rem .6rem;
  border-radius: .5rem;
  font-size: .8rem; font-weight: 600;
}

/* ---------- Stats ---------- */
.stat { text-align: center; }
.stat h3 { font-size: 2rem; margin-bottom: .5rem; }

/* ---------- Comparatif ---------- */
.comparatif { width: 100%; border-collapse: collapse; margin-top: 2rem; }
.comparatif th, .comparatif td { border: 1px solid #ddd; padding: 1rem; text-align: center; }
.comparatif th { background: var(--primary); color: var(--white); }

/* ---------- Avis ---------- */
.testis { display: flex; gap: 2rem; flex-wrap: wrap; justify-content: center; }
.testi {
  background: var(--white);
  border-radius: var(--radius);
  padding: 1.5rem;
  box-shadow: var(--shadow);
  flex: 1; min-width: 250px;
}

/* ---------- Garanties ---------- */
#garanties .card h3 { margin-bottom: .5rem; color: var(--primary); }

/* ---------- Revendeur teaser ---------- */
#revendeur-teaser { text-align: center; }
#revendeur-teaser p { margin: 1rem 0; color: var(--muted); }

/* ---------- FAQ ---------- */
.faq { margin-bottom: 1rem; border: 1px solid #ddd; border-radius: var(--radius); padding: 1rem; background: var(--white); }
.faq summary { font-weight: 600; cursor: pointer; }

/* ---------- Contact ---------- */
.contact-list { list-style: none; }
.contact-list li { margin-bottom: .8rem; }

/* ---------- Footer ---------- */
.footer { background: var(--light); padding: 2rem 0; text-align: center; }
.footer nav { margin-top: 1rem; display: flex; gap: 1rem; justify-content: center; }

/* ---------- WhatsApp Floating ---------- */
.whatsapp-float {
  position: fixed; bottom: 20px; right: 20px;
  background: #25d366; color: var(--white);
  padding: 1rem; border-radius: 50%;
  font-size: 1.5rem; box-shadow: var(--shadow);
  z-index: 1000; text-decoration: none;
}

/* ---------- Sticky Bar ---------- */
.sticky-bar {
  display: none;
  position: fixed; bottom: 0; left: 0; width: 100%;
  background: var(--white); box-shadow: var(--shadow);
  padding: .8rem; display: flex; justify-content: space-between; align-items: center;
  z-index: 999;
}
.sticky-bar a { font-weight: 600; text-decoration: none; }

/* ---------- Shimmer ---------- */
.shimmer {
  position: relative;
  display: inline-block;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  overflow: hidden;
}
.shimmer::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, transparent 0%, rgba(255,255,255,0.4) 50%, transparent 100%);
  transform: translateX(-100%);
  animation: shimmer-move 3s infinite;
  pointer-events: none;
}
@keyframes shimmer-move {
  0% { transform: translateX(-100%); }
  50% { transform: translateX(100%); }
  100% { transform: translateX(100%); }
}

/* ---------- Menu Responsive ---------- */
@media (max-width: 768px) {
  .menu { display: none; flex-direction: column; gap: 1rem; background: var(--white); padding: 1rem; position: absolute; top: 60px; right: 10px; box-shadow: var(--shadow); }
  .menu.show { display: flex; }
  .hamburger { display: flex; }
}

/* ---------- Popup Offre Spéciale ---------- */
.promo-popup {
  position: fixed;
  bottom: 25px;
  right: 25px;
  background: rgba(255,255,255,0.97);
  border: 2px solid #7c3aed;
  border-radius: 18px;
  box-shadow: 0 8px 30px rgba(0,0,0,0.25);
  padding: 1.3rem 1.2rem 1.5rem;
  width: 300px;
  max-width: 90%;
  z-index: 3000;
  font-family: 'Outfit', sans-serif;
  display: none;
  animation: popupBounce 0.9s ease forwards;
  transform-origin: bottom right;
  overflow: visible;
}
.promo-popup::after {
  content: "";
  position: absolute;
  inset: -25%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(124,58,237,0.25) 0%, transparent 70%);
  z-index: -1;
  animation: haloPulse 6s ease-in-out infinite;
}
@keyframes haloPulse {
  0%,100% { transform: scale(0.9); opacity: 0.6; }
  50% { transform: scale(1.1); opacity: 1; }
}
.promo-content { text-align: center; color: #111; }
.promo-popup h3 { font-size: 1.25rem; color: #7c3aed; margin-bottom: .5rem; }
.promo-popup p { font-size: 1rem; line-height: 1.5; margin: .4rem 0 1rem; }
.promo-popup .price { color: #f59e0b; font-weight: 700; }
.promo-popup .btn.violet {
  display: inline-block;
  background: linear-gradient(90deg,#7c3aed,#9333ea);
  color: #fff;
  font-weight: 700;
  padding: 0.7rem 1.4rem;
  border-radius: 10px;
  text-decoration: none;
  transition: transform .3s ease, box-shadow .3s ease;
}
.promo-popup .btn.violet:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(124,58,237,.4);
}
.close-btn {
  position: absolute;
  top: 8px;
  right: 10px;
  background: none;
  border: none;
  font-size: 1.3rem;
  cursor: pointer;
  color: #555;
  transition: color .2s;
  min-width: 44px;
  min-height: 44px;
}
.close-btn:hover { color: #000; }
@keyframes popupBounce {
  0%   { opacity: 0; transform: scale(0.6) translateY(40px); }
  60%  { opacity: 1; transform: scale(1.05) translateY(-5px); }
  80%  { transform: scale(0.95) translateY(2px); }
  100% { transform: scale(1) translateY(0); }
}

/* =========================================================
   📱 Responsive Mobile Total + Scroll Snap Tarifs
   ========================================================= */
@media (max-width: 480px) {

  html, body { font-size: 15px; overflow-x: hidden; }

  .hero { padding: 4rem 1rem; }
  .h1 { font-size: 1.8rem; line-height: 1.3; }
  .lead { font-size: 1rem; }
  .clients { font-size: 0.95rem; }

  .cta { display: flex; flex-direction: column; gap: 1rem; }
  .btn { width: 100%; text-align: center; }

  .grid-3 { grid-template-columns: 1fr; gap: 1.2rem; }
  .card { padding: 1.3rem; }

  .steps { flex-direction: column; gap: 1.5rem; }

  .comparatif { font-size: 0.85rem; }
  .comparatif th, .comparatif td { padding: 0.6rem; }

  .testis { flex-direction: column; gap: 1rem; }
  .contact-list li { font-size: 0.95rem; }

  .sticky-bar {
    flex-direction: column;
    gap: 0.6rem;
    padding: 1rem;
    text-align: center;
  }
  .sticky-bar a { width: 100%; }

  .whatsapp-float {
    bottom: 15px; right: 15px;
    padding: 0.8rem; font-size: 1.3rem;
  }

  .promo-popup {
    bottom: 10px; right: 10px;
    width: 240px; padding: 1rem;
  }
  .promo-popup h3 { font-size: 1.1rem; }
  .promo-popup p { font-size: 0.9rem; }

  .footer nav { flex-direction: column; gap: 0.4rem; }

  /* Tarifs plein écran + Scroll Snap */
  .tab-content.active {
    display: flex;
    flex-direction: column;
    align-items: center;
    overflow-y: auto;
    scroll-snap-type: y mandatory;
    max-height: 85vh;
    padding-bottom: 2rem;
    -webkit-overflow-scrolling: touch;
  }

  .pricing {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.3rem;
  }

  .p-card {
    width: 95%;
    max-width: 380px;
    border-radius: 1.2rem;
    box-shadow: 0 6px 20px rgba(0,0,0,0.08);
    padding: 1.8rem 1.5rem;
    margin: 0 auto 1.5rem;
    scroll-snap-align: center;
    scroll-snap-stop: always;
  }

  .p-card:active,
  .p-card:hover {
    transform: scale(1.02);
    box-shadow: 0 8px 25px rgba(0,0,0,0.12);
  }

  .p-price { font-size: 1.6rem; margin: 1rem 0; }
  .p-feats { margin-left: 1.2rem; font-size: 0.95rem; }

  .p-card--recommended { border: 2px solid var(--primary); }

  #tarifs .container { padding-left: 0; padding-right: 0; overflow-x: hidden; }
}

/* Moyens écrans (481–768px) */
@media (min-width: 481px) and (max-width: 768px) {
  .hero { padding: 5rem 1.5rem; }
  .h1 { font-size: 2.1rem; }
  .grid-3 { grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }
  .pricing { grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); }
  .card { padding: 1.5rem; }
  .footer nav { flex-wrap: wrap; gap: 0.8rem; }
  .promo-popup { width: 260px; }
}
