/* Espace équipe — Allumen.Guide identity (shared tokens from app.css) */
body.admin { padding-bottom: 40px; background: var(--ivory); color: var(--ink-c); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) body.admin { --bg: var(--ivory); --surface: #fffdf8; --surface-2: var(--stone-100); --line: var(--stone-200); --ink: var(--ink-ds); --ink-2: var(--ink-soft); --ink-3: var(--ink-mute); --prune-2: var(--framboise); --prune-soft: var(--stone-100); --terra: var(--framboise-hover); --terra-soft: var(--gold-soft); --warn-bg: var(--gold-soft); --warn-ink: #6b3d12; color-scheme: light; } }
.admin .wrap { max-width: 1120px; }
.adm-top { background: var(--ivory); border-bottom: 1px solid var(--line); }
.adm-top .wrap { display: flex; flex-wrap: wrap; gap: 8px 16px; align-items: center; justify-content: space-between; min-height: 60px; padding-top: 8px; padding-bottom: 8px; }
.adm-logo { display: inline-flex; align-items: center; gap: 8px; text-decoration: none; }
.adm-logo img { height: 30px; width: auto; } .adm-logo img.word { height: 18px; }
.adm-top .who { font-size: .85rem; color: var(--ink-3); display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.adm-top a, .linkbtn { color: var(--raspberry); }
.linkbtn { background: none; border: 0; font: inherit; text-decoration: underline; cursor: pointer; padding: 0; }
.role-chip { display: inline-block; font: 600 .72rem/1 var(--sans); letter-spacing: .06em; text-transform: uppercase; padding: 6px 9px; border-radius: 99px; background: var(--gold-soft); color: var(--framboise-hover); }
.role-chip.staff { background: var(--night); color: var(--ivory); }
.adm-project { background: var(--night); color: var(--ivory); }
.adm-project .wrap { display: flex; flex-wrap: wrap; gap: 6px 20px; align-items: center; min-height: 64px; padding-top: 10px; padding-bottom: 10px; }
.adm-project .back { color: var(--peach); font-weight: 600; text-decoration: none; display: inline-flex; gap: 6px; align-items: center; min-height: 44px; padding-right: 6px; }
.adm-project .back:hover { text-decoration: underline; }
.adm-project .ptitle { display: flex; flex-direction: column; line-height: 1.2; min-width: 0; }
.adm-project .kick { font: 560 .72rem var(--sans); text-transform: uppercase; letter-spacing: .08em; color: var(--peach); }
.adm-project b { font: 600 1.25rem/1.25 var(--serif); color: var(--ivory); }
.adm-nav { background: #fffdf8; border-bottom: 1px solid var(--line); overflow-x: auto; }
.adm-nav ul { list-style: none; margin: 0 auto; padding: 0 16px; display: flex; gap: 2px; max-width: 1120px; }
.adm-nav a { display: block; padding: 13px 10px; white-space: nowrap; color: var(--ink-2); text-decoration: none; font-weight: 600; font-size: .9rem; border-bottom: 3px solid transparent; }
.adm-nav a:hover { color: var(--raspberry); }
.adm-nav a[aria-current] { color: var(--raspberry); border-color: var(--raspberry); }
.admin main.wrap { padding-top: 22px; }
.admin h1 { color: var(--ink-c); }
.page-head { display: flex; flex-wrap: wrap; gap: 12px 20px; align-items: flex-end; justify-content: space-between; margin-bottom: 18px; }
.page-head h1 { margin: 0 0 4px; }
.page-head p { margin: 0; }
/* project cards */
.pgrid { list-style: none; padding: 0; margin: 0; display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr)); }
.pcard { display: grid; grid-template-columns: 96px minmax(0, 1fr) auto; gap: 14px; align-items: center; padding: 10px 14px 10px 10px; border-radius: var(--r-m); background: #fff; border: 1px solid var(--line); text-decoration: none; color: var(--ink-c); box-shadow: var(--shadow-1); }
.pcard:hover { border-color: var(--raspberry); }
.pthumb { width: 96px; height: 96px; border-radius: 12px; overflow: hidden; background: var(--stone-100); display: grid; place-items: center; color: var(--ink-3); flex: none; }
.pthumb img { width: 100%; height: 100%; object-fit: cover; }
.pthumb.lg { width: 140px; height: 140px; }
.pbody { display: flex; flex-direction: column; gap: 4px; min-width: 0; align-items: flex-start; }
.pname { font: 600 1.15rem/1.25 var(--serif); }
.pcard .go { width: 44px; height: 44px; border-radius: 99px; display: grid; place-items: center; background: var(--raspberry); color: var(--ivory); }
.proj-hero { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 18px; align-items: center; margin: 0 0 20px; }
.proj-hero h1 { margin: 6px 0 2px; }
@media (max-width: 560px) { .proj-hero { grid-template-columns: 1fr; } .pthumb.lg { width: 100%; height: 180px; } }
.links { margin: 0; font-size: .9rem; }
.items.grid2 { display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr)); list-style: none; padding: 0; }
td.tcell { width: 64px; padding: 6px 8px; }
td.tcell .thumb { --thumb: 48px; width: 48px; height: 48px; border-radius: 8px; }
.hero-edit { display: grid; gap: 16px; }
@media (min-width: 760px) { .hero-edit { grid-template-columns: 180px 1fr; } }
.hero-prev { display: flex; flex-direction: column; gap: 6px; align-items: center; }
.hero-prev img { width: 180px; height: 320px; object-fit: cover; border-radius: 16px; border: 1px solid var(--line); }
.admin .btn:hover { background: var(--raspberry-hover); }
.admin .btn.ghost:hover { background: var(--rose); }
.flash { padding: 10px 14px; border-radius: 10px; margin: 0 0 14px; background: #e3f1e7; color: #1f4a2c; }
.flash.err { background: #fde7e4; color: #7a1d12; }
.fld { display: block; margin: 0 0 12px; }
.fld > span { display: block; font-weight: 600; font-size: .88rem; margin-bottom: 4px; }
.fld input, .fld textarea, .fld select { width: 100%; font: inherit; font-size: .95rem; padding: 10px 12px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); }
.fld input[readonly] { background: var(--surface-2); color: var(--ink-3); }
.fld .hint { display: block; font-size: .78rem; color: var(--ink-3); margin-top: 3px; }
.grid2 { display: grid; gap: 0 16px; }
@media (min-width: 760px) { .grid2 { grid-template-columns: 1fr 1fr; } }
.actions { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0; align-items: center; }
.inline { display: inline; margin: 0; }
.btn.sm { min-height: 36px; padding: 0 12px; font-size: .85rem; }
.btn.danger { background: #8a2416; }
table.t { width: 100%; border-collapse: collapse; font-size: .9rem; background: var(--surface); border-radius: 12px; overflow: hidden; }
table.t th, table.t td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--line); vertical-align: top; }
table.t th { font-size: .76rem; text-transform: uppercase; letter-spacing: .07em; font-weight: 600; color: var(--ink-3); background: var(--stone-100); }
.tbl-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 12px; }
.badge.ok { background: #e3f1e7; color: #1f4a2c; }
.pending-note { background: var(--warn-bg); color: var(--warn-ink); padding: 8px 12px; border-radius: 10px; font-size: .88rem; margin: 8px 0; }
.locked { font-family: ui-monospace, monospace; background: var(--surface-2); padding: 2px 6px; border-radius: 6px; }
.media-row { display: grid; grid-template-columns: 120px 1fr; gap: 14px; padding: 14px 0; border-top: 1px solid var(--line); }
.media-row img { width: 120px; border-radius: 10px; background: var(--surface-2); }
.adm-plan { display: grid; gap: 16px; }
@media (min-width: 860px) { .adm-plan { grid-template-columns: 300px 1fr; } }
.adm-plan .list { max-height: 70vh; overflow: auto; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); }
.adm-plan .list button { display: flex; width: 100%; gap: 8px; align-items: center; text-align: left; padding: 8px 10px; border: 0; border-bottom: 1px solid var(--line); background: transparent; color: var(--ink); font: inherit; font-size: .88rem; cursor: pointer; }
.adm-plan .list button[aria-pressed="true"] { background: var(--prune-soft); }
.adm-plan .list .placed::after { content: '●'; color: var(--ok); margin-left: auto; }
.adm-plan .stage { position: relative; max-width: 520px; cursor: crosshair; }
.adm-plan .stage img { width: 100%; height: auto; }
.adm-plan .stage .ov { width: 100%; height: 100%; }
.adm-plan .stage .ov { position: absolute; inset: 0; opacity: .45; pointer-events: none; }
.adm-plan .mk.sel { background: var(--prune); transform: translate(-50%, -50%) scale(1.25); }
.secret { font-family: ui-monospace, monospace; background: var(--warn-bg); padding: 8px 12px; border-radius: 8px; display: inline-block; }
.steps-edit .row { display: grid; grid-template-columns: 34px 1fr; gap: 8px; align-items: start; padding: 10px 0; border-top: 1px solid var(--line); }
.cards3 { display: grid; gap: 12px; }
@media (min-width: 760px) { .cards3 { grid-template-columns: repeat(3, 1fr); } }
.cards3 .card + .card { margin-top: 0; }
@media (min-width: 900px) { .adm-nav ul { flex-wrap: wrap; } }

