/* ============================================================
   JSNK3D — Feuille de style principale
   Palette : violet néon sur fond sombre (identité du logo)
   ============================================================ */

:root {
  --bg: #0d0a14;
  --bg-soft: #16101f;
  --bg-card: #1d1529;
  --border: #2e2340;
  --violet: #8b5cf6;
  --violet-vif: #a78bfa;
  --violet-deep: #6d28d9;
  --rose: #e879f9;
  --text: #ece7f5;
  --text-soft: #b3a9c9;
  --radius: 16px;
  --shadow: 0 10px 40px rgba(109, 40, 217, .25);
  --grad: linear-gradient(120deg, #8b5cf6, #e879f9);
}

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

html { scroll-behavior: smooth; }

/* Garde-fou mobile : aucun débordement horizontal (clip ne casse pas position:sticky) */
html, body { overflow-x: clip; }

body {
  font-family: "Inter", system-ui, -apple-system, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }

h1, h2, h3, h4 {
  font-family: "Space Grotesk", "Inter", sans-serif;
  line-height: 1.15;
  letter-spacing: -.01em;
}

a { color: var(--violet-vif); text-decoration: none; }

.container { width: min(1140px, 92%); margin-inline: auto; }

section { padding: 72px 0; }

.section-title {
  font-size: clamp(1.6rem, 3.5vw, 2.4rem);
  margin-bottom: 12px;
}
.section-title .accent {
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.section-sub {
  color: var(--text-soft);
  max-width: 640px;
  margin-bottom: 40px;
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(13, 10, 20, .85);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 14px 0;
}
.logo img { height: 48px; width: auto; }

.main-nav ul {
  display: flex;
  gap: 6px;
  list-style: none;
  align-items: center;
}
.main-nav a {
  display: block;
  padding: 9px 14px;
  border-radius: 10px;
  color: var(--text-soft);
  font-weight: 500;
  font-size: .95rem;
  transition: color .2s, background .2s;
}
.main-nav a:hover { color: var(--text); background: var(--bg-card); }
.main-nav a.active { color: var(--text); background: var(--bg-card); }
.main-nav a.nav-cta {
  background: var(--grad);
  color: #fff;
  font-weight: 600;
  box-shadow: var(--shadow);
}

.burger {
  display: none;
  background: none;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 10px 12px;
  min-width: 48px;
  min-height: 48px;
  cursor: pointer;
}
.burger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text);
  margin: 5px auto;
  transition: transform .25s, opacity .25s;
}
.burger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.burger.open span:nth-child(2) { opacity: 0; }
.burger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  padding: 110px 0 100px;
  overflow: hidden;
}
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: url("../img/hero.jpg") center/cover no-repeat;
  opacity: .22;
}
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 30% 20%, rgba(139, 92, 246, .28), transparent 55%),
              linear-gradient(180deg, rgba(13,10,20,.2), var(--bg) 92%);
}
.hero .container { position: relative; z-index: 2; }
.hero-badge {
  display: inline-block;
  padding: 6px 16px;
  border: 1px solid var(--violet);
  border-radius: 999px;
  color: var(--violet-vif);
  font-size: .85rem;
  font-weight: 600;
  margin-bottom: 22px;
}
.hero h1 {
  font-size: clamp(2.1rem, 5.5vw, 3.6rem);
  max-width: 780px;
  margin-bottom: 20px;
}
.hero h1 .accent {
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hero p {
  max-width: 620px;
  color: var(--text-soft);
  font-size: 1.08rem;
  margin-bottom: 34px;
}
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; }

/* ---------- Boutons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 13px 26px;
  border-radius: 12px;
  font-weight: 600;
  font-size: .98rem;
  transition: transform .2s, box-shadow .2s, background .2s;
  cursor: pointer;
  border: none;
}
.btn-primary { background: var(--grad); color: #fff; box-shadow: var(--shadow); }
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 14px 45px rgba(139, 92, 246, .4); }
.btn-ghost {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border);
}
.btn-ghost:hover { border-color: var(--violet); color: var(--violet-vif); }

/* ---------- Cartes services ---------- */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 30px;
  transition: transform .25s, border-color .25s;
}
.card:hover { transform: translateY(-5px); border-color: var(--violet); }
.card .icon {
  width: 54px;
  height: 54px;
  border-radius: 14px;
  background: rgba(139, 92, 246, .15);
  display: grid;
  place-items: center;
  font-size: 1.6rem;
  margin-bottom: 18px;
}
.card h3 { font-size: 1.15rem; margin-bottom: 10px; }
.card p { color: var(--text-soft); font-size: .95rem; margin-bottom: 16px; }
.card .card-link { font-weight: 600; font-size: .92rem; }

/* ---------- Étapes ---------- */
.steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 22px;
  counter-reset: step;
}
.step {
  position: relative;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 24px 24px;
}
.step::before {
  counter-increment: step;
  content: counter(step, decimal-leading-zero);
  font-family: "Space Grotesk", sans-serif;
  font-size: 2rem;
  font-weight: 700;
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  display: block;
  margin-bottom: 10px;
}
.step h3 { font-size: 1.05rem; margin-bottom: 8px; }
.step p { color: var(--text-soft); font-size: .93rem; }

