/* Mise en page : colonne de 1160px en bandes horizontales ; hero asymétrique
   (texte à gauche, navigateur + téléphone posés sur deux cercles mauves, comme sur la bannière).
   Couleurs relevées sur le logo : prune des lettres, mauve du slogan, rose de l'arabesque.
   Thème clair uniquement, fidèle à l'identité visuelle. */
:root {
  --paper: #F8F3F0;
  --surface: #FFFCFA;
  --surface-2: #F1E8E6;
  --blush: #EADDE2;
  --ink: #251F2A;
  --ink-soft: #64576A;
  --line: #E4D8D8;
  --mauve: #634F63;
  --mauve-hover: #4D3C4D;
  --rose: #8E7985;
  --on-mauve: #FFFCFA;
  --signal: #4F8A6E;

  /* maquettes dessinées en CSS */
  --chrome: #F1E8E6;
  --bezel: #251F2A;
  --mock-line: #ECE2E2;
  --mock-strong: #4A3F4E;
  --shadow: 0 30px 60px -30px rgba(37, 31, 42, 0.32);

  /* bande contact */
  --band: #251F2A;
  --band-panel: #2E2634;
  --band-field: #251F2A;
  --band-fg: #F8F3F0;
  --band-soft: #C4B5C2;
  --band-line: #463A4B;
  --band-accent: #E2CCD8;
  --band-accent-hover: #EEDDE6;
  --band-accent-ink: #251F2A;
  --band-ok: #A8DCC2;
  --band-error: #F4AFA6;

  --font-display: "Cormorant Garamond", "Cormorant", Garamond, "Times New Roman", serif;
  --font-brand: "Cinzel", "Cormorant Garamond", "Times New Roman", serif;
  --font-body: "Jost", "Segoe UI", system-ui, -apple-system, sans-serif;

  --wrap: 1160px;
  --radius: 18px;
  color-scheme: light;
}

/* ---------- Base ---------- */

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 92px;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

/* bande au-dessus de l'en-tête collant (encoches des téléphones) */
body::before {
  content: "";
  position: fixed;
  inset: 0 0 auto;
  height: env(safe-area-inset-top, 0px);
  z-index: 60;
  background: var(--paper);
}

img, svg { display: block; max-width: 100%; }
a { color: inherit; }
p { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }

h1, h2, h3 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 500;
  line-height: 1.05;
  text-wrap: balance;
}

h1 {
  font-size: clamp(2.75rem, 1.6rem + 4vw, 4.75rem);
  letter-spacing: -0.015em;
  line-height: 1;
}
h1 em, h2 em { color: var(--mauve); font-style: italic; }

h2 {
  font-size: clamp(2.125rem, 1.4rem + 2.6vw, 3.25rem);
  letter-spacing: -0.01em;
}

h3 {
  font-size: 1.5rem;
  font-weight: 600;
  line-height: 1.2;
}

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

.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
}

.skip-link {
  position: fixed;
  left: max(16px, env(safe-area-inset-left, 0px));
  top: -100px;
  z-index: 100;
  padding: 10px 16px;
  border-radius: 8px;
  background: var(--mauve);
  color: var(--on-mauve);
  font-weight: 500;
  text-decoration: none;
}
.skip-link:focus { top: calc(12px + env(safe-area-inset-top, 0px)); }

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-left: max(20px, env(safe-area-inset-left, 0px));
  padding-right: max(20px, env(safe-area-inset-right, 0px));
}

/* Étoile à quatre branches du logo */
.star { width: 12px; height: 12px; flex: none; fill: var(--rose); }

/* ---------- Boutons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5em;
  min-height: 50px;
  padding: 0 1.6rem;
  border: 1.5px solid var(--mauve);
  border-radius: 999px;
  background: var(--mauve);
  color: var(--on-mauve);
  font: 500 1rem/1 var(--font-body);
  letter-spacing: 0.02em;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.2s, border-color 0.2s, color 0.2s, transform 0.2s;
}
.btn:hover { background: var(--mauve-hover); border-color: var(--mauve-hover); }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: 0.6; cursor: progress; }

.btn-ghost {
  background: transparent;
  border-color: var(--rose);
  color: var(--ink);
}
.btn-ghost:hover { background: var(--surface); border-color: var(--mauve); }

.btn-small { min-height: 42px; padding: 0 1.2rem; font-size: 0.9375rem; }

/* ---------- En-tête ---------- */

