/* VirtualCard — interface de gestion (responsive, clair/sombre, sans dépendance externe) */
:root {
  --primary: #2563EB; --on-primary: #fff;
  --bg: #f4f6fb; --surface: #fff; --surface-2: #eef1f7; --text: #0f172a; --muted: #5b6785; --border: #e1e6f0;
  --ok: #15803d; --ok-bg: #dcfce7; --warn: #a15c07; --warn-bg: #fef3c7; --danger: #dc2626; --danger-bg: #fee2e2; --info: #1d4ed8; --info-bg: #e0ecff;
  --radius: 16px; --shadow: 0 1px 2px rgba(15, 23, 42, .05), 0 10px 28px -14px rgba(15, 23, 42, .14);
  --sidebar-w: 268px; --bottom-h: 64px;
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color-scheme: light;
}
:root[data-theme=dark] {
  --bg: #0a0f1f; --surface: #121a30; --surface-2: #1a2342; --text: #e9edf7; --muted: #9aa6c2; --border: #263253;
  --ok: #4ade80; --ok-bg: #11351f; --warn: #fbbf24; --warn-bg: #3a2a0b; --danger: #f87171; --danger-bg: #3d1515; --info: #93b4ff; --info-bg: #15244b;
  --shadow: 0 1px 2px rgba(0, 0, 0, .4), 0 10px 28px -14px rgba(0, 0, 0, .7);
  color-scheme: dark;
}
@media (prefers-color-scheme: dark) {
  :root[data-theme=auto] {
    --bg: #0a0f1f; --surface: #121a30; --surface-2: #1a2342; --text: #e9edf7; --muted: #9aa6c2; --border: #263253;
    --ok: #4ade80; --ok-bg: #11351f; --warn: #fbbf24; --warn-bg: #3a2a0b; --danger: #f87171; --danger-bg: #3d1515; --info: #93b4ff; --info-bg: #15244b;
    --shadow: 0 1px 2px rgba(0, 0, 0, .4), 0 10px 28px -14px rgba(0, 0, 0, .7);
    color-scheme: dark;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font: 15px/1.55 var(--font); background: var(--bg); color: var(--text); -webkit-font-smoothing: antialiased; }
a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3 { line-height: 1.25; margin: 0; }
h1 { font-size: 1.6rem; font-weight: 750; letter-spacing: -.01em; }
h2 { font-size: 1.05rem; font-weight: 700; }
h3 { font-size: .95rem; font-weight: 650; }
p { margin: 0; }
button, input, select, textarea { font: inherit; color: inherit; }
button, a, summary, label[for] { touch-action: manipulation; -webkit-tap-highlight-color: transparent; }
:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; border-radius: 6px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--primary); color: var(--on-primary); padding: 8px 14px; border-radius: 10px; z-index: 100; }
.skip:focus { left: 8px; }
[hidden] { display: none !important; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.mono { font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; font-size: .92em; }
.truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.row.between { justify-content: space-between; }
.stack { display: grid; gap: 16px; }
.grow { flex: 1 1 auto; min-width: 0; }
.break { word-break: break-all; overflow-wrap: anywhere; }
.center { text-align: center; }
.container.narrow { max-width: 520px; padding-top: 15vh; }
.mt { margin-top: 10px; }

/* ---------- Icônes ---------- */
.i { width: 1.25em; height: 1.25em; flex: none; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; vertical-align: -.25em; }
.i-fill { fill: currentColor; stroke: none; }

/* ---------- Structure ---------- */
.shell { min-height: 100vh; min-height: 100dvh; }
.sidebar { position: fixed; inset: 0 auto 0 0; width: var(--sidebar-w); background: var(--surface); border-right: 1px solid var(--border); display: flex; flex-direction: column; padding: 18px 14px; z-index: 20; overflow-y: auto; }
.brand { display: flex; align-items: center; gap: 12px; padding: 6px 10px 18px; font-weight: 750; font-size: 1.05rem; color: var(--text); }
.brand:hover { text-decoration: none; }
.brand-logo { width: 38px; height: 38px; border-radius: 11px; background: var(--primary); color: var(--on-primary); display: grid; place-items: center; flex: none; overflow: hidden; }
.brand-logo img { width: 100%; height: 100%; object-fit: contain; background: #fff; }
.nav { display: grid; gap: 3px; }
.nav a, .nav button { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 12px; color: var(--muted); font-weight: 560; border: 0; background: none; text-align: left; cursor: pointer; width: 100%; }
.nav a:hover, .nav button:hover { background: var(--surface-2); color: var(--text); text-decoration: none; }
.nav a[aria-current=page] { background: color-mix(in srgb, var(--primary) 13%, var(--surface)); color: var(--primary); }
.nav-sep { height: 1px; background: var(--border); margin: 10px 6px; }
.sidebar-foot { margin-top: auto; padding-top: 14px; display: grid; gap: 3px; }
.who { display: flex; align-items: center; gap: 10px; padding: 10px 12px; font-size: 13px; color: var(--muted); }
.who b { color: var(--text); display: block; font-size: 14px; }
.content { margin-left: var(--sidebar-w); min-width: 0; }
.container { max-width: 1140px; margin: 0 auto; padding: 30px 30px 56px; }
.topbar, .bottomnav { display: none; }

@media (max-width: 900px) {
  .sidebar { display: none; }
  .content { margin-left: 0; }
  .container { padding: 18px 16px calc(var(--bottom-h) + 36px + env(safe-area-inset-bottom)); }
  .topbar { display: flex; align-items: center; justify-content: space-between; gap: 10px; position: sticky; top: 0; z-index: 25; padding: calc(10px + env(safe-area-inset-top)) 16px 10px; background: color-mix(in srgb, var(--surface) 92%, transparent); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-bottom: 1px solid var(--border); }
  .topbar .brand { padding: 0; }
  .bottomnav { display: grid; grid-template-columns: repeat(5, 1fr); position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; height: calc(var(--bottom-h) + env(safe-area-inset-bottom)); padding-bottom: env(safe-area-inset-bottom); background: color-mix(in srgb, var(--surface) 94%, transparent); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-top: 1px solid var(--border); }
  .bottomnav a, .bottomnav button { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; font-size: 11px; font-weight: 600; color: var(--muted); border: 0; background: none; cursor: pointer; text-decoration: none; }
  .bottomnav .i { width: 24px; height: 24px; }
  .bottomnav [aria-current=page] { color: var(--primary); }
  .bottomnav .fab span.fab-dot { width: 46px; height: 46px; border-radius: 16px; background: var(--primary); color: var(--on-primary); display: grid; place-items: center; margin-top: -18px; box-shadow: 0 8px 18px -6px color-mix(in srgb, var(--primary) 70%, transparent); }
}

/* ---------- En-tête de page ---------- */
.page-head { display: flex; flex-wrap: wrap; gap: 12px 16px; align-items: center; justify-content: space-between; margin-bottom: 22px; }
.page-head .sub { color: var(--muted); margin-top: 2px; }

/* ---------- Boutons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 42px; padding: 0 18px; border-radius: 12px; border: 1px solid transparent; background: var(--primary); color: var(--on-primary); font-weight: 650; cursor: pointer; text-decoration: none; white-space: nowrap; transition: filter .15s, background .15s, transform .06s; }
.btn:hover { filter: brightness(1.08); text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn.secondary { background: var(--surface); color: var(--text); border-color: var(--border); }
.btn.secondary:hover { background: var(--surface-2); filter: none; }
.btn.ghost { background: transparent; color: var(--muted); }
.btn.ghost:hover { background: var(--surface-2); color: var(--text); filter: none; }
.btn.danger { background: var(--danger); color: #fff; }
.btn.danger-soft { background: var(--danger-bg); color: var(--danger); }
.btn.sm { min-height: 36px; padding: 0 13px; font-size: 13px; border-radius: 10px; }
.btn.icon { width: 40px; padding: 0; }
.btn.sm.icon { width: 36px; }
.btn.block { width: 100%; }
.btn[disabled], .btn[aria-disabled=true] { opacity: .5; pointer-events: none; }

/* ---------- Panneaux ---------- */
.panel { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); padding: 22px; }
.panel > h2 { margin-bottom: 4px; }
.panel > .lead { color: var(--muted); font-size: 13px; margin-bottom: 18px; }
.panel + .panel { margin-top: 18px; }
.panel.tight { padding: 0; overflow: hidden; }
.panel-head { display: flex; gap: 10px; align-items: center; justify-content: space-between; padding: 18px 22px; border-bottom: 1px solid var(--border); }

/* ---------- Formulaires ---------- */
.field { display: grid; gap: 6px; align-content: start; }
.field > label, .label { font-weight: 650; font-size: 13px; }
.input, .select, .textarea { width: 100%; min-height: 44px; padding: 10px 13px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface); transition: border-color .15s, box-shadow .15s; }
.textarea { min-height: 96px; resize: vertical; }
.input:focus, .select:focus, .textarea:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 22%, transparent); }
.input::placeholder, .textarea::placeholder { color: color-mix(in srgb, var(--muted) 70%, transparent); }
.hint { font-size: 12px; color: var(--muted); }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.form-grid .span2 { grid-column: 1 / -1; }
.input-color { width: 56px; height: 44px; padding: 3px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface); cursor: pointer; }
.color-field { display: flex; align-items: center; gap: 10px; }
.switch { display: flex; align-items: center; gap: 12px; cursor: pointer; font-weight: 560; }
.switch input { appearance: none; -webkit-appearance: none; width: 46px; height: 28px; border-radius: 999px; background: var(--border); position: relative; flex: none; cursor: pointer; transition: background .2s; margin: 0; }
.switch input::after { content: ""; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .3); transition: transform .2s; }
.switch input:checked { background: var(--primary); }
.switch input:checked::after { transform: translateX(18px); }
.switch input:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }
.check { display: flex; align-items: center; gap: 10px; }
.check input { width: 18px; height: 18px; accent-color: var(--primary); }
.choice-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
.choice { position: relative; border: 2px solid var(--border); border-radius: 14px; padding: 10px; cursor: pointer; background: var(--surface); display: grid; gap: 8px; text-align: center; }
.choice input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.choice:has(input:checked) { border-color: var(--primary); box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 20%, transparent); }
.choice:has(input:focus-visible) { outline: 2px solid var(--primary); outline-offset: 2px; }
.choice .swatch { height: 76px; border-radius: 10px; display: grid; place-items: center; font-weight: 700; background: var(--surface-2); color: var(--muted); }
.choice small { color: var(--muted); }
.section-title { display: flex; align-items: center; gap: 10px; margin-bottom: 16px; }
.section-title .i { color: var(--primary); }
.form-actions { display: flex; gap: 10px; flex-wrap: wrap; position: sticky; bottom: 0; padding: 14px 0; background: linear-gradient(to top, var(--bg) 70%, transparent); z-index: 5; }
@media (max-width: 900px) { .form-actions { bottom: calc(var(--bottom-h) + env(safe-area-inset-bottom)); } }
@media (max-width: 640px) {
  .form-grid { grid-template-columns: 1fr; }
  .input, .select, .textarea { font-size: 16px; }   /* évite le zoom automatique d'iOS */
}

