/* ============================================================
   REALM AI HUB — Stylesheet
   ============================================================ */

/* ===== CSS Variables ===== */
:root {
  --bg-primary: #06060b;
  --bg-secondary: #0c0c14;
  --bg-card: #11111b;
  --bg-elevated: #16162a;
  --bg-code: #0d0d18;
  --bg-hover: #1a1a30;
  --border: #1e1e35;
  --border-light: #2a2a45;
  --accent: #7c3aed;
  --accent-light: #8b5cf6;
  --accent-dim: rgba(124, 58, 237, 0.15);
  --accent-glow: rgba(124, 58, 237, 0.3);
  --accent2: #f59e0b;
  --accent2-dim: rgba(245, 158, 11, 0.15);
  --cyan: #22d3ee;
  --green: #10b981;
  --green-dim: rgba(16, 185, 129, 0.15);
  --red: #ef4444;
  --red-dim: rgba(239, 68, 68, 0.15);
  --text-primary: #e2e8f0;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', monospace;
  --radius: 10px;
  --radius-lg: 16px;
  --radius-sm: 6px;
  --shadow: 0 4px 24px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 12px 48px rgba(0, 0, 0, 0.5);
  --transition: 0.2s ease;
  --nav-height: 64px;
}

/* ===== Reset & Base ===== */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-sans);
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
a { color: var(--accent-light); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--accent); }
::selection { background: var(--accent-dim); color: var(--accent-light); }
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border-light); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--text-muted); }

.container { max-width: 1100px; margin: 0 auto; padding: 0 24px; }

/* ===== Navigation ===== */
#navbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  background: rgba(6, 6, 11, 0.85);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  height: var(--nav-height);
}
.nav-inner {
  max-width: 1200px; margin: 0 auto; padding: 0 24px;
  height: 100%; display: flex; align-items: center; gap: 32px;
}
.nav-logo {
  display: flex; align-items: center; gap: 10px;
  text-decoration: none; color: var(--text-primary); font-weight: 700; font-size: 17px;
  flex-shrink: 0;
}
.logo-icon {
  color: var(--accent-light); font-size: 22px; line-height: 1;
}
.nav-links {
  display: flex; gap: 6px; flex: 1;
}
.nav-links a {
  padding: 6px 14px; border-radius: var(--radius-sm);
  color: var(--text-secondary); font-size: 14px; font-weight: 500;
  transition: all var(--transition);
}
.nav-links a:hover, .nav-links a.active {
  color: var(--text-primary); background: var(--bg-hover);
}
.nav-links a.active { color: var(--accent-light); }
.nav-external { opacity: 0.7; }
.nav-external:hover { opacity: 1; }
.nav-actions {
  display: flex; align-items: center; gap: 8px; flex-shrink: 0;
}
.nav-mobile-toggle {
  display: none; background: none; border: none; color: var(--text-secondary);
  cursor: pointer; padding: 4px;
}
.nav-mobile-menu {
  display: none; flex-direction: column;
  background: var(--bg-secondary); border-bottom: 1px solid var(--border);
  padding: 12px 24px;
}
.nav-mobile-menu a {
  padding: 10px 0; color: var(--text-secondary); font-size: 15px; font-weight: 500;
  border-bottom: 1px solid var(--border);
}
.nav-mobile-menu a:last-child { border-bottom: none; }
.nav-mobile-menu.open { display: flex; }

