/* ============================================================
   Urgence Plomberie Chambéry — styles.css
   Mobile-first. Vanilla CSS. Inspiré des maquettes fournies.
   ============================================================ */

/* ---------- Tokens ---------- */
:root {
  --bg:           #0b0d10;
  --bg-2:         #0f1216;
  --surface:      #14181d;
  --surface-2:    #181d23;
  --border:       rgba(255,255,255,.07);
  --border-strong:rgba(255,255,255,.12);

  --text:         #f2f4f7;
  --text-dim:     #aab1bb;
  --text-mute:    #6c747f;

  --red:          #ef4444;
  --red-2:        #dc2626;
  --red-soft:     rgba(239,68,68,.12);
  --red-glow:     rgba(239,68,68,.45);

  --radius-sm:    10px;
  --radius:       16px;
  --radius-lg:    22px;

  --shadow-card:  0 1px 0 rgba(255,255,255,.04) inset, 0 10px 30px rgba(0,0,0,.35);
  --shadow-cta:   0 10px 24px rgba(239,68,68,.35);

  --ease:         cubic-bezier(.22,.61,.36,1);
  --t-fast:       .18s var(--ease);
  --t:            .28s var(--ease);
  --t-slow:       .55s var(--ease);

  --container:    1180px;
  --header-h:     68px;
}

/* ---------- Reset ---------- */
*,*::before,*::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: 'Inter', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  font-size: 16px;
  line-height: 1.55;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; border: 0; background: none; color: inherit; }
ul { list-style: none; padding: 0; margin: 0; }
input, select, textarea { font: inherit; }
hr { border: 0; border-top: 1px solid var(--border); margin: 0; }

::selection { background: var(--red); color: #fff; }

/* Subtle radial accent on the page */
body::before {
  content: "";
  position: fixed; inset: 0;
  background:
    radial-gradient(900px 500px at 85% -10%, rgba(239,68,68,.10), transparent 60%),
    radial-gradient(700px 400px at -10% 30%, rgba(239,68,68,.06), transparent 60%);
  pointer-events: none;
  z-index: 0;
}

/* ---------- Layout helpers ---------- */
.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 20px;
  position: relative;
  z-index: 1;
}

.section {
  padding: 64px 0;
  position: relative;
}
.section-alt {
  background: linear-gradient(180deg, var(--bg) 0%, var(--bg-2) 100%);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.eyebrow {
  display: inline-block;
  color: var(--red);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .18em;
  text-transform: uppercase;
  margin-bottom: 14px;
}

.section-title {
  font-size: clamp(28px, 7vw, 52px);
  line-height: 1.02;
  letter-spacing: -.01em;
  font-weight: 900;
  text-transform: uppercase;
  margin: 0 0 24px;
}

.lede {
  color: var(--text-dim);
  font-size: 16px;
  max-width: 52ch;
  margin: 0 0 22px;
}

/* ---------- Buttons ---------- */
.btn {
  --pad-y: 14px;
  --pad-x: 22px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: var(--pad-y) var(--pad-x);
  border-radius: 999px;
  font-weight: 600;
  font-size: 15px;
  letter-spacing: .005em;
  transition: transform var(--t), background-color var(--t), box-shadow var(--t), color var(--t);
  will-change: transform;
  white-space: nowrap;
}
.btn-sm { --pad-y: 10px; --pad-x: 16px; font-size: 14px; }
.btn-block { width: 100%; }

.btn-primary {
  background: var(--red);
  color: #fff;
  box-shadow: var(--shadow-cta);
  position: relative;
}
.btn-primary::after {
  content: "";
  position: absolute; inset: 0;
  border-radius: inherit;
  box-shadow: 0 0 0 0 var(--red-glow);
  transition: box-shadow var(--t-slow);
  pointer-events: none;
}
.btn-primary:hover { background: var(--red-2); transform: translateY(-2px); }
.btn-primary:hover::after { box-shadow: 0 0 0 10px rgba(239,68,68,0); }
.btn-primary:active { transform: translateY(0); }

.btn-ghost {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border-strong);
}
.btn-ghost:hover {
  background: rgba(255,255,255,.04);
  border-color: rgba(255,255,255,.22);
  transform: translateY(-2px);
}

