/* Orbpops — Premium Design System */
@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:ital,wght@0,400;0,500;0,600;0,700;0,800;1,400&display=swap');

:root {
  --font: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
  --bg: #0a0a0f;
  --bg-elevated: #12121a;
  --bg-card: rgba(255, 255, 255, 0.04);
  --bg-card-hover: rgba(255, 255, 255, 0.07);
  --surface: #ffffff;
  --surface-muted: #f8f9fc;
  --border: rgba(255, 255, 255, 0.08);
  --border-light: #e8eaef;
  --text: #f4f4f8;
  --text-muted: #9ca3b8;
  --text-dark: #1a1d26;
  --text-secondary: #5c6370;
  --primary: #7c5cfc;
  --primary-light: #9b7fff;
  --primary-dark: #5b3fd4;
  --accent: #22d3ee;
  --accent-warm: #f59e0b;
  --success: #10b981;
  --danger: #ef4444;
  --warning: #f59e0b;
  --gradient: linear-gradient(135deg, #7c5cfc 0%, #22d3ee 100%);
  --gradient-warm: linear-gradient(135deg, #7c5cfc 0%, #f59e0b 100%);
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.08);
  --shadow-md: 0 8px 32px rgba(0, 0, 0, 0.12);
  --shadow-lg: 0 20px 60px rgba(0, 0, 0, 0.2);
  --shadow-glow: 0 0 40px rgba(124, 92, 252, 0.25);
  --radius-sm: 8px;
  --radius: 14px;
  --radius-lg: 20px;
  --radius-xl: 28px;
  --transition: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  margin: 0;
  min-height: 100vh;
  color: var(--text-dark);
  background: var(--surface-muted);
  -webkit-font-smoothing: antialiased;
}

body.page-dark {
  color: var(--text);
  background: var(--bg);
}

/* ── Typography ── */
h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.text-gradient {
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ── Navbar ── */
.orb-navbar {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgba(10, 10, 15, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  padding: 0;
}

.orb-navbar .container-fluid {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
}

.orb-brand {
  font-weight: 800;
  font-size: 1.35rem;
  color: var(--text) !important;
  letter-spacing: -0.03em;
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}

.orb-brand-icon {
  width: 36px;
  height: 36px;
  background: var(--gradient);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
}

.orb-navbar .nav-link {
  color: var(--text-muted) !important;
  font-weight: 500;
  font-size: 0.9rem;
  padding: 8px 14px !important;
  border-radius: var(--radius-sm);
  transition: var(--transition);
}

.orb-navbar .nav-link:hover,
.orb-navbar .nav-link.active {
  color: var(--text) !important;
  background: rgba(255, 255, 255, 0.06);
}

.orb-navbar .navbar-toggler {
  border-color: var(--border);
}

/* ── Buttons ── */
.btn-orb {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  font-family: var(--font);
  font-weight: 600;
  font-size: 0.95rem;
  border-radius: var(--radius);
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: var(--transition);
  line-height: 1.4;
}

.btn-orb-primary {
  background: var(--gradient);
  color: #fff;
  box-shadow: var(--shadow-glow);
}

.btn-orb-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 50px rgba(124, 92, 252, 0.4);
  color: #fff;
}

.btn-orb-secondary {
  background: rgba(255, 255, 255, 0.08);
  color: var(--text);
  border: 1px solid var(--border);
}

.btn-orb-secondary:hover {
  background: rgba(255, 255, 255, 0.12);
  color: var(--text);
}

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

.btn-orb-outline:hover {
  background: var(--primary);
  color: #fff;
}

.btn-orb-ghost {
  background: transparent;
  color: var(--text-secondary);
  border: 1px solid var(--border-light);
}

.btn-orb-ghost:hover {
  background: var(--surface-muted);
  color: var(--text-dark);
}

.btn-orb-lg { padding: 16px 32px; font-size: 1.05rem; }
.btn-orb-sm { padding: 8px 16px; font-size: 0.85rem; }

/* ── Cards ── */
.orb-card {
  background: var(--surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 28px;
  transition: var(--transition);
  box-shadow: var(--shadow-sm);
}

.orb-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.orb-card-dark {
  background: var(--bg-card);
  border: 1px solid var(--border);
  backdrop-filter: blur(12px);
}

.orb-card-dark:hover {
  background: var(--bg-card-hover);
  box-shadow: var(--shadow-glow);
}

/* ── Dashboard action cards ── */
.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
}

.dashboard-card {
  display: block;
  text-decoration: none;
  color: inherit;
  background: var(--surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 28px;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.dashboard-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--gradient);
  opacity: 0;
  transition: var(--transition);
}

.dashboard-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: rgba(124, 92, 252, 0.3);
}

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

.dashboard-card-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(124, 92, 252, 0.15), rgba(34, 211, 238, 0.15));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  margin-bottom: 16px;
  color: var(--primary);
}

