.quant-account-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(3, 7, 12, .76);
}
.quant-account-modal {
  width: 420px;
  border: 1px solid #303846;
  border-radius: 8px;
  color: #d8dee9;
  background: #151b24;
  box-shadow: 0 24px 60px rgba(0, 0, 0, .42);
  font-family: "Microsoft YaHei UI", sans-serif;
}
.quant-account-modal header, .quant-account-modal footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
}
.quant-account-modal header { border-bottom: 1px solid #222833; }
.quant-account-modal footer { justify-content: flex-end; border-top: 1px solid #222833; }
.quant-account-modal header strong { display: block; color: #f3f7fb; font-size: 16px; }
.quant-account-modal header span { display: block; margin-top: 5px; color: #8792a2; font-size: 11px; }
.quant-account-body { display: grid; gap: 14px; padding: 16px; }
.quant-account-body label { display: grid; gap: 7px; }
.quant-account-body label span { color: #aab4c0; font-size: 12px; font-weight: 800; }
.quant-account-body input {
  width: 100%; height: 40px; box-sizing: border-box; border: 1px solid #273141; border-radius: 8px;
  outline: none; padding: 0 11px; color: #f3f7fb; background: #0d1219;
}
.quant-account-body input:focus { border-color: rgba(54, 211, 153, .62); box-shadow: 0 0 0 3px rgba(54, 211, 153, .1); }
.quant-account-modes { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.quant-account-modes button { min-height: 34px; border: 0; border-radius: 8px; color: #aab4c0; background: #0f131a; cursor: pointer; }
.quant-account-modes button.active { color: #06110c; background: #36d399; font-weight: 900; }
.quant-account-error { min-height: 18px; margin: 0; color: #fca5a5; font-size: 12px; }
.quant-account-session-status { min-height: 18px; padding: 12px 16px 0; color: #36d399; font-size: 12px; }
.quant-account-session-status.error { color: #fca5a5; }

@media (max-width: 760px) {
  .quant-account-backdrop {
    align-items: end;
    padding: 0;
    padding-top: env(safe-area-inset-top);
  }
  .quant-account-modal {
    width: 100%;
    max-height: calc(100dvh - env(safe-area-inset-top));
    overflow-y: auto;
    overscroll-behavior: contain;
    border-right: 0;
    border-bottom: 0;
    border-left: 0;
    border-radius: 8px 8px 0 0;
  }
  .quant-account-modal header,
  .quant-account-modal footer { padding: 12px; }
  .quant-account-modal header span { max-width: 250px; line-height: 1.5; }
  .quant-account-body { gap: 12px; padding: 14px 12px; }
  .quant-account-body input { height: 46px; font-size: 16px; }
  .quant-account-modes button { min-height: 42px; }
  .quant-account-modal footer {
    position: sticky;
    bottom: 0;
    padding-bottom: calc(12px + env(safe-area-inset-bottom));
    background: #151b24;
  }
  .quant-account-modal footer button { min-height: 44px; flex: 1; }
}
