@font-face {
  font-family: "Sora";
  src: url("fonts/sora/sora-400.ttf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Sora";
  src: url("fonts/sora/sora-500.ttf") format("truetype");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Sora";
  src: url("fonts/sora/sora-600.ttf") format("truetype");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Sora";
  src: url("fonts/sora/sora-700.ttf") format("truetype");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Sora";
  src: url("fonts/sora/sora-800.ttf") format("truetype");
  font-weight: 800;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg: #010815;
  --bg-2: #080d1c;
  --panel: rgba(12, 22, 40, 0.72);
  --panel-border: rgba(212, 175, 55, 0.28);
  --text: #e8edf7;
  --muted: #93a1bd;
  --gold: #d4af37;
  --color-gold: #d4af37;
  --gold-2: #f0d78c;
  --navy: #0a192f;
  --cyan: #00f2fe;
  --color-usdt: #00f2fe;
  --space: clamp(0.7rem, 1.6vw, 1.25rem);
  --glow-gold: 0 0 18px rgba(212, 175, 55, 0.45), 0 0 40px rgba(212, 175, 55, 0.18);
  --glow-cyan: 0 0 16px rgba(0, 242, 254, 0.35);
  --danger: #ff6b7a;
  --ok: #3d9a7a;
  --font: "Sora", "Segoe UI", system-ui, sans-serif;
  --mono: "Sora", ui-monospace, monospace;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

#xxl-hourglass {
  position: fixed;
  inset: 0;
  z-index: 2147483000;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(1, 8, 21, 0.86);
  transition: opacity 0.28s ease, visibility 0.28s;
  /* Carga inicial: solo visual; no bloquear clics (p. ej. Permitir avisos). */
  pointer-events: none;
}
#xxl-hourglass.is-blocking {
  pointer-events: auto;
}
#xxl-hourglass.is-off {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}
#xxl-hourglass .xxl-hg {
  font-size: 58px;
  line-height: 1;
  color: #d4af37;
  animation: xxl-hg-spin 1.05s linear infinite;
  filter: drop-shadow(0 0 14px #d4af37);
}
@keyframes xxl-hg-spin {
  to { transform: rotate(360deg); }
}
@media (prefers-reduced-motion: reduce) {
  #xxl-hourglass .xxl-hg { animation: none; }
}

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
}
body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font);
  color: var(--text);
  background: var(--bg);
  overflow-x: hidden;
}
body.nav-open {
  overflow: hidden;
}

/* Túnel de estrellas (WebGL) — mismo patrón que cibernia.net */
#webgl-container {
  position: fixed;
  inset: 0;
  z-index: -3;
  pointer-events: none;
  background: #010815;
}
#webgl-container canvas {
  display: block;
  width: 100%;
  height: 100%;
}