/* ===== Buttons ===== */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 20px; border: none; border-radius: var(--radius-sm);
  font-family: var(--font-sans); font-size: 14px; font-weight: 600;
  cursor: pointer; transition: all var(--transition); text-decoration: none;
  white-space: nowrap;
}
.btn-primary {
  background: var(--accent); color: #fff;
  box-shadow: 0 2px 12px var(--accent-glow);
}
.btn-primary:hover {
  background: var(--accent-light); color: #fff;
  box-shadow: 0 4px 20px var(--accent-glow);
  transform: translateY(-1px);
}
.btn-ghost {
  background: transparent; color: var(--text-secondary);
  border: 1px solid var(--border);
}
.btn-ghost:hover { background: var(--bg-hover); color: var(--text-primary); border-color: var(--border-light); }
.btn-outline {
  background: transparent; color: var(--text-secondary);
  border: 1px solid var(--border);
}
.btn-outline:hover { border-color: var(--red); color: var(--red); }
.btn-lg { padding: 14px 28px; font-size: 15px; border-radius: var(--radius); }
.btn-sm { padding: 6px 14px; font-size: 12px; }
.btn-icon {
  background: none; border: none; color: var(--text-muted); cursor: pointer;
  padding: 6px; border-radius: var(--radius-sm); transition: all var(--transition);
  display: inline-flex; align-items: center; justify-content: center;
}
.btn-icon:hover { color: var(--text-primary); background: var(--bg-hover); }

/* ===== Views ===== */
.view { display: none; padding-top: var(--nav-height); min-height: 100vh; }
.view.active { display: block; }

/* ===== Hero Section ===== */
.hero {
  position: relative; padding: 100px 24px 60px;
  text-align: center; overflow: hidden;
}
.hero-bg-grid {
  position: absolute; inset: 0; z-index: 0;
  background-image:
    linear-gradient(rgba(124, 58, 237, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(124, 58, 237, 0.03) 1px, transparent 1px);
  background-size: 60px 60px;
  mask-image: radial-gradient(ellipse 60% 50% at 50% 30%, black 20%, transparent 70%);
}
.hero-content { position: relative; z-index: 1; max-width: 720px; margin: 0 auto; }
.hero-badge {
  display: inline-block;
  padding: 6px 16px; margin-bottom: 28px;
  background: var(--accent-dim); border: 1px solid rgba(124, 58, 237, 0.25);
  border-radius: 100px; font-size: 12px; font-weight: 600;
  color: var(--accent-light); letter-spacing: 0.3px;
}
.hero-title {
  font-size: clamp(36px, 6vw, 64px); font-weight: 900;
  line-height: 1.1; letter-spacing: -1.5px; margin-bottom: 20px;
}
.gradient-text {
  background: linear-gradient(135deg, var(--accent-light), var(--cyan), var(--accent2));
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  background-clip: text;
}
.hero-desc {
  font-size: 18px; color: var(--text-secondary);
  max-width: 560px; margin: 0 auto 36px; line-height: 1.7;
}
.hero-actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; margin-bottom: 60px; }
.hero-stats {
  display: flex; gap: 40px; justify-content: center; flex-wrap: wrap;
}
.stat {
  display: flex; align-items: center; gap: 12px;
  padding: 14px 20px; background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius); min-width: 160px;
}
.stat-icon { font-size: 24px; color: var(--accent-light); width: 32px; text-align: center; }
.stat-label { font-size: 11px; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.5px; }
.stat-value { font-size: 15px; font-weight: 700; color: var(--text-primary); }

/* ===== Features ===== */
.features-section { padding: 80px 0; }
.section-title {
  font-size: 32px; font-weight: 800; text-align: center;
  margin-bottom: 12px; letter-spacing: -0.5px;
}
.section-desc {
  text-align: center; color: var(--text-secondary);
  font-size: 16px; margin-bottom: 48px; max-width: 500px; margin-left: auto; margin-right: auto;
}
.features-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}
.feature-card {
  position: relative; padding: 32px;
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius-lg); transition: all 0.3s ease;
}
.feature-card:hover {
  border-color: var(--accent-dim); background: var(--bg-elevated);
  transform: translateY(-4px); box-shadow: 0 8px 32px rgba(124, 58, 237, 0.1);
}
.feature-step {
  position: absolute; top: 16px; right: 20px;
  font-size: 48px; font-weight: 900; color: var(--border);
  line-height: 1; pointer-events: none;
}
.feature-icon {
  width: 56px; height: 56px; border-radius: 14px;
  background: var(--accent-dim); color: var(--accent-light);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 20px;
}
.feature-card h3 { font-size: 18px; font-weight: 700; margin-bottom: 8px; }
.feature-card p { font-size: 14px; color: var(--text-secondary); line-height: 1.65; }

