/* Shared app structure for the BNB Chain apps; each app sets its tokens on :root and its own layout. */
* { box-sizing: border-box; margin: 0; padding: 0 }
[hidden] { display: none !important }
html { background: var(--bg); color-scheme: dark } body { background: var(--bg); color: var(--text); font: 14px/1.5 var(--font); -webkit-font-smoothing: antialiased; font-variant-numeric: tabular-nums; min-height: 100vh }
a { color: inherit; text-decoration: none; cursor: pointer } button, input, textarea, select { font: inherit; color: inherit } button { cursor: pointer; border: 0; background: none } em, i { font-style: normal }
.muted { color: var(--muted) } .mono { font-family: var(--mono) } .acc { color: var(--acc) } .up { color: var(--up) } .down { color: var(--down) } .small { font-size: 12px }
* { scrollbar-width: thin; scrollbar-color: var(--line2) transparent }
.btn { height: 40px; padding: 0 16px; border-radius: var(--rb); font-weight: 600; display: inline-flex; align-items: center; justify-content: center; border: 1px solid var(--line2); transition: opacity .15s, background .15s; white-space: nowrap }
.btn.main { background: var(--acc); color: var(--on-acc); border-color: transparent } .btn.main:hover { opacity: .88 } .btn[disabled] { opacity: .38; cursor: not-allowed }
.btn.line:hover:not([disabled]) { background: rgba(255,255,255,.05) } .btn.sm { height: 32px; padding: 0 12px; font-size: 13px } .btn.wide { width: 100% }
.top { position: sticky; top: 0; z-index: 10; height: 62px; display: flex; align-items: center; gap: 28px; padding: 0 max(20px, calc((100vw - var(--appw, 1240px)) / 2)); background: var(--barbg); backdrop-filter: blur(14px); border-bottom: 1px solid var(--line) }
.logo { display: flex; align-items: center; gap: 9px; font: 600 19px var(--head); letter-spacing: -.02em } .logo img { width: 26px; height: 26px; object-fit: contain } .logo span { transform: translateY(-1px) }
.top nav { display: flex; gap: 2px } .top nav a { height: 34px; display: inline-flex; align-items: center; padding: 0 13px; border-radius: var(--rb); color: var(--muted); font-weight: 500 } .top nav a.on { color: var(--text); background: var(--s2) } .top nav a:hover { color: var(--text) }
.top .right { margin-left: auto; display: flex; gap: 8px; align-items: center }
.net { display: inline-flex; align-items: center; gap: 7px; height: 40px; padding: 0 13px; border-radius: var(--rb); border: 1px solid var(--line); color: var(--muted); font-size: 13px } .net img { width: 16px; height: 16px }
.panel { background: var(--s1); border: 1px solid var(--line); border-radius: var(--r) }
.pad { padding: 20px }
h1.t { font: var(--h1w) 34px var(--head); letter-spacing: -.03em } h2.t { font: var(--h1w) 22px var(--head); letter-spacing: -.02em }
.f { display: block; margin-top: 14px; position: relative } .f > span:first-child { display: block; font-size: 12px; color: var(--muted); margin-bottom: 6px }
.f .bal { position: absolute; right: 0; top: 0; font: 12px var(--mono); color: var(--muted); cursor: pointer }
.f > input, .f > textarea, .f > select, .in { width: 100%; border-radius: var(--ri); border: 1px solid var(--line); background: var(--inbg); outline: none }
.f > input, .f > select { height: 46px; padding: 0 14px; font: 13px var(--mono) } .f > textarea { padding: 10px 14px; font: 13px var(--mono); resize: vertical }
.f > input:focus, .f > textarea:focus, .in:focus-within { border-color: var(--focus) }
.in { height: 50px; display: flex; align-items: center; padding-right: 12px } .in input { flex: 1; min-width: 0; height: 100%; padding: 0 14px; border: 0; background: none; outline: none; font: 400 20px var(--mono) } .unit { color: var(--muted); font: 13px var(--mono) }
.row2 { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 10px } .row3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px } .row2 > *, .row3 > * { min-width: 0 }
.seg { display: flex; gap: 2px; padding: 3px; border-radius: var(--ri); background: var(--inbg); border: 1px solid var(--line) } .seg a { flex: 1; height: 36px; display: flex; align-items: center; justify-content: center; padding: 0 10px; border-radius: calc(var(--ri) - 3px); color: var(--muted); font-weight: 500; white-space: nowrap } .seg a.on { background: var(--s3); color: var(--text) }
.tog { display: flex; gap: 12px; align-items: flex-start; margin-top: 14px; cursor: pointer } .tog input { display: none }
.tog .sw { width: 40px; height: 22px; border-radius: 999px; background: var(--s3); position: relative; flex: none; transition: background .2s; margin-top: 1px } .tog .sw::after { content: ""; position: absolute; top: 3px; left: 3px; width: 16px; height: 16px; border-radius: 50%; background: #fff; transition: transform .2s }
.tog input:checked + .sw { background: var(--accdim) } .tog input:checked + .sw::after { transform: translateX(18px) }
.tog b { display: block; font-weight: 600 } .tog small { display: block; color: var(--muted); font-size: 12px }
.go { width: 100%; height: 52px; margin-top: 18px; font-size: 15px }
.note { margin-top: 10px; color: var(--muted); font-size: 12px; text-align: center }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 9px 16px } .kv span { color: var(--muted) } .kv b { font: 500 13px var(--mono); text-align: right; word-break: break-all }
.bar2 { height: 8px; border-radius: 8px; background: var(--s3); overflow: hidden } .bar2 i { display: block; height: 100%; background: var(--acc); border-radius: 8px }
.tag { display: inline-block; padding: 3px 9px; border-radius: 999px; font: 600 11px var(--font); background: var(--s3); color: var(--muted); white-space: nowrap } .tag.on { background: var(--accbg); color: var(--acc) } .tag.bad { background: rgba(242,54,116,.12); color: var(--down) } .tag.ok { background: rgba(60,227,171,.12); color: var(--up) }
.coin { display: inline-flex; align-items: center; gap: 9px; font: 600 14px var(--font); min-width: 0 } .coin img { width: 26px; height: 26px; border-radius: 50%; object-fit: cover; flex: none }
.pick { width: 100%; height: 52px; display: flex; align-items: center; gap: 10px; padding: 0 14px; border-radius: var(--ri); border: 1px solid var(--line); background: var(--inbg); text-align: left } .pick:hover { border-color: var(--line2) }
.pick img { width: 28px; height: 28px; border-radius: 50%; object-fit: cover } .pick b { font-size: 15px } .pick small { margin-left: auto; color: var(--muted); font: 12px var(--mono) }
.car { width: 8px; height: 8px; border-right: 1.5px solid var(--muted); border-bottom: 1.5px solid var(--muted); transform: rotate(45deg) translateY(-3px); margin-left: 6px }
.menu { margin-top: 6px; border: 1px solid var(--line2); border-radius: var(--ri); background: var(--s2); overflow: hidden }
.menu input { width: 100%; height: 42px; padding: 0 12px; border: 0; border-bottom: 1px solid var(--line); background: none; outline: none }
.menu .list { max-height: 300px; overflow: auto } .menu .list a { display: flex; align-items: center; gap: 10px; padding: 9px 12px } .menu .list a:hover { background: var(--s3) }
.menu .list img { width: 26px; height: 26px; border-radius: 50%; object-fit: cover } .menu .list b { display: block } .menu .list small { display: block; color: var(--muted); font-size: 11px } .menu .list .r { margin-left: auto; text-align: right; font: 12px var(--mono); color: var(--muted) }
.empty { padding: 60px 20px; text-align: center; color: var(--muted); border: 1px dashed var(--line2); border-radius: var(--r) } .empty b { display: block; font: var(--h1w) 22px var(--head); color: var(--text); margin-bottom: 6px } .empty .btn { margin-top: 16px }
.toast { position: fixed; left: 50%; bottom: 22px; transform: translate(-50%, 20px); opacity: 0; background: var(--s2); border: 1px solid var(--line2); border-radius: var(--ri); padding: 12px 18px; z-index: 40; transition: .25s; pointer-events: none; max-width: 92vw } .toast.on { opacity: 1; transform: translate(-50%, 0) } .toast.bad { border-color: rgba(242,54,116,.6) }
@media (max-width: 920px) { .top nav, .net { display: none } .row2, .row3 { grid-template-columns: 1fr } }
