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

/* ======================== DESIGN TOKENS ======================== */
:root {
  --bg: #07080f;
  --bg-1: #0d0e1a;
  --bg-2: #12132a;
  --bg-card: rgba(18, 19, 42, 0.7);
  --text: #f0f2ff;
  --text-muted: #7b82b0;
  --text-dim: #4a5080;
  --accent: #7c3aed;
  --accent-2: #a855f7;
  --accent-cyan: #06b6d4;
  --accent-green: #22c55e;
  --accent-gold: #fbbf24;
  --accent-red: #ef4444;
  --border: rgba(255, 255, 255, 0.07);
  --border-2: rgba(255, 255, 255, 0.12);
  --glow-purple: rgba(124, 58, 237, 0.25);
  --glow-cyan: rgba(6, 182, 212, 0.2);
  --sidebar-w: 240px;
  --radius-sm: 8px;
  --radius: 12px;
  --radius-lg: 20px;
  --transition: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ======================== RESET & BASE ======================== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: 'Inter', -apple-system, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  overflow-x: hidden;
  line-height: 1.6;
  background-image:
    radial-gradient(ellipse 60% 40% at 20% 10%, rgba(124, 58, 237, 0.12) 0%, transparent 60%),
    radial-gradient(ellipse 50% 40% at 80% 80%, rgba(6, 182, 212, 0.08) 0%, transparent 60%);
}

a { text-decoration: none; color: inherit; }
button { cursor: pointer; font-family: inherit; }
input, select, textarea { font-family: inherit; }

/* ======================== UTILITIES ======================== */
.hidden { display: none !important; }
.w-full { width: 100%; }

