/* anasseh.com — feuille de style unique.
   Variables nommées par FONCTION, jamais par teinte.
   Échelle d'espacement : multiples de 0.5rem uniquement. */

/* Police auto-hébergée (assets/fonts/, licence SIL OFL) — la règle « zéro
   dépendance externe » reste entière : rien n'est chargé hors du site. */
@font-face {
  font-family: "Instrument Sans";
  src: url("../fonts/instrument-sans-400.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Instrument Sans";
  src: url("../fonts/instrument-sans-600.woff2") format("woff2");
  font-weight: 600;
  font-display: swap;
}
@font-face {
  font-family: "Instrument Sans";
  src: url("../fonts/instrument-sans-700.woff2") format("woff2");
  font-weight: 700;
  font-display: swap;
}

:root {
  --color-bg: #FAFAF8;          /* fond principal, blanc légèrement chaud */
  --color-bg-alt: #F2F1EC;      /* fond alterné des sections */
  --color-text: #141414;        /* texte courant, quasi-noir */
  --color-text-soft: #5A5A55;   /* gris moyen (sous-titre du hero), contraste AA sur --color-bg */
  --color-action: #1A3A5C;      /* couleur d'accent — actions, et le H1 du hero */
  --color-action-hover: #12293F;
  --color-chaleur: #B5603A;     /* terracotta de l'APPLICATION (bulles, Envoyer) —
                                   introduit le 16/08 pour relier le site au
                                   produit : sélecteur actif, soulignements de
                                   titre, numéros d'offres, jamais le CTA
                                   principal (qui reste bleu marine) */
  --color-chaleur-hover: #9E4F2E;
  --color-separator: #DDDBD4;   /* seul gris neutre, séparateurs discrets */

  --space-1: 0.5rem;
  --space-2: 1rem;
  --space-3: 1.5rem;
  --space-4: 2rem;
  --space-6: 3rem;
  --space-8: 4rem;
  --space-12: 6rem;
  --space-16: 8rem;
  --space-24: 12rem;

  --measure: 68ch;              /* largeur maximale d'une colonne de texte */
}

/* ---------- base ---------- */

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

@media (prefers-reduced-motion: no-preference) {
  html {
    scroll-behavior: smooth;
  }
}

body {
  font-family: "Instrument Sans", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 1rem;
  line-height: 1.6;
  color: var(--color-text);
  background: var(--color-bg);
  -webkit-text-size-adjust: 100%;
}

/* Aucun mot coupé dans un titre, jamais. */
h1, h2, h3 {
  hyphens: none;
  overflow-wrap: normal;
}

.container {
  max-width: 60rem;
  margin: 0 auto;
  padding-left: var(--space-3);
  padding-right: var(--space-3);
}

p, li, dd {
  max-width: var(--measure);
}

/* ---------- accessibilité ---------- */

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--color-text);
  color: var(--color-bg);
  padding: var(--space-1) var(--space-2);
}

.skip-link:focus {
  left: 0;
  z-index: 10;
}

a:focus-visible,
.btn-action:focus-visible {
  outline: 3px solid var(--color-text);
  outline-offset: 2px;
}

/* ---------- liens et actions ---------- */

a {
  color: var(--color-action);
  text-decoration: underline;
  text-underline-offset: 0.15em;
}

@media (prefers-reduced-motion: no-preference) {
  a,
  .btn-action {
    transition: background-color 150ms ease, color 150ms ease;
  }
}

.btn-action {
  display: inline-block;
  background: var(--color-action);
  color: #FFFFFF;
  text-decoration: none;
  font-weight: 700;
  font-size: 1.125rem;
  padding: var(--space-2) var(--space-4);
  min-height: 44px;
  min-width: 44px;
  border-radius: 10px;
  box-shadow: 0 4px 14px rgba(26, 58, 92, 0.25);
}

.btn-action:hover {
  background: var(--color-action-hover);
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(26, 58, 92, 0.3);
}

