/* base.css: shared by every Hush page. Reset, type, controls, chrome, the crosshair frame. */
*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { overflow-x: clip; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0; min-height: 100dvh; background: var(--bg); background-image: var(--page-bg); background-attachment: fixed;
  color: var(--text); font: 400 var(--fs-md)/1.55 var(--font); -webkit-font-smoothing: antialiased; font-feature-settings: "ss01", "cv11";
}
img, svg, canvas { display: block; max-width: 100%; }
h1, h2, h3, h4, p { margin: 0; }
h1, h2, h3 { font-weight: 500; letter-spacing: -0.03em; line-height: 1.04; text-wrap: balance; overflow-wrap: break-word; min-width: 0; }
p { text-wrap: pretty; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; padding: 0; }
::selection { background: var(--accent); color: var(--ink); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: var(--r-sm); transition: none; }
.num, .tab { font-family: var(--font-mono); font-variant-numeric: tabular-nums; letter-spacing: -0.01em; }
/* every figure that can change keeps its width */
.prow, .srow, .tbl td, .ivfav button, .ohlc, kbd, .lv, .tr, .spr, .stats b, .stats em, .sl-thumb + *, .toast-t p { font-variant-numeric: tabular-nums; }
.vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip { position: absolute; left: 1rem; top: -4rem; z-index: 100; background: var(--accent); color: var(--ink); padding: var(--sp-8) var(--sp-14); border-radius: var(--r-sm); }
.skip:focus-visible { top: 1rem; }
.up { color: var(--up); } .dn { color: var(--down); }

/* container */
.wrap { width: min(100% - 2 * var(--gutter), var(--container)); margin-inline: auto; }

/* buttons */
.btn {
  --h: 44px; display: inline-flex; align-items: center; justify-content: center; gap: var(--sp-8); height: var(--h); padding: 0 var(--sp-16);
  border-radius: var(--r-pill); font-size: var(--fs-sm); font-weight: 500; white-space: nowrap; border: 1px solid var(--line-2); color: var(--text);
  transition: background-color var(--t-fast) var(--ease), border-color var(--t-fast) var(--ease), color var(--t-fast) var(--ease), transform var(--t-fast) var(--ease);
}
.btn:hover { border-color: var(--line-3); background: var(--accent-wash); }
.btn:active { transform: translateY(1px); }
.btn:disabled, .btn[aria-disabled="true"] { opacity: .5; cursor: not-allowed; transform: none; }
.btn.solid { background: var(--chrome); color: var(--ink); border-color: transparent; font-weight: 600; }
.btn.solid:hover { background: var(--accent-hi); }
.btn.sm { --h: 34px; padding: 0 var(--sp-14); font-size: var(--fs-xs); }
.btn .ic { width: 14px; height: 14px; flex: none; }
.mini { font-size: var(--fs-xs); padding: var(--sp-4) var(--sp-10); border-radius: var(--r-pill); border: 1px solid var(--line-2); color: var(--text-2); transition: border-color var(--t-fast) var(--ease), color var(--t-fast) var(--ease); }
.mini:hover { border-color: var(--line-3); color: var(--text); }
.mini:disabled { opacity: .5; cursor: not-allowed; }
.mini:active { transform: translateY(1px); }
.mini { display: inline-flex; align-items: center; gap: var(--sp-6); }

/* brand lockup */
.lock { display: inline-flex; align-items: center; gap: var(--sp-12); min-height: 36px; min-width: 36px; }
.lock img { width: 26px; height: auto; }
.lock span { font-weight: 400; font-size: 1.0625rem; letter-spacing: .42em; margin-right: -.42em; color: var(--text); }

/* nav */
.nav { position: sticky; top: 0; z-index: 40; height: var(--nav-h); background: transparent; border-bottom: 1px solid transparent;
  transition: background-color 200ms var(--ease), border-color 200ms var(--ease); }