/* Pulse for primary CTAs (subtle, attention-grabbing) */
.btn-primary {
  animation: cta-pulse 2.6s ease-in-out infinite;
}
@keyframes cta-pulse {
  0%, 100% { box-shadow: 0 10px 24px rgba(239,68,68,.32), 0 0 0 0 rgba(239,68,68,.35); }
  50%      { box-shadow: 0 12px 28px rgba(239,68,68,.45), 0 0 0 12px rgba(239,68,68,0); }
}
@media (prefers-reduced-motion: reduce) {
  .btn-primary { animation: none; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
  html { scroll-behavior: auto; }
}

/* ---------- Header ---------- */
.header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(11,13,16,.65);
  backdrop-filter: saturate(140%) blur(12px);
  -webkit-backdrop-filter: saturate(140%) blur(12px);
  border-bottom: 1px solid transparent;
  transition: background var(--t), border-color var(--t), padding var(--t);
}
.header.scrolled {
  background: rgba(11,13,16,.92);
  border-color: var(--border);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  height: var(--header-h);
}
.brand img {
  height: 38px;
  width: auto;
  transition: transform var(--t);
}
.brand:hover img { transform: scale(1.04); }

.nav { display: none; }
.nav a {
  font-size: 14px;
  color: var(--text-dim);
  padding: 8px 12px;
  border-radius: 8px;
  position: relative;
  transition: color var(--t);
}
.nav a::after {
  content: "";
  position: absolute;
  left: 12px; right: 12px; bottom: 4px;
  height: 2px;
  background: var(--red);
  border-radius: 2px;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--t);
}
.nav a:hover { color: var(--text); }
.nav a:hover::after { transform: scaleX(1); }

.header-cta { display: none; }

.menu-toggle {
  width: 40px; height: 40px;
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  border-radius: 10px;
  border: 1px solid var(--border-strong);
}
.menu-toggle span {
  display: block;
  width: 18px; height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: transform var(--t), opacity var(--t);
}
.menu-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.menu-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Mobile nav drawer */
.nav.open {
  display: flex;
  flex-direction: column;
  position: fixed;
  top: var(--header-h);
  left: 0; right: 0;
  background: rgba(11,13,16,.98);
  backdrop-filter: blur(14px);
  padding: 18px 20px 28px;
  border-bottom: 1px solid var(--border);
  gap: 4px;
  animation: slide-down .35s var(--ease);
}
.nav.open a {
  font-size: 18px;
  padding: 14px 12px;
  border-bottom: 1px solid var(--border);
  color: var(--text);
}
.nav.open a:last-of-type { border-bottom: 0; }
@keyframes slide-down {
  from { transform: translateY(-12px); opacity: 0; }
  to   { transform: translateY(0); opacity: 1; }
}

/* ---------- HERO ---------- */
.hero {
  position: relative;
  padding: 32px 0 56px;
  overflow: hidden;
}
.hero-bg {
  position: absolute; inset: 0;
  background:
    radial-gradient(600px 320px at 80% 20%, rgba(239,68,68,.18), transparent 70%),
    linear-gradient(180deg, rgba(0,0,0,0) 0%, rgba(0,0,0,.4) 100%);
  z-index: 0;
}
.hero-inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
  align-items: center;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  background: var(--red-soft);
  color: #ffd5d5;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  border-radius: 999px;
  border: 1px solid rgba(239,68,68,.25);
  margin-bottom: 18px;
}
.badge .dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--red);
  box-shadow: 0 0 0 0 var(--red);
  animation: dot-pulse 1.6s infinite;
}
@keyframes dot-pulse {
  0%   { box-shadow: 0 0 0 0 rgba(239,68,68,.7); }
  70%  { box-shadow: 0 0 0 10px rgba(239,68,68,0); }
  100% { box-shadow: 0 0 0 0 rgba(239,68,68,0); }
}