/* ===== Examples ===== */
.examples-section { padding: 80px 0; }
.examples-grid {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.example-card {
  padding: 24px; background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius-lg); transition: all 0.3s ease;
}
.example-card:hover { border-color: var(--accent-dim); }
.example-realm {
  font-family: var(--font-mono); font-size: 16px; font-weight: 600;
  color: var(--accent-light); margin-bottom: 12px;
}
.example-msg {
  font-size: 13.5px; color: var(--text-secondary);
  line-height: 1.65; font-style: italic;
}

/* ===== CTA Section ===== */
.cta-section { padding: 40px 0 80px; }
.cta-card {
  padding: 48px; text-align: center;
  background: linear-gradient(135deg, var(--bg-card), var(--bg-elevated));
  border: 1px solid var(--border); border-radius: var(--radius-lg);
}
.cta-card h2 { font-size: 28px; font-weight: 800; margin-bottom: 12px; }
.cta-card p { color: var(--text-secondary); font-size: 16px; margin-bottom: 28px; max-width: 500px; margin-left: auto; margin-right: auto; }
.cta-actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

/* ===== Dashboard ===== */
#dashboard-view .container { padding-top: 32px; padding-bottom: 60px; }
.dash-header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 28px; flex-wrap: wrap; gap: 12px;
}
.dash-address {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 16px; background: var(--bg-card);
  border: 1px solid var(--border); border-radius: var(--radius);
  font-family: var(--font-mono); font-size: 13px; color: var(--text-secondary);
}
.address-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--green); box-shadow: 0 0 8px var(--green);
  flex-shrink: 0;
}
.dash-actions { display: flex; gap: 8px; }
.realms-header {
  display: flex; align-items: center; gap: 12px; margin-bottom: 24px;
}
.realms-header h2 { font-size: 22px; font-weight: 700; }
.badge {
  padding: 2px 10px; border-radius: 100px;
  background: var(--accent-dim); color: var(--accent-light);
  font-size: 12px; font-weight: 700;
}
.realms-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 16px;
}
.realm-card {
  padding: 24px; background: var(--bg-card);
  border: 1px solid var(--border); border-radius: var(--radius-lg);
  cursor: pointer; transition: all 0.3s ease;
  position: relative; overflow: hidden;
}
.realm-card:hover {
  border-color: var(--accent); background: var(--bg-elevated);
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(124, 58, 237, 0.15);
}
.realm-card-name {
  font-family: var(--font-mono); font-size: 20px; font-weight: 700;
  color: var(--accent-light); margin-bottom: 8px;
  word-break: break-word;
}
.realm-punycode {
  font-size: 0.65em; color: var(--text-muted); font-weight: 500;
  opacity: 0.8;
}
.realm-card-id {
  font-family: var(--font-mono); font-size: 11px;
  color: var(--text-muted); margin-bottom: 16px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.realm-card-action {
  display: flex; align-items: center; gap: 6px;
  font-size: 13px; font-weight: 600; color: var(--accent-light);
}
.realm-card-action svg { transition: transform var(--transition); }
.realm-card:hover .realm-card-action svg { transform: translateX(4px); }
.realm-card-glow {
  position: absolute; top: -50%; right: -50%;
  width: 100%; height: 100%;
  background: radial-gradient(circle, var(--accent-dim) 0%, transparent 70%);
  opacity: 0; transition: opacity 0.3s ease;
  pointer-events: none;
}
.realm-card:hover .realm-card-glow { opacity: 1; }

/* ===== Empty / Loading / Error States ===== */
.empty-state, .loading-state, .error-state {
  display: flex; flex-direction: column; align-items: center;
  justify-content: center; padding: 80px 20px; text-align: center;
}
.empty-icon { color: var(--text-muted); margin-bottom: 20px; opacity: 0.5; }
.empty-state h2, .error-state h2 { font-size: 22px; font-weight: 700; margin-bottom: 8px; }
.empty-state p, .error-state p { color: var(--text-secondary); font-size: 15px; margin-bottom: 24px; max-width: 400px; }
.empty-actions { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; }

.loading-state p { color: var(--text-secondary); font-size: 14px; margin-top: 16px; }
.spinner {
  width: 36px; height: 36px; border: 3px solid var(--border);
  border-top-color: var(--accent-light); border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.error-icon {
  width: 48px; height: 48px; border-radius: 50%;
  background: var(--red-dim); color: var(--red);
  display: flex; align-items: center; justify-content: center;
  font-size: 22px; font-weight: 800; margin-bottom: 16px;
}

/* ===== Chat View ===== */
.chat-container {
  display: flex; flex-direction: column;
  height: calc(100vh - var(--nav-height));
  max-width: 800px; margin: 0 auto;
}
.chat-header {
  display: flex; align-items: center; gap: 12px;
  padding: 14px 20px; border-bottom: 1px solid var(--border);
  background: var(--bg-secondary); flex-shrink: 0;
}
.chat-realm-info { flex: 1; }
.chat-realm-name {
  font-family: var(--font-mono); font-size: 18px; font-weight: 700;
  color: var(--accent-light); word-break: break-word;
}
.chat-realm-name .realm-punycode {
  font-size: 0.6em;
}
.chat-realm-sub { font-size: 12px; color: var(--text-muted); }
.chat-header-actions { display: flex; gap: 4px; }
.chat-messages {
  flex: 1; overflow-y: auto; padding: 20px;
  display: flex; flex-direction: column; gap: 16px;
}
.chat-msg {
  display: flex; gap: 10px; max-width: 85%;
  animation: msgSlideIn 0.25s ease;
}
@keyframes msgSlideIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}
.chat-msg.bot { align-self: flex-start; }
.chat-msg.user { align-self: flex-end; flex-direction: row-reverse; }

.msg-avatar {
  width: 32px; height: 32px; border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-size: 12px; font-weight: 800; flex-shrink: 0; margin-top: 2px;
}
.chat-msg.bot .msg-avatar {
  background: var(--accent-dim); color: var(--accent-light);
}
.chat-msg.user .msg-avatar {
  background: var(--bg-elevated); color: var(--text-muted);
}

.msg-bubble {
  padding: 12px 16px; border-radius: 14px;
  font-size: 14px; line-height: 1.65;
}
.chat-msg.bot .msg-bubble {
  background: var(--bg-card); border: 1px solid var(--border);
  color: var(--text-secondary); border-top-left-radius: 4px;
}
.chat-msg.user .msg-bubble {
  background: var(--accent); color: #fff;
  border-top-right-radius: 4px;
}
.msg-bubble strong { color: var(--text-primary); }
.msg-bubble code {
  background: var(--bg-code); padding: 1px 5px; border-radius: 3px;
  font-family: var(--font-mono); font-size: 12px; color: var(--cyan);
  border: 1px solid var(--border);
}
.msg-bubble pre {
  background: var(--bg-code); border: 1px solid var(--border);
  border-radius: 6px; padding: 10px 12px; margin: 8px 0;
  overflow-x: auto; font-size: 12px;
}
.msg-bubble pre code { border: none; padding: 0; display: block; }

.typing-indicator {
  display: flex; gap: 4px; padding: 8px 0;
}
.typing-indicator span {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--text-muted); animation: typingBounce 1.4s infinite;
}
.typing-indicator span:nth-child(2) { animation-delay: 0.2s; }
.typing-indicator span:nth-child(3) { animation-delay: 0.4s; }
@keyframes typingBounce {
  0%, 60%, 100% { transform: translateY(0); opacity: 0.3; }
  30% { transform: translateY(-6px); opacity: 1; }
}