.dashboard-card h3 {
  font-size: 1.1rem;
  margin: 0 0 8px;
  color: var(--text-dark);
}

.dashboard-card p {
  margin: 0;
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

/* ── Hero / Landing ── */
.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--text);
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -25%;
  width: 150%;
  height: 150%;
  background: radial-gradient(ellipse at 30% 20%, rgba(124, 92, 252, 0.15) 0%, transparent 50%),
              radial-gradient(ellipse at 70% 80%, rgba(34, 211, 238, 0.1) 0%, transparent 50%);
  pointer-events: none;
}

.hero-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 80px 24px;
  position: relative;
  z-index: 1;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background: rgba(124, 92, 252, 0.15);
  border: 1px solid rgba(124, 92, 252, 0.3);
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--primary-light);
  margin-bottom: 24px;
}

.hero h1 {
  font-size: clamp(2.5rem, 6vw, 4rem);
  font-weight: 800;
  margin: 0 0 20px;
  letter-spacing: -0.04em;
  line-height: 1.1;
}

.hero-subtitle {
  font-size: clamp(1.1rem, 2.5vw, 1.35rem);
  color: var(--text-muted);
  max-width: 560px;
  margin: 0 auto 40px;
  line-height: 1.6;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: center;
}

.hero-features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 24px;
  max-width: 900px;
  margin: 60px auto 0;
  padding: 0 24px;
}

.hero-feature {
  text-align: center;
  padding: 24px;
}

.hero-feature-icon {
  font-size: 2rem;
  margin-bottom: 12px;
}

.hero-feature h3 {
  font-size: 1rem;
  margin: 0 0 8px;
  color: var(--text);
}

.hero-feature p {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin: 0;
  line-height: 1.5;
}

/* ── Auth pages ── */
.auth-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg);
  padding: 40px 24px;
  position: relative;
}

.auth-page::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 50% 0%, rgba(124, 92, 252, 0.12) 0%, transparent 60%);
  pointer-events: none;
}

.auth-card {
  width: 100%;
  max-width: 440px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 40px;
  position: relative;
  z-index: 1;
  box-shadow: var(--shadow-lg);
}

.auth-card h1 {
  font-size: 1.75rem;
  color: var(--text);
  margin: 0 0 8px;
}

.auth-card .subtitle {
  color: var(--text-muted);
  margin: 0 0 28px;
  font-size: 0.95rem;
}

.auth-card .form-label {
  color: var(--text-muted);
  font-weight: 500;
  font-size: 0.9rem;
  margin-bottom: 8px;
}

.auth-card .form-control {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text);
  padding: 12px 16px;
  font-family: var(--font);
  transition: var(--transition);
}

.auth-card .form-control:focus {
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(124, 92, 252, 0.2);
  color: var(--text);
}

.auth-card .form-control::placeholder {
  color: rgba(156, 163, 184, 0.6);
}

.auth-divider {
  display: flex;
  align-items: center;
  gap: 16px;
  margin: 24px 0;
  color: var(--text-muted);
  font-size: 0.85rem;
}

.auth-divider::before,
.auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
}

.auth-footer {
  text-align: center;
  margin-top: 24px;
  color: var(--text-muted);
  font-size: 0.9rem;
}

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

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

.btn-google {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 12px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text);
  font-weight: 500;
  text-decoration: none;
  transition: var(--transition);
}

.btn-google:hover {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text);
}

/* ── Page layout (app pages) ── */
.page-header {
  margin-bottom: 32px;
}

.page-header h1 {
  font-size: 1.75rem;
  margin: 0 0 8px;
  color: var(--text-dark);
}

.page-header p {
  margin: 0;
  color: var(--text-secondary);
}

