/* ═══════════════════════════════════════════════════════════════
   QUANTIORI — Design System
   Dark luxury + precision data aesthetic
   Fonts: Clash Display (headings) + DM Sans (body)
═══════════════════════════════════════════════════════════════ */

@import url('https://fonts.googleapis.com/css2?family=DM+Sans:ital,opsz,wght@0,9..40,300;0,9..40,400;0,9..40,500;0,9..40,600;1,9..40,300&family=DM+Mono:wght@400;500&display=swap');

:root {
  /* Core palette */
  --bg-void:        #080B0F;
  --bg-deep:        #0D1117;
  --bg-surface:     #141920;
  --bg-elevated:    #1C2430;
  --bg-hover:       #222D3A;

  /* Gold accent system */
  --gold-bright:    #F0C040;
  --gold-mid:       #D4A820;
  --gold-dim:       #A07818;
  --gold-glow:      rgba(240, 192, 64, 0.12);
  --gold-glow-lg:   rgba(240, 192, 64, 0.06);

  /* Text */
  --text-primary:   #EDF2F7;
  --text-secondary: #8A9BB0;
  --text-muted:     #4A5568;
  --text-accent:    #F0C040;

  /* Semantic */
  --green:          #22C55E;
  --green-dim:      rgba(34, 197, 94, 0.12);
  --yellow:         #EAB308;
  --yellow-dim:     rgba(234, 179, 8, 0.12);
  --red:            #EF4444;
  --red-dim:        rgba(239, 68, 68, 0.12);
  --blue:           #3B82F6;
  --blue-dim:       rgba(59, 130, 246, 0.10);

  /* Borders */
  --border:         rgba(255,255,255,0.07);
  --border-gold:    rgba(240, 192, 64, 0.25);
  --border-strong:  rgba(255,255,255,0.12);

  /* Shadows */
  --shadow-card:    0 4px 24px rgba(0,0,0,0.4);
  --shadow-gold:    0 0 40px rgba(240,192,64,0.08);
  --shadow-lg:      0 20px 60px rgba(0,0,0,0.6);

  /* Radius */
  --radius-sm:      6px;
  --radius:         10px;
  --radius-lg:      16px;
  --radius-xl:      24px;

  /* Transitions */
  --transition:     all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

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

html { scroll-behavior: smooth; }

body {
  font-family: 'DM Sans', -apple-system, sans-serif;
  background: var(--bg-void);
  color: var(--text-primary);
  line-height: 1.6;
  font-size: 15px;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* ── Typography ───────────────────────────────────────────────── */
h1,h2,h3,h4,h5,h6 {
  font-family: 'DM Sans', sans-serif;
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.display-title {
  font-size: clamp(2.8rem, 6vw, 5.5rem);
  font-weight: 700;
  letter-spacing: -0.04em;
  line-height: 1.05;
}

.section-title {
  font-size: clamp(1.8rem, 3vw, 2.8rem);
  font-weight: 600;
  letter-spacing: -0.03em;
}

.label-mono {
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.gold { color: var(--gold-bright); }
.green { color: var(--green); }
.red { color: var(--red); }
.muted { color: var(--text-secondary); }

/* ── Layout ───────────────────────────────────────────────────── */
.container {
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 24px;
}

.container-wide {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 32px;
}

section { padding: 96px 0; }

/* ── Navigation ───────────────────────────────────────────────── */
.navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  padding: 0 40px;
  height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(8, 11, 15, 0.85);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  transition: var(--transition);
}

.navbar.scrolled {
  background: rgba(8, 11, 15, 0.97);
  box-shadow: 0 1px 0 var(--border);
}

.navbar-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}

.navbar-logo-mark {
  width: 32px;
  height: 32px;
  background: linear-gradient(135deg, var(--gold-bright), var(--gold-mid));
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 700;
  color: #080B0F;
  font-family: 'DM Mono', monospace;
}

.navbar-logo-text {
  font-size: 17px;
  font-weight: 600;
  color: var(--text-primary);
  letter-spacing: -0.02em;
}

.navbar-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  list-style: none;
}

.navbar-nav a {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  transition: var(--transition);
}

.navbar-nav a:hover { color: var(--text-primary); background: var(--bg-elevated); }
.navbar-nav a.active { color: var(--gold-bright); }

.navbar-actions { display: flex; align-items: center; gap: 10px; }

/* ── Buttons ──────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  border-radius: var(--radius);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  text-decoration: none;
  border: none;
  transition: var(--transition);
  white-space: nowrap;
  font-family: 'DM Sans', sans-serif;
}

.btn-primary {
  background: var(--gold-bright);
  color: #080B0F;
  font-weight: 600;
}
.btn-primary:hover {
  background: #F5CE5A;
  transform: translateY(-1px);
  box-shadow: 0 8px 24px rgba(240,192,64,0.25);
}

.btn-secondary {
  background: var(--bg-elevated);
  color: var(--text-primary);
  border: 1px solid var(--border-strong);
}
.btn-secondary:hover { background: var(--bg-hover); border-color: var(--border-gold); }

.btn-ghost {
  background: transparent;
  color: var(--text-secondary);
}
.btn-ghost:hover { color: var(--text-primary); background: var(--bg-elevated); }

.btn-lg { padding: 14px 28px; font-size: 15px; border-radius: var(--radius-lg); }
.btn-sm { padding: 7px 14px; font-size: 13px; }

/* ── Cards ────────────────────────────────────────────────────── */
.card {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
  transition: var(--transition);
}

.card:hover { border-color: var(--border-strong); }

.card-gold {
  border-color: var(--border-gold);
  background: linear-gradient(135deg, var(--bg-surface), rgba(240,192,64,0.03));
  box-shadow: var(--shadow-gold);
}

.card-elevated {
  background: var(--bg-elevated);
  border-color: var(--border-strong);
  box-shadow: var(--shadow-card);
}

/* ── Prediction Cards ─────────────────────────────────────────── */
.prediction-card {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 20px;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.prediction-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0;
  width: 3px; height: 100%;
  border-radius: 3px 0 0 3px;
}

.prediction-card.tier-green::before { background: var(--green); }
.prediction-card.tier-yellow::before { background: var(--yellow); }
.prediction-card.tier-red::before { background: var(--red); }

.prediction-card:hover {
  border-color: var(--border-strong);
  transform: translateY(-2px);
  box-shadow: var(--shadow-card);
}

/* ── Confidence Badges ────────────────────────────────────────── */
.confidence-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 100px;
  font-family: 'DM Mono', monospace;
  font-size: 12px;
  font-weight: 500;
}

