/* Cryptomo UI — no build step required */
:root {
  --bg: #f7f8fb; --surface: #ffffff; --surface-2: #f1f3f8; --border: #e3e6ee; --text: #0f172a; --muted: #5b6477; --faint: #8b93a5;
  --primary: #4f46e5; --primary-600: #4338ca; --primary-50: #eef0ff; --accent: #10b981; --accent-50: #e7f8f1;
  --green: #059669; --green-bg: #e7f8f1; --blue: #2563eb; --blue-bg: #e8f0fe; --amber: #b45309; --amber-bg: #fef4e2;
  --red: #dc2626; --red-bg: #fdecec; --gray: #5b6477; --gray-bg: #eef0f4;
  --radius: 12px; --radius-sm: 8px; --shadow: 0 1px 2px rgba(16,24,40,.05), 0 1px 3px rgba(16,24,40,.06);
  --shadow-lg: 0 12px 32px rgba(16,24,40,.10);
  --font: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0b0f1a; --surface: #121826; --surface-2: #1a2233; --border: #263045; --text: #e6e9f2; --muted: #9aa3b8; --faint: #6b7489;
    --primary: #7c74ff; --primary-600: #6a61f5; --primary-50: #1d1f3d; --accent-50: #0f2a22;
    --green: #34d399; --green-bg: #0f2a22; --blue: #60a5fa; --blue-bg: #13233f; --amber: #fbbf24; --amber-bg: #2d2412;
    --red: #f87171; --red-bg: #2f1616; --gray: #9aa3b8; --gray-bg: #1f2738; color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0b0f1a; --surface: #121826; --surface-2: #1a2233; --border: #263045; --text: #e6e9f2; --muted: #9aa3b8; --faint: #6b7489;
  --primary: #7c74ff; --primary-600: #6a61f5; --primary-50: #1d1f3d; --accent-50: #0f2a22;
  --green: #34d399; --green-bg: #0f2a22; --blue: #60a5fa; --blue-bg: #13233f; --amber: #fbbf24; --amber-bg: #2d2412;
  --red: #f87171; --red-bg: #2f1616; --gray: #9aa3b8; --gray-bg: #1f2738; color-scheme: dark;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: var(--font); font-size: 15px; line-height: 1.55; color: var(--text); background: var(--bg); }
a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4 { line-height: 1.2; margin: 0 0 .5em; letter-spacing: -.01em; }
h1 { font-size: 30px; } h2 { font-size: 22px; } h3 { font-size: 17px; }
p { margin: 0 0 1em; }
code, .mono { font-family: var(--mono); font-size: .92em; }
code { background: var(--surface-2); padding: 2px 6px; border-radius: 6px; }
pre { background: #0f172a; color: #e2e8f0; padding: 16px; border-radius: var(--radius-sm); overflow-x: auto; font-size: 13px; line-height: 1.5; }
pre code { background: none; padding: 0; color: inherit; }
hr { border: 0; border-top: 1px solid var(--border); margin: 24px 0; }
img { max-width: 100%; }
.muted { color: var(--muted); } .faint { color: var(--faint); } .small { font-size: 13px; } .tiny { font-size: 12px; }
.break { word-break: break-all; } .nowrap { white-space: nowrap; } .right { text-align: right; } .center { text-align: center; }
.container { max-width: 1160px; margin: 0 auto; padding: 0 16px; }
.narrow { max-width: 460px; margin: 0 auto; padding: 0 16px; }
.stack > * + * { margin-top: 16px; }
.row { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.between { justify-content: space-between; }
.grid { display: grid; gap: 16px; }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); } .grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 900px) { .grid-3, .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 620px) { .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; } h1 { font-size: 25px; } }
.mt-0 { margin-top: 0; } .mt-1 { margin-top: 8px; } .mt-2 { margin-top: 16px; } .mt-3 { margin-top: 24px; } .mt-4 { margin-top: 40px; }
.mb-0 { margin-bottom: 0; } .mb-1 { margin-bottom: 8px; } .mb-2 { margin-bottom: 16px; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 40px; padding: 0 16px; border-radius: var(--radius-sm); border: 1px solid transparent; font: 600 14px var(--font); cursor: pointer; text-decoration: none !important; white-space: nowrap; transition: background .15s, border-color .15s; }
.btn-primary { background: var(--primary); color: #fff; } .btn-primary:hover { background: var(--primary-600); }
.btn-accent { background: var(--accent); color: #fff; }
.btn-ghost { background: var(--surface); color: var(--text); border-color: var(--border); } .btn-ghost:hover { background: var(--surface-2); }
.btn-danger { background: var(--red-bg); color: var(--red); border-color: transparent; }
.btn-sm { height: 32px; padding: 0 12px; font-size: 13px; }
.btn-lg { height: 48px; padding: 0 22px; font-size: 15px; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .55; cursor: not-allowed; }
.link-btn { background: none; border: 0; padding: 0; color: var(--primary); font: inherit; cursor: pointer; }
.link-btn:hover { text-decoration: underline; }
.inline { display: inline; }

/* Forms */
label { display: block; font-weight: 600; font-size: 13px; margin-bottom: 6px; }
.field { margin-bottom: 16px; }
.hint { font-size: 12px; color: var(--muted); margin-top: 4px; font-weight: 400; }
input[type=text], input[type=email], input[type=password], input[type=number], input[type=url], input[type=search], select, textarea {
  width: 100%; height: 40px; padding: 8px 12px; border: 1px solid var(--border); border-radius: var(--radius-sm); background: var(--surface); color: var(--text); font: 14px var(--font);
}
textarea { height: auto; min-height: 110px; resize: vertical; line-height: 1.5; }
input:focus, select:focus, textarea:focus { outline: 2px solid var(--primary); outline-offset: -1px; border-color: transparent; }
.check { display: flex; gap: 8px; align-items: flex-start; font-weight: 500; font-size: 14px; }
.check input { margin-top: 3px; }
.checks { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 8px; }
.code-input { font-family: var(--mono); letter-spacing: .3em; text-align: center; font-size: 20px !important; height: 48px !important; }

/* Cards / panels */
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); }
.card-body { padding: 20px; }
.card-head { padding: 16px 20px; border-bottom: 1px solid var(--border); display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.card-head h2, .card-head h3 { margin: 0; }
.stat { padding: 18px 20px; }
.stat .label { font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); font-weight: 600; }
.stat .value { font-size: 24px; font-weight: 700; margin-top: 4px; }
.empty { padding: 40px 20px; text-align: center; color: var(--muted); }