.glass {
  background: var(--bg-card);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.gradient-text {
  background: linear-gradient(135deg, var(--accent-2), var(--accent-cyan));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ======================== VIEWS ======================== */
#app { min-height: 100vh; display: flex; flex-direction: column; }

.view {
  flex: 1;
  display: flex;
  flex-direction: column;
  animation: fadeSlide 0.35s ease both;
}

@keyframes fadeSlide {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ======================== SITE NAV ======================== */
.site-nav {
  display: flex;
  align-items: center;
  gap: 32px;
  padding: 14px 32px;
  margin: 16px;
  border-radius: var(--radius-lg);
  position: sticky;
  top: 16px;
  z-index: 100;
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 18px;
  font-weight: 800;
  color: var(--text);
  flex-shrink: 0;
}

.brand-icon { color: var(--accent-2); width: 28px; height: 28px; }

.nav-links {
  display: flex;
  gap: 24px;
  flex: 1;
  justify-content: center;
}

.nav-links a {
  color: var(--text-muted);
  font-size: 14px;
  font-weight: 500;
  transition: color var(--transition);
}

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

.nav-actions { display: flex; gap: 10px; flex-shrink: 0; }

/* ======================== HERO ======================== */
.hero {
  max-width: 860px;
  margin: 80px auto 60px;
  padding: 0 24px;
  text-align: center;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(124, 58, 237, 0.15);
  border: 1px solid rgba(124, 58, 237, 0.3);
  color: var(--accent-2);
  padding: 6px 14px;
  border-radius: 50px;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 28px;
}

.hero-title {
  font-size: clamp(36px, 6vw, 68px);
  font-weight: 900;
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin-bottom: 20px;
}

.hero-sub {
  font-size: 18px;
  color: var(--text-muted);
  max-width: 600px;
  margin: 0 auto 36px;
}

.hero-cta {
  display: flex;
  gap: 14px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 60px;
}

.hero-stats {
  display: flex;
  justify-content: center;
  gap: 48px;
  padding-top: 40px;
  border-top: 1px solid var(--border);
}

.hero-stat span {
  display: block;
  font-size: 28px;
  font-weight: 800;
  background: linear-gradient(135deg, var(--accent-2), var(--accent-cyan));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-stat p { color: var(--text-muted); font-size: 13px; margin-top: 2px; }

/* ======================== FEATURES ======================== */
.features-section, .pricing-section {
  max-width: 1100px;
  margin: 80px auto;
  padding: 0 24px;
  text-align: center;
}

.section-tag {
  display: inline-block;
  background: rgba(6, 182, 212, 0.1);
  border: 1px solid rgba(6, 182, 212, 0.3);
  color: var(--accent-cyan);
  padding: 5px 14px;
  border-radius: 50px;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 16px;
}

.section-title {
  font-size: clamp(24px, 4vw, 40px);
  font-weight: 800;
  margin-bottom: 12px;
  letter-spacing: -0.02em;
}

.section-sub { color: var(--text-muted); font-size: 16px; margin-bottom: 48px; }

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
  text-align: left;
}

.feature-card {
  padding: 28px;
  transition: transform var(--transition), box-shadow var(--transition);
}

.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 40px rgba(0,0,0,0.3);
}

.feature-icon {
  width: 48px; height: 48px;
  border-radius: var(--radius-sm);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 16px;
}

.feature-icon i { width: 22px; height: 22px; }
.feature-card h3 { font-size: 17px; font-weight: 700; margin-bottom: 8px; }
.feature-card p { color: var(--text-muted); font-size: 14px; line-height: 1.7; }

/* ======================== PRICING ======================== */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  max-width: 900px;
  margin: 0 auto;
}

.pricing-card {
  padding: 36px 28px;
  text-align: left;
  position: relative;
  transition: transform var(--transition);
}

.pricing-card-featured {
  background: linear-gradient(135deg, rgba(124,58,237,0.2), rgba(6,182,212,0.1));
  border-color: rgba(124,58,237,0.4);
  transform: scale(1.04);
  box-shadow: 0 0 40px rgba(124,58,237,0.2);
}

.featured-badge {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: linear-gradient(135deg, var(--accent), var(--accent-cyan));
  color: white;
  font-size: 11px;
  font-weight: 800;
  padding: 4px 14px;
  border-radius: 50px;
  letter-spacing: 1px;
}

.pricing-card h3 { font-size: 20px; font-weight: 700; margin-bottom: 12px; }

.price {
  font-size: 42px;
  font-weight: 900;
  margin-bottom: 24px;
  background: linear-gradient(135deg, var(--text), var(--text-muted));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.price span { font-size: 16px; font-weight: 400; }

.pricing-features {
  list-style: none;
  margin-bottom: 28px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.pricing-features li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  color: var(--text-muted);
}

.pricing-features li i { width: 16px; height: 16px; color: var(--accent-green); flex-shrink: 0; }

/* ======================== FOOTER ======================== */
.site-footer {
  text-align: center;
  padding: 40px 24px;
  border-top: 1px solid var(--border);
  margin-top: 40px;
}

.footer-brand {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 12px;
}

.site-footer p { color: var(--text-muted); font-size: 13px; }

/* ======================== AUTH VIEWS ======================== */
.auth-view {
  align-items: center;
  justify-content: center;
  padding: 24px;
  min-height: 100vh;
}

.auth-card {
  width: 100%;
  max-width: 440px;
  padding: 40px;
}

.auth-card-wide { max-width: 680px; }

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

.auth-header h1 {
  font-size: 24px;
  font-weight: 800;
}

.auth-subtitle {
  color: var(--text-muted);
  font-size: 14px;
  margin-top: 6px;
}

.form-grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 16px;
}

.input-group {
  position: relative;
  margin-bottom: 16px;
}

.input-group i {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  width: 18px;
  height: 18px;
  pointer-events: none;
}

.input-group input {
  width: 100%;
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid var(--border-2);
  color: var(--text);
  padding: 12px 12px 12px 42px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  outline: none;
  transition: border-color var(--transition), box-shadow var(--transition);
}

.input-group input:focus {
  border-color: var(--accent-2);
  box-shadow: 0 0 0 3px rgba(168, 85, 247, 0.15);
}

.auth-toggle {
  text-align: center;
  margin-top: 20px;
  font-size: 13px;
  color: var(--text-muted);
}

.auth-toggle a { color: var(--accent-cyan); font-weight: 600; margin-left: 4px; }

/* ======================== BUTTONS ======================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 22px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  transition: all var(--transition);
  border: none;
  text-decoration: none;
  white-space: nowrap;
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: white;
  box-shadow: 0 4px 16px rgba(124, 58, 237, 0.35);
}

.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 24px rgba(124, 58, 237, 0.5);
}

.btn-outline {
  background: transparent;
  border: 1px solid var(--border-2);
  color: var(--text);
}

.btn-outline:hover { background: rgba(255,255,255,0.06); }

.btn-danger { background: rgba(239,68,68,0.15); border: 1px solid rgba(239,68,68,0.3); color: var(--accent-red); }
.btn-danger:hover { background: rgba(239,68,68,0.25); }

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

/* ======================== ALERTS ======================== */
.alert {
  padding: 12px 16px;
  border-radius: var(--radius-sm);
  margin-bottom: 18px;
  font-size: 13px;
  font-weight: 500;
}

.alert.error { background: rgba(239,68,68,0.1); color: var(--accent-red); border: 1px solid rgba(239,68,68,0.25); }
.alert.success { background: rgba(34,197,94,0.1); color: var(--accent-green); border: 1px solid rgba(34,197,94,0.25); }

/* ======================== TOAST ======================== */
.toast {
  position: fixed;
  bottom: 32px;
  right: 32px;
  padding: 14px 22px;
  border-radius: var(--radius);
  background: rgba(18,19,42,0.95);
  border: 1px solid var(--border-2);
  backdrop-filter: blur(20px);
  font-size: 14px;
  font-weight: 500;
  z-index: 9999;
  animation: slideUp 0.3s ease;
  max-width: 360px;
}

.toast.success { border-color: rgba(34,197,94,0.4); color: var(--accent-green); }
.toast.error   { border-color: rgba(239,68,68,0.4); color: var(--accent-red); }
.toast.info    { border-color: rgba(6,182,212,0.4); color: var(--accent-cyan); }

@keyframes slideUp { from { opacity:0; transform: translateY(20px); } to { opacity:1; transform:translateY(0); } }

/* ======================== APP LAYOUT (DASHBOARD/ADMIN) ======================== */
.app-layout {
  display: flex;
  flex: 1;
  min-height: 100vh;
}

.sidebar {
  width: var(--sidebar-w);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  position: sticky;
  top: 0;
  padding: 20px 12px;
  border-radius: 0;
  border-right: 1px solid var(--border);
  border-top: none;
  border-bottom: none;
  border-left: none;
  background: rgba(13,14,26,0.9);
  flex-shrink: 0;
}

.sidebar-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 16px;
  font-weight: 800;
  padding: 8px 12px;
  margin-bottom: 24px;
}

