/* ── Landing Page ── */
/* Design tokens (self-contained — landing page loads only landing.css) */
:root {
  /* Brand */
  --color-brand: #ff6a00;
  --color-brand-dim: rgba(255, 106, 0, 0.15);
  --color-brand-glow: rgba(255, 106, 0, 0.25);

  /* Semantic */
  --color-positive: #22c55e;
  --color-positive-dim: rgba(34, 197, 94, 0.12);
  --color-negative: #ef4444;
  --color-negative-dim: rgba(239, 68, 68, 0.12);
  --color-warning: #f59e0b;
  --color-blue: #3b82f6;
  --color-yellow: #eab308;

  /* Surface (dark palette) */
  --bg-primary: hsl(220, 20%, 10%);
  --bg-secondary: hsl(220, 18%, 13%);
  --bg-card: hsl(220, 18%, 14%);
  --bg-card-hover: hsl(220, 18%, 16%);
  --bg-sidebar: hsl(220, 22%, 8%);
  --bg-input: hsl(220, 18%, 12%);

  /* Border */
  --border: hsl(220, 14%, 20%);
  --border-hover: hsl(220, 14%, 28%);

  /* Text */
  --text-primary: hsl(220, 10%, 92%);
  --text-secondary: hsl(220, 10%, 60%);
  --text-muted: hsl(220, 10%, 42%);
}

:root {
  /* Landing-specific aliases */
  --orange: var(--color-brand);
  --orange-dim: var(--color-brand-dim);
  --orange-glow: var(--color-brand-glow);
  --green: var(--color-positive);
  --green-dim: var(--color-positive-dim);
  --red: var(--color-negative);
  --red-dim: var(--color-negative-dim);
  --blue: var(--color-blue);
  --yellow: var(--color-yellow);
  --landing-sidebar-width: 200px;
}

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

body.landing-page {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  display: flex;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

/* ── Sidebar ── */
.landing-sidebar {
  width: var(--landing-sidebar-width);
  min-height: 100vh;
  background: var(--bg-sidebar);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0;
  left: 0;
  z-index: 100;
}

.landing-sidebar-logo {
  padding: 20px 24px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 10px;
}

.landing-sidebar-logo .logo-v {
  font-size: 32px;
  font-weight: 800;
  color: var(--orange);
  line-height: 1;
}

.landing-sidebar-logo .logo-text {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-secondary);
  letter-spacing: 0.5px;
}

.landing-sidebar-section {
  padding: 16px 0 4px 0;
}

.landing-sidebar-section-label {
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1.2px;
  color: var(--text-muted);
  padding: 0 20px 8px;
}

.landing-sidebar-nav a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 20px;
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 13px;
  font-weight: 500;
  transition: all 0.15s ease;
  border-left: 2px solid transparent;
}

.landing-sidebar-nav a:hover {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.03);
  border-left-color: var(--orange);
}

.landing-sidebar-nav a.active {
  color: var(--orange);
  background: var(--orange-dim);
  border-left-color: var(--orange);
}

.landing-sidebar-nav a .material-icons {
  font-size: 18px;
  opacity: 0.7;
}

.landing-sidebar-footer {
  margin-top: auto;
  padding: 16px 20px;
  border-top: 1px solid var(--border);
}

.landing-sidebar-footer .status-dot {
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--green);
  margin-right: 6px;
  animation: landing-pulse-dot 2s ease-in-out infinite;
}

@keyframes landing-pulse-dot {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

.landing-sidebar-footer span {
  font-size: 11px;
  color: var(--text-muted);
}

/* ── Main Content ── */
.landing-main {
  margin-left: var(--landing-sidebar-width);
  flex: 1;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ── Market Pulse Strip ── */
.landing-pulse {
  display: flex;
  align-items: center;
  gap: 0;
  padding: 0 24px;
  height: 44px;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border);
  overflow-x: auto;
  flex-shrink: 0;
}

.landing-pulse-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 20px;
  border-right: 1px solid var(--border);
  white-space: nowrap;
  height: 100%;
}

