/* ============================================================
   AURA — Next-Generation Social Platform
   Design System & Styles
   Fonts: Syne (Display) + Plus Jakarta Sans (Body)
   Palette: Deep Space Violet + Cyan + Pink Gradient
============================================================ */

/* ============================================================
   CSS CUSTOM PROPERTIES — DESIGN TOKENS
============================================================ */
:root {
  /* Core Brand Colors */
  --aura-violet: #A78BFA;
  --aura-cyan: #06B6D4;
  --aura-pink: #F472B6;
  --aura-amber: #F59E0B;
  --aura-green: #10B981;
  --aura-red: #EF4444;

  /* Gradient Definitions */
  --grad-primary: linear-gradient(135deg, #A78BFA 0%, #06B6D4 100%);
  --grad-secondary: linear-gradient(135deg, #F472B6 0%, #A78BFA 100%);
  --grad-warm: linear-gradient(135deg, #F59E0B 0%, #F472B6 100%);
  --grad-cool: linear-gradient(135deg, #06B6D4 0%, #3B82F6 100%);
  --grad-aurora: linear-gradient(135deg, #A78BFA 0%, #06B6D4 50%, #F472B6 100%);
  --grad-dark-bg: linear-gradient(180deg, #0A0A0F 0%, #0F0F1A 100%);

  /* Dark Theme (Default) */
  --bg-primary: #0A0A0F;
  --bg-secondary: #0F0F1A;
  --bg-tertiary: #141420;
  --bg-card: #16162A;
  --bg-card-hover: #1C1C35;
  --bg-glass: rgba(255, 255, 255, 0.04);
  --bg-glass-hover: rgba(255, 255, 255, 0.07);
  --bg-glass-strong: rgba(255, 255, 255, 0.08);
  --bg-overlay: rgba(10, 10, 15, 0.85);

  --border-subtle: rgba(255, 255, 255, 0.06);
  --border-medium: rgba(255, 255, 255, 0.10);
  --border-strong: rgba(255, 255, 255, 0.16);
  --border-accent: rgba(167, 139, 250, 0.3);

  --text-primary: #F0EEFF;
  --text-secondary: #9B9BC0;
  --text-tertiary: #6B6B8A;
  --text-muted: #4A4A6A;
  --text-accent: #A78BFA;
  --text-on-dark: #FFFFFF;

  /* Shadows */
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 20px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 8px 40px rgba(0, 0, 0, 0.5);
  --shadow-xl: 0 16px 60px rgba(0, 0, 0, 0.6);
  --shadow-glow-violet: 0 0 30px rgba(167, 139, 250, 0.2);
  --shadow-glow-cyan: 0 0 30px rgba(6, 182, 212, 0.2);
  --shadow-glow-pink: 0 0 30px rgba(244, 114, 182, 0.2);

  /* Spacing */
  --space-xs: 4px;
  --space-sm: 8px;
  --space-md: 16px;
  --space-lg: 24px;
  --space-xl: 32px;
  --space-2xl: 48px;
  --space-3xl: 64px;

  /* Border Radius */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 20px;
  --radius-2xl: 24px;
  --radius-full: 9999px;

  /* Typography */
  --font-display: 'Syne', sans-serif;
  --font-body: 'Plus Jakarta Sans', sans-serif;
  --font-mono: 'Space Mono', monospace;

  /* Transitions */
  --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-base: 250ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 400ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-spring: 500ms cubic-bezier(0.34, 1.56, 0.64, 1);

  /* Layout */
  --nav-height: 64px;
  --bottom-nav-height: 72px;
  --side-nav-width: 240px;
  --content-max-width: 680px;
}

/* Light Theme */
[data-theme="light"] {
  --bg-primary: #F8F7FF;
  --bg-secondary: #F0EEFF;
  --bg-tertiary: #E8E4FF;
  --bg-card: #FFFFFF;
  --bg-card-hover: #F5F3FF;
  --bg-glass: rgba(167, 139, 250, 0.06);
  --bg-glass-hover: rgba(167, 139, 250, 0.10);
  --bg-glass-strong: rgba(167, 139, 250, 0.12);
  --bg-overlay: rgba(248, 247, 255, 0.92);

  --border-subtle: rgba(167, 139, 250, 0.12);
  --border-medium: rgba(167, 139, 250, 0.20);
  --border-strong: rgba(167, 139, 250, 0.30);
  --border-accent: rgba(167, 139, 250, 0.4);

  --text-primary: #1A1040;
  --text-secondary: #5B4E8A;
  --text-tertiary: #8B7EC0;
  --text-muted: #B0A8D0;
  --text-accent: #7C3AED;

  --shadow-sm: 0 2px 8px rgba(100, 80, 200, 0.08);
  --shadow-md: 0 4px 20px rgba(100, 80, 200, 0.12);
  --shadow-lg: 0 8px 40px rgba(100, 80, 200, 0.16);
  --shadow-xl: 0 16px 60px rgba(100, 80, 200, 0.20);
}

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-body);
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  transition: background var(--transition-slow), color var(--transition-slow);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

button {
  cursor: pointer;
  border: none;
  background: none;
  font-family: var(--font-body);
  color: inherit;
  transition: all var(--transition-base);
}

input, textarea, select {
  font-family: var(--font-body);
  color: var(--text-primary);
  background: var(--bg-glass);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-md);
  outline: none;
  transition: all var(--transition-base);
}

input:focus, textarea:focus, select:focus {
  border-color: var(--aura-violet);
  box-shadow: 0 0 0 3px rgba(167, 139, 250, 0.15);
}

a {
  color: var(--text-accent);
  text-decoration: none;
}

/* ============================================================
   SPLASH SCREEN
============================================================ */
#splash-screen {
  position: fixed;
  inset: 0;
  background: var(--bg-primary);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  gap: var(--space-md);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

#splash-screen.fade-out {
  opacity: 0;
  transform: scale(1.05);
  pointer-events: none;
}

.splash-logo {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  animation: splashLogoIn 0.8s var(--transition-spring) forwards;
}

.splash-icon {
  width: 72px;
  height: 72px;
  animation: splashRotate 3s linear infinite;
}

.splash-icon svg {
  width: 100%;
  height: 100%;
  filter: drop-shadow(0 0 20px rgba(167, 139, 250, 0.5));
}

.splash-wordmark {
  font-family: var(--font-display);
  font-size: 48px;
  font-weight: 800;
  background: var(--grad-aurora);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: 0.1em;
}

.splash-tagline {
  font-family: var(--font-body);
  font-size: 14px;
  color: var(--text-tertiary);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  animation: fadeInUp 0.8s 0.3s ease forwards;
  opacity: 0;
}

.splash-loader {
  width: 200px;
  height: 2px;
  background: var(--border-subtle);
  border-radius: var(--radius-full);
  overflow: hidden;
  margin-top: var(--space-xl);
  animation: fadeInUp 0.8s 0.5s ease forwards;
  opacity: 0;
}

.splash-loader-bar {
  height: 100%;
  background: var(--grad-primary);
  border-radius: var(--radius-full);
  animation: splashLoad 2s ease forwards;
}

@keyframes splashLoad {
  0% { width: 0%; }
  30% { width: 40%; }
  70% { width: 75%; }
  100% { width: 100%; }
}

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

@keyframes splashRotate {
  0%, 100% { transform: rotate(0deg); }
  25% { transform: rotate(5deg); }
  75% { transform: rotate(-5deg); }
}

/* ============================================================
   APP WRAPPER
============================================================ */
#app {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  transition: opacity 0.5s ease;
}

#app.app-hidden {
  opacity: 0;
  pointer-events: none;
}

#app.app-visible {
  opacity: 1;
  pointer-events: all;
}

/* ============================================================
   TOP NAVIGATION
============================================================ */
.top-nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--nav-height);
  background: rgba(10, 10, 15, 0.85);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 var(--space-lg);
  z-index: 100;
  transition: background var(--transition-slow);
}

[data-theme="light"] .top-nav {
  background: rgba(248, 247, 255, 0.85);
}

.nav-left, .nav-right {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  min-width: 160px;
}

.nav-right {
  justify-content: flex-end;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  cursor: pointer;
}

.nav-logo-icon {
  width: 32px;
  height: 32px;
}

.nav-wordmark {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 800;
  background: var(--grad-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: 0.08em;
}

.nav-center {
  flex: 1;
  display: flex;
  justify-content: center;
}

.feed-toggle-group {
  display: flex;
  background: var(--bg-glass);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  padding: 3px;
  gap: 2px;
}

.feed-toggle-btn {
  padding: 6px 16px;
  border-radius: var(--radius-full);
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  transition: all var(--transition-base);
  white-space: nowrap;
}

.feed-toggle-btn.active {
  background: var(--grad-primary);
  color: white;
  box-shadow: var(--shadow-glow-violet);
}

.feed-toggle-btn:hover:not(.active) {
  color: var(--text-primary);
  background: var(--bg-glass-hover);
}

.nav-icon-btn {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  background: var(--bg-glass);
  border: 1px solid var(--border-subtle);
  position: relative;
  transition: all var(--transition-base);
}

.nav-icon-btn:hover {
  color: var(--text-primary);
  background: var(--bg-glass-hover);
  border-color: var(--border-medium);
}

.nav-icon-btn svg {
  width: 18px;
  height: 18px;
}

.notification-btn {
  position: relative;
}

.notif-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  background: var(--aura-pink);
  color: white;
  font-size: 10px;
  font-weight: 700;
  min-width: 18px;
  height: 18px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
  border: 2px solid var(--bg-primary);
}

.nav-avatar {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-full);
  overflow: hidden;
  cursor: pointer;
  position: relative;
  border: 2px solid transparent;
  background: var(--grad-primary);
  padding: 2px;
  transition: all var(--transition-base);
}

.nav-avatar:hover {
  transform: scale(1.05);
  box-shadow: var(--shadow-glow-violet);
}

.nav-avatar img {
  width: 100%;
  height: 100%;
  border-radius: var(--radius-full);
  object-fit: cover;
}

.avatar-status-dot {
  position: absolute;
  bottom: 1px;
  right: 1px;
  width: 9px;
  height: 9px;
  background: var(--aura-green);
  border-radius: var(--radius-full);
  border: 2px solid var(--bg-primary);
}

/* ============================================================
   MAIN CONTENT
============================================================ */
.main-content {
  margin-top: var(--nav-height);
  margin-bottom: var(--bottom-nav-height);
  min-height: calc(100vh - var(--nav-height) - var(--bottom-nav-height));
  position: relative;
}

/* Pages */
.page {
  display: none;
  animation: pageIn 0.3s ease forwards;
}

.page.active {
  display: block;
}

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

/* ============================================================
   HOME FEED
============================================================ */

/* Stories */
.stories-section {
  padding: var(--space-md) 0;
  border-bottom: 1px solid var(--border-subtle);
  background: var(--bg-secondary);
}

.stories-scroll {
  display: flex;
  gap: var(--space-md);
  padding: 0 var(--space-md);
  overflow-x: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.stories-scroll::-webkit-scrollbar { display: none; }

.story-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  flex-shrink: 0;
  transition: transform var(--transition-base);
}

.story-item:hover {
  transform: scale(1.05);
}