@media (prefers-reduced-motion: no-preference) {
  .btn-action { transition: background-color 150ms ease, transform 150ms ease, box-shadow 150ms ease; }
}

/* ---------- en-tête ---------- */

.site-header {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: var(--space-2) var(--space-4);
  max-width: 60rem;
  margin: 0 auto;
  padding: var(--space-3);
  border-bottom: 1px solid var(--color-separator);
}

.site-header .brand {
  font-weight: 700;
}

.site-header nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-1) var(--space-3);
  list-style: none;
}

.site-header nav a {
  color: var(--color-text);
  text-decoration: none;
  /* Zone tactile ≥ 44px de haut : 25.6px de ligne + 2 × 10px. */
  display: inline-block;
  padding: 0.625rem 0;
}

.site-header nav a:hover {
  text-decoration: underline;
}

/* ---------- premier écran : hero à deux situations (refonte 16/08) ---------- */

/* Header + hero tiennent dans 100dvh : sélecteur, titre, corps et CTA sont
   visibles SANS défiler (vérifié à 393×660, iPhone 15 Pro barre Safari
   comprise) ; la capture déborde volontairement sous le pli. */
.ecran1 {
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  /* Profondeur discrète : deux halos bleu nuit très dilués — le fond n'est
     plus un aplat, sans toucher à la palette ni à la lisibilité. */
  background:
    radial-gradient(55rem 30rem at 88% -12%, rgba(26, 58, 92, 0.08), transparent 62%),
    radial-gradient(45rem 26rem at -8% 108%, rgba(26, 58, 92, 0.05), transparent 60%);
}

.hero {
  flex: 1;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-content: start;
  gap: var(--space-2);
  padding: var(--space-1) var(--space-3) 0;
  max-width: 76rem;
  width: 100%;
  margin: 0 auto;
  box-sizing: border-box;
}

.hero-texte {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.hero h1 {
  font-size: clamp(1.55rem, 5.2vw, 2.7rem);
  line-height: 1.12;
  letter-spacing: -0.02em;
  font-weight: 650;
  color: var(--color-action);
  text-wrap: balance;
}

.hero-sub {
  font-size: 1rem;
  color: var(--color-text-soft);
}

.hero-sub p + p { margin-top: var(--space-1); }
.hero-sub .exemples { font-style: italic; }

.hero-cta small {
  display: block;
  margin-top: var(--space-1);
  color: var(--color-text-soft);
  font-size: 0.85rem;
}

/* Le sélecteur : deux SITUATIONS, pas deux catégories administratives. */
.situations {
  display: flex;
  /* Libellés courts (Entreprise/Entrepreneur, 17/08) : côte à côte partout,
     y compris mobile — deux barres pleine largeur pour un mot seraient lourdes. */
  flex-direction: row;
  gap: 0.5rem;
  border: 0;
  margin: 0;
  padding: 0;
}

.situations label { display: block; cursor: pointer; }

.situations input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
}

.situations span {
  display: block;
  padding: 0.65rem 1rem;
  border: 1.5px solid var(--color-separator);
  border-radius: 10px;
  font-weight: 600;
  font-size: 0.9375rem;
  color: var(--color-text-soft);
  background: #fff;
}

.situations label:has(input:checked) span {
  border-color: var(--color-chaleur);
  background: var(--color-chaleur);
  color: #fff;
}

.situations label:hover input:not(:checked) + span,
.situations label:hover span {
  border-color: var(--color-chaleur);
}

.situations label:has(input:checked):hover span {
  background: var(--color-chaleur-hover);
}

.situations label:has(input:focus-visible) span {
  outline: 2px solid var(--color-chaleur);
  outline-offset: 2px;
}

