/* App Theme - Unified dark theme matching marketing site aesthetic */

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

/* Color palette - matching marketing site */
:root {
  /* Core colors */
  --app-bg-primary: #0d0d0d;
  --app-bg-secondary: #1a1a1a;
  --app-bg-tertiary: #2a2a2a;
  --app-text-primary: #ffffff;
  --app-text-secondary: #a0a0a0;
  --app-text-tertiary: #6b7280;
  
  /* Accent colors */
  --app-accent-purple: #8b5cf6;
  --app-accent-cyan: #06b6d4;
  --app-accent-purple-dark: #7c3aed;
  --app-accent-cyan-dark: #0891b2;
  
  /* Borders and surfaces */
  --app-border-color: #2a2a2a;
  --app-border-light: rgba(255, 255, 255, 0.1);
  
  /* Glass effects */
  --app-glass-bg: rgba(255, 255, 255, 0.05);
  --app-glass-bg-hover: rgba(255, 255, 255, 0.08);
  --app-glass-border: rgba(255, 255, 255, 0.1);
  --app-glass-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
  --app-glass-blur: 12px;
  
  /* Shadows */
  --app-shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.3);
  --app-shadow-md: 0 4px 16px rgba(0, 0, 0, 0.4);
  --app-shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.5);
  --app-shadow-glow: 0 0 24px rgba(139, 92, 246, 0.3);
}

/* Typography */
body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', sans-serif;
  font-feature-settings: 'cv02', 'cv03', 'cv04', 'cv11';
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Background enhancements */
.app-bg-enhanced {
  position: relative;
  background-color: var(--app-bg-primary);
}

.app-bg-enhanced::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: 
    radial-gradient(circle at 10% 20%, rgba(139, 92, 246, 0.08) 0%, transparent 40%),
    radial-gradient(circle at 80% 80%, rgba(6, 182, 212, 0.06) 0%, transparent 40%);
  pointer-events: none;
  z-index: 0;
}

/* Glass card styles */
.glass-card {
  background: var(--app-glass-bg);
  backdrop-filter: blur(var(--app-glass-blur));
  -webkit-backdrop-filter: blur(var(--app-glass-blur));
  border: 1px solid var(--app-glass-border);
  box-shadow: var(--app-glass-shadow);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.glass-card:hover {
  background: var(--app-glass-bg-hover);
  border-color: rgba(255, 255, 255, 0.15);
  transform: translateY(-2px);
  box-shadow: var(--app-shadow-lg);
}

/* Gradient button styles */
.btn-gradient {
  background: linear-gradient(135deg, var(--app-accent-purple) 0%, var(--app-accent-cyan) 100%);
  color: white;
  font-weight: 500;
  padding: 0.5rem 1.5rem;
  border-radius: 0.5rem;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
}

.btn-gradient::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, var(--app-accent-purple-dark) 0%, var(--app-accent-cyan-dark) 100%);
  opacity: 0;
  transition: opacity 0.3s ease;
  z-index: -1;
}

.btn-gradient:hover::before {
  opacity: 1;
}

.btn-gradient:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 20px rgba(139, 92, 246, 0.4);
}

.btn-gradient:active {
  transform: translateY(0);
}

/* Gradient text utility */
.gradient-text {
  background: linear-gradient(135deg, var(--app-accent-purple) 0%, var(--app-accent-cyan) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Enhanced sidebar item styles */
.sidebar-item {
  position: relative;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.sidebar-item-active {
  background: linear-gradient(135deg, var(--app-accent-purple) 0%, var(--app-accent-purple-dark) 100%);
  box-shadow: 0 2px 12px rgba(139, 92, 246, 0.3);
}

.sidebar-item:not(.sidebar-item-active):hover {
  background: var(--app-glass-bg);
  border-color: var(--app-glass-border);
}

/* Enhanced card hover effects */
.card-hover-glow {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.card-hover-glow:hover {
  box-shadow: 
    0 0 0 1px rgba(139, 92, 246, 0.2),
    0 4px 24px rgba(0, 0, 0, 0.4),
    0 0 48px rgba(139, 92, 246, 0.1);
}

/* Smooth transitions */
.transition-smooth {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Loading skeleton with gradient */
.skeleton-gradient {
  background: linear-gradient(90deg, 
    var(--app-bg-secondary) 0%, 
    var(--app-bg-tertiary) 50%, 
    var(--app-bg-secondary) 100%);
  background-size: 200% 100%;
  animation: skeleton-loading 1.5s ease-in-out infinite;
}

@keyframes skeleton-loading {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}

/* Subtle background animation */
@keyframes subtle-glow {
  0%, 100% {
    opacity: 0.5;
  }
  50% {
    opacity: 0.8;
  }
}

.bg-glow-purple {
  position: absolute;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(139, 92, 246, 0.15) 0%, transparent 70%);
  filter: blur(80px);
  animation: subtle-glow 8s ease-in-out infinite;
  pointer-events: none;
}

.bg-glow-cyan {
  position: absolute;
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(6, 182, 212, 0.15) 0%, transparent 70%);
  filter: blur(80px);
  animation: subtle-glow 10s ease-in-out infinite;
  animation-delay: 2s;
  pointer-events: none;
}

/* Custom scrollbar */
::-webkit-scrollbar {
  width: 12px;
  height: 12px;
}

::-webkit-scrollbar-track {
  background: var(--app-bg-secondary);
}

::-webkit-scrollbar-thumb {
  background: var(--app-bg-tertiary);
  border-radius: 6px;
  border: 2px solid var(--app-bg-secondary);
}

::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(135deg, var(--app-accent-purple) 0%, var(--app-accent-cyan) 100%);
}

/* Input focus states */
input:focus,
textarea:focus,
select:focus {
  outline: none;
  border-color: var(--app-accent-purple);
  box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.1);
}

/* Noise texture overlay */
.noise-overlay {
  position: relative;
}

.noise-overlay::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: 
    repeating-linear-gradient(45deg, 
      transparent, 
      transparent 2px, 
      rgba(255, 255, 255, 0.03) 2px, 
      rgba(255, 255, 255, 0.03) 4px);
  pointer-events: none;
  mix-blend-mode: overlay;
}