:root {
  --color-bg: #0a0820; /* Darker, bluer midnight for immersive crypto feel */
  --color-surface: #1a1523; /* Kept, but ensured lowercase; subtle card bg */
  --color-surface-elevated: #252a35; /* Warmer gray-blue for depth on hover cards */
  --color-border: #383241; /* Neutral divider; high contrast on surfaces */
  --color-text: #e6d9ff; /* Softer lavender-white for better readability (original was stark) */
  --color-text-secondary: #b0a8cc; /* Muted purple-gray for subtitles; less harsh */
  --color-primary: #6e48d9; /* Richer indigo-purple; energetic yet professional */
  --color-primary-hover: #5a36c3; /* Deeper on hover for feedback */
  --color-primary-light: rgba(110, 72, 217, 0.15); /* Softer overlay for subtle glows */
  --color-success: #00d1b2; /* Brighter teal (like Solana vibes) for buys/positives */
  --color-error: #ff4d7d; /* Softer pink-red for errors; less alarming */
  --color-warning: #ff8c00; /* Amber for alerts; more visible on dark */
  --color-buy: #00d1b2; /* Matches success for consistency */
  --color-sell: #ff4d7d; /* Matches error for sell actions */

  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-mono: "SF Mono", Monaco, "Cascadia Code", "Roboto Mono", Consolas, monospace;

  --radius: 16px;
  --radius-lg: 24px;
  --shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 20px 40px rgba(0, 0, 0, 0.5);
}

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

body {
  font-family: var(--font-sans);
  background: var(--color-bg);
  color: var(--color-text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

/* Navbar */
.navbar {
  background: rgba(26, 21, 35, 0.8);
  border-bottom: 1px solid var(--color-border);
  padding: 16px 0;
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(20px);
}

.navbar .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 20px;
  font-weight: 600;
  color: var(--color-text);
}

.nav-brand .logo {
  width: 40px;
  height: 40px;
  object-fit: contain;
}

.nav-brand svg {
  color: var(--color-primary);
}

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

.nav-menu {
  display: flex;
  gap: 32px;
  align-items: center;
}

.nav-menu a {
  color: var(--color-text-secondary);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.2s;
}

.nav-menu a:hover {
  color: var(--color-text);
}

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

/* Buttons */
.btn-primary,
.btn-secondary {
  padding: 10px 20px;
  border-radius: var(--radius);
  font-weight: 600;
  text-decoration: none;
  display: inline-block;
  transition: all 0.2s;
  border: none;
  cursor: pointer;
  font-size: 10px;
}

.btn-primary {
  background: linear-gradient(135deg, var(--color-primary) 0%, #8b5cf6 100%);
  color: white;
  box-shadow: 0 4px 12px rgba(118, 69, 217, 0.3);
}

.btn-primary:hover {
  background: linear-gradient(135deg, var(--color-primary-hover) 0%, #7c3aed 100%);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(118, 69, 217, 0.4);
}

.btn-secondary {
  background: var(--color-surface-elevated);
  color: var(--color-text);
  border: 2px solid var(--color-border);
}

.btn-secondary:hover {
  background: var(--color-border);
  border-color: var(--color-primary);
}

.btn-lg {
  padding: 14px 28px;
  font-size: 16px;
}

.btn-sm {
  padding: 6px 12px;
  font-size: 13px;
}

.btn-block {
  width: 100%;
  text-align: center;
}

.btn-buy {
  background: var(--color-buy);
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: var(--radius);
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-buy:hover {
  opacity: 0.9;
  transform: translateY(-1px);
}

.btn-sell {
  background: var(--color-sell);
  color: white;
  border: none;
  padding: 5px 10px;
  border-radius: var(--radius);
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-sell:hover {
  opacity: 0.9;
  transform: translateY(-1px);
}

/* Hero Section */
.hero {
  padding: 50px 0;
  position: relative;
  overflow: hidden;
  background: url('background.png') no-repeat center center;
  background-size: cover; /* makes the image fill the section nicely */
}

.hero .container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
}

.hero-content {
  max-width: 600px;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: 100px;
  font-size: 14px;
  color: var(--color-text-secondary);
  margin-bottom: 24px;
}

.badge-dot {
  width: 8px;
  height: 8px;
  background: var(--color-success);
  border-radius: 50%;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.5;
  }
}

.hero h1 {
  font-size: 56px;
  font-weight: 700;
  line-height: 1.1;
  margin-bottom: 24px;
  background: linear-gradient(135deg, #f4eeff 0%, #7645d9 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-subtitle {
  font-size: 18px;
  color: var(--color-text-secondary);
  margin-bottom: 32px;
  line-height: 1.6;
}

.hero-actions {
  display: flex;
  gap: 16px;
}

.hero-visual {
  display: flex;
  justify-content: center;
}

.trading-card {
  background: var(--color-surface);
  border: 2px solid transparent;
  background-image: linear-gradient(var(--color-surface), var(--color-surface)),
    linear-gradient(135deg, var(--color-primary), #8b5cf6);
  background-origin: border-box;
  background-clip: padding-box, border-box;
  border-radius: var(--radius-lg);
  padding: 24px;
  width: 100%;
  max-width: 400px;
  box-shadow: var(--shadow-lg);
}

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

.crypto-icon {
  width: 48px;
  height: 48px;
  background: var(--color-primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
}

.crypto-name {
  font-weight: 600;
  font-size: 18px;
}

.crypto-symbol {
  color: var(--color-text-secondary);
  font-size: 14px;
}

.price-display {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
}

.price {
  font-size: 32px;
  font-weight: 700;
  font-family: var(--font-mono);
}

.price-change {
  padding: 4px 12px;
  border-radius: 6px;
  font-weight: 600;
  font-size: 14px;
}

.price-change.positive {
  background: rgba(16, 185, 129, 0.1);
  color: var(--color-success);
}

.chart-placeholder {
  height: 120px;
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.1) 0%, rgba(16, 185, 129, 0.1) 100%);
  border-radius: var(--radius);
  margin-bottom: 24px;
}

.trade-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

/* Features Section */
.features {
  padding: 120px 0;
  background: var(--color-surface);
}

.section-title {
  text-align: center;
  font-size: 42px;
  font-weight: 700;
  margin-bottom: 64px;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 32px;
}

.feature-card {
  background: var(--color-surface);
  border: 2px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 32px;
  transition: all 0.3s;
  position: relative;
  overflow: hidden;
}

.feature-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(118, 69, 217, 0.1), rgba(139, 92, 246, 0.1));
  opacity: 0;
  transition: opacity 0.3s;
}

.feature-card:hover::before {
  opacity: 1;
}

.feature-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
  border-color: var(--color-primary);
}

.feature-icon {
  font-size: 48px;
  margin-bottom: 16px;
}

.feature-card h3 {
  font-size: 20px;
  font-weight: 600;
  margin-bottom: 12px;
  color: var(--color-primary);
}

.feature-card p {
  color: var(--color-text-secondary);
  line-height: 1.6;
}

/* CTA Section */
.cta {
  padding: 120px 0;
  text-align: center;
}

.cta h2 {
  font-size: 42px;
  font-weight: 700;
  margin-bottom: 16px;
}

.cta p {
  font-size: 18px;
  color: var(--color-text-secondary);
  margin-bottom: 32px;
}

/* About Section */
.about {
  padding: 120px 0;
  background: var(--color-bg);
}

.about-content {
  max-width: 900px;
  margin: 0 auto;
  text-align: center;
}

.about-intro {
  font-size: 20px;
  color: var(--color-text);
  margin-bottom: 48px;
  line-height: 1.8;
}

.company-info {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 32px;
  margin-bottom: 48px;
}

.info-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 32px;
  text-align: left;
  transition: all 0.3s;
}

