/* MinerSwap "Cash" design system — proposal */
:root {
  --green: #00d46a; --green-d: #00a653; --green-soft: #e3f9ec;
  --ink: #0b0b0c; --ink-2: #2a2b2e; --gray: #6b6f76; --gray-2: #9a9ea5;
  --line: #ececee; --bg: #f7f7f8; --white: #fff;
  --red: #ff4d4f; --red-soft: #ffeceb; --amber: #ffb020; --amber-soft: #fff4dc; --blue: #3d7bff;
  --r-xl: 32px; --r-lg: 24px; --r-md: 16px;
  --shadow: 0 30px 60px -30px rgba(0,0,0,.28);
  font-family: "Manrope", system-ui, -apple-system, sans-serif;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--white); color: var(--ink); overflow-x: hidden; -webkit-font-smoothing: antialiased; }
button { font: inherit; color: inherit; cursor: pointer; border: 0; background: none; }
input, select { font: inherit; color: inherit; }
a { color: inherit; }
img { max-width: 100%; }
.wrap { max-width: 1160px; margin: 0 auto; padding: 0 20px; }
.narrow { max-width: 760px; margin: 0 auto; padding: 0 20px; }
.demo { background: var(--ink); color: var(--green); font-size: 13px; text-align: center; padding: 6px 12px; }

/* ---------- top nav ---------- */
.topnav { position: sticky; top: 0; z-index: 40; background: rgba(255,255,255,.86); backdrop-filter: blur(14px); border-bottom: 1px solid transparent; transition: border-color .2s; }
.topnav.green { background: var(--green); }
.topnav.scrolled { border-color: var(--line); }
.topnav.green.scrolled { border-color: rgba(0,0,0,.08); }
.topnav .wrap { display: flex; align-items: center; gap: 28px; height: 72px; }
.logo { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 20px; text-decoration: none; letter-spacing: -.02em; }
.logo img { width: 36px; height: 36px; border-radius: 50%; }
.navlinks { display: flex; gap: 4px; margin-left: 12px; }
.navlinks a { text-decoration: none; font-weight: 700; padding: 9px 14px; border-radius: 999px; color: var(--ink-2); opacity: .8; transition: background .15s, opacity .15s; }
.navlinks a:hover { opacity: 1; background: rgba(0,0,0,.05); }
.navlinks a.on { opacity: 1; background: rgba(0,0,0,.07); }
.navright { margin-left: auto; display: flex; gap: 10px; align-items: center; }

