:root {
  color-scheme: light;
  font-family: "Inter", "Microsoft YaHei UI", "PingFang SC", sans-serif;
  color: #201b38;
  background: #f7f7fc;
  --rail: #19142e;
  --ink: #201b38;
  --muted: #6b677c;
  --purple: #593ac0;
  --line: #e9e5f2;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; min-width: 320px; }
button, input, select { font: inherit; }
button, select { cursor: pointer; }
button:disabled { cursor: default; }
button:focus-visible, select:focus-visible, input:focus-visible { outline: 3px solid #9d80f5; outline-offset: 3px; }
button { color: inherit; }
.layout { min-height: 100vh; display: grid; grid-template-columns: 208px minmax(0, 1fr); }
.rail { background: var(--rail); color: #fff; display: flex; flex-direction: column; padding: 27px 16px 22px; position: sticky; top: 0; height: 100dvh; }
.brand { display: flex; gap: 10px; align-items: center; padding-left: 4px; font-size: 16px; font-weight: 750; white-space: nowrap; }
.brand-icon { display: grid; place-items: center; width: 37px; height: 37px; background: #7956e8; border-radius: 11px; color: white; font-size: 22px; box-shadow: 0 3px 12px #a17eff35; }
.brand small { display: block; font-size: 11px; color: #b3a8cf; font-weight: 500; margin-top: 4px; }
.rail nav { display: grid; gap: 6px; margin-top: 45px; }
.rail nav button { display: flex; align-items: center; gap: 12px; border: 0; border-radius: 8px; background: transparent; color: #c4badc; padding: 12px; text-align: left; font-size: 14px; }
.rail nav button:hover, .rail nav button[aria-current] { background: #392960; color: #fff; }
.rail nav span { color: #b99cff; font-size: 18px; }
.rail nav b { margin-left: auto; font-size: 11px; font-weight: 600; }
.rail-footer { display: flex; align-items: center; gap: 8px; margin-top: auto; color: #c6bedb; font-size: 12px; padding-left: 8px; }
.rail-footer i { width: 7px; height: 7px; background: #8ce4bf; border-radius: 50%; }
main { min-width: 0; }
.top { min-height: 65px; background: #fff; display: flex; align-items: center; justify-content: space-between; padding: 10px clamp(17px, 4vw, 48px); border-bottom: 1px solid var(--line); }
.top > span { font-size: 13px; color: var(--muted); font-weight: 650; }
.top-actions { display: flex; gap: 9px; align-items: center; }
.outline { border: 1px solid var(--line); background: #fff; padding: 8px 12px; border-radius: 8px; font-size: 13px; min-height: 38px; }
.outline:hover { background: #f5f1ff; }
#account { display: flex; gap: 8px; align-items: center; }
.avatar { display: inline-block; border-radius: 50%; background: #ece4ff; color: #4f2db3; font-size: 12px; width: 23px; height: 23px; line-height: 23px; text-align: center; font-weight: 700; }
.account-action { color: var(--muted); font-size: 11px; }
.content { padding: 28px clamp(17px, 4vw, 48px) 55px; margin: 0 auto; max-width: 1560px; }
.hero { display: grid; grid-template-columns: minmax(0, 1fr) minmax(230px, 310px); gap: 25px; align-items: center; padding: 32px; border-radius: 18px; background: radial-gradient(ellipse at 74% -115%, #a287f3, transparent 75%), linear-gradient(115deg, #3d277d, #51339c 58%, #6745c0); color: #fff; overflow: hidden; }
h1, h2, h3, p { margin: 0; }
.hero h1 { font-size: clamp(25px, 3.2vw, 39px); letter-spacing: -.025em; line-height: 1.2; }
.hero-copy p { font-size: 14px; color: #e9e0ff; line-height: 1.65; margin: 12px 0 17px; }
.privacy { display: inline-block; font-size: 12px; color: #f7f2ff; background: #ffffff15; border: 1px solid #ffffff28; border-radius: 20px; padding: 6px 11px; }
.quota { background: #21154c62; border: 1px solid #ffffff30; border-radius: 13px; padding: 16px; }
.quota-title { display: flex; justify-content: space-between; gap: 9px; align-items: center; font-size: 13px; }
.quota-title strong { font-size: 23px; font-variant-numeric: tabular-nums; }
progress { width: 100%; height: 7px; border: 0; appearance: none; display: block; margin: 12px 0; background: #ffffff25; border-radius: 7px; }
progress::-webkit-progress-bar { background: #ffffff25; border-radius: 7px; }
progress::-webkit-progress-value { background: #baf1d5; border-radius: 7px; }
progress::-moz-progress-bar { background: #baf1d5; border-radius: 7px; }
.quota p { color: #f0e8ff; font-size: 12px; line-height: 1.5; }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 10px; margin: 28px 0 16px; }
.section-heading h2 { font-size: 21px; }
.section-heading p, #refreshed { font-size: 12px; margin-top: 6px; color: var(--muted); }
.count { color: var(--purple); background: #eee8fd; display: inline-grid; place-items: center; min-width: 27px; height: 23px; padding: 0 6px; border-radius: 12px; font-size: 12px; vertical-align: 2px; margin-left: 3px; }
.toolbar { display: flex; justify-content: space-between; gap: 10px; align-items: center; margin-bottom: 15px; flex-wrap: wrap; }
.tabs { display: flex; flex-wrap: wrap; gap: 3px; background: #eeedf5; border-radius: 10px; padding: 4px; }
.tabs button { padding: 7px 11px; min-height: 34px; border: 0; color: var(--muted); background: transparent; border-radius: 7px; font-size: 13px; }
.tabs button[aria-pressed="true"] { color: var(--purple); background: #fff; box-shadow: 0 1px 4px #23194314; font-weight: 650; }
.tabs b { margin-left: 3px; font-size: 11px; font-weight: 600; }
.market-filter { display: flex; gap: 8px; align-items: center; font-size: 12px; color: var(--muted); }
select { padding: 9px 10px; color: var(--ink); background: #fff; border: 1px solid var(--line); border-radius: 8px; max-width: 190px; }
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 222px), 1fr)); gap: 13px; }
.card, .surface { background: #fff; border: 1px solid var(--line); border-radius: 13px; box-shadow: 0 2px 8px #281e4b05; }
.card { padding: 15px; display: flex; flex-direction: column; gap: 13px; min-width: 0; }
.card-top, .card-footer { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.market-icon { display: grid; place-items: center; width: 41px; height: 41px; border-radius: 11px; background: #e4f6ee; color: #185c4b; font-size: 13px; font-weight: 800; letter-spacing: .05em; }
.card.high .market-icon { background: #eee6ff; color: #5e39be; }
.card.unknown .market-icon { background: #eeedf5; color: var(--muted); }
.card h3 { font-size: 16px; }
.card p { color: var(--muted); font-size: 12px; line-height: 1.5; margin-top: 4px; overflow-wrap: anywhere; }
.badge { display: inline-block; font-size: 11px; font-weight: 650; white-space: nowrap; background: #e8f6ef; color: #206248; padding: 5px 8px; border-radius: 20px; }
.high .badge { color: #5730b5; background: #eee8fd; }
.unknown .badge { color: #5e5770; background: #eeedf5; }
.card-footer { border-top: 1px solid #f0edf6; padding-top: 11px; margin-top: auto; }
.card-footer time { color: var(--muted); font-size: 11px; }
.primary { border: 1px solid transparent; border-radius: 8px; background: #5b3ac3; color: #fff; font-weight: 650; min-height: 37px; padding: 7px 13px; font-size: 13px; white-space: nowrap; }
.primary:hover { background: #4828a7; }
.primary:disabled { color: #6b647e; background: #f0eef6; }
.empty { grid-column: 1 / -1; border: 1px dashed #d9d2ea; border-radius: 12px; padding: 32px 16px; text-align: center; color: var(--muted); font-size: 14px; }
.login { max-width: 455px; margin: 45px auto; padding: 32px; }
.login h1 { margin: 16px 0 9px; font-size: 25px; }
.login p { color: var(--muted); margin-bottom: 19px; font-size: 14px; line-height: 1.6; }
#demo-accounts, #login-form { display: grid; gap: 10px; }
#login-form label { display: grid; gap: 5px; font-size: 13px; }
#login-form input { padding: 9px 10px; border: 1px solid #dcd5ec; border-radius: 8px; min-width: 0; }
#login-error { color: #9a3223; margin: 12px 0 0; }
dialog { color: var(--ink); border: 1px solid var(--line); border-radius: 16px; padding: 23px; width: min(92vw, 590px); max-height: 82dvh; }
dialog::backdrop { background: #19142e80; }
.modal-header { display: flex; justify-content: space-between; align-items: center; gap: 15px; margin-bottom: 16px; }
.modal-header h2 { font-size: 20px; }
#modal-content { color: var(--muted); font-size: 14px; line-height: 1.65; }
#modal-content .primary { margin-top: 17px; }
.contact, .message, .notice { border: 1px solid var(--line); border-radius: 9px; padding: 10px; margin: 8px 0; overflow-wrap: anywhere; }
.contact strong, .message p { color: var(--ink); }
.message time { font-size: 12px; }
.message p { white-space: pre-wrap; }
#toast { position: fixed; z-index: 2; right: 22px; bottom: 22px; max-width: calc(100% - 44px); background: var(--rail); color: #fff; padding: 13px 17px; border-radius: 10px; box-shadow: 0 4px 16px #0003; font-size: 14px; }
@media (max-width: 860px) { .layout { grid-template-columns: 156px minmax(0, 1fr); } .hero { padding: 24px; } .rail { padding-inline: 10px; } }
@media (max-width: 680px) {
  .layout { display: block; }
  .rail { position: static; height: auto; padding: 10px 13px; flex-direction: row; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 10px; }
  .rail nav { margin: 0; display: flex; gap: 2px; }
  .rail nav button { gap: 4px; padding: 6px 7px; font-size: 12px; }
  .rail nav span, .rail nav b { display: none; }
  .rail-footer { margin: 0; padding: 0; }
  .brand { font-size: 14px; gap: 7px; padding: 0; }
  .brand-icon { width: 29px; height: 29px; font-size: 17px; }
  .top { min-height: 49px; padding-block: 6px; }
  .content { padding-top: 16px; }
  .hero { grid-template-columns: 1fr; gap: 15px; padding: 18px; }
  .hero-copy p { margin: 8px 0 12px; }
  .section-heading { margin-top: 22px; align-items: start; }
  #refreshed { text-align: right; }
}
