/* NovaBet Gaming Platform - Styles */
/* Build: v2.0.0 */

/* ── Reset & Base ── */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  line-height: 1.6;
  color: #f0f0f0;
  background: #0a0e27;
  min-height: 100vh;
}
a { color: #00cec9; text-decoration: none; transition: color 0.2s; }
a:hover { color: #6c5ce7; }
img { max-width: 100%; }

/* ── Layout ── */
.container { max-width: 1140px; margin: 0 auto; padding: 0 20px; }
.page { display: flex; flex-direction: column; min-height: 100vh; }
main { flex: 1; padding-top: 70px; }

/* ── Navbar ── */
.navbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  background: rgba(13, 17, 48, 0.95);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid #2d3154;
  height: 64px;
}
.navbar .container {
  display: flex; align-items: center; justify-content: space-between; height: 100%;
}
.logo {
  font-size: 22px; font-weight: 800; color: #fff !important;
  letter-spacing: -0.5px;
}
.logo span { color: #6c5ce7; }
.nav-links { display: flex; gap: 28px; align-items: center; }
.nav-links a {
  color: #8a8a9e; font-size: 14px; font-weight: 500;
  transition: color 0.2s;
  position: relative;
}
.nav-links a:hover, .nav-links a.active { color: #f0f0f0; }
.nav-links a.active::after {
  content: ''; position: absolute; bottom: -4px; left: 0; right: 0;
  height: 2px; background: #6c5ce7; border-radius: 1px;
}
.nav-user { display: flex; align-items: center; gap: 16px; }
.nav-balance {
  color: #00cec9; font-weight: 600; font-size: 14px;
  background: rgba(0, 206, 201, 0.1);
  padding: 6px 14px; border-radius: 20px;
  border: 1px solid rgba(0, 206, 201, 0.2);
}
.nav-btn {
  background: #6c5ce7; color: #fff; border: none;
  padding: 8px 20px; border-radius: 8px; font-size: 14px;
  font-weight: 600; cursor: pointer; transition: all 0.2s;
}
.nav-btn:hover { background: #5a4bd1; transform: translateY(-1px); }
.nav-btn.outline {
  background: transparent; border: 1px solid #2d3154; color: #8a8a9e;
}
.nav-btn.outline:hover { border-color: #6c5ce7; color: #f0f0f0; }

/* ── Hero ── */
.hero {
  padding: 100px 0 80px;
  background: linear-gradient(180deg, #0a0e27 0%, #141834 50%, #0a0e27 100%);
  text-align: center;
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute; top: 50%; left: 50%;
  width: 600px; height: 600px;
  background: radial-gradient(circle, rgba(108, 92, 231, 0.15) 0%, transparent 70%);
  transform: translate(-50%, -50%);
  pointer-events: none;
}
.hero h1 {
  font-size: 52px; font-weight: 800; letter-spacing: -1px;
  margin-bottom: 16px; position: relative;
  background: linear-gradient(135deg, #fff 0%, #00cec9 100%);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  background-clip: text;
}
.hero p {
  font-size: 18px; color: #8a8a9e; margin-bottom: 36px;
  max-width: 500px; margin-left: auto; margin-right: auto;
}
.cta-btn {
  display: inline-block;
  background: linear-gradient(135deg, #6c5ce7, #a855f7);
  color: #fff !important; padding: 14px 40px;
  border-radius: 12px; font-size: 16px; font-weight: 700;
  transition: all 0.3s; border: none; cursor: pointer;
  text-decoration: none;
  box-shadow: 0 4px 24px rgba(108, 92, 231, 0.3);
}
.cta-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(108, 92, 231, 0.5);
}

/* ── Section ── */
.section { padding: 60px 0; }
.section-title {
  font-size: 28px; font-weight: 700; margin-bottom: 32px;
  padding-bottom: 12px;
  border-bottom: 2px solid #2d3154;
}
.section-subtitle { color: #8a8a9e; font-size: 15px; margin-top: -24px; margin-bottom: 32px; }

/* ── Cards ── */
.card {
  background: #141834;
  border: 1px solid #2d3154;
  border-radius: 12px;
  padding: 24px;
  transition: all 0.25s;
}
.card:hover {
  border-color: #6c5ce7;
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
}

/* ── Game Cards ── */
.game-card { position: relative; overflow: hidden; }
.game-card .game-icon {
  width: 48px; height: 48px; border-radius: 12px;
  background: linear-gradient(135deg, #6c5ce7, #a855f7);
  display: flex; align-items: center; justify-content: center;
  font-size: 24px; margin-bottom: 16px;
}
.game-card h3 { font-size: 18px; font-weight: 700; margin-bottom: 8px; }
.game-card p { color: #8a8a9e; font-size: 14px; margin-bottom: 16px; line-height: 1.5; }
.game-card .play-btn {
  display: inline-block; background: #6c5ce7; color: #fff;
  padding: 8px 24px; border-radius: 8px; font-size: 13px;
  font-weight: 600; border: none; cursor: pointer; transition: all 0.2s;
}
.game-card .play-btn:hover { background: #5a4bd1; }

/* ── Stat Cards ── */
.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 20px; margin-bottom: 40px; }
.stat-card {
  background: #141834; border: 1px solid #2d3154;
  border-radius: 12px; padding: 20px;
}
.stat-card .stat-label { font-size: 12px; color: #8a8a9e; text-transform: uppercase; letter-spacing: 1px; margin-bottom: 8px; }
.stat-card .stat-value { font-size: 28px; font-weight: 700; }
.stat-card .stat-value.teal { color: #00cec9; }
.stat-card .stat-value.purple { color: #6c5ce7; }
.stat-card .stat-value.green { color: #00b894; }

/* ── Badge ── */
.badge {
  display: inline-block; padding: 3px 10px; border-radius: 20px;
  font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.5px;
}
.badge-active { background: rgba(0, 184, 148, 0.15); color: #00b894; }
.badge-win { background: rgba(0, 184, 148, 0.15); color: #00b894; }
.badge-lose { background: rgba(214, 48, 49, 0.15); color: #d63031; }
.badge-deposit { background: rgba(0, 184, 148, 0.15); color: #00b894; }
.badge-withdrawal { background: rgba(214, 48, 49, 0.15); color: #d63031; }
.badge-bet { background: rgba(108, 92, 231, 0.15); color: #6c5ce7; }
.badge-pending { background: rgba(253, 203, 110, 0.15); color: #fdcb6e; }

/* ── Forms ── */
.form-container {
  max-width: 420px; margin: 0 auto;
  background: #141834; border: 1px solid #2d3154;
  border-radius: 16px; padding: 36px;
}
.form-container h2 { font-size: 24px; font-weight: 700; margin-bottom: 8px; text-align: center; }
.form-container .form-subtitle { color: #8a8a9e; font-size: 14px; text-align: center; margin-bottom: 28px; }
.form-group { margin-bottom: 20px; }
.form-label {
  display: block; font-size: 13px; font-weight: 600;
  color: #8a8a9e; margin-bottom: 6px; text-transform: uppercase;
  letter-spacing: 0.5px;
}
.form-input {
  width: 100%; padding: 12px 16px;
  background: #0d1130; border: 1px solid #2d3154;
  border-radius: 10px; color: #f0f0f0; font-size: 15px;
  transition: border-color 0.2s;
  font-family: inherit;
}
.form-input:focus { outline: none; border-color: #6c5ce7; }
.form-input::placeholder { color: #4a4a6a; }
.form-btn {
  width: 100%; padding: 14px;
  background: linear-gradient(135deg, #6c5ce7, #a855f7);
  color: #fff; border: none; border-radius: 10px;
  font-size: 15px; font-weight: 700; cursor: pointer;
  transition: all 0.2s;
}
.form-btn:hover { transform: translateY(-1px); box-shadow: 0 4px 20px rgba(108, 92, 231, 0.4); }
.form-btn:disabled { opacity: 0.5; cursor: not-allowed; transform: none; }
.form-error {
  color: #d63031; font-size: 13px; margin-top: 8px;
  padding: 8px 12px; background: rgba(214, 48, 49, 0.1);
  border-radius: 8px; display: none;
}
.form-error.visible { display: block; }
.form-success {
  color: #00b894; font-size: 13px; margin-top: 8px;
  padding: 8px 12px; background: rgba(0, 184, 148, 0.1);
  border-radius: 8px; display: none;
}
.form-success.visible { display: block; }

/* ── Tables ── */
.table-wrap { overflow-x: auto; border-radius: 12px; border: 1px solid #2d3154; }
.tx-table {
  width: 100%; border-collapse: collapse;
  font-size: 14px;
}
.tx-table th {
  text-align: left; padding: 14px 16px;
  font-size: 11px; text-transform: uppercase; letter-spacing: 1px;
  color: #8a8a9e; background: #0d1130;
  border-bottom: 1px solid #2d3154;
  font-weight: 600;
}
.tx-table td {
  padding: 14px 16px; border-bottom: 1px solid #1a1f40;
}
.tx-table tr:last-child td { border-bottom: none; }
.tx-table tr:nth-child(even) td { background: rgba(13, 17, 48, 0.5); }
.tx-table tr:hover td { background: rgba(108, 92, 231, 0.05); }
.amount-positive { color: #00b894; }
.amount-negative { color: #d63031; }

/* ── Pagination ── */
.pagination { display: flex; gap: 8px; justify-content: center; margin-top: 24px; }
.pagination button {
  background: #141834; border: 1px solid #2d3154;
  color: #f0f0f0; padding: 8px 16px; border-radius: 8px;
  cursor: pointer; font-size: 13px; transition: all 0.2s;
}
.pagination button:hover { border-color: #6c5ce7; }
.pagination button.active { background: #6c5ce7; border-color: #6c5ce7; }
.pagination button:disabled { opacity: 0.3; cursor: not-allowed; }

/* ── Profile ── */
.profile-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.profile-field { margin-bottom: 16px; }
.profile-field .field-label { font-size: 12px; color: #8a8a9e; text-transform: uppercase; letter-spacing: 1px; margin-bottom: 4px; }
.profile-field .field-value { font-size: 16px; font-weight: 500; }

/* ── Balance Display ── */
.balance-display {
  font-size: 42px; font-weight: 800; color: #00cec9;
  margin-bottom: 8px;
}
.balance-label { font-size: 13px; color: #8a8a9e; text-transform: uppercase; letter-spacing: 1px; }

/* ── Result Modal ── */
.result-overlay {
  position: fixed; top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(10, 14, 39, 0.85); z-index: 200;
  display: flex; align-items: center; justify-content: center;
  backdrop-filter: blur(8px);
}
.result-card {
  background: #141834; border: 1px solid #2d3154;
  border-radius: 20px; padding: 48px; text-align: center;
  max-width: 400px; width: 90%;
  animation: slideUp 0.3s ease;
}
.result-card h2 { font-size: 32px; margin-bottom: 12px; }
.result-card .result-amount { font-size: 36px; font-weight: 800; margin: 16px 0; }
.result-card button { margin-top: 20px; }

/* ── Footer ── */
.footer {
  border-top: 1px solid #2d3154;
  padding: 24px 0;
  margin-top: auto;
}
.footer .container {
  display: flex; justify-content: space-between; align-items: center;
}
.footer p { color: #8a8a9e; font-size: 13px; }
.footer-links { display: flex; gap: 20px; }
.footer-links a { color: #8a8a9e; font-size: 13px; }
.footer-links a:hover { color: #f0f0f0; }

/* ── FAQ ── */
.faq-list { max-width: 800px; margin: 0 auto; }
.faq-item {
  border: 1px solid #2d3154; border-radius: 12px;
  margin-bottom: 12px; overflow: hidden;
  background: #141834; transition: border-color 0.2s;
}
.faq-item:hover { border-color: #3d4174; }
.faq-question {
  padding: 20px 24px; cursor: pointer;
  display: flex; justify-content: space-between; align-items: center;
  font-weight: 600; font-size: 16px;
  user-select: none;
}
.faq-question::after {
  content: '+'; font-size: 20px; color: #8a8a9e;
  transition: transform 0.3s;
  flex-shrink: 0; margin-left: 16px;
}
.faq-item.open .faq-question::after { content: '\2212'; color: #6c5ce7; }
.faq-answer {
  max-height: 0; overflow: hidden;
  transition: max-height 0.3s ease, padding 0.3s ease;
  padding: 0 24px;
  color: #8a8a9e; font-size: 15px; line-height: 1.7;
}
.faq-item.open .faq-answer {
  max-height: 200px;
  padding: 0 24px 20px;
}

/* ── Legal / Terms ── */
.legal-content { max-width: 800px; margin: 0 auto; padding: 40px 0; }
.legal-content h1 { font-size: 32px; font-weight: 700; margin-bottom: 32px; }
.legal-content h2 {
  font-size: 20px; font-weight: 600; margin-top: 36px; margin-bottom: 12px;
  color: #f0f0f0;
}
.legal-content p {
  color: #8a8a9e; font-size: 15px; line-height: 1.8; margin-bottom: 16px;
}
.legal-content .last-updated { color: #6c5ce7; font-size: 13px; margin-top: 40px; }

/* ── About ── */
.about-content { max-width: 800px; margin: 0 auto; padding: 40px 0; }
.about-content h1 { font-size: 36px; font-weight: 700; margin-bottom: 16px; }
.about-content .lead { font-size: 18px; color: #8a8a9e; margin-bottom: 40px; line-height: 1.7; }
.about-content h2 { font-size: 22px; font-weight: 600; margin-top: 40px; margin-bottom: 16px; }
.about-content p { color: #c0c0d0; font-size: 15px; line-height: 1.8; margin-bottom: 16px; }
.feature-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 20px; margin-top: 24px; }
.feature-item {
  background: #141834; border: 1px solid #2d3154;
  border-radius: 12px; padding: 24px; text-align: center;
}
.feature-item .feat-icon { font-size: 32px; margin-bottom: 12px; }
.feature-item h3 { font-size: 16px; font-weight: 600; margin-bottom: 8px; }
.feature-item p { font-size: 13px; color: #8a8a9e; }

/* ── Utilities ── */
.hidden { display: none !important; }
.text-center { text-align: center; }
.text-muted { color: #8a8a9e; }
.text-success { color: #00b894; }
.text-danger { color: #d63031; }
.mt-1 { margin-top: 8px; }
.mt-2 { margin-top: 16px; }
.mt-3 { margin-top: 24px; }
.mt-4 { margin-top: 32px; }
.mb-1 { margin-bottom: 8px; }
.mb-2 { margin-bottom: 16px; }
.mb-3 { margin-bottom: 24px; }
.mb-4 { margin-bottom: 32px; }
.flex-between { display: flex; justify-content: space-between; align-items: center; }

/* ── Animations ── */
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes slideUp { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }
.fade-in { animation: fadeIn 0.4s ease; }
.slide-up { animation: slideUp 0.4s ease; }

/* ── Live indicator + live stats (homepage hero) ── */
.live-indicator {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 10px; margin-bottom: 16px;
  background: rgba(239, 68, 68, 0.12); color: #ef4444;
  border: 1px solid rgba(239, 68, 68, 0.35); border-radius: 999px;
  font-size: 12px; font-weight: 600; letter-spacing: 0.08em;
}
.live-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: #ef4444; box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.6);
  animation: livePulse 1.6s ease-out infinite;
}
@keyframes livePulse {
  0%   { box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.6); }
  70%  { box-shadow: 0 0 0 8px rgba(239, 68, 68, 0); }
  100% { box-shadow: 0 0 0 0 rgba(239, 68, 68, 0); }
}
.live-stats { margin-top: 18px; font-size: 14px; opacity: 0.85; }
.live-stats span + span::before { content: " · "; opacity: 0.5; }

/* ── Notification toasts (driven by /api/notifications/stream) ── */
.toast {
  position: fixed; right: 20px; bottom: 20px;
  max-width: 340px; padding: 12px 16px;
  background: #1f2937; color: #f9fafb;
  border: 1px solid #374151; border-radius: 8px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.25);
  font-size: 14px; line-height: 1.4;
  animation: slideUp 0.3s ease;
  z-index: 1000;
}

/* ── Feature list on /about ── */
.feature-list { list-style: disc inside; line-height: 1.9; }
.feature-list code {
  background: rgba(255,255,255,0.08); padding: 2px 6px; border-radius: 4px;
  font-size: 13px;
}

/* ── Responsive ── */
@media (max-width: 768px) {
  .hero h1 { font-size: 32px; }
  .hero p { font-size: 16px; }
  .card-grid { grid-template-columns: 1fr; }
  .stat-grid { grid-template-columns: 1fr; }
  .profile-grid { grid-template-columns: 1fr; }
  .nav-links { gap: 16px; }
  .navbar .container { padding: 0 16px; }
  .footer .container { flex-direction: column; gap: 12px; text-align: center; }
  .balance-display { font-size: 32px; }
  .form-container { padding: 24px; }
}
@media (max-width: 480px) {
  .nav-links { display: none; }
  .hero h1 { font-size: 28px; }
  .section-title { font-size: 22px; }
}
