/* Global Styles - Random Number Lottery Platform */

/* Import modern system fonts */
@import url("https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap");

:root {
  --color-bg: #111111;
  --color-bg-alt: #141414;
  --color-card: rgba(24, 24, 24, 0.9);
  --color-primary: #ff7a00;
  --color-primary-soft: rgba(255, 122, 0, 0.16);
  --color-accent: #38bdf8;
  --color-accent-soft: rgba(56, 189, 248, 0.12);
  --color-text: #ffffff;
  --color-text-muted: #9ca3af;
  --color-border: rgba(148, 163, 184, 0.25);
  --color-success: #22c55e;
  --color-danger: #ef4444;
  --color-warning: #facc15;

  --radius-lg: 18px;
  --radius-md: 12px;
  --radius-pill: 999px;

  --shadow-soft: 0 18px 45px rgba(0, 0, 0, 0.65);
  --shadow-neon-orange: 0 0 18px rgba(255, 122, 0, 0.75);
  --shadow-neon-sky: 0 0 18px rgba(56, 189, 248, 0.7);

  --transition-fast: 150ms ease-out;
  --transition-base: 220ms ease-out;
  --transition-slow: 320ms ease-out;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  width: 100%;
  height: 100%;
}

body {
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  background: radial-gradient(circle at top, #1f2937 0, #020617 40%, #000000 80%);
  color: var(--color-text);
  -webkit-font-smoothing: antialiased;
}

/* Subtle animated background grid for gaming feel */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image: linear-gradient(
      rgba(148, 163, 184, 0.07) 1px,
      transparent 1px
    ),
    linear-gradient(
      90deg,
      rgba(148, 163, 184, 0.07) 1px,
      transparent 1px
    );
  background-size: 80px 80px;
  opacity: 0.7;
  pointer-events: none;
  z-index: -2;
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  background: radial-gradient(
      circle at 10% 0,
      rgba(255, 122, 0, 0.12),
      transparent 55%
    ),
    radial-gradient(
      circle at 90% 100%,
      rgba(56, 189, 248, 0.16),
      transparent 55%
    );
  mix-blend-mode: screen;
  opacity: 0.85;
  pointer-events: none;
  z-index: -1;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  max-width: 100%;
  display: block;
}

button {
  font-family: inherit;
}

/* Layout Wrappers */

.app-shell {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.app-main {
  flex: 1;
  display: flex;
}

.app-content {
  flex: 1;
  padding: 24px;
  max-width: 1200px;
  margin: 0 auto;
}

@media (max-width: 768px) {
  .app-content {
    padding: 16px;
  }
}

/* Top Navigation (shared across app pages) */

.top-nav {
  position: sticky;
  top: 0;
  z-index: 40;
  backdrop-filter: blur(18px);
  background: linear-gradient(
    90deg,
    rgba(15, 23, 42, 0.95),
    rgba(15, 23, 42, 0.7),
    rgba(15, 23, 42, 0.95)
  );
  border-bottom: 1px solid rgba(148, 163, 184, 0.35);
}

.top-nav-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 12px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
}

