:root {
  color-scheme: dark;
  --font-ui: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Helvetica Neue", Arial, sans-serif;
  --font-number: "SF Mono", ui-monospace, Menlo, Monaco, Consolas, monospace;
  --bg: #020814;
  --bg-2: #061a33;
  --panel: rgba(11, 32, 58, .94);
  --panel-2: rgba(12, 39, 73, .92);
  --line: rgba(83, 168, 255, .22);
  --line-strong: rgba(92, 204, 255, .48);
  --text: #edf8ff;
  --muted: #89a9c8;
  --cyan: #42d9ff;
  --blue: #1d7cff;
  --gold: #f7bd45;
  --green: #19d981;
  --red: #ff4960;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background: var(--bg);
}

[hidden] {
  display: none !important;
}

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  overflow: hidden;
  background:
    radial-gradient(circle at 50% 0%, rgba(18, 92, 176, .34), transparent 42%),
    linear-gradient(180deg, #020814 0%, #061324 55%, #020814 100%);
  color: var(--text);
  font-family: var(--font-ui);
  font-size: 14px;
  line-height: 1.4;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

button, input {
  font: inherit;
}

button {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--text);
  background: var(--panel-2);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}

button:active {
  transform: translateY(2px) scale(.985);
  box-shadow: inset 0 4px 10px rgba(0, 0, 0, .34);
}

input {
  width: 100%;
  height: 28px;
  min-width: 0;
  border: 1px solid rgba(83, 168, 255, .18);
  border-radius: 7px;
  padding: 0 8px;
  outline: none;
  color: var(--text);
  font-size: 13px;
  background: rgba(2, 10, 22, .72);
}

input:focus {
  border-color: var(--cyan);
  box-shadow: 0 0 0 2px rgba(66, 217, 255, .12);
}

input:disabled {
  color: #667f98;
  border-color: rgba(83, 168, 255, .08);
}

.auth-gate {
  position: fixed;
  inset: 0;
  z-index: 40;
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    linear-gradient(180deg, rgba(2, 8, 20, .88), rgba(3, 18, 38, .94)),
    repeating-linear-gradient(90deg, rgba(66, 217, 255, .05) 0 1px, transparent 1px 32px),
    repeating-linear-gradient(0deg, rgba(66, 217, 255, .035) 0 1px, transparent 1px 32px);
  backdrop-filter: blur(18px);
}

.auth-video-bg {
  display: none;
}

body.auth-required .shell {
  pointer-events: none;
}

.auth-panel {
  position: relative;
  width: min(1040px, 100%);
  min-height: min(760px, calc(100svh - 48px));
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: minmax(180px, 1fr) auto;
  gap: 18px;
  overflow: hidden;
  border: 1px solid rgba(92, 204, 255, .32);
  border-radius: 18px;
  color: var(--text);
  background: rgba(5, 18, 38, .98);
  box-shadow:
    0 30px 80px rgba(0, 0, 0, .48),
    inset 0 1px 0 rgba(255, 255, 255, .06);
}

.auth-stage {
  position: relative;
  display: grid;
  align-content: start;
  justify-items: start;
  min-height: 0;
  padding: 18px 24px 0;
  overflow: hidden;
  background: rgba(6, 20, 42, .98);
}

.auth-stage::before {
  content: none;
}

.auth-stage-top {
  position: relative;
  z-index: 1;
}

.auth-stage-top {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  width: fit-content;
  color: rgba(237, 248, 255, .72);
  font-size: 11px;
  font-weight: 700;
}

.auth-hero-copy {
  position: relative;
  z-index: 1;
  display: grid;
  justify-items: center;
  gap: 12px;
  max-width: 640px;
  margin-top: clamp(56px, 12vh, 112px);
  margin-right: auto;
  margin-left: auto;
  text-align: center;
}

.auth-hero-copy p,
.auth-hero-copy h1,
.auth-hero-subtitle,
.auth-hero-subtitle-en {
  margin: 0;
}

.auth-hero-copy p {
  color: rgba(237, 248, 255, .7);
  font-size: 13px;
  font-weight: 700;
}

.auth-hero-kicker {
  display: grid;
  gap: 0;
}

.auth-hero-kicker span {
  display: block;
}

.auth-hero-kicker span {
  color: rgba(237, 248, 255, .48);
  font-size: 11px;
  font-weight: 600;
}

.auth-hero-copy h1 {
  color: var(--text);
  font-size: clamp(40px, 7vw, 74px);
  line-height: 1.02;
}

.auth-title-line {
  display: block;
}

.auth-title-line-accent {
  padding-left: 0;
}

.auth-hero-subtitle {
  max-width: 560px;
  color: var(--muted);
  font-size: clamp(14px, 1.7vw, 18px);
  line-height: 1.55;
}

.auth-hero-subtitle-en {
  max-width: 620px;
  color: rgba(237, 248, 255, .52);
  font-size: clamp(12px, 1.3vw, 15px);
  line-height: 1.45;
}

.auth-experience-button {
  position: absolute;
  left: 50%;
  top: 62%;
  z-index: 2;
  overflow: hidden;
  min-width: 168px;
  height: 52px;
  padding: 0 32px;
  border: 1px solid rgba(237, 248, 255, .28);
  border-radius: 999px;
  color: rgba(237, 248, 255, .78);
  background:
    radial-gradient(circle at var(--auth-cta-x, 50%) var(--auth-cta-y, 50%), rgba(237, 248, 255, .2), transparent 36%),
    linear-gradient(180deg, rgba(237, 248, 255, .12), rgba(147, 243, 255, .06));
  box-shadow:
    0 18px 42px rgba(0, 0, 0, .24),
    0 0 26px rgba(56, 198, 255, .08),
    inset 0 1px 0 rgba(255, 255, 255, .14);
  font-weight: 800;
  transform: translate(-50%, -50%);
  transition: color .42s ease, border-color .42s ease, background .42s ease, box-shadow .42s ease, transform .22s ease, opacity .22s ease;
}

.auth-experience-button::before,
.auth-experience-button::after {
  content: "";
  position: absolute;
  pointer-events: none;
}

.auth-experience-button::before {
  inset: -1px;
  opacity: 0;
  background: linear-gradient(105deg, transparent 0%, rgba(255, 255, 255, .72) 46%, transparent 68%);
  transform: translateX(-135%);
  transition: opacity .36s ease, transform .72s cubic-bezier(.2, .8, .2, 1);
}

.auth-experience-button::after {
  inset: 0;
  opacity: .32;
  background: radial-gradient(circle at var(--auth-cta-x, 50%) var(--auth-cta-y, 50%), rgba(237, 248, 255, .26), transparent 42%);
  transition: opacity .42s ease;
}

.auth-experience-button:hover,
.auth-experience-button:focus-visible,
.auth-experience-button.is-awake {
  color: #04101f;
  border-color: rgba(237, 248, 255, .56);
  background:
    radial-gradient(circle at var(--auth-cta-x, 50%) var(--auth-cta-y, 50%), rgba(255, 255, 255, .98), transparent 38%),
    linear-gradient(180deg, rgba(237, 248, 255, .96), rgba(147, 243, 255, .86));
  box-shadow:
    0 24px 54px rgba(0, 0, 0, .34),
    0 0 42px rgba(56, 198, 255, .24),
    inset 0 1px 0 rgba(255, 255, 255, .88);
  transform: translate(-50%, calc(-50% - 2px));
}

.auth-experience-button:hover::before,
.auth-experience-button:focus-visible::before,
.auth-experience-button.is-awake::before {
  opacity: .78;
  transform: translateX(135%);
}

.auth-experience-button:hover::after,
.auth-experience-button:focus-visible::after,
.auth-experience-button.is-awake::after {
  opacity: .86;
}

.auth-experience-button span {
  position: relative;
  z-index: 1;
}

.auth-gate.is-auth-modal-open .auth-experience-button {
  opacity: 0;
  pointer-events: none;
}

.auth-modal-layer {
  position: fixed;
  inset: 0;
  z-index: 5;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(0, 0, 0, .16);
  backdrop-filter: blur(4px);
}

.auth-modal-layer[hidden] {
  display: none;
}

.auth-content {
  position: relative;
  display: grid;
  align-content: center;
  justify-self: center;
  width: min(820px, 100%);
  min-height: 554px;
  padding: 20px clamp(24px, 5vw, 54px);
  background: rgba(6, 20, 42, .98);
}

.auth-modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border: 1px solid rgba(237, 248, 255, .14);
  border-radius: 50%;
  color: var(--muted);
  background: rgba(2, 10, 22, .32);
}

.auth-modal-close svg {
  width: 17px;
  height: 17px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
}

.auth-heading,
.auth-tabs,
.auth-login-method,
.auth-form,
.auth-message {
  width: min(560px, 100%);
  justify-self: center;
}

.auth-heading {
  display: grid;
  gap: 8px;
  margin-bottom: 24px;
}

.auth-heading h2 {
  margin: 0;
  color: var(--text);
  font-size: 32px;
  line-height: 1.2;
}

.auth-heading p,
.auth-message {
  color: var(--muted);
  font-size: 12px;
}

.auth-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  margin-bottom: 20px;
  padding: 4px;
  border: 1px solid rgba(83, 168, 255, .16);
  border-radius: 8px;
  background: rgba(2, 10, 22, .54);
}

.auth-tabs button {
  height: 40px;
  border: 0;
  border-radius: 6px;
  color: var(--muted);
  background: transparent;
}

.auth-tabs button.active {
  color: #04101f;
  background: linear-gradient(180deg, #93f3ff, #38c6ff);
}

.auth-login-method {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  justify-self: center;
  width: auto;
  height: 36px;
  margin: -10px auto 14px;
  padding: 0;
}

.auth-login-method[hidden] {
  display: none;
}

.auth-login-method-thumb {
  display: none;
}

.auth-login-method button {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border: 1px solid rgba(83, 168, 255, .16);
  border-radius: 50%;
  color: var(--muted);
  background: rgba(2, 10, 22, .28);
  transition: transform .16s ease, border-color .16s ease, background .16s ease, box-shadow .16s ease;
}

.auth-login-method button:hover:not(:disabled) {
  transform: translateY(-1px);
  border-color: rgba(83, 168, 255, .38);
  background: rgba(83, 168, 255, .12);
}

.auth-method-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  line-height: 1;
  opacity: .88;
}

