/* Akoben — le cor qui appelle à l'action.
   Une seule chose forte : le cor en laiton (dicter). Le reste est calme.
   Trois couleurs = trois compartiments (Personnel bleu, Spirituel violet, Business vert), toujours avec une icône.
   Téléphone d'abord ; ordinateur : menu à gauche. Clair ou sombre selon l'appareil. */

@font-face {
  font-family: 'Figtree';
  src: url('../fonts/figtree.woff2') format('woff2');
  font-weight: 300 900;
  font-style: normal;
  font-display: swap;
}

:root {
  color-scheme: light;
  --bg: #edeff2;
  --surface: #ffffff;
  --surface-2: #f5f6f8;
  --ink: #15181e;
  --ink-2: #5b626d;
  --line: #dadee4;
  --brass: #8c5410;
  --brass-hi: #c88a3a;
  --brass-lo: #6a3d08;
  --on-brass: #ffffff;
  --brass-soft: rgba(140, 84, 16, 0.1);
  --perso: #1f6fb2;
  --perso-soft: #e4eef8;
  --spirit: #6b3fb0;
  --spirit-soft: #eee8f8;
  --biz: #0e7a4b;
  --biz-soft: #e2f2ea;
  --on-comp: #ffffff;
  --bad: #b42318;
  --bad-soft: #fdecea;
  --warn: #8a5a00;
  --warn-soft: #fff3d6;
  --ok: #0e7a4b;
  --hover: rgba(21, 24, 30, 0.04);
  --shadow: 0 10px 30px rgba(21, 24, 30, 0.18);
  --r: 14px;
  --pill: 999px;
}
@media (prefers-color-scheme: dark) {
  :root {
    color-scheme: dark;
    --bg: #0f1217;
    --surface: #171b22;
    --surface-2: #1e232c;
    --ink: #eceff3;
    --ink-2: #9ba3ae;
    --line: #2b313b;
    --brass: #e2a458;
    --brass-hi: #f3c27f;
    --brass-lo: #b9782c;
    --on-brass: #1a1206;
    --brass-soft: rgba(226, 164, 88, 0.15);
    --perso: #74b3f2;
    --perso-soft: rgba(116, 179, 242, 0.14);
    --spirit: #b99af3;
    --spirit-soft: rgba(185, 154, 243, 0.15);
    --biz: #52c994;
    --biz-soft: rgba(82, 201, 148, 0.14);
    --on-comp: #0f1217;
    --bad: #f2867a;
    --bad-soft: rgba(242, 134, 122, 0.14);
    --warn: #f0c66b;
    --warn-soft: rgba(240, 198, 107, 0.13);
    --ok: #52c994;
    --hover: rgba(255, 255, 255, 0.05);
    --shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  }
}

/* Chaque compartiment porte sa couleur dans --comp */
.c-perso { --comp: var(--perso); --comp-soft: var(--perso-soft); }
.c-spirit { --comp: var(--spirit); --comp-soft: var(--spirit-soft); }
.c-biz { --comp: var(--biz); --comp-soft: var(--biz-soft); }

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: 'Figtree', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  font-size: 15px;
  line-height: 1.45;
  -webkit-text-size-adjust: 100%;
  -webkit-tap-highlight-color: transparent;
}
h1, h2, h3, p { margin: 0; }
h2 { font-size: 1rem; font-weight: 700; }
a { color: inherit; text-decoration: none; }
.muted { color: var(--ink-2); }
.small { font-size: 0.85rem; }
.center { text-align: center; }
.right { text-align: right; }
.grow { flex: 1; min-width: 0; }
.pad { padding: 12px 4px; }
.error { color: var(--bad); font-weight: 600; min-height: 1.2em; }
.error:empty { min-height: 0; }
.bad { color: var(--bad); }
.stack { display: flex; flex-direction: column; gap: 12px; }
.row { display: flex; gap: 8px; align-items: center; }
.row.wrap { flex-wrap: wrap; }
.row.between { justify-content: space-between; }
.row-end { display: flex; gap: 8px; justify-content: flex-end; flex-wrap: wrap; margin-top: 6px; }
pre.code { margin: 0; padding: 12px 14px; border-radius: 10px; background: var(--surface-2); font-size: 1rem; font-weight: 700; user-select: all; }