.story-item span {
  font-size: 11px;
  color: var(--text-secondary);
  max-width: 64px;
  text-align: center;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.story-avatar-wrap {
  width: 64px;
  height: 64px;
  border-radius: var(--radius-full);
  position: relative;
  padding: 2px;
}

.story-avatar-wrap.has-story {
  padding: 2px;
}

.story-avatar-wrap.gradient-1 { background: linear-gradient(135deg, #A78BFA, #06B6D4); }
.story-avatar-wrap.gradient-2 { background: linear-gradient(135deg, #F472B6, #A78BFA); }
.story-avatar-wrap.gradient-3 { background: linear-gradient(135deg, #F59E0B, #F472B6); }
.story-avatar-wrap.gradient-4 { background: linear-gradient(135deg, #10B981, #06B6D4); }
.story-avatar-wrap.gradient-5 { background: linear-gradient(135deg, #3B82F6, #A78BFA); }

.story-avatar-wrap img {
  width: 100%;
  height: 100%;
  border-radius: var(--radius-full);
  object-fit: cover;
  border: 2px solid var(--bg-primary);
}

.story-add-btn {
  width: 60px;
  height: 60px;
  border-radius: var(--radius-full);
  background: var(--bg-glass);
  border: 2px dashed var(--border-medium);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-accent);
  transition: all var(--transition-base);
}

.story-add-btn:hover {
  background: var(--bg-glass-hover);
  border-color: var(--aura-violet);
}

.story-add-btn svg {
  width: 20px;
  height: 20px;
}

.story-live-badge {
  position: absolute;
  bottom: -2px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--aura-red);
  color: white;
  font-size: 8px;
  font-weight: 700;
  padding: 1px 5px;
  border-radius: var(--radius-full);
  letter-spacing: 0.05em;
  border: 1px solid var(--bg-primary);
}

/* AI Banner */
.ai-banner {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  padding: var(--space-md) var(--space-lg);
  background: linear-gradient(135deg, rgba(167, 139, 250, 0.08), rgba(6, 182, 212, 0.08));
  border-bottom: 1px solid var(--border-subtle);
}

.ai-banner-icon {
  font-size: 20px;
  background: var(--grad-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  flex-shrink: 0;
}

.ai-banner-text {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.ai-banner-text strong {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
}

.ai-banner-text span {
  font-size: 12px;
  color: var(--text-secondary);
}

.ai-banner-why {
  font-size: 12px;
  color: var(--aura-violet);
  font-weight: 500;
  padding: 4px 12px;
  border: 1px solid rgba(167, 139, 250, 0.3);
  border-radius: var(--radius-full);
  white-space: nowrap;
  transition: all var(--transition-base);
}

.ai-banner-why:hover {
  background: rgba(167, 139, 250, 0.1);
}

/* Feed Container */
.feed-container {
  max-width: var(--content-max-width);
  margin: 0 auto;
  padding: var(--space-md) 0;
}

/* Post Card */
.post-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  margin: 0 var(--space-md) var(--space-lg);
  overflow: hidden;
  transition: all var(--transition-base);
  animation: postIn 0.4s ease forwards;
}

.post-card:hover {
  border-color: var(--border-medium);
  box-shadow: var(--shadow-md);
}

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

.post-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-md);
}

.post-author {
  display: flex;
  align-items: center;
  gap: var(--space-md);
}

.post-avatar-wrap {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-full);
  padding: 2px;
  position: relative;
  flex-shrink: 0;
}

.post-avatar-wrap img {
  width: 100%;
  height: 100%;
  border-radius: var(--radius-full);
  object-fit: cover;
  border: 2px solid var(--bg-card);
}

.verified-badge {
  position: absolute;
  bottom: -1px;
  right: -1px;
  width: 16px;
  height: 16px;
  background: var(--aura-violet);
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 8px;
  color: white;
  font-weight: 700;
  border: 1.5px solid var(--bg-card);
}

.post-author-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.trust-score {
  font-size: 11px;
  color: var(--aura-cyan);
  font-weight: 500;
  font-family: var(--font-mono);
}

.creator-badge {
  font-size: 10px;
  background: linear-gradient(135deg, rgba(167, 139, 250, 0.2), rgba(6, 182, 212, 0.2));
  color: var(--aura-violet);
  padding: 2px 8px;
  border-radius: var(--radius-full);
  border: 1px solid rgba(167, 139, 250, 0.3);
  font-weight: 600;
}

.post-meta {
  font-size: 12px;
  color: var(--text-tertiary);
}

.post-actions-top {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.post-follow-btn {
  font-size: 13px;
  font-weight: 600;
  color: var(--aura-violet);
  padding: 5px 14px;
  border: 1px solid rgba(167, 139, 250, 0.4);
  border-radius: var(--radius-full);
  transition: all var(--transition-base);
}

.post-follow-btn:hover {
  background: rgba(167, 139, 250, 0.1);
}

.post-follow-btn.following {
  color: var(--text-secondary);
  border-color: var(--border-medium);
}

.post-more-btn {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-tertiary);
  transition: all var(--transition-base);
}

.post-more-btn:hover {
  background: var(--bg-glass);
  color: var(--text-primary);
}

.post-more-btn svg {
  width: 16px;
  height: 16px;
}

/* Post Media */
.post-media {
  position: relative;
  overflow: hidden;
  background: var(--bg-tertiary);
}

.post-media img {
  width: 100%;
  max-height: 600px;
  object-fit: cover;
  transition: transform var(--transition-slow);
}

.post-card:hover .post-media img {
  transform: scale(1.01);
}

.post-media-overlay {
  position: absolute;
  inset: 0;
  background: transparent;
  display: flex;
  align-items: flex-start;
  justify-content: flex-end;
  padding: var(--space-md);
  opacity: 0;
  transition: opacity var(--transition-base);
}

.post-card:hover .post-media-overlay {
  opacity: 1;
}

.media-expand-btn {
  width: 36px;
  height: 36px;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(8px);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  transition: all var(--transition-base);
}

.media-expand-btn svg {
  width: 16px;
  height: 16px;
}

.post-ai-tag {
  position: absolute;
  top: var(--space-md);
  left: var(--space-md);
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(167, 139, 250, 0.3);
  border-radius: var(--radius-full);
  padding: 3px 10px;
}

.post-ai-tag span {
  font-size: 11px;
  font-weight: 600;
  background: var(--grad-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Video Post */
.video-media {
  position: relative;
}

.video-play-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.2);
}

.video-play-btn {
  width: 64px;
  height: 64px;
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(10px);
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  border: 2px solid rgba(255, 255, 255, 0.3);
  transition: all var(--transition-base);
}

.video-play-btn:hover {
  background: rgba(255, 255, 255, 0.25);
  transform: scale(1.1);
}

.video-play-btn svg {
  width: 24px;
  height: 24px;
  margin-left: 3px;
}

.video-duration {
  position: absolute;
  bottom: var(--space-md);
  right: var(--space-md);
  background: rgba(0, 0, 0, 0.6);
  color: white;
  font-size: 12px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: var(--radius-sm);
  font-family: var(--font-mono);
}

.video-progress-bar {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: rgba(255, 255, 255, 0.2);
}

.video-progress-fill {
  height: 100%;
  background: var(--grad-primary);
  border-radius: var(--radius-full);
}

/* Carousel */
.carousel-media {
  position: relative;
  overflow: hidden;
}

.carousel-track {
  display: flex;
  transition: transform var(--transition-slow);
}

.carousel-track img {
  min-width: 100%;
  max-height: 500px;
  object-fit: cover;
}

.carousel-dots {
  position: absolute;
  bottom: var(--space-md);
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 5px;
}

.dot {
  width: 6px;
  height: 6px;
  border-radius: var(--radius-full);
  background: rgba(255, 255, 255, 0.4);
  transition: all var(--transition-base);
}

.dot.active {
  background: white;
  width: 18px;
}

.carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 36px;
  height: 36px;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(8px);
  border-radius: var(--radius-full);
  color: white;
  font-size: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-base);
  z-index: 2;
}

.carousel-btn:hover {
  background: rgba(0, 0, 0, 0.7);
}

.carousel-prev { left: var(--space-md); }
.carousel-next { right: var(--space-md); }

.carousel-counter {
  position: absolute;
  top: var(--space-md);
  right: var(--space-md);
  background: rgba(0, 0, 0, 0.5);
  color: white;
  font-size: 12px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: var(--radius-full);
  font-family: var(--font-mono);
}

/* Post Engagement */
.post-engagement {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-md) var(--space-md) var(--space-sm);
}

.engagement-left, .engagement-right {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.engage-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  border-radius: var(--radius-md);
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  transition: all var(--transition-base);
}

.engage-btn:hover {
  color: var(--text-primary);
  background: var(--bg-glass);
}

.engage-btn svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.like-btn:hover {
  color: var(--aura-pink);
}

.like-btn[data-liked="true"] .heart-icon,
.like-btn .heart-icon.liked {
  fill: var(--aura-pink);
  stroke: var(--aura-pink);
  color: var(--aura-pink);
}

.like-btn[data-liked="true"] {
  color: var(--aura-pink);
}

.save-btn[data-saved="true"] svg,
.save-btn svg.saved {
  fill: var(--aura-violet);
  stroke: var(--aura-violet);
  color: var(--aura-violet);
}

.tip-btn {
  color: var(--aura-amber);
  border: 1px solid rgba(245, 158, 11, 0.3);
  border-radius: var(--radius-full);
}

.tip-btn:hover {
  background: rgba(245, 158, 11, 0.1);
  color: var(--aura-amber);
}

/* Post Caption */
.post-caption {
  padding: 0 var(--space-md) var(--space-sm);
  font-size: 14px;
  line-height: 1.5;
}

.caption-author {
  font-weight: 700;
  color: var(--text-primary);
  margin-right: 6px;
}

.caption-text {
  color: var(--text-secondary);
}

.caption-hashtags {
  color: var(--aura-violet);
  font-weight: 500;
}

/* AI Insight */
.post-ai-insight {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-sm) var(--space-md);
  background: linear-gradient(135deg, rgba(167, 139, 250, 0.05), rgba(6, 182, 212, 0.05));
  border-top: 1px solid var(--border-subtle);
  font-size: 12px;
  color: var(--text-tertiary);
}

.ai-insight-icon {
  font-size: 14px;
  background: var(--grad-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  flex-shrink: 0;
}

.post-ai-insight strong {
  color: var(--text-secondary);
}

/* Comments Preview */
.post-comments-preview {
  padding: var(--space-sm) var(--space-md) var(--space-md);
}

.comment-item {
  font-size: 13px;
  margin-bottom: 4px;
}

.comment-author {
  font-weight: 600;
  color: var(--text-primary);
  margin-right: 6px;
}

.comment-text {
  color: var(--text-secondary);
}

.view-comments-btn {
  font-size: 13px;
  color: var(--text-tertiary);
  margin-top: 4px;
  transition: color var(--transition-base);
}

.view-comments-btn:hover {
  color: var(--text-secondary);
}

/* Skeleton Loader */
.skeleton-post {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  margin: 0 var(--space-md) var(--space-lg);
  overflow: hidden;
  padding: var(--space-md);
}

.skeleton-header {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  margin-bottom: var(--space-md);
}

.skeleton-avatar {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-full);
  background: var(--bg-glass);
  animation: shimmer 1.5s infinite;
}

.skeleton-lines {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.skeleton-line {
  height: 12px;
  background: var(--bg-glass);
  border-radius: var(--radius-sm);
  animation: shimmer 1.5s infinite;
}

.skeleton-line.w-40 { width: 40%; }
.skeleton-line.w-25 { width: 25%; }
.skeleton-line.w-60 { width: 60%; }
.skeleton-line.w-80 { width: 80%; }

.skeleton-media {
  height: 300px;
  background: var(--bg-glass);
  border-radius: var(--radius-lg);
  margin-bottom: var(--space-md);
  animation: shimmer 1.5s infinite;
}

.skeleton-footer {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

@keyframes shimmer {
  0% { opacity: 0.5; }
  50% { opacity: 1; }
  100% { opacity: 0.5; }
}

/* ============================================================
   EXPLORE PAGE
============================================================ */
.explore-header {
  padding: var(--space-md);
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-subtle);
  position: sticky;
  top: var(--nav-height);
  z-index: 50;
}

.search-bar-container {
  margin-bottom: var(--space-md);
}

.search-bar {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  background: var(--bg-glass);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-full);
  padding: 10px var(--space-md);
  transition: all var(--transition-base);
}

.search-bar:focus-within {
  border-color: var(--aura-violet);
  box-shadow: 0 0 0 3px rgba(167, 139, 250, 0.1);
}

.search-icon {
  width: 18px;
  height: 18px;
  color: var(--text-tertiary);
  flex-shrink: 0;
}

.search-input {
  flex: 1;
  background: none;
  border: none;
  font-size: 15px;
  color: var(--text-primary);
  outline: none;
  box-shadow: none;
}

.search-input::placeholder {
  color: var(--text-tertiary);
}

.search-ai-btn {
  font-size: 12px;
  font-weight: 600;
  background: var(--grad-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  white-space: nowrap;
  padding: 4px 10px;
  border: 1px solid rgba(167, 139, 250, 0.3);
  border-radius: var(--radius-full);
  transition: all var(--transition-base);
}

.search-ai-btn:hover {
  background: rgba(167, 139, 250, 0.1);
}

.explore-filters {
  display: flex;
  gap: var(--space-sm);
  overflow-x: auto;
  scrollbar-width: none;
  padding-bottom: 2px;
}

.explore-filters::-webkit-scrollbar { display: none; }

.filter-chip {
  padding: 6px 16px;
  border-radius: var(--radius-full);
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  background: var(--bg-glass);
  border: 1px solid var(--border-subtle);
  white-space: nowrap;
  transition: all var(--transition-base);
  flex-shrink: 0;
}

.filter-chip.active {
  background: var(--grad-primary);
  color: white;
  border-color: transparent;
}

.filter-chip:hover:not(.active) {
  color: var(--text-primary);
  border-color: var(--border-medium);
}

/* Trending */
.trending-section {
  padding: var(--space-lg) var(--space-md) var(--space-md);
}

.section-title {
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: var(--space-md);
}

.trending-chips {
  display: flex;
  gap: var(--space-sm);
  overflow-x: auto;
  scrollbar-width: none;
}

.trending-chips::-webkit-scrollbar { display: none; }

.trending-chip {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: var(--space-sm) var(--space-md);
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  flex-shrink: 0;
  cursor: pointer;
  transition: all var(--transition-base);
}

.trending-chip:hover {
  border-color: var(--border-accent);
  background: var(--bg-card-hover);
}

.trend-rank {
  font-size: 10px;
  color: var(--text-tertiary);
  font-family: var(--font-mono);
}

.trend-name {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
}

.trend-count {
  font-size: 11px;
  color: var(--text-tertiary);
}

/* Explore Grid */
.explore-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2px;
  padding: 0 var(--space-md) var(--space-md);
}

.explore-item {
  position: relative;
  overflow: hidden;
  cursor: pointer;
  aspect-ratio: 1;
  background: var(--bg-tertiary);
}

.explore-item.large {
  grid-column: span 2;
  aspect-ratio: auto;
}

.explore-item.tall {
  grid-row: span 2;
  aspect-ratio: auto;
}

.explore-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-slow);
}

.explore-item:hover img {
  transform: scale(1.05);
}

.explore-item-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity var(--transition-base);
}

