/* ===================================================
   Colchis Digital — Global Design System
   Georgia's Premier Digital Asset Exchange
   =================================================== */

@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@300;400;500;600;700&family=Inter:wght@300;400;500;600;700&family=JetBrains+Mono:wght@400;500;600&display=swap');

/* ── CSS Custom Properties ── */
:root {
  /* Backgrounds */
  --bg-deep:      #070B14;
  --bg-card:      #0D1526;
  --bg-elevated:  #111E35;
  --bg-border:    #1A2B4A;
  --bg-hover:     #162240;

  /* Accent Colors */
  --accent-blue:    #3E7BFA;
  --accent-blue-lt: #6699FF;
  --accent-blue-dk: #2560D8;
  --accent-gold:    #F5A623;
  --accent-gold-lt: #FFBF50;
  --accent-emerald: #10B981;
  --accent-red:     #EF4444;
  --accent-purple:  #8B5CF6;

  /* Text */
  --text-primary: #F0F4FF;
  --text-secondary: #B8C4DB;
  --text-muted:   #8896B3;
  --text-faint:   #4A5678;

  /* Typography */
  --font-heading: 'Space Grotesk', sans-serif;
  --font-body:    'Inter', sans-serif;
  --font-mono:    'JetBrains Mono', monospace;

  /* Spacing */
  --space-xs:  0.25rem;
  --space-sm:  0.5rem;
  --space-md:  1rem;
  --space-lg:  1.5rem;
  --space-xl:  2rem;
  --space-2xl: 3rem;
  --space-3xl: 4rem;
  --space-4xl: 6rem;

  /* Radius */
  --radius-sm:  6px;
  --radius-md:  12px;
  --radius-lg:  16px;
  --radius-xl:  24px;
  --radius-full: 9999px;

  /* Shadows */
  --shadow-sm:  0 1px 3px rgba(0,0,0,0.4);
  --shadow-md:  0 4px 16px rgba(0,0,0,0.5);
  --shadow-lg:  0 8px 32px rgba(0,0,0,0.6);
  --shadow-glow-blue: 0 0 24px rgba(62,123,250,0.25);
  --shadow-glow-gold: 0 0 24px rgba(245,166,35,0.2);

  /* Transitions */
  --transition-fast:   150ms ease;
  --transition-normal: 250ms ease;
  --transition-slow:   400ms ease;

  /* Layout */
  --container-max: 1280px;
  --header-h: 72px;
  --sidebar-w: 260px;
}

/* ── Reset & Base ── */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-body);
  background-color: var(--bg-deep);
  color: var(--text-primary);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* ── Typography ── */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

h1 { font-size: clamp(2rem, 5vw, 3.5rem); }
h2 { font-size: clamp(1.5rem, 3vw, 2.25rem); }
h3 { font-size: clamp(1.25rem, 2.5vw, 1.75rem); }
h4 { font-size: 1.25rem; }
h5 { font-size: 1.1rem; }
h6 { font-size: 1rem; }

p { color: var(--text-secondary); line-height: 1.75; }

a {
  color: var(--accent-blue);
  text-decoration: none;
  transition: color var(--transition-fast);
}
a:hover { color: var(--accent-blue-lt); }

/* ── Layout Utilities ── */
.container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--space-xl);
}

@media (max-width: 768px) {
  .container { padding: 0 var(--space-md); }
}

.section { padding: var(--space-4xl) 0; }
.section--sm { padding: var(--space-2xl) 0; }

/* Flex & Grid helpers */
.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.items-start { align-items: flex-start; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.gap-sm { gap: var(--space-sm); }
.gap-md { gap: var(--space-md); }
.gap-lg { gap: var(--space-lg); }
.gap-xl { gap: var(--space-xl); }

.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: var(--space-xl); }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-xl); }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--space-lg); }

@media (max-width: 1024px) {
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
}

