/* ============================================================
   BAMEK TECHNOLOGIES — design system
   Space Grotesk (display) / IBM Plex Sans (texte) / IBM Plex Mono (labels)
   ============================================================ */

:root {
  --ink: #101d2c;
  --ink-2: #1c3350;
  --ink-3: #2c4a6b;
  --teal: #3f7f96;
  --teal-2: #5a9cb1;
  --teal-soft: #9fc4d1;
  --teal-tint: #eaf2f4;
  --bg: #fbfcfc;
  --surface: #ffffff;
  --border: #e2e8ec;
  --muted: #5b6b7c;
  --muted-2: #8494a3;
  --danger: #b8493f;

  --font-display: "Space Grotesk", "IBM Plex Sans", sans-serif;
  --font-body: "IBM Plex Sans", sans-serif;
  --font-mono: "IBM Plex Mono", monospace;

  --radius: 16px;
  --radius-sm: 10px;
  --shadow-sm: 0 1px 2px rgba(16, 29, 44, .06);
  --shadow-md: 0 8px 24px rgba(16, 29, 44, .08);
  --shadow-lg: 0 24px 64px rgba(16, 29, 44, .14);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--bg);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.15;
  margin: 0 0 .5em;
  letter-spacing: -.01em;
}
h1 { font-size: clamp(2.1rem, 4.2vw, 3.4rem); }
h2 { font-size: clamp(1.5rem, 2.6vw, 2.1rem); }
h3 { font-size: 1.2rem; font-weight: 600; }
p { margin: 0 0 1em; color: var(--muted); }
a { color: inherit; text-decoration: none; }
ul { margin: 0; padding: 0; list-style: none; }
img { max-width: 100%; display: block; }
button { font-family: inherit; cursor: pointer; }

::selection { background: var(--teal-soft); color: var(--ink); }

:focus-visible {
  outline: 2px solid var(--teal);
  outline-offset: 3px;
  border-radius: 4px;
}

.wrap {
  max-width: 1160px;
  margin-inline: auto;
  padding-inline: 24px;
}

/* ---------- Eyebrow / labels ---------- */
.eyebrow {
  font-family: var(--font-mono);
  font-size: .75rem;
  font-weight: 500;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--teal);
  margin: 0 0 .9em;
  display: flex;
  align-items: center;
  gap: .6em;
}
.eyebrow::before {
  content: "";
  width: 22px; height: 1px;
  background: var(--teal);
  display: inline-block;
}