/* ---------- Galerie ---------- */
.gallery {
  columns: 4 240px;
  column-gap: 14px;
}
.gallery a {
  display: block;
  margin-bottom: 14px;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--border);
  break-inside: avoid;
}
.gallery img {
  width: 100%;
  transition: transform .3s;
}
.gallery a:hover img { transform: scale(1.04); }

/* Lightbox */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(8, 5, 14, .93);
  display: grid;
  place-items: center;
  z-index: 300;
  padding: 4vh 4vw;
}
.lightbox img {
  max-height: 88vh;
  max-width: 100%;
  border-radius: 12px;
}
.lightbox-close {
  position: absolute;
  top: 20px;
  right: 26px;
  font-size: 2.2rem;
  color: #fff;
  background: none;
  border: none;
  cursor: pointer;
}

/* ---------- Instagram ---------- */
.insta-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 18px;
  margin-bottom: 34px;
}
.insta-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
}
.insta-item {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}
.insta-item iframe {
  width: 100%;
  height: 480px;
  border: 0;
  display: block;
  background: #fff;
}

/* ---------- Produits ---------- */
.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(270px, 1fr));
  gap: 26px;
}
.product {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform .25s, border-color .25s;
}
.product:hover { transform: translateY(-5px); border-color: var(--violet); }
.product .product-img {
  aspect-ratio: 1 / 1;
  overflow: hidden;
  position: relative;
}
.product .product-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.product .badge-new {
  position: absolute;
  top: 12px;
  left: 12px;
  background: var(--grad);
  color: #fff;
  font-size: .75rem;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 999px;
}
.product-body {
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
}
.product-body h3 { font-size: 1.02rem; }
.product-body .desc { color: var(--text-soft); font-size: .88rem; flex: 1; }
.price { font-family: "Space Grotesk", sans-serif; font-weight: 700; font-size: 1.2rem; }
.price .old {
  color: var(--text-soft);
  text-decoration: line-through;
  font-size: .95rem;
  font-weight: 500;
  margin-right: 8px;
}

/* ---------- Formulaires ---------- */
.form-wrap {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 36px;
  max-width: 760px;
}
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}
.form-grid .full { grid-column: 1 / -1; }
label {
  display: block;
  font-size: .88rem;
  font-weight: 600;
  margin-bottom: 7px;
  color: var(--text-soft);
}
input, textarea, select {
  width: 100%;
  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 12px 14px;
  color: var(--text);
  font: inherit;
  transition: border-color .2s;
}
input:focus, textarea:focus, select:focus { outline: none; border-color: var(--violet); }
textarea { min-height: 130px; resize: vertical; }
input[type="file"] { padding: 10px; }
.form-note { font-size: .82rem; color: var(--text-soft); margin-top: 14px; }

/* ---------- Sections diverses ---------- */
.split {
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  gap: 48px;
  align-items: center;
}
.split img { border-radius: var(--radius); border: 1px solid var(--border); }

.checklist { list-style: none; display: grid; gap: 14px; margin: 22px 0; }
.checklist li { padding-left: 32px; position: relative; color: var(--text-soft); }
.checklist li::before {
  content: "✓";
  position: absolute;
  left: 0;
  top: 0;
  width: 22px;
  height: 22px;
  border-radius: 7px;
  background: rgba(139, 92, 246, .18);
  color: var(--violet-vif);
  font-weight: 700;
  display: grid;
  place-items: center;
  font-size: .8rem;
}
.checklist strong { color: var(--text); }

.cta-band {
  background: linear-gradient(120deg, rgba(139,92,246,.16), rgba(232,121,249,.1));
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 48px;
  text-align: center;
}
.cta-band h2 { font-size: clamp(1.4rem, 3vw, 2rem); margin-bottom: 12px; }
.cta-band p { color: var(--text-soft); margin-bottom: 26px; max-width: 560px; margin-inline: auto; }

/* Page hero (pages intérieures) */
.page-hero { padding: 70px 0 40px; }
.page-hero h1 { font-size: clamp(1.8rem, 4vw, 2.8rem); margin-bottom: 14px; }
.page-hero p { color: var(--text-soft); max-width: 680px; font-size: 1.05rem; }

