/* naoj — système visuel
   Bleu nuit très sombre + un seul accent or. Le caractère vient du vocabulaire
   et d'un unique ancrage visuel, jamais de la texture. */

:root {
  color-scheme: dark;

  --bg:        #07090e;
  --bg-deep:   #05060a;
  --surface:   #0e121b;
  --surface-2: #141926;
  --line:      #1b2130;
  --line-soft: #141926;

  --ink:       #e9ecf3;
  --ink-mute:  #8b95ab;
  --ink-faint: #5a6377;

  --gold:      #d9a94c;
  --gold-hi:   #f0c469;
  --gold-dim:  rgba(217, 169, 76, .12);

  --up:        #3fb950;
  --down:      #f0564a;

  --r:         14px;
  --r-sm:      9px;
  --mono:      ui-monospace, "SF Mono", "JetBrains Mono", "Cascadia Code", Menlo, monospace;
  --sans:      ui-sans-serif, system-ui, -apple-system, "Segoe UI", Inter, sans-serif;
}

* { box-sizing: border-box }

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--ink);
  font: 400 15px/1.65 var(--sans);
  -webkit-font-smoothing: antialiased;
  /* une seule lueur, très basse, pour ne pas faire "SaaS dégradé" */
  background-image:
    radial-gradient(900px 500px at 50% -10%, rgba(217,169,76,.055), transparent 70%),
    radial-gradient(700px 400px at 90% 100%, rgba(217,169,76,.02), transparent 70%);
  background-attachment: fixed;
}

.wrap { max-width: 980px; margin: 0 auto; padding: 0 24px }

/* ---------------------------------------------------------------- en-tête */

header.top {
  display: flex; align-items: center; justify-content: space-between;
  padding: 22px 0 0;
}
.brand { display: flex; align-items: center; gap: 11px; text-decoration: none; color: var(--ink) }/* marque nue : ni fond ni contour, le crâne se suffit */
.brand { line-height: 1 }
.brand .mark {
  width: 30px; height: 30px;
  display: flex; align-items: center; justify-content: center;
  color: #fff;
}
.brand .mark svg { width: 30px; height: 30px; display: block }
.brand .name {
  font-weight: 600; letter-spacing: -.015em; font-size: 18px;
  line-height: 1; display: block;
  position: relative; top: .5px;   /* recalage optique sur l'axe du crâne */
}
.brand .name em { font-style: normal; color: var(--gold) }

nav.top-nav { display: flex; align-items: center; gap: 26px }
nav.top-nav a {
  color: var(--ink-mute); text-decoration: none; font-size: 14px;
  transition: color .15s;
}
nav.top-nav a:hover, nav.top-nav a[aria-current] { color: var(--ink) }

/* ---------------------------------------------------------------- boutons */

.btn {
  appearance: none; border: 1px solid var(--line); background: var(--surface);
  color: var(--ink); font: 500 14px/1 var(--sans); letter-spacing: -.01em;
  padding: 10px 16px; border-radius: var(--r-sm); cursor: pointer;
  display: inline-flex; align-items: center; gap: 8px;
  transition: border-color .15s, background .15s, transform .08s;
}
.btn:hover { border-color: #2a3346; background: var(--surface-2) }
.btn:active { transform: translateY(1px) }
.btn-gold {
  background: var(--gold); border-color: var(--gold); color: #0d0a04; font-weight: 600;
}
.btn-gold:hover { background: var(--gold-hi); border-color: var(--gold-hi) }
.btn .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--up) }

/* ---------------------------------------------------------------- héros */

.hero { padding: 76px 0 54px; max-width: 640px }
.hero h1 {
  margin: 0 0 16px; font-size: clamp(30px, 5.2vw, 46px); line-height: 1.08;
  letter-spacing: -.03em; font-weight: 650;
}
.hero h1 .gold { color: var(--gold) }
.hero p { margin: 0; color: var(--ink-mute); font-size: 17px; max-width: 50ch }

.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font: 500 12px/1 var(--sans); letter-spacing: .09em; text-transform: uppercase;
  color: var(--gold); background: var(--gold-dim);
  border: 1px solid rgba(217,169,76,.2);
  padding: 7px 12px; border-radius: 100px; margin-bottom: 22px;
}

/* ---------------------------------------------------------------- grille d'apps */

.section-label {
  font: 500 12px/1 var(--sans); letter-spacing: .09em; text-transform: uppercase;
  color: var(--ink-faint); margin: 0 0 18px;
}
.apps { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 14px }

.app {
  display: block; text-decoration: none; color: inherit;
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--r); padding: 22px;
  transition: border-color .16s, background .16s, transform .16s;
  position: relative;
}
.app:not(.soon):hover { border-color: rgba(217,169,76,.4); background: var(--surface-2); transform: translateY(-2px) }
.app.soon { opacity: .5; cursor: default }

.app .head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px }
.app h3 { margin: 0; font-size: 16px; font-weight: 600; letter-spacing: -.015em }
.app p { margin: 0; color: var(--ink-mute); font-size: 14px; line-height: 1.55 }