.lead {
  font-size: 1.0625rem;
  color: var(--muted);
  max-width: 56ch;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: .5em;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: .9375rem;
  padding: .85em 1.5em;
  border-radius: 999px;
  border: 1px solid transparent;
  transition: transform .15s ease, background .2s ease, border-color .2s ease, color .2s ease, box-shadow .2s ease;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary {
  background: var(--ink);
  color: #fff;
  box-shadow: var(--shadow-sm);
}
.btn-primary:hover { background: var(--ink-2); box-shadow: var(--shadow-md); }
.btn-ghost {
  background: transparent;
  border-color: var(--border);
  color: var(--ink);
}
.btn-ghost:hover { border-color: var(--ink); background: var(--surface); }

/* ============================================================
   HEADER
   ============================================================ */
header {
  position: sticky; top: 0; z-index: 50;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
}
header .wrap {
  display: flex; align-items: center; justify-content: space-between;
  height: 76px;
}
.brand img { height: 32px; width: auto; }
.nav-links {
  display: flex; align-items: center; gap: 2.25rem;
}
.nav-links a {
  font-size: .9375rem; font-weight: 500; color: var(--muted);
  transition: color .2s ease;
  position: relative;
}
.nav-links a:hover, .nav-links a[aria-current="page"] { color: var(--ink); }
.nav-links a[aria-current="page"]::after {
  content: "";
  position: absolute; left: 0; right: 0; bottom: -26px;
  height: 2px; background: var(--teal);
}
.nav-links a.nav-cta {
  background: var(--ink); color: #fff;
  padding: .6em 1.3em; border-radius: 999px;
  font-weight: 600;
}
.nav-links a.nav-cta:hover { background: var(--ink-2); }
.nav-links a.nav-cta[aria-current="page"]::after { display: none; }

.burger {
  display: none;
  flex-direction: column; justify-content: center; gap: 5px;
  width: 40px; height: 40px;
  background: none; border: none; padding: 0;
}
.burger span {
  display: block; width: 22px; height: 2px; background: var(--ink);
  transition: transform .25s ease, opacity .25s ease;
  margin-inline: auto;
}
.burger[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.burger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.burger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

@media (max-width: 860px) {
  .nav-links {
    position: fixed; inset: 76px 0 0 0;
    z-index: 60;
    background: var(--surface);
    flex-direction: column; align-items: stretch;
    padding: 2rem 24px;
    gap: 0;
    transform: translateY(-8px);
    opacity: 0;
    pointer-events: none;
    transition: opacity .2s ease, transform .2s ease;
  }
  .nav-links.open { opacity: 1; transform: translateY(0); pointer-events: auto; }
  .nav-links a {
    padding: 1.1em 0;
    border-bottom: 1px solid var(--border);
    font-size: 1.05rem;
  }
  .nav-links a[aria-current="page"]::after { display: none; }
  .nav-links a.nav-cta {
    margin-top: 1.25em; text-align: center;
  }
  .burger { display: flex; }
}

/* ============================================================
   HERO
   ============================================================ */
.hero { padding: 76px 0 64px; overflow: hidden; }
.hero-grid {
  display: grid; grid-template-columns: 1.1fr .9fr;
  gap: 3rem; align-items: center;
}
.hero h1 { margin-bottom: .45em; }
.hero-actions { display: flex; gap: .9rem; flex-wrap: wrap; margin-top: 2rem; }
.hero-visual {
  position: relative;
  display: flex; align-items: center; justify-content: center;
}
.hero-visual canvas {
  width: 100%; height: auto; max-width: 440px;
  aspect-ratio: 1 / 1;
}

@media (max-width: 860px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-visual { order: -1; max-width: 280px; margin-inline: auto; }
  .hero-visual canvas { max-width: 280px; }
}

/* Connector divider */
.connector {
  display: flex; align-items: center; justify-content: center;
  gap: .5rem; padding: 8px 0 40px;
}
.connector .ln { width: 64px; height: 1px; background: var(--border); }
.connector .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--teal); }

/* ============================================================
   SECTIONS (generic)
   ============================================================ */
section { padding: 88px 0; }
.section-head { max-width: 62ch; margin-bottom: 3rem; }
.section-head h2 { margin-bottom: .4em; }

/* ---------- Services grid ---------- */
.services-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 1.5rem;
}
.service-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem 1.75rem;
  position: relative;
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.service-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: hsla(0,0%,0%,0); }
.service-card .num {
  font-family: var(--font-mono);
  font-size: .8125rem; color: var(--teal-soft);
  margin: 0 0 1.1em; font-weight: 500;
}
.service-card svg { width: 30px; height: 30px; margin-bottom: 1.1rem; }
.service-card h3 { margin-bottom: .5em; }
.service-card p { font-size: .9375rem; margin-bottom: 0; }
.service-card ul { margin-top: 1.1rem; display: flex; flex-direction: column; gap: .5em; }
.service-card ul li {
  font-size: .875rem; color: var(--muted);
  padding-left: 1.2em; position: relative;
}
.service-card ul li::before {
  content: "";
  position: absolute; left: 0; top: .55em;
  width: 5px; height: 5px; border-radius: 50%;
  background: var(--teal-soft);
}

@media (max-width: 860px) {
  .services-grid { grid-template-columns: 1fr; }
}

