/* ============================================================
   Novorys 3D — design system "impression 3D"
   ============================================================ */

:root {
  /* Palette : dark navy + bleu électrique + cyan, accent orange nozzle */
  --color-bg:           #f4f6fb;
  --color-bg-grid:      rgba(13, 19, 33, 0.04);
  --color-surface:      #ffffff;
  --color-surface-2:    #f7f9fd;

  --color-ink:          #0a0e1a;
  --color-ink-soft:     #1a2236;
  --color-text:         #1a1f2e;
  --color-muted:        #5d6573;
  --color-border:       #e4e8f0;
  --color-border-strong:#cbd3e1;

  --color-primary:      #3d7eff;
  --color-primary-2:    #06b6d4;
  --color-primary-dark: #1d55c8;
  --color-glow:         rgba(61, 126, 255, 0.45);

  --color-accent:       #ff6b35;   /* hot-end / nozzle */
  --color-success:      #10b981;
  --color-warning:      #f59e0b;
  --color-danger:       #ef4444;

  --grad-primary:       linear-gradient(135deg, #3d7eff 0%, #06b6d4 100%);
  --grad-dark:          linear-gradient(180deg, #0a0e1a 0%, #0f1830 60%, #142447 100%);
  --grad-glow:          radial-gradient(60% 60% at 80% 10%, rgba(61, 126, 255, 0.35), transparent 60%);

  --shadow-sm:          0 2px 8px rgba(10, 14, 26, 0.06);
  --shadow-md:          0 10px 30px rgba(10, 14, 26, 0.08);
  --shadow-lg:          0 24px 60px rgba(10, 14, 26, 0.12);
  --shadow-glow:        0 8px 28px rgba(61, 126, 255, 0.35);

  --radius-lg: 22px;
  --radius-md: 14px;
  --radius-sm: 10px;
  --container: 1160px;

  --font-sans:  'Inter', system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  --font-head:  'Chakra Petch', 'Inter', system-ui, sans-serif;
  --font-mono:  'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

/* ============================================================
   Cross-browser baseline
   Cibles : Chrome/Edge 90+, Firefox 80+, Safari 13+ (desktop & iOS),
            Samsung Internet 14+, Android WebView Chromium récent.
   ============================================================ */

*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;       /* empêche iOS d'agrandir le texte en paysage */
  -moz-text-size-adjust: 100%;
  text-size-adjust: 100%;
  -webkit-tap-highlight-color: transparent; /* enlève le flash bleu Android au tap */
  scrollbar-gutter: stable;             /* évite le saut de layout quand une scrollbar apparaît */
}

body {
  margin: 0;
  font-family: var(--font-sans);
  color: var(--color-text);
  background: var(--color-bg);
  line-height: 1.6;
  font-size: 16px;                      /* base pour empêcher le zoom auto iOS sur input < 16px */
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;                   /* aucune bande horizontale parasite sur mobile */
}

/* Trame de plateau d'impression discrète sur le fond global */
body::before {
  content: "";
  position: fixed;
  top: 0; right: 0; bottom: 0; left: 0;
  background-image:
    linear-gradient(to right,  var(--color-bg-grid) 1px, transparent 1px),
    linear-gradient(to bottom, var(--color-bg-grid) 1px, transparent 1px);
  background-size: 56px 56px;
  pointer-events: none;
  z-index: 0;
  -webkit-mask-image: radial-gradient(ellipse at center, #000 30%, transparent 80%);
          mask-image: radial-gradient(ellipse at center, #000 30%, transparent 80%);
}

main, header, footer { position: relative; z-index: 1; }

a { color: inherit; text-decoration: none; }
img { max-width: 100%; }

.section-container {
  width: min(100% - 32px, var(--container));
  margin-left: auto;
  margin-right: auto;
  /* Sur iPhone à encoche en paysage : on respecte les zones de sécurité */
  padding-left: env(safe-area-inset-left, 0);
  padding-right: env(safe-area-inset-right, 0);
}

/* ============================================================
   Header / Navbar
   ============================================================ */

.site-header {
  position: relative;
  color: #fff;
  background:
    var(--grad-glow),
    linear-gradient(135deg, #2352d4 0%, #152f66 55%, #070c1b 100%);
  overflow: hidden;
}

/* Grille "build plate" du hero */
.site-header::before {
  content: "";
  position: absolute;
  top: 0; right: 0; bottom: 0; left: 0;
  background-image:
    linear-gradient(to right,  rgba(255,255,255,0.04) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255,255,255,0.04) 1px, transparent 1px);
  background-size: 48px 48px;
  -webkit-mask-image: radial-gradient(ellipse 80% 60% at 50% 30%, #000 0%, transparent 75%);
          mask-image: radial-gradient(ellipse 80% 60% at 50% 30%, #000 0%, transparent 75%);
  pointer-events: none;
}

/* Ligne de scan animée (tête d'impression qui passe) */
.site-header::after {
  content: "";
  position: absolute;
  left: -10%;
  right: -10%;
  top: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--color-primary) 50%, transparent);
  filter: drop-shadow(0 0 12px var(--color-primary));
  opacity: 0.65;
  animation: scan 7s ease-in-out infinite;
  pointer-events: none;
}

@keyframes scan {
  0%, 100% { transform: translateY(0); opacity: 0; }
  10%      { opacity: 0.7; }
  50%      { transform: translateY(620px); opacity: 0.7; }
  60%      { opacity: 0; }
}

.navbar {
  width: min(100% - 32px, var(--container));
  margin-left: auto;
  margin-right: auto;
  padding-left: env(safe-area-inset-left, 0);
  padding-right: env(safe-area-inset-right, 0);
  padding-top: env(safe-area-inset-top, 0);
  min-height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  position: relative;
  z-index: 2;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-head);
  font-weight: 700;
  letter-spacing: -0.02em;
}

.brand-logo {
  height: 90px;
  width: auto;
  display: block;
  /* Le logo étant en navy sur fond clair, on l'éclaircit pour le header sombre */
  filter: brightness(1) invert(0);
  transition: filter 0.25s ease, transform 0.25s ease;
}

.brand:hover .brand-logo { transform: translateY(-1px); }

.brand-badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: 8px;
  background: var(--grad-primary);
  color: #fff;
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  line-height: 1;
  box-shadow: 0 4px 14px rgba(61, 126, 255, 0.45);
}

.nav-links {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 28px;
  margin: 0;
  padding: 0;
  font-size: 0.93rem;
}

.nav-links a {
  color: rgba(255, 255, 255, 0.78);
  font-weight: 500;
  transition: color 0.2s ease;
  position: relative;
}

.nav-links a:not(.nav-cta)::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -8px;
  height: 2px;
  background: var(--grad-primary);
  border-radius: 2px;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.25s ease;
}

.nav-links a:not(.nav-cta):hover { color: #fff; }
.nav-links a:not(.nav-cta):hover::after { transform: scaleX(1); }

.nav-cta {
  padding: 10px 18px;
  background: var(--grad-primary);
  color: #fff !important;
  border-radius: 999px;
  font-weight: 700;
  box-shadow: var(--shadow-glow);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

@media (hover: hover) {
  .nav-cta:hover {
    transform: translateY(-1px);
    box-shadow: 0 12px 34px rgba(61, 126, 255, 0.55);
  }
}

.nav-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: rgba(255,255,255,0.06);
  border-radius: 12px;
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  background: #fff;
  margin: 5px auto;
  border-radius: 2px;
}

/* ============================================================
   Hero
   ============================================================ */

.hero {
  min-height: 640px;
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  align-items: center;
  gap: 64px;
  padding: 88px 0 112px;
  position: relative;
  z-index: 2;
}

.eyebrow {
  font-family: var(--font-mono);
  margin: 0 0 14px;
  color: var(--color-primary);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: 0.72rem;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.eyebrow::before {
  content: "";
  width: 24px;
  height: 1px;
  background: currentColor;
}

.site-header .eyebrow,
.section-dark .eyebrow { color: #7fb8ff; }

h1, h2, h3, p { margin-top: 0; }

h1 {
  font-family: var(--font-head);
  max-width: 820px;
  font-size: clamp(2.3rem, 5.2vw, 4.2rem);
  line-height: 1.05;
  letter-spacing: -0.02em;
  font-weight: 700;
  margin-bottom: 24px;
}

h1 .accent {
  background: var(--grad-primary);
  -webkit-background-clip: text;
          background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent; /* Safari < 15 a besoin de ça */
}

h2 {
  font-family: var(--font-head);
  font-size: clamp(1.85rem, 3.6vw, 2.7rem);
  line-height: 1.12;
  letter-spacing: -0.015em;
  font-weight: 700;
  margin-bottom: 18px;
  color: var(--color-ink);
}

.section-dark h2, .site-header h1 { color: #fff; }

h3 {
  font-family: var(--font-head);
  font-size: 1.15rem;
  line-height: 1.25;
  font-weight: 600;
  color: var(--color-ink);
}

.hero-text {
  max-width: 580px;
  color: rgba(255, 255, 255, 0.78);
  font-size: 1.1rem;
  line-height: 1.6;
}

.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 12px; }

/* ============================================================
   Boutons
   ============================================================ */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 0;
  min-height: 50px;            /* tap target ≥ 44px iOS HIG */
  padding: 0 24px;
  border-radius: 999px;
  font-family: var(--font-sans);
  font-weight: 700;
  font-size: 0.97rem;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
  text-decoration: none;
  -webkit-appearance: none;    /* normalise iOS Safari (sinon contour bleu + ombrage) */
          appearance: none;
  touch-action: manipulation;  /* supprime le délai de 300 ms sur double-tap mobile */
  -webkit-user-select: none;
          user-select: none;
}

/* Hover seulement sur appareils capables (pas de "sticky hover" en tactile) */
@media (hover: hover) {
  .btn:hover { transform: translateY(-2px); }
}

.btn:active { transform: translateY(0); }
.btn:focus-visible {
  outline: 3px solid rgba(61, 126, 255, 0.55);
  outline-offset: 3px;
}

.btn-primary {
  background: var(--grad-primary);
  color: #fff;
  box-shadow: var(--shadow-glow);
}

.btn-primary:hover {
  box-shadow: 0 14px 38px rgba(61, 126, 255, 0.55);
}

.btn-primary::after {
  content: "→";
  font-weight: 600;
  transition: transform 0.25s ease;
}

.btn-primary:hover::after { transform: translateX(4px); }

.btn-secondary {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.18);
  -webkit-backdrop-filter: blur(6px);
          backdrop-filter: blur(6px);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.14);
  border-color: rgba(255, 255, 255, 0.3);
}

.full-width { width: 100%; }

/* ============================================================
   Hero visual : cube isométrique + specs
   ============================================================ */

.hero-visual {
  position: relative;
  display: grid;
  place-items: center;
  padding: 20px;
}

.iso-cube {
  width: clamp(220px, 28vw, 320px);
  height: clamp(220px, 28vw, 320px);
  filter: drop-shadow(0 24px 40px rgba(61, 126, 255, 0.35));
  animation: floaty 6s ease-in-out infinite;
}

.iso-rotate {
  transform-origin: 0 0;
  animation: gentleSpin 18s linear infinite;
}

.iso-orbit {
  animation: orbitSpin 30s linear infinite;
  transform-origin: 0 0;
}

@keyframes floaty {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-12px); }
}