.site-header {
  position: sticky;
  top: env(safe-area-inset-top, 0px);
  z-index: 50;
  background: var(--paper);
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s;
}
.site-header.is-scrolled,
.site-header.is-open { border-bottom-color: var(--line); }

.header-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 24px;
  min-height: 78px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}
.brand-logo { width: auto; height: 46px; }
.brand-text { display: grid; gap: 3px; }
.brand-name {
  font-family: var(--font-brand);
  font-size: 1.0625rem;
  font-weight: 400;
  letter-spacing: 0.2em;
  line-height: 1.1;
  text-transform: uppercase;
}
.brand-tagline {
  color: var(--mauve);
  font-size: 0.625rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  line-height: 1.2;
  text-transform: uppercase;
}
@media (max-width: 420px) {
  .brand-tagline { display: none; }
  .brand-logo { height: 40px; }
}

.site-nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 28px;
}
.site-nav ul { display: flex; flex-wrap: wrap; gap: 4px 26px; }
.site-nav ul a {
  display: block;
  padding-block: 6px;
  color: var(--ink-soft);
  font-size: 0.9375rem;
  font-weight: 500;
  text-decoration: none;
  transition: color 0.2s;
}
.site-nav ul a:hover { color: var(--mauve); }

.nav-toggle { display: none; }

@media (max-width: 980px) {
  .js .nav-toggle {
    display: inline-grid;
    place-items: center;
    width: 44px;
    height: 44px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: var(--surface);
    color: var(--ink);
    cursor: pointer;
  }

  .nav-toggle-bars,
  .nav-toggle-bars::before,
  .nav-toggle-bars::after {
    display: block;
    width: 18px;
    height: 1.5px;
    border-radius: 2px;
    background: currentColor;
    transition: transform 0.2s, background-color 0.2s;
  }
  .nav-toggle-bars { position: relative; }
  .nav-toggle-bars::before,
  .nav-toggle-bars::after { content: ""; position: absolute; left: 0; }
  .nav-toggle-bars::before { top: -6px; }
  .nav-toggle-bars::after { top: 6px; }
  .is-open .nav-toggle-bars { background: transparent; }
  .is-open .nav-toggle-bars::before { transform: translateY(6px) rotate(45deg); }
  .is-open .nav-toggle-bars::after { transform: translateY(-6px) rotate(-45deg); }

  .js .site-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 16px;
    padding-block: 4px 20px;
    padding-left: max(20px, env(safe-area-inset-left, 0px));
    padding-right: max(20px, env(safe-area-inset-right, 0px));
    background: var(--paper);
    border-bottom: 1px solid var(--line);
  }
  .js .site-header.is-open .site-nav { display: flex; }
  .js .site-nav ul { flex-direction: column; gap: 0; }
  .js .site-nav ul a {
    padding-block: 14px;
    border-bottom: 1px solid var(--line);
    color: var(--ink);
    font-size: 1.0625rem;
  }
  .js .site-nav .btn { min-height: 50px; }
}

/* ---------- Hero ---------- */

.hero {
  overflow: hidden;
  padding-block: clamp(32px, 6vw, 96px) clamp(40px, 8vw, 112px);
}

.hero-inner {
  display: grid;
  align-items: center;
  gap: clamp(56px, 6vw, 72px);
}
@media (min-width: 920px) {
  .hero-inner { grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); }
}

.hero-text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 26px;
  min-width: 0;
}

.status {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 7px 16px 7px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--ink-soft);
  font-size: 0.875rem;
  font-weight: 500;
  line-height: 1.2;
}
.status-dot {
  width: 8px;
  height: 8px;
  flex: none;
  border-radius: 50%;
  background: var(--signal);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--signal) 20%, transparent);
}

.lead {
  max-width: 33em;
  color: var(--ink-soft);
  font-size: clamp(1.0625rem, 1rem + 0.35vw, 1.25rem);
}

.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }
@media (max-width: 480px) {
  .hero-actions { flex-direction: column; align-self: stretch; }
}