/* ---------- Process (services.html) ---------- */
.process-list {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem;
  counter-reset: step;
}
.process-step { position: relative; padding-left: 0; }
.marker {
  font-family: var(--font-mono);
  color: var(--teal);
  font-size: .875rem;
  border: 1px solid var(--teal-soft);
  border-radius: 50%;
  width: 40px; height: 40px;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 1.1rem;
}
.process-step h3 { margin-bottom: .4em; }
.process-step p { font-size: .9375rem; }

@media (max-width: 860px) {
  .process-list { grid-template-columns: 1fr; gap: 2.25rem; }
}

/* ---------- About page ---------- */
.about-grid {
  display: grid; grid-template-columns: 1.1fr .9fr; gap: 3rem;
}
.about-grid p { font-size: .9688rem; }
.values-list { display: flex; flex-direction: column; gap: 1.4rem; }
.values-list li { display: flex; flex-direction: column; gap: .3em; }
.values-list strong { font-family: var(--font-display); font-size: 1.0625rem; font-weight: 600; }
.values-list span { font-size: .9375rem; color: var(--muted); }

@media (max-width: 860px) {
  .about-grid { grid-template-columns: 1fr; gap: 2.5rem; }
}

/* ---------- Contact page ---------- */
.contact-grid {
  display: grid; grid-template-columns: 1.1fr .9fr; gap: 3rem;
  align-items: start;
}
.contact-grid h2 { font-size: 1.375rem; margin-bottom: .5em; }
.prep-list { margin-top: 1.5rem; display: flex; flex-direction: column; gap: .75em; }
.prep-list li {
  font-size: .9375rem; color: var(--muted);
  padding-left: 1.3em; position: relative;
}
.prep-list li::before {
  content: "";
  position: absolute; left: 0; top: .5em;
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--teal);
}
.contact-links {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 2rem;
  display: flex; flex-direction: column; gap: 1.25rem;
}
.contact-links a {
  display: flex; align-items: center; gap: .8em;
  font-family: var(--font-display); font-size: 1.125rem; font-weight: 600;
  padding: .5em 0;
  transition: color .2s ease;
}
.contact-links a:hover { color: var(--teal); }
.contact-links a svg { width: 22px; height: 22px; flex-shrink: 0; color: var(--teal); }
.contact-note { font-size: .875rem; color: var(--muted-2); }

@media (max-width: 860px) {
  .contact-grid { grid-template-columns: 1fr; gap: 2.5rem; }
}

/* ---------- Contact page : formulaire ---------- */
.contact-wrap { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; align-items: start; }
.contact-info h2 { font-size: 1.5rem; }
.contact-info > .lead { margin-top: .25rem; }
.contact-methods { margin-top: 2.25rem; display: flex; flex-direction: column; gap: .9rem; }
.contact-method {
  display: flex; align-items: center; gap: 1rem;
  padding: 1rem 1.25rem;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.contact-method:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); border-color: var(--teal); }
.contact-method .c-ico {
  width: 2.75rem; height: 2.75rem; border-radius: var(--radius-sm); flex-shrink: 0;
  background: var(--teal-tint); color: var(--teal);
  display: flex; align-items: center; justify-content: center;
}
.contact-method .c-ico svg { width: 22px; height: 22px; }
.contact-method .c-label { font-family: var(--font-mono); font-size: .6875rem; letter-spacing: .12em; text-transform: uppercase; color: var(--muted-2); }
.contact-method .c-value { font-family: var(--font-display); font-size: .9688rem; font-weight: 600; word-break: break-word; }
.contact-method .c-value:hover { color: var(--teal); }
.contact-hint { margin-top: 1.75rem; font-size: .8125rem; color: var(--muted-2); }