@keyframes gentleSpin {
  0%   { transform: rotateY(0deg) skewX(0); }
  50%  { transform: rotate(2deg); }
  100% { transform: rotate(0deg); }
}

@keyframes orbitSpin {
  to { transform: rotate(360deg); }
}

.spec-list {
  list-style: none;
  padding: 18px 22px;
  margin: 18px 0 0;
  display: grid;
  gap: 10px;
  background: rgba(10, 14, 26, 0.75);          /* fallback opaque pour Firefox < 103 */
  -webkit-backdrop-filter: blur(10px);
          backdrop-filter: blur(10px);
  border: 1px solid rgba(127, 184, 255, 0.18);
  border-radius: var(--radius-md);
  font-family: var(--font-mono);
  font-size: 0.82rem;
  width: 100%;
  max-width: 360px;
}

/* Si l'effet de flou est supporté, on peut alléger l'opacité du fond */
@supports ((backdrop-filter: blur(10px)) or (-webkit-backdrop-filter: blur(10px))) {
  .spec-list { background: rgba(10, 14, 26, 0.55); }
}

.spec-list li {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  color: rgba(255, 255, 255, 0.6);
}

.spec-list strong {
  color: #fff;
  font-weight: 500;
}

/* ============================================================
   Sections
   ============================================================ */

