/* ==========================================================
   AXIOM — Premium UI layer
   Loaded last. Visual-only overrides: colors, depth, radius,
   typography and motion. No layout/function changes.
   ========================================================== */
:root {
  --mint: #19e3a8;
  --mint-2: #0fc792;
  --mint-glow: rgba(25, 227, 168, 0.35);
  --ink: #05070c;
  --panel: rgba(13, 17, 25, 0.72);
  --panel-solid: #0b0f16;
  --line: rgba(255, 255, 255, 0.07);
  --line-strong: rgba(255, 255, 255, 0.12);
  --grad-cta: linear-gradient(135deg, #2af5b8 0%, #12c995 55%, #0aa57c 100%);
  --grad-live: linear-gradient(135deg, #ff3b57, #e0115f);
  --shadow-cta: 0 10px 30px -8px rgba(25, 227, 168, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.35);
  --shadow-card: 0 30px 80px -20px rgba(0, 0, 0, 0.9), 0 0 0 1px rgba(255, 255, 255, 0.06);
}

html,
body {
  background:
    radial-gradient(1200px 600px at 85% -10%, rgba(25, 227, 168, 0.07), transparent 60%),
    radial-gradient(900px 500px at -10% 110%, rgba(80, 110, 255, 0.06), transparent 60%),
    var(--ink);
  font-feature-settings: "cv11", "ss01", "tnum";
  -webkit-font-smoothing: antialiased;
}

/* ---------- Nav ---------- */
.ax-nav {
  background: rgba(6, 9, 14, 0.78) !important;
  backdrop-filter: saturate(160%) blur(14px);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid var(--line) !important;
}

.ax-brand b {
  letter-spacing: 0.04em;
}

.ax-brand em {
  background: var(--grad-cta);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent !important;
}

.ax-links a {
  transition: color .2s ease;
}

.ax-links a:hover {
  color: #fff;
}

.ax-nav-search {
  border: 1px solid var(--line-strong) !important;
  background: rgba(255, 255, 255, 0.03) !important;
  transition: border-color .2s ease, box-shadow .2s ease;
}

.ax-nav-search:focus-within {
  border-color: rgba(25, 227, 168, 0.5) !important;
  box-shadow: 0 0 0 3px rgba(25, 227, 168, 0.12);
}

.ax-deposit {
  background: var(--grad-cta) !important;
  color: #03140d !important;
  box-shadow: var(--shadow-cta);
  font-weight: 800 !important;
}

/* ---------- Token strip ---------- */
.ax-token {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.025), transparent) !important;
  border-bottom: 1px solid var(--line) !important;
}

.ax-ident img {
  box-shadow: 0 0 0 2px rgba(25, 227, 168, 0.35), 0 6px 18px rgba(0, 0, 0, 0.6);
}

.ax-ratio {
  border-radius: 999px;
  overflow: hidden;
}

/* ---------- Panels ---------- */
.ax-right,
.ax-tools,
.ax-trades,
.ax-activity,
.ax-chart-head {
  border-color: var(--line) !important;
}

.ax-trade,
.ax-info,
.ax-banner-wrap,
.ax-pnl {
  border-radius: 14px;
}

.ax-trade {
  background: linear-gradient(180deg, rgba(25, 227, 168, 0.05), rgba(255, 255, 255, 0.01)) !important;
  border: 1px solid var(--line) !important;
}

.ax-presets button,
.ax-otype button,
.ax-tabs button,
.ax-chart-head .tf button {
  transition: background .2s ease, color .2s ease;
}

/* ---------- Primary CTAs ---------- */
.ax-cta,
.ax-join,
#joinLiveSession,
.dev-ended-join {
  background: var(--grad-cta) !important;
  color: #03140d !important;
  box-shadow: var(--shadow-cta);
  border: 0 !important;
  transition: transform .18s ease, box-shadow .18s ease, filter .18s ease;
}

.ax-cta:hover,
.ax-join:hover,
#joinLiveSession:hover,
.dev-ended-join:hover {
  transform: translateY(-1px);
  filter: brightness(1.06);
  box-shadow: 0 14px 36px -8px rgba(25, 227, 168, 0.7), inset 0 1px 0 rgba(255, 255, 255, 0.4);
}

.ax-join,
#joinLiveSession {
  position: relative;
  overflow: hidden;
}

.ax-join::after,
#joinLiveSession::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: -60%;
  width: 40%;
  background: linear-gradient(100deg, transparent, rgba(255, 255, 255, 0.45), transparent);
  animation: ax-shine 3.2s ease-in-out infinite;
  pointer-events: none;
}

@keyframes ax-shine {

  0%,
  55% {
    left: -60%;
  }

  100% {
    left: 130%;
  }
}

/* ---------- Stream tiles ---------- */
.stream-tile {
  border-radius: 12px !important;
  box-shadow: 0 0 0 1px var(--line), 0 10px 30px -12px rgba(0, 0, 0, 0.8);
}

.ax-live-pill .live,
.pop-live {
  background: var(--grad-live) !important;
  box-shadow: 0 0 14px rgba(255, 59, 87, 0.55);
  animation: ax-pulse 1.8s ease-in-out infinite;
}

@keyframes ax-pulse {
  50% {
    box-shadow: 0 0 4px rgba(255, 59, 87, 0.25);
  }
}

