/* ==========================================================================
   Operandi · Géomètres-Experts
   Intégration de la maquette Figma « Page d'attente »
   Mobile first · breakpoints : 768px (tablette) · 1024px (desktop)
   ========================================================================== */

/* ---------- 0. Polices (auto-hébergées, licence SIL OFL) ---------- */
@font-face {
  font-family: "Syne";
  src: url("../fonts/syne-latin-400-normal.woff2") format("woff2");
  font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Syne";
  src: url("../fonts/syne-latin-600-normal.woff2") format("woff2");
  font-weight: 600; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Syne";
  src: url("../fonts/syne-latin-700-normal.woff2") format("woff2");
  font-weight: 700; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Playfair Display";
  src: url("../fonts/playfair-display-latin-600-italic.woff2") format("woff2");
  font-weight: 600; font-style: italic; font-display: swap;
}

/* ---------- 1. Tokens (variables Figma) ---------- */
:root {
  /* Marque */
  --c-primary: #064d4a;          /* marque/primary */
  --c-secondary: #fff3a3;        /* marque/Secondary */
  --c-teal-light: #c0e0d1;       /* Bleu vert */
  --c-accent: #a3d7ce;           /* fond/accent */

  /* Fonds */
  --c-bg: #fcfefe;               /* fond/background */
  --c-bg-muted: #eef4f5;         /* fond/muted */
  --c-bg-dark: #021c1b;          /* footer */
  --c-white: #ffffff;

  /* Textes */
  --c-text: #101d21;             /* texte/foreground */
  --c-text-muted: #546064;       /* texte/muted-foreground */
  --c-text-inverse: #fcfcfc;     /* texte/primary-foreground */

  /* Lignes */
  --c-border: #d1d9db;           /* ligne/border */
  --c-border-2: #a2b2b7;         /* ligne/border 2 */
  --c-border-3: #e0edeb;         /* ligne/border 3 */

  /* Typo */
  --ff-sans: "Syne", system-ui, -apple-system, "Segoe UI", sans-serif;
  --ff-serif: "Playfair Display", Georgia, "Times New Roman", serif;

  /* Tailles fluides : mobile → desktop 1440px */
  --fs-h1: clamp(2.25rem, 1.5rem + 2.36vw, 3.625rem);      /* 36 → 58px */
  --fs-h2: clamp(2rem, 1.25rem + 2.22vw, 3.25rem);        /* 32 → 52px */
  --fs-quote: clamp(1.25rem, 1.1rem + 0.6vw, 1.5rem);     /* 20 → 24px */
  --fs-lead: clamp(1rem, 0.95rem + 0.25vw, 1.125rem);     /* 16 → 18px */
  --fs-h3: 1.125rem;                                      /* 18px */
  --fs-body: 0.9375rem;                                   /* 15px */
  --fs-small: 0.875rem;                                   /* 14px */
  --fs-btn: 0.8125rem;                                    /* 13px */

  /* Espacements */
  --gutter: clamp(20px, 9.65vw, 139px);   /* 139px à 1440px */
  --section-y: clamp(64px, 7vw, 100px);
  --container: 1162px;                    /* 1440 - 2 × 139 */

  --shadow-photo: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

/* ---------- 2. Reset léger ---------- */
*,
*::before,
*::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--c-bg);
  color: var(--c-text);
  font-family: var(--ff-sans);
  font-size: 1rem;
  line-height: 1.3;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, p, ul, figure, blockquote { margin: 0; }
ul[role="list"] { list-style: none; padding: 0; }

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  margin: -1px; padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

img, picture, svg { display: block; max-width: 100%; height: auto; }

a { color: inherit; }

:focus-visible {
  outline: 2px solid var(--c-primary);
  outline-offset: 3px;
}