.section { padding: 100px 0; position: relative; }
.section-alt {
  background: var(--color-surface);
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
}

.section-dark {
  background: var(--grad-dark);
  color: rgba(255, 255, 255, 0.78);
  position: relative;
  overflow: hidden;
}

.section-dark::before {
  content: "";
  position: absolute;
  top: 0; right: 0; bottom: 0; left: 0;
  background-image:
    linear-gradient(to right,  rgba(255,255,255,0.03) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255,255,255,0.03) 1px, transparent 1px);
  background-size: 48px 48px;
  pointer-events: none;
}

.section-dark .section-container { position: relative; z-index: 1; }

.section-heading {
  max-width: 760px;
  margin-bottom: 48px;
}

.section-heading p { color: var(--color-muted); font-size: 1.05rem; }
.section-dark p { color: rgba(255, 255, 255, 0.72); }

/* ============================================================
   Cards (services + projets) — accent layer-lines
   ============================================================ */

.cards-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}

.card {
  position: relative;
  padding: 28px;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
  overflow: hidden;
}

/* "Lignes d'impression" en haut de chaque carte */
.card::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 4px;
  background: repeating-linear-gradient(
    90deg,
    var(--color-primary) 0 8px,
    var(--color-primary-2) 8px 16px
  );
  opacity: 0.85;
  transform: scaleX(0.18);
  transform-origin: left;
  transition: transform 0.4s cubic-bezier(.2,.8,.2,1);
}

