/* Vaulta — design system (green / gold / Fraunces) + full app */

:root {
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --bg: #0D1B18;
  --surface: #123028;
  --surface-2: #17392F;
  --gold: #D9B25C;
  --gold-soft: rgba(217, 178, 92, 0.14);
  --teal: #3FAE8E;
  --text: #EDEDE3;
  --text-dim: #9FB3AC;
  --danger: #E2604F;
  --line: rgba(237, 237, 227, 0.09);
  --radius: 18px;
  --vault-green: #3FAE8E;
  --vault-green-light: #3FAE8E;
}

* { box-sizing: border-box; }

body {
  background: var(--bg) !important;
  color: var(--text);
  font-family: 'Space Grotesk', system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, .font-serif {
  font-family: 'Fraunces', Georgia, serif;
  font-weight: 500;
  letter-spacing: -0.01em;
}

.logo {
  font-family: 'Fraunces', serif;
  font-size: 22px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 0;
  letter-spacing: -0.02em;
  color: var(--text);
}
.logo span { color: var(--gold); }

.bg-vault-600 {
  background-color: var(--gold) !important;
  color: #12261F !important;
}
.bg-vault-600:hover,
.hover\:bg-vault-500:hover {
  background-color: #e0bc6a !important;
  color: #12261F !important;
}
.text-vault-400,
.text-vault-300 { color: var(--teal) !important; }
.border-vault-600 { border-color: var(--gold) !important; }
.ring-vault-500 { --tw-ring-color: var(--gold) !important; }
.bg-vault-600\/10 { background-color: var(--gold-soft) !important; }
.bg-vault-700 { background-color: var(--surface-2) !important; }

.card,
.bg-slate-900,
.bg-slate-850 {
  background: var(--surface) !important;
  border-color: var(--line) !important;
}
.bg-slate-950 { background: var(--bg) !important; }
.bg-slate-800 { background: var(--surface-2) !important; }
.border-slate-700,
.border-slate-800 { border-color: var(--line) !important; }
.text-slate-400,
.text-slate-500 { color: var(--text-dim) !important; }
.text-slate-300,
.text-slate-200 { color: var(--text) !important; }

.deposit-bonus-banner {
  background: linear-gradient(120deg, rgba(217, 178, 92, 0.14), rgba(63, 174, 142, 0.08));
  border: 1px solid rgba(217, 178, 92, 0.28);
}

#swap-from-asset,
#swap-to-asset {
  max-width: 7.5rem;
}

.safe-bottom {
  padding-bottom: calc(0.5rem + var(--safe-bottom));
}

.nav-btn {
  color: var(--text-dim);
  transition: all 0.15s ease;
}
.nav-btn:hover {
  background: var(--gold-soft);
  color: var(--text);
}
.nav-btn.active {
  background: var(--gold-soft);
  color: var(--gold);
  font-weight: 600;
}

.nav-btn-mobile { color: var(--text-dim); }
.nav-btn-mobile.active { color: var(--gold); }

.term-btn.active,
.loan-term-btn.active {
  border-color: var(--gold) !important;
  background: var(--gold-soft) !important;
  color: var(--gold) !important;
}

::-webkit-scrollbar { width: 5px; height: 5px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--surface-2); border-radius: 3px; }

.toast {
  pointer-events: auto;
  animation: slideIn 0.28s ease;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.35);
  background: var(--gold) !important;
  color: #12261F !important;
}
@keyframes slideIn {
  from { transform: translateX(110%); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}
@keyframes slideOut {
  from { transform: translateX(0); opacity: 1; }
  to { transform: translateX(110%); opacity: 0; }
}

input[type=number]::-webkit-inner-spin-button,
input[type=number]::-webkit-outer-spin-button {
  -webkit-appearance: none;
  margin: 0;
}
input[type=number] { -moz-appearance: textfield; }

input, select, textarea {
  font-family: 'Space Grotesk', system-ui, sans-serif;
  color: var(--text);
}
input:focus, select:focus {
  border-color: var(--gold) !important;
  outline: none;
}

.page {
  animation: fadeIn 0.22s ease;
}
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

.live-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--teal);
  display: inline-block;
  animation: pulse 1.5s ease infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

#sidebar,
.platform-bar {
  background: #0A1815 !important;
  border-color: var(--line) !important;
}

input[type=range] {
  accent-color: var(--gold);
}

#landing-screen h1 {
  font-family: 'Fraunces', Georgia, serif;
  font-weight: 500;
}

#auth-modal .bg-slate-900 {
  background: var(--surface) !important;
}

/* Compact crypto charts */
.spark-wrap {
  height: 36px;
  width: 100%;
  position: relative;
}
.spark-wrap canvas {
  width: 100% !important;
  height: 100% !important;
}
#demo-chart {
  max-height: 100px !important;
}
#asset-charts .card {
  padding: 0.65rem 0.75rem !important;
}
@media (min-width: 1024px) {
  .spark-wrap { height: 40px; }
}
@media (max-width: 640px) {
  .spark-wrap { height: 28px; }
  #asset-charts {
    gap: 0.5rem !important;
  }
}