.hero-title {
  font-size: clamp(40px, 11vw, 84px);
  line-height: .96;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: -.015em;
  margin: 0 0 18px;
}
.hero-title .accent { color: var(--red); }
.hero-title .muted  { color: var(--text-dim); }

.hero-sub {
  color: var(--text-dim);
  font-size: 16px;
  max-width: 56ch;
  margin: 0 0 24px;
}

.hero-ctas {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 24px;
}

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 14px 22px;
  color: var(--text-mute);
  font-size: 13px;
}
.hero-meta strong { color: var(--text); font-weight: 600; }

/* Hero card (logo + stats) */
.hero-card {
  background: linear-gradient(180deg, var(--surface) 0%, var(--surface-2) 100%);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 22px;
  box-shadow: var(--shadow-card);
  transform: translateY(0);
  transition: transform var(--t-slow);
}
.hero-card:hover { transform: translateY(-4px); }

.logo-card {
  background: #0a0c10;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px;
  display: grid;
  place-items: center;
  margin-bottom: 18px;
  position: relative;
  overflow: hidden;
}
.logo-card::before {
  content: "";
  position: absolute; inset: 0;
  background: radial-gradient(400px 200px at 50% -20%, rgba(239,68,68,.18), transparent 70%);
  pointer-events: none;
}
.logo-card img {
  max-height: 160px;
  width: auto;
}

.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  text-align: center;
}
.stats li {
  padding: 14px 6px;
  background: rgba(255,255,255,.02);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.stat-num {
  font-weight: 800;
  font-size: 22px;
  color: var(--text);
}
.stat-num .plus { color: var(--red); }
.stat-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .14em;
  color: var(--text-mute);
}

/* ---------- SERVICES ---------- */
.services-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  margin-top: 32px;
}
.service-card {
  --mx: 50%;
  --my: 0%;
  background: linear-gradient(180deg, var(--surface) 0%, var(--surface-2) 100%);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 26px;
  position: relative;
  overflow: hidden;
  isolation: isolate;
  transition:
    transform .35s var(--ease),
    border-color var(--t),
    box-shadow .4s var(--ease);
}

/* Spotlight qui suit le curseur (--mx/--my mis à jour en JS) */
.service-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(
    260px circle at var(--mx) var(--my),
    rgba(239,68,68,.18),
    transparent 55%
  );
  opacity: 0;
  transition: opacity .35s var(--ease);
  pointer-events: none;
  z-index: -1;
}
.service-card:hover::before { opacity: 1; }

/* Bordure gradient révélée au hover */
.service-card::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(135deg, rgba(239,68,68,.55), rgba(239,68,68,0) 55%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
          mask-composite: exclude;
  opacity: 0;
  transition: opacity var(--t);
  pointer-events: none;
}
.service-card:hover::after { opacity: 1; }

.service-card:hover {
  transform: translateY(-6px);
  border-color: rgba(239,68,68,.25);
  box-shadow:
    0 20px 40px rgba(0,0,0,.45),
    0 0 0 1px rgba(239,68,68,.08);
}

/* Watermark numéro en arrière-plan */
.card-num {
  position: absolute;
  top: 14px;
  right: 18px;
  font-size: 56px;
  font-weight: 900;
  line-height: 1;
  color: rgba(255,255,255,.04);
  letter-spacing: -.04em;
  pointer-events: none;
  transition: color .4s var(--ease), transform .4s var(--ease);
  z-index: 0;
}
.service-card:hover .card-num {
  color: rgba(239,68,68,.18);
  transform: scale(1.06);
}