.hero-facts {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 22px;
  color: var(--ink-soft);
  font-size: 0.8125rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.hero-facts li { display: inline-flex; align-items: center; gap: 9px; }
.hero-facts .star { width: 9px; height: 9px; }

/* Composition navigateur + téléphone. Toutes les cotes sont en cqw
   (pourcentage de la largeur du bloc) pour que le dessin garde ses proportions. */
.hero-visual {
  position: relative;
  isolation: isolate;
  container-type: inline-size;
  width: 100%;
  max-width: 600px;
  aspect-ratio: 100 / 77;
  justify-self: start;
}
@media (min-width: 920px) { .hero-visual { justify-self: end; } }

.hero-visual::before,
.hero-visual::after {
  content: "";
  position: absolute;
  z-index: -1;
  aspect-ratio: 1;
  border-radius: 50%;
}
.hero-visual::before { width: 64cqw; right: 2cqw; top: -8cqw; background: var(--blush); }
.hero-visual::after { width: 38cqw; left: -5cqw; bottom: 1cqw; background: var(--surface-2); }

.device-browser { position: absolute; left: 0; top: 0; width: 88cqw; }
.device-phone { position: absolute; right: 0; bottom: 0; width: 29cqw; }

.dim {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--ink-soft);
  font-size: 0.75rem;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.08em;
  line-height: 1;
  white-space: nowrap;
}
.dim::before { content: ""; width: 22px; height: 1px; background: var(--rose); }
.dim-browser { left: 0; top: 64cqw; }
.dim-phone { right: 32cqw; bottom: 0; }

/* Navigateur */
.browser {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface);
  box-shadow: var(--shadow);
}
.browser-bar {
  display: flex;
  align-items: center;
  gap: 1.1cqw;
  height: 5.5cqw;
  padding-inline: 2.4cqw;
  background: var(--chrome);
  border-bottom: 1px solid var(--line);
}
.browser-bar > span:not(.browser-url) {
  width: 1.5cqw;
  height: 1.5cqw;
  border-radius: 50%;
  background: var(--rose);
  opacity: 0.45;
}
.browser-url {
  flex: 0 1 55%;
  min-width: 0;
  margin-left: 2.4cqw;
  padding-inline: 1.6cqw;
  overflow: hidden;
  border-radius: 1cqw;
  background: var(--surface);
  color: var(--ink-soft);
  font: 500 clamp(0.5rem, 1.9cqw, 0.75rem)/3.4cqw var(--font-body);
  letter-spacing: 0.02em;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.browser-screen {
  display: flex;
  flex-direction: column;
  gap: 3.5cqw;
  aspect-ratio: 16 / 10;
  padding: 3.5cqw 4.5cqw;
  overflow: hidden;
}

/* Traits de maquette */
.ln {
  display: block;
  width: var(--w, 100%);
  height: 1.1cqw;
  border-radius: 99px;
  background: var(--mock-line);
}
.ln-strong { height: 1.4cqw; background: var(--mock-strong); }
.ln-thin { height: 0.9cqw; }
.ln-xl { height: 2.6cqw; background: var(--mock-strong); }
.ln-inv { background: var(--on-mauve); opacity: 0.9; }
.ln-inv.ln-thin { opacity: 0.55; }

.mock-nav { display: flex; align-items: center; justify-content: space-between; gap: 3cqw; }
.mock-logo { width: 7cqw; height: 2cqw; border-radius: 0.6cqw; background: var(--mock-strong); }
.mock-links { display: flex; flex: 0 1 40%; gap: 2.4cqw; }
.mock-links .ln { flex: 1; }
.mock-cta { width: 8cqw; height: 2.6cqw; border: 1px solid var(--mauve); border-radius: 99px; }

.mock-hero { display: grid; grid-template-columns: 1.1fr 1fr; align-items: center; gap: 4cqw; }
.mock-copy { display: flex; flex-direction: column; gap: 1.5cqw; }
.mock-btn {
  width: 12cqw;
  height: 3.6cqw;
  margin-top: 1.2cqw;
  border-radius: 99px;
  background: var(--mauve);
}
.mock-img {
  position: relative;
  overflow: hidden;
  aspect-ratio: 4 / 3;
  border-radius: 1.4cqw;
  background: var(--blush);
}
.mock-img::before {
  content: "";
  position: absolute;
  top: 16%;
  right: 14%;
  width: 40%;
  aspect-ratio: 1;
  border-radius: 50%;
  background: var(--rose);
}
.mock-img::after {
  content: "";
  position: absolute;
  left: -10%;
  right: -10%;
  bottom: -32%;
  height: 62%;
  border-radius: 50% 50% 0 0;
  background: var(--surface);
  opacity: 0.7;
}
.mock-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2.4cqw; }
.mock-cards span {
  height: 8cqw;
  border: 1px solid var(--mock-line);
  border-radius: 1.2cqw;
  background: var(--surface-2);
}