.brand-logo {
  width: 34px;
  height: 34px;
  border-radius: 14px;
  background: radial-gradient(circle at 30% 0, #ffe4c7, #ff7a00 55%, #e65100);
  box-shadow: var(--shadow-neon-orange);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 18px;
  color: #111827;
}

.brand-text-main {
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-size: 14px;
}

.brand-text-sub {
  font-size: 11px;
  text-transform: uppercase;
  color: var(--color-text-muted);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 13px;
}

.nav-link {
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid transparent;
  color: var(--color-text-muted);
  transition: background var(--transition-base),
    color var(--transition-base),
    border-color var(--transition-base),
    transform var(--transition-fast);
}

.nav-link:hover {
  background: rgba(15, 23, 42, 0.9);
  color: var(--color-text);
  border-color: rgba(148, 163, 184, 0.45);
  transform: translateY(-1px);
}

.nav-link-active {
  background: linear-gradient(135deg, #ff7a00, #ea580c);
  color: #111827;
  font-weight: 600;
  box-shadow: var(--shadow-neon-orange);
}

.nav-cta {
  display: flex;
  align-items: center;
  gap: 10px;
}

.pill-badge {
  border-radius: 999px;
  padding: 4px 10px;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  border: 1px solid rgba(148, 163, 184, 0.45);
  color: var(--color-text-muted);
}

.btn {
  border-radius: var(--radius-pill);
  padding: 8px 18px;
  border: none;
  cursor: pointer;
  font-size: 13px;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: transform var(--transition-fast),
    box-shadow var(--transition-fast),
    background var(--transition-fast),
    color var(--transition-fast);
}

.btn-primary {
  background: radial-gradient(circle at 30% 0, #ffe4c7, #ff7a00 45%, #b45309);
  color: #111827;
  box-shadow: var(--shadow-neon-orange);
}

.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 0 0 1px rgba(248, 250, 252, 0.1),
    0 0 32px rgba(255, 122, 0, 0.95);
}

.btn-ghost {
  background: rgba(15, 23, 42, 0.95);
  color: var(--color-text-muted);
  border: 1px solid rgba(148, 163, 184, 0.45);
}

.btn-ghost:hover {
  color: var(--color-text);
  border-color: rgba(248, 250, 252, 0.65);
  box-shadow: 0 0 0 1px rgba(15, 23, 42, 0.9),
    0 0 24px rgba(56, 189, 248, 0.8);
}

.btn-sm {
  padding: 6px 14px;
  font-size: 12px;
}

.btn-block {
  width: 100%;
  justify-content: center;
}

.btn-outline-accent {
  border-radius: var(--radius-pill);
  border: 1px solid rgba(56, 189, 248, 0.7);
  background: rgba(15, 23, 42, 0.85);
  color: var(--color-text);
  box-shadow: 0 0 18px rgba(56, 189, 248, 0.55);
}

.btn-outline-accent:hover {
  background: radial-gradient(circle at 20% 0, #e0f2fe, #38bdf8 40%, #0369a1);
  color: #02131f;
  box-shadow: 0 0 32px rgba(56, 189, 248, 0.95);
}

/* Auth Layout */

.auth-wrapper {
  max-width: 420px;
  margin: 40px auto;
}

.card {
  background: linear-gradient(
      135deg,
      rgba(15, 23, 42, 0.96),
      rgba(15, 23, 42, 0.98)
    ),
    radial-gradient(circle at 0 0, rgba(255, 122, 0, 0.16), transparent 55%);
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-soft);
  padding: 22px 22px 20px;
  position: relative;
  overflow: hidden;
}

.card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(
    circle at 10% -10%,
    rgba(255, 122, 0, 0.14),
    transparent 50%
  );
  opacity: 0.8;
  pointer-events: none;
}

.card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(
    circle at 100% 120%,
    rgba(56, 189, 248, 0.2),
    transparent 55%
  );
  mix-blend-mode: screen;
  opacity: 0.7;
  pointer-events: none;
}

.card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.card-title {
  font-size: 20px;
  font-weight: 600;
}

.card-subtitle {
  font-size: 12px;
  color: var(--color-text-muted);
}

.tag-soft {
  border-radius: var(--radius-pill);
  padding: 4px 10px;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  background: rgba(15, 23, 42, 0.9);
  border: 1px solid rgba(148, 163, 184, 0.6);
}

.form-group {
  margin-bottom: 14px;
}

.form-label {
  font-size: 12px;
  color: var(--color-text-muted);
  margin-bottom: 6px;
  display: block;
}

.form-control {
  width: 100%;
  padding: 9px 11px;
  border-radius: 10px;
  border: 1px solid rgba(148, 163, 184, 0.6);
  background: rgba(15, 23, 42, 0.92);
  color: var(--color-text);
  font-size: 13px;
  transition: border-color var(--transition-base),
    box-shadow var(--transition-base),
    background var(--transition-base),
    transform var(--transition-fast);
}

.form-control::placeholder {
  color: rgba(148, 163, 184, 0.7);
}

.form-control:focus {
  outline: none;
  border-color: rgba(56, 189, 248, 0.9);
  box-shadow: 0 0 0 1px rgba(15, 23, 42, 0.9),
    0 0 28px rgba(56, 189, 248, 0.9);
  background: rgba(15, 23, 42, 0.98);
  transform: translateY(-1px);
}

.form-row {
  display: flex;
  gap: 12px;
}

