/* Kyma app — builds on site.css tokens */
body.app { min-height: 100vh; background: var(--bg); }
.app-stone { position: fixed; inset: 0; z-index: -1; background: url('https://images.unsplash.com/photo-1581710515207-e12b6e176779?w=2200&q=72&auto=format&fit=crop') center / cover; }
.app-stone::after { content: ''; position: absolute; inset: 0; background: rgba(255, 255, 255, .42); }

/* bar */
.abar { position: sticky; top: 0; z-index: 50; background: rgba(230, 228, 223, .84); -webkit-backdrop-filter: blur(14px) saturate(1.1); backdrop-filter: blur(14px) saturate(1.1); border-bottom: 1px solid var(--line); }
.abar-in { max-width: 1320px; margin: 0 auto; padding: 0 var(--gut); height: 68px; display: flex; align-items: center; gap: 22px; }
.atabs { position: relative; display: flex; padding: 4px; margin-left: 10px; border-radius: 999px; background: rgba(20, 20, 18, .06); isolation: isolate; }
.atabs a { position: relative; z-index: 1; height: 36px; display: inline-flex; align-items: center; padding: 0 18px; border-radius: 999px; font-size: 14.5px; font-weight: 500; color: var(--ink-2); transition: color .4s var(--ease); }
.atabs a.on { color: var(--paper); }
.abar-right { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.wallet-btn { gap: 8px; }
.wb-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--paper); opacity: 0; width: 0; transition: opacity .3s, width .3s; }
.wallet-btn.connected { background: var(--paper); color: var(--ink); border: 1px solid var(--line-2); }
.wallet-btn.connected .wb-dot { opacity: 1; width: 7px; background: var(--up); }
.wallet-btn.wrong .wb-dot { opacity: 1; width: 7px; background: var(--down); }