.sidebar-nav { display: flex; flex-direction: column; gap: 2px; flex: 1; }

.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 14px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 500;
  color: var(--text-muted);
  background: none;
  border: none;
  width: 100%;
  text-align: left;
  transition: all var(--transition);
  cursor: pointer;
}

.nav-item:hover { background: rgba(255,255,255,0.06); color: var(--text); }
.nav-item.active { background: rgba(124,58,237,0.15); color: var(--text); border-left: 3px solid var(--accent-2); }
.nav-item i { width: 18px; height: 18px; flex-shrink: 0; }

.sidebar-footer { padding-top: 16px; border-top: 1px solid var(--border); display: flex; flex-direction: column; gap: 4px; }

.logout-btn { color: rgba(239,68,68,0.7) !important; }
.logout-btn:hover { color: var(--accent-red) !important; background: rgba(239,68,68,0.08) !important; }

.credit-pill {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  background: rgba(124,58,237,0.12);
  border: 1px solid rgba(124,58,237,0.25);
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 600;
  color: var(--accent-2);
  margin-bottom: 8px;
}

.credit-pill i { width: 16px; height: 16px; }

.app-main {
  flex: 1;
  padding: 32px;
  overflow-y: auto;
  max-width: calc(100vw - var(--sidebar-w));
}