/* ---------- Badges, alertes ---------- */
.badge { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: 999px; font-size: 12px; font-weight: 650; background: var(--surface-2); color: var(--muted); white-space: nowrap; }
.badge.ok { background: var(--ok-bg); color: var(--ok); }
.badge.warn { background: var(--warn-bg); color: var(--warn); }
.badge.danger { background: var(--danger-bg); color: var(--danger); }
.badge.info { background: var(--info-bg); color: var(--info); }
.alert { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: 12px; border: 1px solid; font-size: 14px; margin-bottom: 16px; }
.alert .i { margin-top: 2px; }
.alert.ok { background: var(--ok-bg); border-color: color-mix(in srgb, var(--ok) 35%, transparent); color: var(--ok); }
.alert.error { background: var(--danger-bg); border-color: color-mix(in srgb, var(--danger) 35%, transparent); color: var(--danger); }
.alert.warn { background: var(--warn-bg); border-color: color-mix(in srgb, var(--warn) 35%, transparent); color: var(--warn); }
.alert.info { background: var(--info-bg); border-color: color-mix(in srgb, var(--info) 30%, transparent); color: var(--info); }
.alert ul { margin: 0; padding-left: 18px; }

/* ---------- Statistiques ---------- */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 14px; margin-bottom: 18px; }
.stat { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px; box-shadow: var(--shadow); display: flex; align-items: center; gap: 14px; }
.stat .ico { width: 44px; height: 44px; border-radius: 13px; display: grid; place-items: center; background: color-mix(in srgb, var(--primary) 13%, var(--surface)); color: var(--primary); flex: none; }
.stat .v { font-size: 1.7rem; font-weight: 750; line-height: 1.1; }
.stat .l { color: var(--muted); font-size: 13px; }
.chart { width: 100%; height: auto; display: block; }
.chart .bar-v { fill: var(--primary); }
.chart .bar-s { fill: color-mix(in srgb, var(--ok) 80%, var(--surface)); }
.chart .axis { stroke: var(--border); }
.chart text { fill: var(--muted); font-size: 10px; }
.legend { display: flex; gap: 16px; font-size: 13px; color: var(--muted); }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 6px; background: var(--primary); }
.legend i.s { background: var(--ok); }