@media (hover: hover) {
  .card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-lg);
    border-color: rgba(61, 126, 255, 0.25);
  }
  .card:hover::before { transform: scaleX(1); }
}

/* En tactile : on garde la ligne d'extrusion entièrement visible (pas de hover possible) */
@media (hover: none) {
  .card::before { transform: scaleX(1); }
}

.card-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 56px;
  height: 36px;
  padding: 0 14px;
  border-radius: 10px;
  background: rgba(61, 126, 255, 0.08);
  color: var(--color-primary);
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 0.82rem;
  letter-spacing: 0.04em;
  margin-bottom: 18px;
  border: 1px solid rgba(61, 126, 255, 0.18);
}

.card p, .step p, .notice-card p { color: var(--color-muted); }

/* ============================================================
   Split layouts + check-list
   ============================================================ */

.split-layout {
  display: grid;
  grid-template-columns: 1fr 0.82fr;
  gap: 64px;
  align-items: center;
}

.check-list {
  list-style: none;
  padding: 0;
  margin: 28px 0;
}

.check-list li {
  position: relative;
  padding-left: 34px;
  margin-bottom: 14px;
}

.check-list li::before {
  content: "";
  position: absolute;
  left: 0; top: 6px;
  width: 18px;
  height: 18px;
  border-radius: 6px;
  background: var(--grad-primary);
  mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'><path d='M3.5 8.5l3 3 6-7' stroke='black' stroke-width='2.2' fill='none' stroke-linecap='round' stroke-linejoin='round'/></svg>") center / 12px no-repeat;
  -webkit-mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'><path d='M3.5 8.5l3 3 6-7' stroke='black' stroke-width='2.2' fill='none' stroke-linecap='round' stroke-linejoin='round'/></svg>") center / 12px no-repeat;
}