/* ======================== TABS ======================== */
.tab-content { display: none; }
.tab-content.active { display: block; animation: fadeSlide 0.3s ease; }

/* ======================== PAGE HEADER ======================== */
.page-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 28px;
  gap: 16px;
}

.page-title { font-size: 26px; font-weight: 800; letter-spacing: -0.02em; }
.page-sub { color: var(--text-muted); font-size: 14px; margin-top: 4px; }

/* ======================== STAT CARDS ======================== */
.stats-grid-4 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 24px;
}

@media (max-width: 1100px) { .stats-grid-4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px)  { .stats-grid-4 { grid-template-columns: 1fr; } }

.stat-card {
  padding: 20px 22px;
  display: flex;
  align-items: center;
  gap: 16px;
  border-left: 3px solid var(--accent-color, var(--accent));
  transition: transform var(--transition);
}

.stat-card:hover { transform: translateY(-2px); }

.stat-icon-wrap {
  width: 44px; height: 44px;
  border-radius: 10px;
  background: color-mix(in srgb, var(--accent-color, var(--accent)) 15%, transparent);
  color: var(--accent-color, var(--accent));
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}

.stat-icon-wrap i { width: 22px; height: 22px; }
.stat-label { font-size: 12px; color: var(--text-muted); font-weight: 500; margin-bottom: 4px; text-transform: uppercase; letter-spacing: 0.5px; }
.stat-number { font-size: 28px; font-weight: 800; line-height: 1; }

/* ======================== SECTION CARDS ======================== */
.section-card {
  padding: 24px;
  margin-bottom: 24px;
}

.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border);
}

.section-head h3 {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 16px;
  font-weight: 700;
}

.section-head h3 i { width: 18px; height: 18px; color: var(--text-muted); }

/* ======================== PHOTO GRID ======================== */
.photo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 14px;
}

.photo-grid.large { grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); }

.photo-card {
  aspect-ratio: 2/3;
  border-radius: var(--radius-sm);
  overflow: hidden;
  position: relative;
  background: var(--bg-2);
  border: 1px solid var(--border);
  cursor: pointer;
  transition: transform var(--transition), box-shadow var(--transition);
}

.photo-card:hover { transform: scale(1.03); box-shadow: 0 10px 30px rgba(0,0,0,0.4); }
.photo-card img { width: 100%; height: 100%; object-fit: cover; display: block; }

.photo-card-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(transparent 50%, rgba(0,0,0,0.85) 100%);
  opacity: 0;
  transition: opacity var(--transition);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 12px;
}