/* Téléphone */
.phone {
  position: relative;
  aspect-ratio: 9 / 19.5;
  padding: 1.1cqw;
  border-radius: 4.6cqw;
  background: var(--bezel);
  box-shadow: var(--shadow);
}
.phone-island {
  position: absolute;
  top: 2.2cqw;
  left: 50%;
  z-index: 1;
  width: 8cqw;
  height: 2.2cqw;
  border-radius: 99px;
  background: var(--bezel);
  transform: translateX(-50%);
}
.phone-screen {
  display: flex;
  flex-direction: column;
  gap: 2cqw;
  height: 100%;
  padding: 6cqw 2.4cqw 0;
  overflow: hidden;
  border-radius: 3.6cqw;
  background: var(--surface);
}
.app-head { display: flex; align-items: center; justify-content: space-between; }
.app-avatar { width: 3.6cqw; height: 3.6cqw; border-radius: 50%; background: var(--blush); }
.app-card {
  display: flex;
  flex-direction: column;
  gap: 1.3cqw;
  padding: 2.2cqw;
  border-radius: 2cqw;
  background: var(--mauve);
}
.app-card-chip {
  width: 7cqw;
  height: 2.6cqw;
  margin-top: 2.4cqw;
  border-radius: 99px;
  background: var(--on-mauve);
  opacity: 0.9;
}
.app-chips { display: flex; gap: 1.2cqw; }
.app-chips span { width: 5.5cqw; height: 2.4cqw; border: 1px solid var(--mock-line); border-radius: 99px; }
.app-chips .on { border-color: transparent; background: var(--blush); }
.app-row { display: flex; align-items: center; gap: 1.8cqw; }
.app-thumb { flex: none; width: 5cqw; height: 5cqw; border-radius: 1.2cqw; background: var(--surface-2); }
.app-lines { display: flex; flex: 1; flex-direction: column; gap: 1cqw; }
.app-tabbar {
  display: flex;
  justify-content: space-around;
  align-items: center;
  height: 7cqw;
  margin-top: auto;
  margin-inline: -2.4cqw;
  border-top: 1px solid var(--mock-line);
}
.app-tabbar span { width: 2.4cqw; height: 2.4cqw; border-radius: 0.7cqw; background: var(--mock-line); }
.app-tabbar .on { background: var(--mauve); }

/* ---------- Sections ---------- */

.section { padding-block: clamp(72px, 9vw, 120px); }
.section > .wrap { display: grid; gap: clamp(36px, 5vw, 56px); }
.section-alt { background: var(--surface); border-block: 1px solid var(--line); }

.section-head { display: grid; gap: 18px; max-width: 46rem; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--mauve);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  line-height: 1.2;
  text-transform: uppercase;
}
.eyebrow::before { content: ""; width: 28px; height: 1px; background: var(--rose); }

.section-intro { max-width: 38em; color: var(--ink-soft); font-size: 1.125rem; }
.section-intro a,
.text-link { color: var(--mauve); font-weight: 500; text-underline-offset: 4px; }
.text-link:hover { color: var(--mauve-hover); }

.tags { display: flex; flex-wrap: wrap; gap: 8px; }
.tags li {
  padding: 6px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--paper);
  color: var(--ink-soft);
  font-size: 0.8125rem;
  font-weight: 500;
  line-height: 1.2;
}

