@font-face { font-family: "Epilogue"; src: url("/fonts/epilogue.woff2") format("woff2"); font-weight: 100 900; font-display: swap; }
@font-face { font-family: "Fira Code"; src: url("/fonts/fira-code.woff2") format("woff2"); font-weight: 300 700; font-display: swap; }

:root {
  --paper: #eef8f5;
  --paper-2: #e2f1ec;
  --ink: #0b090a;
  --ink-2: #3f3b3d;
  --ink-3: #6b6669;
  --mint: #b8f2e6;
  --mint-2: #8fe0cf;
  --teal: #17695c;
  --bad: #9b2c2c;
  --rule: rgba(11, 9, 10, 0.13);
  --grid: rgba(23, 105, 92, 0.07);
  --sans: "Epilogue", ui-sans-serif, system-ui, sans-serif;
  --mono: "Fira Code", ui-monospace, "SFMono-Regular", Menlo, monospace;
  --ease: cubic-bezier(0.2, 0.8, 0.2, 1);
  color-scheme: light;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 80px; }
body {
  margin: 0; min-height: 100vh; display: flex; flex-direction: column;
  font: 400 1rem/1.6 var(--sans); color: var(--ink); background-color: var(--paper);
  background-image: linear-gradient(var(--grid) 1px, transparent 1px), linear-gradient(90deg, var(--grid) 1px, transparent 1px);
  background-size: 32px 32px; background-position: -1px -1px;
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
a { color: var(--teal); text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
code, .mono { font-family: var(--mono); font-size: 0.9em; }
button { font: inherit; color: inherit; cursor: pointer; }
:focus-visible { outline: 2px solid var(--teal); outline-offset: 3px; border-radius: 4px; }
[hidden] { display: none !important; }
main:focus, main:focus-visible { outline: none; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: var(--paper); padding: 8px 12px; border-radius: 6px; z-index: 50; }
.skip:focus { left: 8px; }
.muted { color: var(--ink-3); }
h1, h2, h3 { font-family: var(--sans); line-height: 1.08; margin: 0; letter-spacing: -0.02em; text-wrap: balance; }
h2 { font-size: clamp(1.6rem, 1.2rem + 1.6vw, 2.4rem); font-weight: 750; }
h3 { font-size: 1.12rem; font-weight: 700; letter-spacing: -0.01em; }

/* ---------- header / footer ---------- */
.top {
  position: sticky; top: 0; z-index: 20; display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 12px clamp(16px, 4vw, 48px); background: rgba(238, 248, 245, 0.88); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--rule);
}
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; font-weight: 800; font-size: 1.25rem; letter-spacing: -0.03em; }
.brand-mark { width: 34px; height: 34px; color: var(--ink); }
.mark-dot { fill: var(--mint); }
.nav { display: flex; align-items: center; gap: 4px; }
.nav a { color: var(--ink); text-decoration: none; padding: 8px 10px; border-radius: 8px; font-weight: 550; font-size: 0.95rem; }
.nav a:hover { background: var(--paper-2); }
.keychip { border: 1px solid var(--ink); background: var(--mint); border-radius: 999px; padding: 5px 12px; font: 500 0.8rem var(--mono); white-space: nowrap; transition: transform 0.15s var(--ease); }
.keychip:active { transform: scale(0.96); }
.xbtn { display: inline-grid; place-items: center; width: 38px; height: 38px; padding: 0 !important; }
.xbtn svg { width: 17px; height: 17px; fill: var(--ink); }
main { flex: 1; width: 100%; max-width: 1180px; margin: 0 auto; padding: 0 clamp(16px, 4vw, 48px); outline: none; }
.foot { border-top: 1px solid var(--rule); margin-top: 72px; font-size: 0.88rem; color: var(--ink-2); background: var(--paper); }
.foot-in { max-width: 1180px; margin: 0 auto; padding: 24px clamp(16px, 4vw, 48px) 32px; display: flex; flex-wrap: wrap; gap: 10px 24px; align-items: center; justify-content: space-between; }
.foot-brand { display: inline-flex; align-items: center; gap: 8px; font-weight: 750; color: var(--ink); }
.foot-brand svg { width: 22px; height: 22px; color: var(--ink); }
.foot nav { display: flex; gap: 16px; }