.explore-item:hover .explore-item-overlay {
  opacity: 1;
}

.explore-item-stats {
  display: flex;
  gap: var(--space-md);
  color: white;
  font-size: 13px;
  font-weight: 600;
}

.explore-item-type {
  position: absolute;
  top: var(--space-sm);
  right: var(--space-sm);
  background: rgba(0, 0, 0, 0.6);
  color: white;
  font-size: 11px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: var(--radius-sm);
}

/* ============================================================
   REELS PAGE
============================================================ */
.reels-container {
  height: calc(100vh - var(--nav-height) - var(--bottom-nav-height));
  overflow: hidden;
  position: relative;
}

.reel-item {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: #000;
}

.reel-bg {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.reel-gradient-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(0,0,0,0.3) 0%,
    transparent 30%,
    transparent 50%,
    rgba(0,0,0,0.7) 100%
  );
}

.reel-sidebar {
  position: absolute;
  right: var(--space-md);
  bottom: 120px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-lg);
}

.reel-author-avatar {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-full);
  overflow: hidden;
  border: 2px solid white;
  position: relative;
}

.reel-author-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.reel-follow-plus {
  position: absolute;
  bottom: -8px;
  left: 50%;
  transform: translateX(-50%);
  width: 20px;
  height: 20px;
  background: var(--aura-pink);
  border-radius: var(--radius-full);
  color: white;
  font-size: 14px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid white;
}

.reel-action-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  color: white;
  font-size: 12px;
  font-weight: 600;
  text-shadow: 0 1px 3px rgba(0,0,0,0.5);
  transition: transform var(--transition-base);
}

.reel-action-btn:hover {
  transform: scale(1.1);
}

.reel-action-btn svg {
  width: 28px;
  height: 28px;
  filter: drop-shadow(0 1px 3px rgba(0,0,0,0.5));
}

.reel-action-btn.reel-like.active svg {
  fill: var(--aura-pink);
  stroke: var(--aura-pink);
}

.reel-tip-btn {
  color: var(--aura-amber);
}

.reel-audio-disc {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-full);
  overflow: hidden;
  border: 3px solid rgba(255,255,255,0.3);
  animation: discSpin 4s linear infinite;
}

.reel-audio-disc img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

@keyframes discSpin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.reel-bottom {
  position: absolute;
  bottom: 80px;
  left: var(--space-md);
  right: 80px;
}

.reel-author-info {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  margin-bottom: var(--space-sm);
}

.reel-username {
  font-size: 15px;
  font-weight: 700;
  color: white;
  text-shadow: 0 1px 3px rgba(0,0,0,0.5);
}

.reel-verified {
  width: 18px;
  height: 18px;
  background: var(--aura-violet);
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  color: white;
  font-weight: 700;
}

.reel-caption {
  font-size: 14px;
  color: rgba(255,255,255,0.9);
  line-height: 1.4;
  text-shadow: 0 1px 3px rgba(0,0,0,0.5);
  margin-bottom: var(--space-sm);
}

.reel-audio-info {
  display: flex;
  align-items: center;
  gap: 6px;
  color: rgba(255,255,255,0.8);
  font-size: 12px;
}

.reel-audio-scroll {
  overflow: hidden;
  white-space: nowrap;
  animation: audioScroll 8s linear infinite;
}

@keyframes audioScroll {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

.reel-progress {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: rgba(255,255,255,0.2);
}

.reel-progress-fill {
  height: 100%;
  background: white;
  transition: width 0.1s linear;
}

.reel-top-controls {
  position: absolute;
  top: var(--space-md);
  left: 0;
  right: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 var(--space-md);
}

.reel-top-btn {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-full);
  background: rgba(0,0,0,0.3);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
}

.reel-top-btn svg {
  width: 20px;
  height: 20px;
}

.reel-top-label {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 700;
  color: white;
  text-shadow: 0 1px 3px rgba(0,0,0,0.5);
}

/* ============================================================
   CREATE PAGE
============================================================ */
.create-container {
  max-width: 600px;
  margin: 0 auto;
  padding: var(--space-xl) var(--space-md);
}

.create-header {
  text-align: center;
  margin-bottom: var(--space-xl);
}

.create-title {
  font-family: var(--font-display);
  font-size: 28px;
  font-weight: 800;
  background: var(--grad-aurora);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: var(--space-sm);
}

.create-subtitle {
  font-size: 14px;
  color: var(--text-secondary);
}

.content-type-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-sm);
  margin-bottom: var(--space-xl);
}

.content-type-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-md);
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  transition: all var(--transition-base);
  cursor: pointer;
}

.content-type-card:hover {
  border-color: var(--border-accent);
  color: var(--text-primary);
  background: var(--bg-card-hover);
}

.content-type-card.active {
  border-color: var(--aura-violet);
  background: rgba(167, 139, 250, 0.08);
  color: var(--aura-violet);
}

.content-type-icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-md);
  background: var(--bg-glass);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-base);
}

.content-type-icon svg {
  width: 20px;
  height: 20px;
}

.content-type-card.active .content-type-icon {
  background: rgba(167, 139, 250, 0.15);
}

.live-icon {
  position: relative;
}

.live-icon::after {
  content: '';
  position: absolute;
  top: 4px;
  right: 4px;
  width: 8px;
  height: 8px;
  background: var(--aura-red);
  border-radius: var(--radius-full);
  animation: livePulse 1.5s infinite;
}

@keyframes livePulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(1.3); }
}

/* Upload Zone */
.upload-zone {
  border: 2px dashed var(--border-medium);
  border-radius: var(--radius-xl);
  padding: var(--space-3xl) var(--space-xl);
  text-align: center;
  margin-bottom: var(--space-xl);
  cursor: pointer;
  transition: all var(--transition-base);
  background: var(--bg-glass);
}

.upload-zone:hover {
  border-color: var(--aura-violet);
  background: rgba(167, 139, 250, 0.05);
}

.upload-zone-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-md);
}

.upload-icon-wrap {
  width: 64px;
  height: 64px;
  border-radius: var(--radius-xl);
  background: var(--bg-glass);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-tertiary);
}

.upload-icon-wrap svg {
  width: 28px;
  height: 28px;
}

.upload-title {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
}

.upload-subtitle {
  font-size: 13px;
  color: var(--text-tertiary);
}

.upload-btn {
  padding: 10px 24px;
  background: var(--grad-primary);
  color: white;
  border-radius: var(--radius-full);
  font-size: 14px;
  font-weight: 600;
  transition: all var(--transition-base);
}

.upload-btn:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-glow-violet);
}

/* AI Tools Panel */
.ai-tools-panel {
  background: var(--bg-card);
  border: 1px solid var(--border-accent);
  border-radius: var(--radius-xl);
  padding: var(--space-lg);
  margin-bottom: var(--space-xl);
}

.ai-tools-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-md);
}

.ai-tools-title {
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 700;
  background: var(--grad-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.ai-tools-badge {
  font-size: 11px;
  color: var(--text-tertiary);
  background: var(--bg-glass);
  padding: 3px 10px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border-subtle);
}

.ai-tools-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-sm);
}

.ai-tool-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: var(--space-md) var(--space-sm);
  background: var(--bg-glass);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  font-size: 11px;
  font-weight: 500;
  color: var(--text-secondary);
  transition: all var(--transition-base);
  cursor: pointer;
  text-align: center;
}

.ai-tool-btn:hover {
  background: var(--bg-glass-hover);
  border-color: var(--border-accent);
  color: var(--text-primary);
  transform: translateY(-2px);
}

.ai-tool-icon {
  font-size: 20px;
}

/* Caption Section */
.caption-section {
  margin-bottom: var(--space-xl);
}

.caption-input-wrap {
  position: relative;
  margin-bottom: var(--space-sm);
}

.caption-input {
  width: 100%;
  padding: var(--space-md);
  padding-right: 80px;
  background: var(--bg-card);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-lg);
  font-size: 14px;
  color: var(--text-primary);
  resize: none;
  line-height: 1.5;
}

.caption-input::placeholder {
  color: var(--text-tertiary);
}

.caption-ai-btn {
  position: absolute;
  top: var(--space-md);
  right: var(--space-md);
  font-size: 12px;
  font-weight: 600;
  background: var(--grad-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  padding: 4px 10px;
  border: 1px solid rgba(167, 139, 250, 0.3);
  border-radius: var(--radius-full);
  transition: all var(--transition-base);
}

.caption-tools {
  display: flex;
  gap: var(--space-sm);
  flex-wrap: wrap;
}

.caption-tool {
  font-size: 12px;
  color: var(--text-secondary);
  padding: 5px 12px;
  background: var(--bg-glass);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  transition: all var(--transition-base);
}

.caption-tool:hover {
  color: var(--text-primary);
  border-color: var(--border-medium);
}

/* Post Settings */
.post-settings {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  overflow: hidden;
  margin-bottom: var(--space-xl);
}

.setting-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-md) var(--space-lg);
  border-bottom: 1px solid var(--border-subtle);
}

.setting-row:last-child {
  border-bottom: none;
}

.setting-label {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-primary);
}

.setting-select {
  padding: 6px 12px;
  font-size: 13px;
  border-radius: var(--radius-md);
  cursor: pointer;
}

/* Toggle Switch */
.toggle-switch {
  position: relative;
  display: inline-block;
  width: 44px;
  height: 24px;
  cursor: pointer;
}

.toggle-switch input {
  opacity: 0;
  width: 0;
  height: 0;
  position: absolute;
}

.toggle-slider {
  position: absolute;
  inset: 0;
  background: var(--bg-glass);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-full);
  transition: all var(--transition-base);
}

.toggle-slider::before {
  content: '';
  position: absolute;
  width: 18px;
  height: 18px;
  left: 2px;
  top: 50%;
  transform: translateY(-50%);
  background: var(--text-tertiary);
  border-radius: var(--radius-full);
  transition: all var(--transition-base);
}

.toggle-switch input:checked + .toggle-slider {
  background: var(--grad-primary);
  border-color: transparent;
}