/* Flèche qui apparaît */
.card-arrow {
  position: absolute;
  bottom: 22px;
  right: 22px;
  width: 36px; height: 36px;
  display: grid;
  place-items: center;
  background: rgba(239,68,68,.1);
  color: var(--red);
  border-radius: 50%;
  border: 1px solid rgba(239,68,68,.25);
  opacity: 0;
  transform: translate(-8px, 4px);
  transition: opacity var(--t), transform var(--t), background var(--t);
}
.service-card:hover .card-arrow {
  opacity: 1;
  transform: translate(0, 0);
}
.service-card:hover .card-arrow svg {
  animation: arrow-nudge 1.4s var(--ease) infinite;
}
@keyframes arrow-nudge {
  0%, 100% { transform: translateX(0); }
  50%      { transform: translateX(3px); }
}

.icon-wrap {
  width: 48px; height: 48px;
  display: grid;
  place-items: center;
  background: var(--red-soft);
  color: var(--red);
  border-radius: 12px;
  margin-bottom: 20px;
  position: relative;
  transition: transform .4s var(--ease), background var(--t);
}
.icon-wrap::before {
  content: "";
  position: absolute;
  inset: -4px;
  border-radius: inherit;
  background: var(--red);
  filter: blur(14px);
  opacity: 0;
  z-index: -1;
  transition: opacity .4s var(--ease);
}
.service-card:hover .icon-wrap {
  transform: scale(1.1) rotate(-6deg);
  background: rgba(239,68,68,.18);
}
.service-card:hover .icon-wrap::before { opacity: .4; }

.service-card h3 {
  font-size: 18px;
  font-weight: 800;
  letter-spacing: .01em;
  text-transform: uppercase;
  margin: 0 0 10px;
  position: relative;
  z-index: 1;
}
.service-card p {
  margin: 0;
  color: var(--text-dim);
  font-size: 15px;
  position: relative;
  z-index: 1;
  padding-right: 40px;
}

/* ---------- ABOUT ---------- */
.about-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 28px;
  align-items: start;
}

.check-list { display: grid; gap: 10px; margin-top: 18px; }
.check-list li {
  position: relative;
  padding-left: 28px;
  color: var(--text-dim);
}
.check-list li::before {
  content: "";
  position: absolute;
  left: 0; top: 7px;
  width: 14px; height: 14px;
  border-radius: 50%;
  background: var(--red-soft);
  border: 2px solid var(--red);
}

.zones-card {
  background: linear-gradient(180deg, var(--surface) 0%, var(--surface-2) 100%);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
}
.zones-card h3 {
  margin: 0 0 16px;
  font-size: 22px;
  font-weight: 800;
}
.zones {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 14px;
}
.zones li {
  padding: 7px 14px;
  font-size: 13px;
  background: rgba(255,255,255,.04);
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--text-dim);
  transition: background var(--t-fast), color var(--t-fast), border-color var(--t-fast), transform var(--t-fast);
}
.zones li:hover {
  background: var(--red-soft);
  color: #ffe2e2;
  border-color: rgba(239,68,68,.4);
  transform: translateY(-1px);
}
.zones-foot {
  margin: 0;
  font-size: 12px;
  color: var(--text-mute);
}

/* ---------- AVIS ---------- */
.reviews-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  margin-top: 32px;
}
.review-card {
  background: linear-gradient(180deg, var(--surface) 0%, var(--surface-2) 100%);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  transition: transform var(--t), border-color var(--t);
}
.review-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-strong);
}
.stars {
  color: var(--red);
  letter-spacing: 4px;
  font-size: 16px;
  margin-bottom: 14px;
}
.quote {
  font-size: 15px;
  color: var(--text);
  margin: 0 0 18px;
  line-height: 1.6;
}
.review-card hr { margin-bottom: 14px; }
.who { display: flex; flex-direction: column; }
.who strong { font-weight: 700; }
.who span { color: var(--text-mute); font-size: 13px; }

/* ---------- CONTACT ---------- */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 28px;
  align-items: center;
}