/* Ressources STL */
.resource-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 18px;
}
.resource {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 20px;
  transition: border-color .2s, transform .2s;
}
.resource:hover { border-color: var(--violet); transform: translateY(-3px); }
.resource h3 { font-size: 1rem; margin-bottom: 6px; }
.resource p { color: var(--text-soft); font-size: .87rem; }
.resource .tag {
  display: inline-block;
  font-size: .72rem;
  font-weight: 700;
  padding: 2px 10px;
  border-radius: 999px;
  margin-bottom: 10px;
}
.tag-free { background: rgba(52, 211, 153, .15); color: #34d399; }
.tag-paid { background: rgba(251, 191, 36, .15); color: #fbbf24; }
.tag-mixte { background: rgba(139, 92, 246, .18); color: var(--violet-vif); }

/* Horaires */
.hours-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 30px;
}
.hours-card table { width: 100%; border-collapse: collapse; }
.hours-card td { padding: 10px 0; border-bottom: 1px solid var(--border); color: var(--text-soft); }
.hours-card td:last-child { text-align: right; color: var(--text); font-weight: 600; }

/* ---------- Footer ---------- */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 54px 0 30px;
  background: var(--bg-soft);
}
.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 36px;
  margin-bottom: 40px;
}
.site-footer h4 { font-size: .95rem; margin-bottom: 16px; }
.site-footer ul { list-style: none; display: grid; gap: 9px; }
.site-footer ul a { color: var(--text-soft); font-size: .92rem; }
.site-footer ul a:hover { color: var(--violet-vif); }
.footer-social { display: flex; gap: 12px; }
.footer-social a {
  width: 40px;
  height: 40px;
  border-radius: 11px;
  border: 1px solid var(--border);
  display: grid;
  place-items: center;
  color: var(--text-soft);
  transition: border-color .2s, background .2s, color .2s;
}
.footer-social a svg { width: 17px; height: 17px; fill: currentColor; display: block; }
.footer-social a:hover { border-color: var(--violet); background: var(--bg-card); color: var(--violet-vif); }
.footer-bottom {
  border-top: 1px solid var(--border);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  color: var(--text-soft);
  font-size: .84rem;
}

/* Reveal animation */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .6s, transform .6s; }
.reveal.visible { opacity: 1; transform: none; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .split { grid-template-columns: 1fr; }
  .main-nav {
    position: fixed;
    inset: 77px 0 auto 0;
    background: var(--bg-soft);
    border-bottom: 1px solid var(--border);
    transform: translateY(-130%);
    transition: transform .3s;
    z-index: 90;
    max-height: calc(100vh - 77px);
    max-height: calc(100dvh - 77px);
    overflow-y: auto;
  }
  .main-nav.open { transform: none; }
  .main-nav ul { flex-direction: column; align-items: stretch; padding: 14px 16px 18px; gap: 4px; }
  /* zone tactile confortable (≥ 44 px) */
  .main-nav a { padding: 13px 16px; font-size: 1rem; }
  /* lien actif bien visible dans le menu déroulant */
  .main-nav a.active {
    border-left: 3px solid var(--violet);
    border-radius: 4px 10px 10px 4px;
  }
  .main-nav a.nav-cta { text-align: center; margin-top: 6px; border-left: none; border-radius: 12px; }
  .burger { display: block; }
  .form-grid { grid-template-columns: 1fr; }
  section { padding: 54px 0; }
}

/* ---------- Mobile ≤ 640 px ---------- */
@media (max-width: 640px) {
  section { padding: 46px 0; }
  .section-sub { margin-bottom: 28px; font-size: .97rem; }

  /* Hero : hauteur raisonnable */
  .hero { padding: 68px 0 60px; }
  .hero-badge { margin-bottom: 16px; }
  .hero h1 { margin-bottom: 16px; }
  .hero p { font-size: 1rem; margin-bottom: 26px; }
  .hero-actions { gap: 10px; }

  .page-hero { padding: 44px 0 26px; }
  .page-hero p { font-size: 1rem; }

  /* Cartes & étapes : espacements resserrés en 1 colonne */
  .cards-grid, .steps { gap: 16px; }
  .card { padding: 24px 20px; }
  .step { padding: 24px 20px 20px; }

  /* Mosaïque : 2 colonnes compactes */
  .gallery { columns: 2 140px; column-gap: 10px; }
  .gallery a { margin-bottom: 10px; }

  /* Instagram : reels empilés, hauteur adaptée au format 9:16 */
  .insta-grid { gap: 16px; }
  .insta-item iframe { height: 540px; }

  /* Formulaires : padding tactile, carte moins lourde */
  .form-wrap { padding: 24px 18px; }
  .form-grid { gap: 14px; }
  input, textarea, select { padding: 13px 14px; }

  .cta-band { padding: 36px 22px; }
  .split { gap: 28px; }

  /* Footer : grille empilée, icônes sociales ≥ 44 px */
  .footer-grid { gap: 28px; margin-bottom: 32px; }
  .footer-social { gap: 14px; }
  .footer-social a { width: 44px; height: 44px; }
  .footer-social a svg { width: 19px; height: 19px; }
}

/* ---------- Très petits écrans ≤ 430 px ---------- */
@media (max-width: 430px) {
  .container { width: calc(100% - 32px); }
  .logo img { height: 42px; }
  .main-nav { inset: 71px 0 auto 0; max-height: calc(100vh - 71px); max-height: calc(100dvh - 71px); }

  /* Boutons du hero empilés pleine largeur */
  .hero-actions { flex-direction: column; align-items: stretch; }
  .hero-actions .btn { width: 100%; justify-content: center; }
  .btn { padding: 14px 22px; }

  .cta-band .btn { width: 100%; justify-content: center; }
  .insta-head .btn { width: 100%; justify-content: center; }
  .insta-item iframe { height: 520px; }
  .footer-bottom { justify-content: center; text-align: center; }
}