/* Home page: images stay lightly blurred — never revealed */
body.home-blur .stream-tile>img,
body.home-blur .stream-tile>video,
body.home-blur .stream-tile .dev-thumb,
body.home-blur .stream-tile .dev-video {
  filter: blur(4px) brightness(0.82) saturate(1.05) !important;
  transform: scale(1.06) !important;
}

body.home-blur .stream-tile.is-connecting>img:not(.holder-gif),
body.home-blur .stream-tile.is-buffering>img:not(.holder-gif) {
  filter: blur(5px) brightness(0.62) !important;
}

/* ---------- Popup ---------- */
.popup-dim {
  background: radial-gradient(ellipse at center, rgba(4, 8, 14, 0.55), rgba(0, 0, 0, 0.82)) !important;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.popup-card {
  background:
    radial-gradient(500px 200px at 50% -40px, rgba(25, 227, 168, 0.14), transparent 70%),
    linear-gradient(180deg, #0e131c, #090c12) !important;
  border: 1px solid var(--line-strong) !important;
  border-radius: 20px !important;
  box-shadow: var(--shadow-card) !important;
  animation: ax-pop-in .35s cubic-bezier(.2, .9, .3, 1.2);
}

@keyframes ax-pop-in {
  from {
    opacity: 0;
    transform: translateY(12px) scale(.97);
  }
}

.popup-card h2 {
  font-size: 24px !important;
  background: linear-gradient(180deg, #fff, #b9c3cf);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent !important;
}

.popup-chat {
  background: rgba(0, 0, 0, 0.35) !important;
  border-color: var(--line) !important;
  border-radius: 12px !important;
}

.pop-stats {
  border-color: var(--line) !important;
}

#joinLiveSession {
  height: 48px !important;
  border-radius: 12px !important;
  font-size: 15px;
}

#goToAxiom {
  border-radius: 12px !important;
  border-color: rgba(25, 227, 168, 0.4) !important;
  background: rgba(25, 227, 168, 0.06) !important;
  transition: background .2s ease;
}

#goToAxiom:hover {
  background: rgba(25, 227, 168, 0.12) !important;
}

#closePopup {
  border-radius: 8px;
  transition: background .2s ease, color .2s ease;
}

#closePopup:hover {
  background: rgba(255, 255, 255, 0.06);
  color: #fff;
}

/* ---------- Network chooser (Join live) ---------- */
.ax-chooser {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: none;
  align-items: center;
  justify-content: center;
}

.ax-chooser.is-open {
  display: flex;
}

.ax-chooser-dim {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.ax-chooser-card {
  position: relative;
  z-index: 1;
  width: min(380px, calc(100vw - 24px));
  padding: 22px 20px 18px;
  border-radius: 20px;
  background:
    radial-gradient(400px 180px at 50% -30px, rgba(25, 227, 168, 0.16), transparent 70%),
    linear-gradient(180deg, #0f141d, #090c12);
  border: 1px solid var(--line-strong);
  box-shadow: var(--shadow-card);
  color: #f3f5f7;
  animation: ax-pop-in .3s cubic-bezier(.2, .9, .3, 1.2);
}

.ax-chooser-x {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  border: 0;
  background: none;
  color: #9aa3ae;
  font-size: 22px;
  cursor: pointer;
}

.ax-chooser-x:hover {
  background: rgba(255, 255, 255, 0.06);
  color: #fff;
}

.ax-chooser-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--mint);
}

.ax-chooser-tag i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #ff3b57;
  box-shadow: 0 0 10px #ff3b57;
  animation: ax-pulse 1.6s infinite;
}

.ax-chooser-card h3 {
  margin-top: 8px;
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.ax-chooser-card p {
  margin-top: 4px;
  font-size: 13px;
  color: #9aa3ae;
}

.ax-chooser-list {
  display: grid;
  gap: 10px;
  margin-top: 18px;
}

.ax-chooser-list button {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 14px;
  min-height: 60px;
  border-radius: 14px;
  cursor: pointer;
  text-align: left;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--line-strong);
  color: #fff;
  transition: border-color .2s ease, background .2s ease, transform .15s ease;
}

.ax-chooser-list button:hover {
  transform: translateY(-1px);
  background: rgba(255, 255, 255, 0.06);
}

.ax-chooser-list .connect-btn:hover {
  border-color: rgba(98, 126, 234, 0.7);
}

.ax-chooser-list .interact-button:hover,
.ax-chooser-list .ax-sol-chooser-btn:hover {
  border-color: rgba(153, 69, 255, 0.7);
}

.ax-chooser-ico {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
}

.ax-chooser-ico svg {
  width: 22px;
  height: 22px;
}

.connect-btn .ax-chooser-ico {
  background: linear-gradient(135deg, #627eea, #3b4fb8);
}

.interact-button .ax-chooser-ico,
.ax-sol-chooser-btn .ax-chooser-ico {
  background: linear-gradient(135deg, #14f195, #9945ff);
}

.ax-chooser-list b {
  display: block;
  font-size: 15px;
  font-weight: 700;
}

.ax-chooser-list small {
  display: block;
  font-size: 12px;
  color: #9aa3ae;
  margin-top: 2px;
}

.ax-chooser-list .arr {
  margin-left: auto;
  color: #6b7380;
  font-size: 18px;
}

.ax-chooser-foot {
  margin-top: 14px;
  text-align: center;
  font-size: 11px;
  color: #6b7280;
}