/* BeeLoved : le style de l'appli (BeeLoved/Core/Theme.swift). Fond crème, encre, miel ; Gaegu pour les titres,
   Nunito pour le texte (licence OFL, dans fonts/) ; contours au feutre (feutre.js). */

@font-face { font-family: Gaegu; src: url(fonts/gaegu-bold.woff) format("woff"); font-weight: 700; font-display: swap; }
@font-face { font-family: Nunito; src: url(fonts/nunito-regular.woff) format("woff"); font-weight: 400; font-display: swap; }
@font-face { font-family: Nunito; src: url(fonts/nunito-bold.woff) format("woff"); font-weight: 700; font-display: swap; }
@font-face { font-family: Nunito; src: url(fonts/nunito-extrabold.woff) format("woff"); font-weight: 800; font-display: swap; }

:root {
  color-scheme: light;
  --page: #FBF6EC;
  --ink: #2B2A28;
  --text: #4A4640;
  --sec: #6B665E;
  --faint: #A69E91;
  --bee: #F7CF4F;
  --honey: #FDF1C8;
  --honey-text: #8A6416;
  --nectar: #F5B731;
  --rule: #ECE3D4;
  --segment: #F3EEE5;
  --lawn: #D4EBC5;
  --pink: #F5A3B1;
  --pink-tint: #FCE3E8;
  --lilac-tint: #EFE2F7;
  --blue-tint: #E4EAFA;
  --hand: Gaegu, "Chalkboard SE", "Comic Sans MS", cursive;
  --round: Nunito, ui-rounded, "SF Pro Rounded", -apple-system, system-ui, sans-serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--page);
  color: var(--ink);
  font: 400 17px/1.6 var(--round);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; }
h1, h2, h3 { font-family: var(--hand); font-weight: 700; line-height: 1.05; margin: 0; letter-spacing: 0.01em; }
p { margin: 0 0 1em; }
a { color: inherit; text-decoration-color: var(--nectar); text-decoration-thickness: 2px; text-underline-offset: 3px; }
a:hover { text-decoration-color: var(--ink); }
:focus-visible { outline: 3px solid var(--nectar); outline-offset: 3px; border-radius: 10px; }
strong { font-weight: 800; }

.wrap { max-width: 1040px; margin: 0 auto; padding: 0 20px; }
.wrap.lecture { max-width: 720px; }

/* ---------- Contour au feutre ---------- */
.feutre { position: relative; }
.feutre > svg.trait { position: absolute; left: 0; top: 0; overflow: visible; pointer-events: none; }
.feutre > svg.trait path { fill: none; stroke: var(--ink); stroke-linecap: round; stroke-linejoin: round; }
/* Sans JavaScript : un contour simple. */
html:not(.js) .feutre { box-shadow: inset 0 0 0 2px var(--ink); }

/* ---------- En-tête et pied de page ---------- */
.haut { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-top: 18px; padding-bottom: 8px; }
.logo { display: inline-flex; align-items: center; gap: 8px; text-decoration: none; }
.logo img { width: 46px; height: 46px; transform: rotate(-6deg); }
.logo span { font: 700 34px/1 var(--hand); }
.haut nav a { font: 700 22px/1 var(--hand); text-decoration: none; padding: 10px 16px; border-radius: 99px; display: inline-block; }
.haut nav a:hover { background: var(--honey); }
.haut nav a[aria-current] { background: var(--honey); }

.bas { margin-top: 72px; padding: 32px 0 40px; border-top: 2px dashed var(--rule); color: var(--sec); font-size: 15px; }
.bas .wrap { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 22px; }
.bas nav { display: flex; flex-wrap: wrap; gap: 6px 20px; }
.bas nav a { font: 700 21px/1.2 var(--hand); color: var(--ink); text-decoration: none; }
.bas nav a:hover, .bas nav a[aria-current] { text-decoration: underline; text-decoration-color: var(--nectar); }
.bas .signe { margin-left: auto; display: flex; align-items: center; gap: 8px; }
.bas .signe img { width: 30px; height: 30px; }