/* Services : grille séparée par des filets */
.services-grid {
  display: grid;
  gap: 1px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--line);
}
@media (min-width: 720px) {
  .services-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.service {
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-width: 0;
  padding: clamp(24px, 3.5vw, 40px);
  background: var(--surface);
}
.service-icon {
  width: 46px;
  height: 46px;
  margin-bottom: 6px;
  padding: 11px;
  border-radius: 50%;
  background: var(--blush);
  color: var(--mauve);
}
.service p { color: var(--ink-soft); }
.service .tags { margin-top: auto; padding-top: 6px; }

/* Méthode : frise verticale sur mobile, horizontale sur grand écran */
.steps { display: grid; gap: 36px; }
.step {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-width: 0;
  padding-left: 30px;
}
.step::before {
  content: "";
  position: absolute;
  left: 5px;
  top: 18px;
  bottom: -36px;
  width: 1px;
  background: var(--rose);
  opacity: 0.6;
}
.step:last-child::before { display: none; }
.step::after {
  content: "";
  position: absolute;
  left: 0;
  top: 3px;
  width: 11px;
  height: 11px;
  border: 1.5px solid var(--mauve);
  border-radius: 50%;
  background: var(--surface);
}
@media (min-width: 880px) {
  .steps { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 32px; }
  .step { padding-left: 0; padding-top: 34px; }
  .step::before { left: 18px; right: -32px; top: 5px; bottom: auto; width: auto; height: 1px; }
  .step::after { top: 0; }
}
.step-num {
  color: var(--mauve);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}
.step p { color: var(--ink-soft); }
.step .step-meta {
  margin-top: auto;
  padding-top: 4px;
  color: var(--ink);
  font-size: 0.875rem;
  font-weight: 500;
}

/* Projets */
.projects { display: grid; gap: 24px; }
@media (min-width: 1024px) {
  .projects { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
.project {
  display: flex;
  flex-direction: column;
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  transition: transform 0.25s, box-shadow 0.25s;
}
.project:hover { transform: translateY(-3px); box-shadow: var(--shadow); }

.thumb {
  position: relative;
  container-type: inline-size;
  aspect-ratio: 4 / 3;
  max-width: 100%;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
  background: var(--blush);
}
.thumb::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 16%;
  width: 72%;
  aspect-ratio: 1;
  border-radius: 50%;
  background: var(--paper);
  opacity: 0.6;
  transform: translateX(-50%);
}
/* Vraies captures : images détourées posées sur le fond mauve et son cercle */
.thumb-img img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center bottom;
}

.project-body { display: flex; flex: 1; flex-direction: column; gap: 12px; padding: 24px; }
.project-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 12px; }
.project-type {
  color: var(--mauve);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
.badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 4px 11px;
  border-radius: 999px;
  background: var(--surface-2);
  color: var(--ink-soft);
  font-size: 0.75rem;
  font-weight: 500;
  line-height: 1.3;
}
.badge::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--rose); }
.badge-live::before { background: var(--signal); }
.project h3 { font-size: 1.75rem; }
.project-desc { color: var(--ink-soft); }
.project-foot { display: grid; gap: 14px; margin-top: auto; padding-top: 4px; }
.project-links { display: flex; flex-wrap: wrap; gap: 6px 18px; font-size: 0.9375rem; }
.project-soon { color: var(--ink-soft); font-size: 0.9375rem; }

/* Tablette : une carte par ligne, visuel à gauche et texte à droite */
@media (min-width: 640px) and (max-width: 1023px) {
  .project { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); }
  .thumb {
    aspect-ratio: auto;
    min-height: 280px;
    border-bottom: 0;
    border-right: 1px solid var(--line);
  }
  .project-body { padding: 28px; }
}

/* À propos */
.about { display: grid; gap: 40px; }
@media (min-width: 900px) {
  .about { grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); align-items: start; gap: 72px; }
}
.about-text { display: grid; gap: 18px; max-width: 38em; }
.about-text > p:not(.eyebrow) { color: var(--ink-soft); font-size: 1.125rem; }
.about-text > p.about-first { color: var(--ink); }

.fiche {
  margin: 0;
  padding: 6px 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
}
.fiche > div {
  display: grid;
  grid-template-columns: 7rem minmax(0, 1fr);
  gap: 16px;
  padding-block: 14px;
  border-bottom: 1px solid var(--line);
}
.fiche > div:last-child { border-bottom: 0; }
.fiche dt {
  padding-top: 3px;
  color: var(--mauve);
  font-size: 0.6875rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  line-height: 1.8;
  text-transform: uppercase;
}
.fiche dd { margin: 0; font-weight: 500; }

