/* Scalor — une seule feuille pour le tableau de bord et les boutiques.
   --accent est la couleur de la boutique (choisie par le vendeur) ; le tableau de bord utilise celle de Scalor. */
:root {
  --bg: #f4f4f1;
  --surface: #ffffff;
  --ink: #0f1115;
  --muted: #6a6f78;
  --line: #e5e5df;
  --accent: #ff5a1f;
  --accent-ink: #ffffff;
  --accent-soft: color-mix(in srgb, var(--accent) 12%, white);
  --ok: #12804a;   --ok-soft: #e2f3ea;
  --warn: #8a5a00; --warn-soft: #fbefcf;
  --bad: #b3261e;  --bad-soft: #fbe4e1;
  --radius: 14px;
  --sans: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 15px/1.5 var(--sans); -webkit-font-smoothing: antialiased; }
h1, h2, h3 { margin: 0; font-weight: 700; letter-spacing: -0.02em; line-height: 1.15; }
h1 { font-size: clamp(1.6rem, 4vw, 2.1rem); }
h2 { font-size: 1.1rem; }
p { margin: 0; }
a { color: inherit; }
img { max-width: 100%; display: block; }
.muted { color: var(--muted); }
.small { font-size: 0.85rem; }
.num { font-variant-numeric: tabular-nums; }
[hidden] { display: none !important; }

.demo-banner { background: var(--warn-soft); color: var(--warn); text-align: center; padding: 7px 16px; font-size: 0.82rem; }

