/* Familiz — feuille de style unique (landing, authentification, espace famille) */

@font-face { font-family: Nunito; font-weight: 400; font-display: swap; src: url(../fonts/nunito-latin-400-normal.woff2) format("woff2"); }
@font-face { font-family: Nunito; font-weight: 600; font-display: swap; src: url(../fonts/nunito-latin-600-normal.woff2) format("woff2"); }
@font-face { font-family: Nunito; font-weight: 700; font-display: swap; src: url(../fonts/nunito-latin-700-normal.woff2) format("woff2"); }
@font-face { font-family: Nunito; font-weight: 800; font-display: swap; src: url(../fonts/nunito-latin-800-normal.woff2) format("woff2"); }
@font-face { font-family: Caveat; font-weight: 600; font-display: swap; src: url(../fonts/caveat-latin-600-normal.woff2) format("woff2"); }

:root {
  --navy: #0b1d3a;
  --navy-2: #12305e;
  --primary: #1d64f2;
  --primary-d: #1450cc;
  --primary-soft: #e8f0fe;
  --bg: #f1f5fb;
  --card: #ffffff;
  --line: #e2e9f4;
  --line-2: #eef2f8;
  --text: #0f2342;
  --muted: #5f6e84;
  /* Lisibilité : accent pour le texte, texte sur fond d'accent, titres foncés (ajustés par les thèmes) */
  --primary-ink: var(--primary);
  --on-primary: #fff;
  --heading: var(--navy);
  --green: #16a34a; --green-soft: #e7f7ed;
  --orange: #f97316; --orange-soft: #fff1e6;
  --red: #e11d48; --red-soft: #fde8ee;
  --violet: #7c3aed; --violet-soft: #f1eafe;
  --pink: #db2777; --pink-soft: #fce7f3;
  --teal: #0d9488; --teal-soft: #e0f5f2;
  --yellow: #f59e0b; --yellow-soft: #fef6e2;
  --radius: 16px;
  --radius-sm: 10px;
  --shadow: 0 1px 2px rgba(15, 35, 66, .04), 0 8px 24px rgba(15, 35, 66, .06);
  --shadow-lg: 0 20px 60px rgba(15, 35, 66, .18);
  --side-w: 248px;
  /* Barres de défilement : teinte de la couleur principale du thème (thèmes graphiques et mode sombre compris). */
  --sb-thumb: color-mix(in srgb, var(--primary) 26%, var(--line));
  --sb-thumb-h: color-mix(in srgb, var(--primary) 55%, var(--line));
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: Nunito, system-ui, -apple-system, "Segoe UI", sans-serif; color: var(--text); background: var(--bg); font-size: 15px; line-height: 1.45; }
a { color: var(--primary-ink); text-decoration: none; }
img { max-width: 100%; }
h1, h2, h3, h4 { margin: 0; line-height: 1.2; }
p { margin: 0; }
button, input, select, textarea { font: inherit; color: inherit; }
/* Barres de défilement aux couleurs du thème : fines, arrondies, sur fond transparent.
   Firefox et Chrome récent lisent scrollbar-color ; Safari et les anciens Chrome, les pseudo-éléments -webkit-. */
html { scrollbar-color: var(--sb-thumb) var(--bg); }
* { scrollbar-width: thin; scrollbar-color: var(--sb-thumb) transparent; }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track, ::-webkit-scrollbar-corner { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--sb-thumb); border: 2px solid transparent; border-radius: 999px; background-clip: padding-box; }
::-webkit-scrollbar-thumb:hover { background: var(--sb-thumb-h); border: 2px solid transparent; background-clip: padding-box; }
.sidebar ::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, .18); border: 2px solid transparent; background-clip: padding-box; }
.sidebar ::-webkit-scrollbar-thumb:hover { background: rgba(255, 255, 255, .32); border: 2px solid transparent; background-clip: padding-box; }
.hand { font-family: Caveat, "Segoe Script", cursive; font-weight: 600; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.tiny { font-size: 12px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* Icônes */
.i { width: 1.15em; height: 1.15em; flex: none; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; vertical-align: -0.2em; }
.i.tiny { width: .9em; height: .9em; }

/* ---------------- Coque applicative ---------------- */
.shell { display: flex; min-height: 100vh; }
@media (min-width: 901px) { .shell { background: linear-gradient(90deg, var(--navy) var(--side-w), transparent var(--side-w)); } }
.sidebar {
  width: var(--side-w); flex: none; position: sticky; top: 0; height: 100vh; overflow-y: auto;
  background: linear-gradient(180deg, #0c2147 0%, var(--navy) 60%, #091731 100%);
  color: #dbe6ff; display: flex; flex-direction: column; padding: 22px 14px 16px; z-index: 40;
}
.brand { display: flex; align-items: center; gap: 12px; color: #fff; padding: 0 8px 22px; }
.brand-ic { width: 44px; height: 44px; display: grid; place-items: center; color: #fff; }
.brand-ic .i { width: 38px; height: 38px; stroke-width: 2.2; }
.brand strong { display: block; font-size: 19px; font-weight: 800; letter-spacing: -.01em; }
.brand small { display: block; font-size: 12px; color: rgba(255, 255, 255, .76); }
.nav { display: flex; flex-direction: column; gap: 4px; }
.nav a { display: flex; align-items: center; gap: 14px; padding: 11px 14px; border-radius: 12px; color: #e3ebff; font-weight: 600; font-size: 15px; transition: background .15s; }
.nav a .i { width: 22px; height: 22px; }
.nav a:hover { background: rgba(255, 255, 255, .07); }
.nav a.nav-admin { margin-top: 10px; border-top: 1px solid rgba(255,255,255,.08); border-radius: 0 0 12px 12px; padding-top: 14px; color: #ddd2ff; }
.nav-dot { width: 8px; height: 8px; border-radius: 50%; background: #f43f5e; margin-left: auto; box-shadow: 0 0 0 3px rgba(244,63,94,.25); }
.nav a.active { background: linear-gradient(180deg, #2a72f7, #1a5be0); color: var(--on-act, #fff); box-shadow: 0 6px 18px rgba(29, 100, 242, .35); }
.side-foot { margin-top: auto; padding-top: 18px; }
.me { display: flex; align-items: center; gap: 10px; padding: 10px; border-radius: 12px; background: rgba(255, 255, 255, .06); }
.me-link { flex: 1; min-width: 0; display: flex; align-items: center; gap: 10px; border-radius: 10px; margin: -4px; padding: 4px; color: inherit; text-decoration: none; }
.me-link:hover { background: rgba(255, 255, 255, .08); }
.me-link > span:not(.av) { flex: 1; min-width: 0; }
.me-link strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.me > span:not(.av) { flex: 1; min-width: 0; }
.me strong { display: block; color: #fff; font-size: 14px; }
.sidebar .me small { color: rgba(255, 255, 255, .74); font-size: 12px; }
.me .icon-btn { color: #c7d5f3; }
.me .icon-btn:hover { background: rgba(255, 255, 255, .1); color: #fff; }
.mascot { padding: 16px 6px 0; }
.mascot p { color: #fff; font-size: 19px; line-height: 1.1; transform: rotate(-3deg); margin-bottom: 4px; }
.mascot p .i { color: #fff; }

.main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.content { padding: 20px 20px 8px; flex: 1; }
.foot { display: flex; justify-content: space-between; gap: 12px; padding: 14px 24px 18px; color: var(--muted); font-size: 13px; }
.foot .hand { font-size: 17px; color: #4b5d7a; }

/* Bandeau */
.hero {
  position: relative; min-height: 160px; display: flex; align-items: center; gap: 24px;
  padding: 20px 28px; color: #fff; overflow: hidden;
  background: linear-gradient(90deg, rgba(10, 22, 50, .72) 0%, rgba(10, 22, 50, .35) 45%, rgba(10, 22, 50, 0) 75%), var(--banner) center 60% / cover no-repeat, #36326b;
}
.hero.has-weather { padding-right: 260px; }
.hero-left { display: flex; align-items: center; gap: 22px; min-width: 0; position: relative; z-index: 1; }
.hero h1 { font-size: 34px; font-weight: 800; letter-spacing: -.02em; text-shadow: 0 2px 12px rgba(0, 0, 0, .3); }
.hero-sub { font-size: 17px; margin-top: 4px; opacity: .95; text-shadow: 0 1px 6px rgba(0, 0, 0, .35); }
.hero-meta { margin-top: 10px; font-size: 14px; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; text-shadow: 0 1px 6px rgba(0, 0, 0, .35); }
.hero-meta .i { color: #ff8fab; }
.hero-photo { width: 118px; height: 118px; border-radius: 50%; object-fit: cover; border: 4px solid #fff; box-shadow: 0 8px 24px rgba(0, 0, 0, .3); flex: none; }
.photo-ph { display: grid; place-items: center; background: linear-gradient(135deg, #5b8cff, #8b5cf6); color: #fff; }
.photo-ph .i { width: 46%; height: 46%; }
.hero-ic { width: 84px; height: 84px; border-radius: 50%; display: grid; place-items: center; background: var(--mc); color: #fff; flex: none; border: 4px solid rgba(255, 255, 255, .9); box-shadow: 0 8px 24px rgba(0, 0, 0, .25); }
.hero-ic .i { width: 40px; height: 40px; }
.hero-quote { margin-left: auto; max-width: 320px; text-align: right; font-size: 24px; line-height: 1.1; transform: rotate(-6deg); color: #fff; text-shadow: 0 2px 10px rgba(0, 0, 0, .35); position: relative; z-index: 1; }
.hero-quote .i { width: 18px; height: 18px; }
.hero-weather {
  position: absolute; top: 0; right: 0; bottom: 0; width: 230px; background: #fff; color: var(--text);
  padding: 22px 24px; display: flex; flex-direction: column; justify-content: center; gap: 14px;
}
.hero-weather:hover { background: #fbfdff; }
.hw-top { display: flex; align-items: center; gap: 12px; }
.hw-top strong { display: block; font-size: 28px; font-weight: 800; line-height: 1; }
.hw-top small { color: var(--muted); font-size: 14px; }
.hw-bot { font-size: 14px; color: #475569; }
.wi { display: inline-grid; place-items: center; }
.wi .i { width: 26px; height: 26px; }
.wi.lg .i { width: 44px; height: 44px; }
.wi.xl .i { width: 72px; height: 72px; stroke-width: 1.7; }
.hero .burger { display: none; position: absolute; top: 12px; left: 12px; z-index: 3; background: rgba(0, 0, 0, .3); color: #fff !important; }

/* ---------------- Cartes & grilles ---------------- */
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 18px; min-width: 0; display: flex; flex-direction: column; }
.card-h { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; flex-wrap: wrap; }
.card-h h2 { font-size: 18px; font-weight: 800; display: flex; align-items: center; gap: 10px; margin-right: auto; }
.card-h h2 .badge { font-size: 12px; }
.ch-ic { color: var(--mc); display: inline-flex; }
.ch-ic .i { width: 24px; height: 24px; }
.more { font-size: 13px; font-weight: 700; display: inline-flex; align-items: center; gap: 4px; white-space: nowrap; }
.more .i { width: 14px; height: 14px; }
.card { container-type: inline-size; }
@container (max-width: 330px) { .card-h .more span { display: none; } .card-h .more .i { width: 18px; height: 18px; } }
.card-foot { margin-top: auto; padding-top: 12px; text-align: center; }

.grid { display: grid; gap: 18px; }
.g-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.g-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g-side { grid-template-columns: minmax(0, 1fr) 320px; align-items: start; }
.g-side-l { grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) 320px; align-items: start; }
.span-2 { grid-column: span 2; }
.span-3 { grid-column: span 3; }
.stack { display: flex; flex-direction: column; gap: 18px; min-width: 0; }
.mt { margin-top: 18px; }

/* Lignes de liste */
.rows { display: flex; flex-direction: column; }
.row { display: flex; align-items: center; gap: 12px; padding: 10px 2px; border-bottom: 1px solid var(--line-2); min-width: 0; }
.row:last-child { border-bottom: 0; }
.row-main { flex: 1; min-width: 0; }
.row-title { font-weight: 700; font-size: 14.5px; overflow: hidden; text-overflow: ellipsis; }
.row-sub { color: var(--muted); font-size: 13px; }
.row .actions { display: flex; gap: 2px; opacity: .55; transition: opacity .15s; }
.row:hover .actions { opacity: 1; }
.row.done .row-title { text-decoration: line-through; color: var(--muted); }
a.row { color: inherit; }
a.row:hover .row-title { color: var(--primary-ink); }

.dot { width: 9px; height: 9px; border-radius: 50%; background: var(--c, var(--primary)); flex: none; }
.bar-l { width: 3px; align-self: stretch; border-radius: 3px; background: var(--c, var(--primary)); flex: none; }
.time { font-weight: 700; font-size: 14px; color: #33496b; min-width: 44px; font-variant-numeric: tabular-nums; }
.ic-bubble { width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; background: color-mix(in srgb, var(--c, var(--primary)) 13%, #fff); color: color-mix(in srgb, var(--c, var(--primary)) 82%, #0f2342); flex: none; }
.ic-bubble .i { width: 20px; height: 20px; }
.ic-bubble.round { border-radius: 50%; }
.ic-bubble.lg { width: 52px; height: 52px; border-radius: 50%; }
.ic-bubble.lg .i { width: 26px; height: 26px; }

.daychip { width: 52px; flex: none; text-align: center; border-radius: 12px; background: #f3f7fd; padding: 6px 0; line-height: 1.1; }
.daychip small { display: block; font-size: 11px; font-weight: 700; text-transform: uppercase; color: #4b5d7a; }
.daychip strong { display: block; font-size: 22px; font-weight: 800; }

/* Avatars */
.av { display: inline-grid; place-items: center; border-radius: 50%; background: var(--c); color: #fff; font-weight: 800; object-fit: cover; flex: none; border: 2px solid #fff; box-shadow: 0 1px 4px rgba(15, 35, 66, .15); }
.av-xs { width: 24px; height: 24px; font-size: 11px; }
.av-sm { width: 34px; height: 34px; font-size: 14px; }
.av-md { width: 44px; height: 44px; font-size: 17px; }
.av-lg { width: 64px; height: 64px; font-size: 24px; }
.av-xl { width: 96px; height: 96px; font-size: 36px; border-width: 3px; }
.av-stack { display: inline-flex; }
.av-stack .av + .av { margin-left: -8px; }

/* Badges */
.badge { display: inline-flex; align-items: center; gap: 4px; padding: 3px 10px; border-radius: 999px; font-size: 12px; font-weight: 700; white-space: nowrap; background: var(--primary-soft); color: var(--primary-d); }
.b-green { background: var(--green-soft); color: #15803d; }
.b-orange { background: var(--orange-soft); color: #c2410c; }
.b-red { background: var(--red-soft); color: #be123c; }
.b-violet { background: var(--violet-soft); color: #6d28d9; }
.b-pink { background: var(--pink-soft); color: #be185d; }
.b-teal { background: var(--teal-soft); color: #0f766e; }
.b-yellow { background: var(--yellow-soft); color: #a16207; }
.b-gray { background: #eef2f7; color: #475569; }
.badge .i { width: 13px; height: 13px; }

/* Boutons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 10px 18px; border-radius: 12px; border: 1px solid transparent; font-weight: 700; font-size: 14.5px; cursor: pointer; background: #fff; color: var(--text); transition: background .15s, box-shadow .15s, transform .05s; white-space: nowrap; text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--primary); color: var(--on-primary); box-shadow: 0 6px 16px rgba(29, 100, 242, .25); }
.btn-primary:hover { background: var(--primary-d); }
.btn-ghost { border-color: var(--line); background: #fff; }
.btn-ghost:hover { background: #f6f9fe; }
.btn-soft { background: var(--primary-soft); color: var(--primary-d); }
.btn-soft:hover { background: #dbe7fd; }
.btn-danger { background: var(--red); color: #fff; }
.btn-block { width: 100%; }
.btn-lg { padding: 14px 26px; font-size: 17px; border-radius: 14px; }
.btn-sm { padding: 6px 12px; font-size: 13px; border-radius: 10px; }
.btn-dashed { border: 1.5px dashed #c6d5ee; background: #f7faff; color: var(--primary-d); width: 100%; }
.btn-dashed:hover { background: var(--primary-soft); }
.icon-btn { display: inline-grid; place-items: center; width: 32px; height: 32px; border-radius: 9px; border: 0; background: transparent; color: var(--muted); cursor: pointer; flex: none; }
.icon-btn:hover { background: #eef3fb; color: var(--text); }
.icon-btn .i { width: 17px; height: 17px; }

/* Onglets / filtres */
.toolbar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 18px; }
.toolbar .grow { flex: 1; }
.tabs { display: flex; gap: 8px; flex-wrap: wrap; }
.tab { display: inline-flex; align-items: center; gap: 8px; padding: 9px 16px; border-radius: 12px; border: 1px solid var(--line); background: #fff; font-weight: 700; font-size: 14.5px; color: var(--text); cursor: pointer; box-shadow: 0 1px 2px rgba(15, 35, 66, .03); }
.tab:hover { background: #f7faff; }
.tab.active { background: var(--primary); border-color: var(--primary); color: var(--on-primary); box-shadow: 0 6px 16px rgba(29, 100, 242, .25); }
.tab .count { background: var(--primary-soft); color: var(--primary-d); border-radius: 999px; padding: 0 8px; font-size: 12px; }
.tab.active .count { background: rgba(255, 255, 255, .25); color: var(--on-primary); }
.seg { display: inline-flex; background: #eef3fb; border-radius: 12px; padding: 3px; }
.seg a, .seg button { padding: 7px 14px; border-radius: 9px; font-weight: 700; font-size: 14px; color: #475569; border: 0; background: none; cursor: pointer; }
.seg .active { background: #fff; color: var(--primary-ink); box-shadow: 0 1px 3px rgba(15, 35, 66, .12); }
.search { position: relative; }
.search input, .search input[type=search] { padding-left: 38px; min-width: 220px; }
.search .i { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--muted); }

/* Cases à cocher */
.chk { appearance: none; width: 22px; height: 22px; border-radius: 7px; border: 2px solid #c3cfe0; display: grid; place-items: center; cursor: pointer; flex: none; margin: 0; background: #fff; transition: all .15s; }
.chk::after { content: ""; width: 6px; height: 11px; border: solid #fff; border-width: 0 2.5px 2.5px 0; transform: rotate(45deg) translate(-1px, -1px); opacity: 0; }
.chk:checked { background: var(--primary); border-color: var(--primary); }
.chk.green:checked { background: var(--green); border-color: var(--green); }
.chk:checked::after { opacity: 1; }
.chk:disabled { cursor: default; opacity: .7; }
.chk.round { border-radius: 50%; }

/* Barres de progression */
.progress { height: 8px; border-radius: 99px; background: #e8eef7; overflow: hidden; }
.progress > span { display: block; height: 100%; border-radius: inherit; background: var(--c, var(--primary)); }

/* Formulaires */
.f { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; min-width: 0; }
.f > span { font-weight: 700; font-size: 13.5px; color: #33496b; }
input[type=text], input[type=email], input[type=url], input[type=password], input[type=date], input[type=time], input[type=datetime-local], input[type=number], input[type=search], input[type=month], input[type=tel], select, textarea {
  width: 100%; padding: 10px 12px; border: 1px solid #d5dfee; border-radius: 10px; background: #fff; outline: none; transition: border-color .15s, box-shadow .15s;
}
input:focus, select:focus, textarea:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(29, 100, 242, .15); }
textarea { resize: vertical; }
input[type=color] { width: 100%; height: 42px; padding: 3px; border: 1px solid #d5dfee; border-radius: 10px; background: #fff; cursor: pointer; }
input[type=file] { font-size: 13px; }
.f-check { flex-direction: row; align-items: center; gap: 10px; cursor: pointer; }
.f-check input { width: 18px; height: 18px; accent-color: var(--primary); }
.f-check span { font-weight: 600; }
.f-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.f-row3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 12px; }
.hint { font-size: 12.5px; color: var(--muted); margin-top: -8px; margin-bottom: 12px; }

.switch { position: relative; width: 44px; height: 24px; flex: none; }
.switch input { opacity: 0; width: 0; height: 0; position: absolute; }
.switch span { position: absolute; inset: 0; background: #cbd5e1; border-radius: 99px; cursor: pointer; transition: background .2s; }
.switch span::after { content: ""; position: absolute; width: 18px; height: 18px; left: 3px; top: 3px; background: #fff; border-radius: 50%; transition: transform .2s; box-shadow: 0 1px 3px rgba(0, 0, 0, .2); }
.switch input:checked + span { background: #22c55e; }
.switch input:checked + span::after { transform: translateX(20px); }
.switch input:disabled + span { opacity: .6; cursor: default; }

/* Modales */
.modal { border: 0; padding: 0; border-radius: 18px; width: min(560px, calc(100vw - 24px)); box-shadow: var(--shadow-lg); color: var(--text); max-height: calc(100vh - 32px); }
.modal.modal-sm { width: min(400px, calc(100vw - 24px)); }
.modal.modal-lg { width: min(760px, calc(100vw - 24px)); }
.modal::backdrop { background: rgba(9, 20, 45, .45); backdrop-filter: blur(2px); }
.modal form { display: flex; flex-direction: column; max-height: calc(100vh - 32px); }
.modal-h { display: flex; align-items: center; justify-content: space-between; padding: 18px 22px 6px; }
.modal-h h3 { font-size: 19px; font-weight: 800; }
.modal-body { padding: 12px 22px; overflow-y: auto; }
.modal-foot { display: flex; justify-content: flex-end; gap: 10px; padding: 14px 22px 18px; border-top: 1px solid var(--line-2); }

/* Messages */
.alert { margin: 16px 20px 0; padding: 12px 16px; border-radius: 12px; font-weight: 600; }
.alert-success { background: var(--green-soft); color: #166534; }
.alert-error { background: var(--red-soft); color: #9f1239; }
.alert-info { background: var(--primary-soft); color: var(--primary-d); }
.toasts { position: fixed; bottom: 20px; right: 20px; display: flex; flex-direction: column; gap: 8px; z-index: 100; }
.toast { background: var(--navy); color: #fff; padding: 12px 18px; border-radius: 12px; box-shadow: var(--shadow-lg); font-weight: 600; animation: toast-in .25s ease; }
.toast.err { background: var(--red); }
@keyframes toast-in { from { transform: translateY(10px); opacity: 0; } }

.empty { text-align: center; color: var(--muted); padding: 22px 12px; display: flex; flex-direction: column; align-items: center; gap: 8px; }
.empty > .i { width: 34px; height: 34px; color: #b6c4da; }
.empty p { font-size: 14px; max-width: 280px; }

/* Tableaux */
.table-wrap { overflow-x: auto; }
table.tbl { width: 100%; border-collapse: collapse; font-size: 14px; }
.tbl th { text-align: left; font-size: 13px; color: #33496b; font-weight: 700; padding: 10px 12px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.tbl td { padding: 11px 12px; border-bottom: 1px solid var(--line-2); vertical-align: middle; }
.tbl tr:last-child td { border-bottom: 0; }
.tbl tr:hover td { background: #fafcff; }
.tbl .r { text-align: right; }

/* Barre d'actions rapides */
.quick-bar { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 14px; margin-top: 18px; }
.qa { display: flex; align-items: center; gap: 12px; padding: 14px 16px; border-radius: 14px; background: color-mix(in srgb, var(--mc) 8%, #fff); border: 1px solid color-mix(in srgb, var(--mc) 18%, #fff); color: var(--text); font-weight: 700; font-size: 14px; line-height: 1.2; }
.qa:hover { background: color-mix(in srgb, var(--mc) 14%, #fff); }
.qa-ic { color: var(--mc); display: inline-flex; }
.qa-ic .i { width: 26px; height: 26px; }
.qa span:nth-child(2) { flex: 1; }
.qa-go { color: var(--mc); width: 16px; height: 16px; }

/* Encarts illustrés */
.tip { background: linear-gradient(135deg, #fdf2ff, #fde7f3); border: 1px solid #f7d4ea; }
.tip-green { background: linear-gradient(135deg, #f0fbf3, #e4f7ea); border-color: #ccecd6; }
.tip-blue { background: linear-gradient(135deg, #eff6ff, #e6efff); border-color: #d4e3fb; }
.tip-yellow { background: linear-gradient(135deg, #fffaf0, #fff3dc); border-color: #f8e3b5; }
.tip h3 { font-size: 16px; font-weight: 800; display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }
.photo-card { padding: 0; overflow: hidden; min-height: 150px; position: relative; background: var(--banner) center / cover, #4c4a8a; justify-content: flex-end; }
.photo-card .hand { position: absolute; top: 16px; left: 18px; right: 18px; color: #fff; font-size: 22px; line-height: 1.05; transform: rotate(-6deg); text-shadow: 0 2px 8px rgba(0, 0, 0, .4); }

/* Conseils */
.advice { border-radius: 14px; padding: 14px 16px; margin-bottom: 10px; display: flex; gap: 12px; align-items: flex-start; background: color-mix(in srgb, var(--c) 9%, #fff); border: 1px solid color-mix(in srgb, var(--c) 18%, #fff); }
.advice:last-child { margin-bottom: 0; }
.advice .i { width: 28px; height: 28px; color: var(--c); }
.advice strong { color: color-mix(in srgb, var(--c) 72%, #0f2342); display: block; }
.advice p { font-size: 13px; color: #3d4b61; }

/* ---------------- Calendrier ---------------- */
.cal-week { display: grid; grid-template-columns: 54px repeat(7, minmax(0, 1fr)); border-top: 1px solid var(--line); position: relative; }
.cal-week .ch { text-align: center; padding: 10px 4px; font-weight: 800; border-bottom: 1px solid var(--line); font-size: 15px; }
.cal-week .ch small { display: block; font-weight: 600; color: var(--muted); font-size: 13px; }
.cal-week .ch.today { color: var(--primary-ink); }
.cal-col { position: relative; border-left: 1px solid var(--line-2); }
.cal-hours { position: relative; }
.cal-hours div, .cal-col .slot { height: 46px; }
.cal-hours div:first-child { transform: none !important; }
.cal-hours div { font-size: 12px; color: var(--muted); text-align: right; padding-right: 8px; transform: translateY(-8px); }
.cal-col .slot { border-bottom: 1px dashed #eef2f8; }
.cal-allday { padding: 4px; min-height: 30px; border-left: 1px solid var(--line-2); border-bottom: 1px solid var(--line); display: flex; flex-direction: column; gap: 3px; }
.ev { position: absolute; left: 4px; right: 4px; border-radius: 9px; padding: 5px 7px; font-size: 12px; line-height: 1.25; overflow: hidden; background: color-mix(in srgb, var(--c) 14%, #fff); border: 1px solid color-mix(in srgb, var(--c) 35%, #fff); color: color-mix(in srgb, var(--c) 70%, #0f2342); cursor: pointer; }
.ev strong { display: block; font-weight: 800; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ev-chip { position: static; display: block; padding: 3px 7px; }
.ev-chip strong { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ev-chip strong small { font-weight: 600; opacity: .75; font-size: 10.5px; }
.ev[draggable="true"] { cursor: grab; }
.ev.dragging { opacity: .35; }
.drop-on { background: color-mix(in srgb, var(--primary) 14%, transparent) !important; outline: 2px dashed var(--primary); outline-offset: -2px; }
.cal-col .ev.ev-cont-top { border-top-left-radius: 0; border-top-right-radius: 0; }
.cal-col .ev.ev-cont-bottom { border-bottom-left-radius: 0; border-bottom-right-radius: 0; }
.ev:hover { filter: brightness(.97); box-shadow: 0 3px 10px rgba(15, 35, 66, .1); z-index: 2; }
.now-line { position: absolute; left: 0; right: 0; height: 2px; background: var(--red); z-index: 3; }
.now-line::before { content: ""; position: absolute; left: -4px; top: -3px; width: 8px; height: 8px; border-radius: 50%; background: var(--red); }

.cal-month { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); border-top: 1px solid var(--line); border-left: 1px solid var(--line-2); }
.cal-month .mh { text-align: center; font-size: 13px; font-weight: 800; padding: 8px; color: #33496b; border-right: 1px solid var(--line-2); border-bottom: 1px solid var(--line); }
.cal-month .md { min-height: 108px; padding: 6px; border-right: 1px solid var(--line-2); border-bottom: 1px solid var(--line-2); display: flex; flex-direction: column; gap: 3px; cursor: pointer; }
.cal-month .md:hover { background: #fafcff; }
.cal-month .md.out { background: #fbfcfe; color: #a3b0c4; }
.cal-month .md .n { font-weight: 800; font-size: 13px; }
.cal-month .md.today .n { background: var(--primary); color: var(--on-primary); border-radius: 50%; width: 24px; height: 24px; display: grid; place-items: center; }
.mini-cal { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; text-align: center; font-size: 13px; }
.mini-cal b { font-size: 12px; color: var(--muted); padding: 4px 0; font-weight: 700; }
.mini-cal a { padding: 6px 0; border-radius: 50%; color: var(--text); font-weight: 600; aspect-ratio: 1; display: grid; place-items: center; }
.mini-cal a:hover { background: var(--primary-soft); }
.mini-cal a.out { color: #8a97ab; }
.mini-cal a.sel { background: var(--primary); color: var(--on-primary); }
.mini-cal a { position: relative; }
.mini-cal a.has::after { content: ""; position: absolute; bottom: 3px; left: 50%; width: 5px; height: 5px; margin-left: -2.5px; border-radius: 50%; background: #60a5fa; }
.mini-cal a.sel.has::after { background: #fff; }
.legend { display: flex; flex-direction: column; gap: 8px; font-size: 14px; }
.legend span { display: flex; align-items: center; gap: 10px; }

/* Planning repas */
.meal-grid { display: grid; grid-template-columns: 96px repeat(3, minmax(0, 1fr)); gap: 8px; }
.meal-grid .mh { padding: 10px; border-radius: 12px; text-align: center; font-weight: 800; display: flex; justify-content: center; align-items: center; gap: 8px; }
.meal-grid .md { border-radius: 12px; background: #f3f7fd; padding: 10px; text-align: center; display: flex; flex-direction: column; justify-content: center; }
.meal-grid .md strong { font-size: 17px; }
.meal-grid .md small { color: var(--muted); }
.meal-grid .md.today { background: var(--primary-soft); color: var(--primary-d); }
.meal-cell { border: 1px solid var(--line-2); border-radius: 12px; padding: 10px 12px; min-height: 64px; display: flex; align-items: center; gap: 10px; background: #fff; cursor: pointer; transition: border-color .15s; }
.meal-cell:hover { border-color: #b8cdf3; }
.meal-cell.empty-cell { border-style: dashed; color: #6f7f96; justify-content: center; font-weight: 700; font-size: 13px; }
.meal-cell .ic-bubble { width: 42px; height: 42px; }
.meal-cell strong { font-size: 14px; display: block; }
.meal-cell small { color: var(--muted); font-size: 12.5px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { display: inline-flex; align-items: center; gap: 6px; padding: 6px 14px; border-radius: 999px; font-weight: 700; font-size: 13.5px; background: var(--primary-soft); color: var(--primary-d); }
.chip button { border: 0; background: none; padding: 0; cursor: pointer; color: inherit; opacity: .5; display: inline-flex; }
.chip button:hover { opacity: 1; }
.chip.green { background: var(--green-soft); color: #15803d; }
.chip.red { background: var(--red-soft); color: #be123c; }
.chip.violet { background: var(--violet-soft); color: #6d28d9; }

/* Recettes */
.recipe-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 14px; }
.recipe { border: 1px solid var(--line); border-radius: 14px; overflow: hidden; background: #fff; display: flex; flex-direction: column; }
.recipe-top { height: 92px; display: grid; place-items: center; background: linear-gradient(135deg, #fff1e6, #ffe4cc); color: #f97316; position: relative; }
.recipe-top .i { width: 40px; height: 40px; }
.recipe-top .fav { position: absolute; top: 8px; right: 8px; background: #fff; border-radius: 50%; }
.recipe-top .fav.on { color: var(--red); }
.recipe-top .fav.on .i { fill: currentColor; }
.recipe-b { padding: 12px; flex: 1; display: flex; flex-direction: column; gap: 6px; }
.recipe-b strong { font-size: 15px; }

/* Courses */
.cat-block { border: 1px solid var(--line-2); border-radius: 14px; margin-bottom: 10px; overflow: hidden; }
.cat-h { display: flex; align-items: center; gap: 10px; padding: 10px 14px; background: color-mix(in srgb, var(--c) 8%, #fff); cursor: pointer; user-select: none; }
.cat-h strong { font-size: 16px; }
.cat-h .cnt { color: color-mix(in srgb, var(--c) 72%, #0f2342); font-weight: 800; }
.cat-h .chev { margin-left: auto; transition: transform .2s; }
.cat-block.closed .chev { transform: rotate(-90deg); }
.cat-block.closed .cat-items { display: none; }
.cat-items { padding: 2px 14px; }
.item-emoji { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; background: #f5f8fc; font-size: 19px; flex: none; }

/* Enfants */
.kid-badge { background: color-mix(in srgb, var(--c) 12%, var(--card)); color: color-mix(in srgb, var(--c) 72%, #0f2342); }
.kid-card { position: relative; overflow: hidden; box-shadow: none; background: color-mix(in srgb, var(--c) 4%, var(--card)); }
.kid-top { display: flex; gap: 16px; align-items: center; }
.kid-top h2 { font-size: 26px; font-weight: 800; color: color-mix(in srgb, var(--c) 72%, #0f2342); display: flex; align-items: center; gap: 6px; }
.kid-top .age { color: color-mix(in srgb, var(--c) 72%, #0f2342); font-weight: 700; font-size: 16px; }
.kid-top .bd { color: var(--muted); font-size: 14px; }
.kid-deco { position: absolute; right: 18px; top: 60px; font-size: 64px; opacity: .9; pointer-events: none; }
.info-line { display: flex; gap: 12px; align-items: flex-start; padding: 8px 0; }
.info-line strong { display: block; font-size: 14px; }
.info-line span.v { color: #44546d; font-size: 13.5px; }
.stars { color: #f472b6; letter-spacing: 2px; }
.reward { border-radius: 14px; padding: 14px; background: color-mix(in srgb, var(--c) 7%, #fff); }
.reward h4 { color: color-mix(in srgb, var(--c) 72%, #0f2342); display: flex; align-items: center; gap: 6px; margin-bottom: 6px; }
.reward .score { font-size: 22px; font-weight: 800; color: color-mix(in srgb, var(--c) 72%, #0f2342); }

/* Fichiers */
.ftype { width: 36px; height: 36px; border-radius: 9px; display: grid; place-items: center; color: #fff; background: var(--c); flex: none; }
.ftype.folder { background: none; color: var(--c); }
.ftype.folder .i { width: 32px; height: 32px; fill: color-mix(in srgb, var(--c) 70%, #fff); stroke: var(--c); }
.ring { --p: 0; width: 86px; height: 86px; border-radius: 50%; background: conic-gradient(var(--primary) calc(var(--p) * 1%), #e8eef7 0); display: grid; place-items: center; flex: none; }
.ring::before { content: ""; grid-area: 1/1; width: 66px; height: 66px; border-radius: 50%; background: #fff; }
.ring b { grid-area: 1/1; z-index: 1; font-size: 18px; }
.breadcrumb { display: flex; align-items: center; gap: 6px; font-weight: 700; flex-wrap: wrap; }
.breadcrumb a { color: var(--muted); }
.dropzone { border: 2px dashed #c6d5ee; border-radius: 14px; padding: 22px; text-align: center; color: var(--muted); background: #f8fbff; }
.dropzone.over { border-color: var(--primary); background: var(--primary-soft); }

/* Finances / statistiques */
.stat { display: flex; align-items: center; gap: 16px; padding: 18px; border-radius: var(--radius); background: color-mix(in srgb, var(--c) 6%, #fff); border: 1px solid color-mix(in srgb, var(--c) 18%, #fff); }
.stat .ic-bubble { width: 60px; height: 60px; border-radius: 50%; background: color-mix(in srgb, var(--c) 85%, #fff); color: #fff; }
.stat .ic-bubble .i { width: 28px; height: 28px; }
.stat small { color: #44546d; font-weight: 600; font-size: 14px; display: block; }
.stat strong { font-size: 28px; font-weight: 800; display: block; line-height: 1.15; color: color-mix(in srgb, var(--c) 60%, #0f2342); }
.stat em { font-style: normal; font-size: 13px; color: #44546d; }
.donut { --a: 50; width: 160px; height: 160px; border-radius: 50%; background: conic-gradient(#3b82f6 calc(var(--a) * 1%), #f472b6 0); display: grid; place-items: center; flex: none; }
.donut.empty-donut { background: #e8eef7; }
.donut::before { content: ""; grid-area: 1/1; width: 108px; height: 108px; border-radius: 50%; background: #fff; }
.donut div { grid-area: 1/1; z-index: 1; text-align: center; }
.donut strong { font-size: 24px; font-weight: 800; display: block; }
.donut small { color: var(--muted); }
.opt { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 14px; border: 1px solid var(--line); cursor: pointer; margin-bottom: 10px; }
.opt:has(input:checked) { border-color: #6ee7b7; background: #f0fdf7; }
.opt input { accent-color: var(--green); width: 18px; height: 18px; margin-left: auto; }
.opt strong { display: block; font-size: 14.5px; }
.opt small { color: var(--muted); font-size: 12.5px; }
.amount-neg { color: var(--red); font-weight: 800; white-space: nowrap; }
.amount-pos { color: var(--green); font-weight: 800; white-space: nowrap; }

/* Météo (module) */
.w-now { display: flex; align-items: center; gap: 22px; flex-wrap: wrap; }
.w-now .temp { font-size: 56px; font-weight: 800; line-height: 1; }
.w-days { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 8px; text-align: center; }
.w-day { border-radius: 12px; padding: 10px 4px; background: #f6f9fe; font-size: 13px; }
.w-day b { display: block; }
.w-day .mx { font-weight: 800; }
.w-day .mn { color: var(--muted); }
.w-hours { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 6px; }
.w-hour .wi, .w-day .wi { display: grid; margin: 4px auto; }
.w-hour { min-width: 64px; text-align: center; border-radius: 12px; background: #f6f9fe; padding: 10px 4px; font-size: 13px; }
.w-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.w-stats div { background: #f6f9fe; border-radius: 12px; padding: 10px 12px; font-size: 13px; }
.w-stats strong { display: block; font-size: 16px; }

/* Paramètres */
.mod-row { display: flex; align-items: center; gap: 14px; padding: 12px 0; border-bottom: 1px solid var(--line-2); }
.mod-row:last-child { border-bottom: 0; }
.member-card { display: flex; align-items: center; gap: 12px; padding: 12px; border: 1px solid var(--line); border-radius: 14px; }

/* ---------------- Pages publiques (landing / auth) ---------------- */
.pub { background: #fff; }
.pub-nav { display: flex; align-items: center; gap: 28px; padding: 14px max(24px, calc((100vw - 1340px) / 2)); position: sticky; top: 0; z-index: 30; background: rgba(255, 255, 255, .92); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line-2); }
.logo { display: flex; align-items: center; gap: 12px; color: var(--heading); }
.logo img, .logo .logo-mark { width: 52px; height: 52px; flex: none; }
.logo-mark .lm-ink { fill: var(--logo-ink, #1e293b); }
.logo-mark .lm-ink-s { stroke: var(--logo-ink, #1e293b); }
.logo-mark .lm-win { fill: var(--logo-win, #ffffff); }
.logo-mark .lm-day { fill: #f97316; }
html.dark .logo { --logo-ink: #f1f5f9; --logo-win: #0b1424; }
.auth-side .logo { --logo-ink: #ffffff; --logo-win: #0f172a; }
.logo strong { display: block; font-size: 30px; font-weight: 800; letter-spacing: -.02em; line-height: 1; }
.logo small { color: var(--muted); font-size: 13px; }
.pub-links { display: flex; gap: 28px; margin-left: 40px; }
.pub-links a { color: var(--text); font-weight: 600; padding: 6px 0; border-bottom: 2px solid transparent; }
.pub-links a:hover, .pub-links a.active { color: var(--primary-ink); border-color: var(--primary); }
.pub-cta { margin-left: auto; display: flex; gap: 12px; }
.pill { display: inline-flex; align-items: center; gap: 8px; background: var(--primary-soft); color: var(--primary-d); padding: 6px 14px; border-radius: 999px; font-weight: 700; font-size: 14px; }
.pill .i { color: var(--red); fill: var(--red); }
.checks { display: flex; gap: 20px; margin-top: 16px; color: #26395a; font-weight: 600; font-size: 14px; flex-wrap: wrap; }
.checks .i { color: var(--green); }
.pub-section { padding: 10px max(24px, calc((100vw - 1340px) / 2)) 30px; }
.preview { background: var(--navy); border-radius: 14px; display: grid; grid-template-columns: 120px 1fr; overflow: hidden; box-shadow: var(--shadow-lg); font-size: 11px; }
.preview .pv-side { padding: 12px 8px; color: #dbe6ff; display: flex; flex-direction: column; gap: 3px; }
.preview .pv-side span { display: flex; gap: 6px; align-items: center; padding: 4px 6px; border-radius: 6px; }
.preview .pv-side span.on { background: var(--primary); color: var(--on-primary); }
.preview .pv-side .i { width: 12px; height: 12px; }
.preview .pv-main { background: var(--bg); }
.preview .pv-hero { height: 70px; background: linear-gradient(90deg, rgba(10, 22, 50, .6), transparent), url(../img/banner.svg) center / cover; color: #fff; display: flex; align-items: center; gap: 10px; padding: 0 12px; font-weight: 800; font-size: 15px; }
.preview .pv-hero .photo-ph { width: 44px; height: 44px; border-radius: 50%; border: 2px solid #fff; }
.preview .pv-cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; padding: 8px; }
.preview .pv-cards div { background: #fff; border-radius: 8px; padding: 8px; display: flex; gap: 6px; align-items: center; font-weight: 700; }
.preview .pv-cards .i { color: var(--mc); width: 16px; height: 16px; }
.preview .pv-rows { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; padding: 0 8px 10px; }
.preview .pv-rows div { background: #fff; border-radius: 8px; padding: 8px; height: 72px; }
.preview .pv-rows i { display: block; height: 6px; border-radius: 4px; background: #e3eaf5; margin: 6px 0; }

.auth-wrap { min-height: 100vh; display: grid; grid-template-columns: 1fr 1fr; }
.auth-side { background: #0f172a; color: #e2e8f0; padding: 40px 0 40px 48px; display: flex; flex-direction: column; gap: 36px; overflow: hidden; }
.auth-side .logo { padding-right: 48px; }
.auth-pitch { padding-right: 48px; max-width: 520px; }
.auth-pitch h2 { font-size: 30px; line-height: 1.2; font-weight: 700; letter-spacing: -.02em; color: #fff; margin: 0 0 20px; }
.auth-pitch ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; color: #cbd5e1; }
.auth-pitch li { display: flex; gap: 10px; align-items: center; }
.auth-pitch .i { color: #93c5fd; width: 18px; height: 18px; flex: none; }
.auth-shot { flex: 1; min-height: 0; }
.auth-shot img { display: block; width: 125%; max-width: none; height: auto; border-radius: 10px 0 0 10px; box-shadow: 0 30px 60px rgba(0, 0, 0, .45); }
.auth-trust { display: flex; gap: 8px; align-items: center; font-size: 13.5px; color: #94a3b8; margin: 0; padding-right: 48px; }
.auth-side .logo { color: #fff; }
.auth-side .logo small { color: #dbe6ff; }
.auth-main { display: grid; place-items: center; padding: 30px 20px; background: var(--bg); }
.auth-card { width: min(440px, 100%); background: #fff; border-radius: 14px; padding: 32px; box-shadow: var(--shadow); border: 1px solid var(--line); }
.auth-card h1 { font-size: 28px; font-weight: 800; margin-bottom: 6px; }
.auth-card .sub { color: var(--muted); margin-bottom: 22px; }
.auth-card .alert { margin: 0 0 16px; }
.input-ic { position: relative; }
.input-ic > .i { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--muted); }
.input-ic input { padding-left: 40px; }

/* ---------------- Responsive ---------------- */
@media (max-width: 1400px) {
  .g-side-l { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .g-side-l > :last-child { grid-column: span 2; }
}
@media (max-width: 1200px) {
  .g-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .g-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .g-side { grid-template-columns: minmax(0, 1fr); }
  .hero-quote { display: none; }
}
@media (max-width: 900px) {
  .sidebar { position: fixed; left: 0; transform: translateX(-100%); transition: transform .25s; box-shadow: var(--shadow-lg); }
  body.side-open .sidebar { transform: none; }
  .scrim { display: none; position: fixed; inset: 0; background: rgba(9, 20, 45, .45); z-index: 35; }
  body.side-open .scrim { display: block; }
  .hero .burger { display: grid; }
  .hero { padding: 54px 18px 18px; flex-direction: column; align-items: flex-start; min-height: 0; }
  .hero.has-weather { padding-right: 18px; }
  .hero-weather { position: static; width: auto; border-radius: 14px; flex-direction: row; align-items: center; padding: 10px 14px; gap: 18px; }
  .hero h1 { font-size: 26px; }
  .hero-photo { width: 76px; height: 76px; }
  .hero-ic { width: 60px; height: 60px; }
  .hero-ic .i { width: 28px; height: 28px; }
  .content { padding: 14px 14px 6px; }
  .g-4, .g-3, .g-2, .g-side-l { grid-template-columns: minmax(0, 1fr); }
  .g-side-l > :last-child, .span-2, .span-3 { grid-column: auto; }
  .meal-grid { grid-template-columns: 70px repeat(3, minmax(130px, 1fr)); overflow-x: auto; }
  .cal-week { min-width: 760px; }
  .cal-scroll { overflow-x: auto; }
  .pub-links { display: none; }
  .auth-wrap { grid-template-columns: 1fr; }
  .auth-side { display: none; }
  .w-days { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .search input, .search input[type=search] { min-width: 0; }
  .cal-nav { flex-wrap: wrap; }
  .cal-nav strong { min-width: 0 !important; font-size: 16px !important; }
  .toolbar > * { max-width: 100%; }
  .main { overflow-x: hidden; }
  .f-row, .f-row3 { grid-template-columns: 1fr; }
  .pub-cta .btn-ghost { display: none; }
}
@media (min-width: 901px) { .scrim { display: none; } }
.tip-ic { width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; background: #2563eb; color: #fff; flex: none; box-shadow: 0 6px 16px rgba(37, 99, 235, .3); }
.tip-ic .i { width: 28px; height: 28px; }
.mh-state { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; font-weight: 700; padding: 4px 10px; border-radius: 99px; white-space: nowrap; flex: none; }
.mh-state i { width: 8px; height: 8px; border-radius: 50%; background: currentColor; }
.mh-state.mh-green { background: #e6f6ec; color: #15803d; }
.mh-state.mh-orange { background: #fff1e0; color: #c2570c; }
.mh-state.mh-red { background: #fde8ec; color: #be123c; }
.mh-flags { display: flex; flex-wrap: wrap; gap: 4px 6px; margin-top: 3px; }
.mh-flag { font-size: 11.5px; padding: 1px 8px; border-radius: 99px; background: #eef3fb; color: #33496b; }
.mh-flag.mh-red { background: #fde8ec; color: #be123c; }
.mh-flag.mh-orange { background: #fff1e0; color: #c2570c; }
.mh-flag.mh-blue { background: #e4edff; color: #1d4ed8; }
.brand-ic.has-photo { border-radius: 50%; overflow: hidden; border: 2px solid rgba(255, 255, 255, .85); box-shadow: 0 4px 12px rgba(0, 0, 0, .3); flex: none; }
.brand-ic.has-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* ---------- Statistiques (administration) ---------- */
.stat .trend { display: block; font-size: 11.5px; font-weight: 700; color: var(--muted); margin-top: 2px; }
.stat .trend.up { color: #15803d; }
.stat .trend.down { color: #be123c; }
.sub-h { font-size: 13px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); margin: 18px 0 8px; }
.nowrap { white-space: nowrap; }
.vchart { margin: 0; }
.vc-plot { position: relative; height: 180px; margin-left: 34px; }
.vc-grid { position: absolute; left: 0; right: 0; border-top: 1px dashed #e3e9f3; }
.vc-grid::before { content: attr(data-v); position: absolute; right: calc(100% + 6px); top: -8px; font-size: 11px; color: var(--muted); }
.vc-grid { top: 0; }
.vc-grid.mid { top: 50%; }
.vc-grid.zero { top: 100%; border-top: 1px solid #cdd6e4; }
.vc-bars { position: absolute; inset: 0; display: flex; align-items: flex-end; gap: 2px; }
.vc-bar { flex: 1; height: 100%; display: flex; align-items: flex-end; position: relative; cursor: default; outline: none; }
.vc-bar i { display: block; width: 100%; background: var(--c); border-radius: 4px 4px 0 0; min-height: 0; opacity: .85; transition: opacity .15s; }
.vc-bar:hover i, .vc-bar:focus i { opacity: 1; }
.vc-bar:hover::after, .vc-bar:focus::after { content: attr(data-tip); position: absolute; bottom: calc(100% + 6px); left: 50%; transform: translateX(-50%); background: #0f2342; color: #fff; font-size: 12px; font-weight: 600; padding: 5px 9px; border-radius: 8px; white-space: nowrap; z-index: 5; pointer-events: none; }
.vc-bar:first-child:hover::after, .vc-bar:first-child:focus::after { left: 0; transform: none; }
.vc-bar:last-child:hover::after, .vc-bar:last-child:focus::after { left: auto; right: 0; transform: none; }
.vc-x { display: flex; gap: 2px; margin: 6px 0 0 34px; }
.vc-x span { flex: 1; font-size: 10.5px; color: var(--muted); white-space: nowrap; overflow: visible; }
.vc-table { margin-top: 8px; font-size: 12.5px; }
.vc-table summary { cursor: pointer; color: var(--muted); }
.vc-table table { margin-top: 6px; }
.hbars { display: flex; flex-direction: column; gap: 7px; }
.hb-row { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr) auto; gap: 10px; align-items: center; font-size: 13px; }
.hb-label { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hb-track { height: 8px; background: #eef2f8; border-radius: 99px; overflow: hidden; }
.hb-track i { display: block; height: 100%; background: var(--c); border-radius: 99px; }
.hb-val { font-weight: 700; font-variant-numeric: tabular-nums; text-align: right; }
.hb-val small { color: var(--muted); font-weight: 600; margin-left: 4px; }
.ev-filter select { width: auto; padding: 6px 10px; font-size: 13px; }
.ev-log { max-height: 520px; overflow-y: auto; }
.sess-tbl td { vertical-align: middle; }

/* ---------- Tableau de bord personnalisable ---------- */
.dash-bar { display: flex; justify-content: flex-end; align-items: center; gap: 10px; margin: 0 0 12px; flex-wrap: wrap; }
.dash-edit-tools { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.dash-edit-tools[hidden] { display: none; }
.dash { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; align-items: start; grid-auto-flow: dense; }
.dw { min-width: 0; position: relative; }
.dw[data-size="m"] { grid-column: span 2; }
.dw[data-size="l"] { grid-column: 1 / -1; }
.dw.off { display: none; }
.dw-body > .card { margin: 0; }
/* Petit format : contenu compact (3 lignes), sans grand vide */
.dw[data-size="s"]:not([data-w="members"]):not([data-w="quick"]):not([data-w="info"]) .rows > :nth-child(n+4) { display: none; }
.dw[data-size="s"] .empty { padding: 8px 6px; flex-direction: row; text-align: left; gap: 10px; }
.dw[data-size="s"] .empty > .i { width: 24px; height: 24px; flex: none; }
.dw[data-size="s"] .card.tip { min-height: 0 !important; }
.dw[data-size="s"] .card-foot .btn { padding: 8px 10px; font-size: 13px; }
/* Moyen / grand format : listes sur plusieurs colonnes */
.dw:not([data-size="s"]) .rows { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); column-gap: 18px; }
/* Mode personnalisation */
.dw-ctl { display: none; }
.dash.editing .dw { cursor: grab; padding-top: 30px; }
.dash.editing .dw.off { display: block; opacity: .45; }
.dash.editing .dw-body { pointer-events: none; user-select: none; }
.dash.editing .dw-body > .card { outline: 2px dashed #9db8ee; outline-offset: 2px; animation: dw-wiggle .28s ease-in-out infinite alternate; }
.dash.editing .dw.dragging { opacity: .35; }
.dash.editing .dw { -webkit-touch-callout: none; -webkit-user-select: none; user-select: none; }
.dash.editing .dw.lifted { opacity: .6; transform: scale(.98); transition: transform .15s; }
.dash.editing .dw.lifted .dw-body > .card { outline: 2px solid var(--primary); box-shadow: 0 14px 30px rgba(15, 35, 66, .25); animation: none; }
.dash.editing .dw.over .dw-body > .card { outline-color: var(--primary); background: #f5f9ff; }
.dash.editing .dw-ctl { display: flex; align-items: center; gap: 4px; position: absolute; z-index: 5; top: 0; left: 50%; transform: translateX(-50%); background: #fff; border: 1px solid #cfdcf3; border-radius: 12px; padding: 3px 5px; box-shadow: 0 6px 18px rgba(15, 35, 66, .16); white-space: nowrap; }
.dw-grip { border: 0; background: none; color: var(--muted); cursor: grab; display: grid; place-items: center; width: 28px; height: 32px; }
.dw-sizes { display: inline-flex; background: #eef3fb; border-radius: 9px; padding: 2px; margin: 0 4px; }
.dw-sizes button { border: 0; background: none; font-weight: 800; font-size: 12px; color: #475569; width: 28px; height: 26px; border-radius: 7px; cursor: pointer; }
.dw[data-size="s"] [data-dw-size="s"], .dw[data-size="m"] [data-dw-size="m"], .dw[data-size="l"] [data-dw-size="l"] { background: #fff; color: var(--primary-ink); box-shadow: 0 1px 3px rgba(15, 35, 66, .15); }
@keyframes dw-wiggle { from { transform: rotate(-.25deg); } to { transform: rotate(.25deg); } }
@media (prefers-reduced-motion: reduce) { .dash.editing .dw-body > .card { animation: none; } }
@media (max-width: 1200px) { .dash { grid-template-columns: repeat(2, minmax(0, 1fr)); } .dw[data-size="l"] { grid-column: 1 / -1; } }
@media (max-width: 640px) { .dash { grid-template-columns: minmax(0, 1fr); } .dw[data-size="m"], .dw[data-size="l"] { grid-column: auto; } .dw:not([data-size="s"]) .rows { grid-template-columns: minmax(0, 1fr); } }

/* Disposition « mosaïque » : les widgets se calent les uns sous les autres sans trous (hauteurs mesurées en JS) */
.dash.masonry { grid-auto-rows: 8px; row-gap: 0; overflow-anchor: none; }
.dash.masonry .dw { align-self: start; }

.chip-pick { cursor: pointer; background: #eef3fb; color: #334155; border: 2px solid transparent; user-select: none; }
.chip-pick input { position: absolute; opacity: 0; pointer-events: none; }
.chip-pick:has(input:checked) { background: var(--primary-soft); color: var(--primary-d); border-color: var(--primary); }
.chip-pick:has(input:focus-visible) { outline: 2px solid var(--primary); outline-offset: 2px; }

/* Date et heure dans le header (accueil) */
.hero-clock { display: inline-flex; align-items: center; gap: 8px; margin-top: 10px; padding: 5px 14px 5px 11px; border-radius: 999px; background: rgba(255, 255, 255, .16); backdrop-filter: blur(6px); border: 1px solid rgba(255, 255, 255, .25); font-size: 14px; font-weight: 600; text-shadow: 0 1px 6px rgba(0, 0, 0, .3); }
.hero-clock .i { opacity: .85; }
.hero-clock i { width: 1px; height: 14px; background: rgba(255, 255, 255, .45); }
.hero-clock strong { font-variant-numeric: tabular-nums; font-size: 15px; letter-spacing: .02em; }
/* Bandeau d'anniversaire */
.birthday { position: relative; overflow: hidden; display: flex; align-items: center; justify-content: center; gap: 18px; flex-wrap: wrap; margin-bottom: 18px; padding: 18px 24px; border-radius: 20px; color: #fff; background: linear-gradient(120deg, #ff5f8d, #ff9966 45%, #ffcf5c); box-shadow: 0 10px 28px rgba(255, 105, 135, .35); }
.birthday .bd-emoji { font-size: 38px; animation: bd-bounce 1.6s ease-in-out infinite; }
.birthday .bd-emoji:last-of-type { animation-delay: .4s; }
.birthday .av { border: 3px solid #fff; box-shadow: 0 4px 14px rgba(0, 0, 0, .2); }
.bd-text { text-align: center; position: relative; z-index: 1; }
.bd-text h2 { font-size: 26px; font-weight: 800; text-shadow: 0 2px 10px rgba(120, 30, 50, .35); }
.bd-text p { font-size: 17px; margin-top: 2px; font-weight: 600; text-shadow: 0 1px 6px rgba(120, 30, 50, .3); }
.birthday .confetti { position: absolute; inset: 0; pointer-events: none; opacity: .55; background-image: radial-gradient(circle, #fff 2px, transparent 3px), radial-gradient(circle, #2563eb 3px, transparent 4px), radial-gradient(circle, #16a34a 2px, transparent 3px), radial-gradient(circle, #a855f7 3px, transparent 4px); background-size: 90px 70px, 130px 90px, 110px 80px, 150px 100px; background-position: 0 0, 40px 30px, 70px 10px, 20px 50px; }
@keyframes bd-bounce { 0%, 100% { transform: translateY(0) rotate(-6deg); } 50% { transform: translateY(-6px) rotate(6deg); } }
@media (prefers-reduced-motion: reduce) { .birthday .bd-emoji { animation: none; } }

/* Rentrée scolaire */
.promo-banner { display: flex; gap: 18px; align-items: flex-start; margin-bottom: 18px; background: linear-gradient(120deg, #eff6ff, #f5f3ff); border-color: #c7d2fe; }
.promo-ic { width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center; background: #4f46e5; color: #fff; flex: none; }
.promo-ic .i { width: 26px; height: 26px; }
.promo-main { flex: 1; min-width: 0; }
.promo-main h3 { font-size: 18px; }
.promo-list { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 12px; }
.promo-item { display: flex; align-items: center; gap: 10px; background: #fff; border: 1px solid #e0e7ff; border-radius: 14px; padding: 8px 10px 8px 12px; }

/* Santé : carnet, prises, mesures */
.f-row4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
@media (max-width: 560px) { .f-row4 { grid-template-columns: repeat(2, 1fr); } }
.sub-h { display: flex; align-items: center; gap: 6px; margin: 4px 0 6px; font-size: 12px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted, #64748b); }
.slot { align-items: center; }
.slot-late { background: #fff7ed; border-radius: 12px; }
.slot .time { font-variant-numeric: tabular-nums; font-weight: 700; min-width: 44px; }
.intake-btns { display: inline-flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.intake { display: inline-flex; align-items: center; gap: 4px; padding: 3px 10px; border-radius: 999px; font-size: 12px; font-weight: 700; white-space: nowrap; }
.intake.ok { background: #dcfce7; color: #15803d; }
.intake.no { background: #fee2e2; color: #b91c1c; }
.intake-log { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0 2px; }
.treat { padding: 12px 0; border-top: 1px solid var(--line-2, #eef2f7); }
.treat:first-of-type { border-top: 0; }
.treat-h { display: flex; align-items: center; gap: 10px; }
.treat-done { opacity: .7; }
.carnet-id { display: flex; align-items: center; gap: 16px; margin-bottom: 14px; flex-wrap: wrap; }
.carnet-id h2 { font-size: 22px; }
.carnet-id .blood { margin-left: auto; display: inline-flex; align-items: center; gap: 6px; padding: 8px 16px; border-radius: 14px; background: #fee2e2; color: #b91c1c; font-weight: 800; font-size: 20px; }
.info-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
@media (max-width: 700px) { .info-grid { grid-template-columns: 1fr; } }
.info-grid > div { background: #f8fafc; border: 1px solid #e8eef6; border-radius: 14px; padding: 10px 14px; min-width: 0; overflow-wrap: anywhere; }
.info-grid small { display: block; font-size: 11px; text-transform: uppercase; letter-spacing: .05em; color: #64748b; margin-bottom: 2px; }
.info-grid strong.warn { color: #b91c1c; }
.mkind { border: 1px solid #e8eef6; border-radius: 16px; padding: 12px 14px; background: #fff; }
.mkind-h { display: flex; align-items: center; gap: 12px; margin-bottom: 4px; }
.mkind-h .ic-bubble { --c: var(--c); }
.mkind-h small { display: block; color: #64748b; font-size: 12px; }
.mkind-h strong { font-size: 20px; color: var(--c); }
.spark { width: 100%; height: 46px; display: block; margin: 4px 0 6px; }
.slot { flex-wrap: wrap; row-gap: 6px; padding: 8px 6px; }
.slot .row-main { flex: 1 1 110px; min-width: 0; }
.slot .intake-btns, .slot > .intake { margin-left: 52px; }
.slot .intake-btns { width: 100%; justify-content: flex-start; margin-left: 52px; }

/* ===== Messagerie ===== */
.chat-opt { display: flex; align-items: center; gap: 12px; }
.chat-card { padding: 0; overflow: hidden; }
.chat-app { display: grid; grid-template-columns: 320px minmax(0, 1fr); height: clamp(480px, calc(100vh - 340px), 760px); }
.chat-side { border-right: 1px solid var(--line); display: flex; flex-direction: column; min-height: 0; background: #fbfdff; }
.chat-list { overflow-y: auto; padding: 8px; display: flex; flex-direction: column; gap: 2px; }
.chat-item { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; padding: 10px 12px; border: 0; border-radius: 14px; background: transparent; cursor: pointer; font: inherit; color: inherit; position: relative; }
.chat-item:hover { background: var(--primary-soft); }
.chat-item.active { background: #dbeafe; }
.ci-main { flex: 1; min-width: 0; }
.ci-top { display: flex; justify-content: space-between; gap: 8px; align-items: baseline; }
.ci-top small { color: var(--muted); font-size: 11px; flex: none; }
.ci-sub { font-size: 13px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ci-sub.state::before { content: ''; display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 6px; background: #94a3b8; }
.ci-sub.state.on { color: #15803d; }
.ci-sub.state.on::before { background: #22c55e; }
.ci-badge { min-width: 22px; height: 22px; padding: 0 6px; border-radius: 99px; background: var(--primary); color: var(--on-primary); font-size: 12px; font-weight: 800; display: grid; place-items: center; flex: none; }
.cav { position: relative; display: inline-flex; flex: none; }
.cav .av.fam { background: linear-gradient(135deg, #0ea5e9, #6366f1); }
.cav .av .i { width: 55%; height: 55%; }
.cav .ph { visibility: hidden; width: 24px; height: 24px; }
.pres { position: absolute; right: -1px; bottom: -1px; width: 12px; height: 12px; border-radius: 50%; border: 2px solid #fff; background: #94a3b8; }
.pres.on { background: #22c55e; }
.chat-main { display: flex; flex-direction: column; min-width: 0; min-height: 0; }
.chat-head, .cf-head { display: flex; align-items: center; gap: 12px; padding: 12px 16px; border-bottom: 1px solid var(--line); background: #fff; }
.cf-head { justify-content: flex-start; } .cf-head strong { flex: 1; font-size: 16px; }
.ch-who { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.presence { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 700; padding: 2px 10px 2px 8px; border-radius: 99px; width: fit-content; background: #f1f5f9; color: #64748b; }
.presence i { width: 8px; height: 8px; border-radius: 50%; background: #94a3b8; }
.presence.on { background: #dcfce7; color: #15803d; }
.presence.on i { background: #22c55e; box-shadow: 0 0 0 3px rgba(34, 197, 94, .25); }
.chat-back { display: none; }
.msgs { flex: 1; overflow-y: auto; padding: 16px; display: flex; flex-direction: column; gap: 4px; background: linear-gradient(#f6f9fe, #f1f5fb); }
.day-sep { align-self: center; margin: 10px 0 6px; padding: 3px 12px; border-radius: 99px; background: #e2e8f0; color: #475569; font-size: 12px; font-weight: 700; }
.msg { display: flex; gap: 8px; align-items: flex-end; max-width: 82%; margin-top: 8px; }
.msg.grouped { margin-top: 0; }
.msg.me { align-self: flex-end; flex-direction: row-reverse; }
.mcol { display: flex; flex-direction: column; min-width: 0; }
.msg.me .mcol { align-items: flex-end; }
.mname { color: var(--muted); font-weight: 700; margin: 0 0 2px 4px; font-size: 12px; }
.bubble { background: #fff; border: 1px solid var(--line); border-radius: 18px 18px 18px 6px; padding: 8px 13px; box-shadow: 0 1px 2px rgba(15, 35, 66, .05); overflow-wrap: anywhere; }
.msg.me .bubble { background: var(--primary); color: var(--on-primary); border-color: var(--primary); border-radius: 18px 18px 6px 18px; }
.msg.me .bubble a { color: #fff; text-decoration: underline; }
.mtext { white-space: pre-wrap; }
.mtime { color: var(--muted); font-size: 11px; margin: 2px 6px 0; display: flex; align-items: center; gap: 4px; }
.mdel { border: 0; background: transparent; color: var(--muted); cursor: pointer; padding: 0 2px; opacity: 0; display: inline-flex; }
.msg:hover .mdel, .mdel:focus-visible { opacity: 1; }
.att-img img { display: block; max-width: min(260px, 100%); max-height: 240px; border-radius: 12px; margin: 2px 0 4px; }
.att-file { display: flex; align-items: center; gap: 10px; padding: 6px 4px; color: inherit !important; text-decoration: none !important; }
.att-file span { display: flex; flex-direction: column; min-width: 0; }
.att-file strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 200px; font-size: 14px; }
.att-file small { opacity: .75; font-size: 11px; }
.composer { border-top: 1px solid var(--line); padding: 10px 12px; background: #fff; }
.composer.ro { color: var(--muted); font-size: 13px; text-align: center; }
.cp-row { display: flex; align-items: flex-end; gap: 8px; }
.cp-row textarea { flex: 1; resize: none; border: 1px solid var(--line); border-radius: 18px; padding: 10px 14px; font: inherit; max-height: 130px; min-height: 42px; background: #f8fafc; }
.cp-row textarea:focus { outline: 2px solid var(--primary); outline-offset: -1px; background: #fff; }
.cp-send { width: 44px; height: 44px; padding: 0; border-radius: 50%; display: grid; place-items: center; flex: none; }
.chip-file { display: flex; align-items: center; gap: 8px; margin: 0 0 8px; padding: 6px 8px 6px 12px; background: var(--primary-soft); border-radius: 12px; font-size: 13px; width: fit-content; max-width: 100%; }
.chip-file span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sending .cp-send { opacity: .5; pointer-events: none; }
.chat-empty { margin: auto; text-align: center; color: var(--muted); padding: 24px; }
.chat-empty .big { width: 48px; height: 48px; opacity: .4; }

/* Page : sur écran étroit, une seule colonne à la fois */
@media (max-width: 860px) {
  .chat-app.chat-v-page { grid-template-columns: 1fr; }
  .chat-v-page .chat-main { display: none; }
  .chat-v-page.show-thread .chat-side { display: none; }
  .chat-v-page.show-thread .chat-main { display: flex; }
  .chat-v-page .chat-back { display: inline-grid; }
  .msg { max-width: 92%; }
}

/* Chatbox flottante */
.chat-float { position: fixed; right: 22px; bottom: 22px; z-index: 40; }
.cf-btn { position: relative; height: 54px; padding: 0 22px 0 18px; gap: 10px; grid-auto-flow: column; border-radius: 99px; border: 0; cursor: pointer; background: linear-gradient(135deg, #0ea5e9, #2563eb); color: #fff; display: grid; place-items: center; box-shadow: 0 10px 28px rgba(37, 99, 235, .45); transition: transform .15s; }
.cf-btn:hover { transform: scale(1.06); }
.cf-btn .i { width: 24px; height: 24px; }
.cf-label { font-weight: 800; font-size: 15px; letter-spacing: .01em; }
.cf-btn.has-unread { animation: cf-pulse 2.2s ease-in-out infinite; }
.cf-count { position: absolute; top: -4px; right: -4px; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 99px; background: #e11d48; color: #fff; font-size: 12px; font-weight: 800; display: grid; place-items: center; border: 2px solid #fff; }
.cf-panel { width: 380px; max-width: calc(100vw - 24px); height: min(560px, calc(100vh - 44px)); background: #fff; border-radius: 20px; box-shadow: var(--shadow-lg); border: 1px solid var(--line); overflow: hidden; display: flex; flex-direction: column; }
.cf-panel[hidden], .cf-btn[hidden] { display: none; }
.chat-v-float { display: flex; flex-direction: column; }
.chat-v-float .chat-side, .chat-v-float .chat-main { flex: 1; min-height: 0; border: 0; }
.chat-v-float .chat-main { display: none; }
.chat-v-float.show-thread .chat-side { display: none; }
.chat-v-float.show-thread .chat-main { display: flex; }
.chat-v-float .chat-back { display: inline-grid; }
@keyframes cf-pulse { 0%, 100% { box-shadow: 0 10px 28px rgba(37, 99, 235, .45); } 50% { box-shadow: 0 10px 28px rgba(37, 99, 235, .45), 0 0 0 10px rgba(14, 165, 233, .2); } }
@media (prefers-reduced-motion: reduce) { .cf-btn.has-unread { animation: none; } }
@media (max-width: 560px) { .chat-float { right: 12px; bottom: 12px; } .cf-panel { width: calc(100vw - 24px); } }
.cf-count[hidden] { display: none; }
.chip-file[hidden], .chat-back[hidden] { display: none; }

/* Choix d'icône (abonnements calendrier) */
.icon-pick { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 4px; }
.icon-opt { cursor: pointer; }
.icon-opt input { position: absolute; opacity: 0; pointer-events: none; }
.icon-opt span { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; border: 2px solid var(--line, #e2e8f0); background: #fff; color: #475569; transition: all .12s; }
.icon-opt:hover span { border-color: #94a3b8; }
.icon-opt input:checked + span { border-color: var(--primary, #2563eb); background: color-mix(in srgb, var(--primary, #2563eb) 12%, #fff); color: var(--primary, #2563eb); }
.icon-opt input:focus-visible + span { outline: 2px solid var(--primary, #2563eb); outline-offset: 2px; }
.icon-opt .i { width: 20px; height: 20px; }

/* Courses : propositions en attente */
.pending-box { background: #fffbeb; border: 1px dashed #f59e0b; border-radius: 14px; padding: 10px 12px; margin-bottom: 14px; }
.pending-h { display: flex; align-items: center; gap: 8px; color: #b45309; margin-bottom: 4px; }
.pending-h .i { width: 18px; height: 18px; }
.pending-box .row { background: transparent; }

/* Repas : photo de recette */
.recipe-top.has-img { padding: 0; background: #f1f5f9; height: 130px; }
.recipe-top.has-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.recipe-photo { width: 100%; max-height: 280px; object-fit: cover; border-radius: 14px; margin-bottom: 14px; display: block; }

/* Mode assistance (administrateur dans l'espace d'un membre) */
.imp-bar { position: sticky; top: 0; z-index: 60; display: flex; align-items: center; gap: 12px; flex-wrap: wrap; padding: 10px 18px; background: repeating-linear-gradient(135deg, #f59e0b 0 14px, #fbbf24 14px 28px); color: #1f2937; font-size: 14px; box-shadow: 0 4px 14px rgba(0,0,0,.15); }
.imp-bar > .i { width: 22px; height: 22px; flex: none; }
.imp-bar > span { flex: 1; min-width: 200px; background: rgba(255,255,255,.85); padding: 4px 10px; border-radius: 8px; }
.imp-meta { display: block; font-size: 12px; color: #4b5563; }
.imp-bar form { margin: 0; }
.imp-bar .btn { background: #111827; color: #fff; border: 0; }

/* Pot de miel anti-robots : hors écran, invisible pour les humains et les lecteurs d'écran */
.hp { position: absolute !important; left: -10000px !important; top: auto; width: 1px; height: 1px; overflow: hidden; }

/* Aide & assistance */
.faq { border-top: 1px solid var(--line, #e2e8f0); }
.faq:first-of-type { border-top: 0; }
.faq[hidden] { display: none; }
.faq summary { list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 12px 2px; font-weight: 700; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary .i { transition: transform .15s; flex: none; color: #64748b; }
.faq[open] summary .i { transform: rotate(180deg); }
.faq p { margin: 0 0 12px; color: #475569; font-size: 14px; line-height: 1.55; }
.help-card .help-cta { display: flex; flex-direction: column; gap: 10px; }
.help-card .help-foot { margin-top: 14px; padding-top: 12px; border-top: 1px dashed var(--line, #e2e8f0); font-size: 13px; text-align: center; }
.help-log { margin-top: 12px; font-size: 12px; color: #64748b; }
.help-log li { margin: 4px 0; }
.contact-pub textarea { min-height: 140px; }

/* Administration › Assistance */
.sup-list { display: flex; flex-direction: column; gap: 12px; }
.sup-msg { border: 1px solid var(--line, #e2e8f0); border-left: 4px solid #0d9488; border-radius: 12px; padding: 12px 14px; background: #fff; }
.sup-msg.done { border-left-color: #cbd5e1; opacity: .8; }
.sup-msg header { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 8px; }
.sup-msg p { margin: 0 0 8px; font-size: 14px; line-height: 1.55; white-space: normal; }
.sup-msg footer { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.sup-msg footer form { margin: 0; }

/* Tâches répétées et points des enfants */
.task-recur { color: #7c3aed; display: inline-flex; }
.task-points { display: inline-flex; align-items: center; gap: 3px; font-size: 12px; font-weight: 800; color: #b45309; background: #fef3c7; border-radius: 99px; padding: 2px 8px; }
.task-points .i { color: #f59e0b; }
.kid-points { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; margin: 4px 0 10px; padding: 8px 12px; border-radius: 12px; background: #fffbeb; color: #92400e; font-size: 14px; }
.kid-points > .i { color: #f59e0b; fill: #fde68a; }
.kid-points strong { font-size: 18px; }
.kid-points small { flex-basis: 100%; color: #a16207; font-size: 12px; }

/* Notifications : cloche et panneau */
.bell { position: relative; }
.bell-n { position: absolute; top: -3px; right: -3px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 99px; background: #e11d48; color: #fff; font-size: 11px; font-weight: 800; display: grid; place-items: center; border: 2px solid var(--navy, #0b1d3a); line-height: 1; }
.bell-n[hidden] { display: none; }
.hero .bell-m { display: none; position: absolute; top: 12px; left: 58px; z-index: 3; background: rgba(0, 0, 0, .3); color: #fff !important; }
.hero .bell-m .bell-n { border-color: transparent; }
.notif-panel { position: fixed; z-index: 80; width: 380px; max-height: min(620px, calc(100vh - 40px)); display: flex; flex-direction: column; background: #fff; border-radius: 18px; box-shadow: 0 24px 60px rgba(11, 29, 58, .28); border: 1px solid var(--line, #e2e8f0); overflow: hidden; }
.notif-panel[hidden] { display: none; }
.np-head { display: flex; align-items: center; gap: 10px; padding: 14px 14px 10px 18px; border-bottom: 1px solid var(--line, #e2e8f0); }
.np-head strong { font-size: 16px; margin-right: auto; color: var(--heading); }
.np-link { background: none; border: 0; padding: 0; color: var(--primary, #2563eb); font-weight: 700; font-size: 12.5px; cursor: pointer; }
.np-list { overflow-y: auto; flex: 1; }
.np-item { display: flex; gap: 12px; padding: 12px 16px; text-decoration: none; color: inherit; border-bottom: 1px solid #f1f5f9; }
.np-item:hover { background: #f8fafc; }
.np-item.unread { background: #eff6ff; }
.np-item.unread .np-txt strong::after { content: ''; display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--primary, #2563eb); margin-left: 6px; vertical-align: middle; }
.np-ic { width: 36px; height: 36px; border-radius: 12px; flex: none; display: grid; place-items: center; color: var(--c); background: color-mix(in srgb, var(--c) 13%, #fff); }
.np-ic .i { width: 18px; height: 18px; }
.np-txt { display: flex; flex-direction: column; gap: 2px; min-width: 0; font-size: 13.5px; }
.np-txt strong { color: var(--heading); }
.np-txt span { color: #475569; }
.np-txt small { color: #94a3b8; font-size: 11.5px; }
.np-empty { padding: 36px 20px; text-align: center; color: #94a3b8; }
.np-empty .i { width: 34px; height: 34px; }
.np-device { padding: 12px 16px; background: #f8fafc; border-top: 1px solid var(--line, #e2e8f0); display: flex; flex-direction: column; gap: 8px; }
.np-push-row { display: flex; align-items: center; gap: 8px; font-size: 13px; color: #334155; }
.np-push-row span { flex: 1; }
.np-hint { margin: 0; font-size: 12.5px; color: #64748b; }
@media (max-width: 900px) {
  .hero .bell-m { display: grid; }
  .notif-panel { left: 8px !important; right: 8px; top: 8px !important; bottom: auto !important; width: auto; max-height: calc(100vh - 16px); }
}

/* Double authentification */
.twofa-choices { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 12px; }
.twofa-choices form { margin: 0; }
.twofa-choice { width: 100%; display: flex; flex-direction: column; align-items: flex-start; gap: 4px; text-align: left; padding: 14px 16px; border-radius: 14px; border: 1.5px solid var(--line, #e2e8f0); background: #fff; cursor: pointer; font: inherit; color: inherit; transition: border-color .15s, box-shadow .15s; }
.twofa-choice:hover { border-color: var(--primary, #2563eb); box-shadow: 0 6px 18px rgba(37, 99, 235, .12); }
.twofa-choice .i { width: 24px; height: 24px; color: var(--primary, #2563eb); }
.twofa-choice small { color: #64748b; }
.twofa-setup { display: flex; gap: 22px; flex-wrap: wrap; align-items: flex-start; }
.twofa-setup .qr { width: 190px; height: 190px; flex: none; background: #fff; border: 1px solid var(--line, #e2e8f0); border-radius: 14px; padding: 6px; }
.twofa-setup .qr svg { width: 100%; height: 100%; display: block; }
.twofa-setup > div:last-child { flex: 1; min-width: 240px; }
.twofa-setup code.secret { font-size: 13px; background: #f1f5f9; padding: 3px 6px; border-radius: 6px; word-break: break-all; }
.twofa-confirm { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.otp-input { max-width: 170px; font-size: 22px !important; letter-spacing: .3em; text-align: center; font-variant-numeric: tabular-nums; }
.auth-card .otp-input { max-width: none; }
.twofa-on { display: flex; gap: 12px; align-items: center; margin-bottom: 12px; }
.twofa-pw { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.twofa-pw input { max-width: 220px; }
.recovery-codes { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 8px; margin: 10px 0; }
.recovery-codes code { background: #f8fafc; border: 1px dashed #cbd5e1; border-radius: 8px; padding: 8px; text-align: center; font-size: 14px; letter-spacing: .05em; }
.help-toggle { display: flex; gap: 10px; align-items: flex-start; margin-top: 14px; cursor: pointer; }
.help-toggle strong { display: block; font-size: 13.5px; }
.help-toggle small { color: #64748b; font-size: 12px; line-height: 1.4; }
.help-toggle .switch { flex: none; margin-top: 2px; }

/* 0.13.0 — Annonces de l'administration (accueil des familles) */
.announce { position: relative; display: flex; gap: 14px; align-items: flex-start; margin: 0 0 16px; padding: 14px 16px; border-radius: var(--radius); border: 1px solid color-mix(in srgb, var(--ac) 35%, transparent); border-left: 5px solid var(--ac); background: color-mix(in srgb, var(--ac) 8%, var(--card)); box-shadow: var(--shadow); }
.announce .an-ic { flex: none; width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; background: var(--ac); color: #fff; }
.announce .an-ic .i { width: 20px; height: 20px; }
.announce .an-body { flex: 1; min-width: 0; }
.announce .an-tag { display: inline-block; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--ac); margin-right: 8px; }
.announce strong { font-size: 15px; }
.announce p { margin: 4px 0 0; line-height: 1.5; overflow-wrap: anywhere; }
.announce small { display: block; margin-top: 6px; color: var(--muted, #64748b); font-size: 12px; }
.announce .an-x { flex: none; margin: -4px -6px 0 0; }
.announce.an-high { background: color-mix(in srgb, var(--ac) 12%, var(--card)); }
.announce.an-high .an-ic { animation: an-pulse 2s ease-in-out infinite; }
@keyframes an-pulse { 50% { box-shadow: 0 0 0 6px color-mix(in srgb, var(--ac) 25%, transparent); } }
@media (prefers-reduced-motion: reduce) { .announce.an-high .an-ic { animation: none; } }

/* Choix du niveau (administration) */
.lvl-pick { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin: 0 0 14px; }
.lvl-pick label { cursor: pointer; }
.lvl-pick input { position: absolute; opacity: 0; pointer-events: none; }
.lvl-pick span { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; padding: 10px 12px; border: 2px solid var(--line); border-radius: 12px; transition: border-color .15s, background .15s; }
.lvl-pick span .i { color: var(--ac); width: 20px; height: 20px; }
.lvl-pick small { color: var(--muted, #64748b); font-size: 12px; }
.lvl-pick input:checked + span { border-color: var(--ac); background: color-mix(in srgb, var(--ac) 8%, transparent); }
.lvl-pick input:focus-visible + span { outline: 2px solid var(--ac); outline-offset: 2px; }
.lvl-dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; background: var(--ac); vertical-align: middle; }
@media (max-width: 560px) { .lvl-pick { grid-template-columns: 1fr; } .lvl-pick span { flex-direction: row; align-items: center; gap: 8px; } }

/* Maintenance : bandeau administrateur et page d'attente */
.maint-bar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 10px 16px; border-radius: 12px; background: #fff7ed; border: 1px solid #fdba74; color: #7c2d12; font-size: 14px; }
.main > .maint-bar { border-radius: 0; border-width: 0 0 1px; }
.maint-bar > .i { width: 20px; height: 20px; flex: none; color: #ea580c; }
.maint-bar > span { flex: 1; min-width: 200px; }
.maint-wrap { min-height: 100vh; display: grid; place-items: center; padding: 24px 16px; background: radial-gradient(circle at 20% 10%, #fff7ed, transparent 50%), radial-gradient(circle at 80% 90%, #eff6ff, transparent 50%), var(--bg, #f8fafc); }
.maint-card { max-width: 520px; width: 100%; text-align: center; background: var(--card); border: 1px solid var(--line); border-radius: 24px; box-shadow: var(--shadow); padding: 32px 24px; }
.maint-card .logo { justify-content: center; margin-bottom: 22px; }
.maint-ic { display: inline-grid; place-items: center; width: 72px; height: 72px; border-radius: 22px; background: #fff7ed; color: #ea580c; margin-bottom: 12px; }
.maint-ic .i { width: 36px; height: 36px; animation: maint-turn 3s ease-in-out infinite; }
@keyframes maint-turn { 0%, 60%, 100% { transform: rotate(0); } 75% { transform: rotate(-25deg); } 90% { transform: rotate(10deg); } }
@media (prefers-reduced-motion: reduce) { .maint-ic .i { animation: none; } }
.maint-card h1 { font-size: 26px; margin: 0 0 10px; }
.maint-card .lead { font-size: 16px; line-height: 1.6; margin: 0 0 14px; }
.maint-eta { display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px; border-radius: 999px; background: #eff6ff; color: #1d4ed8; font-weight: 600; margin: 0 0 14px; }
.maint-eta .i { width: 16px; height: 16px; }
.help-access { margin-top: 14px; padding: 12px; border-radius: 12px; background: var(--bg); }
.help-access > strong { display: flex; align-items: center; gap: 6px; font-size: 13.5px; margin-bottom: 4px; }
.help-access p { margin: 0; }
.help-grant { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; justify-content: space-between; font-size: 13px; padding: 6px 0; border-top: 1px solid var(--line); }
.help-grant:first-of-type { border-top: 0; }

/* ---------------- 0.14.0 — Page d'accueil publique ---------------- */
.lh-pill { display: inline-flex; align-items: center; gap: 8px; background: var(--primary-soft); color: var(--primary-d); padding: 6px 14px; border-radius: 999px; font-weight: 700; font-size: 14px; }
.lh-pill .i { color: var(--red); }
.checks span { display: inline-flex; align-items: center; gap: 6px; }
.checks .i { color: var(--primary-ink); }
@media (max-width: 1200px) {
}
@media (max-width: 700px) {
}
@media (prefers-reduced-motion: reduce) { .feature { transition: none; } .feature:hover { transform: none; } }
@media (max-width: 560px) {
  .pub-nav { gap: 10px; padding: 10px 16px; }
  .pub-nav .logo small { display: none; }
  .pub-cta { gap: 8px; }
  .pub-cta .btn { padding: 8px 12px; }
  .pub-cta .btn-primary { display: none; }
}
/* Administration : photos des membres des familles jamais chargées (confidentialité), en-tête mobile */
@media (max-width: 700px) {
  .admin-nav { flex-wrap: wrap; row-gap: 8px; }
  .admin-nav .pub-cta { width: 100%; margin-left: 0; justify-content: flex-start; flex-wrap: wrap; }
  .admin-nav .pub-cta .btn { display: inline-flex; padding: 7px 10px; font-size: 13px; }
  .admin-nav .pub-cta .btn-primary { display: inline-flex; }
}

/* ---------------- 0.14.0 — Mise en page adaptée à la largeur réelle du contenu (requêtes de conteneur) ---------------- */
.content { container-type: inline-size; container-name: content; padding-bottom: 84px; }
.g-auto { grid-template-columns: repeat(auto-fill, minmax(min(100%, 290px), 1fr)); align-items: start; }
@container content (max-width: 1120px) {
  .dash { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .g-side-l { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .g-side-l > :last-child { grid-column: span 2; }
}
@container content (max-width: 860px) {
  .dash { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .g-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .g-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .g-side { grid-template-columns: minmax(0, 1fr); }
}
@container content (max-width: 540px) {
  .dash { grid-template-columns: minmax(0, 1fr); }
  .dw[data-size="m"], .dw[data-size="l"] { grid-column: auto; }
  .g-4, .g-3, .g-2, .g-side-l { grid-template-columns: minmax(0, 1fr); }
  .g-side-l > :last-child { grid-column: auto; }
}
/* Bouton flottant de la messagerie : réduit à l'icône pendant le défilement */
.cf-btn { transition: transform .15s, padding .2s; }
.cf-btn .cf-label { transition: opacity .15s; }
.cf-btn.compact { padding: 0; width: 54px; }
.cf-btn.compact .cf-label { display: none; }
/* Champs d'envoi de fichier harmonisés */
input[type=file] { font-size: 13px; color: var(--muted); max-width: 100%; }
input[type=file]::file-selector-button { font: inherit; font-weight: 700; margin-right: 10px; padding: 7px 12px; border-radius: 10px; border: 1px solid var(--line); background: var(--primary-soft); color: var(--primary-d); cursor: pointer; transition: background .15s; }
input[type=file]::file-selector-button:hover { background: #dbe7fd; }

/* ---------------- 0.14.0 — Recherche globale (Ctrl+K) ---------------- */
.side-search { display: flex; align-items: center; gap: 10px; width: 100%; margin: 0 0 12px; padding: 9px 12px; border-radius: 12px; border: 1px solid rgba(255, 255, 255, .12); background: rgba(255, 255, 255, .06); color: rgba(255, 255, 255, .8); cursor: pointer; font-size: 14px; text-align: left; transition: background .15s, border-color .15s; }
.side-search:hover, .side-search:focus-visible { background: rgba(255, 255, 255, .11); border-color: rgba(255, 255, 255, .22); color: #fff; outline: none; }
.side-search span { flex: 1; }
.side-search kbd, .cmdk kbd { font: 700 11px/1 Nunito, system-ui, sans-serif; padding: 4px 6px; border-radius: 6px; background: rgba(255, 255, 255, .12); color: inherit; }
.hero .search-m { display: none; position: absolute; top: 12px; left: 104px; z-index: 3; background: rgba(0, 0, 0, .3); color: #fff !important; }
@media (max-width: 900px) { .hero .search-m { display: grid; } }
.cmdk { padding: 0; border: 0; background: transparent; width: min(640px, calc(100vw - 24px)); max-height: none; margin: 10vh auto auto; overflow: visible; }
.cmdk::backdrop { background: rgba(9, 20, 45, .5); backdrop-filter: blur(3px); }
.cmdk[open] .cmdk-box { animation: cmdk-in .16s ease-out; }
@keyframes cmdk-in { from { opacity: 0; transform: translateY(-8px) scale(.98); } }
@media (prefers-reduced-motion: reduce) { .cmdk[open] .cmdk-box { animation: none; } }
.cmdk-box { background: #fff; border-radius: 18px; box-shadow: var(--shadow-lg); border: 1px solid var(--line); overflow: hidden; display: flex; flex-direction: column; max-height: min(620px, 78vh); }
.cmdk-head { display: flex; align-items: center; gap: 10px; padding: 14px 16px; border-bottom: 1px solid var(--line); }
.cmdk-head > .i { width: 20px; height: 20px; color: var(--muted); }
.cmdk-head input { flex: 1; border: 0; outline: 0; font-size: 17px; background: transparent; min-width: 0; }
.cmdk-head input::-webkit-search-cancel-button { display: none; }
.cmdk-head kbd { background: var(--bg); color: var(--muted); }
.cmdk-list { overflow-y: auto; padding: 6px 8px 10px; flex: 1; overscroll-behavior: contain; }
.cmdk-gl { font-size: 11.5px; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); padding: 12px 10px 6px; }
.cmdk-item { display: flex; align-items: center; gap: 12px; padding: 8px 10px; border-radius: 12px; color: var(--text); scroll-margin: 8px; }
.cmdk-item.on { background: var(--primary-soft); }
.cmdk-ic { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 10px; flex: none; background: color-mix(in srgb, var(--c) 13%, #fff); color: var(--c); }
.cmdk-ic .i { width: 18px; height: 18px; }
.cmdk-tx { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.cmdk-tx strong { font-size: 14.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cmdk-tx small { font-size: 12.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cmdk-go { color: var(--muted); opacity: 0; }
.cmdk-item.on .cmdk-go { opacity: 1; color: var(--primary-ink); }
.cmdk-empty { padding: 26px 12px; text-align: center; color: var(--muted); }
.cmdk-foot { display: flex; gap: 16px; padding: 9px 16px; border-top: 1px solid var(--line); font-size: 12px; color: var(--muted); background: #fafcff; }
.cmdk-foot span:last-child { margin-left: auto; }
@media (max-width: 600px) { .cmdk { margin-top: 12px; } .cmdk-foot { display: none; } .cmdk-box { max-height: calc(100vh - 24px); } }
.cmdk-head input { border: 0 !important; box-shadow: none !important; padding: 4px 0 !important; height: auto !important; border-radius: 0 !important; }
/* Accessibilité : lien d'évitement et focus clavier visible */
.skip-link { position: absolute; left: 12px; top: -60px; z-index: 100; padding: 10px 16px; border-radius: 10px; background: var(--primary); color: var(--on-primary); font-weight: 700; transition: top .15s; }
.skip-link:focus { top: 12px; }
.content:focus { outline: none; }
a:focus-visible, button:focus-visible, .btn:focus-visible, .icon-btn:focus-visible, summary:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }
.sidebar a:focus-visible, .sidebar button:focus-visible { outline-color: #93c5fd; }
.nav a.nav-help { margin-top: 10px; border-top: 1px solid rgba(255,255,255,.08); border-radius: 0 0 12px 12px; padding-top: 14px; color: #b5ece4; }
.nav a.nav-help + a.nav-admin { margin-top: 0; border-top: 0; border-radius: 12px; padding-top: 10px; }

/* ---------------- 0.15.0 — Jauge de stockage (bas du menu) et page « Mon forfait » ---------------- */
.side-storage { display: block; margin: 0 0 10px; padding: 8px 10px 9px; border-radius: 10px; color: rgba(255, 255, 255, .74); text-decoration: none; font-size: 11.5px; line-height: 1.2; transition: background .15s, color .15s; }
.side-storage:hover, .side-storage:focus-visible { background: rgba(255, 255, 255, .06); color: #dbe6ff; }
.ss-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 6px; }
.ss-plan { display: inline-flex; align-items: center; gap: 5px; font-weight: 700; color: #ddd3fe; white-space: nowrap; }
.ss-plan .i { width: 12px; height: 12px; }
.ss-val { font-variant-numeric: tabular-nums; white-space: nowrap; }
.ss-bar { display: block; height: 4px; border-radius: 99px; background: rgba(255, 255, 255, .1); overflow: hidden; }
.ss-bar i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #60a5fa, #a78bfa); }
.side-storage.is-warn .ss-bar i { background: #f59e0b; }
.side-storage.is-warn .ss-val { color: #fcd34d; }
.side-storage.is-full .ss-bar i { background: #f43f5e; }
.side-storage.is-full .ss-val { color: #fda4af; font-weight: 700; }

.plan-card { background: linear-gradient(160deg, #faf7ff, #fff 55%); border-color: #e4dafb; }
.plan-head { display: flex; gap: 16px; align-items: center; margin-bottom: 16px; }
.plan-ic { display: grid; place-items: center; width: 56px; height: 56px; border-radius: 16px; flex: none; background: linear-gradient(135deg, #8b5cf6, #6366f1); color: #fff; box-shadow: 0 8px 20px rgba(124, 58, 237, .3); }
.plan-ic .i { width: 28px; height: 28px; }
.plan-kicker { font-size: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; color: #7c3aed; margin-bottom: 2px; }
.plan-head h2 { font-size: 24px; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.plan-feats { list-style: none; padding: 0; margin: 0 0 18px; display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 10px 18px; }
.plan-feats li { display: flex; gap: 10px; align-items: flex-start; font-size: 14.5px; }
.plan-feats .i { color: #7c3aed; flex: none; margin-top: 2px; }
.plan-cta { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; padding-top: 16px; border-top: 1px dashed #e4dafb; }
.plan-cta .btn[disabled] { opacity: .55; cursor: not-allowed; box-shadow: none; }
.st-sum { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; margin-bottom: 10px; }
.st-sum strong { font-size: 26px; letter-spacing: -.01em; }
.st-left { margin-left: auto; font-weight: 700; font-size: 13.5px; color: var(--green); }
.st-sum.is-warn .st-left { color: #d97706; }
.st-sum.is-full .st-left { color: var(--red); }
.st-bar { display: flex; gap: 2px; height: 12px; border-radius: 99px; background: var(--line-2); overflow: hidden; margin-bottom: 14px; }
.st-bar i { display: block; height: 100%; background: var(--c); }
.st-legend { display: grid; gap: 2px; }
.st-legend div { display: flex; justify-content: space-between; gap: 10px; font-size: 14px; padding: 4px 0; border-bottom: 1px solid var(--line-2); }
.st-legend div:last-child { border-bottom: 0; }
.st-legend span { display: inline-flex; align-items: center; gap: 8px; }
.st-legend span i { width: 10px; height: 10px; border-radius: 3px; background: var(--c); flex: none; }
.st-legend b { font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; }
.plan-soon { background: linear-gradient(160deg, #f5f3ff, #fff); }
.mini-bar { display: block; height: 5px; border-radius: 99px; background: var(--line-2); overflow: hidden; margin-top: 5px; min-width: 70px; }
.mini-bar i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #60a5fa, #a78bfa); }
.mini-bar.is-warn i { background: #f59e0b; }
.mini-bar.is-full i { background: #f43f5e; }
/* Menu : le pied (jauge, profil) reste toujours visible, la liste des modules défile si l'écran est bas */
.sidebar { overflow: hidden; }
.sidebar .nav { flex: 1 1 auto; min-height: 0; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; scrollbar-color: rgba(255,255,255,.18) transparent !important; margin-right: -8px; padding-right: 8px; }
.sidebar .side-foot { flex: none; margin-top: 0; padding-top: 12px; }
@media (max-height: 980px) { .sidebar .mascot { display: none; } }
@media (max-height: 900px) { .nav a { padding: 8px 14px; } .nav { gap: 2px; } .side-search { margin-bottom: 8px; } .sidebar .brand { margin-bottom: 14px; } }
@media (max-height: 720px) { .nav a { padding: 6px 12px; font-size: 14px; } .nav a .i { width: 20px; height: 20px; } }
@media (max-height: 900px) { .brand { padding-bottom: 12px; } .nav a { padding-top: 7px; padding-bottom: 7px; } }
/* Sections publiques à largeur limitée : la marge des grands écrans ne doit pas s'ajouter à la largeur maximale (bug de la FAQ sur écran large) */
.pub-narrow { max-width: 860px; margin: 30px auto; padding: 0 16px 30px; }
.plan-ic.plan-premium { background: linear-gradient(135deg, #f59e0b, #d946ef); box-shadow: 0 8px 20px rgba(217, 70, 239, .3); }
/* Administration : formule des familles */
.plan-pill { display: inline-flex; align-items: center; gap: 5px; border: 1px solid transparent; border-radius: 99px; padding: 3px 10px; font: 700 12px/1.3 Nunito, system-ui, sans-serif; cursor: pointer; background: #f1f5f9; color: #475569; transition: filter .15s; }
.plan-pill:hover { filter: brightness(.96); border-color: currentColor; }
.plan-pill.tone-violet { background: #f1eafe; color: #6d28d9; }
.plan-pill.tone-orange { background: linear-gradient(135deg, #fef3c7, #fde68a); color: #92400e; }
.plan-pick { display: grid; gap: 8px; margin-bottom: 12px; }
.plan-pick label { cursor: pointer; }
.plan-pick input { position: absolute; opacity: 0; pointer-events: none; }
.plan-pick span { display: flex; flex-direction: column; gap: 2px; padding: 10px 12px; border: 2px solid var(--line); border-radius: 12px; transition: border-color .15s, background .15s; }
.plan-pick strong { display: flex; align-items: center; gap: 8px; }
.plan-pick small { color: var(--muted); font-size: 12.5px; }
.plan-pick input:checked + span { border-color: var(--primary); background: var(--primary-soft); }
.plan-pick .tone-orange input:checked + span { border-color: #f59e0b; background: #fffbeb; }
.plan-pick input:focus-visible + span { outline: 2px solid var(--primary); outline-offset: 2px; }

/* ---------------- 0.16.0 — Galerie photos ---------------- */
.gal-toolbar .seg a { display: inline-flex; align-items: center; gap: 6px; }
.gal-toolbar .seg small { font-size: 11.5px; color: var(--muted); font-weight: 700; }
.gal-month { display: flex; align-items: baseline; gap: 8px; font-size: 16px; margin: 6px 2px 10px; }
.gal-month small { font-size: 12px; color: var(--muted); font-weight: 700; }
.gal-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 6px; margin-bottom: 22px; }
.gal-tile { position: relative; display: block; padding: 0; border: 0; border-radius: 10px; overflow: hidden; aspect-ratio: 1; background: #e9eef6; cursor: zoom-in; }
.gal-tile img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .25s ease; }
.gal-tile:hover img { transform: scale(1.04); }
.gal-tile:focus-visible { outline: 3px solid var(--primary); outline-offset: 2px; }
.gal-fav { position: absolute; right: 6px; bottom: 6px; display: grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; background: rgba(0, 0, 0, .35); color: #fff; }
.gal-fav .i { width: 13px; height: 13px; fill: #fb7185; stroke: #fb7185; }
.gal-pager { display: flex; justify-content: center; gap: 10px; margin: 6px 0 10px; }
.gal-album-head { flex-direction: row; align-items: center; gap: 12px; margin-bottom: 16px; flex-wrap: wrap; }
.gal-album-head h2 { font-size: 20px; }
.gal-albums { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 16px; }
.gal-album { display: flex; flex-direction: column; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; color: var(--text); box-shadow: var(--shadow); transition: transform .18s, box-shadow .18s; }
.gal-album:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); }
.gal-cover { aspect-ratio: 4 / 3; display: grid; place-items: center; background: linear-gradient(135deg, #fce7f3, #ede9fe); color: #db2777; overflow: hidden; }
.gal-cover img { width: 100%; height: 100%; object-fit: cover; }
.gal-cover > .i { width: 40px; height: 40px; opacity: .6; }
.gal-album-b { padding: 12px 14px; display: flex; flex-direction: column; gap: 2px; }
.gal-album-b strong { font-size: 15.5px; }
.gal-album-b small { color: var(--muted); font-size: 12.5px; }
.content.gal-dragging { outline: 3px dashed #db2777; outline-offset: -10px; border-radius: 18px; background: #fdf2f8; }
.gal-progress { margin-top: 6px; }
.gp-bar { display: block; height: 8px; border-radius: 99px; background: var(--line-2); overflow: hidden; margin-bottom: 8px; }
.gp-bar i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, #ec4899, #8b5cf6); transition: width .2s; }
.gal-errors { color: var(--red); margin: 8px 0 0; padding-left: 18px; max-height: 140px; overflow: auto; }
/* Visionneuse */
.gal-viewer { width: 100vw; height: 100dvh; max-width: none; max-height: none; margin: 0; padding: 0; border: 0; background: rgba(6, 10, 22, .96); color: #fff; overflow: hidden; }
.gal-viewer[open] { display: grid; grid-template-columns: 64px 1fr 64px; grid-template-rows: auto 1fr; }
.gal-viewer::backdrop { background: rgba(6, 10, 22, .9); }
.gv-top { grid-column: 1 / -1; display: flex; align-items: center; gap: 4px; padding: 10px 12px; }
.gv-count { font-size: 13px; color: #cbd5e1; font-variant-numeric: tabular-nums; padding-left: 6px; }
.gv-btn { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 12px; border: 0; background: transparent; color: #e2e8f0; cursor: pointer; }
.gv-btn:hover, .gv-btn:focus-visible { background: rgba(255, 255, 255, .12); color: #fff; }
.gv-btn .i { width: 21px; height: 21px; }
.gv-btn.on .i { fill: #fb7185; stroke: #fb7185; }
.gv-nav { align-self: center; justify-self: center; display: grid; place-items: center; width: 48px; height: 48px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .1); color: #fff; cursor: pointer; }
.gv-nav:hover { background: rgba(255, 255, 255, .2); }
.gv-nav .i { width: 26px; height: 26px; }
.gv-stage { margin: 0; min-height: 0; min-width: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; padding: 0 0 18px; }
.gv-stage img { max-width: 100%; max-height: calc(100dvh - 150px); object-fit: contain; border-radius: 6px; box-shadow: 0 20px 60px rgba(0, 0, 0, .5); transition: opacity .2s; }
.gv-stage img.loading { opacity: .35; }
.gv-stage figcaption { text-align: center; max-width: 720px; display: flex; flex-direction: column; gap: 3px; padding: 0 12px; }
.gv-stage figcaption strong { font-size: 16px; }
.gv-stage figcaption span { font-size: 13px; color: #94a3b8; }
@media (max-width: 700px) {
  .gal-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 3px; }
  .gal-tile { border-radius: 4px; }
  .gal-albums { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .gal-viewer[open] { grid-template-columns: 1fr; }
  .gv-nav { display: none; }
  .gal-toolbar { gap: 8px; }
  .gal-toolbar .seg { width: 100%; justify-content: space-between; }
  .gal-toolbar .seg a { padding: 7px 10px; }
  .hide-sm { display: none; }
}
@media (prefers-reduced-motion: reduce) { .gal-tile img, .gal-album { transition: none; } .gal-tile:hover img { transform: none; } }
.dash-photos { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 6px; } .dash-photos .gal-tile { cursor: pointer; }
.gv-top .grow, .gal-toolbar .grow, .gal-album-head .grow { flex: 1; min-width: 0; }
@media (max-width: 700px) { .gal-toolbar .grow { display: none; } .gal-toolbar > .btn { flex: 1; justify-content: center; } }
.plan-pick .badge { font-size: 11px; padding: 2px 8px; }

/* ---------------- 0.17.0 — Page Sécurité ---------------- */
.sec-page { max-width: 1040px; margin: 0 auto; padding: 34px 16px 50px; }
.sec-hero { text-align: center; max-width: 760px; margin: 0 auto 24px; }
.sec-hero h1 { font-size: clamp(30px, 4vw, 44px); font-weight: 800; color: var(--heading); letter-spacing: -.02em; margin: 14px 0 10px; }
.sec-hero p { font-size: 17px; color: #33496b; line-height: 1.55; }
.sec-toc { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-bottom: 26px; }
.sec-toc a { display: inline-flex; align-items: center; gap: 6px; padding: 7px 13px; border-radius: 99px; background: #fff; border: 1px solid var(--line); color: var(--text); font-weight: 700; font-size: 13.5px; }
.sec-toc a .i { color: var(--mc); }
.sec-toc a:hover { border-color: var(--mc); }
.sec-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.sec-card { background: #fff; border: 1px solid var(--line); border-radius: 20px; padding: 22px; box-shadow: var(--shadow); scroll-margin-top: 90px; }
.sec-card h2 { display: flex; align-items: center; gap: 12px; font-size: 19px; color: var(--heading); margin-bottom: 14px; }
.sec-ic { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 12px; background: color-mix(in srgb, var(--mc) 13%, #fff); color: var(--mc); flex: none; }
.sec-card ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.sec-card li { display: flex; gap: 10px; font-size: 14.5px; line-height: 1.55; color: #33496b; }
.sec-card li .i { color: var(--mc); flex: none; margin-top: 4px; }
.sec-contact { margin-top: 22px; text-align: center; background: linear-gradient(135deg, #0b1d3a, #12305e); color: #e2e8f0; border-radius: 22px; padding: 30px 20px; }
.sec-contact h2 { color: #fff; display: inline-flex; align-items: center; gap: 10px; font-size: 21px; margin-bottom: 8px; }
.sec-contact p { max-width: 620px; margin: 0 auto 14px; line-height: 1.55; }
.sec-contact a:not(.btn) { color: #93c5fd; }
@media (max-width: 760px) { .sec-list { grid-template-columns: 1fr; } }
.sec-list > .sec-card:last-child:nth-child(odd) { grid-column: 1 / -1; } .sec-list > .sec-card:last-child:nth-child(odd) ul { columns: 2; column-gap: 28px; display: block; } .sec-list > .sec-card:last-child:nth-child(odd) li { break-inside: avoid; margin-bottom: 10px; } @media (max-width: 760px) { .sec-list > .sec-card:last-child:nth-child(odd) ul { columns: 1; } }

/* ---------------- 0.17.0 — Accueil : comment ça marche, pour qui, installation ---------------- */
.qr-box { width: 176px; height: 176px; background: #fff; border-radius: 18px; padding: 10px; box-shadow: var(--shadow-lg); margin: 0 auto 10px; }
.qr-box svg { width: 100%; height: 100%; display: block; }
@media (max-width: 1000px) { .who-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 760px) {
}
/* Témoignages : saisie */
.stars { color: #f59e0b; letter-spacing: 1px; font-size: 16px; }
.stars span { color: #e2e8f0; }
.avis-mine p { margin: 6px 0 8px; font-size: 14px; line-height: 1.5; color: #33496b; font-style: italic; }
.star-pick { display: inline-flex; flex-direction: row-reverse; gap: 2px; }
.star-pick input { position: absolute; opacity: 0; pointer-events: none; }
.star-pick label { font-size: 30px; line-height: 1; color: #d6dde8; cursor: pointer; transition: color .1s, transform .1s; }
.star-pick label:hover, .star-pick label:hover ~ label, .star-pick input:checked ~ label { color: #f59e0b; }
.star-pick input:focus-visible + label { outline: 2px solid var(--primary); outline-offset: 2px; border-radius: 4px; }
.avis-set { display: flex; align-items: center; gap: 6px; }
.avis-set input { padding: 6px 8px; }
.avis-admin { display: grid; gap: 10px; }
.avis-admin article { display: flex; gap: 12px; align-items: flex-start; border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px; background: #fff; }
.avis-admin article.on { border-color: #86efac; background: #f0fdf4; }
.avis-admin form { margin: 0; }
.avis-check { border: 0; background: none; cursor: pointer; color: #94a3b8; padding: 2px; }
.avis-check .i { width: 24px; height: 24px; }
.avis-admin article.on .avis-check { color: var(--green); }
.avis-b { flex: 1; min-width: 0; }
.avis-b p { margin: 6px 0; font-size: 14px; line-height: 1.55; color: #33496b; }
/* Témoignages : accueil */
.mod-quota { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 10px 12px; margin: 4px 0 10px; border-radius: 12px; background: #f5f3ff; color: #5b21b6; font-size: 13.5px; }
.mod-quota > span { flex: 1; min-width: 200px; }
.mod-quota strong { display: block; color: #9a3412; }
.mod-quota.over { background: #fff7ed; color: #9a3412; }
.mod-row.locked .ic-bubble { filter: grayscale(1); opacity: .6; }
.upgrade { width: 100%; background: linear-gradient(135deg, #f5f3ff, #fdf4ff); border: 1px solid #e4dafb; border-radius: 16px; padding: 16px 18px; }
.upgrade-h { display: flex; align-items: center; gap: 8px; font-size: 16px; color: #5b21b6; margin-bottom: 8px; }
.upgrade-h .i { color: #d946ef; }
.upgrade ul { list-style: none; margin: 0 0 12px; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 6px 14px; font-size: 14px; }
.upgrade li { display: flex; gap: 6px; align-items: center; }
.upgrade li .i { color: var(--green); }
.upgrade-btns { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 10px; }
.upgrade-btns .save { display: inline-block; margin-left: 6px; padding: 1px 7px; border-radius: 99px; background: #dcfce7; color: #15803d; font-size: 12px; font-weight: 800; }
.stripe-steps { margin: -4px 0 12px; padding-left: 18px; line-height: 1.6; color: #475569; }
/* Formules : accueil */
.price { display: flex; align-items: baseline; gap: 8px; margin: 10px 0 2px; }
.price strong { font-size: 36px; font-weight: 800; color: var(--heading); letter-spacing: -.02em; }
.price span { color: var(--muted); }
.price-alt .save, .save { display: inline-block; padding: 1px 7px; border-radius: 99px; background: #dcfce7; color: #15803d; font-size: 12px; font-weight: 800; }
@media (max-width: 760px) { .price-grid { grid-template-columns: 1fr; } }
.ic-bubble.sub-img { padding: 0; overflow: hidden; background: #fff; border: 2px solid var(--c); }
.ic-bubble.sub-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ev-img { width: 100%; height: 100%; object-fit: cover; border-radius: inherit; display: block; }
.sub-img-field input[type=file] { margin: 4px 0; }
/* Captures de l'application (accueil) */
@keyframes shot-in { from { opacity: 0; transform: translateY(6px); } }
@media (prefers-reduced-motion: reduce) { .shot:not([hidden]) img { animation: none; } }
.phone { width: min(260px, 100%); margin: 0 auto; padding: 10px; border-radius: 38px; background: #0b1d3a; box-shadow: 0 30px 60px rgba(15, 35, 66, .35); }
.phone img { display: block; width: 100%; height: auto; border-radius: 28px; }
@media (max-width: 700px) { .shot-tab span { display: none; } .shot-tab { padding: 10px 12px; } .browser-bar span { display: none; } }
/* Réponses de l'assistance */
.sup-reply { margin: 0 0 8px 14px; padding: 10px 12px; border-left: 3px solid #93c5fd; background: #f5f9ff; border-radius: 0 10px 10px 0; }
.sup-reply-h { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; font-size: 13px; margin-bottom: 4px; }
.sup-reply p { margin: 0; font-size: 14px; line-height: 1.55; }
.sup-answer { margin: 4px 0 10px; }
.sup-answer > summary { list-style: none; display: inline-flex; cursor: pointer; }
.sup-answer > summary::-webkit-details-marker { display: none; }
.sup-answer[open] > summary { margin-bottom: 8px; }
.sup-answer textarea { width: 100%; font-size: 14.5px; line-height: 1.5; }
.sup-answer-f { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 8px; }
.sup-sched-f { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 8px; }
.sup-sched-f input[type=datetime-local] { width: auto; padding: 6px 10px; }
.sup-reply.sup-sched { border-left-color: #fdba74; background: #fffaf3; }
.sup-reply.sup-sched.is-failed { border-left-color: #fca5a5; background: #fff5f5; }
.sup-sched-act { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 8px; }
.sup-sched-act form { margin: 0; }
.sup-answer-f .btn { margin-left: auto; }
.my-tickets article { border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px; margin-bottom: 10px; }
.my-tickets header { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 6px; }
.my-tickets > article > p { margin: 0 0 8px; font-size: 14px; color: #33496b; line-height: 1.5; }

/* Pharmacie : base officielle, scan, fiche */
.link-btn { background: none; border: 0; padding: 0; font: inherit; color: inherit; cursor: pointer; text-align: left; display: inline-flex; align-items: center; gap: 4px; }
.link-btn:hover strong, .link-btn:hover { color: var(--primary-ink); }
.ph-thumb { width: 38px; height: 38px; border-radius: 12px; overflow: hidden; padding: 0; border: 1px solid var(--line); background: #fff; cursor: zoom-in; flex: none; }
.ph-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.drug-assist { margin-bottom: 6px; }
.drug-field { position: relative; }
.drug-sugg { position: absolute; z-index: 20; left: 0; right: 0; top: 100%; margin: 4px 0 0; padding: 4px; list-style: none; background: #fff; border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 12px 30px rgba(15, 35, 70, .16); max-height: 280px; overflow: auto; }
.drug-sugg li { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 9px; cursor: pointer; }
.drug-sugg li:hover, .drug-sugg li.on { background: var(--line-2); }
.drug-sugg .ds-ic { width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; background: color-mix(in srgb, var(--primary) 10%, #fff); color: var(--primary-ink); flex: none; }
.drug-sugg .ds-ic .i { width: 17px; height: 17px; }
.drug-sugg .ds-t { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.drug-sugg .ds-t strong { font-size: 14px; }
.drug-sugg .ds-t small { color: var(--muted); font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.drug-sugg .badge { font-size: 11px; flex: none; }
.drug-chip { display: flex; align-items: center; gap: 10px; padding: 8px 8px 8px 10px; border-radius: 12px; background: color-mix(in srgb, #16a34a 8%, #fff); border: 1px solid color-mix(in srgb, #16a34a 25%, #fff); margin: -2px 0 12px; }
.drug-chip.warn { background: color-mix(in srgb, #f97316 9%, #fff); border-color: color-mix(in srgb, #f97316 30%, #fff); }
.drug-chip .dc-ic { color: #16a34a; display: grid; place-items: center; }
.drug-chip.warn .dc-ic { color: #ea580c; }
.drug-chip .dc-t { display: flex; flex-direction: column; flex: 1; min-width: 0; line-height: 1.3; }
.drug-chip .dc-t small { color: var(--muted); font-size: 12px; }
.drug-chip .icon-btn { width: 30px; height: 30px; }
#m-drug .modal-body { max-height: min(70vh, 640px); overflow: auto; }
.di-name { margin: 0 0 12px; color: var(--muted); font-size: 13px; }
.di-alert { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; border-radius: 12px; margin-bottom: 12px; font-size: 14px; }
.di-alert .i { flex: none; margin-top: 2px; }
.di-dl { display: grid; grid-template-columns: max-content 1fr; gap: 6px 16px; margin: 0 0 14px; font-size: 14px; }
.di-dl dt { color: var(--muted); }
.di-dl dd { margin: 0; }
#m-drug h4 { margin: 14px 0 8px; font-size: 14px; }
.di-packs, .di-eq { list-style: none; margin: 0; padding: 0; }
.di-packs li { display: flex; justify-content: space-between; gap: 12px; padding: 8px 10px; border: 1px solid var(--line-2); border-radius: 10px; margin-bottom: 6px; font-size: 14px; }
.di-packs li.on { border-color: var(--primary); background: color-mix(in srgb, var(--primary) 5%, #fff); }
.di-pr { display: flex; flex-direction: column; align-items: flex-end; text-align: right; white-space: nowrap; }
.di-eq li { padding: 4px 0; font-size: 14px; }
.di-eq .link-btn { color: var(--primary-ink); }
.di-note { margin-top: 14px; }
@media (max-width: 520px) { .di-dl { grid-template-columns: 1fr; } .di-dl dd { margin-bottom: 6px; } }
.scan-view { position: relative; border-radius: 14px; overflow: hidden; background: #0b1424; aspect-ratio: 4 / 3; }
.scan-view video { width: 100%; height: 100%; object-fit: cover; display: block; }
.scan-frame { position: absolute; inset: 0; margin: auto; width: 58%; aspect-ratio: 1; border: 3px solid rgba(255, 255, 255, .9); border-radius: 18px; box-shadow: 0 0 0 999px rgba(5, 12, 25, .35); pointer-events: none; }
.scan-msg { position: absolute; left: 10px; right: 10px; bottom: 10px; margin: 0; padding: 7px 10px; border-radius: 10px; background: rgba(5, 12, 25, .7); color: #fff; font-size: 13px; text-align: center; }
.scan-msg.err { background: rgba(185, 28, 28, .88); }
.modal form.scan-manual { display: flex; flex-direction: row; gap: 8px; align-items: stretch; }
.scan-manual .btn { flex: none; }
.scan-manual input { flex: 1; min-width: 0; }
.photo-view { position: fixed; inset: 0; z-index: 200; background: rgba(5, 12, 25, .85); display: grid; place-items: center; padding: 20px; }
.photo-view img { max-width: 100%; max-height: 90vh; border-radius: 12px; }
.photo-view .icon-btn { position: absolute; top: 14px; right: 14px; background: #fff; }
#m-drug .modal-foot { flex-wrap: wrap; }
@media (max-width: 520px) { #m-drug .modal-foot small { flex-basis: 100%; order: 2; } #m-drug .modal-foot .btn { width: 100%; justify-content: center; } }

/* Application installée (iPhone/Android plein écran) : rien sous la barre d'état ni sous la barre d'accueil. */
:root { --sat: env(safe-area-inset-top, 0px); --sab: env(safe-area-inset-bottom, 0px); --sal: env(safe-area-inset-left, 0px); --sar: env(safe-area-inset-right, 0px); }
.sidebar { padding-top: calc(22px + var(--sat)); padding-bottom: calc(16px + var(--sab)); padding-left: calc(14px + var(--sal)); }
.hero .burger, .hero .bell-m, .hero .search-m { top: calc(12px + var(--sat)); }
.hero .burger { left: calc(12px + var(--sal)); }
.hero .bell-m { left: calc(58px + var(--sal)); }
.hero .search-m { left: calc(104px + var(--sal)); }
.chat-float { bottom: calc(22px + var(--sab)); right: calc(22px + var(--sar)); }
.toasts { bottom: calc(20px + var(--sab)); }
.pub-nav { padding-top: calc(14px + var(--sat)); }
.imp-bar { padding-top: calc(10px + var(--sat)); }
.maint-bar:first-child { margin-top: var(--sat); }
.imp-bar ~ .hero .burger, .imp-bar ~ .hero .bell-m, .imp-bar ~ .hero .search-m, .maint-bar ~ .hero .burger, .maint-bar ~ .hero .bell-m, .maint-bar ~ .hero .search-m { top: 12px; }
.foot { padding-bottom: calc(18px + var(--sab)); }
.photo-view { padding-top: calc(20px + var(--sat)); }
.photo-view .icon-btn { top: calc(14px + var(--sat)); }
@media (max-width: 900px) {
  .hero { padding-top: calc(54px + var(--sat)); padding-left: calc(18px + var(--sal)); padding-right: calc(18px + var(--sar)); }
  .imp-bar ~ .hero, .maint-bar ~ .hero { padding-top: 54px; }
  .notif-panel { top: calc(8px + var(--sat)) !important; max-height: calc(100vh - 16px - var(--sat) - var(--sab)); }
}
@media (max-width: 560px) { .chat-float { right: calc(12px + var(--sar)); bottom: calc(12px + var(--sab)); } .pub-nav { padding-top: calc(10px + var(--sat)); } }
@media (max-width: 600px) { .cmdk { margin-top: calc(12px + var(--sat)); } }
.modal { max-height: calc(100vh - 32px - var(--sat) - var(--sab)); }
/* Pharmacie : sorties d'inventaire */
.ph-empty { color: #be123c; font-weight: 700; }
.ph-mv { width: 32px; height: 32px; }
.ph-mv .i { width: 17px; height: 17px; }
.ph-mv.out { --c: #e11d48; }
.ph-mv.in { --c: #16a34a; }
.ph-moves .row-sub .i { width: 13px; height: 13px; vertical-align: -2px; }
.ph-take:hover { color: #e11d48; }
.btn-out { color: #fff; background: #e11d48; box-shadow: 0 6px 16px rgba(225, 29, 72, .22); }
.btn-out:hover { background: #be123c; }
.btn-add { color: #fff; background: #16a34a; box-shadow: 0 6px 16px rgba(22, 163, 74, .22); }
.btn-add:hover { background: #15803d; }
.scan-out .scan-frame { border-color: #fb7185; }
.scan-hint-out, .scan-out .scan-hint-in { display: none; } .scan-out .scan-hint-out { display: block; }

/* Messagerie : plein écran sur téléphone, avec barre de retour vers le site */
.chat-mtop { display: none; }
@media (max-width: 860px) {
  body.chat-page .hero, body.chat-page .chat-tools, body.chat-page .foot, body.chat-page .alert { display: none; }
  body.chat-page .content { padding: 0; }
  body.chat-page .chat-mtop { display: flex; align-items: center; gap: 8px; padding: calc(8px + var(--sat)) calc(10px + var(--sar)) 8px calc(10px + var(--sal)); background: var(--card); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 5; }
  body.chat-page .chat-mtop strong { flex: 1; display: flex; align-items: center; gap: 8px; font-size: 17px; }
  body.chat-page .chat-mtop strong .i { color: var(--primary-ink); }
  body.chat-page .chat-card { border: 0; border-radius: 0; box-shadow: none; margin: 0; }
  body.chat-page .chat-app { height: calc(100vh - 57px - var(--sat)); height: calc(100dvh - 57px - var(--sat)); }
  body.chat-page .composer { padding-bottom: calc(10px + var(--sab)); }
}
.cf-btn { touch-action: none; user-select: none; -webkit-user-select: none; }
.cf-btn.dragging { cursor: grabbing; transform: scale(1.08); opacity: .92; transition: none; }
.login-opts { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin: -4px 0 16px; }
.login-opts .f-check { display: flex; margin: 0; }

/* Pharmacie 0.20 : actions, boîte entamée, choix scan/manuel, historique, contrôle */
.ph-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin: -4px 0 14px; }
.ph-actions .grow { flex: 1; }
.dropdown { position: relative; }
.dropdown > summary { list-style: none; cursor: pointer; }
.dropdown > summary::-webkit-details-marker { display: none; }
.dd-menu { position: absolute; right: 0; top: calc(100% + 6px); z-index: 30; min-width: 200px; background: var(--card); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow-lg); padding: 6px; display: flex; flex-direction: column; }
.dd-menu a { display: flex; align-items: center; gap: 8px; padding: 9px 10px; border-radius: 8px; color: var(--text); font-size: 14px; font-weight: 600; }
.dd-menu a:hover { background: var(--line-2); }
.ph-due { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; padding: 10px 14px; margin-bottom: 14px; border-radius: 12px; background: color-mix(in srgb, #0f9f8f 9%, var(--card)); border: 1px solid color-mix(in srgb, #0f9f8f 30%, transparent); font-size: 14px; }
.ph-due > .i { color: #0f9f8f; flex: none; }
.ph-due > span { flex: 1; min-width: 220px; }
.ph-opened { color: #b45309; font-weight: 600; }
.ph-opened .i { width: 13px; height: 13px; vertical-align: -2px; }
.input-unit { display: flex; align-items: center; gap: 10px; }
.input-unit input { max-width: 120px; }
.input-unit em { font-style: normal; color: var(--muted); font-size: 14px; }
.ph-del { margin-top: 6px; padding-top: 10px; border-top: 1px dashed var(--line); }
.ph-del .btn { color: #be123c; }
.ph-tiles { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.ph-tiles.one { grid-template-columns: 1fr; }
.ph-tile { display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; padding: 20px 14px; border-radius: 16px; border: 2px solid var(--line); background: var(--card); color: var(--text); cursor: pointer; font: inherit; transition: border-color .15s, transform .15s; }
.ph-tile:hover { border-color: #16a34a; transform: translateY(-2px); }
.ph-tile > .i { width: 34px; height: 34px; color: #16a34a; }
.ph-tile.out:hover { border-color: #e11d48; }
.ph-tile.out > .i { color: #e11d48; }
.ph-tile small { color: var(--muted); font-size: 12.5px; }
.ph-tiles.one .ph-tile { flex-direction: row; text-align: left; padding: 14px 16px; }
.ph-tiles.one .ph-tile strong { flex: none; }
.ph-tiles.one .ph-tile small { flex: 1; }
.ph-or { display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: 13px; margin: 14px 0 10px; }
.ph-or::before, .ph-or::after { content: ''; flex: 1; height: 1px; background: var(--line); }
.ph-out-list { max-height: min(46vh, 380px); overflow: auto; margin-top: 8px; }
.ph-out-list .row { gap: 10px; }
.ph-mv-l { display: inline-flex; align-items: center; gap: 5px; font-weight: 700; font-size: 13px; }
.ph-mv-l.out { color: #be123c; }
.ph-mv-l.in { color: #15803d; }
.ph-mv-l.adj { color: #0f766e; }
.ph-mv-l .i { width: 14px; height: 14px; }
.pager { display: flex; align-items: center; justify-content: center; gap: 12px; margin-top: 14px; }
.ctl-bar { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.ctl-progress { flex: 1; min-width: 200px; }
.ctl-num strong { font-size: 26px; font-weight: 800; color: #16a34a; }
.ctl-num small { color: var(--muted); margin-left: 4px; }
.ctl-meter { height: 8px; border-radius: 99px; background: var(--line-2); overflow: hidden; margin-top: 6px; }
.ctl-meter i { display: block; height: 100%; background: linear-gradient(90deg, #22c55e, #16a34a); border-radius: inherit; transition: width .3s; }
.ctl-list { display: flex; flex-direction: column; gap: 6px; }
.ctl-row { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 12px; background: var(--card); transition: background .2s, border-color .2s; }
.ctl-row.ok { border-color: color-mix(in srgb, #16a34a 45%, transparent); background: color-mix(in srgb, #16a34a 7%, var(--card)); }
.ctl-row.part, .ctl-row.over { border-color: color-mix(in srgb, #f59e0b 50%, transparent); background: color-mix(in srgb, #f59e0b 7%, var(--card)); }
.ctl-chk { width: 34px; height: 34px; border: 0; background: none; padding: 0; display: grid; place-items: center; cursor: pointer; color: #94a3b8; flex: none; }
.ctl-chk .i { width: 26px; height: 26px; }
.ctl-row.ok .ctl-chk { color: #16a34a; }
.ctl-row.part .ctl-chk, .ctl-row.over .ctl-chk { color: #d97706; }
.ctl-row.extra .ctl-chk { color: #2563eb; cursor: default; }
.ctl-ic { color: var(--muted); display: grid; place-items: center; }
.ctl-main { flex: 1; min-width: 0; display: flex; flex-direction: column; cursor: pointer; }
.ctl-main small { color: var(--muted); font-size: 12.5px; }
.ctl-count { display: flex; align-items: center; gap: 4px; white-space: nowrap; font-size: 14px; }
.ctl-count .icon-btn { width: 32px; height: 32px; }
.ctl-extra h4, .ph-control h4 { margin: 18px 0 8px; font-size: 14px; display: flex; align-items: center; gap: 6px; }
.ctl-foot { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--line-2); }
.ctl-foot .grow { flex: 1; }
.ctl-sum { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 6px; }
.ctl-sum span { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 99px; font-weight: 700; font-size: 14px; }
.ctl-sum .ok { background: var(--green-soft); color: #15803d; }
.ctl-sum .warn { background: var(--orange-soft); color: #c2410c; }
.ctl-sum .info { background: var(--primary-soft); color: var(--primary-d); }
.ctl-fix { display: flex; flex-direction: column; gap: 6px; }
.ctl-fix-row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; padding: 10px 12px; border: 1px solid var(--line); border-radius: 12px; }
.ctl-fix-row .ctl-main { cursor: default; min-width: 180px; }
.ctl-fix-row select { width: auto; min-width: 210px; }
.scan-control .scan-frame { border-color: #4ade80; }
.scan-control .scan-hint-in { display: none; }

/* Thème : bouton de bascule et choix dans « Mon profil » */
.theme-btn .i { display: none; }
html[data-theme="auto"] .theme-btn .th-auto, html[data-theme="light"] .theme-btn .th-light, html[data-theme="dark"] .theme-btn .th-dark { display: block; }
.pub-theme { color: var(--text); }
.theme-pick { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.theme-opt { display: flex; flex-direction: column; gap: 8px; align-items: center; padding: 10px; border: 2px solid var(--line); border-radius: 14px; cursor: pointer; font-weight: 700; font-size: 14px; }
.theme-opt input { position: absolute; opacity: 0; pointer-events: none; }
.theme-opt:has(input:checked) { border-color: var(--primary); background: var(--primary-soft); }
.theme-opt:has(input:focus-visible) { outline: 2px solid var(--primary); outline-offset: 2px; }
.theme-prev { width: 100%; height: 54px; border-radius: 10px; display: grid; grid-template-columns: 26% 1fr; grid-template-rows: 1fr 1fr; gap: 4px; padding: 5px; background: #eef2f8; border: 1px solid #dbe3ef; }
.theme-prev i { border-radius: 5px; background: #fff; }
.theme-prev i:first-child { grid-row: 1 / 3; background: #0b1d3a; }
.th-dark .theme-prev { background: #0b1424; border-color: #26364f; }
.th-dark .theme-prev i { background: #1b2a40; }
.th-auto .theme-prev { background: linear-gradient(135deg, #eef2f8 50%, #0b1424 50%); }
.th-auto .theme-prev i:not(:first-child) { background: linear-gradient(135deg, #fff 50%, #1b2a40 50%); }
.me { gap: 4px; padding: 10px 8px; }
.me .icon-btn { width: 32px; height: 32px; flex: none; }
.me .icon-btn .i { width: 18px; height: 18px; }
.me-link { margin-right: 4px; }
.side-tools { display: flex; align-items: stretch; gap: 6px; }
.side-tools .side-search { flex: 1; min-width: 0; margin: 0; }
.side-theme { flex: none; width: 42px; height: auto; border-radius: 12px; background: rgba(255, 255, 255, .06); border: 1px solid rgba(255, 255, 255, .1); color: rgba(255, 255, 255, .82); }
.side-theme:hover { background: rgba(255, 255, 255, .12); color: #fff; }
.side-tools { margin-bottom: 12px; }
@media (max-height: 900px) { .side-tools { margin-bottom: 8px; } }
.side-tools kbd { white-space: nowrap; }
@media (max-width: 1400px) { .side-tools kbd { display: none; } }
.fin-charge { display: flex; flex-direction: column; min-width: 0; }
.fin-charge .fc-top { display: flex; align-items: baseline; gap: 8px; white-space: nowrap; }
.fin-charge .fc-desc { color: var(--muted); font-weight: 600; font-size: 14px; }
.b-blue { background: var(--primary-soft); color: var(--primary-d); }
/* Suppression de l'espace famille */
.famdel-list { list-style: none; margin: 14px 0; padding: 14px 16px; border-radius: 14px; background: var(--red-soft); display: flex; flex-direction: column; gap: 8px; }
.famdel-list li { display: flex; gap: 10px; font-size: 14px; }
.famdel-list .i { color: #e11d48; flex: none; width: 16px; height: 16px; margin-top: 3px; }
.famdel-votes { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 12px 0; }
.famdel-votes span { display: inline-flex; align-items: center; gap: 5px; padding: 4px 10px; border-radius: 99px; background: var(--line-2); font-size: 13px; font-weight: 700; color: var(--muted); }
.famdel-votes span.ok { background: var(--green-soft); color: #15803d; }
.famdel-votes .i { width: 15px; height: 15px; }
.famdel-votes small { flex-basis: 100%; }
.famdel-pending { padding: 12px 14px; border-radius: 12px; background: var(--red-soft); }
.famdel-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.famdel-form { margin-top: 14px; }
.clk-sep { display: inline-block; margin: 0 1px; animation: clk-blink 1s steps(1, end) infinite; }
@keyframes clk-blink { 50% { opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .clk-sep { animation: none; } }

/* Messagerie : réactions, menu du message, « … » en train d'écrire */
.reacts { display: flex; flex-wrap: wrap; gap: 4px; margin-top: -6px; position: relative; z-index: 1; padding: 0 6px; }
.react { display: inline-flex; align-items: center; gap: 3px; padding: 1px 7px; min-height: 24px; border-radius: 99px; border: 1px solid var(--line); background: var(--card); font-size: 14px; line-height: 1; cursor: pointer; box-shadow: 0 1px 3px rgba(15, 35, 66, .12); }
.react span { font-size: 12px; font-weight: 700; color: var(--muted); }
.react.mine { border-color: var(--primary); background: var(--primary-soft); }
.react:hover { transform: scale(1.06); }
.msg-menu { position: fixed; z-index: 300; min-width: 220px; max-width: calc(100vw - 16px); background: var(--card); border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--shadow-lg); padding: 6px; animation: mm-in .12s ease-out; }
@keyframes mm-in { from { opacity: 0; transform: scale(.96); } }
.mm-emojis { display: flex; gap: 2px; padding: 2px 2px 6px; border-bottom: 1px solid var(--line-2); margin-bottom: 4px; }
.mm-emojis button { width: 38px; height: 38px; border: 0; border-radius: 50%; background: none; font-size: 22px; cursor: pointer; display: grid; place-items: center; transition: transform .12s, background .12s; }
.mm-emojis button:hover, .mm-emojis button:focus-visible { background: var(--line-2); transform: scale(1.18); outline: none; }
.mm-emojis button.on { background: var(--primary-soft); }
.mm-act { display: flex; align-items: center; gap: 10px; width: 100%; padding: 9px 10px; border: 0; background: none; border-radius: 10px; font: inherit; font-size: 14px; font-weight: 600; color: var(--text); cursor: pointer; text-align: left; }
.mm-act:hover, .mm-act:focus-visible { background: var(--line-2); outline: none; }
.mm-act.danger { color: #e11d48; }
.mm-note { margin: 4px 10px 6px; font-size: 12.5px; color: var(--muted); }
@media (pointer: coarse) { .bubble[data-mid] { -webkit-touch-callout: none; -webkit-user-select: none; user-select: none; } }
.msg.typing .bubble { display: inline-flex; gap: 4px; align-items: center; padding: 12px 14px; }
.msg.typing .bubble i { width: 7px; height: 7px; border-radius: 50%; background: #94a3b8; animation: ty-dot 1.2s infinite ease-in-out; }
.msg.typing .bubble i:nth-child(2) { animation-delay: .15s; }
.msg.typing .bubble i:nth-child(3) { animation-delay: .3s; }
@keyframes ty-dot { 0%, 60%, 100% { transform: translateY(0); opacity: .5; } 30% { transform: translateY(-4px); opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .msg.typing .bubble i { animation: none; } }
/* Fenêtres : le bouton Enregistrer reste toujours visible (téléphone, clavier ouvert, application installée) */
.modal, .modal form { max-height: calc(100vh - 24px - var(--sat) - var(--sab)); max-height: calc(100dvh - 24px - var(--sat) - var(--sab)); }
.modal form > .modal-body { flex: 1 1 auto; min-height: 0; }
.modal form > .modal-foot { flex: none; background: var(--card); }
@media (max-width: 560px) { .modal-foot { padding-bottom: calc(14px + var(--sab)); } }
/* Scan : ajout rapide en série */
.scan-quick { display: flex; flex-direction: column; gap: 10px; }
.sq-card { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 14px; background: var(--green-soft); border: 1px solid color-mix(in srgb, #16a34a 30%, transparent); }
.sq-card strong { display: block; font-size: 16px; }
.sq-card small { color: var(--muted); font-size: 13px; }
.sq-ic { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: var(--card); color: #16a34a; flex: none; }
.sq-boxes { display: flex; align-items: center; gap: 8px; font-weight: 700; font-size: 14px; }
.sq-boxes span { flex: 1; }
.sq-boxes input { width: 64px; text-align: center; }
.sq-actions { display: flex; flex-direction: column; gap: 8px; }
.sq-actions .btn-block { justify-content: center; padding: 13px; font-size: 15px; }
.sq-row { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.sq-row .btn { justify-content: center; }
.sq-skip { align-self: center; }
.sq-count { margin: 10px 0 0; padding: 8px 12px; border-radius: 10px; background: var(--green-soft); color: #15803d; font-weight: 700; font-size: 13.5px; }
.sq-count.err { background: var(--red-soft); color: #be123c; }
.scan-quick .f-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.scan-quick .f { margin: 0; }
.sq-row .btn { white-space: normal; font-size: 14px; padding: 10px 8px; min-width: 0; }
.scan-tools { position: absolute; top: 10px; right: 10px; display: flex; gap: 8px; }
.scan-tool { min-width: 40px; height: 40px; padding: 0 10px; border-radius: 99px; border: 0; background: rgba(5, 12, 25, .6); color: #fff; font: 800 14px/1 Nunito, sans-serif; display: grid; place-items: center; cursor: pointer; }
.scan-tool.on { background: #facc15; color: #111827; }
.scan-tool .i { width: 20px; height: 20px; }
.scan-photo { display: flex; justify-content: center; margin: 0 0 10px; white-space: normal; text-align: center; cursor: pointer; }
/* Administration : famille filtrée, liens */
.adm-famhead { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; padding: 12px 14px; margin-bottom: 14px; border-radius: 14px; background: var(--primary-soft); }
.adm-famhead .grow { flex: 1; min-width: 200px; }
.fam-link { color: inherit; display: inline-flex; align-items: center; gap: 3px; }
.fam-link:hover { color: var(--primary-ink); text-decoration: underline; }
.fam-link .i { width: 13px; height: 13px; opacity: .6; }
.badge-link { text-decoration: none; }
/* Administration 0.23 : fiche, actions groupées, diagnostic, tendances */
.adm-famhead { flex-wrap: wrap; }
.adm-famfacts { flex-basis: 100%; display: flex; flex-wrap: wrap; gap: 14px; font-size: 13px; color: var(--muted); padding-left: 52px; }
.adm-famfacts .i { width: 13px; height: 13px; vertical-align: -2px; }
.adm-mini-log { flex-basis: 100%; display: flex; flex-wrap: wrap; gap: 6px 14px; padding-left: 52px; }
.adm-mini-log .badge { font-size: 11px; }
.adm-user { border: 1px solid var(--line); border-radius: 16px; padding: 14px 16px; margin-bottom: 14px; background: var(--card); box-shadow: var(--shadow); }
.au-head { display: flex; align-items: center; gap: 12px; }
.au-head .grow { flex: 1; min-width: 0; }
.au-actions { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0; }
.au-actions form { margin: 0; }
.au-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; border-top: 1px solid var(--line-2); padding-top: 12px; }
.au-grid h4 { font-size: 13px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); margin: 0 0 8px; display: flex; align-items: center; gap: 6px; }
.au-grid p { margin: 0 0 8px; }
@container content (max-width: 900px) { .au-grid { grid-template-columns: 1fr; } }
@media (max-width: 900px) { .au-grid { grid-template-columns: 1fr; } }
tr.row-on td { background: var(--primary-soft); }
.bulk-col { width: 34px; }
.bulk-col input { width: 18px; height: 18px; accent-color: var(--primary); }
.bulk-bar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 10px 14px; margin-bottom: 12px; border-radius: 12px; background: var(--primary-soft); position: sticky; top: 8px; z-index: 5; }
.bulk-bar small { flex-basis: 100%; }
.ip-block-btn { width: 26px; height: 26px; vertical-align: middle; color: var(--muted); }
.ip-block-btn:hover { color: #e11d48; }
.ip-blocks { margin: 0 0 14px; padding: 10px 14px; border-radius: 12px; border: 1px solid var(--line); }
.ip-blocks summary { cursor: pointer; font-weight: 700; font-size: 14px; display: flex; align-items: center; gap: 8px; }
.ip-blocks .row { gap: 10px; }
.health-list { display: flex; flex-direction: column; gap: 6px; }
.hl-row { display: flex; gap: 12px; align-items: flex-start; padding: 10px 12px; border-radius: 12px; border: 1px solid var(--line-2); font-size: 14px; }
.hl-row small { color: var(--muted); }
.hl-dot { flex: none; display: grid; place-items: center; margin-top: 1px; }
.hl-ok .hl-dot { color: #16a34a; }
.hl-warn { background: color-mix(in srgb, #f59e0b 7%, var(--card)); border-color: color-mix(in srgb, #f59e0b 35%, transparent); }
.hl-warn .hl-dot { color: #d97706; }
.hl-err { background: color-mix(in srgb, #e11d48 7%, var(--card)); border-color: color-mix(in srgb, #e11d48 35%, transparent); }
.hl-err .hl-dot { color: #e11d48; }
.hl-info .hl-dot { color: #2563eb; }
.health-banner { display: flex; align-items: center; gap: 12px; padding: 12px 16px; margin-bottom: 16px; border-radius: 14px; color: inherit; text-decoration: none; font-size: 14px; }
.health-banner span { flex: 1; }
.health-banner.warn { background: color-mix(in srgb, #f59e0b 12%, var(--card)); border: 1px solid color-mix(in srgb, #f59e0b 40%, transparent); }
.health-banner.warn > .i:first-child { color: #d97706; }
.health-banner.err { background: color-mix(in srgb, #e11d48 10%, var(--card)); border: 1px solid color-mix(in srgb, #e11d48 40%, transparent); }
.health-banner.err > .i:first-child { color: #e11d48; }
.g-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
@media (max-width: 900px) { .g-2 { grid-template-columns: 1fr; } }
.trend { width: 100%; height: auto; display: block; margin: 4px 0 6px; }
.trend-axis { stroke: var(--line); stroke-width: 1; }
.trend-val { font: 700 11px Nunito, sans-serif; fill: var(--text); text-anchor: middle; }
.trend-lab { font: 600 11px Nunito, sans-serif; fill: var(--muted); text-anchor: middle; }
.mod-usage { display: flex; flex-direction: column; gap: 7px; }
.mod-usage > div { display: grid; grid-template-columns: 110px 1fr 46px; gap: 10px; align-items: center; font-size: 14px; }
.mod-usage strong { text-align: right; }
.mu-bar { height: 10px; border-radius: 99px; background: var(--line-2); overflow: hidden; }
.mu-bar i { display: block; height: 100%; background: #f97316; border-radius: 99px; }

/* 0.24 — comptes inactifs */
.ret-stats { display: flex; flex-wrap: wrap; gap: 6px; }
.ret-tbl { overflow-x: auto; }
.ret-tbl td, .ret-tbl th { padding-left: 6px; padding-right: 6px; }
.ret-test { display: grid; gap: 8px; margin-top: 12px; }
.ret-test .btn { justify-self: start; }

/* ---------------- 0.25.0 — Accueil : bandeau vivant et nouveaux widgets ---------------- */
/* Bandeau : paysage selon le moment de la journée et la météo, en fondu */
.hero.hero-dyn { background: #1b2550; }
.hero-sky { position: absolute; inset: 0; z-index: 0; overflow: hidden; pointer-events: none; }
.hero-sky::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(10, 22, 50, .55) 0%, rgba(10, 22, 50, .2) 45%, rgba(10, 22, 50, 0) 70%); }
.hero-sky[data-period="matin"]::after, .hero-sky[data-period="midi"]::after, .hero-sky[data-period="apresmidi"]::after { background: linear-gradient(90deg, rgba(10, 30, 70, .5) 0%, rgba(10, 30, 70, .18) 45%, rgba(10, 30, 70, 0) 70%); }
.sky-img { position: absolute; inset: 0; background: center 62% / cover no-repeat; opacity: 0; transition: opacity 2.4s ease; }
.sky-img.on { opacity: 1; }
.hero-greet { font-size: 15px; font-weight: 700; opacity: .95; margin-bottom: 2px; text-shadow: 0 1px 6px rgba(0, 0, 0, .4); }
/* Effets météo : deux plans de gouttes ou de flocons répartis au hasard (tuiles SVG), qui glissent lentement.
   Animations coupées si la famille les a désactivées (.still) ou si l'appareil demande moins de mouvement. */
.sky-fx { position: absolute; inset: 0; z-index: 0; overflow: hidden; }
.sky-fx b { position: absolute; left: -240px; right: -240px; top: -240px; bottom: 0; background-repeat: repeat; will-change: transform; }
.fx-rain b:first-child, .fx-storm b:first-child, .fx-drizzle b:first-child { background-image: url(../img/sky/fx-rain-far.svg); animation: sky-fall 1.9s linear infinite; }
.fx-rain b + b, .fx-storm b + b, .fx-drizzle b + b { background-image: url(../img/sky/fx-rain-near.svg); animation: sky-fall 1.25s linear infinite; }
.fx-drizzle b { opacity: .55; }
.fx-drizzle b:first-child { animation-duration: 2.8s; }
.fx-drizzle b + b { animation-duration: 2s; }
.fx-snow b:first-child { background-image: url(../img/sky/fx-snow-far.svg); animation: sky-snow 14s linear infinite; }
.fx-snow b + b { background-image: url(../img/sky/fx-snow-near.svg); animation: sky-snow 9s linear infinite; }
.sky-fx.fx-storm::after { content: ""; position: absolute; inset: 0; background: #fff; opacity: 0; animation: sky-flash 11s infinite; }
.sky-fx.fx-fog { background: linear-gradient(180deg, rgba(220, 228, 240, .1), rgba(220, 228, 240, .5) 70%, rgba(220, 228, 240, .32)); animation: sky-fog 14s ease-in-out infinite alternate; }
@keyframes sky-fall { from { transform: translate3d(0, 0, 0); } to { transform: translate3d(-43px, 240px, 0); } }
@keyframes sky-snow { from { transform: translate3d(0, 0, 0); } to { transform: translate3d(40px, 240px, 0); } }
@keyframes sky-flash { 0%, 94%, 97%, 100% { opacity: 0; } 95% { opacity: .22; } 96% { opacity: .08; } }
@keyframes sky-fog { from { transform: translateX(-2%); } to { transform: translateX(2%); } }
.hero-sky.still .sky-fx, .hero-sky.still .sky-fx b, .hero-sky.still .sky-fx::after { animation: none !important; }
.hero-sky.still .sky-img { transition: none; }
@media (prefers-reduced-motion: reduce) { .sky-fx, .sky-fx b, .sky-fx::after { animation: none !important; } .sky-img { transition: none; } }

/* Mise en page : 3 colonnes, cartes plus larges */
.dash { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@container content (max-width: 1120px) { .dash { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@container content (max-width: 600px) { .dash { grid-template-columns: minmax(0, 1fr); } .dw[data-size="m"], .dw[data-size="l"] { grid-column: auto; } }
.page-home .cf-btn { padding: 0; width: 54px; }
.page-home .cf-btn .cf-label { display: none; }

/* Frise des 7 prochains jours */
.week-strip { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 8px; }
.wk-day { display: flex; flex-direction: column; gap: 6px; min-width: 0; padding: 8px; border-radius: 14px; background: var(--line-2); color: inherit; text-decoration: none; border: 1px solid transparent; transition: border-color .15s, background .15s; min-height: 96px; }
.wk-day:hover { border-color: #bcd0f3; background: #f5f9ff; }
.wk-day.we { background: #f6f3fd; }
.wk-day.today { background: var(--primary-soft); border-color: #bcd0f3; }
.wk-h { display: flex; align-items: baseline; justify-content: space-between; gap: 4px; }
.wk-h b { font-size: 12px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); }
.wk-h span { font-size: 20px; font-weight: 800; line-height: 1; }
.wk-day.today .wk-h b, .wk-day.today .wk-h span { color: var(--primary-d); }
.wk-list { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.wk-ev { display: block; font-size: 12px; font-weight: 600; line-height: 1.25; padding: 3px 6px; border-radius: 7px; background: color-mix(in srgb, var(--c) 14%, #fff); border-left: 3px solid var(--c); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wk-ev small { font-weight: 800; opacity: .75; }
.wk-more, .wk-free { font-size: 12px; color: var(--muted); }
.wk-free { opacity: .7; }
@container content (max-width: 860px) {
  .week-strip { grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: minmax(120px, 1fr); overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 4px; }
  .wk-day { scroll-snap-align: start; }
}

/* Comptes à rebours */
.cd-list { display: flex; flex-direction: column; gap: 8px; }
.cd-item { display: flex; align-items: center; gap: 10px; padding: 8px; border-radius: 14px; background: color-mix(in srgb, var(--c) 7%, #fff); }
.cd-n { display: flex; flex-direction: column; align-items: center; justify-content: center; min-width: 54px; height: 50px; border-radius: 12px; background: #fff; color: color-mix(in srgb, var(--c) 72%, #0f2342); box-shadow: 0 1px 3px rgba(15, 35, 66, .08); flex: none; line-height: 1; }
.cd-n b { font-size: 20px; font-weight: 800; }
.cd-n b:only-child { font-size: 12px; padding: 0 4px; text-align: center; }
.cd-n small { font-size: 11px; font-weight: 700; margin-top: 2px; opacity: .8; }
.cd-item .ic-bubble { display: none; }

/* Activité récente et messages */
.act-list, .msg-list { display: flex; flex-direction: column; }
.act-item, .msg-item { display: flex; align-items: center; gap: 10px; padding: 9px 4px; color: inherit; text-decoration: none; border-bottom: 1px solid var(--line-2); border-radius: 10px; }
.act-item:last-child, .msg-item:last-child { border-bottom: 0; }
.act-item:hover, .msg-item:hover { background: var(--line-2); }
.act-txt { font-size: 14px; line-height: 1.35; overflow-wrap: anywhere; }
.msg-top { display: flex; justify-content: space-between; gap: 8px; align-items: baseline; }
.msg-top small { color: var(--muted); font-size: 12px; white-space: nowrap; }
.msg-body { font-size: 13.5px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.msg-item.unread .msg-body { color: var(--text); font-weight: 700; }
.msg-n { min-width: 22px; height: 22px; padding: 0 6px; border-radius: 99px; background: var(--red); color: #fff; font-size: 12px; font-weight: 800; display: grid; place-items: center; flex: none; }
.msg-fam { background: linear-gradient(135deg, #0ea5e9, #2563eb); color: #fff; display: grid; place-items: center; }
.msg-fam .i { width: 16px; height: 16px; }

/* Souvenir du jour */
.card.memory-card { padding: 0; overflow: hidden; }
.memory-img { display: flex; align-items: flex-end; min-height: 220px; background: #dfe7f3 center / cover no-repeat; color: #fff; text-decoration: none; }
.memory-cap { display: flex; flex-direction: column; gap: 2px; width: 100%; padding: 40px 16px 14px; background: linear-gradient(180deg, transparent, rgba(8, 16, 36, .75)); text-shadow: 0 1px 4px rgba(0, 0, 0, .4); }
.memory-cap small { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; opacity: .9; }
.memory-cap b { font-size: 17px; }
.memory-cap span { font-size: 13.5px; opacity: .92; }

/* Membres : présence, anniversaire proche, alerte santé seulement si besoin */
.mb-av { position: relative; flex: none; display: inline-flex; }
.mb-av.online::after { content: ""; position: absolute; right: 0; bottom: 0; width: 12px; height: 12px; border-radius: 50%; background: #22c55e; border: 2px solid #fff; }
.mb-seen { font-size: 12px; color: var(--muted); }
.mb-on { color: #15803d; font-weight: 700; }
.mb-chips { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; flex: none; }
.mb-chip { font-size: 12px; font-weight: 700; padding: 3px 9px; border-radius: 99px; white-space: nowrap; }
.mb-chip.bday { background: #fdeaf3; color: #be185d; }
button.row.row-btn { width: 100%; border: 0; background: none; text-align: left; font: inherit; color: inherit; cursor: pointer; border-radius: 10px; }
button.row.row-btn:hover { background: var(--line-2); }
.row-sub.link { color: var(--primary-ink); font-weight: 700; }

/* Vue enfant : points */
.kr-pts { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding: 12px 14px; border-radius: 14px; background: #fff7e0; color: #b45309; margin-bottom: 10px; }
.kr-pts .i { width: 26px; height: 26px; }
.kr-pts strong { font-size: 30px; line-height: 1; }
.kr-pts span { font-weight: 700; }
.kr-pts small { width: 100%; font-size: 12.5px; color: #92400e; }
.wk-long { display: flex; flex-wrap: wrap; gap: 6px; margin: -4px 0 10px; }
.wk-long .wk-ev { font-size: 12.5px; padding: 4px 10px; }
.wk-long .wk-ev small { font-weight: 600; opacity: .8; }
.sky-fx.fx-snow::before { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 45%; background: linear-gradient(180deg, transparent, rgba(244, 248, 255, .55) 45%, rgba(250, 252, 255, .8)); }

/* ---------------- 0.26.0 — Modules indisponibles (maintenance, bientôt) ---------------- */
.nav .nav-off { display: flex; align-items: center; gap: 14px; padding: 11px 14px; border-radius: 12px; color: rgba(227, 235, 255, .4); cursor: not-allowed; font-weight: 600; font-size: 15px; }
.nav .nav-off .i { width: 22px; height: 22px; opacity: .6; }
.nav .nav-off > span { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nav-tag { font-style: normal; font-size: 10px; font-weight: 800; letter-spacing: .02em; text-transform: uppercase; padding: 2px 6px; border-radius: 99px; background: rgba(255, 255, 255, .1); color: #cbd5e1; flex: none; }
.nav-tag.tag-maintenance { background: rgba(249, 115, 22, .22); color: #fdba74; }
.nav-tag.tag-soon { background: rgba(59, 130, 246, .24); color: #93c5fd; }
.mod-row.mod-off { opacity: .6; }
.mod-row.mod-off .ic-bubble { filter: grayscale(1); }
.mod-admin select { width: auto; min-width: 190px; }
.mod-admin select.state-maintenance { border-color: #fdba74; background-color: #fff7ed; }
.mod-admin select.state-soon { border-color: #93c5fd; background-color: #eff6ff; }
.mod-fam { display: flex; flex-direction: column; gap: 8px; }
.mf-row { display: flex; align-items: center; gap: 10px; }
.mf-row .row-main { display: flex; flex-direction: column; min-width: 0; }
.mf-row select { width: auto; max-width: 52%; font-size: 13px; padding: 6px 8px; }

/* ---------------- 0.26.0 — Module Animaux ---------------- */
.pet-av { display: inline-grid; place-items: center; flex: none; border-radius: 50%; background: color-mix(in srgb, var(--c) 16%, #fff); border: 2px solid color-mix(in srgb, var(--c) 45%, #fff); overflow: hidden; line-height: 1; }
.pet-av img { width: 100%; height: 100%; object-fit: cover; }
.pet-av-sm { width: 34px; height: 34px; font-size: 18px; }
.pet-av-md { width: 48px; height: 48px; font-size: 26px; }
.pet-av-xl { width: 88px; height: 88px; font-size: 46px; border-width: 3px; }
.pet-card { border-top: 4px solid var(--c); display: flex; flex-direction: column; gap: 10px; }
.pet-card.is-sel { box-shadow: 0 0 0 2px var(--c), var(--shadow); }
.pet-top { display: flex; gap: 14px; align-items: center; }
.pet-top h2 { font-size: 22px; }
.pet-meta { font-weight: 700; color: var(--c); font-size: 14px; }
.pet-age { font-size: 13px; color: var(--muted); }
.pet-lines .info-line { align-items: center; }
.pet-lines .info-line > div { flex: 1; min-width: 0; }
.pet-spark { flex: none; }
.pet-notes { background: var(--line-2); border-radius: 10px; padding: 8px 10px; margin-top: 6px; }
.pet-foot { display: flex; gap: 8px; flex-wrap: wrap; margin-top: auto; padding-top: 6px; border-top: 1px solid var(--line-2); }
.pet-strip { display: flex; gap: 14px; flex-wrap: wrap; }
.pet-strip > * { display: flex; flex-direction: column; align-items: center; gap: 4px; font-size: 13px; font-weight: 700; color: inherit; text-decoration: none; }
.pet-duty.done .row-title { text-decoration: line-through; opacity: .6; }
.pet-gone summary { cursor: pointer; font-weight: 700; color: var(--muted); }
.duty-members .chip input, .cu-setup .chip input { margin-right: 4px; }

/* ---------------- 0.26.0 — Carnet d'adresses ---------------- */
.ct-toolbar { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-bottom: 12px; }
.ct-cats { margin-bottom: 16px; }
.ct-cats .chip { text-decoration: none; }
.ct-cats .chip small { opacity: .7; font-weight: 700; margin-left: 2px; }
.ct-cats .chip.active { background: var(--primary); color: var(--on-primary); border-color: var(--primary); }
.ct-group { margin-bottom: 4px; }
.ct-gh { display: flex; align-items: center; gap: 10px; font-size: 16px; margin: 4px 0 10px; }
.ct-gh small { color: var(--muted); font-weight: 700; }
.ct-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 270px), 1fr)); gap: 12px; }
.ct-card { background: var(--card); border: 1px solid var(--line); border-left: 4px solid var(--c); border-radius: 16px; padding: 14px; display: flex; flex-direction: column; gap: 10px; box-shadow: var(--shadow); }
.ct-card[hidden] { display: none; }
.ct-top { display: flex; align-items: center; gap: 10px; }
.ct-av { width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; flex: none; background: color-mix(in srgb, var(--c) 15%, #fff); color: color-mix(in srgb, var(--c) 72%, #0f2342); font-weight: 800; font-size: 15px; }
.ct-av.sm { width: 32px; height: 32px; font-size: 12px; }
.ct-name { font-weight: 800; font-size: 15.5px; line-height: 1.25; }
.ct-sub { font-size: 13px; color: var(--muted); }
.ct-star { color: #cbd5e1; }
.ct-star.on { color: #f59e0b; }
.ct-star.on .i { fill: #f59e0b; }
.ct-lines { display: flex; flex-direction: column; gap: 4px; font-size: 13.5px; min-width: 0; }
.ct-lines a, .ct-lines span { display: flex; gap: 6px; align-items: center; color: inherit; overflow-wrap: anywhere; }
.ct-lines a:hover { color: var(--primary-ink); }
.ct-notes { font-size: 13px; color: var(--muted); background: var(--line-2); border-radius: 10px; padding: 6px 9px; }
.ct-actions { display: flex; gap: 6px; align-items: center; margin-top: auto; }
.ct-actions .btn { margin-right: auto; }

/* ---------------- 0.26.0 — Garde partagée ---------------- */
.cu-hero { display: grid; grid-template-columns: 1fr auto; gap: 14px 20px; align-items: center; background: linear-gradient(135deg, color-mix(in srgb, var(--c) 16%, #fff), #fff 70%); border-left: 6px solid var(--c); }
.cu-hero-main small, .cu-hero-next small { display: block; font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.cu-hero-main strong { font-size: 30px; font-weight: 800; color: var(--c); line-height: 1.1; }
.cu-special { display: inline-flex; gap: 4px; align-items: center; margin-top: 6px; font-size: 13px; font-weight: 700; color: #b45309; }
.cu-hero-kids { display: flex; gap: 10px; }
.cu-hero-kids > span { display: flex; flex-direction: column; align-items: center; gap: 2px; font-weight: 700; }
.cu-hero-next { grid-column: 1 / -1; display: flex; gap: 12px; align-items: center; padding: 10px 14px; border-radius: 14px; background: color-mix(in srgb, var(--c2) 10%, #fff); border: 1px solid color-mix(in srgb, var(--c2) 30%, #fff); }
.cu-hero-next > .i { color: var(--c2); width: 24px; height: 24px; }
.cu-hero-next strong { display: block; font-size: 16px; }
.cu-hero-next span { font-size: 13.5px; color: var(--muted); }
.cu-nav { display: flex; gap: 6px; align-items: center; }
.cu-legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: 13px; margin: -4px 0 10px; color: var(--muted); }
.cu-legend span { display: inline-flex; align-items: center; gap: 6px; }
.cu-legend i { width: 14px; height: 14px; border-radius: 4px; background: color-mix(in srgb, var(--c) 30%, #fff); border: 2px solid var(--c); }
.cu-cal { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; }
.cu-cal > b { font-size: 12px; text-align: center; color: var(--muted); text-transform: uppercase; padding-bottom: 2px; }
.cu-day { position: relative; min-height: 64px; border-radius: 10px; padding: 6px; background: color-mix(in srgb, var(--c) 16%, #fff); border-bottom: 3px solid var(--c); display: flex; flex-direction: column; justify-content: space-between; }
.cu-day.out { opacity: .4; }
.cu-day.today { box-shadow: 0 0 0 2px var(--text) inset; }
.cu-day.special { background-image: repeating-linear-gradient(135deg, transparent 0 6px, rgba(255, 255, 255, .55) 6px 9px); }
.cu-n { font-weight: 800; font-size: 14px; }
.cu-h { font-size: 11px; font-weight: 700; color: var(--c); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cu-sw { position: absolute; top: 5px; right: 5px; width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center; background: #fff; color: var(--c); box-shadow: 0 1px 3px rgba(15, 35, 66, .2); }
.cu-sp { position: absolute; top: 6px; right: 28px; color: #b45309; }
.cu-split { margin-top: 10px; }
.cu-pill { width: 10px; align-self: stretch; border-radius: 6px; background: var(--c); flex: none; }
.cu-note.done .row-title { text-decoration: line-through; opacity: .6; }
.cu-swap { flex-wrap: wrap; row-gap: 8px; }
.cu-swap .row-main { flex: 1 1 calc(100% - 60px); }
.cu-swap .btn:first-of-type { margin-left: 46px; }
.cu-widget .cu-now { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 14px; background: color-mix(in srgb, var(--c) 12%, #fff); }
.cu-widget .cu-dot { width: 12px; height: 12px; border-radius: 50%; background: var(--c); flex: none; }
.cu-widget .cu-now small { display: block; font-size: 12px; color: var(--muted); font-weight: 700; }
.cu-widget .cu-now strong { font-size: 18px; color: var(--c); }
.cu-widget .cu-kids { margin-left: auto; display: flex; }
.cu-widget .cu-kids .av { margin-left: -6px; border: 2px solid #fff; }
.cu-widget .cu-next { margin-top: 10px; font-size: 13.5px; font-weight: 600; display: flex; gap: 6px; align-items: center; }
.cu-widget .cu-next .i { color: var(--c2); }
.cu-widget .cu-notes { display: inline-flex; gap: 6px; align-items: center; margin-top: 8px; color: #c2410c; font-weight: 700; }
.wk-home { display: block; margin: -8px -8px 2px; padding: 2px 6px; border-radius: 13px 13px 0 0; background: color-mix(in srgb, var(--c) 22%, #fff); color: color-mix(in srgb, var(--c) 72%, #0f2342); font-size: 10.5px; font-weight: 800; text-transform: uppercase; letter-spacing: .03em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
@container content (max-width: 600px) {
  .cu-day { min-height: 48px; padding: 4px; }
  .cu-sw { top: auto; bottom: 4px; right: 3px; width: 16px; height: 16px; }
  .cu-sw .i { width: 11px; height: 11px; }
  .cu-sp { top: auto; bottom: 4px; right: auto; left: 4px; }
  .cu-h { display: none; }
  .cu-hero { grid-template-columns: 1fr; }
}
.mod-admin select.state-off { border-color: #cbd5e1; background-color: #f1f5f9; color: #64748b; }
.hero .sos-m { display: none; position: absolute; top: calc(12px + var(--sat, 0px)); left: calc(150px + var(--sal, 0px)); z-index: 3; background: rgba(220, 38, 38, .85); color: #fff !important; }
@media (max-width: 900px) { .hero .sos-m { display: grid; } }

/* ---------- 0.28 : Animaux ---------- */
.pet-empty { text-align: center; }
.pet-alert { display: flex; gap: 6px; align-items: center; padding: 7px 10px; border-radius: 10px; background: #fef2f2; color: #b91c1c; font-size: 13px; font-weight: 700; border: 1px solid #fecaca; }
.pet-food { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.pet-food small { font-size: 12.5px; color: var(--muted); font-weight: 600; }
.pf-bar { display: block; height: 8px; border-radius: 99px; background: var(--line-2); overflow: hidden; }
.pf-bar i { display: block; height: 100%; border-radius: 99px; background: #16a34a; transition: width .3s; }
.pet-food.tone-orange .pf-bar i { background: #f59e0b; }
.pet-food.tone-red .pf-bar i { background: #dc2626; }
.pet-food.tone-red small { color: #b91c1c; }
.pet-food-act { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 6px; }
.pet-tr { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; padding: 8px 0; border-bottom: 1px solid var(--line-2); }
.pet-tr:last-child { border-bottom: 0; }
.pet-tr .row-main { flex: 1 1 150px; min-width: 0; }
.pet-slots { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.pet-slot { position: relative; display: inline-flex; align-items: center; gap: 4px; padding: 4px 10px; border-radius: 99px; border: 1.5px solid var(--line); font-size: 13px; font-weight: 700; cursor: pointer; background: var(--card); }
.pet-slot input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.pet-slot:focus-within { outline: 2px solid var(--primary); outline-offset: 1px; }
.pet-slot::before { content: ""; width: 12px; height: 12px; border-radius: 50%; border: 2px solid currentColor; opacity: .5; }
.pet-slot.done { background: #dcfce7; border-color: #16a34a; color: #15803d; }
.pet-slot.done::before { background: currentColor; opacity: 1; }
.pet-slot.late { border-color: #f59e0b; color: #b45309; background: #fffbeb; }
.walk-quick { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; padding: 6px 0; }
.walk-quick > span:first-child { display: inline-flex; align-items: center; gap: 6px; font-weight: 700; margin-right: auto; }
.walk-week { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; align-items: end; height: 70px; margin-top: 10px; padding-bottom: 18px; position: relative; }
.walk-week > span { position: relative; height: 100%; display: flex; align-items: flex-end; justify-content: center; }
.walk-week i { display: block; width: 70%; max-width: 26px; border-radius: 4px 4px 0 0; background: #ea580c; opacity: .75; }
.walk-week > span.today i { opacity: 1; }
.walk-week small { position: absolute; bottom: -18px; font-size: 11px; color: var(--muted); font-weight: 700; }
.pet-chart { width: 100%; height: auto; display: block; color: var(--text); }
.pet-doc-form { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-top: 10px; padding-top: 10px; border-top: 1px dashed var(--line); }
.pet-doc-form input[type=file] { flex: 1 1 180px; font-size: 13px; }
.pet-share-act { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 8px; }
.f-group { border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px 2px; margin: 4px 0 12px; }
.f-group legend { padding: 0 6px; font-weight: 800; font-size: 13px; color: var(--muted); display: inline-flex; gap: 5px; align-items: center; }
/* Fiche de garde publique */
.sitter-wrap { max-width: 860px; margin: 0 auto; padding: 24px 16px 40px; display: flex; flex-direction: column; gap: 16px; }
.sitter-head { display: flex; gap: 14px; align-items: flex-start; justify-content: space-between; flex-wrap: wrap; }
.sitter-head h1 { font-size: 26px; }
.sitter-pet { border-top: 4px solid var(--c); }
.sitter-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 240px), 1fr)); gap: 14px; margin-top: 14px; }
.sitter-grid > div { background: var(--line-2); border-radius: 12px; padding: 10px 12px; }
.sitter-grid h3 { font-size: 14px; display: flex; gap: 6px; align-items: center; margin-bottom: 4px; color: var(--c); }
.sitter-grid p { font-size: 14px; white-space: pre-line; }
.sitter-sos { background: #fef2f2 !important; border: 1px solid #fecaca; }
.sitter-sos h3 { color: #b91c1c !important; }
@media print {
  .sitter-print, .theme-btn { display: none !important; }
  .sitter-wrap { padding: 0; max-width: none; }
  .sitter-pet { break-inside: avoid; box-shadow: none; border: 1px solid #ddd; }
}

/* ---------- 0.28 : Carnet d'adresses ---------- */
.ct-sos { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; padding: 10px 12px; margin-bottom: 14px; border-radius: 16px; background: #fef2f2; border: 1px solid #fecaca; scroll-margin-top: 80px; }
.ct-sos-t { display: inline-flex; gap: 6px; align-items: center; color: #b91c1c; font-size: 15px; }
.ct-sos-list { display: flex; gap: 8px; flex-wrap: wrap; flex: 1; }
.ct-sos-btn { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 99px; background: #fff; border: 1px solid #fecaca; color: #991b1b; text-decoration: none; font-size: 13px; }
.ct-sos-btn b { font-size: 15px; color: #dc2626; display: inline-flex; }
.ct-sos-btn:hover { background: #dc2626; color: #fff; }
.ct-sos-btn:hover b { color: #fff; }
.ct-sos-btn.own { background: #fff7ed; border-color: #fed7aa; color: #9a3412; }
.ct-tag { display: inline-block; font-size: 11px; font-weight: 700; color: var(--muted); background: var(--line-2); border-radius: 6px; padding: 0 6px; margin-right: 4px; text-transform: lowercase; }
.ct-pick { display: inline-flex; gap: 4px; align-items: center; font-size: 12px; font-weight: 700; color: #15803d; background: #dcfce7; border-radius: 99px; padding: 2px 8px; align-self: flex-start; }
.ct-star.on { color: #f59e0b; }
.ct-av img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; display: block; }
.ct-items { display: flex; flex-direction: column; gap: 6px; }
.ct-item { display: grid; grid-template-columns: 74px 120px minmax(0, 1fr) auto; gap: 6px; align-items: center; }
.ct-item-k { font-size: 12px; font-weight: 800; color: var(--muted); text-transform: uppercase; letter-spacing: .03em; }
.ct-item select, .ct-item input { min-width: 0; }
.ct-add { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 6px; }
.ct-checks { display: flex; gap: 6px 18px; flex-wrap: wrap; }
.ct-photo-row { display: flex; gap: 12px; align-items: flex-end; flex-wrap: wrap; }
.ct-photo-row > .f { flex: 1 1 200px; }
.ct-pick-kids { margin: -4px 0 10px 26px; }
.ct-bday { display: flex; gap: 14px; align-items: center; flex-wrap: wrap; padding: 12px 16px; margin-bottom: 16px; border-radius: 18px; background: linear-gradient(135deg, #fef3c7, #fce7f3); border: 1px solid #fde68a; }
.ct-bday .row-main { flex: 1 1 200px; }
.ct-bday strong { font-size: 16px; display: block; }
.ct-bday .ct-av { width: 52px; height: 52px; }
.ct-dups .row { flex-wrap: wrap; }
@media (max-width: 560px) {
  .ct-item { grid-template-columns: minmax(0, 1fr) auto; }
  .ct-item-k { grid-column: 1 / -1; margin-bottom: -4px; }
  .ct-item select { grid-column: 1 / -1; }
}

/* ---------- 0.28 : Garde partagée ---------- */
.cu-day.holiday { background-image: repeating-linear-gradient(45deg, transparent 0 7px, rgba(255, 255, 255, .45) 7px 9px); }
.cu-day.holiday .cu-sp { color: #d97706; }
.cu-swap-act { display: flex; gap: 6px; flex-wrap: wrap; margin-left: 46px; }
.cu-swap .cu-swap-act .btn:first-of-type { margin-left: 0; }
.cu-auto { opacity: .85; }
.cu-hand .row-main { flex: 1 1 160px; }
.cu-hand { flex-wrap: wrap; row-gap: 6px; }
.cu-sub { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line-2); }
.cu-sub h3 { font-size: 14px; display: flex; gap: 6px; align-items: center; margin-bottom: 4px; }
.cu-co-bar { display: flex; gap: 8px; align-items: center; }
.cu-bag-for { margin: -6px 0 10px; }
.cu-bag-bar { height: 6px; border-radius: 99px; background: var(--line-2); overflow: hidden; margin-bottom: 10px; }
.cu-bag-bar i { display: block; height: 100%; background: #f97316; border-radius: 99px; transition: width .3s; }
.cu-bag-list { display: flex; flex-direction: column; gap: 2px; }
.cu-bag-it { display: flex; gap: 10px; align-items: center; padding: 6px 4px; border-radius: 8px; cursor: pointer; font-weight: 600; }
.cu-bag-it:hover { background: var(--line-2); }
.cu-bag-it span { flex: 1; }
.cu-bag-it small { font-size: 12px; color: var(--muted); font-weight: 700; }
.cu-bag-it.on span { text-decoration: line-through; opacity: .6; }
.cu-bag-ok { margin-top: 8px; color: #15803d; font-weight: 800; display: flex; gap: 6px; align-items: center; }
.cu-kid { display: flex; flex-direction: column; gap: 16px; }
.cu-kid-hero { position: relative; overflow: hidden; display: flex; gap: 18px; align-items: center; padding: 22px; background: linear-gradient(135deg, color-mix(in srgb, var(--c) 22%, #fff), #fff 75%); border-left: 6px solid var(--c); }
.cu-kid-hero small { display: block; font-size: 14px; font-weight: 800; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; }
.cu-kid-hero strong { display: block; font-size: clamp(30px, 6vw, 44px); line-height: 1.05; color: var(--c); font-weight: 900; }
.cu-kid-hero span { display: inline-flex; gap: 6px; align-items: center; margin-top: 6px; font-weight: 700; font-size: 15px; }
.cu-kid-house { position: absolute; right: -10px; bottom: -18px; color: var(--c); opacity: .14; }
.cu-kid-house .i { width: 130px; height: 130px; }
.cu-nights { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; }
.cu-night { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 10px 4px; border-radius: 14px; background: color-mix(in srgb, var(--c) 16%, #fff); border-bottom: 4px solid var(--c); text-align: center; }
.cu-night small { font-size: 11.5px; font-weight: 800; color: var(--muted); text-transform: uppercase; }
.cu-night b { font-size: 20px; }
.cu-night span { font-size: 11.5px; font-weight: 800; color: var(--c); line-height: 1.2; overflow-wrap: anywhere; }
.cu-night.today { box-shadow: 0 0 0 2px var(--c); }
@media (max-width: 560px) {
  .cu-nights { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .cu-swap-act { margin-left: 0; }
}
.cu-kid-hero { flex-wrap: nowrap; }
.cu-kid-hero > .av { flex: none; }
.cu-kid-hero > div { flex: 1; min-width: 0; position: relative; z-index: 1; }
@media (max-width: 560px) { .cu-kid-hero { padding: 16px; gap: 12px; } .cu-kid-hero > .av { width: 52px; height: 52px; font-size: 20px; } }
@media (max-width: 560px) { .cu-hand .row-main { flex-basis: calc(100% - 24px); } .cu-hand .badge { margin-left: 22px; } .cu-hand .badge + .btn, .cu-hand .badge ~ .btn { margin-left: auto; } }
@media (max-width: 560px) {
  .ct-sos { flex-direction: column; align-items: stretch; gap: 8px; padding: 10px; }
  .ct-sos-list { flex-wrap: nowrap; overflow-x: auto; padding-bottom: 2px; scrollbar-width: none; }
  .ct-sos-btn { flex: none; }
  .ct-toolbar > :first-child { flex: 1 1 100%; }
}
/* Finances : vignettes du haut (5) et taux d'effort */
.fin-stats { gap: 12px; }
.fin-stats .stat { padding: 14px; gap: 12px; }
.fin-stats .stat .ic-bubble { width: 48px; height: 48px; flex: none; }
.fin-stats .stat .ic-bubble .i { width: 22px; height: 22px; }
.fin-stats .stat strong { font-size: 24px; }
.fin-stats .stat em { font-size: 12.5px; }
.fin-effort > div { min-width: 0; flex: 1; }
.fe-bar { display: block; height: 6px; border-radius: 99px; background: color-mix(in srgb, var(--c) 18%, #fff); overflow: hidden; margin: 4px 0 3px; }
.fe-bar i { display: block; height: 100%; background: var(--c); border-radius: 99px; }
.fin-mode { width: 100%; text-align: left; font: inherit; color: inherit; background: none; border: 0; border-radius: 12px; cursor: pointer; padding-left: 6px; padding-right: 6px; }
.fin-mode:hover:not(:disabled) { background: var(--line-2); }
.fin-mode:disabled { cursor: default; opacity: .6; }
.fin-mode .row-main { display: flex; flex-direction: column; }
.fin-mode > .i { color: var(--muted); opacity: .5; }
.fin-mode.active { background: color-mix(in srgb, var(--primary) 10%, #fff); box-shadow: inset 0 0 0 2px var(--primary); }
.fin-mode.active > .i { color: var(--primary-ink); opacity: 1; }
.fin-filter { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; padding: 8px 12px; margin-bottom: 10px; border-radius: 12px; background: color-mix(in srgb, var(--primary) 8%, #fff); font-size: 14px; font-weight: 600; }
.fin-filter .btn { margin-left: auto; }
.tbl tr[hidden] { display: none !important; }
/* Garde partagée : onglets et livret des dépenses */
.cu-tabs { margin-bottom: 14px; }
.cu-tabs a { display: inline-flex; align-items: center; gap: 6px; text-decoration: none; }
.cu-tab-n { min-width: 18px; height: 18px; padding: 0 5px; border-radius: 99px; background: #f97316; color: #fff; font-size: 11px; font-weight: 800; display: inline-grid; place-items: center; }
.cx-hero { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 14px 18px; align-items: center; border-left: 5px solid var(--c); background: linear-gradient(135deg, color-mix(in srgb, var(--c) 12%, #fff), #fff 70%); }
.cx-hero-main small { display: block; font-size: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.cx-hero-main strong { display: block; font-size: clamp(20px, 3vw, 27px); line-height: 1.2; font-weight: 800; color: color-mix(in srgb, var(--c) 70%, #0f2342); margin: 2px 0; }
.cx-hero-main span { font-size: 13px; color: var(--muted); }
.cx-hero-act { display: flex; flex-direction: column; gap: 8px; }
.cx-facts { grid-column: 1 / -1; display: flex; gap: 8px; flex-wrap: wrap; }
.cx-facts span { display: inline-flex; gap: 6px; align-items: baseline; padding: 6px 12px; border-radius: 12px; background: var(--card); border: 1px solid var(--line); font-size: 13px; color: var(--muted); font-weight: 600; }
.cx-facts b { color: var(--text); font-size: 15px; }
.cx-row { flex-wrap: wrap; row-gap: 6px; align-items: flex-start; }
.cx-row .row-main { flex: 1 1 200px; }
.cx-due { font-weight: 600; }
.cx-due a { color: var(--primary-ink); text-decoration: none; display: inline-flex; gap: 3px; align-items: center; }
.cx-why { margin-top: 4px; font-size: 13px; color: #b91c1c; background: #fef2f2; border-radius: 8px; padding: 4px 8px; display: inline-flex; gap: 5px; align-items: center; }
.cx-side { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; }
.cx-side strong { font-size: 16px; white-space: nowrap; }
.cx-act { display: flex; gap: 6px; align-items: center; justify-content: flex-end; flex-wrap: wrap; margin-left: auto; }
.cx-total { text-align: right; font-weight: 800; margin-top: 8px; }
.cx-exports { margin: 12px 0 0; gap: 6px; flex-wrap: wrap; }
.cx-bars { display: flex; flex-direction: column; gap: 10px; }
.cx-bar { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 3px 8px; font-size: 13.5px; }
.cx-bar-l { display: inline-flex; gap: 6px; align-items: center; font-weight: 600; min-width: 0; }
.cx-bar-l .i { color: var(--c); }
.cx-bar-t { grid-column: 1 / -1; height: 8px; border-radius: 0 4px 4px 0; background: var(--line-2); overflow: hidden; }
.cx-bar-t i { display: block; height: 100%; background: var(--c); border-radius: 0 4px 4px 0; }
.cx-pen-h { margin-bottom: 6px; }
.cx-pen-h b { font-size: 18px; }
.cx-splits { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 12px; }
@media (max-width: 700px) {
  .cx-hero { grid-template-columns: minmax(0, 1fr); }
  .cx-hero-act { flex-direction: row; flex-wrap: wrap; }
  .cx-splits { grid-template-columns: minmax(0, 1fr); }
}
/* Carnet de santé : courbes */
.hc-bar { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.hc-kinds { display: flex; gap: 6px; flex-wrap: wrap; }
.hc-kinds .chip { cursor: pointer; display: inline-flex; align-items: center; gap: 5px; font: inherit; font-size: 13.5px; font-weight: 700; }
.hc-kinds .chip small { opacity: .65; font-weight: 700; }
.hc-kinds .chip.active { background: var(--primary); color: var(--on-primary); border-color: var(--primary); }
.hc-legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: 13px; color: var(--muted); font-weight: 600; margin-bottom: 4px; }
.hc-legend:empty { display: none; }
.hc-legend span { display: inline-flex; align-items: center; gap: 6px; }
.hc-legend i { width: 14px; height: 3px; border-radius: 2px; background: var(--c); }
.hc-plot { position: relative; min-height: 120px; }
.hc-svg { display: block; width: 100%; height: auto; overflow: visible; touch-action: pan-y; }
.hc-grid { stroke: var(--line); stroke-width: 1; }
.hc-base { stroke: var(--muted); stroke-width: 1; opacity: .5; }
.hc-ax { font-size: 11px; fill: var(--muted); font-family: inherit; }
.hc-band-t { font-size: 10.5px; font-weight: 700; font-family: inherit; }
.hc-dot { stroke: var(--card); stroke-width: 2; }
.hc-hot { stroke: var(--card); stroke-width: 2.5; pointer-events: none; }
.hc-cross { stroke: var(--muted); stroke-width: 1; stroke-dasharray: 3 3; pointer-events: none; }
.hc-tip { position: absolute; transform: translate(-50%, -100%); background: var(--card); border: 1px solid var(--line); border-radius: 10px; box-shadow: 0 6px 20px rgba(15, 35, 66, .16); padding: 7px 10px; font-size: 12.5px; pointer-events: none; white-space: nowrap; z-index: 2; }
.hc-tip span { color: var(--muted); }
.hc-tip .hc-tip-age { display: block; font-size: 11.5px; }
.hc-tip div { display: flex; align-items: center; gap: 6px; margin-top: 2px; }
.hc-tip i { width: 8px; height: 8px; border-radius: 50%; }
.hc-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); gap: 8px; margin-top: 10px; }
.hc-stats > div { background: var(--line-2); border-radius: 12px; padding: 8px 10px; min-width: 0; }
.hc-stats small { display: block; font-size: 11.5px; font-weight: 800; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
.hc-stats strong { display: block; font-size: 16px; }
.hc-stats span { display: block; font-size: 11.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hc-table { margin-top: 10px; }
.hc-table summary { cursor: pointer; font-weight: 700; font-size: 13.5px; color: var(--primary-ink); }
.hc-table .table-wrap { margin-top: 8px; max-height: 300px; overflow: auto; }
/* Pharmacie : produits regroupés et détail des boîtes */
.ph-group { cursor: pointer; }
.ph-group:hover td { background: var(--line-2); }
.ph-group:focus-visible { outline: 2px solid var(--primary); outline-offset: -2px; }
.ph-lots { font-weight: 700; color: var(--primary-ink); }
.ph-qty { font-size: 15px; }
.ph-detail { max-width: 560px; }
.ph-boxes { display: flex; flex-direction: column; gap: 8px; }
.ph-box { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; padding: 10px 12px; border: 1px solid var(--line); border-radius: 14px; }
.ph-box.empty { opacity: .6; }
.ph-box-main { flex: 1 1 200px; display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.ph-box-act { display: flex; gap: 2px; }
.advice-set:not([hidden]) { animation: advice-in .35s ease; }
@keyframes advice-in { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }
[data-tips-next].spin .i { animation: tips-spin .5s ease; }
@keyframes tips-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .advice-set:not([hidden]), [data-tips-next].spin .i { animation: none; } }

/* ---------- 0.30 : Pharmacie, inventaires ---------- */
.ph-tabs { display: flex; gap: 6px; overflow-x: auto; padding: 2px 2px 8px; margin-bottom: 8px; scrollbar-width: thin; }
.ph-tab { flex: none; display: inline-flex; align-items: center; gap: 6px; padding: 8px 14px; border-radius: 12px; background: var(--card); border: 1px solid var(--line); color: var(--text); text-decoration: none; font-weight: 700; font-size: 14px; position: relative; cursor: pointer; font-family: inherit; }
.ph-tab .i { color: var(--c); }
.ph-tab small { font-weight: 700; color: var(--muted); font-size: 12px; }
.ph-tab:hover { border-color: var(--c); }
.ph-tab.active { background: var(--c); border-color: var(--c); color: #fff; }
.ph-tab.active .i, .ph-tab.active small { color: #fff; }
.ph-tab-al { font-style: normal; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 99px; background: #e11d48; color: #fff; font-size: 11px; display: inline-grid; place-items: center; }
.ph-tab-add { border-style: dashed; color: var(--muted); --c: var(--muted); }
.ph-cab-head { display: flex; gap: 14px; align-items: center; flex-wrap: wrap; padding: 14px 16px; margin-bottom: 14px; border-radius: 18px; background: linear-gradient(135deg, color-mix(in srgb, var(--c) 12%, #fff), #fff 70%); border: 1px solid color-mix(in srgb, var(--c) 25%, #fff); border-left: 5px solid var(--c); }
.ph-cab-head h2 { font-size: 20px; }
.ph-cab-head .grow { min-width: 160px; }
.ph-cab-ic { width: 46px; height: 46px; border-radius: 14px; display: grid; place-items: center; background: var(--c); color: #fff; flex: none; }
.ph-cab-ic .i { width: 24px; height: 24px; }
.ph-cab-act { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.ph-cab-chip { display: inline-flex; align-items: center; gap: 4px; padding: 2px 8px; border-radius: 99px; background: color-mix(in srgb, var(--c) 12%, #fff); color: color-mix(in srgb, var(--c) 75%, #0f2342); font-weight: 700; font-size: 12.5px; white-space: nowrap; }
.ph-cab-chip .i { color: var(--c); }
.ph-cab-chip.sm { font-size: 11.5px; padding: 1px 7px; }
.ph-dist { display: flex; flex-wrap: wrap; gap: 4px 6px; align-items: center; font-size: 12.5px; }
.ph-box-main .ph-cab-chip { align-self: flex-start; margin-bottom: 2px; }
.ph-mins { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); }
.ph-mins h4 { display: flex; gap: 6px; align-items: center; font-size: 14px; }
.ph-min-row { display: flex; gap: 8px; align-items: center; margin-top: 8px; flex-wrap: wrap; }
.ph-min-row input[type=number] { width: 72px; }
.ph-cab-list .row { gap: 6px; }
.ph-cab-link { display: flex; gap: 10px; align-items: center; flex: 1; min-width: 0; color: inherit; text-decoration: none; }
.ph-cab-link .row-main { display: flex; flex-direction: column; min-width: 0; }
.ph-ord { display: flex; }
.ph-ord .icon-btn { width: 28px; height: 28px; }
.ph-ord .icon-btn:disabled { opacity: .3; }
.ph-tpl-bar { height: 6px; border-radius: 99px; background: var(--line-2); overflow: hidden; margin-bottom: 8px; }
.ph-tpl-bar i { display: block; height: 100%; border-radius: 99px; }
.ph-tpl-list { display: flex; flex-direction: column; }
.ph-tpl-it { display: flex; gap: 8px; align-items: center; padding: 6px 2px; border-bottom: 1px solid var(--line-2); font-size: 13.5px; font-weight: 600; }
.ph-tpl-it:last-child { border-bottom: 0; }
.ph-tpl-it small { display: block; font-size: 11.5px; color: var(--muted); font-weight: 600; }
.ph-tpl-ic { display: inline-grid; place-items: center; color: #16a34a; }
.ph-tpl-it.st-missing .ph-tpl-ic { color: #f97316; }
.ph-tpl-it.st-skip { opacity: .55; }
.ph-tpl-it.st-skip .ph-tpl-ic { color: var(--muted); }
.ph-tpl-it .icon-btn { width: 28px; height: 28px; }
.btn-xs { padding: 3px 9px; font-size: 12px; border-radius: 8px; min-height: 0; }
.ph-ic-pick, .ph-col-pick { display: flex; flex-wrap: wrap; gap: 6px; }
.ph-ic-pick label, .ph-col-pick label { cursor: pointer; }
.ph-ic-pick input, .ph-col-pick input { position: absolute; opacity: 0; pointer-events: none; }
.ph-ic-pick span { width: 38px; height: 38px; border-radius: 10px; display: grid; place-items: center; border: 1.5px solid var(--line); color: var(--muted); }
.ph-ic-pick input:checked + span { border-color: var(--primary); background: color-mix(in srgb, var(--primary) 10%, #fff); color: var(--primary-ink); }
.ph-ic-pick input:focus-visible + span, .ph-col-pick input:focus-visible + span { outline: 2px solid var(--primary); outline-offset: 2px; }
.ph-col-pick span { width: 30px; height: 30px; border-radius: 50%; display: block; background: var(--c); border: 3px solid var(--card); box-shadow: 0 0 0 1.5px var(--line); }
.ph-col-pick input:checked + span { box-shadow: 0 0 0 2.5px var(--c); }
.ph-cab-del { margin-top: 10px; padding-top: 10px; border-top: 1px dashed var(--line); }
.ph-cab-del summary { cursor: pointer; color: #b91c1c; font-weight: 700; display: inline-flex; gap: 5px; align-items: center; }
.ph-cab-del .f-row { display: flex; gap: 8px; margin-top: 8px; }
.ph-mv.mv, .ph-mv-l.mv { --c: #7c3aed; color: #7c3aed; }
.ph-qr-body { text-align: center; }
.ph-qr svg { width: 220px; height: 220px; margin: 0 auto; display: block; background: #fff; padding: 6px; border-radius: 10px; }
.ph-qr-name { font-weight: 800; margin: 6px 0 10px; }
/* Fiche d'urgence */
.ph-sheet-tools { flex-wrap: wrap; gap: 10px; }
.ph-sheet-hint { margin: -4px 0 12px; }
.ph-sheet { max-width: 148mm; margin: 0 auto; background: #fff; color: #0f2342; border-radius: 12px; border: 1px solid #e2e8f0; padding: 9mm 8mm; box-shadow: var(--shadow); font-size: 12px; }
.phs-head { display: flex; gap: 10px; justify-content: space-between; align-items: flex-start; border-bottom: 3px solid var(--c); padding-bottom: 8px; margin-bottom: 8px; }
.phs-head small { color: #64748b; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; font-size: 10px; }
.phs-head h1 { font-size: 20px; display: flex; gap: 6px; align-items: center; color: var(--c); margin: 2px 0; }
.phs-head p { margin: 0; color: #475569; }
.phs-date { font-size: 10px; }
.phs-qr { width: 26mm; flex: none; }
.phs-qr svg { width: 100%; height: auto; display: block; }
.ph-sheet h2 { font-size: 13px; margin: 8px 0 4px; display: flex; gap: 5px; align-items: center; color: #0f2342; }
.phs-sos { background: #fef2f2; border: 1px solid #fecaca; border-radius: 8px; padding: 6px 8px; }
.phs-sos h2 { color: #b91c1c; margin-top: 0; }
.phs-nums { display: grid; grid-template-columns: 1fr 1fr; gap: 2px 10px; }
.phs-nums b { color: #b91c1c; }
.ph-sheet table { width: 100%; border-collapse: collapse; }
.ph-sheet th { text-align: left; font-size: 10px; text-transform: uppercase; color: #64748b; border-bottom: 1px solid #cbd5e1; padding: 3px 4px; }
.ph-sheet td { padding: 3px 4px; border-bottom: 1px solid #eef2f7; vertical-align: top; }
.ph-sheet td small { color: #64748b; }
.phs-warn td { color: #b91c1c; font-weight: 700; }
.phs-foot { margin-top: 8px; font-size: 10px; color: #64748b; text-align: center; }
@media print {
  @page { size: A5; margin: 8mm; }
  body:has(.ph-sheet) .sidebar, body:has(.ph-sheet) .hero, body:has(.ph-sheet) .ph-tabs, body:has(.ph-sheet) .ph-sheet-tools, body:has(.ph-sheet) .ph-sheet-hint,
  body:has(.ph-sheet) .site-foot, body:has(.ph-sheet) footer:not(.phs-foot), body:has(.ph-sheet) .chat-fab, body:has(.ph-sheet) [class*="chat-"] { display: none !important; }
  body:has(.ph-sheet) .main, body:has(.ph-sheet) .content, body:has(.ph-sheet) .shell { padding: 0 !important; margin: 0 !important; display: block !important; background: #fff !important; }
  .ph-sheet { box-shadow: none; border: 0; padding: 0; max-width: none; }
  body.print-qr > *:not(.shell), body.print-qr .shell > *:not(.main), body.print-qr .main > *:not(.content), body.print-qr .content > *:not(dialog) { display: none !important; }
  body.print-qr dialog.qr-printing { position: static; display: block; box-shadow: none; border: 0; }
  body.print-qr dialog.qr-printing .modal-h, body.print-qr dialog.qr-printing .modal-foot, body.print-qr dialog.qr-printing p.small { display: none; }
}
.ph-cab-chip > span { overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.ph-cab-chip.sm { max-width: 120px; }
.ph-cab-chip .i { flex: none; }

.ph-st { margin-top: 4px; }
#ph-table .tbl th, #ph-table .tbl td { padding-left: 7px; padding-right: 7px; }
#ph-table .tbl td.r .icon-btn { width: 30px; height: 30px; }
.ph-dist { flex-direction: column; align-items: flex-start; }
.ph-dist-it { display: inline-flex; align-items: center; gap: 4px; white-space: nowrap; }
dialog.ph-detail form.ph-min-row { display: flex; flex-direction: row; align-items: center; gap: 8px; flex-wrap: wrap; }
dialog.ph-detail form.ph-min-row input[type=number] { width: 72px; flex: none; }

/* ---------- 0.31 : Pharmacie, rappels de lots et fiche officielle ---------- */
.ph-recall { border-radius: 18px; border: 1.5px solid #fecaca; background: #fff5f5; padding: 12px 14px; margin-bottom: 14px; }
.ph-recall-h { display: flex; gap: 10px; align-items: center; margin-bottom: 6px; color: #b91c1c; }
.ph-recall-h > .i { width: 26px; height: 26px; flex: none; }
.ph-recall-h strong { display: block; font-size: 16px; }
.ph-recall-h span { font-size: 13px; color: #7f1d1d; }
.ph-recall-it { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; padding: 10px 12px; margin-top: 8px; border-radius: 12px; background: var(--card); border-left: 4px solid #dc2626; }
.ph-recall-it.st-check { border-left-color: #f59e0b; }
.ph-recall-it .grow { flex: 1 1 260px; min-width: 0; }
.ph-recall-it p { font-size: 13.5px; margin: 2px 0; }
.ph-recall-it small { color: var(--muted); font-size: 12px; display: block; }
.ph-recall-act { display: flex; gap: 6px; flex-wrap: wrap; }
.ph-recall-mini { font-size: 13px; font-weight: 700; color: #b91c1c; display: flex; gap: 5px; align-items: center; margin: 4px 0; }
.ph-recall-mini.st-check { color: #b45309; }
.ph-off-link { display: inline-flex; vertical-align: middle; margin-left: 4px; color: var(--muted); padding: 2px; border-radius: 6px; }
.ph-off-link:hover { color: var(--primary-ink); background: var(--line-2); }
.ph-off { display: flex; gap: 6px; flex-wrap: wrap; margin: 4px 0 10px; }
.ph-recalls-card .row-title { font-size: 13.5px; white-space: normal; }
.adm-recalls { border-top: 1px dashed var(--line); margin: 10px 0; padding-top: 10px; }
.ph-recalls-card .row-main { display: flex; flex-direction: column; min-width: 0; }

/* ---------- 1.1 : Administration, statistiques détaillées ---------- */
.st-range { display: inline-flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.st-range input { padding: 6px 8px; font-size: 13px; width: auto; }
.st-period-note { margin: -6px 0 14px; display: flex; gap: 6px; align-items: center; }
.st-h { font-size: 19px; margin: 26px 0 12px; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.st-h .btn { font-size: 12px; }
.st-h .st-csv:first-of-type { margin-left: auto; }
.st-report { margin-bottom: 8px; border-left: 4px solid #0b1d3a; }
.st-report-form .f-check { margin: 4px 0 8px; }
.st-rcpt { border: 1px solid var(--line); border-radius: var(--r-sm, 10px); padding: 10px 14px 4px; margin: 6px 0 10px; }
.st-rcpt legend { font-weight: 700; font-size: 13px; padding: 0 6px; }
.st-rcpt-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 0 16px; }
.st-rcpt-list .f-check { margin: 4px 0; min-width: 0; }
.st-rcpt-list .f-check span { overflow-wrap: anywhere; }
.st-report-act { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 12px; }
.st-report-test { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-top: 10px; padding-top: 10px; border-top: 1px dashed var(--line); }
.st-funnel { display: flex; flex-direction: column; gap: 10px; }
.sf-row { display: grid; grid-template-columns: minmax(150px, 220px) minmax(0, 1fr) 70px; gap: 4px 12px; align-items: center; }
.sf-l { font-weight: 700; font-size: 14px; }
.sf-track { height: 16px; border-radius: 0 6px 6px 0; background: var(--line-2); overflow: hidden; }
.sf-track i { display: block; height: 100%; background: #2563eb; border-radius: 0 6px 6px 0; }
.sf-row strong { text-align: right; font-size: 15px; }
.sf-row small { grid-column: 2 / -1; color: var(--muted); font-size: 12px; margin-top: -2px; }
.st-cohort td, .st-cohort th { text-align: center; }
.st-cohort td:first-child, .st-cohort th:first-child { text-align: left; }
.ch-cell { background: color-mix(in srgb, #7c3aed calc(var(--p) * 1%), #fff); color: #1e1b4b; font-weight: 700; }
.ch-na { color: var(--muted); }
.st-key { display: flex; flex-wrap: wrap; gap: 6px 16px; margin-bottom: 10px; color: var(--muted); }
.st-key span { display: inline-flex; gap: 6px; align-items: center; }
.st-key i { width: 14px; height: 8px; border-radius: 2px; }
.lg-on i { background: color-mix(in srgb, #f97316 30%, #fff); }
.lg-used i { background: #f97316; }
.st-mods { display: flex; flex-direction: column; gap: 8px; }
.sm-row { display: grid; grid-template-columns: 140px minmax(0, 1fr) 230px; gap: 10px; align-items: center; font-size: 14px; }
.sm-l { font-weight: 600; }
.sm-bars { position: relative; height: 12px; border-radius: 0 6px 6px 0; background: var(--line-2); overflow: hidden; display: block; }
.sm-on, .sm-used { position: absolute; left: 0; top: 0; bottom: 0; border-radius: 0 6px 6px 0; }
.sm-on { background: color-mix(in srgb, #f97316 30%, #fff); }
.sm-used { background: #f97316; height: 100%; }
.sm-v small { color: var(--muted); font-size: 12px; }
.st-mini { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; margin-bottom: 8px; }
.st-mini > div { background: var(--line-2); border-radius: 12px; padding: 10px 12px; min-width: 0; }
.st-mini small { display: block; font-size: 12px; color: var(--muted); font-weight: 700; }
.st-mini strong { display: block; font-size: 20px; }
.st-mini span { font-size: 12px; color: var(--muted); }
.st-feat { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 10px; }
.sf-tile { display: flex; gap: 10px; align-items: center; padding: 12px; border-radius: 14px; background: var(--card); border: 1px solid var(--line); }
.sf-tile small { display: block; font-size: 12.5px; color: var(--muted); font-weight: 600; }
.sf-tile strong { display: block; font-size: 20px; }
.sf-tile span { font-size: 11.5px; color: var(--muted); }
.st-errs { display: flex; flex-direction: column; gap: 6px; margin-top: 10px; }
.se-row { display: flex; gap: 8px; align-items: flex-start; padding: 6px 0; border-bottom: 1px solid var(--line-2); }
.se-row code { font-size: 12px; overflow-wrap: anywhere; display: block; }
.se-row small { display: block; color: var(--muted); font-size: 11.5px; overflow-wrap: anywhere; }
.st-bad { color: #b91c1c; }
.st-mid { color: #b45309; }
.st-cron { display: flex; flex-wrap: wrap; gap: 6px; }
.st-cron span { display: inline-flex; gap: 5px; align-items: center; font-size: 12px; padding: 3px 8px; border-radius: 99px; background: var(--line-2); }
.st-cron i { width: 8px; height: 8px; border-radius: 50%; background: #16a34a; }
.st-cron .late i { background: #e11d48; }
.st-cron .late { color: #b91c1c; font-weight: 700; }
.st-sto > div { display: grid; grid-template-columns: minmax(0, 1fr) 120px 70px 40px; gap: 8px; align-items: center; font-size: 13.5px; padding: 3px 0; }
.st-sto small { color: var(--muted); text-align: right; }
.st-cmp td:nth-child(4) .trend { display: inline; }
@media (max-width: 760px) {
  .sf-row { grid-template-columns: minmax(0, 1fr) 60px; }
  .sf-track { grid-column: 1 / -1; grid-row: 2; }
  .sf-row small { grid-column: 1 / -1; }
  .sm-row { grid-template-columns: minmax(0, 1fr); gap: 3px; }
  .st-sto > div { grid-template-columns: minmax(0, 1fr) 70px 40px; }
  .st-sto .sm-bars { display: none; }
}

/* ===== 1.2 : Pharmacie, confirmation de sortie d'une boîte ===== */
.ph-take-prod { display: flex; gap: 12px; align-items: center; padding: 12px; border-radius: 12px; background: var(--bg); margin-bottom: 14px; --c: #0f9f8f; }
.ph-take-prod > div { display: grid; gap: 2px; min-width: 0; }
.ph-take-prod strong { font-size: 15px; }
.ph-take-prod small { color: var(--muted); font-size: 12.5px; }
.ph-take-box .btn-block { justify-content: center; padding: 12px; }
.ph-take-box [data-tk-scan] > p.small { margin: 6px 0 0; text-align: center; }
.ph-take-list, .ph-take-ack { display: flex; gap: 10px; }
.ph-take-list { margin: 0 0 14px; align-items: flex-start; }
.ph-take-list span { font-weight: 500; font-size: 14px; }
.ph-take-list input { margin-top: 1px; flex: none; }
.ph-take-ack { align-items: flex-start; margin-bottom: 12px; padding: 10px 12px; border-radius: 10px; background: color-mix(in srgb, #f59e0b 12%, transparent); border: 1px solid color-mix(in srgb, #f59e0b 35%, transparent); font-size: 13.5px; line-height: 1.45; }
.ph-take-ack .icon { color: #d97706; vertical-align: -2px; }
.ph-take-ack input { margin-top: 2px; flex: none; }
[data-tk-nocode] { margin: 0 0 12px; }
.ph-take-box [data-tk-go]:disabled { opacity: .5; cursor: not-allowed; }
.ph-take-ack span { font-weight: 500; }

/* ===== 1.2.2 : pastille des messages non lus dans le menu ===== */
.nav-count { margin-left: auto; min-width: 22px; height: 22px; padding: 0 7px; border-radius: 11px; background: #f43f5e; color: #fff; font: 700 12px/22px var(--font, inherit); font-style: normal; text-align: center; font-variant-numeric: tabular-nums; box-shadow: 0 0 0 3px rgba(244, 63, 94, .22); }
.nav a.active .nav-count { background: #fff; color: #e11d48; box-shadow: none; }
.nav-count[hidden], .burger-dot[hidden] { display: none; }
.burger { position: relative; }
.hero .burger { position: absolute; }
.burger-dot { position: absolute; top: 3px; right: 3px; width: 9px; height: 9px; border-radius: 50%; background: #f43f5e; box-shadow: 0 0 0 2px #fff; }

/* ===== 1.2.3 : Pharmacie, mention du partenaire ===== */
.ph-partner { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 6px 10px; margin: 18px 0 4px; font-size: 12.5px; color: var(--muted); opacity: .85; }
.ph-partner a { display: inline-flex; align-items: center; gap: 8px; color: var(--muted); text-decoration: none; }
.ph-partner a:hover { color: var(--text); }
.ph-partner a:hover span { text-decoration: underline; }
.ph-partner img { height: 15px; width: auto; display: block; border-radius: 3px; }
.adm-partner { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; margin: 10px 0; padding: 10px 0; border-top: 1px dashed var(--line); border-bottom: 1px dashed var(--line); }
.adm-partner .f-check span { font-weight: 500; font-size: 14px; }
@media print { .ph-partner { display: none; } }

/* ===== 1.2.4 : Pharmacie, nombre de boîtes mis en avant ===== */
.ph-qty-cell { min-width: 84px; }
.ph-qty-cell .ph-qty { display: inline-block; white-space: nowrap; font-size: 14px; font-weight: 800; color: var(--text); padding: 2px 9px; border-radius: 999px; background: var(--primary-soft); }
.ph-qty-cell .ph-qty.ph-empty { background: var(--red-soft); color: var(--red); }
.ph-qty-cell small { display: block; margin-top: 4px; font-size: 11.5px; line-height: 1.3; }
.ph-detail-sum { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; margin: 0 0 6px; }
.ph-detail-sum strong { font-size: 18px; }
.ph-detail-sum span { color: var(--muted); font-size: 14px; }

/* ===== 1.2.5 : Pharmacie, détail par lot ===== */
.ph-lots-h { display: flex; align-items: center; gap: 6px; margin: 14px 0 2px; font-size: 14px; }
.ph-lots-hint { margin: 0 0 8px; }
.ph-lot-n { flex: none; display: grid; place-items: center; align-content: center; width: 54px; height: 54px; border-radius: 12px; background: var(--primary-soft); color: var(--primary-d); line-height: 1; }
.ph-lot-n b { font-size: 21px; font-weight: 800; }
.ph-lot-n small { font-size: 10.5px; font-weight: 700; margin-top: 2px; text-transform: lowercase; }
.ph-box.empty .ph-lot-n { background: var(--red-soft); color: var(--red); }
.ph-dist-n { font-size: 11.5px; font-weight: 700; color: var(--muted); }

/* ===== 1.3 : Pharmacie, une ligne par boîte et « J'ai pris… » ===== */
.ph-row-act { white-space: nowrap; }
.ph-dose { color: #7c3aed; }
.ph-qty-cell { max-width: 150px; }
.ph-qty-cell small.ph-opened { white-space: normal; }
.ph-box-ic { flex: none; display: grid; place-items: center; width: 38px; height: 38px; border-radius: 10px; background: var(--line-2); color: var(--muted); }
.ph-box.is-open { border-color: color-mix(in srgb, #f59e0b 45%, var(--line)); background: color-mix(in srgb, #f59e0b 6%, transparent); }
.ph-box.is-open .ph-box-ic { background: var(--yellow-soft); color: #b45309; }
.ph-box-main .ph-cab-chip { margin-top: 2px; }
.ph-serial { color: var(--primary-ink); vertical-align: -2px; }
.ph-add-more { margin-top: 10px; }
.ph-dose-n { display: flex; align-items: center; justify-content: center; gap: 18px; margin: 4px 0 6px; }
.ph-dose-n > div { display: grid; justify-items: center; min-width: 90px; }
.ph-dose-n output { font-size: 40px; font-weight: 800; line-height: 1.1; font-variant-numeric: tabular-nums; }
.ph-dose-n span { color: var(--muted); font-size: 14px; }
.ph-dose-n .icon-btn { width: 46px; height: 46px; border-radius: 50%; background: var(--primary-soft); color: var(--primary-d); }
.ph-dose-after { text-align: center; font-size: 14px; margin: 6px 0 14px; min-height: 20px; }
.ph-dose-hint { text-align: center; margin: 10px 0 0; }
.sq-serial { color: var(--primary-d); margin: 0 0 8px; }


.ph-box-act .ph-dose { color: #6d28d9; }
.ph-tip { position: fixed; z-index: 9999; max-width: 260px; padding: 6px 10px; border-radius: 8px; background: #0f2342; color: #fff; font-size: 12.5px; font-weight: 600; line-height: 1.35; pointer-events: none; box-shadow: 0 6px 18px rgba(15, 35, 66, .25); animation: ph-tip-in .12s ease; }
@keyframes ph-tip-in { from { opacity: 0; transform: translateY(3px); } }
@media (prefers-reduced-motion: reduce) { .ph-tip { animation: none; } }
#ph-table .tbl td.ph-row-act { padding-left: 0; padding-right: 0; }
#ph-table .tbl td.ph-row-act .icon-btn { width: 27px; height: 30px; }

/* ===== 1.4 : Pharmacie, listing lisible avec illustrations ===== */
.ph-layout { display: grid; gap: 18px; }
.ph-aside { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 18px; align-items: start; }
.ph-list .tbl th { font-size: 11.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.ph-list .tbl td { vertical-align: middle; padding-top: 12px; padding-bottom: 12px; }
.ph-list .tbl th:first-child, .ph-list .tbl td:first-child { padding-left: 4px; }
.ph-med { display: flex; align-items: center; gap: 14px; min-width: 0; }
.ph-art-wrap { flex: none; display: grid; place-items: center; width: 64px; height: 44px; border-radius: 8px; overflow: hidden; }
.ph-art-wrap .ph-art { display: block; filter: drop-shadow(0 2px 3px rgba(15, 35, 66, .12)); }
.ph-art-wrap.ph-thumb { padding: 0; border: 1px solid var(--line); background: #fff; cursor: zoom-in; }
.ph-art-wrap.ph-thumb img { width: 100%; height: 100%; object-fit: cover; }
.ph-art-ic { background: color-mix(in srgb, var(--c) 14%, transparent); color: var(--c); }
.ph-art-ic .i { width: 24px; height: 24px; }
.ph-med-t { min-width: 0; display: grid; gap: 3px; }
.ph-med-n { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 6px; }
.ph-med-n strong { font-size: 15px; font-weight: 700; }
.ph-med-t small { color: var(--muted); font-size: 13px; }
.ph-info { display: inline-grid; place-items: center; width: 22px; height: 22px; padding: 0; border: 0; border-radius: 50%; background: var(--primary-soft); color: var(--primary-ink); cursor: pointer; }
.ph-info .i { width: 14px; height: 14px; }
.ph-rx { display: inline-flex; align-items: center; padding: 1px 8px; border-radius: 999px; border: 1px solid color-mix(in srgb, #7c3aed 40%, transparent); color: #6d28d9; font-size: 11px; font-weight: 700; letter-spacing: .02em; }
.ph-med-x { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; margin: 6px 0 0 78px; font-size: 12.5px; }
.ph-med-x .ph-dist { flex-direction: row; }
.ph-c-exp { color: var(--muted); white-space: nowrap; font-variant-numeric: tabular-nums; }
.ph-st-expired .ph-c-exp { color: var(--red); font-weight: 700; }
.ph-st-soon .ph-c-exp { color: #be185d; font-weight: 600; }
.ph-c-box { white-space: nowrap; }
.ph-nbox { font-size: 19px; font-weight: 800; font-variant-numeric: tabular-nums; }
.ph-nbox.many { color: var(--green); }
.ph-c-box span { color: var(--muted); font-size: 13px; }
.ph-step { display: inline-flex; align-items: center; gap: 4px; padding: 3px; border: 1px solid var(--line); border-radius: 12px; background: var(--card); box-shadow: 0 1px 2px rgba(15, 35, 66, .05); }
.ph-st-btn { display: grid; place-items: center; width: 30px; height: 30px; padding: 0; border: 0; border-radius: 9px; background: var(--line-2); color: var(--text); cursor: pointer; }
.ph-st-btn:hover:not(:disabled) { background: var(--primary-soft); color: var(--primary-d); }
.ph-st-btn:disabled { opacity: .35; cursor: default; }
.ph-st-btn .i { width: 15px; height: 15px; }
.ph-st-val { min-width: 104px; text-align: center; font-size: 14px; white-space: nowrap; }
.ph-st-val b { font-variant-numeric: tabular-nums; }
.ph-step.busy { opacity: .7; }
.ph-step.flash .ph-st-val b { animation: ph-flash .5s ease; }
@keyframes ph-flash { 0% { color: var(--primary-ink); } 100% { color: inherit; } }
.ph-qtxt { font-size: 14px; white-space: nowrap; }
.ph-stat-act { display: flex; align-items: center; gap: 8px; }
.ph-stat-act > .badge { min-width: 104px; justify-content: center; text-align: center; }
.ph-sq-btn { display: grid; place-items: center; flex: none; width: 34px; height: 34px; padding: 0; border: 1px solid var(--line); border-radius: 10px; background: var(--card); color: var(--text); cursor: pointer; }
.ph-sq-btn:hover { border-color: var(--primary); color: var(--primary-ink); }
.ph-sq-btn .i { width: 17px; height: 17px; }
.ph-c-more { width: 36px; }
.ph-detail-head { display: flex; gap: 14px; align-items: center; margin-bottom: 8px; }
.ph-detail-head .ph-art { flex: none; filter: drop-shadow(0 3px 5px rgba(15, 35, 66, .15)); }
.ph-detail-photo { width: 96px; height: 64px; object-fit: cover; border-radius: 10px; flex: none; }
.ph-rx-note { margin: 4px 0 0; padding: 6px 10px; border-radius: 8px; background: color-mix(in srgb, #7c3aed 8%, transparent); color: #5b21b6; }
.ph-box-step { flex: none; }
.ph-box-step .ph-st-val { min-width: 90px; }
.ph-rx-chk span { font-weight: 600; }
@media (max-width: 1100px) {
  .ph-list .tbl thead { display: none; }
  .ph-list .tbl, .ph-list .tbl tbody, .ph-list .tbl tr, .ph-list .tbl td { display: block; }
  .ph-list .tbl tr { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 14px; padding: 14px 2px; border-bottom: 1px solid var(--line); }
  .ph-list .tbl td { padding: 0 !important; border: 0; }
  .ph-list .ph-c-med, .ph-list .ph-c-qty, .ph-list .ph-c-st { grid-column: 1 / -1; }
  .ph-list .tbl td.ph-c-more { display: none; }
  .ph-list td[data-label]::before { content: attr(data-label); display: block; margin-bottom: 2px; font-size: 10.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
  .ph-med-x { margin-left: 0; }
  .ph-list .ph-step { display: flex; width: 100%; justify-content: space-between; }
  .ph-list .ph-stat-act { justify-content: space-between; }
}

/* ===== 1.4.1 : Administration, photos des médicaments ===== */
.dp-wrap { display: grid; grid-template-columns: repeat(auto-fit, minmax(420px, 1fr)); gap: 18px; align-items: start; }
.dp-search { display: flex; gap: 10px; }
.dp-list { display: grid; gap: 8px; }
.dp-grid { grid-template-columns: repeat(auto-fill, minmax(420px, 1fr)); }
.dp-row { display: flex; align-items: center; gap: 12px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 12px; }
.dp-thumb { flex: none; display: grid; place-items: center; width: 72px; height: 50px; border-radius: 8px; overflow: hidden; background: var(--line-2); }
.dp-thumb.has { background: #fff; border: 1px solid var(--line); }
.dp-thumb img { width: 100%; height: 100%; object-fit: contain; }
.dp-main { flex: 1; min-width: 0; display: grid; gap: 1px; }
.dp-main strong { font-size: 14px; }
.dp-main small { color: var(--muted); font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dp-main code { font-size: 11.5px; color: var(--muted); }
.dp-up label { cursor: pointer; white-space: nowrap; }
@media (max-width: 560px) { .dp-wrap, .dp-grid { grid-template-columns: 1fr; } .dp-row { flex-wrap: wrap; } }
.ph-art-wrap.ph-thumb img { object-fit: contain; background: #fff; }
.dp-main .badge { justify-self: start; margin-top: 2px; }

/* ===== 1.4.2 : sortie d'une boîte plus explicite, informations rapides complémentaires ===== */
.ph-sq-btn.ph-take { color: #be123c; border-color: color-mix(in srgb, #e11d48 30%, var(--line)); }
.ph-sq-btn.ph-take:hover { background: color-mix(in srgb, #e11d48 8%, transparent); border-color: #e11d48; color: #be123c; }
.hinfo-extra .hinfo-list { display: grid; gap: 8px; margin-bottom: 8px; }
.hinfo-x { display: grid; grid-template-columns: 1.4fr 1fr auto; gap: 6px; align-items: center; padding: 8px; border: 1px solid var(--line); border-radius: 12px; background: var(--line-2); }
.hinfo-x input[name="extra_label[]"] { grid-column: 1 / 3; grid-row: 1; font-weight: 600; }
.hinfo-x [data-repeat-del] { grid-column: 3; grid-row: 1; }
.hinfo-x input[name="extra_value[]"] { grid-column: 1; grid-row: 2; }
.hinfo-x input[name="extra_phone[]"] { grid-column: 2; grid-row: 2; }
.hinfo-x input { min-width: 0; }
.hinfo-extra .btn { justify-self: start; }
.hinfo-add .row-sub { font-size: 13px; }
@media (max-width: 520px) {
  .hinfo-x { grid-template-columns: 1fr auto; }
  .hinfo-x input[name="extra_label[]"] { grid-column: 1; grid-row: 1; }
  .hinfo-x [data-repeat-del] { grid-column: 2; grid-row: 1; }
  .hinfo-x input[name="extra_value[]"] { grid-column: 1 / -1; grid-row: 2; }
  .hinfo-x input[name="extra_phone[]"] { grid-column: 1 / -1; grid-row: 3; }
}

/* ===== 1.5 : Module Véhicules ===== */
.veh-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 18px; }
.veh-card { position: relative; overflow: hidden; display: flex; flex-direction: column; gap: 12px; border-top: 4px solid var(--c); }
.veh-card.is-sel { box-shadow: 0 0 0 2px var(--c), var(--shadow, 0 6px 18px rgba(15, 35, 66, .08)); }
.veh-top { display: flex; align-items: flex-start; gap: 12px; }
.veh-ic { flex: none; display: grid; place-items: center; width: 46px; height: 46px; border-radius: 14px; background: color-mix(in srgb, var(--c) 14%, transparent); color: var(--c); }
.veh-ic .i { width: 24px; height: 24px; }
.veh-ic.sm { width: 34px; height: 34px; border-radius: 10px; vertical-align: middle; }
.veh-ic.sm .i { width: 18px; height: 18px; }
.veh-t { flex: 1; min-width: 0; }
.veh-t h2 { font-size: 18px; margin: 0; }
.veh-t h2 a { color: inherit; }
.veh-t small { color: var(--muted); font-size: 13px; }
.veh-badges { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.veh-plate { display: inline-flex; align-items: stretch; height: 30px; border: 2px solid #1f2937; border-radius: 5px; background: #fff; overflow: hidden; font-family: "Arial Narrow", Arial, sans-serif; box-shadow: 0 1px 2px rgba(0,0,0,.15); }
.veh-plate i { display: grid; place-items: end center; width: 16px; padding-bottom: 2px; background: #1d4ed8; color: #fff; font-size: 9px; font-style: normal; font-weight: 700; }
.veh-plate i:last-child { background: #1d4ed8; }
.veh-plate b { display: grid; place-items: center; padding: 0 10px; color: #111827; font-size: 16px; font-weight: 800; letter-spacing: .06em; }
.veh-crit { display: inline-flex; align-items: center; padding: 3px 10px; border-radius: 999px; border: 2px solid var(--k); color: var(--k); font-size: 12px; font-weight: 800; }
.veh-lines { display: grid; gap: 6px; }
.veh-lines > div { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; font-size: 14px; }
.veh-lines > div > span { color: var(--muted); min-width: 150px; display: inline-flex; align-items: center; gap: 6px; }
.veh-lines small { flex-basis: 100%; color: var(--muted); font-size: 12px; padding-left: 158px; }
.veh-foot { display: flex; flex-wrap: wrap; gap: 8px; margin-top: auto; }
.veh-foot .btn-soft { --c: var(--primary); }
.veh-add { display: grid; place-items: center; align-content: center; gap: 8px; min-height: 180px; border: 2px dashed var(--line); border-radius: var(--radius); background: transparent; color: var(--muted); font: inherit; font-weight: 700; cursor: pointer; }
.veh-add:hover { border-color: var(--primary); color: var(--primary-ink); }
.veh-add .i { width: 28px; height: 28px; }
.veh-sel-h { display: flex; align-items: center; gap: 10px; font-size: 20px; }
.veh-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.veh-act { background: color-mix(in srgb, var(--c) 10%, var(--card)); color: color-mix(in srgb, var(--c) 80%, var(--text)); border: 1px solid color-mix(in srgb, var(--c) 30%, transparent); }
.veh-act:hover { background: color-mix(in srgb, var(--c) 18%, var(--card)); }
.veh-ops { display: grid; }
.veh-op { display: grid; grid-template-columns: auto 1fr auto auto; align-items: start; gap: 12px; padding: 12px 2px; border-bottom: 1px solid var(--line-2); }
.veh-op:last-child { border-bottom: 0; }
.veh-op-t { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; }
.veh-op-t small { color: var(--muted); font-size: 12.5px; }
.veh-op-d { font-size: 14px; margin-top: 2px; }
.veh-op-n { margin-top: 2px; }
.veh-op-a { white-space: nowrap; font-variant-numeric: tabular-nums; padding-top: 2px; }
.veh-op-x { display: flex; gap: 2px; }
.veh-att { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
.veh-att a { display: inline-flex; align-items: center; gap: 4px; padding: 2px 9px; border-radius: 999px; background: var(--primary-soft); color: var(--primary-d); font-size: 12px; font-weight: 600; }
.veh-chart { width: 100%; height: auto; color: var(--text); }
.veh-split { display: flex; flex-wrap: wrap; gap: 6px 14px; margin-top: 8px; font-size: 12.5px; color: var(--muted); }
.veh-split span { display: inline-flex; align-items: center; gap: 5px; }
.veh-split i { width: 9px; height: 9px; border-radius: 3px; }
.veh-split b { color: var(--text); }
.veh-dl { display: grid; grid-template-columns: auto 1fr; gap: 6px 14px; margin: 0; font-size: 14px; }
.veh-dl dt { color: var(--muted); }
.veh-dl dd { margin: 0; font-weight: 600; }
.veh-notes { margin-top: 10px; padding: 8px 10px; border-radius: 10px; background: var(--line-2); }
.veh-fiche-act { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.veh-alerts { margin-top: 10px; }
.veh-doc-up { margin-top: 10px; }
.veh-doc-up label { cursor: pointer; }
.veh-search { position: relative; }
.veh-sugg { position: absolute; z-index: 20; left: 0; right: 0; top: calc(100% - 18px); max-height: 300px; overflow: auto; margin: 0; padding: 4px; list-style: none; background: var(--card); border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 12px 30px rgba(15, 35, 66, .18); }
.veh-sugg li { display: grid; gap: 1px; padding: 8px 10px; border-radius: 8px; cursor: pointer; }
.veh-sugg li:hover { background: var(--primary-soft); }
.veh-sugg li span { font-size: 13px; }
.veh-sugg li small { color: var(--muted); font-size: 12px; }
.veh-alert-box { display: grid; gap: 2px; padding: 10px 12px; margin: 4px 0 10px; border-radius: 12px; background: var(--line-2); }
.veh-alert-box .f-check span { font-weight: 500; font-size: 14px; }
.veh-del { margin-top: 10px; }
@media (max-width: 560px) {
  .veh-lines > div > span { min-width: 0; flex-basis: 100%; }
  .veh-lines small { padding-left: 0; }
  .veh-op { grid-template-columns: auto 1fr auto; }
  .veh-op-x { grid-column: 2 / -1; justify-content: flex-end; }
}
.veh-more { margin-top: 10px; text-align: center; }

/* ===== 1.6 : Véhicules — illustration, recherche des générations, certificat d'immatriculation ===== */
.veh-vis-wrap { position: relative; }
.veh-vis-wrap > a { display: block; }
.veh-visual { position: relative; display: grid; place-items: center; height: 136px; border-radius: 12px; overflow: hidden; color: var(--text);
  background: radial-gradient(120% 90% at 50% 100%, color-mix(in srgb, var(--c) 16%, transparent), transparent 70%), linear-gradient(180deg, color-mix(in srgb, var(--c) 6%, var(--card)), var(--line-2)); }
.veh-visual.lg { height: 170px; margin-bottom: 12px; }
.veh-visual img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.veh-visual .veh-sil { width: 78%; max-width: 270px; height: auto; margin-top: 8px; }
.veh-credit { position: absolute; right: 6px; bottom: 6px; max-width: calc(100% - 12px); padding: 1px 7px; border-radius: 6px; background: rgba(15, 23, 42, .6); color: #fff; font-size: 10.5px; line-height: 1.5; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.veh-credit:hover { background: rgba(15, 23, 42, .8); color: #fff; }
.veh-photo-btn { position: absolute; top: 8px; right: 8px; display: inline-flex; align-items: center; gap: 5px; padding: 6px 9px; border: 0; border-radius: 10px; background: rgba(255, 255, 255, .88); color: #0f172a; font: inherit; font-size: 12.5px; font-weight: 700; cursor: pointer; box-shadow: 0 2px 8px rgba(15, 23, 42, .15); }
.veh-photo-btn:hover { background: #fff; }
.veh-photo-btn .i { width: 16px; height: 16px; }
.veh-sugg { padding: 6px; max-height: 380px; }
.veh-sugg ul { margin: 0; padding: 0; list-style: none; }
.veh-sg-h { padding: 8px 10px 4px; color: var(--muted); font-size: 11.5px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; }
.veh-sg-h small { margin-left: 4px; font-weight: 600; text-transform: none; letter-spacing: 0; }
.veh-sg-none { margin: 0; padding: 6px 10px 8px; color: var(--muted); font-size: 13px; }
.veh-sugg .veh-sg-wiki li { grid-template-columns: 64px 1fr; align-items: center; gap: 10px; }
.veh-sg-wiki img, .veh-sg-noimg, .veh-gen img { width: 64px; height: 44px; border-radius: 7px; object-fit: cover; background: var(--line-2); }
.veh-sg-noimg { display: block; }
.veh-sg-wiki div { display: grid; gap: 1px; min-width: 0; }
.veh-sg-wiki small { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.veh-gen { display: flex; align-items: center; gap: 12px; padding: 10px 12px; margin: -2px 0 12px; border: 1px solid color-mix(in srgb, var(--primary) 35%, transparent); border-radius: 12px; background: var(--primary-soft); }
.veh-gen img { width: 84px; height: 56px; }
.veh-gen > div { flex: 1; display: grid; gap: 2px; min-width: 0; }
.veh-gen small { font-size: 12.5px; }
.veh-engines { margin: -4px 0 12px; padding: 10px 12px; border-radius: 12px; background: var(--line-2); }
.veh-eng-list ul { display: grid; gap: 4px; max-height: 230px; overflow: auto; margin: 8px 0 0; padding: 0; list-style: none; }
.veh-eng-list li { display: grid; gap: 1px; padding: 7px 10px; border-radius: 9px; background: var(--card); border: 1px solid transparent; cursor: pointer; font-size: 14px; }
.veh-eng-list li:hover { border-color: var(--primary); }
.veh-eng-list li.is-on { border-color: var(--primary); box-shadow: 0 0 0 2px color-mix(in srgb, var(--primary) 25%, transparent); }
.veh-eng-list li small { color: var(--muted); font-size: 12px; }
.veh-eng-list .veh-sg-none { padding: 6px 0 0; }
.veh-up-row input[type=file] { font-size: 13px; }
.veh-rc { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 8px; }
.veh-rc-slot { display: grid; gap: 6px; }
.veh-rc-slot form { display: contents; }
.veh-rc-add { display: grid; place-items: center; align-content: center; gap: 2px; min-height: 104px; padding: 8px; border: 2px dashed var(--line); border-radius: 12px; color: var(--muted); text-align: center; cursor: pointer; }
.veh-rc-add:hover { border-color: var(--primary); color: var(--primary-ink); }
.veh-rc-add .i { width: 22px; height: 22px; }
.veh-rc-add small { font-size: 11.5px; }
.veh-rc-view { display: grid; place-items: center; height: 104px; border-radius: 12px; overflow: hidden; background: var(--line-2); color: var(--muted); }
.veh-rc-view { position: relative; }
.veh-rc-view img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.veh-rc-view .i { width: 30px; height: 30px; }
.veh-rc-f { display: flex; align-items: center; gap: 6px; font-size: 13px; }
.veh-rc-f small { flex: 1; color: var(--muted); font-size: 12px; }
.veh-wiki { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line-2); }
.veh-wiki-h { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 10px; }
.veh-wiki-h .search { flex: 1 1 220px; max-width: 320px; }
.veh-wiki-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; margin-bottom: 8px; }
.veh-wiki-it { display: grid; gap: 3px; padding: 6px; border: 1px solid var(--line); border-radius: 12px; background: var(--card); color: var(--text); font: inherit; text-align: left; cursor: pointer; }
.veh-wiki-it:hover { border-color: var(--primary); }
.veh-wiki-it img, .veh-wiki-it .veh-sg-noimg { width: 100%; height: 92px; border-radius: 8px; object-fit: cover; }
.veh-wiki-it b { font-size: 13px; line-height: 1.25; }
.veh-wiki-it small { color: var(--muted); font-size: 12px; }
.veh-wiki-it.is-busy { opacity: .5; pointer-events: none; }
@media (max-width: 560px) {
  .veh-visual { height: 120px; }
  .veh-wiki-grid { grid-template-columns: 1fr 1fr; }
}

/* Cadrage de la photo d'un véhicule */
.veh-frame { display: grid; gap: 8px; margin: 4px 0 6px; padding: 12px; border-radius: 12px; background: var(--line-2); }
.veh-frame-box { position: relative; height: 136px; max-width: 360px; border-radius: 12px; overflow: hidden; cursor: grab; touch-action: none; box-shadow: inset 0 0 0 2px color-mix(in srgb, var(--primary) 40%, transparent); }
.veh-frame-box.is-drag { cursor: grabbing; }
.veh-frame-box img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; pointer-events: none; user-select: none; }
.veh-frame-range { display: flex; align-items: center; gap: 10px; max-width: 360px; font-size: 12.5px; color: var(--muted); }
.veh-frame-range input { flex: 1; }

/* ===== 1.7 : Véhicules — plan d'entretien, pneus, coûts, carburant, papiers, partage, lecture des photos ===== */
.veh-tools { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.veh-compare > summary { display: flex; align-items: center; gap: 8px; cursor: pointer; font-weight: 800; font-size: 16px; list-style: none; }
.veh-compare > summary::-webkit-details-marker { display: none; }
.veh-compare > summary small { font-weight: 500; }
.veh-compare[open] > summary { margin-bottom: 10px; }
.veh-cmp { width: 100%; border-collapse: collapse; font-size: 14px; }
.veh-cmp td, .veh-cmp th { white-space: nowrap; padding: 9px 12px; border-bottom: 1px solid var(--line-2); text-align: left; }
.veh-cmp th { color: var(--muted); font-size: 12px; font-weight: 700; }
.veh-cmp tr:last-child td { border-bottom: 0; }
.veh-cmp td a { display: inline-flex; align-items: center; color: inherit; font-weight: 700; }
.veh-cmp td.num, .veh-cmp th.num { text-align: right; font-variant-numeric: tabular-nums; }
.veh-cmp-bar { display: block; width: 120px; margin-left: auto; height: 4px; margin-top: 4px; border-radius: 4px; background: linear-gradient(90deg, var(--c) var(--w), var(--line-2) var(--w)); }
.veh-dot { display: inline-block; width: 10px; height: 10px; margin-right: 8px; border-radius: 50%; background: var(--c); }
.veh-plan-intro { margin: -4px 0 10px; }
.veh-plan { display: grid; }
.veh-plan-row { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(70px, 1fr) auto auto; align-items: center; gap: 12px; padding: 9px 0; border-bottom: 1px solid var(--line-2); }
.veh-plan-row:last-child { border-bottom: 0; }
.veh-plan-row.is-off { opacity: .55; }
.veh-plan-t { display: grid; gap: 1px; min-width: 0; }
.veh-plan-t strong { font-size: 14px; }
.veh-plan-t small { color: var(--muted); font-size: 12px; }
.veh-plan-bar { height: 8px; border-radius: 6px; background: var(--line-2); overflow: hidden; }
.veh-plan-bar i { display: block; height: 100%; border-radius: 6px; background: var(--green); }
.veh-plan-bar i.t-orange { background: var(--orange, #f59e0b); }
.veh-plan-bar i.t-red { background: var(--red); }
.veh-plan-bar i.t-gray { background: #cbd5e1; }
.veh-plan-check { margin: 4px 0 10px; }
.veh-plan-boxes { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 2px 12px; margin-top: 6px; padding: 8px 10px; border-radius: 10px; background: var(--line-2); }
.veh-plan-boxes .f-check span { font-size: 13.5px; font-weight: 500; }
.veh-tyres { display: grid; gap: 8px; }
.veh-tyre { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 12px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 12px; }
.veh-tyre.is-on { border-color: color-mix(in srgb, var(--primary) 45%, transparent); background: color-mix(in srgb, var(--primary) 5%, var(--card)); }
.veh-tyre-ic { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 50%; background: #fef3c7; color: #b45309; }
.veh-tyre-ic.s-hiver { background: #e0f2fe; color: #0369a1; }
.veh-tyre-ic.s-4s { background: #dcfce7; color: #15803d; }
.veh-tyre-m { display: grid; gap: 2px; min-width: 0; }
.veh-tyre-m > small { color: var(--muted); font-size: 12.5px; }
.veh-tyre-w { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; margin-top: 4px; font-size: 13px; }
.veh-tyre-w small { color: var(--muted); font-size: 12px; }
.veh-tread { width: 90px; height: 7px; border-radius: 5px; background: var(--line-2); overflow: hidden; }
.veh-tread i { display: block; height: 100%; background: var(--green); }
.veh-tread.t-orange i { background: #f59e0b; }
.veh-tread.t-red i { background: var(--red); }
.veh-tyre-x { display: flex; align-items: center; gap: 2px; }
.veh-rc-sum { display: grid; grid-template-columns: 1fr auto; gap: 2px 8px; margin-top: 10px; padding: 10px 12px; border-radius: 12px; background: color-mix(in srgb, #7c3aed 8%, var(--card)); }
.veh-rc-sum small { grid-column: 1 / -1; color: var(--muted); font-size: 12px; }
.veh-rc { grid-template-columns: 1fr 1fr; }
.veh-rc-slot:nth-child(3) { grid-column: 1 / -1; }
.veh-rc-slot:nth-child(3) .veh-rc-add, .veh-rc-slot:nth-child(3) .veh-rc-view { min-height: 84px; height: auto; }
.veh-rc-slot:nth-child(3) .veh-rc-view { height: 104px; }
.veh-fuelp-avg { display: grid; grid-template-columns: 1fr auto; gap: 2px 8px; padding: 10px 12px; border-radius: 12px; background: #fff7ed; color: #7c2d12; margin-bottom: 8px; }
.veh-fuelp-avg b { font-size: 20px; }
.veh-fuelp-avg small { grid-column: 1 / -1; color: #9a3412; font-size: 12px; }
.veh-fuelp-list { display: grid; gap: 2px; margin: 0 0 8px; padding: 0; list-style: none; counter-reset: st; }
.veh-fuelp-list li { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 10px; padding: 7px 2px; border-bottom: 1px solid var(--line-2); font-size: 13.5px; }
.veh-fuelp-list li:first-child b { color: var(--green-d, #15803d); }
.veh-fuelp-list b { font-variant-numeric: tabular-nums; }
.veh-fuelp-list span { display: grid; min-width: 0; }
.veh-fuelp-list small { color: var(--muted); font-size: 12px; }
.veh-share-link { display: flex; gap: 6px; margin: 6px 0; }
.veh-share-link input { flex: 1; min-width: 0; font-size: 12.5px; }
.veh-f-check { align-self: end; }
.veh-ocr { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; margin: 0 0 12px; }
.veh-ocr > label { cursor: pointer; }
.veh-ocr > small { flex: 1 1 220px; font-size: 12px; }
.veh-ocr-out { flex-basis: 100%; padding: 10px 12px; border-radius: 12px; background: var(--primary-soft); font-size: 13.5px; }
.veh-ocr-out ul { margin: 6px 0 8px; padding: 0; list-style: none; display: grid; gap: 2px; }
.veh-ocr-out .f-check span { font-weight: 500; }
.veh-ocr-out.is-err { background: var(--red-soft); color: #9f1239; }
.veh-ocr-out.is-ok { background: var(--green-soft); color: #166534; }
.veh-ocr-spin { display: inline-block; width: 14px; height: 14px; vertical-align: -2px; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: veh-spin .8s linear infinite; }
@keyframes veh-spin { to { transform: rotate(360deg); } }
input.is-warn { border-color: #f59e0b !important; box-shadow: 0 0 0 3px rgba(245, 158, 11, .2); }
.veh-odo-warn { display: block; margin-top: 4px; color: #b45309; font-size: 12.5px; }
.vshare-card .veh-visual { margin-bottom: 12px; }
.vshare-h { display: flex; align-items: center; gap: 8px; font-size: 18px; }
.vshare-form { display: grid; gap: 4px; max-width: 560px; }
@media (max-width: 560px) {
  .veh-plan-row { grid-template-columns: 1fr auto; }
  .veh-plan-bar { grid-column: 1 / -1; grid-row: 2; }
  .veh-plan-n { grid-row: 1; grid-column: 2; }
  .veh-plan-row .icon-btn { grid-row: 3; grid-column: 2; justify-self: end; }
  .veh-tyre { grid-template-columns: auto 1fr; }
  .veh-tyre-x { grid-column: 1 / -1; justify-content: flex-end; }
}

/* ===== 1.7.1 : Véhicules — page du véhicule (bandeau, ajout d'un événement) ===== */
.veh-back { display: inline-flex; align-items: center; gap: 6px; margin-bottom: 12px; color: var(--muted); font-weight: 700; font-size: 14px; }
.veh-back:hover { color: var(--primary-ink); }
.veh-hero { display: grid; grid-template-columns: minmax(260px, 400px) 1fr; gap: 22px; align-items: stretch; border-top: 4px solid var(--c); }
.veh-hero-vis { position: relative; }
.veh-visual.hero { height: 100%; min-height: 220px; }
.veh-visual.hero .veh-sil { width: 82%; max-width: 330px; }
.veh-hero-m { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.veh-hero-t { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.veh-hero-t h1 { margin: 0; font-size: 26px; line-height: 1.15; }
.veh-hero-t p { margin: 4px 0 0; color: var(--muted); font-size: 14px; }
.veh-hero-facts { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.veh-hero-facts > div { display: grid; gap: 2px; padding: 10px 12px; border-radius: 12px; background: var(--line-2); border-left: 3px solid #cbd5e1; min-width: 0; }
.veh-hero-facts > div.t-green { border-left-color: var(--green); }
.veh-hero-facts > div.t-blue { border-left-color: var(--primary); }
.veh-hero-facts > div.t-orange { border-left-color: #f59e0b; }
.veh-hero-facts > div.t-red { border-left-color: var(--red); background: var(--red-soft); }
.veh-hero-facts small { display: flex; align-items: center; gap: 5px; color: var(--muted); font-size: 12px; }
.veh-hero-facts b { font-size: 15px; font-variant-numeric: tabular-nums; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.veh-hero-facts em { font-style: normal; color: var(--muted); font-size: 12px; }
.veh-hero-act { display: flex; flex-wrap: wrap; gap: 8px; margin-top: auto; }
.veh-hist-act { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.veh-add-for { margin: -4px 0 12px; }
.veh-add-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.veh-add-it { display: grid; justify-items: start; gap: 4px; padding: 14px; border: 1px solid var(--line); border-radius: 14px; background: color-mix(in srgb, var(--c) 6%, var(--card)); color: var(--text); font: inherit; text-align: left; cursor: pointer; }
.veh-add-it:hover { border-color: var(--c); box-shadow: 0 4px 14px color-mix(in srgb, var(--c) 18%, transparent); }
.veh-add-it .ic-bubble { --c: inherit; }
.veh-add-it b { font-size: 14.5px; }
.veh-add-it small { color: var(--muted); font-size: 12px; line-height: 1.35; }
@media (max-width: 900px) {
  .veh-hero { grid-template-columns: 1fr; }
  .veh-visual.hero { min-height: 180px; height: 180px; }
  .veh-hero-facts { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 560px) {
  .veh-hero-t h1 { font-size: 22px; }
  .veh-hero-act .btn { flex: 1 1 auto; justify-content: center; }
  .veh-add-grid { grid-template-columns: 1fr 1fr; }
}

/* Glisser-déposer (module Véhicules) */
.veh-drop { transition: box-shadow .15s, background-color .15s; border-radius: 12px; }
.veh-drop.is-drag { box-shadow: 0 0 0 2px var(--primary), 0 0 0 6px color-mix(in srgb, var(--primary) 18%, transparent); background-color: var(--primary-soft); }
.veh-drop-hint { display: block; margin-top: 4px; color: var(--muted); font-size: 12px; }
.veh-drop-ov { position: fixed; inset: 0; z-index: 90; display: none; place-items: center; padding: 24px; background: rgba(15, 23, 42, .35); pointer-events: none; }
.veh-drop-ov > div { display: grid; gap: 6px; padding: 28px 36px; border: 3px dashed #fff; border-radius: 20px; background: rgba(37, 99, 235, .92); color: #fff; text-align: center; font-size: 15px; }
.veh-drop-ov b { font-size: 20px; }
body.veh-dragging .veh-drop-ov { display: grid; }

/* Lecture d'un ticket ou d'une facture depuis le choix « Ajouter un événement » */
.veh-add-photo { display: grid; margin: 0 0 6px; }
.veh-add-photo-btn { grid-template-columns: auto 1fr; align-items: center; column-gap: 14px; padding: 16px; border-style: dashed; border-width: 2px; }
.veh-add-photo-t { display: grid; gap: 3px; }
.veh-add-photo-t b { font-size: 15.5px; }
.veh-add-or { margin: 10px 0 8px; }
.veh-ocr-out .veh-ocr-kind { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 4px; font-weight: 600; }
.veh-ocr-out .veh-ocr-kind select { width: auto; padding: 4px 8px; }
.veh-ocr-warn { margin: 6px 0; padding: 8px 10px; border-radius: 10px; background: #fff7ed; color: #9a3412; }

/* ===== 1.8.0 : Santé — carnet en onglets, fiche d'urgence, mesures, consultations, rappels ===== */
.txt-red { color: var(--red); }
.center { text-align: center; justify-content: center; }
.htabs { display: flex; flex-wrap: wrap; gap: 6px; overflow-x: auto; padding: 4px; margin: 0 0 16px; background: var(--card); border: 1px solid var(--line); border-radius: 14px; scrollbar-width: thin; }
.htabs a { display: inline-flex; align-items: center; gap: 6px; padding: 8px 12px; border-radius: 10px; color: var(--muted); font-weight: 700; font-size: 14px; white-space: nowrap; }
.htabs a .i { width: 16px; height: 16px; }
.htabs a:hover { background: var(--line-2); color: var(--text); }
.htabs a.active { background: var(--red-soft); color: #be123c; }
.htab-n { min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px; background: var(--orange); color: #fff; font-size: 12px; display: inline-flex; align-items: center; justify-content: center; }
.htab-n.late { background: #dc2626; }
.hsub { display: flex; width: max-content; max-width: 100%; overflow-x: auto; margin: -6px 0 16px; }
.hsub a { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; }
.hsub a.active { background: var(--card); color: var(--heading); box-shadow: 0 1px 3px rgba(15, 35, 66, .12); }
.hsub .htab-n { height: 18px; min-width: 18px; font-size: 11px; }
/* Carnet › Aperçu : bandeau des informations vitales */
.hvital { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; padding: 14px 16px; margin-bottom: 16px; border-radius: var(--radius); background: var(--card); border: 1px solid var(--line); border-left: 4px solid #dc2626; box-shadow: var(--shadow); }
.hvital dl { display: flex; flex-wrap: wrap; gap: 8px 26px; flex: 1; min-width: 0; margin: 0; }
.hvital dl > div { min-width: 0; }
.hvital dt { font-size: 12px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.hvital dd { margin: 2px 0 0; font-weight: 600; overflow-wrap: anywhere; }
.hvital-go { flex: none; }
@media (max-width: 760px) { .hvital-go { width: 100%; justify-content: center; } }
/* Fenêtre « Ajouter » : tuiles */
.hadd-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.hadd-tile { display: flex; align-items: flex-start; gap: 10px; padding: 12px; border: 1px solid var(--line); border-radius: 14px; background: var(--card); color: var(--text); font: inherit; text-align: left; cursor: pointer; transition: border-color .15s, background .15s; }
.hadd-tile:hover, .hadd-tile:focus-visible { border-color: var(--primary); background: var(--primary-soft); }
.hadd-tile > span:last-child { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.hadd-tile strong { font-size: 14.5px; }
.hadd-tile small { font-size: 12.5px; color: var(--muted); line-height: 1.35; }
.hadd-tile .ic-bubble { flex: none; }
@media (max-width: 480px) { .hadd-tile { flex-direction: column; gap: 6px; padding: 10px; } .hadd-tile small { display: none; } }
.hstats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 12px; }
.hstats-3 { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
@container (max-width: 900px) { .hstats { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 700px) { .hstats { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.hstat { display: flex; gap: 12px; align-items: flex-start; background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 14px; box-shadow: var(--shadow); min-width: 0; }
.hstat .ic-bubble { --c: inherit; flex: none; }
.hstat small { display: block; color: var(--muted); font-weight: 700; font-size: 12.5px; }
.hstat strong { display: block; font-size: 24px; line-height: 1.15; font-weight: 800; }
.hstat strong small { display: inline; font-size: 13px; color: var(--muted); }
.hstat-sub { display: flex; flex-wrap: wrap; gap: 4px 6px; align-items: center; font-size: 12.5px; color: var(--muted); margin-top: 3px; }
.hpill { display: inline-flex; align-items: center; padding: 2px 9px; border-radius: 999px; font-size: 12px; font-weight: 800; white-space: nowrap; }
.hpill-green { background: var(--green-soft); color: #15803d; }
.hpill-orange { background: var(--orange-soft); color: #c2410c; }
.hpill-red { background: #fee2e2; color: #b91c1c; }
.hpill-gray { background: var(--line-2); color: var(--muted); }
.hquick { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 16px; }
.hsyn { margin-bottom: 18px; align-items: start; }
.hemerg { border: 2px solid #dc2626; box-shadow: 0 0 0 4px rgba(220, 38, 38, .07), var(--shadow); }
.hemerg-id { display: flex; gap: 14px; align-items: center; margin: 4px 0 12px; }
.hemerg-id strong { font-size: 18px; }
.hblood { display: inline-flex; flex-direction: column; align-items: center; justify-content: center; width: 58px; height: 58px; border-radius: 50%; background: #dc2626; color: #fff; flex: none; }
.hblood b { font-size: 19px; line-height: 1; }
.hblood .i { width: 14px; height: 14px; }
.hemerg-dl { display: grid; grid-template-columns: minmax(110px, 34%) 1fr; gap: 8px 12px; margin: 0; }
.hemerg-dl dt { color: var(--muted); font-weight: 700; font-size: 13px; }
.hemerg-dl dd { margin: 0; min-width: 0; overflow-wrap: anywhere; }
.h-allergy { color: #dc2626; font-weight: 900; }
.hice-call { white-space: nowrap; }
.hpriv { margin-top: 14px; padding-top: 12px; border-top: 1px dashed var(--line); }
.hrem-late .row-title { color: #b91c1c; }
.hqr-mini { display: flex; gap: 14px; align-items: center; }
.hqr-mini .qr { width: 120px; flex: none; background: #fff; border-radius: 10px; padding: 4px; }
.qr svg { width: 100%; height: auto; display: block; }
.qr-big { width: min(300px, 100%); margin: 6px auto 8px; background: #fff; border-radius: 14px; padding: 8px; border: 1px solid var(--line); }
.hcharts { margin-bottom: 18px; }
.hchart-box { position: relative; height: 250px; }
.hchart-box canvas { width: 100% !important; height: 100% !important; }
.hchart-empty { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; color: var(--muted); font-weight: 700; margin: 0; background: repeating-linear-gradient(-45deg, transparent 0 10px, var(--line-2) 10px 11px); border-radius: 12px; }
.hchart-empty[hidden] { display: none; }
.hm-table td, .hm-table th { vertical-align: middle; }
.hm-table td .hpill { margin-top: 3px; }
.hep-list { display: grid; gap: 12px; }
.hep { padding: 16px; }
.hep-h { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.hep-h h3 { margin: 0; font-size: 17px; }
.hep-done { opacity: .9; }
.hep-dl { display: grid; grid-template-columns: 110px 1fr; gap: 6px 12px; margin: 12px 0 0 54px; font-size: 14px; }
.hep-dl dt { color: var(--muted); font-weight: 700; }
.hep-dl dd { margin: 0; }
.hep-cons { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin: 10px 0 0 54px; }
.hep-add { margin: 8px 0 0 48px; }
@media (max-width: 600px) { .hep-dl, .hep-cons, .hep-add { margin-left: 0; } .hep-dl { grid-template-columns: 1fr; } }
.hc-filter { flex-wrap: wrap; }
.hc-filter select { width: auto; }
.hcons { display: grid; gap: 10px; }
.hcon { padding: 14px 16px; scroll-margin-top: 90px; }
.hcon-h { display: flex; gap: 12px; align-items: center; }
.hcon-h h3 { margin: 0; font-size: 16px; }
.hcon-amt { font-size: 16px; white-space: nowrap; }
.hcon-rep { margin-top: 8px; }
.hcon-rep summary { cursor: pointer; font-weight: 700; color: var(--primary-ink); font-size: 14px; }
.hcon-files { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.hc-flash { animation: hcflash 2.4s ease; }
@keyframes hcflash { 0%, 40% { box-shadow: 0 0 0 3px var(--primary); } 100% { box-shadow: var(--shadow); } }
.hdoc-drop { border: 2px dashed var(--line); border-radius: 14px; padding: 12px 14px 6px; margin-bottom: 12px; background: var(--line-2); transition: border-color .15s, background .15s; }
.hdoc-drop.over { border-color: var(--primary); background: var(--primary-soft); }
.hdoc-drop .f { margin-bottom: 4px; }
.hdoc-status { margin: 6px 0 8px; padding: 9px 12px; border-radius: 10px; background: var(--primary-soft); font-size: 14px; display: grid; gap: 3px; }
.hdoc-status.ok { background: var(--green-soft); color: #166534; }
.hdoc-status .small { color: var(--muted); }
.spin { display: inline-block; width: 14px; height: 14px; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: hspin .7s linear infinite; vertical-align: -2px; }
@keyframes hspin { to { transform: rotate(360deg); } }
.hdoc-hl { animation: hdochl 4s ease; }
@keyframes hdochl { 0%, 60% { background-color: #dcfce7; border-color: #16a34a; box-shadow: 0 0 0 3px rgba(22, 163, 74, .2); } 100% { } }
.hdoc-files { display: grid; gap: 4px; margin-bottom: 6px; }
.hdoc-file { display: flex; align-items: center; gap: 8px; font-size: 14px; }
.hdoc-file a { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hrem-presets { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-bottom: 12px; }
.hrem-presets .chip { font-size: 12.5px; padding: 4px 10px; }
.chip.active { background: var(--primary); color: var(--on-primary); }
.hrem-when { font-weight: 800; font-size: 13px; white-space: nowrap; color: var(--muted); }
.hrem-when.soon { color: #c2410c; }
.hrem-when.late { color: #dc2626; }
.hrem.hrem-late { background: #fef2f2; border-radius: 12px; }
.hrem-arch { opacity: .75; }
.hrem-archive summary { cursor: pointer; font-weight: 700; display: flex; gap: 8px; align-items: center; }
.hurg { align-items: start; margin-bottom: 18px; }
.hurg-form fieldset { border: 0; padding: 0; margin: 0 0 14px; }
.hurg-form legend { font-weight: 800; margin-bottom: 6px; }
.hurg-modes { display: grid; gap: 8px; }
.hurg-mode { display: flex; gap: 10px; align-items: flex-start; border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; cursor: pointer; }
.hurg-mode:has(input:checked) { border-color: #dc2626; background: #fef2f2; }
.hurg-mode input { margin-top: 4px; }
.hurg-mode span { display: grid; gap: 2px; }
.hurg-mode span .i { display: none; }
.hurg-mode small { color: var(--muted); }
.hurg-fields { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 6px 12px; }
.hurg-fields legend { grid-column: 1 / -1; }
.hurg-fields .f-check { display: flex; gap: 8px; align-items: center; }
.hurg-link { margin-top: 14px; padding-top: 12px; border-top: 1px dashed var(--line); }
.hurg-text pre { white-space: pre-wrap; font-size: 12.5px; background: var(--line-2); padding: 10px; border-radius: 10px; max-height: 260px; overflow: auto; }
.hpub-mini { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 10px; }
.hpub-row { border: 1px solid var(--line); border-radius: 12px; padding: 8px 12px; min-width: 0; }
.hpub-row small { display: block; color: var(--muted); font-weight: 700; text-transform: uppercase; font-size: 11.5px; letter-spacing: .04em; }
.hpub-row strong { overflow-wrap: anywhere; }
.hpub-row.is-alert strong { color: #dc2626; }
.myh-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.myh-t { background: var(--line-2); border-radius: 12px; padding: 10px 12px; min-width: 0; }
.myh-t small { display: block; color: var(--muted); font-weight: 700; font-size: 12px; }
.myh-v { display: block; font-size: 19px; font-weight: 800; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.myh-v small { display: inline; font-size: 12px; }
.myh-s { display: block; font-size: 12px; color: var(--muted); margin-top: 2px; }
.myh { position: relative; }
.myh-hidden .myh-grid { filter: blur(7px); user-select: none; cursor: pointer; }
.myh-reveal { position: absolute; left: 50%; top: 58%; transform: translate(-50%, -50%); display: inline-flex; gap: 6px; align-items: center; border: 0; border-radius: 999px; padding: 9px 16px; background: var(--card); color: var(--text); font-weight: 800; box-shadow: var(--shadow-lg); cursor: pointer; }
@media (max-width: 600px) { .hemerg-dl { grid-template-columns: 1fr; gap: 2px; } .hemerg-dl dd { margin-bottom: 8px; } .hcon-h { flex-wrap: wrap; } .hqr-mini { flex-direction: column; align-items: flex-start; } }
@media (max-width: 700px) { .htabs { flex-wrap: nowrap; } }

/* ===== 1.8.1 : Santé — page de la famille simplifiée ===== */
.hfam-h { font-size: 17px; margin: 0 0 10px; }
.hfam { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 12px; margin-bottom: 18px; }
.hfam-c { display: flex; flex-direction: column; align-items: center; gap: 8px; text-align: center; background: var(--card); border: 1px solid var(--line); border-radius: 18px; padding: 16px 12px 14px; box-shadow: var(--shadow); color: inherit; transition: transform .15s, box-shadow .15s; min-width: 0; }
a.hfam-c:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); }
.hfam-t strong { display: block; font-size: 16px; }
.hfam-t small { color: var(--muted); }
.hfam-s { font-size: 12.5px; color: var(--muted); max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hfam-add { display: inline-flex; flex-wrap: wrap; gap: 6px; justify-content: flex-end; }
.hfam-g { margin: 14px 0 4px; }
.hfam-g.late { color: #dc2626; }
.hfam-row { color: inherit; cursor: pointer; }
@media (max-width: 600px) { .hfam { grid-template-columns: repeat(2, minmax(0, 1fr)); } .hfam-add .btn { padding: 6px 9px; } }
@media (max-width: 600px) {
  .hfam { grid-template-columns: 1fr; gap: 8px; }
  .hfam-c { flex-direction: row; text-align: left; padding: 10px 12px; gap: 12px; }
  .hfam-c .av { width: 44px; height: 44px; font-size: 18px; }
  .hfam-t { flex: 1; min-width: 0; }
  .hfam-s { display: none; }
}

/* ===== 1.11.0 : Actualités (franceinfo) ===== */
.news-tabs { display: flex; gap: 6px; overflow-x: auto; padding: 4px; margin: 0 0 12px; background: var(--card); border: 1px solid var(--line); border-radius: 14px; scrollbar-width: thin; }
.news-tabs a { display: inline-flex; align-items: center; gap: 6px; padding: 8px 12px; border-radius: 10px; color: var(--muted); font-weight: 700; font-size: 14px; white-space: nowrap; flex: none; }
.news-tabs a .i { width: 16px; height: 16px; color: var(--c); }
.news-tabs a:hover { background: var(--line-2); color: var(--text); }
.news-tabs a.active { background: var(--c); color: #fff; }
.news-tabs a.active .i { color: #fff; }
.news-tabs-sep { flex: none; width: 1px; margin: 6px 4px; background: var(--line); }
.news-bar { flex-wrap: wrap; }
.news-upd { white-space: nowrap; }
.news-layout { align-items: start; }
.news-main { min-width: 0; display: grid; gap: 14px; }
.news-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 14px; }
.news-card { display: flex; flex-direction: column; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; min-width: 0; }
.news-img { display: block; aspect-ratio: 16 / 9; background: var(--line-2); overflow: hidden; }
.news-img img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .3s; }
.news-card:hover .news-img img { transform: scale(1.03); }
.news-ph { width: 100%; height: 100%; display: grid; place-items: center; background: linear-gradient(135deg, color-mix(in srgb, var(--c) 18%, transparent), color-mix(in srgb, var(--c) 6%, transparent)); color: var(--c); }
.news-ph .i { width: 42px; height: 42px; opacity: .6; }
.news-body { display: flex; flex-direction: column; gap: 6px; padding: 12px 14px 10px; flex: 1; }
.news-meta { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--muted); }
.news-rub { color: var(--c); font-weight: 800; text-transform: uppercase; letter-spacing: .03em; font-size: 11.5px; }
.news-body h3 { font-size: 16px; line-height: 1.3; margin: 0; }
.news-body h3 a { color: var(--text); }
.news-body h3 a:hover { color: var(--primary-ink); }
.news-body p { margin: 0; font-size: 13.5px; color: var(--muted); line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.news-acts { display: flex; gap: 2px; margin-top: auto; padding-top: 4px; justify-content: flex-end; }
.news-acts .icon-btn { width: 34px; height: 34px; color: var(--muted); }
.news-save.on { color: #0f766e; }
.news-save.on .i { fill: currentColor; }
.news-lead { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); }
.news-lead .news-img { aspect-ratio: auto; min-height: 260px; height: 100%; }
.news-lead .news-body { padding: 20px 22px 14px; gap: 10px; }
.news-lead h3 { font-size: 24px; line-height: 1.2; }
.news-lead p { -webkit-line-clamp: 6; font-size: 15px; }
@media (max-width: 760px) { .news-lead { grid-template-columns: 1fr; } .news-lead .news-img { min-height: 0; aspect-ratio: 16 / 9; } .news-lead h3 { font-size: 20px; } }
.news-by { display: flex; align-items: center; gap: 8px; padding: 8px 10px; border-radius: 10px; background: var(--line-2); font-size: 13px; }
.news-by span { flex: 1; min-width: 0; }
.news-fil ol { list-style: none; margin: 0; padding: 0; }
.news-fil li { display: grid; grid-template-columns: 44px 1fr; gap: 8px; padding: 8px 0; border-bottom: 1px solid var(--line-2); font-size: 14px; line-height: 1.35; }
.news-fil li:last-child { border-bottom: 0; }
.news-fil time { color: #e11d48; font-weight: 800; font-size: 13px; }
.news-fil a { color: var(--text); font-weight: 600; }
.news-fil a:hover { color: var(--primary-ink); }
.news-2l { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; white-space: normal; }
.news-about { gap: 8px; }
.news-about p { margin: 0; color: var(--muted); }
.news-share-t { font-weight: 700; margin: 0 0 10px; }
.news-mini { display: grid; gap: 2px; }
.news-mini-it { display: grid; grid-template-columns: 1fr auto; gap: 2px 10px; padding: 8px 0; border-bottom: 1px solid var(--line-2); color: var(--text); }
.news-mini-it:last-child { border-bottom: 0; }
.news-mini-it img { grid-column: 1 / -1; width: 100%; aspect-ratio: 16 / 8; object-fit: cover; border-radius: 10px; margin-bottom: 6px; }
.news-mini-t { font-weight: 700; font-size: 14px; line-height: 1.3; }
.news-mini-it small { color: var(--muted); font-size: 12px; white-space: nowrap; }
.news-mini-it:hover .news-mini-t { color: var(--primary-ink); }
.news-src { margin: 8px 0 0; font-size: 12px; color: var(--muted); }

/* ---------- Administration › Mises à jour ---------- */
.upd-done { display: flex; gap: 8px; align-items: center; margin-bottom: 16px; }
.upd-pending { border-left: 4px solid #16a34a; }
.upd-facts { list-style: none; margin: 0 0 12px; padding: 0; display: grid; gap: 6px; font-size: 14px; }
.upd-facts li { display: flex; gap: 8px; align-items: flex-start; }
.upd-facts .i { color: #16a34a; margin-top: 3px; flex: none; }
.upd-notes { margin: 4px 0 14px; }
.upd-notes summary { cursor: pointer; font-weight: 700; font-size: 14px; color: var(--primary-ink); }
.upd-notes .cl-entry { box-shadow: none; border: 1px solid var(--line); margin-top: 10px; }
.upd-install { display: grid; gap: 10px; max-width: 460px; }
.upd-install .btn { justify-self: start; }
.upd-cancel { margin-top: 8px; }
.upd-upload { display: grid; gap: 12px; }
.upd-upload .btn { justify-self: start; }
.upd-drop { position: relative; display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 24px 16px; border: 2px dashed var(--line); border-radius: var(--r, 14px); text-align: center; cursor: pointer; transition: border-color .15s, background .15s; }
.upd-drop:hover, .upd-drop:focus-within { border-color: var(--primary); background: color-mix(in srgb, var(--primary) 5%, transparent); }
.upd-drop > .i { width: 30px; height: 30px; color: var(--primary-ink); }
.upd-drop input[type=file] { position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%; }
.upd-file { font-weight: 700; color: var(--text); min-height: 1em; overflow-wrap: anywhere; }
.upd-secure { margin-top: 16px; padding: 12px 14px; border-radius: var(--r-sm, 10px); background: var(--bg); }
.upd-secure h3 { font-size: 14px; margin: 0 0 6px; display: flex; gap: 6px; align-items: center; }
.upd-secure ul { margin: 0; padding-left: 18px; display: grid; gap: 4px; }
.upd-bk .row { flex-wrap: wrap; }
@media (max-width: 600px) {
  .upd-bk .row-main { flex: 1 1 calc(100% - 56px); }
  .upd-bk .row > .btn { margin-left: 52px; }
}
.upd-bk form { margin: 0; }
.upd-manual { margin-top: 12px; }
.upd-manual summary { cursor: pointer; color: var(--primary-ink); font-weight: 600; }
.upd-manual form { display: grid; gap: 8px; max-width: 360px; margin-top: 8px; }
.upd-manual .btn { justify-self: start; }
.upd-mode { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; border: 1px solid var(--line); border-radius: var(--r-sm, 10px); margin-bottom: 8px; cursor: pointer; font-size: 14px; line-height: 1.35; }
.upd-mode input { flex: none; margin-top: 2px; width: 18px; height: 18px; accent-color: var(--primary); }
.upd-mode:has(input:checked) { border-color: var(--primary); background: color-mix(in srgb, var(--primary) 5%, transparent); }
.upd-ver { font-size: 30px; font-weight: 800; letter-spacing: -.02em; }
.upd-req { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.upd-req li { display: flex; gap: 8px; align-items: flex-start; font-size: 14px; }
.upd-req li .i { margin-top: 3px; flex: none; }
.upd-req li.ok > .i { color: #16a34a; }
.upd-req li.ko > .i { color: var(--red); }
.upd-key { display: block; font-size: 12px; padding: 6px 8px; margin-top: 6px; border-radius: 8px; background: var(--bg); overflow-wrap: anywhere; }
a.card.upd-link { display: flex; flex-direction: row; gap: 12px; align-items: center; text-align: left; margin-bottom: 16px; color: inherit; text-decoration: none; }
.upd-link > span:nth-child(2) { flex: 1; min-width: 0; }
.upd-link:hover { border-color: var(--primary); }
.upd-req li.warn > .i { color: #d97706; }

/* ---------- Administration : navigation par rubriques, tableau de bord, journal des versions ---------- */
.admin-groups { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 12px; }
.admin-groups .tab { position: relative; }
.admin-sub { display: flex; gap: 4px; flex-wrap: wrap; margin: 0 0 20px; padding: 4px; border-radius: 12px; background: var(--card, #fff); border: 1px solid var(--line); width: fit-content; max-width: 100%; }
.admin-sub a { display: inline-flex; align-items: center; gap: 6px; padding: 7px 12px; border-radius: 9px; font-size: 14px; font-weight: 600; color: var(--muted); text-decoration: none; }
.admin-sub a:hover { color: var(--text); background: var(--bg); }
.admin-sub a.active { color: var(--on-primary); background: var(--primary); }
.admin-sub a .i { width: 16px; height: 16px; }
.sub-dot { background: var(--red); color: #fff; font-size: 10px; border-radius: 99px; padding: 1px 6px; margin-left: 2px; }
.admin-sub a.active .sub-dot { background: #fff; color: var(--red); }
.cl-older-h { font-size: 16px; margin: 22px 0 10px; }
.cl-older { display: grid; gap: 6px; }
.cl-fold { background: var(--card, #fff); border: 1px solid var(--line); border-radius: 12px; }
.cl-fold summary { display: flex; gap: 12px; align-items: baseline; padding: 10px 14px; cursor: pointer; }
.cl-fold-n { margin-left: auto; }
.cl-ver-s { font-weight: 800; color: var(--heading); }
.cl-fold .cl-entry { margin: 0; border: 0; box-shadow: none; border-top: 1px solid var(--line); border-radius: 0 0 12px 12px; }
.adm-narrow { max-width: 860px; }
.adm-wide { max-width: 1040px; }
.hl-row { align-items: center; }
.hl-go { flex: none; white-space: nowrap; }
.adm-todo .row { color: inherit; text-decoration: none; }
.adm-todo-ic { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; flex: none; }
.adm-todo-ic.t-red { background: #fde8ea; color: #dc2626; } .adm-todo-ic.t-orange { background: #fff1e0; color: #d97706; }
.adm-todo-ic.t-blue { background: #e6efff; color: #2563eb; } .adm-todo-ic.t-violet { background: #f1eafe; color: #7c3aed; } .adm-todo-ic.t-green { background: #e3f6ea; color: #16a34a; }
.adm-todo-ok { display: flex; gap: 8px; align-items: center; color: #16a34a; font-weight: 600; margin: 0; }
.adm-ver-h { display: flex; gap: 10px; align-items: baseline; flex-wrap: wrap; margin-bottom: 6px; }
.adm-ver-list { margin: 0 0 12px; padding-left: 18px; display: grid; gap: 4px; font-size: 14px; line-height: 1.45; }
.set-links .row { color: inherit; text-decoration: none; }
.st-toc { display: flex; gap: 6px; flex-wrap: wrap; margin: 0 0 14px; }
.st-toc a { font-size: 13px; font-weight: 600; padding: 5px 10px; border-radius: 99px; border: 1px solid var(--line); color: var(--muted); text-decoration: none; background: var(--card, #fff); }
.st-toc a:hover { color: var(--primary-ink); border-color: var(--primary); }
.st-h, #st-freq, #st-trend { scroll-margin-top: 16px; }
.sec-sum { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.sec-sum-i { display: flex; flex-direction: column; gap: 2px; padding: 10px 12px; border-radius: 10px; background: var(--bg); color: inherit; text-decoration: none; }
.sec-sum-i strong { font-size: 22px; }
.sec-sum-i .t-green { color: #16a34a; } .sec-sum-i .t-red { color: #dc2626; } .sec-sum-i .t-orange { color: #d97706; } .sec-sum-i .t-blue { color: #2563eb; } .sec-sum-i .t-gray { color: var(--muted); }
@media (max-width: 700px) { .hl-row { flex-wrap: wrap; } .hl-go { margin-left: 34px; } .admin-sub { width: 100%; } }
.upd-cfg { margin: 4px 0 6px; align-items: flex-start; }

/* ================= Pages publiques : présentation (v1.15) ================= */
body.pub { font-family: Inter, system-ui, -apple-system, "Segoe UI", sans-serif; background: var(--card); color: var(--text); font-size: 15.5px; line-height: 1.55; }
body.pub .logo strong { font-size: 24px; font-weight: 700; letter-spacing: -.02em; }
body.pub .logo img, body.pub .logo .logo-mark { width: 40px; height: 40px; }
body.pub .logo strong { font-family: Inter, system-ui, sans-serif; letter-spacing: -0.04em; }
body.pub .logo small { font-size: 12px; }
.pub-nav { gap: 24px; padding-top: 12px; padding-bottom: 12px; background: rgba(255, 255, 255, .94); border-bottom: 1px solid var(--line); }
.pub-links { gap: 26px; margin-left: 28px; }
.pub-links a { font-weight: 500; font-size: 15px; color: #334155; border-bottom: 0; }
.pub-links a:hover { color: var(--text); }
.pub-cta { align-items: center; gap: 10px; }
.pub-cta .btn { border-radius: 8px; box-shadow: none; font-weight: 600; }
body.pub .btn-primary { box-shadow: none; }
body.pub .btn-lg { border-radius: 10px; padding: 13px 22px; font-size: 16px; font-weight: 600; }
body.pub .btn-ghost { background: var(--card); border: 1px solid #cbd5e1; color: var(--text); }
body.pub .btn-ghost:hover { border-color: #94a3b8; background: #f8fafc; }

.lp-wrap { max-width: 1200px; margin: 0 auto; padding: 0 24px; }
.lp-kicker { font-size: 13px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--primary-ink); margin: 0 0 12px; }
.lp h1, .lp h2, .lp h3 { font-family: inherit; color: var(--text); }
.lp-sec { padding: 96px 0; }
.lp-sec-alt { background: #f7f8fa; border-top: 1px solid var(--line-2); border-bottom: 1px solid var(--line-2); }
.lp-head { max-width: 720px; margin: 0 0 48px; }
.lp-head h2, .lp-sec h2 { font-size: clamp(28px, 3.4vw, 40px); line-height: 1.15; font-weight: 700; letter-spacing: -.025em; margin: 0 0 14px; }
.lp-head p { font-size: 17px; color: #475569; margin: 0; }
.lp-fine { font-size: 14px; color: #64748b; margin: 14px 0 0; }
.lp-link { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; color: var(--primary-ink); }
.lp-link:hover { text-decoration: underline; }
.lp-center { text-align: center; margin-top: 12px; }
.lp-checks { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.lp-checks li { display: flex; gap: 10px; align-items: flex-start; color: #334155; }
.lp-checks .i { width: 18px; height: 18px; flex: none; margin-top: 3px; color: var(--primary-ink); }

/* Bandeau d'ouverture */
.lp-hero { padding: 72px 0 80px; background: linear-gradient(180deg, #f5f8fc 0%, var(--card) 100%); overflow: hidden; }
.lp-hero-in { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: 56px; align-items: center; }
.lp-hero h1 { font-size: clamp(34px, 3.9vw, 50px); line-height: 1.08; font-weight: 800; letter-spacing: -.035em; margin: 0 0 20px; }
.lp-lead { font-size: 18.5px; line-height: 1.6; color: #475569; margin: 0 0 30px; max-width: 560px; }
.lp-cta { display: flex; gap: 12px; flex-wrap: wrap; }
.lp-hero-media { position: relative; padding-bottom: 28px; }
.lp-hero-media .lp-window { transform: translateX(4%); width: 112%; max-width: none; }
.lp-hero-photo { display: block; width: 100%; aspect-ratio: 5 / 4; object-fit: cover; border-radius: 16px; box-shadow: 0 30px 60px -20px rgba(15, 23, 42, .35); }
.lp-hero-phone { position: absolute; left: -6%; bottom: 0; width: 26%; min-width: 120px; }
.lp-window { border-radius: 12px; overflow: hidden; background: var(--card); border: 1px solid #dfe4ec; box-shadow: 0 1px 2px rgba(15, 23, 42, .06), 0 24px 60px -18px rgba(15, 23, 42, .28); }
.lp-window-bar { display: flex; gap: 6px; padding: 9px 12px; background: #f1f3f6; border-bottom: 1px solid #e3e7ed; }
.lp-window-bar i { width: 10px; height: 10px; border-radius: 50%; background: #d4d9e1; }
.lp-window img, .lp-phone img { display: block; width: 100%; height: auto; }
.lp-phone { padding: 6px; border-radius: 30px; background: #0f172a; box-shadow: 0 24px 50px -14px rgba(15, 23, 42, .5); }
.lp-phone img { border-radius: 24px; }

/* Chiffres clés */
.lp-facts { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); background: var(--card); }
.lp-facts-in { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.lp-facts-in > div { padding: 28px 24px; border-left: 1px solid var(--line); }
.lp-facts-in > div:first-child { border-left: 0; padding-left: 0; }
.lp-facts strong { display: block; font-size: 26px; font-weight: 700; letter-spacing: -.02em; color: var(--text); }
.lp-facts span { font-size: 14px; color: #64748b; }

/* Fonctionnalités : rangées alternées */
.lp-rows { display: grid; gap: 112px; }
.lp-row { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 64px; align-items: center; }
.lp-row.is-rev .lp-row-txt { order: 2; }
.lp-row-txt h3 { font-size: clamp(24px, 2.6vw, 32px); line-height: 1.2; font-weight: 700; letter-spacing: -.02em; margin: 0 0 14px; }
.lp-row-txt > p { font-size: 17px; color: #475569; margin: 0 0 22px; }
.lp-eyebrow { display: flex; align-items: center; gap: 10px; font-size: 14px; font-weight: 600; color: var(--mc); margin: 0 0 14px; }
.lp-dot { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 8px; background: color-mix(in srgb, var(--mc) 12%, transparent); }
.lp-dot .i { width: 18px; height: 18px; }
.lp-row .lp-checks .i { color: var(--mc); }

/* Tous les modules */
.lp-mods { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.lp-mods li { display: flex; gap: 14px; align-items: flex-start; padding: 20px; background: var(--card); border: 1px solid var(--line); border-radius: 10px; }
.lp-mi { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 9px; flex: none; color: var(--mc); background: color-mix(in srgb, var(--mc) 10%, transparent); }
.lp-mi .i { width: 20px; height: 20px; }
.lp-mods strong { display: block; font-size: 15.5px; font-weight: 600; color: var(--text); }
.lp-mods small { display: block; font-size: 14px; color: #64748b; line-height: 1.45; margin-top: 2px; }
.lp-soon { font-style: normal; font-size: 11px; font-weight: 600; padding: 1px 6px; border-radius: 4px; background: #f1f5f9; color: #475569; margin-left: 4px; vertical-align: 2px; }

/* Pour qui */
.lp-who { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; }
.lp-who article { border: 1px solid var(--line); border-radius: 12px; overflow: hidden; background: var(--card); display: flex; flex-direction: column; }
.lp-who article > div { padding: 22px; }
.lp-who-photo { display: block; width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.lp-who-ic { display: grid; place-items: center; width: 40px; height: 40px; margin: 22px 22px 0; border-radius: 9px; background: var(--primary-soft); color: var(--primary-ink); }
.lp-who-ic .i { width: 20px; height: 20px; }
.lp-who h3 { font-size: 17px; font-weight: 600; margin: 0 0 8px; }
.lp-who p { font-size: 14.5px; color: #475569; margin: 0; }

/* Démarrage */
.lp-steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 40px; counter-reset: none; }
.lp-steps li { border-top: 2px solid var(--text); padding-top: 22px; }
.lp-step-n { display: block; font-size: 14px; font-weight: 700; color: var(--primary-ink); margin-bottom: 10px; font-variant-numeric: tabular-nums; }
.lp-steps h3 { font-size: 19px; font-weight: 600; margin: 0 0 8px; }
.lp-steps p { color: #475569; margin: 0; }

/* Confidentialité */
.lp-trust { background: #0f172a; color: #cbd5e1; }
.lp-trust-in { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 64px; align-items: start; }
.lp-trust .lp-kicker { color: #93c5fd; }
.lp-trust h2 { color: #fff; }
.lp-trust-txt > p { font-size: 17px; color: #cbd5e1; margin: 0 0 20px; }
.lp-trust .lp-link { color: #93c5fd; }
.lp-trust-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 36px 40px; }
.lp-trust-list li { display: flex; gap: 14px; }
.lp-trust-list li > .i { width: 22px; height: 22px; flex: none; color: #93c5fd; margin-top: 2px; }
.lp-trust-list h3 { color: #fff; font-size: 16.5px; font-weight: 600; margin: 0 0 6px; }
.lp-trust-list p { font-size: 14.5px; color: #94a3b8; margin: 0; line-height: 1.6; }

/* Témoignages */
.lp-testi { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); gap: 20px; }
.lp-quote { margin: 0; padding: 26px; border: 1px solid var(--line); border-radius: 12px; background: var(--card); display: flex; flex-direction: column; gap: 16px; }
.lp-stars { color: #f59e0b; letter-spacing: 2px; font-size: 15px; }
.lp-stars span { color: #e2e8f0; }
.lp-quote blockquote { margin: 0; font-size: 16px; line-height: 1.65; color: #1e293b; flex: 1; }
.lp-quote figcaption { display: flex; gap: 12px; align-items: center; }
.lp-quote figcaption strong { display: block; font-size: 15px; }
.lp-quote figcaption small { color: #64748b; font-size: 13.5px; }
.lp-av { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: #e2e8f0; color: #334155; font-weight: 700; }

/* Formules */
.lp-prices { display: grid; grid-template-columns: repeat(2, minmax(0, 380px)); gap: 24px; }
.lp-price { position: relative; padding: 30px; border: 1px solid var(--line); border-radius: 14px; background: var(--card); display: flex; flex-direction: column; }
.lp-price.is-hot { border: 2px solid var(--primary); }
.lp-price-tag { position: absolute; top: -12px; left: 28px; padding: 3px 10px; border-radius: 6px; background: var(--primary); color: var(--on-primary); font-size: 12px; font-weight: 600; }
.lp-price h3 { font-size: 18px; font-weight: 600; margin: 0; }
.lp-amount { display: flex; align-items: baseline; gap: 8px; margin: 12px 0 4px; }
.lp-amount strong { font-size: 40px; font-weight: 700; letter-spacing: -.03em; }
.lp-amount span { color: #64748b; }
.lp-price-alt { font-size: 14px; color: #475569; margin: 0; }
.lp-save { display: inline-block; padding: 1px 7px; border-radius: 4px; background: #dcfce7; color: #15803d; font-size: 12px; font-weight: 700; }
.lp-price .lp-checks { margin: 22px 0 26px; flex: 1; align-content: start; }
.lp-price .lp-checks li.no { color: #94a3b8; }
.lp-price-note { display: flex; gap: 6px; align-items: center; justify-content: center; font-size: 12.5px; color: #64748b; margin: 12px 0 0; }

/* Application mobile */
.lp-app { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 64px; align-items: center; }
.lp-app-phones { position: relative; display: flex; justify-content: center; gap: 0; padding: 10px 0 30px; }
.lp-app-phones .lp-phone { width: 44%; max-width: 250px; }
.lp-app-p1 { transform: translateY(30px) rotate(-2deg); margin-right: -4%; z-index: 1; }
.lp-app-p2 { transform: rotate(2deg); }
.lp-app-txt > p { font-size: 17px; color: #475569; margin: 0 0 20px; }
.lp-app-act { display: flex; align-items: center; gap: 24px; margin-top: 28px; flex-wrap: wrap; }
.lp-qr { display: flex; align-items: center; gap: 14px; }
.lp-qr .qr-box { width: 112px; height: 112px; margin: 0; border-radius: 10px; padding: 6px; box-shadow: none; border: 1px solid var(--line); }
.lp-qr p { font-size: 13.5px; color: #64748b; max-width: 180px; margin: 0; }

/* Inscription */
.lp-join-in { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 440px); gap: 64px; align-items: center; }
.lp-join-txt h2 { margin-bottom: 24px; }
.lp-join-shot { margin-top: 36px; }
.lp-cta-photo { display: block; width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 14px; margin-bottom: 30px; }
.lp-join-card { padding: 32px; border: 1px solid var(--line); border-radius: 14px; background: var(--card); box-shadow: 0 24px 60px -24px rgba(15, 23, 42, .25); }
.lp-join-card h3 { font-size: 22px; font-weight: 700; margin: 0; }
.lp-join-card .lp-fine { margin: 6px 0 20px; }
.lp-join-card .f > span:first-child { font-weight: 600; font-size: 14px; }
.lp-join-card .btn-lg { margin-top: 6px; }

/* FAQ */
.lp-faq { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: 64px; align-items: start; }
.lp-faq-head p { color: #475569; }
.lp-faq-list details { border-bottom: 1px solid #dfe4ec; }
.lp-faq-list details:first-child { border-top: 1px solid #dfe4ec; }
.lp-faq-list summary { list-style: none; display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 20px 0; font-weight: 600; font-size: 16px; cursor: pointer; color: var(--text); }
.lp-faq-list summary::-webkit-details-marker { display: none; }
.lp-faq-list summary .i { flex: none; color: #64748b; transition: transform .2s; }
.lp-faq-list details[open] summary .i { transform: rotate(45deg); color: var(--text); }
.lp-faq-list details p { margin: -6px 0 20px; color: #475569; line-height: 1.65; max-width: 680px; }

/* Pied de page */
.pub-foot { background: #f7f8fa; border-top: 1px solid var(--line); padding: 56px max(24px, calc((100vw - 1152px) / 2)) 28px; }
.pf-in { display: grid; grid-template-columns: minmax(0, 2fr) repeat(3, minmax(0, 1fr)); gap: 40px; }
.pf-brand p { color: #64748b; font-size: 14.5px; max-width: 340px; margin: 14px 0 0; }
.pf-col { display: flex; flex-direction: column; gap: 10px; }
.pf-col h3 { font-size: 13px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--text); margin: 0 0 4px; }
.pf-col a { color: #475569; font-size: 14.5px; }
.pf-col a:hover { color: var(--text); }
.pf-bottom { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-top: 44px; padding-top: 22px; border-top: 1px solid var(--line); font-size: 13.5px; color: #64748b; }
.pf-bottom span { display: inline-flex; gap: 6px; align-items: center; }

@media (max-width: 1100px) {
  .pub-links { display: none; }
  .lp-mods { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .lp-who { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
  .lp-sec { padding: 64px 0; }
  .lp-hero { padding: 40px 0 48px; }
  .lp-hero-in, .lp-row, .lp-trust-in, .lp-app, .lp-join-in, .lp-faq { grid-template-columns: 1fr; gap: 36px; }
  .lp-hero-media .lp-window { transform: none; width: 100%; }
  .lp-hero-phone { left: auto; right: 4%; width: 28%; }
  .lp-row.is-rev .lp-row-txt { order: 0; }
  .lp-rows { gap: 72px; }
  .lp-facts-in { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .lp-facts-in > div:nth-child(odd) { border-left: 0; padding-left: 0; }
  .lp-facts-in > div:nth-child(n+3) { border-top: 1px solid var(--line); }
  .lp-steps { grid-template-columns: 1fr; gap: 28px; }
  .lp-app-phones { order: 2; }
  .lp-prices { grid-template-columns: minmax(0, 1fr); }
  .pf-in { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pf-brand { grid-column: 1 / -1; }
}
@media (max-width: 600px) {
  .lp-wrap { padding: 0 16px; }
  .pub-nav .pub-login { display: none; }
  .pub-nav .pub-cta .btn-primary { display: inline-flex; padding: 8px 12px; font-size: 14px; }
  .lp-mods li { padding: 14px 16px; }
  .lp-mods, .lp-who, .lp-trust-list { grid-template-columns: 1fr; }
  .lp-cta .btn { width: 100%; justify-content: center; }
  .lp-hero h1 { font-size: 34px; }
  .lp-lead { font-size: 17px; }
  .lp-head { margin-bottom: 32px; }
  .lp-join-card { padding: 22px; }
  .lp-qr { display: none; }
  .lp-facts strong { font-size: 21px; }
  .lp-facts-in > div { padding: 20px 12px; }
}

/* ================= Module Activités & Sport (v1.16) ================= */
.act-av { display: inline-grid; place-items: center; flex: none; border-radius: 12px; background: color-mix(in srgb, var(--c) 14%, #fff); border: 1.5px solid color-mix(in srgb, var(--c) 40%, #fff); line-height: 1; }
.act-av-sm { width: 34px; height: 34px; font-size: 18px; border-radius: 10px; }
.act-av-md { width: 42px; height: 42px; font-size: 22px; }
.act-av-xl { width: 72px; height: 72px; font-size: 38px; border-radius: 18px; border-width: 2px; }
.act-top { display: flex; gap: 12px; align-items: center; justify-content: space-between; flex-wrap: wrap; margin-bottom: 16px; }
.act-tabs { flex-wrap: wrap; max-width: 100%; }
.act-tabs a { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; }
.act-renew { margin-bottom: 18px; border-left: 4px solid #059669; }
.act-renew-h { display: flex; gap: 12px; align-items: flex-start; margin-bottom: 8px; }
.act-renew-h > .i { color: #059669; width: 22px; height: 22px; flex: none; margin-top: 2px; }
.act-week-h { flex-wrap: wrap; }
.act-week-nav { display: inline-flex; align-items: center; gap: 6px; margin-left: auto; }
.act-who { margin: -4px 0 8px; }
.act-who .chip-pick.on { background: var(--primary-soft); color: var(--primary-d); border-color: var(--primary); }
.act-day { padding: 12px 0; border-top: 1px solid var(--line-2); }
.act-day:first-of-type { border-top: 0; }
.act-day h3 { font-size: 14.5px; font-weight: 700; margin: 0 0 8px; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; color: var(--text); }
.act-day.is-past { opacity: .6; }
.act-day.is-today h3 { color: #047857; }
.act-none { margin: 0; }
.act-slot { display: flex; gap: 12px; align-items: flex-start; padding: 10px 12px; border: 1px solid var(--line); border-radius: 12px; background: var(--card); margin-bottom: 8px; }
.act-slot.is-event { border-color: color-mix(in srgb, #d97706 35%, var(--line)); background: color-mix(in srgb, #d97706 4%, var(--card)); }
.act-slot.is-skip { opacity: .65; }
.act-slot.is-skip .row-title { text-decoration: line-through; }
.act-time { flex: none; width: 46px; font-weight: 800; font-variant-numeric: tabular-nums; font-size: 15px; line-height: 1.2; padding-top: 2px; }
.act-time small { display: block; font-weight: 600; font-size: 12px; color: var(--muted); }
.act-slot-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.act-slot .actions { flex: none; }
.act-line { display: flex; flex-wrap: wrap; gap: 6px 10px; align-items: center; font-size: 13px; color: #44546d; }
.act-line .i { width: 14px; height: 14px; }
.act-link { font-size: 12.5px; font-weight: 700; color: var(--primary-ink); }
.act-home { display: inline-flex; align-items: center; gap: 4px; padding: 1px 8px; border-radius: 999px; font-size: 12px; font-weight: 700; background: color-mix(in srgb, var(--c) 14%, #fff); color: color-mix(in srgb, var(--c) 80%, #000); }
.act-bag { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-top: 4px; }
.act-bag-h { display: inline-flex; align-items: center; gap: 4px; font-size: 12.5px; font-weight: 700; color: #0e7490; }
.act-bag-it { position: relative; display: inline-flex; cursor: pointer; }
.act-bag-it input { position: absolute; opacity: 0; pointer-events: none; }
.act-bag-it span { display: inline-block; padding: 3px 10px; border-radius: 999px; font-size: 12.5px; font-weight: 600; border: 1px solid var(--line); background: var(--card); color: #44546d; }
.act-bag-it input:checked + span { background: #ecfdf5; border-color: #6ee7b7; color: #047857; text-decoration: line-through; }
.act-bag-it input:focus-visible + span { outline: 2px solid var(--primary); outline-offset: 1px; }
.act-bag-it input:disabled + span { cursor: default; }
.act-cards { align-items: start; }
.act-card { border-top: 4px solid var(--c); display: flex; flex-direction: column; gap: 6px; scroll-margin-top: 80px; }
.act-card-top { display: flex; gap: 14px; align-items: center; }
.act-card-top h2 { font-size: 21px; }
.act-meta { color: #44546d; font-size: 14px; }
.act-meta.small { font-size: 12.5px; color: var(--muted); }
.act-lines .info-line { padding: 6px 0; }
.act-slot-line { display: flex; gap: 8px; align-items: baseline; flex-wrap: wrap; }
.act-papers { flex: 1; min-width: 0; }
.act-paper { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 3px 0; font-size: 13.5px; }
.act-notes { color: #44546d; background: var(--line-2); border-radius: 10px; padding: 8px 10px; }
.act-docs { margin-top: 6px; padding-top: 8px; border-top: 1px dashed var(--line); }
.act-docs strong { display: flex; align-items: center; gap: 6px; }
.act-doc-add summary { list-style: none; cursor: pointer; display: inline-flex; align-items: center; gap: 4px; margin-top: 4px; }
.act-doc-add summary::-webkit-details-marker { display: none; }
.act-doc-form { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-top: 8px; }
.act-doc-form input[type=file] { flex: 1 1 180px; font-size: 13px; }
.act-foot { display: flex; gap: 8px; flex-wrap: wrap; margin-top: auto; padding-top: 10px; border-top: 1px solid var(--line-2); }
.act-gone { margin-top: 18px; }
.act-timeline { list-style: none; margin: 0; padding: 0 0 0 4px; }
.act-timeline li { position: relative; display: flex; gap: 12px; align-items: flex-start; padding: 8px 0 12px 0; }
.act-timeline li::before { content: ""; position: absolute; left: 15px; top: 40px; bottom: -4px; width: 2px; background: color-mix(in srgb, var(--c) 25%, transparent); }
.act-timeline li:last-child::before { display: none; }
.act-tl-ic { flex: none; display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; background: color-mix(in srgb, var(--c) 14%, #fff); color: var(--c); }
.act-tl-ic .i { width: 17px; height: 17px; }
.act-tl-main { flex: 1; min-width: 0; }
.act-tl-photo img { width: 64px; height: 64px; object-fit: cover; border-radius: 10px; display: block; }
.act-buy { background: color-mix(in srgb, #f97316 6%, transparent); border-radius: 10px; }
.act-buy-t { position: relative; display: inline-flex; cursor: pointer; flex: none; }
.act-buy-t input { position: absolute; opacity: 0; pointer-events: none; }
.act-buy-t span { padding: 3px 10px; border-radius: 999px; font-size: 12px; font-weight: 700; border: 1px solid var(--line); color: var(--muted); }
.act-buy-t input:checked + span { background: #fff7ed; border-color: #fdba74; color: #c2410c; }
.act-buy-t input:focus-visible + span { outline: 2px solid var(--primary); outline-offset: 1px; }
.act-bag-list { padding: 8px 0; border-top: 1px solid var(--line-2); }
.act-bag-list:first-of-type { border-top: 0; }
.act-bag-list strong { display: flex; align-items: center; gap: 8px; font-size: 14px; }
.act-bag-list ul { margin: 6px 0 0 42px; padding: 0; font-size: 13.5px; color: #44546d; }
.act-amount { font-variant-numeric: tabular-nums; flex: none; }
.act-total { font-size: 32px; font-weight: 800; letter-spacing: -.02em; margin: 0 0 10px; }
.act-bar { height: 6px; border-radius: 3px; background: var(--line-2); overflow: hidden; margin-top: 6px; }
.act-bar i { display: block; height: 100%; border-radius: 3px; }
.act-quick { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 10px; }
.act-walk i { background: #0891b2; }
.act-occ.is-skip .row-title { text-decoration: line-through; }
@media (max-width: 900px) {
  .act-top { flex-direction: column; align-items: stretch; }
  .act-tabs { overflow-x: auto; flex-wrap: nowrap; scrollbar-width: none; }
  .act-tabs::-webkit-scrollbar { display: none; }
}
@media (max-width: 600px) {
  .act-slot { padding: 10px; gap: 10px; }
  .act-slot .act-av-md { display: none; }
  .act-time { width: 42px; font-size: 14px; }
}

/* Calendrier : répétition des événements (v1.17) */
.ev .i-tiny, .ev-chip .i-tiny { vertical-align: -1px; opacity: .8; }

/* ---------- Module Dossiers & Litiges ---------- */
.dos-top { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-bottom: 14px; }
.dos-top .btn-primary { margin-left: auto; }
.dos-filters { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.dos-filters select { width: auto; flex: 0 1 auto; height: 38px; border-radius: 10px; border: 1px solid var(--line); background: var(--card); padding: 0 10px; font: inherit; font-size: 14px; }
.dos-search { min-width: 190px; flex: 0 1 220px; }
.dos-search input { height: 38px; }
.dos-n { display: inline-block; min-width: 18px; padding: 0 5px; border-radius: 9px; background: rgba(15, 35, 66, .07); font-size: 11.5px; font-weight: 800; text-align: center; color: inherit; }
.dos-list { display: flex; flex-direction: column; }
.dos-item { display: flex; gap: 14px; align-items: center; padding: 14px 6px; border-bottom: 1px solid var(--line-2); color: inherit; text-decoration: none; border-radius: 10px; transition: background .12s; }
.dos-item:last-child { border-bottom: 0; }
.dos-item:hover { background: color-mix(in srgb, var(--primary) 4%, transparent); }
.dos-item > .i { color: var(--muted); flex: none; }
.dos-item.closed { opacity: .72; }
.dos-item.urgent { box-shadow: inset 3px 0 0 #dc2626; }
.dos-item-main { flex: 1; min-width: 0; }
.dos-item-t { font-weight: 800; font-size: 15px; line-height: 1.3; }
.dos-flag { color: #dc2626; margin-right: 4px; }
.dos-item-m { color: var(--muted); font-size: 13px; margin-top: 1px; }
.dos-item-s { display: flex; flex-wrap: wrap; gap: 6px 12px; align-items: center; margin-top: 7px; font-size: 12.5px; }
.dos-silence { color: #b45309; font-weight: 700; display: inline-flex; align-items: center; gap: 4px; }
.dos-next, .dos-dl, .dos-await { display: inline-flex; align-items: center; gap: 5px; font-weight: 700; }
.dos-got { color: #15803d; font-weight: 800; }
.t-red { color: #be123c; } .t-orange { color: #c2410c; } .t-yellow { color: #a16207; } .t-gray { color: var(--muted); }
.dos-side { display: flex; flex-direction: column; gap: 16px; }
.dos-side .card { margin: 0; }
.dos-due { color: inherit; text-decoration: none; }
.dos-due-d { flex: none; width: 44px; text-align: center; border-radius: 10px; padding: 4px 0; background: rgba(15, 35, 66, .05); font-size: 11px; font-weight: 700; text-transform: uppercase; line-height: 1.1; }
.dos-due-d b { display: block; font-size: 18px; }
.dos-due-d.t-red { background: var(--red-soft); } .dos-due-d.t-orange { background: var(--orange-soft); }
.dos-kpis { display: grid; gap: 10px; }
.dos-kpis > div, .dos-figs > div, .dos-syn > div { display: flex; flex-direction: column; }
.dos-kpis small, .dos-figs small, .dos-syn small { color: var(--muted); font-weight: 700; font-size: 12px; }
.dos-kpis strong { font-size: 22px; font-weight: 800; }
.dos-kpis strong small, .dos-figs strong small { font-size: 12.5px; color: var(--muted); font-weight: 600; }
.dos-empty .empty p { max-width: 520px; }
.dos-ideas { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 12px; margin-top: 8px; }
.dos-idea { display: flex; gap: 12px; align-items: flex-start; padding: 12px; border: 1px solid var(--line); border-radius: 14px; }
.dos-idea strong { display: block; font-size: 14px; }
.dos-idea span { color: var(--muted); font-size: 13px; }
.dos-back { display: inline-flex; align-items: center; gap: 4px; font-weight: 700; font-size: 13.5px; margin-bottom: 10px; color: var(--muted); }
.dos-head { border-top: 4px solid var(--c); }
.dos-head-top { display: flex; gap: 16px; align-items: flex-start; flex-wrap: wrap; }
.dos-head-main { flex: 1; min-width: 240px; }
.dos-head-main h2 { margin: 6px 0 4px; font-size: 22px; line-height: 1.25; }
.dos-head-badges { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.dos-vis { display: inline-flex; gap: 4px; align-items: center; color: var(--muted); font-size: 12.5px; font-weight: 700; }
.dos-head-meta { display: flex; flex-wrap: wrap; gap: 4px 16px; color: var(--muted); font-size: 13px; align-items: center; }
.dos-head-meta b { color: var(--text, #0f172a); font-weight: 700; }
.dos-head-meta span { display: inline-flex; gap: 5px; align-items: center; }
.dos-head-act { display: flex; gap: 6px; flex-wrap: wrap; }
.dos-figs, .dos-syn { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--line-2); }
.dos-figs strong, .dos-syn strong { font-size: 20px; font-weight: 800; }
.pos { color: #15803d; } .neg { color: #be123c; }
.dos-deadlines { display: flex; flex-wrap: wrap; gap: 8px 18px; margin-top: 12px; font-size: 13px; align-items: center; }
.dos-dl-link { font-size: 13px; font-weight: 700; display: inline-flex; gap: 4px; align-items: center; }
.dos-suggest { display: flex; gap: 10px; align-items: flex-start; margin-top: 14px; padding: 10px 12px; border-radius: 12px; background: color-mix(in srgb, #f59e0b 12%, transparent); color: #78350f; font-size: 13.5px; }
.dos-suggest > .i { flex: none; color: #d97706; margin-top: 1px; }
.dos-suggest strong { display: block; }
.dos-tabs { margin: 16px 0 14px; flex-wrap: wrap; }
.dos-tabs a { display: inline-flex; align-items: center; gap: 5px; }
.dos-quick { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; padding-bottom: 12px; margin-bottom: 6px; border-bottom: 1px solid var(--line-2); }
.dos-chip { cursor: pointer; border: 1px solid var(--line); background: var(--card); display: inline-flex; gap: 5px; align-items: center; }
.dos-chip:hover { border-color: var(--primary); color: var(--primary-ink); }
.dos-tl { list-style: none; margin: 0; padding: 4px 0 0; }
.dos-tl li { position: relative; display: flex; gap: 14px; align-items: flex-start; padding: 10px 0 14px; }
.dos-tl li::before { content: ""; position: absolute; left: 17px; top: 46px; bottom: -6px; width: 2px; background: var(--line); }
.dos-tl li:last-child::before { display: none; }
.dos-tl-ic { flex: none; width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; background: color-mix(in srgb, #64748b 12%, #fff); color: #475569; }
.dos-tl li.dir-out .dos-tl-ic { background: color-mix(in srgb, #2563eb 13%, #fff); color: #2563eb; }
.dos-tl li.dir-in .dos-tl-ic { background: color-mix(in srgb, #059669 14%, #fff); color: #047857; }
.dos-tl li.auto .dos-tl-ic { width: 28px; height: 28px; margin: 4px; background: transparent; border: 2px solid var(--line); color: var(--muted); }
.dos-tl li.auto .dos-tl-ic .i { width: 14px; height: 14px; }
.dos-tl li.auto .dos-tl-t { font-weight: 600; color: var(--muted); font-size: 13.5px; }
.dos-tl-main { flex: 1; min-width: 0; }
.dos-tl-h { display: flex; flex-wrap: wrap; gap: 4px 10px; align-items: center; font-size: 12.5px; color: var(--muted); font-weight: 700; }
.dos-tl-k { text-transform: uppercase; letter-spacing: .03em; font-size: 11px; }
.dos-dir { font-weight: 800; }
.dos-dir.out { color: #2563eb; } .dos-dir.in { color: #047857; }
.dos-tl-t { font-weight: 800; font-size: 14.5px; margin-top: 2px; }
.dos-tl-b { margin: 4px 0 0; font-size: 13.5px; color: #33445f; white-space: normal; }
.dos-tl-files { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
.dos-await { margin-top: 6px; font-size: 12.5px; }
.dos-await.ok { color: #15803d; }
.dos-tl li .actions { display: flex; gap: 2px; opacity: .5; }
.dos-tl li:hover .actions { opacity: 1; }
.dos-h3 { font-size: 13px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); margin: 16px 0 4px; }
.dos-h3:first-child { margin-top: 0; }
.dos-upload { display: flex; flex-direction: column; gap: 10px; }
.dos-upload .dropzone { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 16px; border: 2px dashed var(--line); border-radius: 14px; text-align: center; font-size: 13px; color: var(--muted); cursor: pointer; }
.dos-upload .dropzone input { max-width: 100%; font-size: 12.5px; }
.dos-cmp-h { display: flex; gap: 12px; justify-content: space-between; align-items: flex-start; flex-wrap: wrap; margin-bottom: 10px; }
.dos-cmp-h h3 { margin: 0; font-size: 17px; }
.dos-cmp-h p { margin: 4px 0 0; max-width: 620px; }
.dos-cmp-act { display: flex; gap: 6px; }
.dos-cmp th, .dos-cmp td { text-align: center; min-width: 130px; }
.dos-cmp th:first-child, .dos-cmp td:first-child { text-align: left; min-width: 170px; position: sticky; left: 0; background: var(--card); z-index: 1; }
.dos-cmp th { vertical-align: top; white-space: normal; }
.dos-cmp th.best { background: color-mix(in srgb, #f59e0b 9%, transparent); }
.dos-cmp th.chosen, .dos-cmp td.chosen { background: color-mix(in srgb, #16a34a 9%, transparent); }
.dos-off-h { display: flex; flex-direction: column; align-items: center; gap: 3px; }
.dos-off-h > span:first-child { font-weight: 800; font-size: 14.5px; color: var(--text, #0f172a); }
.dos-off-h small { color: var(--muted); font-weight: 600; }
.dos-cmp td.top .dos-score { color: #15803d; }
.dos-score { font-weight: 800; font-size: 15px; }
.dos-score small { color: var(--muted); font-weight: 600; font-size: 11px; }
.dos-crit { display: inline-flex; gap: 4px; align-items: center; flex-wrap: wrap; }
.dos-crit .actions { display: inline-flex; opacity: .4; }
.dos-cmp tr:hover .dos-crit .actions { opacity: 1; }
.dos-auto { padding: 0 5px; border-radius: 6px; background: rgba(15, 35, 66, .06); font-size: 10.5px; font-weight: 700; color: var(--muted); }
.dos-total td { border-top: 2px solid var(--line); font-size: 15px; }
.dos-total td:not(:first-child) b { font-size: 18px; }
.dos-meter { display: block; height: 6px; border-radius: 3px; background: rgba(15, 35, 66, .08); margin: 0 auto 5px; max-width: 110px; overflow: hidden; }
.dos-meter i { display: block; height: 100%; background: linear-gradient(90deg, #f59e0b, #16a34a); border-radius: 3px; }
.dos-saving b { font-size: 15px; }
.dos-infos td { font-size: 12.5px; vertical-align: top; }
.d-b { display: block; }
.dos-offer-act td { white-space: nowrap; }
.icon-btn.sm { width: 28px; height: 28px; }
.icon-btn.sm .i { width: 15px; height: 15px; }
.dos-txt { font-size: 14px; color: #33445f; margin: 0; }
.dos-danger { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line-2); }
@media (max-width: 760px) {
  .dos-top .btn-primary { margin-left: 0; }
  .dos-filters { width: 100%; }
  .dos-filters select { flex: 1 1 calc(50% - 4px); min-width: 0; }
  .dos-search { flex: 1 1 100%; min-width: 0; }
  .dos-top .seg { width: 100%; justify-content: space-between; }
  .dos-top .seg a { padding: 7px 8px; font-size: 13.5px; }
  .dos-head-top > .ic-bubble { display: none; }
  .dos-head-main h2 { font-size: 19px; }
  .dos-figs, .dos-syn { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .dos-head-act { width: 100%; }
}


/* ---------- Fenêtre d'événement ---------- */
.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; }
#m-event { width: min(600px, calc(100vw - 24px)); }
#m-event .modal-body { padding-top: 4px; }
.ev-title { margin-bottom: 10px; }
.ev-title input { font-size: 18px; font-weight: 700; padding: 12px 14px; }
.ev-cats { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 6px; }
.ev-cat { position: relative; display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 999px; font-size: 13px; font-weight: 700; cursor: pointer; user-select: none;
  color: #475569; background: #f1f5f9; border: 1.5px solid transparent; transition: background .12s, color .12s, border-color .12s; }
.ev-cat .i { color: var(--c); width: 15px; height: 15px; }
.ev-cat input { position: absolute; opacity: 0; pointer-events: none; }
.ev-cat:hover { background: color-mix(in srgb, var(--c) 10%, #fff); }
.ev-cat:has(input:checked) { background: color-mix(in srgb, var(--c) 14%, #fff); color: color-mix(in srgb, var(--c) 75%, #0f172a); border-color: var(--c); }
.ev-cat:has(input:focus-visible) { outline: 2px solid var(--c); outline-offset: 2px; }
.ev-sec { padding: 14px 0 2px; border-top: 1px solid var(--line-2); margin-top: 12px; }
.ev-sec h4 { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin: 0 0 10px; font-size: 12.5px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); }
.ev-sec h4 .i { width: 15px; height: 15px; }
.ev-sec h4 small { text-transform: none; letter-spacing: 0; font-weight: 600; font-size: 12.5px; margin-left: 4px; opacity: .85; }
.ev-sec[data-members] .chips { margin-bottom: 12px; }
.ev-when { display: flex; flex-wrap: wrap; gap: 12px; }
.ev-when .ev-date { flex: 1 1 170px; max-width: 100%; }
.ev-times { flex: 2 1 260px; display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.ev-times[hidden] { display: none; }
.ev-toggles { display: flex; flex-wrap: wrap; gap: 8px; margin: -2px 0 12px; }
.ev-toggle { display: inline-flex; align-items: center; gap: 8px; padding: 7px 12px 7px 8px; border-radius: 10px; border: 1px solid var(--line); background: var(--card); font-size: 13.5px; font-weight: 600; cursor: pointer; user-select: none; }
.ev-toggle input { width: 30px; height: 18px; margin: 0; appearance: none; -webkit-appearance: none; border-radius: 9px; background: #cbd5e1; position: relative; cursor: pointer; transition: background .15s; flex: none; }
.ev-toggle input::after { content: ""; position: absolute; top: 2px; left: 2px; width: 14px; height: 14px; border-radius: 50%; background: #fff; box-shadow: 0 1px 2px rgba(0,0,0,.2); transition: transform .15s; }
.ev-toggle input:checked { background: var(--primary); }
.ev-toggle input:checked::after { transform: translateX(12px); }
.ev-toggle input:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }
.ev-toggle:has(input:checked) { border-color: var(--primary); color: var(--primary-d); background: var(--primary-soft); }
.ev-until { max-width: 260px; }
.ev-until[hidden] { display: none; }
.ev-rec-line { display: flex; flex-wrap: wrap; gap: 12px; align-items: flex-start; }
.ev-rec-line > .f, .ev-rec-line > div { flex: 1 1 180px; min-width: 0; }
.ev-rec-line > [hidden] { display: none; }
.ev-rec-line .input-unit input { max-width: 90px; }
.ev-days { gap: 6px; }
.ev-days .chip { width: 38px; height: 38px; padding: 0; justify-content: center; border-radius: 50%; }
.ev-scope { margin-top: 14px; background: var(--primary-soft); border-radius: 12px; padding: 12px 14px; }
.ev-scope > span { display: flex; align-items: center; gap: 6px; font-weight: 700; font-size: 13.5px; color: var(--primary-d); margin-bottom: 8px; }
.ev-scope .chip-pick { background: var(--card); }
.ev-del { margin-top: 12px; }
.ev-del .link-btn { color: #be123c; font-weight: 700; font-size: 13.5px; display: inline-flex; align-items: center; gap: 5px; }
@media (max-width: 560px) {
  .ev-when .ev-date { flex-basis: 100%; }
  .ev-until { max-width: none; }
}

/* ---------- Module Maison ---------- */
.hm-tabs { margin-bottom: 16px; flex-wrap: wrap; }
.hm-tabs a { display: inline-flex; align-items: center; gap: 5px; }
.hm-bar { display: flex; gap: 12px; align-items: center; justify-content: space-between; flex-wrap: wrap; margin-bottom: 14px; }
.hm-bar p { margin: 0; max-width: 640px; }
.hm-h3 { font-size: 12.5px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); margin: 16px 0 2px; }
.hm-kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 16px; }
.hm-kpi { display: flex; gap: 12px; align-items: flex-start; background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 14px; box-shadow: var(--shadow); color: inherit; text-decoration: none; min-width: 0; }
.hm-kpi:hover { border-color: color-mix(in srgb, var(--primary) 35%, var(--line)); }
.hm-kpi small { display: block; color: var(--muted); font-weight: 700; font-size: 12.5px; }
.hm-kpi strong { display: block; font-size: 24px; font-weight: 800; line-height: 1.2; }
.hm-kpi strong small { display: inline; font-size: 13px; }
.hm-kpi span { font-size: 12.5px; font-weight: 600; }
.hm-side { display: flex; flex-direction: column; gap: 16px; }
.hm-side .card { margin: 0; }
.hm-start h2 { margin: 0 0 4px; font-size: 20px; }
.hm-start-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin-top: 14px; }
.hm-start-item { display: flex; flex-direction: column; gap: 6px; align-items: flex-start; padding: 16px; border: 1px solid var(--line); border-radius: 16px; }
.hm-start-item span { color: var(--muted); font-size: 13.5px; flex: 1; }
.hm-mrow { gap: 12px; }
.hm-due { flex: none; width: 44px; text-align: center; border-radius: 10px; padding: 4px 0; background: rgba(15, 35, 66, .05); font-size: 11px; font-weight: 700; text-transform: uppercase; line-height: 1.1; }
.hm-due b { display: block; font-size: 17px; }
.hm-due.t-red { background: var(--red-soft); } .hm-due.t-orange { background: var(--orange-soft); } .hm-due.t-yellow { background: color-mix(in srgb, #f59e0b 14%, transparent); }
.hm-tag { display: inline-block; padding: 1px 7px; border-radius: 6px; background: var(--red-soft); color: #be123c; font-size: 11px; font-weight: 800; vertical-align: 1px; }
.hm-eq-top { display: flex; gap: 12px; align-items: flex-start; }
.hm-eq-top h3 { margin: 0; font-size: 17px; line-height: 1.3; }
.hm-eq.archived { opacity: .65; }
.hm-facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 14px; margin: 14px 0 6px; }
.hm-facts dt { font-size: 12px; color: var(--muted); font-weight: 700; }
.hm-facts dd { margin: 2px 0 0; font-size: 14px; font-weight: 600; }
.hm-eq-maint { margin-top: 6px; border-top: 1px solid var(--line-2); }
.hm-last, .hm-notes { margin: 8px 0 0; }
.hm-last { display: flex; gap: 5px; align-items: center; }
.hm-docs { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.hm-doc { display: inline-flex; align-items: center; gap: 2px; padding: 3px 4px 3px 10px; border-radius: 999px; background: var(--primary-soft); font-size: 12.5px; font-weight: 700; max-width: 100%; }
.hm-doc a { display: inline-flex; gap: 4px; align-items: center; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hm-eq-foot { display: flex; flex-wrap: wrap; gap: 6px; align-items: flex-start; margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line-2); }
.hm-up { position: relative; }
.hm-up summary { list-style: none; cursor: pointer; }
.hm-up summary::-webkit-details-marker { display: none; }
.hm-up-form { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; margin-top: 6px; font-size: 12.5px; }
.hm-up-form input[type=file] { max-width: 220px; font-size: 12.5px; }
.hm-cap { margin: 10px 0 0; display: flex; gap: 6px; align-items: flex-start; }
.hm-cost { white-space: nowrap; font-size: 14px; }
.hm-logs .row { align-items: flex-start; }
.hm-budget { margin: 14px 0 4px; }
.hm-budget-l { display: flex; justify-content: space-between; gap: 8px; font-size: 13.5px; margin-bottom: 6px; }
.hm-meter { height: 8px; border-radius: 4px; background: rgba(15, 35, 66, .08); overflow: hidden; }
.hm-meter i { display: block; height: 100%; border-radius: 4px; background: #7c3aed; }
.hm-meter.over i { background: #dc2626; }
.hm-steps { margin-top: 12px; display: flex; flex-direction: column; gap: 2px; }
.hm-steps > strong { margin-bottom: 4px; }
.hm-step { display: flex; align-items: center; gap: 10px; padding: 4px 0; font-size: 14px; cursor: pointer; }
.hm-step input { width: 17px; height: 17px; accent-color: #7c3aed; flex: none; }
.hm-step span { flex: 1; }
.hm-step.done span { text-decoration: line-through; color: var(--muted); }
.hm-step .icon-btn { opacity: 0; }
.hm-step:hover .icon-btn { opacity: .6; }
.hm-inline { display: flex; gap: 6px; align-items: center; margin: 6px 0 4px; }
.hm-inline input { flex: 1; min-width: 0; height: 36px; }
.hm-gar { margin-top: 12px; padding: 10px 12px; border-radius: 12px; background: color-mix(in srgb, #2563eb 6%, transparent); }
.hm-gar > strong { display: flex; gap: 5px; align-items: center; margin-bottom: 6px; }
.hm-gar-l { display: flex; justify-content: space-between; gap: 8px; align-items: center; font-size: 13.5px; padding: 3px 0; }
.hm-danger { color: #be123c; font-weight: 700; font-size: 13.5px; display: inline-flex; gap: 5px; align-items: center; margin-top: 6px; }
.hm-diy .card { margin: 0; }
.hm-job { cursor: pointer; }
.hm-job.done .row-title { text-decoration: line-through; color: var(--muted); }
.hm-supply textarea { font-size: 14px; }
.hm-meter-card { margin-bottom: 16px; }
.hm-meter-act { display: flex; gap: 2px; }
.hm-sync { font-size: 12.5px; font-weight: 700; display: inline-flex; gap: 4px; align-items: center; white-space: nowrap; margin-top: 4px; }
.hm-figs { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin: 16px 0 6px; padding: 12px 0; border-top: 1px solid var(--line-2); border-bottom: 1px solid var(--line-2); }
.hm-figs > div { display: flex; flex-direction: column; min-width: 0; }
.hm-figs small { color: var(--muted); font-weight: 700; font-size: 12px; }
.hm-figs strong { font-size: 21px; font-weight: 800; }
.hm-figs strong small { font-size: 12.5px; }
.hm-figs span { font-size: 12.5px; font-weight: 600; }
.hm-charts { margin-top: 10px; gap: 20px; }
.hm-charts figure { margin: 0; min-width: 0; }
.hm-charts figcaption { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px; font-size: 13px; font-weight: 700; color: #33496b; margin-bottom: 4px; }
.hm-legend { display: inline-flex; gap: 6px; align-items: center; font-weight: 600; color: var(--muted); font-size: 12px; }
.hm-legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-left: 6px; }
.hm-legend i.b1 { background: #0f766e; }
.hm-legend i.b2 { background: #b6c2d1; }
.hm-chart { display: block; width: 100%; height: auto; overflow: visible; }
.hm-chart .hm-b.b1 { fill: #0f766e; }
.hm-chart .hm-b.b2 { fill: #b6c2d1; }
.hm-chart .hm-grid { stroke: rgba(15, 35, 66, .07); stroke-width: 1; }
.hm-chart .hm-base { stroke: rgba(15, 35, 66, .25); stroke-width: 1; }
.hm-chart .hm-ax { font-size: 10.5px; fill: #64748b; font-family: inherit; }
.hm-chart .hm-hit { fill: transparent; }
.hm-chart .hm-col:hover .hm-hit { fill: rgba(15, 35, 66, .05); }
.hm-chart .hm-col:hover .hm-b.b1 { fill: #115e59; }
.hm-tips { list-style: none; margin: 14px 0 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.hm-tips li { display: flex; gap: 8px; align-items: flex-start; font-size: 13.5px; padding: 8px 10px; border-radius: 10px; background: rgba(15, 35, 66, .035); }
.hm-tips li > .i { flex: none; color: #0f766e; margin-top: 2px; }
.hm-index { margin-top: 12px; }
.hm-index-form { display: flex; gap: 10px; align-items: flex-end; flex-wrap: wrap; }
.hm-index-form .f { margin: 0; flex: 1 1 150px; }
.hm-index-form .btn { height: 42px; }
.hm-checks { display: flex; flex-wrap: wrap; gap: 4px 18px; }
.hm-linky-help h3 { margin: 0 0 8px; display: flex; gap: 6px; align-items: center; }
.hm-linky-help ol { margin: 0 0 8px; padding-left: 20px; display: flex; flex-direction: column; gap: 6px; font-size: 14px; }
@media (max-width: 1100px) { .hm-kpis, .hm-figs { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 760px) {
  .hm-start-grid { grid-template-columns: 1fr; }
  .hm-kpi strong { font-size: 20px; }
  .hm-charts { grid-template-columns: 1fr; }
  .hm-meter-card .hm-eq-top { flex-wrap: wrap; }
  .hm-meter-card .hm-eq-top .row-main { flex: 1 1 calc(100% - 140px); }
  .hm-sync { order: 5; flex-basis: 100%; padding-left: 50px; margin-top: 0; }
  .hm-mrow { flex-wrap: wrap; row-gap: 6px; }
  .hm-mrow .row-main { flex: 1 1 calc(100% - 60px); }
  .hm-mrow > .btn { margin-left: 56px; }
  .hm-chart .hm-ax { font-size: 18px; }
  .hm-side .hm-chart .hm-ax { font-size: 11px; }
  .hm-facts { grid-template-columns: 1fr 1fr; }
}

/* ---------- Administration : notifications SMS ---------- */
.sms-ids .f { margin-bottom: 10px; }
label.sms-ev { display: flex; flex-direction: row; align-items: flex-start; gap: 10px; margin: 2px 0 10px; cursor: pointer; }
label.sms-ev input { flex: none; width: 18px; height: 18px; margin: 2px 0 0; }
.sms-ev span { display: flex; flex-direction: column; line-height: 1.3; }
.sms-ev small { font-size: 12.5px; }
.sms-btns { display: flex; flex-wrap: wrap; gap: 8px; margin: 6px 0 8px; }
.sms-off { color: #be123c; font-weight: 700; font-size: 13px; display: inline-flex; gap: 5px; align-items: center; }

/* ---------- Code personnalisé du pied de page (statistiques, mention d'un outil tiers) ---------- */
.site-code { font-size: 12.5px; line-height: 1.45; color: #64748b; min-width: 0; overflow-wrap: anywhere; }
.site-code p { margin: 0; }
.site-code a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }
.site-code a:hover { color: var(--primary-ink); }
.site-code img, .site-code svg { max-height: 28px; width: auto; vertical-align: middle; }
.site-code iframe { max-width: 100%; }
.pf-bottom .site-code { flex: 1 1 260px; text-align: center; align-self: center; }
.foot .site-code { flex: 1 1 220px; text-align: center; }
.site-code-auth { margin-top: 20px; max-width: 440px; text-align: center; align-self: end; }
@media (max-width: 640px) {
  .pf-bottom .site-code { order: 3; flex-basis: 100%; text-align: left; }
  .foot { flex-wrap: wrap; }
  .foot .site-code { order: 3; flex-basis: 100%; }
}
.fc-card { margin-top: 16px; }
.fc-grid { align-items: start; }
.fc-card textarea.mono { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 12.5px; line-height: 1.5; }
.fc-notes { margin: 4px 0 14px 18px; line-height: 1.7; }

/* ---------- Monétisation : publicité et dons ---------- */
.ad-slot { position: relative; margin: 18px auto; padding: 10px 12px 12px; border: 1px dashed var(--line); border-radius: 14px; background: color-mix(in srgb, var(--card) 70%, transparent); max-width: 100%; overflow: hidden; text-align: center; }
.ad-label { display: block; font-size: 10.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: #64748b; margin-bottom: 6px; text-align: left; }
.ad-body { min-height: 60px; }
.ad-body ins.adsbygoogle { min-height: 90px; }
.ad-slot:has(ins.adsbygoogle[data-ad-status="unfilled"]) { display: none; }
.lp-ad { padding-top: 8px; padding-bottom: 8px; }
.pub-ad { padding: 0 20px; }
.pub-ad .pf-in { display: block; }
.pub-ad .ad-slot { margin: 28px auto 0; }
.donate-btn { display: inline-flex; align-items: center; gap: 8px; padding: 10px 18px; border-radius: 999px; background: var(--dn, #ffdd00); color: var(--dn-ink, #111827); font-weight: 800; font-size: 15px; text-decoration: none; box-shadow: 0 2px 0 rgba(0,0,0,.08); transition: transform .12s, box-shadow .12s; white-space: nowrap; }
.donate-btn:hover { transform: translateY(-1px); box-shadow: 0 6px 16px rgba(0,0,0,.12); color: var(--dn-ink, #111827); }
.donate-btn.donate-sm { padding: 6px 14px; font-size: 13.5px; margin-top: 12px; }
.donate-btn.donate-lg { padding: 13px 24px; font-size: 16.5px; }
.donate-card, section.card.donate-card { position: relative; display: flex; flex-direction: row; gap: 16px; align-items: center; flex-wrap: wrap; margin-top: 18px; background: linear-gradient(135deg, #fffbeb, #fff); border: 1px solid #fde68a; }
.donate-card > div { flex: 1 1 260px; min-width: 0; }
.donate-card h3 { margin: 0 0 4px; font-size: 16px; }
.donate-card p { margin: 0; font-size: 13.5px; color: #57534e; }
.donate-ic { flex: none; width: 46px; height: 46px; border-radius: 14px; display: grid; place-items: center; font-size: 24px; background: #fef3c7; }
.donate-x { position: absolute; top: 8px; right: 8px; }
.donate-card .donate-btn { margin-right: 26px; }
.donate-preview { margin: 0 0 10px; padding: 14px; border-radius: 14px; flex-shrink: 0; }
.donate-preview .donate-btn { margin-right: 0; }
.side-donate { display: flex; align-items: center; justify-content: center; gap: 6px; margin: 0 0 10px; padding: 8px 10px; border-radius: 12px; background: #fef3c7; color: #78350f; font-weight: 700; font-size: 13.5px; text-decoration: none; }
.side-donate:hover { background: #fde68a; color: #78350f; }
.lp-donate { padding: 56px 0; }
.lp-donate-in { display: flex; gap: 24px; align-items: center; flex-wrap: wrap; padding: 28px 32px; border-radius: 24px; background: linear-gradient(135deg, #fffbeb, #fef3c7); border: 1px solid #fde68a; }
.lp-donate-ic { font-size: 44px; line-height: 1; }
.lp-donate-txt { flex: 1 1 320px; }
.lp-donate-txt h2 { margin: 2px 0 6px; font-size: 26px; }
.lp-donate-txt p { margin: 0; color: #57534e; max-width: 640px; }
.mz-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-top: 8px; }
.mz-card { display: flex; flex-direction: column; gap: 6px; padding: 16px; border-radius: 16px; border: 1.5px solid var(--line); background: var(--card); color: inherit; text-decoration: none; transition: border-color .12s, box-shadow .12s; }
a.mz-card:hover { border-color: var(--mz); box-shadow: 0 6px 18px rgba(15, 35, 66, .08); }
.mz-card.on { border-color: var(--mz); background: color-mix(in srgb, var(--mz) 5%, var(--card)); }
.mz-top { display: flex; justify-content: space-between; align-items: center; }
.mz-ic { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: color-mix(in srgb, var(--mz) 14%, transparent); color: var(--mz); }
.mz-card h3 { margin: 4px 0 0; font-size: 16px; }
.mz-card p { margin: 0; font-size: 13.5px; color: var(--muted); flex: 1; }
.mz-go { font-size: 13px; font-weight: 700; color: var(--mz); display: inline-flex; gap: 4px; align-items: center; }
.mz-card form { margin-top: 4px; }
.mz-steps { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 6px; line-height: 1.5; }
.mz-place { padding: 4px 0 2px; border-bottom: 1px solid var(--line-2); margin-bottom: 8px; }
.mz-place:last-child { border-bottom: 0; }
.mz-color input[type=color] { width: 64px; height: 38px; padding: 2px; border-radius: 10px; }
/* Publicité : lien vers l'abonnement, bandeau de consentement, partenaires */
.ad-slot[hidden] { display: none; }
.ad-slot.ad-wait .ad-body { min-height: 0; }
.ad-upsell { display: inline-flex; align-items: center; gap: 5px; margin-top: 8px; font-size: 12.5px; font-weight: 700; color: var(--primary-d); text-decoration: none; }
.ad-upsell:hover { text-decoration: underline; }
.ads-consent { position: fixed; left: 50%; bottom: 16px; transform: translateX(-50%); z-index: 90; width: min(640px, calc(100% - 32px)); display: flex; gap: 14px; align-items: center; flex-wrap: wrap; padding: 14px 16px; border-radius: 16px; background: var(--card); border: 1px solid var(--line); box-shadow: var(--shadow-lg); }
.ads-consent p { margin: 0; flex: 1 1 300px; font-size: 13.5px; line-height: 1.5; }
.ads-consent-btns { display: flex; gap: 8px; }
.ads-consent-btns .btn { min-width: 96px; justify-content: center; }
.ad-sponsor { text-align: left; border-style: solid; display: block; width: 100%; max-width: 760px; box-sizing: border-box; }
.sp-card { display: flex; gap: 14px; align-items: center; color: inherit; text-decoration: none; }
.sp-card img { flex: 0 1 300px; width: 300px; max-width: 45%; aspect-ratio: 3 / 1; object-fit: cover; border-radius: 10px; background: var(--line-2); }
.sp-txt { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.sp-txt b { font-size: 15.5px; line-height: 1.3; }
.sp-txt small { color: var(--muted); font-size: 13.5px; }
.sp-txt em { font-style: normal; font-size: 12.5px; font-weight: 700; color: var(--primary-d); display: inline-flex; align-items: center; gap: 4px; }
.sp-card:hover b { text-decoration: underline; }
@media (max-width: 560px) { .sp-card { flex-direction: column; align-items: stretch; } .sp-card img { flex: none; width: 100%; max-width: none; height: auto; } }
/* Dons : objectif du mois, badge « Soutien » */
.dn-goal { margin-top: 10px; max-width: 520px; }
.dn-goal-h { display: flex; justify-content: space-between; gap: 10px; font-size: 13px; color: #57534e; margin-bottom: 5px; }
.dn-goal-h b { color: #1c1917; }
.dn-goal-h em { font-style: normal; font-weight: 800; color: #92400e; white-space: nowrap; }
.dn-bar { height: 10px; border-radius: 999px; background: rgba(146, 64, 14, .12); overflow: hidden; }
.dn-bar i { display: block; height: 100%; border-radius: 999px; background: linear-gradient(90deg, #f59e0b, #eab308); }
.dn-goal.is-done .dn-bar i { background: #16a34a; }
.dn-goal.is-done .dn-goal-h em { color: #15803d; }
.dn-goal-lg { margin-top: 14px; }
.dn-goal-lg .dn-goal-h { font-size: 14.5px; }
.dn-goal-lg .dn-bar { height: 12px; }
.sup-badge { display: inline-flex; align-items: center; gap: 3px; margin-left: 6px; padding: 1px 7px; border-radius: 999px; background: #fef3c7; color: #92400e; font-size: 10.5px; font-weight: 800; vertical-align: 2px; white-space: nowrap; }
/* Mon forfait : code cadeau, offrir, parrainer, résiliation */
.up-note { display: flex; gap: 6px; align-items: flex-start; margin: 8px 0 0; color: #15803d; font-weight: 600; }
.gift-redeem { margin-top: 14px; border-top: 1px solid var(--line-2); padding-top: 12px; }
.gift-redeem summary { cursor: pointer; font-weight: 700; font-size: 14px; color: var(--primary-d); display: inline-flex; gap: 6px; align-items: center; list-style: none; }
.gift-redeem summary::-webkit-details-marker { display: none; }
.gift-redeem-f { display: flex; gap: 8px; margin-top: 10px; max-width: 420px; }
.gift-redeem-f input { flex: 1; min-width: 0; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .06em; text-transform: uppercase; }
.gift-durations { display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); gap: 8px; margin-bottom: 12px; }
.gift-dur { position: relative; cursor: pointer; }
.gift-dur input { position: absolute; opacity: 0; }
.gift-dur span { display: flex; flex-direction: column; gap: 2px; padding: 10px 12px; border: 1.5px solid var(--line); border-radius: 12px; }
.gift-dur small { color: var(--muted); font-weight: 700; }
.gift-dur input:checked + span { border-color: #ea580c; background: color-mix(in srgb, #ea580c 7%, var(--card)); }
.gift-dur input:focus-visible + span { outline: 2px solid var(--primary); outline-offset: 2px; }
.gift-code { font-size: 13px; letter-spacing: .05em; background: var(--line-2); padding: 1px 6px; border-radius: 6px; }
.gift-list { margin-top: 12px; border-top: 1px solid var(--line-2); padding-top: 4px; }
.gift-list .row { align-items: center; }
.ref-link { display: flex; gap: 8px; }
.ref-link input { flex: 1; min-width: 0; font-size: 13px; }
.switch-row { display: flex; gap: 10px; align-items: center; font-size: 14px; cursor: pointer; }
.switch-row input { width: 18px; height: 18px; flex: none; }
.cf-reasons .f-check { display: flex; gap: 8px; align-items: center; margin-bottom: 6px; }
.cf-offers { margin-top: 6px; padding: 12px; border-radius: 14px; background: var(--primary-soft); display: flex; flex-direction: column; gap: 10px; }
.cf-kicker { margin: 0; font-weight: 800; font-size: 13px; color: var(--primary-d); }
.cf-offer { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; padding: 10px 12px; border-radius: 12px; background: var(--card); }
.cf-offer > div { flex: 1 1 200px; display: flex; flex-direction: column; gap: 2px; }
.cf-offer small { color: var(--muted); font-size: 12.5px; }
.cf-ic { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; color: var(--c); background: color-mix(in srgb, var(--c) 14%, transparent); flex: none; }
.cf-pause { display: flex; gap: 6px; }
.ref-hello { display: flex; gap: 8px; align-items: flex-start; }
.trial-hello { display: flex; gap: 6px; align-items: center; margin: -6px 0 14px; color: #7c3aed; font-weight: 600; }
/* Administration : partenaires, revenus, offres, résiliations */
#sp-form .f-group .f-check { display: flex; margin-bottom: 6px; }
.sp-admin { display: flex; flex-direction: column; }
.sp-row { display: flex; gap: 14px; align-items: flex-start; padding: 12px 0; border-top: 1px solid var(--line-2); }
.sp-row:first-child { border-top: 0; }
.sp-thumb { flex: none; width: 96px; aspect-ratio: 3 / 1; border-radius: 8px; overflow: hidden; background: var(--line-2); display: grid; place-items: center; color: var(--muted); }
.sp-thumb img { width: 100%; height: 100%; object-fit: cover; }
.sp-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.sp-stats { display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: 13px; align-items: baseline; margin-top: 2px; }
.sp-stats small { flex-basis: 100%; }
.sp-acts { display: flex; gap: 2px; align-items: center; }
.mz-rev { margin-top: 18px; }
.mz-kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 14px; }
.mz-kpi { display: flex; flex-direction: column; gap: 2px; padding: 12px 14px; border-radius: 14px; background: var(--bg); }
.mz-kpi > span { font-size: 12.5px; font-weight: 700; color: var(--muted); }
.mz-kpi b { font-size: 22px; letter-spacing: -.01em; }
.mz-kpi small { font-size: 12.5px; }
.mz-kpi .up { color: #15803d; }
.mz-kpi .down { color: #b91c1c; margin-left: 4px; }
.mz-legend { display: flex; flex-wrap: wrap; gap: 6px 16px; list-style: none; margin: 0 0 6px; padding: 0; font-size: 13px; color: var(--muted); }
.mz-legend li { display: inline-flex; align-items: center; gap: 6px; }
.mz-legend i { width: 10px; height: 10px; border-radius: 3px; background: var(--c); }
.mz-rev { --s1: #2a78d6; --s2: #eb6834; --s3: #1baf7a; --s4: #eda100; --s5: #e87ba4; }
.mz-legend i.s1, .mz-chart .s1 { --c: var(--s1); fill: var(--s1); }
.mz-legend i.s2, .mz-chart .s2 { --c: var(--s2); fill: var(--s2); }
.mz-legend i.s3, .mz-chart .s3 { --c: var(--s3); fill: var(--s3); }
.mz-legend i.s4, .mz-chart .s4 { --c: var(--s4); fill: var(--s4); }
.mz-legend i.s5, .mz-chart .s5 { --c: var(--s5); fill: var(--s5); }
.mz-chart { display: block; width: 100%; height: auto; overflow: visible; }
.mz-chart .mz-grid { stroke: rgba(15, 35, 66, .07); stroke-width: 1; }
.mz-chart .mz-base { stroke: rgba(15, 35, 66, .25); stroke-width: 1; }
.mz-chart .mz-ax { font-size: 11px; fill: #64748b; }
.mz-chart .mz-hit { fill: transparent; }
.mz-chart .mz-col:hover .mz-hit { fill: rgba(15, 35, 66, .04); }
.mz-table { margin: 10px 0 8px; }
.mz-table summary { cursor: pointer; font-size: 13px; font-weight: 700; color: var(--primary-d); }
.rev-add { display: grid; grid-template-columns: 1fr 1fr 1fr 2fr auto; gap: 8px; align-items: end; }
.rev-add .f { margin-bottom: 0; }
.rev-add + .rows { margin-top: 12px; }
.chips-row { display: flex; flex-wrap: wrap; gap: 6px; margin: 6px 0 4px; }
.chip-check { cursor: pointer; }
.chip-check input { position: absolute; opacity: 0; }
.chip-check span { display: inline-block; padding: 5px 11px; border-radius: 999px; border: 1.5px solid var(--line); font-size: 13px; font-weight: 600; }
.chip-check input:checked + span { border-color: #7c3aed; background: color-mix(in srgb, #7c3aed 8%, var(--card)); color: #5b21b6; }
.chip-check input:focus-visible + span { outline: 2px solid var(--primary); outline-offset: 2px; }
.mz-new { margin-top: 12px; }
.mz-new summary { cursor: pointer; font-weight: 700; font-size: 14px; color: var(--primary-d); display: inline-flex; gap: 6px; align-items: center; margin-bottom: 10px; }
.gift-admin-f { display: grid; grid-template-columns: 90px 110px 1fr auto; gap: 8px; align-items: end; }
.gift-admin-f .f { margin-bottom: 0; }
.churn-grid { display: grid; grid-template-columns: 3fr 2fr; gap: 24px; }
.churn-bar { display: grid; grid-template-columns: minmax(0, 240px) 1fr 32px; gap: 10px; align-items: center; font-size: 13px; margin-bottom: 6px; }
.churn-bar i { height: 10px; border-radius: 999px; background: #e11d48; opacity: .75; min-width: 4px; }
.churn-bar b { text-align: right; }
.churn-out { display: flex; flex-wrap: wrap; gap: 8px; }
.churn-k { display: flex; flex-direction: column; padding: 8px 12px; border-radius: 12px; background: var(--bg); font-size: 12.5px; color: var(--muted); }
.churn-k b { font-size: 18px; color: var(--text); }
html.dark .mz-rev { --s1: #3987e5; --s2: #d95926; --s3: #199e70; --s4: #c98500; --s5: #d55181; }
html.dark .dn-goal-h, html.dark .dn-goal-h b { color: var(--text); }
html.dark .sup-badge { background: #392c10; color: #fcd34d; }
@media (max-width: 1100px) { .mz-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); } .rev-add { grid-template-columns: 1fr 1fr; } }
@media (max-width: 760px) { .churn-grid { grid-template-columns: 1fr; } .gift-admin-f { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .mz-kpis { grid-template-columns: 1fr 1fr; } .rev-add { grid-template-columns: 1fr; } .churn-bar { grid-template-columns: 1fr 60px 28px; } .ads-consent { bottom: 8px; } .ads-consent-btns { width: 100%; } .ads-consent-btns .btn { flex: 1; } }
@media (max-width: 1100px) { .mz-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .mz-grid { grid-template-columns: 1fr; } .lp-donate-in { padding: 22px; } }

/* ---------- Fenêtres de saisie : briques communes (mf-*) ---------- */
.mf-title { margin-bottom: 10px; }
.mf-title input { font-size: 18px; font-weight: 700; padding: 12px 14px; }
.mf-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.mf-chip { --c: var(--primary); position: relative; display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 999px; font-size: 13px; font-weight: 700; cursor: pointer; user-select: none;
  background: var(--card); border: 1.5px solid var(--line); color: #334155; }
.mf-chip .i { color: var(--c); width: 15px; height: 15px; }
.mf-chip input { position: absolute; opacity: 0; pointer-events: none; }
.mf-chip:hover { background: color-mix(in srgb, var(--c) 8%, var(--card)); }
.mf-chip:has(input:checked) { background: color-mix(in srgb, var(--c) 14%, var(--card)); color: color-mix(in srgb, var(--c) 75%, #0f172a); border-color: var(--c); }
.mf-chip:has(input:focus-visible) { outline: 2px solid var(--c); outline-offset: 2px; }
.mf-sec { padding: 14px 0 2px; border-top: 1px solid var(--line-2); margin-top: 12px; }
.mf-title + .mf-sec, .mf-chips + .mf-sec { margin-top: 4px; }
.mf-sec:first-child { border-top: 0; margin-top: 0; padding-top: 4px; }
.mf-sec > h4 { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin: 0 0 10px; font-size: 12.5px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); }
.mf-sec > h4 .i { width: 15px; height: 15px; }
.mf-sec > h4 small { text-transform: none; letter-spacing: 0; font-weight: 600; font-size: 12.5px; margin-left: 4px; opacity: .85; }
.mf-sec .chips { margin-bottom: 12px; }
.mf-toggles { display: flex; flex-wrap: wrap; gap: 8px; margin: -2px 0 12px; }
.mf-toggle { display: inline-flex; align-items: center; gap: 8px; padding: 7px 12px 7px 8px; border-radius: 10px; border: 1px solid var(--line); background: var(--card); font-size: 13.5px; font-weight: 600; cursor: pointer; user-select: none; }
.mf-toggle input { width: 30px; height: 18px; margin: 0; appearance: none; -webkit-appearance: none; border-radius: 9px; background: #cbd5e1; position: relative; cursor: pointer; transition: background .15s; flex: none; }
.mf-toggle input::after { content: ""; position: absolute; top: 2px; left: 2px; width: 14px; height: 14px; border-radius: 50%; background: #fff; box-shadow: 0 1px 2px rgba(0,0,0,.2); transition: transform .15s; }
.mf-toggle input:checked { background: var(--primary); }
.mf-toggle input:checked::after { transform: translateX(12px); }
.mf-toggle input:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }
.mf-toggle:has(input:checked) { border-color: var(--primary); color: var(--primary-d); background: var(--primary-soft); }
.mf-more { margin-top: 12px; border-top: 1px solid var(--line-2); padding-top: 10px; }
.mf-more > summary { cursor: pointer; list-style: none; display: inline-flex; align-items: center; gap: 6px; font-size: 13.5px; font-weight: 700; color: var(--primary-d); padding: 4px 0; }
.mf-more > summary::-webkit-details-marker { display: none; }
.mf-more > summary .i { transition: transform .15s; }
.mf-more[open] > summary .i { transform: rotate(90deg); }
.mf-more-b { padding-top: 10px; }
.mf-more-b > .mf-sec:first-child { border-top: 0; margin-top: 0; padding-top: 0; }
.mf-hint { margin: -4px 0 10px; font-size: 12.5px; color: var(--muted); }
.mf-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 0 12px; }
.mf-inline { display: flex; flex-wrap: wrap; gap: 0 12px; align-items: flex-end; }
.mf-inline > * { flex: 1 1 140px; min-width: 0; }
.mf-note textarea { min-height: 64px; }
html.dark .mf-chip { color: var(--text); }
html.dark .mf-chip:has(input:checked) { color: color-mix(in srgb, var(--c) 55%, #fff); }

/* Fenêtres de saisie : compléments (fusion des lots de la refonte) */
.modal-body > input[type=hidden]:first-child + .mf-sec,
.modal-body > input[type=hidden] + input[type=hidden] + .mf-sec { border-top: 0; margin-top: 0; padding-top: 4px; }
.mf-members { margin-bottom: 12px; }
/* Lot A : fenêtre « Nouveau dossier » (Fichiers) — description et couleur sur une ligne */
.fo-desc-row { display: grid; grid-template-columns: 1fr 76px; gap: 12px; align-items: end; }
.fo-desc-row input[type=color] { width: 100%; height: 44px; padding: 4px; cursor: pointer; }
/* Lot C — garde : ligne « maison » (nom, couleur, parent) de la fenêtre Organisation de la garde */
.cx-home-row { display: grid; grid-template-columns: minmax(0, 1.5fr) 64px minmax(0, 1.3fr); gap: 0 12px; align-items: end; }
.cx-home-row input[type=color] { padding: 4px; height: 44px; }
@media (max-width: 480px) { .cx-home-row { grid-template-columns: minmax(0, 1fr) 56px; } .cx-home-row > :last-child { grid-column: 1 / -1; } }
/* Bouton de lecture d'un ticket placé en tête de la fenêtre d'opération. */
.veh-ocr-top { margin-bottom: 4px; }
/* Choix en puces aligné à côté d'un champ (montant + périodicité) : sur une ligne, à la hauteur du champ. */
.mf-inline > .f:has(> .mf-chips) { flex: 0 0 auto; }
.mf-inline .mf-chips { flex-wrap: nowrap; margin-bottom: 0; min-height: 44px; align-items: center; }

/* ---------- Maison 1.25 : chauffage, logement, extérieur ---------- */
.t-blue { color: #1d4ed8; } .t-green { color: #15803d; }
.hm-bar-btns { display: flex; gap: 8px; flex-wrap: wrap; }
.hm-start-mini { display: flex; gap: 16px; align-items: flex-start; }
.hm-start-mini h3 { margin: 0 0 4px; }
.hm-h4 { display: flex; align-items: center; gap: 6px; margin: 16px 0 6px; font-size: 12.5px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); }
.hm-gauge { margin: 12px 0 4px; }
.hm-gauge-h { display: flex; justify-content: space-between; gap: 10px; font-size: 14px; margin-bottom: 6px; }
.hm-gauge-h em { font-style: normal; font-weight: 800; }
.hm-gauge-bar { position: relative; height: 14px; border-radius: 999px; background: var(--line-2); overflow: visible; }
.hm-gauge-bar i { display: block; height: 100%; border-radius: 999px; background: linear-gradient(90deg, #16a34a, #22c55e); }
.hm-gauge.t-mid .hm-gauge-bar i { background: linear-gradient(90deg, #d97706, #f59e0b); }
.hm-gauge.t-low .hm-gauge-bar i { background: linear-gradient(90deg, #dc2626, #ef4444); }
.hm-gauge.t-low .hm-gauge-h em { color: #be123c; }
.hm-gauge-bar s { position: absolute; top: -3px; bottom: -3px; width: 2px; background: #0f172a; opacity: .45; border-radius: 1px; }
.hm-gauge p { margin: 8px 0 0; }
.hm-gauge-sm { margin: 8px 0 10px; }
.hm-gauge-sm .hm-gauge-bar { height: 8px; }
.hm-gauge-sm .hm-gauge-h { font-size: 13px; margin-bottom: 4px; }
.hm-forecast { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 10px 0 0; padding: 8px 12px; border-radius: 10px; background: var(--bg); font-size: 13.5px; font-weight: 600; }
.hm-level-f { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 12px 0 0; padding: 10px 12px; border-radius: 12px; border: 1px dashed var(--line); }
.hm-level-f .input-unit { width: 120px; }
.hm-level-f .input-unit input { padding: 6px 8px; }
.hm-unitp { display: inline-block; margin-left: 4px; padding: 1px 7px; border-radius: 999px; background: #fef3c7; color: #92400e; font-size: 12px; font-weight: 700; }
.hm-issue { display: inline-flex; align-items: center; gap: 5px; margin-top: 4px; font-size: 12.5px; font-weight: 700; color: #be123c; }
.hm-quotes { margin-top: 3px; }
.hm-pricefig { margin: 14px 0 8px; }
.hm-pricefig figcaption { font-size: 12.5px; color: var(--muted); font-weight: 700; margin-bottom: 4px; }
.hm-years { margin-top: 6px; font-size: 13.5px; }
.hm-season.on { border-color: color-mix(in srgb, #ea580c 40%, var(--line)); }
.hm-season-now { display: flex; gap: 12px; align-items: center; margin: 0 0 8px; }
.hm-season-now span:last-child { display: flex; flex-direction: column; }
.hm-season-now small { color: var(--muted); }
.hm-flame { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; background: #ffedd5; color: #ea580c; flex: none; }
.hm-season-now.off .hm-flame { background: var(--line-2); color: var(--muted); }
.hm-season-btns { display: flex; gap: 8px; flex-wrap: wrap; margin: 8px 0; }
.hm-nights { display: flex; flex-wrap: wrap; gap: 4px 12px; align-items: center; }
.hm-th { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 12px 0 0; padding-top: 10px; border-top: 1px solid var(--line-2); font-size: 13px; color: var(--muted); }
.hm-th .input-unit { display: inline-flex; width: 86px; vertical-align: middle; }
.hm-th .input-unit input { padding: 4px 6px; }
.hm-seasons { margin-top: 12px; }
.hm-codes { display: flex; flex-direction: column; gap: 6px; margin-top: 8px; }
.hm-codes > div { display: flex; gap: 10px; align-items: flex-start; font-size: 13.5px; }
.hm-codes code { flex: none; min-width: 44px; text-align: center; padding: 2px 6px; border-radius: 6px; background: #fee2e2; color: #991b1b; font-weight: 800; }
.hm-codes span { display: flex; flex-direction: column; }
.hm-codes small { color: var(--muted); }
.hm-checks-list { display: flex; flex-direction: column; gap: 2px; }
.hm-check { display: flex; gap: 10px; align-items: flex-start; padding: 7px 8px; border-radius: 10px; cursor: pointer; }
.hm-check:hover { background: var(--bg); }
.hm-check input { width: 18px; height: 18px; margin-top: 2px; flex: none; accent-color: var(--primary); }
.hm-check span { display: flex; flex-direction: column; font-size: 14px; font-weight: 600; }
.hm-check small { font-weight: 500; font-size: 12.5px; }
.hm-check:has(input:checked) span { color: var(--muted); }
.mf-dpe { gap: 4px; margin-bottom: 6px; }
.mf-dpe .mf-chip { width: 34px; height: 34px; padding: 0; justify-content: center; border-radius: 8px; font-size: 15px; }
.mf-dpe .mf-chip:has(input:checked) { background: var(--c); color: #0f172a; border-color: #0f172a; }
.hm-dpe { display: inline-grid; place-items: center; width: 22px; height: 22px; margin-left: 4px; border-radius: 6px; background: var(--c); color: #0f172a; font-size: 12.5px; font-weight: 900; vertical-align: 1px; }
.hm-dpe-box { margin-bottom: 12px; padding: 12px; border-radius: 12px; background: var(--bg); }
.hm-dpe-scale { display: flex; gap: 4px; margin-bottom: 8px; }
.hm-dpe-scale span { flex: 1; height: 26px; display: grid; place-items: center; border-radius: 6px; background: var(--c); color: #0f172a; font-weight: 800; opacity: .35; }
.hm-dpe-scale span.on { opacity: 1; transform: scaleY(1.25); box-shadow: 0 0 0 2px #0f172a; }
.hm-dpe-box p { margin: 6px 0 0; }
.hm-dpe-move { display: inline-flex; align-items: center; gap: 2px; }
.hm-log .card { min-width: 0; }
.hm-howto { margin-top: 4px; padding: 6px 10px; border-left: 3px solid #dc2626; background: #fef2f2; border-radius: 0 8px 8px 0; }
.hm-thumbs { display: flex; gap: 6px; margin-top: 6px; flex-wrap: wrap; }
.hm-thumbs img { width: 96px; height: 72px; object-fit: cover; border-radius: 8px; display: block; }
.hm-breakers { font-size: 13.5px; margin-bottom: 8px; }
.hm-brk-grid { display: grid; grid-template-columns: 64px minmax(0, 1fr) 90px 100px; gap: 6px; align-items: center; }
.hm-brk-grid > span { font-size: 12px; font-weight: 800; color: var(--muted); text-transform: uppercase; letter-spacing: .03em; }
.hm-brk-grid input { padding: 7px 9px; font-size: 14px; min-width: 0; }
.hm-phone { display: inline-flex; gap: 5px; align-items: center; margin-top: 3px; font-weight: 700; }
.hm-reno { margin: 12px 0 4px; padding: 12px; border-radius: 12px; background: color-mix(in srgb, #16a34a 6%, var(--card)); border: 1px solid color-mix(in srgb, #16a34a 22%, var(--line)); }
.hm-reno-h { display: flex; justify-content: space-between; gap: 8px; align-items: center; margin-bottom: 6px; }
.hm-reno-h strong { color: #15803d; display: inline-flex; gap: 5px; align-items: center; }
.hm-aid { display: grid; grid-template-columns: minmax(0, 1fr) auto auto auto; gap: 8px; align-items: center; padding: 5px 0; border-top: 1px solid var(--line-2); font-size: 13.5px; }
.hm-aid-v { font-weight: 700; }
.hm-aid-tot { margin: 8px 0 4px; }
.hm-saving { display: flex; gap: 5px; align-items: center; margin: 4px 0; font-weight: 700; }
.hm-balance { margin-bottom: 16px; }
.hm-balance .hm-figs { margin-top: 8px; }
.seg-sm a { padding: 4px 10px; font-size: 13px; }
.hm-src { display: inline-flex; align-items: center; gap: 6px; }
.hm-bal-t { font-size: 13.5px; }
.hm-dim { opacity: .6; }
.hm-pool { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-bottom: 8px; }
.hm-pool > div { display: flex; flex-direction: column; padding: 8px 10px; border-radius: 10px; background: var(--bg); }
.hm-pool small { font-size: 12px; font-weight: 700; color: var(--muted); }
.hm-pool b { font-size: 20px; }
.hm-pool em { font-style: normal; font-size: 11.5px; color: var(--muted); }
.hm-pool .t-green b { color: #15803d; } .hm-pool .t-orange b { color: #c2410c; } .hm-pool .t-red b { color: #be123c; }
.hm-eq-mini { display: flex; align-items: center; gap: 6px; margin: 10px 0 4px; font-size: 14px; }
html.dark .hm-unitp { background: #392c10; color: #fcd34d; }
html.dark .hm-flame { background: #431407; }
html.dark .hm-howto { background: #3f1515; }
html.dark .hm-codes code { background: #450a0a; color: #fecaca; }
@media (max-width: 640px) { .hm-brk-grid { grid-template-columns: 48px minmax(0, 1fr) 64px; } .hm-brk-grid > :nth-child(4n) { display: none; } .hm-figs { grid-template-columns: repeat(2, minmax(0, 1fr)); } .hm-aid { grid-template-columns: minmax(0, 1fr) auto auto; } .hm-aid .actions { grid-column: 1 / -1; } }
.hm-set { padding: 10px 0; border-top: 1px solid var(--line-2); }
.hm-set-h { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.hm-set-h b { display: inline-flex; align-items: center; gap: 6px; }
.hm-set .hm-facts { margin-top: 8px; }
.hm-water .row { flex-wrap: wrap; row-gap: 6px; }
.hm-water .row-main { flex: 1 1 100%; }

/* ---------- Administration › Utilisation ---------- */
.us-intro { margin: 0 0 12px; }
.us-levels { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 10px; margin-bottom: 18px; }
.us-level { display: flex; flex-direction: column; padding: 12px 14px; border-radius: 14px; background: var(--card); border: 1px solid var(--line); text-decoration: none; color: inherit; }
.us-level b { font-size: 24px; line-height: 1.1; }
.us-level span { font-size: 13px; font-weight: 700; }
.us-level small { color: var(--muted); }
.us-level.on { box-shadow: 0 0 0 2px currentColor; }
.us-level.t-green b { color: #15803d; } .us-level.t-blue b { color: #1d4ed8; } .us-level.t-yellow b { color: #a16207; } .us-level.t-orange b { color: #c2410c; } .us-level.t-red b { color: #be123c; } .us-level.t-gray b { color: var(--muted); }
.us-mods { display: flex; flex-direction: column; gap: 7px; }
.us-mod { display: grid; grid-template-columns: minmax(0, 190px) minmax(0, 1fr) 52px; gap: 10px; align-items: center; font-size: 13.5px; }
.us-mod-l { display: inline-flex; align-items: center; gap: 8px; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ch-ic.sm { display: inline-grid; place-items: center; width: 26px; height: 26px; border-radius: 8px; flex: none; color: var(--mc); background: color-mix(in srgb, var(--mc) 13%, transparent); }
.ch-ic.sm .i { width: 15px; height: 15px; }
.us-stack { display: flex; gap: 2px; height: 12px; border-radius: 999px; background: var(--line-2); overflow: hidden; }
.us-stack i { display: block; height: 100%; }
.us-stack .s-reg { background: #16a34a; } .us-stack .s-occ { background: #eab308; } .us-stack .s-unused { background: #f87171; }
.us-mod-n { text-align: right; color: var(--muted); }
.us-mod-n b { color: var(--text); }
.us-legend { margin-top: 12px; }
.us-off { margin-top: 10px; display: flex; flex-wrap: wrap; gap: 4px 12px; }
.us-tbl { font-size: 13.5px; }
.us-tbl td { vertical-align: middle; }
.us-dots { display: inline-flex; flex-wrap: wrap; gap: 2px; max-width: 150px; margin-right: 6px; vertical-align: middle; }
.us-dots i { width: 8px; height: 8px; border-radius: 2px; background: #cbd5e1; }
.us-dots .d-intense { background: #15803d; } .us-dots .d-regular { background: #2563eb; } .us-dots .d-occasional { background: #eab308; } .us-dots .d-dormant { background: #f97316; } .us-dots .d-never { background: #ef4444; } .us-dots .d-off { background: #e2e8f0; }
.us-score { display: inline-grid; place-items: center; width: 38px; height: 38px; border-radius: 50%; background: conic-gradient(#2563eb calc(var(--p) * 1%), var(--line-2) 0); }
.us-score b { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; background: var(--card); font-size: 12.5px; }
.us-score.lg { width: 64px; height: 64px; }
.us-score.lg b { width: 52px; height: 52px; font-size: 19px; }
.us-back { margin: 0 0 10px; }
.us-head-t { display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; }
.us-head-t h2 { margin: 0 0 4px; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.us-cal { display: grid; grid-template-rows: repeat(7, 13px); grid-auto-flow: column; grid-auto-columns: 13px; gap: 3px; margin: 14px 0 6px; }
.us-cal i { border-radius: 3px; background: var(--line-2); }
.us-cal .l1 { background: #bfdbfe; } .us-cal .l2 { background: #60a5fa; } .us-cal .l3 { background: #2563eb; } .us-cal .l4 { background: #1e3a8a; }
.us-muted td { opacity: .55; }
.us-top { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 4px; }
.us-top span { display: inline-flex; align-items: center; gap: 4px; padding: 1px 8px; border-radius: 999px; background: var(--bg); font-size: 12px; }
.us-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
.us-chip { display: inline-flex; align-items: center; gap: 5px; padding: 4px 10px; border-radius: 999px; font-size: 13px; font-weight: 600; background: #fee2e2; color: #991b1b; }
.us-chip.dormant { background: #ffedd5; color: #9a3412; }
.us-chip small { font-weight: 500; opacity: .8; }
html.dark .us-chip { background: #450a0a; color: #fecaca; } html.dark .us-chip.dormant { background: #431407; color: #fed7aa; }
@media (max-width: 1100px) { .us-levels { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 560px) { .us-levels { grid-template-columns: repeat(2, minmax(0, 1fr)); } .us-mod { grid-template-columns: minmax(0, 1fr) 80px 44px; } }

/* Menu latéral : rubriques (ordre conseillé) */
.nav .nav-group { display: flex; align-items: center; justify-content: space-between; width: 100%; border: 0; background: none; cursor: pointer; font-family: inherit; text-align: left; padding: 10px 12px 3px; font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: rgba(255, 255, 255, .62); border-radius: 8px; }
.nav .nav-group:hover { color: rgba(255, 255, 255, .9); }
.nav .nav-group .i { width: 14px; height: 14px; opacity: .7; transition: transform .15s; }
.nav .nav-group[aria-expanded="false"] .i { transform: rotate(-90deg); }
.nav .nav-group[aria-expanded="false"] { padding-bottom: 6px; }
.nav [data-ng][hidden] { display: none !important; }
/* 1.27.1 — menu plus compact */
.nav { gap: 1px; }
.nav a, .nav .nav-off { padding: 8px 12px; gap: 12px; font-size: 14.5px; border-radius: 10px; }
.nav a .i, .nav .nav-off .i { width: 20px; height: 20px; }
.brand { padding-bottom: 14px; }
.side-tools, .side-search { margin-bottom: 8px; }
.nav .nav-group:first-of-type { padding-top: 8px; }
.nav .nav-group-sep { padding: 0; margin: 6px 14px; height: 1px; background: rgba(255,255,255,.08); }
@media (max-height: 900px) { .nav .nav-group { padding-top: 7px; font-size: 10.5px; } .nav a, .nav .nav-off { padding-top: 6px; padding-bottom: 6px; } }
/* Paramètres : ordre du menu */
.menu-order { display: flex; flex-direction: column; gap: 2px; }
.menu-order .mo-group { font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); padding: 10px 4px 4px; }
.menu-order .mo-group:first-child { padding-top: 0; }
.menu-order .mo-row { display: flex; align-items: center; gap: 10px; padding: 5px 4px; border-radius: 10px; }
.menu-order .mo-row:hover { background: var(--soft, rgba(0,0,0,.03)); }
.menu-order .mo-label { flex: 1; font-weight: 600; }
.menu-order .icon-btn[disabled] { opacity: .3; pointer-events: none; }
.ic-bubble.sm { width: 30px; height: 30px; border-radius: 9px; } .ic-bubble.sm .i { width: 16px; height: 16px; }

/* Lisibilité : initiales blanches sur les couleurs claires des membres ; icônes colorées un peu plus soutenues */
.av, .cf-label { text-shadow: 0 1px 2px rgba(0, 0, 0, .28); }
.ch-ic { color: color-mix(in srgb, var(--mc) 82%, #0f2342); }

/* Paramètres : onglets et formulaire « Famille » en deux cartes */
.set-tabs .count { display: inline-block; min-width: 20px; padding: 0 6px; border-radius: 99px; background: var(--primary-soft); color: var(--primary-d); font-size: 11.5px; line-height: 18px; text-align: center; }
.set-h { display: flex; align-items: center; gap: 6px; margin: 18px 0 8px; padding-top: 14px; border-top: 1px solid var(--line-2); font-size: 13px; font-weight: 800; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.set-form .set-save { position: sticky; bottom: 12px; z-index: 5; display: flex; justify-content: flex-end; margin-top: 16px; }
.set-form .set-save .btn { box-shadow: var(--shadow-lg); }

/* ---------- 1.27 : Listes d'envies ---------- */
.wish-who { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 16px; }
.wish-chip { display: inline-flex; align-items: center; gap: 8px; padding: 5px 12px 5px 5px; border-radius: 99px; background: var(--card); border: 1px solid var(--line); color: var(--text); font-weight: 700; font-size: 14px; }
.wish-chip b { min-width: 20px; padding: 0 6px; border-radius: 99px; background: var(--line-2); color: var(--text); font-size: 12px; text-align: center; }
.wish-chip.on { border-color: #e11d48; box-shadow: 0 0 0 3px color-mix(in srgb, #e11d48 15%, transparent); }
.wish-chip.on b { background: #e11d48; color: #fff; }
.wish-secret { display: flex; align-items: center; gap: 6px; margin: -4px 0 14px; padding: 8px 12px; border-radius: 10px; background: var(--pink-soft); color: #9d174d; font-size: 13px; font-weight: 600; }
.wish-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 14px; }
.wish { display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: var(--radius-sm); overflow: hidden; background: var(--card); }
.wish.is-res { opacity: .78; }
.wish-img { position: relative; height: 64px; background: color-mix(in srgb, #e11d48 7%, var(--card)); display: grid; place-items: center; }
.wish-img:has(img) { height: auto; aspect-ratio: 16 / 9; }
.wish-img img { width: 100%; height: 100%; object-fit: cover; }
.wish-img > span .i { width: 28px; height: 28px; color: color-mix(in srgb, #e11d48 62%, #0f2342); opacity: .9; }
html.dark .wish-prio { color: color-mix(in srgb, var(--c) 50%, #e2e8f0); }
.wish-prio { position: absolute; left: 8px; top: 8px; padding: 2px 9px; border-radius: 99px; background: var(--card); color: color-mix(in srgb, var(--c) 62%, #0f2342); font-style: normal; font-size: 11.5px; font-weight: 800; box-shadow: var(--shadow); }
.wish-b { padding: 12px 14px 14px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.wish-b h3 { font-size: 16px; line-height: 1.25; }
.wish-b p { font-size: 13px; color: var(--muted); }
.wish-meta { display: flex; flex-wrap: wrap; gap: 4px 12px; align-items: center; font-size: 13px; color: var(--muted); }
.wish-meta strong { color: var(--text); font-size: 15px; }
.wish-act { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: auto; padding-top: 6px; }
.wish-own { margin-left: auto; display: inline-flex; gap: 2px; align-items: center; }
.wish-tag { display: inline-flex; align-items: center; gap: 4px; padding: 3px 10px; border-radius: 99px; background: var(--line-2); color: var(--muted); font-size: 12.5px; font-weight: 700; }
.wish-tag.ok { background: var(--green-soft); color: #166534; }

/* ---------- 1.27 : Routines & corvées ---------- */
.rt-head { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; }
.rt-head h2 { font-size: 20px; flex: 1; }
.rt-pts { display: inline-flex; align-items: center; gap: 4px; padding: 4px 12px; border-radius: 99px; background: var(--yellow-soft); color: #92400e; font-weight: 800; }
.rt-block { border: 1px solid var(--line); border-radius: var(--radius-sm); margin-top: 10px; background: color-mix(in srgb, var(--c) 3%, var(--card)); }
.rt-block > summary { display: flex; align-items: center; gap: 10px; padding: 12px 14px; cursor: pointer; list-style: none; }
.rt-block > summary::-webkit-details-marker { display: none; }
.rt-block.is-done > summary strong::after { content: " ✓"; color: var(--green); }
.rt-mo { width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; background: color-mix(in srgb, var(--c) 15%, var(--card)); color: color-mix(in srgb, var(--c) 62%, #0f2342); }
.rt-count { margin-left: auto; font-size: 13px; color: var(--muted); font-weight: 700; display: inline-flex; align-items: center; gap: 4px; }
.rt-bar { display: block; height: 5px; margin: 0 14px; border-radius: 99px; background: var(--line-2); overflow: hidden; }
.rt-bar i { display: block; height: 100%; background: var(--green); border-radius: inherit; transition: width .3s; }
.rt-steps { display: grid; grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: 10px; padding: 12px 14px 14px; }
.rt-step { position: relative; display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 14px 8px 12px; border-radius: 16px; border: 2px solid var(--line); background: var(--card); cursor: pointer; text-align: center; min-height: 112px; justify-content: center; transition: transform .12s, border-color .15s, background .15s; user-select: none; -webkit-user-select: none; }
.rt-step input { position: absolute; opacity: 0; pointer-events: none; }
.rt-step:active { transform: scale(.96); }
.rt-emo { font-size: 34px; line-height: 1; }
.rt-lbl { font-weight: 700; font-size: 13.5px; line-height: 1.2; }
.rt-ok { position: absolute; top: 6px; right: 6px; width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; background: var(--green); color: #fff; opacity: 0; transform: scale(.4); transition: .18s; }
.rt-ok .i { width: 14px; height: 14px; }
.rt-step:has(input:checked) { border-color: var(--green); background: var(--green-soft); }
.rt-step:has(input:checked) .rt-lbl { text-decoration: line-through; color: var(--muted); }
.rt-step:has(input:checked) .rt-ok { opacity: 1; transform: none; }
.rt-step:has(input:disabled) { cursor: default; }
.rt-step:has(input:focus-visible) { outline: 3px solid var(--primary); outline-offset: 2px; }
.chore-emo { font-size: 22px; width: 32px; text-align: center; flex: none; }
.row.chore.done .row-title { text-decoration: line-through; color: var(--muted); }
.rt-tpl { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }

/* ---------- 1.27 : Historique des modifications ---------- */
.hist { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.hist > li { display: flex; gap: 10px; align-items: flex-start; }
.hist > li > div { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.hist small { color: var(--muted); font-size: 12px; }
.hist ul { margin: 4px 0 0; padding-left: 16px; font-size: 13px; color: var(--muted); }

/* ---------- 1.27 : Voyages ---------- */
.sec-title { font-size: 17px; margin: 18px 0 10px; }
.trip-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 16px; }
.trip-card { display: flex; flex-direction: column; gap: 10px; color: var(--text); border-top: 4px solid var(--c); transition: transform .15s, box-shadow .15s; }
.trip-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); }
.trip-top { display: flex; gap: 12px; align-items: flex-start; }
.trip-top > div { flex: 1; min-width: 0; }
.trip-top h3 { font-size: 17px; }
.trip-top small { color: var(--muted); }
.trip-ic { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; background: color-mix(in srgb, var(--c) 14%, var(--card)); color: color-mix(in srgb, var(--c) 80%, #0f2342); flex: none; }
.trip-facts { display: flex; flex-direction: column; gap: 4px; font-size: 13px; color: var(--muted); }
.trip-facts span { display: inline-flex; align-items: center; gap: 6px; }
.trip-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: auto; }
.trip-warn { display: inline-flex; align-items: center; gap: 4px; font-size: 12.5px; font-weight: 700; color: #b45309; }
.trip-hero { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 16px 24px; border-left: 5px solid var(--c); margin-bottom: 14px; }
@media (max-width: 760px) { .trip-hero { grid-template-columns: 1fr; } .trip-hero > .btn { justify-self: start; } }
.trip-kpis { display: flex; flex-wrap: wrap; gap: 8px 28px; flex: 1; }
.trip-kpis small { display: block; font-size: 12px; color: var(--muted); font-weight: 700; text-transform: uppercase; letter-spacing: .04em; }
.trip-kpis strong { font-size: 19px; }
.trip-who { display: flex; align-items: center; gap: 4px; }
.trip-tools { display: inline-flex; margin-left: 8px; }
.trip-day { font-size: 14px; margin: 16px 0 6px; color: var(--muted); text-transform: uppercase; letter-spacing: .03em; }
.trip-day:first-of-type { margin-top: 4px; }
.seg .count.warn { background: #fde68a; color: #92400e; }
.pack-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 16px; align-items: start; }
.pack-h { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.pack-h strong { flex: 1; }
.pack-h b { font-size: 13px; color: var(--muted); }
.pack-list { display: flex; flex-direction: column; }
.pack-it { display: flex; align-items: center; gap: 10px; padding: 6px 2px; border-bottom: 1px solid var(--line-2); cursor: pointer; }
.pack-it span { flex: 1; }
.pack-it.done span, .pack-it:has(input:checked) span { text-decoration: line-through; color: var(--muted); }
.pack-it .icon-btn { opacity: .5; }
.pack-add { display: flex; gap: 6px; margin-top: 10px; }
.pack-add input { flex: 1; min-width: 0; }
.inline-form { display: inline-flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.inline-form select { max-width: 260px; }
.doc-card { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 12px 14px; }
.doc-h { display: flex; align-items: center; gap: 10px; margin-bottom: 6px; }
.doc-issue { display: flex; align-items: center; gap: 6px; margin-top: 8px; font-size: 13px; font-weight: 700; }
.doc-issue.t-red { color: #b91c1c; } .doc-issue.t-orange { color: #b45309; }
.trip-budget p { margin-top: 8px; }
.trip-budget.over .mini-bar i { background: #dc2626; }
.big-num { font-size: 30px; font-weight: 800; margin: 0 0 10px; }
.pre-wrap { white-space: pre-wrap; }

/* ---------- 1.27 : Journal de famille ---------- */
.jr { display: flex; gap: 16px; }
.jr-date { flex: none; width: 58px; text-align: center; display: flex; flex-direction: column; align-items: center; gap: 2px; padding-top: 2px; }
.jr-date b { font-size: 26px; line-height: 1; color: color-mix(in srgb, #c026d3 75%, #0f2342); }
.jr-date small { text-transform: uppercase; font-weight: 800; font-size: 11px; color: var(--muted); letter-spacing: .05em; }
.jr-date span { font-size: 22px; margin-top: 4px; }
.jr-b { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 8px; }
.jr-b h3 { font-size: 17px; }
.jr-img { width: 100%; max-height: 380px; object-fit: cover; border-radius: var(--radius-sm); display: block; }
.jr-foot { display: flex; align-items: center; gap: 10px; }
.jr-foot small { color: var(--muted); }
.jr-tools { margin-left: auto; display: inline-flex; }
.jr-mem { display: flex; flex-direction: column; gap: 6px; padding: 8px 0; border-bottom: 1px solid var(--line-2); }
.jr-mem:last-child { border-bottom: 0; }
.jr-mem img { width: 100%; border-radius: 10px; aspect-ratio: 4 / 3; object-fit: cover; }
.jr-mem a { color: var(--text); }
.sub-amt { text-align: right; display: flex; flex-direction: column; flex: none; }
.sub-amt small { color: var(--muted); font-size: 12px; }
.sub-row.is-off { opacity: .6; }

/* ---------- 1.27 : Sondages ---------- */
.poll + .poll { margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--line-2); }
.poll-q { display: flex; align-items: flex-start; gap: 8px; }
.poll-q strong { flex: 1; font-size: 15px; }
.poll-tools { display: inline-flex; }
.poll-opts { display: flex; flex-direction: column; gap: 6px; margin-top: 8px; }
.poll-opt { position: relative; display: flex; align-items: center; justify-content: space-between; gap: 10px; width: 100%; padding: 9px 12px; border-radius: 10px; border: 1px solid var(--line); background: linear-gradient(90deg, color-mix(in srgb, #0ea5e9 14%, var(--card)) var(--p), var(--card) var(--p)); color: var(--text); font: inherit; font-weight: 700; text-align: left; cursor: default; }
button.poll-opt { cursor: pointer; }
button.poll-opt:hover { border-color: #0ea5e9; }
.poll-opt.mine { border-color: #0284c7; box-shadow: inset 0 0 0 1px #0284c7; }
.poll-opt.win { border-color: var(--green); background: linear-gradient(90deg, var(--green-soft) var(--p), var(--card) var(--p)); }
.poll-l { display: inline-flex; align-items: center; gap: 6px; min-width: 0; }
.poll-v { display: inline-flex; align-items: center; gap: 2px; flex: none; }
.poll-v b { margin-left: 6px; font-size: 13px; color: var(--text); opacity: .8; }
.memory-card.memory-text .memory-img { min-height: 160px; background: linear-gradient(135deg, #a21caf, #6d28d9); }
.memory-card.memory-text .memory-cap { background: none; padding-top: 18px; }
.chat-polls { margin-top: 16px; max-width: 760px; }
.btn-row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.shop-store { display: flex; align-items: center; gap: 8px; margin: -4px 0 12px; flex-wrap: wrap; color: var(--muted); }
.shop-store select { width: auto; min-width: 0; max-width: 100%; padding-top: 6px; padding-bottom: 6px; }
.aisle-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 4px; counter-reset: ai; }
.aisle-list li { display: flex; align-items: center; gap: 4px; padding: 6px 8px; border: 1px solid var(--line); border-radius: 10px; background: var(--card); counter-increment: ai; }
.aisle-list li::before { content: counter(ai); width: 22px; font-weight: 800; color: var(--muted); }
.aisle-list li span { flex: 1; font-weight: 600; }
.allergy-flag, .left-flag { display: inline-flex; align-items: center; gap: 4px; margin: 3px 0 0; padding: 1px 8px; border-radius: 99px; font-size: 11.5px; font-weight: 800; line-height: 1.5; width: fit-content; }
.allergy-flag { background: var(--red-soft); color: #9f1239; }
.left-flag { background: var(--teal-soft); color: #115e59; }
.meal-cell .allergy-flag { display: flex; }
.share-link { display: flex; flex-direction: column; gap: 6px; margin-bottom: 12px; }
.share-link input { font-size: 13px; }
/* Album partagé (page publique) */
.alb-wrap { max-width: 1100px; margin: 0 auto; padding: 24px 16px 40px; }
.alb-head { display: flex; gap: 18px; align-items: flex-start; margin-bottom: 20px; flex-wrap: wrap; }
.alb-head h1 { font-size: 26px; margin: 0 0 4px; color: var(--heading); }
.alb-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px; }
.alb-grid figure { margin: 0; }
.alb-grid img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 12px; display: block; background: var(--line-2); }
.alb-grid figcaption { font-size: 13px; color: var(--muted); padding: 4px 2px; display: flex; justify-content: space-between; gap: 6px; }

/* Mode hors ligne : modifications en attente d'envoi */
.outbox-bar { margin: 0 0 12px; padding: 9px 14px; border-radius: 12px; background: #fef3c7; color: #78350f; border: 1px solid #fcd34d; font-size: 14px; font-weight: 600; }

/* Aide : installer l'application */
.app-guide { margin-bottom: 18px; }
.ag-state { display: flex; gap: 8px; align-items: center; padding: 10px 12px; border-radius: 12px; background: #dcfce7; color: #14532d; font-weight: 600; margin-bottom: 12px; }
.ag-tabs { display: flex; gap: 6px; flex-wrap: wrap; margin: 12px 0 6px; }
.ag-tabs button { border: 1px solid var(--line); background: var(--card, #fff); color: inherit; border-radius: 999px; padding: 7px 14px; font: inherit; font-weight: 600; display: inline-flex; gap: 6px; align-items: center; cursor: pointer; }
.ag-tabs button[aria-selected="true"] { background: var(--primary); border-color: var(--primary); color: var(--on-primary); }
.ag-steps { margin: 10px 0 14px; padding-left: 22px; display: grid; gap: 6px; }
.ag-feats { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 10px; }
.ag-feats > div { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; border-radius: 12px; background: var(--soft, #f3f6fc); }
.ag-feats strong { display: block; }
.ag-feats span { font-size: 14px; color: var(--muted); }
.ag-feats strong { color: var(--text); }

/* ---------------- 1.27.0 — Écrans pliables (iPhone Duo et autres) ----------------
   Plié : ~466 px de large. Déplié : ~669 px en portrait, ~951 px en paysage. Écran partagé : ~330 px par application.
   La place réelle du contenu décide du nombre de colonnes (requêtes de conteneur), pas la seule largeur de l'écran. */
@container content (min-width: 600px) and (max-width: 900px) {
  .g-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .g-3, .g-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .g-side-l { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .g-side-l > :last-child { grid-column: span 2; }
  .modal { width: min(600px, calc(100vw - 48px)); }
}
/* Îlot dynamique sur le côté (paysage, plié ou déplié) : les marges suivent la zone sûre de chaque bord. */
@media (max-width: 900px) {
  body:not(.chat-page) .content { padding-left: calc(14px + var(--sal)); padding-right: calc(14px + var(--sar)); }
  .hero { padding-left: calc(18px + var(--sal)); padding-right: calc(18px + var(--sar)); }
}
@media (min-width: 901px) {
  body:not(.chat-page) .content { padding-right: calc(20px + var(--sar)); }
  .chat-float { right: calc(22px + var(--sar)); }
}
/* Très étroit (application en écran partagé, ~330 px) : on gagne de la place partout. */
@media (max-width: 380px) {
  body:not(.chat-page) .content { padding-left: calc(10px + var(--sal)); padding-right: calc(10px + var(--sar)); }
  .hero h1 { font-size: 22px; }
  .toolbar { gap: 6px; }
  .toolbar .btn { padding-left: 10px; padding-right: 10px; }
  .card { padding-left: 14px; padding-right: 14px; }
  .modal { width: calc(100vw - 12px); border-radius: 14px; }
  .chips { gap: 6px; }
  .ag-feats { grid-template-columns: minmax(0, 1fr); }
  .chat-float .cf-label { display: none; }
}
/* Écran à deux segments (pliure visible, API « viewport segments ») : les fenêtres se placent dans un seul segment,
   le contenu en deux colonnes s'aligne de part et d'autre de la pliure. */
@media (horizontal-viewport-segments: 2) {
  .modal { margin-left: env(viewport-segment-left 1 0, auto); margin-right: auto; width: min(560px, calc(env(viewport-segment-width 1 0, 50vw) - 24px)); }
  .g-2, .dash { column-gap: calc(env(viewport-segment-left 1 0, 0px) - env(viewport-segment-right 0 0, 0px) + 18px); }
}
@media (vertical-viewport-segments: 2) {
  .modal { margin-top: env(viewport-segment-top 0 1, auto); max-height: calc(env(viewport-segment-height 0 1, 50vh) - 16px); }
}

/* Corbeille */
.trash-filter { width: 100%; margin-bottom: 10px; }
.trash-day { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); padding: 12px 2px 4px; }
.trash-card .row { gap: 10px; flex-wrap: wrap; }
.trash-card .row .row-main { flex: 1 1 200px; }

/* Questionnaire de satisfaction */
.nps-card { margin-bottom: 16px; border: 1px solid #fbcfe8; background: linear-gradient(135deg, #fff1f7, var(--card, #fff) 60%); }
.nps-h { display: flex; gap: 12px; align-items: flex-start; }
.nps-h > .i { color: #db2777; width: 26px; height: 26px; flex: none; margin-top: 2px; }
.nps-h > div { flex: 1; }
.nps-h p { margin: 2px 0 0; }
.nps-scale { display: grid; grid-template-columns: repeat(11, minmax(0, 1fr)); gap: 5px; margin-top: 12px; }
.nps-scale label { position: relative; }
.nps-scale input { position: absolute; opacity: 0; inset: 0; }
.nps-scale span { display: grid; place-items: center; height: 40px; border-radius: 10px; border: 1px solid var(--line); background: var(--card, #fff); font-weight: 700; cursor: pointer; transition: background .12s; }
.nps-scale label:hover span { border-color: #db2777; }
.nps-scale input:checked + span { background: #db2777; border-color: #db2777; color: #fff; }
.nps-scale input:focus-visible + span { outline: 2px solid var(--primary); outline-offset: 2px; }
.nps-legend { display: flex; justify-content: space-between; margin-top: 4px; }
.nps-more { margin-top: 12px; }
@media (max-width: 420px) { .nps-scale { gap: 3px; } .nps-scale span { height: 34px; font-size: 13px; border-radius: 8px; } }
.us-react { margin: 4px 0 0; padding-left: 18px; display: grid; gap: 3px; }
.nps-res { display: flex; gap: 18px; align-items: center; flex-wrap: wrap; }
.nps-score b { font-size: 38px; line-height: 1; display: block; }
.nps-score span { font-size: 12px; color: var(--muted); }
.nps-split { display: grid; gap: 2px; }
.nps-bars { display: grid; grid-template-columns: repeat(11, minmax(0, 1fr)); gap: 4px; height: 110px; margin: 14px 0 6px; align-items: end; }
.nps-bars > div { height: 100%; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: 3px; }
.nps-bars i { display: block; width: 100%; border-radius: 4px 4px 0 0; }
.nps-bars i.pro { background: #16a34a; } .nps-bars i.pas { background: #94a3b8; } .nps-bars i.det { background: #dc2626; }
.nps-bars small { font-size: 11px; color: var(--muted); }
.nps-comments blockquote { margin: 8px 0 0; padding: 8px 12px; border-left: 3px solid #fbcfe8; background: var(--soft, #f8fafc); border-radius: 0 8px 8px 0; font-size: 14px; }
.nps-comments blockquote b { display: inline-grid; place-items: center; min-width: 22px; height: 22px; border-radius: 6px; background: #fce7f3; color: #9d174d; font-size: 12px; margin-right: 4px; }
@media (max-height: 760px) { .nav a, .nav .nav-off { padding-top: 5px; padding-bottom: 5px; font-size: 14px; } .nav .nav-group { padding-top: 6px; } .brand { padding-bottom: 8px; } }
.nav .nav-group.nav-group-sep { padding: 0; height: 1px; margin: 6px 12px; cursor: default; }
@media (max-height: 800px) {
  .side-donate { padding: 5px 10px; margin-bottom: 6px; font-size: 13px; }
  .side-storage { margin-bottom: 6px; padding-top: 5px; padding-bottom: 6px; }
  .sidebar .side-foot { padding-top: 8px; }
  .sidebar .brand small { display: none; }
}

/* ---------------- Administration › Audit d'usage ---------------- */
.au-bar { display: flex; flex-wrap: wrap; gap: 10px 18px; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.au-bar > p { flex: 1 1 420px; margin: 0; }
.au-tools { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.au-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 12px; margin-bottom: 18px; }
.au-kpis > div { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px; display: grid; gap: 2px; }
.au-kpis small { color: var(--muted); font-size: 12px; font-weight: 600; }
.au-kpis strong { font-size: 26px; line-height: 1.15; color: var(--text); }
.au-kpis span { font-size: 12px; color: var(--muted); }
.au-tr { display: inline-block; font-size: 11.5px; font-weight: 700; padding: 0 6px; border-radius: 99px; background: var(--line-2); color: var(--muted); }
.au-tr.up { background: #dcfce7; color: #166534; } .au-tr.down { background: #fee2e2; color: #991b1b; }
.au-h { display: flex; align-items: center; gap: 8px; font-size: 18px; margin: 26px 0 10px; }
.au-h .i { color: var(--primary-ink, var(--primary)); }
.au-sub { font-size: 13px; margin: 14px 0 6px; color: var(--text); }
.au-hbars, .au-funnel { display: grid; gap: 6px; }
.au-hb, .au-funnel > div { display: grid; grid-template-columns: minmax(90px, 38%) 1fr auto 42px; gap: 8px; align-items: center; font-size: 13px; }
.au-hb-l, .au-funnel > div > span:first-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.au-hb-t { display: block; height: 10px; border-radius: 99px; background: var(--line-2); overflow: hidden; }
.au-hb-t i { display: block; height: 100%; border-radius: 99px; background: var(--primary); }
.au-hb b, .au-funnel b { font-variant-numeric: tabular-nums; text-align: right; }
.au-hb small, .au-funnel small { color: var(--muted); text-align: right; font-variant-numeric: tabular-nums; }
.au-feat .au-hb { grid-template-columns: minmax(140px, 46%) 1fr auto 42px; }
.au-mini { gap: 10px 22px; }
.au-cols { position: relative; display: grid; grid-template-columns: repeat(var(--n), minmax(0, 1fr)); gap: 2px; align-items: end; height: 150px; padding-top: 16px; border-bottom: 1px solid var(--line); }
.au-col { height: 100%; display: flex; align-items: flex-end; }
.au-col i { display: block; width: 100%; border-radius: 4px 4px 0 0; background: var(--primary); min-height: 0; }
.au-col:hover i { filter: brightness(1.15); }
.au-cols-max { position: absolute; top: 0; left: 0; font-size: 11px; color: var(--muted); }
.au-cols-x { display: flex; justify-content: space-between; font-size: 11px; color: var(--muted); margin-top: 4px; }
.au-heat { display: grid; gap: 3px; margin: 4px 0 8px; }
.au-heat-r { display: grid; grid-template-columns: 34px repeat(12, minmax(0, 1fr)); gap: 3px; align-items: center; font-size: 11px; color: var(--muted); }
.au-heat-r > span[role="cell"] { height: 22px; border-radius: 4px; background: color-mix(in srgb, var(--primary) calc(var(--a) * 100%), var(--line-2)); }
.au-heat-h span { text-align: left; }
.au-coh { width: 100%; border-collapse: separate; border-spacing: 3px; font-size: 13px; }
.au-coh th { font-size: 12px; color: var(--muted); font-weight: 600; text-align: center; }
.au-coh th:first-child, .au-coh td:first-child { text-align: left; }
.au-coh td { text-align: center; padding: 6px 8px; border-radius: 6px; font-variant-numeric: tabular-nums; }
.au-coh-c { background: color-mix(in srgb, #16a34a calc(var(--a) * 85%), var(--card)); color: var(--text); font-weight: 600; }
.au-mods { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.au-mods th { text-align: left; font-size: 12px; color: var(--muted); font-weight: 600; padding: 6px 8px; border-bottom: 1px solid var(--line); }
.au-mods td { padding: 7px 8px; border-bottom: 1px solid var(--line-2); font-variant-numeric: tabular-nums; }
.au-mods .r { text-align: right; }
.au-mods tr.au-zero td { color: var(--muted); }
.au-mod { display: inline-flex; gap: 8px; align-items: center; white-space: nowrap; }
.au-adopt { display: grid; grid-template-columns: minmax(80px, 1fr) 46px 40px; gap: 6px; align-items: center; min-width: 190px; }
.au-adopt b { text-align: right; } .au-adopt small { color: var(--muted); }
.au-help { margin-top: 12px; } .au-help code { word-break: break-all; font-size: 12px; }
@media (max-width: 560px) { .au-hb, .au-funnel > div { grid-template-columns: minmax(80px, 40%) 1fr auto; } .au-hb small, .au-funnel small { display: none; } }
/* Confirmation d'une demande d'assistance (1.29) */
.sup-preview { margin: 0 0 18px; padding: 14px 16px; border-radius: 14px; background: var(--bg); border: 1px solid var(--line); }
.sup-preview p { margin: 6px 0 8px; font-size: 14.5px; white-space: normal; }
/* Administration : activité en direct (1.30) */
.lv-pulse { width: 12px; height: 12px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 0 color-mix(in srgb, var(--green) 60%, transparent); animation: lvPulse 2s infinite; }
@keyframes lvPulse { 70% { box-shadow: 0 0 0 10px transparent; } 100% { box-shadow: 0 0 0 0 transparent; } }
@media (prefers-reduced-motion: reduce) { .lv-pulse { animation: none; } }
.lv-card { margin-bottom: 22px; }
.lv-kpis { display: grid; grid-template-columns: repeat(2, minmax(160px, 1fr)) minmax(260px, 2fr); gap: 14px; margin-bottom: 18px; }
.lv-kpi { padding: 14px 16px; border: 1px solid var(--line); border-radius: 14px; display: grid; grid-template-columns: auto 1fr; column-gap: 10px; align-items: baseline; }
.lv-kpi strong { font-size: 30px; line-height: 1.1; color: var(--heading); grid-column: 2; }
.lv-kpi small { grid-column: 2; color: var(--text); font-size: 14px; }
.lv-kpi em { grid-column: 2; font-style: normal; color: var(--muted); font-size: 12.5px; margin-top: 2px; }
.lv-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--primary); grid-row: 1; align-self: center; }
.lv-dot.g { background: var(--green); }
.lv-spark { padding: 12px 16px; border: 1px solid var(--line); border-radius: 14px; display: flex; flex-direction: column; gap: 6px; }
.lv-spark small { color: var(--muted); font-size: 12.5px; }
.lv-bars { flex: 1; min-height: 64px; display: flex; align-items: flex-end; gap: 2px; }
.lv-bars i { flex: 1; height: max(var(--h), 3px); background: var(--primary); border-radius: 3px 3px 0 0; }
.lv-bars i.z { background: var(--line); }
.lv-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 22px; }
.lv-col h3 { font-size: 14.5px; display: flex; gap: 8px; align-items: center; margin: 0 0 10px; color: var(--heading); }
.lv-col h3:not(:first-child) { margin-top: 18px; }
.lv-people { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; max-height: 460px; overflow: auto; }
.lv-people li { display: grid; grid-template-columns: auto 1fr auto; gap: 12px; align-items: center; padding: 9px 4px; border-bottom: 1px solid var(--line-2); }
.lv-people li:last-child { border-bottom: 0; }
.lv-who, .lv-where { display: flex; flex-direction: column; min-width: 0; }
.lv-who strong a { color: var(--heading); }
.lv-where { text-align: right; font-size: 14px; }
.lv-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.lv-list li { position: relative; display: flex; justify-content: space-between; gap: 10px; padding: 6px 10px; border-radius: 8px; font-size: 14px; overflow: hidden; }
.lv-list li i { position: absolute; inset: 0 auto 0 0; width: var(--w); background: var(--primary-soft); z-index: 0; }
.lv-list li span, .lv-list li b { position: relative; z-index: 1; }
.lv-foot { margin: 16px 0 0; }
.admin-online { display: inline-flex; align-items: center; gap: 7px; font-size: 13.5px; font-weight: 600; color: var(--green); padding: 5px 11px; border-radius: 999px; background: var(--green-soft); text-decoration: none; }
.admin-online .lv-pulse { width: 8px; height: 8px; }
@media (max-width: 900px) { .lv-kpis, .lv-grid { grid-template-columns: 1fr; } .lv-where { text-align: left; } .lv-people li { grid-template-columns: auto 1fr; } .lv-where { grid-column: 2; } }
/* Connexion par lien magique (1.30) */
.login-or { display: flex; align-items: center; gap: 12px; margin: 16px 0; color: var(--muted); font-size: 13px; }
.login-or::before, .login-or::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.magic-acc { display: flex; align-items: center; gap: 12px; padding: 12px 14px; margin: 0 0 16px; border: 1px solid var(--line); border-radius: 14px; background: var(--bg); }
.magic-acc div { display: flex; flex-direction: column; }
.hdoc-status .hdoc-stop { justify-self: start; margin-top: 6px; }
/* Santé › Remboursements (1.31) */
.hr-stats { grid-template-columns: repeat(5, minmax(0, 1fr)); }
@media (max-width: 1100px) { .hr-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.hr-late-n { color: var(--red); }
.hr-filter { margin: 4px 0 8px; }
.hr-note { margin: 0 0 14px; }
.hr-list { list-style: none; margin: 0; padding: 0; }
.hr-row { display: grid; grid-template-columns: auto 1fr auto auto; gap: 14px; align-items: start; padding: 14px 4px; border-bottom: 1px solid var(--line-2); scroll-margin-top: 90px; }
.hr-row:last-child { border-bottom: 0; }
.hr-row:target { background: var(--primary-soft); border-radius: 12px; }
.hr-row.is-late .daychip { border-color: color-mix(in srgb, var(--red) 45%, transparent); }
.hr-what { min-width: 0; display: grid; gap: 8px; }
.hr-title { display: flex; gap: 10px; align-items: center; }
.hr-title > div { display: flex; flex-direction: column; min-width: 0; }
.hr-title .av { vertical-align: -4px; }
.hr-sides { display: flex; flex-wrap: wrap; gap: 8px; }
.hr-pill { display: inline-flex; align-items: center; gap: 8px; padding: 5px 6px 5px 10px; border: 1px solid var(--line); border-radius: 10px; font-size: 13px; background: var(--card); }
.hr-pill .hr-who { color: var(--muted); font-weight: 600; }
.hr-pill .hr-amt { font-weight: 700; color: var(--heading); font-variant-numeric: tabular-nums; }
.hr-pill.hr-late { border-color: color-mix(in srgb, var(--red) 40%, transparent); background: var(--red-soft); }
.hr-pill.hr-tosend { border-color: color-mix(in srgb, var(--orange) 40%, transparent); background: var(--orange-soft); }
.hr-money { text-align: right; display: flex; flex-direction: column; font-variant-numeric: tabular-nums; }
.hr-money strong { font-size: 16px; color: var(--heading); }
.hr-mini { width: 100%; border-collapse: collapse; font-size: 13.5px; font-variant-numeric: tabular-nums; }
.hr-mini th { text-align: right; font-weight: 600; color: var(--muted); font-size: 12px; padding: 0 0 6px; }
.hr-mini td { text-align: right; padding: 7px 0; border-top: 1px solid var(--line-2); white-space: nowrap; }
.hr-mini td:first-child, .hr-mini th:first-child { text-align: left; }
.hr-bars { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.hr-bars li { display: grid; grid-template-columns: 1fr auto; gap: 3px 10px; font-size: 13.5px; }
.hr-bars li b { font-variant-numeric: tabular-nums; }
.hr-bars i { grid-column: 1 / -1; height: 8px; border-radius: 4px; background: var(--line-2); position: relative; overflow: hidden; }
.hr-bars i::before { content: ""; position: absolute; inset: 0 auto 0 0; width: var(--w); background: var(--c); border-radius: 4px; opacity: .85; }
.hr-bars small { grid-column: 1 / -1; font-size: 12px; }
.hr-help ul { margin: 0; padding-left: 18px; display: grid; gap: 8px; }
.hr-card { display: block; color: inherit; text-decoration: none; }
.hr-card:hover { border-color: color-mix(in srgb, var(--green) 40%, var(--line)); }
.hr-card-kpis { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.hr-card-kpis > div { display: flex; flex-direction: column; }
.hr-card-kpis small { color: var(--muted); font-size: 12.5px; }
.hr-card-kpis strong { font-size: 20px; color: var(--heading); font-variant-numeric: tabular-nums; }
.hr-card-alert { margin: 10px 0 0; color: var(--red); font-weight: 600; }
.hr-card-go { display: inline-flex; align-items: center; gap: 4px; margin-top: 12px; font-size: 13.5px; font-weight: 600; color: var(--primary-ink); }
.hr-calc-out output { display: block; padding: 10px 0 0; }
@media (max-width: 700px) {
  .hr-row { grid-template-columns: auto minmax(0, 1fr); gap: 10px 12px; }
  .hr-row .daychip { grid-row: 1 / span 2; }
  .hr-row .hr-what { grid-column: 2; grid-row: 1; }
  .hr-row .hr-money { grid-column: 2; grid-row: 2; text-align: left; flex-direction: row; gap: 8px; align-items: baseline; padding-right: 44px; }
  .hr-row .icon-btn { grid-column: 2; grid-row: 2; justify-self: end; align-self: center; }
  .hr-pill { flex-wrap: wrap; max-width: 100%; row-gap: 4px; }
  .hr-stats { gap: 10px; }
}
.hr-filter select { width: auto; min-width: 150px; flex: 0 0 auto; }
/* Remboursements : consultation, contrats, décomptes (1.32) */
.hcon-refund { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; margin: 10px 0 4px; padding-top: 10px; border-top: 1px dashed var(--line); }
.hr-unlinked { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; }
.hr-unlinked > span { flex: 1 1 260px; display: flex; flex-direction: column; gap: 2px; }
.hr-row .hcon-files { margin-top: 2px; }
.hr-contract-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.hr-contract-list > li { padding-bottom: 12px; border-bottom: 1px solid var(--line-2); }
.hr-contract-list > li:last-child { border-bottom: 0; padding-bottom: 0; }
.hr-ct-h { display: flex; align-items: center; gap: 8px; }
.hr-ct-h .muted { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hr-ct-rules { list-style: none; margin: 6px 0 0; padding: 0; display: grid; gap: 4px; }
.hr-ct-rules li { display: grid; grid-template-columns: 1fr auto; gap: 2px 8px; }
.hr-ct-rules li b { font-weight: 600; color: var(--heading); }
.hr-ct-bar { grid-column: 1 / -1; height: 5px; border-radius: 3px; background: var(--line-2); position: relative; overflow: hidden; }
.hr-ct-bar::before { content: ""; position: absolute; inset: 0 auto 0 0; width: var(--w); background: var(--teal); }
.hr-ct-rules em { grid-column: 1 / -1; font-style: normal; font-size: 12px; }
.hr-presets { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin: 0 0 12px; }
.hr-rules { width: 100%; border-collapse: collapse; margin: 0 0 14px; font-size: 14px; }
.hr-rules th, .hr-rules td { padding: 5px 6px; border-bottom: 1px solid var(--line-2); text-align: left; }
.hr-rules thead th { font-size: 12px; color: var(--muted); font-weight: 600; }
.hr-rules tbody th { font-weight: 500; }
.hr-rules input { width: 100%; min-width: 70px; padding: 7px 9px; }
.hr-rules tbody tr:first-child th { font-weight: 700; }
.hr-recap-t { margin-top: 12px; }
.hr-dec { width: 100%; border-collapse: collapse; font-size: 13.5px; margin: 0 0 14px; }
.hr-dec th { text-align: left; font-size: 12px; color: var(--muted); font-weight: 600; padding: 0 6px 6px; }
.hr-dec td { padding: 7px 6px; border-top: 1px solid var(--line-2); vertical-align: top; }
.hr-dec input[type=text] { width: 86px; padding: 6px 8px; }
.hr-dec-diff { display: block; color: var(--orange); margin-top: 2px; }
.hr-dec-left { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.hr-dec-left li { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 13.5px; }
.hr-dec-left li > span { flex: 1 1 200px; }
.hr-dec-left select { max-width: 320px; }
.hr-dec-left input { width: 90px; padding: 6px 8px; }
@media (max-width: 700px) { .hr-dec thead { display: none; } .hr-dec tr { display: grid; grid-template-columns: auto 1fr; gap: 4px 8px; padding: 8px 0; border-top: 1px solid var(--line-2); } .hr-dec td { border: 0; padding: 2px 0; } }
/* Glisser-déposer sur les champs de fichier (1.33) */
.fz-drop-hint { display: block; margin-top: 4px; font-size: 12px; color: var(--muted); font-weight: 400; }
.fz-dragging .fz-dz { outline: 2px dashed color-mix(in srgb, var(--primary) 55%, transparent); outline-offset: 4px; border-radius: 10px; transition: outline-color .15s, background-color .15s; }
.fz-dragging .fz-dz.fz-over, .fz-dz.fz-over { outline-color: var(--primary); background: var(--primary-soft); }
/* Préférence du menu (Mon profil › Préférences) */
.nav-pref { display: grid; gap: 8px; }
.nav-pref-opt { display: flex; gap: 12px; align-items: flex-start; padding: 11px 14px; border: 1px solid var(--line); border-radius: 12px; cursor: pointer; }
.nav-pref-opt:has(input:checked) { border-color: var(--primary); background: var(--primary-soft); }
.nav-pref-opt input { margin-top: 3px; accent-color: var(--primary); }
.nav-pref-opt span { display: flex; flex-direction: column; gap: 2px; }
.nav-pref-opt small { font-size: 13px; }
/* Page d'accueil : modules proposés en partenariat (1.33.3) */
.lp-partner { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; margin: 8px 0 0; font-size: 12.5px; color: var(--muted); }
.lp-partner a { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); text-decoration: none; font-weight: 600; }
.lp-partner a:hover span { text-decoration: underline; color: var(--text); }
.lp-partner img { display: block; width: auto; border-radius: 3px; }
.lp-row-txt .lp-partner { margin-top: 18px; font-size: 13.5px; }
.lp-mods small.lp-partner { display: flex; margin-top: 8px; }
/* Barre latérale fixe en largeur : jamais de défilement horizontal (1.33.5) */
.sidebar, .sidebar .nav { overflow-x: hidden; }
.sidebar .nav > * { max-width: 100%; min-width: 0; }
.nav .nav-group.nav-group-sep { width: auto; flex: none; align-self: stretch; }
.side-search { min-width: 0; max-width: 100%; }
.side-search span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.side-search kbd { flex: none; }
.nav a > span, .nav .nav-off > span { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
/* Santé : prises ponctuelles de médicaments (1.34) */
.hd-card .rows { display: grid; gap: 0; }
.hd-row { align-items: flex-start; gap: 12px; scroll-margin-top: 90px; }
.hd-time { display: flex; flex-direction: column; align-items: center; min-width: 48px; padding-top: 2px; font-variant-numeric: tabular-nums; }
.hd-time strong { font-size: 15px; color: var(--heading); }
.hd-time small { font-size: 11.5px; color: var(--muted); }
.hd-reason { display: inline-flex; align-items: center; gap: 4px; padding: 1px 8px; border-radius: 999px; font-weight: 600; font-size: 12.5px; color: var(--c); background: color-mix(in srgb, var(--c) 12%, transparent); }
.hd-day { margin: 14px 0 2px; font-size: 12.5px; font-weight: 700; color: var(--muted); text-transform: capitalize; }
.hd-day:first-of-type { margin-top: 4px; }
.hd-month { margin: 0 0 6px; padding: 8px 12px; border-radius: 10px; background: var(--bg); }
.hd-last { margin: 0 0 12px; font-size: 13.5px; display: grid; gap: 2px; }
div:target > .hd-row { background: var(--primary-soft); border-radius: 12px; }
.hd-last { background: color-mix(in srgb, #f59e0b 14%, var(--card)); border: 1px solid color-mix(in srgb, #f59e0b 45%, transparent); color: var(--text); }
.hd-last strong { color: color-mix(in srgb, #b45309 80%, var(--heading)); }
.hd-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 12px; margin-top: 3px; }
.hd-meta > span { display: inline-flex; align-items: center; gap: 4px; }

/* ===== 1.35 : bandeau des modules (action principale), résumé, messagerie dans la barre du haut, barre d'action mobile ===== */
.hero-act { margin-left: auto; display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px; position: relative; z-index: 2; flex: none; }
.hero.has-act .hero-quote { display: none; }
.hero-act .btn { white-space: nowrap; }
.psum { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 10px; margin: 0 0 18px; }
.psum-i { display: flex; align-items: center; gap: 12px; min-width: 0; padding: 12px 14px; background: var(--card, #fff); border: 1px solid var(--line); border-left: 4px solid var(--line); border-radius: var(--radius-sm, 12px); color: var(--text); text-decoration: none; transition: border-color .15s, box-shadow .15s; }
a.psum-i:hover { border-color: #cbd5e1; box-shadow: 0 4px 14px rgba(15, 23, 42, .06); }
.psum-ic { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; flex: none; background: var(--line-2, #f1f5f9); color: var(--muted); }
.psum-ic .i { width: 18px; height: 18px; }
.psum-t { display: grid; min-width: 0; line-height: 1.2; }
.psum-t b { font-size: 21px; font-weight: 800; font-variant-numeric: tabular-nums; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.psum-t small { font-size: 13px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.psum-t em { font-style: normal; font-size: 12px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.psum-i.t-danger { border-left-color: var(--red, #dc2626); }
.psum-i.t-danger b, .psum-i.t-danger .psum-ic { color: var(--red, #dc2626); }
.psum-i.t-danger .psum-ic { background: var(--red-soft, #fee2e2); }
.psum-i.t-warn { border-left-color: #f59e0b; }
.psum-i.t-warn .psum-ic { background: #fef3c7; color: #b45309; }
.psum-i.t-ok { border-left-color: var(--green, #16a34a); }
.psum-i.t-ok .psum-ic { background: #dcfce7; color: #15803d; }
.psum-i.t-info { border-left-color: var(--primary); }
.psum-i.t-info .psum-ic { background: var(--primary-soft); color: var(--primary); }
.me .chat-ic { position: relative; }
.me .chat-ic .bell-n { border-color: var(--navy, #0b1d3a); }
.hero .chat-m { display: none; position: absolute; top: calc(12px + var(--sat, 0px)); left: calc(104px + var(--sal, 0px)); z-index: 3; background: rgba(0, 0, 0, .3); color: #fff !important; }
.hero .chat-m .bell-n { border-color: transparent; }
.chat-float { right: calc(22px + var(--sar, 0px)); bottom: calc(22px + var(--sab, 0px)); }
.mob-act { display: none; }
@media (max-width: 900px) {
  .hero .chat-m { display: grid; }
  .hero:has(.chat-m) .search-m { left: calc(150px + var(--sal, 0px)); }
  .hero:has(.chat-m) .sos-m { left: calc(196px + var(--sal, 0px)); }
}
@media (max-width: 760px) {
  .hero-act { display: none; }
  .psum { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin-bottom: 14px; }
  .psum-i { padding: 10px 11px; gap: 9px; }
  .psum-ic { width: 30px; height: 30px; }
  .psum-t b { font-size: 18px; }
  .psum-t small { font-size: 12px; white-space: normal; }
  .psum-t em { display: none; }
  .mob-act { display: flex; gap: 8px; position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; padding: 10px calc(12px + var(--sar, 0px)) calc(10px + var(--sab, 0px)) calc(12px + var(--sal, 0px)); background: color-mix(in srgb, var(--card, #fff) 92%, transparent); backdrop-filter: blur(10px); border-top: 1px solid var(--line); box-shadow: 0 -6px 18px rgba(15, 23, 42, .06); }
  .mob-act .btn { flex: 1 1 0; justify-content: center; min-height: 46px; }
  .mob-act .btn:nth-child(n+3) { display: none; }
  .main:has(.mob-act) .foot { padding-bottom: calc(86px + var(--sab, 0px)); }
  .main:has(.mob-act) ~ .chat-float, body:has(.mob-act) .chat-float { bottom: calc(80px + var(--sab, 0px)); }
}
.card-late { border-left: 4px solid var(--red, #dc2626); }
@media (min-width: 901px) { .me { gap: 2px; } .me .icon-btn { width: 29px; height: 29px; } .me .icon-btn .i { width: 17px; height: 17px; } }
.card-opts { padding: 0; }
.card-opts > summary { list-style: none; display: flex; align-items: center; gap: 10px; padding: 14px 18px; cursor: pointer; font-weight: 700; color: var(--muted); }
.card-opts > summary::-webkit-details-marker { display: none; }
.card-opts > summary span { flex: 1; }
.card-opts > summary .i:last-child { transition: transform .2s; }
.card-opts[open] > summary .i:last-child { transform: rotate(180deg); }
.card-opts > summary:hover { color: var(--text); }
.card-opts .opts-in { padding: 0 18px 16px; display: grid; gap: 14px; }
.card-opts .opts-in > .card { padding: 0; border: 0; box-shadow: none; background: none; }
.cal-nav, .wk-nav { flex-wrap: nowrap !important; }
.cal-nav strong { min-width: 0 !important; white-space: nowrap; }
.wk-nav { display: flex; align-items: center; gap: 8px; }
.wk-nav strong { white-space: nowrap; }
/* En-têtes de carte : le titre se replie sur deux lignes plutôt que de rejeter « + » et « → » seuls sur une ligne. */
.card-h h2 { flex: 1 1 150px; min-width: 0; }
.card-h > .icon-btn, .card-h > .more { flex: none; }
.psum-t small, .psum-t em { white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.fin-help { margin-top: 12px; }
.fin-help > summary { cursor: pointer; font-size: 13px; font-weight: 700; color: var(--muted); list-style: none; display: flex; align-items: center; gap: 6px; }
.fin-help > summary::-webkit-details-marker { display: none; }
.fin-help p { margin: 8px 0 0; }
.cd-n b.cd-late { color: var(--red, #dc2626); font-size: 13px; }
/* Courses : article à valider — sur petit écran, les boutons passent sous le texte au lieu de l'écraser. */
.row.pending { flex-wrap: wrap; }
.row.pending .row-main { flex: 1 1 160px; }
.row.pending .actions { display: flex; gap: 6px; flex-wrap: wrap; }
@media (max-width: 560px) { .row.pending .actions { width: 100%; padding-left: 50px; } }
/* Repas sur téléphone : la semaine tient dans l'écran (icônes des repas, cases compactes) au lieu de défiler de côté. */
@media (max-width: 560px) {
  .meal-grid { grid-template-columns: 46px repeat(3, minmax(0, 1fr)); gap: 4px; overflow: visible; }
  .meal-grid .mh { padding: 8px 2px; font-size: 0; gap: 0; }
  .meal-grid .mh .i { width: 18px; height: 18px; }
  .meal-grid .md { padding: 6px 2px; }
  .meal-grid .md strong { font-size: 13px; }
  .meal-grid .md small { font-size: 10px; }
  .meal-grid .meal-cell { padding: 6px; font-size: 12px; gap: 4px; min-height: 44px; }
  .meal-grid .meal-cell .ic-bubble { display: none; }
  .meal-grid .meal-cell.empty-cell { font-size: 0; justify-content: center; }
  .meal-grid .meal-cell.empty-cell .i { width: 16px; height: 16px; }
}
/* Carnet de santé : les onglets restent sur une ligne (défilement horizontal si l'écran est trop étroit). */
.htabs { flex-wrap: nowrap; gap: 2px; }
.htabs a { padding: 8px 10px; font-size: 13.5px; flex: none; }
.toolbar .inline-form { display: flex; gap: 8px; flex-wrap: wrap; }
.toolbar .inline-form select { width: auto; }
.card-opts { margin-top: 16px; }

/* ---------- Wallet : cartes de fidélité ---------- */
.wal-bar { display: flex; gap: 10px; align-items: center; justify-content: space-between; max-width: 460px; margin: 0 auto 16px; }
body:has(.wal.is-grid-view) .wal-bar { max-width: none; }
.wal-search { flex: 1; min-width: 0; display: flex; align-items: center; gap: 8px; background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 0 12px; }
.wal-search .i { width: 17px; height: 17px; color: var(--muted); flex: none; }
.wal-search input { border: 0; background: none; padding: 10px 0; min-width: 0; width: 100%; outline: none; box-shadow: none; }
.wal-bar .seg button { display: inline-flex; align-items: center; gap: 6px; }
.wal-bar .seg .i { width: 16px; height: 16px; }
.wal { max-width: 460px; margin: 0 auto; }
.wal.is-grid-view { max-width: none; }
.wal-stage { position: relative; padding-bottom: 6px; }
.wal-stage > .wcard { position: absolute; left: 0; right: 0; top: 0; transform-origin: 50% 0; will-change: transform; }
.wal-stage.anim > .wcard { transition: transform .5s cubic-bezier(.2, .8, .2, 1), opacity .3s ease, box-shadow .3s; }
.wal-stage.anim { transition: height .5s cubic-bezier(.2, .8, .2, 1); }
.wal-stage.has-sel { clip-path: inset(-40px -40px 0 -40px); }
.wal-stage > .wcard[hidden] { display: none; }
.wal-stage > .wcard.is-gone { opacity: 0; pointer-events: none; }
.wal-stage > .wcard.in-stack { box-shadow: 0 -4px 14px -6px rgba(15, 35, 66, .35); }
.wal-stage.is-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 16px; height: auto !important; overflow: visible; margin: 0; padding: 0; }
.wal-stage.is-grid > .wcard { position: relative; transform: none !important; z-index: auto !important; }
.wal-stage.is-grid > .wal-sheet { display: none; }

.wcard { aspect-ratio: 1.586; border-radius: 16px; padding: 16px 18px; color: #fff; display: flex; flex-direction: column; justify-content: space-between; overflow: hidden; position: relative; cursor: pointer; user-select: none; -webkit-tap-highlight-color: transparent;
  background: linear-gradient(112deg, transparent 0 44%, rgba(255, 255, 255, .08) 44% 63%, transparent 63%), linear-gradient(135deg, var(--wc, #0e7490), var(--wc2, #08465a));
  box-shadow: 0 12px 26px -12px rgba(15, 35, 66, .55), 0 2px 6px rgba(15, 35, 66, .12), inset 0 1px 0 rgba(255, 255, 255, .18); }
.wcard:focus-visible { outline: 3px solid var(--primary); outline-offset: 3px; }
.wcard.is-light { color: #111827; }
.wc-top { display: flex; align-items: center; gap: 12px; min-width: 0; }
.wc-logo { width: 40px; height: 40px; border-radius: 12px; background: #fff; flex: none; display: grid; place-items: center; overflow: hidden; box-shadow: 0 1px 3px rgba(0, 0, 0, .18); position: relative; }
.wc-logo img { width: 30px; height: 30px; object-fit: contain; grid-area: 1 / 1; }
.wc-logo b { grid-area: 1 / 1; font-size: 19px; font-weight: 800; color: var(--wc, #0e7490); line-height: 1; }
.wc-logo.has-img b { display: none; }
.wc-name { font-weight: 800; font-size: 17px; letter-spacing: -.01em; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; text-shadow: 0 1px 1px rgba(0, 0, 0, .12); }
.is-light .wc-name { text-shadow: none; }
.wc-fav, .wc-priv { flex: none; display: inline-flex; opacity: .92; }
.wc-fav { margin-left: auto; color: #fde047; }
.is-light .wc-fav { color: #a16207; }
.wc-fav .i { fill: currentColor; width: 17px; height: 17px; }
.wc-priv .i { width: 15px; height: 15px; }
.wc-fav + .wc-priv { margin-left: 2px; }
.wc-name + .wc-priv { margin-left: auto; }
.wc-exp { position: absolute; left: 18px; top: 66px; font-size: 11.5px; font-weight: 700; padding: 3px 9px; border-radius: 999px; background: rgba(0, 0, 0, .28); color: #fff; }
.wc-exp.expired { background: #dc2626; }
.wc-exp.soon { background: #f59e0b; color: #1f1300; }
.wc-bot { display: flex; align-items: flex-end; justify-content: space-between; gap: 10px; min-width: 0; }
.wc-holder { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; opacity: .88; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.wc-num { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 15px; letter-spacing: .08em; white-space: nowrap; opacity: .95; overflow: hidden; text-overflow: ellipsis; min-width: 0; flex-shrink: 1; max-width: 62%; }
.wc-holder { flex-shrink: 2; }

.wal-sheet { position: absolute; left: 0; right: 0; z-index: 55; }
.wal-sheet:not([hidden]) { animation: wal-in .35s ease .12s both; }
@keyframes wal-in { from { opacity: 0; transform: translateY(-10px); } }
.wal-sheet, .wal-sheet-in { display: flex; flex-direction: column; gap: 12px; }
.ws-code { background: #fff; border: 1px solid #e2e8f0; border-radius: 14px; padding: 14px 12px; display: flex; justify-content: center; align-items: center; min-height: 96px; cursor: zoom-in; box-shadow: 0 1px 2px rgba(15, 35, 66, .06); }
.ws-code svg { display: block; width: 100%; height: auto; max-height: 130px; }
.ws-code.is-2d svg { width: 190px; height: 190px; max-height: none; }
.ws-code .ws-load, .ws-code .ws-nocode { color: #64748b; font-weight: 600; font-size: 14px; }
.ws-num { display: flex; align-items: center; justify-content: center; gap: 6px; margin-top: -4px; }
.ws-num span { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 17px; letter-spacing: .06em; font-weight: 600; color: var(--text); word-break: break-all; text-align: center; }
.ws-act { display: flex; flex-wrap: wrap; gap: 8px; }
.ws-act .btn { flex: 1 1 auto; justify-content: center; }
.ws-act .btn-primary { flex: 2 1 100%; }
.ws-fav.on { color: #b45309; background: var(--yellow-soft, #fef3c7); }
.ws-fav.on .i { fill: currentColor; }
.ws-pin { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; letter-spacing: .25em; font-size: 16px; }
.ws-info { margin: 0; background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 4px 14px; }
.ws-info > div { display: grid; grid-template-columns: 128px 1fr; gap: 10px; padding: 9px 0; border-top: 1px solid var(--line-2); font-size: 14px; }
.ws-info > div:first-child { border-top: 0; }
.ws-info dt { color: var(--muted); font-weight: 600; display: flex; align-items: center; gap: 6px; }
.ws-info dd { margin: 0; min-width: 0; overflow-wrap: anywhere; }
.ws-photos { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.ws-photos button { border: 1px solid var(--line); background: var(--card); border-radius: 12px; padding: 0; overflow: hidden; cursor: zoom-in; position: relative; aspect-ratio: 1.586; }
.ws-photos img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ws-photos span { position: absolute; left: 8px; bottom: 8px; font-size: 12px; font-weight: 700; background: rgba(15, 23, 42, .7); color: #fff; padding: 2px 8px; border-radius: 999px; }
.ws-move { display: flex; align-items: center; justify-content: flex-end; gap: 4px; }
.ws-move span { margin-right: auto; }
.wal-none { text-align: center; padding: 24px 0; }
.wal-dlg .modal-body { display: flex; flex-direction: column; gap: 14px; }
.wal-dlg .wc-in-dlg { cursor: default; }
.wal-photo { padding: 0; background: #000; border: 0; max-width: min(96vw, 900px); }
.wal-photo img { display: block; max-width: 100%; max-height: 86vh; }
.wal-photo .icon-btn { position: absolute; top: 8px; right: 8px; background: rgba(255, 255, 255, .9); color: #0f172a; }

/* Mode caisse : plein écran blanc, code en grand */
.wal-pos { position: fixed; inset: 0; z-index: 1000; background: #fff; color: #0f172a; display: flex; align-items: center; justify-content: center; padding: calc(16px + var(--sat, 0px)) 16px calc(16px + var(--sab, 0px)); overflow: auto; }
.wal-pos[hidden] { display: none; }
body.wal-pos-on { overflow: hidden; }
.wp-in { width: 100%; max-width: 720px; display: flex; flex-direction: column; align-items: center; gap: 14px; text-align: center; }
.wp-head { display: flex; align-items: center; gap: 12px; }
.wp-head .wc-logo { width: 48px; height: 48px; border: 1px solid #e2e8f0; box-shadow: none; }
.wp-head .wc-logo img { width: 38px; height: 38px; }
.wp-head .wc-logo img:not([hidden]) + b { display: none; }
.wp-head strong { font-size: 22px; font-weight: 800; }
.wp-code { width: 100%; display: flex; justify-content: center; padding: 8px 0; }
.wp-code svg { width: 100%; max-width: 680px; height: auto; max-height: 46vh; display: block; }
.wp-code.is-2d svg { width: min(78vw, 46vh, 340px); height: auto; }
.wp-code .wp-photo { max-width: 100%; max-height: 50vh; border-radius: 12px; }
.wp-big { font-size: 34px; font-weight: 800; letter-spacing: .06em; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; word-break: break-all; }
.wp-num { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: clamp(20px, 5.4vw, 30px); font-weight: 700; letter-spacing: .1em; word-break: break-all; }
.wp-holder { font-size: 14px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: #475569; }
.wp-tip { margin: 4px 0 0; font-size: 13px; color: #64748b; display: flex; gap: 6px; align-items: center; }
.wp-tip .i { width: 15px; height: 15px; }
.wp-act { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 6px; }
.wp-act [data-wp-done]:not([hidden]) { flex-basis: 100%; justify-content: center; }
.wal-pos:fullscreen { padding: 16px; }
/* iPhone : pas de verrouillage d'orientation, l'affichage pivote de 90° */
.wal-pos.rot .wp-in { position: fixed; top: 50%; left: 50%; width: 100vh; width: 100dvh; max-width: none; transform: translate(-50%, -50%) rotate(90deg); padding: 0 20px; }
.wal-pos.rot .wp-in { gap: 8px; }
.wal-pos.rot .wp-head .wc-logo { width: 34px; height: 34px; }
.wal-pos.rot .wp-head .wc-logo img { width: 26px; height: 26px; }
.wal-pos.rot .wp-head strong { font-size: 18px; }
.wal-pos.rot .wp-code { padding: 0; }
.wal-pos.rot .wp-code svg { max-height: calc(100vw - 210px); }
.wal-pos.rot .wp-code.is-2d svg { width: calc(100vw - 210px); }
.wal-pos.rot .wp-num { font-size: 20px; }
.wal-pos.rot .wp-act { margin-top: 0; }
.wal-pos.rot .wp-act .btn { padding-top: 7px; padding-bottom: 7px; }
.wal-pos.rot .wp-act [data-wp-done] { flex-basis: auto; }
.wal-pos.rot .wp-tip { display: none; }

/* Fenêtre d'ajout */
/* Wallet : hors ligne, ménage, outils, import, prêt */
.wal-offline { display: flex; align-items: flex-start; gap: 8px; }
.wal-off [data-wal-add], .wal-off .wal-tools, .wal-off .wal-tidy, .wal-off [data-ws-pin], .wal-off [data-ws-fav], .wal-off [data-ws-edit], .wal-off [data-ws-share], .wal-off .ws-move { display: none !important; }
.wal-tidy { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 10px 12px; margin-bottom: 12px; border-radius: 14px; background: #fefce8; border: 1px solid #fde68a; color: #713f12; font-size: 14px; }
.wal-tidy > .i { color: #ca8a04; flex: none; }
.wal-tidy > span { flex: 1; min-width: 180px; }
.wal-tidy .icon-btn { margin-left: -4px; }
.wal-tools { display: flex; gap: 4px; }
.wal-tidy-list { display: flex; flex-direction: column; gap: 6px; max-height: 50vh; overflow: auto; }
.wal-tidy-row { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 12px; cursor: pointer; }
.wal-tidy-row:has(input:checked) { border-color: #fca5a5; background: #fff1f2; }
.wal-tidy-row .row-main { display: flex; flex-direction: column; min-width: 0; }
.wal-tidy-row .row-sub { font-size: 12.5px; color: var(--muted); }
.wal-tidy-row input { flex: none; width: 18px; height: 18px; }
.linkish { border: 0; background: none; padding: 0; font: inherit; font-weight: 700; color: var(--primary-d); text-decoration: underline; cursor: pointer; }
.wim-drop { display: flex; align-items: center; gap: 12px; padding: 14px; margin-bottom: 12px; border: 2px dashed var(--line); border-radius: 14px; cursor: pointer; color: var(--primary-d); }
.wim-drop:hover { border-color: var(--primary); background: var(--primary-soft); }
.wim-drop .i { width: 28px; height: 28px; flex: none; }
.wim-drop > span { display: flex; flex-direction: column; }
.wim-drop small { color: var(--muted); font-size: 12.5px; }
.wim-table { display: flex; flex-direction: column; gap: 6px; max-height: 52vh; overflow: auto; margin-bottom: 12px; }
.wim-row { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 12px; cursor: pointer; }
.wim-row.is-off { opacity: .6; cursor: default; }
.wim-row input { flex: none; width: 18px; height: 18px; }
.wim-main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.wim-num { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 13px; overflow-wrap: anywhere; }
.wim-row .badge { flex: none; }
.wsh-state { display: flex; gap: 6px; align-items: center; margin: 0 0 10px; font-weight: 700; color: #047857; }
.wsh-link { display: flex; gap: 6px; margin-bottom: 12px; }
.wsh-link input { flex: 1; min-width: 0; font-size: 13px; }
.wsh-act { display: flex; flex-wrap: wrap; gap: 8px; }
.wsh-act [data-wsh-send] { flex-basis: 100%; justify-content: center; }
.wsh-act [data-wsh-edit], .wsh-act [data-wsh-stop] { flex: 1; justify-content: center; }
.wim-act { flex-wrap: nowrap; justify-content: space-between; }
.ws-act .btn.on { color: #047857; }
.shop-wcard { margin-left: auto; }
.card-h .shop-wcard + .icon-btn { margin-left: 0; }
.rows .row.is-for { background: #ecfeff; border-radius: 10px; padding-left: 8px; }
/* Page publique d'une carte prêtée */
.wshare-page { background: #eef2f6; }
.wshare { max-width: 460px; margin: 0 auto; padding: 18px 16px 28px; }
.wshare-head { display: flex; align-items: center; gap: 14px; padding: 18px; border-radius: 20px; color: #fff; background: linear-gradient(135deg, var(--wc), var(--wc2)); box-shadow: 0 14px 30px -18px rgba(15, 23, 42, .6); }
.wshare-head.is-light { color: #0f172a; }
.wshare-head h1 { margin: 0; font-size: 22px; }
.wshare-head p { margin: 2px 0 0; font-size: 13.5px; opacity: .88; }
.wshare-head .wc-logo { width: 48px; height: 48px; flex: none; }
.wshare-card { background: #fff; color: #0f172a; border-radius: 20px; padding: 18px 16px; margin-top: 14px; text-align: center; box-shadow: 0 10px 26px -18px rgba(15, 23, 42, .45); }
.wshare-hi { margin: 0 0 12px; font-weight: 700; }
.wshare-code { display: flex; justify-content: center; padding: 10px 6px; min-height: 90px; align-items: center; }
.wshare-code svg { width: 100%; height: auto; max-height: 140px; }
.wshare-code.is-2d svg { width: 220px; height: 220px; max-height: none; }
.wshare-num { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 20px; letter-spacing: .08em; margin-top: 6px; overflow-wrap: anywhere; }
.wshare-holder { margin-top: 4px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; font-size: 13px; color: #475569; }
.wshare-tip { margin: 14px 0 0; font-size: 12.5px; color: #64748b; }
.wshare-foot { text-align: center; font-size: 12.5px; color: #64748b; margin-top: 16px; }
/* Fenêtre d'ajout : le scan en tête, puis l'aperçu de la carte */
.wal-top { margin: -2px 0 14px; }
.wal-top[data-wal-top="start"] .wal-result, .wal-top[data-wal-top="cam"] .wal-result,
.wal-top[data-wal-top="card"] .wal-hero, .wal-top[data-wal-top="cam"] .wal-hero { display: none; }
.wal-hero-btn { display: flex; align-items: center; gap: 14px; width: 100%; text-align: left; padding: 16px; border-radius: 16px; cursor: pointer; font: inherit; color: #fff;
  border: 0; background: linear-gradient(135deg, #0e7490, #155e75 60%, #164e63); box-shadow: 0 10px 24px -12px rgba(14, 116, 144, .8); transition: transform .15s, box-shadow .15s; }
.wal-hero-btn:hover { transform: translateY(-1px); box-shadow: 0 14px 28px -12px rgba(14, 116, 144, .9); }
.wal-hero-btn:focus-visible { outline: 3px solid #67e8f9; outline-offset: 2px; }
.wal-hero-ic { flex: none; width: 54px; height: 54px; border-radius: 14px; background: rgba(255, 255, 255, .16); display: grid; place-items: center; }
.wal-hero-ic .i { width: 30px; height: 30px; }
.wal-hero-t { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.wal-hero-t b { font-size: 17px; }
.wal-hero-t small { font-size: 13px; line-height: 1.35; opacity: .86; }
.wal-hero-go { flex: none; opacity: .7; }
.wal-hero-alt { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 10px; }
.wal-hero-alt .btn { justify-content: center; white-space: nowrap; }
.wal-hero-alt label.btn, .wal-result-act label.btn { cursor: pointer; }
.wal-result { display: flex; flex-direction: column; align-items: center; gap: 8px; }
.wc-preview { width: 100%; max-width: 270px; cursor: default; padding: 12px 14px; }
.wc-preview .wc-name { font-size: 15px; }
.wal-result-act { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; }
.wal-cam { position: relative; border-radius: 16px; overflow: hidden; background: #050b16; aspect-ratio: 4 / 3; max-height: 52vh; width: 100%; }
.wal-cam video { width: 100%; height: 100%; object-fit: cover; display: block; }
.wal-cam-frame { position: absolute; left: 8%; right: 8%; top: 28%; bottom: 28%; border: 2px solid rgba(255, 255, 255, .9); border-radius: 12px; box-shadow: 0 0 0 999px rgba(0, 0, 0, .35); pointer-events: none; }
.wal-cam-frame::after { content: ""; position: absolute; left: 6%; right: 6%; top: 50%; height: 2px; background: #22d3ee; box-shadow: 0 0 10px #22d3ee; animation: wal-sweep 1.6s ease-in-out infinite alternate; }
@keyframes wal-sweep { from { transform: translateY(-34px); } to { transform: translateY(34px); } }
@media (prefers-reduced-motion: reduce) { .wal-cam-frame::after { animation: none; } }
.wal-cam-hint { position: absolute; left: 0; right: 0; bottom: 10px; text-align: center; color: #fff; font-size: 13px; font-weight: 700; text-shadow: 0 1px 3px rgba(0, 0, 0, .6); pointer-events: none; }
.wal-cam-btns { position: absolute; top: 8px; right: 8px; display: flex; gap: 6px; }
.wal-cam-btns .icon-btn { background: rgba(255, 255, 255, .92); color: #0f172a; }
.wal-cam-btns .icon-btn[aria-pressed="true"] { background: #fde047; }
.wal-scan-msg { margin: 10px 0 0; text-align: center; color: var(--muted); }
.wal-scan-msg:empty { display: none; }
.wal-scan-msg .i { vertical-align: -2px; }
.wal-scan-msg.err { color: #be123c; }
.wal-scan-msg.ok { color: #047857; }
.wal-scan-msg .linkish { border: 0; background: none; padding: 0; font: inherit; font-weight: 700; color: var(--primary-d); text-decoration: underline; cursor: pointer; }
.wal-code-prev { background: #fff; border: 1px solid #e2e8f0; border-radius: 12px; padding: 8px; display: flex; justify-content: center; width: 100%; max-width: 270px; box-sizing: border-box; }
.wal-code-prev svg { width: 100%; height: auto; max-height: 52px; }
.wal-code-prev.is-2d svg { width: 84px; height: 84px; max-height: none; }
/* Champs */
.wal-f > label { font-weight: 700; font-size: 13.5px; color: #33496b; }
.wal-f > label small { font-weight: 600; font-size: 12px; margin-left: 4px; }
.wal-f #wal-store { font-size: 17px; font-weight: 700; padding: 11px 13px; }
.wal-num-row { display: flex; gap: 8px; }
.wal-num-row input { flex: 1; min-width: 0; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 16px; letter-spacing: .04em; }
.wal-num-row input::placeholder { font-family: Nunito, system-ui, sans-serif; letter-spacing: 0; }
.wal-num-row select { flex: none; width: auto; max-width: 42%; font-size: 13px; }
.wal-hint { margin: 0; font-size: 12.5px; color: var(--muted); line-height: 1.45; }
.wal-hint:empty { display: none; }
.wal-hint .i { vertical-align: -2px; }
.wal-hint .warn { color: #b45309; }
[data-wal-brand] { color: #047857; }
.wal-sugg { display: flex; flex-wrap: wrap; gap: 6px; }
.wal-sugg:empty, .wal-sugg[hidden] { display: none; }
.wal-chip { display: inline-flex; align-items: center; gap: 6px; padding: 5px 11px; border-radius: 999px; border: 1.5px solid var(--line); background: var(--card); font: inherit; font-size: 13px; font-weight: 700; color: #334155; cursor: pointer; }
.wal-chip:hover { border-color: var(--primary); }
.wal-chip i { width: 10px; height: 10px; border-radius: 50%; flex: none; }
.wal-chip .i { width: 14px; height: 14px; color: var(--muted); }
.wal-chip.on { border-color: var(--primary); background: var(--primary-soft); color: var(--primary-d); }
@media (max-width: 760px) {
  .wal-hero-btn { padding: 14px; }
  .wal-hero-ic { width: 48px; height: 48px; }
}
.wal-color-in { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.wal-color-in .mf-chips { margin: 0; }
.wal-color-in input[type=color] { width: 46px; height: 34px; padding: 2px; border-radius: 10px; cursor: pointer; }
.wal-color-in input[type=color]:disabled { opacity: .35; cursor: default; }
.wal-modal-del { display: flex; justify-content: space-between; gap: 8px; margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--line-2); }
@media (max-width: 760px) {
  .wal-bar .seg button span { display: none; }
  .wal-bar .seg button { padding: 8px 11px; }
  .wal-stage.is-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
  .is-grid > .wcard { padding: 10px 11px; border-radius: 12px; }
  .is-grid > .wcard .wc-logo { width: 30px; height: 30px; border-radius: 9px; }
  .is-grid > .wcard .wc-logo img { width: 22px; height: 22px; }
  .is-grid > .wcard .wc-logo b { font-size: 15px; }
  .is-grid > .wcard .wc-top { gap: 8px; }
  .is-grid > .wcard .wc-name { font-size: 13.5px; }
  .is-grid > .wcard .wc-holder { font-size: 9.5px; }
  .is-grid > .wcard .wc-num { font-size: 11px; letter-spacing: .04em; }
  .is-grid > .wcard .wc-exp { top: 46px; left: 11px; font-size: 10px; padding: 2px 7px; }
  .is-grid > .wcard .wc-fav .i { width: 14px; height: 14px; }
  .ws-info > div { grid-template-columns: 108px 1fr; }
}
.ic-bubble.wal-mini { background: linear-gradient(135deg, var(--wc), var(--wc2)); padding: 0; display: grid; place-items: center; }
.wal-mini .wc-logo { width: 26px; height: 26px; border-radius: 8px; box-shadow: none; }
.wal-mini .wc-logo img { width: 20px; height: 20px; }
.wal-mini .wc-logo b { font-size: 13px; }
html.dark .wal-search input { background: transparent; border: 0; }

/* Tâches : notes, sous-tâches et pièces jointes sous le titre */
.task-more { margin-top: 4px; font-size: 13px; color: var(--muted); display: grid; gap: 4px; cursor: default; }
.task-more p { margin: 0; white-space: normal; }
.task-steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.task-steps label { display: inline-flex; align-items: center; gap: 7px; cursor: pointer; color: var(--text); }
.task-steps li.done span { text-decoration: line-through; color: var(--muted); }
.chk.chk-sm { width: 16px; height: 16px; border-radius: 5px; }
.task-file { display: inline-flex; align-items: center; gap: 4px; }
.task-file a { display: inline-flex; align-items: center; gap: 4px; font-weight: 600; }

/* Finances : mois passés, budgets, vue annuelle, objectifs d'épargne */
.fin-stats { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 1250px) { .fin-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 480px) { .fin-stats { grid-template-columns: minmax(0, 1fr); } }
.fin-past { display: flex; align-items: center; gap: 7px; margin: 0 0 12px; padding: 9px 12px; border-radius: 12px; background: color-mix(in srgb, var(--primary) 8%, var(--card)); font-size: 13.5px; }
.fin-sal .row-main { min-width: 0; }
.fin-sal .row-sub input { width: 96px !important; }
.fin-stopped { margin: 12px 0 0; font-size: 13px; color: var(--muted); display: flex; flex-wrap: wrap; gap: 4px 12px; align-items: center; }
#charges-tbl td:nth-child(4) { min-width: 120px !important; }
#charges-tbl td.r .icon-btn { width: 30px; height: 30px; }
#charges-tbl th, #charges-tbl td { padding-left: 8px; padding-right: 8px; }
.fin-budgets { display: grid; gap: 12px; }
.fin-bud .fb-top { display: flex; justify-content: space-between; gap: 8px; font-size: 13.5px; margin-bottom: 4px; }
.fin-bud .fb-top span { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; }
.fin-bud .fb-top small { color: var(--muted); font-weight: 500; }
.fin-budget-form { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 14px; }
.fin-budget-form label { display: grid; gap: 3px; font-size: 13px; font-weight: 600; }
.fin-budget-form label > span:first-child { display: inline-flex; align-items: center; gap: 6px; }
@media (max-width: 520px) { .fin-budget-form { grid-template-columns: 1fr; } }
.fin-legend { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 12.5px; color: var(--muted); margin-bottom: 8px; }
.fin-legend span { display: inline-flex; align-items: center; gap: 6px; }
.fin-legend i { width: 10px; height: 10px; border-radius: 3px; display: inline-block; }
.fin-year { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 6px; height: 190px; margin-bottom: 14px; border-bottom: 1px solid var(--line); }
.fy-col { display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 4px; color: var(--muted); text-decoration: none; border-radius: 8px 8px 0 0; padding-top: 4px; }
.fy-col:hover { background: color-mix(in srgb, var(--primary) 7%, transparent); }
.fy-col.now small { color: var(--primary); font-weight: 800; }
.fy-col.future { opacity: .45; }
.fy-col small { font-size: 11.5px; padding-bottom: 4px; }
.fy-bars { flex: 1; width: 100%; display: flex; align-items: flex-end; justify-content: center; gap: 2px; min-height: 0; }
.fy-bars > i, .fy-bars .out { width: 38%; max-width: 20px; }
.fy-bars > i.in { background: #0d9488; border-radius: 4px 4px 0 0; display: block; min-height: 0; }
.fy-bars .out { height: 100%; display: flex; flex-direction: column; justify-content: flex-end; gap: 2px; }
.fy-bars .out i { display: block; width: 100%; }
.fy-bars .out i.sp { background: #93c5fd; border-radius: 4px 4px 0 0; }
.fy-bars .out i.fx { background: #2563eb; }
.fy-bars .out i.sp[style*="height:0%"] + i.fx { border-radius: 4px 4px 0 0; }
.fin-year-tbl tfoot th { border-top: 2px solid var(--line); border-bottom: 0; }
.fin-year-tbl tr.muted td { color: var(--muted); }
.fin-goals { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 14px; }
.fin-goal { border: 1px solid var(--line); border-radius: 16px; padding: 14px; display: grid; gap: 9px; }
.fin-goal.done { background: color-mix(in srgb, #16a34a 6%, var(--card)); }
.fg-top { display: flex; align-items: center; gap: 10px; }
.fg-top strong { display: block; }
.fg-emoji { font-size: 26px; line-height: 1; }
.fg-nums { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 8px; }
.fg-nums small { flex-basis: 100%; }
.fg-add { display: flex; gap: 8px; align-items: center; }
.fg-add .input-unit { flex: 1; min-width: 0; }
.fin-sal { flex-wrap: wrap; }
.fin-sal .row-main { flex: 1 1 calc(100% - 70px); }
.fin-sal .row-sub { flex-wrap: nowrap; white-space: nowrap; }
.fin-sal > .btn { margin-left: auto; }

/* Détails : intertitre dans une liste, champs fichier qui ne débordent plus de leur carte */
.row-sep { margin: 10px 0 2px; font-size: 11.5px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
input[type="file"] { max-width: 100%; min-width: 0; }
.f input[type="file"] { width: 100%; }
.f-row > * { min-width: 0; }

/* Enfants : onglets École, Points et récompenses, Argent de poche */
.seg-badge { display: inline-block; min-width: 18px; padding: 0 5px; border-radius: 9px; background: #e11d48; color: #fff; font-size: 11px; font-weight: 800; text-align: center; line-height: 18px; }
.kid-pick { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 14px; }
.kid-pick a { display: inline-flex; align-items: center; gap: 8px; padding: 5px 14px 5px 6px; border-radius: 999px; border: 1px solid var(--line); background: var(--card); color: var(--text); font-weight: 700; text-decoration: none; }
.kid-pick a.active { border-color: var(--c); background: color-mix(in srgb, var(--c) 12%, var(--card)); }
.tt-grid { display: grid; grid-template-columns: repeat(var(--n, 5), minmax(0, 1fr)); gap: 8px; }
.tt-day h4 { margin: 0 0 6px; font-size: 12.5px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); text-align: center; padding: 4px 0; border-radius: 8px; }
.tt-day.today h4 { background: color-mix(in srgb, var(--primary) 12%, transparent); color: var(--primary); }
.tt-day { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.tt-slot { border-left: 4px solid var(--c); background: color-mix(in srgb, var(--c) 10%, var(--card)); border-radius: 10px; padding: 7px 9px; display: grid; gap: 1px; min-width: 0; }
.tt-slot[data-edit] { cursor: pointer; }
.tt-slot small { font-size: 11px; color: var(--muted); font-weight: 600; }
.tt-slot strong { font-size: 13.5px; overflow-wrap: anywhere; }
.tt-slot span { font-size: 11.5px; color: var(--muted); overflow-wrap: anywhere; }
.tt-tag { display: inline-block; padding: 1px 8px; border-radius: 999px; font-size: 11.5px; font-weight: 700; color: var(--c); background: color-mix(in srgb, var(--c) 12%, transparent); }
@media (max-width: 760px) { .tt-grid { grid-template-columns: 1fr; } .tt-day h4 { text-align: left; padding-left: 8px; } }
.switch-line { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; margin-left: auto; cursor: pointer; }
.pts-total { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; margin: 2px 0 10px; color: var(--c); font-size: 20px; font-weight: 800; }
.pts-total strong { font-size: 38px; line-height: 1; }
.pts-total small { font-size: 13px; color: var(--muted); font-weight: 600; }
.rw-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 12px; }
.rw-item { border: 1px solid var(--line); border-radius: 14px; padding: 12px; display: grid; gap: 7px; align-content: start; }
.rw-item.got { opacity: .7; }
.rw-top { display: flex; justify-content: space-between; gap: 8px; align-items: flex-start; }
.rw-cost { flex: none; font-weight: 800; color: #b45309; background: #fef3c7; border-radius: 999px; padding: 1px 9px; font-size: 13px; }
.rw-act { display: flex; gap: 6px; align-items: center; justify-content: space-between; }
.tt-slot strong, .tt-slot span { overflow-wrap: break-word; hyphens: auto; }
.tt-slot strong { font-size: 13px; }

/* Messagerie : groupes, recherche, réponse et modification */
.cav .av.fam.grp { background: linear-gradient(135deg, #a855f7, #db2777); }
.chat-find { display: flex; gap: 6px; align-items: center; padding: 10px 10px 2px; }
.chat-find input { flex: 1; min-width: 0; padding: 8px 12px; border-radius: 12px; font-size: 13.5px; }
.chat-noresult { padding: 16px 12px; color: var(--muted); font-size: 13.5px; }
.chip-ctx { display: flex; align-items: center; gap: 8px; margin: 0 0 8px; padding: 6px 8px 6px 12px; background: var(--primary-soft); border-left: 3px solid var(--primary); border-radius: 10px; font-size: 13px; }
.chip-ctx[hidden] { display: none; }
.chip-ctx span { flex: 1; min-width: 0; display: grid; }
.chip-ctx small { color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.reply-q { display: grid; width: 100%; text-align: left; margin: 0 0 6px; padding: 5px 9px; border: 0; border-left: 3px solid currentColor; border-radius: 8px; background: color-mix(in srgb, currentColor 10%, transparent); color: inherit; font: inherit; font-size: 12.5px; cursor: pointer; }
.reply-q strong { font-size: 12px; }
.reply-q span { opacity: .85; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 260px; }
.msg.flash .bubble { animation: msg-flash 1.8s ease; }
@keyframes msg-flash { 0%, 60% { box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 55%, transparent); } 100% { box-shadow: 0 0 0 0 transparent; } }
.btn.danger { color: var(--red); }

/* Galerie : vidéos et commentaires */
.gal-play { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; background: rgba(0, 0, 0, .5); color: #fff; }
.gal-play .i { width: 20px; height: 20px; fill: #fff; margin-left: 2px; }
.gal-nc { position: absolute; left: 6px; bottom: 6px; display: inline-flex; align-items: center; gap: 3px; padding: 2px 7px; border-radius: 999px; background: rgba(0, 0, 0, .45); color: #fff; font-size: 11.5px; font-weight: 700; }
.gv-stage video { max-width: 100%; max-height: calc(100dvh - 150px); border-radius: 6px; background: #000; box-shadow: 0 20px 60px rgba(0, 0, 0, .5); }
.gv-stage img[hidden], .gv-stage video[hidden] { display: none; }
.gv-btn [data-gv="comcount"] { position: absolute; margin: -22px 0 0 26px; font-size: 11px; font-weight: 800; color: #fbbf24; }
.gal-viewer.with-com[open] { grid-template-columns: 64px 1fr 64px 320px; }
.gal-viewer.with-com .gv-top { grid-column: 1 / -1; }
.gv-com { grid-column: 4; grid-row: 2; display: flex; flex-direction: column; min-height: 0; background: rgba(15, 23, 42, .92); border-left: 1px solid rgba(255, 255, 255, .1); padding: 12px; gap: 10px; }
.gv-com[hidden] { display: none; }
.gv-com h4 { margin: 0; display: flex; align-items: center; gap: 6px; font-size: 14px; color: #e2e8f0; }
.gv-com-list { flex: 1; min-height: 0; overflow-y: auto; display: grid; gap: 10px; align-content: start; }
.gv-com-empty { color: #94a3b8; font-size: 13px; margin: 0; }
.gv-c > div { display: flex; align-items: baseline; gap: 8px; }
.gv-c small { color: #94a3b8; font-size: 11.5px; }
.gv-c p { margin: 2px 0 0; font-size: 13.5px; color: #e2e8f0; overflow-wrap: anywhere; }
.gv-c-del { margin-left: auto; border: 0; background: transparent; color: #94a3b8; cursor: pointer; font-size: 16px; line-height: 1; }
.gv-com-form { display: flex; gap: 6px; }
.gv-com-form input { flex: 1; min-width: 0; background: rgba(255, 255, 255, .08); border: 1px solid rgba(255, 255, 255, .16); color: #fff; border-radius: 10px; padding: 8px 10px; }
@media (max-width: 860px) {
  .gal-viewer.with-com[open] { grid-template-columns: 44px 1fr 44px; grid-template-rows: auto 1fr minmax(160px, 38dvh); }
  .gv-com { grid-column: 1 / -1; grid-row: 3; border-left: 0; border-top: 1px solid rgba(255, 255, 255, .1); }
  .gal-viewer.with-com .gv-stage img, .gal-viewer.with-com .gv-stage video { max-height: calc(62dvh - 150px); }
}
a.cd-item { color: inherit; text-decoration: none; }
a.cd-item:hover { background: color-mix(in srgb, var(--c) 14%, #fff); }
#m-deadlines .cd-list { display: grid; gap: 8px; }

/* Téléphone : barre de navigation du bas (accueil, trois modules du quotidien, menu) */
.botnav { display: none; }
@media (max-width: 760px) {
  .botnav { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; position: fixed; left: 0; right: 0; bottom: 0; z-index: 31; height: calc(58px + var(--sab, 0px)); padding: 0 var(--sar, 0px) var(--sab, 0px) var(--sal, 0px);
    background: color-mix(in srgb, var(--card, #fff) 94%, transparent); backdrop-filter: blur(12px); border-top: 1px solid var(--line); }
  .botnav a, .botnav button { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; border: 0; background: none; color: var(--muted); font: inherit; font-size: 10.5px; font-weight: 700; text-decoration: none; cursor: pointer; min-width: 0; padding: 0 2px; }
  .botnav .i { width: 22px; height: 22px; }
  .botnav span { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .botnav a.active { color: var(--primary); }
  .botnav a.active .i { stroke-width: 2.4; }
  .mob-act { bottom: calc(58px + var(--sab, 0px)) !important; padding-bottom: 10px !important; }
  .main:has(.botnav) .foot { padding-bottom: calc(74px + var(--sab, 0px)); }
  .main:has(.botnav):has(.mob-act) .foot { padding-bottom: calc(144px + var(--sab, 0px)); }
  body:has(.botnav) .chat-float { bottom: calc(70px + var(--sab, 0px)); }
  body:has(.botnav):has(.mob-act) .chat-float { bottom: calc(138px + var(--sab, 0px)); }
  body.chat-page .botnav { display: none; }
  .mob-act .btn { min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 14px; padding-left: 10px; padding-right: 10px; }
}
@media print { .botnav { display: none !important; } }
body.side-open .botnav { display: none; }