.form-row .form-group {
  flex: 1;
}

.helper-text {
  font-size: 11px;
  color: var(--color-text-muted);
}

.link-soft {
  color: var(--color-accent);
  cursor: pointer;
}

.link-soft:hover {
  text-decoration: underline;
}

.text-center {
  text-align: center;
}

.mt-2 {
  margin-top: 8px;
}

.mt-3 {
  margin-top: 12px;
}

.mt-4 {
  margin-top: 16px;
}

.mt-6 {
  margin-top: 24px;
}

.mb-0 {
  margin-bottom: 0;
}

.badge-level {
  border-radius: var(--radius-pill);
  padding: 4px 9px;
  font-size: 11px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  border: 1px solid rgba(148, 163, 184, 0.7);
  background: radial-gradient(
    circle at 0 0,
    rgba(56, 189, 248, 0.2),
    rgba(15, 23, 42, 0.96)
  );
}

.badge-level.bronze {
  border-color: #f97316;
}

.badge-level.silver {
  border-color: #e5e7eb;
}

.badge-level.gold {
  border-color: #facc15;
}

.badge-level.platinum {
  border-color: #e5e7eb;
}

.badge-level.diamond {
  border-color: #38bdf8;
}

/* Landing Hero */

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 3fr) minmax(0, 2.5fr);
  gap: 28px;
  align-items: center;
  margin-top: 32px;
}

.hero-headline {
  font-size: 32px;
  line-height: 1.25;
  font-weight: 700;
}

.hero-gradient {
  background: linear-gradient(135deg, #f97316, #facc15, #38bdf8);
  -webkit-background-clip: text;
  color: transparent;
}

.hero-subcopy {
  margin-top: 12px;
  font-size: 14px;
  color: var(--color-text-muted);
  max-width: 460px;
}

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
}