/* past the first few pixels of scroll (and while the mobile menu is open) the header gets its glass and its hairline */
.nav.scrolled { background: color-mix(in srgb, var(--bg) 72%, transparent); border-bottom-color: var(--line); backdrop-filter: blur(14px) saturate(1.2); -webkit-backdrop-filter: blur(14px) saturate(1.2); }
.nav .wrap { height: 100%; display: flex; align-items: center; justify-content: space-between; gap: var(--sp-16); }
.nav-d { display: flex; align-items: center; gap: var(--sp-12); }
.nav-links { display: flex; gap: var(--sp-2); font-size: var(--fs-sm); color: var(--text-2); }
.nav-links a { display: inline-flex; align-items: center; height: 36px; padding: 0 var(--sp-12); border-radius: var(--r-pill); transition: color var(--t-fast) var(--ease), background-color var(--t-fast) var(--ease); }
.nav-links a:hover { color: var(--text); background: var(--accent-wash); }
.nav-links a[aria-current="page"] { color: var(--text); }
.nav-links a:active, .foot-links a:active { opacity: .8; }
.nav-toggle { display: none; place-items: center; width: 40px; height: 40px; border: 1px solid var(--line-2); border-radius: var(--r-pill); color: var(--text);
  transition: border-color var(--t-fast) var(--ease), background-color var(--t-fast) var(--ease); }
.nav-toggle:hover { border-color: var(--line-3); background: var(--accent-wash); }
.mti { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; max-width: none; }
.mti path { transform-origin: 12px 12px; transition: transform 300ms var(--ease), opacity 200ms var(--ease); }
.nav-toggle[aria-expanded="true"] .mti-a { transform: rotate(45deg) translateY(5px); }
.nav-toggle[aria-expanded="true"] .mti-b { opacity: 0; transform: scaleX(.2); }
.nav-toggle[aria-expanded="true"] .mti-c { transform: rotate(-45deg) translateY(-5px); }
/* the mobile menu: a sheet under the header, added to the page by nav.js */
.mmenu { position: fixed; inset: var(--nav-h) 0 0 0; z-index: 39; display: flex; flex-direction: column; overflow: hidden; border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--bg) 92%, transparent); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); }
.mmenu-in { flex: 1; display: flex; flex-direction: column; justify-content: space-between; gap: var(--sp-8); padding: var(--sp-16) var(--gutter) max(var(--sp-16), env(safe-area-inset-bottom));
  opacity: 0; transform: scale(.97); transition: opacity 200ms var(--ease), transform 200ms var(--ease); }
.mmenu.in .mmenu-in { opacity: 1; transform: none; }
.mmenu-links { display: grid; gap: var(--sp-4); }
.mmenu-links a { display: flex; align-items: center; min-height: 48px; padding: 0 var(--sp-14); border-radius: var(--r-md); font-size: var(--fs-md); color: var(--text-2); transition: background-color var(--t-fast) var(--ease), color var(--t-fast) var(--ease); }
.mmenu-links a:hover, .mmenu-links a[aria-current="page"] { background: var(--accent-wash); color: var(--text); }
.mmenu-cta { display: grid; gap: var(--sp-8); }
.mmenu-cta .btn { width: 100%; --h: 48px; }
@media (max-width: 820px) { .nav-d { display: none; } .nav-toggle { display: grid; } }
@media (min-width: 821px) { .mmenu { display: none; } }

/* the crosshair frame: hairline grid with a + at every intersection.
   The frame draws top, left and right; each block inside draws its own bottom line. */
.frame { position: relative; border: 1px solid var(--line); border-bottom: 0; }
.cross, .cell::after, .cells.c3 > .cell:nth-child(3n+1)::before, .cells.c2 > .cell:nth-child(2n+1)::before, .cells.c4 > .cell:nth-child(4n+1)::before { content: ""; position: absolute; width: 13px; height: 13px; pointer-events: none; z-index: 2;
  background: linear-gradient(var(--line-3), var(--line-3)) center / 1px 100% no-repeat, linear-gradient(var(--line-3), var(--line-3)) center / 100% 1px no-repeat; }
