:root {
  --bg: #030508;
  --panel: #070b10;
  --border: #121c26;
  --inner-bg: #04070b;
  --cyan: #22e5ff;
  --red: #ff4d6d;
  --text-main: #ffffff;
  --text-sub: #7a8f9e;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --mono: 'SFMono-Regular', Consolas, monospace;
}

* { box-sizing: border-box; margin: 0; padding: 0; -webkit-tap-highlight-color: transparent; }

body {
  background-color: var(--bg);
  color: var(--text-main);
  font-family: var(--sans);
  overflow-x: hidden;
  min-height: 100vh;
}

/* --- PAGES & EXIT SCREEN --- */
.page { display: none; min-height: 100vh; }
.page.active { display: block; animation: fadeIn 0.4s ease-out; }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

#exitScreen {
  position: fixed; inset: 0; z-index: 10000; display: none;
  align-items: center; justify-content: center; flex-direction: column; gap: 20px;
  background: var(--bg); text-align: center;
}
#exitScreen.show { display: flex; }
#exitScreen h2 { font-size: 28px; color: var(--cyan); letter-spacing: 0.1em; font-family: var(--mono); }
#exitScreen p { color: var(--text-sub); font-size: 12px; letter-spacing: 0.1em; font-family: var(--mono); }

/* --- RIPPLE EFFECT --- */
#bubbles { position: fixed; inset: 0; pointer-events: none; z-index: 9999; overflow: hidden; }
.bubble {
  position: absolute; border-radius: 50%;
  border: 1px solid rgba(34, 229, 255, 0.7);
  box-shadow: 0 0 12px rgba(34, 229, 255, 0.5), inset 0 0 8px rgba(34, 229, 255, 0.3);
  background: radial-gradient(circle at 30% 30%, rgba(34, 229, 255, 0.2), transparent 60%);
  transform: translate(-50%, -50%) scale(0);
  animation: bubblePop 0.8s cubic-bezier(0.2, 0.7, 0.3, 1) forwards;
}
@keyframes bubblePop {
  0% { transform: translate(-50%, -50%) scale(0); opacity: 0.9; }
  60% { opacity: 0.5; }
  100% { transform: translate(-50%, -50%) scale(1); opacity: 0; }
}

/* --- LOGIN PAGE --- */
#loginPage { display: none; align-items: center; justify-content: center; padding: 20px; }
#loginPage.active { display: flex; }
.login-box {
  background: var(--panel); border: 1px solid var(--border); border-radius: 16px;
  padding: 40px 30px; width: 100%; max-width: 380px; box-shadow: 0 0 40px rgba(0,0,0,0.5);
}
.login-box h2 { font-size: 20px; letter-spacing: 0.1em; margin-bottom: 30px; text-align: center; }
.input-group { margin-bottom: 20px; }
.input-group label { display: block; font-size: 10px; color: var(--text-sub); letter-spacing: 0.15em; margin-bottom: 8px; font-family: var(--mono); }
.input-group input {
  width: 100%; background: var(--inner-bg); border: 1px solid var(--border);
  color: var(--text-main); padding: 12px; font-family: var(--mono); font-size: 13px;
  border-radius: 6px; outline: none; transition: 0.2s;
}
.input-group input:focus { border-color: var(--cyan); box-shadow: 0 0 10px rgba(34, 229, 255, 0.2); }
.btn-submit {
  width: 100%; background: rgba(34, 229, 255, 0.1); color: var(--cyan);
  border: 1px solid var(--cyan); padding: 12px; font-family: var(--mono);
  font-size: 12px; letter-spacing: 0.1em; border-radius: 6px; cursor: pointer;
  transition: 0.2s; margin-top: 10px;
}
.btn-submit:hover { background: rgba(34, 229, 255, 0.2); box-shadow: 0 0 15px rgba(34, 229, 255, 0.3); }
.btn-danger {
  background: rgba(255, 77, 109, 0.1); color: var(--red);
  border: 1px solid var(--red); padding: 10px 14px; font-family: var(--mono);
  font-size: 11px; letter-spacing: 0.1em; border-radius: 6px; cursor: pointer; transition: 0.2s;
}
.btn-danger:hover { background: rgba(255, 77, 109, 0.2); }

/* --- TOP NAVIGATION --- */
header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 20px 24px; background: var(--bg); position: sticky; top: 0; z-index: 50;
}
.logo-container { display: flex; align-items: center; gap: 12px; }
.logo-link { text-decoration: none; color: inherit; }

.logo-icon { width: 36px; height: 36px; display: flex; align-items: center; justify-content: center; }
.logo-svg { width: 100%; height: 100%; overflow: visible; }
.trace-pulse { animation: trace-glow 1.5s ease-in-out infinite alternate; }
@keyframes trace-glow {
  0% { opacity: 0.4; filter: drop-shadow(0 0 0px transparent); }
  100% { opacity: 1; filter: drop-shadow(0 0 6px var(--cyan)); }
}

.logo-text { font-size: 18px; font-weight: 600; letter-spacing: 0.15em; text-transform: uppercase; }
.logo-text span { color: var(--cyan); }

.right-nav { display: flex; align-items: center; gap: 16px; }
.menu-btn { width: 26px; height: 18px; display: flex; flex-direction: column; justify-content: space-between; cursor: pointer; }
.menu-btn span { display: block; height: 2px; background: var(--text-main); border-radius: 2px; }
.btn-exit {
  background: transparent; border: 1px solid var(--red); color: var(--red);
  padding: 6px 10px; font-family: var(--mono); font-size: 10px;
  border-radius: 4px; cursor: pointer; transition: 0.2s;
}
.btn-exit:hover { background: rgba(255, 77, 109, 0.1); }

