/* dumpd app layer: live board, coin page, trading, profiles, chat, launch controls */

/* board */
.coin-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.coin-grid.one { grid-template-columns: 1fr; padding: 12px; }
.coin-card.live { position: relative; transition: border-color .25s, transform .4s var(--ease), background .25s; }
.coin-card.live:hover { border-color: var(--red); transform: translateY(-3px); background: #26272c; }
.coin-card.live:hover .cc-img img { transform: scale(1.06) rotate(-1.5deg); }
.cc-img { overflow: hidden; }
.cc-img img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease); }
.cc-meta b { color: var(--ink); font-weight: 500; }
.badge { margin-left: 8px; padding: 2px 6px; border-radius: 3px; font: 500 10px/1.4 var(--f-mono); letter-spacing: .08em; text-transform: uppercase; vertical-align: 2px; }
.badge.grad { background: rgba(255,49,49,.14); color: var(--red); }

/* podium filled slots */
.slot.filled { border-style: solid; padding: 0; }
.slot.filled a { display: flex; align-items: center; gap: 10px; width: 100%; height: 100%; padding: 12px; color: var(--ink); }
.slot-img { flex: none; width: 46px; height: 46px; border-radius: 3px; background: var(--card); overflow: hidden; }
.slot-img img { width: 100%; height: 100%; object-fit: cover; }
.slot.filled .slot-t { text-transform: none; letter-spacing: 0; gap: 3px; min-width: 0; }
.slot.filled .slot-t b { font: 600 13px/1.1 var(--f-text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.slot.filled .slot-t span { color: var(--muted); }
.slot.filled .slot-t em { font-style: normal; color: var(--red); }
.slot.filled .slot-n { font-size: 20px; }

/* tape with real trades */
a.tape-item { color: var(--dim); }
a.tape-item:hover b { color: var(--red); }

/* wallet */
.js-connect.is-connected { font-family: var(--f-mono); font-weight: 500; border-color: var(--red); }
.wallet-menu { position: absolute; z-index: 80; width: 220px; padding: 12px; background: var(--bg-2); border: 1px solid var(--line-2); border-radius: var(--radius); box-shadow: 0 30px 60px -20px #000; animation: pop .3s var(--ease); }
.wm-addr { margin: 8px 0 10px; font: 500 11px/1.4 var(--f-mono); color: var(--muted); word-break: break-all; }
.wm-item { display: block; width: 100%; padding: 9px 8px; border: 0; border-radius: 3px; background: none; text-align: left; font-size: 14px; color: var(--ink); cursor: pointer; }
.wm-item:hover { background: var(--card); color: var(--red); }

/* toasts */
#toasts { position: fixed; z-index: 120; right: 16px; bottom: 16px; display: grid; gap: 8px; max-width: min(380px, calc(100vw - 32px)); }
.toast { padding: 12px 14px; background: var(--bg-2); border: 1px solid var(--line-2); border-left: 3px solid var(--muted); border-radius: var(--radius); font-size: 14px; box-shadow: 0 20px 40px -20px #000; animation: pop .35s var(--ease); transition: opacity .5s, transform .5s; }
.toast.good { border-left-color: var(--ink); } .toast.bad { border-left-color: var(--red); }
.toast a { text-decoration: underline; text-decoration-color: var(--red); }
.toast.out { opacity: 0; transform: translateY(8px); }

/* chat messages + form */
.msg { padding: 10px 0; border-bottom: 1px solid var(--line); }
.msg-top { display: flex; align-items: center; gap: 8px; font: 500 12px/1 var(--f-mono); }
.msg-who { color: hsl(var(--h) 70% 68%); }
.msg-ago { color: var(--dim); }
.msg-report { margin-left: auto; border: 0; background: none; color: var(--dim); font: inherit; cursor: pointer; }
.msg-report:hover { color: var(--red); }
.msg p { margin: 6px 0 0; font-size: 14px; overflow-wrap: anywhere; }
.chat-body { overflow-y: auto; max-height: 520px; }
.chat-form { display: flex; gap: 8px; }
.chat-form input { flex: 1; min-width: 0; height: 38px; padding: 0 10px; background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius); outline: none; }
.chat-form input:focus { border-color: var(--red); }
.chat-form .btn { height: 38px; padding: 0 14px; }

/* launch controls */
.modes { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.mode { display: grid; gap: 6px; padding: 14px; text-align: left; background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius); cursor: pointer; transition: border-color .2s, background .2s; }
.mode b { font: 700 15px/1 var(--f-display); letter-spacing: -.03em; }
.mode span { font-size: 13px; color: var(--muted); line-height: 1.45; }
.mode:hover { border-color: var(--line-2); }
.mode.is-on { border-color: var(--red); background: linear-gradient(160deg, rgba(255,49,49,.12), transparent 70%), var(--bg-2); }
.toggle { display: flex; align-items: center; gap: 10px; margin-top: 12px; font-size: 14px; cursor: pointer; }
.toggle input { position: absolute; opacity: 0; }
.toggle span { position: relative; width: 38px; height: 22px; border-radius: 11px; background: var(--line); transition: background .2s; }
.toggle span::after { content: ""; position: absolute; left: 3px; top: 3px; width: 16px; height: 16px; border-radius: 50%; background: var(--ink); transition: transform .3s var(--ease-snap); }
.toggle input:checked + span { background: var(--red); }
.toggle input:checked + span::after { transform: translateX(16px); }
.toggle input:focus-visible + span { outline: 2px solid var(--red); outline-offset: 3px; }
.toggle i { font-style: normal; color: var(--dim); }
.form-msg { min-height: 20px; margin: 0; font-size: 14px; color: var(--red); }
.steps li[data-state="run"] i { color: var(--ink); }
.steps li[data-state="run"] span::before { animation: pulse 1.2s infinite; }
.steps li[data-state="done"] i { color: var(--muted); }
.steps li[data-state="done"] span { color: var(--muted); }
.steps li[data-state="err"] i { color: var(--red); }

/* coin page */
.coin-loading { color: var(--muted); font: 500 13px/1 var(--f-mono); }
.coin-head { display: grid; grid-template-columns: 120px 1fr auto; gap: 24px; align-items: start; margin-bottom: 24px; }
.ch-img { width: 120px; height: 120px; border-radius: var(--radius); overflow: hidden; background: var(--card); display: grid; place-items: center; border: 1px solid var(--line); }
.ch-img img { width: 100%; height: 100%; object-fit: cover; }
.ch-img svg { width: 60px; height: 60px; opacity: .4; }
.ch-title { margin: 0; font: 800 clamp(28px, 4vw, 52px)/1 var(--f-display); letter-spacing: -.05em; overflow-wrap: anywhere; }
.ch-title span { color: var(--red); font-weight: 500; }
.ch-desc { margin: 10px 0 0; color: var(--muted); max-width: 60ch; }
.ch-links { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.chip.mono, .mono-title { font-family: var(--f-mono); }
a.chip { display: inline-flex; align-items: center; }
.ch-grade { display: flex; gap: 14px; align-items: center; }
.grade { display: grid; place-items: center; width: 84px; height: 84px; border: 2px solid currentColor; border-radius: var(--radius); }
.grade b { font: 800 40px/1 var(--f-display); letter-spacing: -.05em; }
.grade span { font: 500 10px/1 var(--f-mono); letter-spacing: .14em; text-transform: uppercase; margin-top: -10px; }
.g-A, .g-B { color: var(--ink); } .g-C, .g-D { color: #ff9a9a; } .g-E, .g-F { color: var(--red); }
.grade-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; font: 500 12px/1.3 var(--f-mono); color: var(--muted); }
.grade-list b { color: var(--ink); font-weight: 500; }
.coin-stats { display: grid; grid-template-columns: repeat(5, 1fr); gap: 1px; margin-bottom: 24px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.coin-stats div { padding: 14px 16px; background: var(--bg-2); }
.coin-stats b { display: block; margin-top: 8px; font: 700 20px/1.1 var(--f-display); letter-spacing: -.03em; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.coin-grid-wrap, .coin-grid { }
.coin-page .coin-grid { grid-template-columns: minmax(0, 1fr) 340px; gap: 20px; align-items: start; }
.coin-left, .coin-right { display: grid; gap: 20px; min-width: 0; }
.coin-right { position: sticky; top: 108px; }
.chart-card { position: relative; padding: 14px; background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius); }
.chart-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }
.tf { display: flex; gap: 2px; }
.tf button { height: 28px; padding: 0 10px; border: 0; border-radius: 3px; background: none; color: var(--muted); font: 500 12px/1 var(--f-mono); cursor: pointer; }
.tf button:hover { color: var(--ink); }
.tf button.is-on { background: var(--card); color: var(--ink); box-shadow: inset 0 -2px 0 var(--red); }
#chart { display: block; width: 100%; height: 340px; cursor: crosshair; }
.chart-empty { position: absolute; inset: 50px 14px 14px; display: grid; place-items: center; margin: 0; color: var(--dim); font: 500 13px/1.4 var(--f-mono); text-align: center; }
.panel { background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.panel-head { display: flex; justify-content: space-between; align-items: center; padding: 12px 14px; border-bottom: 1px solid var(--line); }
.panel-head h2 { margin: 0; font: 700 15px/1 var(--f-display); letter-spacing: -.03em; }
.panel .chat-body { min-height: 120px; padding: 4px 14px; }
.panel .chat-foot { padding: 12px 14px; border-top: 1px solid var(--line); font-size: 13px; color: var(--muted); }
.pad { padding: 14px; margin: 0; }
.dim { color: var(--dim); }
.table-wrap { overflow-x: auto; }
.tbl { width: 100%; border-collapse: collapse; font: 400 13px/1.4 var(--f-mono); }
.tbl th { padding: 9px 14px; text-align: left; font: 500 11px/1 var(--f-mono); letter-spacing: .1em; text-transform: uppercase; color: var(--dim); border-bottom: 1px solid var(--line); }
.tbl td { padding: 9px 14px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.tbl tr:last-child td { border-bottom: 0; }
.tbl .r { text-align: right; }
.tbl a:hover { color: var(--red); }
.tbl tr.buy .side { color: var(--ink); } .tbl tr.sell .side { color: var(--red); }
.tbl tbody tr { animation: rowin .5s var(--ease); }
@keyframes rowin { from { background: rgba(255,49,49,.1); } }
.trade-card { padding: 14px; background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius); display: grid; gap: 12px; }
.side-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; padding: 4px; background: var(--bg); border-radius: var(--radius); }
.side-tabs button { height: 38px; border: 0; border-radius: 3px; background: none; color: var(--muted); font-weight: 600; cursor: pointer; }
.side-tabs button.is-on { background: var(--card); color: var(--ink); box-shadow: inset 0 -2px 0 var(--ink); }
.side-tabs button.is-on.sell { box-shadow: inset 0 -2px 0 var(--red); color: var(--red); }
.amt { display: flex; align-items: center; border: 1px solid var(--line-2); border-radius: var(--radius); background: var(--bg); transition: border-color .2s; }
.amt:focus-within { border-color: var(--red); }
.amt input { flex: 1; min-width: 0; height: 52px; padding: 0 14px; border: 0; background: none; outline: none; font: 700 22px/1 var(--f-display); letter-spacing: -.03em; }
.amt span { padding-right: 14px; font: 500 13px/1 var(--f-mono); color: var(--muted); }
.quote { margin: 0; font: 500 13px/1.4 var(--f-mono); color: var(--muted); }
.quote b { color: var(--ink); font-weight: 500; }
.btn-red.sell { background: var(--bg); color: var(--red); border-color: var(--red); }
.trade-grad h2 { margin: 0 0 6px; font: 700 22px/1 var(--f-display); letter-spacing: -.04em; color: var(--red); }
.trade-grad p { margin: 0 0 14px; color: var(--muted); }
.fee-big { margin: 0; padding: 14px 14px 6px; color: var(--muted); }
.fee-big b { font: 700 24px/1 var(--f-display); letter-spacing: -.03em; color: var(--ink); }
#feeCard .btn, #feeCard .hint { margin: 8px 14px 14px; width: calc(100% - 28px); }
.curve { padding: 14px; }
.cc-bar.big { height: 10px; margin: 0 0 10px; }
.cc-bar span { transition: width .8s var(--ease); }
.holders { list-style: none; margin: 0; padding: 4px 0; max-height: 420px; overflow-y: auto; font: 400 13px/1.4 var(--f-mono); }
.holders li { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 7px 14px; }
.holders li:nth-child(odd) { background: rgba(255,255,255,.015); }
.holders b { font-weight: 500; }
.holders a:hover { color: var(--red); }
.tag { margin-left: 6px; padding: 1px 5px; border-radius: 3px; background: var(--card); font: normal 500 10px/1.5 var(--f-mono); color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }
.tag.sell { color: var(--red); }
.holders .chip { height: 26px; padding: 0 10px; font-size: 11px; }
.profile-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }

/* docs fee table + legal */
.fee-schedule { margin-top: 56px; }
.sec-title { margin: 0; font: 800 clamp(28px, 3.6vw, 44px)/1 var(--f-display); letter-spacing: -.05em; }
.fee-schedule .page-sub { margin: 10px 0 20px; }
.fees-tbl { background: var(--bg-2); border: 1px solid var(--line); font-family: var(--f-text); font-size: 14px; }
.fees-tbl td { white-space: normal; }
.fees-tbl td:first-child { color: var(--muted); }
.legal-body { max-width: 70ch; }
.legal-body h3 { margin: 28px 0 8px; font: 700 18px/1.2 var(--f-display); letter-spacing: -.03em; }
.legal-body p { margin: 0 0 10px; color: var(--muted); }

@media (max-width: 1100px) {
  .coin-page .coin-grid { grid-template-columns: 1fr; }
  .coin-right { position: static; order: -1; }
  .coin-stats { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 760px) {
  .coin-grid { grid-template-columns: 1fr; }
  .coin-head { grid-template-columns: 76px 1fr; gap: 14px; }
  .ch-img { width: 76px; height: 76px; }
  .ch-grade { grid-column: 1 / -1; }
  .coin-stats { grid-template-columns: repeat(2, 1fr); }
  .coin-stats div:last-child { grid-column: 1 / -1; }
  #chart { height: 260px; }
  .modes, .profile-grid { grid-template-columns: 1fr; }
  .tbl th:nth-child(4), .tbl td:nth-child(4) { display: none; }
}

/* fixes: hidden overlays, grid overflow */
.chart-empty[hidden], .empty-board[hidden], .panel[hidden] { display: none !important; }
.coin-left, .coin-right, .trade-card { grid-template-columns: minmax(0, 1fr); }
.coin-page .coin-grid > * { min-width: 0; }

/* backend not live yet */
#launchBtn.is-soon { background: var(--card); color: var(--muted); box-shadow: none; border: 1px dashed var(--line-2); cursor: default; }
#launchBtn.is-soon::before { display: none; }
.soon-line { color: var(--dim); font: 500 12px/1.4 var(--f-mono); letter-spacing: .04em; }