.frame > .cross.tl { left: -7px; top: -7px; } .frame > .cross.tr { right: -7px; top: -7px; }
.frame > .cross.ml { left: -7px; } .frame > .cross.mr { right: -7px; }
.cells { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.cells.c2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.cells.c4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.cell { position: relative; padding: clamp(1.25rem, 1rem + 1vw, 2rem); border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); min-width: 0; }
.cell::after { right: -7px; bottom: -7px; }
.cells > .cell::before { left: -7px; bottom: -7px; }
.cells.c3 > .cell:nth-child(3n), .cells.c2 > .cell:nth-child(2n), .cells.c4 > .cell:nth-child(4n), .cells > .cell.last { border-right: 0; }
.blk { position: relative; border-bottom: 1px solid var(--line); }
@media (max-width: 860px) {
  .cells, .cells.c2, .cells.c4 { grid-template-columns: minmax(0, 1fr); }
  .cells > .cell { border-right: 0; }
  .cell::before { content: ""; position: absolute; left: -7px; bottom: -7px; width: 13px; height: 13px; pointer-events: none; z-index: 2;
    background: linear-gradient(var(--line-3), var(--line-3)) center / 1px 100% no-repeat, linear-gradient(var(--line-3), var(--line-3)) center / 100% 1px no-repeat; }
}

/* section head */
.shead { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: var(--sp-32); align-items: end; padding: clamp(2rem, 1.4rem + 2.4vw, 3.5rem) clamp(1.25rem, 1rem + 1vw, 2rem); border-bottom: 1px solid var(--line); }
.shead h2 { font-size: var(--fs-3xl); }
.shead p { color: var(--text-2); max-width: 46ch; justify-self: end; }
.step { display: block; font-family: var(--font-mono); font-size: var(--fs-xs); color: var(--text-3); margin-bottom: var(--sp-16); }
@media (max-width: 860px) { .shead { grid-template-columns: minmax(0, 1fr); } .shead p { justify-self: start; } }

/* tags */
.tag { display: inline-flex; align-items: center; gap: var(--sp-6); font-size: .75rem; line-height: 1; padding: var(--sp-4) var(--sp-8); border-radius: var(--r-pill); border: 1px solid var(--line-2); color: var(--text-2); white-space: nowrap; }
.tag.sample { border-style: dashed; border-color: var(--line-3); color: var(--text-2); }

/* monogram coin avatar (no remote logos) */
.mono { --h: 160; display: inline-grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; flex: none; font: 600 9px/1 var(--font); letter-spacing: 0; font-style: normal;
  background: hsl(var(--h) 38% 22%); color: hsl(var(--h) 70% 82%); box-shadow: inset 0 0 0 1px hsl(var(--h) 50% 40% / .5); }
.mono.logo { background: #fff1; box-shadow: none; object-fit: contain; }
.mono.gen { background: var(--surface-3); color: var(--text-2); box-shadow: inset 0 0 0 1px var(--line-2); }

/* footer */
.foot { border-top: 1px solid var(--line); margin-top: clamp(3rem, 2rem + 4vw, 6rem); padding: var(--sp-48) 0 var(--sp-40); color: var(--text-2); font-size: var(--fs-sm); }
.foot .wrap { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 2fr) auto; gap: var(--sp-40); align-items: start; }
.foot .lock { margin-bottom: var(--sp-16); }
.foot-links { display: grid; gap: var(--sp-10); }
.foot-links { gap: 0; }
.foot-links a { display: inline-flex; align-items: center; min-height: 36px; transition: color var(--t-fast) var(--ease); } .foot-links a:hover { color: var(--text); }
@media (pointer: coarse) { .foot-links a { min-height: 44px; } }
.truth { font-size: var(--fs-xs); line-height: 1.6; color: var(--text-3); max-width: 72ch; }
.truth strong { color: var(--text-2); font-weight: 500; }
@media (max-width: 860px) { .foot .wrap { grid-template-columns: minmax(0, 1fr); } }