.landing-pulse-item:last-child { border-right: none; }

.landing-pulse-item .label {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
}

.landing-pulse-item .value {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-primary);
  font-variant-numeric: tabular-nums;
}

.landing-pulse-item .change {
  font-size: 11px;
  font-weight: 600;
  padding: 2px 6px;
  border-radius: 4px;
  font-variant-numeric: tabular-nums;
}

.landing-pulse-item .change.up {
  color: var(--green);
  background: var(--green-dim);
}

.landing-pulse-item .change.down {
  color: var(--red);
  background: var(--red-dim);
}

/* ── Content Area ── */
.landing-content {
  padding: 20px 24px 40px;
  flex: 1;
}

/* ── Search Bar ── */
.landing-search {
  margin-bottom: 24px;
}

.landing-search-bar {
  display: flex;
  align-items: center;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 0 16px;
  height: 46px;
  transition: all 0.2s ease;
}

.landing-search-bar:focus-within {
  border-color: var(--orange);
  box-shadow: 0 0 0 3px var(--orange-dim);
}

.landing-search-bar .material-icons {
  color: var(--text-muted);
  font-size: 20px;
  margin-right: 10px;
}

.landing-search-bar input {
  flex: 1;
  background: none;
  border: none;
  outline: none;
  color: var(--text-primary);
  font-size: 14px;
  font-family: 'Inter', sans-serif;
}

.landing-search-bar input::placeholder {
  color: var(--text-muted);
}

.landing-search-hint {
  font-size: 11px;
  color: var(--text-muted);
  background: hsl(220, 18%, 18%);
  padding: 3px 8px;
  border-radius: 4px;
  font-weight: 500;
  white-space: nowrap;
}

/* ── Cards Grid ── */
.landing-cards-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 24px;
}

.landing-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 18px 20px;
  transition: all 0.2s ease;
  cursor: default;
}

.landing-card:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-hover);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3), 0 0 0 1px var(--orange-glow);
}

.landing-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.landing-card-header-left {
  display: flex;
  align-items: center;
  gap: 8px;
}

.landing-card-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
}

.landing-card-icon.hl { background: rgba(139, 92, 246, 0.15); color: var(--color-purple); }
.landing-card-icon.cex { background: rgba(59, 130, 246, 0.15); color: var(--color-blue); }
.landing-card-icon.spot { background: rgba(34, 197, 94, 0.15); color: var(--color-positive); }
.landing-card-icon.options { background: rgba(234, 179, 8, 0.15); color: var(--color-yellow); }

.landing-card-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-primary);
}

.landing-card-subtitle {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 1px;
}

.landing-card-link {
  font-size: 12px;
  color: var(--orange);
  text-decoration: none;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 2px;
  transition: opacity 0.15s;
}

.landing-card-link:hover { opacity: 0.8; }

.landing-card-link .material-icons { font-size: 16px; }

/* ── Mini Tables ── */
.landing-mini-table {
  width: 100%;
  border-collapse: collapse;
}

.landing-mini-table th {
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--text-muted);
  text-align: left;
  padding: 0 0 8px 0;
  border-bottom: 1px solid var(--border);
}

.landing-mini-table th:last-child { text-align: right; }

.landing-mini-table td {
  font-size: 13px;
  padding: 8px 0;
  border-bottom: 1px solid hsl(220, 14%, 16%);
  font-variant-numeric: tabular-nums;
}

.landing-mini-table tr:last-child td { border-bottom: none; }

.landing-mini-table td:last-child { text-align: right; }

.landing-mini-table .token-name {
  font-weight: 600;
  color: var(--text-primary);
}

.landing-mini-table .token-sub {
  font-size: 11px;
  color: var(--text-muted);
}

.landing-mini-table .positive { color: var(--green); font-weight: 600; }
.landing-mini-table .negative { color: var(--red); font-weight: 600; }
.landing-mini-table .neutral { color: var(--text-secondary); }