/* Desktop : texte à gauche, capture à droite, sélecteur côte à côte. */
@media (min-width: 900px) {
  .hero {
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
    column-gap: var(--space-8);
    align-items: center;
    align-content: center;
    padding: 0 var(--space-6);
  }

  .hero-texte { gap: var(--space-3); }

  .situations { flex-direction: row; gap: 0.6rem; }
  .situations span { font-size: 0.9rem; padding: 0.55rem 0.95rem; }

  .hero h1 { font-size: clamp(2rem, 3.2vw, 2.7rem); }
  .hero-sub { font-size: 1.0625rem; }
}

/* Petits écrans : le bloc hero complet (header + titre + sous-titre + CTA)
   doit tenir au-dessus du pli d'un iPhone SE (667px) — mesuré par sonde le
   14/08 : 745px sans ces ajustements. text-wrap: balance répartit les mots
   du titre (plus de « traitement » isolé sur sa ligne) ; les navigateurs
   sans support l'ignorent proprement. */
@media (max-width: 640px) {
  /* Navigation réduite au seul lien Contact (les liens ne tiennent pas
     sur une ligne à 375px — option prévue par la direction artistique). */
  .site-header nav li:not(:last-child) {
    display: none;
  }
}

@media (max-width: 480px) {
  .site-header {
    padding-top: var(--space-2);
    padding-bottom: var(--space-2);
  }
}

/* ---------- sections ---------- */

.section {
  padding-top: var(--space-8);
  padding-bottom: var(--space-8);
}

.section-alt {
  background: var(--color-bg-alt);
}

.section h2 {
  font-size: clamp(1.75rem, 2vw + 1rem, 2.25rem);
  line-height: 1.1;
  font-weight: 700;
  letter-spacing: -0.015em;
  margin-bottom: var(--space-6);
}

/* Soulignement court terracotta sous chaque titre de section : le fil
   conducteur chaleureux qui relie le site aux couleurs de l'application. */
.section h2::after {
  content: "";
  display: block;
  width: 2.75rem;
  height: 4px;
  border-radius: 2px;
  background: var(--color-chaleur);
  margin-top: var(--space-2);
}

@media (min-width: 768px) {
  .section {
    padding-top: var(--space-12);
    padding-bottom: var(--space-12);
  }
}

/* ---------- le constat ---------- */

/* « Le constat » : traitement SOBRE, presque en retrait (direction visuelle
   du 16/08) — ce sont des problèmes, ils n'ont pas à briller. Le contraste
   avec les cartes de « Notre approche » différencie les deux sections. */
.constats {
  list-style: none;
  display: grid;
  gap: var(--space-3);
  max-width: var(--measure);
}

.constats li {
  padding-left: var(--space-3);
  border-left: 2px solid var(--color-separator);
  font-size: 1.0625rem;
  color: var(--color-text-soft);
}

/* ---------- offres : liste verticale, jamais une grille ---------- */

.offre {
  padding-top: var(--space-6);
  padding-bottom: var(--space-6);
  border-top: 1px solid var(--color-separator);
}

.offre:last-of-type {
  border-bottom: 1px solid var(--color-separator);
}

/* Numéros d'offres GRANDS et structurants (direction visuelle du 16/08) —
   l'ancien gris pâle minuscule ne structurait rien. */
.offre-num {
  font-size: 2.75rem;
  font-weight: 700;
  line-height: 1;
  color: var(--color-chaleur);
  opacity: 0.85;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
  margin-bottom: var(--space-2);
}

.offre h3 {
  font-size: 1.5rem;
  line-height: 1.2;
  font-weight: 700;
  margin-bottom: var(--space-2);
  max-width: var(--measure);
}

/* ---------- questions : le vide et la rupture de format ---------- */

.section-questions {
  padding-top: var(--space-16);
  padding-bottom: var(--space-16);
}

@media (min-width: 768px) {
  .section-questions {
    padding-top: var(--space-24);
    padding-bottom: var(--space-24);
  }
}

.questions-intro {
  margin-bottom: var(--space-8);
}

.questions {
  list-style: none;
  display: grid;
  gap: var(--space-3);
}