.check-list.light li::before {
  background: linear-gradient(135deg, #7fb8ff, #06b6d4);
}

.notice-card {
  padding: 32px;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-left: 4px solid var(--color-primary);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  position: relative;
  overflow: hidden;
}

.notice-card::after {
  content: "";
  position: absolute;
  top: 0; right: 0;
  width: 120px; height: 120px;
  background: radial-gradient(circle at 100% 0%, rgba(61, 126, 255, 0.12), transparent 70%);
  pointer-events: none;
}

/* ============================================================
   Steps
   ============================================================ */

.steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
  counter-reset: step;
}

.step {
  position: relative;
  padding: 28px 24px 24px;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

@media (hover: hover) {
  .step:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
}

.step span {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: var(--grad-primary);
  color: #fff;
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 0.95rem;
  margin-bottom: 16px;
  box-shadow: 0 6px 16px rgba(61, 126, 255, 0.35);
}

/* ============================================================
   Price table
   ============================================================ */

.price-table {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  overflow: hidden;
}

.price-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 20px;
  padding: 20px 28px;
  border-bottom: 1px solid var(--color-border);
  transition: background 0.15s ease;
}

.price-row:last-child { border-bottom: 0; }
@media (hover: hover) {
  .price-row:not(.price-head):hover { background: var(--color-surface-2); }
}

.price-head {
  background: var(--color-ink);
  color: #fff;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 600;
}

.price-row strong {
  font-family: var(--font-mono);
  font-weight: 700;
  color: var(--color-primary);
}

/* ============================================================
   Formulaire devis
   ============================================================ */

.quote-form {
  padding: 32px;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  position: relative;
  overflow: hidden;
}

.quote-form::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 4px;
  background: var(--grad-primary);
}

.quote-form label {
  display: block;
  margin-bottom: 18px;
  color: var(--color-ink);
  font-weight: 600;
  font-size: 0.93rem;
}

.quote-form .optional {
  color: var(--color-muted);
  font-weight: 400;
  font-size: 0.82rem;
  margin-left: 4px;
}

.quote-form input,
.quote-form select,
.quote-form textarea {
  width: 100%;
  margin-top: 7px;
  border: 1px solid var(--color-border-strong);
  border-radius: var(--radius-sm);
  padding: 13px 14px;
  font: inherit;
  font-weight: 400;
  font-size: 16px;            /* ≥ 16px → empêche iOS Safari de zoomer au focus */
  color: var(--color-text);
  background: var(--color-surface);
  transition: border-color 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
  -webkit-appearance: none;
     -moz-appearance: none;
          appearance: none;
}

/* Custom chevron pour <select> (sinon arrow OS différent selon Android/iOS) */
.quote-form select {
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 16 16'><path d='M3 6l5 5 5-5' fill='none' stroke='%231a1f2e' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/></svg>");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 40px;
}

@media (hover: hover) {
  .quote-form input:hover,
  .quote-form select:hover,
  .quote-form textarea:hover { border-color: var(--color-muted); }
}

.quote-form input:focus,
.quote-form select:focus,
.quote-form textarea:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 4px rgba(61, 126, 255, 0.15);
  background: #fff;
}

.quote-form textarea { resize: vertical; min-height: 120px; }

.quote-form input:invalid:not(:placeholder-shown) { border-color: var(--color-danger); }

/* Supprime les bizarreries iOS sur number / date / etc. */
.quote-form input[type="number"]::-webkit-outer-spin-button,
.quote-form input[type="number"]::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.quote-form input[type="number"] { -moz-appearance: textfield; }

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.form-row > label { margin-bottom: 18px; }