/* Tables */
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th { text-align: left; font-size: 12px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); font-weight: 600; padding: 10px 16px; border-bottom: 1px solid var(--border); white-space: nowrap; }
td { padding: 12px 16px; border-bottom: 1px solid var(--border); vertical-align: middle; }
tr:last-child td { border-bottom: 0; }
tbody tr:hover { background: var(--surface-2); }
dl.kv { display: grid; grid-template-columns: 170px 1fr; gap: 10px 16px; margin: 0; font-size: 14px; }
dl.kv dt { color: var(--muted); } dl.kv dd { margin: 0; word-break: break-word; }
@media (max-width: 620px) { dl.kv { grid-template-columns: 1fr; gap: 2px 0; } dl.kv dd { margin-bottom: 10px; } }

/* Badges & alerts */
.badge { display: inline-flex; align-items: center; height: 22px; padding: 0 8px; border-radius: 999px; font-size: 12px; font-weight: 600; text-transform: capitalize; white-space: nowrap; }
.badge-green { background: var(--green-bg); color: var(--green); } .badge-blue { background: var(--blue-bg); color: var(--blue); }
.badge-amber { background: var(--amber-bg); color: var(--amber); } .badge-red { background: var(--red-bg); color: var(--red); } .badge-gray { background: var(--gray-bg); color: var(--gray); }
.alert { padding: 12px 16px; border-radius: var(--radius-sm); margin-bottom: 16px; font-size: 14px; border: 1px solid transparent; }
.alert-success { background: var(--green-bg); color: var(--green); } .alert-error { background: var(--red-bg); color: var(--red); }
.alert-warning { background: var(--amber-bg); color: var(--amber); } .alert-info { background: var(--blue-bg); color: var(--blue); }
.alert ul { margin: 4px 0 0; padding-left: 18px; }
.coin { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; }
.coin-dot { width: 26px; height: 26px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; color: #fff; font-size: 10px; font-weight: 800; flex: none; }
.secret-box { font-family: var(--mono); background: var(--surface-2); border: 1px dashed var(--border); padding: 10px 12px; border-radius: var(--radius-sm); word-break: break-all; font-size: 13px; }

/* Public site */
.site-nav { position: sticky; top: 0; z-index: 20; background: color-mix(in srgb, var(--bg) 88%, transparent); backdrop-filter: blur(10px); border-bottom: 1px solid var(--border); }
.site-nav .container { display: flex; align-items: center; justify-content: space-between; height: 64px; gap: 16px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 800; font-size: 19px; color: var(--text); letter-spacing: -.02em; }
.brand:hover { text-decoration: none; }
.brand-mark { width: 30px; height: 30px; border-radius: 9px; background: linear-gradient(135deg, var(--primary), var(--accent)); display: inline-flex; align-items: center; justify-content: center; color: #fff; font-weight: 900; font-size: 16px; }
.nav-links { display: flex; gap: 22px; align-items: center; }
.nav-links a { color: var(--muted); font-weight: 500; font-size: 14px; }
.nav-links a:hover { color: var(--text); text-decoration: none; }
.nav-toggle { display: none; background: none; border: 1px solid var(--border); border-radius: 8px; width: 40px; height: 40px; color: var(--text); font-size: 18px; }
@media (max-width: 860px) {
  .nav-toggle { display: inline-flex; align-items: center; justify-content: center; }
  .nav-links { display: none; position: absolute; top: 64px; left: 0; right: 0; background: var(--surface); flex-direction: column; align-items: stretch; padding: 12px 16px 16px; border-bottom: 1px solid var(--border); gap: 12px; }
  .nav-links.open { display: flex; }
}
.hero { padding: 80px 0 60px; text-align: center; }
.hero h1 { font-size: 50px; letter-spacing: -.03em; max-width: 820px; margin: 0 auto 18px; }
.hero p.lead { font-size: 19px; color: var(--muted); max-width: 640px; margin: 0 auto 28px; }
.hero .gradient { background: linear-gradient(90deg, var(--primary), var(--accent)); -webkit-background-clip: text; background-clip: text; color: transparent; }
@media (max-width: 620px) { .hero { padding: 48px 0 36px; } .hero h1 { font-size: 34px; } .hero p.lead { font-size: 16px; } }
.pill { display: inline-flex; gap: 6px; align-items: center; padding: 6px 12px; border-radius: 999px; background: var(--primary-50); color: var(--primary); font-weight: 600; font-size: 13px; margin-bottom: 20px; }
.section { padding: 56px 0; }
.section-title { text-align: center; max-width: 640px; margin: 0 auto 36px; }
.section-title p { color: var(--muted); font-size: 16px; }
.feature { padding: 22px; }
.feature .icon { width: 40px; height: 40px; border-radius: 10px; background: var(--primary-50); color: var(--primary); display: flex; align-items: center; justify-content: center; font-size: 19px; margin-bottom: 14px; }
.feature p { color: var(--muted); font-size: 14px; margin: 0; }
.coins-strip { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.coins-strip .chip { display: inline-flex; gap: 8px; align-items: center; padding: 6px 12px 6px 6px; border: 1px solid var(--border); border-radius: 999px; background: var(--surface); font-weight: 600; font-size: 14px; }
.steps { counter-reset: s; }
.steps .step { position: relative; padding-left: 52px; margin-bottom: 22px; }
.steps .step::before { counter-increment: s; content: counter(s); position: absolute; left: 0; top: 0; width: 36px; height: 36px; border-radius: 50%; background: var(--primary); color: #fff; font-weight: 700; display: flex; align-items: center; justify-content: center; }
.price-card { padding: 26px; display: flex; flex-direction: column; }
.price-card .price { font-size: 38px; font-weight: 800; letter-spacing: -.02em; }
.price-card ul { list-style: none; padding: 0; margin: 18px 0 24px; flex: 1; }
.price-card li { padding: 6px 0 6px 26px; position: relative; font-size: 14px; }
.price-card li::before { content: "✓"; position: absolute; left: 0; color: var(--accent); font-weight: 800; }
.price-card.featured { border: 2px solid var(--primary); }
.cta-band { background: linear-gradient(135deg, var(--primary), #6d28d9); color: #fff; border-radius: 20px; padding: 44px 28px; text-align: center; }
.cta-band p { opacity: .9; }
.site-footer { border-top: 1px solid var(--border); padding: 36px 0; margin-top: 40px; font-size: 14px; color: var(--muted); }
.site-footer .container { display: flex; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
.site-footer a { color: var(--muted); } .site-footer .links { display: flex; gap: 18px; flex-wrap: wrap; }
.prose { max-width: 760px; } .prose h2 { margin-top: 32px; } .prose table { margin: 12px 0 20px; }
.docs-layout { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 36px; padding: 32px 0; }
.docs-nav { position: sticky; top: 84px; align-self: start; font-size: 14px; }
.docs-nav a { display: block; padding: 5px 0; color: var(--muted); }
@media (max-width: 860px) { .docs-layout { grid-template-columns: 1fr; } .docs-nav { position: static; } }

/* Auth pages */
.auth-wrap { min-height: calc(100vh - 64px); display: flex; align-items: center; padding: 40px 0; }
.auth-card { width: 100%; padding: 28px; }
.auth-card h1 { font-size: 24px; }

/* App shell (dashboard + admin) */
.app { display: grid; grid-template-columns: 240px minmax(0, 1fr); min-height: 100vh; }
.sidebar { background: var(--surface); border-right: 1px solid var(--border); padding: 18px 12px; position: sticky; top: 0; height: 100vh; overflow-y: auto; }
.sidebar .brand { padding: 4px 10px 18px; }
.sidebar nav a { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border-radius: 8px; color: var(--muted); font-weight: 500; font-size: 14px; }
.sidebar nav a:hover { background: var(--surface-2); color: var(--text); text-decoration: none; }
.sidebar nav a.active { background: var(--primary-50); color: var(--primary); font-weight: 600; }
.sidebar .nav-label { font-size: 11px; text-transform: uppercase; letter-spacing: .08em; color: var(--faint); padding: 16px 12px 6px; font-weight: 700; }
.sidebar .ic { width: 18px; text-align: center; }
.main { min-width: 0; }
.topbar { height: 60px; display: flex; align-items: center; justify-content: space-between; padding: 0 24px; border-bottom: 1px solid var(--border); background: var(--surface); gap: 12px; }
.topbar .who { font-size: 14px; color: var(--muted); }
.page { padding: 24px; max-width: 1200px; }
.page-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; margin-bottom: 20px; flex-wrap: wrap; }
.page-head h1 { font-size: 24px; margin: 0; }
.page-head p { margin: 4px 0 0; color: var(--muted); }
.menu-btn { display: none; }
@media (max-width: 900px) {
  .app { grid-template-columns: 1fr; }
  .sidebar { position: fixed; left: 0; top: 0; bottom: 0; width: 260px; z-index: 50; transform: translateX(-100%); transition: transform .2s; box-shadow: var(--shadow-lg); }
  .sidebar.open { transform: none; }
  .menu-btn { display: inline-flex; }
  .page { padding: 16px; }
  .topbar { padding: 0 16px; }
}
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--border); margin-bottom: 20px; overflow-x: auto; }
.tabs a { padding: 10px 14px; color: var(--muted); font-weight: 600; font-size: 14px; border-bottom: 2px solid transparent; white-space: nowrap; }
.tabs a.active { color: var(--primary); border-bottom-color: var(--primary); }
.tabs a:hover { text-decoration: none; color: var(--text); }
.filters { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 16px; }
.filters input, .filters select { width: auto; min-width: 150px; }
.pager { display: flex; gap: 8px; justify-content: flex-end; padding: 12px 16px; }

/* Checkout */
.checkout-body { background: var(--bg); min-height: 100vh; display: flex; flex-direction: column; align-items: center; padding: 32px 16px; }
.checkout { width: 100%; max-width: 460px; }
.checkout .card { overflow: hidden; }
.co-head { padding: 20px 22px; border-bottom: 1px solid var(--border); display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.co-store { font-weight: 700; display: flex; align-items: center; gap: 10px; }
.co-store img { width: 32px; height: 32px; border-radius: 8px; object-fit: cover; }
.co-amount { text-align: right; }
.co-amount .fiat { font-size: 22px; font-weight: 800; }
.co-body { padding: 22px; }
.token-list { display: grid; gap: 8px; }
.token-opt { display: flex; justify-content: space-between; align-items: center; gap: 12px; width: 100%; padding: 12px 14px; border: 1px solid var(--border); border-radius: 10px; background: var(--surface); color: var(--text); cursor: pointer; font: inherit; text-align: left; }
.token-opt:hover { border-color: var(--primary); background: var(--primary-50); }
.token-opt .net { font-size: 12px; color: var(--muted); font-weight: 500; }
.qr { display: flex; justify-content: center; padding: 12px; background: #fff; border-radius: 12px; width: 212px; margin: 0 auto 16px; }
.qr svg, .qr img { width: 188px; height: 188px; display: block; }
.copy-row { display: flex; align-items: center; gap: 8px; background: var(--surface-2); border: 1px solid var(--border); border-radius: 10px; padding: 10px 12px; margin-bottom: 10px; }
.copy-row .val { flex: 1; font-family: var(--mono); font-size: 13px; word-break: break-all; }
.copy-row .lbl { font-size: 11px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); font-weight: 700; display: block; margin-bottom: 2px; font-family: var(--font); }
.copy-btn { border: 1px solid var(--border); background: var(--surface); color: var(--text); border-radius: 8px; height: 30px; padding: 0 10px; cursor: pointer; font: 600 12px var(--font); flex: none; }
.timer { display: flex; align-items: center; justify-content: center; gap: 8px; font-size: 13px; color: var(--muted); margin: 14px 0 0; }
.warn-net { font-size: 13px; background: var(--amber-bg); color: var(--amber); padding: 10px 12px; border-radius: 10px; margin-bottom: 14px; }
.status-big { text-align: center; padding: 18px 0 6px; }
.status-big .icon { width: 64px; height: 64px; border-radius: 50%; margin: 0 auto 14px; display: flex; align-items: center; justify-content: center; font-size: 30px; }
.status-big.ok .icon { background: var(--green-bg); color: var(--green); }
.status-big.bad .icon { background: var(--gray-bg); color: var(--gray); }
.status-big.wait .icon { background: var(--blue-bg); color: var(--blue); }
.spinner { width: 16px; height: 16px; border: 2px solid var(--border); border-top-color: var(--primary); border-radius: 50%; animation: spin 1s linear infinite; display: inline-block; }
@keyframes spin { to { transform: rotate(360deg); } }
.powered { text-align: center; font-size: 12px; color: var(--faint); margin-top: 16px; }
.progress { height: 6px; background: var(--surface-2); border-radius: 99px; overflow: hidden; margin: 8px 0 14px; }
.progress > span { display: block; height: 100%; background: var(--accent); }

/* Install */
.install-wrap { max-width: 720px; margin: 40px auto; padding: 0 16px; }
.req { display: flex; justify-content: space-between; padding: 8px 0; border-bottom: 1px solid var(--border); font-size: 14px; }
.req .ok { color: var(--green); font-weight: 700; } .req .no { color: var(--red); font-weight: 700; }
.nav-links a.btn-primary, .nav-links a.btn-primary:hover { color: #fff; }
.coin-dot { font-size: 9px; letter-spacing: -.02em; overflow: hidden; }
.co-amount .fiat { font-size: 20px; white-space: nowrap; }
.co-head { align-items: flex-start; }
