:root {
  --bg: #07110c;
  --card: #0e1a13;
  --card-2: #12231a;
  --line: #1e3327;
  --text: #eafaf0;
  --muted: #8aa596;
  --green: #7cf5b0;
  --green-dim: #3fbf7f;
  --purple: #b79cff;
  --danger: #ff8d8d;
  --radius: 22px;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", Inter, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
}

body {
  min-height: 100dvh;
  padding: max(18px, env(safe-area-inset-top)) 16px calc(28px + env(safe-area-inset-bottom));
  display: flex;
  justify-content: center;
}

.glow {
  position: fixed;
  inset: -30% -20% auto;
  height: 60vh;
  background:
    radial-gradient(45% 55% at 25% 30%, rgba(124, 245, 176, .18), transparent 70%),
    radial-gradient(40% 50% at 85% 10%, rgba(183, 156, 255, .12), transparent 70%);
  pointer-events: none;
  filter: blur(20px);
  z-index: 0;
}

#app {
  width: 100%;
  max-width: 440px;
  position: relative;
  z-index: 1;
}

.screen[hidden] { display: none; }

/* ── brand ── */
.brand {
  font-weight: 800;
  letter-spacing: -.02em;
  font-size: 15px;
  display: flex;
  align-items: baseline;
  gap: 2px;
}
.brand span {
  color: var(--green);
  font-weight: 600;
  font-size: 13px;
  margin-left: 2px;
}
.brand.big {
  font-size: 22px;
  margin-bottom: 34px;
}
.brand.big span { font-size: 18px; }

/* ── onboarding ── */
#onboard { padding-top: 6vh; }
#onboard h1 {
  font-size: 38px;
  line-height: 1.05;
  letter-spacing: -.035em;
  margin: 0 0 14px;
}
.lede {
  color: var(--muted);
  font-size: 17px;
  line-height: 1.45;
  margin: 0 0 30px;
}
.primary, .secondary, .ghost, .danger, .pill, .copy, .tab, .refresh {
  font: inherit;
  border: 0;
  cursor: pointer;
  border-radius: 16px;
  transition: transform .08s ease, opacity .15s ease, background .15s ease;
}
.primary:active, .secondary:active, .ghost:active, .tab:active { transform: scale(.98); }
.primary:disabled, .secondary:disabled { cursor: default; }
.primary:disabled {
  opacity: 1;
  background: #16281e;
  color: #6f8a7b;
  box-shadow: none;
  border: 1px solid var(--line);
}

.primary {
  width: 100%;
  padding: 17px 18px;
  background: var(--green);
  color: #04140a;
  font-weight: 700;
  font-size: 17px;
  border-radius: 18px;
  box-shadow: 0 8px 30px -10px rgba(124, 245, 176, .55);
}
.primary + .ghost { margin-top: 10px; }
.ghost {
  width: 100%;
  padding: 14px;
  background: transparent;
  color: var(--text);
  border: 1px solid var(--line);
  font-size: 15px;
}
.secondary {
  padding: 13px 16px;
  background: var(--card-2);
  color: var(--text);
  border: 1px solid var(--line);
  font-weight: 600;
  font-size: 15px;
}
.secondary.small, .ghost.small, .danger.small {
  width: auto;
  padding: 9px 12px;
  font-size: 13px;
  border-radius: 12px;
}
.danger {
  background: transparent;
  color: var(--danger);
  border: 1px solid #4a2020;
}
.warn {
  margin: 26px 0 0;
  color: #b9c9bf;
  font-size: 12.5px;
  line-height: 1.55;
  text-align: center;
}
.warn b { color: var(--text); }

.import { margin-top: 14px; display: grid; gap: 10px; }
.import[hidden] { display: none; }
.import label { color: var(--muted); font-size: 13px; }
.import textarea {
  width: 100%;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 14px;
  color: var(--text);
  padding: 12px 14px;
  font: 13px/1.4 ui-monospace, SFMono-Regular, Menlo, monospace;
  resize: vertical;
}

