/* ============================================================
 *  panel-compact.css — 25/11/2026
 *  1) Menu latéral plus compact (on voit plus d'entrées sans défiler).
 *  2) Clients : liste à gauche, fiche à droite (tiroir plein écran sur mobile).
 *  Chargée APRÈS panel-skin.css : vaut pour la nouvelle et l'ancienne apparence.
 *  Retour arrière : retirer la ligne <link> dans gerer.php / elevage.php.
 * ============================================================ */

/* 1) Menu latéral compact : retiré le 25/11/2026 au soir à la demande de Tom (rendu jugé moins beau). */

/* ---------- 2) Clients : liste + fiche ---------- */
.cli-split { display: grid; grid-template-columns: minmax(250px, 320px) minmax(0, 1fr);
  border: 1px solid var(--line); border-radius: 12px; overflow: hidden; background: var(--card);
  height: clamp(480px, calc(100vh - 230px), 860px); margin-top: 14px; }
.cli-list { display: flex; flex-direction: column; min-height: 0; border-right: 1px solid var(--line); background: var(--card); }
.cli-search { padding: 10px 10px 6px; }
.cli-search input { width: 100%; border: 1px solid var(--line); border-radius: 8px; padding: 8px 11px;
  font: inherit; font-size: .88rem; background: var(--card); color: var(--ink); }
.cli-chips { display: flex; gap: 6px; flex-wrap: wrap; padding: 2px 10px 8px; border-bottom: 1px solid var(--line); }
.cli-chip { border: 1px solid var(--line); background: transparent; color: var(--muted); border-radius: 999px;
  padding: 3px 10px; font: inherit; font-size: .76rem; font-weight: 600; cursor: pointer; }
.cli-chip span { opacity: .7; margin-left: 2px; }
.cli-chip.on { background: var(--ink); color: #fff; border-color: var(--ink); }
.cli-items { flex: 1; overflow-y: auto; padding: 4px 6px 10px; }
.cli-grp { font-size: .7rem; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--muted-2);
  padding: 12px 8px 4px; }
.cli-item { display: flex; align-items: center; gap: 9px; width: 100%; text-align: left; border: 0; background: transparent;
  padding: 6px 8px; border-radius: 8px; cursor: pointer; font: inherit; color: var(--ink); min-height: 44px; }