.auth-method-icon svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.auth-login-method button.active {
  color: #04101f;
  border-color: rgba(147, 243, 255, .72);
  background: linear-gradient(180deg, rgba(147, 243, 255, .96), rgba(56, 198, 255, .92));
  box-shadow: 0 8px 18px rgba(56, 198, 255, .18);
}

.auth-login-method button:disabled {
  opacity: .45;
  cursor: not-allowed;
}

.auth-form {
  display: grid;
  gap: 14px;
}

.auth-field {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
}

.auth-field input {
  height: 48px;
  border-radius: 8px;
  padding: 0 14px;
}

.auth-code-field {
  grid-column: 1 / -1;
}

.auth-code-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 92px;
  gap: 8px;
}

.auth-code-row button {
  height: 48px;
  border-radius: 8px;
  color: #04101f;
  border-color: rgba(66, 217, 255, .64);
  background: linear-gradient(180deg, #93f3ff, #38c6ff);
  font-weight: 800;
}

.auth-gate.is-email-login .auth-form {
  width: min(560px, 100%);
  margin: 0 auto;
  grid-template-columns: minmax(0, 1fr);
}

.auth-gate.is-email-login .auth-field,
.auth-gate.is-email-login .auth-code-field,
.auth-gate.is-email-login .auth-consent,
.auth-gate.is-email-login .auth-submit {
  grid-column: 1;
}

.auth-gate.is-email-login .auth-code-row {
  grid-template-columns: minmax(0, 1fr) 84px;
}

.auth-gate.is-email-login .auth-field,
.auth-gate.is-email-login .auth-code-field,
.auth-gate.is-email-login .auth-consent,
.auth-gate.is-email-login .auth-submit {
  width: min(430px, 100%);
  justify-self: center;
}

.auth-consent {
  display: grid;
  grid-template-columns: 16px minmax(0, 1fr);
  gap: 8px;
  align-items: start;
  padding: 10px;
  border: 1px solid rgba(255, 202, 92, .22);
  border-radius: 8px;
  background: rgba(255, 202, 92, .08);
  color: #e7edf5;
  font-size: 11px;
  line-height: 1.45;
}

.auth-consent input {
  width: 14px;
  height: 14px;
  margin: 1px 0 0;
  accent-color: #19d981;
}

.auth-consent a {
  color: #8ed8ff;
  text-decoration: none;
}

.auth-consent a:hover {
  text-decoration: underline;
}

.auth-submit {
  height: 50px;
  margin-top: 8px;
  color: #04101f;
  border-color: rgba(66, 217, 255, .64);
  background: linear-gradient(180deg, #93f3ff, #38c6ff);
  box-shadow: 0 10px 22px rgba(29, 124, 255, .2);
}

.auth-message {
  min-height: 18px;
  margin-top: 14px;
  text-align: center;
}

@media (max-width: 760px) {
  .auth-gate {
    padding: 16px;
  }

  .auth-panel {
    width: min(430px, 100%);
    min-height: calc(100svh - 32px);
    grid-template-columns: 1fr;
    grid-template-rows: minmax(0, 1fr);
  }

  .auth-stage {
    padding: 16px 20px 0;
  }

  .auth-hero-copy {
    gap: 8px;
    margin-top: 34px;
  }

  .auth-hero-copy h1 {
    font-size: clamp(30px, 11vw, 44px);
  }

  .auth-hero-subtitle,
  .auth-hero-subtitle-en {
    font-size: 13px;
  }

  .auth-content {
    min-height: min(554px, calc(100svh - 44px));
    padding: 22px;
  }

  .auth-heading {
    margin-bottom: 16px;
  }

  .auth-heading h2 {
    font-size: 23px;
  }
}

@media (max-width: 380px) {
  .auth-gate {
    padding: 12px;
  }

  .auth-stage {
    padding: 14px 16px 0;
  }

  .auth-content {
    padding: 14px;
  }
}

.account-switcher {
  display: grid;
  gap: 10px;
  width: 100%;
  min-width: 0;
  padding: 10px;
  border: 1px solid rgba(83, 168, 255, .16);
  border-radius: 12px;
  background:
    linear-gradient(135deg, rgba(83, 168, 255, .08), rgba(126, 236, 189, .04)),
    rgba(2, 10, 22, .42);
}

.account-switcher[hidden] {
  display: none;
}

.account-switcher-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-width: 0;
}

.account-switcher-title {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.account-switcher-title span,
.account-switcher-title em {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.35;
}

.account-switcher-title strong {
  overflow: hidden;
  color: var(--text);
  font-size: 14px;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.account-switcher-title em {
  overflow: hidden;
  font-style: normal;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.account-switcher-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.sim-account-balance-field {
  display: grid;
  gap: 2px;
  width: 78px;
  color: var(--muted);
  font-size: 9px;
  font-weight: 800;
  line-height: 1.1;
}

.sim-account-balance-field input {
  height: 28px;
  border-radius: 9px;
  padding: 0 7px;
  font-size: 11px;
}

.account-switcher-actions button {
  height: 28px;
  border-radius: 9px;
  padding: 0 10px;
  font-size: 12px;
}

.account-switcher .sim-account-button {
  border-color: rgba(126, 236, 189, .3);
  color: #b8ffd9;
  background: rgba(35, 177, 112, .14);
}

.account-platform-groups {
  display: grid;
  gap: 8px;
  min-width: 0;
}

.account-platform-group {
  display: grid;
  gap: 7px;
  min-width: 0;
}

.account-platform-button {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) 16px;
  align-items: center;
  gap: 10px;
  width: 100%;
  min-height: 58px;
  border: 1px solid rgba(83, 168, 255, .16);
  border-radius: 12px;
  padding: 8px;
  color: var(--text);
  text-align: left;
  background:
    linear-gradient(135deg, rgba(83, 168, 255, .08), rgba(2, 10, 22, .04)),
    rgba(2, 10, 22, .44);
  transition: border-color .18s ease, background .18s ease, box-shadow .18s ease, transform .18s ease;
}

.account-platform-button:hover,
.account-platform-button:focus-visible {
  border-color: rgba(147, 243, 255, .44);
  background:
    linear-gradient(135deg, rgba(83, 168, 255, .14), rgba(126, 236, 189, .07)),
    rgba(2, 10, 22, .58);
}

.account-platform-group.is-current .account-platform-button {
  border-color: rgba(147, 243, 255, .54);
  box-shadow: 0 0 0 1px rgba(147, 243, 255, .1), 0 10px 22px rgba(56, 198, 255, .1);
}

.account-platform-group.is-expanded .account-platform-button {
  background:
    linear-gradient(135deg, rgba(83, 168, 255, .18), rgba(126, 236, 189, .09)),
    rgba(2, 10, 22, .62);
}

.account-platform-logo-wrap {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, .12);
  border-radius: 12px;
  background: rgba(255, 255, 255, .08);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .1);
}

.account-platform-logo {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.account-platform-copy {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.account-platform-copy strong,
.account-platform-copy em {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.account-platform-copy strong {
  color: var(--text);
  font-size: 13px;
  font-weight: 800;
  line-height: 1.3;
}

.account-platform-copy em {
  color: var(--muted);
  font-size: 10px;
  font-style: normal;
  line-height: 1.3;
}

.account-platform-chevron {
  justify-self: center;
  width: 9px;
  height: 9px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  opacity: .72;
  transform: rotate(45deg);
  transition: transform .18s ease, opacity .18s ease;
}

.account-platform-group.is-expanded .account-platform-chevron {
  opacity: .95;
  transform: rotate(225deg);
}

.account-card-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 6px;
  margin-left: 52px;
  min-width: 0;
}

.account-card {
  display: grid;
  width: 100%;
  min-width: 0;
  min-height: 68px;
  border: 1px solid rgba(83, 168, 255, .16);
  border-radius: 10px;
  padding: 9px;
  color: var(--text);
  text-align: left;
  background: rgba(2, 10, 22, .56);
  cursor: pointer;
  transition: border-color .18s ease, background .18s ease, box-shadow .18s ease, transform .18s ease;
}

.account-card:hover,
.account-card:focus-visible {
  border-color: rgba(147, 243, 255, .45);
  background: rgba(8, 25, 48, .72);
}

.account-card:active {
  transform: translateY(1px);
}

.account-card.is-selected {
  border-color: rgba(147, 243, 255, .62);
  background:
    linear-gradient(135deg, rgba(83, 168, 255, .22), rgba(126, 236, 189, .11)),
    rgba(2, 10, 22, .68);
  box-shadow: 0 0 0 1px rgba(147, 243, 255, .12), 0 12px 24px rgba(56, 198, 255, .12);
}

.account-card.is-disabled {
  cursor: not-allowed;
  opacity: .56;
}

.account-card-main {
  display: grid;
  gap: 5px;
  min-width: 0;
}

.account-card-title-row,
.account-card-data-row {
  display: flex;
  align-items: center;
  min-width: 0;
}

.account-card-title-row {
  justify-content: space-between;
  gap: 8px;
}

.account-card-data-row {
  flex-wrap: wrap;
  gap: 5px 8px;
}

.account-card-title-row strong,
.account-card-data-row em {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.account-card-title-row strong {
  font-size: 12px;
  line-height: 1.35;
}

.account-card-data-row em {
  max-width: 100%;
  color: var(--muted);
  font-size: 10px;
  font-style: normal;
  line-height: 1.35;
}

.account-card-status {
  flex: 0 0 auto;
  border-radius: 999px;
  padding: 4px 7px;
  color: #b8ffd9;
  font-size: 10px;
  font-weight: 800;
  line-height: 1;
  background: rgba(35, 177, 112, .18);
}

.account-card.is-disabled .account-card-status {
  color: #ffc2c8;
  background: rgba(255, 91, 105, .14);
}

.account-empty-state {
  display: grid;
  gap: 4px;
  border: 1px dashed rgba(83, 168, 255, .2);
  border-radius: 10px;
  padding: 10px;
  color: var(--muted);
  background: rgba(2, 10, 22, .35);
}

.account-empty-state strong {
  color: var(--text);
  font-size: 12px;
}

.account-empty-state span {
  font-size: 11px;
  line-height: 1.5;
}

@media (max-width: 380px) {
  .account-switcher-head {
    align-items: stretch;
    flex-direction: column;
  }

  .account-switcher-actions {
    justify-content: flex-end;
  }

  .account-card-list {
    grid-template-columns: minmax(0, 1fr);
    margin-left: 0;
  }
}

h1, h2, p {
  margin: 0;
}

.shell {
  width: 100%;
  max-width: 430px;
  height: 100vh;
  height: 100dvh;
  margin: 0 auto;
  padding: 9px;
  overflow: hidden;
  background:
    linear-gradient(90deg, rgba(66, 217, 255, .04) 1px, transparent 1px),
    linear-gradient(180deg, rgba(66, 217, 255, .035) 1px, transparent 1px),
    linear-gradient(180deg, rgba(4, 18, 36, .82), rgba(2, 8, 20, .96));
  background-size: 22px 22px, 22px 22px, auto;
}

.shell-admin {
  max-width: 980px;
}

@supports (padding: max(0px)) {
  .shell {
    padding-top: max(9px, env(safe-area-inset-top));
    padding-right: max(9px, env(safe-area-inset-right));
    padding-bottom: max(9px, env(safe-area-inset-bottom));
    padding-left: max(9px, env(safe-area-inset-left));
  }
}

@media (max-width: 380px) {
  .shell {
    padding: 7px;
  }

  .home-view {
    grid-template-rows: 142px 198px 40px minmax(0, 1fr) 10px;
    gap: 6px;
  }

  .home-view.chart-expanded {
    grid-template-rows: 142px 258px 40px minmax(0, 1fr) 10px;
  }

  .hero-copy h1 {
    font-size: 25px;
  }

  .position-tools {
    grid-template-columns: 62px auto;
    gap: 3px;
  }

  .settings-button {
    padding: 0;
    font-size: 10px;
  }
}

.view {
  height: 100%;
  min-height: 0;
}

.home-view {
  display: grid;
  grid-template-rows: 150px 204px 42px minmax(0, 1fr) 10px;
  gap: 6px;
}

.home-view.chart-expanded {
  grid-template-rows: 150px clamp(268px, 34vh, 304px) 42px minmax(0, 1fr) 10px;
}

@media (max-width: 380px) {
  .home-view.chart-expanded {
    grid-template-rows: 142px clamp(250px, 36vh, 276px) 40px minmax(0, 1fr) 10px;
  }
}

@media (max-height: 700px) {
  .home-view.chart-expanded {
    grid-template-rows: 142px 252px 40px minmax(0, 1fr) 10px;
  }
}

.hero {
  position: relative;
  isolation: isolate;
  display: grid;
  grid-template-rows: 1fr minmax(36px, auto);
  gap: 8px;
  overflow: hidden;
  padding: 15px 12px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: inset 0 0 18px rgba(66, 217, 255, .055), 0 8px 18px rgba(0, 0, 0, .16);
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  opacity: .1;
  z-index: 1;
  pointer-events: none;
  background:
    linear-gradient(90deg, rgba(66, 217, 255, .12) 1px, transparent 1px),
    linear-gradient(180deg, rgba(66, 217, 255, .075) 1px, transparent 1px),
    linear-gradient(180deg, rgba(255, 255, 255, .018), transparent 44%, rgba(66, 217, 255, .018));
  background-size: 24px 24px, 24px 24px, auto;
  mask-image: linear-gradient(180deg, #000, transparent 88%);
}

.hero::after {
  content: "";
  position: absolute;
  inset: -22px -38px -8px;
  z-index: 0;
  pointer-events: none;
  opacity: .14;
  background:
    linear-gradient(92deg, transparent 8%, rgba(66, 217, 255, .065) 26%, rgba(25, 217, 129, .025) 50%, rgba(92, 204, 255, .052) 72%, transparent 94%),
    linear-gradient(180deg, transparent 10%, rgba(66, 217, 255, .032) 50%, transparent 72%);
  filter: blur(12px);
}

.hero-copy, .hero-session-pnl {
  position: relative;
  z-index: 2;
}

.hero-copy {
  display: grid;
  align-content: center;
  text-align: center;
}

.hero-copy h1 {
  position: relative;
  justify-self: center;
  display: inline-block;
  font-size: 30px;
  line-height: 1.15;
  font-weight: 900;
  letter-spacing: 0;
  color: transparent;
  background: linear-gradient(180deg, #ffffff 0%, #d7fbff 34%, #55e8ff 52%, #f6ffff 66%, #85b8ff 100%);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  text-shadow: 0 0 14px rgba(66, 217, 255, .22);
}

.hero-copy h1::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -5px;
  width: 126px;
  height: 1px;
  transform: translateX(-50%);
  background: linear-gradient(90deg, transparent, rgba(66, 217, 255, .78), rgba(25, 217, 129, .48), transparent);
  box-shadow: 0 0 10px rgba(66, 217, 255, .42);
}

.hero-copy p {
  margin-top: 7px;
  color: #b8d9ff;
  font-size: 12px;
  line-height: 1.35;
}

.hero-session-pnl {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
}

.heartbeat {
  min-width: 0;
  height: 18px;
  display: flex;
  align-items: center;
  gap: 5px;
  overflow: hidden;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
}

.ecg {
  width: 100%;
  height: 18px;
  overflow: visible;
}

.ecg-path, .ecg-trail {
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.ecg-path {
  stroke: #506d88;
  stroke-width: 2.1;
  filter: drop-shadow(0 0 2px rgba(80, 109, 136, .28));
}

.ecg-trail {
  opacity: 0;
  stroke: rgba(25, 217, 129, .72);
  stroke-width: 5.2;
  stroke-dasharray: 48 300;
  stroke-dashoffset: 348;
  filter: drop-shadow(0 0 6px rgba(25, 217, 129, .7)) drop-shadow(0 0 14px rgba(25, 217, 129, .34));
  pointer-events: none;
}

.ecg-runner, .ecg-runner-halo {
  opacity: 0;
  pointer-events: none;
}

.ecg-runner {
  fill: #f8fffb;
}

.ecg-runner-halo {
  fill: rgba(25, 217, 129, .34);
}

.heartbeat.live {
  border-color: transparent;
}

.heartbeat.live .ecg-path {
  stroke: var(--green);
  filter: drop-shadow(0 0 4px rgba(25, 217, 129, .42));
}

.heartbeat.live .ecg-trail {
  opacity: .9;
  animation: ecgTrailRun .92s linear infinite;
}

.heartbeat.live .ecg-runner {
  opacity: 1;
  fill: #f5fff9;
  filter: drop-shadow(0 0 7px rgba(255, 255, 255, 1)) drop-shadow(0 0 14px rgba(25, 217, 129, 1));
  animation: ecgRunnerGlow .92s ease-in-out infinite;
}

.heartbeat.live .ecg-runner-halo {
  opacity: .68;
  filter: drop-shadow(0 0 10px rgba(25, 217, 129, .82)) blur(.35px);
  animation: ecgRunnerHalo .92s ease-in-out infinite;
}

.settings-button {
  position: relative;
  z-index: 3;
  width: auto;
  height: 22px;
  padding: 0;
  border: 0;
  background: transparent;
  color: #d9f5ff;
  font-size: 12px;
  font-weight: 400;
  line-height: 20px;
  box-shadow: none;
}

.settings-button:active {
  transform: none;
  box-shadow: none;
}

.settings-button::before {
  content: "";
  position: absolute;
  inset: -9px -8px;
}

.back-button {
  height: 28px;
  border-color: rgba(66, 217, 255, .28);
  background: linear-gradient(180deg, rgba(23, 75, 132, .92), rgba(10, 36, 72, .92));
  color: #d9f5ff;
  font-size: 12px;
}

.back-icon-button {
  position: relative;
  width: 28px;
  padding: 0;
  display: grid;
  place-items: center;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  color: #e9fbff;
  box-shadow: none !important;
}

.back-icon-button:active {
  transform: none;
  box-shadow: none !important;
}

.back-icon-button span {
  display: block;
  font-family: var(--font-ui);
  font-size: 24px;
  font-weight: 800;
  line-height: 1;
}

.back-arrow-icon {
  display: block;
  width: 29px;
  height: 29px;
  object-fit: contain;
  filter: drop-shadow(0 0 5px rgba(42, 141, 194, .24));
}

.chart-stack {
  min-height: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
}

.chart-stack.has-expanded {
  grid-template-columns: 1fr;
}

.chart-stack.has-expanded .chart-card:not(.is-expanded) {
  display: none;
}

.chart-card, .data-card, .settings-block {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .045),
    inset 0 0 18px rgba(66, 217, 255, .065),
    0 8px 18px rgba(0, 0, 0, .16),
    0 0 0 1px rgba(66, 217, 255, .035);
}

.chart-card {
  position: relative;
  min-height: 0;
  overflow: hidden;
  padding: 7px;
}

.chart-card::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  border-radius: inherit;
  background: linear-gradient(180deg, rgba(255, 255, 255, .045), transparent 34%, rgba(0, 0, 0, .12));
  mix-blend-mode: screen;
}

.chart-card.is-expanded {
  display: grid;
  grid-template-rows: 32px minmax(0, 1fr);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .06),
    inset 0 -22px 28px rgba(1, 6, 16, .16),
    0 14px 26px rgba(0, 0, 0, .26),
    0 0 22px rgba(66, 217, 255, .1);
}

.chart-head {
  height: 32px;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 5px;
}

.chart-head strong {
  display: block;
  font-size: 12px;
  line-height: 1.2;
  font-weight: 700;
}

.chart-head span {
  display: block;
  margin-top: 2px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.2;
}

.chart-meta {
  min-width: 60px;
  text-align: right;
}

.chart-meta b {
  display: block;
  font-family: var(--font-number);
  font-size: 12px;
  line-height: 1.2;
  font-weight: 700;
}

.chart-meta em {
  display: block;
  margin-top: 2px;
  font-style: normal;
  font-family: var(--font-number);
  font-size: 11px;
  line-height: 1.2;
}

.chart-meta i {
  display: block;
  margin-top: 1px;
  color: var(--muted);
  font-family: var(--font-number);
  font-size: 11px;
  font-style: normal;
  line-height: 1.2;
}

.kline-chart {
  position: relative;
  z-index: 1;
  display: block;
  width: 100%;
  height: calc(100% - 32px);
  overflow: visible;
  filter: drop-shadow(0 5px 8px rgba(0, 0, 0, .22));
}

.chart-card.is-expanded .kline-chart {
  height: 100%;
  min-height: 0;
}

.chart-card.is-expanded .wick {
  stroke-width: .9;
}

.chart-card.is-expanded .candle {
  rx: .55;
}

.chart-detail {
  display: none;
}

.grid-line {
  stroke: rgba(95, 171, 255, .12);
  stroke-width: 1;
  filter: drop-shadow(0 1px 1px rgba(0, 0, 0, .28));
}

.rsi-grid-line {
  stroke: rgba(247, 189, 69, .48);
  stroke-width: .45;
  stroke-dasharray: 4 3;
  filter: drop-shadow(0 0 4px rgba(247, 189, 69, .16));
  vector-effect: non-scaling-stroke;
}

.chart-separator {
  stroke: rgba(83, 168, 255, .18);
  stroke-width: 1;
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, .34));
}

.bb-fill {
  fill: rgba(66, 217, 255, .09);
}

.bb-line {
  fill: none;
  stroke: rgba(89, 224, 255, .78);
  stroke-width: .45;
  filter: drop-shadow(0 0 5px rgba(66, 217, 255, .26)) drop-shadow(0 2px 2px rgba(0, 0, 0, .26));
  vector-effect: non-scaling-stroke;
}

.bb-mid {
  fill: none;
  stroke: rgba(247, 189, 69, .72);
  stroke-width: .45;
  stroke-dasharray: 4 3;
  filter: drop-shadow(0 0 5px rgba(247, 189, 69, .22)) drop-shadow(0 2px 2px rgba(0, 0, 0, .2));
  vector-effect: non-scaling-stroke;
}

.wick {
  stroke-width: 1.35;
  filter: drop-shadow(0 1px 1px rgba(0, 0, 0, .36));
}

.candle {
  rx: 1.2;
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, .42));
}