/* ---------- hero ---------- */
.hero { display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px 48px; padding: clamp(28px, 6vw, 72px) 0 24px; }
.hero-copy h1 { font-size: clamp(2.05rem, 1.2rem + 4.2vw, 4.4rem); font-weight: 800; letter-spacing: -0.035em; line-height: 1.0; max-width: 15ch; }
.lede { font-size: clamp(1.02rem, 0.95rem + 0.35vw, 1.2rem); color: var(--ink-2); max-width: 54ch; margin: 18px 0 0; }
.stage { position: relative; margin: 8px -8px 0; }
.stage-art { aspect-ratio: 600 / 400; width: 100%; }
.stage-note { margin: 0 8px; font: 400 0.8rem/1.4 var(--mono); color: var(--ink-3); }
@media (min-width: 960px) {
  .hero { grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); grid-template-areas: "copy stage" "form stage"; align-items: start; }
  .hero-copy { grid-area: copy; }
  .stage { grid-area: stage; align-self: center; margin: 0; }
  .search { grid-area: form; }
}

/* the diagram */
.venn { width: 100%; height: 100%; display: block; touch-action: none; user-select: none; -webkit-user-select: none; overflow: visible; }
.venn .lens { fill: var(--mint); }
.venn .ring { fill: none; stroke: var(--ink); stroke-width: 1.6; }
.venn .ring.held { stroke-width: 2.6; }
.venn .ring-1 { stroke-dasharray: none; }
.venn .ring-2 { stroke-dasharray: 7 5; }
.venn .ring-3 { stroke-dasharray: 2 5; stroke-linecap: round; }
.venn .ring-4 { stroke-dasharray: 14 4 2 4; }
.venn .ring { transition: stroke-width 0.2s var(--ease); }
.venn .hit { fill: transparent; cursor: grab; outline: none; }
.venn.dragging .hit { cursor: grabbing; }
.venn .hit:focus-visible { stroke: var(--teal); stroke-width: 2; stroke-dasharray: 3 4; }
.venn .letter { font: 750 26px var(--sans); fill: var(--ink); pointer-events: none; }
.venn .setlabel { font: 600 19px var(--mono); fill: var(--ink); pointer-events: none; paint-order: stroke; stroke: var(--mint); stroke-width: 6px; transition: opacity 0.2s; }
.venn .setlabel.gone { opacity: 0; }
.venn .mark { fill: var(--paper); stroke: rgba(11, 9, 10, 0.35); stroke-width: 1; transform-box: fill-box; transform-origin: center; transition: transform 0.25s var(--ease), fill 0.2s; }
.venn .mark.on { fill: var(--ink); stroke: var(--ink); transform: scale(1.35); }
.venn .ring-0.enter, .venn .ring-1.enter { stroke-dasharray: 956; animation: draw 1.1s var(--ease) both; }
.venn .ring-1.enter { animation-delay: 0.12s; }
.venn .ring-2.enter, .venn .ring-3.enter, .venn .ring-4.enter { transform-box: fill-box; transform-origin: center; animation: pop 0.55s var(--ease) both; }
@keyframes pop { from { opacity: 0; transform: scale(0.82); } }
.venn.anim .lens { animation: fade 0.7s 0.6s var(--ease) both; }
@keyframes draw { from { stroke-dashoffset: 956; } to { stroke-dashoffset: 0; } }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
.venn.busy .lens { animation: breathe 1.6s ease-in-out infinite; }
@keyframes breathe { 50% { opacity: 0.45; } }