.info-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--color-primary);
}

.info-card h3 {
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 16px;
  color: var(--color-primary);
}

.info-card p {
  font-size: 16px;
  color: var(--color-text-secondary);
  line-height: 1.6;
}

.about-description {
  font-size: 18px;
  color: var(--color-text-secondary);
  line-height: 1.8;
}

/* Footer */
.footer {
  background: var(--color-surface);
  border-top: 1px solid var(--color-border);
  padding: 48px 0;
  margin-top: 120px;
}

.footer-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 18px;
  font-weight: 600;
}

.footer-brand .logo {
  width: 32px;
  height: 32px;
  object-fit: contain;
}

.footer-brand svg {
  color: var(--color-primary);
  margin-bottom: 16px;
}

.footer p {
  color: var(--color-text-secondary);
  font-size: 14px;
}

/* Auth Pages */
.auth-page {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 50vh;
  padding: 24px;
}

.auth-container {
  width: 100%;
  max-width: 440px;
}

.auth-card {
  background: var(--color-surface);
  border: 2px solid transparent;
  background-image: linear-gradient(var(--color-surface), var(--color-surface)),
    linear-gradient(135deg, var(--color-primary), #8b5cf6);
  background-origin: border-box;
  background-clip: padding-box, border-box;
  border-radius: var(--radius-lg);
  padding: 48px;
  box-shadow: var(--shadow-lg);
}

.auth-header {
  text-align: center;
  margin-bottom: 32px;
}

.auth-header svg {
  color: var(--color-primary);
  margin-bottom: 16px;
}

.auth-header h1 {
  font-size: 28px;
  font-weight: 700;
  margin-bottom: 8px;
}

.auth-header p {
  color: var(--color-text-secondary);
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.form-group label {
  font-weight: 600;
  font-size: 14px;
}

.form-group input,
.form-group select,
.form-group textarea {
  padding: 14px 18px;
  background: var(--color-bg);
  border: 2px solid var(--color-border);
  border-radius: var(--radius);
  color: var(--color-text);
  font-size: 15px;
  font-family: var(--font-sans);
  transition: all 0.2s;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 4px rgba(118, 69, 217, 0.15);
  background: var(--color-surface);
}

.auth-footer {
  text-align: center;
  margin-top: 24px;
  padding-top: 24px;
  border-top: 1px solid var(--color-border);
}

.auth-footer a {
  color: var(--color-primary);
  text-decoration: none;
  font-weight: 600;
}

.auth-footer a:hover {
  text-decoration: underline;
}

/* Alerts */
.alert {
  padding: 16px;
  border-radius: var(--radius);
  margin-bottom: 24px;
  font-size: 14px;
}

.alert-error {
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid var(--color-error);
  color: var(--color-error);
}

.alert-success {
  background: rgba(16, 185, 129, 0.1);
  border: 1px solid var(--color-success);
  color: var(--color-success);
}

/* Dashboard */
.dashboard {
  padding: 48px 0;
  min-height: calc(100vh - 200px);
}

.dashboard-header {
  margin-bottom: 48px;
}

.dashboard-header h1 {
  font-size: 36px;
  font-weight: 700;
  margin-bottom: 8px;
}

.dashboard-header p {
  color: var(--color-text-secondary);
  font-size: 16px;
}

.wallet-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 24px;
  margin-bottom: 48px;
}

.wallet-card {
  background: linear-gradient(135deg, var(--color-surface) 0%, var(--color-surface-elevated) 100%);
  border: 2px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 24px;
  transition: all 0.3s;
}

.wallet-card:hover {
  border-color: var(--color-primary);
  transform: translateY(-4px);
  box-shadow: var(--shadow);
}

.dashboard-actions {
  display: flex;
  gap: 16px;
  margin-bottom: 48px;
}

.orders-section h2 {
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 24px;
}

.orders-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 24px;
}