.tag {
  font: 600 10px/1 var(--sans); letter-spacing: .08em; text-transform: uppercase;
  padding: 5px 8px; border-radius: 5px;
}
.tag.live  { color: var(--up);   background: rgba(63,185,80,.1);  border: 1px solid rgba(63,185,80,.22) }
.tag.soon  { color: var(--ink-faint); background: #10141d; border: 1px solid var(--line) }

/* ---------------------------------------------------------------- outil */

.tool { padding: 46px 0 0 }
.field { display: flex; gap: 10px; margin: 26px 0 0 }
.field input {
  flex: 1; background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--r-sm); padding: 14px 16px;
  color: var(--ink); font: 400 14px/1 var(--mono);
  transition: border-color .15s;
}
.field input::placeholder { color: var(--ink-faint) }
.field input:focus { outline: none; border-color: rgba(217,169,76,.5) }
.hint { margin: 10px 0 0; color: var(--ink-faint); font-size: 13px }

/* ---------------------------------------------------------------- résultat */

.result { margin: 34px 0 0; border: 1px solid var(--line); border-radius: var(--r); overflow: hidden }
.result .figure {
  padding: 34px 28px; text-align: center;
  background: linear-gradient(180deg, var(--surface), var(--bg-deep));
  border-bottom: 1px solid var(--line);
}
.figure .label { font-size: 12px; letter-spacing: .09em; text-transform: uppercase; color: var(--ink-faint); margin-bottom: 12px }
.figure .big {
  font: 650 clamp(38px, 8vw, 62px)/1 var(--sans); letter-spacing: -.035em;
  font-variant-numeric: tabular-nums;
}
.figure .big.up { color: var(--up) } .figure .big.down { color: var(--down) }
.figure .sub { margin-top: 10px; color: var(--ink-mute); font-size: 15px; font-variant-numeric: tabular-nums }

.compare { padding: 20px 28px; background: var(--surface); border-bottom: 1px solid var(--line) }
.compare .row { display: flex; align-items: baseline; justify-content: space-between; padding: 7px 0; font-size: 14px }
.compare .row + .row { border-top: 1px solid var(--line-soft) }
.compare .k { color: var(--ink-mute) }
.compare .v { font-family: var(--mono); font-variant-numeric: tabular-nums }
.compare .v.gold { color: var(--gold); font-weight: 600 }
.compare .note { margin: 14px 0 0; padding-top: 14px; border-top: 1px solid var(--line-soft); color: var(--ink-faint); font-size: 13px; line-height: 1.6 }

details.log { background: var(--bg-deep) }
details.log summary {
  padding: 15px 28px; cursor: pointer; color: var(--ink-mute); font-size: 14px;
  list-style: none; display: flex; align-items: center; gap: 9px;
}
details.log summary::-webkit-details-marker { display: none }
details.log summary::before { content: "▸"; color: var(--ink-faint); transition: transform .15s }
details.log[open] summary::before { transform: rotate(90deg) }
details.log summary:hover { color: var(--ink) }
.ledger { padding: 4px 28px 24px; font-family: var(--mono); font-size: 12.5px; line-height: 1.85; color: var(--ink-mute) }
.ledger .ln { display: flex; gap: 14px; white-space: nowrap; overflow-x: auto }
.ledger .t { color: var(--ink-faint) }
.ledger .n { color: var(--ink); font-variant-numeric: tabular-nums; min-width: 105px; text-align: right }
.ledger .n.up { color: var(--up) } .ledger .n.down { color: var(--down) }

/* ---------------------------------------------------------------- pied */

footer.bot {
  margin-top: 84px; border-top: 1px solid var(--line); padding: 26px 0 40px;
  display: flex; align-items: center; justify-content: space-between;
  color: var(--ink-faint); font-size: 13px;
}
footer.bot a { color: var(--ink-mute); text-decoration: none }
footer.bot a:hover { color: var(--gold) }

@media (max-width: 620px) {
  nav.top-nav { gap: 16px }
  nav.top-nav .hide-sm { display: none }
  .field { flex-direction: column }
  footer.bot { flex-direction: column; gap: 12px; text-align: center }
}

/* ---------------------------------------------------------------- wallet */

.btn:disabled { opacity: .55; cursor: default }
.btn-sm { padding: 7px 12px; font-size: 13px }
.btn-quiet { background: transparent; border-color: transparent; color: var(--ink-mute) }
.btn-quiet:hover { color: var(--down); background: transparent; border-color: transparent }
.btn-wallet { font-family: var(--mono); font-size: 13px }
.btn .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--up); flex: none }
.btn .dot.pending { background: var(--gold) }