main { padding: 34px 0 90px; }
.app .wrap { max-width: 1320px; }
.view { animation: viewIn .7s var(--ease) both; }
@keyframes viewIn { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
.rise { animation: rise .9s var(--ease) both; animation-delay: calc(var(--d, 0) * 80ms); }
@keyframes rise { from { opacity: 0; transform: translateY(22px); } to { opacity: 1; transform: none; } }

.a-h1 { font-weight: 500; font-size: clamp(34px, 4vw, 54px); line-height: 1; letter-spacing: -.04em; margin-top: 14px; }
.card-head { display: flex; align-items: baseline; justify-content: space-between; padding: 20px 22px 14px; }
.card-head h2, .form-head h2 { margin: 0; font-size: 22px; font-weight: 500; letter-spacing: -.025em; }
.card-head .muted { font-size: 12px; }

/* intro */
.intro { display: grid; grid-template-columns: 1.3fr 1fr; gap: 36px; align-items: end; padding: 30px 30px 28px; }
.intro .sub { max-width: 520px; font-size: 16.5px; }
.intro-stats { display: grid; grid-template-columns: 1fr 1fr; border-top: 1px solid var(--line); }
.intro-stats > div { padding: 14px 0 4px; display: flex; flex-direction: column; gap: 6px; }
.intro-stats > div:nth-child(even) { padding-left: 18px; border-left: 1px solid var(--line); }
.intro-stats > div:nth-child(n+3) { border-top: 1px solid var(--line); padding-top: 14px; }
.intro-stats span { font-family: var(--mono); font-size: 11.5px; letter-spacing: .05em; text-transform: uppercase; color: var(--ink-3); }
.intro-stats b { font-size: 22px; font-weight: 500; letter-spacing: -.02em; }

/* vault grid */
.vgrid { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 14px; margin-top: 14px; align-items: start; }
.table-scroll { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
th { font-family: var(--mono); font-weight: 400; font-size: 11px; letter-spacing: .05em; text-transform: uppercase; color: var(--ink-3); text-align: left; padding: 0 14px 12px; white-space: nowrap; }
th.r, td.r { text-align: right; }
th button { font: inherit; color: inherit; letter-spacing: inherit; text-transform: inherit; display: inline-flex; align-items: center; gap: 6px; }
th button.on { color: var(--ink); }
th button.on::after { content: ''; width: 0; height: 0; border-left: 4px solid transparent; border-right: 4px solid transparent; border-top: 5px solid currentColor; transition: transform .3s; }
th button.on.asc::after { transform: rotate(180deg); }
td { padding: 0 12px; height: 70px; border-top: 1px solid var(--line); white-space: nowrap; font-size: 15px; }
tbody tr { transition: background-color .3s var(--ease); }
tbody tr:hover { background: rgba(20, 20, 18, .025); }
.vtable th:first-child, .vtable td:first-child, .ptable th:first-child, .ptable td:first-child { padding-left: 22px; }
.vtable th:last-child, .vtable td:last-child, .ptable th:last-child, .ptable td:last-child { padding-right: 22px; }
.vtable tbody tr { cursor: pointer; }
.vtable tbody tr.sel { background: rgba(20, 20, 18, .04); }
.vtable tbody tr.sel td:first-child { box-shadow: inset 3px 0 0 var(--ink); }
.vname { display: flex; align-items: center; gap: 12px; }
.vname img, .mname img { width: 34px; height: 34px; border-radius: 50%; background: #fff; box-shadow: 0 0 0 1px var(--line); flex: none; }
.vname b, .mname b { display: block; font-weight: 600; font-size: 15.5px; letter-spacing: -.01em; }
.vname em, .mname em { display: block; font-style: normal; font-size: 12.5px; color: var(--ink-3); }
.mono-cell { font-family: var(--mono); font-variant-numeric: tabular-nums; font-size: 14px; }
.soon { font-family: var(--font); display: inline-flex; align-items: center; gap: 7px; height: 26px; padding: 0 11px; border-radius: 999px; border: 1px solid var(--line-2); font-size: 12px; color: var(--ink-2); background: rgba(247, 246, 242, .7); }
.soon::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: var(--ink-3); animation: soonPulse 2.4s var(--ease-io) infinite; }
@keyframes soonPulse { 50% { opacity: .25; } }
.vtable .mono-cell { font-size: 13px; }
.vtable td { padding: 0 10px; }
.ext { display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 30px; min-width: 30px; padding: 0 9px; border-radius: 999px; border: 1px solid var(--line); font-size: 12.5px; color: var(--ink-2); transition: border-color .3s, color .3s, background-color .3s; }
.ext:hover { border-color: var(--ink); color: var(--ink); background: var(--paper); }
.ext svg { width: 11px; height: 11px; }

/* form */
.form-card { position: sticky; top: 86px; padding: 20px 22px 22px; }
.form-head { display: flex; align-items: center; justify-content: space-between; gap: 14px; }
.seg.mini { width: 200px; }
.seg.mini button { height: 34px; font-size: 13.5px; padding: 0 10px; }
.form-viz { margin: 16px -4px 0; padding: 14px 6px 6px; border-radius: 16px; background: rgba(20, 20, 18, .035); }
.form-note { margin-top: 10px; font-size: 13.5px; line-height: 1.45; color: var(--ink-2); }
.form-note b { color: var(--ink); font-weight: 600; }
.fee-viz { margin: 18px 0 4px; padding: 16px 10px 8px; border-radius: 18px; background: rgba(20, 20, 18, .035); }
.flabel { display: block; margin-top: 18px; margin-bottom: 8px; font-family: var(--mono); font-size: 11px; letter-spacing: .05em; text-transform: uppercase; color: var(--ink-3); }
.select { position: relative; }
.select-btn { width: 100%; display: flex; align-items: center; gap: 12px; padding: 10px 14px; border-radius: 16px; border: 1px solid var(--line-2); background: var(--paper); text-align: left; transition: border-color .3s; }
.select-btn:hover, .select.open .select-btn { border-color: var(--ink); }
.select-btn img, .select-list img { width: 30px; height: 30px; border-radius: 50%; flex: none; }
.select-btn .st, .select-list .st { flex: 1; min-width: 0; }
.select-btn b, .select-list b { display: block; font-weight: 600; font-size: 15px; }
.select-btn em, .select-list em { display: block; font-style: normal; font-size: 12.5px; color: var(--ink-3); }
.select-btn .caret { width: 12px; height: 12px; transition: transform .4s var(--ease); }
.select.open .caret { transform: rotate(180deg); }
.select-list { position: absolute; z-index: 20; left: 0; right: 0; top: calc(100% + 6px); padding: 6px; border-radius: 16px; border: 1px solid var(--line-2); background: var(--paper); opacity: 0; transform: translateY(-6px) scale(.98); transform-origin: 50% 0; pointer-events: none; transition: opacity .25s var(--ease), transform .35s var(--ease); }
.select.open .select-list { opacity: 1; transform: none; pointer-events: auto; }
.select-list li { display: flex; align-items: center; gap: 12px; padding: 9px 10px; border-radius: 11px; cursor: pointer; transition: background-color .2s; }
.select-list li:hover, .select-list li[aria-selected="true"] { background: rgba(20, 20, 18, .05); }
.select-list .tag-r { font-family: var(--mono); font-size: 11px; color: var(--ink-3); }
.native-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 10px; font-size: 13px; color: var(--ink-2); animation: rise .5s var(--ease) both; }
.native-row[hidden] { display: none; }
.mini-seg { display: inline-flex; padding: 3px; border-radius: 999px; background: rgba(20, 20, 18, .06); }
.mini-seg button { display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 12px 0 5px; border-radius: 999px; font-size: 13px; font-weight: 500; color: var(--ink-2); transition: background-color .35s var(--ease), color .35s var(--ease); }
.mini-seg button img { width: 20px; height: 20px; border-radius: 50%; }
.mini-seg button[aria-pressed="true"] { background: var(--paper); color: var(--ink); box-shadow: 0 0 0 1px var(--line-2); }
.amount { display: flex; align-items: center; gap: 10px; padding: 8px 10px 8px 16px; border-radius: 16px; border: 1px solid var(--line-2); background: var(--paper); transition: border-color .3s; }
.amount:focus-within { border-color: var(--ink); }
.amount input { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; font-family: var(--mono); font-size: 30px; font-weight: 500; letter-spacing: -.03em; color: var(--ink); padding: 6px 0; }
.amount input::placeholder { color: var(--ink-3); opacity: .55; }
.amount-asset { display: inline-flex; align-items: center; gap: 8px; height: 38px; padding: 0 12px 0 6px; border-radius: 999px; background: rgba(20, 20, 18, .05); font-weight: 600; font-size: 14px; }
.amount-asset img { width: 26px; height: 26px; border-radius: 50%; }
.amount-meta { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-top: 8px; font-size: 12.5px; }
.pcts { display: inline-flex; gap: 4px; }
.pcts button { height: 26px; padding: 0 9px; border-radius: 999px; border: 1px solid var(--line); font-size: 12px; color: var(--ink-2); transition: all .25s var(--ease); }
.pcts button:hover { border-color: var(--ink); color: var(--ink); }
.pcts button:disabled { opacity: .4; pointer-events: none; }
.wrapbox { display: flex; flex-direction: column; align-items: flex-start; gap: 12px; margin-top: 14px; padding: 14px 14px 14px 16px; border-radius: 16px; background: rgba(20, 20, 18, .045); animation: rise .6s var(--ease) both; }
.wrapbox b { font-size: 14px; font-weight: 600; }
.wrapbox p { margin-top: 2px; font-size: 13px; color: var(--ink-2); line-height: 1.4; }
.wrapbox .btn { flex: none; }
.facts { margin: 18px 0 18px; border-top: 1px solid var(--line); }
.facts > div { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 11px 0; border-bottom: 1px solid var(--line); }
.facts dt { font-size: 13.5px; color: var(--ink-2); }
.facts dd { margin: 0; font-size: 13.5px; text-align: right; }
.btn-block { width: 100%; justify-content: center; height: 54px; font-size: 16px; }
.btn[disabled], .btn.dim { opacity: .45; pointer-events: none; }
.btn.busy { pointer-events: none; }
/* what the last transaction did, read from its receipt; stays until the next edit */
.done-line { display: flex; align-items: center; gap: 9px; margin: 12px 2px 0; padding: 11px 14px; border-radius: 14px; background: rgba(29, 122, 82, .08); color: var(--ink); font-size: 14px; line-height: 1.4; }
.done-line[hidden] { display: none; }
.done-line .ok { flex: none; display: grid; place-items: center; width: 20px; height: 20px; border-radius: 50%; background: var(--up); }
.done-line .ok::after { content: ''; width: 9px; height: 5px; border-left: 2px solid #fff; border-bottom: 2px solid #fff; transform: translateY(-1px) rotate(-45deg); }
.done-line a { margin-left: auto; color: var(--ink-2); text-decoration: underline; text-underline-offset: 2px; white-space: nowrap; }
.btn.busy::after { content: ''; width: 14px; height: 14px; margin-left: 4px; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent; animation: spin .8s linear infinite; }

/* swap */
.sgrid { display: grid; grid-template-columns: minmax(0, 480px) minmax(0, 1fr); gap: 14px; align-items: start; justify-content: center; max-width: 1080px; }
.swap-card { padding: 18px 18px 20px; }
.swap-head { display: flex; align-items: center; justify-content: space-between; padding: 2px 4px 14px; }
.swap-head h2 { margin: 0; font-size: 22px; font-weight: 500; letter-spacing: -.025em; }
.slip { display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 12px; border-radius: 999px; border: 1px solid var(--line); font-size: 12.5px; color: var(--ink-2); transition: border-color .3s; }
.slip:hover { border-color: var(--ink); }
.slip b { font-weight: 500; color: var(--ink); }
.sbox { padding: 14px 16px; border-radius: 18px; background: rgba(20, 20, 18, .045); transition: background-color .3s; }
.sbox:focus-within { background: rgba(20, 20, 18, .07); }
.sbox-top, .sbox-bot { display: flex; justify-content: space-between; align-items: center; gap: 10px; font-size: 12.5px; min-height: 18px; }
.sbox-row { display: flex; align-items: center; gap: 10px; margin: 6px 0; }
.sbox-row input, .sout { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; font-family: var(--mono); font-size: 32px; font-weight: 500; letter-spacing: -.03em; color: var(--ink); padding: 2px 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sbox-row input::placeholder { color: var(--ink-3); opacity: .5; }
.sout.loading { color: var(--ink-3); animation: soonPulse 1.2s var(--ease-io) infinite; }
/* finding the best price: a small spinning circle by the amount and on the button */
.sout.finding::after { content: ''; display: inline-block; width: 20px; height: 20px; margin-left: 14px; vertical-align: -1px; border-radius: 50%; border: 2.5px solid var(--ink-3); border-right-color: transparent; animation: spin .8s linear infinite; }
.btn.finding::after { content: ''; width: 16px; height: 16px; margin-left: 10px; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent; animation: spin .8s linear infinite; }
.btn.finding.dim { opacity: .7; }
.sout.pop { animation: pop .5s var(--ease); }
@keyframes pop { 0% { transform: translateY(6px); opacity: .3; } 100% { transform: none; opacity: 1; } }
.maxb { height: 24px; padding: 0 9px; border-radius: 999px; border: 1px solid var(--line-2); font-size: 11.5px; color: var(--ink-2); }
.maxb:hover { border-color: var(--ink); color: var(--ink); }
.tsel { position: relative; flex: none; }
.tsel > button { display: inline-flex; align-items: center; gap: 8px; height: 40px; padding: 0 12px 0 6px; border-radius: 999px; background: var(--paper); border: 1px solid var(--line-2); font-weight: 600; font-size: 15px; transition: border-color .3s; }
.tsel > button:hover { border-color: var(--ink); }
.tsel img { width: 28px; height: 28px; border-radius: 50%; }
.tsel ul { position: absolute; right: 0; top: calc(100% + 6px); z-index: 20; min-width: 200px; padding: 6px; border-radius: 16px; border: 1px solid var(--line-2); background: var(--paper); opacity: 0; transform: translateY(-6px) scale(.98); transform-origin: 100% 0; pointer-events: none; transition: opacity .25s var(--ease), transform .35s var(--ease); }
.tsel.open ul { opacity: 1; transform: none; pointer-events: auto; }
.tsel li { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 11px; cursor: pointer; font-size: 14px; }
.tsel li:hover, .tsel li[aria-selected="true"] { background: rgba(20, 20, 18, .05); }
.tsel li b { display: block; font-weight: 600; }
.tsel li em { display: block; font-style: normal; font-size: 12px; color: var(--ink-3); }
.flip { display: grid; place-items: center; width: 40px; height: 40px; margin: -12px auto; position: relative; z-index: 2; border-radius: 12px; background: var(--paper); border: 1px solid var(--line-2); color: var(--ink); transition: transform .5s var(--ease), border-color .3s; }
.flip:hover { border-color: var(--ink); }
.flip svg { width: 18px; height: 18px; }
.flip.spin { transform: rotate(180deg); }
.sfacts { margin-top: 16px; }
.sfacts dd { display: flex; align-items: center; justify-content: flex-end; gap: 6px; flex-wrap: wrap; }
.rchip { display: inline-flex; align-items: center; gap: 5px; height: 22px; padding: 0 8px 0 3px; border-radius: 999px; border: 1px solid var(--line); font-family: var(--mono); font-size: 11px; }
.rchip img { width: 16px; height: 16px; border-radius: 50%; }
.rarrow { color: var(--ink-3); font-size: 12px; }
.fund-card { padding: 24px 24px 20px; }
.fund-h { font-size: 30px; margin-top: 12px; }
.fund-card .sub { font-size: 15px; max-width: 420px; }
.fund-list { margin-top: 18px; border-top: 1px solid var(--line); }
.fund-list li { display: grid; grid-template-columns: 36px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 14px 0; border-bottom: 1px solid var(--line); transition: background-color .4s var(--ease); }
.fund-list li img { width: 36px; height: 36px; border-radius: 50%; }
.fund-list b { display: block; font-size: 15px; font-weight: 600; }
.fund-list em { display: block; font-style: normal; font-size: 12.5px; color: var(--ink-3); }
.fund-list .fv { text-align: right; font-family: var(--mono); font-size: 13px; }
.fund-list .fv small { display: block; font-size: 11.5px; color: var(--ink-3); }
.fund-list li.earn { background: linear-gradient(90deg, rgba(20, 20, 18, .05), transparent); }
.fund-list li.earn b::after { content: 'earns this fee'; display: inline-block; white-space: nowrap; margin-left: 8px; padding: 2px 8px; border-radius: 999px; background: var(--ink); color: var(--paper); font-size: 10.5px; font-weight: 500; vertical-align: 2px; }
@media (max-width: 480px) { .fund-list li.earn b::after { content: 'earns fee'; } .fund-list em { font-size: 12px; } }

/* trade */
.tgrid { display: grid; grid-template-columns: 300px minmax(0, 1fr) 350px; gap: 14px; align-items: start; }
.mlist { display: flex; flex-direction: column; max-height: calc(100vh - 140px); position: sticky; top: 86px; overflow: hidden; }
.mlist-head { padding: 14px 14px 10px; border-bottom: 1px solid var(--line); }
.search { display: flex; align-items: center; gap: 9px; height: 40px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--line-2); background: var(--paper); color: var(--ink-3); transition: border-color .3s; }
.search:focus-within { border-color: var(--ink); }
.search svg { width: 15px; height: 15px; flex: none; }
.search input { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; font: inherit; font-size: 14.5px; color: var(--ink); }
.chips { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 10px; }
.chips button { height: 28px; padding: 0 11px; border-radius: 999px; font-size: 12.5px; border: 1px solid var(--line); color: var(--ink-2); transition: all .3s var(--ease); }
.chips button:hover { border-color: var(--line-2); color: var(--ink); }
.chips button.on { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.mlist .chips { flex-wrap: nowrap; gap: 4px; }
.mlist .chips button { padding: 0 9px; font-size: 12px; }
.mrows { overflow-y: auto; padding: 6px; }
.mrow { width: 100%; display: grid; grid-template-columns: 30px 1fr auto; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 12px; text-align: left; transition: background-color .25s; }
.mrow:hover { background: rgba(20, 20, 18, .04); }
.mrow.on { background: rgba(20, 20, 18, .07); }
.mrow img { width: 30px; height: 30px; border-radius: 50%; background: #fff; box-shadow: 0 0 0 1px var(--line); }
.mrow b { display: block; font-size: 14px; font-weight: 600; }
.mrow em { display: block; font-style: normal; font-size: 12px; color: var(--ink-3); }
.mrow .mp { text-align: right; font-family: var(--mono); font-size: 13px; }
.mrow .mp small { display: block; font-size: 11.5px; }
.tbook { padding: 18px 20px 16px; }
.tbook-head { display: flex; align-items: center; gap: 12px; padding-bottom: 6px; }
.tbook-head img { width: 36px; height: 36px; border-radius: 50%; background: #fff; box-shadow: 0 0 0 1px var(--line); transition: transform .6s var(--ease); }
.tbook-head img.swap { animation: swapIn .6s var(--ease); }
@keyframes swapIn { from { transform: scale(.6) rotate(-30deg); opacity: 0; } to { transform: none; opacity: 1; } }
.tb-name b { display: block; font-size: 20px; font-weight: 600; letter-spacing: -.02em; }
.tb-name .muted { font-size: 13px; }
.tb-px { margin-left: auto; text-align: right; }
.tb-px b { display: block; font-size: 22px; font-weight: 500; }
.tb-px span { font-size: 12.5px; }
.tbook .lvl { height: 23px; }
.tticket { padding: 18px 22px 20px; display: flex; flex-direction: column; position: sticky; top: 86px; }
.size-coin { font-size: 13px; margin-top: 2px; }
.tticket .route { margin-bottom: 14px; }
.hl-acct { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; padding: 10px 0 14px; font-size: 13px; color: var(--ink-2); border-top: 1px solid var(--line); }
.hl-acct b { font-size: 13px; font-weight: 500; color: var(--ink); text-align: right; }
.hl-move { margin: -4px 0 14px; padding: 10px 12px; border-radius: 12px; background: rgba(20, 20, 18, .045); font-size: 12.5px; color: var(--ink-2); }
.hl-move-row { display: flex; gap: 8px; margin-top: 8px; }
.hl-move input { flex: 1; min-width: 0; height: 34px; padding: 0 10px; border-radius: 10px; border: 1px solid var(--line-2); background: var(--paper); font-family: var(--mono); font-size: 13px; color: var(--ink); outline: 0; }
.hl-move input:focus { border-color: var(--ink); }
.hl-move .btn { height: 34px; padding: 0 14px; }
.tticket .ticket-note a { text-decoration: underline; text-underline-offset: 2px; color: var(--ink-2); }
.hl-pos { margin: 0 0 14px; padding: 12px 14px 2px; border-radius: 16px; background: rgba(20, 20, 18, .05); box-shadow: inset 0 0 0 1px var(--line); }
.hl-pos-head { display: flex; justify-content: space-between; font-size: 12px; font-family: var(--mono); letter-spacing: .04em; text-transform: uppercase; color: var(--ink-3); }
.hl-pos-head a { text-transform: none; letter-spacing: 0; }
.hl-pos li { display: grid; grid-template-columns: 26px minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--line); }
.hl-pos li:last-child { border-bottom: 0; }
.hl-pos li img { width: 26px; height: 26px; border-radius: 50%; background: #fff; box-shadow: 0 0 0 1px var(--line); }
.hl-pos li b { display: block; font-size: 14px; font-weight: 600; }
.hl-pos li em { display: block; font-style: normal; font-family: var(--mono); font-size: 11.5px; color: var(--ink-3); }
.hl-pos li .pnl { display: block; font-family: var(--mono); font-size: 12px; }
.hl-pos li button { height: 32px; padding: 0 16px; border-radius: 999px; border: 0; font-size: 13px; font-weight: 600; background: var(--ink); color: var(--paper); transition: opacity .3s; }
.hl-pos li button:hover { opacity: .85; }
.hl-pos li button:disabled { opacity: .5; }
.up-t { color: var(--up); }
.down-t { color: var(--down); }

/* prices */
.phead { display: flex; align-items: flex-end; justify-content: space-between; gap: 30px; margin-bottom: 18px; }
.ptools { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; }
.ptools .search { width: 300px; }
.pcard { padding-top: 14px; }
.ptable td { height: 64px; }
.ptable .n { width: 40px; color: var(--ink-3); font-family: var(--mono); font-size: 12px; }
.mname { display: flex; align-items: center; gap: 12px; }
.mname .tag { font-weight: 400; font-family: var(--mono); font-size: 10.5px; letter-spacing: .05em; text-transform: uppercase; color: var(--ink-3); border: 1px solid var(--line); border-radius: 999px; padding: 2px 8px; margin-left: 4px; }
.ptable .pxc { transition: color .9s var(--ease); }
.ptable .pxc.up { color: var(--up); transition: none; }
.ptable .pxc.down { color: var(--down); transition: none; }
.pspark { width: 130px; height: 34px; display: inline-block; vertical-align: middle; }
.pspark path { fill: none; stroke-width: 1.4; vector-effect: non-scaling-stroke; stroke-linejoin: round; }
.pspark .area { stroke: none; }
.pspark.up path.line { stroke: var(--up); }
.pspark.down path.line { stroke: var(--down); }
.pspark.up .area { fill: rgba(29, 122, 82, .08); }
.pspark.down .area { fill: rgba(178, 63, 56, .08); }
.trade-link { display: inline-flex; align-items: center; height: 30px; padding: 0 13px; border-radius: 999px; border: 1px solid var(--line-2); font-size: 12.5px; font-weight: 500; transition: all .3s var(--ease); }
.trade-link:hover { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.ptable tbody tr.in { animation: rowIn .7s var(--ease) both; animation-delay: calc(var(--i, 0) * 18ms); }
@keyframes rowIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.empty-row td { height: 120px; text-align: center; color: var(--ink-3); }

/* skeleton */
.sk { display: inline-block; height: 12px; width: 70px; border-radius: 6px; background: linear-gradient(90deg, rgba(20,20,18,.06), rgba(20,20,18,.12), rgba(20,20,18,.06)); background-size: 200% 100%; animation: sk 1.4s linear infinite; vertical-align: middle; }
@keyframes sk { to { background-position: -200% 0; } }

/* modal */
.modal { position: fixed; inset: 0; z-index: 90; display: grid; place-items: center; padding: 20px; background: rgba(20, 20, 18, .28); animation: fadeIn .3s var(--ease) both; }
.modal[hidden] { display: none; }
@keyframes fadeIn { from { opacity: 0; } }
.modal-card { width: min(420px, 100%); padding: 22px; animation: rise .5s var(--ease) both; }
.modal-head { display: flex; align-items: center; justify-content: space-between; }
.modal-head h2 { margin: 0; font-size: 22px; font-weight: 500; letter-spacing: -.02em; }
.modal-card > p { margin-top: 10px; font-size: 14px; line-height: 1.5; }
.x { position: relative; width: 32px; height: 32px; border-radius: 50%; border: 1px solid var(--line); }
.x::before, .x::after { content: ''; position: absolute; left: 50%; top: 50%; width: 12px; height: 1.5px; background: var(--ink); transform: translate(-50%, -50%) rotate(45deg); }
.x::after { transform: translate(-50%, -50%) rotate(-45deg); }
.wlist { margin-top: 16px; display: grid; gap: 8px; }
.wlist button { width: 100%; display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 14px; border: 1px solid var(--line-2); background: var(--paper); font-size: 15px; font-weight: 500; text-align: left; transition: border-color .3s, transform .4s var(--ease); }
.wlist button:hover { border-color: var(--ink); transform: translateY(-1px); }
.wlist img { width: 28px; height: 28px; border-radius: 8px; }
.wlist .wapp { display: flex; align-items: center; justify-content: space-between; padding: 14px 16px; border-radius: 14px; border: 1px solid var(--line-2); background: var(--paper); font-size: 15px; font-weight: 500; transition: border-color .3s; }
.wlist .wapp:hover { border-color: var(--ink); }
.wlist .wapp span { color: var(--ink-3); }
.wlist .none { font-size: 14px; color: var(--ink-2); line-height: 1.5; }

/* toast with link */
.toast { display: flex; align-items: center; gap: 12px; max-width: min(520px, calc(100vw - 32px)); }
.toast a { text-decoration: underline; text-underline-offset: 2px; }

@media (max-width: 1240px) {
  .tgrid { grid-template-columns: 250px minmax(0, 1fr) 310px; }
  .vgrid { grid-template-columns: minmax(0, 1fr) 350px; }
  .vtable th:first-child, .vtable td:first-child { padding-left: 18px; }
  .vname img { width: 30px; height: 30px; }
}
@media (max-width: 1000px) {
  .tgrid { grid-template-columns: 250px minmax(0, 1fr); }
  .tticket { grid-column: 1 / -1; position: static; }
}
@media (max-width: 960px) {
  .abar-in { gap: 12px; }
  .chip .chip-label, .chip-logo { display: none; }
  .intro { grid-template-columns: minmax(0, 1fr); gap: 18px; padding: 22px; }
  .vgrid { grid-template-columns: minmax(0, 1fr); }
  .sgrid { grid-template-columns: minmax(0, 1fr); }
  .form-card { position: static; }
  .tgrid { grid-template-columns: minmax(0, 1fr); }
  .mlist { position: static; max-height: 360px; }
  .phead { flex-direction: column; align-items: flex-start; }
  .ptools { align-items: flex-start; }
  .spark-h, .ptable td.spark-c { display: none; }
}
@media (max-width: 640px) {
  .abar-in { padding: 10px 14px; height: auto; flex-wrap: wrap; row-gap: 10px; }
  .atabs { order: 3; width: 100%; margin-left: 0; }
  .atabs a { flex: 1; justify-content: center; padding: 0 6px; font-size: 13.5px; height: 34px; }
  .abar .soon { display: none; }
  .a-h1 { font-size: 32px; }
  .intro-stats b { font-size: 18px; }
  .phead { margin-bottom: 12px; }
  .chip.live { display: none; }
  .wallet-btn { padding: 0 12px; font-size: 13px; }
  .ptools .search { width: 100%; }
  .ptable .n, .ptable th:nth-child(5), .ptable td:nth-child(5) { display: none; }
}