/* wallet modal (wallet.js) */
.modal { position: fixed; inset: 0; z-index: 90; display: none; place-items: center; background: var(--scrim); backdrop-filter: blur(6px); padding: var(--sp-16); }
.modal.on { display: grid; }
.mbox { width: min(420px, 100%); background: var(--surface-2); border: 1px solid var(--line-2); border-radius: var(--r-md); padding: var(--sp-24); display: grid; gap: var(--sp-16); }
.mbox h3 { font-size: var(--fs-xl); }
.mbox p { color: var(--text-2); font-size: var(--fs-sm); }
.wl { display: grid; gap: var(--sp-8); }
.wl button { display: flex; align-items: center; gap: var(--sp-12); padding: var(--sp-12) var(--sp-14); border-radius: var(--r-md); border: 1px solid var(--line-2); text-align: left; transition: border-color var(--t-fast) var(--ease), background-color var(--t-fast) var(--ease); }
.wl button:hover { border-color: var(--line-3); background: var(--accent-wash); }
.wl img { width: 24px; height: 24px; border-radius: var(--r-sm); }
.wl em { margin-left: auto; font-style: normal; font-size: var(--fs-xs); color: var(--text-3); }
.wl .wic { display: grid; place-items: center; width: 24px; height: 24px; border-radius: var(--r-sm); background: var(--surface-3); color: var(--text-2); }
.wl button:disabled { opacity: .6; }
.wl .ic.spin { margin-left: auto; color: var(--text-2); }
.winstall { display: grid; gap: var(--sp-8); }
.winstall a { display: flex; align-items: center; gap: var(--sp-12); padding: var(--sp-10) var(--sp-14); border-radius: var(--r-md); border: 1px solid var(--line-2); transition: border-color var(--t-fast) var(--ease), background-color var(--t-fast) var(--ease); }
.winstall a:hover { border-color: var(--line-3); background: var(--accent-wash); }
.winstall a:active { transform: translateY(1px); }
.winstall img { width: 24px; height: 24px; }
.winstall .ic { margin-left: auto; color: var(--text-3); }
.wnone { color: var(--text-2); font-size: var(--fs-sm); }
.mx { justify-self: start; }

/* toasts (toast.js) */
.toaster { position: fixed; right: 1rem; bottom: 1rem; z-index: 95; display: grid; gap: var(--sp-8); width: min(380px, calc(100vw - 2rem)); pointer-events: none; }
.toast { --tc: var(--accent); pointer-events: auto; position: relative; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: var(--sp-12); align-items: start;
  padding: var(--sp-14) var(--sp-12) var(--sp-14) var(--sp-16); border-radius: var(--r-md); border: 1px solid var(--line-2); background: color-mix(in srgb, var(--surface-3) 92%, transparent);
  backdrop-filter: blur(12px); box-shadow: var(--shadow-pop); font-size: var(--fs-sm);
  opacity: 0; transform: translateY(8px); transition: opacity 200ms var(--ease), transform 200ms var(--ease); }
.toast.in { opacity: 1; transform: none; }
.toast.out { opacity: 0; transform: translateY(6px); }
.toast > .ic { color: var(--tc); margin-top: 2px; }
.toast.error { --tc: var(--down); } .toast.info, .toast.loading { --tc: var(--text-2); }
.toast-t b { display: block; font-weight: 500; color: var(--text); }
.toast-t p { margin-top: var(--sp-2); color: var(--text-2); font-size: var(--fs-xs); line-height: 1.5; }
.toast-x { display: grid; place-items: center; width: 24px; height: 24px; margin: -2px -2px 0 0; border-radius: var(--r-sm); color: var(--text-3); transition: color var(--t-fast) var(--ease), background-color var(--t-fast) var(--ease); }
.toast-x:hover { color: var(--text); background: var(--accent-wash); }
.toast-x:active { transform: translateY(1px); }

