:root {
  --bg: #f3f6f4;
  --surface: #ffffff;
  --ink: #15231d;
  --muted: #5b6b63;
  --line: #dbe3de;
  --brand: #0b5d43;
  --brand-soft: #e1f0e9;
  --brand-ink: #ffffff; --cd: #f2b705;
  --sun: #f2b705;
  --sun-soft: #fff4cc;
  --wa: #1fa855;
  --danger: #b4231b;
  --danger-soft: #fde8e6;
  --info: #155e8a;
  --info-soft: #e2f0f8;
  --shadow: 0 1px 2px rgba(15, 35, 28, .06), 0 4px 16px rgba(15, 35, 28, .06);
  --display: "Bricolage Grotesque", "Avenir Next", "Segoe UI", system-ui, sans-serif;
  --body: "Atkinson Hyperlegible", "Segoe UI", Roboto, system-ui, sans-serif;
  --radius: 14px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0f1714; --surface: #17221d; --ink: #e6efe9; --muted: #9db0a6; --line: #2a3a33;
    --brand: #3fbf8a; --brand-soft: #173a2d; --brand-ink: #06150f; --cd: #06150f; --sun: #f5c533; --sun-soft: #3a3110;
    --wa: #33c46c; --danger: #ff7b70; --danger-soft: #3d1a17; --info: #7cc3ec; --info-soft: #14303f;
    --shadow: 0 1px 2px rgba(0,0,0,.4); color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0f1714; --surface: #17221d; --ink: #e6efe9; --muted: #9db0a6; --line: #2a3a33;
  --brand: #3fbf8a; --brand-soft: #173a2d; --brand-ink: #06150f; --cd: #06150f; --sun: #f5c533; --sun-soft: #3a3110;
  --wa: #33c46c; --danger: #ff7b70; --danger-soft: #3d1a17; --info: #7cc3ec; --info-soft: #14303f;
  --shadow: 0 1px 2px rgba(0,0,0,.4); color-scheme: dark;
}
* { box-sizing: border-box; }
body { background: var(--bg); color: var(--ink); font-family: var(--body); font-size: 15px; line-height: 1.5; margin: 0; }
h1, h2, h3 { font-family: var(--display); line-height: 1.15; text-wrap: balance; margin: 0; }
h1 { font-size: 1.7rem; font-weight: 800; }
h2 { font-size: 1.25rem; font-weight: 800; }
h3 { font-size: 1.05rem; font-weight: 600; }
p { margin: 0; }
button, input, select, textarea { font: inherit; color: inherit; }
a { color: var(--brand); }
:focus-visible { outline: 3px solid var(--sun); outline-offset: 2px; }