/* Welcome message styling */
.chat-welcome {
  text-align: center; padding: 40px 20px;
  color: var(--text-muted);
}
.chat-welcome-icon {
  font-size: 48px; margin-bottom: 16px; color: var(--accent-light); opacity: 0.5;
}
.chat-welcome h3 { font-size: 18px; color: var(--text-secondary); margin-bottom: 8px; }
.chat-welcome p { font-size: 13px; max-width: 360px; margin: 0 auto; line-height: 1.6; }

.chat-input-area {
  padding: 16px 20px; border-top: 1px solid var(--border);
  background: var(--bg-secondary); flex-shrink: 0;
}
.chat-input-wrapper {
  display: flex; gap: 10px; align-items: flex-end;
}
.chat-input-wrapper textarea {
  flex: 1; padding: 12px 16px;
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius); color: var(--text-primary);
  font-family: var(--font-sans); font-size: 14px;
  resize: none; outline: none; min-height: 44px; max-height: 120px;
  line-height: 1.5; transition: border-color var(--transition);
}
.chat-input-wrapper textarea:focus { border-color: var(--accent); }
.chat-input-wrapper textarea::placeholder { color: var(--text-muted); }
.chat-send-btn {
  width: 44px; height: 44px; border: none;
  background: var(--accent); color: #fff; border-radius: var(--radius);
  cursor: pointer; display: flex; align-items: center; justify-content: center;
  transition: all var(--transition); flex-shrink: 0;
}
.chat-send-btn:hover { background: var(--accent-light); transform: scale(1.05); }
.chat-send-btn:disabled { opacity: 0.4; cursor: not-allowed; transform: none; }

