/* Appli de pilotage Eternal Conseil — charte : marine, or, crème */
:root {
  --navy: #0E223F; --navy-2: #0B1B33; --gold: #C8A15A; --cream: #F1EDE6; --card: #FFFFFF;
  --ink: #0E223F; --ink-2: #3A4556; --muted: #545C66; --line: #EEE8DD; --soft: #F7F4EE; --soft-2: #F2EDE4;
  --ok: #2F9E66; --warn: #D08A1E; --bad: #C2412D; --info: #3B6FB6;
  --shadow: 0 10px 30px rgba(14,34,63,.07); --radius: 24px;
  color-scheme: light;
}
[data-theme="sombre"] {
  --cream: #08111F; --card: #12203A; --ink: #E9EEF6; --ink-2: #C8D2E1; --muted: #A3B1C6; --line: #22385C;
  --soft: #192B49; --soft-2: #1C2F50; --shadow: 0 10px 30px rgba(0,0,0,.35); color-scheme: dark;
}
@media (prefers-color-scheme: dark) {
  [data-theme="auto"] { --cream: #08111F; --card: #12203A; --ink: #E9EEF6; --ink-2: #C8D2E1; --muted: #A3B1C6; --line: #22385C; --soft: #192B49; --soft-2: #1C2F50; --shadow: 0 10px 30px rgba(0,0,0,.35); color-scheme: dark; }
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body { background: var(--cream); color: var(--ink); font: 14px/1.45 Inter, system-ui, sans-serif; -webkit-font-smoothing: antialiased; }
a { color: inherit; }
h1, h2, h3 { font-family: Manrope, Inter, sans-serif; font-weight: 800; margin: 0; letter-spacing: -.01em; }
h1 { font-size: 28px; } h2 { font-size: 18px; } h3 { font-size: 15px; }
.muted { color: var(--muted); } .small { font-size: 12.5px; } .tiny { font-size: 11.5px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.overline { font-size: 11.5px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }

/* Coque */
.shell { display: flex; min-height: 100vh; }
.nav { flex: 0 0 236px; background: var(--navy-2); padding: 20px 14px; display: flex; flex-direction: column; gap: 18px; position: sticky; top: 0; height: 100vh; overflow-y: auto; }
.nav .brand { background: #F7F3EC; border-radius: 18px; padding: 12px 14px; display: block; }
.nav .brand img { width: 100%; height: auto; display: block; }
.nav a.item { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 14px; text-decoration: none; color: #C3CDDA; font-weight: 500; transition: background .2s, color .2s; }
.nav a.item:hover { background: rgba(255,255,255,.06); color: #fff; }
.nav a.item.on { color: #fff; font-weight: 700; background: linear-gradient(90deg, rgba(200,161,90,.24), rgba(200,161,90,.06)); }
.nav a.item svg { width: 18px; height: 18px; stroke: #A9B5C6; flex-shrink: 0; }
.nav a.item.on svg { stroke: var(--gold); }
.nav .count { margin-left: auto; font-size: 11px; font-weight: 700; border-radius: 999px; padding: 2px 8px; background: rgba(255,255,255,.1); color: #DCE3EC; }
.nav .count.bad { background: var(--bad); color: #fff; }
.nav .group-title { font-size: 11px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: #8C9AB0; padding: 0 12px; }
.nav .pin { display: flex; align-items: center; gap: 10px; padding: 7px 12px; border-radius: 12px; text-decoration: none; color: #DCE3EC; font-size: 13.5px; }
.nav .pin:hover { background: rgba(255,255,255,.06); }
.nav .me { margin-top: auto; display: flex; align-items: center; gap: 10px; padding: 10px; border-radius: 16px; background: rgba(255,255,255,.06); color: #fff; }
.nav .me button { margin-left: auto; background: none; border: 0; color: #A9B5C6; cursor: pointer; font-size: 12px; }
.main { flex: 1; min-width: 0; padding: 20px 28px 48px; display: flex; flex-direction: column; gap: 20px; }

/* Barre du haut */
.topbar { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.search-btn { flex: 1 1 320px; height: 46px; display: flex; align-items: center; gap: 12px; padding: 0 16px; border: 1px solid var(--line); border-radius: 16px; background: var(--card); color: var(--muted); font: inherit; cursor: pointer; text-align: left; }
.kbd { font-size: 12px; font-weight: 600; color: var(--ink-2); background: var(--soft-2); border-radius: 8px; padding: 3px 8px; }
.icon-btn { width: 46px; height: 46px; border: 1px solid var(--line); border-radius: 16px; background: var(--card); display: inline-flex; align-items: center; justify-content: center; color: var(--ink); text-decoration: none; cursor: pointer; }
.icon-btn svg { width: 20px; height: 20px; }

/* Boutons et champs */
.btn { height: 44px; padding: 0 18px; border-radius: 14px; border: 1px solid var(--line); background: var(--card); color: var(--ink); font: 600 14px Inter, sans-serif; cursor: pointer; display: inline-flex; align-items: center; gap: 8px; text-decoration: none; transition: transform .15s, box-shadow .2s, background .2s; white-space: nowrap; }
.btn:hover { box-shadow: 0 6px 16px rgba(14,34,63,.12); }
.btn:active { transform: translateY(1px); }
.btn.primary { background: var(--navy); border-color: var(--navy); color: #fff; box-shadow: 0 8px 20px rgba(14,34,63,.22); }
[data-theme="sombre"] .btn.primary { background: var(--gold); border-color: var(--gold); color: #0B1B33; }
.btn.gold { background: var(--gold); border-color: var(--gold); color: #0B1B33; font-weight: 800; }
.btn.danger { color: #9E2F1F; border-color: #E8A398; background: #FFF1EE; }
.btn.sm { height: 36px; padding: 0 12px; font-size: 13px; border-radius: 12px; }
.btn.ghost { border-color: transparent; background: transparent; box-shadow: none; }
.btn.dashed { border: 1.5px dashed #CFC6B6; background: transparent; justify-content: center; }
input[type=text], input[type=email], input[type=password], input[type=url], input[type=date], input[type=time], input[type=number], input[type=datetime-local], input[type=search], select, textarea {
  height: 42px; border: 1px solid var(--line); border-radius: 12px; padding: 0 12px; font: 14px Inter, sans-serif; color: var(--ink); background: var(--card); width: 100%; }
textarea { height: auto; min-height: 90px; padding: 10px 12px; resize: vertical; }
input[type=color] { width: 42px; height: 42px; border: 1px solid var(--line); border-radius: 12px; padding: 4px; background: var(--card); }
input:focus, select:focus, textarea:focus, button:focus-visible, a:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
label.field { display: flex; flex-direction: column; gap: 6px; font-size: 12.5px; font-weight: 600; color: var(--ink-2); }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.form-grid .full { grid-column: 1 / -1; }
.check-line { display: flex; align-items: center; gap: 10px; font-size: 13.5px; font-weight: 500; }
.check-line input { width: 18px; height: 18px; accent-color: var(--navy); }

/* Cartes */
.card { background: var(--card); border-radius: var(--radius); padding: 22px 24px; box-shadow: var(--shadow); }
.card.flush { padding: 8px; }
.card-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 14px; }
.grid { display: grid; gap: 20px; }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); } .g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.split { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: 20px; }
.row { display: flex; gap: 12px; align-items: center; }
.stack { display: flex; flex-direction: column; gap: 10px; }
.hero { position: relative; overflow: hidden; background: var(--navy); color: #fff; border-radius: 28px; padding: 28px 30px; }
.hero::before, .hero::after { content: ""; position: absolute; border-radius: 50%; border: 1px solid rgba(200,161,90,.32); pointer-events: none; }
.hero::before { right: -90px; top: -130px; width: 380px; height: 380px; }
.hero::after { right: -30px; top: -70px; width: 250px; height: 250px; border-color: rgba(200,161,90,.2); }
.hero .overline { color: var(--gold); }
.hero p { color: #C9D3E0; margin: 8px 0 0; max-width: 520px; }

/* Puces, pastilles, logos */
.chip { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600; border-radius: 999px; padding: 4px 10px; background: var(--soft-2); color: var(--ink-2); white-space: nowrap; }
.chip .dot, .dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; flex-shrink: 0; }
.tag { font-size: 11px; font-weight: 800; border-radius: 999px; padding: 3px 9px; white-space: nowrap; }
.logo-tile { width: 40px; height: 40px; border-radius: 12px; background: #fff; border: 1px solid var(--line); display: inline-flex; align-items: center; justify-content: center; overflow: hidden; flex-shrink: 0; font-family: Manrope, sans-serif; font-weight: 800; font-size: 14px; color: #0E223F; }
.logo-tile img { max-width: 82%; max-height: 82%; object-fit: contain; }
.logo-tile.lg { width: 92px; height: 92px; border-radius: 26px; font-size: 28px; box-shadow: 0 10px 24px rgba(14,34,63,.18); }
.logo-tile.sm { width: 22px; height: 22px; border-radius: 6px; font-size: 9px; }
.logo-tile.xs { width: 28px; height: 28px; border-radius: 9px; font-size: 10px; }

/* Lanceur */
.launcher { display: grid; grid-template-columns: repeat(auto-fill, minmax(84px, 1fr)); gap: 12px 8px; }
.tool { display: flex; flex-direction: column; align-items: center; gap: 7px; text-decoration: none; color: var(--ink); padding: 6px 2px; border-radius: 14px; transition: transform .15s; }
.tool:hover { transform: translateY(-2px); }
.tool .ic { width: 54px; height: 54px; border-radius: 17px; background: #fff; border: 1px solid var(--line); box-shadow: 0 6px 16px rgba(14,34,63,.10); display: inline-flex; align-items: center; justify-content: center; font-family: Manrope, sans-serif; font-weight: 800; font-size: 17px; }
.tool .ic img { width: 26px; height: 26px; }
.tool span:last-child { font-size: 11.5px; font-weight: 500; text-align: center; line-height: 1.25; }
.dock { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 2px; }
.dock .tool { flex: 0 0 86px; }

/* Tâches */
.task { display: flex; align-items: center; gap: 14px; padding: 10px 12px; border-radius: 14px; border-top: 1px solid var(--soft-2); transition: background .2s; }
.task:first-of-type { border-top: 0; }
.task.done .t-title { color: #8A929C; text-decoration: line-through; }
.task.focus { background: #FBF6EC; box-shadow: inset 0 0 0 1.5px var(--gold); }
.check { width: 26px; height: 26px; border-radius: 9px; border: 2px solid #CFC6B6; background: var(--card); cursor: pointer; display: inline-flex; align-items: center; justify-content: center; padding: 0; flex-shrink: 0; transition: all .25s; }
.check svg { width: 14px; height: 14px; stroke: #fff; opacity: 0; transition: opacity .2s; }
.check.on { background: var(--ok); border-color: var(--ok); box-shadow: 0 4px 10px rgba(47,158,102,.35); }
.check.on svg { opacity: 1; }
.check.pop { animation: pop .35s ease; }
@keyframes pop { 50% { transform: scale(1.2); } }
.t-body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.t-title { font-weight: 600; font-size: 14.5px; }
.t-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 12px; color: var(--muted); }
.t-due { font-size: 12.5px; font-weight: 600; white-space: nowrap; }
.t-due.late { color: #9E2F1F; }
.timer { height: 34px; min-width: 100px; display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 0 12px; border-radius: 10px; border: 0; cursor: pointer; font: 700 12px Inter, sans-serif; font-variant-numeric: tabular-nums; background: var(--soft-2); color: var(--ink); }
.timer.on { background: var(--navy); color: #fff; }
.timer svg { width: 12px; height: 12px; }
details.edit > summary { list-style: none; cursor: pointer; }
details.edit > summary::-webkit-details-marker { display: none; }
details.edit[open] { background: var(--soft); border-radius: 16px; padding: 10px; }

/* Alertes */
.alert-grave { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; padding: 16px 20px; border-radius: 22px; background: #FFF1EE; border: 1.5px solid #E8A398; color: #6E1F14; box-shadow: 0 10px 26px rgba(194,65,45,.14); }
.alert-grave .badge { width: 48px; height: 48px; border-radius: 15px; background: var(--bad); display: inline-flex; align-items: center; justify-content: center; box-shadow: 0 0 0 6px rgba(194,65,45,.15); }
.alert-grave .badge svg { width: 24px; height: 24px; stroke: #fff; }
.flash { padding: 12px 16px; border-radius: 14px; font-weight: 600; }
.flash.ok { background: #E3F1E9; color: #1B5E3E; }
.flash.error { background: #FBE7E3; color: #9E2F1F; }

/* Anneaux et barres */
.ring { position: relative; display: inline-flex; align-items: center; justify-content: center; }
.ring svg { transform: rotate(-90deg); }
.ring b { position: absolute; font-family: Manrope, sans-serif; font-weight: 800; }
.bar { height: 6px; border-radius: 6px; background: var(--soft-2); overflow: hidden; }
.bar > span { display: block; height: 100%; border-radius: 6px; background: var(--gold); transition: width .4s; }
.steps { display: flex; gap: 6px; margin: 0; padding: 0; list-style: none; }
.steps li { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 8px; }
.steps li button { all: unset; cursor: pointer; display: flex; flex-direction: column; gap: 8px; }
.steps .seg { height: 6px; border-radius: 6px; background: var(--soft-2); }
.steps .done .seg { background: var(--ok); } .steps .cur .seg { background: var(--gold); }
.steps .lbl { font-size: 12px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.steps .cur .lbl { color: var(--ink); font-weight: 700; } .steps .done .lbl { color: var(--ink-2); }

/* Timeline */
.timeline { position: relative; height: 116px; }
.timeline .hours { position: absolute; inset: 0 0 auto 0; display: flex; justify-content: space-between; }
.timeline .hours span { width: 0; display: flex; flex-direction: column; align-items: center; gap: 8px; font-size: 11px; color: var(--muted); }
.timeline .hours span::after { content: ""; width: 1px; height: 86px; background: var(--soft-2); }
.timeline .blk { position: absolute; height: 38px; border-radius: 12px; padding: 4px 10px; color: #fff; display: flex; flex-direction: column; justify-content: center; overflow: hidden; box-shadow: 0 4px 12px rgba(14,34,63,.15); font-size: 12.5px; font-weight: 600; white-space: nowrap; }
.timeline .blk small { font-weight: 400; opacity: .9; font-size: 11px; }
.timeline .now { position: absolute; top: 22px; bottom: 0; width: 2px; background: var(--gold); }
.timeline .now::before { content: ""; position: absolute; top: -6px; left: -5px; width: 12px; height: 12px; border-radius: 50%; background: var(--gold); border: 2px solid var(--card); }

/* Fiche */
.fiche { display: flex; flex-wrap: wrap; gap: 20px; align-items: flex-start; }
.fiche > .col { flex: 999 1 600px; min-width: 0; display: flex; flex-direction: column; gap: 18px; }
.fiche > aside { flex: 1 1 260px; max-width: 310px; display: flex; flex-direction: column; gap: 14px; }
.cover { background: var(--card); border-radius: 28px; box-shadow: var(--shadow); overflow: hidden; }
.cover .band { height: 92px; background: var(--navy); position: relative; overflow: hidden; }
.cover .band::after { content: ""; position: absolute; right: -40px; top: -120px; width: 340px; height: 340px; border-radius: 50%; border: 1px solid rgba(200,161,90,.4); }
.cover .head { padding: 0 24px 20px; position: relative; display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 14px; }
.cover .head .logo-tile.lg { margin-top: -46px; }
.cover .head .who { padding-top: 14px; }
.cover .dockwrap { border-top: 1px solid var(--soft-2); padding: 14px 16px; }
.tabs { display: inline-flex; flex-wrap: wrap; gap: 4px; padding: 5px; background: var(--soft-2); border-radius: 16px; align-self: flex-start; }
.tabs a { height: 40px; padding: 0 16px; border-radius: 12px; display: inline-flex; align-items: center; gap: 8px; text-decoration: none; font-size: 13.5px; color: var(--ink-2); font-weight: 500; }
.tabs a.on { background: var(--card); color: var(--ink); font-weight: 700; box-shadow: 0 2px 8px rgba(14,34,63,.12); }
.sub { display: flex; align-items: center; gap: 12px; width: 100%; padding: 10px; border-radius: 16px; text-decoration: none; border: 1px solid transparent; transition: all .2s; }
.sub:hover { background: var(--soft); }
.sub.on { border-color: var(--gold); background: #FBF6EC; }
[data-theme="sombre"] .sub.on, [data-theme="sombre"] .task.focus { background: #2A2614; }
.project { border: 1px solid var(--line); border-radius: 20px; padding: 16px 18px; display: flex; flex-direction: column; gap: 14px; }
.client-card { background: var(--card); border-radius: 22px; padding: 18px; box-shadow: var(--shadow); text-decoration: none; display: flex; flex-direction: column; gap: 12px; transition: transform .15s; }
.client-card:hover { transform: translateY(-2px); }

/* Réglages */
.settings { display: flex; flex-wrap: wrap; gap: 18px; align-items: flex-start; }
.settings nav { flex: 0 0 240px; background: var(--card); border-radius: 22px; padding: 10px; box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 2px; }
.settings nav a { height: 44px; display: flex; align-items: center; padding: 0 12px; border-radius: 12px; text-decoration: none; font-weight: 500; }
.settings nav a.on { background: #FBF6EC; font-weight: 700; }
[data-theme="sombre"] .settings nav a.on { background: #2A2614; }
.settings .pane { flex: 999 1 560px; min-width: 0; display: flex; flex-direction: column; gap: 16px; }
.link-row { display: grid; grid-template-columns: 44px minmax(0, 1fr) minmax(0, 1.6fr) 40px; gap: 10px; align-items: center; }
.switch { position: relative; width: 52px; height: 30px; flex-shrink: 0; }
.switch input { opacity: 0; width: 0; height: 0; }
.switch span { position: absolute; inset: 0; border-radius: 999px; background: #CFC6B6; transition: background .2s; cursor: pointer; }
.switch span::after { content: ""; position: absolute; top: 3px; left: 3px; width: 24px; height: 24px; border-radius: 50%; background: #fff; box-shadow: 0 2px 6px rgba(0,0,0,.2); transition: left .2s; }
.switch input:checked + span { background: var(--ok); }
.switch input:checked + span::after { left: 25px; }
.qr svg { width: 220px; height: 220px; background: #fff; border-radius: 16px; padding: 12px; }

/* Palette Ctrl K */
.palette-bg { position: fixed; inset: 0; background: rgba(11,27,51,.55); display: none; z-index: 50; }
.palette-bg.open { display: block; }
.palette { position: absolute; left: 50%; top: 10vh; transform: translateX(-50%); width: min(680px, 94vw); background: var(--card); border-radius: 24px; box-shadow: 0 30px 80px rgba(11,27,51,.45); overflow: hidden; }
.palette .q { display: flex; align-items: center; gap: 12px; padding: 16px 20px; border-bottom: 1px solid var(--soft-2); }
.palette .q input { border: 0; height: 40px; font-size: 19px; padding: 0; background: transparent; }
.palette .q input:focus { outline: none; }
.palette .res { max-height: 56vh; overflow-y: auto; padding: 8px; }
.palette .grp { font-size: 11px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); padding: 10px 12px 6px; }
.palette .it { display: flex; flex-direction: column; gap: 1px; width: 100%; padding: 10px 12px; border: 0; border-radius: 14px; background: transparent; text-align: left; cursor: pointer; color: var(--ink); font: inherit; text-decoration: none; }
.palette .it.sel { background: #FBF6EC; box-shadow: inset 0 0 0 1.5px var(--gold); }
[data-theme="sombre"] .palette .it.sel { background: #2A2614; }
.palette .foot { display: flex; flex-wrap: wrap; gap: 16px; padding: 10px 20px; border-top: 1px solid var(--soft-2); background: var(--soft); font-size: 12px; color: var(--muted); }

/* Connexion */
.auth { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 24px; background: var(--navy-2); }
.auth .box { width: min(440px, 100%); background: var(--card); border-radius: 28px; padding: 32px; display: flex; flex-direction: column; gap: 16px; box-shadow: 0 30px 80px rgba(0,0,0,.35); }
.auth .box img.logo { width: 220px; align-self: center; }

/* Téléphone */
.mobile-tabs { display: none; }
@media (max-width: 900px) {
  .nav { display: none; }
  .main { padding: 14px 14px 104px; }
  .g2, .g3, .g4, .split, .form-grid { grid-template-columns: 1fr; }
  .fiche > aside { max-width: none; }
  .timeline .hours span:nth-child(even) { visibility: hidden; }
  .mobile-tabs { display: grid; grid-template-columns: repeat(5, 1fr); position: fixed; left: 10px; right: 10px; bottom: 12px; height: 68px; background: var(--navy-2); border-radius: 24px; z-index: 40; box-shadow: 0 12px 28px rgba(11,27,51,.35); align-items: center; }
  .mobile-tabs a { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; min-height: 48px; color: #A9B5C6; text-decoration: none; font-size: 10.5px; }
  .mobile-tabs a.on { color: #fff; font-weight: 700; }
  .mobile-tabs svg { width: 20px; height: 20px; stroke: currentColor; }
  .mobile-tabs .fab { width: 54px; height: 54px; margin: -26px auto 0; border-radius: 18px; border: 4px solid var(--cream); background: var(--gold); color: #0B1B33; font-size: 26px; font-weight: 700; cursor: pointer; }
  .link-row { grid-template-columns: 40px 1fr 40px; }
  .link-row input[type=url] { grid-column: 2 / 4; }
  .settings nav { flex: 1 1 100%; flex-direction: row; overflow-x: auto; }
  .settings nav a { white-space: nowrap; }
  .topbar { flex-wrap: nowrap; }
  .search-btn { flex: 1; min-width: 0; }
  .search-btn span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .task { flex-wrap: wrap; row-gap: 6px; }
  .task .t-body { flex: 1 1 calc(100% - 50px); }
  .task .t-due { margin-left: 46px; }
  .task .js-timer { margin-left: auto; }
  .search-btn .kbd, .btn.primary.js-palette[data-mode=quick]:not(.fab) { display: none; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }

/* Pipeline des tâches */
.pipeline { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(250px, 1fr); gap: 14px; overflow-x: auto; padding-bottom: 6px; align-items: start; }
.pcol { background: var(--soft); border-radius: 20px; padding: 12px; min-height: 200px; }
.pdrop { display: flex; flex-direction: column; gap: 10px; min-height: 120px; border-radius: 14px; transition: background .2s; }
.pcol.over .pdrop { background: rgba(200,161,90,.14); }
.pcard { background: var(--card); border-radius: 14px; padding: 12px; box-shadow: 0 2px 8px rgba(14,34,63,.06); display: flex; flex-direction: column; gap: 8px; cursor: grab; }
.pcard.dragging { opacity: .5; }
.pselect { height: 28px !important; width: auto !important; font-size: 11.5px !important; padding: 0 6px !important; border-radius: 8px !important; }

/* Carte (vue d'ensemble) */
.carte { columns: 3 340px; column-gap: 20px; }
.carte-bloc { break-inside: avoid; margin-bottom: 20px; display: inline-block; width: 100%; }
.carte-bloc.hot { box-shadow: 0 0 0 1.5px #E8A398, var(--shadow); }
.carte-nodes { display: flex; flex-direction: column; gap: 12px; margin-top: 14px; }
.carte-node { display: flex; flex-direction: column; gap: 6px; padding: 10px 12px; border-radius: 16px; background: var(--soft); }
.carte-proj { display: flex; flex-direction: column; gap: 4px; padding: 2px 0; }
.carte-task { display: flex; align-items: center; gap: 8px; font-size: 13px; text-decoration: none; padding: 3px 0; }
.carte-task:hover span:nth-child(2) { text-decoration: underline; }

/* --- calendrier éditorial --- */
.cal { overflow: hidden; padding: 0; }
.cal-head, .cal-week { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); }
.cal-head span { padding: 10px 8px; font-size: 11.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); text-align: center; }
.cal-day { min-height: 112px; border-top: 1px solid var(--soft-2); border-left: 1px solid var(--soft-2); padding: 6px; display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.cal-day:nth-child(7n+1) { border-left: 0; }
.cal-day.out { background: rgba(0,0,0,.015); }
.cal-day.out .cal-num { color: #B9B2A5; }
.cal-day.today .cal-num { background: var(--navy); color: #fff; }
.cal-num { align-self: flex-start; font-size: 12px; font-weight: 700; text-decoration: none; width: 24px; height: 24px; border-radius: 8px; display: inline-flex; align-items: center; justify-content: center; }
.cal-num:hover { background: var(--soft-2); }
.cal-post { display: flex; flex-wrap: wrap; align-items: center; gap: 5px; font-size: 11.5px; font-weight: 600; text-decoration: none; background: #fff; border: 1px solid var(--line); border-left: 3px solid; border-radius: 8px; padding: 4px 6px; min-width: 0; }
.cal-post > span:nth-child(2) { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cal-post.on { box-shadow: 0 0 0 2px var(--gold); }
.cal-client { width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 500; }
@media (max-width: 900px) {
  .cal-head { display: none; }
  .cal-week { grid-template-columns: 1fr; }
  .cal-day { min-height: 0; border-left: 0; flex-direction: row; flex-wrap: wrap; }
  .cal-day.out { display: none; }
}

/* --- factures --- */
.inv-lines { display: flex; flex-direction: column; gap: 8px; }
.inv-line { display: grid; grid-template-columns: minmax(0, 1fr) 70px 110px 70px 40px; gap: 8px; align-items: center; }
.inv-line.ro { grid-template-columns: minmax(0, 1fr) 50px 100px 60px 110px; padding: 8px 0; border-top: 1px solid var(--soft-2); }
.inv-line.ro span:not(:first-child) { text-align: right; }
.inv-line.head { font-size: 11.5px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; border-top: 0; }
@media (max-width: 900px) {
  .inv-line { grid-template-columns: 1fr 1fr 1fr 40px; }
  .inv-line input[name=label] { grid-column: 1 / -1; }
  .inv-line.head { display: none; }
  .inv-line.ro { grid-template-columns: 1fr auto; }
  .inv-line.ro span:nth-child(2), .inv-line.ro span:nth-child(3), .inv-line.ro span:nth-child(4) { display: none; }
}

/* --- espace client --- */
.client-space { display: block; }
.cs-top { position: sticky; top: 0; z-index: 30; display: flex; align-items: center; gap: 18px; padding: 12px 28px; background: var(--navy-2); flex-wrap: wrap; }
.cs-brand { background: #F7F3EC; border-radius: 14px; padding: 8px 12px; display: block; }
.cs-brand img { height: 30px; display: block; }
.cs-nav { display: flex; gap: 4px; flex: 1; flex-wrap: wrap; }
.cs-nav a { display: flex; align-items: center; gap: 8px; padding: 9px 12px; border-radius: 12px; color: #C9D3E0; text-decoration: none; font-weight: 600; font-size: 14px; }
.cs-nav a svg { stroke: #A9B5C6; }
.cs-nav a.on { background: rgba(255,255,255,.1); color: #fff; }
.cs-nav a.on svg { stroke: var(--gold); }
.cs-top .btn.ghost { color: #fff; }
.cs-main { max-width: 1180px; margin: 0 auto; }
@media (max-width: 900px) {
  .cs-top { padding: 10px 12px; gap: 10px; }
  .cs-nav { order: 3; flex: 1 1 100%; overflow-x: auto; flex-wrap: nowrap; }
  .cs-nav a span { white-space: nowrap; }
  .cs-main { padding-bottom: 40px; }
}