.order-card {
  background: var(--color-surface);
  border: 2px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 24px;
  transition: all 0.3s;
  position: relative;
  overflow: hidden;
}

.order-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
  background: linear-gradient(180deg, var(--color-primary), #8b5cf6);
  opacity: 0;
  transition: opacity 0.3s;
}

.order-card:hover::before {
  opacity: 1;
}

.order-card:hover {
  border-color: var(--color-primary);
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

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

.order-type {
  padding: 4px 12px;
  border-radius: 6px;
  font-weight: 600;
  font-size: 12px;
  text-transform: uppercase;
}

.order-type.buy {
  background: rgba(16, 185, 129, 0.1);
  color: var(--color-buy);
}

.order-type.sell {
  background: rgba(239, 68, 68, 0.1);
  color: var(--color-sell);
}

.order-crypto {
  font-weight: 600;
  color: var(--color-text-secondary);
}

.order-details {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 16px;
}

.order-amount {
  font-size: 20px;
  font-weight: 700;
  font-family: var(--font-mono);
}

.order-price,
.order-total,
.order-payment {
  font-size: 14px;
  color: var(--color-text-secondary);
}

.empty-state {
  text-align: center;
  color: var(--color-text-secondary);
  padding: 48px;
}

/* Page Header */
.page-header {
  margin-bottom: 48px;
  padding-top: 48px;
}

.page-header h1 {
  font-size: 36px;
  font-weight: 700;
  margin-bottom: 8px;
}

.page-header p {
  color: var(--color-text-secondary);
  font-size: 16px;
}

/* Form Container */
.form-container {
  max-width: 600px;
  margin: 0 auto;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 48px;
}

.order-form,
.kyc-form {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.form-total {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px;
  background: var(--color-bg);
  border-radius: var(--radius);
  font-size: 18px;
  font-weight: 600;
}

/* KYC Status */
.kyc-status-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 32px;
  margin-bottom: 32px;
}

.kyc-status-card h3 {
  font-size: 24px;
  margin-bottom: 16px;
}

.kyc-status-card.status-pending {
  border-color: var(--color-warning);
}

.kyc-status-card.status-approved {
  border-color: var(--color-success);
}

.kyc-status-card.status-rejected {
  border-color: var(--color-error);
}

.rejection-reason {
  color: var(--color-error);
  margin-top: 12px;
}
/* Navbar Logo Styling */
.nav-brand .logo {
    height: 45px; /* adjust size as you like */
    width: auto;
    vertical-align: middle;
    transition: transform 0.3s ease;
}

.nav-brand .logo:hover {
    transform: scale(1.05);
}

/* Responsive */
@media (max-width: 768px) {
  .hero .container {
    grid-template-columns: 1fr;
    gap: 48px;
  }

  .hero h1 {
    font-size: 42px;
  }
    .auth-logo {
      display: block;
      margin: 12px auto 8px;
      width: 60px;
      height: auto;
      max-width: 60px;
    }

  .hero-actions {
    flex-direction: column;
  }

  .features-grid {
    grid-template-columns: 1fr;
  }

  .nav-menu {
    display: none;
  }

  .wallet-cards {
    grid-template-columns: 1fr;
  }

  .orders-grid {
    grid-template-columns: 1fr;
  }
}