/* ============================================
   EXPLORER PAGE
   ============================================ */

/* Hero / search area */
.ex-hero {
  text-align: center;
  padding: 0 0 48px;
}

.ex-title {
  font-family: var(--mono);
  font-size: 28px;
  font-weight: 600;
  letter-spacing: 0.04em;
  margin: 0 0 8px;
}

.ex-subtitle {
  font-family: var(--mono);
  font-size: 13px;
  color: var(--text-dim);
  letter-spacing: 0.02em;
  margin: 0 0 28px;
}

.ex-search-wrap {
  display: flex;
  gap: 0;
  max-width: 680px;
  margin: 0 auto;
}

.ex-search {
  flex: 1;
  padding: 14px 18px;
  background: var(--bg-elev);
  border: 1px solid var(--line-2);
  border-right: none;
  border-radius: 2px 0 0 2px;
  color: var(--text);
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: 0.02em;
  outline: none;
  transition: border-color 0.15s ease;
}

.ex-search:focus {
  border-color: var(--accent);
}

.ex-search::placeholder {
  color: var(--text-muted);
}

.ex-search-btn {
  padding: 14px 24px;
  background: var(--accent);
  color: #000;
  border: 1px solid var(--accent);
  border-radius: 0 2px 2px 0;
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.04em;
  cursor: pointer;
  transition: background 0.12s ease;
  white-space: nowrap;
}

.ex-search-btn:hover {
  background: var(--accent-dim);
}

.ex-search-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.ex-error {
  margin-top: 12px;
  font-family: var(--mono);
  font-size: 12px;
  color: var(--red);
  min-height: 18px;
}

/* Address banner */
.ex-addr-banner {
  padding: 20px 24px;
  background: var(--bg-elev);
  border: 1px solid var(--line-2);
  border-radius: 2px;
  margin-bottom: 32px;
}

.ex-addr-label {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--text-muted);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 6px;
}

.ex-addr-value {
  font-family: var(--mono);
  font-size: 15px;
  color: var(--accent);
  letter-spacing: 0.02em;
  word-break: break-all;
}

/* Sections */
.ex-section {
  margin-bottom: 36px;
}

.ex-section-title {
  font-family: var(--mono);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text);
  margin: 0 0 16px;
}

.ex-empty {
  padding: 32px 20px;
  font-family: var(--mono);
  font-size: 12px;
  color: var(--text-muted);
  text-align: center;
  border: 1px solid var(--line);
  background: var(--bg);
}

/* Holdings table */
.ex-holdings-wrap {
  border: 1px solid var(--line);
  background: var(--bg);
}

.ex-holdings-head,
.ex-holding-row {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 0.8fr;
  gap: 12px;
  padding: 14px 20px;
  align-items: center;
  font-family: var(--mono);
  font-size: 12px;
}