.hero-meta-pill {
  border-radius: var(--radius-pill);
  padding: 5px 11px;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  border: 1px dashed rgba(148, 163, 184, 0.5);
  color: var(--color-text-muted);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.hero-cta-row {
  margin-top: 18px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.hero-note {
  font-size: 11px;
  color: var(--color-text-muted);
}

.hero-card {
  position: relative;
  padding: 20px 18px;
  border-radius: 18px;
  background: linear-gradient(
      135deg,
      rgba(15, 23, 42, 0.98),
      rgba(17, 24, 39, 0.96)
    ),
    linear-gradient(135deg, rgba(56, 189, 248, 0.4), transparent 50%);
  border: 1px solid rgba(148, 163, 184, 0.4);
  box-shadow: 0 0 0 1px rgba(15, 23, 42, 0.6), var(--shadow-soft);
}

.hero-card-ribbon {
  position: absolute;
  top: 14px;
  right: 18px;
  padding: 4px 10px;
  font-size: 11px;
  border-radius: var(--radius-pill);
  background: radial-gradient(circle at 0 0, #f97316, #ea580c);
  color: #111827;
  font-weight: 600;
  box-shadow: var(--shadow-neon-orange);
}

.hero-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
}

.hero-card-title {
  font-size: 15px;
  font-weight: 600;
}

.hero-card-subtitle {
  font-size: 12px;
  color: var(--color-text-muted);
}

.hero-card-metric-row {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}

.metric-chip {
  flex: 1;
  border-radius: 14px;
  padding: 10px 12px;
  background: radial-gradient(
    circle at 0 0,
    rgba(56, 189, 248, 0.22),
    rgba(15, 23, 42, 0.96)
  );
  border: 1px solid rgba(56, 189, 248, 0.5);
}

.metric-chip-label {
  font-size: 11px;
  color: var(--color-text-muted);
}

.metric-chip-value {
  margin-top: 2px;
  font-weight: 600;
  font-size: 15px;
}

.metric-chip-sub {
  font-size: 11px;
  color: var(--color-text-muted);
}

.hero-countdown {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 8px;
  font-size: 12px;
  color: var(--color-text-muted);
}

.countdown-pill {
  border-radius: var(--radius-pill);
  padding: 4px 10px;
  border: 1px solid rgba(56, 189, 248, 0.7);
  background: rgba(15, 23, 42, 0.98);
  color: var(--color-accent);
  font-size: 11px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.flash-pill {
  border-radius: var(--radius-pill);
  padding: 4px 9px;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  background: rgba(220, 38, 38, 0.2);
  border: 1px solid rgba(248, 113, 113, 0.9);
  color: #fecaca;
  animation: flash 1.1s ease-in-out infinite alternate;
}

@keyframes flash {
  from {
    box-shadow: 0 0 0 rgba(248, 113, 113, 0);
    transform: translateY(0);
  }
  to {
    box-shadow: 0 0 22px rgba(248, 113, 113, 0.85);
    transform: translateY(-1px);
  }
}

@media (max-width: 900px) {
  .hero-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* Section headings / layout utilities */

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 28px;
  margin-bottom: 14px;
}

.section-title {
  font-size: 16px;
  font-weight: 600;
}

.section-subtitle {
  font-size: 12px;
  color: var(--color-text-muted);
}

.section-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.grid {
  display: grid;
  gap: 16px;
}

.grid-3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.grid-2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.grid-4 {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

@media (max-width: 1100px) {
  .grid-3,
  .grid-4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  .grid-3,
  .grid-4,
  .grid-2 {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* Pool Cards */

.pool-card {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-lg);
  padding: 16px 16px 14px;
  background: linear-gradient(
      145deg,
      rgba(15, 23, 42, 0.96),
      rgba(15, 23, 42, 0.98)
    ),
    radial-gradient(circle at 0 0, rgba(255, 122, 0, 0.18), transparent 55%);
  border: 1px solid rgba(148, 163, 184, 0.45);
  box-shadow: var(--shadow-soft);
  transition: transform var(--transition-base),
    box-shadow var(--transition-base),
    border-color var(--transition-base);
}

.pool-card:hover {
  transform: translateY(-3px) translateZ(0);
  border-color: rgba(248, 250, 252, 0.6);
  box-shadow: 0 0 0 1px rgba(15, 23, 42, 0.9),
    0 0 32px rgba(255, 122, 0, 0.9);
}

.pool-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}

.pool-name {
  font-weight: 600;
  font-size: 15px;
}

.pool-meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 11px;
  color: var(--color-text-muted);
}

.pill {
  border-radius: var(--radius-pill);
  padding: 3px 9px;
  border: 1px solid rgba(148, 163, 184, 0.5);
  background: rgba(15, 23, 42, 0.9);
}

.pill-orange {
  border-color: rgba(248, 171, 84, 0.9);
  color: #fed7aa;
}

.pill-sky {
  border-color: rgba(56, 189, 248, 0.8);
  color: #e0f2fe;
}

.pool-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin-top: 10px;
  margin-bottom: 8px;
}

.pool-stat {
  font-size: 11px;
  color: var(--color-text-muted);
}

.pool-stat-value {
  margin-top: 1px;
  font-weight: 600;
  font-size: 14px;
  color: var(--color-text);
}

.highlight {
  color: #f97316;
}

.highlight-sky {
  color: #38bdf8;
}

.progress-shell {
  margin-top: 6px;
}

.progress-label-row {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  color: var(--color-text-muted);
}

.progress-bar {
  margin-top: 4px;
  width: 100%;
  height: 7px;
  border-radius: 99px;
  background: rgba(15, 23, 42, 0.95);
  border: 1px solid rgba(31, 41, 55, 0.9);
  overflow: hidden;
  position: relative;
}

.progress-fill {
  position: absolute;
  inset: 0;
  transform-origin: left;
  background: linear-gradient(90deg, #22c55e, #f97316, #ef4444);
  box-shadow: 0 0 18px rgba(248, 171, 84, 0.8);
  transition: transform 800ms cubic-bezier(0.22, 0.61, 0.36, 1);
}

.pool-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 10px;
  gap: 10px;
  font-size: 11px;
  color: var(--color-text-muted);
}

.pool-footer-left {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.pool-countdown {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  border-radius: var(--radius-pill);
  padding: 3px 8px;
  border: 1px solid rgba(56, 189, 248, 0.7);
  background: rgba(15, 23, 42, 0.96);
  font-size: 11px;
  color: var(--color-accent);
}

.pool-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

.status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 12px rgba(34, 197, 94, 0.9);
}

.status-dot.offline {
  background: #6b7280;
  box-shadow: none;
}

/* Stats Cards */

.stat-card {
  border-radius: var(--radius-lg);
  padding: 14px 14px 12px;
  background: linear-gradient(
      135deg,
      rgba(15, 23, 42, 0.98),
      rgba(15, 23, 42, 0.96)
    ),
    radial-gradient(circle at 0 0, rgba(56, 189, 248, 0.18), transparent 55%);
  border: 1px solid rgba(148, 163, 184, 0.5);
  box-shadow: var(--shadow-soft);
}

.stat-label {
  font-size: 11px;
  color: var(--color-text-muted);
}

.stat-value-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-top: 4px;
  gap: 4px;
}

.stat-value {
  font-size: 18px;
  font-weight: 600;
}

.stat-trend {
  font-size: 11px;
  color: #4ade80;
}

.stat-footnote {
  margin-top: 6px;
  font-size: 11px;
  color: var(--color-text-muted);
}

/* Table styles (tickets, winners, admin lists) */

.table-shell {
  border-radius: var(--radius-lg);
  border: 1px solid rgba(55, 65, 81, 0.9);
  background: radial-gradient(
      circle at 0 0,
      rgba(56, 189, 248, 0.12),
      transparent 60%
    ),
    rgba(15, 23, 42, 0.98);
  overflow: hidden;
  box-shadow: var(--shadow-soft);
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
}

thead {
  background: rgba(15, 23, 42, 0.98);
}

th,
td {
  padding: 9px 12px;
  text-align: left;
}

th {
  font-weight: 500;
  color: var(--color-text-muted);
  border-bottom: 1px solid rgba(31, 41, 55, 0.9);
}

tbody tr:nth-child(even) {
  background: rgba(15, 23, 42, 0.98);
}

tbody tr:nth-child(odd) {
  background: rgba(17, 24, 39, 0.98);
}

tbody tr:hover {
  background: rgba(24, 35, 56, 0.95);
}

.table-tag {
  border-radius: 999px;
  padding: 2px 8px;
  font-size: 11px;
  border: 1px solid rgba(148, 163, 184, 0.7);
}

.table-tag-win {
  border-color: rgba(34, 197, 94, 0.9);
  color: #bbf7d0;
}

.table-tag-loss {
  border-color: rgba(239, 68, 68, 0.9);
  color: #fecaca;
}

/* Winner badges / leaderboard */

.rank-badge {
  border-radius: 999px;
  padding: 4px 9px;
  font-size: 11px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.rank-badge.gold {
  background: radial-gradient(circle at 0 0, #fef3c7, #facc15);
  color: #92400e;
  box-shadow: 0 0 24px rgba(250, 204, 21, 0.95);
}

.rank-badge.silver {
  background: radial-gradient(circle at 0 0, #e5e7eb, #9ca3af);
  color: #111827;
}

.rank-badge.bronze {
  background: radial-gradient(circle at 0 0, #fed7aa, #f97316);
  color: #7c2d12;
}

.trophy-icon {
  font-size: 14px;
}

.leaderboard-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.96);
  border: 1px solid rgba(55, 65, 81, 0.95);
  margin-bottom: 8px;
}

.leaderboard-user {
  display: flex;
  align-items: center;
  gap: 10px;
}

.avatar-circle {
  width: 30px;
  height: 30px;
  border-radius: 999px;
  background: radial-gradient(circle at 0 0, #38bdf8, #020617);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 600;
}

.leaderboard-meta {
  font-size: 11px;
  color: var(--color-text-muted);
}

.leaderboard-score {
  font-weight: 600;
  font-size: 14px;
}

/* Referral panel */

.referral-card {
  border-radius: var(--radius-lg);
  padding: 16px;
  background: linear-gradient(
      135deg,
      rgba(15, 23, 42, 0.96),
      rgba(15, 23, 42, 0.98)
    ),
    radial-gradient(circle at 0 0, rgba(56, 189, 248, 0.22), transparent 55%);
  border: 1px solid rgba(56, 189, 248, 0.8);
  box-shadow: var(--shadow-neon-sky);
}

.referral-link-row {
  display: flex;
  gap: 8px;
  margin-top: 10px;
}

.referral-input {
  flex: 1;
  background: rgba(15, 23, 42, 0.95);
  border-radius: 10px;
  border: 1px solid rgba(56, 189, 248, 0.8);
  padding: 7px 10px;
  font-size: 12px;
  color: var(--color-accent);
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

/* Profile layout */

.profile-grid {
  display: grid;
  grid-template-columns: minmax(0, 2.1fr) minmax(0, 2.1fr);
  gap: 18px;
}

@media (max-width: 860px) {
  .profile-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* Admin layout */

.admin-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
}

.admin-sidebar {
  border-right: 1px solid rgba(31, 41, 55, 0.95);
  background: radial-gradient(circle at 0 0, rgba(56, 189, 248, 0.16), #020617);
  padding: 18px 16px;
}

.admin-main {
  padding: 20px 24px 24px;
  max-width: 1200px;
  width: 100%;
  margin: 0 auto;
}

.admin-logo {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 18px;
}

.admin-nav-section-title {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-text-muted);
  margin: 16px 0 8px;
}

.admin-nav-link {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 7px 9px;
  font-size: 13px;
  border-radius: 999px;
  color: var(--color-text-muted);
  cursor: pointer;
  transition: background var(--transition-base),
    color var(--transition-base),
    transform var(--transition-fast);
}

.admin-nav-link:hover {
  background: rgba(15, 23, 42, 0.96);
  color: var(--color-text);
  transform: translateX(1px);
}

.admin-nav-link.active {
  background: radial-gradient(circle at 0 0, #f97316, #ea580c);
  color: #111827;
  font-weight: 600;
  box-shadow: var(--shadow-neon-orange);
}

@media (max-width: 900px) {
  .admin-shell {
    grid-template-columns: minmax(0, 1fr);
  }
  .admin-sidebar {
    border-right: none;
    border-bottom: 1px solid rgba(31, 41, 55, 0.95);
  }
}

/* Simple chart placeholders (admin dashboard) */

.chart-placeholder {
  border-radius: var(--radius-lg);
  padding: 14px;
  background: radial-gradient(
      circle at 0 0,
      rgba(56, 189, 248, 0.16),
      transparent 55%
    ),
    rgba(15, 23, 42, 0.98);
  border: 1px solid rgba(148, 163, 184, 0.5);
  box-shadow: var(--shadow-soft);
}

.chart-bars {
  display: flex;
  align-items: flex-end;
  gap: 8px;
  margin-top: 10px;
  height: 120px;
}

.chart-bar {
  flex: 1;
  border-radius: 999px;
  background: linear-gradient(180deg, #38bdf8, rgba(15, 23, 42, 0.2));
  box-shadow: 0 0 18px rgba(56, 189, 248, 0.7);
  position: relative;
  overflow: hidden;
}

.chart-bar::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.25), transparent);
  mix-blend-mode: screen;
}

.chart-x-labels {
  display: flex;
  justify-content: space-between;
  margin-top: 8px;
  font-size: 11px;
  color: var(--color-text-muted);
}

/* Modals / overlays */

.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.88);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 60;
  animation: fadeIn var(--transition-slow);
}

.modal {
  width: 100%;
  max-width: 420px;
  border-radius: 18px;
  padding: 18px 18px 16px;
  background: radial-gradient(
      circle at 0 0,
      rgba(255, 122, 0, 0.15),
      transparent 55%
    ),
    rgba(15, 23, 42, 0.98);
  border: 1px solid rgba(148, 163, 184, 0.6);
  box-shadow: var(--shadow-soft);
  position: relative;
  overflow: hidden;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.modal-title {
  font-size: 16px;
  font-weight: 600;
}

.modal-close {
  width: 26px;
  height: 26px;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.7);
  background: rgba(15, 23, 42, 0.96);
  color: var(--color-text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 13px;
}

.modal-close:hover {
  background: rgba(30, 64, 175, 0.9);
  color: #e5e7eb;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(5px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Confetti effect */

.confetti-container {
  position: fixed;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
  z-index: 70;
}

.confetti-piece {
  position: absolute;
  width: 6px;
  height: 12px;
  border-radius: 2px;
  background: #f97316;
  animation: confetti-fall 2.2s linear forwards;
}

.confetti-piece:nth-child(3n) {
  background: #38bdf8;
}

.confetti-piece:nth-child(4n) {
  background: #facc15;
}

@keyframes confetti-fall {
  0% {
    transform: translate3d(0, -10%, 0) rotateZ(0deg);
    opacity: 1;
  }
  100% {
    transform: translate3d(0, 110vh, 0) rotateZ(260deg);
    opacity: 0;
  }
}

/* Chips / tags */

.chip {
  border-radius: 999px;
  padding: 4px 9px;
  font-size: 11px;
  border: 1px solid rgba(148, 163, 184, 0.6);
  color: var(--color-text-muted);
}

.chip-orange {
  border-color: rgba(248, 171, 84, 0.9);
  color: #fed7aa;
}

.chip-sky {
  border-color: rgba(56, 189, 248, 0.8);
  color: #e0f2fe;
}

.chip-muted {
  background: rgba(15, 23, 42, 0.96);
}

/* Badges for "Almost full" etc. */

.badge-flash {
  border-radius: 999px;
  padding: 3px 9px;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  background: rgba(248, 113, 113, 0.18);
  border: 1px solid rgba(248, 113, 113, 0.95);
  color: #fecaca;
  animation: flash 1.1s ease-in-out infinite alternate;
}

/* Simple tabs */

.tabs {
  display: inline-flex;
  align-items: center;
  padding: 3px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.95);
  border: 1px solid rgba(55, 65, 81, 0.95);
}

.tab {
  border-radius: 999px;
  padding: 5px 11px;
  font-size: 11px;
  color: var(--color-text-muted);
  cursor: pointer;
}

.tab.active {
  background: radial-gradient(circle at 0 0, #38bdf8, #0ea5e9);
  color: #020617;
  font-weight: 600;
}

/* Small utilities */

.pill-soft {
  border-radius: 999px;
  padding: 3px 8px;
  font-size: 11px;
  background: rgba(15, 23, 42, 0.96);
  border: 1px solid rgba(75, 85, 99, 0.9);
}

.text-muted {
  color: var(--color-text-muted);
}

.text-accent {
  color: var(--color-accent);
}

.text-orange {
  color: var(--color-primary);
}

.fw-600 {
  font-weight: 600;
}

.fs-12 {
  font-size: 12px;
}

.fs-13 {
  font-size: 13px;
}

.flex {
  display: flex;
}

.flex-between {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.flex-wrap {
  flex-wrap: wrap;
}

.gap-6 {
  gap: 6px;
}

.gap-8 {
  gap: 8px;
}

.gap-10 {
  gap: 10px;
}

.gap-12 {
  gap: 12px;
}

.tag-success {
  border-radius: 999px;
  padding: 3px 8px;
  font-size: 11px;
  background: rgba(22, 163, 74, 0.16);
  border: 1px solid rgba(34, 197, 94, 0.9);
  color: #bbf7d0;
}

.tag-danger {
  border-radius: 999px;
  padding: 3px 8px;
  font-size: 11px;
  background: rgba(248, 113, 113, 0.15);
  border: 1px solid rgba(239, 68, 68, 0.95);
  color: #fecaca;
}

.tag-warning {
  border-radius: 999px;
  padding: 3px 8px;
  font-size: 11px;
  background: rgba(250, 204, 21, 0.16);
  border: 1px solid rgba(250, 204, 21, 0.9);
  color: #fef3c7;
}

.divider {
  border-top: 1px solid rgba(31, 41, 55, 0.95);
  margin: 10px 0;
}

.pill-outline {
  border-radius: 999px;
  padding: 3px 8px;
  border: 1px solid rgba(148, 163, 184, 0.65);
  font-size: 11px;
  color: var(--color-text-muted);
}

.badge-small {
  border-radius: 999px;
  padding: 2px 7px;
  border: 1px solid rgba(148, 163, 184, 0.7);
  font-size: 10px;
}

.scroll-y {
  max-height: 280px;
  overflow-y: auto;
}

.scroll-y::-webkit-scrollbar {
  width: 5px;
}

.scroll-y::-webkit-scrollbar-track {
  background: transparent;
}

.scroll-y::-webkit-scrollbar-thumb {
  background: rgba(55, 65, 81, 0.9);
  border-radius: 999px;
}

/* Footer */

.app-footer {
  padding: 12px 24px 18px;
  font-size: 11px;
  color: var(--color-text-muted);
  text-align: center;
}