.stack { display: grid; gap: 24px; }
.stack-grid { display: grid; gap: 28px 32px; }
@media (min-width: 560px) { .stack-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 980px) { .stack-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.stack-group { display: grid; align-content: start; gap: 14px; padding-top: 16px; border-top: 1px solid var(--line); }
.stack-label { font-weight: 600; }

/* FAQ */
@media (min-width: 900px) {
  .section > .wrap.faq { grid-template-columns: minmax(0, 1fr) minmax(0, 1.9fr); gap: 72px; }
  .faq .section-head { position: sticky; top: 108px; align-self: start; }
}
.faq-list { border-top: 1px solid var(--line); }
.faq-item { border-bottom: 1px solid var(--line); }
.faq-item summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding-block: 22px;
  font-family: var(--font-display);
  font-size: 1.4375rem;
  font-weight: 600;
  line-height: 1.25;
  list-style: none;
  cursor: pointer;
  transition: color 0.2s;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: "+";
  flex: none;
  color: var(--mauve);
  font: 300 1.75rem/1 var(--font-body);
  transition: transform 0.2s;
}
.faq-item[open] summary::after { transform: rotate(45deg); }
.faq-item summary:hover { color: var(--mauve); }
.faq-item p { max-width: 40em; padding-bottom: 24px; color: var(--ink-soft); }

/* ---------- Contact ---------- */

.contact {
  padding-block: clamp(72px, 9vw, 120px);
  background: var(--band);
  color: var(--band-fg);
  color-scheme: dark;
}
.contact-inner { display: grid; gap: 48px; }
@media (min-width: 900px) {
  .contact-inner { grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); align-items: start; gap: 72px; }
}
.contact .eyebrow { color: var(--band-accent); }
.contact .eyebrow::before { background: var(--band-accent); }
.contact h2 em { color: var(--band-accent); }
.contact-text { display: grid; align-content: start; gap: 18px; min-width: 0; }
.contact-text > p:not(.eyebrow) { max-width: 30em; color: var(--band-soft); font-size: 1.125rem; }

.contact-direct {
  display: grid;
  gap: 14px;
  margin-top: 12px;
  padding-top: 24px;
  border-top: 1px solid var(--band-line);
}
.contact-label {
  color: var(--band-soft);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}
.contact-lines { display: grid; gap: 10px; }
.contact-line { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; }
.contact-value {
  min-width: 0;
  color: var(--band-fg);
  font-size: clamp(1.125rem, 1rem + 0.5vw, 1.3125rem);
  font-weight: 500;
  text-decoration: underline;
  text-decoration-color: var(--band-line);
  text-decoration-thickness: 1px;
  text-underline-offset: 6px;
  overflow-wrap: anywhere;
  transition: text-decoration-color 0.2s;
}
.contact-value:hover { text-decoration-color: var(--band-accent); }
.contact-line svg { width: 20px; height: 20px; flex: none; color: var(--band-accent); }
.btn-copy {
  padding: 7px 14px;
  border: 1px solid var(--band-line);
  border-radius: 999px;
  background: transparent;
  color: var(--band-fg);
  font: 500 0.8125rem/1 var(--font-body);
  cursor: pointer;
  transition: border-color 0.2s;
}
.btn-copy:hover { border-color: var(--band-soft); }
.contact :focus-visible { outline-color: var(--band-accent); }

.socials { display: flex; flex-wrap: wrap; gap: 8px 22px; margin-top: 4px; }
.socials a {
  color: var(--band-soft);
  font-weight: 500;
  text-decoration: none;
  transition: color 0.2s;
}
.socials a::after { content: " ↗"; }
.socials a:hover { color: var(--band-fg); }

.contact-form {
  display: grid;
  gap: 18px;
  min-width: 0;
  padding: clamp(22px, 3.5vw, 36px);
  border: 1px solid var(--band-line);
  border-radius: var(--radius);
  background: var(--band-panel);
}
.field-row { display: grid; gap: 18px; }
@media (min-width: 560px) { .field-row { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.field { display: grid; gap: 8px; min-width: 0; }
.field label { font-size: 0.9375rem; font-weight: 500; }
.field .optional { color: var(--band-soft); font-weight: 400; }
.field input,
.field select,
.field textarea {
  width: 100%;
  min-height: 48px;
  padding: 12px 14px;
  border: 1px solid var(--band-line);
  border-radius: 12px;
  background: var(--band-field);
  color: var(--band-fg);
  font: inherit;
  font-size: 1rem;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.field textarea { min-height: 150px; resize: vertical; }
.field input::placeholder,
.field textarea::placeholder { color: var(--band-soft); opacity: 0.8; }
.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--band-accent);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--band-accent) 28%, transparent);
}