/* ── wallet top ── */
.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 22px;
}
.pill {
  flex: 0 0 auto;
  white-space: nowrap;
  background: transparent;
  color: var(--muted);
  border: 1px solid var(--line);
  padding: 7px 12px;
  font-size: 12.5px;
  border-radius: 999px;
}

/* ── balance ── */
.balance {
  padding: 20px 20px 16px;
  background: linear-gradient(160deg, #102018, #0b1711 70%);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  position: relative;
  overflow: hidden;
}
.balance::after {
  content: "";
  position: absolute;
  width: 180px; height: 180px;
  right: -70px; top: -90px;
  background: radial-gradient(circle, rgba(124,245,176,.16), transparent 65%);
  pointer-events: none;
}
.label {
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .09em;
  font-weight: 600;
}
.amount {
  display: flex;
  align-items: baseline;
  gap: 7px;
  margin-top: 6px;
  font-size: 44px;
  font-weight: 800;
  letter-spacing: -.04em;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}
.amount .unit {
  font-size: 15px;
  font-weight: 500;
  color: var(--muted);
  letter-spacing: 0;
}
.sub {
  margin-top: 9px;
  color: var(--muted);
  font-weight: 600;
  font-size: 13.5px;
  font-variant-numeric: tabular-nums;
}
.fuel {
  color: #5d7467;
  font-weight: 500;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .06em;
}
.refresh {
  position: absolute;
  right: 16px;
  bottom: 15px;
  background: transparent;
  color: var(--muted);
  font-size: 12px;
  padding: 6px 8px;
}
.inline-err {
  margin-top: 10px;
  color: var(--danger);
  font-size: 12.5px;
  line-height: 1.4;
}

/* ── address ── */
.addr {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 12px 0 18px;
  padding: 12px 14px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 16px;
}
.addr-main { min-width: 0; flex: 1; }
.mono {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 12.5px;
}
#addr {
  margin-top: 4px;
  color: #cfe3d7;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.copy {
  background: var(--card-2);
  border: 1px solid var(--line);
  color: var(--text);
  padding: 8px 11px;
  font-size: 12px;
  border-radius: 11px;
}

/* ── tabs ── */
.actions {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-bottom: 14px;
}
.tab {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  padding: 12px 6px 10px;
  background: var(--card);
  border: 1px solid var(--line);
  color: var(--muted);
  font-size: 12.5px;
  font-weight: 600;
}
.tab span { font-size: 17px; line-height: 1; }
.tab.active {
  background: #12241a;
  color: var(--text);
  border-color: #2c4a38;
}
.tab.active span { color: var(--green); }