/* the form */
.search { margin-top: 8px; padding: 18px; background: var(--paper); border: 1px solid var(--ink); border-radius: 14px; box-shadow: 4px 4px 0 var(--ink); }
.rows { display: grid; gap: 10px; }
.row { display: flex; align-items: center; gap: 10px; }
.tag { flex: none; display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; border: 1.6px solid var(--ink); font-weight: 750; font-size: 0.95rem; background: var(--paper); color: var(--ink); }
.tag.small { width: 22px; height: 22px; font-size: 0.7rem; border-width: 1.2px; }
.tag-2 { border-style: dashed; }
.tag-3 { border-style: dotted; border-width: 2px; }
.tag-4 { outline: 1px solid var(--ink); outline-offset: 2px; }
.row input {
  flex: 1; min-width: 0; height: 46px; padding: 0 12px; border: 1px solid var(--rule); border-bottom: 1.6px solid var(--ink); border-radius: 8px 8px 2px 2px;
  background: #fff; font: 400 0.9rem var(--mono); color: var(--ink); transition: border-color 0.15s, background 0.15s;
}
.row input::placeholder { color: var(--ink-3); font-family: var(--sans); }
.row input:focus { outline: none; border-color: var(--teal); background: #fbfffe; box-shadow: 0 2px 0 var(--teal); }
.rm { flex: none; width: 36px; height: 36px; border: 1px solid var(--rule); border-radius: 50%; background: transparent; font-size: 1.2rem; line-height: 1; }
.rm:hover { border-color: var(--ink); }
.search-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; margin: 12px 0 14px; }
.add { border: 1px dashed var(--ink); background: transparent; border-radius: 999px; padding: 7px 14px; font-weight: 600; font-size: 0.9rem; transition: background 0.15s, transform 0.15s var(--ease); }
.add:hover { background: var(--mint); }
.add:active { transform: scale(0.97); }
.hint { font-size: 0.85rem; color: var(--ink-2); }
.go {
  display: flex; width: 100%; align-items: center; justify-content: center; min-height: 52px; padding: 0 20px; border: 1.6px solid var(--ink); border-radius: 10px;
  background: var(--ink); color: var(--paper); font-weight: 700; font-size: 1.02rem; text-decoration: none; transition: transform 0.15s var(--ease), background 0.15s, color 0.15s;
}
.go:hover { background: var(--teal); border-color: var(--teal); text-decoration: none; }
.go:active { transform: translateY(1px) scale(0.99); }
.go:disabled { background: var(--paper-2); color: var(--ink-3); border-color: var(--rule); cursor: not-allowed; transform: none; }
.go.inline { display: inline-flex; width: auto; }
.formmsg { margin: 10px 0 0; font-size: 0.9rem; min-height: 1.4em; }
.formmsg:empty { display: none; }
.formmsg.bad { color: var(--bad); }
.formmsg.note { padding: 10px 12px; border-left: 3px solid var(--teal); background: var(--paper-2); border-radius: 0 8px 8px 0; color: var(--ink-2); }

/* ---------- how ---------- */
.how { padding: 72px 0 8px; }
.ruler-wrap { margin: 24px 0 8px; overflow: hidden; }
.ruler { width: 100%; max-width: 620px; display: block; }
.ruler line { stroke: var(--ink); stroke-width: 1.2; }
.ruler .base { stroke-width: 1.6; }
.ruler text { font: 400 19px var(--mono); fill: var(--ink-2); text-anchor: middle; }
.ruler .unit { fill: var(--ink-3); text-anchor: end; }
.ruler .slice { fill: var(--mint); stroke: var(--ink); stroke-width: 0.8; transform-box: fill-box; transform-origin: left center; }
.how.reveal.in .slice { animation: slice 0.5s var(--ease) both; }
.how .slice:nth-of-type(1) { animation-delay: 0ms; }
.how .slice:nth-of-type(2) { animation-delay: 60ms; }
.how .slice:nth-of-type(3) { animation-delay: 120ms; }
.how .slice:nth-of-type(4) { animation-delay: 180ms; }
.how .slice:nth-of-type(5) { animation-delay: 240ms; }
.how .slice:nth-of-type(6) { animation-delay: 300ms; }
.how .slice:nth-of-type(7) { animation-delay: 360ms; }
.how .slice:nth-of-type(8) { animation-delay: 420ms; }
.how .slice:nth-of-type(9) { animation-delay: 480ms; }
.how .slice:nth-of-type(10) { animation-delay: 540ms; }
.how .slice:nth-of-type(11) { animation-delay: 600ms; }
.how .slice:nth-of-type(12) { animation-delay: 660ms; }
@keyframes slice { from { transform: scaleX(0); } to { transform: scaleX(1); } }
.steps { list-style: none; counter-reset: s; margin: 28px 0 0; padding: 0; display: grid; gap: 28px; }
.steps li { counter-increment: s; position: relative; padding-left: 48px; max-width: 46ch; }
.steps li::before { content: counter(s); position: absolute; left: 0; top: -2px; width: 32px; height: 32px; border-radius: 50%; border: 1.6px solid var(--ink); display: grid; place-items: center; font: 600 0.85rem var(--mono); background: var(--paper); }
.steps p { margin: 6px 0 0; color: var(--ink-2); }
@media (min-width: 860px) { .steps { grid-template-columns: repeat(3, 1fr); gap: 36px; } }