a { color: var(--gold-2); text-decoration: none; }
.tg-ia-start { margin: 0.35rem 0 0.15rem; }
.tg-ia-start a { text-decoration: underline; }
a:hover { color: #fff; text-shadow: 0 0 10px rgba(212, 175, 55, 0.5); }

.wrap {
  position: relative;
  z-index: 1;
  max-width: 1100px;
  margin: 0 auto;
  padding: 1.25rem 1.5rem 3rem;
}

.top {
  position: relative;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.5rem;
  padding: 0.85rem 1rem;
  border: 1px solid var(--panel-border);
  border-radius: 14px;
  background: var(--panel);
  box-shadow: var(--glow-gold);
  backdrop-filter: blur(10px);
  overflow: visible;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}
.brand img {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: transparent;
  box-shadow: var(--glow-cyan), 0 0 0 2px rgba(212, 175, 55, 0.55);
  object-fit: contain;
}
.brand .name { font-size: 1.05rem; color: var(--gold-2); text-shadow: 0 0 12px rgba(212, 175, 55, 0.35); }
.brand .sub { display: block; font-size: 0.75rem; font-weight: 500; color: var(--muted); letter-spacing: 0.08em; }

.nav { display: flex; gap: 0.85rem; flex-wrap: wrap; align-items: center; }
.nav a, .nav-dd-btn {
  color: var(--muted);
  padding: 0.35rem 0.65rem;
  border-radius: 8px;
  border: 1px solid transparent;
  font-size: 0.9rem;
  background: transparent;
  cursor: pointer;
  font-family: inherit;
}
.nav a:hover, .nav a.active, .nav-dd-btn:hover, .nav-dd.is-active > .nav-dd-btn, .nav-dd.is-open > .nav-dd-btn {
  color: #fff;
  border-color: rgba(212, 175, 55, 0.4);
  background: rgba(212, 175, 55, 0.08);
  box-shadow: var(--glow-gold);
}
.nav > a.nav-cta,
.nav > .nav-dd > .nav-dd-btn.nav-cta {
  color: var(--gold-2);
  border-color: rgba(212, 175, 55, 0.45);
  background: linear-gradient(145deg, rgba(212, 175, 55, 0.22), rgba(10, 25, 47, 0.9));
  box-shadow: none;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  margin: 0;
  min-height: 2.4rem;
  line-height: 1.2;
}
.nav > a.nav-cta.active,
.nav > .nav-dd.is-active > .nav-dd-btn.nav-cta,
.nav > .nav-dd.is-open > .nav-dd-btn.nav-cta {
  color: #fff;
  border-color: rgba(212, 175, 55, 0.45);
  background: linear-gradient(145deg, rgba(212, 175, 55, 0.22), rgba(10, 25, 47, 0.9));
  box-shadow: none;
}
.nav > a.nav-cta:hover,
.nav > .nav-dd > .nav-dd-btn.nav-cta:hover {
  color: #fff;
  border-color: rgba(212, 175, 55, 0.45);
  background: linear-gradient(145deg, rgba(212, 175, 55, 0.22), rgba(10, 25, 47, 0.9));
  box-shadow: var(--glow-gold);
}
.nav a.btn {
  margin-top: 0;
  margin-right: 0;
  display: inline-flex;
  align-items: center;
}
.nav-dd {
  position: relative;
  overflow: visible;
}
.nav-dd-btn::after {
  content: " ▾";
  font-size: 0.75em;
  opacity: 0.8;
}
.nav-dd-menu {
  display: none;
  position: absolute;
  right: 0;
  top: calc(100% + 0.35rem);
  min-width: 12rem;
  padding: 0.35rem;
  border-radius: 10px;
  border: 1px solid var(--panel-border);
  background: rgba(8, 14, 28, 0.98);
  box-shadow: var(--glow-gold);
  z-index: 80;
}
.nav-dd.is-open .nav-dd-menu { display: flex; flex-direction: column; gap: 0.15rem; }
.nav-dd-menu a {
  display: block;
  white-space: nowrap;
}
.nav-dd-menu .nav-dd-logout {
  margin-top: 0.25rem;
  padding-top: 0.45rem;
  border-top: 1px solid rgba(212, 175, 55, 0.22);
  color: #ff8a96;
}
.nav-dd-menu .nav-dd-logout:hover {
  color: #fff;
  border-color: rgba(255, 107, 122, 0.45);
  background: rgba(255, 107, 122, 0.12);
  box-shadow: none;
}
.top, .top-right, .nav { overflow: visible; }
.charts-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}
.charts-toolbar h1 { margin-bottom: 0.35rem; }
.charts-toolbar-right {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 0.75rem 1rem;
}
.charts-family {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  min-width: 12rem;
}
.charts-family select {
  min-width: 12rem;
  max-width: 18rem;
  padding: 0.4rem 0.65rem;
  border-radius: 8px;
  border: 1px solid rgba(0, 242, 254, 0.2);
  background: rgba(1, 8, 21, 0.65);
  color: #e8eef5;
  font-family: inherit;
  font-size: 0.9rem;
}
.tf-switch {
  display: inline-flex;
  gap: 0.35rem;
  flex-wrap: wrap;
  padding: 0.25rem;
  border-radius: 10px;
  border: 1px solid rgba(0, 242, 254, 0.2);
  background: rgba(1, 8, 21, 0.65);
}
.tf-btn {
  min-width: 2.75rem;
  padding: 0.4rem 0.7rem;
  border-radius: 8px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--muted);
  font-family: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
}
.tf-btn:hover {
  color: #fff;
  border-color: rgba(0, 242, 254, 0.35);
}
.tf-btn.is-active {
  color: #010815;
  background: linear-gradient(135deg, #00f2fe, #4facfe);
  border-color: transparent;
  box-shadow: var(--glow-cyan);
}
.tf-btn:disabled {
  opacity: 0.5;
  cursor: wait;
}
.chart-box.is-loading {
  opacity: 0.55;
  pointer-events: none;
}
.charts-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
}
@media (min-width: 960px) {
  .charts-grid,
  .charts-grid.is-triple { grid-template-columns: 1fr; }
}
.chart-panel .chart-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.65rem 1rem;
  margin-bottom: 0.75rem;
}
.chart-panel .chart-head h2 { margin: 0; flex: 1 1 auto; font-size: 1.05rem; }
.chart-box {
  position: relative;
  width: 100%;
  min-height: 380px;
  height: 420px;
  border-radius: 12px;
  border: 1px solid rgba(0, 242, 254, 0.22);
  overflow: hidden;
  background: linear-gradient(165deg, #010815 0%, #061428 55%, #0a192f 100%);
  box-shadow: inset 0 0 40px rgba(0, 242, 254, 0.04);
}
.chart-box-dark canvas {
  display: block;
}
.chart-hover {
  position: absolute;
  top: 10px;
  left: 12px;
  z-index: 5;
  max-width: min(92%, 420px);
  padding: 0.45rem 0.65rem;
  border-radius: 8px;
  border: 1px solid rgba(0, 242, 254, 0.22);
  background: rgba(1, 8, 21, 0.82);
  color: #c5d0db;
  font-size: 0.78rem;
  line-height: 1.35;
  pointer-events: none;
  backdrop-filter: blur(6px);
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.35);
}
.chart-hover.is-empty { opacity: 0; }
.chart-hover-date {
  color: #e8eef5;
  font-weight: 650;
  margin-bottom: 0.2rem;
}
.chart-hover-ohlc {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.75rem;
  color: #9aa8b8;
}
.chart-hover-ohlc em {
  font-style: normal;
  color: #6b7c8f;
  margin-right: 0.15rem;
}
.chart-hover-ohlc .up { color: #2dd4a8; }
.chart-hover-ohlc .down { color: #f07178; }
.chart-hover-trade {
  margin-top: 0.35rem;
  padding-top: 0.3rem;
  border-top: 1px solid rgba(0, 242, 254, 0.12);
}
.chart-hover-trade strong {
  display: block;
  font-weight: 650;
}
.chart-hover-trade.buy strong { color: #22c55e; }
.chart-hover-trade.sell strong { color: #ef4444; }
.chart-hover-trade-meta {
  display: block;
  color: #9aa8b8;
  margin-top: 0.1rem;
}
.chart-levels {
  flex: 1 1 100%;
  display: flex;
  flex-wrap: wrap;
  gap: 0.2rem 0.75rem;
  align-items: center;
}
.chart-levels .lvl-buy { color: #22c55e; font-weight: 600; }
.chart-levels .lvl-sell { color: #ef4444; font-weight: 600; }
.chart-tv { margin-left: auto; }
.chart-draw-tools {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 0.3rem;
  align-items: center;
  margin-left: 0.35rem;
}
.chart-draw-tools .draw-btn {
  min-width: 2.2rem;
  padding: 0.28rem 0.5rem;
  margin: 0;
  font-size: 0.95rem;
  line-height: 1;
  background: rgba(1, 8, 21, 0.75);
  border: 1px solid rgba(0, 242, 254, 0.28);
  color: #e8eef5;
}
.chart-draw-tools .draw-btn:hover {
  border-color: rgba(212, 175, 55, 0.55);
  color: #fff;
}
.chart-draw-tools .draw-btn.is-active {
  background: linear-gradient(135deg, #00f2fe, #4facfe);
  color: #010815;
  border-color: transparent;
}
.chart-box.is-drawing { cursor: crosshair; }
.chart-box.is-freehand { cursor: crosshair; }
.chart-draw-svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 4;
  pointer-events: none;
}
.chart-draw-svg .draw-hline,
.chart-draw-svg .draw-trend,
.chart-draw-svg .draw-freehand {
  stroke-width: 1.5;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.chart-draw-svg .draw-rect {
  fill: rgba(0, 242, 254, 0.08);
  stroke-width: 1;
}
.chart-draw-svg .draw-measure {
  fill: rgba(212, 175, 55, 0.12);
  stroke-width: 1;
  stroke-dasharray: 4 3;
}
.chart-draw-svg .draw-label {
  font-size: 11px;
  font-family: inherit;
}
.chart-draw-palette {
  position: relative;
  display: inline-flex;
  align-items: center;
  margin-left: 0.15rem;
}
.draw-color-toggle {
  min-width: 2.2rem !important;
  padding: 0.28rem 0.45rem !important;
}
.draw-color-dot {
  display: inline-block;
  width: 0.95rem;
  height: 0.95rem;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.35);
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.25);
  vertical-align: middle;
}
.draw-color-menu {
  position: absolute;
  top: calc(100% + 4px);
  right: 0;
  z-index: 30;
  display: grid;
  grid-template-columns: repeat(5, 1.55rem);
  gap: 0.3rem;
  padding: 0.45rem;
  background: rgba(1, 8, 21, 0.96);
  border: 1px solid rgba(212, 175, 55, 0.4);
  border-radius: 8px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45);
}
.draw-color-menu[hidden] { display: none !important; }
.draw-color-swatch {
  width: 1.55rem;
  height: 1.55rem;
  padding: 0;
  margin: 0;
  border-radius: 6px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(0, 0, 0, 0.25);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.draw-color-swatch.is-active {
  outline: 2px solid #d4af37;
  outline-offset: 1px;
}
.draw-color-select {
  display: none;
}

.panel {
  background: var(--panel);
  border: 1px solid var(--panel-border);
  border-radius: 14px;
  padding: 1.25rem 1.35rem;
  margin-bottom: 1.1rem;
  box-shadow: 0 0 24px rgba(0, 0, 0, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.04);
  backdrop-filter: blur(8px);
}
.panel.glow { box-shadow: var(--glow-gold), 0 0 24px rgba(0, 0, 0, 0.35); }
.balance-toolbar {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.65rem;
  margin-bottom: 0.75rem;
}
.balance-toolbar h2 { margin: 0; }
.balance-scope {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.balance-scope .btn {
  margin: 0;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}

.sl-title {
  margin: 0.35rem 0 0.65rem;
  color: var(--gold-2, #d4af37);
  font-size: 1.55rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  line-height: 1.15;
}
.sl-card { margin-top: 1rem; }
.sl-bases {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 1.2rem;
  margin: 0.35rem 0 0.75rem;
}
.sl-slider-label {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 0.75rem;
}
.sl-pct-out { color: #ff6b7a; font-size: 1.05rem; }
.sl-slider {
  width: 100%;
  margin: 0.2rem 0 0.7rem;
  accent-color: #ff4d5e;
}
.sl-live {
  margin: 0 0 0.4rem;
  color: var(--gold-2);
  font-size: 0.88rem;
}
.sl-fired { color: #ff6b7a; }
.cfg-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 1rem 0 1.25rem;
}
.cfg-tabs .btn { margin: 0; }
.cfg-aw-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem 1rem;
  margin: 0 0 0.45rem;
}
.cfg-aw-head .check { margin: 0; flex: 1 1 16rem; }
.cfg-net-label { align-items: center; }
.cfg-net-chk { margin: 0 0.15rem 0 0; }
.cfg-net-ball {
  display: inline-block;
  width: 0.68rem;
  height: 0.68rem;
  border-radius: 50%;
  flex: 0 0 auto;
}
.cfg-net-ball.is-on {
  background: #22c55e;
  box-shadow: 0 0 0 1px rgba(34, 197, 94, 0.45);
}
.cfg-net-ball.is-off {
  background: #ef4444;
  box-shadow: 0 0 0 1px rgba(239, 68, 68, 0.4);
}
.cfg-addr-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
  margin: 0 0 0.75rem;
}
.cfg-addr-row input {
  flex: 1 1 16rem;
  min-width: 0;
  margin: 0;
}
.cfg-addr-row .btn { margin: 0; white-space: nowrap; }
.cfg-addr-row .btn[aria-disabled="true"] {
  opacity: 0.45;
  pointer-events: none;
}
.cfg-addr-label {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.45rem 0.75rem;
}
.cfg-addr-err {
  display: none;
  margin: 0;
  color: #ff4d5e;
  font-size: 0.82rem;
  font-weight: 650;
  line-height: 1.25;
}
.cfg-addr-err.is-on { display: inline; }
#cfg-strategy-err.is-on { display: block; margin: 0 0 0.65rem; }
.cfg-addr-row input.is-invalid,
input.is-invalid {
  border-color: #ff4d5e;
  box-shadow: 0 0 0 1px rgba(255, 77, 94, 0.35);
}
.cfg-bal-widgets {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  margin: 0 0 1rem;
}
.cfg-bal-card {
  border: 1px solid rgba(212, 175, 55, 0.28);
  border-radius: 12px;
  padding: 0.7rem 0.9rem;
  background: rgba(12, 22, 40, 0.55);
}
.cfg-bal-label {
  display: block;
  color: var(--muted);
  font-size: 0.82rem;
  margin-bottom: 0.25rem;
}
.cfg-bal-card strong {
  color: var(--gold-2);
  font-size: 1.15rem;
  letter-spacing: 0.02em;
}
.cfg-bal-sub {
  display: block;
  color: var(--muted);
  font-size: 0.8rem;
  margin-top: 0.2rem;
}
.cfg-bal-card.is-pending {
  border-color: rgba(212, 175, 55, 0.55);
}
.cfg-bal-card.is-ready {
  border-color: rgba(34, 197, 94, 0.5);
}
.cfg-aw-min-block {
  margin: 0 0 0.85rem;
}
.cfg-aw-min-block input[type="number"] {
  max-width: 10rem;
}
.cfg-wd-list {
  margin: 0 0 0.85rem;
  padding-left: 1.1rem;
  color: var(--muted);
  font-size: 0.85rem;
}
.cfg-etherfi-tip { margin-top: 0.85rem; }
.cfg-etherfi-tip a { color: var(--gold-2); }
.retirar-result {
  margin: 0.85rem 0 0;
  padding: 0.7rem 0.85rem;
  border-radius: 10px;
  border: 1px solid rgba(147, 161, 189, 0.28);
  font-size: 0.92rem;
}
.retirar-result.is-ok {
  border-color: rgba(0, 229, 168, 0.4);
  color: #b8ffe8;
  background: rgba(0, 80, 60, 0.25);
}
.retirar-result.is-err {
  border-color: rgba(255, 107, 122, 0.5);
  color: #ffd0d5;
  background: rgba(80, 16, 28, 0.28);
}
.retirar-log {
  margin-top: 1.4rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(212, 175, 55, 0.18);
}
.retirar-log-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.7rem;
}
.retirar-log-head h2 { margin: 0; }
.retirar-log-wrap { overflow-x: auto; }
.retirar-log-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.84rem;
}
.retirar-log-table th,
.retirar-log-table td {
  text-align: left;
  padding: 0.45rem 0.5rem;
  border-bottom: 1px solid rgba(147, 161, 189, 0.16);
  vertical-align: top;
}
.retirar-log-table th { color: var(--muted); font-weight: 600; }
.retirar-log-dest,
.retirar-log-tx {
  word-break: break-all;
  max-width: 18rem;
}
.retirar-log-dest a,
.retirar-log-tx a,
.admin-cfg-dl a {
  color: var(--gold, #d4af37);
}
.admin-cfg-dl {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr));
  gap: 0.7rem 1.2rem;
  margin: 0.8rem 0 1.2rem;
}
.admin-cfg-dl div { margin: 0; }
.admin-cfg-dl dt {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 600;
}
.admin-cfg-dl dd {
  margin: 0.15rem 0 0;
  word-break: break-all;
}
.retirar-st {
  display: inline-block;
  font-weight: 700;
  letter-spacing: 0.03em;
  padding: 0.12rem 0.5rem;
  border-radius: 6px;
  font-size: 0.76rem;
  line-height: 1.35;
}
.retirar-st-pending {
  color: #3a2a00;
  background: #f5c518;
}
.retirar-st-ok {
  color: #043226;
  background: #00e5a8;
}
.retirar-st-error {
  color: #fff8f8;
  background: #e23b4a;
}
.retirar-warn {
  margin: 0;
  color: #ffd0d5;
  line-height: 1.45;
}
@media (max-width: 640px) {
  .cfg-bal-widgets { grid-template-columns: 1fr; }
}

h1, h2 { margin: 0 0 0.75rem; font-weight: 650; }
h1,
.title-gold {
  font-family: var(--font);
  font-size: 1.45rem;
  font-weight: 650;
  letter-spacing: 0;
  line-height: 1.2;
  color: var(--gold-2);
  text-shadow: 0 0 18px rgba(212, 175, 55, 0.35);
}
h2 { font-size: 1.05rem; color: var(--cyan); text-shadow: var(--glow-cyan); }
h2.title-gold {
  font-family: var(--font);
  font-size: 1.45rem;
  font-weight: 650;
  letter-spacing: 0;
  line-height: 1.2;
  color: var(--gold-2);
  text-shadow: 0 0 18px rgba(212, 175, 55, 0.35);
}

.flash { list-style: none; padding: 0; margin: 0 0 1rem; }
.flash li {
  position: relative;
  padding: 0.65rem 2.2rem 0.65rem 0.85rem;
  border-radius: 10px;
  margin-bottom: 0.4rem;
  border: 1px solid transparent;
}
.flash-x {
  position: absolute;
  top: 0.28rem;
  right: 0.28rem;
  width: 1.6rem;
  height: 1.6rem;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: inherit;
  font-size: 1.15rem;
  line-height: 1;
  cursor: pointer;
}
.flash-x:hover { background: rgba(255, 255, 255, 0.08); }
.flash .ok { background: rgba(61, 154, 122, 0.18); border-color: rgba(61, 154, 122, 0.45); color: #a8e6cf; }
.flash .error { background: rgba(255, 107, 122, 0.12); border-color: rgba(255, 107, 122, 0.4); color: #ffc0c6; }

.table { width: 100%; border-collapse: collapse; }
.table th, .table td {
  text-align: left;
  padding: 0.7rem 0.45rem;
  border-bottom: 1px solid rgba(147, 161, 189, 0.18);
  font-size: 0.92rem;
}
.table th { color: var(--gold); font-weight: 600; font-size: 0.8rem; letter-spacing: 0.04em; text-transform: uppercase; }
.table tr:hover td { background: rgba(212, 175, 55, 0.05); }
.balance-table tr.balance-total td {
  border-top: 1px solid rgba(212, 175, 55, 0.35);
  font-weight: 600;
  color: var(--gold);
}
.balance-table td[data-i18n-label="balance_col_operating"] {
  color: var(--gold);
}
.bot-panel .panel {
  margin-top: 1rem;
  margin-bottom: 0.75rem;
}

.badge {
  display: inline-block;
  padding: 0.18rem 0.55rem;
  border-radius: 999px;
  font-size: 0.72rem;
  border: 1px solid rgba(147, 161, 189, 0.35);
  letter-spacing: 0.03em;
}
.badge.on { color: #a8e6cf; border-color: #2f6b55; box-shadow: 0 0 10px rgba(61, 154, 122, 0.35); }
.badge.off { color: var(--muted); }
.badge.err { color: #ffc0c6; border-color: #6b2f2f; box-shadow: 0 0 10px rgba(255, 107, 122, 0.3); }
.badge.warn { color: #ffe6a8; border-color: #6b5a2f; box-shadow: 0 0 10px rgba(255, 196, 77, 0.28); }
.health-kpis { display: flex; flex-wrap: wrap; gap: 0.45rem; margin-top: 0.75rem; }
.bulk-bar .bulk-actions,
.bulk-bar > label { display: flex; flex-wrap: wrap; gap: 0.5rem; align-items: center; margin-bottom: 0.75rem; }
.filter-bar { display: flex; flex-wrap: wrap; gap: 0.75rem; align-items: flex-end; }
.filter-bar label { display: flex; flex-direction: column; gap: 0.25rem; font-size: 0.85rem; color: var(--muted); }
.filter-bar input, .filter-bar select { min-width: 10rem; }
.row-issue td { background: rgba(255, 107, 122, 0.06); }
pre.log-tail {
  max-height: 28rem; overflow: auto; padding: 0.75rem 1rem;
  font-size: 0.78rem; line-height: 1.35; background: rgba(0,0,0,0.35);
  border: 1px solid rgba(212, 175, 55, 0.25); border-radius: 8px; white-space: pre-wrap; word-break: break-word;
}
.log-wrap.log-expanded pre.log-tail,
.log-wrap.log-expanded .log {
  max-height: min(85vh, 56rem);
  min-height: 24rem;
}
.user-alerts {
  list-style: none; margin: 0.85rem 0 0; padding: 0;
  display: flex; flex-direction: column; gap: 0.4rem;
}
.user-alerts li {
  padding: 0.55rem 0.75rem; border-radius: 8px; font-size: 0.9rem;
  border: 1px solid rgba(147, 161, 189, 0.35);
}
.user-alerts .alert-warn { border-color: rgba(255, 196, 77, 0.45); background: rgba(255, 196, 77, 0.08); color: #ffe6a8; }
.user-alerts .alert-err { border-color: rgba(255, 107, 122, 0.45); background: rgba(255, 107, 122, 0.08); color: #ffc0c6; }
.user-alerts .alert-info { border-color: rgba(0, 242, 254, 0.3); background: rgba(0, 242, 254, 0.06); }
.onboard-box {
  margin-top: 1rem; padding: 0.85rem 1rem;
  border: 1px solid rgba(212, 175, 55, 0.35); border-radius: 10px;
  background: rgba(0, 0, 0, 0.22);
}
.onboard-list { list-style: none; margin: 0.5rem 0 0; padding: 0; }
.onboard-list li {
  display: grid; grid-template-columns: 1.4rem 1fr; gap: 0.35rem 0.55rem;
  padding: 0.35rem 0; border-bottom: 1px solid rgba(147, 161, 189, 0.12);
}
.onboard-list li:last-child { border-bottom: 0; }
.onboard-list .tick { color: var(--muted); }
.onboard-list li.ok .tick { color: #a8e6cf; }
.onboard-list .tip { color: #ffe6a8; }
.onboard-done { margin-top: 0.75rem; }
.human-state {
  margin: 0.65rem 0 0.85rem; padding: 0.65rem 0.85rem;
  border-radius: 8px; border: 1px solid rgba(212, 175, 55, 0.35);
  background: rgba(212, 175, 55, 0.06);
}
.human-state.is-drought { border-color: rgba(255, 196, 77, 0.5); background: rgba(255, 196, 77, 0.08); }
.human-state.is-err { border-color: rgba(255, 107, 122, 0.5); background: rgba(255, 107, 122, 0.08); }
.recent-trades { margin-top: 1.25rem; }
.why-not-list { margin: 0.5rem 0 0; padding-left: 1.2rem; color: var(--text); }
.why-not-list li { margin: 0.35rem 0; }
.badge.gold { color: var(--gold-2); border-color: rgba(212, 175, 55, 0.55); box-shadow: var(--glow-gold); }

label { display: block; margin: 0.75rem 0 0.3rem; color: var(--muted); font-size: 0.88rem; }
input[type="text"],
input[type="password"],
input[type="number"],
input[type="date"],
input[type="search"],
textarea,
select {
  width: 100%;
  max-width: 420px;
  padding: 0.55rem 0.7rem;
  border-radius: 10px;
  border: 1px solid rgba(212, 175, 55, 0.28);
  background: rgba(1, 8, 21, 0.75);
  color: var(--text);
  font: inherit;
  box-shadow: inset 0 0 12px rgba(0, 242, 254, 0.05);
}
select { cursor: pointer; }
input:focus,
textarea:focus,
select:focus {
  outline: none;
  border-color: var(--gold);
  box-shadow: var(--glow-gold);
}

.check { display: flex; align-items: center; gap: 0.5rem; margin: 0.6rem 0; color: var(--muted); }
.check input { width: auto; }

.btn {
  display: inline-block;
  margin-top: 0.85rem;
  margin-right: 0.45rem;
  padding: 0.55rem 1.05rem;
  border-radius: 10px;
  border: 1px solid rgba(212, 175, 55, 0.45);
  background: linear-gradient(145deg, rgba(212, 175, 55, 0.22), rgba(10, 25, 47, 0.9));
  color: var(--gold-2);
  font: inherit;
  font-weight: 600;
  cursor: pointer;
  box-shadow: var(--glow-gold);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
a.btn { text-decoration: none; }
.btn:hover { transform: translateY(-1px); color: #fff; box-shadow: 0 0 24px rgba(212, 175, 55, 0.55); }
.btn.primary {
  background: linear-gradient(145deg, #c9a227, #8a7018);
  color: #04101c;
  border-color: var(--gold-2);
}
.btn.danger {
  background: linear-gradient(145deg, rgba(255, 107, 122, 0.35), #3a1520);
  border-color: rgba(255, 107, 122, 0.55);
  color: #ffd0d5;
  box-shadow: 0 0 14px rgba(255, 107, 122, 0.25);
}
.btn.ghost {
  background: transparent;
  box-shadow: none;
}
.inline-form { display: inline; }

.login-box {
  max-width: 400px;
  margin: 10vh auto;
  text-align: center;
}
.login-box .logo-xl {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  margin: 0 auto 1rem;
  background: transparent;
  box-shadow: var(--glow-cyan), var(--glow-gold);
  object-fit: contain;
}
.login-box input { max-width: 100%; text-align: left; }

.log {
  font-family: var(--mono);
  font-size: 0.78rem;
  white-space: pre-wrap;
  word-break: break-word;
  background: rgba(1, 8, 21, 0.85);
  border: 1px solid rgba(0, 242, 254, 0.2);
  border-radius: 10px;
  padding: 0.85rem;
  max-height: 28rem;
  overflow: auto;
  color: #c5d0db;
  box-shadow: inset 0 0 20px rgba(0, 242, 254, 0.06);
}
.log.log-expanded {
  max-height: min(85vh, 56rem);
  min-height: 24rem;
}
.log-wrap { position: relative; }
.log-wrap .log-tail,
.log-wrap .log { padding-right: 4.2rem; }
.log-wrap.doc-copy { padding-right: 3.6rem; }
.log-tools {
  position: absolute;
  top: 0.45rem;
  right: 0.45rem;
  display: flex;
  gap: 0.3rem;
  z-index: 2;
}
.log-tool {
  width: 2rem;
  height: 2rem;
  padding: 0;
  margin: 0;
  border-radius: 8px;
  border: 1px solid rgba(212, 175, 55, 0.4);
  background: rgba(8, 12, 28, 0.88);
  color: var(--gold-2);
  font-size: 1rem;
  line-height: 1;
  cursor: pointer;
  box-shadow: var(--glow-gold);
}
.log-tool:hover { color: #fff; }

.meta { color: var(--muted); font-size: 0.9rem; }
.meta-spaced { margin-top: 0.75rem; }
.grid2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}
.grid3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.85rem;
}
.grid-redit {
  grid-template-columns: repeat(4, 1fr);
  overflow: visible;
}
@media (max-width: 1100px) {
  .grid-redit { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 820px) {
  .grid2, .grid3, .grid-redit { grid-template-columns: 1fr; }
}

.stat {
  position: relative;
  overflow: visible;
  border: 1px solid rgba(212, 175, 55, 0.3);
  border-radius: 12px;
  padding: 0.9rem 1rem;
  background: linear-gradient(160deg, rgba(212, 175, 55, 0.1), rgba(1, 8, 21, 0.5));
  box-shadow: 0 0 16px rgba(212, 175, 55, 0.12);
}
.plat-btc { margin: 1rem 0 1.25rem; }
.plat-btc-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}
.plat-btc-head h2 { margin: 0; font-size: 1.05rem; }
.plat-btc.is-masked .cj-money { letter-spacing: 0.12em; }
.stat .label {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.4rem;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  margin-bottom: 0.35rem;
}
.fx-hover {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 0.28rem;
  margin-left: 0.15rem;
  cursor: help;
  color: #0b1524;
  letter-spacing: 0;
  text-transform: none;
  vertical-align: middle;
}
.fx-ico {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.45rem;
  height: 1.45rem;
  border-radius: 50%;
  border: 1px solid rgba(240, 215, 140, 0.95);
  background: radial-gradient(circle at 32% 28%, #ffe7a3 0%, #d4af37 62%, #a8841c 100%);
  color: #0b1524;
  font-size: 0.78rem;
  font-weight: 800;
  line-height: 1;
  box-shadow: 0 0 10px rgba(212, 175, 55, 0.55);
}
.fx-hover:hover .fx-ico,
.fx-hover:focus .fx-ico {
  transform: scale(1.08);
  box-shadow: 0 0 16px rgba(240, 215, 140, 0.75);
}
.fx-pop {
  display: none;
  position: absolute;
  left: 0;
  top: calc(100% + 8px);
  z-index: 40;
  min-width: 12rem;
  padding: 0.5rem 0.7rem;
  border-radius: 10px;
  border: 1px solid rgba(212, 175, 55, 0.45);
  background: rgba(8, 13, 28, 0.97);
  color: var(--gold-2);
  font-size: 0.82rem;
  font-weight: 650;
  letter-spacing: 0;
  text-transform: none;
  white-space: nowrap;
  box-shadow: var(--glow-gold);
}
.fx-hover:hover .fx-pop,
.fx-hover:focus .fx-pop,
.fx-hover:active .fx-pop { display: block; }
.stat .value {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--gold-2);
  text-shadow: 0 0 12px rgba(212, 175, 55, 0.4);
}
.stat .sub {
  margin-top: 0.25rem;
  font-size: 0.85rem;
  color: var(--cyan);
  text-shadow: var(--glow-cyan);
}
.fleet-split-h {
  margin: 1.25rem 0 0.5rem;
  font-size: 1.05rem;
  color: var(--gold-2);
  font-weight: 700;
}

.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: flex-end;
  margin-bottom: 1rem;
}
.filter-bar .field { flex: 1; min-width: 140px; }
.filter-bar input { max-width: none; }
.filter-bar .btn { margin-top: 0; }

.capture-needed {
  display: inline-block;
  margin: 0.35rem 0;
  padding: 0.35rem 0.65rem;
  border-radius: 8px;
  border: 1px dashed rgba(255, 196, 77, 0.7);
  background: rgba(255, 196, 77, 0.08);
  color: #ffc44d;
  font-size: 0.82rem;
  font-weight: 650;
  letter-spacing: 0.04em;
  box-shadow: 0 0 14px rgba(255, 196, 77, 0.25);
}

.docs-index-hint { margin-top: 0.35rem; }
.doc-glossary {
  margin: 0;
  display: grid;
  gap: 0.85rem 1.25rem;
}
.doc-glossary dt {
  margin: 0;
  color: var(--gold-2);
  font-weight: 650;
  font-size: 0.98rem;
}
.doc-glossary dd {
  margin: 0.2rem 0 0;
  color: #cdd8ec;
  line-height: 1.5;
  padding-bottom: 0.65rem;
  border-bottom: 1px solid rgba(0, 242, 254, 0.08);
}
.doc-glossary dd:last-of-type { border-bottom: 0; padding-bottom: 0; }
@media (min-width: 720px) {
  .doc-glossary {
    grid-template-columns: 11rem 1fr;
    align-items: baseline;
  }
  .doc-glossary dd {
    padding-bottom: 0.75rem;
  }
}
.doc-card {
  display: block;
  padding: 1rem 1.1rem;
  border-radius: 12px;
  border: 1px solid rgba(212, 175, 55, 0.28);
  background: rgba(12, 22, 40, 0.7);
  margin-bottom: 0.75rem;
  transition: box-shadow 0.15s, border-color 0.15s;
}
.doc-card:hover {
  border-color: var(--gold);
  box-shadow: var(--glow-gold);
}
.doc-card h3 { margin: 0 0 0.35rem; color: var(--gold-2); font-size: 1rem; }
.doc-card p { margin: 0; color: var(--muted); font-size: 0.88rem; }

.account-hero {
  display: flex;
  gap: 1rem;
  align-items: center;
  flex-wrap: wrap;
}
.account-hero .actions { margin-left: auto; }

.pos { color: #a8e6cf; }
.neg { color: #ffc0c6; }

/* —— Responsive / mobile —— */
.table-wrap {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

@media (max-width: 720px) {
  .wrap { padding: 0.75rem 0.85rem 2.5rem; }
  .top {
    align-items: center;
    gap: 0.55rem;
    padding: 0.65rem 0.75rem;
  }
  .brand img { width: 44px; height: 44px; }
  .brand .name { font-size: 0.95rem; }
  .panel { padding: 1rem 0.9rem; border-radius: 12px; }
  h1,
  .title-gold,
  h2.title-gold { font-size: 1.2rem; }
  .stat .value { font-size: 1.05rem; }
  .account-hero { flex-direction: column; align-items: stretch; }
  .account-hero .actions {
    margin-left: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
  }
  .account-hero .actions .btn { margin-top: 0.35rem; flex: 1 1 auto; text-align: center; }
  .balance-scope .btn,
  .cfg-tabs .btn { min-height: 44px; }
  .filter-bar { flex-direction: column; align-items: stretch; }
  .filter-bar .field { min-width: 0; width: 100%; }
  .filter-bar .btn, .filter-bar a.btn { width: 100%; text-align: center; margin-right: 0; }
  .table th, .table td { font-size: 0.8rem; padding: 0.55rem 0.35rem; white-space: nowrap; }
  .login-box { margin: 6vh auto; max-width: 100%; }
  .login-box .logo-xl { width: 96px; height: 96px; }
  input[type="text"],
  input[type="password"],
  input[type="number"],
  input[type="date"] { max-width: 100%; font-size: 16px; /* evita zoom iOS */ }
  .btn { min-height: 44px; }
}

@media (max-width: 400px) {
  .grid3, .grid-redit { grid-template-columns: 1fr; }
}

/* —— Login wallet / user —— */
.wallet-actions { margin-top: 1.25rem; }
.wallet-actions .btn { width: 100%; margin-right: 0; }
.login-sep {
  border: 0;
  border-top: 1px solid rgba(212, 175, 55, 0.25);
  margin: 1.5rem 0 1rem;
}
.admin-lan {
  text-align: left;
  color: var(--muted);
  font-size: 0.9rem;
}
.admin-lan summary {
  cursor: pointer;
  color: var(--gold);
  margin-bottom: 0.75rem;
}
.admin-form .btn { width: 100%; margin-right: 0; }
.err-text { color: #ffc0c6 !important; }
.ok-text { color: #a8e6cf !important; }
.kpi-row {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.75rem;
  margin: 1rem 0 1.25rem;
}
.kpi {
  border: 1px solid rgba(212, 175, 55, 0.28);
  border-radius: 12px;
  padding: 0.75rem 0.85rem;
  background: rgba(1, 8, 21, 0.45);
}
.kpi-label {
  display: block;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  margin-bottom: 0.35rem;
}
.kpi-value { font-weight: 650; color: var(--gold-2); }
.row-gap { display: flex; flex-wrap: wrap; gap: 0.5rem; align-items: center; }
.row-gap .btn { margin-top: 0; }
.config-form input,
.config-form textarea { max-width: 100%; }
.admin-form textarea.note-field,
.config-form textarea.note-field {
  min-height: 10rem;
  max-width: 100%;
  resize: vertical;
  line-height: 1.45;
}
.field-tip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.1rem;
  height: 1.1rem;
  margin-left: 0.25rem;
  border-radius: 50%;
  border: 1px solid rgba(212, 175, 55, 0.55);
  color: var(--gold-2);
  font-size: 0.72rem;
  font-weight: 700;
  cursor: help;
  position: relative;
  vertical-align: middle;
  line-height: 1;
  background: rgba(1, 8, 21, 0.55);
}
.field-tip::after {
  content: attr(data-tip);
  position: absolute;
  left: 50%;
  bottom: calc(100% + 0.45rem);
  transform: translateX(-50%);
  width: min(18rem, 70vw);
  padding: 0.55rem 0.7rem;
  border-radius: 10px;
  border: 1px solid rgba(212, 175, 55, 0.45);
  background: rgba(2, 12, 28, 0.97);
  color: var(--text, #e8eef8);
  font-size: 0.78rem;
  font-weight: 500;
  line-height: 1.35;
  text-align: left;
  box-shadow: var(--glow-gold), 0 8px 24px rgba(0, 0, 0, 0.45);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.12s ease;
  z-index: 80;
  white-space: normal;
}
.field-tip:hover::after,
.field-tip:focus::after,
.field-tip:active::after {
  opacity: 1;
  visibility: visible;
}
.strategy-box {
  margin: 1.25rem 0 0.5rem;
  padding: 0.85rem 1rem 1rem;
  border: 1px solid rgba(212, 175, 55, 0.28);
  border-radius: 12px;
  background: rgba(1, 8, 21, 0.4);
}
.strategy-box legend {
  padding: 0 0.35rem;
  color: var(--gold-2);
  font-weight: 650;
}
.wc-mobile-open {
  margin-top: 0.85rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.wc-mobile-open[hidden] { display: none !important; }
.wc-mobile-open .btn { width: 100%; text-align: center; box-sizing: border-box; }
.wc-mobile-open a.btn { display: inline-flex; align-items: center; justify-content: center; text-decoration: none; }
.wc-qr-box {
  margin-top: 1rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.65rem;
}
.wc-qr-box img {
  width: 280px;
  height: 280px;
  max-width: 100%;
  border-radius: 12px;
  border: 1px solid rgba(212, 175, 55, 0.35);
  background: #fff;
  box-shadow: var(--glow-gold);
}
.wc-qr-box[hidden] { display: none !important; }
.kucoin-cta,
.exchange-ctas {
  margin-top: 1.25rem;
  text-align: center;
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  justify-content: center;
  align-items: stretch;
  gap: 0.85rem;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 0.25rem;
  max-width: 100%;
}
.kucoin-cta-link,
.exchange-cta-link {
  display: inline-flex;
  flex-direction: row;
  align-items: center;
  justify-content: flex-start;
  gap: 0.65rem;
  box-sizing: border-box;
  flex: 0 0 auto;
  width: auto;
  min-width: 11.5rem;
  max-width: 16rem;
  min-height: 4.25rem;
  padding: 0.65rem 0.85rem;
  border-radius: 12px;
  border: 1px solid rgba(35, 175, 145, 0.4);
  background: rgba(35, 175, 145, 0.08);
  color: var(--text);
  text-decoration: none;
  transition: box-shadow 0.15s ease, border-color 0.15s ease;
}
.exchange-cta-mexc {
  border-color: rgba(0, 184, 232, 0.45);
  background: rgba(0, 184, 232, 0.08);
}
.exchange-cta-bitbase {
  border-color: rgba(255, 122, 26, 0.5);
  background: rgba(255, 122, 26, 0.08);
}
.exchange-cta-etherfi {
  border-color: rgba(212, 175, 55, 0.5);
  background: rgba(212, 175, 55, 0.1);
}
.kucoin-cta-link:hover,
.exchange-cta-kucoin:hover {
  border-color: #23af91;
  box-shadow: 0 0 18px rgba(35, 175, 145, 0.35);
  color: #fff;
  text-shadow: none;
}
.exchange-cta-mexc:hover {
  border-color: #00b8e8;
  box-shadow: 0 0 18px rgba(0, 184, 232, 0.35);
  color: #fff;
  text-shadow: none;
}
.exchange-cta-bitbase:hover {
  border-color: #ff7a1a;
  box-shadow: 0 0 18px rgba(255, 122, 26, 0.35);
  color: #fff;
  text-shadow: none;
}
.exchange-cta-etherfi:hover {
  border-color: var(--gold);
  box-shadow: var(--glow-gold);
  color: #fff;
  text-shadow: none;
}
.kucoin-cta-link img,
.exchange-cta-link img,
.exchange-cta-ico {
  width: 48px;
  height: 48px;
  object-fit: contain;
  border-radius: 50%;
  flex-shrink: 0;
  box-shadow: 0 0 0 1px rgba(212, 175, 55, 0.25);
}
.kucoin-cta-text,
.exchange-cta-text {
  font-size: 0.82rem;
  line-height: 1.25;
  color: var(--muted);
  text-align: left;
  max-width: 9.5rem;
}
.kucoin-cta-link:hover .kucoin-cta-text,
.exchange-cta-kucoin:hover .exchange-cta-text { color: #a8e6cf; }
.exchange-cta-mexc:hover .exchange-cta-text { color: #9ee8ff; }
.exchange-cta-bitbase:hover .exchange-cta-text { color: #ffc48a; }
.exchange-cta-etherfi:hover .exchange-cta-text { color: var(--gold-2); }
.login-box .kucoin-cta,
.login-box .exchange-ctas {
  margin-top: 1.5rem;
  flex-direction: column;
  flex-wrap: nowrap;
  align-items: stretch;
  justify-content: flex-start;
  overflow-x: visible;
  max-width: 18rem;
  margin-left: auto;
  margin-right: auto;
  gap: 0.75rem;
}
.login-box .exchange-cta-link,
.login-box .kucoin-cta-link {
  width: 100%;
  max-width: none;
  min-width: 0;
  flex: 0 0 auto;
}
@media (max-width: 720px) {
  .kpi-row { grid-template-columns: 1fr 1fr; }
  .exchange-cta-link,
  .kucoin-cta-link {
    min-width: 10.25rem;
    max-width: 14rem;
    min-height: 3.75rem;
    padding: 0.55rem 0.7rem;
  }
  .exchange-cta-link img,
  .kucoin-cta-link img {
    width: 40px;
    height: 40px;
  }
  .top { gap: 0.55rem; }
  .panel { padding: 1rem 0.85rem; }
  .table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .users-table .user-actions { max-width: none; min-width: 12rem; }
  .users-table .btn { min-height: 44px; }
}
@media (max-width: 420px) {
  .kpi-row { grid-template-columns: 1fr; }
}

.wallet-addr {
  font-family: var(--mono);
  font-size: 0.85rem;
  color: var(--cyan);
}
code.uid-short {
  font-family: var(--mono);
  font-size: 0.82rem;
  white-space: nowrap;
  cursor: help;
  border-bottom: 1px dotted var(--muted);
}
.ip-trunc {
  cursor: help;
  white-space: nowrap;
  border-bottom: 1px dotted var(--muted);
}
.users-search {
  position: relative;
  max-width: 36rem;
  margin: 0.85rem 0 0;
}
.users-search-box { position: relative; }
.users-search input[type="search"] {
  width: 100%;
  max-width: none;
  margin: 0;
}
.users-search #user-search-count {
  min-height: 1.2rem;
  margin: 0.4rem 0 0;
}
.users-suggest {
  position: absolute;
  z-index: 30;
  left: 0;
  right: 0;
  top: calc(100% + 4px);
  margin: 0;
  padding: 0.3rem 0;
  list-style: none;
  background: #0a1428;
  border: 1px solid rgba(212, 175, 55, 0.35);
  border-radius: 10px;
  box-shadow: var(--glow-gold);
  max-height: 18rem;
  overflow-y: auto;
}
.users-suggest li button {
  display: block;
  width: 100%;
  text-align: left;
  background: none;
  border: 0;
  color: var(--text);
  font: inherit;
  padding: 0.5rem 0.85rem;
  cursor: pointer;
}
.users-suggest li button:hover,
.users-suggest li.is-active button {
  background: rgba(212, 175, 55, 0.14);
}
.users-suggest .suggest-title {
  display: block;
  color: var(--gold-2);
  font-weight: 600;
}
.users-suggest .hint {
  display: block;
  color: var(--muted);
  font-size: 0.78rem;
  margin-top: 0.1rem;
}
.panel.is-search-empty { display: none; }
.user-row.is-flash td,
.pending-row.is-flash td,
.orphan-row.is-flash td {
  outline: 1px solid var(--gold);
  background: rgba(212, 175, 55, 0.08);
}
.users-table .user-actions {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  min-width: 14.5rem;
  max-width: 22rem;
}
.users-table .user-actions-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  align-items: center;
}
.users-table .inline-form { display: inline; margin: 0; }
.users-table .note-form {
  display: flex;
  gap: 0.35rem;
  align-items: center;
  margin-top: 0.25rem;
}
.users-table .note-form input[type="text"] {
  flex: 1;
  margin: 0;
  font-size: 0.8rem;
  padding: 0.35rem 0.5rem;
}
.users-table .profile-form {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  margin-bottom: 0.4rem;
}
.users-table .profile-form input[type="text"] {
  margin: 0;
  font-size: 0.8rem;
  padding: 0.35rem 0.5rem;
}
.user-alias { color: var(--gold-2); }
.tg-id {
  font-family: var(--mono);
  font-size: 0.8rem;
  color: var(--cyan);
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}
.users-bind-form .check {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0.75rem 0 1rem;
  color: var(--muted);
  font-size: 0.9rem;
}
.row-disabled td { opacity: 0.72; }
.users-table .btn {
  width: auto;
  margin: 0;
  padding: 0.4rem 0.72rem;
  font-size: 0.82rem;
}
.bot-tabs { display: none !important; }
.bot-panel {
  margin-top: 1.1rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(147, 161, 189, 0.22);
}
.bot-panel:first-of-type { border-top: 0; padding-top: 0; }
.bot-panel-title {
  margin: 0 0 0.65rem;
  font-size: 1.05rem;
  font-weight: 650;
  color: var(--gold-2);
}
.bot-stack {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}
.config-form select { max-width: 100%; }

html.is-nav-loading,
html.is-nav-loading * {
  cursor: none !important;
}
#cj-load-cursor {
  display: none;
  position: fixed;
  left: 0;
  top: 0;
  z-index: 10000;
  width: 24px;
  height: 24px;
  margin: -12px 0 0 -12px;
  pointer-events: none;
  will-change: transform;
}
html.is-nav-loading #cj-load-cursor {
  display: block;
}
#cj-load-cursor[hidden] { display: none !important; }
#cj-load-cursor img {
  display: block;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  animation: cj-spin 0.8s linear infinite;
}
@keyframes cj-spin {
  to { transform: rotate(360deg); }
}

@media (prefers-reduced-motion: reduce) {
  html.is-nav-loading,
  html.is-nav-loading * {
    cursor: wait !important;
  }
  html.is-nav-loading #cj-load-cursor,
  #cj-load-cursor { display: none !important; }
  #cj-load-cursor img { animation: none; }
  #webgl-container { display: none !important; }
  body {
    background:
      radial-gradient(900px 480px at 8% -8%, rgba(212, 175, 55, 0.14), transparent 55%),
      radial-gradient(800px 520px at 100% 0%, rgba(0, 242, 254, 0.1), transparent 50%),
      linear-gradient(165deg, var(--bg) 0%, var(--bg-2) 45%, #0a1224 100%);
  }
}

@media print {
  #webgl-container { display: none !important; }
  body { background: #fff; color: #000; }
}

/* —— i18n flags (AutoSeller pattern) —— */
.top-right {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}
.top-public { justify-content: space-between; }
.lang-switch {
  position: relative;
  display: flex;
  gap: 0.05rem;
  border: 1px solid var(--panel-border);
  border-radius: 999px;
  padding: 0.18rem 0.22rem;
  background: rgba(8, 16, 32, 0.65);
}
.lang-now {
  display: none;
  align-items: center;
  justify-content: center;
  border: 0;
  background: transparent;
  line-height: 0;
  padding: 0.35rem 0.38rem;
  border-radius: 999px;
  cursor: pointer;
  min-width: 44px;
  min-height: 44px;
}
.lang-switch-menu {
  display: flex;
  gap: 0.05rem;
  align-items: center;
}
.lang-switch button {
  border: 0;
  background: transparent;
  line-height: 0;
  padding: 0.35rem 0.38rem;
  border-radius: 999px;
  opacity: 0.9;
  cursor: pointer;
}
.lang-switch .flag {
  display: block;
  width: 1.35rem;
  height: 0.9rem;
  border-radius: 2px;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.28);
  object-fit: cover;
}
.lang-switch button.is-active {
  opacity: 1;
  background: rgba(212, 175, 55, 0.22);
  box-shadow: inset 0 0 0 1px rgba(212, 175, 55, 0.45);
}

/* —— community footer —— */
.site-footer {
  margin-top: 2.5rem;
  padding: 1.1rem 0 0.25rem;
  border-top: 1px solid rgba(212, 175, 55, 0.18);
  text-align: center;
}
.site-footer .tg-community {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}
.site-footer .tg-ico {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.35rem;
  height: 1.35rem;
  border-radius: 50%;
  background: #229ed9;
  color: #fff;
  font-size: 0.7rem;
  transform: rotate(-25deg);
}
.site-footer .meta {
  margin: 0.35rem 0 0;
  font-size: 0.85rem;
}
.footer-privacy {
  position: relative;
  display: inline-block;
  margin: 0.85rem auto 0;
  max-width: 36rem;
}
.footer-privacy-trigger {
  appearance: none;
  border: 0;
  background: transparent;
  color: rgba(212, 175, 55, 0.92);
  font: inherit;
  font-size: 0.88rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  cursor: help;
  padding: 0.2rem 0.35rem;
  text-decoration: underline;
  text-decoration-color: rgba(212, 175, 55, 0.35);
  text-underline-offset: 0.2em;
}
.footer-privacy-trigger:hover,
.footer-privacy-trigger:focus-visible {
  color: #f0d78c;
  text-decoration-color: rgba(240, 215, 140, 0.7);
  outline: none;
}
.footer-privacy-pop {
  position: absolute;
  left: 50%;
  bottom: calc(100% + 0.55rem);
  transform: translateX(-50%) translateY(0.25rem);
  width: min(92vw, 26rem);
  padding: 0.85rem 1rem;
  border-radius: 10px;
  border: 1px solid rgba(212, 175, 55, 0.35);
  background: rgba(8, 14, 28, 0.97);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.45);
  text-align: left;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.18s ease, transform 0.18s ease, visibility 0.18s;
  z-index: 40;
}
.footer-privacy-pop::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 100%;
  transform: translateX(-50%);
  border: 7px solid transparent;
  border-top-color: rgba(212, 175, 55, 0.35);
}
.footer-privacy:hover .footer-privacy-pop,
.footer-privacy:focus-within .footer-privacy-pop {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
  pointer-events: auto;
}
.footer-privacy-pop p {
  margin: 0 0 0.55rem;
  font-size: 0.78rem;
  line-height: 1.45;
  color: rgba(220, 228, 240, 0.92);
}
.footer-privacy-pop p:last-child {
  margin-bottom: 0;
}
.footer-privacy-lead {
  color: rgba(240, 215, 140, 0.95) !important;
  font-weight: 600;
  font-size: 0.82rem !important;
}
.footer-ref-icons {
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  justify-content: center;
  align-items: center;
  gap: 0.7rem;
  margin: 0.85rem auto 0;
  width: 100%;
  overflow-x: auto;
}
.footer-ref-ico {
  display: inline-flex;
  flex-direction: row;
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  border-radius: 6px;
  overflow: hidden;
  border: 1px solid rgba(147, 161, 189, 0.35);
  background: rgba(0, 0, 0, 0.25);
  opacity: 0.85;
  transition: opacity 0.15s ease, border-color 0.15s ease;
}
.footer-ref-ico:hover {
  opacity: 1;
  border-color: rgba(212, 175, 55, 0.55);
}
.footer-ref-ico-bitbase {
  border-color: rgba(255, 122, 26, 0.5);
  box-shadow: 0 0 10px rgba(255, 122, 26, 0.22);
  opacity: 1;
}
.footer-ref-ico-gold {
  border-color: rgba(212, 175, 55, 0.55);
  box-shadow: 0 0 10px rgba(212, 175, 55, 0.28);
  opacity: 1;
}
.footer-ref-ico img {
  width: 28px;
  height: 28px;
  object-fit: cover;
  display: block;
}

.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}
@media (max-width: 800px) {
  .grid-2 { grid-template-columns: 1fr; }
}
.paper-verdict.status-promising { border-color: rgba(80, 200, 120, 0.45); }
.paper-verdict.status-marginal { border-color: rgba(212, 175, 55, 0.55); }
.paper-verdict.status-no_go { border-color: rgba(220, 80, 80, 0.5); }
.paper-verdict.status-caution { border-color: rgba(230, 140, 60, 0.55); }
.paper-verdict-head {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  flex-wrap: wrap;
}
.paper-ball {
  display: inline-block;
  width: 1.1rem;
  height: 1.1rem;
  border-radius: 50%;
  background: #64748b;
  box-shadow: 0 0 10px rgba(100, 116, 139, 0.55);
}
.paper-ball.is-ok {
  background: #22c55e;
  box-shadow: 0 0 12px rgba(34, 197, 94, 0.75);
}
.paper-ball.is-notok {
  background: #ef4444;
  box-shadow: 0 0 12px rgba(239, 68, 68, 0.75);
}
.paper-ok-label {
  font-weight: 800;
  letter-spacing: 0.06em;
  font-size: 1.05rem;
}
.paper-ok-label.is-ok { color: #22c55e; }
.paper-ok-label.is-notok { color: #ef4444; }
#paper-verdict-study { margin-top: 0.35rem; }
#paper-spark {
  width: 100%;
  max-width: 720px;
  height: 120px;
  margin-top: 0.75rem;
  background: rgba(0, 0, 0, 0.25);
  border-radius: 8px;
  border: 1px solid rgba(147, 161, 189, 0.2);
}

.ficha-wait {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(1, 8, 21, 0.72);
  backdrop-filter: blur(6px);
}
.ficha-wait[hidden] { display: none !important; }
.ficha-wait-card {
  min-width: 16rem;
  padding: 1.35rem 1.6rem;
  border-radius: 14px;
  border: 1px solid rgba(212, 175, 55, 0.4);
  background: rgba(12, 22, 40, 0.95);
  box-shadow: var(--glow-gold);
  text-align: center;
}
.ficha-wait-spin {
  width: 2.1rem;
  height: 2.1rem;
  margin: 0 auto 0.85rem;
  border-radius: 50%;
  border: 3px solid rgba(0, 242, 254, 0.2);
  border-top-color: #d4af37;
  animation: ficha-spin 0.8s linear infinite;
}
.ficha-wait-card p {
  margin: 0;
  color: var(--gold-2);
  font-weight: 650;
  letter-spacing: 0.03em;
}
@keyframes ficha-spin {
  to { transform: rotate(360deg); }
}

.home-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}
.home-head h1 { margin: 0 0 0.25rem; }
.status-pill {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 7.2rem;
  padding: 0.45rem 0.85rem;
  border-radius: 999px;
  font-weight: 750;
  letter-spacing: 0.06em;
  font-size: 0.82rem;
  cursor: default;
}
.status-pill .status-main {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
}
.status-pill .status-level {
  padding: 0.1rem 0.45rem;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  background: rgba(0, 0, 0, 0.22);
  color: inherit;
  line-height: 1.2;
}
.status-pill.is-on .status-level {
  background: rgba(11, 42, 28, 0.18);
}
.status-pill.is-off .status-level {
  background: rgba(0, 0, 0, 0.28);
}
.status-pill.is-on {
  color: #0b2a1c;
  background: #7ee0b0;
  box-shadow: 0 0 16px rgba(61, 154, 122, 0.45);
}
.status-pill.is-off {
  color: #fff;
  background: #c43b4a;
  box-shadow: 0 0 16px rgba(196, 59, 74, 0.4);
}
.status-pill .status-tip {
  display: none;
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  z-index: 20;
  width: min(22rem, 80vw);
  padding: 0.65rem 0.8rem;
  border-radius: 10px;
  border: 1px solid rgba(212, 175, 55, 0.35);
  background: rgba(8, 13, 28, 0.96);
  color: var(--text);
  font-weight: 500;
  letter-spacing: 0;
  font-size: 0.82rem;
  line-height: 1.4;
  box-shadow: var(--glow-gold);
  text-transform: none;
}
.status-pill:hover .status-tip,
.status-pill:focus .status-tip,
.status-pill:active .status-tip { display: block; }

.first-launch-cue {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin: 0.9rem 0 0;
  padding: 0.9rem 1.05rem;
  border-radius: 12px;
  border: 1px solid rgba(212, 175, 55, 0.5);
  background: linear-gradient(180deg, rgba(212, 175, 55, 0.16), rgba(8, 13, 28, 0.35));
  box-shadow: 0 0 28px rgba(212, 175, 55, 0.22);
}
.first-launch-logo {
  width: 56px;
  height: 56px;
  flex: 0 0 56px;
  animation: cj-logo-bounce 0.9s ease-in-out infinite;
  filter: drop-shadow(0 0 12px rgba(212, 175, 55, 0.55));
}
.first-launch-copy { min-width: 0; }
.first-launch-kicker {
  margin: 0;
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #d4af37;
  font-weight: 750;
}
.first-launch-title {
  margin: 0.15rem 0 0.25rem;
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  color: var(--text);
}
.first-launch-cue .btn { margin-top: 0.45rem; }
@keyframes cj-logo-bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}
@media (prefers-reduced-motion: reduce) {
  .first-launch-logo { animation: none; }
}
.alta-docs-link {
  margin: 0.85rem 0 0;
  padding: 0.55rem 0.75rem;
  border-radius: 8px;
  border: 1px solid rgba(212, 175, 55, 0.28);
  background: rgba(212, 175, 55, 0.06);
}
.login-invited {
  margin: 0.75rem 0 0;
  padding: 0.55rem 0.75rem;
  border-radius: 8px;
  border: 1px solid rgba(212, 175, 55, 0.4);
  background: rgba(212, 175, 55, 0.08);
  color: var(--gold-2);
}
.ref-share { margin-top: 1.25rem; }
.ref-share h2 { margin: 0 0 0.5rem; font-size: 1.05rem; }
.ref-url-row {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  align-items: center;
}
.ref-url-row input[type="text"] {
  flex: 1 1 16rem;
  max-width: 100%;
  font-family: var(--mono);
  font-size: 0.85rem;
}
.ref-card-img {
  display: block;
  width: min(100%, 420px);
  height: auto;
  margin: 1rem 0;
  border-radius: 12px;
  border: 1px solid rgba(212, 175, 55, 0.35);
  box-shadow: var(--glow-gold);
}
.share-btns {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 0.35rem 0 0.5rem;
}
.share-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 6.4rem;
  padding: 0.45rem 0.75rem;
  border-radius: 8px;
  border: 1px solid rgba(147, 161, 189, 0.35);
  background: rgba(0, 0, 0, 0.28);
  color: var(--text);
  font-weight: 650;
  font-size: 0.86rem;
  cursor: pointer;
  text-decoration: none;
}
.share-btn:hover { color: #fff; border-color: rgba(212, 175, 55, 0.55); }
.share-x { border-color: rgba(255, 255, 255, 0.35); }
.share-fb { border-color: rgba(24, 119, 242, 0.55); }
.share-li { border-color: rgba(10, 102, 194, 0.55); }
.share-ig { border-color: rgba(225, 48, 108, 0.55); }
.share-tt { border-color: rgba(238, 29, 82, 0.55); }
.share-wa { border-color: rgba(37, 211, 102, 0.55); }
.share-tg { border-color: rgba(38, 165, 228, 0.55); }
.summary-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.65rem;
}
.summary-head h2,
.summary-head .title-gold { margin: 0; }
.btn-share-rrss {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  min-height: 2.35rem;
  padding: 0 0.85rem 0 0.95rem;
  border-radius: 999px;
  border: 1px solid rgba(212, 175, 55, 0.5);
  background: rgba(212, 175, 55, 0.12);
  color: var(--gold-2);
  cursor: pointer;
  flex-shrink: 0;
}
.btn-share-label {
  color: var(--gold-2);
  font-weight: 650;
  letter-spacing: 0.02em;
  text-shadow: 0 0 18px rgba(212, 175, 55, 0.45);
}
.btn-share-rrss:hover {
  color: #fff;
  border-color: rgba(212, 175, 55, 0.85);
  box-shadow: var(--glow-gold);
}
.btn-share-rrss:hover .btn-share-label { color: #fff; }
.btn-share-rrss svg { display: block; fill: currentColor; flex-shrink: 0; }
.rrss-daily {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 0.55rem 0.75rem;
  margin: 0.75rem 0 0.35rem;
}
.rrss-daily-field {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  font-size: 0.78rem;
  color: var(--gold-2);
}
.rrss-daily-field input[type="date"] {
  min-width: 9.5rem;
  padding: 0.35rem 0.5rem;
  border-radius: 8px;
  border: 1px solid rgba(212, 175, 55, 0.35);
  background: rgba(8, 13, 28, 0.7);
  color: var(--text);
}
.rrss-popup {
  position: fixed;
  inset: 0;
  z-index: 220;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.2rem;
  background: rgba(1, 8, 21, 0.78);
  backdrop-filter: blur(8px);
}
.rrss-popup[hidden] { display: none !important; }
.rrss-popup-card {
  width: min(100%, 28rem);
  max-height: calc(100vh - 2.4rem);
  overflow: auto;
  padding: 1.1rem 1.15rem 1.25rem;
  border-radius: 16px;
  border: 1px solid rgba(212, 175, 55, 0.4);
  background: rgba(10, 18, 32, 0.96);
  box-shadow: var(--glow-gold);
}
.rrss-popup-card.trades-popup-card {
  width: min(100%, 54rem);
}
.rrss-popup-card h2 {
  margin: 0 0 0.45rem;
  font-size: 1.05rem;
  color: var(--gold-2);
}
.rrss-period-label { margin: 0 0 0.4rem; }
.rrss-period {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin: 0 0 0.85rem;
}
.rrss-period .btn.is-active {
  color: #fff;
  border-color: rgba(212, 175, 55, 0.85);
  background: rgba(212, 175, 55, 0.22);
  box-shadow: var(--glow-gold);
}
.rrss-popup-img {
  display: block;
  width: 100%;
  height: auto;
  margin: 0.35rem 0 0.75rem;
  border-radius: 12px;
  border: 1px solid rgba(212, 175, 55, 0.35);
}
.rrss-popup-img[hidden] { display: none; }
.rrss-popup-err { color: #ff8a8a; }
.rrss-popup-share { margin: 0.2rem 0 0.55rem; }
.rrss-popup-share[hidden],
.rrss-popup-hint[hidden] { display: none !important; }
.rrss-popup-close { width: 100%; margin-top: 0.35rem; }
.cj-congrats-card {
  text-align: center;
  width: min(100%, 26rem);
  padding: 1.6rem 1.35rem 1.45rem;
}
.cj-congrats-kicker {
  margin: 0 0 0.55rem;
  letter-spacing: 0.18em;
  font-size: 0.72rem;
  font-weight: 600;
  color: #d4af37;
  text-transform: uppercase;
}
.cj-congrats-card h2 {
  margin: 0 0 0.65rem;
  font-size: 1.35rem;
  line-height: 1.25;
  color: #f4e4b2;
}
.cj-congrats-card .meta { margin: 0 0 1.1rem; }
.cj-congrats-card .btn { min-width: 10rem; }
.cj-congrats-art {
  width: min(12rem, 70%);
  height: 8rem;
  margin: 0 auto 0.85rem;
  border-radius: 12px;
  border: 1px dashed rgba(212, 175, 55, 0.45);
  background: rgba(212, 175, 55, 0.08);
}
#cfg-test-body {
  white-space: pre-wrap;
  text-align: left;
  line-height: 1.45;
}
.cj-notify-ask {
  position: fixed;
  inset: auto 1rem 1.1rem 1rem;
  z-index: 2147483645;
  display: flex;
  justify-content: center;
  pointer-events: none;
}
.cj-notify-ask[hidden] { display: none !important; }
.cj-notify-ask-card {
  pointer-events: auto;
  width: min(100%, 28rem);
  padding: 0.85rem 1rem;
  border-radius: 14px;
  border: 1px solid rgba(212, 175, 55, 0.45);
  background: rgba(10, 18, 32, 0.96);
  box-shadow: var(--glow-gold);
}
.cj-notify-ask-card p { margin: 0 0 0.65rem; color: var(--text); }
.cj-notify-ask-actions { display: flex; gap: 0.45rem; flex-wrap: wrap; }
.cj-notify-toasts {
  position: fixed;
  top: 4.5rem;
  right: 1rem;
  z-index: 2147483646;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  width: min(100% - 2rem, 22rem);
  pointer-events: none;
}
.cj-notify-toast {
  position: relative;
  padding: 0.7rem 2.1rem 0.7rem 0.85rem;
  border-radius: 12px;
  border: 1px solid rgba(212, 175, 55, 0.55);
  background: rgba(10, 18, 32, 0.98);
  box-shadow: var(--glow-gold), 0 8px 32px rgba(0, 0, 0, 0.45);
  color: var(--text);
  white-space: pre-wrap;
  max-height: 14rem;
  overflow: auto;
  pointer-events: auto;
  animation: cj-toast-in 0.35s ease-out;
}
.cj-notify-toast.is-new {
  border-color: rgba(243, 217, 137, 0.85);
}
@keyframes cj-toast-in {
  from { opacity: 0; transform: translateX(1.2rem); }
  to { opacity: 1; transform: translateX(0); }
}
.cj-notify-x {
  position: absolute;
  top: 0.28rem;
  right: 0.28rem;
  width: 1.6rem;
  height: 1.6rem;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--gold-2);
  font-size: 1.15rem;
  line-height: 1;
  cursor: pointer;
}
.cj-notify-x:hover { color: var(--text); background: rgba(212, 175, 55, 0.12); }
.cj-notify-toast strong { display: block; color: var(--gold-2); margin-bottom: 0.3rem; }
.cj-notify-toast p { margin: 0; font-size: 0.86rem; }
#desktop-notify-status:not(:empty) {
  margin-top: 0.55rem;
  padding: 0.55rem 0.7rem;
  border-radius: 10px;
  border: 1px solid rgba(212, 175, 55, 0.35);
  background: rgba(212, 175, 55, 0.08);
  color: var(--gold-2);
}
.pending-act-card { width: min(100%, 34rem); }
.pending-act-list {
  list-style: none;
  margin: 0.75rem 0 0.85rem;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}
.pending-act-list li {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.7rem;
  padding: 0.5rem 0.6rem;
  border-radius: 10px;
  border: 1px solid rgba(212, 175, 55, 0.28);
  background: rgba(0, 0, 0, 0.25);
}
.pending-act-list li > div {
  display: flex;
  flex-direction: column;
  gap: 0.12rem;
  min-width: 0;
}
.pending-act-actions {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}
.pending-act-actions .btn { flex: 1 1 8rem; }
body.pending-act-open { overflow: hidden; }
.pending-ficha-card {
  width: min(100%, 36rem);
  max-height: calc(100vh - 2rem);
}
.pending-ficha-card .admin-form label { margin-top: 0.55rem; }
.pending-ficha-card .admin-form input[readonly] {
  opacity: 0.85;
  cursor: default;
}
.pending-ficha-ips {
  margin: 0.75rem 0 0.35rem;
  padding: 0.55rem 0.65rem;
  border-radius: 10px;
  border: 1px solid rgba(212, 175, 55, 0.22);
  background: rgba(0, 0, 0, 0.22);
  white-space: pre-wrap;
}
.pending-ficha-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.85rem;
}
.pending-ficha-side { margin-top: 0.35rem; }
.pending-ficha-side .inline-form { display: inline; }
#users-pending.is-search-empty,
#users-linked.is-search-empty,
#users-visitors.is-search-empty,
#users-orphans.is-search-empty { display: none; }
.visitors-search { margin: 0.65rem 0 0.85rem; }
.visitors-search input[type="search"] {
  width: min(100%, 28rem);
  margin-top: 0.25rem;
}
.funds-popup-card { width: min(100%, 32rem); }
.funds-bals {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.55rem;
  margin: 0.75rem 0 0.65rem;
}
.funds-bal {
  border: 1px solid rgba(212, 175, 55, 0.28);
  border-radius: 10px;
  padding: 0.45rem 0.5rem;
  background: rgba(0, 0, 0, 0.25);
}
.funds-bal span {
  display: block;
  font-size: 0.72rem;
  color: var(--muted, #9aa7b5);
}
.funds-bal strong {
  display: block;
  margin-top: 0.15rem;
  font-variant-numeric: tabular-nums;
  color: #fff;
}
.funds-actions { flex-wrap: wrap; }
.funds-actions .btn { width: 100%; }
.funds-msg { min-height: 1.2em; }
@media (max-width: 520px) {
  .funds-bals { grid-template-columns: 1fr; }
}
body.rrss-open { overflow: hidden; }
body.share-public {
  min-height: 100vh;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 1.5rem 1rem 2rem;
}
.share-public-card {
  width: min(100%, 28rem);
  padding: 1rem 1.1rem 1.25rem;
  border-radius: 16px;
  border: 1px solid rgba(212, 175, 55, 0.4);
  background: rgba(10, 18, 32, 0.96);
  box-shadow: var(--glow-gold);
}
.share-public-card img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 12px;
  border: 1px solid rgba(212, 175, 55, 0.35);
}
.share-public-card p {
  margin: 0.75rem 0 0;
  color: var(--text);
  word-break: break-word;
}
.share-public-card a { color: var(--gold-2); }
.alta-panel { padding: 1.15rem 1.2rem 1.35rem; }
.alta-progress {
  display: flex;
  align-items: baseline;
  gap: 0.45rem;
  margin: 0 0 1rem;
  color: var(--muted);
}
.alta-progress-num {
  font-size: 1.6rem;
  font-weight: 750;
  color: var(--gold-2);
}
.alta-steps {
  list-style: none;
  margin: 0;
  padding: 0;
}
.alta-step {
  display: grid;
  grid-template-columns: 2.2rem 1fr;
  gap: 0.75rem;
  padding: 0.85rem 0.15rem 0.85rem 0.35rem;
  border-left: 2px solid rgba(147, 161, 189, 0.2);
  margin-left: 1.05rem;
}
.alta-step.is-ok { border-left-color: rgba(126, 224, 176, 0.7); }
.alta-step.is-todo { border-left-color: rgba(212, 175, 55, 0.55); }
.alta-step strong { display: block; color: var(--text); }
.alta-step p { margin: 0.25rem 0 0; }
.alta-mark {
  width: 2.1rem;
  height: 2.1rem;
  margin-left: -1.45rem;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 750;
  background: rgba(12, 22, 40, 0.95);
  border: 1px solid rgba(212, 175, 55, 0.45);
  color: var(--gold-2);
}
.alta-step.is-ok .alta-mark {
  background: #7ee0b0;
  color: #0b2a1c;
  border-color: #7ee0b0;
}
.alta-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin: 1.15rem 0 0;
}

/* ToS gate modal */
.tos-dialog {
  border: 1px solid rgba(212, 175, 55, 0.45);
  border-radius: 12px;
  padding: 0;
  max-width: min(720px, 96vw);
  width: 100%;
  background: #0c1628;
  color: var(--text, #e8edf7);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.55);
}
.tos-dialog::backdrop {
  background: rgba(1, 8, 21, 0.78);
}
.tos-panel {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding: 1.1rem 1.2rem 1.2rem;
  max-height: min(88vh, 900px);
}
.tos-panel h2 {
  margin: 0;
  color: var(--gold-2, #f0d78c);
  font-size: 1.25rem;
}
.tos-body {
  flex: 1 1 auto;
  overflow: auto;
  max-height: 42vh;
  padding: 0.75rem 0.85rem;
  border: 1px solid rgba(147, 161, 189, 0.25);
  border-radius: 8px;
  background: rgba(1, 8, 21, 0.55);
  white-space: pre-wrap;
  font-size: 0.86rem;
  line-height: 1.45;
  color: #c5d0e6;
}
.tos-check {
  display: flex;
  gap: 0.65rem;
  align-items: flex-start;
  font-size: 0.92rem;
  line-height: 1.35;
  cursor: pointer;
}
.tos-check input {
  margin-top: 0.2rem;
  flex: 0 0 auto;
}
.tos-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  justify-content: flex-end;
}

.broadcast-form textarea {
  width: 100%;
  max-width: none;
  min-height: 10rem;
  resize: vertical;
  margin: 0.35rem 0 0.75rem;
}
.broadcast-fold {
  margin: 0.55rem 0 0.85rem;
  border: 1px solid rgba(212, 175, 55, 0.28);
  border-radius: 10px;
  background: rgba(1, 8, 21, 0.45);
  padding: 0.15rem 0.75rem 0.15rem;
}
.broadcast-fold summary {
  cursor: pointer;
  color: var(--gold-2);
  font-weight: 600;
  font-size: 0.9rem;
  padding: 0.55rem 0;
  list-style: none;
}
.broadcast-fold summary::-webkit-details-marker { display: none; }
.broadcast-fold summary::before {
  content: "▸ ";
  color: var(--gold);
}
.broadcast-fold[open] summary::before { content: "▾ "; }
.broadcast-targets {
  margin: 0 0 0.65rem;
  padding: 0 0 0.35rem;
  list-style: none;
  color: var(--muted);
  font-size: 0.85rem;
  max-height: 14rem;
  overflow-y: auto;
}
.broadcast-targets li { margin: 0.2rem 0; }
.broadcast-list-edit {
  min-height: 22rem;
  font-family: var(--mono);
  font-size: 0.86rem;
  line-height: 1.45;
}
.broadcast-edit-rows {
  list-style: none;
  margin: 0.5rem 0 0;
  padding: 0;
}
.broadcast-edit-rows li {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.45rem;
  padding: 0.4rem 0;
  border-bottom: 1px solid rgba(147, 161, 189, 0.14);
}
.broadcast-edit-rows .btn { margin: 0; }
.keys-lan-box {
  margin-top: 1.1rem;
  padding-top: 0.85rem;
  border-top: 1px solid rgba(212, 175, 55, 0.22);
}

/* —— Asistente ayuda (flotante) —— */
.cj-help-fab {
  position: fixed;
  right: 1.1rem;
  bottom: 1.1rem;
  z-index: 2147482000;
  width: 3.35rem;
  height: 3.35rem;
  border: 1px solid rgba(212, 175, 55, 0.55);
  border-radius: 50%;
  padding: 0;
  cursor: pointer;
  background: radial-gradient(circle at 30% 25%, #1a2744 0%, #0a1224 70%);
  box-shadow: var(--glow-gold);
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}
.cj-help-fab:hover {
  transform: scale(1.04);
  box-shadow: 0 0 22px rgba(212, 175, 55, 0.55);
}
.cj-help-fab img {
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  display: block;
  margin: 0 auto;
}
.cj-help-panel {
  position: fixed;
  right: 1rem;
  bottom: 4.85rem;
  z-index: 2147481999;
  width: min(22.5rem, calc(100vw - 1.5rem));
  max-height: min(28rem, calc(100vh - 6.5rem));
  display: flex;
  flex-direction: column;
  border: 1px solid rgba(212, 175, 55, 0.45);
  border-radius: 14px;
  background: rgba(8, 13, 28, 0.96);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.45), var(--glow-gold);
  overflow: hidden;
}
.cj-help-panel[hidden] {
  display: none !important;
}
.cj-help-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.65rem 0.75rem;
  border-bottom: 1px solid rgba(212, 175, 55, 0.25);
  background: rgba(12, 22, 40, 0.85);
}
.cj-help-head strong {
  color: var(--gold-2);
  font-size: 0.92rem;
}
.cj-help-close {
  border: 0;
  background: transparent;
  color: var(--muted);
  font-size: 1.25rem;
  line-height: 1;
  cursor: pointer;
  padding: 0.15rem 0.35rem;
}
.cj-help-close:hover { color: var(--gold); }
.cj-help-log {
  flex: 1 1 auto;
  overflow-y: auto;
  padding: 0.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  min-height: 12rem;
}
.cj-help-msg {
  display: flex;
}
.cj-help-msg-user { justify-content: flex-end; }
.cj-help-msg-bot { justify-content: flex-start; }
.cj-help-bubble {
  max-width: 92%;
  padding: 0.5rem 0.65rem;
  border-radius: 10px;
  font-size: 0.86rem;
  line-height: 1.45;
  white-space: pre-wrap;
  word-break: break-word;
}
.cj-help-msg-user .cj-help-bubble {
  background: rgba(212, 175, 55, 0.18);
  border: 1px solid rgba(212, 175, 55, 0.35);
  color: var(--text);
}
.cj-help-bubble a.cj-help-link {
  color: var(--gold);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.cj-help-bubble a.cj-help-link:hover {
  color: #ffe08a;
}
.cj-help-bubble strong {
  color: inherit;
  font-weight: 600;
}
.cj-help-msg-bot .cj-help-bubble {
  background: rgba(12, 22, 40, 0.9);
  border: 1px solid rgba(147, 161, 189, 0.22);
  color: var(--text);
}
.cj-help-form {
  display: flex;
  gap: 0.45rem;
  padding: 0.65rem 0.75rem;
  border-top: 1px solid rgba(212, 175, 55, 0.22);
  background: rgba(8, 13, 28, 0.95);
}
.cj-help-form input {
  flex: 1 1 auto;
  min-width: 0;
  border-radius: 8px;
  border: 1px solid rgba(147, 161, 189, 0.28);
  background: rgba(1, 8, 21, 0.85);
  color: var(--text);
  padding: 0.45rem 0.55rem;
  font-size: 0.86rem;
}
.cj-help-form .btn {
  margin: 0;
  padding: 0.45rem 0.7rem;
  font-size: 0.82rem;
  white-space: nowrap;
}
body.cj-help-open .cj-help-fab {
  box-shadow: 0 0 0 2px rgba(212, 175, 55, 0.35), var(--glow-gold);
}
.cj-help-typing {
  display: inline-flex;
  align-items: center;
  gap: 0.28rem;
  min-height: 1.1rem;
  padding-top: 0.55rem;
  padding-bottom: 0.55rem;
}
.cj-help-typing span {
  width: 0.42rem;
  height: 0.42rem;
  border-radius: 50%;
  background: var(--gold);
  opacity: 0.35;
  animation: cj-help-dot 1s ease-in-out infinite;
}
.cj-help-typing span:nth-child(2) { animation-delay: 0.15s; }
.cj-help-typing span:nth-child(3) { animation-delay: 0.3s; }
@keyframes cj-help-dot {
  0%, 80%, 100% { opacity: 0.35; transform: translateY(0); }
  40% { opacity: 1; transform: translateY(-3px); }
}
@media (max-width: 480px) {
  .cj-help-panel {
    right: 0.5rem;
    bottom: 4.6rem;
    width: calc(100vw - 1rem);
  }
  .cj-help-fab {
    right: 0.65rem;
    bottom: 0.65rem;
  }
}

/* —— Rendimiento (BTC oro / USDT cian) —— */
.kpi-row-home {
  margin: 1rem 0 1.25rem;
  grid-template-columns: minmax(10.5rem, 16rem);
}
.bot-panel .perf-panel {
  margin: 1rem 0 1.25rem;
}
.bot-panel .perf-mode {
  flex-direction: row;
  flex-wrap: wrap;
  margin: 0 0 0.55rem;
}
.bot-panel .perf-mode-btn {
  width: auto;
  flex: 1 1 10rem;
}
.perf-mode {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  margin-top: 0.75rem;
}
.perf-mode-btn {
  min-height: 44px;
  width: 100%;
  padding: 0.45rem 0.7rem;
  border-radius: 10px;
  border: 1px solid rgba(212, 175, 55, 0.28);
  background: rgba(1, 8, 21, 0.45);
  color: var(--muted);
  font-family: inherit;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  cursor: pointer;
  text-align: center;
}
.perf-mode-btn:hover {
  color: #fff;
  border-color: var(--color-gold);
}
.perf-mode-btn.is-active {
  color: #010815;
  background: linear-gradient(135deg, var(--color-gold), var(--gold-2));
  border-color: transparent;
  box-shadow: var(--glow-gold);
}
.perf-panel {
  border: 1px solid rgba(212, 175, 55, 0.28);
  border-radius: 12px;
  padding: 0.75rem 0.85rem 0.65rem;
  background: rgba(1, 8, 21, 0.45);
  min-width: 0;
}
.perf-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem 0.75rem;
  margin-bottom: 0.55rem;
}
.perf-head h2 {
  margin: 0;
  font-size: clamp(0.95rem, 1.2vw + 0.7rem, 1.1rem);
  color: var(--gold-2);
}
.perf-ranges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  max-width: 100%;
  padding-bottom: 0.1rem;
}
.perf-range {
  flex: 0 0 auto;
  min-height: 44px;
  min-width: 44px;
  padding: 0.35rem 0.7rem;
  border-radius: 999px;
  border: 1px solid rgba(212, 175, 55, 0.28);
  background: rgba(1, 8, 21, 0.45);
  color: var(--muted);
  font-family: inherit;
  font-size: 0.78rem;
  font-weight: 650;
  cursor: pointer;
}
.perf-range:hover {
  color: #fff;
  border-color: var(--color-gold);
}
.perf-range.is-active {
  color: #010815;
  background: linear-gradient(135deg, var(--color-gold), var(--gold-2));
  border-color: transparent;
  box-shadow: var(--glow-gold);
}
.perf-chart-wrap {
  position: relative;
  width: 100%;
}
.perf-chart-box {
  position: relative;
  width: 100%;
  height: 280px;
  min-height: 280px;
  border-radius: 10px;
  overflow: hidden;
  background: linear-gradient(165deg, #010815 0%, #061428 55%, #0a192f 100%);
}
.perf-tooltip {
  position: absolute;
  top: 10px;
  left: 12px;
  z-index: 8;
  transition: top 0.08s ease, left 0.08s ease;
  min-width: 9.5rem;
  max-width: min(92%, 16rem);
  padding: 0.45rem 0.65rem;
  border-radius: 10px;
  border: 1px solid rgba(212, 175, 55, 0.35);
  background: rgba(8, 13, 28, 0.96);
  color: var(--text);
  font-size: 0.78rem;
  line-height: 1.4;
  pointer-events: none;
  box-shadow: var(--glow-gold);
  backdrop-filter: blur(6px);
}
.perf-tip-date {
  font-weight: 650;
  color: var(--gold-2);
  margin-bottom: 0.25rem;
}
.perf-tip-row {
  display: flex;
  justify-content: space-between;
  gap: 0.85rem;
}
.perf-tip-btc { color: var(--color-gold); }
.perf-tip-usdt { color: var(--color-usdt); }
.perf-tip-in { color: var(--gold-2); font-weight: 650; }
.perf-tip-out { color: #e23b4a; font-weight: 650; }
.perf-empty { margin: 0.35rem 0 0; }
.perf-legend {
  display: flex;
  gap: 1rem;
  margin-top: 0.45rem;
  font-size: 0.78rem;
  font-weight: 650;
}
.perf-leg::before {
  content: "";
  display: inline-block;
  width: 0.7rem;
  height: 0.2rem;
  margin-right: 0.35rem;
  border-radius: 99px;
  vertical-align: middle;
}
.perf-leg-btc { color: var(--color-gold); }
.perf-leg-btc::before { background: var(--color-gold); box-shadow: var(--glow-gold); }
.perf-leg-usdt { color: var(--color-usdt); }
.perf-leg-usdt::before { background: var(--color-usdt); box-shadow: var(--glow-cyan); }

/* —— Menú hamburguesa (drawer) —— */
.nav-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  min-width: 44px;
  min-height: 44px;
  padding: 0;
  border-radius: 10px;
  border: 1px solid rgba(212, 175, 55, 0.35);
  background: rgba(1, 8, 21, 0.45);
  color: var(--gold-2);
  cursor: pointer;
}
.nav-toggle-bars {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 18px;
}
.nav-toggle-bars span {
  display: block;
  height: 2px;
  width: 100%;
  background: var(--color-gold);
  border-radius: 99px;
  transition: transform 0.18s ease, opacity 0.18s ease;
}
body.nav-open .nav-toggle-bars span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
body.nav-open .nav-toggle-bars span:nth-child(2) {
  opacity: 0;
}
body.nav-open .nav-toggle-bars span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}
.nav-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 90;
  background: rgba(1, 8, 21, 0.55);
}

@media (max-width: 820px) {
  .top {
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: center;
    z-index: 100;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    overflow: visible;
  }
  .top-right {
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    gap: 0.4rem;
    margin-left: auto;
    flex: 0 0 auto;
  }
  .lang-switch {
    flex: 0 0 auto;
    max-width: none;
    overflow: visible;
    padding: 0;
    border-radius: 12px;
  }
  .lang-now { display: inline-flex; }
  .lang-switch-menu {
    display: none;
    position: absolute;
    top: calc(100% + 0.35rem);
    right: 0;
    z-index: 230;
    flex-direction: column;
    gap: 0.15rem;
    padding: 0.35rem;
    border-radius: 12px;
    border: 1px solid var(--panel-border);
    background: rgba(8, 13, 28, 0.98);
    box-shadow: var(--glow-gold);
  }
  .lang-switch.is-open .lang-switch-menu {
    display: flex;
  }
  .lang-switch-menu button {
    min-width: 44px;
    min-height: 44px;
    justify-content: center;
  }
  .nav-toggle {
    display: inline-flex;
    position: relative;
    z-index: 220;
    touch-action: manipulation;
  }
  .nav-backdrop.is-on {
    display: block;
  }
  .nav {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: min(18.5rem, 86vw);
    height: 100vh;
    height: 100dvh;
    z-index: 210;
    display: flex;
    flex-direction: column;
    flex-wrap: nowrap;
    align-items: stretch;
    gap: 0.35rem;
    padding: 4.5rem 1rem max(1.5rem, env(safe-area-inset-bottom));
    margin: 0;
    background: rgba(8, 13, 28, 0.98);
    border-left: 1px solid var(--panel-border);
    box-shadow: var(--glow-gold);
    transform: translateX(110%);
    transition: transform 0.22s ease;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    grid-template-columns: none;
    pointer-events: auto;
  }
  .nav.is-open { transform: translateX(0); }
  .nav a, .nav-dd-btn {
    min-height: 44px;
    display: flex;
    align-items: center;
    width: 100%;
    text-align: left;
    padding: 0.65rem 0.75rem;
    font-size: 0.95rem;
    border: 1px solid rgba(212, 175, 55, 0.25);
    touch-action: manipulation;
  }
  .nav > a.nav-cta,
  .nav > .nav-dd > .nav-dd-btn.nav-cta {
    min-height: 44px;
  }
  .nav-dd { width: 100%; }
  .nav-dd-menu {
    position: static;
    margin-top: 0.35rem;
    box-shadow: none;
  }
  h1,
  .title-gold,
  h2.title-gold { font-size: clamp(1.15rem, 4vw, 1.45rem); }
  .home-overview { grid-template-columns: 1fr; }
  .perf-chart-box {
    height: 220px;
    min-height: 220px;
  }
  .perf-ranges { flex-wrap: wrap; }
  .tf-switch {
    width: 100%;
    flex-wrap: wrap;
  }
  .tf-btn, .chart-draw-tools .draw-btn {
    min-height: 44px;
    min-width: 44px;
    touch-action: manipulation;
  }
  .charts-toolbar-right,
  .charts-family,
  .charts-family select {
    width: 100%;
    max-width: 100%;
    min-width: 0;
  }
  .chart-head {
    flex-wrap: wrap;
    gap: 0.45rem;
  }
  .chart-tv { margin-left: 0; }
  .chart-draw-tools {
    margin-left: 0;
    width: 100%;
  }
  .field-tip {
    width: 2rem;
    height: 2rem;
    min-width: 2rem;
    min-height: 2rem;
    font-size: 0.85rem;
  }
  input, select, textarea,
  input[type="file"] {
    max-width: 100%;
    font-size: 16px;
  }
  .btn, .perf-range, .perf-mode-btn {
    touch-action: manipulation;
  }
  .btn.primary,
  .config-form .btn.primary,
  .wallet-actions .btn {
    width: 100%;
  }
  .admin-form .actions,
  .broadcast-form .actions {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
  }
}

@media (max-width: 720px) {
  .table-as-cards table.table thead {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
  }
  .table-as-cards table.table,
  .table-as-cards table.table tbody,
  .table-as-cards table.table tr,
  .table-as-cards table.table td {
    display: block;
    width: 100%;
  }
  .table-as-cards table.table tr {
    margin-bottom: 0.75rem;
    padding: 0.55rem 0.7rem;
    border: 1px solid rgba(212, 175, 55, 0.28);
    border-radius: 12px;
    background: rgba(1, 8, 21, 0.45);
  }
  .table-as-cards table.table td {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 0.75rem;
    white-space: normal;
    padding: 0.35rem 0;
    border: 0;
    font-size: 0.88rem;
  }
  .table-as-cards table.table td::before {
    content: attr(data-label);
    color: var(--muted);
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    flex: 0 0 auto;
  }
  .wrap { padding: 0.75rem 0.85rem 2.5rem; }
  .table-as-cards table.table td.user-actions,
  .table-as-cards table.table td:last-child {
    flex-wrap: wrap;
    justify-content: flex-end;
    align-items: center;
  }
}

.broadcast-preview {
  display: block;
  margin: 0.55rem 0 0;
  max-width: min(100%, 22rem);
  max-height: 180px;
  object-fit: contain;
  border-radius: 10px;
  border: 1px solid var(--panel-border);
  background: rgba(1, 8, 21, 0.45);
}
.broadcast-preview[hidden] { display: none; }

.cj-news-card { width: min(100%, 28rem); }
.cj-news-list {
  margin: 0.55rem 0 1rem;
  padding-left: 1.15rem;
  color: var(--text);
  line-height: 1.45;
}
.cj-news-list li { margin: 0.45rem 0; }

.doc-section blockquote {
  margin: 0.65rem 0 0.15rem;
  padding: 0.7rem 0.9rem;
  border-left: 4px solid var(--gold, #d4af37);
  background: rgba(212, 175, 55, 0.08);
  border-radius: 0 10px 10px 0;
}
.doc-section blockquote p { margin: 0; }
.doc-formula {
  margin: 0.5rem 0 0.75rem;
  padding: 0.75rem 0.9rem;
  font-family: "IBM Plex Mono", "Consolas", ui-monospace, monospace;
  font-size: 0.82rem;
  line-height: 1.45;
  color: #00f2fe;
  background: rgba(0, 242, 254, 0.08);
  border: 1px solid rgba(0, 242, 254, 0.35);
  border-radius: 8px;
  white-space: pre-wrap;
  overflow-x: auto;
}
.table-compact { font-size: 0.88em; }