/* Éléments communs */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.stack > * + * { margin-top: 14px; }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.spread { justify-content: space-between; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 18px;
  border-radius: 10px; border: 1px solid transparent; background: var(--accent); color: var(--accent-ink);
  font: 600 0.95rem var(--sans); text-decoration: none; cursor: pointer; transition: filter .15s ease, transform .06s ease;
}
.btn:hover { filter: brightness(.95); }
.btn:active { transform: translateY(1px); }
.btn[disabled] { opacity: .45; cursor: not-allowed; }
.btn.dark { background: var(--ink); color: #fff; }
.btn.ghost { background: var(--surface); color: var(--ink); border-color: var(--line); }
.btn.danger { background: var(--surface); color: var(--bad); border-color: #efc9c5; }
.btn.block { width: 100%; }
.btn.sm { min-height: 34px; padding: 0 12px; font-size: 0.82rem; border-radius: 8px; }
:is(.btn, input, select, textarea, a, button):focus-visible { outline: 3px solid color-mix(in srgb, var(--accent) 45%, white); outline-offset: 2px; }

label { display: block; font-weight: 600; font-size: 0.85rem; margin-bottom: 6px; }
input, select, textarea {
  width: 100%; min-height: 44px; padding: 9px 12px; border-radius: 10px; border: 1px solid #d3d3cc;
  background: #fff; color: var(--ink); font: 0.95rem var(--sans);
}
input[type=color] { padding: 4px; width: 56px; cursor: pointer; }
textarea { min-height: 84px; resize: vertical; }
.grid2 { display: grid; gap: 14px; grid-template-columns: 1fr 1fr; }
.grid3 { display: grid; gap: 14px; grid-template-columns: 2fr 1fr 1fr; }
@media (max-width: 620px) { .grid2, .grid3 { grid-template-columns: 1fr; } }
.alert { border-radius: 10px; padding: 11px 14px; font-size: 0.9rem; }
.alert.bad { background: var(--bad-soft); color: var(--bad); }
.alert.ok { background: var(--ok-soft); color: var(--ok); }
.badge { display: inline-block; padding: 2px 9px; border-radius: 999px; font-size: 0.75rem; font-weight: 600; white-space: nowrap; }
.badge.completed, .badge.success { background: var(--ok-soft); color: var(--ok); }
.badge.pending { background: var(--warn-soft); color: var(--warn); }
.badge.failed, .badge.review { background: var(--bad-soft); color: var(--bad); }

.table-wrap { overflow-x: auto; margin: 0 -22px -6px; padding: 0 22px; }
table { width: 100%; border-collapse: collapse; font-size: 0.9rem; min-width: 540px; }
th { text-align: left; color: var(--muted); font-size: 0.74rem; text-transform: uppercase; letter-spacing: .05em; font-weight: 600; padding: 0 14px 10px 0; }
td { padding: 12px 14px 12px 0; border-top: 1px solid var(--line); vertical-align: middle; }
td.r, th.r { text-align: right; }
td:last-child, th:last-child { padding-right: 0; }
.empty { color: var(--muted); padding: 18px 0; }
.thumb { width: 44px; height: 44px; border-radius: 9px; object-fit: cover; background: var(--accent-soft); flex: none; display: grid; place-items: center; font-weight: 700; color: var(--accent); }
.linkbox { display: flex; gap: 8px; align-items: center; background: var(--bg); border-radius: 9px; padding: 6px 6px 6px 10px; font-size: 0.8rem; max-width: 340px; }
.linkbox code { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-family: var(--mono); }

/* ---------------------------------------------------------------- Tableau de bord */
.app { display: grid; grid-template-columns: 232px 1fr; min-height: 100vh; }
.side { background: var(--ink); color: #fff; padding: 20px 14px; display: flex; flex-direction: column; gap: 4px; position: sticky; top: 0; height: 100vh; }
.logo { font-weight: 800; font-size: 1.15rem; letter-spacing: -0.03em; padding: 4px 10px 18px; }
.logo i { font-style: normal; color: var(--accent); }
.nav a {
  display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 9px; text-decoration: none;
  color: #b9bcc4; font-weight: 500; font-size: 0.92rem;
}
.nav a:hover { color: #fff; background: #1c1f26; }
.nav a[aria-current=page] { color: #fff; background: #23262e; }
.nav svg { width: 18px; height: 18px; flex: none; }
.side .foot { margin-top: auto; padding: 10px; font-size: 0.8rem; color: #8d919a; }
.side .foot button { background: none; border: 0; color: #b9bcc4; font: inherit; cursor: pointer; padding: 0; text-decoration: underline; }
.main { padding: 28px 32px 64px; min-width: 0; }
.main > header { display: flex; justify-content: space-between; align-items: flex-end; gap: 12px; flex-wrap: wrap; margin-bottom: 22px; }
.view > * + * { margin-top: 18px; }
.tiles { display: grid; gap: 14px; grid-template-columns: repeat(4, 1fr); }
.tile .label { color: var(--muted); font-size: 0.78rem; font-weight: 600; }
.tile .value { font-size: 1.55rem; font-weight: 700; letter-spacing: -0.02em; margin-top: 6px; }
.tile.hl { background: var(--ink); color: #fff; border-color: var(--ink); }
.tile.hl .label { color: #a9adb6; }
.chart { display: grid; grid-template-columns: repeat(14, 1fr); gap: 6px; align-items: end; height: 150px; margin-top: 18px; }
.chart div { background: var(--accent); border-radius: 5px 5px 2px 2px; min-height: 3px; opacity: .9; }
.chart div.zero { background: var(--line); }
.chart-x { display: flex; justify-content: space-between; color: var(--muted); font-size: 0.75rem; margin-top: 8px; }
.preview { border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.preview .band { padding: 22px; background: var(--accent-soft); }
.preview .band b { font-size: 1.15rem; display: block; }
.preview .foot { padding: 14px 22px; }
.login { max-width: 420px; margin: 9vh auto 0; padding: 0 16px; }
@media (max-width: 1020px) { .tiles { grid-template-columns: 1fr 1fr; } }
@media (max-width: 800px) {
  .app { grid-template-columns: 1fr; }
  .side { position: static; height: auto; flex-direction: row; align-items: center; overflow-x: auto; padding: 10px 12px; gap: 2px; }
  .logo { padding: 0 10px 0 4px; }
  .nav { display: flex; gap: 2px; }
  .nav a { white-space: nowrap; }
  .side .foot { margin: 0 0 0 auto; white-space: nowrap; }
  .main { padding: 20px 16px 56px; }
}
@media (max-width: 460px) { .tiles { grid-template-columns: 1fr; } }

/* ---------------------------------------------------------------- Boutique publique */
.shop-head { background: var(--surface); border-bottom: 1px solid var(--line); }
.shop-head .in, .wrap { max-width: 1080px; margin: 0 auto; padding: 0 20px; }
.shop-head .in { display: flex; align-items: center; justify-content: space-between; min-height: 64px; gap: 12px; }
.shop-id { display: flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 700; letter-spacing: -0.01em; }
.avatar { width: 36px; height: 36px; border-radius: 10px; background: var(--accent); color: var(--accent-ink); display: grid; place-items: center; font-weight: 800; object-fit: cover; }
.hero { background: var(--accent-soft); padding: 46px 0 50px; }
.hero h1 { font-size: clamp(2rem, 6vw, 3rem); }
.hero p { margin-top: 12px; max-width: 52ch; font-size: 1.05rem; color: #3b3f47; }
.section { padding: 34px 0 72px; }
.products { display: grid; gap: 18px; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); margin-top: 18px; }
.product { display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; text-decoration: none; transition: transform .15s ease, box-shadow .15s ease; }
.product:hover { transform: translateY(-3px); box-shadow: 0 10px 26px rgba(15,17,21,.08); }
.cover { aspect-ratio: 4 / 3; width: 100%; object-fit: cover; background: linear-gradient(135deg, var(--accent-soft), color-mix(in srgb, var(--accent) 34%, white)); display: grid; place-items: center; font-size: 3rem; font-weight: 800; color: var(--accent); }
.product .body { padding: 16px 18px 18px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.product h2 { font-size: 1.02rem; }
.product .desc { color: var(--muted); font-size: 0.88rem; flex: 1; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.price { font-weight: 800; font-size: 1.2rem; letter-spacing: -0.02em; }
.shop-foot { text-align: center; color: var(--muted); font-size: 0.8rem; padding: 0 0 36px; }

.buy { display: grid; gap: 34px; grid-template-columns: 1.15fr 1fr; align-items: start; padding: 34px 0 72px; }
.buy .cover { border-radius: var(--radius); border: 1px solid var(--line); }
.buy h1 { margin-top: 22px; }
.buy .price { font-size: 1.9rem; margin-top: 14px; }
.buy .pay { position: sticky; top: 18px; }
.trust { list-style: none; padding: 0; margin: 20px 0 0; color: var(--muted); font-size: 0.9rem; }
.trust li { padding: 5px 0 5px 24px; position: relative; }
.trust li::before { content: "✓"; position: absolute; left: 0; color: var(--ok); font-weight: 700; }
@media (max-width: 820px) { .buy { grid-template-columns: 1fr; gap: 22px; padding-top: 20px; } .buy .pay { position: static; } }

.narrow { max-width: 520px; margin: 0 auto; padding: 34px 20px 72px; }
.state { text-align: center; padding: 38px 24px; }
.state .icon { width: 68px; height: 68px; border-radius: 50%; display: grid; place-items: center; margin: 0 auto 18px; font-size: 1.9rem; font-weight: 700; }
.state .icon.ok { background: var(--ok-soft); color: var(--ok); }
.state .icon.bad { background: var(--bad-soft); color: var(--bad); }
.state .icon.wait { background: var(--warn-soft); color: var(--warn); }
.spinner { width: 28px; height: 28px; border-radius: 50%; border: 3px solid #ead9a8; border-top-color: var(--warn); animation: spin .9s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .spinner { animation-duration: 3s; } .product, .btn { transition: none; } }
.stack > .table-wrap { margin-top: 18px; }

/* ---------------------------------------------------------------- Création et fiche produit */
.page { max-width: 1060px; margin: 0 auto; padding: 28px 20px 72px; }
.page.slim { max-width: 660px; }
.back { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); text-decoration: none; font-size: 0.88rem; margin-bottom: 18px; }
.back:hover { color: var(--ink); }
.steps { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 8px; margin: 18px 0 26px; }
.steps i { height: 6px; border-radius: 99px; background: var(--line); }
.steps i.on { background: var(--ink); }
.wiz-head { display: flex; gap: 12px; align-items: center; }
.wiz-head .ico { width: 42px; height: 42px; border-radius: 11px; background: var(--accent); color: #fff; display: grid; place-items: center; flex: none; }
.wiz-head .ico svg, .type .ico svg { width: 22px; height: 22px; }
.actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 26px; flex-wrap: wrap; }
.req::after { content: " *"; color: var(--bad); }

.types { display: grid; gap: 12px; grid-template-columns: repeat(3, 1fr); margin-top: 22px; }
@media (max-width: 620px) { .types { grid-template-columns: 1fr 1fr; } }
.type { position: relative; text-align: left; background: var(--surface); border: 1.5px solid var(--line); border-radius: 14px; padding: 16px; cursor: pointer; font: inherit; color: inherit; display: flex; flex-direction: column; gap: 22px; }
.type .ico { width: 38px; height: 38px; border-radius: 10px; display: grid; place-items: center; color: #fff; background: var(--c, var(--ink)); }
.type b { font-weight: 600; }
.type .dot { position: absolute; top: 16px; right: 16px; width: 22px; height: 22px; border-radius: 50%; border: 1.5px solid #b9bcc4; display: grid; place-items: center; font-size: 13px; color: transparent; }
.type[aria-pressed=true] { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.type[aria-pressed=true] .dot { background: var(--accent); border-color: var(--accent); color: #fff; }
.type[disabled] { cursor: not-allowed; opacity: .55; }
.type .soon { position: absolute; top: -9px; right: 10px; background: var(--ink); color: #fff; font-size: 0.68rem; font-weight: 700; padding: 2px 8px; border-radius: 99px; }
.panel { background: #ecece7; border-radius: 14px; padding: 20px; margin-top: 22px; }
.panel ul { list-style: none; margin: 14px 0 0; padding: 0; display: grid; gap: 10px; }
.panel li { display: flex; gap: 10px; align-items: center; }
.panel li::before { content: "✓"; width: 30px; height: 30px; border-radius: 8px; background: #dcdcd5; display: grid; place-items: center; font-weight: 700; flex: none; }

.money-input { display: flex; align-items: center; border: 1px solid #d3d3cc; border-radius: 10px; background: #fff; padding-left: 10px; }
.money-input span { font-size: 0.75rem; font-weight: 600; color: var(--muted); border: 1px solid var(--line); border-radius: 6px; padding: 3px 6px; }
.money-input input { border: 0; min-height: 42px; background: transparent; }
.money-input:focus-within { outline: 3px solid color-mix(in srgb, var(--accent) 45%, white); outline-offset: 2px; }
.money-input input:focus-visible { outline: none; }

.drop { border: 1.5px dashed #c9c9c1; border-radius: 14px; background: #f1f1ec; padding: 26px 18px; text-align: center; color: var(--muted); font-size: 0.88rem; }
.drop.over { border-color: var(--accent); background: var(--accent-soft); }
.drop .btn { margin-bottom: 10px; }
.pick { position: relative; display: grid; place-items: center; border-radius: 14px; background: #e4e4de; color: var(--muted); cursor: pointer; overflow: hidden; border: 1.5px dashed transparent; font-size: 0.85rem; }
.pick:hover { border-color: #b9bcc4; }
.pick.square { width: 170px; aspect-ratio: 1; }
.pick.wide { width: 100%; aspect-ratio: 702 / 260; border-color: #c9c9c1; background: #f1f1ec; }
.pick img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
/* Bannière : elle garde la forme de l'image envoyée (large, carrée ou verticale), comme sur la page produit. */
.pick.wide.has-img { aspect-ratio: auto; max-width: 460px; place-items: end center; }
.pick.wide.has-img img { position: static; height: auto; grid-area: 1 / 1; }
.pick.wide.has-img > span { grid-area: 1 / 1; margin: 10px; padding: 6px 12px; border-radius: 99px; background: rgba(15,17,21,.72); color: #fff; font-weight: 600; z-index: 1; }
.pick input { position: absolute; inset: 0; opacity: 0; cursor: pointer; min-height: 0; }
.filelist { list-style: none; margin: 14px 0 0; padding: 0; display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; }
.filelist li { display: flex; align-items: center; justify-content: space-between; gap: 12px; background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; }
.filelist .name { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.filelist li > div { flex: 1 1 auto; min-width: 0; }
.filelist li > span { flex: none; white-space: nowrap; }

.summary { background: #ecece7; border-radius: 14px; padding: 16px; display: grid; gap: 10px; }
.summary div { background: var(--surface); border-radius: 10px; padding: 12px 14px; }
.summary span { display: block; font-size: 0.78rem; color: var(--muted); font-weight: 600; margin-bottom: 4px; }
.ready { display: flex; gap: 12px; align-items: center; border: 1px solid #a9dfc0; background: var(--ok-soft); color: var(--ok); border-radius: 12px; padding: 14px 16px; margin-top: 18px; }

.editor { display: grid; grid-template-columns: 240px 1fr; gap: 28px; align-items: start; margin-top: 22px; }
.tabs { background: #ecece7; border-radius: 14px; padding: 10px; display: grid; gap: 2px; position: sticky; top: 18px; }
.tabs button { display: flex; align-items: center; gap: 10px; text-align: left; border: 0; background: none; font: 500 0.92rem var(--sans); color: var(--ink); padding: 10px 12px; border-radius: 9px; cursor: pointer; }
.tabs button:hover { background: #e0e0d9; }
.tabs button[aria-selected=true] { background: var(--ink); color: #fff; }
.tabpanel > * + * { margin-top: 16px; }
.tabpanel .lead { color: var(--muted); margin-top: 6px; }
.faq-item { border: 1px solid var(--line); border-radius: 12px; padding: 14px; background: var(--surface); display: grid; gap: 10px; }
@media (max-width: 800px) {
  .editor { grid-template-columns: 1fr; gap: 16px; }
  .tabs { position: static; display: flex; overflow-x: auto; }
  .tabs button { white-space: nowrap; }
}

/* Page produit publique : bannière, prix barré, FAQ */
.banner { width: 100%; aspect-ratio: 702 / 260; object-fit: cover; border-radius: var(--radius); border: 1px solid var(--line); margin-top: 24px; }
.was { color: var(--muted); text-decoration: line-through; font-weight: 500; font-size: 0.6em; margin-left: 8px; }
.faq { margin-top: 28px; display: grid; gap: 8px; }
.faq details { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; }
.faq summary { font-weight: 600; cursor: pointer; }
.faq p { margin-top: 8px; color: var(--muted); white-space: pre-line; }
.buy .cover.small { aspect-ratio: 1; width: 96px; font-size: 2rem; border-radius: 14px; }

/* Automatisations */
.subtabs { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 2px; }
.subtabs button { border: 1px solid var(--line); background: var(--surface); font: 600 0.88rem var(--sans); color: var(--ink); padding: 8px 14px; border-radius: 99px; cursor: pointer; white-space: nowrap; }
.subtabs button[aria-selected=true] { background: var(--ink); color: #fff; border-color: var(--ink); }
ul.plain { margin: 0; padding-left: 18px; display: grid; gap: 8px; font-size: 0.92rem; }
code { font-family: var(--mono); font-size: 0.86em; }
td code { background: var(--bg); padding: 2px 6px; border-radius: 6px; }

/* ---------------------------------------------------------------- Pages de vente (page builder) */
.lp { background: var(--surface); }
.lp-in { max-width: 1040px; margin: 0 auto; padding: 0 22px; }
.lp-in.narrow-text { max-width: 720px; }
.lp h1 { font-size: clamp(2rem, 5.5vw, 3.2rem); }
.lp h2 { font-size: clamp(1.4rem, 3.4vw, 1.9rem); }
.lp h3 { font-size: 1.02rem; }
.lp-hero { background: var(--accent-soft); padding: 56px 0; }
.lp-hero .lp-in { display: grid; gap: 34px; align-items: center; }
.lp-hero.with-image .lp-in { grid-template-columns: 1.1fr 1fr; }
.lp-hero img { width: 100%; border-radius: 16px; aspect-ratio: 4 / 3; object-fit: cover; box-shadow: 0 18px 40px rgba(15,17,21,.14); }
.lp-lead { margin-top: 14px; font-size: 1.12rem; color: #3b3f47; max-width: 52ch; white-space: pre-line; }
.lp-buy { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; margin-top: 24px; }
.lp-btn { min-height: 52px; padding: 0 26px; font-size: 1.02rem; border-radius: 12px; }
.lp-btn.off { opacity: .5; cursor: not-allowed; margin-top: 24px; }
.lp-price { font-weight: 800; font-size: 1.15rem; }
.lp-price s { margin-left: 8px; color: var(--muted); font-weight: 500; font-size: .85em; }
.lp-section { padding: 52px 0; }
.lp-section.tinted { background: var(--bg); }
.lp-body { margin-top: 14px; white-space: pre-line; font-size: 1.04rem; color: #2b2f36; }
.lp-grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); margin-top: 22px; }
.lp-card { margin: 0; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 20px; }
.lp-card p { margin-top: 8px; color: var(--muted); }
.lp-card footer { margin-top: 12px; font-weight: 600; font-size: 0.9rem; }
blockquote.lp-card p { color: var(--ink); margin-top: 0; }
.lp-quote::before { content: "« "; }
.lp-quote::after { content: " »"; }
.lp-tick { width: 30px; height: 30px; border-radius: 9px; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; font-weight: 800; margin-bottom: 12px; }
.lp-figure { margin: 0 auto; }
.lp-figure img { width: 100%; border-radius: 16px; }
.lp-figure figcaption { text-align: center; color: var(--muted); font-size: 0.88rem; margin-top: 10px; }
.lp-video { position: relative; aspect-ratio: 16 / 9; border-radius: 16px; overflow: hidden; background: #000; }
.lp-video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.lp-cta { background: var(--ink); color: #fff; padding: 56px 0; text-align: center; }
.lp-cta p { margin-top: 10px; color: #b9bcc4; }
.lp-cta .lp-buy { justify-content: center; }
.lp-cta .lp-price s { color: #8d919a; }
@media (max-width: 760px) { .lp-hero.with-image .lp-in { grid-template-columns: 1fr; } .lp-hero, .lp-section, .lp-cta { padding: 38px 0; } }

/* Éditeur */
.builder-body { background: #e9e9e4; }
.builder { min-height: 100vh; display: flex; flex-direction: column; }
.b-top { display: flex; align-items: center; gap: 12px; padding: 10px 18px; background: var(--surface); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 5; flex-wrap: wrap; }
.b-title { border: 1px solid transparent; background: transparent; font-weight: 700; font-size: 1.05rem; max-width: 320px; min-height: 38px; padding: 4px 8px; }
.b-title:hover { border-color: var(--line); }
.b-notice { margin: 10px 18px 0; }
.b-cols { display: grid; grid-template-columns: 360px minmax(0, 1fr); gap: 18px; padding: 18px; align-items: start; flex: 1; }
.ai-open .b-cols { grid-template-columns: 360px minmax(0, 1fr) 320px; }
.b-ai { display: none; position: sticky; top: 76px; height: calc(100vh - 96px); background: var(--surface); border: 1px solid var(--line); border-radius: 16px; flex-direction: column; overflow: hidden; }
.ai-open .b-ai { display: flex; }
.b-ai-head { padding: 14px 16px; border-bottom: 1px solid var(--line); display: grid; gap: 2px; }
.b-ai-log { flex: 1; overflow: auto; padding: 14px; display: flex; flex-direction: column; gap: 10px; }
.ai-msg { padding: 10px 12px; border-radius: 12px; font-size: .9rem; max-width: 92%; white-space: pre-wrap; overflow-wrap: anywhere; }
.ai-msg.me { align-self: flex-end; background: var(--ink); color: #fff; }
.ai-msg.ai { align-self: flex-start; background: var(--bg); }
.ai-msg.ai small { display: block; margin-top: 6px; color: var(--muted); }
.ai-msg.wait { color: var(--muted); font-style: italic; }
.ai-msg.err { align-self: flex-start; background: #fdecec; color: var(--bad); }
.b-ai-ideas { display: grid; gap: 6px; padding: 0 14px 10px; }
.b-ai-ideas button { text-align: left; border: 1px solid var(--line); background: var(--surface); border-radius: 10px; padding: 8px 10px; font: 500 .82rem var(--sans); color: var(--ink); cursor: pointer; }
.b-ai-ideas button:hover { border-color: var(--ink); }
.b-ai-form { border-top: 1px solid var(--line); padding: 12px; display: grid; gap: 8px; }
.b-ai-form textarea { min-height: 0; resize: none; }
#aiToggle[aria-pressed="true"] { border-color: var(--ink); }
.b-code { font: 0.82rem/1.5 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; min-height: 220px; white-space: pre; tab-size: 2; }
.b-grip { color: var(--muted); cursor: grab; padding: 0 2px 0 6px; user-select: none; }
.b-head[draggable] { cursor: grab; }
.b-add button[draggable] { cursor: grab; }
.b-block.drop-before { box-shadow: 0 -4px 0 -1px var(--accent); }
.b-block.drop-after { box-shadow: 0 4px 0 -1px var(--accent); }
.b-blocks.drop-into { outline: 2px dashed var(--accent); min-height: 60px; border-radius: 12px; }
.is-preview > section.drop-before { box-shadow: inset 0 5px 0 var(--accent); }
.is-preview > section.drop-after { box-shadow: inset 0 -5px 0 var(--accent); }
.is-preview.drop-into { outline: 3px dashed var(--accent); outline-offset: -6px; }
.pv-grip { color: #fff; cursor: grab; padding: 0 6px; align-self: center; user-select: none; }
.lp-custom { padding: 0; }
.lp-html { display: block; width: 100%; height: 120px; border: 0; }
.is-preview .lp-html { pointer-events: none; }
.b-side { min-width: 0; }
.b-preview { position: sticky; top: 76px; }
.b-device { background: var(--surface); border-radius: 16px; overflow: hidden; height: calc(100vh - 150px); min-height: 420px; border: 1px solid var(--line); box-shadow: 0 10px 30px rgba(15,17,21,.08); margin: 0 auto; transition: width .2s ease; width: 100%; }
.b-device.mobile { width: 390px; max-width: 100%; border: 8px solid #15171c; border-radius: 30px; }
.b-device iframe { width: 100%; height: 100%; border: 0; display: block; background: var(--surface); transform-origin: 0 0; }
.b-bar { display: flex; align-items: center; gap: 14px; margin-bottom: 10px; flex-wrap: wrap; }
.b-seg { display: inline-flex; background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 3px; }
.b-seg button { border: 0; background: none; font: 600 0.85rem var(--sans); color: var(--muted); padding: 7px 14px; border-radius: 7px; cursor: pointer; }
.b-seg button[aria-pressed="true"] { background: var(--ink); color: #fff; }
/* Intérieur de l'aperçu (chargé dans le cadre) : sélection d'un bloc et texte modifiable au clic. */
.pv-body { background: var(--surface); }
.is-preview > section { position: relative; cursor: pointer; }
.is-preview > section:hover { outline: 2px dashed color-mix(in srgb, var(--accent) 55%, transparent); outline-offset: -2px; }
.is-preview > section.sel { outline: 2px solid var(--accent); outline-offset: -2px; }
.is-preview [data-f] { cursor: text; border-radius: 6px; outline-offset: 3px; }
.is-preview [data-f]:hover { box-shadow: 0 0 0 2px color-mix(in srgb, var(--accent) 35%, transparent); }
.is-preview [data-f]:focus { outline: 2px solid var(--accent); box-shadow: none; }
.is-preview .lp-video iframe { pointer-events: none; }
.pv-tools { transform: scale(var(--pv-zoom, 1)); transform-origin: top right; position: absolute; top: 0; right: 0; z-index: 3; display: flex; gap: 2px; background: var(--ink); border-radius: 0 0 0 10px; padding: 3px; box-shadow: 0 6px 18px rgba(15,17,21,.25); cursor: default; }
.pv-tools button { width: 28px; height: 28px; border: 0; border-radius: 7px; background: none; color: #fff; cursor: pointer; font-size: .95rem; }
.pv-tools button:hover:not([disabled]) { background: rgba(255,255,255,.16); }
.pv-tools button[disabled] { opacity: .35; cursor: default; }
.pv-tools .pv-name { color: #fff; font: 600 .78rem var(--sans); padding: 0 8px; align-self: center; }
.lp-ph { border: 2px dashed #c9c9c1; border-radius: 16px; padding: 48px 20px; text-align: center; color: var(--muted); }
.b-blocks { display: grid; gap: 8px; }
.b-block { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.b-block.open { border-color: var(--ink); }
.b-head { display: flex; align-items: center; gap: 6px; padding: 6px 8px 6px 4px; }
.b-head .name { flex: 1; text-align: left; border: 0; background: none; font: 600 0.92rem var(--sans); padding: 8px 8px; cursor: pointer; color: var(--ink); min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.b-head .name small { color: var(--muted); font-weight: 400; margin-left: 6px; }
.b-icon { width: 30px; height: 30px; border-radius: 8px; border: 1px solid var(--line); background: var(--surface); cursor: pointer; font-size: 0.9rem; color: var(--ink); flex: none; }
.b-icon:hover { background: var(--bg); }
.b-icon[disabled] { opacity: .35; cursor: default; }
.b-icon.del { color: var(--bad); }
.b-body { padding: 4px 14px 16px; display: grid; gap: 12px; border-top: 1px solid var(--line); }
.b-item { border: 1px dashed #c9c9c1; border-radius: 10px; padding: 10px; display: grid; gap: 8px; }
.b-add { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.b-add button { text-align: left; border: 1px solid var(--line); background: var(--surface); border-radius: 10px; padding: 10px 12px; cursor: pointer; font: 600 0.88rem var(--sans); color: var(--ink); }
.b-add button:hover { border-color: var(--ink); }
.b-add small { display: block; font-weight: 400; color: var(--muted); margin-top: 2px; }
.b-empty { text-align: center; color: var(--muted); padding: 60px 20px; }
@media (max-width: 980px) { .b-cols, .ai-open .b-cols { grid-template-columns: 1fr; } .b-ai { position: static; height: 420px; } .b-preview { position: static; } .b-device { height: 75vh; } }

/* ---------------------------------------------------------------- Description mise en forme (produit) */
.rich { line-height: 1.65; color: #2b2f36; overflow-wrap: anywhere; }
.rich > :first-child { margin-top: 0; }
.rich p, .rich div { margin: 0 0 12px; }
.rich h2 { font-size: 1.35rem; margin: 22px 0 10px; color: var(--ink); }
.rich h3 { font-size: 1.1rem; margin: 18px 0 8px; color: var(--ink); }
.rich ul, .rich ol { margin: 0 0 12px; padding-left: 22px; }
.rich li { margin: 4px 0; }
.rich blockquote { margin: 14px 0; padding: 10px 16px; border-left: 4px solid var(--accent); background: var(--accent-soft); border-radius: 0 10px 10px 0; }
.rich a { color: var(--accent); text-decoration: underline; }
.rich img { max-width: 100%; height: auto; border-radius: 12px; display: block; margin: 14px 0; }
.rich iframe { width: 100%; aspect-ratio: 16 / 9; border: 0; border-radius: 12px; display: block; margin: 14px 0; background: #000; }
/* Un titre qui englobe des paragraphes ou des images (erreur fréquente de l'éditeur) s'affiche comme du texte normal. */
.rich :is(h2, h3):has(p, div, img, ul, ol, blockquote, iframe) { font-size: inherit; font-weight: inherit; line-height: inherit; margin: 0; color: inherit; }
.rich { font-size: 1rem; }
.pp > *, .pp-main > * { min-width: 0; }
.rich hr { border: 0; border-top: 1px solid var(--line); margin: 18px 0; }
.rt { border: 1px solid var(--line); border-radius: 12px; background: var(--surface); overflow: hidden; }
.rt:focus-within { border-color: var(--ink); }
.rt-bar { display: flex; flex-wrap: wrap; gap: 4px; align-items: center; padding: 8px; border-bottom: 1px solid var(--line); background: var(--bg); position: sticky; top: 0; z-index: 2; }
.rt-btn { border: 1px solid transparent; background: none; border-radius: 8px; min-width: 32px; height: 32px; padding: 0 8px; font: 600 0.84rem var(--sans); color: var(--ink); cursor: pointer; display: inline-flex; align-items: center; justify-content: center; gap: 4px; }
.rt-btn:hover { background: var(--surface); border-color: var(--line); }
.rt-btn.b { font-weight: 800; } .rt-btn.i { font-style: italic; } .rt-btn.u { text-decoration: underline; } .rt-btn.s { text-decoration: line-through; font-weight: 500; }
.rt-select { height: 32px; min-height: 0; width: auto; padding: 0 8px; font-size: 0.84rem; border-radius: 8px; }
.rt-sep { width: 1px; height: 20px; background: var(--line); margin: 0 4px; }
.rt-colorbtn { position: relative; }
.rt-color { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; padding: 0; min-height: 0; border: 0; }
.rt-prompt { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; padding: 8px; border-bottom: 1px solid var(--line); }
.rt-prompt input { flex: 1; min-width: 200px; min-height: 36px; }
.rt-area { min-height: 320px; max-height: 70vh; overflow: auto; padding: 16px 18px; outline: none; }
.rt-area:empty::before { content: "Décris ton produit : ce qu'il contient, pour qui, ce que le client obtient…"; color: var(--muted); }
.rt .alert { margin: 8px; }

.buy-cta { min-height: 52px; padding: 0 28px; font-size: 1.04rem; border-radius: 12px; }

/* ---------------------------------------------------------------- Page produit (deux colonnes, carte d'achat fixe) */
.pp { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 36px; align-items: start; padding: 30px 0 72px; }
.pp-title { font-size: clamp(1.4rem, 3vw, 1.9rem); line-height: 1.25; }
.pp-meta { display: flex; flex-wrap: wrap; gap: 6px 0; margin: 10px 0 18px; color: var(--muted); font-size: 0.9rem; }
.pp-meta > * + * { border-left: 1px solid var(--line); margin-left: 12px; padding-left: 12px; }
.pp-cover img, .pp-cover .cover { width: 100%; border-radius: var(--radius); border: 1px solid var(--line); display: block; }
.pp-cover img { height: auto; max-height: 85vh; object-fit: contain; background: var(--surface); }
.pp-desc { margin-top: 26px; }
.pp-h2 { font-size: 1.25rem; margin: 30px 0 12px; }
.pp-side { position: sticky; top: 18px; }
.pp-card { padding: 22px; box-shadow: 0 14px 38px rgba(15,17,21,.08); display: grid; gap: 16px; }
.pp-stocktxt { font-weight: 600; font-size: .9rem; margin-bottom: 8px; }
.pp-bar { height: 10px; border-radius: 99px; background: var(--bg); overflow: hidden; }
.pp-bar span { display: block; height: 100%; border-radius: 99px; background: linear-gradient(90deg, var(--accent), color-mix(in srgb, var(--accent) 55%, #ffd166)); }
.pp-timer { color: var(--bad); font-weight: 600; font-size: .9rem; font-variant-numeric: tabular-nums; }
.pp-price { display: flex; align-items: baseline; justify-content: center; gap: 12px; flex-wrap: wrap; padding: 4px 0; }
.pp-price s { color: var(--muted); font-size: 1.05rem; }
.pp-price strong { font-size: 2rem; }
.pp-price strong.promo { color: var(--bad); }
.pp-cta { min-height: 54px; font-size: 1.05rem; border-radius: 12px; }
.pp-form { border-top: 1px solid var(--line); padding-top: 16px; }
.pp-methods { text-align: center; display: grid; gap: 8px; }
.pp-methods > div { display: flex; flex-wrap: nowrap; gap: 5px; justify-content: center; }
.pp-chip { border: 1px solid var(--line); border-radius: 8px; padding: 5px 10px; font-size: .82rem; font-weight: 600; background: var(--bg); }
.pp-actions { display: flex; justify-content: center; border-top: 1px solid var(--line); padding-top: 12px; }
.pp-actions button { border: 0; background: none; font: 500 .9rem var(--sans); color: var(--ink); cursor: pointer; padding: 4px 14px; }
.pp-actions button + button { border-left: 1px solid var(--line); }
.pp-howto { text-align: center; margin: 0; font-size: .9rem; }
.pp-howto a { color: var(--ink); }
.pp-dialog { border: 0; border-radius: 16px; padding: 24px; max-width: 460px; width: calc(100% - 32px); box-shadow: 0 30px 80px rgba(15,17,21,.3); }
.pp-dialog::backdrop { background: rgba(15,17,21,.45); }
.pp-dialog ol { padding-left: 20px; display: grid; gap: 10px; margin: 16px 0 20px; }
@media (max-width: 880px) {
  .pp { grid-template-columns: minmax(0, 1fr); gap: 20px; padding-top: 18px; }
  .pp-price strong { font-size: 1.75rem; }
  .pp-card { padding: 18px; }
  .pp-side { position: static; order: 2; }
  .pp-main { display: contents; }
  .pp-title { order: 0; } .pp-meta { order: 0; margin-bottom: 0; } .pp-cover { order: 1; }
  .pp-desc, #files, .faq, .pp-reviews, .pp-preview { order: 3; }
}
.review-box { margin-top: 26px; padding-top: 20px; border-top: 1px solid var(--line); display: grid; gap: 10px; text-align: center; }
.review-box [aria-pressed="true"] { border-color: var(--ink); background: var(--ink); color: #fff; }
.pp-logo { box-sizing: border-box; flex: 1 1 0; min-width: 0; max-width: 76px; height: 34px; padding: 5px 6px; border: 1px solid var(--line); border-radius: 8px; background: #fff; display: inline-flex; align-items: center; justify-content: center; }
.pp-logo img { max-height: 22px; max-width: 100%; width: auto; height: auto; object-fit: contain; display: block; }

/* ---------------------------------------------------------------- Fenêtre « Finaliser votre achat » */
.co { border: 0; padding: 0; border-radius: 18px; width: min(920px, calc(100% - 24px)); max-height: calc(100vh - 24px); box-shadow: 0 30px 80px rgba(15,17,21,.3); }
.co::backdrop { background: rgba(15,17,21,.5); }
.co-in { display: flex; flex-direction: column; max-height: calc(100vh - 24px); }
.co-head { display: flex; align-items: center; gap: 14px; padding: 16px 22px; border-bottom: 1px solid var(--line); }
.co-head h2 { font-size: 1.2rem; flex: 1; }
.co-help { color: var(--ink); font-size: .9rem; }
.co-close { border: 0; background: var(--bg); width: 34px; height: 34px; border-radius: 50%; cursor: pointer; font-size: .95rem; }
.co-body { display: grid; grid-template-columns: minmax(0, 1fr) 320px; overflow: auto; }
.co-main { padding: 22px; }
.co-main h3, .co-sum h3 { font-size: 1rem; }
.co-switch { display: flex; align-items: center; gap: 10px; font-weight: 600; cursor: pointer; padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; }
.co-switch input { width: 18px; height: 18px; min-height: 0; accent-color: var(--accent); margin: 0; }
.co-sub { margin-top: -6px; padding: 14px; background: var(--bg); border-radius: 12px; }
.co-sum { padding: 22px; background: var(--bg); border-left: 1px solid var(--line); display: grid; gap: 14px; align-content: start; }
.co-item { display: flex; gap: 12px; align-items: center; }
.co-item img, .co-thumb { width: 56px; height: 56px; border-radius: 10px; object-fit: cover; flex: none; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; font-weight: 800; }
.co-lines { margin: 0; display: grid; gap: 8px; }
.co-lines > div { display: flex; justify-content: space-between; gap: 10px; }
.co-lines dt { color: var(--muted); } .co-lines dd { margin: 0; font-weight: 600; white-space: nowrap; }
.co-total { border-top: 1px solid var(--line); padding-top: 10px; }
.co-total dt { color: var(--ink); font-weight: 700; } .co-total dd { font-size: 1.25rem; font-weight: 800; }
.co-hint { margin-top: 4px; }
.co-foot { padding: 0 22px 22px; background: var(--bg); border-left: 1px solid var(--line); display: grid; gap: 10px; }
.co-note { text-align: center; margin: 0; }
@media (min-width: 761px) {
  .co-in { display: grid; grid-template-columns: minmax(0, 1fr) 320px; grid-template-rows: auto 1fr auto; overflow: auto; }
  .co-head { grid-column: 1 / -1; }
  .co-body { display: contents; }
  .co-main { grid-column: 1; grid-row: 2 / 4; }
  .co-sum { grid-column: 2; grid-row: 2; }
  .co-foot { grid-column: 2; grid-row: 3; }
}
/* Téléphone : formulaire court, résumé en haut, bouton Payer toujours visible en bas. */
@media (max-width: 760px) {
  .co { width: 100%; max-width: 100%; height: 100%; max-height: 100%; border-radius: 0; margin: 0; }
  .co-in { max-height: 100%; height: 100%; }
  .co-head { padding: 10px 16px; gap: 10px; }
  .co-head h2 { font-size: 1.05rem; }
  .co-close { width: 32px; height: 32px; }
  .co-body { display: flex; flex-direction: column; overflow: auto; flex: 1; min-height: 0; }
  .co-sum { order: -1; border-left: 0; border-bottom: 1px solid var(--line); padding: 10px 16px; gap: 6px; }
  .co-sum .co-h, #sumPrice, .co-lines > div:first-child { display: none; }
  .co-item { gap: 10px; font-size: .92rem; }
  .co-item img, .co-item .co-thumb { width: 40px; height: 40px; border-radius: 8px; }
  .co-total { border-top: 0; padding-top: 0; }
  .co-total dd { font-size: 1.1rem; }
  .co-main { padding: 14px 16px 18px; }
  .co-main.stack { gap: 12px; }
  .co-main .co-h { display: none; }
  .co-main .grid2 { grid-template-columns: 1fr 1fr; gap: 10px; }
  .co-main label { font-size: .88rem; margin-bottom: 4px; }
  .co-main input:not([type=checkbox]) { min-height: 46px; font-size: 16px; padding-top: 8px; padding-bottom: 8px; }
  .tel-cc { padding: 0 10px; }
  .co-hint { font-size: .78rem; margin-top: 3px; }
  .co-switch { border: 0; padding: 4px 0; font-weight: 500; font-size: .92rem; color: var(--muted); }
  .co-switch input { width: 16px; height: 16px; }
  .co-foot { border-left: 0; border-top: 1px solid var(--line); background: var(--surface); padding: 10px 16px calc(10px + env(safe-area-inset-bottom)); gap: 6px; box-shadow: 0 -8px 24px rgba(15,17,21,.06); }
  .co-foot .pp-cta { min-height: 52px; }
  .co-note { font-size: .74rem; }
}

/* ---------------------------------------------------------------- Téléphone : drapeau + indicatif */
.tel-field { position: relative; }
.tel { display: flex; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); overflow: hidden; }
.tel:focus-within { border-color: var(--ink); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 18%, transparent); }
.tel-cc { display: flex; align-items: center; gap: 6px; border: 0; border-right: 1px solid var(--line); background: var(--bg); padding: 0 12px; font: 600 .95rem var(--sans); color: var(--ink); cursor: pointer; white-space: nowrap; }
.tel-flag { font-size: 1.25rem; line-height: 1; }
.tel-caret { color: var(--muted); font-size: .75rem; }
.tel input { border: 0; border-radius: 0; flex: 1; min-width: 0; box-shadow: none; }
.tel input:focus { box-shadow: none; outline: none; }
.tel-pop { position: absolute; z-index: 20; left: 0; right: 0; top: 100%; margin-top: 6px; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 18px 40px rgba(15,17,21,.16); padding: 8px; }
.tel-pop ul { list-style: none; margin: 8px 0 0; padding: 0; max-height: 260px; overflow: auto; }
.tel-pop li { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 8px; cursor: pointer; }
.tel-pop li:hover, .tel-pop li[aria-selected="true"] { background: var(--bg); }
.tel-name { flex: 1; }

/* ---------------------------------------------------------------- Avis clients avec photos */
.pp-rating { color: inherit; text-decoration: none; }
.stars-sm, .stars { color: #f5a524; letter-spacing: 1px; }
.stars { font-size: 1.05rem; }
.pp-reviews { margin-top: 10px; }
.rv-summary { display: flex; align-items: center; gap: 14px; margin-bottom: 14px; }
.rv-avg { font-size: 2.4rem; line-height: 1; }
.rv-strip { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 6px; margin-bottom: 14px; scrollbar-width: thin; }
.rv-strip .rv-pic { flex: none; width: 92px; height: 92px; }
.rv-list { display: grid; gap: 12px; margin-bottom: 12px; }
.rv-card { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 14px 16px; display: grid; gap: 8px; }
.rv-head { display: flex; align-items: center; gap: 10px; }
.rv-avatar { width: 36px; height: 36px; border-radius: 50%; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; font-weight: 800; flex: none; }
.rv-text { margin: 0; white-space: pre-line; overflow-wrap: anywhere; }
.rv-gallery { display: flex; gap: 8px; flex-wrap: wrap; }
.rv-gallery .rv-pic { width: 84px; height: 84px; }
.rv-pic { padding: 0; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; cursor: zoom-in; background: var(--bg); }
.rv-pic img { width: 100%; height: 100%; object-fit: cover; display: block; }
.rv-viewer { border: 0; padding: 0; background: rgba(10,10,12,.94); max-width: 100vw; max-height: 100vh; width: 100vw; height: 100vh; display: grid; place-items: center; }
.rv-viewer:not([open]) { display: none; }
.rv-viewer::backdrop { background: rgba(10,10,12,.88); }
.rv-viewer img { max-width: 92vw; max-height: 82vh; object-fit: contain; border-radius: 10px; }
.rv-close, .rv-nav { position: fixed; z-index: 2; border: 0; background: rgba(15,17,21,.62); color: #fff; width: 44px; height: 44px; border-radius: 50%; font-size: 1.3rem; cursor: pointer; }
.rv-close { top: 14px; right: 14px; }
.rv-nav { top: 50%; transform: translateY(-50%); font-size: 1.8rem; }
.rv-nav.prev { left: 10px; } .rv-nav.next { right: 10px; }
.rv-count { position: fixed; bottom: 18px; left: 0; right: 0; text-align: center; color: #fff; font-size: .9rem; }
/* Formulaire de l'acheteur */
.rv-form { text-align: center; }
.rv-form textarea { min-height: 84px; text-align: left; }
.rv-stars { display: flex; justify-content: center; gap: 4px; }
.rv-star { border: 0; background: none; font-size: 2.1rem; line-height: 1; color: #d9d6cf; cursor: pointer; padding: 2px 4px; min-height: 0; }
.rv-star.on { color: #f5a524; }
.rv-hint { min-height: 1.2em; }
.rv-photo-block { display: grid; gap: 8px; text-align: left; }
.rv-photos { display: flex; gap: 8px; flex-wrap: wrap; }
.rv-thumb, .rv-add { width: 76px; height: 76px; border-radius: 10px; position: relative; flex: none; }
.rv-thumb { border: 1px solid var(--line); overflow: hidden; background: var(--bg); display: grid; place-items: center; }
.rv-thumb img { width: 100%; height: 100%; object-fit: cover; }
.rv-del { position: absolute; top: 4px; right: 4px; width: 22px; height: 22px; min-height: 0; padding: 0; border: 0; border-radius: 50%; background: rgba(15,17,21,.7); color: #fff; font-size: .85rem; line-height: 1; cursor: pointer; }
.rv-add { border: 1.5px dashed var(--line); background: var(--surface); display: grid; place-content: center; gap: 2px; font: 600 .78rem var(--sans); color: var(--muted); cursor: pointer; padding: 0; }
.rv-add span:first-child { font-size: 1.3rem; }
.rv-admin { display: grid; gap: 10px; }
.rv-card.is-hidden { opacity: .55; }

/* ---------------------------------------------------------------- Aperçu du PDF */
.pp-preview { margin-top: 22px; }
.pv-head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.pv-head .pp-h2 { margin: 0 0 12px; }
.pv-strip { display: flex; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 4px 2px 10px; scrollbar-width: thin; }
.pv-page { position: relative; flex: none; width: min(62%, 240px); aspect-ratio: 1 / 1.414; scroll-snap-align: start; padding: 0; border: 1px solid var(--line); border-radius: 10px; background: #fff; overflow: hidden; cursor: zoom-in; box-shadow: 0 6px 18px rgba(15,17,21,.08); display: grid; place-items: center; }
.pv-page img { width: 100%; height: 100%; object-fit: contain; display: block; }
.pv-page.loading { cursor: default; background: var(--bg); }
.pv-num { position: absolute; bottom: 6px; right: 6px; background: rgba(15,17,21,.7); color: #fff; font-size: .72rem; font-weight: 600; padding: 2px 7px; border-radius: 99px; }
.pv-note { margin: 4px 0 0; }
.rv-viewer img { background: #fff; }
.rv-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin: 30px 0 12px; }
.rv-top .pp-h2 { margin: 0; }
.rv-top .btn { min-height: 38px; padding: 0 14px; font-size: .9rem; }
.rv-empty { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 16px; display: grid; gap: 12px; justify-items: start; }
.rv-empty p { margin: 0; }
.store-switch { display: grid; gap: 6px; margin: 4px 0 18px; }
.store-switch select { min-height: 40px; font-weight: 600; }
.store-switch .btn { min-height: 34px; font-size: .82rem; }
.tiles.tiles3 { grid-template-columns: repeat(3, 1fr); }
.tiles.tiles3 .tile { background: var(--bg); border-radius: 12px; padding: 14px; }
.chart-visits > div:not(.zero) { background: color-mix(in srgb, var(--ink) 75%, #3b82f6); }
.bars { display: grid; gap: 10px; }
.bar-row { display: grid; gap: 4px; }
.bar { height: 8px; border-radius: 99px; background: var(--bg); overflow: hidden; }
.bar span { display: block; height: 100%; border-radius: 99px; background: var(--accent); }
@media (max-width: 620px) { .tiles.tiles3 { grid-template-columns: 1fr 1fr; } }