/* ---------- pricing ---------- */
.pricing { padding: 80px 0 8px; }
.sub { color: var(--ink-2); max-width: 56ch; margin: 12px 0 0; }
.plans { display: grid; gap: 16px; margin-top: 28px; }
@media (min-width: 860px) { .plans { grid-template-columns: repeat(3, 1fr); } }
.plan { display: flex; flex-direction: column; gap: 6px; padding: 22px; border: 1px solid var(--ink); border-radius: 14px; background: var(--paper); }
.plan:nth-child(2) { background: var(--mint); }
.plan p { margin: 0; color: var(--ink-2); }
.plan .price { font: 600 1.7rem/1.2 var(--mono); color: var(--ink); letter-spacing: -0.02em; margin: 4px 0 6px; }
.buy { margin-top: auto; align-self: flex-start; border: 1.6px solid var(--ink); background: var(--ink); color: var(--paper); border-radius: 999px; padding: 10px 18px; font-weight: 650; transition: transform 0.15s var(--ease), background 0.15s; }
.plan .buy { margin-top: 14px; }
.buy:hover { background: var(--teal); border-color: var(--teal); }
.buy:active { transform: scale(0.97); }
.soon { margin-top: 14px !important; font-size: 0.88rem; font-style: italic; }
.havekey { margin: 18px 0 0; }
.linkish { background: none; border: 0; padding: 0; color: var(--teal); text-decoration: underline; text-underline-offset: 3px; }

/* ---------- reveal ---------- */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity 0.7s var(--ease), transform 0.7s var(--ease); }
.reveal.in { opacity: 1; transform: none; }

