/* Le site de Cultivia : la charte de l'application, sans rien charger d'ailleurs. */
@font-face { font-family: 'Fraunces'; font-weight: 600; font-display: swap; src: url('/fonts/Fraunces_600SemiBold.ttf') format('truetype'); }
@font-face { font-family: 'Fraunces'; font-weight: 700; font-display: swap; src: url('/fonts/Fraunces_700Bold.ttf') format('truetype'); }
@font-face { font-family: 'Fraunces'; font-weight: 600; font-style: italic; font-display: swap; src: url('/fonts/Fraunces_600SemiBold_Italic.ttf') format('truetype'); }
@font-face { font-family: 'Manrope'; font-weight: 400; font-display: swap; src: url('/fonts/Manrope_400Regular.ttf') format('truetype'); }
@font-face { font-family: 'Manrope'; font-weight: 600; font-display: swap; src: url('/fonts/Manrope_600SemiBold.ttf') format('truetype'); }
@font-face { font-family: 'Manrope'; font-weight: 700; font-display: swap; src: url('/fonts/Manrope_700Bold.ttf') format('truetype'); }

:root {
  --beige0: #FBF5EF; --beige1: #F3E7DC; --beige2: #E9D8C8;
  --rose1: #F1DCD6; --rose2: #DCA79A; --rose3: #C4826F; --rose4: #B06048;
  --brun1: #8A6653; --brun2: #5E4335; --brun3: #3C2A21; --encre-douce: #75604F;
  --carte: #FFFDFB; --erreur: #B4442E; --terracotta-fonce: #8E4632;
  /* La DA « D2 ton sur ton » (Lou, 14/11/2026) : cartes blanches qui flottent, terracotta pour l'action. */
  --ombre: 0 2px 4px rgba(60,42,33,.04), 0 8px 24px rgba(60,42,33,.09);
  --ombre-terracotta: 0 14px 30px rgba(176,96,72,.32);
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--beige0); color: var(--brun2); font: 400 17px/1.6 'Manrope', system-ui, sans-serif; position: relative; overflow-x: hidden; }
/* `clip` rogne les bulles qui débordent sans créer de zone qu'on peut faire défiler (Safari iOS, zoom arrière). */
html, body { overflow-x: clip; }
/* Les bulles du logo, en décor. */
body::before, body::after { content: ''; position: absolute; z-index: -1; border-radius: 50%; background: var(--rose1); pointer-events: none; }
body::before { width: 420px; height: 420px; top: -140px; right: -140px; }
body::after { width: 300px; height: 300px; top: 620px; left: -150px; opacity: .7; }
em { font-family: 'Fraunces', serif; font-style: italic; font-weight: 600; color: var(--rose4); }
.point { color: var(--rose3); }
a { color: var(--rose4); text-underline-offset: 3px; }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible {
  outline: 3px solid var(--rose3); outline-offset: 2px;
}
.passer { position: absolute; left: -9999px; }
.passer:focus { left: 16px; top: 16px; background: var(--carte); padding: 8px 12px; border-radius: 8px; z-index: 10; }