.confidence-badge.green { background: var(--green-dim); color: var(--green); border: 1px solid rgba(34,197,94,0.2); }
.confidence-badge.yellow { background: var(--yellow-dim); color: var(--yellow); border: 1px solid rgba(234,179,8,0.2); }
.confidence-badge.red { background: var(--red-dim); color: var(--red); border: 1px solid rgba(239,68,68,0.2); }

/* ── BET/SKIP Badges ──────────────────────────────────────────── */
.bet-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  border-radius: 100px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  font-family: 'DM Mono', monospace;
}

.bet-badge.bet { background: rgba(240,192,64,0.15); color: var(--gold-bright); border: 1px solid var(--border-gold); }
.bet-badge.skip { background: var(--bg-elevated); color: var(--text-muted); border: 1px solid var(--border); }

/* ── Stats numbers ────────────────────────────────────────────── */
.stat-number {
  font-family: 'DM Mono', monospace;
  font-size: 2.2rem;
  font-weight: 500;
  line-height: 1;
  letter-spacing: -0.03em;
}

.stat-number.positive { color: var(--green); }
.stat-number.negative { color: var(--red); }
.stat-number.gold     { color: var(--gold-bright); }

/* ── Progress bars ────────────────────────────────────────────── */
.progress-bar {
  height: 4px;
  background: var(--bg-elevated);
  border-radius: 100px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  border-radius: 100px;
  transition: width 1s cubic-bezier(0.4, 0, 0.2, 1);
}