.contact-form {
  background: linear-gradient(180deg, var(--surface) 0%, var(--surface-2) 100%);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px;
  display: grid;
  gap: 14px;
}
.contact-form .row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}
.contact-form label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .14em;
  color: var(--text-mute);
  text-transform: uppercase;
}
.contact-form input,
.contact-form select,
.contact-form textarea {
  background: var(--bg);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 13px 14px;
  text-transform: none;
  letter-spacing: 0;
  font-weight: 400;
  transition: border-color var(--t), box-shadow var(--t), background var(--t);
}
.contact-form input::placeholder,
.contact-form textarea::placeholder { color: #5a626d; }
.contact-form input:focus,
.contact-form select:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: var(--red);
  box-shadow: 0 0 0 4px rgba(239,68,68,.16);
}
.contact-form textarea { resize: vertical; min-height: 100px; }
.contact-form select {
  appearance: none;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'><path fill='%23aab1bb' d='M6 8L0 0h12z'/></svg>");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 36px;
}
.form-foot {
  margin: 4px 0 0;
  font-size: 12px;
  color: var(--text-mute);
  text-align: center;
}
.form-foot a { color: var(--red); font-weight: 600; }

/* ---------- Footer ---------- */
.footer {
  border-top: 1px solid var(--border);
  padding: 28px 0;
  background: var(--bg-2);
}
.footer-inner {
  display: flex;
  flex-direction: column;
  gap: 18px;
  align-items: center;
  text-align: center;
}
.footer-brand {
  display: flex;
  align-items: center;
  gap: 14px;
  color: var(--text-mute);
  font-size: 14px;
}
.footer-brand img { height: 36px; }
.footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 20px;
}
.footer-links a {
  color: var(--text-dim);
  font-size: 14px;
  transition: color var(--t);
}
.footer-links a:hover { color: var(--text); }

/* ---------- Floating call ---------- */
.float-call {
  position: fixed;
  right: 18px;
  bottom: 18px;
  width: 58px; height: 58px;
  background: var(--red);
  color: #fff;
  display: grid;
  place-items: center;
  border-radius: 50%;
  box-shadow: 0 16px 40px rgba(239,68,68,.45);
  z-index: 40;
  animation: float-pulse 2.4s infinite;
}
@keyframes float-pulse {
  0%, 100% { box-shadow: 0 16px 40px rgba(239,68,68,.4), 0 0 0 0 rgba(239,68,68,.5); }
  60%      { box-shadow: 0 16px 40px rgba(239,68,68,.5), 0 0 0 16px rgba(239,68,68,0); }
}

/* ---------- Scroll reveal ---------- */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity .7s var(--ease), transform .7s var(--ease);
  will-change: opacity, transform;
}
.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}
.reveal.delay-1 { transition-delay: .08s; }
.reveal.delay-2 { transition-delay: .16s; }
.reveal.delay-3 { transition-delay: .24s; }

/* ============================================================
   BREAKPOINTS — mobile first
   ============================================================ */

/* ≥ 640px : tablette portrait */
@media (min-width: 640px) {
  .hero-ctas { flex-direction: row; flex-wrap: wrap; }
  .contact-form .row { grid-template-columns: 1fr 1fr; }
  .footer-inner { flex-direction: row; justify-content: space-between; text-align: left; }
}

/* ≥ 820px : tablette paysage */
@media (min-width: 820px) {
  .section { padding: 96px 0; }
  .services-grid { grid-template-columns: repeat(3, 1fr); }
  .reviews-grid  { grid-template-columns: repeat(3, 1fr); }
  .about-grid    { grid-template-columns: 1.15fr .85fr; gap: 48px; }
  .contact-grid  { grid-template-columns: 1fr 1fr; gap: 48px; }
  .float-call    { display: none; }
}

/* ≥ 980px : desktop */
@media (min-width: 980px) {
  :root { --header-h: 76px; }
  .nav { display: flex; align-items: center; gap: 6px; }
  .header-cta { display: inline-flex; }
  .menu-toggle { display: none; }
  .hero { padding: 56px 0 96px; }
  .hero-inner { grid-template-columns: 1.25fr .75fr; gap: 56px; }
}

/* ≥ 1200px : large desktop */
@media (min-width: 1200px) {
  .container { padding: 0 32px; }
}