.toggle-switch input:checked + .toggle-slider::before {
  transform: translateX(20px) translateY(-50%);
  background: white;
}

/* Publish Button */
.publish-btn {
  width: 100%;
  padding: var(--space-md) var(--space-xl);
  background: var(--grad-primary);
  color: white;
  border-radius: var(--radius-full);
  font-size: 16px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  transition: all var(--transition-base);
  box-shadow: var(--shadow-glow-violet);
}

.publish-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(167, 139, 250, 0.4);
}

.publish-btn svg {
  width: 18px;
  height: 18px;
}

/* ============================================================
   MESSAGES PAGE
============================================================ */
.messages-layout {
  display: flex;
  height: calc(100vh - var(--nav-height) - var(--bottom-nav-height));
}

.conversations-panel {
  width: 360px;
  border-right: 1px solid var(--border-subtle);
  display: flex;
  flex-direction: column;
  background: var(--bg-secondary);
  flex-shrink: 0;
}

.conversations-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-lg) var(--space-md);
  border-bottom: 1px solid var(--border-subtle);
}

.conversations-header h2 {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
}

.conv-action-btn {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-full);
  background: var(--bg-glass);
  border: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  transition: all var(--transition-base);
}

.conv-action-btn:hover {
  color: var(--text-primary);
  background: var(--bg-glass-hover);
}

.conv-action-btn svg {
  width: 16px;
  height: 16px;
}

.conv-search {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-sm) var(--space-md);
  background: var(--bg-glass);
  border-bottom: 1px solid var(--border-subtle);
}

.conv-search svg {
  width: 16px;
  height: 16px;
  color: var(--text-tertiary);
  flex-shrink: 0;
}

.conv-search input {
  flex: 1;
  background: none;
  border: none;
  font-size: 14px;
  color: var(--text-primary);
  outline: none;
  box-shadow: none;
}

.conv-tabs {
  display: flex;
  padding: var(--space-sm) var(--space-md);
  gap: var(--space-sm);
  border-bottom: 1px solid var(--border-subtle);
}

.conv-tab {
  padding: 5px 14px;
  border-radius: var(--radius-full);
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  transition: all var(--transition-base);
}

.conv-tab.active {
  background: var(--grad-primary);
  color: white;
}

.conv-tab:hover:not(.active) {
  background: var(--bg-glass);
  color: var(--text-primary);
}

.conversations-list {
  flex: 1;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--border-subtle) transparent;
}

.conv-item {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  padding: var(--space-md);
  cursor: pointer;
  transition: all var(--transition-base);
  border-bottom: 1px solid var(--border-subtle);
}

.conv-item:hover {
  background: var(--bg-glass);
}

.conv-item.active {
  background: rgba(167, 139, 250, 0.08);
  border-left: 3px solid var(--aura-violet);
}

.conv-avatar-wrap {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-full);
  overflow: hidden;
  position: relative;
  flex-shrink: 0;
}

.conv-avatar-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.conv-online-dot {
  position: absolute;
  bottom: 2px;
  right: 2px;
  width: 10px;
  height: 10px;
  background: var(--aura-green);
  border-radius: var(--radius-full);
  border: 2px solid var(--bg-secondary);
}

.group-avatar {
  position: relative;
}

.group-avatar-extra {
  position: absolute;
  bottom: -2px;
  right: -2px;
  background: var(--aura-violet);
  color: white;
  font-size: 9px;
  font-weight: 700;
  padding: 1px 4px;
  border-radius: var(--radius-full);
  border: 1.5px solid var(--bg-secondary);
}

.conv-info {
  flex: 1;
  min-width: 0;
}

.conv-name-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 3px;
}

.conv-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
}

.conv-time {
  font-size: 11px;
  color: var(--text-tertiary);
}

.conv-preview-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.conv-preview {
  font-size: 13px;
  color: var(--text-tertiary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 180px;
}

.conv-unread {
  background: var(--aura-violet);
  color: white;
  font-size: 10px;
  font-weight: 700;
  min-width: 18px;
  height: 18px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
  flex-shrink: 0;
}

/* Chat Panel */
.chat-panel {
  flex: 1;
  display: flex;
  flex-direction: column;
  background: var(--bg-primary);
  min-width: 0;
}

.chat-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-md) var(--space-lg);
  border-bottom: 1px solid var(--border-subtle);
  background: var(--bg-secondary);
}

.chat-header-user {
  display: flex;
  align-items: center;
  gap: var(--space-md);
}

.chat-avatar-wrap {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-full);
  overflow: hidden;
  position: relative;
}

.chat-avatar-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.chat-username {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-primary);
  display: block;
}

.chat-status {
  font-size: 12px;
  color: var(--aura-green);
  display: block;
}

.chat-header-actions {
  display: flex;
  gap: var(--space-sm);
}

.chat-action-btn {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-full);
  background: var(--bg-glass);
  border: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  transition: all var(--transition-base);
}

.chat-action-btn:hover {
  color: var(--text-primary);
  background: var(--bg-glass-hover);
}

.chat-action-btn svg {
  width: 16px;
  height: 16px;
}

.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: var(--space-lg);
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
  scrollbar-width: thin;
  scrollbar-color: var(--border-subtle) transparent;
}

.chat-date-divider {
  text-align: center;
  position: relative;
  margin: var(--space-sm) 0;
}

.chat-date-divider::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  height: 1px;
  background: var(--border-subtle);
}

.chat-date-divider span {
  position: relative;
  background: var(--bg-primary);
  padding: 0 var(--space-md);
  font-size: 12px;
  color: var(--text-tertiary);
}

.message-bubble {
  display: flex;
  align-items: flex-end;
  gap: var(--space-sm);
  max-width: 70%;
  animation: msgIn 0.3s ease forwards;
}

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

.message-bubble.sent {
  align-self: flex-end;
  flex-direction: row-reverse;
}

.msg-avatar {
  width: 28px;
  height: 28px;
  border-radius: var(--radius-full);
  object-fit: cover;
  flex-shrink: 0;
}

.msg-content {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  border-bottom-left-radius: var(--radius-sm);
  padding: var(--space-sm) var(--space-md);
  position: relative;
}

.message-bubble.sent .msg-content {
  background: var(--grad-primary);
  border: none;
  border-radius: var(--radius-xl);
  border-bottom-right-radius: var(--radius-sm);
}

.msg-content p {
  font-size: 14px;
  color: var(--text-primary);
  line-height: 1.5;
}

.message-bubble.sent .msg-content p {
  color: white;
}

.msg-time {
  font-size: 10px;
  color: var(--text-tertiary);
  display: block;
  margin-top: 3px;
}

.message-bubble.sent .msg-time {
  color: rgba(255,255,255,0.6);
}

.msg-status {
  font-size: 10px;
  color: var(--aura-cyan);
  margin-left: 4px;
}

.typing-indicator {
  display: flex;
  align-items: flex-end;
  gap: var(--space-sm);
}

.typing-dots {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  border-bottom-left-radius: var(--radius-sm);
  padding: var(--space-md);
  display: flex;
  gap: 4px;
  align-items: center;
}

.typing-dots span {
  width: 6px;
  height: 6px;
  background: var(--text-tertiary);
  border-radius: var(--radius-full);
  animation: typingBounce 1.2s infinite;
}

.typing-dots span:nth-child(2) { animation-delay: 0.2s; }
.typing-dots span:nth-child(3) { animation-delay: 0.4s; }

@keyframes typingBounce {
  0%, 60%, 100% { transform: translateY(0); }
  30% { transform: translateY(-6px); }
}

.chat-input-area {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-md);
  border-top: 1px solid var(--border-subtle);
  background: var(--bg-secondary);
}

.chat-input-tools {
  display: flex;
  gap: 4px;
}

.chat-tool-btn {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-tertiary);
  transition: all var(--transition-base);
}

.chat-tool-btn:hover {
  color: var(--text-primary);
  background: var(--bg-glass);
}

.chat-tool-btn svg {
  width: 18px;
  height: 18px;
}

.chat-input-wrap {
  flex: 1;
  position: relative;
}

.chat-input {
  width: 100%;
  padding: 10px 40px 10px var(--space-md);
  background: var(--bg-card);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-full);
  font-size: 14px;
  color: var(--text-primary);
  outline: none;
}

.chat-input::placeholder {
  color: var(--text-tertiary);
}

.chat-ai-reply-btn {
  position: absolute;
  right: var(--space-sm);
  top: 50%;
  transform: translateY(-50%);
  font-size: 14px;
  background: var(--grad-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-weight: 700;
}

.chat-send-btn {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-full);
  background: var(--grad-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  flex-shrink: 0;
  transition: all var(--transition-base);
}

.chat-send-btn:hover {
  transform: scale(1.05);
  box-shadow: var(--shadow-glow-violet);
}

.chat-send-btn svg {
  width: 16px;
  height: 16px;
}

.smart-replies {
  display: flex;
  gap: var(--space-sm);
  padding: var(--space-sm) var(--space-md);
  overflow-x: auto;
  scrollbar-width: none;
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-subtle);
}

.smart-replies::-webkit-scrollbar { display: none; }

.smart-reply-chip {
  padding: 6px 14px;
  background: var(--bg-glass);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-full);
  font-size: 13px;
  color: var(--text-secondary);
  white-space: nowrap;
  flex-shrink: 0;
  transition: all var(--transition-base);
}

.smart-reply-chip:hover {
  background: rgba(167, 139, 250, 0.1);
  border-color: var(--border-accent);
  color: var(--aura-violet);
}

/* ============================================================
   PROFILE PAGE
============================================================ */
.profile-container {
  max-width: 900px;
  margin: 0 auto;
}

.profile-header {
  position: relative;
}

.profile-cover {
  height: 220px;
  overflow: hidden;
  position: relative;
}

.cover-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cover-gradient {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 120px;
  background: linear-gradient(to top, var(--bg-primary), transparent);
}

.profile-info-section {
  padding: 0 var(--space-lg) var(--space-lg);
  display: flex;
  align-items: flex-end;
  gap: var(--space-lg);
  flex-wrap: wrap;
  margin-top: -60px;
  position: relative;
}

.profile-avatar-section {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-sm);
}

.profile-avatar-wrap {
  width: 120px;
  height: 120px;
  border-radius: var(--radius-full);
  position: relative;
  padding: 3px;
  background: var(--grad-aurora);
}

.profile-avatar-wrap img {
  width: 100%;
  height: 100%;
  border-radius: var(--radius-full);
  object-fit: cover;
  border: 3px solid var(--bg-primary);
}

.profile-avatar-ring {
  position: absolute;
  inset: -3px;
  border-radius: var(--radius-full);
  background: var(--grad-aurora);
  z-index: -1;
  animation: ringPulse 3s ease infinite;
}

@keyframes ringPulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.6; }
}

.profile-avatar-edit {
  position: absolute;
  bottom: 4px;
  right: 4px;
  width: 28px;
  height: 28px;
  background: var(--bg-card);
  border: 2px solid var(--bg-primary);
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  transition: all var(--transition-base);
}

.profile-avatar-edit:hover {
  color: var(--text-primary);
  background: var(--bg-card-hover);
}

.profile-avatar-edit svg {
  width: 12px;
  height: 12px;
}

.profile-badges {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
  justify-content: center;
}

.profile-badge {
  font-size: 10px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: var(--radius-full);
}

.profile-badge.verified {
  background: rgba(167, 139, 250, 0.15);
  color: var(--aura-violet);
  border: 1px solid rgba(167, 139, 250, 0.3);
}

.profile-badge.creator {
  background: rgba(6, 182, 212, 0.15);
  color: var(--aura-cyan);
  border: 1px solid rgba(6, 182, 212, 0.3);
}

.profile-badge.trust {
  background: rgba(16, 185, 129, 0.15);
  color: var(--aura-green);
  border: 1px solid rgba(16, 185, 129, 0.3);
  font-family: var(--font-mono);
}

.profile-details {
  flex: 1;
  min-width: 200px;
  padding-top: 60px;
}

