/* Mafia Féline — feuille de style unique, sans préprocesseur.
 *
 * Parti pris (docs/BRIEF.md, « Identité visuelle ») : un site blanc comme la fourrure d'un Ragdoll.
 * Deux couleurs tirées de la race : le seal (brun très foncé des extrémités) pour le texte, le
 * saphir (les yeux) pour ce qui se clique. Un seul motif fort : l'arche, cadre de portrait de famille
 * qui entoure chaque photo de chat. Le reste est calme : filets fins, pas d'ombres, pas de dégradés.
 * Titres en Bodoni Moda (didone italienne, clin d'œil à la « mafia »), texte en Jost. Polices servies
 * par le site (aucun tiers chargé par le navigateur).
 */

@font-face { font-family: "Bodoni Moda"; src: url("/polices/bodoni-moda-latin-500-normal.woff2") format("woff2"); font-weight: 500; font-style: normal; font-display: swap; }
@font-face { font-family: "Bodoni Moda"; src: url("/polices/bodoni-moda-latin-400-italic.woff2") format("woff2"); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: "Bodoni Moda"; src: url("/polices/bodoni-moda-latin-500-italic.woff2") format("woff2"); font-weight: 500; font-style: italic; font-display: swap; }
@font-face { font-family: "Jost"; src: url("/polices/jost-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Jost"; src: url("/polices/jost-latin-500-normal.woff2") format("woff2"); font-weight: 500; font-style: normal; font-display: swap; }

:root {
  /* Couleurs (contrastes vérifiés sur blanc : seal 15:1, seal-doux 7:1, saphir 8,5:1) */
  --blanc: #ffffff;
  --neige: #f4f5f7;        /* fond de bande, froid comme une ombre sur du blanc */
  --seal: #2a201b;         /* texte et titres */
  --seal-doux: #5f5650;    /* texte secondaire */
  --saphir: #2c4f7c;       /* liens, onglet actif, boutons */
  --saphir-fonce: #1f3a5c;
  --ligne: #e4e0dc;        /* filets */
  --mink: #b9aca0;         /* filet de l'arche (décor seulement) */

  --police-titre: "Bodoni Moda", "Bodoni 72", Didot, Georgia, serif;
  --police-texte: "Jost", "Futura", "Century Gothic", "Avenir Next", system-ui, sans-serif;

  --mesure: 38rem;         /* longueur de ligne du texte courant (≈ 66 caractères) */
  --largeur: 72rem;
  --marge: clamp(1.25rem, 4vw, 2.5rem);
}

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

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

body {
  margin: 0;
  background: var(--blanc);
  color: var(--seal);
  font-family: var(--police-texte);
  font-size: 1.0625rem;
  line-height: 1.65;
  font-kerning: normal;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main { flex: 1; outline: none; }

img { max-width: 100%; display: block; }

h1, h2, h3 { margin: 0; font-weight: 500; text-wrap: balance; }
h1, h2 { font-family: var(--police-titre); letter-spacing: -0.01em; }
h3 { font-family: var(--police-texte); font-size: 1.0625rem; letter-spacing: 0.01em; }
p { margin: 0 0 1em; }

a { color: var(--saphir); text-decoration-thickness: 1px; text-underline-offset: 0.2em; }
a:hover { color: var(--saphir-fonce); text-decoration-thickness: 2px; }

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

.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; }

.evitement { position: absolute; left: 1rem; top: -4rem; background: var(--saphir); color: var(--blanc); padding: 0.5rem 1rem; z-index: 20; }
.evitement:focus { top: 1rem; }

.noscript { max-width: var(--mesure); margin: 4rem auto; padding: 0 var(--marge); }

/* ---------- En-tête et onglets de navigation ---------- */

.entete {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgb(255 255 255 / 0.96);
  border-bottom: 1px solid var(--ligne);
}

.entete__interieur {
  max-width: var(--largeur);
  margin: 0 auto;
  padding: 0 var(--marge);
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 2rem;
}

.marque {
  display: flex;
  flex-direction: column;
  padding: 1rem 0 0.9rem;
  color: var(--seal);
  text-decoration: none;
  line-height: 1.1;
}
.marque:hover { color: var(--seal); }
.marque__nom { font-family: var(--police-titre); font-size: 1.625rem; letter-spacing: -0.005em; }
.marque__sous { font-size: 0.8125rem; color: var(--seal-doux); letter-spacing: 0.02em; margin-top: 0.2rem; }

.navigation ul { display: flex; gap: 0.25rem; margin: 0; padding: 0; list-style: none; }

.navigation a {
  display: block;
  padding: 1.35rem 0.85rem 1.1rem;
  color: var(--seal);
  font-size: 0.9375rem;
  font-weight: 500;
  text-decoration: none;
  white-space: nowrap;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px; /* l'indicateur repose sur le filet de l'en-tête */
}
.navigation a:hover { color: var(--saphir); border-bottom-color: var(--ligne); }
.navigation a[aria-current] { color: var(--saphir); border-bottom-color: var(--saphir); }

/* Téléphone : la marque au-dessus, les onglets sur une ligne qui défile (pas de menu caché). */
@media (max-width: 52rem) {
  .entete { position: static; }
  .entete__interieur { flex-direction: column; align-items: stretch; gap: 0; padding: 0; }
  .marque { padding: 0.9rem var(--marge) 0.4rem; }
  .navigation {
    overflow-x: auto;
    scrollbar-width: none;
    -webkit-mask-image: linear-gradient(to right, transparent 0, #000 1.25rem, #000 calc(100% - 1.5rem), transparent 100%);
    mask-image: linear-gradient(to right, transparent 0, #000 1.25rem, #000 calc(100% - 1.5rem), transparent 100%);
  }
  .navigation::-webkit-scrollbar { display: none; }
  .navigation ul { gap: 0; padding: 0 calc(var(--marge) - 0.6rem); width: max-content; }
  .navigation a { padding: 0.75rem 0.6rem 0.7rem; }
}

/* ---------- L'arche : cadre de portrait ---------- */

.arche {
  display: block;
  position: relative;
  aspect-ratio: 4 / 5;
  border-radius: 9999px 9999px 0 0; /* demi-cercle exact, quelle que soit la largeur */
  overflow: hidden;
  background: var(--neige);
  outline: 1px solid var(--mink);
  outline-offset: 5px;
}
.arche img { width: 100%; height: 100%; object-fit: cover; }

.arche--heros { width: min(100%, 27rem); margin-left: auto; outline-offset: 10px; }
.arche--portrait { width: 100%; }

/* ---------- Boutons et liens d'action ---------- */

.actions { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 2rem; }

.bouton {
  display: inline-flex;
  align-items: center;
  min-height: 2.875rem;
  padding: 0.6rem 1.4rem;
  background: var(--saphir);
  color: var(--blanc);
  border: 1px solid var(--saphir);
  border-radius: 999px;
  font-weight: 500;
  font-size: 0.9375rem;
  text-decoration: none;
  letter-spacing: 0.01em;
}
.bouton:hover { background: var(--saphir-fonce); border-color: var(--saphir-fonce); color: var(--blanc); text-decoration: none; }
.bouton--discret { background: transparent; color: var(--saphir); }
.bouton--discret:hover { background: var(--neige); color: var(--saphir-fonce); }

.lien-fleche { font-weight: 500; }

/* ---------- Mises en page communes ---------- */

.page { max-width: var(--largeur); margin: 0 auto; padding: clamp(2rem, 6vw, 4.5rem) var(--marge) 5rem; }

.page__tete { max-width: 44rem; margin-bottom: clamp(2rem, 5vw, 3.5rem); }
.page__tete h1 { font-size: clamp(2.375rem, 2.2vw + 1.6rem, 3.5rem); line-height: 1.08; }
.chapeau { font-size: 1.1875rem; line-height: 1.55; color: var(--seal-doux); margin-top: 1.1rem; max-width: var(--mesure); }

.fil { margin-bottom: 1.5rem; font-size: 0.9375rem; }
.fil a { text-decoration: none; }
.fil a::before { content: "‹"; margin-right: 0.4em; }

.texte-long { max-width: var(--mesure); }
.texte-long section + section { margin-top: 2.5rem; }
.texte-long h2 { font-size: 1.5rem; line-height: 1.25; margin-bottom: 0.75rem; }

.page--texte .texte-long { max-width: 44rem; }

.liste { margin: 0 0 1em; padding-left: 1.2em; }
.liste li { margin-bottom: 0.35em; }
.liste li::marker { color: var(--mink); }

.liens { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--ligne); }
.liens li { border-bottom: 1px solid var(--ligne); }
.liens a { display: block; padding: 0.8rem 0; font-weight: 500; text-decoration: none; }
.liens a:hover { text-decoration: underline; }

.brouillon { border-left: 3px solid var(--mink); background: var(--neige); padding: 0.75rem 1rem; color: var(--seal-doux); font-size: 0.9375rem; max-width: 44rem; }

/* Fiche : paires intitulé / valeur, en filets */
.fiche { margin: 0; border-top: 1px solid var(--ligne); }
.fiche > div { display: grid; grid-template-columns: minmax(7rem, 12rem) 1fr; gap: 1rem; padding: 0.65rem 0; border-bottom: 1px solid var(--ligne); }
.fiche dt { color: var(--seal-doux); font-size: 0.9375rem; }
.fiche dd { margin: 0; }
@media (max-width: 30rem) { .fiche > div { grid-template-columns: 1fr; gap: 0.1rem; } }

/* ---------- Accueil ---------- */

.heros {
  max-width: var(--largeur);
  margin: 0 auto;
  padding: clamp(2.5rem, 7vw, 5.5rem) var(--marge) clamp(3rem, 7vw, 5.5rem);
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: clamp(2rem, 6vw, 5rem);
  align-items: center;
}
.heros h1 { font-size: clamp(2.75rem, 4.2vw + 1.1rem, 5rem); line-height: 1.02; letter-spacing: -0.02em; max-width: 12ch; }
.heros .chapeau { font-size: 1.25rem; }

@media (max-width: 52rem) {
  .heros { grid-template-columns: 1fr; }
  .heros__photo { order: -1; }
  .arche--heros { width: min(78%, 20rem); margin: 0 auto; }
}

.bandeau-chatons {
  background: var(--neige);
  border-top: 1px solid var(--ligne);
  border-bottom: 1px solid var(--ligne);
  padding: 1.75rem max(var(--marge), calc((100% - var(--largeur)) / 2 + var(--marge)));
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 0.5rem 2rem;
  align-items: center;
}
.bandeau-chatons h2 { font-size: 1.5rem; }
.bandeau-chatons p { margin: 0; color: var(--seal-doux); max-width: 44rem; }
@media (max-width: 52rem) {
  .bandeau-chatons { grid-template-columns: 1fr; }
  .bandeau-chatons .bouton { justify-self: start; margin-top: 0.5rem; }
}

.bloc-famille, .bloc-texte { max-width: var(--largeur); margin: 0 auto; padding: clamp(3rem, 7vw, 5rem) var(--marge) 0; }
.bloc-famille__tete { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 0.5rem 2rem; margin-bottom: 2.25rem; }
.bloc-famille__tete h2, .bloc-texte h2 { font-size: clamp(1.875rem, 1.5vw + 1.3rem, 2.5rem); line-height: 1.1; }
.bloc-famille__tete p { margin: 0; color: var(--seal-doux); max-width: 30rem; }

.bloc-texte {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 2fr);
  gap: 1rem clamp(2rem, 6vw, 5rem);
}
.bloc-texte > h2 { padding-top: 1.25rem; border-top: 1px solid var(--seal); align-self: start; }
.bloc-texte > div { padding-top: 1.25rem; border-top: 1px solid var(--ligne); max-width: var(--mesure); }
.bloc-texte:last-child { padding-bottom: 5rem; }
@media (max-width: 52rem) {
  .bloc-texte { grid-template-columns: 1fr; }
  .bloc-texte > div { border-top: 0; padding-top: 0; }
}

/* ---------- Chats : grille de portraits ---------- */

.grille-chats {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 13rem), 1fr));
  gap: 2.5rem clamp(1.25rem, 3vw, 2.5rem);
}
.grille-chats--petite { grid-template-columns: repeat(auto-fill, minmax(min(100%, 9.5rem), 1fr)); gap: 2rem 1.5rem; }