/* mobile bottom tab bar */
.tabbar { display: none; }
@media (max-width: 860px) {
  .navlinks { display: none; }
  .tabbar { display: grid; grid-template-columns: repeat(5, 1fr); position: fixed; left: 10px; right: 10px; bottom: 10px; z-index: 50; background: var(--ink); border-radius: 22px; padding: 6px; box-shadow: 0 12px 30px rgba(0,0,0,.3); }
  .tabbar a { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 8px 0 6px; border-radius: 16px; color: #fff; text-decoration: none; font-size: 11px; font-weight: 700; opacity: .6; }
  .tabbar a svg { width: 22px; height: 22px; }
  .tabbar a.on { opacity: 1; background: rgba(255,255,255,.1); color: var(--green); }
  body { padding-bottom: 86px; }
}

/* ---------- buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 13px 22px; border-radius: 999px; font-weight: 800; text-decoration: none; transition: transform .12s, background .15s, opacity .15s; white-space: nowrap; }
.btn:active { transform: scale(.96); }
.btn.dark { background: var(--ink); color: var(--white); }
.btn.dark:hover { background: var(--ink-2); }
.btn.green { background: var(--green); color: var(--ink); }
.btn.green:hover { background: #00e273; }
.btn.light { background: var(--white); color: var(--ink); }
.btn.ghost { background: var(--bg); }
.btn.ghost:hover { background: var(--line); }
.btn.block { width: 100%; padding: 17px; font-size: 17px; }
.btn:disabled { opacity: .35; cursor: not-allowed; transform: none; }
.btn.sm { padding: 8px 14px; font-size: 14px; }

/* ---------- type ---------- */
h1, h2, h3 { letter-spacing: -.04em; font-weight: 800; }
.h-xl { font-size: clamp(46px, 7vw, 96px); line-height: .92; margin: 0 0 22px; }
.h-lg { font-size: clamp(36px, 5vw, 62px); line-height: 1; margin: 0 0 16px; }
.h-md { font-size: clamp(26px, 3vw, 34px); line-height: 1.1; margin: 0 0 10px; }
.lead { font-size: 20px; font-weight: 500; max-width: 30em; margin: 0 0 28px; }
.muted { color: var(--gray); font-weight: 500; }
.eyebrow { display: inline-block; font-size: 13px; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; color: var(--green-d); margin-bottom: 12px; }

/* ---------- layout blocks ---------- */
section.s { padding-top: 96px; padding-bottom: 96px; }
.page-head { padding-top: 56px; padding-bottom: 36px; }
.page-head .lead { color: var(--gray); margin-bottom: 0; }
.panel { background: var(--white); border-radius: var(--r-xl); padding: 22px; box-shadow: var(--shadow); border: 1px solid var(--line); }
.soft { background: var(--bg); border-radius: var(--r-lg); padding: 24px; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.split { display: grid; grid-template-columns: 1fr 440px; gap: 56px; align-items: start; }
.split > *, .grid-2 > *, .grid-3 > * { min-width: 0; }
@media (max-width: 960px) {
  .split { grid-template-columns: 1fr; gap: 32px; }
  .grid-3, .grid-4 { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 600px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  section.s { padding-top: 64px; padding-bottom: 64px; }
  .page-head { padding-top: 32px; padding-bottom: 24px; }
}

/* ---------- form controls ---------- */
.field { display: block; margin-bottom: 14px; }
.field > span { display: block; font-size: 13px; font-weight: 800; color: var(--gray); margin: 0 0 6px 4px; }
.input { width: 100%; padding: 15px 16px; border-radius: var(--r-md); border: 2px solid var(--line); background: var(--white); outline: none; font-weight: 600; font-size: 16px; transition: border-color .15s, box-shadow .15s; }
.input:focus { border-color: var(--green); box-shadow: 0 0 0 4px var(--green-soft); }
.input.filled { background: var(--bg); border-color: transparent; }
.input.filled:focus { background: var(--white); border-color: var(--green); }
.hint { font-size: 13px; font-weight: 700; margin: 6px 4px 0; min-height: 18px; color: var(--gray); }
.hint.ok { color: var(--green-d); }
.hint.bad { color: var(--red); }
.seg { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; background: var(--bg); border-radius: 999px; padding: 4px; position: relative; }
.seg button { padding: 10px 12px; border-radius: 999px; font-weight: 800; font-size: 14px; color: var(--gray); position: relative; z-index: 1; transition: color .2s; }
.seg button.on { color: var(--ink); }
.seg .knob { position: absolute; top: 4px; bottom: 4px; left: 4px; background: var(--white); border-radius: 999px; box-shadow: 0 2px 8px rgba(0,0,0,.08); transition: transform .3s cubic-bezier(.3,1.3,.5,1), width .3s; }
.chip { display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px 8px 8px; background: var(--bg); border-radius: 999px; font-weight: 800; transition: background .15s; }
.chip:hover { background: var(--line); }
.chip img { width: 26px; height: 26px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.pill-opt { padding: 10px 16px; border-radius: 999px; background: var(--bg); font-weight: 800; font-size: 15px; border: 2px solid transparent; transition: border-color .15s, background .15s; }
.pill-opt:hover { background: var(--line); }
.pill-opt.on { background: var(--green-soft); border-color: var(--green); }

/* ---------- rows / lists ---------- */
.line { display: flex; justify-content: space-between; gap: 12px; padding: 13px 0; border-bottom: 1px solid var(--line); font-weight: 700; }
.line:last-child { border-bottom: 0; }
.line > span:first-child { color: var(--gray); font-weight: 600; }
.badge { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 999px; font-size: 12.5px; font-weight: 800; }
.badge.ok { background: var(--green-soft); color: var(--green-d); }
.badge.wait { background: var(--amber-soft); color: #a86b00; }
.badge.bad { background: var(--red-soft); color: var(--red); }
.badge.dot::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.item { display: flex; align-items: center; gap: 14px; padding: 12px; border-radius: var(--r-md); transition: background .15s; }
.item:hover { background: var(--bg); }
.item .ic { width: 44px; height: 44px; border-radius: 50%; background: var(--bg); display: grid; place-items: center; flex: none; position: relative; }
.item .ic img { width: 28px; height: 28px; }
.item .ic img + img { position: absolute; width: 22px; height: 22px; right: -4px; bottom: -4px; border: 2px solid var(--white); border-radius: 50%; background: var(--white); }
.item .tx { flex: 1; min-width: 0; }
.item .tx b { display: block; }
.item .tx small { color: var(--gray); font-weight: 600; }
.item .amt { text-align: right; font-weight: 800; }
.item .amt small { display: block; color: var(--gray); font-weight: 600; }

/* ---------- timeline ---------- */
.timeline { list-style: none; margin: 0; padding: 0; }
.timeline li { display: grid; grid-template-columns: 32px 1fr; gap: 14px; position: relative; padding-bottom: 22px; }
.timeline li:last-child { padding-bottom: 0; }
.timeline li::before { content: ""; position: absolute; left: 15px; top: 34px; bottom: 2px; width: 2px; background: var(--line); }
.timeline li:last-child::before { display: none; }
.timeline .dotc { width: 32px; height: 32px; border-radius: 50%; background: var(--bg); color: var(--gray-2); display: grid; place-items: center; font-weight: 800; font-size: 14px; transition: all .3s; }
.timeline li.done .dotc { background: var(--green); color: var(--ink); }
.timeline li.done::before { background: var(--green); }
.timeline li.active .dotc { background: var(--ink); color: var(--green); box-shadow: 0 0 0 6px var(--green-soft); animation: ping 1.6s infinite; }
@keyframes ping { 50% { box-shadow: 0 0 0 10px transparent; } }
.timeline b { display: block; padding-top: 4px; }
.timeline li:not(.done):not(.active) b { color: var(--gray-2); }
.timeline small { color: var(--gray); font-weight: 600; }

/* ---------- sheet & modal ---------- */
.overlay { position: fixed; inset: 0; background: rgba(11,11,12,.45); z-index: 80; opacity: 0; pointer-events: none; transition: opacity .25s; }
.overlay.open { opacity: 1; pointer-events: auto; }
.sheet { position: fixed; left: 50%; bottom: 0; width: min(520px, 100%); max-height: 88vh; overflow: auto; background: var(--white); border-radius: 28px 28px 0 0; padding: 12px 22px 26px; z-index: 90; transform: translate(-50%, 105%); transition: transform .4s cubic-bezier(.2,.9,.3,1); }
.sheet.open { transform: translate(-50%, 0); }
.sheet .grab { width: 44px; height: 5px; border-radius: 4px; background: var(--line); margin: 0 auto 16px; }
.sheet h3 { font-size: 24px; margin: 0 0 14px; }
@media (min-width: 861px) {
  .sheet { top: 50%; bottom: auto; border-radius: 28px; transform: translate(-50%, -40%) scale(.96); opacity: 0; pointer-events: none; transition: transform .3s cubic-bezier(.2,.9,.3,1), opacity .2s; }
  .sheet.open { transform: translate(-50%, -50%); opacity: 1; pointer-events: auto; }
  .sheet .grab { display: none; }
}

/* coin list in sheet */
.coinlist { display: grid; gap: 2px; margin-top: 10px; }
.coinlist button { display: flex; align-items: center; gap: 12px; padding: 10px; border-radius: 14px; text-align: left; }
.coinlist button:hover { background: var(--bg); }
.coinlist img { width: 36px; height: 36px; }
.coinlist b { display: block; }
.coinlist small { color: var(--gray); font-weight: 600; }
.coinlist .px { margin-left: auto; text-align: right; font-weight: 700; }

/* slide to confirm */
.slide { position: relative; height: 62px; border-radius: 999px; background: var(--bg); overflow: hidden; user-select: none; touch-action: none; margin-top: 18px; }
.slide .fill { position: absolute; inset: 0 auto 0 0; background: var(--green); width: 62px; border-radius: 999px; }
.slide .label { position: absolute; inset: 0; display: grid; place-items: center; font-weight: 800; color: var(--gray); pointer-events: none; }
.slide .knob { position: absolute; top: 5px; left: 5px; width: 52px; height: 52px; border-radius: 50%; background: var(--ink); color: var(--white); display: grid; place-items: center; font-size: 20px; cursor: grab; }
.slide.locked { opacity: .4; pointer-events: none; }

/* toast */
.toast { position: fixed; left: 50%; top: 20px; transform: translate(-50%, -150%); background: var(--ink); color: var(--white); padding: 12px 18px; border-radius: 999px; font-weight: 700; z-index: 100; transition: transform .35s cubic-bezier(.3,1.4,.5,1); display: flex; align-items: center; gap: 8px; }
.toast::before { content: "✓"; width: 22px; height: 22px; border-radius: 50%; background: var(--green); color: var(--ink); display: grid; place-items: center; font-size: 13px; }
.toast.show { transform: translate(-50%, 0); }

/* faq */
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { list-style: none; cursor: pointer; padding: 24px 0; font-size: 20px; font-weight: 800; display: flex; justify-content: space-between; gap: 16px; letter-spacing: -.01em; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-size: 26px; line-height: 1; transition: transform .25s; color: var(--green-d); }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq p { margin: 0 0 24px; color: var(--gray); font-size: 17px; font-weight: 500; max-width: 42em; line-height: 1.6; }

/* footer */
footer.site { border-top: 1px solid var(--line); margin-top: 40px; padding: 48px 0 56px; }
footer.site .wrap { display: grid; grid-template-columns: 1.4fr repeat(3, 1fr); gap: 24px; }
footer.site h4 { margin: 0 0 12px; font-size: 14px; color: var(--gray); text-transform: uppercase; letter-spacing: .06em; }
footer.site a { display: block; text-decoration: none; font-weight: 700; padding: 4px 0; }
footer.site a:hover { color: var(--green-d); }
footer.site p { color: var(--gray); font-weight: 500; max-width: 22em; }
@media (max-width: 760px) { footer.site .wrap { grid-template-columns: 1fr 1fr; } footer.site .wrap > div:first-child { grid-column: 1 / -1; } }

/* misc */
.vcard { aspect-ratio: 1.586; width: 100%; max-width: 380px; border-radius: 22px; padding: 22px; color: #fff; display: flex; flex-direction: column; justify-content: space-between; background: radial-gradient(circle at 85% 0%, #2f2f35, transparent 60%), linear-gradient(135deg, #111114, #2a2a30); box-shadow: 0 30px 60px -24px rgba(0,0,0,.55); position: relative; overflow: hidden; }
.vcard::after { content: ""; position: absolute; inset: 0; background: linear-gradient(110deg, transparent 30%, rgba(255,255,255,.12) 45%, transparent 60%); transform: translateX(-100%); transition: transform .8s; }
.vcard:hover::after { transform: translateX(100%); }
.vcard .chiprow { display: flex; justify-content: space-between; align-items: center; }
.vcard .emv { width: 42px; height: 32px; border-radius: 6px; background: linear-gradient(135deg, #e9c37a, #b8893d); }
.vcard .num { font-size: 20px; letter-spacing: .14em; font-weight: 700; }
.vcard .bottom { display: flex; justify-content: space-between; align-items: flex-end; font-size: 13px; font-weight: 700; opacity: .9; }
.vcard .net { font-size: 20px; font-weight: 800; font-style: italic; }
.vcard.green { background: radial-gradient(circle at 85% 0%, #5bffa8, transparent 60%), linear-gradient(135deg, #00b85c, #00d46a); color: var(--ink); }
.qr { width: 184px; height: 184px; border-radius: 18px; background: var(--white); padding: 12px; border: 1px solid var(--line); }
.qr canvas { width: 100%; height: 100%; image-rendering: pixelated; }
.copy { display: flex; align-items: center; gap: 10px; background: var(--bg); border-radius: var(--r-md); padding: 12px 14px; font-family: ui-monospace, SFMono-Regular, monospace; font-size: 14px; word-break: break-all; cursor: pointer; transition: background .15s; }
.copy:hover { background: var(--line); }
.copy::after { content: "Copy"; margin-left: auto; font-family: "Manrope", sans-serif; font-weight: 800; font-size: 13px; color: var(--green-d); flex: none; }
.empty { text-align: center; padding: 40px 20px; color: var(--gray); font-weight: 600; }
.shake { animation: shake .3s; }
@keyframes shake { 25% { transform: translateX(-6px); } 75% { transform: translateX(6px); } }
.fade-in { animation: fadein .45s ease both; }
@keyframes fadein { from { opacity: 0; transform: translateY(10px); } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }

/* ---------- "More" menu ---------- */
.more { position: relative; }
.more summary { list-style: none; cursor: pointer; font-weight: 700; padding: 9px 14px; border-radius: 999px; color: var(--ink-2); opacity: .8; }
.more summary::-webkit-details-marker { display: none; }
.more summary:hover, .more summary.on, .more[open] summary { opacity: 1; background: rgba(0,0,0,.06); }
.more-menu { position: absolute; top: calc(100% + 8px); left: 0; width: 300px; background: var(--white); border: 1px solid var(--line); border-radius: 20px; box-shadow: var(--shadow); padding: 8px; display: grid; animation: fadein .2s ease both; z-index: 60; }
.more-menu a { padding: 10px 12px !important; border-radius: 14px !important; opacity: 1 !important; }
.more-menu a:hover, .more-menu a.on { background: var(--bg) !important; }
.more-menu b { display: block; font-size: 15px; }
.more-menu small { color: var(--gray); font-weight: 600; }

/* ---------- Private mode (dark) ---------- */
.private-pill { display: none; padding: 8px 14px; border-radius: 999px; background: #1d1e22; color: #d6d8dc; font-weight: 800; font-size: 13px; border: 1px solid #34363c; }
body.private .private-pill { display: inline-flex; align-items: center; gap: 6px; cursor: pointer; }
body { transition: background .45s ease, color .45s ease; }
body.private {
  --white: #121316; --bg: #1b1c20; --line: #2a2c31; --ink: #f1f2f4; --ink-2: #d4d6da; --gray: #9a9ea6; --gray-2: #6e727a;
  --green: #2be38a; --green-d: #3ff09a; --green-soft: #12301f; --amber-soft: #3a2d12; --red-soft: #3a1717;
  --shadow: 0 30px 60px -30px rgba(0,0,0,.8);
  background: #0b0c0e;
}
body.private main, body.private footer.site { background: transparent; }
body.private .topnav { background: rgba(11,12,14,.85); }
body.private .topnav.green { background: #0b0c0e; }
body.private .hero-bg { background: radial-gradient(circle at 80% 0%, #10331f, #0b0c0e 60%); }
body.private .hero-bg .h-xl, body.private .hero-bg .lead, body.private .hero-bg .stats { color: var(--ink); }
body.private .tabbar { background: #000; border: 1px solid #222; }
body.private .btn.dark { background: #f1f2f4; color: #0b0c0e; }
body.private .btn.green, body.private .kpi.green, body.private .band, body.private .p-gift, body.private .auth .pitch { color: #0b0c0e; }
body.private .demo { background: #000; }
body.private .navlinks a:hover, body.private .navlinks a.on, body.private .more summary:hover, body.private .more summary.on, body.private .more[open] summary { background: rgba(255,255,255,.08); }
body.private .chip .ic, body.private .item:hover { background: var(--bg); }
body.private .toast { background: #f1f2f4; color: #0b0c0e; }
body.private .vcard.green { color: #0b0c0e; }
body.private .warn { color: #ffcf7a; }
body.private .badge.wait { color: #ffcf7a; }
body.private input, body.private select { color-scheme: dark; }
body.private .private-only { display: block; }
.private-only { display: none; }
/* Dark blocks that keep a dark background in private mode */
body.private .card-stage, body.private .avatar { background: #1b1c20; }
body.private .fees { background: #1b1c20; color: var(--ink); }
body.private .how .soft::before, body.private .timeline li.active .dotc { background: #000; }

/* ---------- code ---------- */
.code-block { margin: 0; padding: 16px 18px; border-radius: 16px; background: #0b0b0c; color: #e9fbe9; font: 600 13px/1.6 ui-monospace, Menlo, monospace; overflow-x: auto; white-space: pre; }
code { font-family: ui-monospace, Menlo, monospace; font-size: .92em; background: var(--bg); padding: 2px 6px; border-radius: 6px; }
.code-block code { background: none; padding: 0; }

.hidden { display: none !important; }