.chart-up {
  fill: #19d981;
  stroke: #19d981;
  filter: drop-shadow(0 0 4px rgba(25, 217, 129, .28)) drop-shadow(0 1px 2px rgba(0, 0, 0, .34));
}

.chart-down {
  fill: #ff4960;
  stroke: #ff4960;
  filter: drop-shadow(0 0 4px rgba(255, 73, 96, .28)) drop-shadow(0 1px 2px rgba(0, 0, 0, .34));
}

.chart-empty {
  fill: var(--muted);
  font-size: 12px;
}

.rsi-line {
  fill: none;
  stroke: #f7bd45;
  stroke-width: .45;
  stroke-linecap: round;
  stroke-linejoin: round;
  filter: drop-shadow(0 0 5px rgba(247, 189, 69, .28)) drop-shadow(0 2px 2px rgba(0, 0, 0, .2));
  vector-effect: non-scaling-stroke;
}

.trade-controls {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.trade-button {
  height: 42px;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 700;
  transition: transform .12s ease, box-shadow .12s ease, background .12s ease, color .12s ease;
}

.trade-button.start {
  border-color: rgba(25, 217, 129, .35);
  background: #082f25;
  color: #86eab7;
}

.trade-button.start.is-active {
  border-color: #34ff95;
  background: #16bd64;
  color: #f4fff8;
  box-shadow: 0 0 18px rgba(25, 217, 129, .42);
}

.trade-button.pause {
  border-color: rgba(255, 73, 96, .36);
  background: #3d121d;
  color: #ffacb8;
}

.trade-button.pause.is-active {
  border-color: #ff6b7c;
  background: #e6374b;
  color: #fff7f8;
  box-shadow: 0 0 18px rgba(255, 73, 96, .42);
}

.table-zone {
  min-height: 0;
  display: grid;
  grid-template-rows: minmax(0, 1fr);
  gap: 7px;
  margin-bottom: -3px;
}

.data-card {
  min-height: 0;
  display: grid;
  grid-template-rows: 24px minmax(0, 1fr);
  overflow: hidden;
  padding: 7px;
}

.position-card-wrap {
  grid-template-rows: 24px auto minmax(0, 1fr);
  padding-bottom: 3px;
}

.data-title, .settings-title {
  color: #b9ddff;
  font-size: 12px;
  line-height: 1.3;
  font-weight: 700;
}

.position-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.position-tools {
  min-width: 0;
  display: grid;
  grid-template-columns: 118px auto;
  align-items: center;
  justify-content: end;
  gap: 5px;
  justify-self: end;
  margin-right: -4px;
}

.position-tools .settings-button::before {
  inset: -4px -7px;
}

@media (max-width: 380px) {
  .position-tools {
    grid-template-columns: 98px auto;
    gap: 3px;
  }
}

.trade-notice {
  min-width: 0;
  margin: 0 0 6px;
  padding: 6px 8px;
  border: 1px solid rgba(247, 189, 69, .28);
  border-radius: 7px;
  background: rgba(247, 189, 69, .11);
  color: #ffe19a;
  font-size: 11px;
  line-height: 1.35;
  word-break: break-word;
}

.session-pnl {
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 7px;
  color: var(--muted);
  text-align: right;
  white-space: nowrap;
  font-family: var(--font-number);
  font-size: 10px;
  line-height: 1.3;
  font-weight: 600;
}

.session-pnl > span {
  min-width: 0;
  display: inline-flex;
  align-items: center;
}

.session-pnl b {
  display: inline-block;
  font-weight: 700;
  line-height: 1;
}

.session-pnl b.profit-scale-1 {
  font-size: 22px;
}

.session-pnl b.profit-scale-2 {
  font-size: 44px;
}

.session-pnl b.profit-scale-4 {
  font-size: 66px;
}

.hero-session-pnl.session-pnl {
  justify-content: center;
  gap: 10px;
  font-family: var(--font-ui);
  font-size: 11px;
}

.hero-session-pnl.session-pnl > span {
  gap: 1px;
}

.hero-session-pnl.session-pnl b {
  font-family: var(--font-ui);
  font-variant-numeric: proportional-nums;
  font-feature-settings: "pnum" 1, "tnum" 0;
  letter-spacing: 0;
}

.table-wrap, .positions {
  min-height: 0;
  position: relative;
  isolation: isolate;
  overflow: auto;
  border: .5px solid rgba(83, 168, 255, .09);
  border-radius: 8px;
  background:
    repeating-linear-gradient(to bottom, transparent 0 27px, rgba(83, 168, 255, .035) 27px 27.5px),
    repeating-linear-gradient(to right, transparent 0 calc(100% / 5 - .5px), rgba(83, 168, 255, .032) calc(100% / 5 - .5px) calc(100% / 5)),
    rgba(8, 24, 43, .52);
}

.positions::before {
  content: "";
  position: absolute;
  z-index: 0;
  left: 50%;
  top: 83%;
  width: min(292px, 86%);
  aspect-ratio: 1039 / 433;
  transform: translate(-50%, -50%);
  pointer-events: none;
  background: url("/assets/jinlin02-settings-footer.png") center / contain no-repeat;
  opacity: .045;
  filter: drop-shadow(0 0 8px rgba(66, 217, 255, .1));
}

.positions > * {
  position: relative;
  z-index: 1;
}

table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
}