.cli-item:hover { background: rgba(0, 0, 0, .04); }
.cli-item.on { background: var(--brass-soft); }
.cli-item[hidden], .cli-grp[hidden] { display: none; }
.cli-nm { flex: 1; min-width: 0; font-size: .88rem; font-weight: 600; line-height: 1.25; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cli-nm em { font-weight: 400; color: var(--muted); font-style: normal; }
.cli-nm small { display: block; font-weight: 400; color: var(--muted); font-size: .74rem; overflow: hidden; text-overflow: ellipsis; }
.cli-flag { font-size: .8rem; }
.cli-dot { width: 9px; height: 9px; border-radius: 50%; background: #9a9384; flex: none; }
.cli-dot.active { background: #3a9d5d; }
.cli-dot.pending { background: #C99A3E; }
.cli-dot.banned { background: #c0392b; }
.cli-none, .cli-note { color: var(--muted); font-size: .8rem; padding: 10px 8px; margin: 0; }

.cli-detail { min-width: 0; min-height: 0; overflow-y: auto; position: relative; }
.cli-empty { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; height: 100%;
  color: var(--muted); font-size: .92rem; text-align: center; padding: 24px; }
.cli-empty .ic { font-size: 2rem; opacity: .5; }
.cli-split.sel .cli-empty { display: none; }
.cli-fiche[hidden] { display: none; }
.cli-fhead { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; padding: 16px 20px 10px; }
.cli-ft { flex: 1; min-width: 160px; }
.cli-ft h3 { margin: 0 0 4px; font-family: Fraunces, Georgia, serif; font-size: 1.2rem; font-weight: 600; }
.cli-fm { display: flex; gap: 6px; flex-wrap: wrap; }
.cli-quick { display: flex; gap: 6px; flex-wrap: wrap; }
.cli-back { display: none; border: 0; background: transparent; font: inherit; font-weight: 600; color: var(--brass);
  padding: 6px 0; cursor: pointer; width: 100%; text-align: left; min-height: 40px; }
.cli-tabs { display: flex; gap: 6px; padding: 0 20px 10px; border-bottom: 1px solid var(--line);
  position: sticky; top: 0; background: var(--card); z-index: 2; overflow-x: auto; }
.cli-tabs button { border: 0; background: transparent; font: inherit; font-size: .86rem; font-weight: 600;
  color: var(--muted); padding: 7px 14px; border-radius: 999px; cursor: pointer; white-space: nowrap; min-height: 36px; }
.cli-tabs button.on { background: var(--ink); color: #fff; }
.cli-fbody { padding: 16px 20px 28px; }
.cli-tp[hidden] { display: none; }
.cli-fbody .pnl-modal-foot { flex-wrap: wrap; gap: 8px; }

/* Tablette et mobile : la fiche devient un tiroir plein écran */
@media (max-width: 999px) {
  .cli-split { display: block; height: auto; border: 0; background: transparent; overflow: visible; }
  .cli-list { border: 1px solid var(--line); border-radius: 12px; max-height: none; }
  .cli-items { overflow: visible; }
  .cli-detail { position: fixed; inset: 0; z-index: 90; background: var(--card); overflow-y: auto;
    transform: translateX(100%); transition: transform .2s; visibility: hidden; }
  .cli-split.open .cli-detail { transform: none; visibility: visible; }
  .cli-empty { display: none; }
  .cli-back { display: block; }
  .cli-fhead, .cli-fbody { padding-left: 16px; padding-right: 16px; }
  .cli-tabs { padding-left: 16px; padding-right: 16px; }
}
@media (prefers-reduced-motion: reduce) { .cli-detail { transition: none; } }

/* ---------- Élevage : fiche client complète ---------- */
.elv-cli-av { width: 32px; height: 32px; border-radius: 50%; flex: none; display: inline-flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: .9rem; color: #fff; background: hsl(var(--h, 30) 45% 45%); }
.elv-cli-av.lg { width: 48px; height: 48px; font-size: 1.2rem; }
.cli-badge { display: inline-block; min-width: 18px; padding: 0 5px; margin-left: 4px; border-radius: 999px;
  background: #c0392b; color: #fff; font-size: .7rem; line-height: 18px; text-align: center; }
.cli-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 10px; margin-bottom: 14px; }
.cli-kpis > div { border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; background: var(--card); }
.cli-kpis b { display: block; font-size: 1.05rem; }
.cli-kpis span { font-size: .76rem; color: var(--muted); }
.cli-kpis .warn { border-color: #e3b3ab; background: #fdf3f1; }
.cli-box { border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; margin: 0 0 12px; }
.cli-box h4 { margin: 0 0 8px; font-size: .78rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.cli-dl { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 8px 16px; margin: 0; }
.cli-dl dt { font-size: .74rem; color: var(--muted); }
.cli-dl dd { margin: 0; font-weight: 600; overflow-wrap: anywhere; }
.cli-line { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; padding: 7px 0; border-top: 1px solid var(--line); font-size: .88rem; }
.cli-box h4 + .cli-line { border-top: 0; }
.cli-amt { margin-left: auto; font-weight: 700; white-space: nowrap; }
.elv-cli .elv-todo { display: block; margin-bottom: 12px; }

/* Onglets : passent à la ligne plutôt qu une barre de défilement */
.cli-tabs { flex-wrap: wrap; overflow: visible; }

/* Messages dans la fiche client */
.cli-chat { display: flex; flex-direction: column; gap: 6px; max-height: 52vh; overflow-y: auto; padding: 4px 2px 10px; }
.cli-chat-empty { font-size: .86rem; }
.cli-chat-day { align-self: center; font-size: .72rem; color: var(--muted); margin: 8px 0 2px; }
.cli-msg { display: flex; align-items: flex-end; gap: 8px; max-width: 86%; }
.cli-msg.them { align-self: flex-start; }
.cli-msg.me { align-self: flex-end; flex-direction: row-reverse; }
.cli-bav { width: 28px; height: 28px; border-radius: 50%; flex: none; object-fit: cover; display: inline-flex; align-items: center; justify-content: center;
  font-size: .78rem; font-weight: 700; color: #fff; background: hsl(var(--h, 30) 45% 45%); }
.cli-bav.ph.me { background: #e9e4d8; font-size: .9rem; }
.cli-seen { align-self: flex-end; font-size: .72rem; color: var(--muted); margin: -2px 40px 0 0; }
.cli-seen[hidden] { display: none; }
.cli-bub { max-width: 100%; padding: 8px 12px; border-radius: 14px; font-size: .88rem; line-height: 1.4; overflow-wrap: anywhere; }
.cli-bub span { display: block; font-size: .68rem; opacity: .65; margin-top: 3px; text-align: right; }
.cli-msg.them .cli-bub { background: #f1ede4; border-bottom-left-radius: 4px; }
.cli-msg.me .cli-bub { background: #1B2A4A; color: #fff; border-bottom-right-radius: 4px; }
.cli-chat-form { display: flex; gap: 8px; align-items: flex-end; border-top: 1px solid var(--line); padding-top: 10px; }
.cli-chat-form textarea { flex: 1; border: 1px solid var(--line); border-radius: 10px; padding: 8px 10px; font: inherit; font-size: .9rem; resize: vertical; }

/* ---------- Boutons dorés, plus sobres (25/11/2026) ----------
   Fond doré clair et texte bronze au lieu du doré plein : le bouton principal
   reste repérable sans attirer l'œil partout. Vaut pour les deux apparences. */
.pnl-body .pnl-btn.gold, .pnl-body .pnl-btn.green {
  background: #F3E9D2; color: #5C4314; border: 1px solid #DCC593; box-shadow: none; font-weight: 600; }
.pnl-body .pnl-btn.gold:hover, .pnl-body .pnl-btn.green:hover { background: #EADBB8; color: #4A3510; border-color: #C9AD72; }
.pnl-body .pnl-btn.gold:focus-visible, .pnl-body .pnl-btn.green:focus-visible { outline: 2px solid #B0812B; outline-offset: 2px; }

/* ---------- Lignes cliquables (chevaux, reproducteurs) ---------- */
.elv-rowlink { cursor: pointer; }
.elv-rowlink:hover > td, .elv-rowlink:hover > th { background: rgba(200, 151, 63, .06); }
.elv-rowlink.is-pinned > td:first-child { box-shadow: inset 3px 0 0 #C8973F; }

/* ---------- Fiche cheval en tableau de bord ---------- */
.elv-horse-acts { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
@media (min-width: 1200px) {
  .elv-hgrid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; align-items: start; grid-auto-flow: row dense; }
  .elv-hgrid > .pnl-card { margin-bottom: 0; min-width: 0; }
  .elv-hgrid > .elv-wide, .elv-hgrid > .elv-post-card { grid-column: 1 / -1; }
}
.elv-ped-inline { margin-top: 14px; overflow-x: auto; }

/* ---------- Case « Inviter vos cavaliers » du tableau de bord ---------- */
.dash-inv { display: flex; gap: 20px; align-items: center; flex-wrap: wrap; }
.dash-inv-qr { width: 150px; height: 150px; flex: none; border: 1px solid var(--line); border-radius: 12px; background: #fff;
  display: flex; align-items: center; justify-content: center; overflow: hidden; }
.dash-inv-qr img { width: 100%; height: 100%; image-rendering: pixelated; }
.dash-inv-tx { flex: 1; min-width: 240px; }
.dash-inv-tx h2 { margin: 0 0 4px; }
.dash-inv-tx > p { margin: 0 0 10px; font-size: .88rem; }
.dash-inv-row { display: flex; gap: 8px; flex-wrap: wrap; }
.dash-inv-row input { flex: 1; min-width: 200px; border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; font: inherit; font-size: .88rem;
  background: #FBF8F1; color: var(--ink); }
.dash-inv-foot { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 10px; }
.dash-inv-foot form { margin: 0; }
.cli-filters { margin-bottom: 0; }

.cli-merge { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 10px 12px; margin: 0 0 12px;
  border: 1px dashed #DCC593; border-radius: 10px; background: #FBF7EC; font-size: .86rem; }
.cli-merge span { flex: 1; min-width: 200px; }
img.elv-cli-av { object-fit: cover; background: none; }

/* Ligne avec action au survol (rations…) : un voile fondu et le texte de l'action */
.elv-hoverlabel { position: relative; }
.elv-hoverlabel::after { content: attr(data-hover); position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  background: rgba(251, 247, 236, .9); color: #5C4314; font-weight: 700; font-size: .95rem; letter-spacing: .01em;
  opacity: 0; transition: opacity .18s ease; pointer-events: none; border-radius: 8px; }
.elv-hoverlabel:hover::after, .elv-hoverlabel:focus-within::after { opacity: 1; }
@media (hover: none) { .elv-hoverlabel::after { display: none; } }

.elv-team-row.elv-rowlink { cursor: pointer; border-radius: 10px; }

/* Chevaux à vendre : la nouvelle apparence remettait une marge intérieure aux
   cartes d'annonce (photo en retrait, carte « tassée »). La photo reprend toute
   la largeur, le corps garde sa propre marge. */
.pnl-body .pnl-card.elv-sale-card { padding: 0; }
.pnl-body .elv-sale-ph { border-radius: 0; font-size: 3.4rem; }
.pnl-body .elv-sale-body h3 { line-height: 1.25; }

/* ---------- Titre encadré du menu = sélecteur de structure ----------
   La liste déroulante native couvre tout l'encadré, invisible : un clic sur le
   titre l'ouvre (clavier et lecteurs d'écran compris). Un chevron le signale. */
.pnl-club.pnl-club-pick { position: relative; cursor: pointer; }
.pnl-club.pnl-club-pick .name { padding-right: 18px; }
.pnl-club.pnl-club-pick::after { content: "▾"; position: absolute; right: 14px; top: 50%; transform: translateY(-50%);
  color: currentColor; opacity: .6; font-size: .85rem; pointer-events: none; }
.pnl-club.pnl-club-pick:hover::after { opacity: 1; }
.pnl-body .pnl-club .pnl-club-select, .pnl-club .pnl-club-select {
  position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: pointer; z-index: 2; }
.pnl-club.pnl-club-pick:focus-within { outline: 2px solid #E9CD92; outline-offset: 2px; border-radius: 10px; }
.pnl-side.rail .pnl-club.pnl-club-pick::after, .pnl-app.pnl-rail .pnl-club.pnl-club-pick::after { display: none; }

/* Épingle seule : estompée tant que le cheval n'est pas épinglé */
.elv-pin { min-width: 34px; justify-content: center; }
.elv-pin:not(.on) { filter: grayscale(1); opacity: .45; }
.elv-pin:not(.on):hover { filter: none; opacity: 1; }
.elv-pin.on { background: #F3E9D2; border-color: #DCC593; }

/* ---------- Tableau de bord élevage : grille adaptative (25/11/2026) ----------
   auto-fill : autant de colonnes que la largeur permet ; dense : les petits
   encadrés comblent les trous laissés par les grands. */
.elv-board { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(330px, 100%), 1fr)); gap: 16px; align-items: start; grid-auto-flow: dense; }
.elv-board > .pnl-card { margin: 0; min-width: 0; }
.pnl-body .elv-board > .pnl-card { margin: 0; }
@media (min-width: 1100px) { .elv-board > .elv-w2 { grid-column: span 2; } }
.elv-todo-cols { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(280px, 100%), 1fr)); gap: 6px; }
.elv-board h2 { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.elv-board-go { margin-left: auto; font-size: .78rem; font-weight: 600; color: var(--brass); text-decoration: none; font-family: inherit; }
.elv-board-line { display: flex; align-items: baseline; gap: 8px; padding: 7px 4px; border-top: 1px solid var(--line); text-decoration: none; color: var(--ink); font-size: .86rem; }
.elv-board h2 + .elv-board-line, .elv-board-big + .elv-board-line { border-top: 0; }
a.elv-board-line:hover { background: rgba(200, 151, 63, .06); border-radius: 6px; }
.elv-board-line > .muted { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .8rem; }
.elv-board-r { margin-left: auto; white-space: nowrap; font-weight: 600; font-size: .8rem; }
.elv-board-r.warn { color: #C0392B; }
.elv-board-big { font-size: 1.35rem; font-weight: 700; margin: 0 0 6px; }
.elv-board-big small { font-size: .78rem; font-weight: 500; color: var(--muted); }
.elv-map-kpis { margin-bottom: 16px; }

.ped-c.elv-click-proxy { cursor: pointer; }
.ped-c.elv-hoverlabel::after { font-size: .78rem; border-radius: inherit; }
.ped-c.elv-hoverlabel a { position: relative; z-index: 1; }

/* Petits nombres orange (comme le panneau admin) : pastilles du menu et demandes */
/* Pastilles du menu : orange doux, pas un aplat opaque (retour de Tom, 25/11/2026) */
.pnl-body .pnl-nav a .badge, .pnl-body .pnl-navgrp > summary .badge {
  background: rgba(232, 119, 46, .16); color: #F4A26A; box-shadow: inset 0 0 0 1px rgba(232, 119, 46, .35); font-weight: 700; }
.nb-orange { display: inline-flex; align-items: center; justify-content: center; min-width: 22px; height: 22px; padding: 0 6px; margin-right: 6px;
  border-radius: 999px; background: #E8772E; color: #fff; font-weight: 700; font-size: .8rem; }
.elv-req-alert { border-left: 3px solid #E8772E; }
.elv-pen.elv-rowlink { cursor: pointer; }

/* Factures : colonnes centrées, et l'action « Payée » reste au-dessus du voile */
.elv-inv-table th, .elv-inv-table td { text-align: center; }
.elv-inv-table .elv-act { position: relative; z-index: 1; }
.elv-hoverlabel .elv-act, .elv-hoverlabel .elv-pen-act { position: relative; z-index: 1; }
.elv-steps { margin: 0 0 14px; padding-left: 22px; font-size: .86rem; color: var(--ink); }
.elv-steps li { margin: 3px 0; }

/* Page d'une facture : actions en haut, état centré */
.elv-inv-actions { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; margin: 0 0 14px; }
.elv-inv-actions form { margin: 0; }
.elv-center.elv-paystate { text-align: center; justify-content: center; }
/* La facture elle-même, centrée dans la page (elle était collée à gauche). */
.pnl-body .elv-invoice { margin-left: auto; margin-right: auto; }
.elv-inv-actions, .elv-center.elv-paystate { max-width: 860px; margin-left: auto; margin-right: auto; }

/* Photos de profil des messages : jamais écrasées */
.cli-bav, img.elv-cli-av { aspect-ratio: 1 / 1; min-width: 28px; min-height: 28px; flex-shrink: 0; }
img.elv-cli-av { min-width: 32px; min-height: 32px; }
img.elv-cli-av.lg { min-width: 48px; min-height: 48px; }

/* Lignes cliquables : noms sans doré ni surlignage, survol neutre */
.elv-rowlink a { color: inherit; text-decoration: none; }
.elv-rowlink:hover > td, .elv-rowlink:hover > th { background: rgba(27, 42, 74, .035); }

/* Équipe : ligne non modifiable = curseur « interdit » */
.elv-team-row.elv-locked, .elv-team-row.elv-locked * { cursor: not-allowed; }

/* ---------- Texte non sélectionnable dans le panneau (25/11/2026) ----------
   Rien ne se sélectionne à la souris, sauf ce qu'on copie vraiment : champs de
   saisie, e-mails, téléphones, liens, adresses, numéros (SIREN, SIRE, factures),
   messages, et tout élément marqué .sel-ok. */
.pnl-body .pnl-main { -webkit-user-select: none; user-select: none; }
.pnl-body .pnl-main :is(input, textarea, select, [contenteditable], code, pre, kbd,
  a[href^="mailto:"], a[href^="tel:"], a[href^="http"], .cli-dl dd, .cli-bub, .elv-invoice,
  .dash-inv-row input, .elv-invlink input, .inv-lien, .sel-ok, [data-copy-src], .pnl-item-sub, .elv-horse-meta, .cli-nm small) {
  -webkit-user-select: text; user-select: text; }

/* Tableau de bord : mosaïque en colonnes (aucun trou, quelle que soit la
   hauteur des encadrés). Le nombre de colonnes suit la largeur disponible. */
.elv-board { display: block; columns: 340px; column-gap: 16px; }
.elv-board > .pnl-card, .pnl-body .elv-board > .pnl-card { break-inside: avoid; margin: 0 0 16px; display: block; width: 100%; }
.elv-board > .elv-w2 { grid-column: auto; }
.elv-board .elv-todo-cols { grid-template-columns: 1fr; }

/* 25/11 : bouton « + Traitement » tout à droite du titre */
.soin-today > h2 { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.soin-today > h2 .soin-add { margin-left: auto; }
/* Pastilles (Poulinière, Jeune poulain…) un peu espacées du nom */
.elv-rowlink td .pnl-chip { margin-left: 6px; }

/* 25/11 (2) : le tableau de bord occupe toute la largeur, quel que soit le contenu.
   Chiffres étirés sur toute la ligne ; « À faire » à gauche (défile tout seul s'il
   est long), les autres encadrés remplissent la droite en colonnes. */
.elv-map-kpis { grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)) !important; }
.elv-board { display: grid; columns: auto; grid-template-columns: 1fr; gap: 16px; align-items: start; }
.elv-board > .pnl-card, .pnl-body .elv-board > .pnl-card { margin: 0; }
.elv-board-side { columns: 320px; column-gap: 16px; }
.elv-board-side > .pnl-card, .pnl-body .elv-board-side > .pnl-card { break-inside: avoid; margin: 0 0 16px; display: block; width: 100%; }
.elv-board-side:empty { display: none; }
@media (min-width: 1000px) {
  .elv-board { grid-template-columns: minmax(330px, 1fr) minmax(0, 2fr); }
  .elv-board > .elv-tall { position: sticky; top: 12px; max-height: calc(100vh - 24px); overflow: auto; }
  .elv-board:not(:has(.elv-board-side > *)) { grid-template-columns: 1fr; }
}
@media (min-width: 1700px) { .elv-board { grid-template-columns: minmax(360px, 1fr) minmax(0, 3fr); } }

/* Fiche cheval : portrait en médaillon à côté du nom (25/11/2026) */
.elv-horse-head { align-items: flex-start; }
.elv-horse-av { flex: 0 0 auto; width: 88px; height: 88px; border-radius: 50%; overflow: hidden; position: relative; margin-right: 18px;
  box-shadow: 0 0 0 3px var(--paper, #fff), 0 0 0 4px rgba(200, 151, 63, .55), 0 6px 18px rgba(0, 0, 0, .12);
  display: grid; place-items: center; text-decoration: none; transition: transform .2s ease, box-shadow .2s ease; }
.elv-horse-av img { width: 100%; height: 100%; object-fit: cover; display: block; }
.elv-horse-av:hover { transform: scale(1.04); }
.elv-horse-av.empty { background: linear-gradient(145deg, #F6EEDD, #EADBB9); box-shadow: 0 0 0 1px rgba(200, 151, 63, .35); }
.elv-horse-av.empty span { font-family: var(--serif, Georgia, serif); font-size: 2rem; font-weight: 600; color: #9C6F2A; }
.elv-horse-av.empty i { position: absolute; inset: 0; display: grid; place-items: center; font-style: normal; font-size: .72rem; font-weight: 700;
  color: #fff; background: rgba(60, 40, 15, .55); opacity: 0; transition: opacity .2s; }
.elv-horse-av.empty:hover i { opacity: 1; }
#photos { scroll-margin-top: 16px; }
@media (max-width: 640px) { .elv-horse-av { width: 64px; height: 64px; margin-right: 12px; } .elv-horse-av.empty span { font-size: 1.5rem; } }

/* Pastilles photo des chevaux dans les listes (25/11/2026) */
.elv-nm { display: inline-flex; align-items: center; gap: 9px; vertical-align: middle; }
.elv-dot { flex: 0 0 auto; width: 32px; height: 32px; border-radius: 50%; overflow: hidden; display: inline-grid; place-items: center;
  box-shadow: 0 0 0 1px rgba(200, 151, 63, .45); background: #F3EADA; }
.elv-dot img { width: 100%; height: 100%; object-fit: cover; display: block; }
.elv-dot.empty { background: linear-gradient(145deg, #F6EEDD, #EADBB9); color: #9C6F2A; font-family: var(--serif, Georgia, serif); font-weight: 600; font-size: .88rem; }
.elv-board-line .elv-dot { width: 24px; height: 24px; font-size: .72rem; }
.elv-board-line .elv-nm { gap: 7px; }

/* Confirmation de naissance (25/11/2026) */
.elv-birth-ok { text-align: center; padding: 6px 4px 2px; animation: elvPop .25s ease; }
.elv-birth-ok .ic { font-size: 2.6rem; line-height: 1; margin-bottom: 8px; }
.elv-birth-ok .t { font-family: var(--serif, Georgia, serif); font-size: 1.35rem; }
.elv-birth-ok .s { margin-top: 4px; color: var(--muted); text-transform: none; }
.elv-birth-ok .p { display: inline-block; margin-top: 10px; padding: 4px 12px; border-radius: 999px; background: #F3E9D2; color: #8A6326; font-size: .84rem; font-weight: 600; }
.elv-birth-ok .n { margin-top: 12px; font-size: .82rem; color: var(--muted); }
.elv-birth-ok .a { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; margin-top: 18px; }
@keyframes elvPop { from { opacity: 0; transform: scale(.97); } to { opacity: 1; transform: none; } }
.pnl-modal-body:has(.elv-birth-ok) > .pnl-item-sub { display: none; }

/* ---------- Téléphone (25/11/2026) ----------
   1) Champs à 16 px : en dessous, l'iPhone zoome au toucher et la page se
      met à glisser de gauche à droite. 2) Aucun champ ne dépasse son cadre
      (les champs date d'iOS ont une largeur imposée). */
@media (max-width: 760px) {
  .pnl-body input:not([type=checkbox]):not([type=radio]):not([type=hidden]), .pnl-body select, .pnl-body textarea,
  .pnl-modal input:not([type=checkbox]):not([type=radio]), .pnl-modal select, .pnl-modal textarea { font-size: 16px !important; }
  .pnl-body input, .pnl-body select, .pnl-body textarea, .pnl-modal input, .pnl-modal select, .pnl-modal textarea { max-width: 100%; min-width: 0; box-sizing: border-box; }
  .pnl-body input[type=date], .pnl-body input[type=time], .pnl-body input[type=datetime-local], .pnl-body input[type=month],
  .pnl-modal input[type=date], .pnl-modal input[type=time] { -webkit-appearance: none; appearance: none; display: block; width: 100%; min-height: 42px; text-align: left; }
  .pnl-field, .pnl-row > *, .pnl-modal fieldset, .pnl-modal-body form > * { min-width: 0; max-width: 100%; }
  .pnl-row { flex-wrap: wrap; }
  .pnl-modal, .pnl-modal-body { overflow-x: hidden; max-width: 100vw; }
  .pnl-modal fieldset { margin-left: 0; margin-right: 0; }
  html, body { overflow-x: hidden; }

  /* Liste des chevaux compacte : une ligne nette par cheval, sans étiquettes */
  .elv-horse-list thead { display: none; }
  .elv-horse-list tbody tr { display: grid; grid-template-columns: 1fr auto; gap: 2px 8px; padding: 10px 12px; margin: 0 0 8px; border: 1px solid var(--line); border-radius: 12px; }
  .elv-horse-list tbody td { display: block; padding: 0 !important; border: 0 !important; text-align: left !important; }
  .elv-horse-list tbody td::before { display: none !important; content: none !important; }
  .elv-horse-list td[data-label="Cheval"] { grid-column: 1; }
  .elv-horse-list td.elv-act { grid-column: 2; grid-row: 1; align-self: start; }
  .elv-horse-list td.elv-act .elv-pin { min-width: 0; padding: 4px 8px; }
  .elv-horse-list td[data-label="Propriétaire"], .elv-horse-list td[data-label="Généalogie"] { grid-column: 1 / -1; font-size: .78rem !important; color: var(--muted); padding-left: 41px !important; }
  .elv-horse-list td[data-label="Généalogie"]:not(:has(*)) { display: none; }
  .elv-horse-list td[data-label="Cheval"] .muted { padding-left: 41px; }
  .elv-horse-list td[data-label="Cheval"] .pnl-chip { font-size: .7rem; padding: 1px 7px; }
}

/* ---------- Téléphone, suite (25/11/2026) ---------- */
.elv-show-m { display: none; }
@media (max-width: 700px) {
  .elv-hide-m { display: none; }
  .elv-show-m { display: inline; }
  /* Barre d'onglets du bas retirée : le menu ☰ suffit */
  .elv-tabbar { display: none !important; }
  .pnl-body .pnl-main, .pnl-body .pnl-content { padding-bottom: 16px !important; }
  /* Toutes les listes en cartes compactes : étiquette à gauche sur la même
     ligne que la valeur, au lieu d'une étiquette au-dessus de chaque valeur. */
  .elv-stack:not(.elv-horse-list) tr { padding: 9px 12px; margin-bottom: 7px; }
  .elv-stack:not(.elv-horse-list) td { padding: 2px 0 !important; font-size: .86rem; }
  .elv-stack:not(.elv-horse-list) td[data-label]::before { display: inline-block !important; min-width: 82px; margin: 0 8px 0 0; font-size: .62rem; vertical-align: baseline; }
  .elv-stack:not(.elv-horse-list) td:first-child { padding-bottom: 4px !important; font-size: .92rem; }
  .elv-stack:not(.elv-horse-list) td:first-child::before { display: none !important; }
  .elv-stack:not(.elv-horse-list) td > div.muted, .elv-stack:not(.elv-horse-list) td > .muted { display: inline; margin-left: 4px; }
  .elv-stack:not(.elv-horse-list) td:first-child > div.muted { display: block; margin-left: 0; }
  .elv-stack:not(.elv-horse-list) td.elv-act { padding-top: 6px !important; justify-content: flex-end; }
  .elv-stack:not(.elv-horse-list) td.elv-act > * { flex: 0 0 auto; }
  .elv-stack:not(.elv-horse-list) td.elv-act .pnl-btn { padding: 5px 10px; font-size: .78rem; width: auto !important; }
  .elv-stack td:has(> :only-child:empty), .elv-stack td.muted:empty { display: none; }
}
@media (max-width: 700px) {
  /* Chiffres clés : deux par ligne, pas un par ligne */
  .elv-map-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; gap: 8px !important; }
  .elv-map-kpis .elv-kpi { padding: 9px 10px; min-width: 0; }
  /* Un seul bouton d'action : il reste sur la ligne du titre */
  .pnl-top:has(.pnl-head-actions > :only-child) { grid-template-columns: auto 1fr auto !important; align-items: center; }
  .pnl-top:has(.pnl-head-actions > :only-child) .pnl-head-actions { grid-column: 3 !important; grid-row: 1 !important; width: auto !important; margin: 0 !important; justify-content: flex-end; }
  .pnl-top:has(.pnl-head-actions > :only-child) .pnl-head-actions .pnl-btn { padding: 6px 10px; font-size: .78rem; white-space: nowrap; }
}
@media (max-width: 700px) {
  /* (le conteneur d'actions est en display:contents : on vise le bouton lui-même) */
  .pnl-top:has(.elv-top-act > :only-child) { grid-template-columns: auto minmax(0, 1fr) auto !important; align-items: center; }
  .pnl-top .elv-top-act:has(> :only-child) { grid-column: 3 !important; grid-row: 1 !important; width: auto !important; margin: 0 !important; }
  .pnl-top .elv-top-act:has(> :only-child) .pnl-btn { padding: 6px 10px; font-size: .78rem; white-space: nowrap; width: auto !important; }
}

/* Réglages > Paiement en ligne (25/11/2026) : encadrés par moyen de paiement */
.elv-pay h2 { margin-bottom: 12px; }
.elv-pay-state { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 12px; background: #FBF6EC; border: 1px solid #EADBB9; flex-wrap: wrap; }
.elv-pay-state.ok { background: #EEF7F2; border-color: #BFDCCB; }
.elv-pay-state > span { font-size: 1.4rem; }
.elv-pay-state > div { flex: 1 1 200px; min-width: 0; }
.elv-pay-state small { display: block; color: var(--muted); font-size: .82rem; margin-top: 2px; }
.elv-pay-state form { margin: 0; }
.elv-pay-h3 { font-size: .95rem; margin: 18px 0 10px; }
.elv-pay-h3 small { font-weight: 400; color: var(--muted); font-size: .78rem; margin-left: 6px; }
.elv-pm-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 10px; }
.elv-pm { position: relative; display: flex; flex-direction: column; gap: 4px; padding: 13px 14px; border-radius: 14px; border: 1px solid var(--line); background: var(--card, #fff); }
label.elv-pm { cursor: pointer; transition: border-color .15s, box-shadow .15s, opacity .15s; opacity: .6; }
label.elv-pm:has(input:checked) { opacity: 1; border-color: #C8973F; box-shadow: 0 0 0 1px #C8973F inset; }
label.elv-pm input { position: absolute; opacity: 0; pointer-events: none; }
.elv-pm-tick { position: absolute; top: 10px; right: 10px; width: 20px; height: 20px; border-radius: 50%; border: 1.5px solid var(--line); display: grid; place-items: center; font-size: .7rem; color: transparent; }
label.elv-pm:has(input:checked) .elv-pm-tick { background: #C8973F; border-color: #C8973F; color: #fff; }
.elv-pm-top { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; padding-right: 22px; }
.elv-pm-top .ic { font-size: 1.15rem; }
.elv-pm-top em { font-style: normal; font-size: .66rem; font-weight: 700; padding: 2px 7px; border-radius: 999px; background: #F3E9D2; color: #8A6326; }
.elv-pm-net { font-size: 1.2rem; font-weight: 700; margin-top: 4px; }
.elv-pm-net small { font-size: .74rem; font-weight: 500; color: var(--muted); }
.elv-pm-fee, .elv-pm-use { font-size: .76rem; color: var(--muted); }
.elv-pay-foot { font-size: .76rem; margin: 12px 0 0; }

/* Fiche cheval : encadré vide = bouton d'ajout, à la souris seulement (25/11/2026).
   Sur téléphone (pas de survol), on garde le bouton classique. */
@media (hover: hover) and (pointer: fine) {
  .elv-empty-add { cursor: pointer; }
  .elv-empty-add.elv-hoverlabel::after { border-radius: inherit; }
  .pnl-card:has(.elv-empty-add) .elv-add-btn { display: none; }
}
@media not ((hover: hover) and (pointer: fine)) { .elv-empty-add { pointer-events: none; } }
.elv-credit-box { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; background: #EEF7F2; border-color: #BFDCCB; }
.elv-credit-box small { flex: 1 1 220px; color: var(--muted); }
.elv-credit-box form { margin: 0; }
.elv-wait { border-left: 3px solid #E8772E; }
.elv-wait .nb-orange { min-width: 20px; height: 20px; font-size: .72rem; margin: 0; }
.elv-wait .elv-board-r { font-weight: 400; }
.cli-unread { min-width: 19px; height: 19px; font-size: .7rem; margin-right: 6px; vertical-align: 1px; }
@media (max-width: 700px) {
  /* Bouton d'action + « ? » sur la ligne du titre, côte à côte */
  .pnl-top:has(.elv-top-act > :only-child):has(.elv-helpq) { grid-template-columns: auto minmax(0, 1fr) auto auto !important; column-gap: 6px; }
  .pnl-top:has(.elv-top-act > :only-child) .elv-helpq { grid-column: 4 !important; grid-row: 1 !important; }
}

/* Invitation courte (30/11/2026) : lien en avant, QR et options repliés. */
.dash-inv--court { display: block; }
.dash-inv--court .dash-inv-tx { min-width: 0; }
.dash-inv--court .dash-inv-plus { margin-top: 8px; }
.dash-inv--court .dash-inv-plus summary { cursor: pointer; font-size: .84rem; color: var(--muted); }
.dash-inv--court .dash-inv-plus .dash-inv-qr { width: 120px; height: 120px; margin: 10px 0 6px; }