/* ---------- Tuiles de cartes ---------- */
.cards-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 16px; }
.ctile { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; display: flex; flex-direction: column; }
.ctile-head { height: 86px; position: relative; background: var(--primary); }
.ctile-head .badge { position: absolute; top: 12px; right: 12px; background: rgba(255, 255, 255, .92); color: #334155; }
.ctile-head .badge.ok { color: #15803d; }
.ctile-avatar { position: absolute; left: 18px; bottom: -28px; width: 60px; height: 60px; border-radius: 50%; border: 4px solid var(--surface); background: var(--surface-2); object-fit: cover; display: grid; place-items: center; font-weight: 700; color: #fff; overflow: hidden; }
.ctile-body { padding: 38px 18px 16px; display: grid; gap: 10px; flex: 1; }
.ctile-body h3 { font-size: 1.05rem; }
.ctile-meta { display: flex; gap: 14px; font-size: 12px; color: var(--muted); }
.ctile-actions { display: flex; gap: 6px; flex-wrap: wrap; padding: 0 18px 18px; }
.ctile-actions form { display: contents; }
.toolbar { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 18px; align-items: center; }
.toolbar .search { flex: 1 1 240px; position: relative; }
.toolbar .search .i { position: absolute; left: 13px; top: 50%; transform: translateY(-50%); color: var(--muted); }
.toolbar .search input { padding-left: 40px; }
.empty { text-align: center; padding: 48px 20px; color: var(--muted); display: grid; gap: 12px; justify-items: center; }
.empty .ico { width: 64px; height: 64px; border-radius: 20px; display: grid; place-items: center; background: var(--surface-2); }
.empty .ico .i { width: 30px; height: 30px; }
.empty h2 { color: var(--text); }

/* ---------- Onglets ---------- */
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--border); margin-bottom: 22px; overflow-x: auto; scrollbar-width: none; }
.tabs a { padding: 11px 16px; color: var(--muted); font-weight: 600; white-space: nowrap; border-bottom: 2px solid transparent; margin-bottom: -1px; }
.tabs a:hover { color: var(--text); text-decoration: none; }
.tabs a[aria-current=page] { color: var(--primary); border-color: var(--primary); }

/* ---------- Tableaux ---------- */
.table { width: 100%; border-collapse: collapse; }
.table th { text-align: left; font-size: 12px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); padding: 12px 16px; background: var(--surface-2); }
.table td { padding: 14px 16px; border-top: 1px solid var(--border); vertical-align: middle; }
@media (max-width: 720px) {
  .table thead { display: none; }
  .table, .table tbody, .table tr, .table td { display: block; }
  .table tr { border-top: 1px solid var(--border); padding: 10px 0; }
  .table td { border: 0; padding: 5px 16px; display: flex; justify-content: space-between; gap: 12px; align-items: center; text-align: right; }
  .table td::before { content: attr(data-label); color: var(--muted); font-size: 12px; font-weight: 650; text-align: left; }
  .table td.actions { justify-content: flex-end; }
  .table td.actions::before { content: none; }
}