/* ── Options Card ── */
.landing-options-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.landing-gauge-container { text-align: center; }

.landing-gauge-label {
  font-size: 11px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.6px;
  font-weight: 600;
  margin-bottom: 8px;
}

.landing-gauge-value {
  font-size: 28px;
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1;
  margin-bottom: 4px;
}

.landing-gauge-bar {
  height: 6px;
  background: var(--border);
  border-radius: 3px;
  overflow: hidden;
  margin-top: 8px;
}

.landing-gauge-fill {
  height: 100%;
  border-radius: 3px;
  transition: width 0.6s ease;
}

.landing-gauge-fill.puts { background: linear-gradient(90deg, var(--red), #f87171); }
.landing-gauge-fill.calls { background: linear-gradient(90deg, var(--green), #4ade80); }

.landing-gauge-desc {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 6px;
}

.landing-max-pain-box {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.landing-max-pain-value {
  font-size: 28px;
  font-weight: 700;
  color: var(--yellow);
  line-height: 1;
  margin-bottom: 4px;
}

.landing-max-pain-sub {
  font-size: 11px;
  color: var(--text-muted);
}

.landing-option-stat-row {
  display: flex;
  justify-content: space-between;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
}

.landing-option-stat { text-align: center; }

.landing-option-stat .stat-val {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
}

.landing-option-stat .stat-label {
  font-size: 10px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-top: 2px;
}

/* ── Bottom Tables ── */
.landing-bottom-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.landing-table-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
}

.landing-table-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 20px;
  border-bottom: 1px solid var(--border);
}

.landing-table-card-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 8px;
}

.landing-table-card-title .material-icons {
  font-size: 18px;
  color: var(--orange);
}

.landing-table-card-badge {
  font-size: 10px;
  font-weight: 600;
  color: var(--orange);
  background: var(--orange-dim);
  padding: 3px 8px;
  border-radius: 4px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.landing-full-table {
  width: 100%;
  border-collapse: collapse;
}

.landing-full-table th {
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--text-muted);
  text-align: left;
  padding: 10px 20px;
  background: hsl(220, 18%, 11%);
  border-bottom: 1px solid var(--border);
}

.landing-full-table td {
  font-size: 13px;
  padding: 10px 20px;
  border-bottom: 1px solid hsl(220, 14%, 16%);
  font-variant-numeric: tabular-nums;
}

.landing-full-table tr:last-child td { border-bottom: none; }

.landing-full-table tr:hover td {
  background: rgba(255, 255, 255, 0.02);
}

.landing-addr {
  font-family: 'Inter', monospace;
  font-size: 12px;
  color: var(--blue);
  font-weight: 500;
  text-decoration: none;
}

.landing-chain-badge {
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 3px;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.landing-chain-badge.eth { background: rgba(98, 126, 234, 0.15); color: #627eea; }
.landing-chain-badge.bsc { background: rgba(243, 186, 47, 0.15); color: #f3ba2f; }
.landing-chain-badge.sol { background: rgba(153, 69, 255, 0.15); color: #9945ff; }
.landing-chain-badge.btc { background: rgba(247, 147, 26, 0.15); color: #f7931a; }
.landing-chain-badge.base { background: rgba(0, 82, 255, 0.15); color: #0052ff; }
.landing-chain-badge.arb { background: rgba(40, 160, 240, 0.15); color: #28a0f0; }

.landing-vol-bar-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
}

.landing-vol-bar {
  flex: 1;
  height: 4px;
  background: var(--border);
  border-radius: 2px;
  overflow: hidden;
  max-width: 60px;
}

.landing-vol-bar-fill {
  height: 100%;
  background: var(--orange);
  border-radius: 2px;
}

/* ── Responsive ── */
@media (max-width: 1100px) {
  .landing-cards-grid, .landing-bottom-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .landing-sidebar { display: none; }
  .landing-main { margin-left: 0; }
  .landing-pulse { padding: 0 12px; }
  .landing-content { padding: 16px; }
}