th, td {
  height: 28px;
  overflow: hidden;
  padding: 6px 4px;
  border-bottom: .5px solid rgba(83, 168, 255, .07);
  text-align: center;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: 11px;
  line-height: 1.2;
}

.position-table {
  height: 100%;
}

.position-table tbody {
  height: 100%;
}

.position-table .empty-row td,
.position-table .placeholder-row td {
  color: rgba(137, 169, 200, .58);
}

.position-symbol-cell b {
  margin-left: 3px;
  font-weight: 700;
}

.entry-source-badge {
  display: inline-grid;
  place-items: center;
  width: 13px;
  height: 13px;
  margin-right: 3px;
  border-radius: 3px;
  background: rgba(66, 217, 255, .12);
  color: #d9f5ff;
  font-size: 9px;
  line-height: 1;
}

.manual-close-button {
  width: 42px;
  height: 22px;
  padding: 0;
  border-color: rgba(247, 189, 69, .34);
  border-radius: 6px;
  background: rgba(247, 189, 69, .13);
  color: #ffe0a0;
  font-size: 10px;
  line-height: 1;
}

.manual-close-button:disabled {
  cursor: wait;
  opacity: .58;
}

th {
  position: sticky;
  top: 0;
  z-index: 1;
  color: #91bfe7;
  background: #061a32;
  font-weight: 600;
}

tr:last-child td {
  border-bottom: 0;
}

.position-table th,
.position-table td {
  border-right: .5px solid rgba(83, 168, 255, .065);
}

.position-table th {
  border-bottom-color: rgba(83, 168, 255, .11);
}

.position-table tr:last-child td {
  border-bottom: .5px solid rgba(83, 168, 255, .06);
}

.position-table th:last-child,
.position-table td:last-child {
  border-right: 0;
}

.up {
  color: var(--green);
}

.down {
  color: var(--red);
}

.warn {
  color: var(--gold);
}

footer {
  min-height: 0;
  display: grid;
  justify-items: center;
  align-content: center;
  gap: 0;
  padding-top: 0;
  padding-bottom: 0;
  color: #7292b5;
  text-align: center;
  font-size: 9px;
  line-height: 1.05;
  overflow: visible;
}

.footer-logo {
  width: min(77px, 23vw);
  height: auto;
  display: block;
  object-fit: contain;
  opacity: .84;
  filter: drop-shadow(0 0 8px rgba(66, 217, 255, .14));
}

.home-view footer .footer-logo {
  width: min(74px, 22vw);
  opacity: .68;
  filter: drop-shadow(0 0 4px rgba(66, 217, 255, .07));
  transform: translateY(8px);
}

.settings-view {
  overflow-y: auto;
  display: grid;
  grid-template-rows: auto auto auto minmax(0, 1fr) auto;
  align-content: start;
  padding-bottom: 0;
  background: linear-gradient(180deg, rgba(10, 31, 58, .2), rgba(8, 24, 46, .14));
}

.settings-top {
  position: sticky;
  top: 0;
  z-index: 3;
  display: grid;
  grid-template-columns: 56px minmax(0, 1fr) 56px;
  gap: 10px;
  align-items: start;
  min-height: 112px;
  padding: 34px 0 26px;
  background: linear-gradient(180deg, rgba(2, 11, 27, .99) 0%, rgba(3, 16, 36, .98) 48%, rgba(5, 23, 50, .88) 76%, rgba(6, 28, 58, .44) 92%, rgba(6, 28, 58, 0));
}

.settings-heading {
  grid-column: 2;
  min-width: 0;
  display: grid;
  gap: 3px;
  justify-items: center;
  text-align: center;
}

.settings-top h2 {
  font-size: 27px;
  line-height: 1.05;
  font-weight: 800;
  letter-spacing: 0;
}

.settings-top p {
  min-width: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.2;
  overflow: hidden;
  text-overflow: ellipsis;
}

.settings-top .back-button {
  grid-column: 3;
  justify-self: end;
  width: 34px;
  height: 34px;
  border-color: transparent;
  background: transparent;
  color: #f4fbff;
  font-size: 24px;
  line-height: 1;
  box-shadow: none;
}