.photo-card:hover .photo-card-overlay { opacity: 1; }
.photo-card-overlay p { font-size: 11px; color: rgba(255,255,255,0.8); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.photo-card-overlay a { display: inline-flex; align-items: center; gap: 4px; font-size: 11px; color: var(--accent-cyan); margin-top: 4px; }

/* ======================== EVENT BLOCKS ======================== */
.event-block {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  margin-bottom: 20px;
}

.event-block-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.event-block-name {
  font-size: 18px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 8px;
}

.event-block-name i { width: 18px; height: 18px; color: var(--accent-cyan); }
.event-block-meta { color: var(--text-muted); font-size: 12px; margin-top: 2px; }

/* ======================== CREDIT BALANCE ======================== */
.credit-balance-card {
  padding: 32px;
  margin-bottom: 28px;
  background: linear-gradient(135deg, rgba(124,58,237,0.15), rgba(6,182,212,0.08));
  border-color: rgba(124,58,237,0.3);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.credit-balance-number {
  font-size: 64px;
  font-weight: 900;
  background: linear-gradient(135deg, var(--accent-2), var(--accent-cyan));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  line-height: 1;
  margin: 8px 0;
}

/* ======================== PRICING MINI ======================== */
.pricing-grid-inline {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-bottom: 8px;
}

@media (max-width: 700px) { .pricing-grid-inline { grid-template-columns: 1fr; } }

.pricing-mini {
  padding: 28px;
  text-align: center;
  cursor: pointer;
  transition: transform var(--transition), box-shadow var(--transition);
  position: relative;
}

.pricing-mini:hover { transform: translateY(-4px); box-shadow: 0 16px 40px rgba(0,0,0,0.3); }
.pricing-mini h4 { font-size: 18px; font-weight: 700; margin-bottom: 10px; }
.price-mini { font-size: 36px; font-weight: 900; margin: 8px 0; }
.pricing-mini p { color: var(--text-muted); font-size: 13px; margin-bottom: 20px; }

.pricing-mini-featured {
  background: linear-gradient(135deg, rgba(124,58,237,0.2), rgba(6,182,212,0.1));
  border-color: rgba(124,58,237,0.4);
  box-shadow: 0 0 30px rgba(124,58,237,0.15);
}

.mini-badge {
  position: absolute;
  top: -10px; left: 50%;
  transform: translateX(-50%);
  background: linear-gradient(135deg, var(--accent), var(--accent-cyan));
  color: white;
  font-size: 10px;
  font-weight: 800;
  padding: 3px 12px;
  border-radius: 50px;
  letter-spacing: 0.5px;
}

/* ======================== DATA TABLES ======================== */
.table-wrap { overflow-x: auto; }

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

.data-table th {
  text-align: left;
  padding: 12px 14px;
  color: var(--text-muted);
  font-weight: 600;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  border-bottom: 1px solid var(--border);
}

.data-table td {
  padding: 14px;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
}

.data-table tr:last-child td { border-bottom: none; }
.data-table tr:hover td { background: rgba(255,255,255,0.02); }

.user-cell { display: flex; flex-direction: column; }
.user-cell .user-name { font-weight: 600; font-size: 13px; }
.user-cell .user-meta { color: var(--text-muted); font-size: 11px; margin-top: 1px; }

.badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 8px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 700;
}

.badge-admin { background: rgba(168,85,247,0.15); color: #d8b4fe; }
.badge-user  { background: rgba(255,255,255,0.06); color: var(--text-muted); }
.badge-success { background: rgba(34,197,94,0.15); color: var(--accent-green); }

.credit-edit {
  width: 72px;
  background: rgba(0,0,0,0.3);
  border: 1px solid var(--border-2);
  color: var(--text);
  padding: 6px 10px;
  border-radius: 6px;
  outline: none;
  font-size: 13px;
  text-align: center;
}

.credit-edit:focus { border-color: var(--accent-cyan); }

/* ======================== ACCOUNT PAGE ======================== */
.account-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

@media (max-width: 800px) { .account-grid { grid-template-columns: 1fr; } }

.account-info-grid { display: flex; flex-direction: column; gap: 4px; }

.info-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
}

.info-row:last-child { border-bottom: none; }
.info-label { font-size: 13px; color: var(--text-muted); }
.info-value { font-size: 13px; font-weight: 600; }

/* ======================== EMPTY STATE ======================== */
.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 60px 20px;
  color: var(--text-muted);
  text-align: center;
}

.empty-state i { width: 48px; height: 48px; opacity: 0.3; }
.empty-state p { font-size: 14px; max-width: 300px; }

/* ======================== COUNT BADGE ======================== */
.count-badge {
  background: rgba(6,182,212,0.1);
  border: 1px solid rgba(6,182,212,0.3);
  color: var(--accent-cyan);
  padding: 4px 12px;
  border-radius: 50px;
  font-size: 12px;
  font-weight: 600;
}