.ex-holdings-head {
  border-bottom: 1px solid var(--line);
  color: #a3a3a3;
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.ex-holding-row {
  border-bottom: 1px solid var(--line);
  transition: background 0.12s ease;
}

.ex-holding-row:last-child {
  border-bottom: none;
}

.ex-holding-row:hover {
  background: var(--bg-elev);
}

.ex-holding-ticker {
  font-weight: 600;
  font-size: 14px;
  color: var(--accent);
}

.ex-holding-pct {
  color: #a3a3a3;
}

/* Tabs */
.ex-tabs {
  display: flex;
  gap: 0;
  margin-bottom: 0;
}

.ex-tab {
  padding: 12px 20px;
  background: transparent;
  border: 1px solid var(--line);
  border-bottom: none;
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.12s ease;
  border-radius: 2px 2px 0 0;
}

.ex-tab:not(:first-child) {
  border-left: none;
}

.ex-tab:hover {
  color: var(--text);
}

.ex-tab-active {
  background: var(--bg);
  color: var(--accent);
  border-color: var(--line);
}

.ex-panel {
  border: 1px solid var(--line);
  border-top: none;
  background: var(--bg);
}

/* Activity table */
.ex-table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.ex-activity-head,
.ex-activity-row {
  display: grid;
  grid-template-columns: 100px 90px 1fr 1.2fr 1.2fr 100px;
  gap: 12px;
  padding: 12px 20px;
  align-items: center;
  font-family: var(--mono);
  font-size: 12px;
}

.ex-activity-head {
  border-bottom: 1px solid var(--line);
  color: #a3a3a3;
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  background: var(--bg);
}

.ex-activity-row {
  border-bottom: 1px solid var(--line);
  transition: background 0.12s ease;
}

.ex-activity-row:last-child {
  border-bottom: none;
}

.ex-activity-row:hover {
  background: var(--bg-elev);
}

/* Trades table */
.ex-trades-head,
.ex-trade-row {
  display: grid;
  grid-template-columns: 70px 80px 1fr 1fr 1fr 1.3fr 100px;
  gap: 12px;
  padding: 12px 20px;
  align-items: center;
  font-family: var(--mono);
  font-size: 12px;
}

.ex-trades-head {
  border-bottom: 1px solid var(--line);
  color: #a3a3a3;
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  background: var(--bg);
}

.ex-trade-row {
  border-bottom: 1px solid var(--line);
  transition: background 0.12s ease;
}

.ex-trade-row:last-child {
  border-bottom: none;
}

.ex-trade-row:hover {
  background: var(--bg-elev);
}

/* Event badges */
.ex-badge {
  display: inline-block;
  padding: 3px 8px;
  border-radius: 2px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.ex-badge-mint {
  background: rgba(76, 175, 80, 0.15);
  color: var(--green);
  border: 1px solid rgba(76, 175, 80, 0.4);
}

.ex-badge-transfer {
  background: rgba(100, 181, 246, 0.12);
  color: #64b5f6;
  border: 1px solid rgba(100, 181, 246, 0.35);
}

.ex-badge-trade {
  background: rgba(244, 183, 40, 0.12);
  color: var(--accent);
  border: 1px solid rgba(244, 183, 40, 0.4);
}

.ex-badge-deploy {
  background: rgba(186, 104, 200, 0.12);
  color: #ba68c8;
  border: 1px solid rgba(186, 104, 200, 0.35);
}

.ex-badge-inscribe {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-dim);
  border: 1px solid var(--line-2);
}

.ex-badge-buy {
  background: rgba(76, 175, 80, 0.15);
  color: var(--green);
  border: 1px solid rgba(76, 175, 80, 0.4);
}

.ex-badge-sell {
  background: rgba(239, 83, 80, 0.12);
  color: var(--red);
  border: 1px solid rgba(239, 83, 80, 0.35);
}

/* Address display */
.ex-addr {
  color: var(--text-dim);
  font-size: 11px;
}

.ex-addr-self {
  color: var(--accent);
  font-weight: 500;
}

.ex-time {
  color: #a3a3a3;
  font-size: 11px;
}

/* Responsive */
@media (max-width: 980px) {
  .ex-activity-head,
  .ex-activity-row {
    grid-template-columns: 80px 70px 1fr 1fr 1fr 80px;
    font-size: 11px;
    padding: 10px 14px;
  }
  .ex-trades-head,
  .ex-trade-row {
    grid-template-columns: 60px 70px 1fr 1fr 1fr 1fr 80px;
    font-size: 11px;
    padding: 10px 14px;
  }
  .ex-holdings-head,
  .ex-holding-row {
    padding: 12px 14px;
  }
}

@media (max-width: 620px) {
  .ex-search-wrap {
    flex-direction: column;
  }
  .ex-search {
    border-right: 1px solid var(--line-2);
    border-radius: 2px 2px 0 0;
  }
  .ex-search-btn {
    border-radius: 0 0 2px 2px;
  }
  .ex-activity-head,
  .ex-activity-row {
    grid-template-columns: 70px 70px 1fr 1fr 70px;
  }
  /* Hide FROM column on mobile */
  .ex-activity-head > div:nth-child(4),
  .ex-activity-row > div:nth-child(4) {
    display: none;
  }
  .ex-trades-head,
  .ex-trade-row {
    grid-template-columns: 50px 60px 1fr 1fr 70px;
  }
  /* Hide PRICE and COUNTERPARTY on mobile */
  .ex-trades-head > div:nth-child(4),
  .ex-trades-head > div:nth-child(6),
  .ex-trade-row > div:nth-child(4),
  .ex-trade-row > div:nth-child(6) {
    display: none;
  }
  .ex-holdings-head,
  .ex-holding-row {
    grid-template-columns: 1fr 1fr 0.6fr;
  }
  /* Hide TRANSFERABLE on mobile */
  .ex-holdings-head > div:nth-child(3),
  .ex-holding-row > div:nth-child(3) {
    display: none;
  }
}