/* icons (icons.js): Lucide, stroke 1.75, sizes 14/16/20 */
.ic { display: inline-block; flex: none; vertical-align: middle; }
.spin { animation: spin 900ms linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* tooltip (ui.js) */
.tip { position: fixed; left: 0; top: 0; z-index: 99; max-width: 260px; padding: var(--sp-8) var(--sp-10); border-radius: var(--r-sm); border: 1px solid var(--line-2);
  background: var(--surface-3); color: var(--text); font-size: var(--fs-xs); line-height: 1.45; pointer-events: none; opacity: 0; transition: opacity 150ms var(--ease); }
.tip.on { opacity: 1; }
[data-tip] { cursor: help; }
button[data-tip], a[data-tip] { cursor: pointer; }

/* copy button (ui.js) */
.copy { display: inline-grid; place-items: center; width: 26px; height: 26px; border-radius: var(--r-sm); color: var(--text-3); flex: none;
  transition: color var(--t-fast) var(--ease), background-color var(--t-fast) var(--ease); }
.copy:hover { color: var(--text); background: var(--accent-wash); }
.copy:active { transform: translateY(1px); }
.copy.done { color: var(--up); }

/* slider (ui.js) */
.slider { --f: 25%; position: relative; display: block; height: 32px; cursor: pointer; touch-action: none; border-radius: var(--r-sm); }
.sl-track { position: absolute; left: 8px; right: 8px; top: 14px; height: 4px; border-radius: var(--r-sm); background: var(--line-2); }
.sl-fill { position: absolute; inset: 0 auto 0 0; width: var(--f); border-radius: inherit; background: var(--accent); }
.sl-thumb { position: absolute; top: 8px; left: calc(8px + (100% - 16px) * var(--fp, .25)); width: 16px; height: 16px; margin-left: -8px; border-radius: 50%;
  background: var(--accent-hi); border: 3px solid var(--ink); box-shadow: 0 0 0 1px var(--accent); transition: transform 150ms var(--ease); }
.slider:hover .sl-thumb, .slider.drag .sl-thumb { transform: scale(1.12); }
.slider:focus-visible { outline-offset: 4px; }

/* skeletons: shaped like what loads */
.sk { display: block; height: .75rem; border-radius: var(--r-sm); background: linear-gradient(90deg, var(--surface-2) 30%, var(--surface-3) 50%, var(--surface-2) 70%); background-size: 220% 100%; animation: sk 1.3s linear infinite; }
.sk.round { border-radius: 50%; }
@keyframes sk { from { background-position: 120% 0; } to { background-position: -120% 0; } }

/* plain buttons: hover, press, disabled */
button:not(.btn):not(:disabled):active { transform: translateY(1px); }
button:disabled { cursor: not-allowed; opacity: .55; }
[aria-busy="true"] { cursor: progress; }
.btn .ic { margin-left: calc(-1 * var(--sp-2)); }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 1ms !important; animation-iteration-count: 1 !important; transition-duration: 1ms !important; }
}
.tag { font-style: normal; }
.dim { color: var(--text-3); }


/* ---------- Hush: neon ---------- */
h1, h2, h3 { font-family: var(--font); font-weight: 600; letter-spacing: -0.035em; line-height: 1.02; }
/* the lit words: a cold white core with a blue halo, like a tube */
.tone { color: #D9E6FF; text-shadow: 0 0 6px rgba(169, 196, 255, .65), 0 0 22px rgba(77, 134, 255, .75), 0 0 46px rgba(43, 91, 255, .45); }
.btn, .nav-links a, .nav-toggle { border-radius: var(--r-pill); }
.mini, .tag { border-radius: var(--r-sm); }
/* the main action is a neon tube: lit border, inner glow, outer halo */
.btn.solid { background: rgba(77, 134, 255, .16); color: #EEF3FF; border: 1.5px solid #8FB0FF; text-shadow: 0 0 8px rgba(169, 196, 255, .8);
  box-shadow: 0 0 0 1px rgba(77, 134, 255, .35), 0 0 22px rgba(77, 134, 255, .55), inset 0 0 14px rgba(77, 134, 255, .4); }
.btn.solid:hover { background: rgba(77, 134, 255, .26); filter: none; box-shadow: 0 0 0 1px rgba(77, 134, 255, .5), 0 0 34px rgba(77, 134, 255, .75), inset 0 0 18px rgba(77, 134, 255, .5); }
.lock img { width: 28px; height: 28px; filter: drop-shadow(0 0 6px rgba(77, 134, 255, .85)); }
.lock span { font: 500 1.0625rem/1 var(--font); letter-spacing: .42em; margin-right: -.42em; }
/* points of light where the hairlines cross */
.cross, .cell::after, .cells.c3 > .cell:nth-child(3n+1)::before, .cells.c2 > .cell:nth-child(2n+1)::before, .cells.c4 > .cell:nth-child(4n+1)::before,
.cells > .cell::before { width: 5px; height: 5px; margin: 4px 0 0 4px; border-radius: 50%; background: #A9C4FF !important; box-shadow: 0 0 8px 1px rgba(77, 134, 255, .9); }
/* sections numbered quietly */
main { counter-reset: part; }
.frame .shead { counter-increment: part; }
.frame .shead h2::before, .frame .shead h1::before { content: counter(part, decimal-leading-zero); display: block; margin-bottom: var(--sp-16); font: 500 var(--fs-xs)/1 var(--font-mono); letter-spacing: .14em; color: var(--accent-hi); text-shadow: 0 0 10px rgba(77, 134, 255, .8); }