/* ---------- result ---------- */
.result { padding: 36px 0 0; max-width: 860px; }
.res-head h1 { font-size: clamp(1.7rem, 1.1rem + 2.6vw, 2.9rem); font-weight: 800; letter-spacing: -0.03em; }
.setname { font: 500 0.95rem var(--mono); margin: 0 0 8px; color: var(--teal); }
.res-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.ghost { display: inline-flex; align-items: center; min-height: 40px; padding: 0 14px; border: 1px solid var(--ink); border-radius: 999px; background: var(--paper); color: var(--ink); font-weight: 600; font-size: 0.9rem; text-decoration: none; transition: background 0.15s, transform 0.15s var(--ease); }
.ghost:hover { background: var(--mint); text-decoration: none; }
.ghost:active { transform: scale(0.97); }
.ghost.ok, .mini.ok { background: var(--mint); }
.coins { list-style: none; margin: 24px 0; padding: 0; display: grid; gap: 12px; }
.coins li { display: flex; gap: 12px; align-items: flex-start; }
.coins li > div { min-width: 0; overflow-wrap: anywhere; }
.coins a { font-weight: 700; color: var(--ink); }
.coin-meta { margin: 2px 0 0; font-size: 0.88rem; color: var(--ink-2); }
.working { display: flex; align-items: center; gap: 14px; margin: 24px 0 8px; padding: 16px; border: 1px solid var(--ink); border-radius: 12px; background: var(--paper); }
.working p { margin: 0; }
.spin { flex: none; width: 40px; height: 40px; color: var(--ink); animation: turn 2.4s linear infinite; }
@keyframes turn { to { transform: rotate(360deg); } }
.loading { color: var(--ink-3); }
.empty { padding: 18px; border: 1px dashed var(--ink); border-radius: 12px; background: var(--paper); }
.wallets { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.wallet { padding: 16px; border: 1px solid var(--ink); border-radius: 12px; background: var(--paper); }
.w-top { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.rank { font: 600 0.8rem var(--mono); width: 26px; height: 26px; display: grid; place-items: center; border-radius: 50%; background: var(--ink); color: var(--paper); }
.w-top code { font-size: 0.95rem; font-weight: 600; }
.avg { margin-left: auto; font: 500 0.85rem var(--mono); padding: 3px 10px; border-radius: 999px; background: var(--mint); border: 1px solid var(--ink); }
.mini { display: inline-flex; align-items: center; min-height: 32px; padding: 0 10px; border: 1px solid var(--rule); border-radius: 8px; background: transparent; color: var(--ink); font-size: 0.8rem; font-weight: 600; text-decoration: none; transition: border-color 0.15s, background 0.15s; }
.mini:hover { border-color: var(--ink); text-decoration: none; }
.tracks { display: grid; gap: 6px; margin-top: 12px; }
.track { display: grid; grid-template-columns: 22px 1fr 48px; align-items: center; gap: 10px; }
.rail { position: relative; height: 8px; border-radius: 4px; background: repeating-linear-gradient(90deg, var(--rule) 0 1px, transparent 1px calc(100% / 12)), var(--paper-2); border: 1px solid var(--rule); }
.rail i { position: absolute; top: 50%; left: var(--x, 0%); width: 12px; height: 12px; margin: -6px 0 0 -6px; border-radius: 50%; background: var(--ink); box-shadow: 0 0 0 3px var(--mint); }
.track.miss .rail i { display: none; }
.track.miss { opacity: 0.45; }
.min { font: 500 0.8rem var(--mono); text-align: right; color: var(--ink-2); }
.buys { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 12px; font-size: 0.85rem; }
.buys > .muted { margin-right: 4px; }
.buy-chip { display: inline-flex; align-items: baseline; gap: 6px; padding: 4px 10px; border: 1px solid var(--ink); border-radius: 999px; color: var(--ink); text-decoration: none; font-weight: 600; background: #fff; }
.buy-chip:hover { background: var(--mint); text-decoration: none; }
.buy-chip small { font: 400 0.72rem var(--mono); color: var(--ink-3); }
.near { margin-top: 28px; }
.near summary { cursor: pointer; font-weight: 700; padding: 10px 0; }
.near .wallets { margin-top: 8px; }

/* ---------- docs ---------- */
.docs { padding: 40px 0 0; max-width: 760px; }
.docs h1 { font-size: clamp(2rem, 1.4rem + 2.6vw, 3.2rem); font-weight: 800; letter-spacing: -0.03em; }
.docs h2 { font-size: 1.35rem; margin: 36px 0 10px; }
.docs pre { margin: 0; padding: 16px; background: var(--ink); color: var(--paper); border-radius: 10px; overflow-x: auto; font-size: 0.85rem; line-height: 1.55; }
.docs pre code { font-size: inherit; }
.fields { width: 100%; border-collapse: collapse; margin-top: 12px; font-size: 0.92rem; }
.fields th, .fields td { text-align: left; vertical-align: top; padding: 10px 8px 10px 0; border-top: 1px solid var(--rule); }
.fields th { font: 500 0.82rem var(--mono); white-space: nowrap; padding-right: 14px; }
@media (max-width: 520px) { .fields th, .fields td { display: block; padding: 8px 0 0; border: 0; } .fields tr { display: block; border-top: 1px solid var(--rule); padding-bottom: 8px; } }

/* ---------- dialogs ---------- */
.sheet { width: min(480px, calc(100vw - 24px)); max-height: calc(100dvh - 24px); overflow-y: auto; border: 1.6px solid var(--ink); border-radius: 16px; padding: 24px 20px 20px; background: var(--paper); color: var(--ink); box-shadow: 6px 6px 0 var(--ink); }
.sheet::backdrop { background: rgba(11, 9, 10, 0.45); }
.sheet[open] { animation: rise 0.28s var(--ease); }
@keyframes rise { from { opacity: 0; transform: translateY(14px); } }
.sheet h2 { font-size: 1.4rem; margin: 0 32px 10px 0; }
.sheet p { margin: 0 0 14px; }
.sheet .x { position: absolute; top: 10px; right: 10px; width: 38px; height: 38px; border: 0; background: transparent; font-size: 1.5rem; border-radius: 50%; }
.sheet .x:hover { background: var(--paper-2); }
.payline { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-top: 1px solid var(--rule); }
.payline:last-of-type { margin-bottom: 14px; }
.payline .muted { width: 56px; flex: none; font-size: 0.85rem; }
.payline code { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.amt { font-size: 1.05rem !important; font-weight: 600; }
.paystate { display: flex; align-items: center; gap: 10px; margin-top: 14px !important; font-size: 0.9rem; color: var(--ink-2); }
.pulse { width: 10px; height: 10px; border-radius: 50%; background: var(--teal); animation: pulse 1.4s ease-in-out infinite; flex: none; }
@keyframes pulse { 50% { opacity: 0.25; transform: scale(0.7); } }
.sigform label { display: block; font-size: 0.85rem; color: var(--ink-2); margin-bottom: 6px; }
.sigrow { display: flex; gap: 8px; }
.sigrow input { flex: 1; min-width: 0; height: 40px; padding: 0 10px; border: 1px solid var(--ink); border-radius: 8px; background: #fff; font: 400 0.82rem var(--mono); }

@media (max-width: 400px) {
  .nav a { padding: 8px 7px; font-size: 0.9rem; }
  .brand { font-size: 1.1rem; }
  .brand-mark { width: 30px; height: 30px; }
  .search { padding: 14px; box-shadow: 3px 3px 0 var(--ink); }
  .avg { margin-left: 0; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
  .reveal { opacity: 1; transform: none; }
}
