:root {
  --bg-dark: #07080f;
  --bg-card: rgba(18, 21, 35, 0.75);
  --bg-card-hover: rgba(26, 30, 50, 0.85);
  --monad-purple: #836ef9;
  --monad-purple-glow: rgba(131, 110, 249, 0.4);
  --monad-purple-light: #a08bfc;
  --cyber-cyan: #00f0ff;
  --cyber-cyan-glow: rgba(0, 240, 255, 0.35);
  --neon-green: #10b981;
  --neon-amber: #f59e0b;
  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-purple: rgba(131, 110, 249, 0.35);
  --text-primary: #f8fafc;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  --font-display: 'Space Grotesk', sans-serif;
  --font-sans: 'Inter', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-xl: 28px;
  --radius-full: 9999px;
  --shadow-dapp: 0 20px 40px -15px rgba(0, 0, 0, 0.7), 0 0 1px rgba(255, 255, 255, 0.1);
}

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

body {
  background-color: var(--bg-dark);
  color: var(--text-primary);
  font-family: var(--font-sans);
  line-height: 1.6;
  overflow-x: hidden;
  position: relative;
  min-height: 100vh;
}

.font-mono {
  font-family: var(--font-mono);
}

/* Cosmic Background */
.cosmic-bg {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: -1;
  overflow: hidden;
}

.glow-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(140px);
  opacity: 0.28;
  animation: orbFloat 14s infinite alternate ease-in-out;
}

.orb-1 {
  width: 600px;
  height: 600px;
  background: var(--monad-purple);
  top: -10%;
  right: -5%;
}

.orb-2 {
  width: 500px;
  height: 500px;
  background: var(--cyber-cyan);
  bottom: 10%;
  left: -5%;
  animation-duration: 18s;
}

@keyframes orbFloat {
  0% { transform: translate(0, 0) scale(1); }
  100% { transform: translate(-80px, 60px) scale(1.15); }
}

.grid-overlay {
  position: absolute;
  inset: 0;
  background-image: 
    linear-gradient(rgba(255, 255, 255, 0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
  background-size: 50px 50px;
  opacity: 0.6;
}

/* Navbar */
.navbar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(7, 8, 15, 0.85);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-subtle);
  padding: 16px 0;
}

.nav-container {
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
}

.brand-logo {
  position: relative;
  width: 42px;
  height: 42px;
  background: linear-gradient(135deg, #1e1b4b, #31104b);
  border: 1.5px solid var(--monad-purple);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 20px var(--monad-purple-glow);
}

.brand-logo.small {
  width: 32px;
  height: 32px;
}

.pulse-ring {
  position: absolute;
  inset: -4px;
  border-radius: 16px;
  border: 1px solid var(--monad-purple);
  opacity: 0.4;
  animation: pulseRing 2.5s infinite;
}

@keyframes pulseRing {
  0% { transform: scale(0.95); opacity: 0.8; }
  100% { transform: scale(1.2); opacity: 0; }
}

.logo-icon {
  font-size: 1.3rem;
  color: #fff;
}

.brand-name {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.35rem;
  letter-spacing: -0.5px;
  color: #fff;
}

.network-badge {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.72rem;
  color: var(--text-secondary);
  background: rgba(131, 110, 249, 0.12);
  border: 1px solid rgba(131, 110, 249, 0.3);
  padding: 2px 8px;
  border-radius: var(--radius-full);
  margin-top: 2px;
}

.status-dot {
  width: 6px;
  height: 6px;
  background: var(--neon-green);
  border-radius: 50%;
  box-shadow: 0 0 8px var(--neon-green);
  animation: blink 2s infinite;
}

@keyframes blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
}

.nav-link {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 600;
  transition: all 0.2s ease;
  position: relative;
  display: flex;
  align-items: center;
  gap: 6px;
}

.nav-link:hover, .nav-link.active {
  color: #fff;
}