.file-field input[type="file"] {
  padding: 11px;
  background: var(--color-surface-2);
  cursor: pointer;
  font-size: 14px;
}

/* Standard (Chrome 89+, Firefox 82+, Safari 14.1+) */
.file-field input[type="file"]::file-selector-button {
  border: 0;
  background: var(--grad-primary);
  color: #fff;
  padding: 9px 16px;
  margin-right: 14px;
  border-radius: 8px;
  font: inherit;
  font-weight: 700;
  font-size: 0.85rem;
  cursor: pointer;
  box-shadow: var(--shadow-glow);
}

/* Anciens Safari (< 14.1) et anciens Chrome/Edge */
.file-field input[type="file"]::-webkit-file-upload-button {
  border: 0;
  background: var(--grad-primary);
  color: #fff;
  padding: 9px 16px;
  margin-right: 14px;
  border-radius: 8px;
  font: inherit;
  font-weight: 700;
  font-size: 0.85rem;
  cursor: pointer;
  -webkit-appearance: none;
}

.file-summary {
  display: block;
  margin-top: 10px;
  font-weight: 500;
  font-size: 0.86rem;
  color: var(--color-muted);
  font-family: var(--font-mono);
}

.file-summary[data-state="ok"]    { color: var(--color-success); }
.file-summary[data-state="error"] { color: var(--color-danger); }

.consent {
  display: flex !important;
  align-items: flex-start;
  gap: 12px;
  font-weight: 400 !important;
  font-size: 0.88rem;
  color: var(--color-text) !important;
  margin: 8px 0 22px !important;
  padding: 14px;
  background: var(--color-surface-2);
  border-radius: var(--radius-sm);
  border: 1px solid var(--color-border);
}

.consent input[type="checkbox"] {
  width: auto;
  margin: 2px 0 0;
  flex-shrink: 0;
  accent-color: var(--color-primary);
  transform: scale(1.15);
}

.hp-field {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

#quote-submit {
  position: relative;
  margin-top: 4px;
}

#quote-submit.is-loading { opacity: 0.85; cursor: progress; }
#quote-submit.is-loading .btn-label { visibility: hidden; }
#quote-submit.is-loading::after { content: none; }

#quote-submit .btn-spinner {
  display: none;
  position: absolute;
  width: 20px;
  height: 20px;
  border: 2.5px solid rgba(255, 255, 255, 0.35);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}

#quote-submit.is-loading .btn-spinner { display: block; }

@keyframes spin { to { transform: rotate(360deg); } }

.form-feedback {
  min-height: 24px;
  margin: 16px 0 0;
  font-family: var(--font-mono);
  font-weight: 600;
  font-size: 0.88rem;
  color: var(--color-primary-dark);
}

.form-feedback[data-state="pending"] { color: var(--color-muted); }
.form-feedback[data-state="success"] { color: var(--color-success); }
.form-feedback[data-state="error"]   { color: var(--color-danger); }

.form-note {
  margin: 10px 0 0;
  font-size: 0.78rem;
  color: var(--color-muted);
  font-family: var(--font-mono);
}

/* ============================================================
   Footer
   ============================================================ */