.profile-name {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.profile-username {
  font-size: 14px;
  color: var(--text-secondary);
  margin-bottom: var(--space-sm);
}

.profile-joined {
  color: var(--text-tertiary);
}

.profile-bio {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: var(--space-sm);
}

.profile-links {
  display: flex;
  gap: var(--space-md);
  flex-wrap: wrap;
}

.profile-link {
  font-size: 13px;
  color: var(--aura-violet);
  font-weight: 500;
  transition: color var(--transition-base);
}

.profile-link:hover {
  color: var(--aura-cyan);
}

.profile-actions {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  padding-top: 60px;
}

.profile-edit-btn {
  padding: 8px 20px;
  background: var(--bg-glass);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-full);
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  transition: all var(--transition-base);
}

.profile-edit-btn:hover {
  background: var(--bg-glass-hover);
  border-color: var(--border-strong);
}

.profile-share-btn, .profile-more-btn {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-full);
  background: var(--bg-glass);
  border: 1px solid var(--border-medium);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  transition: all var(--transition-base);
}

.profile-share-btn:hover, .profile-more-btn:hover {
  color: var(--text-primary);
  background: var(--bg-glass-hover);
}

.profile-share-btn svg, .profile-more-btn svg {
  width: 16px;
  height: 16px;
}

/* Profile Stats */
.profile-stats {
  display: flex;
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
  background: var(--bg-secondary);
}

.stat-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: var(--space-lg) var(--space-md);
  cursor: pointer;
  transition: background var(--transition-base);
  border-right: 1px solid var(--border-subtle);
}

.stat-item:last-child {
  border-right: none;
}

.stat-item:hover {
  background: var(--bg-glass);
}

.stat-number {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 800;
  color: var(--text-primary);
}

.stat-label {
  font-size: 12px;
  color: var(--text-tertiary);
  margin-top: 2px;
}

/* Creator Analytics Strip */
.creator-analytics-strip {
  display: flex;
  align-items: center;
  gap: var(--space-lg);
  padding: var(--space-md) var(--space-lg);
  background: linear-gradient(135deg, rgba(167, 139, 250, 0.05), rgba(6, 182, 212, 0.05));
  border-bottom: 1px solid var(--border-subtle);
  overflow-x: auto;
  scrollbar-width: none;
}

.creator-analytics-strip::-webkit-scrollbar { display: none; }

.analytics-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex-shrink: 0;
}

.analytics-value {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 700;
  color: var(--text-primary);
}

.analytics-value.positive {
  color: var(--aura-green);
}

.analytics-label {
  font-size: 11px;
  color: var(--text-tertiary);
}

.analytics-full-btn {
  margin-left: auto;
  font-size: 13px;
  color: var(--aura-violet);
  font-weight: 600;
  white-space: nowrap;
  flex-shrink: 0;
  padding: 6px 14px;
  border: 1px solid rgba(167, 139, 250, 0.3);
  border-radius: var(--radius-full);
  transition: all var(--transition-base);
}

.analytics-full-btn:hover {
  background: rgba(167, 139, 250, 0.1);
}

/* Profile Tabs */
.profile-tabs {
  display: flex;
  border-bottom: 1px solid var(--border-subtle);
  background: var(--bg-secondary);
}

.profile-tab {
  flex: 1;
  padding: var(--space-md);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-tertiary);
  border-bottom: 2px solid transparent;
  transition: all var(--transition-base);
}

.profile-tab:hover {
  color: var(--text-secondary);
}

.profile-tab.active {
  color: var(--text-primary);
  border-bottom-color: var(--aura-violet);
}

.profile-tab svg {
  width: 20px;
  height: 20px;
}

/* Profile Grid */
.profile-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2px;
}

.profile-grid-item {
  position: relative;
  aspect-ratio: 1;
  overflow: hidden;
  cursor: pointer;
  background: var(--bg-tertiary);
}

.profile-grid-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-slow);
}

.profile-grid-item:hover img {
  transform: scale(1.05);
}

.grid-item-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity var(--transition-base);
  color: white;
  font-size: 14px;
  font-weight: 600;
}

.profile-grid-item:hover .grid-item-overlay {
  opacity: 1;
}

.grid-item-type {
  position: absolute;
  top: var(--space-sm);
  right: var(--space-sm);
  color: white;
  font-size: 16px;
  text-shadow: 0 1px 3px rgba(0,0,0,0.5);
}

/* ============================================================
   COMMUNITIES PAGE
============================================================ */
.communities-container {
  max-width: 800px;
  margin: 0 auto;
  padding: var(--space-xl) var(--space-md);
}

.communities-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-xl);
}

.communities-header h2 {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 800;
}

.create-community-btn {
  padding: 8px 20px;
  background: var(--grad-primary);
  color: white;
  border-radius: var(--radius-full);
  font-size: 14px;
  font-weight: 600;
  transition: all var(--transition-base);
}

.create-community-btn:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-glow-violet);
}

.communities-section {
  margin-bottom: var(--space-2xl);
}

.communities-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

.community-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  overflow: hidden;
  transition: all var(--transition-base);
}

.community-card:hover {
  border-color: var(--border-medium);
  box-shadow: var(--shadow-md);
}

.community-card.featured {
  border-color: var(--border-accent);
}

.community-cover {
  height: 100px;
  overflow: hidden;
}

.community-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.community-info {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  padding: var(--space-md);
  flex-wrap: wrap;
}

.community-icon-wrap {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-lg);
  background: var(--bg-glass);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  flex-shrink: 0;
}

.community-details {
  flex: 1;
  min-width: 150px;
}

.community-details h4 {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 3px;
}

.community-details p {
  font-size: 12px;
  color: var(--text-tertiary);
  margin-bottom: var(--space-sm);
}

.community-tags {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
}

.community-tag {
  font-size: 11px;
  padding: 2px 8px;
  background: var(--bg-glass);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  color: var(--text-secondary);
}

.community-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: var(--space-sm);
}

.community-join-btn {
  padding: 7px 18px;
  background: var(--grad-primary);
  color: white;
  border-radius: var(--radius-full);
  font-size: 13px;
  font-weight: 600;
  transition: all var(--transition-base);
}

.community-join-btn.joined {
  background: var(--bg-glass);
  color: var(--aura-green);
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.community-join-btn:hover:not(.joined) {
  transform: translateY(-1px);
  box-shadow: var(--shadow-glow-violet);
}

.community-rep {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.rep-badge {
  font-size: 10px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: var(--radius-full);
}

.rep-badge.expert {
  background: rgba(245, 158, 11, 0.15);
  color: var(--aura-amber);
  border: 1px solid rgba(245, 158, 11, 0.3);
}

.rep-badge.contributor {
  background: rgba(167, 139, 250, 0.15);
  color: var(--aura-violet);
  border: 1px solid rgba(167, 139, 250, 0.3);
}

.rep-score {
  font-size: 11px;
  color: var(--text-tertiary);
  font-family: var(--font-mono);
}

/* Discover Communities Grid */
.discover-communities-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-md);
}

.discover-community-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  overflow: hidden;
  cursor: pointer;
  transition: all var(--transition-base);
}

.discover-community-card:hover {
  border-color: var(--border-accent);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.discover-community-card img {
  width: 100%;
  height: 100px;
  object-fit: cover;
}

.discover-community-info {
  padding: var(--space-md);
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.discover-community-icon {
  font-size: 20px;
}

.discover-community-info h4 {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-primary);
}

.discover-community-info p {
  font-size: 12px;
  color: var(--text-tertiary);
  margin-bottom: var(--space-sm);
}

/* Challenges */
.challenges-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

.challenge-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: var(--space-lg);
  transition: all var(--transition-base);
}

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

.challenge-header {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  margin-bottom: var(--space-md);
}

.challenge-emoji {
  font-size: 28px;
  flex-shrink: 0;
}

.challenge-info {
  flex: 1;
}

.challenge-info h4 {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 3px;
}

.challenge-info p {
  font-size: 12px;
  color: var(--text-tertiary);
}

.challenge-prize {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}

.prize-label {
  font-size: 10px;
  color: var(--text-tertiary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.prize-value {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 800;
  background: var(--grad-warm);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.challenge-progress {
  margin-bottom: var(--space-md);
}

.challenge-stats {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: var(--text-tertiary);
  margin-bottom: var(--space-sm);
}

.challenge-bar {
  height: 6px;
  background: var(--bg-glass);
  border-radius: var(--radius-full);
  overflow: hidden;
}

.challenge-bar-fill {
  height: 100%;
  background: var(--grad-primary);
  border-radius: var(--radius-full);
  transition: width 1s ease;
}

.challenge-enter-btn {
  width: 100%;
  padding: 10px;
  background: var(--grad-primary);
  color: white;
  border-radius: var(--radius-full);
  font-size: 14px;
  font-weight: 600;
  transition: all var(--transition-base);
}

.challenge-enter-btn:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-glow-violet);
}

/* ============================================================
   CREATOR STUDIO PAGE
============================================================ */
.studio-container {
  max-width: 1000px;
  margin: 0 auto;
  padding: var(--space-xl) var(--space-md);
}

.studio-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-xl);
}

.studio-header h2 {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 800;
}

.studio-period-selector {
  display: flex;
  background: var(--bg-glass);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  padding: 3px;
  gap: 2px;
}

.period-btn {
  padding: 5px 14px;
  border-radius: var(--radius-full);
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
  transition: all var(--transition-base);
}

.period-btn.active {
  background: var(--grad-primary);
  color: white;
}

.period-btn:hover:not(.active) {
  color: var(--text-primary);
}

/* Revenue Overview */
.revenue-overview {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-md);
  margin-bottom: var(--space-xl);
}

.revenue-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: var(--space-lg);
  display: flex;
  align-items: center;
  gap: var(--space-md);
  transition: all var(--transition-base);
}

.revenue-card:hover {
  border-color: var(--border-medium);
  box-shadow: var(--shadow-md);
}

.revenue-card.primary {
  background: linear-gradient(135deg, rgba(167, 139, 250, 0.1), rgba(6, 182, 212, 0.1));
  border-color: var(--border-accent);
}

.revenue-icon {
  font-size: 28px;
  flex-shrink: 0;
}

.revenue-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.revenue-label {
  font-size: 12px;
  color: var(--text-tertiary);
}

.revenue-amount {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 800;
  color: var(--text-primary);
}

.revenue-change {
  font-size: 12px;
  color: var(--text-tertiary);
}

.revenue-change.positive {
  color: var(--aura-green);
}

/* Analytics Chart */
.analytics-chart-section {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: var(--space-xl);
  margin-bottom: var(--space-xl);
}

.chart-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-xl);
}

.chart-header h3 {
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 700;
}

.chart-legend {
  display: flex;
  gap: var(--space-md);
}

.legend-item {
  font-size: 12px;
  font-weight: 500;
  padding: 3px 10px;
  border-radius: var(--radius-full);
}

.legend-item.reach {
  background: rgba(167, 139, 250, 0.15);
  color: var(--aura-violet);
}

.legend-item.engagement {
  background: rgba(6, 182, 212, 0.15);
  color: var(--aura-cyan);
}

.legend-item.followers {
  background: rgba(244, 114, 182, 0.15);
  color: var(--aura-pink);
}

.chart-container {
  position: relative;
  height: 200px;
}

.chart-bars {
  display: flex;
  align-items: flex-end;
  justify-content: space-around;
  height: 100%;
  gap: var(--space-sm);
}

.chart-bar-group {
  display: flex;
  align-items: flex-end;
  gap: 3px;
  flex: 1;
  position: relative;
  padding-bottom: 24px;
}

.chart-bar {
  flex: 1;
  border-radius: var(--radius-sm) var(--radius-sm) 0 0;
  min-height: 4px;
  transition: height 1s ease;
}

.reach-bar { background: var(--aura-violet); opacity: 0.8; }
.engagement-bar { background: var(--aura-cyan); opacity: 0.8; }
.followers-bar { background: var(--aura-pink); opacity: 0.8; }

.chart-label {
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  font-size: 11px;
  color: var(--text-tertiary);
  white-space: nowrap;
}

/* AI Assistant Panel */
.ai-assistant-panel {
  background: var(--bg-card);
  border: 1px solid var(--border-accent);
  border-radius: var(--radius-xl);
  padding: var(--space-xl);
  margin-bottom: var(--space-xl);
}

.ai-assistant-header {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  margin-bottom: var(--space-xl);
}

.ai-assistant-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-lg);
  background: var(--grad-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  color: white;
  flex-shrink: 0;
}