.carte-chat { display: block; color: var(--seal); text-decoration: none; }
.carte-chat .arche { margin-bottom: 1.1rem; }
.carte-chat:hover { color: var(--seal); }
.carte-chat__nom { display: block; font-family: var(--police-titre); font-size: 1.375rem; line-height: 1.2; }
.carte-chat__nom em { display: block; font-style: italic; font-weight: 400; color: var(--seal-doux); font-size: 0.78em; line-height: 1.3; }
.carte-chat__ligne { display: block; color: var(--seal-doux); font-size: 0.9375rem; margin-top: 0.3rem; }
.carte-chat:hover .carte-chat__nom span { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 0.2em; }
@media (max-width: 30rem) {
  .grille-chats { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2.25rem 1.4rem; }
  .carte-chat__nom { font-size: 1.125rem; }
}

/* ---------- Fiche d'un chat ---------- */

.fiche-chat__tete {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  gap: clamp(2rem, 6vw, 5rem);
  align-items: end;
  margin-bottom: clamp(2.5rem, 6vw, 4rem);
}
.fiche-chat__tete .arche { max-width: 24rem; }
.nom-chat { font-size: clamp(2.5rem, 3vw + 1.4rem, 4.25rem); line-height: 1.02; letter-spacing: -0.02em; }
.nom-chat em { display: block; font-style: italic; font-weight: 400; font-size: 0.52em; letter-spacing: 0; color: var(--seal-doux); margin-top: 0.2em; }
.nom-chat em:first-child { margin: 0 0 0.25em; }
.fiche-chat__accroche { font-family: var(--police-titre); font-style: italic; font-size: 1.375rem; margin: 1.25rem 0 1.75rem; }
@media (max-width: 52rem) {
  .fiche-chat__tete { grid-template-columns: 1fr; }
  .fiche-chat__tete .arche { width: min(80%, 20rem); }
}