.site-footer {
  padding: 46px 0 calc(40px + env(safe-area-inset-bottom, 0px));
    background:
    var(--grad-glow),
    linear-gradient(135deg, #2352d4 0%, #152f66 55%, #070c1b 100%);
  overflow: hidden;
  color: rgba(255, 255, 255, 0.6);
  border-top: 1px solid rgba(127, 184, 255, 0.08);
  font-size: 0.93rem;
}

.site-footer strong {
  color: #fff;
  font-family: var(--font-head);
  font-size: 1.1rem;
  letter-spacing: -0.01em;
}

.footer-brand {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.footer-brand p {
  flex-basis: 100%;
  margin: 14px 0 0;
}

.brand-logo-footer {
  height: 60px;
  filter: brightness(1) invert(0);
  opacity: 0.95;
}

.footer-layout {
  display: flex;
  justify-content: space-between;
  gap: 32px;
  align-items: flex-start;
}

.footer-layout p {
  max-width: 540px;
  margin: 8px 0 0;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  font-family: var(--font-mono);
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.footer-links a {
  color: rgba(255, 255, 255, 0.65);
  transition: color 0.2s ease;
}

.footer-links a:hover { color: var(--color-primary); }

/* ============================================================
   Animations scroll-reveal
   ============================================================ */

.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.7s ease, transform 0.7s cubic-bezier(.2,.8,.2,1);
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
  .reveal { opacity: 1; transform: none; }
}

/* ============================================================
   Responsive
   ============================================================ */

@media (max-width: 960px) {
  .nav-toggle { display: block; }

  .nav-links {
    position: absolute;
    top: 76px; right: 16px; left: 16px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 20px;
    background: rgba(10, 14, 26, 0.97);
    -webkit-backdrop-filter: blur(14px);
            backdrop-filter: blur(14px);
    color: #fff;
    border-radius: var(--radius-md);
    border: 1px solid rgba(127, 184, 255, 0.15);
    box-shadow: var(--shadow-lg);
    z-index: 10;
  }

  .nav-links.is-open { display: flex; }
  .nav-links a:not(.nav-cta)::after { display: none; }
  .nav-cta { text-align: center; }

  .hero,
  .split-layout {
    grid-template-columns: 1fr;
    gap: 48px;
  }

  .hero { padding: 56px 0 80px; }

  .cards-grid,
  .steps { grid-template-columns: repeat(2, 1fr); }

  .footer-layout { flex-direction: column; }
}

@media (max-width: 620px) {
  .section { padding: 68px 0; }
  .cards-grid, .steps { grid-template-columns: 1fr; }

  .price-row {
    grid-template-columns: 1fr;
    gap: 4px;
    padding: 16px 20px;
  }

  .form-row { grid-template-columns: 1fr; gap: 0; }

  .iso-cube { width: 70vw; height: 70vw; max-width: 280px; max-height: 280px; }
}

/* ============================================================
   Très petits écrans (≤ 360 px : iPhone SE 1re gen, Galaxy Fold fermé…)
   ============================================================ */
@media (max-width: 380px) {
  .navbar { gap: 12px; }
  .brand-logo { height: 32px; }
  .brand-badge { padding: 3px 8px; font-size: 0.72rem; }
  .quote-form { padding: 22px; }
  .hero { padding: 40px 0 64px; }
  h1 { letter-spacing: -0.01em; }
}

/* ============================================================
   Très grands écrans (4K, ultrawide)
   ============================================================ */
@media (min-width: 1600px) {
  :root { --container: 1320px; }
}

/* ============================================================
   Connexion lente / data saver : on désactive les animations gourmandes
   ============================================================ */
@media (prefers-reduced-data: reduce) {
  .site-header::after,
  .iso-cube,
  .iso-rotate,
  .iso-orbit { animation: none !important; }
}

/* ============================================================
   Impression
   ============================================================ */
@media print {
  body { background: #fff !important; color: #000 !important; padding: 0; }
  body::before, .site-header::before, .site-header::after,
  .section-dark::before, .nav-toggle, .nav-links, .hero-actions,
  .iso-cube, .reveal { display: none !important; }
  .site-header, .section-dark, .site-footer {
    background: #fff !important; color: #000 !important;
  }
  .site-header h1, .section-dark h2, .site-footer strong { color: #000 !important; }
  .brand-logo, .brand-logo-footer { filter: none !important; }
  a { color: #000 !important; text-decoration: underline; }
  .card, .step, .price-table, .notice-card, .quote-form {
    box-shadow: none !important; border: 1px solid #999 !important; break-inside: avoid;
  }
  .section { padding: 24px 0 !important; }
}