.ai-assistant-header h3 {
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 700;
  color: var(--text-primary);
}

.ai-assistant-header p {
  font-size: 13px;
  color: var(--text-tertiary);
}

.ai-insights-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

.ai-insight-card {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  padding: var(--space-md);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-subtle);
  transition: all var(--transition-base);
}

.ai-insight-card:hover {
  border-color: var(--border-medium);
}

.ai-insight-card.positive {
  background: rgba(16, 185, 129, 0.05);
  border-color: rgba(16, 185, 129, 0.2);
}

.ai-insight-card.warning {
  background: rgba(245, 158, 11, 0.05);
  border-color: rgba(245, 158, 11, 0.2);
}

.ai-insight-card.info {
  background: rgba(6, 182, 212, 0.05);
  border-color: rgba(6, 182, 212, 0.2);
}

.insight-icon {
  font-size: 24px;
  flex-shrink: 0;
}

.insight-content {
  flex: 1;
}

.insight-content strong {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  display: block;
  margin-bottom: 3px;
}

.insight-content p {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.4;
}

.insight-action-btn {
  padding: 6px 14px;
  background: var(--bg-glass);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-full);
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
  white-space: nowrap;
  flex-shrink: 0;
  transition: all var(--transition-base);
}

.insight-action-btn:hover {
  background: var(--grad-primary);
  color: white;
  border-color: transparent;
}

/* Monetization */
.monetization-section {
  margin-bottom: var(--space-xl);
}

.monetization-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-md);
}

.monetization-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: var(--space-lg);
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
  transition: all var(--transition-base);
  cursor: pointer;
}

.monetization-card:hover {
  border-color: var(--border-accent);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.monetization-card.active {
  border-color: var(--border-accent);
  background: rgba(167, 139, 250, 0.05);
}

.monetization-icon {
  font-size: 28px;
}

.monetization-card h4 {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-primary);
}

.monetization-card p {
  font-size: 12px;
  color: var(--text-tertiary);
  flex: 1;
}

.monetization-status {
  font-size: 11px;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: var(--radius-full);
  background: var(--bg-glass);
  color: var(--text-tertiary);
  border: 1px solid var(--border-subtle);
  align-self: flex-start;
}

.monetization-status.active-status {
  background: rgba(16, 185, 129, 0.15);
  color: var(--aura-green);
  border-color: rgba(16, 185, 129, 0.3);
}

.monetization-setup-btn {
  font-size: 12px;
  font-weight: 600;
  color: var(--aura-violet);
  padding: 5px 12px;
  border: 1px solid rgba(167, 139, 250, 0.3);
  border-radius: var(--radius-full);
  align-self: flex-start;
  transition: all var(--transition-base);
}

.monetization-setup-btn:hover {
  background: rgba(167, 139, 250, 0.1);
}

/* ============================================================
   LIVE PAGE
============================================================ */
.live-container {
  max-width: 1100px;
  margin: 0 auto;
  padding: var(--space-md);
}

.live-stream-view {
  display: flex;
  gap: var(--space-md);
  margin-bottom: var(--space-xl);
  height: 500px;
}

.live-video-area {
  flex: 1;
  border-radius: var(--radius-xl);
  overflow: hidden;
  position: relative;
  background: #000;
}

.live-video-placeholder {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.live-video-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: var(--space-md);
}

.live-top-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.live-badge-wrap {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.live-badge {
  background: var(--aura-red);
  color: white;
  font-size: 12px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: var(--radius-full);
  letter-spacing: 0.05em;
  animation: livePulse 1.5s infinite;
}

.live-viewer-count {
  background: rgba(0,0,0,0.5);
  backdrop-filter: blur(8px);
  color: white;
  font-size: 13px;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: var(--radius-full);
}

.live-top-actions {
  display: flex;
  gap: var(--space-sm);
}

.live-top-btn {
  width: 36px;
  height: 36px;
  background: rgba(0,0,0,0.5);
  backdrop-filter: blur(8px);
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  transition: all var(--transition-base);
}

.live-top-btn svg {
  width: 18px;
  height: 18px;
}

.live-end-btn {
  padding: 6px 16px;
  background: var(--aura-red);
  color: white;
  border-radius: var(--radius-full);
  font-size: 13px;
  font-weight: 700;
  transition: all var(--transition-base);
}

.live-end-btn:hover {
  background: #DC2626;
}

.live-reactions-stream {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  align-items: flex-start;
  gap: 4px;
  pointer-events: none;
  overflow: hidden;
}

.live-reaction-bubble {
  background: rgba(0,0,0,0.5);
  backdrop-filter: blur(8px);
  border-radius: var(--radius-full);
  padding: 4px 12px;
  color: white;
  font-size: 13px;
  animation: reactionFloat 3s ease forwards;
}

@keyframes reactionFloat {
  0% { opacity: 0; transform: translateY(20px); }
  20% { opacity: 1; transform: translateY(0); }
  80% { opacity: 1; }
  100% { opacity: 0; transform: translateY(-40px); }
}

.live-bottom-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.live-host-info {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.live-host-avatar {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-full);
  object-fit: cover;
  border: 2px solid white;
}

.live-host-name {
  font-size: 14px;
  font-weight: 700;
  color: white;
  display: block;
  text-shadow: 0 1px 3px rgba(0,0,0,0.5);
}

.live-host-title {
  font-size: 12px;
  color: rgba(255,255,255,0.7);
  display: block;
}

.live-bottom-actions {
  display: flex;
  gap: var(--space-sm);
}

.live-action-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: rgba(0,0,0,0.5);
  backdrop-filter: blur(8px);
  border-radius: var(--radius-full);
  color: white;
  font-size: 13px;
  font-weight: 600;
  transition: all var(--transition-base);
}

.live-action-btn:hover {
  background: rgba(0,0,0,0.7);
}

.live-action-btn svg {
  width: 16px;
  height: 16px;
}

.live-gift-btn { color: var(--aura-amber); }
.live-shop-btn { color: var(--aura-cyan); }

/* Live Chat Panel */
.live-chat-panel {
  width: 320px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
}

.live-chat-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-md);
  border-bottom: 1px solid var(--border-subtle);
  font-size: 14px;
  font-weight: 600;
}

.live-chat-controls {
  display: flex;
  gap: var(--space-sm);
}

.live-chat-btn {
  font-size: 11px;
  color: var(--text-tertiary);
  padding: 3px 8px;
  background: var(--bg-glass);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  transition: all var(--transition-base);
}

.live-chat-btn:hover {
  color: var(--text-primary);
}

.live-chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: var(--space-md);
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
  scrollbar-width: thin;
  scrollbar-color: var(--border-subtle) transparent;
}

.live-chat-msg {
  font-size: 13px;
  line-height: 1.4;
}

.live-chat-user {
  font-weight: 700;
  margin-right: 6px;
}

.live-chat-text {
  color: var(--text-secondary);
}

.gift-msg .live-chat-text {
  color: var(--aura-amber);
  font-weight: 600;
}

.live-chat-input-wrap {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-md);
  border-top: 1px solid var(--border-subtle);
}

.live-chat-input {
  flex: 1;
  padding: 8px 12px;
  background: var(--bg-glass);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-full);
  font-size: 13px;
  color: var(--text-primary);
  outline: none;
}

.live-chat-emoji-btn {
  font-size: 18px;
  transition: transform var(--transition-base);
}

.live-chat-emoji-btn:hover {
  transform: scale(1.2);
}

.live-chat-send-btn {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-full);
  background: var(--grad-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  flex-shrink: 0;
}

.live-chat-send-btn svg {
  width: 14px;
  height: 14px;
}

/* Live Discovery */
.live-discovery {
  margin-bottom: var(--space-xl);
}

.live-discovery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-md);
}

.live-discovery-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  overflow: hidden;
  cursor: pointer;
  transition: all var(--transition-base);
}

.live-discovery-card:hover {
  border-color: var(--border-accent);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.live-discovery-card img {
  width: 100%;
  height: 140px;
  object-fit: cover;
}

.live-discovery-overlay {
  position: absolute;
  top: var(--space-sm);
  left: var(--space-sm);
  right: var(--space-sm);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.live-discovery-card {
  position: relative;
}

.live-badge-sm {
  background: var(--aura-red);
  color: white;
  font-size: 10px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: var(--radius-full);
}

.live-viewers-sm {
  background: rgba(0,0,0,0.6);
  color: white;
  font-size: 11px;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: var(--radius-full);
}

.live-discovery-info {
  padding: var(--space-md);
}

.live-discovery-name {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-primary);
  display: block;
  margin-bottom: 3px;
}

.live-discovery-title {
  font-size: 12px;
  color: var(--text-tertiary);
}

/* ============================================================
   PRIVACY & WELLNESS PAGE
============================================================ */
.privacy-container {
  max-width: 800px;
  margin: 0 auto;
  padding: var(--space-xl) var(--space-md);
}

.privacy-header {
  margin-bottom: var(--space-xl);
}

.privacy-header h2 {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 800;
  margin-bottom: var(--space-sm);
}

.privacy-header p {
  font-size: 14px;
  color: var(--text-secondary);
}

/* Wellness Dashboard */
.wellness-dashboard {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-md);
  margin-bottom: var(--space-2xl);
}

.wellness-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: var(--space-lg);
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
  transition: all var(--transition-base);
}

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

.wellness-icon {
  font-size: 28px;
}

.wellness-info h4 {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: var(--space-sm);
}

.usage-time {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 800;
  background: var(--grad-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: var(--space-sm);
}

.usage-bar {
  height: 6px;
  background: var(--bg-glass);
  border-radius: var(--radius-full);
  overflow: hidden;
  margin-bottom: var(--space-sm);
}

.usage-bar-fill {
  height: 100%;
  background: var(--grad-primary);
  border-radius: var(--radius-full);
}

.wellness-info p {
  font-size: 12px;
  color: var(--text-tertiary);
}

.mood-score {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 800;
  color: var(--aura-green);
  margin-bottom: var(--space-sm);
}

.wellness-adjust-btn {
  font-size: 12px;
  font-weight: 600;
  color: var(--aura-violet);
  padding: 5px 12px;
  border: 1px solid rgba(167, 139, 250, 0.3);
  border-radius: var(--radius-full);
  transition: all var(--transition-base);
  align-self: flex-start;
}

.wellness-adjust-btn:hover {
  background: rgba(167, 139, 250, 0.1);
}

/* Privacy Section */
.privacy-section {
  margin-bottom: var(--space-2xl);
}

.privacy-controls-list {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  overflow: hidden;
}

.privacy-control-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-md) var(--space-lg);
  border-bottom: 1px solid var(--border-subtle);
  gap: var(--space-md);
}

.privacy-control-item:last-child {
  border-bottom: none;
}

.privacy-control-info h4 {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 3px;
}

.privacy-control-info p {
  font-size: 12px;
  color: var(--text-tertiary);
}

.privacy-select {
  padding: 6px 12px;
  font-size: 13px;
  border-radius: var(--radius-md);
  cursor: pointer;
  min-width: 140px;
}

.privacy-action-btn {
  padding: 6px 14px;
  background: var(--bg-glass);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-full);
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
  transition: all var(--transition-base);
}

.privacy-action-btn:hover {
  color: var(--text-primary);
  background: var(--bg-glass-hover);
}

/* Data Transparency */
.data-transparency-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-md);
}

.data-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: var(--space-lg);
  transition: all var(--transition-base);
}

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

.data-card h4 {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: var(--space-md);
}

.data-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
  margin-bottom: var(--space-md);
}

.data-list li {
  font-size: 13px;
  color: var(--text-secondary);
}

.data-manage-btn {
  font-size: 12px;
  font-weight: 600;
  color: var(--aura-violet);
  padding: 5px 12px;
  border: 1px solid rgba(167, 139, 250, 0.3);
  border-radius: var(--radius-full);
  transition: all var(--transition-base);
}

.data-manage-btn:hover {
  background: rgba(167, 139, 250, 0.1);
}

/* Safety Tools */
.safety-tools-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-md);
}

.safety-tool-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: var(--space-lg);
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
  cursor: pointer;
  transition: all var(--transition-base);
  text-align: left;
}