.booking-form-card {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem 1.75rem;
  box-shadow: 0 24px 64px rgba(16, 29, 44, .08);
  overflow: hidden;
}
.booking-form-card::before {
  content: "";
  position: absolute; inset: 0 0 auto 0; height: 3px;
  background: linear-gradient(90deg, var(--teal), var(--teal-2), var(--teal-soft));
}
.booking-form-card h3 { font-size: 1.375rem; margin-bottom: 1.5rem; }
.form-fields { display: flex; flex-direction: column; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.form-field { margin-bottom: 1.25rem; }
.form-field label {
  display: block;
  font-family: var(--font-mono); font-size: .6875rem; letter-spacing: .12em; text-transform: uppercase;
  color: var(--muted-2); margin-bottom: .5rem;
}
.form-field input, .form-field select, .form-field textarea {
  width: 100%; padding: .75rem 1rem;
  border: 1px solid var(--border); border-radius: var(--radius-sm);
  background: var(--bg); color: var(--ink); font-family: var(--font-body); font-size: .875rem;
  outline: none; transition: border-color .2s ease, box-shadow .2s ease;
}
.form-field input:focus, .form-field select:focus, .form-field textarea:focus {
  border-color: var(--teal); box-shadow: 0 0 0 3px var(--teal-tint);
}
.form-field textarea { min-height: 120px; resize: vertical; }
.form-actions { display: flex; flex-direction: column; gap: .75rem; margin-top: .5rem; }
.btn-block { width: 100%; }
.wa-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .6rem;
  border: none; cursor: pointer;
  background: #25D366; color: #fff;
  font-family: var(--font-display); font-weight: 600; font-size: .9375rem;
  padding: .9rem 1.25rem; border-radius: 999px;
  transition: background .2s ease, transform .2s ease, box-shadow .2s ease;
}
.wa-btn:hover { background: #1fbd5b; transform: translateY(-1px); box-shadow: 0 8px 24px rgba(37, 211, 102, .3); }
.wa-btn:disabled { opacity: .6; cursor: wait; transform: none; box-shadow: none; }
.wa-btn svg { width: 18px; height: 18px; }
.mail-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .6rem;
  background: transparent; color: var(--teal); border: 1px solid var(--teal);
  font-family: var(--font-display); font-weight: 600; font-size: .9375rem;
  padding: .9rem 1.25rem; border-radius: 999px; cursor: pointer;
  transition: background .2s ease, color .2s ease;
}
.mail-btn:hover { background: var(--teal); color: #fff; }
.mail-btn:disabled { opacity: .6; cursor: wait; }
.form-note { font-size: .75rem; color: var(--muted-2); text-align: center; margin: 0; }

.success-panel { display: none; text-align: center; padding: 2.5rem 1rem; }
.success-panel.show { display: block; animation: fadeUp .6s ease; }
.success-panel .check-circle {
  width: 4rem; height: 4rem; border-radius: 9999px;
  background: var(--teal-tint); color: var(--teal);
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 1.25rem;
}
.success-panel h3 { font-size: 1.375rem; margin-bottom: .5rem; }
.success-panel p { font-size: .9375rem; color: var(--muted); line-height: 1.6; max-width: 30rem; margin-inline: auto; }
.success-panel .wa-btn { margin-top: 1.25rem; }
.success-panel .link-reset {
  display: inline-block; margin-top: 1.25rem;
  background: none; border: none; cursor: pointer;
  font-family: var(--font-body); font-size: .8125rem; color: var(--muted-2);
  text-decoration: underline;
}
.success-panel a.link-reset:hover { color: var(--teal); }
.spinner {
  display: inline-block; width: 1.1rem; height: 1.1rem;
  border: 2px solid hsla(0,0%,100%,.4); border-top-color: #fff;
  border-radius: 9999px; animation: spin .7s linear infinite;
  vertical-align: middle;
}
.spinner-dark { border-color: var(--teal-tint); border-top-color: var(--teal); }

@keyframes fadeUp { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: none; } }
@keyframes spin { to { transform: rotate(360deg); } }