/* ── Card Base ── */
.card {
  background: var(--bg-card);
  border: 1px solid var(--bg-border);
  border-radius: var(--radius-lg);
  padding: var(--space-xl);
  transition: border-color var(--transition-normal), box-shadow var(--transition-normal), transform var(--transition-normal);
}
.card:hover {
  border-color: rgba(62, 123, 250, 0.3);
  box-shadow: var(--shadow-glow-blue);
  transform: translateY(-2px);
}

.card--glass {
  background: rgba(13, 21, 38, 0.6);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

/* ── Buttons ── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  padding: 0.75rem 1.75rem;
  border-radius: var(--radius-md);
  font-family: var(--font-heading);
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: all var(--transition-normal);
  white-space: nowrap;
  text-decoration: none;
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent-blue), var(--accent-blue-lt));
  color: #fff;
  box-shadow: 0 4px 20px rgba(62, 123, 250, 0.4);
}
.btn-primary:hover {
  background: linear-gradient(135deg, var(--accent-blue-lt), var(--accent-blue));
  box-shadow: 0 6px 28px rgba(62, 123, 250, 0.6);
  transform: translateY(-1px);
  color: #fff;
}
.btn-primary:active { transform: translateY(0); }

.btn-secondary {
  background: transparent;
  color: var(--text-primary);
  border: 1px solid var(--bg-border);
}
.btn-secondary:hover {
  border-color: var(--accent-blue);
  color: var(--accent-blue);
  background: rgba(62, 123, 250, 0.08);
}

.btn-gold {
  background: linear-gradient(135deg, var(--accent-gold), var(--accent-gold-lt));
  color: #070B14;
  font-weight: 700;
  box-shadow: 0 4px 20px rgba(245, 166, 35, 0.3);
}
.btn-gold:hover {
  box-shadow: 0 6px 28px rgba(245, 166, 35, 0.5);
  transform: translateY(-1px);
  color: #070B14;
}

.btn-sm { padding: 0.5rem 1.25rem; font-size: 0.85rem; }
.btn-lg { padding: 1rem 2.5rem; font-size: 1.05rem; }
.btn-full { width: 100%; }

/* ── Form Elements ── */
.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.375rem;
  margin-bottom: var(--space-lg);
}

.form-label {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-secondary);
  font-family: var(--font-heading);
}

.form-input, .form-select {
  width: 100%;
  padding: 0.875rem 1.125rem;
  background: var(--bg-elevated);
  border: 1px solid var(--bg-border);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 0.95rem;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
  outline: none;
  appearance: none;
}
.form-input:focus, .form-select:focus {
  border-color: var(--accent-blue);
  box-shadow: 0 0 0 3px rgba(62, 123, 250, 0.15);
}
.form-input::placeholder { color: var(--text-faint); }

.form-select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%238896B3' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  padding-right: 2.5rem;
  cursor: pointer;
}

.form-error {
  font-size: 0.8rem;
  color: var(--accent-red);
  margin-top: 0.25rem;
}