/* Chaque question ressemble à une bulle de saisie du chat — c'est
   littéralement ce qu'elle est dans le produit. */
.questions li {
  font-size: 1.2rem;
  font-weight: 400;
  line-height: 1.6;
  max-width: var(--measure);
  padding: var(--space-2) var(--space-3);
  background: #fff;
  border: 1px solid var(--color-separator);
  border-radius: 999px;
  box-shadow: 0 4px 14px rgba(20, 20, 20, 0.05);
  width: fit-content;
}

@media (max-width: 640px) {
  .questions li { border-radius: 18px; font-size: 1.0625rem; }
}

/* ---------- approche ---------- */

.approche {
  display: grid;
  gap: var(--space-3);
}

.approche > div {
  padding: var(--space-3);
  background: #fff;
  border: 1px solid var(--color-separator);
  border-radius: 12px;
  box-shadow: 0 4px 16px rgba(20, 20, 20, 0.05);
}

@media (min-width: 768px) {
  .approche { grid-template-columns: 1fr 1fr; }
}

/* « Notre approche » énonce des GARANTIES : c'est ici que la hiérarchie et
   la chaleur ont du sens — pastille terracotta devant chaque titre. */
.approche dt {
  font-weight: 700;
  font-size: 1.1875rem;
  margin-bottom: var(--space-1);
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.approche dt::before {
  content: "";
  flex: none;
  width: 0.6rem;
  height: 0.6rem;
  border-radius: 3px;
  background: var(--color-chaleur);
}

/* ---------- contact ---------- */

.contact-cta {
  margin-top: var(--space-6);
}

/* Trois moyens de contact, traitement typographique IDENTIQUE — aucun
   n'est mis en avant par rapport aux autres, l'email en premier. */
/* Trois moyens de contact en cartes-boutons équivalentes — la dernière
   chose que voit un prospect ne doit pas ressembler à un pied de page. */
.contact-cartes {
  display: grid;
  gap: var(--space-3);
  margin-top: var(--space-6);
}

@media (min-width: 768px) {
  .contact-cartes { grid-template-columns: repeat(3, 1fr); }
}

.contact-carte {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.35rem;
  padding: var(--space-3);
  background: #fff;
  border: 1px solid var(--color-separator);
  border-radius: 12px;
  box-shadow: 0 4px 16px rgba(20, 20, 20, 0.05);
  text-decoration: none;
  color: var(--color-text);
  min-height: 44px;
}

.contact-carte:hover {
  border-color: var(--color-chaleur);
  transform: translateY(-2px);
  box-shadow: 0 8px 22px rgba(20, 20, 20, 0.09);
}

@media (prefers-reduced-motion: no-preference) {
  .contact-carte { transition: border-color 150ms ease, transform 150ms ease, box-shadow 150ms ease; }
}

.contact-carte svg { color: var(--color-chaleur); }

.contact-carte-titre {
  font-weight: 700;
  font-size: 1.0625rem;
}

.contact-carte-valeur {
  color: var(--color-text-soft);
  font-size: 0.95rem;
  word-break: break-word;
}

/* ---------- capture du premier écran + agrandissement ---------- */

.hero-visuel a.zoomable,
.offre-figure a.zoomable,
.approche-figure a.zoomable { display: block; cursor: zoom-in; }

/* Cadre « fenêtre de navigateur » autour des captures (pur CSS) : la barre
   aux trois pastilles transforme une capture brute en visuel produit. */
.hero-visuel a.zoomable,
.approche-figure a.zoomable {
  border: 1px solid var(--color-separator);
  border-radius: 10px;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 14px 38px rgba(20, 20, 20, 0.12);
}

.hero-visuel a.zoomable::before,
.approche-figure a.zoomable::before {
  content: "";
  display: block;
  height: 26px;
  background-color: var(--color-bg-alt);
  background-image:
    radial-gradient(circle 5px at 18px 13px, #E0655A 5px, transparent 6px),
    radial-gradient(circle 5px at 36px 13px, #E9B44C 5px, transparent 6px),
    radial-gradient(circle 5px at 54px 13px, #7CB47C 5px, transparent 6px);
  border-bottom: 1px solid var(--color-separator);
}

.hero-visuel img {
  display: block;
  width: 100%;
  height: auto;
}

/* L'image dans un cadre navigateur ne porte plus sa propre bordure. */
.approche-figure a.zoomable img { border: none; }

/* Lightbox PUR CSS (:target) : clic sur une capture = plein écran assombri,
   clic n'importe où = fermeture (href="#!" — aucun défilement parasite).
   Sur mobile, le pincement fonctionne dans l'agrandissement. */
.lightbox {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 50;
  background: rgba(20, 20, 20, 0.88);
}

.lightbox:target { display: block; }

.lightbox a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  cursor: zoom-out;
  padding: 2vh 2vw;
  box-sizing: border-box;
}

.lightbox img {
  max-width: 96vw;
  max-height: 94dvh;
  width: auto;
  height: auto;
  border-radius: 6px;
  background: #fff;
}

/* ---------- captures d'écran dans les offres ---------- */

.offre-figure {
  margin-top: var(--space-4);
  max-width: 27rem;
}

.offre-figure img {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid var(--color-separator);
}

.offre-figure figcaption {
  margin-top: var(--space-1);
  font-size: 0.875rem;
  color: var(--color-text-soft);
}

/* Capture au format bandeau large (section Approche) : la largeur des
   figures d'offre (27rem) rendrait son texte illisible. */
.approche-figure {
  max-width: 45rem;
}

/* Horodatage de version dans le footer — repère de déploiement, discret. */
.version-stamp {
  margin-top: var(--space-1);
  font-size: 0.75rem;
  color: var(--color-text-soft);
}

/* ---------- commutateur de profil Entreprise / Particulier ---------- */
/* Pur CSS, zéro script (principe du site) : deux radios cachés dans le hero
   + :has() sur body pour afficher/masquer les blocs .profil-entreprise /
   .profil-particulier partout dans la page. Navigateur sans :has() (très
   anciens) : les deux contenus s'affichent — dégradation lisible, jamais
   une page vide. Le commutateur est une ACTION : l'accent y est légitime. */
/* Bascule de contenu par situation : les radios du hero (#etat-equipe /
   #etat-docs) pilotent tout le document — équipe = .profil-entreprise,
   mes documents = .profil-particulier ; sans classe = commun. Navigateur
   sans :has() : les deux contenus s'affichent, jamais une page vide. */
body:has(#etat-docs:checked) .profil-entreprise { display: none; }
body:has(#etat-equipe:checked) .profil-particulier { display: none; }

/* Texte réservé aux lecteurs d'écran (légende du commutateur). */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.contact-secondaire {
  margin-top: var(--space-4);
}

.contact-secondaire a {
  display: inline-block;
  padding: var(--space-1) 0;    /* zone cliquable ≥ 44px de haut */
}

.contact-lieu {
  margin-top: var(--space-6);
}

/* ---------- pied de page ---------- */

.site-footer {
  border-top: 1px solid var(--color-separator);
  padding-top: var(--space-4);
  padding-bottom: var(--space-4);
}

/* ---------- pages annexes (mentions légales, 404) ---------- */

.page-simple {
  padding-top: var(--space-8);
  padding-bottom: var(--space-12);
}

.page-simple h1 {
  font-size: clamp(1.75rem, 2vw + 1rem, 2.25rem);
  line-height: 1.1;
  font-weight: 800;
  margin-bottom: var(--space-6);
}

.page-simple h2 {
  font-size: 1.25rem;
  font-weight: 700;
  margin-top: var(--space-6);
  margin-bottom: var(--space-2);
}

.page-simple p + p {
  margin-top: var(--space-2);
}