.wallet-menu { position: relative }
.menu {
  position: absolute; right: 0; top: calc(100% + 9px); width: 290px; z-index: 40;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r);
  box-shadow: 0 18px 50px rgba(0,0,0,.6); padding: 16px;
}
.menu[hidden] { display: none }
.menu-head { padding-bottom: 13px; margin-bottom: 13px; border-bottom: 1px solid var(--line) }
.menu-head .addr { font-family: var(--mono); font-size: 11px; color: var(--ink-mute); word-break: break-all; line-height: 1.5 }
.menu-head .status { margin-top: 7px; font-size: 12px; color: var(--gold) }
.menu-field { display: block; margin-bottom: 11px }
.menu-field span { display: block; font-size: 12px; color: var(--ink-faint); margin-bottom: 5px }
.menu-field input {
  width: 100%; background: var(--bg-deep); border: 1px solid var(--line);
  border-radius: 7px; padding: 9px 11px; color: var(--ink); font: 400 13px/1 var(--sans);
}
.menu-field input:focus { outline: none; border-color: rgba(217,169,76,.45) }
.menu-actions { display: flex; gap: 8px; justify-content: space-between; margin-top: 14px }

/* ---------------------------------------------------------------- retours */

.fb-open {
  position: fixed; right: 20px; bottom: 20px; z-index: 30;
  background: var(--surface); border: 1px solid var(--line); color: var(--ink-mute);
  border-radius: 100px; padding: 10px 16px; font: 500 13px/1 var(--sans); cursor: pointer;
  display: inline-flex; align-items: center; gap: 8px;
  transition: color .15s, border-color .15s, transform .12s;
}
.fb-open:hover { color: var(--ink); border-color: rgba(217,169,76,.4); transform: translateY(-1px) }

#fb {
  position: fixed; inset: 0; z-index: 50; background: rgba(3,4,7,.72);
  backdrop-filter: blur(3px); display: grid; place-items: center; padding: 22px;
}
#fb[hidden] { display: none }
.fb-card {
  width: min(460px, 100%); background: var(--surface);
  border: 1px solid var(--line); border-radius: var(--r); padding: 24px;
}
.fb-card h3 { margin: 0 0 6px; font-size: 17px; font-weight: 600; letter-spacing: -.015em }
.fb-card p.sub { margin: 0 0 18px; color: var(--ink-mute); font-size: 14px }
.fb-card textarea, .fb-card input {
  width: 100%; background: var(--bg-deep); border: 1px solid var(--line);
  border-radius: var(--r-sm); padding: 12px 14px; color: var(--ink);
  font: 400 14px/1.6 var(--sans); resize: vertical;
}
.fb-card textarea { min-height: 130px; margin-bottom: 11px }
.fb-card input:focus, .fb-card textarea:focus { outline: none; border-color: rgba(217,169,76,.45) }
.fb-actions { display: flex; gap: 9px; justify-content: flex-end; margin-top: 16px }

/* ---------------------------------------------------------------- toast */

#toast {
  position: fixed; left: 50%; bottom: 26px; transform: translate(-50%, 14px);
  background: var(--surface-2); border: 1px solid var(--line); color: var(--ink);
  padding: 12px 18px; border-radius: 100px; font-size: 14px; z-index: 60;
  opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s;
  box-shadow: 0 14px 40px rgba(0,0,0,.5);
}
#toast.on { opacity: 1; transform: translate(-50%, 0) }

/* ---------------------------------------------------------------- pied */

footer.bot { line-height: 1 }
footer.bot .x-link { display: inline-flex; align-items: center; gap: 7px; line-height: 1 }
footer.bot .x-link svg { width: 13px; height: 13px; fill: currentColor; display: block; flex: none }


/* ---------------------------------------------------------------- choix du wallet */

#wmodal {
  position: fixed; inset: 0; z-index: 50; background: rgba(3,4,7,.72);
  backdrop-filter: blur(3px); display: grid; place-items: center; padding: 22px;
}
#wmodal[hidden] { display: none }

#wpick { display: flex; flex-direction: column; gap: 8px; margin: 4px 0 2px }
.wrow {
  display: flex; align-items: center; gap: 11px; width: 100%; text-align: left;
  background: var(--bg-deep); border: 1px solid var(--line); border-radius: var(--r-sm);
  padding: 12px 14px; color: var(--ink); font: 500 14px/1 var(--sans); cursor: pointer;
  transition: border-color .15s, background .15s;
}
.wrow:hover:not(:disabled) { border-color: rgba(217,169,76,.45); background: var(--surface-2) }
.wrow:disabled { opacity: .45; cursor: default }
.wrow.busy { border-color: rgba(217,169,76,.6) }
.wrow img { border-radius: 5px; flex: none }
.wdot { width: 22px; height: 22px; border-radius: 6px; background: var(--surface-2); flex: none }
.wname { flex: 1 }
.wtag {
  font: 600 9px/1 var(--sans); letter-spacing: .08em; text-transform: uppercase;
  color: var(--gold); background: var(--gold-dim); border: 1px solid rgba(217,169,76,.22);
  padding: 4px 7px; border-radius: 4px;
}
.wpick-empty { margin: 6px 0 2px; color: var(--ink-mute); font-size: 14px; line-height: 1.65 }
