/* 登录门 + 顶栏第二行 + 中转配置 */

.watch-panel.panel {
  position: relative;
}

.gate-center {
  position: absolute;
  inset: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(5, 5, 8, 0.55);
  backdrop-filter: blur(4px);
}

.gate-center[hidden],
.relay-setup[hidden],
.pay-gate[hidden],
#logoutBtn[hidden],
.app[data-auth="out"] #logoutBtn {
  display: none !important;
}

.btn-login-wallet {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  height: 32px;
  padding: 0 14px;
  border: none;
  border-radius: 999px;
  background: #2aabee;
  color: #fff;
  font-family: var(--font);
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(42, 171, 238, 0.22);
}

.btn-login-wallet:hover {
  filter: brightness(1.06);
}

.btn-login-wallet:disabled {
  opacity: 0.75;
  cursor: wait;
}

.topbar-row-tools {
  justify-content: flex-end !important;
}

.topbar-tools-right {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 8px 10px;
  margin-left: auto;
  min-width: 0;
}

.join-group-guide-wrap {
  position: relative;
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
}

.join-group-guide-wrap[hidden] {
  display: none !important;
}

.join-group-guide-btn {
  flex: 0 0 auto;
  white-space: nowrap;
  font-size: 0.72rem;
  padding: 4px 18px 4px 10px;
  color: #e8a317 !important;
  border-color: rgba(232, 163, 23, 0.45) !important;
  background: rgba(232, 163, 23, 0.1) !important;
  font-weight: 600;
}

.join-group-guide-btn:hover {
  color: #ffc107 !important;
  border-color: rgba(255, 193, 7, 0.55) !important;
  background: rgba(232, 163, 23, 0.16) !important;
}

.join-group-guide-dismiss {
  position: absolute;
  top: -6px;
  right: -6px;
  width: 16px;
  height: 16px;
  padding: 0;
  border: 1px solid rgba(232, 163, 23, 0.5);
  border-radius: 50%;
  background: #1a1408;
  color: #e8a317;
  font-size: 11px;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
}

.join-group-guide-dismiss:hover {
  color: #fff;
  background: rgba(232, 163, 23, 0.55);
  border-color: rgba(255, 193, 7, 0.7);
}

.join-group-guide-body {
  display: flex;
  flex-direction: column;
  gap: 12px;
  font-size: 0.85rem;
  line-height: 1.55;
  color: var(--text-secondary, #c8c8c8);
}

.join-group-guide-body ol,
.join-group-guide-body ul {
  margin: 0;
  padding-left: 1.2em;
}

.join-group-guide-steps {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.join-group-guide-steps code {
  font-size: 0.8em;
  padding: 1px 5px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.06);
}

.join-group-bot-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  align-self: flex-start;
  margin-top: 2px;
  padding: 8px 14px;
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 600;
  color: #fff;
  text-decoration: none;
  background: #2aabee;
  transition: filter 0.15s ease, transform 0.15s ease;
}

.join-group-bot-link:hover {
  filter: brightness(1.08);
  transform: translateY(-1px);
}

.join-group-guide-note {
  margin: 0;
  font-size: 0.78rem;
  color: var(--text-muted, #888);
}

.modal.modal-join-group-guide {
  width: min(520px, calc(100vw - 32px));
}

.relay-setup {
  position: absolute;
  inset: 0;
  z-index: 21;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 24px;
  background: rgba(5, 5, 8, 0.78);
  backdrop-filter: blur(6px);
  text-align: center;
}

.relay-setup h3 {
  margin: 0;
  font-size: 0.95rem;
}

.relay-setup p {
  margin: 0;
  max-width: 42rem;
  font-size: 0.75rem;
  color: var(--text-secondary);
  line-height: 1.55;
}

.relay-setup code {
  font-size: 0.7rem;
  color: var(--accent-bright);
}

.relay-setup-row {
  display: flex;
  gap: 8px;
  width: min(520px, 100%);
}

.relay-setup-row input {
  flex: 1;
  min-width: 0;
  height: 36px;
  padding: 0 12px;
  border-radius: 10px;
  border: 1px solid var(--border-strong);
  background: rgba(0, 0, 0, 0.35);
  color: var(--text);
  font-family: var(--font);
  font-size: 0.75rem;
}

/* 未登录：顶栏控件占位禁用（进群教程可点） */
.app[data-auth="out"] .topbar-right .bn-mcap-pill,
.app[data-auth="out"] .topbar-right .fdv-update-interval,
.app[data-auth="out"] .topbar-right .btn-topbar:not(#logoutBtn),
.app[data-auth="out"] .topbar-right .btn-settings,
.app[data-auth="out"] .topbar-tools-right > :not(#joinGroupGuideWrap) {
  opacity: 0.55;
  pointer-events: none;
}

.app[data-auth="out"] #emptyState,
.app[data-auth="out"] #monitorScroll {
  visibility: hidden;
}

/* 底池映射：上下同一套列宽，按内容收紧 */
.quote-map-title-row {
  justify-content: flex-start;
  gap: 10px;
  margin-bottom: 12px;
}

.quote-map-panel {
  --quote-map-cols: 42ch minmax(7.5rem, 11rem) auto;
  --quote-map-gap: 8px;
  --quote-map-pad-x: 6px;
  width: fit-content;
  max-width: 100%;
}

.quote-map-add-row,
.quote-map-header,
.quote-map-item {
  display: grid;
  grid-template-columns: var(--quote-map-cols);
  gap: var(--quote-map-gap);
  align-items: center;
  padding-left: var(--quote-map-pad-x);
  padding-right: var(--quote-map-pad-x);
  box-sizing: border-box;
}

.quote-map-add-row {
  margin-bottom: 8px;
  width: 100%;
}

.quote-map-add-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  width: max-content;
}