/* ---------- Boutons ---------- */
.bouton {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 54px; padding: 4px 24px 6px;
  border-radius: 99px; background: var(--bee); color: var(--ink);
  font: 700 25px/1 var(--hand); text-decoration: none;
  transition: transform .12s ease-out;
}
.bouton:hover { transform: rotate(-1deg) scale(1.02); }
.bouton:active { transform: scale(0.97); }
.bouton.blanc { background: #fff; }
.bouton img { width: 26px; height: 26px; }

/* ---------- Titres de section : un trait de surligneur ---------- */
.surligne {
  padding: 0 6px; background: url(img/trait.svg) left bottom 0.02em / 100% 0.42em no-repeat;
  -webkit-box-decoration-break: clone; box-decoration-break: clone;
}
/* Un tour de feutre autour d'un mot. */
.entoure { position: relative; display: inline-block; white-space: nowrap; }
.insecable { white-space: nowrap; }
.entoure::after {
  content: ""; position: absolute; left: -0.22em; right: -0.22em; top: -0.12em; bottom: -0.18em;
  background: url(img/tour.svg) center / 100% 100% no-repeat; pointer-events: none;
}

/* ---------- Écrans de l'appli ---------- */
.ecran { margin: 0; width: 250px; flex: none; position: relative; border-radius: 36px; background: #fff; box-shadow: 0 22px 44px -18px rgba(43, 42, 40, .32); }
.ecran img { display: block; width: 100%; border-radius: 36px; }
.ecran.gauche { transform: rotate(-3deg); }
.ecran.droite { transform: rotate(2.5deg); }

/* ---------- Accueil ---------- */
.une { display: grid; gap: 28px; align-items: center; padding-top: 26px; }
.une h1 { font-size: clamp(48px, 13vw, 74px); line-height: 0.98; }
.une .chapo { font-size: 19px; color: var(--text); margin: 18px 0 26px; max-width: 30em; }
.une .vol { position: relative; height: 92px; }
.une .vol img { position: absolute; left: 0; top: 0; width: 96px; transform: rotate(-10deg); }
.une .vol svg { position: absolute; left: 92px; top: 30px; width: 170px; height: 60px; }
.une .scene { position: relative; display: flex; justify-content: center; padding: 16px 0 10px; }
.une .scene .fl { position: absolute; width: 64px; }
.bientot { display: block; margin-top: 10px; color: var(--sec); font-size: 14px; }

.partie { display: grid; gap: 28px; align-items: center; margin-top: 88px; }
.partie h2 { font-size: clamp(40px, 10vw, 54px); margin-bottom: 14px; }
.partie p { color: var(--text); font-size: 18px; }
.partie .image { display: flex; justify-content: center; }
.partie.seule { text-align: center; }
.partie.seule p { max-width: 32em; margin-left: auto; margin-right: auto; }

.humeurs { list-style: none; margin: 26px 0 0; padding: 0; display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px 6px; }
.humeurs li { display: flex; flex-direction: column; align-items: center; gap: 2px; font: 700 18px/1 var(--hand); color: var(--sec); }
.humeurs img { width: 58px; height: 58px; transition: transform .2s ease-out; }
.humeurs li:hover img { transform: rotate(-12deg) scale(1.12); }

.rdv { list-style: none; margin: 22px 0 0; padding: 0; display: grid; gap: 12px; }
.rdv li { display: flex; align-items: center; gap: 14px; background: #fff; border-radius: 20px; padding: 12px 16px; }
.rdv b { font: 700 23px/1.05 var(--hand); display: block; }
.rdv small { font-size: 14.5px; color: var(--sec); line-height: 1.35; display: block; margin-top: 3px; }
.rdv .pastille { flex: none; width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; font: 700 24px/1 var(--hand); }
.p-miel { background: var(--honey); }
.p-rose { background: var(--pink-tint); }
.p-herbe { background: var(--lawn); }
.p-lilas { background: var(--lilac-tint); }
.p-bleu { background: var(--blue-tint); }

.fin { margin-top: 96px; text-align: center; display: flex; flex-direction: column; align-items: center; gap: 18px; }
.fin img.abeille { width: 120px; transform: rotate(8deg); }
.fin h2 { font-size: clamp(40px, 10vw, 54px); }

/* ---------- Pages à lire ---------- */
.page-titre { padding-top: 30px; margin-bottom: 8px; display: flex; align-items: flex-end; gap: 14px; }
.page-titre h1 { font-size: clamp(46px, 12vw, 62px); }
.date { color: var(--sec); font-size: 14px; font-weight: 800; margin: 0 0 28px; }
.lecture h2 { font-size: 32px; margin: 42px 0 12px; }
.lecture h3 { font-size: 24px; margin: 22px 0 6px; }
.lecture p, .lecture li { color: var(--text); }
.lecture ul { padding-left: 1.2em; margin: 0 0 1em; }
.lecture li { margin: 0.35em 0; }
.lecture li::marker { color: var(--nectar); }

.carte { background: #fff; border-radius: 24px; padding: 20px 22px; margin: 18px 0; }
.carte > :last-child { margin-bottom: 0; }
.carte.miel { background: var(--honey); }
.carte h2:first-child, .carte h3:first-child { margin-top: 0; }

/* Le sommaire défile de côté sur téléphone, comme dans l'appli (LegalView). */
.lecture .sommaire {
  display: flex; gap: 8px; margin: 0 -20px 8px; padding: 2px 20px 6px; list-style: none;
  overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch;
}
.lecture .sommaire::-webkit-scrollbar { display: none; }
.sommaire li { flex: none; margin: 0; }
.sommaire a { display: inline-block; font: 700 18px/1 var(--hand); padding: 8px 13px 9px; border-radius: 99px; background: var(--segment); color: var(--sec); text-decoration: none; }
.sommaire a:hover { color: var(--ink); background: var(--honey); }

dl.infos { margin: 0; display: grid; grid-template-columns: 1fr; gap: 2px 18px; }
dl.infos dt { font-weight: 800; color: var(--ink); margin-top: 10px; }
dl.infos dd { margin: 0; color: var(--text); }
dl.infos > div { display: contents; }

/* Questions et réponses (details) */
.faq { display: grid; gap: 12px; margin-top: 18px; }
/* Le contour est sur l'enveloppe : dans un details fermé, seul le summary s'affiche. */
.faq > div { background: #fff; border-radius: 22px; }
.faq summary { list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 20px; font: 700 23px/1.1 var(--hand); }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ""; flex: none; width: 12px; height: 12px; border-right: 2.4px solid var(--ink); border-bottom: 2.4px solid var(--ink); transform: rotate(-45deg); border-radius: 2px; transition: transform .2s; margin-right: 4px; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details > div { padding: 0 20px 18px; color: var(--text); }
.faq details > div > :last-child { margin-bottom: 0; }

.contact { display: flex; flex-wrap: wrap; align-items: center; gap: 16px 20px; }
.contact + p { margin-top: 18px; }
.faq + .ou { margin-top: 28px; }
.cache { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.contact .bulle { font: 700 26px/1.1 var(--hand); background: #fff; padding: 12px 18px; border-radius: 22px 22px 22px 6px; }
.contact img { width: 70px; }
.ou { color: var(--sec); font-size: 15px; margin-top: 14px; }
.chemin { font-weight: 800; color: var(--ink); white-space: nowrap; }

/* ---------- Écrans plus larges ---------- */
@media (min-width: 760px) {
  body { font-size: 18px; }
  .une { grid-template-columns: 1.15fr 1fr; gap: 40px; padding-top: 40px; }
  .partie { grid-template-columns: 1fr 1fr; gap: 56px; margin-top: 120px; }
  .partie.inverse .image { order: -1; }
  .ecran { width: 280px; }
  .partie.seule { grid-template-columns: 1fr; }
  .lecture .sommaire { flex-wrap: wrap; margin: 0 0 8px; padding: 0; overflow: visible; }
  .humeurs { grid-template-columns: repeat(10, 1fr); }
  dl.infos { grid-template-columns: minmax(150px, max-content) 1fr; }
  dl.infos dt { margin-top: 0; }
  dl.infos dt, dl.infos dd { padding: 8px 0; border-bottom: 1.5px solid var(--rule); }
}

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