.skip-link {
  position: absolute;
  top: 8px;
  left: 8px;
  z-index: 100;
  padding: 12px 16px;
  background: var(--c-primary);
  color: var(--c-text-inverse);
  font-weight: 700;
  text-decoration: none;
  transform: translateY(-200%);
}
.skip-link:focus { transform: none; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; }
}

/* ---------- 3. Utilitaires ---------- */
.container {
  width: 100%;
  max-width: calc(var(--container) + 2 * var(--gutter));
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* Mot en italique Playfair dans les titres */
.serif {
  font-family: var(--ff-serif);
  font-style: italic;
  font-weight: 600;
  letter-spacing: 0;
}

/* Motif « Grille thème » : lignes verticales à 0, 1/3 et 2/3 de la largeur */
.theme-grid { position: relative; isolation: isolate; }
.theme-grid::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    linear-gradient(var(--c-border-3), var(--c-border-3)) 0 0 / 1px 100% no-repeat,
    linear-gradient(var(--c-border-3), var(--c-border-3)) 33.33% 0 / 1px 100% no-repeat,
    linear-gradient(var(--c-border-3), var(--c-border-3)) 66.67% 0 / 1px 100% no-repeat;
}

/* Titre de section (H2) */
.title-2 {
  font-size: var(--fs-h2);
  font-weight: 600;
  line-height: 1.08;
  letter-spacing: -0.022em;
}

/* ---------- 4. Bouton ---------- */
.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 51px;
  padding: 12px 16px;
  border: 1px solid var(--c-teal-light);
  background: var(--c-primary);
  color: var(--c-text-inverse);
  font-size: var(--fs-btn);
  font-weight: 700;
  line-height: 1.25;
  text-transform: uppercase;
  text-decoration: none;
  transition: background-color .2s ease;
}
/* Point blanc devant le libellé */
.btn::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: currentColor;
  flex: none;
}
/* Repères de coin (asset Figma « coin », 15 × 15, décalés de 8px) */
.btn::after {
  content: "";
  position: absolute;
  inset: -8px;
  pointer-events: none;
  background:
    url("../img/bouton-coin.svg") left top / 15px 15px no-repeat,
    url("../img/bouton-coin.svg") right top / 15px 15px no-repeat,
    url("../img/bouton-coin.svg") left bottom / 15px 15px no-repeat,
    url("../img/bouton-coin.svg") right bottom / 15px 15px no-repeat;
}
.btn:hover { background: #043b39; }

/* Variante claire (fond jaune), utilisée sur fond vert */
.btn--light {
  border-color: var(--c-white);
  background: var(--c-secondary);
  color: var(--c-primary);
  padding-block: 14px;
}
.btn--light:hover { background: #fff8c9; }

/* ==========================================================================
   5. HERO
   ========================================================================== */
.hero {
  padding: 12px 12px 0;
  background: var(--c-bg);
}

.hero__visual {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: min(760px, 100svh);
  overflow: hidden;
  color: var(--c-text-inverse);
  isolation: isolate;
}

/* Image de fond + dégradés de lisibilité (valeurs Figma) */
.hero__visual > picture,
.hero__img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: -2;
}
.hero__img { object-fit: cover; object-position: 60% center; }
.hero__visual::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(180deg, rgba(4, 11, 13, 0) 55%, rgba(4, 11, 13, .54) 100%),
    linear-gradient(90deg, rgba(4, 11, 13, .54) 0%, rgba(4, 11, 13, 0) 83%);
}

.hero__bar {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  display: flex;
  align-items: center;
  height: 80px;
  padding-inline: 20px;
}
.brand { display: inline-block; }
.brand img { width: 150px; }

.hero__content {
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding: 120px 20px 40px;
}
.hero__content > * { max-width: 682px; }