.quote-map-add-row .settings-field-input.quote-map-ca,
.quote-map-add-row .settings-field-input.quote-map-name,
.quote-map-add-row .settings-field-input.quote-map-search {
  width: 100%;
  min-width: 0;
  height: 28px;
  margin: 0;
  padding: 2px 8px;
  font-size: 0.75rem;
  line-height: 1.2;
  box-sizing: border-box;
}

.quote-map-add-row .settings-field-input.quote-map-ca {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

.quote-map-add-row .settings-field-input.quote-map-ca::placeholder,
.quote-map-add-row .settings-field-input.quote-map-name::placeholder,
.quote-map-add-row .settings-field-input.quote-map-search::placeholder {
  font-size: 0.75rem;
  line-height: 1.2;
}

.quote-map-add-actions .btn-block-unblock {
  flex: 0 0 auto;
  height: 28px;
  font-size: 0.75rem;
  padding: 0 7px;
}

.quote-map-search {
  width: 9.5rem;
  flex: 0 0 9.5rem;
}

.quote-map-scroll {
  width: 100%;
  max-height: 240px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.18);
  padding: 8px 0;
  scrollbar-gutter: stable;
}

.quote-map-header {
  padding-top: 0;
  padding-bottom: 6px;
  margin-bottom: 2px;
  font-size: 0.625rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-muted);
  border-bottom: 1px solid var(--border);
}

.quote-map-col-actions {
  text-align: right;
}

.quote-map-list {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.quote-map-item {
  display: grid !important;
  grid-template-columns: var(--quote-map-cols) !important;
  gap: var(--quote-map-gap) !important;
  align-items: center;
  min-height: 28px;
}

.quote-map-item .block-addr {
  overflow: hidden;
  text-overflow: clip;
  white-space: nowrap;
  word-break: normal;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.6875rem;
  line-height: 1.35;
}

.quote-map-item .block-symbol {
  white-space: nowrap;
}

.quote-map-item .block-actions {
  justify-content: flex-end;
  min-width: 0;
  width: 100%;
}

.pay-gate {
  position: absolute;
  inset: 0;
  z-index: 22;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 28px 20px;
  background: rgba(5, 5, 8, 0.88);
  backdrop-filter: blur(8px);
  text-align: center;
}

.pay-gate h3 {
  margin: 0;
  font-size: 1rem;
  font-weight: 600;
}

.pay-gate-desc {
  margin: 0;
  max-width: 28rem;
  font-size: 0.75rem;
  color: var(--muted, #9a9a9a);
  line-height: 1.45;
}

.pay-gate-grid {
  display: flex;
  gap: 24px;
  justify-content: center;
}

.pay-label {
  display: block;
  font-size: 0.65rem;
  color: var(--muted, #9a9a9a);
  margin-bottom: 4px;
}

.pay-treasury-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  max-width: 100%;
}

.pay-treasury {
  display: block;
  max-width: min(92vw, 28rem);
  padding: 8px 10px;
  border: 1px solid var(--border, #333);
  border-radius: 6px;
  font-size: 0.7rem;
  word-break: break-all;
  background: rgba(0, 0, 0, 0.35);
}

.pay-status {
  margin: 0;
  min-height: 1.2em;
  font-size: 0.72rem;
  color: #1a9eb2;
}

/* 未付费：锁住盯盘控件；设置 / Logout / 进群教程必须可点 */
.app[data-auth="in"][data-paid="0"] .topbar-right .bn-mcap-pill,
.app[data-auth="in"][data-paid="0"] .topbar-right .fdv-update-interval,
.app[data-auth="in"][data-paid="0"] .topbar-right .btn-topbar:not(#logoutBtn),
.app[data-auth="in"][data-paid="0"] .topbar-tools-right > :not(#joinGroupGuideWrap) {
  opacity: 0.45;
  pointer-events: none;
}

.app[data-auth="in"] .topbar-right .btn-settings,
.app[data-auth="in"] .topbar-right #logoutBtn,
.app[data-auth="in"] #joinGroupGuideWrap,
.app[data-auth="out"] #joinGroupGuideWrap {
  opacity: 1 !important;
  pointer-events: auto !important;
}

