:root {
  --accent: #E03131;
  --accent-dark: #B02525;
  --accent-soft: #FDECEC;
  --green: #3F9142;
  --green-soft: #E8F3E8;
  --amber: #C77700;
  --amber-soft: #FBF0DE;
  --blue: #2D6FB8;
  --blue-soft: #E7F0F9;
  --purple: #6B4FA8;
  --purple-soft: #EFEAF8;
  --cream: #FDF8F1;
  --ink: #1E1B18;
  --ink-2: #5C554E;
  --ink-3: #8C847B;
  --line: #E8E0D5;
  --white: #FFFFFF;
  --radius: 12px;
  --radius-lg: 18px;
  --maxw: 1180px;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Roboto, Helvetica, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 20px; }

h1, h2, h3 { line-height: 1.2; margin: 0 0 12px; font-weight: 800; letter-spacing: -0.02em; }
h1 { font-size: 44px; }
h2 { font-size: 29px; }
h3 { font-size: 19px; font-weight: 700; letter-spacing: -0.01em; }
p { margin: 0 0 14px; }

.icn { width: 1em; height: 1em; display: inline-block; vertical-align: -0.125em; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- Barre supérieure ---------- */
.topbar { background: var(--white); border-bottom: 1px solid var(--line); }
.topbar-in { display: flex; align-items: center; gap: 24px; height: 78px; }

.logo { display: flex; align-items: center; gap: 12px; flex-shrink: 0; }
.logo-mark {
  width: 46px; height: 46px; border-radius: 14px;
  background: var(--accent); color: #fff;
  display: grid; place-items: center; font-size: 24px;
}
.logo-text { font-weight: 800; font-size: 23px; letter-spacing: -0.03em; line-height: 1.1; }
.logo-sub { font-size: 10px; color: var(--ink-3); font-weight: 700; letter-spacing: .14em; text-transform: uppercase; }

.baseline { font-size: 14px; color: var(--ink-2); font-style: italic; max-width: 200px; line-height: 1.35; }

.search { flex: 1; min-width: 0; max-width: 370px; margin-left: auto; position: relative; }
.search input {
  width: 100%; height: 46px; border-radius: 999px;
  border: 1px solid var(--line); background: var(--cream);
  padding: 0 46px 0 20px; font-size: 15px; font-family: inherit; color: var(--ink);
}
.search input:focus { outline: none; border-color: var(--accent); background: #fff; }
.search button {
  position: absolute; right: 6px; top: 6px;
  width: 34px; height: 34px; border-radius: 50%;
  border: 0; background: transparent; cursor: pointer; color: var(--ink-2);
  display: grid; place-items: center; font-size: 18px;
}
.search button:hover { background: var(--accent-soft); color: var(--accent); }

/* ---------- Sélecteur de profil ---------- */
.prof-switch { position: relative; flex-shrink: 0; }
.prof-chip {
  display: flex; align-items: center; gap: 9px;
  background: var(--cream); border: 1px solid var(--line); border-radius: 999px;
  padding: 6px 12px 6px 6px; cursor: pointer; font-family: inherit; color: var(--ink);
  max-width: 230px;
}
.prof-chip:hover { border-color: var(--ink-3); }
.prof-chip-txt { display: flex; flex-direction: column; align-items: flex-start; min-width: 0; line-height: 1.25; }
.prof-chip-nom { font-size: 14px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 130px; }
.prof-chip-sous { font-size: 11px; color: var(--ink-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 130px; }

.prof-pastille {
  width: 32px; height: 32px; border-radius: 50%; flex-shrink: 0;
  background: var(--accent); color: #fff;
  display: grid; place-items: center; font-weight: 800; font-size: 14px;
}
.prof-pastille.grand { width: 46px; height: 46px; font-size: 19px; }

.prof-menu {
  position: absolute; top: calc(100% + 8px); right: 0; z-index: 50;
  background: var(--white); border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: 0 8px 28px rgba(30, 27, 24, .12);
  min-width: 250px; padding: 6px; display: flex; flex-direction: column; gap: 2px;
}
/* display:flex ci-dessus écrase le display:none de l'attribut hidden : on le rétablit,
   sinon le menu fermé occupe toujours de la place et déborde sur mobile. */
.prof-menu[hidden] { display: none; }
.prof-menu-item {
  display: flex; align-items: center; gap: 10px; width: 100%;
  background: transparent; border: 0; border-radius: 8px; padding: 9px 10px;
  cursor: pointer; font-family: inherit; text-align: left; color: var(--ink);
}
.prof-menu-item:hover { background: var(--cream); }
.prof-menu-item.on { background: var(--accent-soft); }
.prof-menu-nom { display: block; font-size: 14px; font-weight: 700; }
.prof-menu-sous { display: block; font-size: 12px; color: var(--ink-3); }
.prof-menu-coche { margin-left: auto; color: var(--accent); font-weight: 800; }
.prof-menu-lien {
  display: block; padding: 10px; margin-top: 4px; border-top: 1px solid var(--line);
  font-size: 14px; font-weight: 700; color: var(--accent); text-align: center;
}
.prof-menu-lien:hover { background: var(--cream); }

/* ---------- Cartes de profil ---------- */
.profil-grille { display: grid; grid-template-columns: repeat(auto-fit, minmax(290px, 1fr)); gap: 16px; }
.profil-carte { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }
.profil-carte.actif { border-color: var(--accent); }
.profil-tete { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.profil-tete h3 { margin: 0 0 2px; font-size: 18px; display: flex; align-items: center; gap: 8px; }
.profil-meta { margin: 0; font-size: 13px; color: var(--ink-2); }
.profil-infos { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin: 0 0 16px; }
.profil-infos dt { font-size: 11px; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-3); font-weight: 700; }
.profil-infos dd { margin: 2px 0 0; font-size: 15px; font-weight: 600; }
.profil-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.profil-actions .btn { padding: 8px 14px; font-size: 13px; }
.btn-ghost.danger { color: var(--accent-dark); }
.btn-ghost.danger.confirme { background: var(--accent); color: #fff; border-color: var(--accent); }

/* ---------- Badges de ration sur les cartes ---------- */
.ration-zone { display: flex; flex-wrap: wrap; gap: 6px; }
.ration-zone:not(:empty) { margin-bottom: 12px; }
.ration-badge { font-size: 12px; font-weight: 700; padding: 5px 11px; border-radius: 999px; }
.ration-badge.ok { background: var(--green-soft); color: #2C6B2F; }
.ration-badge.attention { background: var(--amber-soft); color: #8F5600; }
.ration-badge.alerte { background: var(--accent-soft); color: var(--accent-dark); }

.topbar-links { display: flex; gap: 22px; align-items: center; flex-shrink: 0; }
.topbar-link { display: flex; flex-direction: column; align-items: center; gap: 3px; font-size: 12px; color: var(--ink-2); font-weight: 600; }
.topbar-link span:first-child { font-size: 19px; }
.topbar-link:hover { color: var(--accent); }

/* ---------- Navigation ---------- */
.nav { background: var(--white); border-bottom: 1px solid var(--line); }
.nav-in {
  /* La barre déborde et devient défilable si elle ne tient pas : c'est le
     comportement voulu sur mobile. Sur un écran large elle doit tenir, d'où
     ces espacements serrés — le rendu des polices système varie d'un système
     à l'autre et la marge est étroite. */
  display: flex; align-items: center; gap: 2px; height: 62px;
  overflow-x: auto; overflow-y: hidden;
  scrollbar-width: none; -ms-overflow-style: none;
}
.nav-in::-webkit-scrollbar { display: none; }
.nav a {
  /* Espacements serrés : avec huit entrées plus le bouton d'appel, la barre
     dépasse la largeur du conteneur dès 16 px de marge intérieure. */
  display: flex; align-items: center; gap: 6px;
  padding: 9px 11px; border-radius: 999px;
  font-size: 15px; font-weight: 600; color: var(--ink-2); white-space: nowrap;
}
.nav a:hover { background: var(--cream); color: var(--ink); }
.nav a.on { background: var(--accent); color: #fff; }
.nav .spacer { flex: 1; }
.nav .cta { background: var(--accent); color: #fff; padding: 11px 17px; }
.nav .cta:hover { background: var(--accent-dark); color: #fff; }

/* ---------- Hero ---------- */
.hero { background: var(--white); border-bottom: 1px solid var(--line); }
.hero-in { display: grid; grid-template-columns: 1fr 1fr; gap: 44px; align-items: center; padding: 54px 0; }
.hero p.lead { font-size: 17px; color: var(--ink-2); max-width: 470px; }
.hero-art {
  border-radius: var(--radius-lg); overflow: hidden;
  background: #F3E9DA; aspect-ratio: 4 / 3;
  display: grid; place-items: center; position: relative;
}
/* La photo occupe tout le cadre quel que soit le rapport de la colonne :
   le cadrage 4/3 est déjà fait dans le fichier, object-fit ne rogne que sur
   les écrans où la grille s'écarte de ce rapport. */
.hero-art img { width: 100%; height: 100%; object-fit: cover; display: block; }
.hero-art .big { font-size: 96px; line-height: 1; }
.hero-badge {
  position: absolute; top: 22px; right: 22px;
  background: var(--green); color: #fff;
  padding: 11px 17px; border-radius: 10px;
  font-size: 13px; font-weight: 700; line-height: 1.45; text-align: center;
  transform: rotate(-3deg);
}

.btn {
  display: inline-flex; align-items: center; gap: 10px;
  background: var(--accent); color: #fff;
  padding: 15px 28px; border-radius: 999px;
  font-weight: 700; font-size: 16px; border: 0; cursor: pointer; font-family: inherit;
}
.btn:hover { background: var(--accent-dark); }
.btn-ghost { background: transparent; color: var(--ink); border: 1px solid var(--line); padding: 11px 20px; font-size: 14px; }
.btn-ghost:hover { background: var(--white); border-color: var(--ink-3); }

.features { display: flex; gap: 34px; margin-top: 34px; flex-wrap: wrap; }
.feature { display: flex; flex-direction: column; gap: 8px; max-width: 152px; }
.feature-ic { width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center; border: 2px solid currentColor; font-size: 20px; }
.feature-ic.g { color: var(--green); }
.feature-ic.r { color: var(--accent); }
.feature small { font-size: 13px; color: var(--ink-2); font-weight: 600; line-height: 1.35; }

/* ---------- Sections ---------- */
section { padding: 50px 0; }
.sec-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 22px; flex-wrap: wrap; }
.sec-head p { margin: 0; color: var(--ink-2); font-size: 15px; }
.link-more { font-weight: 700; font-size: 15px; display: inline-flex; gap: 8px; align-items: center; }
.link-more:hover { color: var(--accent); }

/* ---------- Catégories ---------- */
.cats { display: grid; grid-template-columns: repeat(auto-fit, minmax(148px, 1fr)); gap: 14px; }
.cat { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 14px; text-align: center; }
.cat:hover { border-color: var(--accent); }
.cat-ic { width: 58px; height: 58px; border-radius: 50%; margin: 0 auto 12px; display: grid; place-items: center; font-size: 27px; }
.cat strong { display: block; font-size: 15px; }
.cat small { color: var(--ink-3); font-size: 13px; }

/* ---------- Cartes recettes ---------- */
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(256px, 1fr)); gap: 20px; }
.card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; position: relative; }
.card:hover { border-color: var(--ink-3); }
/* Toute la carte est cliquable : le lien du titre est étiré sur la carte entière. */
.card-body h3 a::after { content: ""; position: absolute; inset: 0; z-index: 1; }
.card:focus-within { border-color: var(--accent); }
.card-art { aspect-ratio: 16 / 11; display: grid; place-items: center; position: relative; font-size: 52px; }
.card-fav {
  position: absolute; top: 10px; right: 10px;
  width: 34px; height: 34px; border-radius: 50%;
  background: rgba(255,255,255,.92); display: grid; place-items: center;
  color: var(--ink-3); border: 0; cursor: pointer; font-size: 16px; line-height: 1;
  z-index: 2;
}
.card-fav:hover, .card-fav.on { color: var(--accent); }
.card-body { padding: 16px 16px 18px; display: flex; flex-direction: column; flex: 1; }
.card-body h3 { margin-bottom: 8px; }
.card-meta { display: flex; align-items: center; justify-content: space-between; font-size: 13px; color: var(--ink-2); margin-bottom: 10px; }
.card-sum { font-size: 14px; color: var(--ink-2); margin-bottom: 14px; flex: 1; }
.pills { display: flex; gap: 6px; flex-wrap: wrap; }
.pill { font-size: 12px; font-weight: 700; padding: 5px 12px; border-radius: 999px; }
.pill.r { background: var(--accent-soft); color: var(--accent-dark); }
.pill.g { background: var(--green-soft); color: #2C6B2F; }
.pill.b { background: var(--blue-soft); color: #1F548F; }
.pill.a { background: var(--amber-soft); color: #8F5600; }
.pill.p { background: var(--purple-soft); color: #543C87; }

/* ---------- Formulaires ---------- */
.panel { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 28px; }
.field { margin-bottom: 18px; }
.field > label { display: block; font-size: 14px; font-weight: 700; margin-bottom: 8px; }
.field .hint { font-size: 13px; color: var(--ink-3); font-weight: 400; }
input[type="text"], input[type="number"], input[type="email"], select, textarea {
  width: 100%; height: 46px; padding: 0 14px;
  border: 1px solid var(--line); border-radius: 10px;
  background: var(--cream); font-family: inherit; font-size: 15px; color: var(--ink);
}
textarea { height: auto; min-height: 150px; padding: 12px 14px; line-height: 1.6; resize: vertical; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--accent); background: #fff; }

.choices { display: grid; grid-template-columns: repeat(auto-fit, minmax(108px, 1fr)); gap: 8px; }
.choice { position: relative; }
.choice input { position: absolute; opacity: 0; pointer-events: none; }
.choice span {
  display: block; text-align: center; cursor: pointer;
  padding: 11px 8px; border: 1px solid var(--line); border-radius: 10px;
  background: var(--cream); font-size: 14px; font-weight: 600;
}
.choice small { display: block; font-weight: 400; font-size: 12px; color: var(--ink-3); }
.choice input:checked + span { border-color: var(--accent); background: var(--accent-soft); color: var(--accent-dark); }
.choice input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }

.checks { display: grid; grid-template-columns: repeat(auto-fit, minmax(145px, 1fr)); gap: 8px; }
.check { display: flex; align-items: center; gap: 8px; font-size: 14px; }
.check input { width: auto; height: auto; }

.error { color: var(--accent-dark); font-size: 14px; font-weight: 600; margin: 6px 0 0; }
.notice { background: var(--green-soft); border-left: 4px solid var(--green); padding: 14px 18px; font-size: 15px; color: #2C6B2F; margin-bottom: 20px; }
.warn-box { background: var(--accent-soft); border-left: 4px solid var(--accent); padding: 14px 18px; font-size: 15px; color: var(--accent-dark); margin-bottom: 20px; }

/* ---------- Résultat générateur ---------- */
.result-table { width: 100%; border-collapse: collapse; font-size: 15px; }
.result-table td { padding: 11px 0; border-bottom: 1px solid var(--line); vertical-align: top; }
.result-table td:last-child { text-align: right; color: var(--ink-2); white-space: nowrap; }
.result-table tr:last-child td { border-bottom: 0; font-weight: 800; color: var(--ink); padding-top: 16px; }
.role-tag { font-size: 11px; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-3); font-weight: 700; display: block; }

.verdict { border-radius: var(--radius); padding: 16px 20px; margin: 20px 0 0; }
.verdict strong { font-size: 19px; }
.verdict.ok { background: var(--green-soft); color: #2C6B2F; }
.verdict.attention { background: var(--amber-soft); color: #8F5600; }
.verdict.alerte { background: var(--accent-soft); color: var(--accent-dark); }

/* ---------- Conseils / sécurité ---------- */
.tips { display: grid; grid-template-columns: repeat(auto-fit, minmax(288px, 1fr)); gap: 18px; }
.tip { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.tip h3 { display: flex; align-items: center; gap: 10px; }
.tip p { font-size: 15px; color: var(--ink-2); margin: 0; }

.danger-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(258px, 1fr)); gap: 12px; }
.danger { background: var(--accent-soft); border-radius: 0 var(--radius) var(--radius) 0; padding: 16px 18px; border-left: 4px solid var(--accent); }
.danger strong { display: block; color: var(--accent-dark); text-transform: capitalize; margin-bottom: 4px; }
.danger span { font-size: 14px; color: var(--ink-2); }

/* ---------- Fiche recette ---------- */
.recipe-head { display: grid; grid-template-columns: 1.05fr 1fr; gap: 36px; align-items: start; }
.recipe-art { border-radius: var(--radius-lg); aspect-ratio: 4/3; display: grid; place-items: center; font-size: 96px; }
.steps { counter-reset: s; list-style: none; padding: 0; margin: 0; }
.steps li { counter-increment: s; position: relative; padding: 0 0 20px 48px; }
.steps li::before {
  content: counter(s); position: absolute; left: 0; top: 0;
  width: 32px; height: 32px; border-radius: 50%;
  background: var(--accent); color: #fff;
  display: grid; place-items: center; font-weight: 800; font-size: 15px;
}
.steps li:not(:last-child)::after { content: ""; position: absolute; left: 15px; top: 36px; bottom: 6px; width: 2px; background: var(--line); }
.callout { background: var(--amber-soft); border-left: 4px solid var(--amber); padding: 16px 20px; font-size: 15px; color: #7A4A00; border-radius: 0 var(--radius) var(--radius) 0; }

/* ---------- Bandeau vétérinaire ---------- */
.vetbar { background: #2B2724; color: #F2ECE4; padding: 15px 0; font-size: 14px; }
.vetbar .wrap { display: flex; gap: 12px; align-items: center; }
.vetbar strong { color: #fff; }
.vetbar a { text-decoration: underline; }

/* ---------- Pied de page ---------- */
footer { background: var(--white); border-top: 1px solid var(--line); padding: 44px 0 28px; margin-top: 40px; }
.foot-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 32px; margin-bottom: 28px; }
.foot-grid h4 { font-size: 14px; margin: 0 0 12px; }
.foot-grid a { display: block; font-size: 14px; color: var(--ink-2); padding: 4px 0; }
.foot-grid a:hover { color: var(--accent); }
.foot-legal { border-top: 1px solid var(--line); padding-top: 20px; font-size: 13px; color: var(--ink-3); }

/* ---------- Divers ---------- */
.empty { background: var(--white); border: 1px dashed var(--line); border-radius: var(--radius); padding: 48px 24px; text-align: center; color: var(--ink-2); }
.filters { display: flex; gap: 10px; flex-wrap: wrap; align-items: flex-end; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; margin-bottom: 24px; }
.filters .f { flex: 1; min-width: 148px; }
.filters label { display: block; font-size: 13px; font-weight: 700; margin-bottom: 6px; }
.count { color: var(--ink-2); font-size: 15px; margin-bottom: 18px; }
.prose { max-width: 720px; }
.prose h2 { margin-top: 30px; }

.cta-panel { display: grid; grid-template-columns: 1fr auto; gap: 28px; align-items: center; }
.cta-panel .btn { white-space: nowrap; }

.gen-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; align-items: start; margin-top: 28px; }
.recipe-cols { display: grid; grid-template-columns: 1fr 1.4fr; gap: 34px; align-items: start; }

@media (max-width: 900px) {
  h1 { font-size: 33px; }
  h2 { font-size: 24px; }
  .hero-in, .recipe-head { grid-template-columns: 1fr; }
  /* Sur une colonne, la photo passe devant le texte : c'est elle l'accroche,
     et elle serait sinon sous le pli sur un téléphone. */
  .hero-art { order: -1; margin-bottom: 26px; }
  .baseline, .topbar-links { display: none; }
  .foot-grid { grid-template-columns: 1fr 1fr; }
  .topbar-in { height: 66px; gap: 10px; }
  .search { max-width: none; }
  .logo-sub { display: none; }
  .cta-panel, .gen-grid, .recipe-cols { grid-template-columns: 1fr; }
  .cta-panel .btn { justify-content: center; }
  /* Le sélecteur de profil reste visible sur mobile, contrairement aux liens rapides. */
  .prof-chip { max-width: 160px; padding: 5px 9px 5px 5px; }
  .prof-chip-nom, .prof-chip-sous { max-width: 84px; }
  .prof-menu { right: auto; left: 0; min-width: 230px; }
  .profil-infos { grid-template-columns: 1fr; }
}

/* Très petits écrans : le chip se réduit à la pastille et au prénom. */
@media (max-width: 400px) {
  .prof-chip { max-width: none; padding: 4px; gap: 6px; }
  .prof-chip-sous { display: none; }
  .prof-chip-nom { max-width: 56px; font-size: 13px; }
  .prof-chip .icn { display: none; }
  .prof-menu { min-width: 200px; max-width: calc(100vw - 32px); }
}

/* ---------- Carnet de ration ---------- */
.carnet-onglets { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 16px; }
.carnet-onglet {
  display: inline-flex; align-items: center; gap: 7px;
  background: var(--white); border: 1px solid var(--line);
  border-radius: 999px; padding: 8px 16px;
  font-size: 14px; font-weight: 600; color: var(--ink-2);
  font-family: inherit; cursor: pointer;
}
.carnet-onglet:hover { border-color: var(--ink-3); }
.carnet-onglet.on { background: var(--accent); border-color: var(--accent); color: #fff; }

.carnet-jours { display: flex; align-items: center; gap: 14px; margin-bottom: 20px; }
.carnet-date { font-weight: 700; font-size: 17px; }
.carnet-jour { font-size: 14px; font-weight: 600; color: var(--ink-2); display: inline-flex; align-items: center; gap: 4px; }
.carnet-jour:hover { color: var(--accent); }
#carnet-hier .icn { transform: rotate(90deg); }
#carnet-demain .icn { transform: rotate(-90deg); }

.carnet-grid { display: grid; grid-template-columns: 340px 1fr; gap: 28px; align-items: start; }

.carnet-chiffres { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-bottom: 4px; }
.carnet-chiffres div { display: flex; flex-direction: column; }
.carnet-chiffres strong { font-size: 30px; font-weight: 800; letter-spacing: -0.02em; line-height: 1.15; }
.carnet-chiffres span { font-size: 12px; color: var(--ink-3); font-weight: 600; }
.carnet-legende { font-size: 14px; color: var(--ink-2); margin: 10px 0 18px; }

/* Jauge des friandises. Le repère des 10 % est un trait vertical : c'est une
   limite indicative, pas la fin de la barre, et il ne faut pas laisser croire
   que la dépasser est un échec. */
.carnet-jauge { position: relative; height: 12px; background: var(--cream); border: 1px solid var(--line); border-radius: 999px; overflow: hidden; }
.carnet-jauge-barre { height: 100%; border-radius: 999px; transition: width .25s ease; }
.carnet-jauge-barre.ok { background: var(--green); }
.carnet-jauge-barre.attention { background: var(--amber); }
.carnet-jauge-barre.alerte { background: var(--accent); }
.carnet-jauge-repere { position: absolute; top: 0; bottom: 0; width: 2px; background: var(--ink); opacity: .75; }
.carnet-jauge-txt { font-size: 13px; color: var(--ink-2); margin: 10px 0 0; }

.carnet-suppr {
  background: none; border: 0; cursor: pointer; font-family: inherit;
  font-size: 19px; line-height: 1; color: var(--ink-3);
  padding: 0 0 0 12px;
}
.carnet-suppr:hover { color: var(--accent); }
.carnet-suppr:disabled { opacity: .4; cursor: default; }

.carnet-barres { display: flex; align-items: flex-end; gap: 10px; height: 130px; margin-top: 16px; }
.carnet-barre { flex: 1; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: 7px; height: 100%; }
.carnet-barre-fut {
  width: 100%; min-height: 3px; border-radius: 6px 6px 0 0;
  background: var(--blue-soft); display: flex; flex-direction: column; justify-content: flex-end;
}
.carnet-barre-fri { width: 100%; background: var(--blue); border-radius: 6px 6px 0 0; }
.carnet-barre.vide .carnet-barre-fut { background: repeating-linear-gradient(45deg, var(--line), var(--line) 3px, transparent 3px, transparent 7px); }
.carnet-barre span { font-size: 11px; color: var(--ink-3); font-weight: 700; }

.recipe-actions { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }
.carnet-ajout-note { font-size: 13px; color: var(--ink-2); margin: 0; max-width: 340px; }
.carnet-ajout-note a { color: var(--accent); font-weight: 600; text-decoration: underline; }


@media (max-width: 900px) {
  .carnet-grid { grid-template-columns: 1fr; }
  .carnet-chiffres strong { font-size: 25px; }
  .carnet-barres { height: 108px; gap: 6px; }
}

/* display:inline-flex plus haut écrase le display:none de l'attribut hidden.
   Même piège que .prof-menu[hidden] : sans cette ligne, les deux liens de
   navigation entre les jours restent visibles en permanence. */
.carnet-jour[hidden] { display: none; }