/* Reveal au scroll */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .6s ease, transform .6s ease; }
.reveal.visible { opacity: 1; transform: translateY(0); }
.reveal-d1 { transition-delay: .08s; }
.reveal-d2 { transition-delay: .16s; }

/* Toast */
.toast {
  position: fixed; bottom: 1.5rem; right: 1.5rem; z-index: 100;
  background: var(--ink); color: hsla(150,15%,94%,.95);
  border-radius: var(--radius-sm); padding: 1rem 1.5rem;
  box-shadow: 0 20px 60px -20px rgba(16,29,44,.4);
  font-family: var(--font-body); font-size: .875rem;
  opacity: 0; transform: translateY(12px);
  transition: opacity .3s ease, transform .3s ease;
  pointer-events: none; max-width: 320px;
}
.toast.show { opacity: 1; transform: none; }
.toast strong { display: block; margin-bottom: .25rem; color: #fff; }

@media (max-width: 860px) {
  .contact-wrap { grid-template-columns: 1fr; gap: 2.5rem; }
  .field-row { grid-template-columns: 1fr; }
}

/* ---------- Page hero (sous-pages) ---------- */
.page-hero { padding: 64px 0 56px; }
.page-hero .lead { margin-top: .5rem; }

/* ---------- Legal pages ---------- */
.legal-content { max-width: 72ch; }
.legal-updated {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: .8125rem; color: var(--muted-2);
  margin-bottom: 2.5rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--border);
  width: 100%;
}
.legal-content h2 {
  font-size: 1.125rem; margin-top: 2.25em;
}
.legal-content h2:first-of-type { margin-top: 0; }
.legal-content p, .legal-content li { font-size: .9375rem; }
.legal-content ul { margin: 1em 0; display: flex; flex-direction: column; gap: .5em; }
.legal-content ul li { padding-left: 1.3em; position: relative; }
.legal-content ul li::before {
  content: ""; position: absolute; left: 0; top: .55em;
  width: 5px; height: 5px; border-radius: 50%; background: var(--teal-soft);
}

/* ============================================================
   FOOTER
   ============================================================ */
footer {
  background: var(--ink);
  color: hsla(150, 15%, 94%, .9);
  padding: 72px 0 28px;
  margin-top: 40px;
}
.footer-top {
  display: grid; grid-template-columns: 1fr 2fr; gap: 3rem;
  padding-bottom: 48px;
  border-bottom: 1px solid hsla(0,0%,100%,.1);
}
.footer-brand img { height: 34px; margin-bottom: 1rem; filter: brightness(0) invert(1); }
.footer-brand p { color: hsla(150, 15%, 90%, .62); font-size: .875rem; max-width: 28ch; }
.footer-cols { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; }
.footer-col h4 {
  font-family: var(--font-mono); font-size: .75rem; letter-spacing: .1em; text-transform: uppercase;
  color: hsla(150, 15%, 90%, .5); font-weight: 500; margin-bottom: 1.1em;
}
.footer-col a {
  display: block; font-size: .9375rem;
  color: hsla(150, 15%, 92%, .82);
  padding-block: .4em;
  transition: color .2s ease;
}
.footer-col a:hover { color: #fff; }
.footer-row {
  padding-top: 28px;
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 1rem;
}
.footer-row p { margin: 0; font-size: .8125rem; color: hsla(150, 15%, 90%, .5); }

@media (max-width: 860px) {
  .footer-top { grid-template-columns: 1fr; gap: 2.5rem; }
  .footer-cols { grid-template-columns: 1fr 1fr; gap: 2rem 1rem; }
}
@media (max-width: 520px) {
  .footer-cols { grid-template-columns: 1fr; }
}

/* ============================================================
   UTILITY / RESPONSIVE
   ============================================================ */
@media (max-width: 640px) {
  section { padding: 64px 0; }
  .hero { padding: 48px 0 40px; }
  .wrap { padding-inline: 20px; }
}