.progress-fill.green { background: linear-gradient(90deg, var(--green), #4ADE80); }
.progress-fill.gold  { background: linear-gradient(90deg, var(--gold-mid), var(--gold-bright)); }
.progress-fill.red   { background: linear-gradient(90deg, var(--red), #F87171); }

/* ── Tables ───────────────────────────────────────────────────── */
.data-table { width: 100%; border-collapse: collapse; }

.data-table th {
  text-align: left;
  padding: 10px 16px;
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
  border-bottom: 1px solid var(--border);
}

.data-table td {
  padding: 14px 16px;
  border-bottom: 1px solid var(--border);
  font-size: 14px;
  color: var(--text-secondary);
}

.data-table tr:hover td { background: var(--bg-elevated); color: var(--text-primary); }
.data-table tr:last-child td { border-bottom: none; }

/* ── Forms ────────────────────────────────────────────────────── */
.form-group { margin-bottom: 20px; }

.form-label {
  display: block;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

.form-input {
  width: 100%;
  padding: 11px 16px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text-primary);
  font-size: 14px;
  font-family: 'DM Sans', sans-serif;
  transition: var(--transition);
  outline: none;
}

.form-input:focus {
  border-color: var(--gold-mid);
  box-shadow: 0 0 0 3px var(--gold-glow);
}

.form-input::placeholder { color: var(--text-muted); }

select.form-input { cursor: pointer; }

/* ── Sidebar (dashboard) ──────────────────────────────────────── */
.dashboard-layout {
  display: flex;
  min-height: 100vh;
  padding-top: 68px;
}

.sidebar {
  width: 240px;
  flex-shrink: 0;
  background: var(--bg-deep);
  border-right: 1px solid var(--border);
  padding: 24px 16px;
  position: fixed;
  top: 68px;
  bottom: 0;
  overflow-y: auto;
}

.sidebar-section-label {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
  padding: 8px 12px 6px;
  margin-top: 8px;
}

.sidebar-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  border-radius: var(--radius);
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  transition: var(--transition);
  margin-bottom: 2px;
}

.sidebar-link:hover { background: var(--bg-elevated); color: var(--text-primary); }
.sidebar-link.active { background: var(--gold-glow); color: var(--gold-bright); border: 1px solid var(--border-gold); }
.sidebar-link svg { opacity: 0.6; flex-shrink: 0; }
.sidebar-link.active svg { opacity: 1; }

.main-content {
  flex: 1;
  margin-left: 240px;
  padding: 32px;
  min-width: 0;
}

/* ── Alerts ───────────────────────────────────────────────────── */
.alert {
  padding: 12px 16px;
  border-radius: var(--radius);
  font-size: 14px;
  margin-bottom: 16px;
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.alert-success { background: var(--green-dim); border: 1px solid rgba(34,197,94,0.2); color: #86EFAC; }
.alert-error   { background: var(--red-dim);   border: 1px solid rgba(239,68,68,0.2);  color: #FCA5A5; }
.alert-warning { background: var(--yellow-dim); border: 1px solid rgba(234,179,8,0.2); color: #FDE047; }
.alert-info    { background: var(--blue-dim);   border: 1px solid rgba(59,130,246,0.2); color: #93C5FD; }

/* ── Pricing cards ────────────────────────────────────────────── */
.pricing-card {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 32px;
  transition: var(--transition);
  position: relative;
}

.pricing-card.featured {
  border-color: var(--border-gold);
  background: linear-gradient(160deg, var(--bg-surface), rgba(240,192,64,0.04));
  box-shadow: 0 0 60px rgba(240,192,64,0.07);
}

.pricing-card .price {
  font-family: 'DM Mono', monospace;
  font-size: 2.8rem;
  font-weight: 500;
  line-height: 1;
  color: var(--text-primary);
  letter-spacing: -0.04em;
}

.pricing-card .price sup {
  font-size: 1.2rem;
  vertical-align: top;
  margin-top: 8px;
  color: var(--text-secondary);
}

.pricing-card .price-period {
  font-size: 13px;
  color: var(--text-muted);
  margin-left: 4px;
}

.pricing-feature {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 14px;
  color: var(--text-secondary);
  padding: 7px 0;
}

.pricing-feature svg { color: var(--green); flex-shrink: 0; margin-top: 2px; }
.pricing-feature.locked { opacity: 0.4; }
.pricing-feature.locked svg { color: var(--text-muted); }

/* ── Hero section ─────────────────────────────────────────────── */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-top: 68px;
  position: relative;
  overflow: hidden;
}

.hero-grid-bg {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(240,192,64,0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(240,192,64,0.03) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse 80% 60% at 50% 40%, black, transparent);
}

.hero-glow {
  position: absolute;
  top: 20%;
  left: 50%;
  transform: translateX(-50%);
  width: 600px;
  height: 400px;
  background: radial-gradient(ellipse, rgba(240,192,64,0.07) 0%, transparent 70%);
  pointer-events: none;
}

/* ── Bankroll simulator ───────────────────────────────────────── */
.simulator-chart {
  height: 120px;
  position: relative;
  overflow: hidden;
}

.simulator-chart svg { width: 100%; height: 100%; }

/* ── Tags ─────────────────────────────────────────────────────── */
.tag {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  border-radius: 100px;
  font-size: 12px;
  font-weight: 500;
  background: var(--bg-elevated);
  color: var(--text-secondary);
  border: 1px solid var(--border);
}

.tag-gold { background: var(--gold-glow); color: var(--gold-bright); border-color: var(--border-gold); }

/* ── Dividers ─────────────────────────────────────────────────── */
.divider {
  height: 1px;
  background: var(--border);
  margin: 24px 0;
}

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

/* ── Responsive ───────────────────────────────────────────────── */
@media (max-width: 1024px) {
  .sidebar { display: none; }
  .main-content { margin-left: 0; }
}

@media (max-width: 768px) {
  .navbar { padding: 0 20px; }
  .navbar-nav { display: none; }
  section { padding: 64px 0; }
  .container { padding: 0 16px; }
}


}

/* Hero layout */
.hero-grid {
  display: grid;
  grid-template-columns: 1fr 380px;
  gap: 48px;
  align-items: center;
}
@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr !important; }
  .hero-cards-col { display: none !important; }
  .sim-grid { grid-template-columns: 1fr !important; }
  .pricing-grid { grid-template-columns: 1fr !important; max-width: 400px !important; margin: 0 auto !important; }
  .data-table th:nth-child(3), .data-table td:nth-child(3) { display: none; }
}

/* ── Dashboard Mobile ─────────────────────────────────────────── */
@media (max-width: 768px) {
  .main-content { padding: 16px !important; }
  .main-content > div { padding-left: 0 !important; padding-right: 0 !important; }

  /* Grids: forțăm 1-2 coloane */
  .main-content div[style*="grid-template-columns: repeat(4"] { grid-template-columns: repeat(2, 1fr) !important; gap: 8px !important; }
  .main-content div[style*="grid-template-columns:repeat(4"] { grid-template-columns: repeat(2, 1fr) !important; gap: 8px !important; }
  .main-content div[style*="grid-template-columns: repeat(3"] { grid-template-columns: 1fr !important; gap: 8px !important; }
  .main-content div[style*="grid-template-columns:repeat(3"] { grid-template-columns: 1fr !important; gap: 8px !important; }
  .main-content div[style*="grid-template-columns: 1fr 1fr"] { grid-template-columns: 1fr !important; gap: 12px !important; }
  .main-content div[style*="grid-template-columns:1fr 1fr"] { grid-template-columns: 1fr !important; gap: 12px !important; }

  /* Cards mai compacte */
  .main-content .card { padding: 12px !important; }
  .main-content .card .stat-number { font-size: 1.2rem !important; }

  /* Tabele scrollabile */
  .main-content .card:has(table), .main-content div:has(> table) { overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .main-content table { min-width: 500px; }
  .data-table th, .data-table td { padding: 8px 10px !important; font-size: 12px !important; }

  /* Header flex wrap */
  .main-content div[style*="justify-content:space-between"] { flex-wrap: wrap; gap: 8px; }

  /* Titluri mai mici */
  .main-content h1 { font-size: 1.2rem !important; }
  .main-content h3 { font-size: 14px !important; }

  /* Chart container */
  .main-content canvas { max-height: 180px !important; }

  /* Modal responsive */
  #add-bet-modal > div { width: 95% !important; max-height: 90vh; overflow-y: auto; padding: 20px !important; }
  #add-bet-modal div[style*="grid-template-columns:1fr 1fr 1fr"] { grid-template-columns: 1fr 1fr !important; }
  #add-bet-modal div[style*="grid-template-columns:1fr 1fr"] { grid-template-columns: 1fr !important; }

  /* Prediction cards */
  .main-content .prediction-card { padding: 12px !important; }
}

@media (max-width: 480px) {
  .main-content div[style*="grid-template-columns: repeat(4"] { grid-template-columns: 1fr 1fr !important; }
  .main-content div[style*="grid-template-columns:repeat(4"] { grid-template-columns: 1fr 1fr !important; }
  .main-content div[style*="grid-template-columns: repeat(2"] { grid-template-columns: 1fr 1fr !important; }
  .main-content div[style*="grid-template-columns:repeat(2"] { grid-template-columns: 1fr 1fr !important; }
  .main-content table { min-width: 400px; }
}