.settings-top .back-button:active {
  transform: translateY(1px);
  box-shadow: none;
}

.settings-block {
  margin-bottom: 9px;
  padding: 10px;
  border-color: rgba(83, 168, 255, .14);
  background: rgba(255, 255, 255, .042);
  box-shadow: none;
}

.settings-view .settings-block {
  border-color: transparent;
  background: transparent;
}

.settings-view input:not([type="checkbox"]) {
  border-color: rgba(83, 168, 255, .18);
  background: rgba(2, 11, 24, .58);
  color: var(--text);
  box-shadow: none;
}

.settings-view input:not([type="checkbox"]):focus {
  border-color: rgba(66, 217, 255, .72);
  box-shadow: 0 0 0 2px rgba(66, 217, 255, .1);
}

.settings-view input:not([type="checkbox"]):disabled {
  border-color: rgba(83, 168, 255, .1);
  background: rgba(2, 11, 24, .34);
  color: #7796b3;
  opacity: 1;
}

.settings-entry {
  position: relative;
  z-index: 20;
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
  justify-items: center;
  align-items: center;
  padding-bottom: 8px;
}

.coin-picker {
  width: min(312px, 100%);
  min-width: 0;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  margin: 0 auto;
  padding: 8px 10px;
  border: 1px solid rgba(83, 168, 255, .14);
  border-radius: 8px;
  background: rgba(255, 255, 255, .035);
}

.coin-title {
  color: #cfe9ff;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.2;
  white-space: nowrap;
}

.coin-options {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
}

.coin-options label {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  min-height: 34px;
  border: 1px solid rgba(83, 168, 255, .14);
  border-radius: 7px;
  background: rgba(2, 11, 24, .42);
  color: var(--text);
  font-size: 12px;
  transition: background .16s ease, border-color .16s ease, color .16s ease;
}

.coin-options label.active {
  border-color: rgba(83, 168, 255, .14) !important;
  background: rgba(2, 11, 24, .42) !important;
  color: var(--text) !important;
}

.coin-options input {
  width: 13px;
  height: 13px;
  padding: 0;
  accent-color: #28f78a;
}

.api-connector {
  position: relative;
  z-index: 30;
  width: min(180px, 100%);
  min-width: 0;
  justify-self: center;
}

.api-access-button {
  width: 100%;
  height: 34px;
  border-color: rgba(255, 222, 132, .62);
  background: rgba(255, 222, 132, .22);
  color: #ffe8a6;
  box-shadow: none;
}

.api-connector.connected .api-access-button {
  border-color: rgba(255, 222, 132, .72);
  background: rgba(255, 222, 132, .28);
  color: #fff0b9;
}

.api-popover {
  position: absolute;
  z-index: 40;
  top: 40px;
  left: 50%;
  width: min(320px, calc(100vw - 24px));
  max-height: 0;
  overflow: hidden;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 8px;
  padding: 0 10px;
  border: 1px solid transparent;
  border-radius: 8px;
  background: rgba(5, 18, 36, .98);
  box-shadow: 0 18px 30px rgba(0, 0, 0, .36);
  opacity: 0;
  transform: translate(-50%, -4px);
  transition: max-height .2s ease, padding .2s ease, opacity .16s ease, border-color .16s ease, transform .16s ease;
}

.api-connector:hover .api-popover,
.api-connector.open .api-popover {
  max-height: 340px;
  padding: 8px;
  border-color: rgba(83, 168, 255, .18);
  opacity: 1;
  transform: translate(-50%, 0);
}

.api-form {
  display: grid;
  gap: 6px;
}

.api-oauth-panel {
  display: grid;
  gap: 8px;
}

.api-oauth-button,
.api-register-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  border-radius: 12px;
  text-decoration: none;
  font-size: 13px;
  font-weight: 700;
}

.api-oauth-button {
  width: 100%;
}

.api-register-link {
  border: 1px solid rgba(83, 168, 255, .18);
  color: #cdeeff;
  background: rgba(83, 168, 255, .09);
}

.oauth-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 7px;
  justify-items: center;
  padding: 8px;
  border: 1px solid rgba(83, 168, 255, .18);
  border-radius: 10px;
  background: rgba(83, 168, 255, .08);
}

.oauth-panel[hidden] {
  display: none;
}

.oauth-qr {
  width: min(160px, 100%);
  aspect-ratio: 1;
  padding: 8px;
  border-radius: 8px;
  background: #fff;
}

.oauth-qr svg,
.oauth-qr img {
  display: block;
  width: 100%;
  height: 100%;
}

.oauth-hint {
  margin: 0;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.35;
  text-align: center;
}

.oauth-actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
  width: 100%;
}

.oauth-actions button {
  min-height: 28px;
  padding: 0 8px;
  border: 1px solid rgba(83, 168, 255, .24);
  border-radius: 9px;
  background: rgba(83, 168, 255, .1);
  color: #cdeeff;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}

.oauth-actions button:disabled {
  cursor: wait;
  opacity: .62;
}

.weex-invite-modal[hidden] {
  display: none;
}

.weex-invite-modal {
  position: fixed;
  inset: 0;
  z-index: 3000;
  display: grid;
  place-items: center;
  padding: 18px;
  opacity: 0;
  pointer-events: none;
  transition: opacity .18s ease;
}

.weex-invite-modal.show {
  opacity: 1;
  pointer-events: auto;
}

.weex-invite-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(3, 9, 18, .62);
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
}

.weex-invite-card {
  position: relative;
  width: min(390px, calc(100vw - 32px));
  padding: 22px;
  border: 1px solid rgba(136, 204, 255, .22);
  border-radius: 22px;
  background:
    linear-gradient(150deg, rgba(26, 36, 58, .94), rgba(17, 20, 35, .9)),
    rgba(10, 13, 24, .9);
  box-shadow: 0 30px 90px rgba(0, 0, 0, .38);
  color: #f7fbff;
  transform: translateY(10px) scale(.98);
  transition: transform .2s ease;
}

.weex-invite-modal.show .weex-invite-card {
  transform: translateY(0) scale(1);
}

.weex-invite-kicker {
  display: inline-flex;
  margin-bottom: 10px;
  color: rgba(205, 238, 255, .72);
  font-size: 12px;
  font-weight: 700;
}

.weex-invite-card h3 {
  margin: 0 0 10px;
  font-size: 22px;
  line-height: 1.2;
}

.weex-invite-card p {
  margin: 0;
  color: rgba(234, 244, 255, .78);
  font-size: 14px;
  line-height: 1.7;
}

.weex-invite-code {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  margin: 16px 0 18px;
  padding: 12px 14px;
  border: 1px solid rgba(136, 204, 255, .2);
  border-radius: 16px;
  background: rgba(136, 204, 255, .08);
  text-align: left;
  cursor: pointer;
  transition: border-color .16s ease, background .16s ease, transform .16s ease;
}

.weex-invite-code:hover,
.weex-invite-code.copied {
  border-color: rgba(136, 204, 255, .42);
  background: rgba(136, 204, 255, .14);
}

.weex-invite-code:active {
  transform: scale(.99);
}

.weex-invite-code span {
  color: rgba(234, 244, 255, .68);
  font-size: 12px;
}

.weex-invite-code strong {
  color: #fff;
  font-size: 18px;
  letter-spacing: 0;
}

.weex-invite-actions {
  display: grid;
  grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr);
  gap: 10px;
}

.weex-invite-actions button {
  min-height: 42px;
  border-radius: 14px;
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
}

.weex-invite-cancel {
  border: 1px solid rgba(255, 255, 255, .16);
  background: rgba(255, 255, 255, .08);
  color: rgba(247, 251, 255, .82);
}

.weex-invite-confirm {
  border: 1px solid rgba(255, 255, 255, .3);
  background: linear-gradient(135deg, #f7fbff, #cdeeff);
  color: #111827;
}

.api-form label {
  display: grid;
  gap: 4px;
}

.api-input-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 44px;
  gap: 5px;
  align-items: center;
}

.api-input-row input {
  -webkit-user-select: text;
  user-select: text;
  touch-action: manipulation;
}

.api-paste-button {
  height: 28px;
  padding: 0;
  border-color: rgba(83, 168, 255, .28);
  background: rgba(83, 168, 255, .12);
  color: #cdeeff;
  font-size: 11px;
  line-height: 1;
}

.api-form span {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.2;
}

button.primary {
  height: 30px;
  border-color: rgba(25, 217, 129, .34);
  background: rgba(25, 217, 129, .18);
  color: #bff8d8;
}

.api-message {
  display: none;
  min-height: 0;
  margin-top: 3px;
  color: var(--gold);
  font-size: 12px;
  line-height: 1.35;
}

.strategy-section {
  position: relative;
  z-index: 1;
  padding-top: 12px;
}

.strategy-card-grid {
  width: min(760px, calc(100vw - 28px));
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  align-items: start;
  justify-items: stretch;
  margin: 0 auto;
}

.strategy-card {
  min-width: 0;
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid rgba(83, 168, 255, .14);
  border-radius: 8px;
  background: rgba(4, 17, 35, .28);
}

.strategy-card-head {
  display: grid;
  gap: 3px;
}

.strategy-card-head span {
  color: var(--muted);
  font-size: 10px;
  line-height: 1.1;
}

.strategy-card-head h3 {
  margin: 0;
  color: #eef7ff;
  font-size: 15px;
  line-height: 1.15;
}

.strategy-mode-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 11px;
  align-items: start;
  justify-items: center;
}

.strategy-mode-card {
  position: relative;
  width: min(286px, 100%);
  min-width: 0;
  transition: padding-bottom .2s ease;
}

[data-mode-card="default"]:hover,
[data-mode-card="default"]:focus-within,
[data-mode-card="default"].open {
  padding-bottom: 58px;
}

[data-mode-card="steady"]:hover,
[data-mode-card="steady"]:focus-within,
[data-mode-card="steady"].open {
  padding-bottom: 58px;
}

[data-mode-card="aggressive"]:hover,
[data-mode-card="aggressive"]:focus-within,
[data-mode-card="aggressive"].open {
  padding-bottom: 272px;
}

[data-bollinger-mode-card]:hover,
[data-bollinger-mode-card]:focus-within,
[data-bollinger-mode-card].open {
  padding-bottom: 160px;
}