/* ======================== PURCHASE HISTORY ======================== */
.purchase-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
}

.purchase-row:last-child { border-bottom: none; }
.purchase-pkg { font-weight: 600; font-size: 14px; }
.purchase-date { color: var(--text-muted); font-size: 12px; margin-top: 2px; }
.purchase-credits { color: var(--accent-green); font-weight: 700; font-size: 16px; }
.purchase-amount { color: var(--text-muted); font-size: 12px; }

/* ======================== SHARE VIEW (MINIMAL SLIDER) ======================== */
.share-page {
  background: #000;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.share-header {
  padding: 16px 24px;
  background: rgba(0,0,0,0.5);
  display: flex;
  justify-content: center;
  position: absolute;
  top: 0; left: 0; right: 0;
  z-index: 50;
}

.share-header-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #fff;
  font-weight: 800;
  font-size: 18px;
}

.share-header-brand i { color: var(--accent-2); width: 20px; height: 20px; }

.share-loading-full {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  gap: 16px;
}

.share-spinner {
  width: 40px; height: 40px;
  border: 3px solid var(--border-2);
  border-top-color: var(--accent-2);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

.share-body {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 80px 20px 40px;
}

/* BEFORE/AFTER SLIDER */
.ba-wrap {
  position: relative;
  width: 100%;
  max-width: 600px;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 20px 40px rgba(0,0,0,0.5);
  user-select: none;
  background: #111;
  /* Maintain aspect ratio or rely on before image */
}

.ba-before-img {
  display: block;
  width: 100%;
  height: auto;
  pointer-events: none;
}

.ba-after {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  width: 50%; /* Initial split */
  overflow: hidden;
}

.ba-after img {
  display: block;
  width: 100vw; /* Need to match parent width via JS */
  height: 100%;
  max-width: none;
  pointer-events: none;
}

.ba-handle {
  position: absolute;
  top: 0; bottom: 0;
  left: 50%;
  width: 40px;
  margin-left: -20px;
  cursor: ew-resize;
  display: flex;
  flex-direction: column;
  align-items: center;
  z-index: 10;
}

.ba-handle-line {
  flex: 1;
  width: 3px;
  background: #fff;
  box-shadow: 0 0 10px rgba(0,0,0,0.5);
}

.ba-handle-circle {
  width: 40px; height: 40px;
  background: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #000;
  box-shadow: 0 0 10px rgba(0,0,0,0.5);
  flex-shrink: 0;
}

.ba-handle-circle i { width: 24px; height: 24px; }

.ba-label {
  position: absolute;
  top: 16px;
  background: rgba(0,0,0,0.5);
  color: #fff;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  pointer-events: none;
}

.ba-label-after { left: 16px; }
.ba-label-before { right: 16px; }

/* TOGGLE FALLBACK */
.share-toggle {
  display: flex;
  background: rgba(255,255,255,0.1);
  padding: 4px;
  border-radius: 8px;
  margin-bottom: 24px;
}

.share-toggle-btn {
  background: transparent;
  border: none;
  color: #fff;
  padding: 8px 16px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 600;
  opacity: 0.6;
}

.share-toggle-btn.active {
  background: rgba(255,255,255,0.2);
  opacity: 1;
}

.share-actions-row {
  margin-top: 32px;
  display: flex;
  gap: 16px;
}

.share-actions-row .btn {
  font-size: 16px;
  padding: 14px 32px;
  border-radius: 50px;
}

.share-error-state {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
}

.share-error-state i { width: 48px; height: 48px; margin-bottom: 16px; opacity: 0.5; }

.share-footer {
  text-align: center;
  padding: 24px;
  font-size: 13px;
  color: var(--text-muted);
}

.share-footer strong { color: #fff; }
.share-footer a { color: var(--accent-cyan); font-weight: 600; }