/* --- SIDE DRAWER NAV --- */
.drawer-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,0.6); backdrop-filter: blur(2px);
  z-index: 90; opacity: 0; pointer-events: none; transition: opacity 0.25s;
}
.drawer-overlay.show { opacity: 1; pointer-events: auto; }
.drawer {
  position: fixed; top: 0; right: -280px; width: 280px; height: 100vh;
  background: var(--panel); border-left: 1px solid var(--border);
  z-index: 95; transition: right 0.3s ease; display: flex; flex-direction: column;
  padding: 28px 0; font-family: var(--mono);
}
.drawer.show { right: 0; }
.drawer .drawer-head {
  display: flex; justify-content: space-between; align-items: center;
  padding: 0 24px 20px; border-bottom: 1px solid var(--border);
}
.drawer .drawer-head span { font-size: 10px; letter-spacing: 0.2em; color: var(--text-sub); }
.drawer-close { color: var(--text-sub); cursor: pointer; font-size: 18px; background: none; border: none; }
.drawer nav { display: flex; flex-direction: column; gap: 2px; padding: 16px 12px; flex: 1; }
.drawer a {
  color: var(--text-sub); text-decoration: none; font-size: 13px; letter-spacing: 0.1em;
  padding: 12px 14px; border-radius: 8px; transition: 0.2s; display: flex; align-items: center; gap: 10px;
}
.drawer a:hover { color: var(--text-main); background: rgba(34, 229, 255, 0.06); }
.drawer a.active { color: var(--cyan); background: rgba(34, 229, 255, 0.1); }
.drawer-foot {
  padding: 16px 24px 0; border-top: 1px solid var(--border);
  font-size: 10px; letter-spacing: 0.1em; color: var(--text-sub); line-height: 1.8;
}
.drawer-foot .val { color: var(--cyan); }

/* --- SEARCH BAR --- */
.search-container { display: flex; gap: 10px; margin-bottom: 24px; }
.search-container input {
  flex: 1; min-width: 0; background: var(--panel); border: 1px solid var(--border);
  color: var(--text-main); padding: 12px 16px; font-family: var(--mono); font-size: 13px;
  border-radius: 8px; outline: none; transition: 0.2s;
}
.search-container select {
  background: var(--panel); border: 1px solid var(--border); color: var(--cyan);
  padding: 12px 8px; font-family: var(--mono); font-size: 11px; letter-spacing: 0.08em;
  border-radius: 8px; outline: none; cursor: pointer; transition: 0.2s;
}
.search-container select:focus { border-color: var(--cyan); }
.search-container select option { background: var(--panel); color: var(--text-main); }
.search-container input:focus { border-color: var(--cyan); box-shadow: 0 0 10px rgba(34, 229, 255, 0.2); }
.search-container button {
  background: rgba(34, 229, 255, 0.1); color: var(--cyan); border: 1px solid var(--cyan);
  padding: 0 20px; font-family: var(--mono); font-size: 12px; border-radius: 8px; cursor: pointer; transition: 0.2s;
}
.search-container button:hover { background: rgba(34, 229, 255, 0.2); box-shadow: 0 0 15px rgba(34, 229, 255, 0.3); }

/* ===== mobile devices ===== */
@media (max-width: 640px) {
  .search-container { flex-wrap: wrap; gap: 8px; }
  .search-container input { order: -1; flex: 1 1 100%; font-size: 16px; } /* 16px = no iOS auto-zoom */
  .search-container select { flex: 1; font-size: 12px; }
  .search-container button { flex: 1; padding: 12px 10px; }
}

/* --- MAIN LAYOUT --- */
.container { padding: 20px; max-width: 600px; margin: 0 auto; display: flex; flex-direction: column; gap: 24px; padding-bottom: 60px; }
.outer-card {
  background: var(--panel); border: 1px solid var(--border); border-radius: 20px;
  padding: 24px; position: relative; overflow: hidden;
}
.card-icon { margin-bottom: 16px; }
.card-icon svg { width: 28px; height: 28px; fill: none; stroke: var(--cyan); stroke-width: 2; filter: drop-shadow(0 0 4px rgba(34,229,255,0.4)); }
.outer-card h2 { font-size: 20px; font-weight: 500; margin-bottom: 12px; letter-spacing: 0.02em; }
.outer-card p { font-size: 15px; color: var(--text-sub); line-height: 1.5; margin-bottom: 24px; }

.inner-box {
  background: var(--inner-bg); border: 1px solid #111a24; border-radius: 12px;
  padding: 20px; font-family: var(--mono);
}
.data-text { font-size: 11px; color: var(--text-sub); line-height: 1.6; letter-spacing: 0.05em; display: flex; flex-direction: column; gap: 4px; }
.data-text .val { color: var(--cyan); word-break: break-all; }
.data-text .val.red { color: var(--red); }

/* --- 1. LIVE SCANNING CHART --- */
.chart-header { display: flex; justify-content: space-between; align-items: flex-start; font-size: 11px; letter-spacing: 0.15em; color: var(--text-sub); margin-bottom: 15px; }
.chart-header .right-text { display: flex; align-items: center; gap: 8px; color: var(--cyan); }
.dot { width: 6px; height: 6px; background: var(--cyan); border-radius: 50%; box-shadow: 0 0 8px var(--cyan); }

.canvas-container { position: relative; width: 100%; height: 100px; margin-bottom: 20px; }
canvas#liveChart { width: 100%; height: 100%; display: block; }