header.tete { max-width: 1100px; margin: 0 auto; padding: 18px 20px; display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.marque { font: 700 26px/1 'Fraunces', serif; color: var(--brun3); text-decoration: none; letter-spacing: -.3px; }
nav.tete-liens { display: flex; gap: 18px; align-items: center; flex-wrap: wrap; }
nav.tete-liens a { color: var(--brun2); font-weight: 600; text-decoration: none; }
nav.tete-liens a:hover { color: var(--rose4); }

main { max-width: 1100px; margin: 0 auto; padding: 0 20px 64px; }
/* La colonne garde la largeur de l'en-tête (le texte part sous le logo) ; seule la longueur des lignes est limitée. */
main.lecture > * { max-width: 720px; }
main p, main li { overflow-wrap: anywhere; }
h1, h2, h3 { font-family: 'Fraunces', serif; color: var(--brun3); line-height: 1.2; }
h1 { font-size: clamp(32px, 6vw, 54px); font-weight: 700; margin: 24px 0 14px; letter-spacing: -.5px; }
h2 { font-size: clamp(22px, 3.4vw, 30px); font-weight: 600; margin: 40px 0 12px; }
h3 { font-size: 20px; font-weight: 600; margin: 28px 0 8px; }
p { margin: 0 0 14px; }
strong { color: var(--brun3); font-weight: 700; }
ul { padding-left: 22px; } li { margin-bottom: 6px; }

.bouton { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 50px; padding: 0 26px;
  border-radius: 100px; border: 0; background: var(--rose4); color: #fff; font: 700 16px 'Manrope', sans-serif; text-decoration: none; cursor: pointer; box-shadow: var(--ombre); }
.bouton:hover { filter: brightness(1.06); }
.bouton[aria-disabled="true"], .bouton:disabled { opacity: .5; cursor: not-allowed; }
.bouton.contour { background: var(--carte); color: var(--rose4); border: 0; box-shadow: var(--ombre); }

.accueil { display: grid; grid-template-columns: 1.1fr .9fr; gap: 40px; align-items: center; padding: 30px 0 10px; }
.accroche { font-size: clamp(18px, 2.4vw, 21px); color: var(--brun2); max-width: 34ch; }
.actions { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 22px; }
.ecran { background: var(--beige0); border-radius: 36px; box-shadow: var(--ombre); padding: 26px 22px; position: relative; overflow: hidden; }
.ecran::before { content: ''; position: absolute; width: 220px; height: 220px; border-radius: 50%; background: var(--rose1); top: -80px; right: -80px; }
.ecran > * { position: relative; }
.ecran-bonjour { font: 700 28px/1.1 'Fraunces', serif; color: var(--brun3); margin: 0 0 10px; }
.pastilles { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 16px; }
.pastilles span { font: 700 12px 'Manrope', sans-serif; padding: 6px 11px; border-radius: 100px; }
.pastilles .pleine { background: var(--rose4); color: #fff; }
.pastilles .douce { background: var(--rose1); color: var(--terracotta-fonce); }
.pastilles .foncee { background: var(--terracotta-fonce); color: #fff; }
.en-cours { display: flex; gap: 14px; align-items: flex-end; background: var(--rose4); border-radius: 24px; padding: 16px; box-shadow: var(--ombre-terracotta); position: relative; overflow: hidden; color: var(--beige0); }
.en-cours::before { content: ''; position: absolute; width: 150px; height: 150px; border-radius: 50%; background: var(--rose3); top: -60px; right: -40px; }
.en-cours > * { position: relative; }
/* Le bloc texte prend toute la place à droite de la couverture : la barre va jusqu'au bord de la carte. */
.en-cours > div:last-child { flex: 1; min-width: 0; }
.en-cours .couv { width: 92px; height: 138px; border-radius: 10px; flex: none; box-shadow: 0 12px 24px rgba(40,15,5,.35); }
.en-cours small { font: 700 10px 'Manrope', sans-serif; letter-spacing: 1.2px; color: #F6D3C6; }
.en-cours b { display: block; font: 700 20px/1.15 'Fraunces', serif; margin-top: 2px; }
.en-cours span { display: block; font-size: 13px; color: #F6DED5; }
.en-cours .piste { height: 6px; border-radius: 6px; background: rgba(255,255,255,.28); margin-top: 12px; overflow: hidden; }
.en-cours .piste i { display: block; height: 100%; background: var(--beige0); border-radius: 6px; }
.en-cours .pos { font-weight: 700; color: var(--beige0); margin-top: 6px; }
.vignettes { display: flex; gap: 10px; margin-top: 14px; }
.vignettes .couv { width: 64px; height: 94px; border-radius: 10px; background: var(--beige1); box-shadow: var(--ombre); border: 6px solid var(--carte); }
.vignettes .plus { width: 64px; height: 94px; border-radius: 12px; border: 2px dashed var(--rose2); display: grid; place-items: center; color: var(--rose4); font: 700 26px 'Manrope', sans-serif; }
/*
 * Les six cases (cinq couvertures et le « + ») se partagent toute la largeur et gardent leur proportion :
 * la rangée va d'un bord à l'autre de la carte, comme le bloc « en cours » au-dessus (Lou, 02/12/2026).
 * Une base calculée et non `flex: 1 1 0` : celle-ci partage la place entre les contenus, bordure non comprise,
 * et la case « + » (bordure de 2) sortait plus étroite que les couvertures (bordure de 6).
 */
.vignettes > .couv, .vignettes > .plus { flex: 0 0 calc((100% - 50px) / 6); width: auto; height: auto; aspect-ratio: 64 / 94; }
.vignettes .couv { border-width: 4px; }

/* Une, deux puis quatre colonnes : jamais trois cartes et une orpheline (iPad vertical). */
.grille { display: grid; grid-template-columns: 1fr; gap: 16px; margin-top: 18px; }
@media (min-width: 600px) {
  .grille { grid-template-columns: repeat(2, 1fr); }
  /* Deux lignes réservées au titre : les paragraphes d'une même rangée partent à la même hauteur. */
  .grille .carte h3 { min-height: 2.4em; }
}
@media (min-width: 1000px) { .grille { grid-template-columns: repeat(4, 1fr); } }
.carte { background: var(--carte); border-radius: 20px; padding: 22px; box-shadow: var(--ombre); }
.carte h3 { margin-top: 6px; }
.pastille-icone { width: 44px; height: 44px; border-radius: 50%; background: var(--rose1); color: var(--terracotta-fonce); display: grid; place-items: center; font: 700 18px 'Fraunces', serif; }

.bandeau { background: var(--carte); border-radius: 26px; padding: 28px; margin-top: 40px; box-shadow: var(--ombre); }
.bandeau.terracotta { background: var(--rose4); color: var(--beige0); box-shadow: var(--ombre-terracotta); position: relative; overflow: hidden; }
.bandeau.terracotta::before { content: ''; position: absolute; width: 260px; height: 260px; border-radius: 50%; background: var(--rose3); top: -110px; right: -70px; }
.bandeau.terracotta > * { position: relative; }
.bandeau.terracotta h2 { color: var(--beige0); }
.sources { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.sources span { background: var(--beige0); color: var(--terracotta-fonce); font: 700 13px 'Manrope', sans-serif; padding: 7px 13px; border-radius: 100px; }
form { display: grid; gap: 14px; max-width: 560px; }
form > * { min-width: 0; }
label { font-weight: 700; color: var(--brun3); font-size: 15px; display: grid; gap: 6px; }
input, select, textarea { font: 400 16px 'Manrope', sans-serif; color: var(--brun3); background: var(--carte);
  border: 1.5px solid var(--rose1); border-radius: 12px; padding: 12px 14px; min-height: 48px; width: 100%; }
textarea { min-height: 110px; resize: vertical; }
.case { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; color: var(--brun2); overflow-wrap: anywhere; }
.case input { width: 22px; height: 22px; min-height: 0; margin-top: 2px; accent-color: var(--rose4); flex: none; }
.choix-plateforme { border: 0; padding: 0; margin: 0 0 14px; display: flex; flex-wrap: wrap; gap: 8px 24px; }
.choix-plateforme legend { font-weight: 700; color: var(--brun); padding: 0; margin-bottom: 8px; width: 100%; }
.choix-plateforme .case { align-items: center; }
.aide { font-size: 14px; color: var(--encre-douce); font-weight: 400; }
.message { padding: 12px 14px; border-radius: 12px; font-weight: 600; }
.message.ok { background: var(--rose1); color: var(--brun3); }
.message.erreur { background: #F6DAD3; color: var(--erreur); }
.brouillon { background: var(--rose1); color: var(--brun3); border-radius: 12px; padding: 10px 14px; font-weight: 600; font-size: 15px; }

.fiche { background: var(--carte); box-shadow: var(--ombre); border-radius: 14px; padding: 14px 16px; margin-bottom: 10px; }
.fiche dt { font-size: 12px; letter-spacing: .5px; text-transform: uppercase; color: var(--brun1); font-weight: 700; margin-top: 8px; }
.fiche dd { margin: 2px 0 0; font-size: 15px; }
.fiche .titre-fiche { font-weight: 700; color: var(--brun3); }

footer.pied { border-top: 1px solid var(--beige2); padding: 28px 20px 40px; text-align: center; font-size: 14px; color: var(--encre-douce); }
footer.pied nav { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; margin-bottom: 10px; }
footer.pied a { color: var(--brun2); }
/* Les liens restent dans les marges de l'en-tête (1100 moins 2 x 20). */
footer.pied nav, footer.pied p { max-width: 1060px; margin-left: auto; margin-right: auto; }

@media (max-width: 760px) {
  .accueil { grid-template-columns: 1fr; gap: 26px; }
  nav.tete-liens .secondaire { display: none; }
  body { font-size: 16px; }
}

.bientot { margin-top: 14px; font-size: 15px; color: var(--encre-douce); }
nav.tete-liens a.bouton { white-space: nowrap; }
.bouton.petit { min-height: 40px; padding: 0 16px; font-size: 14px; }
nav.tete-liens a.bouton:not(.contour), nav.tete-liens a.bouton:not(.contour):hover { color: #fff; }
nav.tete-liens { gap: 10px; }
nav.tete-liens .secondaire { margin-right: 8px; }
.autre-langue { font-size: 14px; margin: 0 0 6px; }

/* La maquette d'écran de l'accueil : les trois pastilles tiennent sur une ligne. */
@media (max-width: 800px) {
  .pastilles span { padding: 5px 9px; }
}
/*
 * Tablette verticale (deux colonnes encore, mais étroites) : la maquette prend la moitié de la largeur
 * au lieu de 45 %, assez pour que « 24 terminées en 2026 » reste sur la ligne des deux autres pastilles.
 */
@media (min-width: 761px) and (max-width: 900px) {
  .accueil { grid-template-columns: 1fr 1fr; }
}
/* Petit téléphone : « Se connecter » et « S'inscrire » restent sur une ligne, l'en-tête garde sa hauteur. */
@media (max-width: 420px) {
  nav.tete-liens { flex-wrap: nowrap; gap: 8px; }
  .bouton.petit { padding: 0 12px; font-size: 13px; }
}
/* Écran extérieur des pliables, petit téléphone : seule « S'inscrire » reste, sinon elle sortait de l'écran. */
@media (max-width: 360px) {
  nav.tete-liens a.bouton.contour { display: none; }
}
/* La fiche d'une œuvre : à côté de la couverture, un titre long ne fait plus six lignes. */
@media (max-width: 500px) {
  .tete-oeuvre h1 { font-size: 26px; }
}
/* Un mot long du titre se coupe plutôt que de sortir de la colonne. */
.tete-oeuvre h1 { overflow-wrap: break-word; }
/* Très étroit : la couverture au-dessus du titre, qui prend alors toute la largeur. */
@media (max-width: 360px) {
  .tete-oeuvre { flex-direction: column; }
}

/* Très petits écrans (pliables fermés) : les trois pastilles de la maquette restent sur une ligne. */
@media (max-width: 360px) {
  .pastilles { gap: 4px; }
  .pastilles span { font-size: 10.5px; padding: 4px 7px; }
}