/* design system (landing page): warm paper sections, framboise actions, safran accents on night */
html:has(body.admin) { background: var(--paper); }
body.admin { background: linear-gradient(180deg, var(--ivory) 0, var(--paper) 100vh, var(--paper)); min-height: 100vh; }
.pcard, .card { background: #fffdf8; }
.admin .btn.ghost:hover { background: #ad493612; }
.adm-project .back { color: var(--peach); }
.flash { background: #e6f1e8; color: #1f4a2c; }
.badge.ok { background: #e6f1e8; color: #1f4a2c; }

/* project status: coming soon / en ligne / hors ligne */
.badge.soon { background: #302622; color: #fffaf3; }
.badge.off { background: #ecd9c6; color: #54453e; }
.pgrid > li { display: flex; flex-direction: column; gap: 0; }
.pgrid > li .pcard { border-bottom-left-radius: 0; border-bottom-right-radius: 0; }
.pgrid > li .vis-form { border: 1px solid var(--line); border-top: 0; border-radius: 0 0 var(--radius-m) var(--radius-m); background: #fffdf8; padding: 8px 12px; }
.pgrid > li > a.pcard:only-child { border-radius: var(--radius-m); }
.vis-form { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin: 0; }
.vis-form select { font: inherit; font-size: .9rem; padding: 7px 10px; border-radius: 10px; border: 1px solid var(--line); background: #fff; color: var(--ink); min-height: 38px; }
.proj-hero .vis-form { display: inline-flex; margin-left: 8px; vertical-align: middle; }

/* ───────── v2.4 : menu latéral commun (admin Allumen + client) ───────── */
.admin.has-side { padding-bottom: 0; }
.adm-shell { display: grid; grid-template-columns: 268px minmax(0, 1fr); min-height: 100vh; background: linear-gradient(90deg, #fffdf8 267px, var(--line) 267px, var(--line) 268px, transparent 268px); }
.adm-side { position: sticky; top: 0; align-self: start; height: 100vh; overflow-y: auto; display: flex; flex-direction: column; gap: 14px;
  padding: 18px 14px 14px; background: #fffdf8; border-right: 1px solid var(--line); }
.adm-side .adm-logo { padding: 2px 8px 6px; }
.side-ctx { display: flex; flex-direction: column; gap: 6px; padding: 12px; border-radius: 14px; background: var(--night); color: var(--ivory); }
.side-kick { font: 600 .7rem/1 var(--sans); letter-spacing: .08em; text-transform: uppercase; color: var(--peach); }
.side-church { font: 600 1.12rem/1.25 var(--serif); color: var(--ivory); }
.side-switch { display: flex; gap: 6px; }
.side-switch select { flex: 1; min-width: 0; font: inherit; font-size: .9rem; padding: 8px 10px; border-radius: 10px; border: 1px solid #ffffff40; background: #fffaf3; color: var(--ink-c); min-height: 40px; }
.side-switch .side-go { color: var(--ivory); border-color: #ffffff60; }
.js .side-switch .side-go { display: none; }
.side-nav { display: flex; flex-direction: column; gap: 4px; flex: 1; }
.side-group { margin: 10px 10px 4px; font: 600 .72rem/1.3 var(--sans); letter-spacing: .07em; text-transform: uppercase; color: var(--ink-3); }
.adm-side ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 2px; }
.adm-side li a, .side-logout { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 42px; padding: 8px 10px; border-radius: 10px;
  color: var(--ink-2); text-decoration: none; font: 600 .92rem/1.25 var(--sans); background: none; border: 0; cursor: pointer; text-align: left; position: relative; }
.adm-side li a .ic, .side-logout .ic { width: 19px; height: 19px; flex: none; color: var(--ink-3); }
.adm-side li a:hover, .side-logout:hover { background: var(--stone-100); color: var(--raspberry); }
.adm-side li a[aria-current="page"] { background: #ad49361a; color: var(--framboise-hover); }
.adm-side li a[aria-current="page"]::before { content: ''; position: absolute; left: -14px; top: 8px; bottom: 8px; width: 4px; border-radius: 0 4px 4px 0; background: var(--raspberry); }
.adm-side li a[aria-current="page"] .ic { color: var(--raspberry); }
.side-foot { border-top: 1px solid var(--line); padding-top: 10px; }
.side-user { margin: 0 10px 6px; display: flex; flex-direction: column; font-size: .85rem; line-height: 1.3; min-width: 0; }
.side-user span { color: var(--ink-3); font-size: .78rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.side-foot form { margin: 0; }
.adm-content { min-width: 0; }
.has-side main.wrap { max-width: 1120px; margin: 0; padding: 26px 32px 48px; }
.adm-mobilebar { display: none; }
main:focus { outline: none; }
@media (max-width: 959px) {
  .adm-shell { display: block; }
  .adm-mobilebar { display: flex; position: sticky; top: 0; z-index: 20; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 16px; background: #fffdf8; border-bottom: 1px solid var(--line); }
  .adm-mobilebar .adm-logo img { height: 26px; } .adm-mobilebar .adm-logo img.word { height: 16px; }
  .menu-btn { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 14px; border-radius: 99px; border: 1px solid var(--line); background: #fff; color: var(--ink-c); font-weight: 600; text-decoration: none; }
  .menu-btn[aria-expanded="true"] { background: var(--night); color: var(--ivory); border-color: var(--night); }
  .adm-side { display: none; position: static; height: auto; border-right: 0; border-bottom: 1px solid var(--line); box-shadow: 0 10px 24px #30262214; }
  .adm-side .adm-logo { display: none; }
  .adm-side:target, .side-open .adm-side { display: flex; }
  .has-side main.wrap { padding: 18px 16px 40px; }
}
/* status */
.badge.prep { background: #fdebc2; color: #6b3d12; }
.badge.soon { background: #302622; color: #fffaf3; }
.badge.off { background: #ecd9c6; color: #54453e; }
.st-line { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 8px 0 2px; }
.st-line .vis-form { margin-left: 4px; }
.st-now { margin: 4px 0 0; max-width: 62ch; }
.kicker-sm { margin: 0 0 4px; font: 600 .74rem var(--sans); letter-spacing: .08em; text-transform: uppercase; color: var(--raspberry); }
.status-pick fieldset { border: 0; margin: 0; padding: 0; display: grid; gap: 8px; }
.status-pick legend { font-weight: 600; margin-bottom: 8px; }
.st-opt { display: grid; grid-template-columns: 22px 1fr; gap: 10px; padding: 12px; border: 1px solid var(--line); border-radius: 12px; cursor: pointer; background: #fff; }
.st-opt input { margin-top: 3px; accent-color: var(--raspberry); width: 18px; height: 18px; }
.st-opt.is-sel, .st-opt:has(input:checked) { border-color: var(--raspberry); box-shadow: 0 0 0 1px var(--raspberry) inset; }
.st-body { display: flex; flex-direction: column; gap: 4px; }
.st-confirm { margin-top: 16px; border-color: var(--raspberry); }
.st-confirm h2 { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; font-size: 1.15rem; margin-top: 0; }
.st-effects { margin: 0; display: grid; gap: 10px; }
.st-effects div { display: grid; gap: 2px; }
.st-effects dt { font-weight: 600; font-size: .85rem; color: var(--ink-3); }
.st-effects dd { margin: 0; }
/* accounts */
.auth-box { max-width: 440px; margin: 40px auto; }
.search-bar { display: flex; flex-wrap: wrap; gap: 0 12px; align-items: flex-end; padding-bottom: 4px; }
.search-bar .grow { flex: 1 1 240px; } .search-bar .btn { margin-bottom: 12px; }
.users-t .acc { display: inline-block; margin: 0 6px 4px 0; padding: 3px 8px; border-radius: 8px; background: var(--stone-100); }
.u-name { font-weight: 600; }
.cols2 { display: grid; gap: 16px; align-items: start; }
@media (min-width: 1100px) { .cols2 { grid-template-columns: 1fr 1fr; } }
.cols2 .card + .card { margin-top: 0; }
.kv { margin: 0 0 8px; display: grid; gap: 6px; } .kv div { display: flex; gap: 8px; flex-wrap: wrap; } .kv dt { color: var(--ink-3); min-width: 140px; } .kv dd { margin: 0; }
.type-form { display: flex; gap: 8px; align-items: flex-end; flex-wrap: wrap; border-top: 1px solid var(--line); padding-top: 12px; margin-top: 4px; }
.type-form .fld { margin: 0; flex: 1 1 220px; }
.access-t select { font: inherit; font-size: .9rem; padding: 7px 10px; border-radius: 10px; border: 1px solid var(--line); background: #fff; min-height: 38px; }
fieldset.fld { border: 0; padding: 0; } fieldset.fld legend { font-weight: 600; font-size: .88rem; margin-bottom: 6px; }
.radio { display: flex; gap: 8px; align-items: flex-start; margin: 0 0 6px; font-size: .92rem; }
.radio input { margin-top: 4px; accent-color: var(--raspberry); }
.crumb { margin: 0 0 8px; } .crumb a { display: inline-flex; gap: 6px; align-items: center; }
ul.plain { padding-left: 18px; }
.stats { display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); margin: 0 0 20px; }
.stat { background: #fffdf8; border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; text-decoration: none; color: var(--ink-c); }
.stat b { display: block; font: 600 1.6rem/1.1 var(--serif); }
.stat span { font-size: .85rem; color: var(--ink-3); }
a.stat:hover { border-color: var(--raspberry); }
.fld .radio input { width: auto; flex: none; padding: 0; }
table.t .badge { white-space: nowrap; }
@media (max-width: 959px) { .adm-shell { background: none; } }

/* v2.5 — the team space keeps its previous number style (only the visit app switched to the .mk style) */
.admin .lm { background: var(--gold-soft); color: var(--framboise-hover); box-shadow: inset 0 0 0 1px #d97b2f55; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .admin .lm { background: #6e4334; color: var(--gold-soft); } }

/* v2.5 — fiche list: multiple selection and status change */
th.tsel, td.tsel { width: 44px; padding: 0; text-align: center; vertical-align: middle; }
td.tsel input, th.tsel input { width: 20px; height: 20px; margin: 12px; accent-color: var(--framboise); cursor: pointer; }
table.t tr.is-sel td { background: var(--stone-100); }
.bulk-bar { position: sticky; top: 8px; z-index: 5; box-shadow: var(--shadow-1); display: flex; flex-wrap: wrap; gap: 8px 12px; align-items: center; margin: 0 0 12px; padding: 8px 12px; border: 1px solid var(--line); border-radius: 12px; background: #fffdf8; }
.bulk-count { font-weight: 600; font-size: .9rem; margin-right: auto; }
.bulk-st select { font: inherit; font-size: .9rem; padding: 7px 10px; border-radius: 10px; border: 1px solid var(--line); background: #fff; color: var(--ink); min-height: 38px; }
.js .bulk-bar.empty { visibility: hidden; }  /* space kept: the table does not move when the first fiche is ticked */
@media (max-width: 959px) { .bulk-bar { top: 74px; } }

/* v3.1 — support project: photos and work picker */
.sp-photos { margin: 0 0 16px; }
.ph-list { list-style: none; margin: 0 0 12px; padding: 0; display: grid; gap: 8px; }
.ph-list li { display: grid; grid-template-columns: 96px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 8px; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
.ph-list li:first-child { border-color: var(--framboise); }
.ph-list img { width: 96px; height: 72px; object-fit: cover; border-radius: 8px; background: var(--stone-100); }
.ph-meta { display: flex; flex-direction: column; min-width: 0; } .ph-meta .small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ph-act { display: flex; gap: 4px; flex-wrap: wrap; justify-content: flex-end; }
@media (max-width: 560px) { .ph-list li { grid-template-columns: 72px minmax(0, 1fr); } .ph-list img { width: 72px; height: 54px; } .ph-act { grid-column: 1 / -1; justify-content: flex-start; } }
.fp { position: relative; }
.fp-btn { display: flex; width: 100%; align-items: center; gap: 10px; min-height: 56px; padding: 6px 12px 6px 6px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); font: inherit; font-size: .95rem; text-align: left; cursor: pointer; }
.fp-btn .fp-caret { margin-left: auto; color: var(--ink-3); }
.fp img, .fp-ph { width: 44px; height: 44px; flex: none; border-radius: 8px; object-fit: cover; background: var(--stone-100); display: block; }
.fp-t { display: flex; flex-direction: column; min-width: 0; line-height: 1.25; } .fp-t small { color: var(--ink-3); font-family: ui-monospace, monospace; font-size: .74rem; }
.fp-t .lm { min-width: 24px; height: 24px; font-size: .72rem; display: inline-grid; margin-right: 4px; vertical-align: middle; }
.fp-pop { position: absolute; z-index: 30; left: 0; right: 0; top: calc(100% + 4px); background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow-2); padding: 8px; }
.fp-pop input { width: 100%; min-height: 42px; padding: 0 12px; border-radius: 8px; border: 1px solid var(--line); font: inherit; margin-bottom: 6px; }
.fp-pop ul { list-style: none; margin: 0; padding: 0; max-height: 320px; overflow: auto; }
.fp-pop li { display: flex; gap: 10px; align-items: center; padding: 6px; border-radius: 8px; cursor: pointer; min-height: 52px; }
.fp-pop li.act, .fp-pop li:hover { background: var(--stone-100); }
.fp-pop li[aria-selected="true"] { box-shadow: inset 0 0 0 1.5px var(--framboise); }
.fp-clear { margin-top: 6px; font-size: .88rem; }