/* ---------- Dialogues & toasts ---------- */
dialog.modal { border: 0; border-radius: 20px; padding: 0; width: min(92vw, 480px); max-height: 90dvh; background: var(--surface); color: var(--text); box-shadow: 0 30px 80px -20px rgba(0, 0, 0, .5); overflow: auto; }
dialog.modal::backdrop { background: rgba(8, 12, 24, .58); backdrop-filter: blur(3px); }
.modal-body { padding: 24px; display: grid; gap: 14px; }
.modal-actions { display: flex; gap: 10px; justify-content: flex-end; flex-wrap: wrap; }
.modal-body .qr-box { background: #fff; border-radius: 16px; padding: 14px; justify-self: center; line-height: 0; }
.qr-box svg, .qr-box canvas { width: min(260px, 70vw); height: auto; display: block; }
#toasts { position: fixed; z-index: 90; left: 50%; transform: translateX(-50%); bottom: calc(24px + env(safe-area-inset-bottom)); display: grid; gap: 8px; width: min(92vw, 420px); pointer-events: none; }
@media (max-width: 900px) { #toasts { bottom: calc(var(--bottom-h) + 16px + env(safe-area-inset-bottom)); } }
.toast { background: #0f172a; color: #fff; padding: 12px 16px; border-radius: 14px; box-shadow: 0 12px 30px -10px rgba(0, 0, 0, .5); font-weight: 560; animation: toast-in .25s ease; display: flex; gap: 10px; align-items: center; pointer-events: auto; }
.toast.error { background: #b91c1c; }
@keyframes toast-in { from { opacity: 0; transform: translateY(10px); } }
.menu-list { display: grid; gap: 4px; }
.menu-list a, .menu-list button { display: flex; gap: 12px; align-items: center; padding: 12px; border-radius: 12px; color: var(--text); border: 0; background: none; width: 100%; text-align: left; cursor: pointer; font-weight: 560; }
.menu-list a:hover, .menu-list button:hover { background: var(--surface-2); text-decoration: none; }

/* ---------- Connexion ---------- */
.login { min-height: 100vh; min-height: 100dvh; display: grid; place-items: center; padding: 24px 16px; position: relative; isolation: isolate; background: linear-gradient(135deg, color-mix(in srgb, var(--primary) 85%, #1e1b4b), color-mix(in srgb, var(--primary) 40%, #4c1d95)); }
.login-bg { position: absolute; inset: 0; z-index: -1; width: 100%; height: 100%; object-fit: cover; }
.login-bg.blur { filter: blur(6px); transform: scale(1.05); }
.login-overlay { position: absolute; inset: 0; z-index: -1; background: rgba(0, 0, 0, .45); }
.login-box { width: min(100%, 420px); }
.login-head { text-align: center; color: #fff; margin-bottom: 22px; display: grid; gap: 6px; justify-items: center; }
.login-head img { max-height: 64px; max-width: 220px; object-fit: contain; }
.login-head .brand-logo { width: 62px; height: 62px; border-radius: 18px; background: rgba(255, 255, 255, .2); }
.login-card { background: var(--surface); border-radius: 24px; padding: 28px; box-shadow: 0 30px 70px -25px rgba(0, 0, 0, .55); display: grid; gap: 16px; }
.sep { display: flex; align-items: center; gap: 12px; color: var(--muted); font-size: 12px; }
.sep::before, .sep::after { content: ""; flex: 1; height: 1px; background: var(--border); }

/* ---------- Aperçu téléphone (formulaires carte/template) ---------- */
.split { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 24px; align-items: start; }
.preview-col { position: sticky; top: 20px; }
.phone { border: 9px solid #0b1020; border-radius: 40px; overflow: hidden; box-shadow: 0 24px 50px -20px rgba(0, 0, 0, .5); background: #000; aspect-ratio: 9 / 17; position: relative; }
.phone-screen { position: absolute; inset: 0; overflow: auto; scrollbar-width: none; }
.phone-screen::-webkit-scrollbar { display: none; }
@media (max-width: 1100px) { .split { grid-template-columns: 1fr; } .preview-col { position: static; max-width: 340px; margin: 0 auto; width: 100%; } }

/* ---------- Divers ---------- */
.kv { display: grid; grid-template-columns: max-content 1fr; gap: 6px 18px; font-size: 14px; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; word-break: break-word; }
.list-plain { list-style: none; margin: 0; padding: 0; display: grid; }
.list-plain li { display: flex; gap: 12px; align-items: center; padding: 12px 0; border-top: 1px solid var(--border); }
.list-plain li:first-child { border-top: 0; }
.pad { padding: 20px; }
.list-plain.pad { padding: 0 22px; }
.nowrap { flex-wrap: nowrap; }
.avatar-sm { border-radius: 50%; object-fit: cover; flex: none; }
.share-row { display: grid; grid-template-columns: 112px 1fr; gap: 18px; align-items: center; }
.share-row .qr-mini { background: #fff; border-radius: 12px; padding: 8px; line-height: 0; width: 112px; height: 112px; }
.share-row .qr-mini svg { width: 100%; height: 100%; }
@media (max-width: 560px) { .share-row { grid-template-columns: 84px 1fr; } .share-row .qr-mini { width: 84px; height: 84px; } }
.nfc-pulse { width: 84px; height: 84px; border-radius: 50%; background: var(--primary); color: var(--on-primary); display: grid; place-items: center; justify-self: center; animation: pulse 1.6s infinite; }
.nfc-pulse .i { width: 38px; height: 38px; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--primary) 55%, transparent); } 100% { box-shadow: 0 0 0 28px transparent; } }
.progress { height: 8px; background: var(--surface-2); border-radius: 99px; overflow: hidden; }
.progress > span { display: block; height: 100%; background: var(--primary); }
pre.log { background: var(--surface-2); border-radius: 12px; padding: 14px; overflow: auto; font-size: 12.5px; max-height: 280px; margin: 0; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}
@media print { .sidebar, .topbar, .bottomnav, .form-actions { display: none !important; } .content { margin: 0; } }

/* ---------- Réglages ---------- */
.swatch-dot { width: 28px; height: 28px; border-radius: 50%; border: 2px solid var(--surface); box-shadow: 0 0 0 1px var(--border); cursor: pointer; padding: 0; }
.swatch-dot:hover { transform: scale(1.12); }
.logo-prev { max-height: 56px; max-width: 200px; object-fit: contain; border-radius: 10px; background: var(--surface-2); padding: 6px; justify-self: start; }
.logo-prev.wide { max-height: 110px; max-width: 100%; }
.checklist { margin: 0; padding-left: 20px; display: grid; gap: 8px; }
.steps { display: flex; justify-content: center; gap: 8px; margin-bottom: 20px; }
.steps span { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; font-weight: 700; background: var(--surface-2); color: var(--muted); }
.steps span.on { background: var(--primary); color: var(--on-primary); }
.steps span.done { background: var(--ok-bg); color: var(--ok); }