/* ── panels ── */
.panel {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px;
  margin-bottom: 14px;
}
.panel[hidden] { display: none; }
.panel h2 {
  margin: 0 0 6px;
  font-size: 19px;
  letter-spacing: -.02em;
}
.hint {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
  margin: 0 0 16px;
}
.panel label {
  display: block;
  color: var(--muted);
  font-size: 12px;
  margin: 14px 0 6px;
}
input, textarea, select {
  width: 100%;
  background: #0a140e;
  border: 1px solid var(--line);
  color: var(--text);
  border-radius: 13px;
  padding: 13px 14px;
  font-size: 15px;
  font-family: inherit;
  line-height: 1.4;
  outline: none;
}
input:focus, textarea:focus { border-color: #35704f; }
textarea { resize: vertical; font-size: 13px; line-height: 1.45; }
.field-row { display: flex; gap: 8px; align-items: center; }
.field-row input { flex: 1; }
.suffix { color: var(--muted); font-size: 13px; }
.panel .primary { margin-top: 16px; }

/* ── invoice ── */
.invoice { margin-top: 18px; text-align: center; }
.invoice[hidden] { display: none; }
.qr {
  display: inline-flex;
  padding: 12px;
  background: #fff;
  border-radius: 16px;
  margin-bottom: 12px;
}
.qr img, .qr canvas { display: block; }
.qr.small { padding: 10px; border-radius: 14px; }
#invoiceText { font-size: 11.5px; text-align: left; }
.row { display: flex; gap: 8px; margin-top: 10px; }
.row > * { flex: 1; }
.status { margin-top: 12px; font-size: 12.5px; color: var(--muted); line-height: 1.5; }
.status.ok { color: var(--green); }
.status.err { color: var(--danger); }

/* ── pprgb subcards ── */
.subcard {
  padding: 14px;
  background: var(--card-2);
  border: 1px solid var(--line);
  border-radius: 16px;
  margin-bottom: 12px;
  text-align: left;
}
.subcard:last-child { margin-bottom: 0; }
.subcard-title {
  font-weight: 700;
  font-size: 14px;
  margin-bottom: 4px;
}
.subcard .qr { margin: 12px auto; }
.subcard .secondary { width: 100%; }
.preview {
  margin-top: 10px;
  color: var(--green);
  font-size: 13px;
}
.preview.err { color: var(--danger); }

/* ── debug ── */
.debug {
  margin-top: 18px;
  border: 1px dashed #243d2e;
  border-radius: 14px;
  padding: 10px 12px;
  color: var(--muted);
  font-size: 12px;
}
.debug summary { cursor: pointer; }
.debug-actions { display: flex; gap: 8px; margin: 10px 0; }
#log {
  max-height: 220px;
  overflow: auto;
  background: #060d09;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 10px;
  color: #9fd9b6;
  font-size: 11px;
  line-height: 1.5;
  white-space: pre-wrap;
  word-break: break-all;
}
.raw { margin-top: 12px; }
.raw label { font-size: 11px; }
.raw .secondary { margin-top: 8px; }
.raw select { width: auto; padding: 10px; }

.foot {
  text-align: center;
  color: #5d7467;
  font-size: 11px;
  margin: 22px 0 0;
}

/* ── toast ── */
.toast {
  position: fixed;
  left: 50%;
  bottom: calc(22px + env(safe-area-inset-bottom));
  transform: translateX(-50%);
  background: #eafaf0;
  color: #06110b;
  font-weight: 600;
  font-size: 13.5px;
  padding: 11px 16px;
  border-radius: 999px;
  z-index: 50;
  max-width: 88vw;
  text-align: center;
  box-shadow: 0 10px 30px rgba(0,0,0,.35);
}
.toast[hidden] { display: none; }
.toast.err { background: #ffd9d9; color: #3a0d0d; }

/* ── scanner ── */
.scan-btn { width: 100%; margin-top: 8px; }
.scanner {
  position: fixed;
  inset: 0;
  background: #000;
  z-index: 60;
  display: flex;
  align-items: center;
  justify-content: center;
}
.scanner[hidden] { display: none; }
.scanner video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.scan-frame {
  width: min(68vw, 280px);
  aspect-ratio: 1;
  border: 2px solid rgba(124, 245, 176, .9);
  border-radius: 22px;
  box-shadow: 0 0 0 100vmax rgba(0, 0, 0, .45);
  position: relative;
  z-index: 2;
}
.scan-hint {
  position: absolute;
  bottom: 110px;
  color: #eafaf0;
  font-size: 14px;
  z-index: 2;
  background: rgba(0,0,0,.45);
  padding: 8px 14px;
  border-radius: 999px;
}
.scan-close {
  position: absolute;
  bottom: 40px;
  z-index: 2;
  background: #eafaf0;
  color: #06110b;
  border: 0;
  border-radius: 999px;
  padding: 13px 26px;
  font: 600 15px inherit;
}

/* ── passphrase / unlock / backup ── */
#pass label, #unlock label {
  display: block;
  color: var(--muted);
  font-size: 12px;
  margin: 16px 0 6px;
}
#pass input, #unlock input { margin-bottom: 4px; }
#pass .primary, #unlock .primary { margin-top: 20px; }
#pass .hint.small {
  font-size: 12px;
  color: #9fb5a8;
  margin-top: 10px;
  line-height: 1.5;
}
.account-chip {
  display: inline-block;
  background: var(--card);
  border: 1px solid var(--line);
  color: #cfe3d7;
  border-radius: 999px;
  padding: 9px 14px;
  margin: 2px 0 18px;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.alert {
  background: #1a1208;
  border: 1px solid #4a3a1c;
  border-radius: 16px;
  padding: 16px;
  margin: 0 0 20px;
}
.alert b { display: block; color: #ffd9a0; font-size: 15px; margin-bottom: 8px; }
.alert p {
  margin: 0 0 8px;
  color: #e8d9c2;
  font-size: 13.5px;
  line-height: 1.55;
}
.alert p:last-child { margin-bottom: 0; }

.check {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 18px 0 12px;
  color: var(--text);
  font-size: 14px;
  cursor: pointer;
}
.check input {
  width: 20px;
  height: 20px;
  accent-color: var(--green);
  flex: 0 0 auto;
}
#backup .primary, #backup .secondary, #backup .ghost { margin-bottom: 8px; }
#backup .secondary { width: 100%; }
#backupContinue[disabled] { opacity: .35; }
.backup-links {
  display: flex;
  gap: 8px;
  justify-content: center;
  margin-top: 22px;
}

/* ── modal ── */
.modal {
  position: fixed;
  inset: 0;
  z-index: 70;
  background: rgba(3, 8, 6, .82);
  backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 22px;
}
.modal[hidden] { display: none; }
.modal-card {
  width: 100%;
  max-width: 320px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: 20px;
  text-align: center;
}
.modal-title { font-weight: 800; font-size: 17px; margin-bottom: 6px; }
.modal-card .hint { margin-bottom: 14px; }
.modal-card .qr { margin: 0 auto 16px; }
.modal-card .secondary { width: 100%; }

/* ── import fichier ── */
.or {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--muted);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .08em;
  margin: 4px 0;
}
.or::before, .or::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--line);
}
.file-label {
  display: inline-block;
  padding: 12px 14px;
  border: 1px dashed #2f533d;
  border-radius: 13px;
  color: var(--text);
  font-size: 14px;
  text-align: center;
  cursor: pointer;
}
#importFile {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}
#importFileName { color: var(--green); }
#importPassWrap label { margin-top: 4px; }