.safety-tool-card:hover {
  border-color: var(--border-accent);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.safety-tool-icon {
  font-size: 28px;
}

.safety-tool-card h4 {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-primary);
}

.safety-tool-card p {
  font-size: 12px;
  color: var(--text-tertiary);
  flex: 1;
}

.safety-status {
  font-size: 11px;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: var(--radius-full);
  background: var(--bg-glass);
  color: var(--text-tertiary);
  border: 1px solid var(--border-subtle);
  align-self: flex-start;
}

.safety-status.active {
  background: rgba(16, 185, 129, 0.15);
  color: var(--aura-green);
  border-color: rgba(16, 185, 129, 0.3);
}

/* ============================================================
   ADMIN PANEL PAGE
============================================================ */
.admin-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: var(--space-xl) var(--space-md);
}

.admin-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-xl);
}

.admin-header-left {
  display: flex;
  align-items: center;
  gap: var(--space-md);
}

.admin-header-left h2 {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 800;
}

.admin-badge {
  font-size: 11px;
  font-weight: 700;
  padding: 3px 10px;
  background: rgba(245, 158, 11, 0.15);
  color: var(--aura-amber);
  border: 1px solid rgba(245, 158, 11, 0.3);
  border-radius: var(--radius-full);
}

.admin-header-right {
  display: flex;
  align-items: center;
  gap: var(--space-md);
}

.admin-last-updated {
  font-size: 12px;
  color: var(--text-tertiary);
}

.admin-refresh-btn {
  padding: 6px 14px;
  background: var(--bg-glass);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-full);
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
  transition: all var(--transition-base);
}

.admin-refresh-btn:hover {
  color: var(--text-primary);
  background: var(--bg-glass-hover);
}

/* Admin Stats Grid */
.admin-stats-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: var(--space-md);
  margin-bottom: var(--space-xl);
}

.admin-stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: var(--space-lg);
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
  transition: all var(--transition-base);
}

.admin-stat-card:hover {
  border-color: var(--border-medium);
  box-shadow: var(--shadow-md);
}

.admin-stat-icon {
  font-size: 24px;
}

.admin-stat-value {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 800;
  color: var(--text-primary);
  display: block;
}

.admin-stat-label {
  font-size: 11px;
  color: var(--text-tertiary);
  display: block;
}

.admin-stat-change {
  font-size: 11px;
  color: var(--text-tertiary);
  display: block;
}

.admin-stat-change.positive {
  color: var(--aura-green);
}

/* Admin Panels Grid */
.admin-panels-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-lg);
}

.admin-panel {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: var(--space-xl);
}

.admin-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-lg);
}

.admin-panel-header h3 {
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 700;
}

.queue-count {
  font-size: 12px;
  font-weight: 600;
  color: var(--aura-amber);
  background: rgba(245, 158, 11, 0.1);
  padding: 3px 10px;
  border-radius: var(--radius-full);
  border: 1px solid rgba(245, 158, 11, 0.2);
}

.trend-period {
  font-size: 12px;
  color: var(--text-tertiary);
}

/* Moderation List */
.moderation-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

.mod-item {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  padding: var(--space-md);
  background: var(--bg-glass);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
}

.mod-item-thumb {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  overflow: hidden;
  flex-shrink: 0;
}

.mod-item-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.mod-item-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.mod-item-user {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
}

.mod-item-reason {
  font-size: 12px;
  color: var(--text-secondary);
}

.mod-item-confidence {
  font-size: 11px;
  color: var(--text-tertiary);
  font-family: var(--font-mono);
}

.mod-item-actions {
  display: flex;
  gap: var(--space-sm);
}

.mod-approve-btn, .mod-remove-btn, .mod-review-btn {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 700;
  transition: all var(--transition-base);
}

.mod-approve-btn {
  background: rgba(16, 185, 129, 0.15);
  color: var(--aura-green);
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.mod-approve-btn:hover {
  background: rgba(16, 185, 129, 0.25);
}

.mod-remove-btn {
  background: rgba(239, 68, 68, 0.15);
  color: var(--aura-red);
  border: 1px solid rgba(239, 68, 68, 0.3);
}

.mod-remove-btn:hover {
  background: rgba(239, 68, 68, 0.25);
}

.mod-review-btn {
  background: var(--bg-glass);
  color: var(--text-secondary);
  border: 1px solid var(--border-subtle);
}

.mod-review-btn:hover {
  background: var(--bg-glass-hover);
  color: var(--text-primary);
}

/* Trend Analysis */
.trend-analysis-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

.trend-analysis-item {
  display: flex;
  align-items: center;
  gap: var(--space-md);
}

.trend-rank-badge {
  width: 28px;
  height: 28px;
  border-radius: var(--radius-md);
  background: var(--grad-primary);
  color: white;
  font-size: 12px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.trend-info {
  flex: 1;
}

.trend-hashtag {
  font-size: 13px;
  font-weight: 600;
  color: var(--aura-violet);
  display: block;
  margin-bottom: 4px;
}

.trend-bar-wrap {
  height: 4px;
  background: var(--bg-glass);
  border-radius: var(--radius-full);
  overflow: hidden;
}

.trend-bar-fill {
  height: 100%;
  background: var(--grad-primary);
  border-radius: var(--radius-full);
}

.trend-posts {
  font-size: 12px;
  color: var(--text-tertiary);
  white-space: nowrap;
  font-family: var(--font-mono);
}

/* Security Monitor */
.security-status-badge {
  font-size: 11px;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: var(--radius-full);
}

.security-status-badge.safe {
  background: rgba(16, 185, 129, 0.15);
  color: var(--aura-green);
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.security-metrics {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

.security-metric {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-sm) 0;
  border-bottom: 1px solid var(--border-subtle);
}

.security-metric:last-child {
  border-bottom: none;
}

.security-metric-label {
  font-size: 13px;
  color: var(--text-secondary);
}

.security-metric-value {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
  font-family: var(--font-mono);
}

/* Revenue Breakdown */
.admin-export-btn {
  font-size: 12px;
  font-weight: 600;
  color: var(--aura-violet);
  padding: 5px 12px;
  border: 1px solid rgba(167, 139, 250, 0.3);
  border-radius: var(--radius-full);
  transition: all var(--transition-base);
}

.admin-export-btn:hover {
  background: rgba(167, 139, 250, 0.1);
}

.revenue-breakdown {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

.revenue-breakdown-item {
  display: flex;
  align-items: center;
  gap: var(--space-md);
}

.revenue-breakdown-label {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  width: 120px;
  flex-shrink: 0;
  font-size: 13px;
  color: var(--text-secondary);
}

.revenue-dot {
  width: 10px;
  height: 10px;
  border-radius: var(--radius-full);
  flex-shrink: 0;
}

.revenue-dot.ads { background: var(--aura-violet); }
.revenue-dot.subscriptions { background: var(--aura-cyan); }
.revenue-dot.commerce { background: var(--aura-pink); }
.revenue-dot.other { background: var(--aura-amber); }

.revenue-breakdown-bar {
  flex: 1;
  height: 8px;
  background: var(--bg-glass);
  border-radius: var(--radius-full);
  overflow: hidden;
}

.revenue-breakdown-fill {
  height: 100%;
  border-radius: var(--radius-full);
}

.ads-fill { background: var(--aura-violet); }
.subs-fill { background: var(--aura-cyan); }
.commerce-fill { background: var(--aura-pink); }
.other-fill { background: var(--aura-amber); }

.revenue-breakdown-value {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-primary);
  width: 60px;
  text-align: right;
  font-family: var(--font-mono);
}

/* ============================================================
   BOTTOM NAVIGATION
============================================================ */
.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: var(--bottom-nav-height);
  background: rgba(10, 10, 15, 0.92);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border-top: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-around;
  padding: 0 var(--space-sm);
  z-index: 100;
}

[data-theme="light"] .bottom-nav {
  background: rgba(248, 247, 255, 0.92);
}

.bottom-nav-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: var(--space-sm);
  border-radius: var(--radius-lg);
  color: var(--text-tertiary);
  font-size: 10px;
  font-weight: 500;
  position: relative;
  transition: all var(--transition-base);
  min-width: 52px;
}

.bottom-nav-btn:hover {
  color: var(--text-secondary);
}

.bottom-nav-btn.active {
  color: var(--aura-violet);
}

.bottom-nav-btn svg {
  width: 22px;
  height: 22px;
}

.create-nav-btn {
  color: var(--text-primary) !important;
}

.create-nav-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-lg);
  background: var(--grad-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-glow-violet);
  transition: all var(--transition-base);
}

.create-nav-icon:hover {
  transform: scale(1.05);
}

.create-nav-icon svg {
  width: 20px;
  height: 20px;
  color: white;
}

.nav-badge {
  position: absolute;
  top: 4px;
  right: 4px;
  background: var(--aura-pink);
  color: white;
  font-size: 9px;
  font-weight: 700;
  min-width: 16px;
  height: 16px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 3px;
  border: 1.5px solid var(--bg-primary);
}

/* ============================================================
   SIDE NAVIGATION (Desktop)
============================================================ */
.side-nav {
  display: none;
  position: fixed;
  left: 0;
  top: 0;
  bottom: 0;
  width: var(--side-nav-width);
  background: var(--bg-secondary);
  border-right: 1px solid var(--border-subtle);
  flex-direction: column;
  padding: var(--space-lg) var(--space-md);
  z-index: 90;
  overflow-y: auto;
  scrollbar-width: none;
}

.side-nav::-webkit-scrollbar { display: none; }

.side-nav-logo {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-md) var(--space-sm);
  margin-bottom: var(--space-lg);
}

.side-nav-logo-icon {
  width: 32px;
  height: 32px;
}

.side-nav-logo span {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 800;
  background: var(--grad-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: 0.08em;
}

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

.side-nav-item {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  padding: 10px var(--space-md);
  border-radius: var(--radius-lg);
  color: var(--text-secondary);
  font-size: 14px;
  font-weight: 500;
  transition: all var(--transition-base);
  position: relative;
  text-align: left;
}

.side-nav-item:hover {
  background: var(--bg-glass);
  color: var(--text-primary);
}

.side-nav-item.active {
  background: rgba(167, 139, 250, 0.1);
  color: var(--aura-violet);
}

.side-nav-item svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.side-nav-avatar {
  width: 28px;
  height: 28px;
  border-radius: var(--radius-full);
  object-fit: cover;
  flex-shrink: 0;
}

.side-nav-badge {
  margin-left: auto;
  background: var(--aura-pink);
  color: white;
  font-size: 10px;
  font-weight: 700;
  min-width: 18px;
  height: 18px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
}

.live-indicator {
  margin-left: auto;
  color: var(--aura-red);
  font-size: 12px;
  animation: livePulse 1.5s infinite;
}

.side-nav-bottom {
  border-top: 1px solid var(--border-subtle);
  padding-top: var(--space-md);
  margin-top: var(--space-md);
}

/* ============================================================
   STORY MODAL
============================================================ */
.story-modal {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: none;
  align-items: center;
  justify-content: center;
}

.story-modal.active {
  display: flex;
}

.story-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.9);
  backdrop-filter: blur(10px);
}

.story-modal-content {
  position: relative;
  width: 100%;
  max-width: 400px;
  height: 100vh;
  max-height: 700px;
  background: #000;
  border-radius: var(--radius-2xl);
  overflow: hidden;
  z-index: 1;
}

.story-progress-bars {
  position: absolute;
  top: var(--space-md);
  left: var(--space-md);
  right: var(--space-md);
  display: flex;
  gap: 4px;
  z-index: 10;
}

.story-progress-bar {
  flex: 1;
  height: 2px;
  background: rgba(255,255,255,0.3);
  border-radius: var(--radius-full);
  overflow: hidden;
}

.story-progress-fill {
  height: 100%;
  background: white;
  border-radius: var(--radius-full);
  width: 0%;
}

.story-progress-fill.active {
  animation: storyProgress 5s linear forwards;
}

@keyframes storyProgress {
  from { width: 0%; }
  to { width: 100%; }
}

.story-header {
  position: absolute;
  top: 24px;
  left: var(--space-md);
  right: var(--space-md);
  display: flex;
  align-items: center;
  justify-content: space-between;
  z-index: 10;
}