.autres-chats { margin-top: 5rem; padding-top: 2rem; border-top: 1px solid var(--ligne); }
.autres-chats h2 { font-size: 1.5rem; margin-bottom: 1.75rem; }
.autres-chats .carte-chat__nom { font-size: 1.125rem; }

/* ---------- Onglets de contenu ---------- */

.onglets__liste {
  display: flex;
  gap: 0.25rem;
  border-bottom: 1px solid var(--ligne);
  margin-bottom: 2.25rem;
  overflow-x: auto;
  scrollbar-width: none;
}
.onglets__liste::-webkit-scrollbar { display: none; }
.onglets__liste [role="tab"] {
  appearance: none;
  background: none;
  border: 0;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  padding: 0.75rem 0.9rem;
  font: inherit;
  font-weight: 500;
  font-size: 0.9875rem;
  color: var(--seal-doux);
  cursor: pointer;
  white-space: nowrap;
}
.onglets__liste [role="tab"]:first-child { padding-left: 0; }
.onglets__liste [role="tab"]:hover { color: var(--seal); }
.onglets__liste [role="tab"][aria-selected="true"] { color: var(--saphir); border-bottom-color: var(--saphir); }
.onglet__compte { font-weight: 400; color: var(--seal-doux); font-size: 0.875em; margin-left: 0.15em; }
[role="tabpanel"] { outline: none; }
[role="tabpanel"]:focus-visible { outline: 2px solid var(--saphir); outline-offset: 8px; }