.strategy-mode-button {
  width: 100%;
  min-height: 44px;
  display: grid;
  place-items: center;
  padding: 0 14px;
  border-color: rgba(83, 168, 255, .2);
  background: rgba(54, 84, 116, .34);
  color: #d5eaff;
  box-shadow: none;
  transition: background .16s ease, border-color .16s ease, color .16s ease;
}

.strategy-mode-button strong {
  font-size: 15px;
  font-weight: 400;
  line-height: 1.15;
}

.strategy-mode-button.active {
  border-color: rgba(56, 255, 159, .72);
  background: rgba(25, 217, 129, .36);
  color: #f1fff7;
}

.strategy-mode-row:has(.strategy-mode-card:hover) .strategy-mode-button.active {
  border-color: rgba(83, 168, 255, .2);
  background: rgba(54, 84, 116, .34);
  color: #d5eaff;
}

.strategy-mode-card:hover .strategy-mode-button,
.strategy-mode-row:has(.strategy-mode-card:hover) .strategy-mode-card:hover .strategy-mode-button.active {
  border-color: rgba(56, 255, 159, .72);
  background: rgba(25, 217, 129, .36);
  color: #f1fff7;
}

.strategy-drawer {
  position: absolute;
  top: 52px;
  left: 50%;
  z-index: 4;
  width: 252px;
  max-height: 0;
  overflow: hidden;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr)) 58px;
  gap: 6px;
  padding: 0 8px;
  border: 1px solid transparent;
  border-radius: 8px;
  background: rgba(4, 17, 35, .98);
  box-shadow: 0 16px 28px rgba(0, 0, 0, .34);
  opacity: 0;
  transform: translate(-50%, -4px);
  transition: max-height .2s ease, padding .2s ease, opacity .16s ease, transform .16s ease, border-color .16s ease;
}

.strategy-mode-card:hover .strategy-drawer,
.strategy-mode-card:focus-within .strategy-drawer,
.strategy-mode-card.open .strategy-drawer {
  max-height: 280px;
  padding: 8px;
  border-color: rgba(83, 168, 255, .18);
  opacity: 1;
  transform: translate(-50%, 0);
}

[data-mode-card="default"] .strategy-drawer {
  left: 50%;
  transform: translate(-50%, -4px);
}

[data-mode-card="default"]:hover .strategy-drawer,
[data-mode-card="default"]:focus-within .strategy-drawer,
[data-mode-card="default"].open .strategy-drawer {
  transform: translate(-50%, 0);
}

.symbol-mode-drawer,
.steady-drawer,
.aggressive-card .strategy-drawer {
  left: 50%;
  right: auto;
  width: min(398px, calc(100vw - 24px));
  grid-template-columns: 1fr;
  transform: translate(-50%, -4px);
}