.form-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; }
@media (max-width: 480px) {
  .form-foot .btn { width: 100%; }
}
.form-note { max-width: 26em; color: var(--band-soft); font-size: 0.8125rem; }
.form-note a { color: var(--band-fg); text-underline-offset: 3px; }
.contact .btn { border-color: var(--band-accent); background: var(--band-accent); color: var(--band-accent-ink); }
.contact .btn:hover { border-color: var(--band-accent-hover); background: var(--band-accent-hover); }
.form-status { min-height: 1.6em; color: var(--band-soft); font-size: 0.9375rem; }
.form-status:empty { display: none; }
.form-status[data-state="ok"] { color: var(--band-ok); }
.form-status[data-state="error"] { color: var(--band-error); }

/* Confirmation d'envoi : remplace le contenu du formulaire */
.contact-form.is-sent > :not(.form-success) { display: none; }
.form-success {
  display: grid;
  justify-items: start;
  gap: 14px;
  padding-block: 12px;
  outline: none;
  animation: success-in 0.45s ease-out;
}
.form-success[hidden] { display: none; }
.form-success-icon {
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: color-mix(in srgb, var(--band-ok) 16%, transparent);
  color: var(--band-ok);
}
.form-success-icon svg { width: 28px; height: 28px; }
.form-success-title { color: var(--band-fg); font-size: 2rem; }
.form-success p { max-width: 32em; color: var(--band-soft); font-size: 1.0625rem; }
.form-success .btn-copy { margin-top: 6px; }
@keyframes success-in {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: none; }
}

/* ---------- Pied de page ---------- */

.site-footer {
  padding-block: 48px 32px;
  color: var(--ink-soft);
  font-size: 0.9375rem;
}
.footer-inner { display: grid; gap: 32px; }
.footer-top { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px 40px; }
.footer-brand { display: flex; align-items: center; gap: 14px; text-decoration: none; color: var(--ink); }
.footer-brand .brand-logo { height: 58px; }
.footer-links { display: flex; flex-wrap: wrap; gap: 8px 24px; }
.footer-links a { font-weight: 500; text-decoration: none; transition: color 0.2s; }
.footer-links a:hover { color: var(--mauve); }
.footer-rule { display: flex; align-items: center; gap: 14px; }
.footer-rule::before,
.footer-rule::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.footer-legal { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 24px; font-size: 0.8125rem; }

/* ---------- Bouton flottant « haut de page » ---------- */

.to-top {
  position: fixed;
  right: max(20px, calc(env(safe-area-inset-right, 0px) + 12px));
  bottom: max(20px, calc(env(safe-area-inset-bottom, 0px) + 12px));
  z-index: 40;
  display: grid;
  place-items: center;
  width: 50px;
  height: 50px;
  border: 1px solid color-mix(in srgb, var(--on-mauve) 28%, transparent);
  border-radius: 50%;
  background: var(--mauve);
  color: var(--on-mauve);
  box-shadow: 0 12px 28px -10px rgba(37, 31, 42, 0.55);
  opacity: 0;
  visibility: hidden;
  transform: translateY(12px);
  transition: opacity 0.25s, transform 0.25s, visibility 0.25s, background-color 0.2s;
}
.to-top.is-visible { opacity: 1; visibility: visible; transform: none; }
.to-top:hover { background: var(--mauve-hover); }
.to-top svg { width: 22px; height: 22px; }

/* ---------- Mentions légales ---------- */

.section > .wrap.legal { max-width: calc(48rem + 40px); gap: 32px; }
.legal h1 { font-size: clamp(2.5rem, 1.8rem + 2.4vw, 3.5rem); }
.legal-updated { color: var(--ink-soft); font-size: 0.875rem; }
.legal section { display: grid; gap: 10px; padding-top: 24px; border-top: 1px solid var(--line); }
.legal h2 { font-size: 1.75rem; font-weight: 600; }
.legal p:not(.eyebrow), .legal li { color: var(--ink-soft); }
.legal strong { color: var(--ink); font-weight: 500; }
.legal ul { display: grid; gap: 4px; padding-left: 1.25rem; list-style: disc; }
.legal a { color: var(--mauve); text-underline-offset: 3px; }

/* ---------- Mouvement réduit ---------- */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
  .project:hover { transform: none; }
}