.orb-main {
  max-width: 1280px;
  margin: 0 auto;
  padding: 32px 24px 64px;
}

/* ── Alerts ── */
.alert-orb {
  border-radius: var(--radius);
  border: none;
  padding: 14px 18px;
  font-size: 0.9rem;
}

/* ── Pops grid ── */
.pops-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
}

.pop-card {
  background: var(--surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: var(--transition);
}

.pop-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.pop-cover {
  width: 100%;
  height: 150px;
  object-fit: cover;
  background: linear-gradient(135deg, #f0f0f5, #e8eaef);
}

.pop-body { padding: 18px; flex: 1; display: flex; flex-direction: column; gap: 10px; }

.pop-title {
  font-size: 1.05rem;
  font-weight: 700;
  margin: 0;
  color: var(--text-dark);
}

.pop-desc {
  font-size: 0.88rem;
  color: var(--text-secondary);
  margin: 0;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.pop-meta { font-size: 0.8rem; color: var(--text-secondary); }

.kpi-row { display: flex; gap: 8px; flex-wrap: wrap; }

.kpi {
  font-size: 0.78rem;
  background: var(--surface-muted);
  border: 1px solid var(--border-light);
  border-radius: 999px;
  padding: 4px 10px;
  color: var(--text-dark);
}

.pop-actions { display: flex; gap: 8px; margin-top: auto; flex-wrap: wrap; }

.btn-chip {
  padding: 7px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: var(--transition);
}

.btn-chip-play { background: #ecfdf5; color: #065f46; border-color: #a7f3d0; }
.btn-chip-view { background: #eef2ff; color: #3730a3; border-color: #c7d2fe; }
.btn-chip-edit { background: #ecfeff; color: #155e75; border-color: #a5f3fc; }
.btn-chip-delete { background: #fef2f2; color: #991b1b; border-color: #fecaca; cursor: pointer; }

.btn-chip:hover { filter: brightness(0.95); transform: translateY(-1px); }

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

.empty-state h3 { color: var(--text-dark); margin: 0 0 8px; }

/* ── Profile ── */
.profile-container { max-width: 980px; margin: 0 auto; }

.profile-header {
  display: flex;
  gap: 24px;
  align-items: center;
  flex-wrap: wrap;
  margin-bottom: 28px;
}

.profile-avatar {
  width: 110px;
  height: 110px;
  border-radius: var(--radius-lg);
  object-fit: cover;
  border: 3px solid var(--border-light);
  box-shadow: var(--shadow-sm);
}

.profile-meta h1 { font-size: 1.6rem; margin: 0; }

.profile-meta .handle { color: var(--text-secondary); }

.kpis {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 24px;
}

.kpi-card {
  background: var(--surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius);
  padding: 18px;
}

.kpi-card .label { font-size: 0.8rem; color: var(--text-secondary); margin-bottom: 6px; }
.kpi-card .value { font-size: 1.5rem; font-weight: 800; color: var(--text-dark); }

.progress-bar-orb {
  height: 8px;
  background: var(--surface-muted);
  border-radius: 999px;
  overflow: hidden;
  margin-top: 10px;
}

.progress-bar-orb > span {
  display: block;
  height: 100%;
  background: var(--gradient);
  border-radius: 999px;
  transition: width 0.6s ease;
}

/* ── Footer ── */
.orb-footer {
  border-top: 1px solid var(--border-light);
  padding: 24px;
  margin-top: auto;
}

.orb-footer .container {
  max-width: 1280px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.orb-footer a {
  color: var(--text-secondary);
  text-decoration: none;
}

.orb-footer a:hover { color: var(--primary); }

/* ── Placeholder pages ── */
.coming-soon {
  text-align: center;
  padding: 80px 24px;
}

.coming-soon-icon {
  font-size: 3rem;
  margin-bottom: 20px;
}

.coming-soon h2 { margin: 0 0 12px; }

.coming-soon p { color: var(--text-secondary); max-width: 400px; margin: 0 auto 24px; }

/* ── Responsive ── */
@media (max-width: 768px) {
  .kpis { grid-template-columns: repeat(2, 1fr); }
  .hero-actions { flex-direction: column; width: 100%; max-width: 320px; }
  .hero-actions .btn-orb { width: 100%; }
  .auth-card { padding: 28px 24px; }
}