.chat-input-footer {
  display: flex; justify-content: space-between; align-items: center;
  margin-top: 8px; font-size: 11px; color: var(--text-muted);
}
.chat-input-footer a { font-size: 11px; }

/* ===== Lookup View ===== */
#lookup-view .container { padding-top: 48px; padding-bottom: 60px; }
.lookup-header { text-align: center; margin-bottom: 40px; }
.lookup-header h1 { font-size: 32px; font-weight: 800; margin-bottom: 8px; }
.lookup-header p { color: var(--text-secondary); font-size: 16px; }

.lookup-search { max-width: 600px; margin: 0 auto 32px; }
.lookup-input-group {
  display: flex; align-items: stretch;
  background: var(--bg-card); border: 2px solid var(--border);
  border-radius: var(--radius-lg); overflow: hidden;
  transition: border-color var(--transition);
}
.lookup-input-group:focus-within { border-color: var(--accent); }
.lookup-prefix {
  display: flex; align-items: center; padding: 0 4px 0 18px;
  font-family: var(--font-mono); font-size: 20px; font-weight: 700;
  color: var(--accent-light);
}
.lookup-input-group input {
  flex: 1; padding: 14px 12px; background: transparent; border: none;
  color: var(--text-primary); font-family: var(--font-mono); font-size: 16px;
  outline: none;
}
.lookup-input-group input::placeholder { color: var(--text-muted); font-family: var(--font-sans); font-size: 14px; }
.lookup-input-group .btn { border-radius: 0; padding: 14px 24px; }
.lookup-hint { text-align: center; font-size: 12px; color: var(--text-muted); margin-top: 8px; }

#lookup-result { max-width: 600px; margin: 0 auto 40px; }
.lookup-result-card {
  padding: 24px; background: var(--bg-card);
  border: 1px solid var(--border); border-radius: var(--radius-lg);
}
.lookup-result-card.minted { border-color: rgba(16, 185, 129, 0.3); }
.lookup-result-card.available { border-color: rgba(245, 158, 11, 0.3); }

.result-status {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 12px; border-radius: 100px;
  font-size: 12px; font-weight: 700; margin-bottom: 16px;
}
.result-status.minted { background: var(--green-dim); color: var(--green); }
.result-status.available { background: var(--accent2-dim); color: var(--accent2); }

.result-name {
  font-family: var(--font-mono); font-size: 24px; font-weight: 700;
  color: var(--text-primary); margin-bottom: 12px;
}
.result-details { margin-bottom: 16px; }
.result-row {
  display: flex; justify-content: space-between; padding: 6px 0;
  font-size: 13px; border-bottom: 1px solid var(--border);
}
.result-row:last-child { border-bottom: none; }
.result-row .label { color: var(--text-muted); }
.result-row .value { color: var(--text-primary); font-family: var(--font-mono); font-size: 12px; }
.result-actions { display: flex; gap: 10px; flex-wrap: wrap; }