.kicker {
  color: var(--c-secondary);
  font-size: var(--fs-small);
  font-weight: 600;
  line-height: 1.4;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.hero__title {
  font-size: var(--fs-h1);
  font-weight: 600;
  line-height: 1;
  letter-spacing: -0.01em;
}
.hero__title .serif { display: block; }

.hero__text {
  font-size: var(--fs-lead);
  line-height: 1.3;
}

/* ==========================================================================
   5b. ANNONCE NOUVEAU SITE
   ========================================================================== */
.announce {
  padding: 12px;
  background: var(--c-bg);
}
.announce__inner {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 20px;
  padding: 20px;
  border: 1px solid var(--c-border-3);
  background: var(--c-primary);
  color: var(--c-text-inverse);
}
/* Repères de coin haut-gauche / bas-droite (même asset que les boutons) */
.announce__inner::before,
.announce__inner::after {
  content: "";
  position: absolute;
  width: 15px;
  height: 15px;
  background: url("../img/bouton-coin.svg") center / contain no-repeat;
  pointer-events: none;
}
.announce__inner::before { top: -8px; left: -8px; }
.announce__inner::after { bottom: -8px; right: -8px; }

.announce__text {
  font-size: clamp(1.125rem, 1rem + .55vw, 1.5rem);      /* 18 → 24px */
  font-weight: 600;
  line-height: 1.08;
  letter-spacing: -0.008em;
}
.announce__caps { text-transform: uppercase; }
.announce__text .serif { font-size: 1.375em; }          /* 33 / 24 */

/* ==========================================================================
   6. SECTIONS SPLIT (Expertises / Cabinet)
   ========================================================================== */
.section {
  border-top: 1px solid var(--c-border);
  padding-block: var(--section-y);
  background: var(--c-bg);
}

.split__inner {
  display: grid;
  gap: 56px;
  align-items: center;
}

.split__content {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 32px;
  min-width: 0;
}

/* ---- Collage photos ---- */
.collage {
  position: relative;
  width: 100%;
  max-width: 460px;
  aspect-ratio: 460 / 654;
  margin-inline: auto;
}
.collage__item {
  position: absolute;
  box-shadow: var(--shadow-photo);
  background: var(--c-bg-muted);
}
.collage__item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.collage__item picture { height: 100%; }
/* Positions en % du cadre 460 × 654 de la maquette */
.collage__item--a { left: 0;      top: 0;      width: 70.87%; height: 50%; }     /* 326 × 327 */
.collage__item--b { left: 51.96%; top: 18.35%; width: 48.04%; height: 38.23%; }  /* 221 × 250 */
.collage__item--c { left: 12.83%; top: 45.18%; width: 62.39%; height: 55.5%; }   /* 287 × 363 */

/* ---- Domaines d'expertise ---- */
.domains {
  display: grid;
  gap: 8px 40px;
  width: 100%;
}
.domain { padding-bottom: 24px; }
.domain__title {
  padding-block: 18px;
  font-size: var(--fs-h3);
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: -0.01em;
}
.domain__text {
  color: var(--c-text-muted);
  font-size: var(--fs-body);
  line-height: 1.3;
}

/* ---- Texte du cabinet ---- */
.prose {
  display: flex;
  flex-direction: column;
  gap: 1.3em;
  padding-bottom: 24px;
  color: var(--c-text-muted);
  font-size: var(--fs-body);
  line-height: 1.3;
}

/* ---- Photo Lyon ---- */
.split__media {
  width: 100%;
  max-width: 460px;
  margin-inline: auto;
}
.split__media img {
  width: 100%;
  aspect-ratio: 460 / 654;
  object-fit: cover;
}

/* ==========================================================================
   7. CITATION
   ========================================================================== */
.quote {
  background: var(--c-white);
  padding-block: clamp(56px, 6vw, 88px);
}
.quote__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 32px;
  max-width: calc(916px + 2 * var(--gutter));
  text-align: center;
}
.quote__text {
  font-size: var(--fs-quote);
  line-height: 1.3;
  text-wrap: balance;
}
.quote__author {
  color: var(--c-text-muted);
  font-size: 1rem;
  line-height: 1.3;
  text-transform: uppercase;
}