/* ---------- boutons et champs ---------- */
button {
  font: inherit; cursor: pointer; border-radius: var(--pill); padding: 9px 18px; min-height: 44px;
  border: 1px solid var(--line); background: var(--surface); color: var(--ink); font-weight: 600;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
}
button.primary { background: var(--brass); color: var(--on-brass); border-color: transparent; }
button.secondary { background: transparent; color: var(--brass); border-color: var(--brass); }
button.ghost { background: transparent; border-color: transparent; color: var(--ink-2); }
button.danger { background: var(--bad); color: #fff; border-color: transparent; }
button.danger-text { color: var(--bad); }
button.big { min-height: 52px; font-size: 1.05rem; padding: 10px 24px; }
button.link { background: none; border: 0; color: var(--brass); text-decoration: underline; text-underline-offset: 3px; min-height: 36px; padding: 4px 6px; font-weight: 600; justify-content: flex-start; }
button:disabled { opacity: 0.55; cursor: default; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, summary:focus-visible {
  outline: 2px solid var(--brass); outline-offset: 2px;
}
.icon-btn { min-height: 42px; min-width: 42px; padding: 0; border: 0; background: transparent; color: var(--ink-2); position: relative; }
.ic { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.ic.small { width: 17px; height: 17px; }
.ic.tiny { width: 14px; height: 14px; stroke-width: 2; }
.ic.big { width: 44px; height: 44px; }
.ic.ok { color: var(--ok); }

.chips { display: flex; gap: 6px; flex-wrap: wrap; }
.chip { min-height: 36px; padding: 5px 13px; font-size: 0.88rem; font-weight: 500; gap: 6px; }
.chip.active { background: var(--ink); color: var(--surface); border-color: var(--ink); }
.chip[class*="c-"] { color: var(--comp); border-color: color-mix(in srgb, var(--comp) 40%, var(--line)); }
.chip[class*="c-"].active { background: var(--comp); color: var(--on-comp); border-color: var(--comp); }
.chip.p1.active { background: var(--bad); border-color: var(--bad); color: #fff; }
.chip.p2.active { background: var(--warn); border-color: var(--warn); color: var(--surface); }
.chip.round { width: 40px; min-width: 40px; padding: 0; }
.chip.lang { min-height: 32px; font-weight: 700; letter-spacing: 0.04em; }

.field { display: flex; flex-direction: column; gap: 5px; font-size: 0.88rem; font-weight: 600; min-width: 0; flex: 1; }
.field-label, .ed-label { color: var(--ink-2); font-size: 0.86rem; font-weight: 600; display: flex; gap: 8px; align-items: baseline; flex-wrap: wrap; }
.hint { font-weight: 400; color: var(--ink-2); font-size: 0.82rem; }
.hint.warn { color: var(--warn); font-weight: 600; }
input, select, textarea {
  font: inherit; font-weight: 400; font-size: 16px; /* 16 px : pas de zoom sur iPhone */
  padding: 10px 14px; border-radius: 12px; border: 1px solid var(--line);
  background: var(--surface); color: var(--ink); min-height: 44px; width: 100%;
}
textarea { resize: vertical; line-height: 1.45; }
select { appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--ink-2) 50%), linear-gradient(135deg, var(--ink-2) 50%, transparent 50%);
  background-position: calc(100% - 20px) 55%, calc(100% - 15px) 55%; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 36px; }
input[type="checkbox"] { width: 22px; height: 22px; min-height: 0; accent-color: var(--brass); flex: none; }
input[type="time"] { max-width: 160px; }
input[type="search"] { border: 0; background: transparent; padding-left: 4px; }

/* ---------- entrée ---------- */
.auth { min-height: 100vh; min-height: 100dvh; display: grid; place-items: center; padding: 24px 16px; }
.auth-card { width: min(400px, 100%); background: var(--surface); border: 1px solid var(--line); border-radius: 20px; padding: 28px 22px; display: flex; flex-direction: column; gap: 14px; }
.auth-head { display: flex; flex-direction: column; align-items: center; gap: 8px; text-align: center; }
.brand-icon { width: 30px; height: 30px; border-radius: 8px; }
.brand-icon.big { width: 72px; height: 72px; border-radius: 18px; }
.brand { font-weight: 800; color: var(--brass); font-size: 1.15rem; letter-spacing: 0.01em; }
.brand.big { font-size: 2.1rem; line-height: 1; letter-spacing: -0.01em; }
.pin-card { align-items: center; text-align: center; }
.pin-title { font-size: 1.15rem; font-weight: 700; }
.pin-dots { display: flex; gap: 14px; margin: 6px 0; }
.pdot { width: 14px; height: 14px; border-radius: 50%; border: 2px solid var(--brass); }
.pdot.on { background: var(--brass); }
.pin-pad { display: grid; grid-template-columns: repeat(3, 72px); gap: 12px; justify-content: center; }
.pkey { width: 72px; height: 72px; border-radius: 50%; font-size: 1.6rem; font-weight: 600; padding: 0; background: var(--surface-2); border-color: transparent; }
.pkey.del { background: transparent; }
.pkey:active { background: var(--brass-soft); }

/* ---------- cadre ---------- */
.shell { min-height: 100vh; }
.side { display: none; }
.main-col { max-width: 640px; margin: 0 auto; padding: 0 16px calc(156px + env(safe-area-inset-bottom)); }
.top { position: sticky; top: 0; z-index: 10; display: flex; align-items: center; justify-content: space-between; gap: 8px;
  padding: calc(6px + env(safe-area-inset-top)) 0 6px; background: var(--bg); }
.top h1 { font-size: 1.05rem; font-weight: 700; color: var(--ink-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.top-actions { display: flex; align-items: center; gap: 2px; }
.sync-btn.spin .ic { animation: spin 1s linear infinite; color: var(--brass); }
.sync-btn.off .ic { color: var(--bad); }
.sync-btn.wait .ic { color: var(--warn); }
.dot-count { position: absolute; top: 4px; right: 2px; background: var(--warn); color: var(--surface); font-size: 0.66rem; font-weight: 800; border-radius: 999px; min-width: 16px; height: 16px; padding: 0 4px; display: grid; place-items: center; }
@keyframes spin { to { transform: rotate(360deg); } }
.view { display: flex; flex-direction: column; gap: 14px; padding-top: 2px; }
.view.slide-l { animation: slideL 200ms ease-out; }
.view.slide-r { animation: slideR 200ms ease-out; }
@keyframes slideL { from { transform: translateX(36px); opacity: 0.5; } to { transform: none; opacity: 1; } }
@keyframes slideR { from { transform: translateX(-36px); opacity: 0.5; } to { transform: none; opacity: 1; } }

.tabs { position: fixed; left: 0; right: 0; bottom: 0; z-index: 20; display: flex; justify-content: space-around; background: var(--surface); border-top: 1px solid var(--line);
  padding: 4px 4px calc(4px + env(safe-area-inset-bottom)); }
.tab { display: flex; flex-direction: column; align-items: center; gap: 2px; font-size: 0.72rem; color: var(--ink-2); padding: 6px 4px; min-width: 64px; border-radius: 10px; }
.tab.active { color: var(--brass); font-weight: 700; }
.fab { position: fixed; right: max(16px, calc(50% - 304px)); bottom: calc(78px + env(safe-area-inset-bottom)); z-index: 21; width: 60px; height: 60px; border-radius: 50%; padding: 0;
  background: radial-gradient(circle at 35% 30%, var(--brass-hi), var(--brass) 62%, var(--brass-lo)); color: var(--on-brass); border: 0; box-shadow: var(--shadow); }
.fab .ic { width: 26px; height: 26px; stroke-width: 2; }

@media (min-width: 900px) {
  .shell { display: grid; grid-template-columns: 228px 1fr; }
  .side { display: flex; flex-direction: column; gap: 14px; position: sticky; top: 0; height: 100vh; padding: 20px 12px; border-right: 1px solid var(--line); background: var(--surface); }
  .brand-row { display: flex; align-items: center; gap: 10px; padding: 2px 10px 8px; }
  .side-nav { display: flex; flex-direction: column; gap: 2px; }
  .side-link { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 10px; color: var(--ink-2); font-weight: 600; }
  .side-link:hover { background: var(--hover); }
  .side-link.active { background: var(--brass-soft); color: var(--brass); }
  .side-foot { margin-top: auto; padding: 8px 12px; }
  .main-col { max-width: 780px; width: 100%; padding: 0 clamp(16px, 4vw, 48px) 48px; }
  .tabs, .phone-only { display: none !important; }
  .fab { right: 32px; bottom: 32px; }
  .top { padding-top: 16px; }
}

/* ---------- blocs et listes ---------- */
.block { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 8px 14px 10px; display: flex; flex-direction: column; gap: 6px; }
.block-title { display: flex; align-items: center; gap: 8px; font-size: 0.92rem; font-weight: 700; padding: 6px 0 2px; color: var(--ink); }
.block-title.bad { color: var(--bad); }
summary.block-title, details > summary { cursor: pointer; list-style: none; }
details > summary::-webkit-details-marker { display: none; }
details > summary::before { content: '›'; display: inline-block; margin-right: 6px; transition: transform 0.15s; color: var(--ink-2); }
details[open] > summary::before { transform: rotate(90deg); }
.list { display: flex; flex-direction: column; }
.list-head { display: flex; align-items: center; gap: 6px; font-size: 0.8rem; color: var(--ink-2); font-weight: 700; padding: 12px 0 2px; }
.empty { padding: 28px 8px; display: flex; flex-direction: column; gap: 10px; align-items: flex-start; }
.empty-title { font-size: 1.2rem; font-weight: 700; }
.pill { font-size: 0.8rem; background: var(--surface-2); border-radius: 999px; padding: 4px 12px; color: var(--ink-2); width: fit-content; }
.banner { padding: 10px 12px; border-radius: 12px; font-weight: 600; display: flex; gap: 10px; align-items: center; font-size: 0.9rem; }
.banner.warn { background: var(--warn-soft); color: var(--warn); }
.banner.info { background: var(--brass-soft); color: var(--brass); }
.banner .chip { margin-left: auto; }
.kv { display: flex; justify-content: space-between; gap: 12px; font-size: 0.88rem; padding: 7px 0; border-bottom: 1px solid var(--line); }
.kv:last-child { border-bottom: 0; }
.kv > span:last-child { text-align: right; }
.kv.bad > span:first-child { color: var(--bad); font-weight: 600; }

/* Étiquette de compartiment */
.ctag { display: inline-flex; align-items: center; gap: 5px; font-size: 0.78rem; font-weight: 700; color: var(--comp); background: var(--comp-soft); padding: 3px 9px; border-radius: 999px; white-space: nowrap; flex: none; }
.ctag.small { font-size: 0.72rem; padding: 2px 8px; }

/* Une tâche : un trait de couleur à gauche, le rond pour « fait », le titre, les repères */
.trow { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--line); min-width: 0; position: relative; }
.list > .trow:last-child { border-bottom: 0; }
.trow::before { content: ''; position: absolute; left: -14px; top: 10px; bottom: 10px; width: 4px; border-radius: 0 3px 3px 0; background: var(--comp); }
button.trow { width: 100%; text-align: left; background: none; border: 0; border-bottom: 1px solid var(--line); border-radius: 0; padding: 10px 0; min-height: 0; font-weight: 400; justify-content: flex-start; }
.tick { width: 30px; height: 30px; min-height: 30px; padding: 0; border-radius: 50%; border: 2px solid color-mix(in srgb, var(--comp) 60%, var(--line)); background: transparent; color: transparent; flex: none; }
.tick:hover { color: var(--comp); }
.tick.on { background: var(--comp); border-color: var(--comp); color: var(--on-comp); }
.tick.small { width: 22px; height: 22px; min-height: 22px; border-width: 2px; display: inline-grid; place-items: center; }
.trow-main { flex: 1; min-width: 0; display: flex; flex-direction: column; align-items: flex-start; gap: 3px; background: none; border: 0; padding: 0; min-height: 0; text-align: left; font-weight: 400; border-radius: 6px; }
.trow-title { font-weight: 600; font-size: 0.98rem; line-height: 1.3; overflow-wrap: anywhere; }
.trow.done .trow-title { text-decoration: line-through; color: var(--ink-2); font-weight: 500; }
.trow-meta { display: flex; flex-wrap: wrap; gap: 4px 12px; font-size: 0.8rem; color: var(--ink-2); }
.mi { display: inline-flex; align-items: center; gap: 4px; }
.mi.bad { color: var(--bad); font-weight: 700; }
.mi.warn { color: var(--warn); font-weight: 700; }
.mi.soft { opacity: 0.85; }
.prio { font-weight: 800; font-size: 0.74rem; }
.prio.p1 { color: var(--bad); }
.prio.p2 { color: var(--warn); }
.trow.compact { padding: 8px 0; }
.trow.compact .tick { width: 26px; height: 26px; min-height: 26px; }
.prow { display: flex; align-items: center; gap: 10px; padding: 12px 0; border-bottom: 1px solid var(--line); color: var(--ink); font-weight: 600; }
.prow > .ic:first-child { color: var(--comp); }
.prow .count { font-size: 0.8rem; color: var(--ink-2); font-weight: 700; min-width: 20px; text-align: right; }
.list > .prow:last-child { border-bottom: 0; }

/* ---------- Capturer ---------- */
.cap-hero { display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 18px 0 6px; position: relative; }
.cap-hero .lang { position: absolute; top: 12px; right: 0; }
.horn { position: relative; width: 132px; height: 132px; border-radius: 50%; padding: 0; border: 0; color: var(--on-brass);
  background: radial-gradient(circle at 35% 28%, var(--brass-hi), var(--brass) 58%, var(--brass-lo)); box-shadow: var(--shadow); }
.horn .horn-ic { width: 46px; height: 46px; stroke-width: 1.9; position: relative; z-index: 1; }
.horn .ring { position: absolute; inset: 0; border-radius: 50%; border: 2px solid var(--brass); opacity: 0; pointer-events: none; }
.horn.on .ring { animation: call 1.8s ease-out infinite; }
.horn.on .ring.r2 { animation-delay: 0.9s; }
@keyframes call { from { transform: scale(1); opacity: 0.55; } to { transform: scale(1.7); opacity: 0; } }
.horn:active { transform: scale(0.97); }
.cap-hint { font-weight: 600; color: var(--ink-2); text-align: center; }
.cap-input { display: flex; flex-direction: column; gap: 8px; }
.cap-text { min-height: 110px; font-size: 1.02rem; border-radius: 16px; }
.interim { color: var(--ink-2); font-style: italic; min-height: 0; }
.interim:empty { display: none; }
.tips { font-size: 0.9rem; background: var(--surface); border: 1px dashed var(--line); border-radius: var(--r); padding: 12px 14px; }
.tips summary { font-weight: 700; }
.tips ul { margin: 8px 0; padding-left: 18px; display: flex; flex-direction: column; gap: 4px; }
.notes .note-row { display: flex; gap: 10px; align-items: center; padding: 6px 0; border-bottom: 1px solid var(--line); }

/* Carte à valider */
.vcard { background: var(--surface); border: 1px solid var(--line); border-top: 4px solid var(--comp); border-radius: var(--r); padding: 12px 14px 14px; display: flex; flex-direction: column; gap: 12px; }
.vcard-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; font-size: 0.85rem; }
.vcard-count { font-weight: 800; }
.by { display: inline-flex; align-items: center; gap: 5px; color: var(--ink-2); }
.vcard-actions { display: flex; gap: 8px; flex-wrap: wrap; position: sticky; bottom: calc(70px + env(safe-area-inset-bottom)); background: var(--surface); padding-top: 8px; z-index: 2; }
.vcard-actions .primary { flex: 1; }
.editor { display: flex; flex-direction: column; gap: 14px; }
.ed-block { display: flex; flex-direction: column; gap: 7px; }
.ed-title { font-size: 1.12rem; font-weight: 700; }
.tag-warn { font-size: 0.74rem; font-weight: 700; color: var(--warn); background: var(--warn-soft); padding: 1px 8px; border-radius: 999px; }
.field.missing textarea { border-style: dashed; border-color: var(--warn); }
.said { display: flex; align-items: center; gap: 6px; font-size: 0.86rem; flex-wrap: wrap; }
.said strong { color: var(--brass); }
.steps-edit { display: flex; flex-direction: column; gap: 6px; }
.step-row { display: flex; align-items: center; gap: 8px; }
.ed-meta { display: flex; flex-direction: column; gap: 8px; }
.source summary { font-size: 0.84rem; color: var(--ink-2); font-weight: 600; }
.source p { margin-top: 6px; }
.date-pop { max-width: 220px; }

/* ---------- Aujourd'hui ---------- */
.day-head { padding: 4px 0 0; }
.day-title { font-size: clamp(1.6rem, 6.5vw, 2rem); font-weight: 800; letter-spacing: -0.015em; line-height: 1.1; }
.load { display: flex; flex-direction: column; gap: 6px; }
.load-bar { position: relative; display: flex; height: 10px; border-radius: 6px; background: var(--surface-2); border: 1px solid var(--line); overflow: hidden; }
.load.compact .load-bar { height: 6px; }
.seg { display: block; height: 100%; background: var(--comp); }
.seg + .seg { border-left: 2px solid var(--surface); }
.cap-mark { position: absolute; top: -2px; bottom: -2px; width: 2px; background: var(--bad); }
.load-text { font-size: 0.85rem; color: var(--ink-2); font-weight: 600; }
.load-text.bad { color: var(--bad); }
.focus-btn { width: 100%; min-height: 54px; border-radius: 16px; background: var(--ink); color: var(--surface); border: 0; font-size: 1.02rem; }
.done-block > summary { color: var(--ink-2); }

/* Focus : une tâche, tout l'écran */
.focus-back { position: fixed; inset: 0; z-index: 40; background: var(--bg); overflow-y: auto; }
.focus { max-width: 600px; margin: 0 auto; min-height: 100%; padding: calc(10px + env(safe-area-inset-top)) 20px calc(24px + env(safe-area-inset-bottom)); display: flex; flex-direction: column; gap: 16px; }
.focus-top { display: flex; justify-content: space-between; align-items: center; }
.focus-count { font-weight: 700; color: var(--ink-2); }
.focus-title { font-size: clamp(1.6rem, 7vw, 2.2rem); font-weight: 800; line-height: 1.15; letter-spacing: -0.015em; overflow-wrap: anywhere; }
.focus-outcome { border-left: 4px solid var(--brass); padding: 4px 0 4px 14px; display: flex; flex-direction: column; gap: 4px; }
.focus-outcome p { font-size: 1.1rem; font-weight: 600; }
.focus-outcome.empty { border-left-style: dashed; }
.focus-label { font-size: 0.82rem; font-weight: 700; color: var(--brass); }
.focus-steps { display: flex; flex-direction: column; gap: 6px; }
.step { justify-content: flex-start; text-align: left; background: var(--surface); border-color: var(--line); border-radius: 12px; font-weight: 500; gap: 12px; min-height: 48px; }
.step.on { color: var(--ink-2); text-decoration: line-through; }
.step .tick { --comp: var(--brass); }
.focus-facts { display: flex; flex-wrap: wrap; gap: 8px 16px; color: var(--ink-2); font-weight: 600; font-size: 0.92rem; }
.focus-desc { white-space: pre-wrap; }
.focus-actions { margin-top: auto; display: flex; flex-direction: column; gap: 10px; padding-top: 8px; }
.focus-actions .row { justify-content: center; flex-wrap: wrap; }
.focus-done { width: 100%; min-height: 60px; font-size: 1.15rem; }
.focus-end { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; text-align: center; padding: 40px 0; }

/* ---------- Semaine ---------- */
.week-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.week-title { font-size: 1.15rem; font-weight: 800; text-align: center; }
.day { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 10px 14px; display: flex; flex-direction: column; gap: 8px; }
.day.is-today { border-color: var(--brass); }
.day.past { opacity: 0.7; }
.day-row-head { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.day-row-head h2 { font-size: 0.98rem; }
.deadline-mark { display: flex; gap: 6px; align-items: center; font-size: 0.84rem; font-weight: 700; color: var(--warn); }

/* ---------- Tout ---------- */
.search-row { display: flex; align-items: center; gap: 6px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 0 12px; color: var(--ink-2); }
.results:empty { display: none; }
.results .list { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 4px 14px; }
.proj-head { display: flex; flex-direction: column; gap: 6px; align-items: flex-start; }
.proj-title { font-size: 1.6rem; font-weight: 800; letter-spacing: -0.01em; }
.edit-actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; position: sticky; bottom: calc(70px + env(safe-area-inset-bottom)); background: var(--bg); padding: 10px 0; }
.edit-actions .primary { flex: 1; }
@media (min-width: 900px) { .vcard-actions, .edit-actions { bottom: 0; } }

/* ---------- Réglages ---------- */
.state { font-weight: 600; }
.state.ok { color: var(--ok); }
h3.sub { font-size: 0.86rem; color: var(--ink-2); margin-top: 8px; }

/* ---------- fenêtres ---------- */
.modal-back { position: fixed; inset: 0; z-index: 50; background: rgba(10, 12, 16, 0.5); display: grid; place-items: center; padding: 16px; }
.modal { width: min(440px, 100%); background: var(--surface); border-radius: 18px; padding: 20px; display: flex; flex-direction: column; gap: 12px; max-height: 90vh; overflow-y: auto; }
.modal-back:has(> .sheet) { align-items: end; padding: 0; }
.sheet { width: min(640px, 100%); margin: 0 auto; background: var(--surface); border-radius: 20px 20px 0 0; padding: 14px 16px calc(18px + env(safe-area-inset-bottom)); display: flex; flex-direction: column; gap: 12px; max-height: 92vh; overflow-y: auto; }
.sheet-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.sheet .vcard-actions { bottom: 0; }
.modal-text { font-size: 0.98rem; }
.toast { position: fixed; left: 50%; bottom: calc(150px + env(safe-area-inset-bottom)); transform: translate(-50%, 20px); z-index: 60; opacity: 0; pointer-events: none;
  background: var(--ink); color: var(--surface); padding: 10px 18px; border-radius: 999px; font-weight: 600; transition: opacity 0.2s, transform 0.2s; width: max-content; max-width: 92vw; text-align: center;
  display: flex; align-items: center; gap: 12px; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast.with-action { pointer-events: auto; padding-right: 8px; }
.toast.err { background: var(--bad); color: #fff; }
.toast-btn { min-height: 34px; padding: 4px 14px; background: transparent; color: var(--brass-hi); border-color: color-mix(in srgb, var(--brass-hi) 50%, transparent); }
@media (prefers-color-scheme: dark) { .toast-btn { color: var(--brass-lo); } }
@media (min-width: 900px) { .toast { bottom: 32px; } }
.update-bar { position: fixed; top: 0; left: 0; right: 0; z-index: 70; background: var(--ink); color: var(--surface); display: flex; gap: 12px; align-items: center; justify-content: center; padding: calc(8px + env(safe-area-inset-top)) 12px 8px; font-weight: 600; }

@media (prefers-reduced-motion: reduce) {
  .view.slide-l, .view.slide-r, .horn.on .ring, .sync-btn.spin .ic { animation: none; }
  .horn.on .ring.r1 { opacity: 0.5; transform: scale(1.25); }
}

/* « Plus de détails » sur la carte à valider */
.more { border-top: 1px solid var(--line); padding-top: 10px; }
.more > summary { display: flex; flex-wrap: wrap; gap: 4px 10px; align-items: baseline; font-weight: 700; font-size: 0.92rem; }
.more-bits { font-weight: 500; color: var(--ink-2); font-size: 0.85rem; }
.more-body { display: flex; flex-direction: column; gap: 14px; padding-top: 12px; }

.today, .week, .all, .capture { display: flex; flex-direction: column; gap: 14px; }
.focus .ctag { align-self: flex-start; }
.top-left { display: flex; align-items: center; gap: 2px; min-width: 0; }
.top-left .icon-btn { margin-left: -10px; }