.compact-symbol-grid .symbol-param-group {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.aggressive-card:hover .strategy-drawer,
.aggressive-card:focus-within .strategy-drawer,
.aggressive-card.open .strategy-drawer,
.strategy-mode-card:hover .symbol-mode-drawer,
.strategy-mode-card:focus-within .symbol-mode-drawer,
.strategy-mode-card.open .symbol-mode-drawer {
  max-height: 520px;
  transform: translate(-50%, 0);
}

.strategy-drawer label {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.strategy-drawer span,
.symbol-param-group b {
  color: var(--muted);
  font-size: 10px;
  line-height: 1.15;
}

.strategy-drawer input {
  height: 26px;
  padding: 0 6px;
  font-size: 12px;
}

.mode-save {
  align-self: end;
  height: 26px;
  border-color: rgba(25, 217, 129, .34);
  background: rgba(25, 217, 129, .18);
  color: #c9ffe0;
  font-size: 12px;
}

.aggressive-common {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
}

.symbol-param-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.symbol-param-group {
  min-width: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 5px;
  padding: 7px;
  border: 1px solid rgba(83, 168, 255, .12);
  border-radius: 8px;
  background: rgba(255, 255, 255, .035);
}

.symbol-param-group b {
  grid-column: 1 / -1;
  color: var(--gold);
  font-weight: 700;
}

.symbol-param-empty {
  padding: 8px;
  border: 1px dashed rgba(247, 189, 69, .24);
  border-radius: 8px;
  color: var(--gold);
  text-align: center;
  font-size: 11px;
  line-height: 1.2;
}

.aggressive-drawer .mode-save {
  justify-self: end;
  width: 76px;
}

.bollinger-drawer .mode-save {
  justify-self: center;
}

.strategy-card {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
}

.strategy-card.is-strategy-disabled {
  opacity: .68;
}

.strategy-card-head,
.strategy-card-metric {
  min-width: 0;
}

.strategy-card-actions {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 7px;
}

.strategy-enable-toggle {
  width: 58px;
  height: 30px;
  display: inline-grid;
  grid-template-columns: 18px auto;
  align-items: center;
  justify-content: center;
  gap: 5px;
  padding: 0 7px;
  border: 1px solid rgba(83, 168, 255, .18);
  border-radius: 999px;
  background: rgba(255, 255, 255, .055);
  color: #b8c9dc;
  font-size: 11px;
  cursor: pointer;
  transition: background .16s ease, border-color .16s ease, color .16s ease, box-shadow .16s ease, opacity .16s ease;
}

.strategy-enable-toggle i {
  width: 16px;
  height: 16px;
  border-radius: 999px;
  background: rgba(184, 201, 220, .78);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .4);
}

.strategy-enable-toggle.is-enabled {
  border-color: rgba(56, 255, 159, .34);
  background: rgba(25, 217, 129, .14);
  color: #d8ffe7;
}

.strategy-enable-toggle.is-enabled i {
  background: linear-gradient(135deg, #38ff9f, #54d9ff);
  box-shadow: 0 0 14px rgba(56, 255, 159, .28), inset 0 1px 0 rgba(255, 255, 255, .56);
}

.strategy-enable-toggle:hover,
.strategy-enable-toggle:focus-visible {
  border-color: rgba(83, 168, 255, .38);
  background: rgba(83, 168, 255, .12);
  color: #f3f9ff;
}

.strategy-card-metric {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: auto minmax(72px, auto) minmax(0, 1fr);
  align-items: baseline;
  gap: 9px;
  padding: 9px 10px;
  border: 1px solid rgba(83, 168, 255, .12);
  border-radius: 8px;
  background: rgba(255, 255, 255, .04);
}

.strategy-card-metric span,
.strategy-card-metric em {
  color: var(--muted);
  font-size: 11px;
  font-style: normal;
  line-height: 1.2;
}

.strategy-card-metric strong {
  color: #f7fbff;
  font-size: 22px;
  line-height: 1;
}

.strategy-settings-toggle {
  width: 72px;
  height: 34px;
  display: inline-grid;
  grid-template-columns: 14px auto;
  align-items: center;
  justify-content: center;
  gap: 5px;
  padding: 0 10px;
  border-color: rgba(83, 168, 255, .18);
  background: rgba(255, 255, 255, .06);
  color: #ddecff;
  font-size: 12px;
}

.strategy-settings-toggle svg {
  width: 14px;
  height: 14px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.strategy-settings-toggle.active,
.strategy-settings-toggle:hover {
  border-color: rgba(56, 255, 159, .42);
  background: rgba(25, 217, 129, .18);
  color: #f1fff7;
}

.strategy-settings-stack {
  width: min(760px, calc(100vw - 28px));
  margin: 12px auto 0;
  display: grid;
  gap: 12px;
}

.strategy-settings-panel {
  display: grid;
  gap: 12px;
  padding: 12px;
  border: 1px solid rgba(83, 168, 255, .14);
  border-radius: 8px;
  background: rgba(4, 17, 35, .32);
}

.strategy-settings-panel[hidden] {
  display: none !important;
}

.strategy-settings-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  color: #eef7ff;
  font-size: 13px;
  font-weight: 700;
}

.strategy-settings-close {
  height: 28px;
  padding: 0 10px;
  border-color: rgba(83, 168, 255, .16);
  background: rgba(255, 255, 255, .05);
  color: var(--muted);
  font-size: 12px;
}

.strategy-settings-panel .strategy-mode-card {
  width: 100%;
  padding-bottom: 0 !important;
}

.strategy-settings-panel .strategy-drawer,
.strategy-settings-panel .symbol-mode-drawer,
.strategy-settings-panel .steady-drawer,
.strategy-settings-panel .aggressive-card .strategy-drawer {
  position: static;
  left: auto;
  right: auto;
  width: 100%;
  max-height: 0;
  margin-top: 0;
  padding: 0 8px;
  opacity: 0;
  transform: none;
  pointer-events: none;
}

.strategy-settings-panel .strategy-mode-card.open .strategy-drawer,
.strategy-settings-panel .strategy-mode-card.open .symbol-mode-drawer,
.strategy-settings-panel .strategy-mode-card.open .steady-drawer,
.strategy-settings-panel .aggressive-card.open .strategy-drawer {
  max-height: 640px;
  margin-top: 8px;
  padding: 8px;
  border-color: rgba(83, 168, 255, .18);
  opacity: 1;
  transform: none;
  pointer-events: auto;
}

.strategy-settings-panel .strategy-mode-card:not(.open):hover .strategy-drawer,
.strategy-settings-panel .strategy-mode-card:not(.open):focus-within .strategy-drawer {
  max-height: 0;
  margin-top: 0;
  padding-top: 0;
  padding-bottom: 0;
  border-color: transparent;
  opacity: 0;
  transform: none;
  pointer-events: none;
}

@media (max-width: 760px) {
  .strategy-card-grid {
    grid-template-columns: 1fr;
  }
  .strategy-settings-stack {
    width: min(390px, 100%);
  }
}

.settings-footer {
  align-self: end;
  margin-top: 0;
  padding-bottom: 0;
}

.settings-footer span {
  margin-top: 5px;
  transform: translateY(4px);
}

.settings-footer .footer-logo {
  width: min(77px, 23vw);
  opacity: .84;
  mix-blend-mode: normal;
}

.settings-footer .settings-footer-logo {
  order: -1;
  width: min(92px, 28vw);
  opacity: .78;
  filter: drop-shadow(0 0 10px rgba(66, 217, 255, .2));
}

body[data-app-role="user"] .hero,
body[data-app-role="user"] .chart-card,
body[data-app-role="user"] .data-card,
body[data-app-role="user"] .settings-block {
  --card-corner-a: rgba(102, 229, 255, .86);
  --card-corner-b: rgba(65, 126, 255, .62);
  --card-line-a: rgba(100, 217, 255, .44);
  --card-line-b: rgba(42, 102, 255, .18);
  position: relative;
  isolation: isolate;
  border: .5px solid transparent;
  background:
    linear-gradient(180deg, rgba(13, 39, 72, .9), rgba(4, 15, 35, .92) 46%, rgba(3, 11, 25, .96)) padding-box,
    linear-gradient(135deg, rgba(109, 226, 255, .7), rgba(42, 103, 255, .22) 34%, rgba(255, 255, 255, .08) 50%, rgba(37, 205, 255, .38) 74%, rgba(59, 125, 255, .52)) border-box;
  box-shadow:
    inset 0 0 0 .5px rgba(163, 236, 255, .05),
    inset 0 18px 32px rgba(67, 151, 255, .085),
    inset 0 -20px 30px rgba(0, 3, 14, .34),
    0 0 0 .5px rgba(34, 98, 189, .16),
    0 0 14px rgba(51, 154, 255, .13),
    0 9px 20px rgba(0, 0, 0, .22);
}

body[data-app-role="user"] .chart-card,
body[data-app-role="user"] .data-card {
  overflow: hidden;
  background:
    linear-gradient(var(--panel), var(--panel)) padding-box,
    linear-gradient(135deg, rgba(109, 226, 255, .7), rgba(42, 103, 255, .22) 34%, rgba(255, 255, 255, .08) 50%, rgba(37, 205, 255, .38) 74%, rgba(59, 125, 255, .52)) border-box;
  box-shadow:
    0 0 0 .5px rgba(34, 98, 189, .16),
    0 0 14px rgba(51, 154, 255, .13),
    0 9px 20px rgba(0, 0, 0, .22);
}

body[data-app-role="user"] .settings-block {
  overflow: visible;
}

body[data-app-role="user"] .settings-view .settings-block {
  border-color: transparent;
  background: transparent;
  box-shadow: none;
}

body[data-app-role="user"] .hero::before,
body[data-app-role="user"] .chart-card::before,
body[data-app-role="user"] .data-card::before,
body[data-app-role="user"] .settings-block::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  border-radius: inherit;
  opacity: .9;
  background:
    linear-gradient(90deg, var(--card-corner-a), transparent 54px) top left / 92px .5px no-repeat,
    linear-gradient(180deg, var(--card-corner-a), transparent 54px) top left / .5px 92px no-repeat,
    linear-gradient(270deg, var(--card-corner-b), transparent 54px) top right / 92px .5px no-repeat,
    linear-gradient(180deg, var(--card-corner-b), transparent 54px) top right / .5px 92px no-repeat,
    linear-gradient(90deg, rgba(58, 123, 255, .34), transparent 46px) bottom left / 84px .5px no-repeat,
    linear-gradient(0deg, rgba(58, 123, 255, .34), transparent 46px) bottom left / .5px 84px no-repeat,
    linear-gradient(270deg, rgba(93, 224, 255, .5), transparent 46px) bottom right / 84px .5px no-repeat,
    linear-gradient(0deg, rgba(93, 224, 255, .5), transparent 46px) bottom right / .5px 84px no-repeat,
    linear-gradient(90deg, transparent, rgba(116, 232, 255, .36), transparent) 50% 0 / 72% .5px no-repeat,
    linear-gradient(180deg, rgba(255, 255, 255, .045), transparent 28%, rgba(73, 166, 255, .035));
}

body[data-app-role="user"] .hero::after,
body[data-app-role="user"] .chart-card::after,
body[data-app-role="user"] .data-card::after,
body[data-app-role="user"] .settings-block::after {
  content: "";
  position: absolute;
  inset: 1px;
  z-index: 1;
  pointer-events: none;
  border-radius: 7px;
  opacity: .64;
  background:
    radial-gradient(circle at 18% 0%, rgba(88, 196, 255, .18), transparent 38%),
    radial-gradient(circle at 88% 100%, rgba(43, 105, 255, .12), transparent 42%);
  mix-blend-mode: screen;
}

body[data-app-role="user"] .settings-view .settings-block::before,
body[data-app-role="user"] .settings-view .settings-block::after {
  content: none;
}

body[data-app-role="user"] .chart-card::after,
body[data-app-role="user"] .data-card::after {
  content: none;
}

body[data-app-role="user"] .chart-card::before,
body[data-app-role="user"] .data-card::before {
  background:
    linear-gradient(90deg, var(--card-corner-a), transparent 54px) top left / 92px .5px no-repeat,
    linear-gradient(180deg, var(--card-corner-a), transparent 54px) top left / .5px 92px no-repeat,
    linear-gradient(270deg, var(--card-corner-b), transparent 54px) top right / 92px .5px no-repeat,
    linear-gradient(180deg, var(--card-corner-b), transparent 54px) top right / .5px 92px no-repeat,
    linear-gradient(90deg, rgba(58, 123, 255, .34), transparent 46px) bottom left / 84px .5px no-repeat,
    linear-gradient(0deg, rgba(58, 123, 255, .34), transparent 46px) bottom left / .5px 84px no-repeat,
    linear-gradient(270deg, rgba(93, 224, 255, .5), transparent 46px) bottom right / 84px .5px no-repeat,
    linear-gradient(0deg, rgba(93, 224, 255, .5), transparent 46px) bottom right / .5px 84px no-repeat,
    linear-gradient(90deg, transparent, rgba(116, 232, 255, .36), transparent) 50% 0 / 72% .5px no-repeat;
}

body[data-app-role="user"] .hero > *,
body[data-app-role="user"] .chart-card > *,
body[data-app-role="user"] .data-card > *,
body[data-app-role="user"] .settings-block > * {
  position: relative;
  z-index: 2;
}

body[data-app-role="user"] .chart-card.is-expanded {
  box-shadow:
    0 0 0 .5px rgba(34, 98, 189, .18),
    0 0 18px rgba(51, 154, 255, .16),
    0 12px 24px rgba(0, 0, 0, .26);
}

body[data-app-role="user"] .coin-picker,
body[data-app-role="user"] .api-popover,
body[data-app-role="user"] .strategy-drawer,
body[data-app-role="user"] .symbol-param-group {
  border-width: .5px;
  border-style: solid;
  border-color: rgba(99, 202, 255, .24);
  background:
    linear-gradient(180deg, rgba(13, 42, 76, .68), rgba(3, 14, 32, .82)) padding-box,
    linear-gradient(135deg, rgba(99, 214, 255, .46), rgba(45, 106, 255, .18) 58%, rgba(85, 214, 255, .34)) border-box;
  box-shadow:
    inset 0 0 0 .5px rgba(163, 236, 255, .03),
    inset 0 12px 22px rgba(67, 151, 255, .055),
    0 0 12px rgba(51, 154, 255, .09);
}

body[data-app-role="user"] .api-popover {
  background-color: rgb(5, 18, 36);
  background:
    linear-gradient(180deg, rgb(13, 42, 76), rgb(3, 14, 32)) padding-box,
    linear-gradient(135deg, rgb(55, 129, 174), rgb(21, 55, 105) 58%, rgb(47, 112, 150)) border-box;
}

body[data-app-role="user"] .api-popover input {
  background: rgb(3, 14, 32);
}

body[data-app-role="user"] .api-popover .api-paste-button {
  background: rgb(8, 45, 74);
}

body[data-app-role="user"] .api-popover button.primary {
  background: rgb(14, 76, 50);
}

.admin-view .settings-top {
  grid-template-columns: minmax(0, 1fr) 56px;
  min-height: 58px;
  padding: 2px 0 10px;
}

.admin-view .settings-heading {
  grid-column: 1;
  justify-items: start;
  text-align: left;
}

.admin-view .settings-top h2 {
  font-size: 17px;
  line-height: 1.2;
  font-weight: 700;
}

.admin-view .settings-top .back-button {
  grid-column: 2;
  width: 52px;
  height: 28px;
  font-size: 13px;
}

.admin-view {
  overflow-y: auto;
  padding-bottom: 8px;
}

.shell-admin .admin-health {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.shell-admin .admin-user-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.admin-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 7px;
  margin-top: 8px;
}

.admin-access-controls {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
  align-items: center;
}

.admin-access-controls span {
  color: var(--muted);
  font-size: 11px;
}

.admin-section-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
}

.admin-access-toggle {
  min-width: 86px;
  border-color: rgba(25, 217, 129, .28);
  color: #c8ffe1;
}

.admin-access-toggle.is-closed {
  border-color: rgba(247, 189, 69, .26);
  color: #ffe2a3;
}

.admin-health {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px 8px;
  margin-top: 8px;
}

.admin-health span {
  min-width: 0;
  display: flex;
  justify-content: space-between;
  gap: 6px;
  padding: 7px 8px;
  border: 1px solid rgba(83, 168, 255, .1);
  border-radius: 8px;
  background: rgba(255, 255, 255, .04);
  color: var(--muted);
  font-size: 11px;
  line-height: 1.25;
}

.admin-health b {
  color: var(--text);
  font-family: var(--font-number);
}

.admin-server-status {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px 8px;
  margin-top: 8px;
}