.unlock-links {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 14px;
}
.unlock-links button { width: 100%; }

.moved {
  margin: 22px 0 0;
  text-align: center;
  color: #7e9588;
  font-size: 12px;
  line-height: 1.6;
}
.moved a { color: var(--green); text-decoration: none; font-weight: 600; }
.moved b { color: #b9c9bf; }

.payee-info {
  margin-top: 8px;
  font-size: 12.5px;
  line-height: 1.45;
  padding: 9px 11px;
  border-radius: 11px;
  border: 1px solid var(--line);
  color: var(--muted);
  background: #0a140e;
}
.payee-info.ok { color: var(--green); border-color: #245239; }
.payee-info.warn { color: #ffd9a0; border-color: #4a3a1c; background: #1a1208; }
.payee-info.err { color: var(--danger); border-color: #4a2020; }

/* ── trade ── */
.tab { font-size: 11.5px; padding: 11px 4px 9px; }
.market-line {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  background: #0a140e;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 11px 12px;
  margin: 12px 0 14px;
}
.market-line .label { display: block; font-size: 10px; }
.market-line b {
  display: block;
  margin-top: 3px;
  font-size: 15px;
  font-variant-numeric: tabular-nums;
}
#bestBid { color: var(--green); }
#bestAsk { color: #ffb4a0; }

.seg {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  background: #0a140e;
  border: 1px solid var(--line);
  border-radius: 13px;
  padding: 4px;
  margin-bottom: 4px;
}
.seg button {
  border: 0;
  background: transparent;
  color: var(--muted);
  font: 600 14px inherit;
  padding: 9px;
  border-radius: 10px;
}
.seg button.active {
  background: var(--card-2);
  color: var(--text);
  box-shadow: inset 0 0 0 1px var(--line);
}
.seg button[data-side="buy"].active { color: var(--green); }
.seg button[data-side="sell"].active { color: #ffb4a0; }

.trade-total {
  margin-top: 14px;
  font-size: 13px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.trade-total b { color: var(--text); }
#tradeHint { margin: 6px 0 0; min-height: 16px; }
.orders {
  margin-top: 18px;
  border-top: 1px solid var(--line);
  padding-top: 12px;
  color: var(--muted);
  font-size: 12.5px;
}
.orders summary { cursor: pointer; }
.orders-list { margin-top: 10px; display: grid; gap: 8px; }
.order-row {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #0a140e;
  border: 1px solid var(--line);
  border-radius: 11px;
  padding: 9px 10px;
}
.order-row .meta { flex: 1; min-width: 0; }
.order-row .side { font-weight: 700; font-size: 11px; }
.order-row .side.buy { color: var(--green); }
.order-row .side.sell { color: #ffb4a0; }
.order-row .nums { color: var(--text); font-size: 12px; }
.order-row .sub { color: var(--muted); font-size: 11px; margin-top: 2px; }
.order-row button {
  background: transparent;
  border: 1px solid #4a2020;
  color: var(--danger);
  border-radius: 9px;
  padding: 6px 9px;
  font: 600 11px inherit;
}

.trade-total .muted { color: var(--muted); }

.secret-row { display: flex; gap: 8px; align-items: center; }
.secret-row input { flex: 1; }
.reveal-btn {
  flex: 0 0 auto;
  background: var(--card-2);
  border: 1px solid var(--line);
  color: var(--muted);
  border-radius: 11px;
  padding: 10px 11px;
  font: 600 11.5px inherit;
}
.reveal-btn:active { transform: scale(.97); }

/* Champs “secret” sans type=password : évite le strong-password Safari. */
.secret { -webkit-text-security: disc; text-security: disc; }
.secret.reveal { -webkit-text-security: none; text-security: none; }

/* iOS zoome dès qu'un champ focus a une police < 16px. */
@supports (-webkit-touch-callout: none) {
  input, textarea, select { font-size: 16px; }
  #invoiceText { font-size: 16px; }
}

/* ── réorganisation PPRGB / sats ── */
#panel-receive { text-align: center; }
#panel-receive .hint { text-align: center; }
#panel-receive .qr { margin: 8px auto 16px; }
#panel-receive .secondary { width: 100%; }

#satsSide { margin: 4px 0 12px; }
.panel h2 .fuel {
  font-size: 10px;
  letter-spacing: .08em;
  color: var(--muted);
  vertical-align: middle;
}

.trade-helpers { display: flex; gap: 8px; margin-top: 8px; }
.mini-btn {
  background: transparent;
  border: 1px solid var(--line);
  color: var(--muted);
  border-radius: 10px;
  padding: 7px 10px;
  font: 600 11.5px inherit;
}
.mini-btn:active { transform: scale(.97); }

/* ── carnet ── */
.book {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 10px 12px;
  margin: 0 0 14px;
  background: #0a140e;
}
.book summary {
  cursor: pointer;
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
}
.book summary .fuel { margin-left: 4px; }
.book-side {
  margin-top: 9px;
  color: #5d7467;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: .08em;
}
.book-list { display: grid; gap: 5px; margin-top: 4px; }
.book-row {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 11.5px;
  font-variant-numeric: tabular-nums;
}
.book-row .vol { width: 74px; color: var(--text); }
.book-row .price { width: 48px; font-weight: 700; color: var(--text); }
.book-row .total { flex: 1; text-align: right; color: var(--muted); }
.book-row .mini-btn { padding: 5px 8px; font-size: 10.5px; }
.book-empty { color: #5d7467; font-size: 11px; }

.mini-btn:disabled { opacity: .3; }

/* ── séparation carnet / création d'ordre ── */
.trade-sep {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 18px 0 10px;
  color: var(--text);
  font-weight: 700;
  font-size: 13px;
}
.trade-sep::before,
.trade-sep::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--line);
}
.trade-sep span { flex: 0 0 auto; }

.order-row .status-ok { color: var(--green); }
.order-row .status-off { color: var(--muted); }
.order-row .status-err { color: var(--danger); }

/* ── performance perso ── */
.perf {
  background: #0a140e;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 12px 14px;
  margin: 12px 0 14px;
}
.perf-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.perf-head-right {
  display: flex;
  align-items: center;
  gap: 10px;
}
.perf-toggle {
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 999px;
  min-height: 30px;
  padding: 5px 10px;
  color: var(--muted);
  font-family: inherit;
  font-size: 11px;
  font-weight: 600;
  line-height: 1;
  cursor: pointer;
}
.perf-toggle:hover { color: var(--text); }
.perf.collapsed .perf-total { display: none; }
.perf.collapsed #perfBody { display: none; }
.perf-total {
  white-space: nowrap;
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -.02em;
  font-variant-numeric: tabular-nums;
}
.perf-total.ok { color: var(--green); }
.perf-total.err { color: var(--danger); }
.perf-detail {
  margin-top: 3px;
  color: var(--muted);
  font-size: 11.5px;
  font-variant-numeric: tabular-nums;
}
.perf-chart {
  margin-top: 10px;
  min-height: 56px;
  color: #5d7467;
  font-size: 11px;
}
.perf-chart svg { display: block; width: 100%; height: 64px; overflow: visible; }
.perf-chart:empty, .perf-pos:empty { display: none; }
.perf-pos {
  margin-top: 4px;
  color: var(--muted);
  font-size: 11.5px;
  font-variant-numeric: tabular-nums;
}
/* ── célébration de fill ── */
.celebrate {
  position: fixed;
  inset: 0;
  z-index: 90;
  pointer-events: none;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.celebrate[hidden] { display: none; }
.celebrate-card {
  background: rgba(9, 18, 12, .97);
  border: 1px solid #2c4a38;
  border-radius: 22px;
  padding: 22px 28px;
  text-align: center;
  box-shadow: 0 24px 70px rgba(0, 0, 0, .55);
  animation: celebrate-pop .45s cubic-bezier(.2, 1.4, .4, 1);
  position: relative;
  z-index: 2;
}
.celebrate-title {
  color: var(--muted);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .1em;
  font-weight: 700;
}
.celebrate-big {
  margin-top: 7px;
  font-size: 31px;
  font-weight: 800;
  letter-spacing: -.03em;
  color: var(--green);
  font-variant-numeric: tabular-nums;
}
.celebrate-card.purple .celebrate-big { color: var(--purple); }
.celebrate-small {
  margin-top: 6px;
  color: var(--muted);
  font-size: 12px;
  font-variant-numeric: tabular-nums;
}
.confetti-span {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 7px;
  height: 7px;
  border-radius: 2px;
  background: var(--c);
  opacity: .95;
  animation: celebrate-burst .95s ease-out forwards;
  transform: translate(-50%, -50%);
  z-index: 1;
}
@keyframes celebrate-burst {
  to {
    transform: translate(calc(-50% + var(--tx)), calc(-50% + var(--ty))) rotate(var(--r));
    opacity: 0;
  }
}
@keyframes celebrate-pop {
  from { transform: scale(.82); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

/* ── langue ── */
.lang-select {
  appearance: none;
  -webkit-appearance: none;
  width: auto;
  flex: 0 0 auto;
  background: var(--card);
  border: 1px solid var(--line);
  color: var(--text);
  border-radius: 999px;
  padding: 6px 10px;
  font-family: inherit;
  font-size: 16px;
  font-weight: 600;
  line-height: 1;
  outline: none;
}
.lang-top { display: flex; justify-content: flex-end; margin-bottom: 12px; }
.top-actions { display: flex; align-items: center; gap: 8px; }

.top .brand { flex: 0 0 auto; }
.brand .ver {
  font-style: normal;
  font-size: 9px;
  font-weight: 600;
  color: var(--muted);
  margin-left: 5px;
  cursor: pointer;
}
.verfoot { margin-top: 2px; opacity: .55; font-size: 9px; }
.top-actions { flex: 0 0 auto; }