/* ---------- Galerie et visionneuse ---------- */

.galerie { list-style: none; margin: 0; padding: 0; columns: 3 14rem; column-gap: 1rem; }
.galerie li { break-inside: avoid; margin-bottom: 1rem; }
.galerie__photo { display: block; width: 100%; padding: 0; border: 0; background: var(--neige); cursor: zoom-in; }
.galerie__photo img { width: 100%; height: auto; }
.galerie__photo:hover img { opacity: 0.92; }
@media (max-width: 30rem) { .galerie { columns: 2; column-gap: 0.6rem; } .galerie li { margin-bottom: 0.6rem; } }

.visionneuse {
  width: 100vw;
  height: 100dvh;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 1rem;
  border: 0;
  background: var(--blanc);
  color: var(--seal);
}
.visionneuse[open] { display: grid; grid-template-rows: minmax(0, 1fr) auto; gap: 1rem; }
.visionneuse::backdrop { background: var(--blanc); }
.visionneuse__figure { margin: 0; min-height: 0; display: grid; grid-template-rows: minmax(0, 1fr) auto; justify-items: center; gap: 0.75rem; }
.visionneuse__image { width: 100%; height: 100%; min-height: 0; object-fit: contain; }
.visionneuse__legende { color: var(--seal-doux); font-size: 0.9375rem; text-align: center; max-width: var(--mesure); }
.visionneuse__commandes { display: flex; justify-content: center; align-items: center; gap: 0.75rem; flex-wrap: wrap; }
.visionneuse__bouton {
  font: inherit; font-weight: 500; font-size: 0.9375rem;
  min-height: 2.75rem; padding: 0.5rem 1.1rem;
  background: var(--blanc); color: var(--saphir);
  border: 1px solid var(--ligne); border-radius: 999px; cursor: pointer;
}
.visionneuse__bouton:hover { border-color: var(--saphir); }
.visionneuse__position { color: var(--seal-doux); font-size: 0.875rem; min-width: 5.5rem; text-align: center; }