.nav-pill {
  background: linear-gradient(135deg, #ef4444, #f97316);
  color: #fff;
  font-size: 0.65rem;
  font-weight: 800;
  padding: 2px 6px;
  border-radius: var(--radius-full);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 16px;
}

.gas-tracker {
  display: flex;
  align-items: center;
  gap: 6px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-subtle);
  padding: 6px 12px;
  border-radius: var(--radius-full);
  font-size: 0.8rem;
  font-family: var(--font-mono);
  color: var(--text-secondary);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: none;
  cursor: pointer;
  font-family: var(--font-sans);
  font-weight: 600;
  border-radius: var(--radius-md);
  transition: all 0.25s ease;
  text-decoration: none;
}

.btn-connect {
  background: linear-gradient(135deg, var(--monad-purple) 0%, #6d28d9 100%);
  color: #fff;
  padding: 10px 20px;
  font-size: 0.92rem;
  box-shadow: 0 4px 15px var(--monad-purple-glow);
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.btn-connect:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 25px rgba(131, 110, 249, 0.6);
  background: linear-gradient(135deg, var(--monad-purple-light) 0%, #7c3aed 100%);
}

.btn-primary {
  background: linear-gradient(135deg, var(--monad-purple) 0%, #5b21b6 100%);
  color: #fff;
  padding: 16px 28px;
  font-size: 1.05rem;
  font-weight: 700;
  box-shadow: 0 4px 20px var(--monad-purple-glow);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(131, 110, 249, 0.7);
}

.btn-block {
  width: 100%;
}

.btn-sm {
  padding: 8px 16px;
  font-size: 0.85rem;
}

.btn-outline {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  color: #fff;
}

.btn-outline:hover {
  background: rgba(131, 110, 249, 0.15);
  border-color: var(--monad-purple);
}

.btn-twitter {
  background: #1d9bf0;
  color: #fff;
}

.btn-twitter:hover {
  background: #0c8de4;
}

/* Hero Section */
.hero-section {
  padding: 70px 0 40px;
  text-align: center;
}

.hero-container {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 20px;
}

.announcement-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(131, 110, 249, 0.1);
  border: 1px solid rgba(131, 110, 249, 0.3);
  padding: 6px 18px;
  border-radius: var(--radius-full);
  font-size: 0.88rem;
  color: #fff;
  margin-bottom: 24px;
}

.pill-arrow {
  color: var(--monad-purple-light);
}

.hero-title {
  font-family: var(--font-display);
  font-size: 3.4rem;
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -1.2px;
  margin-bottom: 20px;
}

.gradient-text {
  background: linear-gradient(135deg, #fff 0%, var(--monad-purple-light) 50%, var(--cyber-cyan) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-subtitle {
  font-size: 1.2rem;
  color: var(--text-secondary);
  max-width: 720px;
  margin: 0 auto 50px;
  line-height: 1.6;
}

/* Metrics Bar */
.metrics-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.metric-card {
  background: var(--bg-card);
  backdrop-filter: blur(16px);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 22px 18px;
  text-align: left;
  transition: all 0.3s ease;
}

.metric-card:hover {
  border-color: var(--border-purple);
  transform: translateY(-3px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
}

.metric-label {
  font-size: 0.82rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 600;
}

.metric-value-wrap {
  display: flex;
  align-items: baseline;
  gap: 6px;
  margin: 8px 0 10px;
}

.metric-value {
  font-size: 1.9rem;
  font-weight: 700;
  color: #fff;
}

.metric-unit {
  font-size: 0.85rem;
  color: var(--monad-purple-light);
  font-weight: 700;
}

.metric-badge {
  font-size: 0.75rem;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: var(--radius-sm);
  display: inline-block;
}

.metric-badge.green { background: rgba(16, 185, 129, 0.15); color: var(--neon-green); }
.metric-badge.purple { background: rgba(131, 110, 249, 0.15); color: var(--monad-purple-light); }
.metric-badge.cyan { background: rgba(0, 240, 255, 0.15); color: var(--cyber-cyan); }
.metric-badge.amber { background: rgba(245, 158, 11, 0.15); color: var(--neon-amber); }

/* dApp Section */
.dapp-section {
  padding: 40px 0 80px;
}

.dapp-container {
  max-width: 680px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Tabs */
.dapp-tabs {
  display: flex;
  background: rgba(18, 21, 35, 0.9);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: 6px;
  margin-bottom: 24px;
  gap: 6px;
}

.dapp-tab {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: transparent;
  border: none;
  color: var(--text-secondary);
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 0.9rem;
  padding: 12px 14px;
  border-radius: var(--radius-lg);
  cursor: pointer;
  transition: all 0.25s ease;
  position: relative;
}

.dapp-tab:hover {
  color: #fff;
}

.dapp-tab.active {
  background: var(--monad-purple);
  color: #fff;
  box-shadow: 0 4px 15px var(--monad-purple-glow);
}

.tab-badge {
  background: var(--cyber-cyan);
  color: #000;
  font-size: 0.65rem;
  font-weight: 800;
  padding: 2px 6px;
  border-radius: var(--radius-full);
}

/* Panels */
.tab-panel {
  display: none;
}

.tab-panel.active {
  display: block;
  animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.panel-card {
  background: var(--bg-card);
  backdrop-filter: blur(24px);
  border: 1px solid var(--border-purple);
  border-radius: var(--radius-xl);
  padding: 32px;
  box-shadow: var(--shadow-dapp);
}

.panel-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 24px;
}

.panel-header h3 {
  font-family: var(--font-display);
  font-size: 1.45rem;
  color: #fff;
  margin-bottom: 4px;
}

.panel-header p {
  color: var(--text-secondary);
  font-size: 0.9rem;
}

.status-chip {
  font-size: 0.75rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: var(--radius-full);
  background: rgba(16, 185, 129, 0.15);
  color: var(--neon-green);
  border: 1px solid rgba(16, 185, 129, 0.3);
}

/* Form */
.faucet-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.input-group label {
  display: block;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

.input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.input-wrapper input {
  width: 100%;
  background: rgba(7, 8, 15, 0.8);
  border: 1.5px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 14px 105px 14px 16px;
  color: #fff;
  font-family: var(--font-mono);
  font-size: 0.95rem;
  outline: none;
  transition: all 0.25s ease;
}

.input-wrapper input:focus {
  border-color: var(--monad-purple);
  box-shadow: 0 0 15px var(--monad-purple-glow);
}

.btn-paste {
  position: absolute;
  right: 8px;
  background: rgba(131, 110, 249, 0.15);
  border: 1px solid rgba(131, 110, 249, 0.3);
  color: var(--monad-purple-light);
  font-size: 0.78rem;
  font-weight: 700;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-paste:hover {
  background: var(--monad-purple);
  color: #fff;
}

.drip-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(7, 8, 15, 0.6);
  border: 1.5px solid var(--border-purple);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  cursor: pointer;
}

.drip-box input {
  display: none;
}

.drip-info strong {
  display: block;
  font-size: 1.05rem;
  color: #fff;
}

.drip-info small {
  color: var(--text-muted);
  font-size: 0.8rem;
}

.drip-tag {
  background: rgba(131, 110, 249, 0.2);
  color: var(--monad-purple-light);
  font-size: 0.75rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: var(--radius-full);
}

/* Tx Result Box */
.tx-result {
  background: rgba(16, 185, 129, 0.08);
  border: 1.5px solid rgba(16, 185, 129, 0.4);
  border-radius: var(--radius-md);
  padding: 18px;
  margin-top: 20px;
  animation: fadeIn 0.3s ease;
}

.tx-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.tx-check {
  background: var(--neon-green);
  color: #000;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.85rem;
}

.tx-header h4 {
  color: #fff;
  font-size: 1rem;
}

.tx-details {
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 0.85rem;
}

.tx-row {
  display: flex;
  justify-content: space-between;
  color: var(--text-secondary);
}

.tx-hash {
  color: var(--cyber-cyan);
  max-width: 260px;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Swap Card */
.swap-card {
  max-width: 520px;
  margin: 0 auto;
}

.btn-settings {
  background: transparent;
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  width: 36px;
  height: 36px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-size: 1rem;
}

.swap-box {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.swap-token-box {
  background: rgba(7, 8, 15, 0.7);
  border: 1.5px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 16px;
}

.token-box-header {
  display: flex;
  justify-content: space-between;
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.token-box-input {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.token-box-input input {
  background: transparent;
  border: none;
  color: #fff;
  font-family: var(--font-mono);
  font-size: 1.8rem;
  font-weight: 700;
  width: 60%;
  outline: none;
}

.token-badge {
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--border-subtle);
  padding: 8px 14px;
  border-radius: var(--radius-full);
}

.token-symbol {
  font-weight: 700;
  font-size: 1rem;
  color: #fff;
}

.swap-divider {
  display: flex;
  justify-content: center;
  margin: -12px 0;
  z-index: 2;
}

.btn-switch {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: #1e1b4b;
  border: 2px solid var(--monad-purple);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-switch:hover {
  transform: rotate(180deg);
  background: var(--monad-purple);
}

.swap-route-info {
  background: rgba(255, 255, 255, 0.02);
  border-radius: var(--radius-sm);
  padding: 12px;
  margin: 10px 0 16px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 0.82rem;
  color: var(--text-muted);
}

.route-row {
  display: flex;
  justify-content: space-between;
}

.text-green {
  color: var(--neon-green);
}

/* Quests */
.quests-banner {
  background: linear-gradient(135deg, rgba(131, 110, 249, 0.2) 0%, rgba(0, 240, 255, 0.1) 100%);
  border: 1px solid var(--border-purple);
  border-radius: var(--radius-md);
  padding: 18px 24px;
  margin-bottom: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.xp-label {
  font-size: 0.82rem;
  color: var(--text-secondary);
}

.xp-total {
  font-size: 1.8rem;
  color: #fff;
  display: block;
}

.rank-badge {
  background: rgba(131, 110, 249, 0.3);
  color: #fff;
  font-size: 0.85rem;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: var(--radius-full);
  display: inline-block;
  margin-bottom: 4px;
}

.quest-rank-box small {
  display: block;
  color: var(--text-muted);
  font-size: 0.78rem;
}

.quests-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.quest-item {
  display: flex;
  align-items: center;
  gap: 16px;
  background: rgba(7, 8, 15, 0.6);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  transition: all 0.2s ease;
}

.quest-item:hover {
  border-color: var(--border-purple);
  background: rgba(131, 110, 249, 0.05);
}

.quest-status {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1.5px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.quest-item.completed .quest-status {
  background: var(--neon-green);
  border-color: var(--neon-green);
  color: #000;
}

.quest-details {
  flex: 1;
}

.quest-details h4 {
  font-size: 1rem;
  color: #fff;
  margin-bottom: 2px;
}

.quest-details p {
  font-size: 0.82rem;
  color: var(--text-muted);
}

.quest-action {
  display: flex;
  align-items: center;
  gap: 12px;
}

.xp-reward {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--monad-purple-light);
}

.claimed-tag {
  font-size: 0.78rem;
  color: var(--neon-green);
  font-weight: 700;
}

/* Explorer Stream Table */
.stream-table-wrapper {
  overflow-x: auto;
}

.stream-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.85rem;
  font-family: var(--font-mono);
}

.stream-table th {
  text-align: left;
  color: var(--text-muted);
  font-weight: 600;
  padding: 12px 10px;
  border-bottom: 1px solid var(--border-subtle);
  font-family: var(--font-sans);
}

.stream-table td {
  padding: 12px 10px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.03);
  color: var(--text-secondary);
}

.tx-type-pill {
  font-size: 0.72rem;
  padding: 2px 6px;
  border-radius: var(--radius-sm);
}

.tx-type-pill.faucet { background: rgba(0, 240, 255, 0.15); color: var(--cyber-cyan); }
.tx-type-pill.swap { background: rgba(131, 110, 249, 0.15); color: var(--monad-purple-light); }
.tx-type-pill.quest { background: rgba(16, 185, 129, 0.15); color: var(--neon-green); }

.pulse-live-indicator {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--neon-green);
  animation: blink 1.5s infinite;
}

/* Features Section */
.features-section {
  padding: 80px 0;
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
  background: rgba(10, 12, 22, 0.4);
}

.features-container {
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 20px;
}

.section-title-wrap {
  text-align: center;
  margin-bottom: 50px;
}

.section-badge {
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 1px;
  color: var(--monad-purple-light);
}

.section-title-wrap h2 {
  font-family: var(--font-display);
  font-size: 2.2rem;
  color: #fff;
  margin-top: 8px;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 30px;
  transition: all 0.3s ease;
}

.feature-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-purple);
}

.f-icon {
  font-size: 2.2rem;
  margin-bottom: 16px;
}

.feature-card h3 {
  font-family: var(--font-display);
  font-size: 1.25rem;
  color: #fff;
  margin-bottom: 10px;
}

.feature-card p {
  color: var(--text-secondary);
  font-size: 0.92rem;
}

/* Footer */
.footer {
  padding: 60px 0 30px;
}

.footer-container {
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  justify-content: space-between;
  gap: 40px;
  margin-bottom: 40px;
}

.footer-desc {
  color: var(--text-muted);
  font-size: 0.88rem;
  max-width: 280px;
  margin-top: 10px;
}

.footer-links {
  display: flex;
  gap: 60px;
}

.footer-col h5 {
  color: #fff;
  font-size: 0.95rem;
  margin-bottom: 14px;
}

.footer-col a {
  display: block;
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.88rem;
  margin-bottom: 8px;
  transition: color 0.2s ease;
}

.footer-col a:hover {
  color: var(--monad-purple-light);
}

.footer-bottom {
  max-width: 1140px;
  margin: 0 auto;
  padding: 24px 20px 0;
  border-top: 1px solid var(--border-subtle);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.82rem;
  color: var(--text-muted);
}

.footer-tags {
  display: flex;
  gap: 16px;
}

/* Modal */
.modal-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(12px);
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.modal-backdrop.open {
  display: flex;
}

.modal-dialog {
  background: #111424;
  border: 1.5px solid var(--monad-purple);
  border-radius: var(--radius-xl);
  padding: 30px;
  max-width: 440px;
  width: 100%;
  box-shadow: 0 0 50px var(--monad-purple-glow);
  animation: modalIn 0.25s ease;
}

@keyframes modalIn {
  from { transform: scale(0.92); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
}

.modal-header h3 {
  font-family: var(--font-display);
  font-size: 1.3rem;
  color: #fff;
}

.modal-close {
  background: none;
  border: none;
  color: var(--text-secondary);
  font-size: 1.5rem;
  cursor: pointer;
}

.modal-desc {
  color: var(--text-muted);
  font-size: 0.85rem;
  margin-bottom: 20px;
}

.wallets-grid {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 20px;
}

.wallet-option {
  display: flex;
  align-items: center;
  gap: 14px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 14px 18px;
  cursor: pointer;
  text-align: left;
  transition: all 0.2s ease;
}

.wallet-option:hover {
  background: rgba(131, 110, 249, 0.12);
  border-color: var(--monad-purple);
  transform: translateX(4px);
}

.w-icon {
  font-size: 1.6rem;
}

.w-info {
  flex: 1;
}

.w-info strong {
  display: block;
  font-size: 0.95rem;
  color: #fff;
}

.w-info small {
  color: var(--text-muted);
  font-size: 0.78rem;
}

.w-badge {
  background: rgba(16, 185, 129, 0.15);
  color: var(--neon-green);
  font-size: 0.72rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: var(--radius-full);
}

.modal-footer-notice {
  font-size: 0.75rem;
  color: var(--text-muted);
  text-align: center;
  line-height: 1.4;
}

/* Spinner */
.spinner {
  display: none;
  width: 18px;
  height: 18px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin-left: 8px;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.btn.loading .spinner {
  display: inline-block;
}

/* Responsive */
@media (max-width: 900px) {
  .hero-title { font-size: 2.6rem; }
  .metrics-grid { grid-template-columns: repeat(2, 1fr); }
  .features-grid { grid-template-columns: 1fr; }
  .nav-links { display: none; }
  .footer-container { flex-direction: column; }
  .footer-links { flex-wrap: wrap; gap: 30px; }
  .footer-bottom { flex-direction: column; gap: 12px; text-align: center; }
}

@media (max-width: 600px) {
  .hero-title { font-size: 2rem; }
  .metrics-grid { grid-template-columns: 1fr; }
  .dapp-tabs { flex-wrap: wrap; }
  .dapp-tab { flex: 1 1 45%; }
}