.chart-footer { display: flex; justify-content: space-between; font-size: 11px; letter-spacing: 0.05em; color: var(--text-sub); line-height: 1.8; }
.chart-footer .col { display: flex; flex-direction: column; gap: 4px; }

/* --- 2. ROTATING CIRCLE --- */
.flex-row { display: flex; align-items: center; gap: 20px; }
.rotating-circle {
  width: 70px; height: 70px; flex-shrink: 0; border: 1px dashed var(--cyan); border-radius: 50%;
  display: flex; align-items: center; justify-content: center; animation: spin 8s linear infinite;
}
.rotating-circle svg { width: 24px; height: 24px; fill: none; stroke: var(--cyan); stroke-width: 2; animation: spin-reverse 8s linear infinite; }
@keyframes spin { 100% { transform: rotate(360deg); } }
@keyframes spin-reverse { 100% { transform: rotate(-360deg); } }

/* --- 3. PULSING DOT GRID --- */
.dot-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; flex-shrink: 0; }
.dot-item { width: 8px; height: 8px; border-radius: 50%; background: #12202e; }
.dot-item.active { background: var(--cyan); animation: pulse 2s infinite alternate; box-shadow: 0 0 6px rgba(34,229,255,0.4); }
.dot-item.active:nth-child(1) { animation-delay: 0.0s; } .dot-item.active:nth-child(2) { animation-delay: 0.2s; }
.dot-item.active:nth-child(3) { animation-delay: 0.4s; } .dot-item.active:nth-child(4) { animation-delay: 0.6s; }
.dot-item.active:nth-child(5) { animation-delay: 0.8s; } .dot-item.active:nth-child(6) { animation-delay: 1.0s; }
.dot-item.active:nth-child(7) { animation-delay: 1.2s; } .dot-item.active:nth-child(8) { animation-delay: 1.4s; }
@keyframes pulse { 0% { opacity: 0.3; transform: scale(0.8); } 100% { opacity: 1; transform: scale(1.2); } }

/* --- 4. TYPING TERMINAL --- */
.terminal-text { font-size: 12px; line-height: 1.6; color: var(--text-sub); white-space: pre-wrap; min-height: 120px; max-height: 200px; overflow-y: auto; }
.terminal-text span.cmd { color: var(--cyan); }
.terminal-text span.time { color: var(--text-main); }
.terminal-text span.green { color: var(--cyan); }
.terminal-text span.red { color: var(--red); }
.terminal-text span.breach { color: #ffb84d; }
.cursor { display: inline-block; width: 6px; height: 14px; background: var(--cyan); animation: blink 1s step-end infinite; vertical-align: middle; margin-left: 4px; }
@keyframes blink { 50% { opacity: 0; } }

/* --- 5. RING GAUGE --- */
.ring-gauge-container { position: relative; width: 70px; height: 70px; flex-shrink: 0; display: flex; align-items: center; justify-content: center; }
.ring-gauge-svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.ring-bg { fill: none; stroke: #12202e; stroke-width: 4; }
.ring-progress { fill: none; stroke: var(--cyan); stroke-width: 4; stroke-linecap: round; stroke-dasharray: 220; stroke-dashoffset: 220; transition: stroke-dashoffset 1.5s ease-out, stroke 0.3s; filter: drop-shadow(0 0 4px rgba(34,229,255,0.6)); }
.ring-progress.danger { stroke: var(--red); filter: drop-shadow(0 0 4px rgba(255,77,109,0.6)); }
.ring-text { position: absolute; font-family: var(--mono); font-size: 14px; color: var(--text-main); font-weight: bold; }

/* --- HISTORY TABLE --- */
.history-tools { display: flex; gap: 10px; margin-bottom: 16px; flex-wrap: wrap; }
.history-tools .btn-submit, .history-tools .btn-danger { width: auto; }
.hx-table { width: 100%; border-collapse: collapse; font-family: var(--mono); font-size: 11px; }
.hx-table th {
  text-align: left; color: var(--text-sub); font-weight: 400; letter-spacing: 0.1em;
  padding: 10px 8px; border-bottom: 1px solid var(--border); font-size: 10px;
}
.hx-table td { padding: 12px 8px; border-bottom: 1px solid #0c141d; color: var(--text-sku, var(--text-main)); }
.hx-table td.val { color: var(--cyan); }
.hx-table td.red { color: var(--red); }
.hx-table tr { cursor: pointer; transition: 0.15s; }
.hx-table tbody tr:hover { background: rgba(34, 229, 255, 0.04); }
.hx-detail { display: none; background: var(--inner-bg); font-size: 10px; color: var(--text-sub); }
.hx-detail td { color: var(--text-sub); padding: 10px 8px 16px; line-height: 1.9; }
.hx-detail .b { color: #ffb84d; }
.empty-state { font-family: var(--mono); font-size: 12px; color: var(--text-sub); padding: 30px 10px; text-align: center; letter-spacing: 0.1em; }

/* --- SETTINGS --- */
.setting-row { margin-bottom: 24px; }
.setting-row .desc { font-size: 13px; color: var(--text-sub); line-height: 1.6; margin-bottom: 14px; }
.status-pill {
  display: inline-block; font-family: var(--mono); font-size: 10px; letter-spacing: 0.1em;
  padding: 4px 10px; border-radius: 999px; border: 1px solid var(--border); color: var(--text-sub);
}
.status-pill.ok { color: var(--cyan); border-color: rgba(34,229,255,0.4); }
.status-pill.warn { color: #ffb84d; border-color: rgba(255,184,77,0.4); }

/* --- ABOUT --- */
.about-block { margin-bottom: 22px; }
.about-block h3 { font-size: 14px; letter-spacing: 0.08em; margin-bottom: 10px; color: var(--text-main); }
.about-block p { font-size: 14px; color: var(--text-sub); line-height: 1.65; margin: 0 0 10px; }
.about-block .kbd {
  font-family: var(--mono); font-size: 12px; color: var(--cyan);
  background: var(--inner-bg); border: 1px solid var(--border); border-radius: 6px; padding: 2px 8px;
}

/* --- FOOTER --- */
.site-foot {
  max-width: 600px; margin: 0 auto; padding: 0 20px 50px;
  font-family: var(--mono); font-size: 10px; letter-spacing: 0.1em; color: #4a5c68; line-height: 2;
  display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 10px;
}
.site-foot a { color: #5f7684; text-decoration: none; margin-left: 14px; }
.site-foot a:hover { color: var(--cyan); }

/* --- HUB PAGE (reseller landing) --- */
.hub-container { max-width: 720px; margin: 0 auto; padding: 10px 20px 60px; display: flex; flex-direction: column; gap: 28px; }

.hub-hero { text-align: center; padding: 40px 0 10px; }
.hub-hero h1 {
  font-size: 34px; font-weight: 600; letter-spacing: -0.5px; line-height: 1.2; margin-bottom: 14px;
  text-shadow: 0 0 30px rgba(34,229,255,0.15);
}
.hub-hero h1 .hl { color: var(--cyan); text-shadow: 0 0 20px rgba(34,229,255,0.5); }
.hub-hero p { font-size: 15px; color: var(--text-sub); max-width: 520px; margin: 0 auto; line-height: 1.6; }

.link-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; }
.link-card {
  background: var(--panel); border: 1px solid var(--border); border-radius: 16px;
  padding: 22px 18px; text-align: center; text-decoration: none; color: inherit;
  transition: all 0.3s; display: block; position: relative; overflow: hidden;
}
.link-card::before {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(circle at 50% -20%, rgba(34,229,255,0.08), transparent 60%);
  opacity: 0; transition: 0.3s;
}
.link-card:hover { border-color: rgba(34,229,255,0.35); transform: translateY(-4px); box-shadow: 0 16px 50px rgba(0,0,0,0.45), 0 0 24px rgba(34,229,255,0.08); }
.link-card:hover::before { opacity: 1; }
.link-card .icon svg { width: 30px; height: 30px; fill: none; stroke: var(--cyan); stroke-width: 1.6; filter: drop-shadow(0 0 6px rgba(34,229,255,0.4)); margin-bottom: 12px; }
.link-card .icon.gold svg { stroke: #ffb84d; filter: drop-shadow(0 0 6px rgba(255,184,77,0.4)); }
.link-card .icon.purple svg { stroke: #8b5cf6; filter: drop-shadow(0 0 6px rgba(139,92,246,0.4)); }
.link-card .icon.teal svg { stroke: #2a9d8f; filter: drop-shadow(0 0 6px rgba(42,157,143,0.4)); }
.link-card h3 { font-size: 14px; font-weight: 600; letter-spacing: 0.06em; margin-bottom: 6px; font-family: var(--mono); }
.link-card p.crumb { font-size: 12px; color: var(--text-sub); margin: 0; }
.link-card .arrow { display: inline-block; margin-top: 12px; font-size: 10px; letter-spacing: 0.2em; color: var(--cyan); font-family: var(--mono); opacity: 0; transition: 0.3s; }
.link-card:hover .arrow { opacity: 1; }

.stats-bar {
  display: flex; flex-wrap: wrap; justify-content: space-around; gap: 24px;
  background: var(--panel); border: 1px solid var(--border); border-radius: 24px;
  padding: 30px 26px;
}
.stat-item { text-align: center; min-width: 110px; }
.stat-number {
  font-size: 30px; font-weight: 700; display: flex; align-items: flex-start; justify-content: center;
  font-family: var(--mono); color: var(--text-main); line-height: 1;
  text-shadow: 0 0 20px rgba(34,229,255,0.25);
}
.stat-number .accent { color: var(--cyan); text-shadow: 0 0 16px rgba(34,229,255,0.6); }
.stat-label { font-size: 10px; color: var(--text-sub); margin-top: 8px; letter-spacing: 0.12em; font-family: var(--mono); }

.feature-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(270px, 1fr)); gap: 16px; }
.feature-card {
  background: var(--panel); border: 1px solid var(--border); border-radius: 16px;
  padding: 20px 18px; transition: all 0.3s;
}
.feature-card:hover { border-color: rgba(34,229,255,0.25); transform: translateY(-2px); }
.feature-row { display: flex; align-items: center; gap: 14px; margin-bottom: 10px; }
.feature-icon {
  width: 42px; height: 42px; border-radius: 12px; flex-shrink: 0;
  background: rgba(34,229,255,0.06); border: 1px solid rgba(34,229,255,0.12);
  display: flex; align-items: center; justify-content: center;
}
.feature-icon svg { width: 20px; height: 20px; fill: none; stroke: var(--cyan); stroke-width: 1.8; }
.feature-card h3 { font-size: 13px; font-weight: 600; letter-spacing: 0.06em; font-family: var(--mono); }
.feature-card p { font-size: 12.5px; color: var(--text-sub); line-height: 1.6; margin: 0; }

.hub-foot { text-align: center; font-family: var(--mono); font-size: 10px; letter-spacing: 0.1em; color: #4a5c68; line-height: 2.2; }
.hub-foot p.legal { font-size: 9px; color: #384854; }

/* ===== visible top navigation (desktop) ===== */
.main-nav { display: flex; gap: 4px; align-items: center; flex: 1; margin: 0 18px; min-width: 0; }
.main-nav a {
  font-family: var(--mono); font-size: 11px; letter-spacing: 0.12em; color: #8ba3af;
  text-decoration: none; padding: 7px 12px; border: 1px solid transparent;
  border-radius: 8px; white-space: nowrap; transition: 0.15s;
}
.main-nav a:hover { color: var(--cyan); border-color: var(--border); }
.main-nav a.active { color: var(--cyan); border-color: rgba(34,229,255,0.35); background: rgba(34,229,255,0.06); }
.main-nav a.cta { color: #04121a; background: var(--cyan); border-color: var(--cyan); }
.main-nav a.cta:hover { color: #04121a; filter: brightness(1.12); }
@media (max-width: 980px) { /* removed: .main-nav { display: none; } — new 3-item nav fits on mobile */ }

/* ===== hub organization ===== */
.grid-label {
  display: flex; align-items: center; gap: 12px; margin: 22px 0 2px;
  font-family: var(--mono); font-size: 11px; letter-spacing: 0.2em; color: #5f7684;
}
.grid-label::after { content: ""; flex: 1; height: 1px; background: var(--border); }
.link-card.primary { border-color: rgba(34,229,255,0.45); box-shadow: 0 0 28px rgba(34,229,255,0.10); }
.hero-cta { display: flex; gap: 12px; justify-content: center; margin-top: 20px; flex-wrap: wrap; }
.hero-cta .btn-submit { width: auto; padding: 13px 30px; text-decoration: none; font-size: 13px; }
.hero-cta .btn-ghost2 {
  width: auto; padding: 13px 26px; background: transparent; border: 1px solid var(--border);
  color: #8ba3af; border-radius: 10px; font-family: var(--mono); font-size: 12px;
  letter-spacing: 0.1em; text-decoration: none; transition: 0.2s;
}
.hero-cta .btn-ghost2:hover { color: var(--cyan); border-color: rgba(34,229,255,0.4); }


/* ===== MOBILE — pending order / buttons / wallet (2026-11-10) ===== */
@media (max-width: 640px) {
  html, body { overflow-x: hidden; }

  /* Stack button rows vertically, full-width */
  .btn-line {
    display: flex !important;
    flex-direction: column !important;
    gap: 10px !important;
  }
  .btn-line > button,
  .btn-line > .btn-mini,
  .btn-line > a {
    width: 100% !important;
    margin: 0 !important;
    padding: 14px 18px !important;
    font-size: 13px !important;
    box-sizing: border-box !important;
  }

  /* Touch-friendly button heights */
  .btn-mini, .btn-submit, button, .btn {
    min-height: 44px !important;
    font-size: 12px !important;
    padding: 12px 16px !important;
  }

  /* Wallet address: wraps cleanly, tap-to-select */
  .wallet-line {
    word-break: break-all !important;
    overflow-wrap: anywhere !important;
    font-size: 11px !important;
    line-height: 1.6 !important;
    padding: 12px !important;
    background: rgba(0,0,0,0.35) !important;
    border-radius: 8px !important;
    border: 1px solid var(--border, rgba(255,255,255,0.1)) !important;
    user-select: all !important;
    -webkit-user-select: all !important;
  }

  /* Amount row: stack number above COPY button */
  #amountLine {
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 10px !important;
    padding: 12px !important;
    background: rgba(0,0,0,0.25) !important;
    border-radius: 8px !important;
  }
  #amountLine [data-copy-amount] {
    width: 100% !important;
    margin: 0 !important;
    padding: 12px !important;
    min-height: 44px !important;
    font-size: 12px !important;
  }

  /* Inputs: full-width, 16px prevents iOS Safari auto-zoom */
  input, textarea, select {
    font-size: 16px !important;
    width: 100% !important;
    box-sizing: border-box !important;
    min-height: 44px !important;
    padding: 12px 14px !important;
  }
  .input-group { width: 100% !important; margin-bottom: 12px !important; }
  .input-group input, .input-group textarea { width: 100% !important; }

  /* Pending box: tighter padding */
  .pending-box { padding: 14px !important; }
  .pending-box .t { font-size: 11px !important; letter-spacing: 0.08em !important; }

  /* Nav: keep visible, allow slight scroll if needed */
  .main-nav {
    margin: 0 4px !important;
    gap: 2px !important;
    flex-wrap: nowrap !important;
    overflow-x: auto !important;
  }
  .main-nav a {
    font-size: 11px !important;
    padding: 8px 10px !important;
    white-space: nowrap !important;
  }

  /* Page container padding */
  .page, .container, .wrap, .inner { padding: 12px !important; box-sizing: border-box !important; }

  /* Tables scroll instead of overflow */
  table { display: block; overflow-x: auto; -webkit-overflow-scrolling: touch; }

  /* Long strings never overflow */
  code, .mono { word-break: break-all; overflow-wrap: anywhere; }

  img { max-width: 100%; height: auto; }

  .modal, .dialog, .popup {
    width: calc(100vw - 24px) !important;
    max-width: calc(100vw - 24px) !important;
    margin: 12px !important;
    box-sizing: border-box !important;
  }
}

/* Very small screens */
@media (max-width: 400px) {
  .main-nav a { font-size: 10px !important; padding: 6px 8px !important; }
  .btn-mini, button { font-size: 11px !important; padding: 10px 12px !important; }
  .pending-box { padding: 10px !important; }
  #amountLine { padding: 10px !important; }
}

/* Touch devices: bigger tap targets */
@media (hover: none) and (pointer: coarse) {
  a, button, .btn-mini, [data-copy-amount] { min-height: 40px; min-width: 40px; }
  .btn-mini { padding: 12px 18px !important; }
}

/* ===== HEADER + NAV mobile fix (2026-11-10 v3) ===== */
@media (max-width: 980px) {
  /* Header: wrap to two rows */
  header {
    flex-wrap: wrap !important;
    align-items: center !important;
    gap: 8px !important;
    padding: 10px 12px !important;
    box-sizing: border-box !important;
  }

  /* Hide hamburger — 3 nav items are enough */
  .menu-btn { display: none !important; }

  /* Row 1: logo on left, EXIT on right */
  .logo-link {
    flex: 1 1 auto !important;
    min-width: 0 !important;
  }
  .logo-text { font-size: 13px !important; }

  .btn-exit {
    flex-shrink: 0 !important;
    font-size: 11px !important;
    padding: 8px 12px !important;
    min-height: 36px !important;
  }

  /* Row 2: nav full-width, centered, spaced */
  .main-nav {
    flex: 1 1 100% !important;
    order: 99 !important;
    width: 100% !important;
    margin: 8px 0 0 0 !important;
    padding: 10px 0 0 0 !important;
    border-top: 1px solid rgba(255,255,255,0.08) !important;
    justify-content: center !important;
    gap: 6px !important;
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch !important;
  }

  .main-nav a {
    flex: 0 0 auto !important;
    font-size: 12px !important;
    padding: 8px 14px !important;
    min-height: 40px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    white-space: nowrap !important;
    box-sizing: border-box !important;
  }
}

/* Very small phones */
@media (max-width: 420px) {
  .logo-text { font-size: 12px !important; }
  .btn-exit { font-size: 10px !important; padding: 7px 10px !important; }
  .main-nav a { font-size: 11px !important; padding: 7px 11px !important; }
}


/* THEME POLISH v1 — softer panels, cleaner cards */
:root {
  --card-bg: rgba(10, 18, 26, 0.85);
  --card-border: rgba(34, 229, 255, 0.12);
  --card-shadow: 0 2px 12px rgba(0, 0, 0, 0.4);
}

.portal-card,
.pending-box,
.outer-card {
  background: var(--card-bg) !important;
  border: 1px solid var(--card-border) !important;
  border-radius: 12px !important;
  box-shadow: var(--card-shadow) !important;
}

.portal-card h2,
.pending-box .t {
  color: var(--cyan) !important;
  font-size: 14px !important;
  letter-spacing: 0.12em !important;
  margin-bottom: 14px !important;
}

.portal-card p.sub {
  color: var(--text-sub) !important;
  font-size: 12px !important;
  margin-bottom: 16px !important;
}

/* Stat cards: softer, uniform */
#dashboardBlock > div > div {
  background: var(--card-bg) !important;
  border: 1px solid var(--card-border) !important;
  border-radius: 10px !important;
  box-shadow: var(--card-shadow) !important;
}

/* Search results wrapper: match the card style */
#searchResults > div {
  background: var(--card-bg) !important;
  border: 1px solid var(--card-border) !important;
  box-shadow: var(--card-shadow) !important;
}

/* Buttons: consistent */
.btn-primary, .btn-mini {
  font-family: var(--mono) !important;
  letter-spacing: 0.08em !important;
  transition: all 0.15s ease !important;
}
.btn-primary:hover {
  filter: brightness(1.15) !important;
  box-shadow: 0 0 20px rgba(34, 229, 255, 0.25) !important;
}
.btn-mini:hover {
  background: rgba(34, 229, 255, 0.15) !important;
  color: var(--cyan) !important;
}

/* Field spacing */
.field { margin-bottom: 14px !important; }
.field label {
  display: block !important;
  font-size: 10px !important;
  color: var(--text-sub) !important;
  letter-spacing: 0.15em !important;
  margin-bottom: 6px !important;
  font-family: var(--mono) !important;
}

/* Input polish */
.portal-card input,
.portal-card select {
  width: 100% !important;
  box-sizing: border-box !important;
}

/* Kill harsh inline rgba(0,0,0,0.3/0.4) backgrounds */
[style*="rgba(0,0,0,0.3)"],
[style*="rgba(0,0,0,0.4)"],
[style*="rgba(0,0,0,0.5)"] {
  background: var(--card-bg) !important;
  border-color: var(--card-border) !important;
}

/* Nav consistency */
.main-nav a {
  color: var(--text-sub) !important;
  transition: color 0.15s !important;
}
.main-nav a:hover,
.main-nav a.active,
.main-nav a.cta {
  color: var(--cyan) !important;
}


/* FORM DARK THEME — force dark mode on all inputs/selects */
select,
input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
input[type="search"],
input[type="url"],
input[type="tel"],
textarea {
  background-color: #0a121a !important;
  background-image: none !important;
  color: #dbe7ec !important;
  border: 1px solid rgba(34, 229, 255, 0.2) !important;
  border-radius: 8px !important;
  padding: 12px 14px !important;
  font-family: var(--mono) !important;
  font-size: 14px !important;
  outline: none !important;
  box-sizing: border-box !important;
  width: 100% !important;
  -webkit-appearance: none !important;
  -moz-appearance: none !important;
  appearance: none !important;
}

/* Select needs a custom arrow since we killed the default one */
select {
  background-image: url("data:image/svg+xml;charset=US-ASCII,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%2322e5ff' d='M6 8L0 0h12z'/%3E%3C/svg%3E") !important;
  background-repeat: no-repeat !important;
  background-position: right 14px center !important;
  background-size: 10px 6px !important;
  padding-right: 38px !important;
  cursor: pointer !important;
}

select:hover,
input:hover,
textarea:hover {
  border-color: rgba(34, 229, 255, 0.4) !important;
}

select:focus,
input:focus,
textarea:focus {
  border-color: #22e5ff !important;
  box-shadow: 0 0 0 3px rgba(34, 229, 255, 0.1) !important;
}

select option {
  background-color: #0a121a !important;
  color: #dbe7ec !important;
  padding: 10px !important;
}

input::placeholder,
textarea::placeholder {
  color: #4a5c68 !important;
  opacity: 1 !important;
}

input[type="search"]::-webkit-search-decoration,
input[type="search"]::-webkit-search-cancel-button {
  -webkit-appearance: none !important;
}

/* Generic button baseline (dark theme) */
button {
  font-family: var(--mono) !important;
  cursor: pointer !important;
  background-color: rgba(34, 229, 255, 0.08) !important;
  color: #22e5ff !important;
  border: 1px solid rgba(34, 229, 255, 0.3) !important;
  border-radius: 8px !important;
  padding: 10px 16px !important;
  transition: all 0.15s ease !important;
}

button:hover:not(:disabled) {
  background-color: rgba(34, 229, 255, 0.15) !important;
  border-color: #22e5ff !important;
}

button:disabled {
  opacity: 0.5 !important;
  cursor: not-allowed !important;
}

/* Keep .btn-primary as-is (bright cyan) */
.btn-primary {
  background-color: #22e5ff !important;
  color: #04121a !important;
  border: 1px solid #22e5ff !important;
}

.btn-primary:hover:not(:disabled) {
  background-color: #3deaff !important;
  border-color: #3deaff !important;
}

/* Kill any white backgrounds from browser defaults */
input:not([type="checkbox"]):not([type="radio"]),
select,
textarea {
  -webkit-text-fill-color: #dbe7ec !important;
}

/* Autofill fix (Chrome yellow/white bg) */
input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus {
  -webkit-box-shadow: 0 0 0 1000px #0a121a inset !important;
  -webkit-text-fill-color: #dbe7ec !important;
  transition: background-color 5000s ease-in-out 0s !important;
}


/* CTA BUTTON FIX — make ACCOUNT button text visible on cyan bg */
.main-nav a.cta,
.main-nav a.cta:visited {
  color: #04121a !important;
  background: var(--cyan) !important;
  font-weight: 600 !important;
}

.main-nav a.cta:hover {
  color: #04121a !important;
  filter: brightness(1.15) !important;
}

.main-nav a.cta.active {
  color: #04121a !important;
  background: var(--cyan) !important;
}

/* Any other cta anywhere */
a.cta {
  color: #04121a !important;
}
a.cta:hover {
  color: #04121a !important;
}



/* logo text removed */
/* Optional: slight grunge text-shadow to match the logo */
.logo-text {
  text-shadow: 0 0 4px rgba(255,255,255,0.15) !important;
}


/* LOGO TEXT IMAGE */
.logo-text-img {
  height: 38px; /* Adjust this if you want it bigger/smaller */
  width: auto;
  display: block;
  margin-left: 12px;
  /* This magic line makes the black background invisible on dark themes! */
  mix-blend-mode: screen; 
}


/* NEON GLOW - At Your Fingertips */
.hl, 
.hero h1 span,
.hero h2 span,
.highlight {
  color: #22e5ff !important;
  /* 4 layers of shadows to create a massive neon bloom */
  text-shadow: 
    0 0 7px rgba(34, 229, 255, 0.9),
    0 0 15px rgba(34, 229, 255, 0.7),
    0 0 30px rgba(34, 229, 255, 0.5),
    0 0 50px rgba(34, 229, 255, 0.3) !important;
  animation: neon-pulse 2s infinite alternate !important;
}

/* Make it pulse slowly like a breathing light */
@keyframes neon-pulse {
  0% {
    text-shadow: 
      0 0 7px rgba(34, 229, 255, 0.9),
      0 0 15px rgba(34, 229, 255, 0.7),
      0 0 30px rgba(34, 229, 255, 0.5),
      0 0 50px rgba(34, 229, 255, 0.3) !important;
  }
  100% {
    text-shadow: 
      0 0 10px rgba(34, 229, 255, 1),
      0 0 25px rgba(34, 229, 255, 0.9),
      0 0 45px rgba(34, 229, 255, 0.7),
      0 0 80px rgba(34, 229, 255, 0.5) !important;
  }
}


/* SOLO TEXT LOGO */
.logo-text-img {
  height: 44px; /* Made it slightly bigger since it's on its own now */
  width: auto;
  display: block;
  margin-left: 0; /* Removed the gap that was there for the icon */
  mix-blend-mode: screen;
}








/* BULLETPROOF WATERMARK BACKGROUND */
body {
  /* The first linear-gradient dims the image to 5% so text is readable */
  background-image: 
    linear-gradient(rgba(3, 5, 8, 0.95), rgba(3, 5, 8, 0.95)), 
    url('logo.jpg') !important;
  background-position: center center !important;
  background-size: 70vmin !important; /* Adjust size here */
  background-repeat: no-repeat !important;
  background-attachment: fixed !important; /* Keeps it in place when scrolling */
  background-color: var(--bg) !important;
}




/* IOS SAFE WATERMARK */
#sl-watermark {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  width: 100vw; height: 100vh;
  background-image: url('logo.jpg');
  background-size: 80vmin;
  background-position: center;
  background-repeat: no-repeat;
  opacity: 0.05; /* Subtle glass effect */
  mix-blend-mode: screen; 
  pointer-events: none;
  z-index: 0;
}

/* Push everything else above it */
body, header, main, .page, .container {
  position: relative;
  z-index: 10;
}


/* FIX HERO BUTTON SIZES */
.hero-cta {
  display: flex !important;
  gap: 16px !important;
  justify-content: center !important;
  align-items: center !important;
  flex-wrap: wrap !important;
}

.hero-cta > a, 
.hero-cta > button {
  width: 200px !important; /* Forces both buttons to be exact same width */
  height: 54px !important; /* Forces exact same height */
  padding: 0 !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  box-sizing: border-box !important;
  margin: 0 !important;
}

@media (max-width: 480px) {
  .hero-cta > a, 
  .hero-cta > button {
    width: 100% !important; /* Stacks them full-width on mobile */
    max-width: 280px !important;
  }
}


/* BOLDER WATERMARK */
#sl-watermark {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  width: 100vw; height: 100vh;
  background-image: url('logo.jpg');
  background-size: 45vw; /* Smaller so it doesn't get stretched/blurry on PC */
  background-position: center;
  background-repeat: no-repeat;
  
  /* Bolder Settings */
  opacity: 0.15 !important; /* 3x bolder than before */
  filter: contrast(1.5) brightness(1.1) !important; /* Sharpens the edges */
  mix-blend-mode: screen; 
  
  pointer-events: none;
  z-index: 0;
}

/* Keep it looking good on mobile too */
@media (max-width: 768px) {
  #sl-watermark {
    background-size: 80vw; /* Bigger on mobile so it fills the screen */
    opacity: 0.12 !important;
  }
}


/* DESKTOP PC OPTIMIZATION (Mobile remains untouched) */
@media (min-width: 768px) {
  /* 1. Center and contain the page so it doesn't stretch infinitely */
  .hub-container {
    max-width: 1200px !important;
    margin: 0 auto !important;
    padding: 40px 60px !important;
  }

  /* 2. Make the Hero text much bigger and punchier for PC */
  .hub-hero h1 {
    font-size: 64px !important;
    line-height: 1.1 !important;
    margin-bottom: 24px !important;
    letter-spacing: -2px !important;
  }
  
  .hub-hero p {
    font-size: 20px !important;
    max-width: 800px !important;
    margin: 0 auto 40px auto !important;
    line-height: 1.6 !important;
  }

  /* 3. Fix the Hero Buttons size on PC */
  .hero-cta {
    margin-bottom: 50px !important;
  }
  .hero-cta > a {
    font-size: 16px !important;
    padding: 18px 40px !important;
  }

  /* 4. Make the 4 stat boxes look premium on PC */
  .hero-stats-row {
    gap: 20px !important;
    max-width: 900px !important;
  }
  .hero-stats-row > div {
    padding: 24px 20px !important;
  }
  .hero-stats-row > div > div:first-child {
    font-size: 36px !important;
  }
  .hero-stats-row > div > div:last-child {
    font-size: 11px !important;
  }

  /* 5. Space out the Telemetry / Features grids so they don't look cramped */
  .telemetry-grid {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 30px !important;
  }
  .feature-grid {
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 30px !important;
  }

  /* 6. Add more breathing room between sections */
  section {
    padding-top: 60px !important;
    padding-bottom: 60px !important;
  }
  
  /* 7. Make the background watermark slightly larger on PC */
  #sl-watermark {
    background-size: 55vw !important;
  }
}




/* DESKTOP LAYOUT CONSTRAINT */
@media (min-width: 768px) {
  /* 1. Center the main container so it doesn't stretch infinitely */
  .hub-container {
    max-width: 1200px !important;
    margin: 0 auto !important;
    padding: 40px 20px !important;
  }

  /* 2. Make the hero text bigger and more balanced for PC */
  .hub-hero {
    padding: 60px 20px 40px 20px !important;
  }
  .hub-hero h1 {
    font-size: 64px !important;
    line-height: 1.1 !important;
  }
  .hub-hero p {
    font-size: 20px !important;
    max-width: 800px !important;
    margin: 0 auto 40px auto !important;
  }

  /* 3. Force the 4 Hero Stat boxes into a neat 4-column row */
  .hero-stats-row {
    grid-template-columns: repeat(4, 1fr) !important;
    max-width: 900px !important;
    margin: 40px auto 0 auto !important;
  }

  /* 4. Force the Live Network Stats into a neat 2x2 grid */
  .section > div[style*="minmax(280px, 1fr)"] {
    grid-template-columns: repeat(2, 1fr) !important;
    max-width: 1000px !important;
    margin: 0 auto !important;
    gap: 20px !important;
  }

  /* 5. Force Access Your Account into 3 equal columns */
  .section > div[style*="minmax(260px, 1fr)"] {
    grid-template-columns: repeat(3, 1fr) !important;
    max-width: 1000px !important;
    margin: 0 auto !important;
    gap: 20px !important;
  }

  /* 6. Force Features into a neat 3x2 grid */
  .feature-grid {
    grid-template-columns: repeat(3, 1fr) !important;
    max-width: 1100px !important;
    margin: 0 auto !important;
    gap: 20px !important;
  }

  /* 7. Constrain the header width */
  header {
    max-width: 1200px;
    margin: 0 auto;
    border-bottom: 1px solid var(--border);
  }
}


/* PORTAL DEFAULT VIEW - ensures correct state on load */
#acctView[style*="display:none"] { display: none !important; }
#authView[style*="display:block"] { display: block !important; }