.shell-admin .admin-server-status {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.admin-server-status span,
.admin-watch-grid span {
  min-width: 0;
  display: flex;
  justify-content: space-between;
  gap: 6px;
  padding: 7px 8px;
  border: 1px solid rgba(83, 168, 255, .1);
  border-radius: 8px;
  background: rgba(255, 255, 255, .04);
  color: var(--muted);
  font-size: 11px;
  line-height: 1.25;
}

.admin-server-status b,
.admin-watch-grid b {
  min-width: 0;
  color: var(--text);
  font-family: var(--font-number);
  overflow-wrap: anywhere;
  text-align: right;
}

.admin-system-health {
  display: grid;
  gap: 10px;
  margin-top: 8px;
}

.system-visuals {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.system-meter {
  min-width: 0;
  display: grid;
  justify-items: center;
  gap: 5px;
  padding: 10px 8px;
  border: 1px solid rgba(83, 168, 255, .12);
  border-radius: 8px;
  background: rgba(255, 255, 255, .045);
  text-align: center;
}

.meter-ring {
  width: 58px;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background:
    radial-gradient(circle, rgba(5, 18, 36, .98) 0 56%, transparent 57%),
    conic-gradient(var(--cyan) var(--meter), rgba(83, 168, 255, .12) 0);
}

.meter-ring b {
  color: var(--text);
  font-family: var(--font-number);
  font-size: 13px;
}

.system-meter span {
  color: #cfe9ff;
  font-size: 12px;
  font-weight: 700;
}

.system-meter em {
  max-width: 100%;
  color: var(--muted);
  font-family: var(--font-number);
  font-size: 10px;
  font-style: normal;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.system-status-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 6px 8px;
}

.system-status-grid span {
  min-width: 0;
  display: flex;
  justify-content: space-between;
  gap: 6px;
  padding: 7px 8px;
  border: 1px solid rgba(83, 168, 255, .1);
  border-radius: 8px;
  background: rgba(255, 255, 255, .04);
  color: var(--muted);
  font-size: 11px;
  line-height: 1.25;
}

.system-status-grid b {
  min-width: 0;
  color: var(--text);
  font-family: var(--font-number);
  overflow: hidden;
  text-align: right;
  text-overflow: ellipsis;
}

.admin-watch-pool {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 8px;
}

.admin-watch-card {
  min-width: 0;
  padding: 10px;
  border: 1px solid rgba(83, 168, 255, .12);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(83, 168, 255, .075), rgba(255, 255, 255, .035));
}

.admin-watch-card.has-breakout {
  border-color: rgba(247, 189, 69, .3);
}

.admin-watch-card header {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 7px;
  color: var(--text);
  font-size: 12px;
  line-height: 1.2;
}

.admin-watch-card header div {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.admin-watch-card header em {
  color: var(--muted);
  font-size: 10px;
  font-style: normal;
  font-family: var(--font-number);
}

.admin-watch-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 6px 8px;
}

.admin-metrics div {
  min-width: 0;
  display: grid;
  gap: 4px;
  padding: 8px 6px;
  border: 1px solid rgba(83, 168, 255, .12);
  border-radius: 8px;
  background: rgba(255, 255, 255, .055);
  text-align: center;
}

.admin-metrics span,
.admin-user-grid span,
.admin-empty {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.25;
}

.admin-metrics b {
  color: var(--text);
  font-family: var(--font-number);
  font-size: 16px;
  line-height: 1;
}

.admin-users-table {
  display: grid;
  gap: 8px;
  margin-top: 8px;
}

.admin-user-row {
  min-width: 0;
  padding: 8px;
  border: 1px solid rgba(83, 168, 255, .12);
  border-radius: 8px;
  background: rgba(255, 255, 255, .045);
}

.admin-user-row header {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 7px;
  color: var(--text);
  font-size: 12px;
  line-height: 1.2;
}

.admin-user-row header span {
  color: var(--muted);
}

.admin-status-pill {
  flex: 0 0 auto;
  min-width: 58px;
  display: inline-grid;
  place-items: center;
  padding: 4px 9px;
  border-radius: 999px;
  font-size: 11px;
  line-height: 1;
  font-weight: 700;
}

.admin-status-pill.is-running {
  background: rgba(25, 217, 129, .18);
  color: #89ffc4;
}

.admin-status-pill.is-idle {
  background: rgba(247, 189, 69, .18);
  color: #ffe19a;
}

.admin-status-pill.is-unauthorized {
  background: rgba(255, 104, 104, .18);
  color: #ffb3b3;
}

.admin-user-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 6px 8px;
}

.admin-user-grid span {
  display: flex;
  justify-content: space-between;
  gap: 6px;
}

.admin-user-grid b {
  color: var(--text);
  font-family: var(--font-number);
  font-weight: 700;
}

.admin-user-actions {
  display: flex;
  justify-content: flex-end;
  gap: 7px;
  margin-top: 8px;
}

.admin-mini-button {
  min-width: 56px;
  height: 26px;
  border: 1px solid rgba(83, 168, 255, .18);
  border-radius: 7px;
  background: rgba(255, 255, 255, .07);
  color: var(--text);
  font-size: 12px;
}

.admin-mini-button.danger {
  border-color: rgba(255, 104, 104, .22);
  color: #ffb6b6;
}

.admin-mini-button:disabled {
  cursor: not-allowed;
  opacity: .45;
}

.admin-modal {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: grid;
  place-items: center;
  padding: 16px;
  background: rgba(0, 7, 18, .68);
  backdrop-filter: blur(8px);
}

.admin-modal[hidden] {
  display: none;
}

.admin-modal-card {
  width: min(760px, 100%);
  max-height: min(86vh, 720px);
  overflow: auto;
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1px solid rgba(83, 168, 255, .18);
  border-radius: 10px;
  background: #071529;
  box-shadow: 0 24px 60px rgba(0, 0, 0, .48);
}

.admin-modal-card header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.admin-modal-card header div {
  display: grid;
  gap: 4px;
}

.admin-modal-card header strong {
  color: var(--text);
  font-size: 15px;
}

.admin-modal-card header span,
.admin-modal-actions span {
  color: var(--muted);
  font-size: 11px;
}

.admin-modal-close {
  width: 28px;
  height: 28px;
  border: 1px solid rgba(83, 168, 255, .14);
  border-radius: 8px;
  background: rgba(255, 255, 255, .06);
  color: var(--text);
  font-size: 18px;
  line-height: 1;
}

.admin-edit-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.admin-edit-grid label,
.admin-edit-mode-fields label {
  min-width: 0;
  display: grid;
  gap: 4px;
  color: var(--muted);
  font-size: 11px;
}

.admin-edit-grid input,
.admin-edit-grid select,
.admin-edit-mode-fields input {
  height: 30px;
  min-width: 0;
  padding: 0 8px;
  border: 1px solid rgba(83, 168, 255, .16);
  border-radius: 8px;
  background: rgba(255, 255, 255, .055);
  color: var(--text);
  font-size: 12px;
}

.admin-edit-check {
  align-content: end;
  grid-template-columns: 18px minmax(0, 1fr);
  align-items: center;
  min-height: 30px;
}

.admin-edit-check input {
  width: 16px;
  height: 16px;
  padding: 0;
}

.admin-edit-symbol-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.admin-modal-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
}

.admin-modal-actions span {
  margin-right: auto;
}

.admin-empty {
  padding: 10px;
  border: 1px solid rgba(83, 168, 255, .12);
  border-radius: 8px;
  text-align: center;
}

@media (max-width: 720px) {
  .shell-admin .admin-user-grid,
  .system-status-grid,
  .admin-watch-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .admin-edit-grid,
  .admin-edit-symbol-grid {
    grid-template-columns: 1fr;
  }

  .system-visuals {
    grid-template-columns: 1fr;
  }

  .admin-watch-pool {
    grid-template-columns: 1fr;
  }

  .admin-section-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .admin-access-controls {
    width: 100%;
    justify-content: flex-start;
  }
}

@keyframes ecgRun {
  from { stroke-dashoffset: 150; }
  to { stroke-dashoffset: -150; }
}

@keyframes dotPulse {
  0%, 100% { transform: scale(1); opacity: .72; }
  45% { transform: scale(1.45); opacity: 1; }
}

@keyframes ecgRunnerGlow {
  0%, 100% { opacity: .76; }
  42% { opacity: 1; }
}

@keyframes ecgRunnerHalo {
  0%, 100% { opacity: .42; }
  42% { opacity: .76; }
}

@keyframes ecgTrailRun {
  from { stroke-dashoffset: 348; }
  to { stroke-dashoffset: 0; }
}

.operation-feedback {
  position: fixed;
  top: calc(env(safe-area-inset-top, 0px) + 18px);
  left: 50%;
  z-index: 3000;
  width: min(330px, calc(100vw - 36px));
  min-height: 72px;
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr) 24px;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border: 1px solid rgba(238, 212, 255, .72);
  border-radius: 14px;
  background: rgba(226, 203, 255, .96);
  color: #21133f;
  box-shadow:
    0 18px 38px rgba(28, 10, 58, .34),
    0 0 24px rgba(195, 117, 255, .42),
    inset 0 1px 0 rgba(255, 255, 255, .72);
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, -12px) scale(.98);
  transition: opacity .2s ease, transform .2s ease;
}

.operation-feedback.show {
  opacity: 1;
  pointer-events: auto;
  transform: translate(-50%, 0) scale(1);
}

.operation-feedback-icon {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  position: relative;
  border-radius: 50%;
  background: #3877f0;
  box-shadow:
    0 8px 18px rgba(43, 24, 78, .22),
    inset 0 1px 0 rgba(255, 255, 255, .42);
}

.operation-feedback-copy {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.operation-feedback-copy strong {
  font-size: 17px;
  line-height: 1.15;
  color: inherit;
}

.operation-feedback-copy span {
  font-size: 13px;
  line-height: 1.3;
  color: rgba(33, 19, 63, .78);
}

.operation-feedback-close {
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: rgba(33, 19, 63, .8);
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
}

.operation-feedback.success .operation-feedback-icon {
  background: linear-gradient(135deg, #1ccf72, #0aa84f);
}

.operation-feedback.success .operation-feedback-icon::before {
  content: "";
  width: 20px;
  height: 11px;
  border-left: 3px solid #fff;
  border-bottom: 3px solid #fff;
  transform: rotate(-45deg) translate(1px, -2px);
}

.operation-feedback.error .operation-feedback-icon {
  background: linear-gradient(135deg, #ff4268, #de103e);
}

.operation-feedback.error .operation-feedback-icon::before,
.operation-feedback.error .operation-feedback-icon::after {
  content: "";
  position: absolute;
  width: 22px;
  height: 3px;
  border-radius: 999px;
  background: #fff;
}

.operation-feedback.error .operation-feedback-icon::before {
  transform: rotate(45deg);
}

.operation-feedback.error .operation-feedback-icon::after {
  transform: rotate(-45deg);
}

.operation-feedback.warning .operation-feedback-icon {
  background: linear-gradient(135deg, #ffae38, #ff801f);
}

.operation-feedback.warning .operation-feedback-icon::before {
  content: "!";
  color: #fff;
  font-size: 28px;
  font-weight: 800;
  line-height: 1;
}

.operation-feedback.info .operation-feedback-icon {
  background: linear-gradient(135deg, #3b8dff, #2e60f0);
}

.operation-feedback.info .operation-feedback-icon::before {
  content: "i";
  color: #fff;
  font-size: 28px;
  font-family: Georgia, serif;
  font-weight: 700;
  line-height: 1;
}

.operation-feedback.loading .operation-feedback-icon {
  background: linear-gradient(135deg, #7e52df, #5f3cc9);
}

.operation-feedback.loading .operation-feedback-icon::before {
  content: "";
  width: 24px;
  height: 24px;
  border: 3px solid rgba(255, 255, 255, .34);
  border-top-color: #fff;
  border-radius: 50%;
  animation: feedbackSpin .75s linear infinite;
}

@keyframes feedbackSpin {
  to { transform: rotate(360deg); }
}