.lookup-suggestions {
  max-width: 600px; margin: 0 auto; text-align: center;
}
.lookup-suggestions h3 { font-size: 14px; color: var(--text-muted); font-weight: 500; margin-bottom: 14px; }
.suggestion-chips { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }
.chip {
  padding: 6px 16px; background: var(--bg-card); border: 1px solid var(--border);
  border-radius: 100px; color: var(--text-secondary); font-family: var(--font-mono);
  font-size: 13px; cursor: pointer; transition: all var(--transition);
}
.chip:hover { border-color: var(--accent); color: var(--accent-light); background: var(--accent-dim); }

/* ===== Modals ===== */
.modal-overlay {
  position: fixed; inset: 0; z-index: 200;
  background: rgba(0, 0, 0, 0.6); backdrop-filter: blur(8px);
  display: none; align-items: center; justify-content: center;
  padding: 20px;
}
.modal-overlay.open { display: flex; }
.modal {
  background: var(--bg-secondary); border: 1px solid var(--border);
  border-radius: var(--radius-lg); width: 100%; max-width: 460px;
  box-shadow: var(--shadow-lg); animation: modalIn 0.2s ease;
  max-height: 90vh; overflow-y: auto;
}
@keyframes modalIn { from { opacity: 0; transform: scale(0.95) translateY(10px); } to { opacity: 1; transform: scale(1) translateY(0); } }
.modal-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 20px 24px; border-bottom: 1px solid var(--border);
}
.modal-header h3 { font-size: 17px; font-weight: 700; }
.modal-close { color: var(--text-muted); }
.modal-body { padding: 24px; }
.modal-desc { font-size: 13.5px; color: var(--text-secondary); margin-bottom: 20px; line-height: 1.6; }
.modal-actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 20px; }

/* Wallet Options */
.wallet-options { display: flex; flex-direction: column; gap: 10px; margin-bottom: 20px; }
.wallet-option {
  display: flex; align-items: center; gap: 14px;
  padding: 16px; background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius); cursor: pointer; transition: all var(--transition);
  text-align: left; width: 100%; color: inherit; font-family: inherit;
}
.wallet-option:hover { border-color: var(--accent); background: var(--bg-elevated); }
.wallet-option.disabled { opacity: 0.4; cursor: not-allowed; }
.wallet-option.disabled:hover { border-color: var(--border); background: var(--bg-card); }
.wallet-icon {
  width: 44px; height: 44px; border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0; overflow: hidden;
}
.wallet-icon svg {
  width: 100%; height: 100%; display: block;
}
.wallet-info { flex: 1; }
.wallet-name { font-size: 14px; font-weight: 600; }
.wallet-desc { font-size: 12px; color: var(--text-muted); margin-top: 2px; }
.wallet-status {
  font-size: 11px; color: var(--text-muted);
  padding: 3px 10px; background: var(--bg-primary);
  border-radius: 100px; white-space: nowrap;
}
.wallet-status.ready { color: var(--green); background: var(--green-dim); }
.wallet-status.missing { color: var(--red); background: var(--red-dim); }
.wallet-connected-info {
  display: flex; align-items: center;
  padding: 8px 0;
}
.wallet-note {
  font-size: 12.5px; color: var(--text-muted);
  padding: 12px 16px; background: var(--bg-card);
  border: 1px solid var(--border); border-radius: var(--radius-sm);
  line-height: 1.6;
}
.wallet-note strong { color: var(--text-secondary); }