/* ── Badge ── */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.25rem 0.75rem;
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 600;
  font-family: var(--font-heading);
  letter-spacing: 0.03em;
  text-transform: uppercase;
}
.badge-blue   { background: rgba(62,123,250,0.15); color: var(--accent-blue-lt); border: 1px solid rgba(62,123,250,0.3); }
.badge-gold   { background: rgba(245,166,35,0.15); color: var(--accent-gold-lt); border: 1px solid rgba(245,166,35,0.3); }
.badge-green  { background: rgba(16,185,129,0.15); color: #34D399; border: 1px solid rgba(16,185,129,0.3); }
.badge-red    { background: rgba(239,68,68,0.15);  color: #F87171; border: 1px solid rgba(239,68,68,0.3); }
.badge-muted  { background: rgba(136,150,179,0.1); color: var(--text-muted); border: 1px solid rgba(136,150,179,0.2); }

/* ── Tag pills ── */
.tag { display: inline-flex; align-items: center; gap: 6px; padding: 4px 12px; border-radius: var(--radius-full); font-size: 0.8rem; font-weight: 500; background: var(--bg-elevated); color: var(--text-secondary); border: 1px solid var(--bg-border); }

/* ── Dividers ── */
.divider { height: 1px; background: var(--bg-border); margin: var(--space-xl) 0; }
.divider-text { display: flex; align-items: center; gap: var(--space-md); color: var(--text-muted); font-size: 0.875rem; }
.divider-text::before, .divider-text::after { content: ''; flex: 1; height: 1px; background: var(--bg-border); }

/* ── Price display ── */
.price {
  font-family: var(--font-mono);
  font-weight: 600;
  letter-spacing: -0.02em;
}
.price-up   { color: var(--accent-emerald); }
.price-down { color: var(--accent-red); }
.price-neutral { color: var(--text-muted); }

/* ── Dot indicator ── */
.dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; }
.dot-green { background: var(--accent-emerald); box-shadow: 0 0 8px var(--accent-emerald); }
.dot-red   { background: var(--accent-red); }
.dot-gold  { background: var(--accent-gold); }
.dot-blue  { background: var(--accent-blue); }

/* ── Glow effects ── */
.glow-blue { box-shadow: var(--shadow-glow-blue); }
.glow-gold { box-shadow: var(--shadow-glow-gold); }
.glow-text-blue { text-shadow: 0 0 20px rgba(62, 123, 250, 0.6); }

/* ── Section headers ── */
.section-label {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent-blue);
  font-family: var(--font-heading);
  margin-bottom: var(--space-sm);
}

.section-title {
  font-family: var(--font-heading);
  font-weight: 700;
  margin-bottom: var(--space-md);
}

.section-subtitle {
  color: var(--text-muted);
  font-size: 1.1rem;
  max-width: 540px;
  line-height: 1.7;
}

/* ── Gradient text ── */
.gradient-text {
  background: linear-gradient(135deg, var(--accent-blue-lt), var(--accent-gold));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ── Scrollbar ── */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--bg-deep); }
::-webkit-scrollbar-thumb { background: var(--bg-border); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--accent-blue); }

/* ── Utility ── */
.text-center { text-align: center; }
.text-right  { text-align: right; }
.text-muted  { color: var(--text-muted); }
.text-primary { color: var(--text-primary); }
.text-blue  { color: var(--accent-blue); }
.text-gold  { color: var(--accent-gold); }
.text-green { color: var(--accent-emerald); }
.text-red   { color: var(--accent-red); }
.text-sm    { font-size: 0.875rem; }
.text-xs    { font-size: 0.75rem; }
.text-lg    { font-size: 1.125rem; }
.font-mono  { font-family: var(--font-mono); }
.font-heading { font-family: var(--font-heading); }
.fw-600     { font-weight: 600; }
.fw-700     { font-weight: 700; }
.mt-auto    { margin-top: auto; }
.mb-0       { margin-bottom: 0; }
.hidden     { display: none !important; }
.sr-only    { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); }

/* ── Mesh gradient background ── */
.bg-mesh {
  position: relative;
}
.bg-mesh::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 60% 50% at 20% 20%, rgba(62,123,250,0.08) 0%, transparent 60%),
    radial-gradient(ellipse 40% 40% at 80% 80%, rgba(139,92,246,0.06) 0%, transparent 60%),
    radial-gradient(ellipse 50% 60% at 50% 0%, rgba(245,166,35,0.04) 0%, transparent 50%);
  pointer-events: none;
  z-index: 0;
}
.bg-mesh > * { position: relative; z-index: 1; }

/* ── Responsive utilities ── */
@media (max-width: 768px) {
  .hide-mobile { display: none !important; }
  .section { padding: var(--space-3xl) 0; }
}
@media (min-width: 769px) {
  .show-mobile { display: none !important; }
}