/* ---------- Chatons ---------- */

.vide { border: 1px solid var(--ligne); padding: clamp(1.5rem, 4vw, 2.5rem); max-width: 44rem; }
.vide p { font-size: 1.125rem; }
p.vide { border: 0; padding: 0; color: var(--seal-doux); }

.renvoi { margin-top: 2.5rem; }

.portee + .portee { margin-top: 4rem; }
.portee h2 { font-size: 1.75rem; }
.portee__ligne { color: var(--seal-doux); }
.chatons { list-style: none; margin: 1.5rem 0 2rem; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 11rem), 1fr)); gap: 2rem 1.5rem; }
.chaton .arche { margin-bottom: 0.9rem; }
.chaton h3 { font-family: var(--police-titre); font-size: 1.25rem; font-weight: 500; letter-spacing: 0; }
.chaton p { margin: 0.2rem 0 0; color: var(--seal-doux); font-size: 0.9375rem; }
.statut { display: inline-block; margin-top: 0.5rem !important; padding: 0.1rem 0.6rem; border: 1px solid currentColor; border-radius: 999px; font-size: 0.8125rem !important; font-weight: 500; }
.statut--disponible { color: var(--saphir) !important; }
.statut--option { color: var(--seal) !important; }
.fiche--legale { max-width: 44rem; font-size: 0.9375rem; }

.projets { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--ligne); max-width: 44rem; }
.projet { padding: 1.25rem 0; border-bottom: 1px solid var(--ligne); }
.projet h3 { font-family: var(--police-titre); font-size: 1.375rem; letter-spacing: 0; }
.projet__periode { color: var(--saphir); font-weight: 500; margin: 0.2rem 0 0.5rem; }

/* ---------- Pages éditoriales : étapes, figures, coordonnées ---------- */

.etapes { list-style: none; margin: 1.5rem 0 0; padding: 0; counter-reset: etape; }
.etapes li {
  counter-increment: etape;
  position: relative;
  padding: 0 0 1.75rem 3.5rem;
}
.etapes li::before {
  content: counter(etape);
  position: absolute; left: 0; top: -0.15rem;
  width: 2.25rem; height: 2.25rem;
  display: grid; place-items: center;
  border: 1px solid var(--saphir); border-radius: 50%;
  color: var(--saphir);
  font-family: var(--police-titre); font-size: 1.125rem;
}
.etapes li:not(:last-child)::after {
  content: ""; position: absolute; left: calc(1.125rem - 0.5px); top: 2.35rem; bottom: 0.2rem;
  border-left: 1px solid var(--ligne);
}
.etapes h3 { margin-bottom: 0.25rem; }
.etapes p { margin: 0; color: var(--seal-doux); }

.figures { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 12rem), 1fr)); gap: 2.5rem 2rem; margin-top: 2rem; }
.page--texte .figures { max-width: 44rem; }
.figure { margin: 0; }
.figure .arche { margin-bottom: 1.1rem; }
.figure h3 { font-family: var(--police-titre); font-size: 1.375rem; font-weight: 500; letter-spacing: 0; margin-bottom: 0.35rem; }
.figure p { font-size: 0.9375rem; color: var(--seal-doux); margin-bottom: 0.5rem; }
.figure .credit { font-size: 0.8125rem; }
.texte-long .figures .arche { max-width: 16rem; }

.coordonnees h2 { margin-bottom: 1rem; }
.coordonnees .fiche > div { grid-template-columns: 7rem 1fr; }
.coordonnees--photo { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: clamp(2rem, 5vw, 4rem); align-items: end; }
.coordonnees--photo .arche { max-width: 17rem; width: 100%; justify-self: end; }
@media (max-width: 40rem) { .coordonnees--photo { grid-template-columns: 1fr; } .coordonnees--photo .arche { justify-self: start; width: 70%; } }

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

.pied { border-top: 1px solid var(--ligne); margin-top: auto; }
.pied__interieur {
  max-width: var(--largeur);
  margin: 0 auto;
  padding: 2.25rem var(--marge) 2.5rem;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-end;
  gap: 1.25rem 2rem;
}
.pied__nom { font-family: var(--police-titre); font-size: 1.25rem; margin: 0; }
.pied__ligne { margin: 0.2rem 0 0; color: var(--seal-doux); font-size: 0.875rem; }
.pied__liens { display: flex; flex-wrap: wrap; gap: 0.25rem 1.5rem; margin: 0; padding: 0; list-style: none; font-size: 0.9375rem; }

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

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