:root {
  --bg: #0F1117;
  --card: #1A1D27;
  --red: #C41E2E;
  --red-soft: rgba(196,30,46,0.12);
  --text: #E8E9F0;
  --muted: #8B8FA8;
  --border: rgba(255,255,255,0.08);
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: 'DM Sans', system-ui, sans-serif;
  font-size: 15px;
  line-height: 1.5;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, h4, .display { font-family: 'Space Grotesk', sans-serif; letter-spacing: -0.02em; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font-family: inherit; font-size: inherit; color: inherit; }

.btn {
  background: var(--red);
  color: #fff;
  border: none;
  padding: 12px 22px;
  border-radius: 10px;
  font-weight: 600;
  cursor: pointer;
  transition: filter .15s, transform .15s;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.btn:hover { filter: brightness(1.1); }
.btn:active { transform: scale(0.98); }
.btn-ghost {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text);
}
.btn-ghost:hover { background: rgba(255,255,255,0.04); }
.btn-danger { background: #2a1418; color: #ff7280; border: 1px solid rgba(255,114,128,0.25); }
.btn-danger:hover { background: #3a1820; }

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 22px;
}

.input {
  width: 100%;
  background: #0c0e14;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 12px 14px;
  color: var(--text);
  outline: none;
  transition: border-color .15s;
}
.input:focus { border-color: var(--red); }

.muted { color: var(--muted); }

.badge {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  background: rgba(255,255,255,0.06);
  color: var(--muted);
  border: 1px solid var(--border);
}
.badge-active { background: rgba(46,204,113,0.12); color: #4ade80; border-color: rgba(74,222,128,0.25); }
.badge-red { background: var(--red-soft); color: #ff8a92; border-color: rgba(196,30,46,0.35); }

.grid-bg {
  position: fixed;
  inset: 0;
  z-index: -1;
  background-color: var(--bg);
  background-image:
    linear-gradient(rgba(196,30,46,0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(196,30,46,0.06) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse at center, #000 30%, transparent 75%);
}

.logo-wrap { display: flex; align-items: center; gap: 14px; font-weight: 700; }
.logo-img { height: 42px; width: auto; display: block; }
.logo-img.lg { height: 64px; }
.logo-sep {
  width: 1px; height: 28px; background: var(--border);
}
.logo-text { font-family: 'Space Grotesk', sans-serif; font-size: 15px; letter-spacing: -0.01em; line-height: 1.2; }
.logo-text small { display: block; font-size: 11px; color: var(--muted); font-weight: 500; letter-spacing: 0.02em; margin-top: 2px; }

.dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: #4ade80;
  box-shadow: 0 0 0 0 rgba(74,222,128,0.6);
  animation: pulse 1.6s infinite;
  display: inline-block;
}
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(74,222,128,0.55); }
  70% { box-shadow: 0 0 0 8px rgba(74,222,128,0); }
  100% { box-shadow: 0 0 0 0 rgba(74,222,128,0); }
}

.toast {
  position: fixed; bottom: 24px; right: 24px;
  background: var(--card);
  border: 1px solid var(--border);
  border-left: 3px solid var(--red);
  padding: 14px 18px;
  border-radius: 10px;
  z-index: 9999;
  max-width: 360px;
  animation: slideIn .25s ease;
}
@keyframes slideIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