.topbar { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 20; background: var(--surface); border-bottom: 1px solid var(--line); }
.topbar-in { max-width: 1080px; margin: 0 auto; padding: 10px 16px; display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; }
.logo { font-family: var(--display); font-weight: 800; font-size: 1.35rem; color: var(--brand); letter-spacing: -.01em; }
.logo span { color: var(--sun); }
a.logo { text-decoration: none; }
.theme-btn { width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--line); background: var(--surface); color: var(--ink); font-size: 1.1rem; line-height: 1; cursor: pointer; }
.theme-btn:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }
.compte { margin-left: auto; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: .9rem; }
.compte .qui { color: var(--muted); max-width: 22ch; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tabs { max-width: 1080px; margin: 0 auto; padding: 0 16px; display: flex; gap: 4px; overflow-x: auto; }
.tab { text-decoration: none; display: inline-block; border: 0; background: none; padding: 10px 12px; border-bottom: 3px solid transparent; color: var(--muted); font-weight: 700; cursor: pointer; white-space: nowrap; }
.tab[aria-current="page"] { color: var(--ink); border-color: var(--brand); }
.tab .count { display: inline-block; min-width: 20px; padding: 0 6px; border-radius: 99px; background: var(--sun); color: #15231d; font-size: .75rem; margin-left: 4px; }

.launch-band { background: var(--brand); color: var(--brand-ink); font-size: .9rem; }
.launch-band div { max-width: 1080px; margin: 0 auto; padding: 8px 16px; display: flex; flex-wrap: wrap; gap: 2px 14px; align-items: baseline; justify-content: center; text-align: center; }
.launch-band .cd { font-variant-numeric: tabular-nums; white-space: nowrap; }
.launch-band .cd b { font-family: var(--display); font-size: 1.05rem; color: var(--cd); }
.linkbtn { background: none; border: 0; padding: 0; color: var(--brand); text-decoration: underline; cursor: pointer; font-weight: 700; }

main { max-width: 1080px; margin: 0 auto; padding-block: 20px 60px; padding-inline: 16px; }
.stack { display: flex; flex-direction: column; gap: 16px; }
.row { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.grid2 { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 20px; align-items: start; }
@media (max-width: 820px) { .grid2 { grid-template-columns: minmax(0, 1fr); } }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; box-shadow: var(--shadow); min-width: 0; }
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; min-width: 0; }
.muted { color: var(--muted); }
.small { font-size: .85rem; }
.lead { color: var(--muted); max-width: 62ch; }

/* Publication texte, sans image */
.post { display: flex; flex-direction: column; gap: 10px; }
.post-head { display: flex; justify-content: space-between; gap: 8px; align-items: flex-start; }
.who { display: flex; gap: 10px; align-items: center; min-width: 0; }
.avatar { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; font-weight: 700; font-family: var(--display); background: var(--brand-soft); color: var(--brand); flex: none; }
img.avatar { object-fit: cover; display: block; background: var(--line); }
.avatar.locked { background: var(--line); color: var(--muted); }
.quote { font-size: 1.05rem; line-height: 1.55; border-left: 4px solid var(--sun); padding: 4px 0 4px 12px; overflow-wrap: anywhere; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { display: inline-flex; align-items: center; gap: 4px; padding: 2px 9px; border-radius: 99px; font-size: .78rem; font-weight: 700; background: var(--bg); border: 1px solid var(--line); white-space: nowrap; }
.chip.ok { background: var(--info-soft); color: var(--info); border-color: transparent; }
.chip.cert { background: var(--sun-soft); color: var(--ink); border-color: var(--sun); }
.chip.warn { background: var(--sun-soft); color: var(--ink); border-color: transparent; }
.chip.bad { background: var(--danger-soft); color: var(--danger); border-color: transparent; }
.chip.green { background: var(--brand-soft); color: var(--brand); border-color: transparent; }
.price { font-family: var(--display); font-weight: 800; font-size: 1.15rem; color: var(--brand); font-variant-numeric: tabular-nums; }
.stars { color: var(--sun); letter-spacing: 1px; white-space: nowrap; }
.stars .off { color: var(--line); }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 9px 14px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface); font-weight: 700; cursor: pointer; text-decoration: none; color: var(--ink); }
.btn:hover { border-color: var(--brand); }
.btn.primary { background: var(--brand); color: var(--brand-ink); border-color: var(--brand); }
.btn.wa { background: var(--wa); color: #fff; border-color: var(--wa); }
.btn.sun { background: var(--sun); color: #15231d; border-color: var(--sun); }
.btn.danger { color: var(--danger); border-color: var(--danger); }
.btn.sm { padding: 6px 10px; font-size: .85rem; }
.btn[disabled] { opacity: .5; cursor: not-allowed; }

label.f { display: flex; flex-direction: column; gap: 4px; font-weight: 700; font-size: .9rem; min-width: 0; }
.f input, .f select, .f textarea { padding: 9px 10px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg); font-weight: 400; width: 100%; }
.form { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 12px; align-items: end; }
.form .full { grid-column: 1 / -1; }
.counter { font-weight: 400; font-size: .8rem; color: var(--muted); text-align: right; }

.notice { border-radius: 12px; padding: 12px 14px; background: var(--brand-soft); }
.notice.sun { background: var(--sun-soft); }
.notice.info { background: var(--info-soft); }
.notice.bad { background: var(--danger-soft); }

.lock { display: flex; gap: 10px; align-items: center; padding: 10px 12px; border-radius: 10px; background: var(--bg); border: 1px dashed var(--line); font-size: .9rem; }

.proposal { display: flex; flex-direction: column; gap: 8px; padding: 12px; border-radius: 12px; border: 1px solid var(--line); background: var(--bg); }
.zones { display: flex; flex-direction: column; gap: 6px; }
.zone { display: flex; justify-content: space-between; gap: 8px; font-size: .9rem; }
.dots { letter-spacing: 2px; color: var(--brand); white-space: nowrap; }
.dots .off { color: var(--line); }

.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 12px; }
.tile { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; }
.tile b { display: block; font-family: var(--display); font-size: 1.6rem; font-variant-numeric: tabular-nums; }
.scroll { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
table { border-collapse: collapse; width: 100%; font-size: .9rem; }
th, td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { color: var(--muted); font-size: .78rem; text-transform: uppercase; letter-spacing: .04em; white-space: nowrap; }
tr:last-child td { border-bottom: 0; }
.nowrap { white-space: nowrap; }

.steps { display: flex; gap: 6px; flex-wrap: wrap; }
.step { padding: 4px 10px; border-radius: 99px; font-size: .8rem; font-weight: 700; background: var(--bg); border: 1px solid var(--line); color: var(--muted); }
.step.on { background: var(--brand); color: var(--brand-ink); border-color: var(--brand); }
.step.done { background: var(--brand-soft); color: var(--brand); border-color: transparent; }
.plans { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 10px; }
.plan { border: 2px solid var(--line); border-radius: 12px; padding: 12px; cursor: pointer; display: flex; flex-direction: column; gap: 4px; }
.plan:has(input:checked) { border-color: var(--brand); background: var(--brand-soft); }
.plan input { accent-color: var(--brand); }
.slots { display: flex; flex-wrap: wrap; gap: 8px; }
.slot { border: 1px solid var(--line); border-radius: 10px; padding: 6px 10px; cursor: pointer; font-size: .9rem; }
.slot:has(input:checked) { border-color: var(--brand); background: var(--brand-soft); }
.code { font-family: ui-monospace, "SFMono-Regular", Menlo, monospace; font-weight: 700; letter-spacing: .06em; background: var(--bg); border: 1px dashed var(--brand); padding: 2px 8px; border-radius: 8px; }

.overlay { position: fixed; inset: 0; background: rgba(10, 20, 16, .55); display: grid; place-items: center; padding: 16px; z-index: 50; }
.modal { background: var(--surface); border-radius: 18px; padding: 20px; width: min(520px, 100%); max-height: 90vh; overflow: auto; display: flex; flex-direction: column; gap: 14px; }
.toast { position: fixed; left: 50%; bottom: calc(18px + env(safe-area-inset-bottom, 0px)); transform: translateX(-50%); background: var(--ink); color: var(--bg); padding: 10px 16px; border-radius: 12px; z-index: 60; max-width: calc(100% - 32px); font-weight: 700; }
.ratepick { display: flex; gap: 4px; }
.ratepick button { font-size: 1.8rem; background: none; border: 0; cursor: pointer; color: var(--line); padding: 0 2px; }
.ratepick button.on { color: var(--sun); }
.review { padding: 10px 0; border-bottom: 1px solid var(--line); }
.review:last-child { border-bottom: 0; }
@media (prefers-reduced-motion: no-preference) { .card, .modal { animation: rise .18s ease-out; } }
@keyframes rise { from { transform: translateY(4px); opacity: .6; } to { transform: none; opacity: 1; } }

.chargement { padding: 40px 0; text-align: center; color: var(--muted); }
.erreur { color: var(--danger); font-weight: 700; }
.cni-img { width: 100%; max-width: 100%; border-radius: 10px; border: 1px solid var(--line); background: var(--bg); }
.hint { font-weight: 400; font-size: .8rem; color: var(--muted); }
.f input[type=file] { padding: 7px; }
.pied { max-width: 1080px; margin: 0 auto; padding: 0 16px 40px; color: var(--muted); font-size: .85rem; }
.choix { display: grid; gap: 10px; }
.choix-item { display: grid; gap: 4px; text-align: left; width: 100%; padding: 14px; background: var(--surface); color: inherit; font: inherit; border: 1px solid var(--line); border-radius: var(--radius); cursor: pointer; }
.choix-item:hover, .choix-item:focus-visible { border-color: var(--brand); }
.install-bar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; display: flex; align-items: center; gap: 12px; padding: 12px 16px calc(12px + env(safe-area-inset-bottom, 0px)); background: var(--surface); border-top: 1px solid var(--line); box-shadow: 0 -4px 16px rgba(0,0,0,.12); }
.install-bar img { border-radius: 10px; flex: none; }
.install-txt { flex: 1; min-width: 0; display: grid; }
.install-x { background: none; border: 0; color: var(--muted); font-size: 1.5rem; line-height: 1; padding: 4px 6px; cursor: pointer; }
body:has(.install-bar:not([hidden])) { padding-bottom: 84px; }
.install-bar[hidden] { display: none; }
body:has(.install-bar:not([hidden])) .toast { bottom: calc(96px + env(safe-area-inset-bottom, 0px)); }
.bell { position: relative; display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--line); color: var(--ink); text-decoration: none; }
.bell[aria-current="page"] { border-color: var(--brand); color: var(--brand); }
.bell-n { position: absolute; top: -4px; right: -6px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 99px; background: var(--danger); color: #fff; font-size: .7rem; font-weight: 700; line-height: 18px; text-align: center; }
.notifs { display: grid; gap: 8px; }
.notif { display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); color: inherit; text-decoration: none; }
.notif.nouveau { border-color: var(--brand); background: var(--brand-soft); }
.notif-i { width: 32px; height: 32px; flex: none; display: grid; place-items: center; border-radius: 50%; background: var(--bg); font-size: 1rem; }
.notif-t { display: grid; gap: 2px; min-width: 0; }