/* Form Elements */
.form-label {
  display: block; font-size: 11px; font-weight: 600;
  color: var(--text-muted); text-transform: uppercase;
  letter-spacing: 0.5px; margin-bottom: 6px; margin-top: 16px;
}
.form-label:first-of-type { margin-top: 0; }
.form-select, .form-input {
  width: 100%; padding: 10px 14px;
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius-sm); color: var(--text-primary);
  font-family: var(--font-sans); font-size: 13px;
  outline: none; transition: border-color var(--transition);
}
.form-select:focus, .form-input:focus { border-color: var(--accent); }
.form-select option { background: var(--bg-card); }
.input-with-toggle {
  position: relative; display: flex; align-items: center;
}
.input-with-toggle input { padding-right: 40px; }
.input-with-toggle .btn-icon {
  position: absolute; right: 6px; top: 50%; transform: translateY(-50%);
}

.provider-guide {
  margin-top: 12px; padding: 12px 16px;
  background: var(--accent-dim); border: 1px solid rgba(124, 58, 237, 0.2);
  border-radius: var(--radius-sm); font-size: 12.5px;
  color: var(--text-secondary); line-height: 1.65;
}
.provider-guide strong { color: var(--accent-light); }

/* ===== Toasts ===== */
#toast-container {
  position: fixed; top: 80px; right: 24px; z-index: 300;
  display: flex; flex-direction: column; gap: 8px;
}
.toast {
  padding: 12px 20px; border-radius: var(--radius);
  font-size: 13px; font-weight: 500;
  background: var(--bg-elevated); border: 1px solid var(--border);
  color: var(--text-primary); box-shadow: var(--shadow);
  animation: toastIn 0.3s ease;
  max-width: 360px;
}
.toast.success { border-color: rgba(16, 185, 129, 0.4); }
.toast.error { border-color: rgba(239, 68, 68, 0.4); }
.toast.info { border-color: rgba(124, 58, 237, 0.4); }
@keyframes toastIn { from { opacity: 0; transform: translateX(20px); } to { opacity: 1; transform: translateX(0); } }
.toast-out { animation: toastOut 0.3s ease forwards; }
@keyframes toastOut { to { opacity: 0; transform: translateX(20px); } }

/* ===== Footer ===== */
#site-footer {
  padding: 32px 0; border-top: 1px solid var(--border);
  background: var(--bg-secondary);
}
.footer-content {
  display: flex; align-items: center; justify-content: space-between;
  flex-wrap: wrap; gap: 16px;
}
.footer-brand { font-weight: 700; font-size: 15px; color: var(--text-secondary); }
.footer-links { display: flex; gap: 20px; }
.footer-links a { font-size: 13px; color: var(--text-muted); }
.footer-links a:hover { color: var(--text-primary); }
.footer-copy { font-size: 12px; color: var(--text-muted); }

/* ===== Responsive ===== */
@media (max-width: 1024px) and (min-width: 769px) {
  .examples-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 768px) {
  .nav-links, .nav-actions #btn-ai-settings { display: none; }
  .nav-mobile-toggle { display: block; }
  .nav-inner { gap: 0; justify-content: space-between; }
  .nav-actions { gap: 6px; }
  .hero { padding: 60px 16px 40px; }
  .hero-stats { flex-direction: column; align-items: center; gap: 12px; }
  .stat { min-width: 200px; }
  .features-grid { grid-template-columns: 1fr; }
  .examples-grid { grid-template-columns: 1fr; }
  .cta-card { padding: 32px 20px; }
  .chat-container { height: calc(100vh - var(--nav-height)); }
  .chat-messages { padding: 12px; }
  .chat-msg { max-width: 92%; }
  .dash-header { flex-direction: column; align-items: stretch; }
  .dash-address { justify-content: center; }
  .dash-actions { justify-content: center; }
  .realms-grid { grid-template-columns: 1fr; }
  .footer-content { flex-direction: column; text-align: center; }
  .footer-links { justify-content: center; }
  .lookup-input-group { flex-direction: column; border-radius: var(--radius); }
  .lookup-prefix { padding: 10px 18px 0; font-size: 16px; }
  .lookup-input-group input { font-size: 14px; }
  .lookup-input-group .btn { border-radius: 0 0 var(--radius) var(--radius); }
}