/* ==========================================================================
   8. IMPLANTATION NATIONALE
   ========================================================================== */
.national {
  display: grid;
  background: var(--c-bg);
}
.national__content {
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding: var(--section-y) var(--gutter) 40px;
}
.national__intro,
.national__label,
.places {
  color: var(--c-text-muted);
  font-size: var(--fs-lead);
  line-height: 1.3;
}
.national__intro { margin-bottom: 1.3em; }
.national__label { margin-bottom: -20px; } /* colle la liste au libellé, comme dans la maquette */
.places {
  margin: 0;
  padding-left: 27px;
  list-style: square;
}
.places li::marker { font-size: .8em; }

.national__map {
  position: relative;
  align-self: start;
}
.national__map > img { width: 100%; }

.pins { position: absolute; inset: 0; margin: 0; }
.pin {
  position: absolute;
  left: var(--x);
  top: var(--y);
  width: 8.2%;              /* 58 / 706 */
}
.pin img { width: 100%; }

/* ==========================================================================
   9. FOOTER
   ========================================================================== */
.footer {
  position: relative;
  overflow: hidden;
  background-color: var(--c-bg-dark);
  /* Motif « Grille technique » : quadrillage 88px, 10% d'opacité */
  background-image:
    linear-gradient(rgba(255, 255, 255, .1) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, .1) 1px, transparent 1px);
  background-size: 88px 88px;
  color: var(--c-text-inverse);
}
.footer__inner {
  position: relative;
  z-index: 1;
  padding: 56px 20px;
}
.footer__brand { display: inline-block; }
.footer__brand img { width: 220px; }

.footer__deco {
  position: absolute;
  right: 0;
  bottom: 0;
  width: 180px;
  pointer-events: none;
}

/* ==========================================================================
   10. TABLETTE ≥ 768px
   ========================================================================== */
@media (min-width: 768px) {
  .hero { padding: 20px 20px 0; }
  .announce { padding: 20px; }
  .announce__inner {
    flex-direction: row;
    align-items: center;
    gap: 36px;
    padding: 16px 28px;
  }
  .announce__text { flex: 1; }
  .hero__bar { height: 100px; padding-inline: 36px; }
  .brand img { width: 207px; }   /* logo 222 × 76 moins son padding interne Figma */
  .hero__bar { padding-left: 44px; }
  .hero__content { gap: 24px; padding: 160px 48px 60px; }

  .domains { grid-template-columns: repeat(2, minmax(0, 1fr)); }

  .footer__inner { padding: 91px 66px; }
  .footer__brand img { width: 298px; }  /* logo 320 × 110 moins son padding interne Figma */
  .footer__deco { width: 281px; }
}

/* ==========================================================================
   11. DESKTOP ≥ 1024px
   ========================================================================== */
@media (min-width: 1024px) {
  .hero__visual { min-height: 760px; }

  /* Collage à gauche (465px) / contenu à droite, gap 80px */
  .split__inner {
    grid-template-columns: 465px minmax(0, 1fr);
    gap: clamp(48px, 5.5vw, 80px);
  }
  .split__content { gap: 40px; }
  .collage { margin-inline: 0 auto; }

  /* Section Cabinet : contenu à gauche, photo à droite */
  .split--reverse { padding-block: 38px; }
  .split--reverse .split__inner { grid-template-columns: minmax(0, 1fr) 465px; }
  .split--reverse .split__content { padding-block: 60px; }
  .split__media { margin-inline: auto 0; }

  /* Carte à gauche (706/1440), texte à droite */
  .national {
    grid-template-columns: 49% minmax(0, 1fr);
    align-items: center;
  }
  .national__map { order: -1; }
  .national__content {
    justify-content: center;
    padding: 80px clamp(20px, 4.45vw, 64px) 80px clamp(40px, 5.8vw, 84px);
  }
}