.story-author {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.story-author img {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-full);
  object-fit: cover;
  border: 2px solid white;
}

.story-author span {
  color: white;
  font-size: 13px;
  font-weight: 600;
  display: block;
  text-shadow: 0 1px 3px rgba(0,0,0,0.5);
}

.story-author span:last-child {
  font-size: 11px;
  font-weight: 400;
  opacity: 0.7;
}

.story-close-btn {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-full);
  background: rgba(0,0,0,0.4);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  transition: all var(--transition-base);
}

.story-close-btn:hover {
  background: rgba(0,0,0,0.6);
}

.story-media-area {
  width: 100%;
  height: 100%;
  position: relative;
}

.story-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.story-tap-left, .story-tap-right {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 40%;
  cursor: pointer;
}

.story-tap-left { left: 0; }
.story-tap-right { right: 0; }

.story-bottom {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: var(--space-md);
  background: linear-gradient(to top, rgba(0,0,0,0.6), transparent);
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
}

.story-reply-wrap {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.story-reply-input {
  flex: 1;
  padding: 10px var(--space-md);
  background: rgba(255,255,255,0.15);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255,255,255,0.3);
  border-radius: var(--radius-full);
  color: white;
  font-size: 14px;
  outline: none;
}

.story-reply-input::placeholder {
  color: rgba(255,255,255,0.6);
}

.story-reply-send {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-full);
  background: var(--grad-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  flex-shrink: 0;
}

.story-reply-send svg {
  width: 16px;
  height: 16px;
}

.story-quick-reactions {
  display: flex;
  justify-content: center;
  gap: var(--space-md);
}

.story-quick-reactions button {
  font-size: 24px;
  transition: transform var(--transition-base);
}

.story-quick-reactions button:hover {
  transform: scale(1.3);
}

/* ============================================================
   NOTIFICATION PANEL
============================================================ */
.notification-panel {
  position: fixed;
  top: var(--nav-height);
  right: var(--space-md);
  width: 380px;
  background: var(--bg-card);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-xl);
  z-index: 150;
  display: none;
  overflow: hidden;
  animation: panelIn 0.3s var(--transition-spring) forwards;
}

.notification-panel.active {
  display: block;
}

@keyframes panelIn {
  from { opacity: 0; transform: translateY(-10px) scale(0.97); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.notif-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-md) var(--space-lg);
  border-bottom: 1px solid var(--border-subtle);
}

.notif-panel-header h3 {
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 700;
}

.notif-mark-all {
  font-size: 12px;
  color: var(--aura-violet);
  font-weight: 600;
  transition: color var(--transition-base);
}

.notif-mark-all:hover {
  color: var(--aura-cyan);
}

.notif-list {
  max-height: 480px;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--border-subtle) transparent;
}

.notif-item {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  padding: var(--space-md) var(--space-lg);
  border-bottom: 1px solid var(--border-subtle);
  transition: background var(--transition-base);
  cursor: pointer;
}

.notif-item:hover {
  background: var(--bg-glass);
}

.notif-item.unread {
  background: rgba(167, 139, 250, 0.04);
}

.notif-item.unread::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: var(--radius-full);
  background: var(--aura-violet);
  flex-shrink: 0;
}

.notif-avatar {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-full);
  object-fit: cover;
  flex-shrink: 0;
}

.notif-ai-icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-full);
  background: var(--grad-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  color: white;
  flex-shrink: 0;
}

.notif-system-icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-full);
  background: rgba(245, 158, 11, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  flex-shrink: 0;
}

.notif-content {
  flex: 1;
  min-width: 0;
}

.notif-content p {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.4;
}

.notif-content strong {
  color: var(--text-primary);
}

.notif-time {
  font-size: 11px;
  color: var(--text-tertiary);
  display: block;
  margin-top: 3px;
}

.notif-post-thumb {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  object-fit: cover;
  flex-shrink: 0;
}

.notif-follow-back-btn {
  padding: 5px 12px;
  background: var(--grad-primary);
  color: white;
  border-radius: var(--radius-full);
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
  flex-shrink: 0;
  transition: all var(--transition-base);
}

.notif-follow-back-btn:hover {
  transform: scale(1.02);
}

/* ============================================================
   AI FLOATING ACTION BUTTON
============================================================ */
.ai-fab {
  position: fixed;
  bottom: calc(var(--bottom-nav-height) + var(--space-lg));
  right: var(--space-lg);
  width: 52px;
  height: 52px;
  border-radius: var(--radius-full);
  background: var(--grad-aurora);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 20px;
  box-shadow: var(--shadow-glow-violet);
  z-index: 90;
  transition: all var(--transition-spring);
}

.ai-fab:hover {
  transform: scale(1.1) rotate(15deg);
  box-shadow: 0 8px 30px rgba(167, 139, 250, 0.5);
}

.ai-fab-pulse {
  position: absolute;
  inset: -4px;
  border-radius: var(--radius-full);
  background: var(--grad-aurora);
  opacity: 0.3;
  animation: fabPulse 2s ease infinite;
}

@keyframes fabPulse {
  0%, 100% { transform: scale(1); opacity: 0.3; }
  50% { transform: scale(1.2); opacity: 0; }
}

/* AI Assistant Modal */
.ai-assistant-modal {
  position: fixed;
  bottom: calc(var(--bottom-nav-height) + 80px);
  right: var(--space-lg);
  width: 360px;
  background: var(--bg-card);
  border: 1px solid var(--border-accent);
  border-radius: var(--radius-2xl);
  box-shadow: var(--shadow-xl), var(--shadow-glow-violet);
  z-index: 90;
  display: none;
  overflow: hidden;
  animation: modalIn 0.4s var(--transition-spring) forwards;
}

.ai-assistant-modal.active {
  display: flex;
  flex-direction: column;
}

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

.ai-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-md) var(--space-lg);
  background: linear-gradient(135deg, rgba(167, 139, 250, 0.1), rgba(6, 182, 212, 0.1));
  border-bottom: 1px solid var(--border-subtle);
}

.ai-modal-title {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  font-size: 14px;
  font-weight: 700;
  background: var(--grad-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.ai-modal-icon {
  font-size: 16px;
}

.ai-modal-close {
  width: 28px;
  height: 28px;
  border-radius: var(--radius-full);
  background: var(--bg-glass);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-tertiary);
  font-size: 12px;
  transition: all var(--transition-base);
}

.ai-modal-close:hover {
  color: var(--text-primary);
  background: var(--bg-glass-hover);
}

.ai-modal-body {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
  padding: var(--space-md);
  max-height: 400px;
}

.ai-chat-messages {
  flex: 1;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
  scrollbar-width: thin;
  scrollbar-color: var(--border-subtle) transparent;
}

.ai-message {
  display: flex;
  gap: var(--space-sm);
  align-items: flex-start;
}

.ai-msg-icon {
  width: 28px;
  height: 28px;
  border-radius: var(--radius-full);
  background: var(--grad-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  color: white;
  flex-shrink: 0;
}

.ai-msg-content {
  background: var(--bg-glass);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  border-top-left-radius: var(--radius-sm);
  padding: var(--space-sm) var(--space-md);
}

.ai-msg-content p {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.5;
}

.user-msg .ai-msg-content {
  background: var(--grad-primary);
  border: none;
  border-radius: var(--radius-lg);
  border-top-right-radius: var(--radius-sm);
  margin-left: auto;
}

.user-msg .ai-msg-content p {
  color: white;
}

.ai-quick-actions {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-sm);
}

.ai-quick-btn {
  padding: 8px 12px;
  background: var(--bg-glass);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  font-size: 12px;
  font-weight: 500;
  color: var(--text-secondary);
  transition: all var(--transition-base);
  text-align: left;
}

.ai-quick-btn:hover {
  background: rgba(167, 139, 250, 0.1);
  border-color: var(--border-accent);
  color: var(--aura-violet);
}

.ai-input-wrap {
  display: flex;
  gap: var(--space-sm);
}

.ai-input {
  flex: 1;
  padding: 10px var(--space-md);
  background: var(--bg-glass);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-full);
  font-size: 13px;
  color: var(--text-primary);
  outline: none;
}

.ai-input::placeholder {
  color: var(--text-tertiary);
}

.ai-send-btn {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-full);
  background: var(--grad-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  flex-shrink: 0;
  transition: all var(--transition-base);
}

.ai-send-btn:hover {
  transform: scale(1.05);
}

.ai-send-btn svg {
  width: 14px;
  height: 14px;
}

/* ============================================================
   TOAST NOTIFICATIONS
============================================================ */
.toast-container {
  position: fixed;
  top: calc(var(--nav-height) + var(--space-md));
  right: var(--space-md);
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
  z-index: 300;
  pointer-events: none;
}

.toast {
  background: var(--bg-card);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-lg);
  padding: var(--space-md) var(--space-lg);
  box-shadow: var(--shadow-lg);
  display: flex;
  align-items: center;
  gap: var(--space-md);
  min-width: 280px;
  max-width: 360px;
  pointer-events: all;
  animation: toastIn 0.4s var(--transition-spring) forwards;
}

.toast.removing {
  animation: toastOut 0.3s ease forwards;
}

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

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

.toast-icon {
  font-size: 18px;
  flex-shrink: 0;
}

.toast-content {
  flex: 1;
}

.toast-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
  display: block;
}

.toast-message {
  font-size: 12px;
  color: var(--text-secondary);
  display: block;
}

.toast.success { border-left: 3px solid var(--aura-green); }
.toast.error { border-left: 3px solid var(--aura-red); }
.toast.info { border-left: 3px solid var(--aura-violet); }
.toast.warning { border-left: 3px solid var(--aura-amber); }

/* ============================================================
   UTILITY ANIMATIONS
============================================================ */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes scaleIn {
  from { opacity: 0; transform: scale(0.9); }
  to { opacity: 1; transform: scale(1); }
}

@keyframes heartBeat {
  0% { transform: scale(1); }
  25% { transform: scale(1.3); }
  50% { transform: scale(1); }
  75% { transform: scale(1.15); }
  100% { transform: scale(1); }
}

/* ============================================================
   RESPONSIVE — TABLET
============================================================ */
@media (min-width: 768px) {
  .feed-container {
    padding: var(--space-lg) var(--space-xl);
  }

  .post-card {
    margin: 0 0 var(--space-lg);
  }

  .explore-grid {
    padding: 0 var(--space-xl) var(--space-xl);
  }

  .content-type-grid {
    grid-template-columns: repeat(6, 1fr);
  }

  .ai-tools-grid {
    grid-template-columns: repeat(4, 1fr);
  }

  .revenue-overview {
    grid-template-columns: repeat(2, 1fr);
  }

  .monetization-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* ============================================================
   RESPONSIVE — DESKTOP
============================================================ */
@media (min-width: 1024px) {
  .side-nav {
    display: flex;
  }

  .bottom-nav {
    display: none;
  }

  .top-nav {
    left: var(--side-nav-width);
  }

  .main-content {
    margin-left: var(--side-nav-width);
    margin-bottom: 0;
  }

  .ai-fab {
    bottom: var(--space-xl);
  }

  .ai-assistant-modal {
    bottom: 80px;
  }

  .feed-container {
    padding: var(--space-xl) var(--space-2xl);
  }

  .revenue-overview {
    grid-template-columns: repeat(4, 1fr);
  }

  .admin-stats-grid {
    grid-template-columns: repeat(6, 1fr);
  }

  .wellness-dashboard {
    grid-template-columns: repeat(3, 1fr);
  }

  .data-transparency-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* ============================================================
   RESPONSIVE — LARGE DESKTOP
============================================================ */
@media (min-width: 1280px) {
  :root {
    --side-nav-width: 260px;
  }

  .feed-container {
    max-width: 720px;
  }
}

/* ============================================================
   SCROLLBAR STYLING
============================================================ */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background: var(--border-medium);
  border-radius: var(--radius-full);
}

::-webkit-scrollbar-thumb:hover {
  background: var(--border-strong);
}

/* ============================================================
   SELECTION STYLING
============================================================ */
::selection {
  background: rgba(167, 139, 250, 0.3);
  color: var(--text-primary);
}

/* ============================================================
   FOCUS VISIBLE
============================================================ */
:focus-visible {
  outline: 2px solid var(--aura-violet);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}