/* ===================================================
   DRIARY - FANTASY DREAM JOURNAL CSS (COMPLETE)
   A mystical design system focused on dreams & symbolism
   =================================================== */

/* ===================================================
   CSS VARIABLES - Dream Color System
   =================================================== */

:root {
  /* Primary Colors - Dream Palette */
  --dream-night: #0F0E1A;
  --dream-twilight: #1A1825;
  --dream-midnight: #252339;
  --dream-lavender: #8B7FD6;
  --dream-moonlight: #C4B8E7;
  --dream-stardust: #E8E3F5;
  --dream-aurora: #7FC8D6;
  --dream-rose: #D67F9B;
  --dream-gold: #D6AD7F;
  
  /* Neutral Colors */
  --neutral-100: #F5F3F7;
  --neutral-200: #E8E5ED;
  --neutral-300: #C8C3D1;
  --neutral-400: #9892A6;
  --neutral-500: #6B657A;
  --neutral-600: #4A4559;
  --neutral-700: #352F44;
  --neutral-800: #231E33;
  --neutral-900: #151221;
  
  /* Gradients */
  --gradient-dream: linear-gradient(135deg, var(--dream-lavender) 0%, var(--dream-aurora) 100%);
  --gradient-night: linear-gradient(180deg, var(--dream-night) 0%, var(--dream-midnight) 100%);
  --gradient-mystic: linear-gradient(135deg, var(--dream-rose) 0%, var(--dream-lavender) 100%);
  
  /* Typography */
  --font-main: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-heading: 'Playfair Display', Georgia, serif;
  
  /* Spacing */
  --space-xs: 0.5rem;
  --space-sm: 1rem;
  --space-md: 1.5rem;
  --space-lg: 2rem;
  --space-xl: 3rem;
  --space-2xl: 4rem;
  --space-3xl: 6rem;
  
  /* Shadows */
  --shadow-sm: 0 2px 4px rgba(15, 14, 26, 0.1);
  --shadow-md: 0 4px 8px rgba(15, 14, 26, 0.15);
  --shadow-lg: 0 8px 16px rgba(15, 14, 26, 0.2);
  --shadow-dream: 0 0 20px rgba(139, 127, 214, 0.2);
  
  /* Border Radius */
  --radius-sm: 0.5rem;
  --radius-md: 0.75rem;
  --radius-lg: 1rem;
  --radius-xl: 1.5rem;
  --radius-full: 9999px;
  
  /* Transitions */
  --transition-fast: 150ms ease;
  --transition-base: 250ms ease;
  --transition-slow: 400ms ease;
}

/* ===================================================
   RESET & BASE STYLES
   =================================================== */

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-main);
  background: var(--dream-night);
  color: var(--neutral-200);
  line-height: 1.6;
  overflow-x: hidden;
  min-height: 100vh;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

::-webkit-scrollbar-track {
  background: var(--dream-midnight);
}

::-webkit-scrollbar-thumb {
  background: var(--dream-lavender);
  border-radius: var(--radius-full);
}

::-webkit-scrollbar-thumb:hover {
  background: var(--dream-moonlight);
}

/* Selection */
::selection {
  background: var(--dream-lavender);
  color: white;
}

/* Focus styles for better keyboard navigation */
*:focus-visible {
  outline: 2px solid var(--dream-lavender);
  outline-offset: 2px;
}

button:focus-visible,
a:focus-visible {
  outline-offset: 4px;
}

/* ===================================================
   DREAM BACKGROUND
   =================================================== */

.dream-canvas {
  position: fixed;
  inset: 0;
  background: var(--dream-night);
  z-index: -1;
}

.dream-canvas::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: 
    radial-gradient(circle at 20% 50%, rgba(139, 127, 214, 0.08) 0%, transparent 50%),
    radial-gradient(circle at 80% 80%, rgba(127, 200, 214, 0.08) 0%, transparent 50%),
    radial-gradient(circle at 40% 20%, rgba(214, 127, 155, 0.05) 0%, transparent 50%);
}

/* Subtle stars effect */
.stars {
  position: absolute;
  inset: 0;
  background-image: 
    radial-gradient(2px 2px at 20% 30%, white, transparent),
    radial-gradient(2px 2px at 60% 70%, white, transparent),
    radial-gradient(1px 1px at 90% 10%, white, transparent);
  background-size: 500px 500px;
  opacity: 0.3;
}

/* ===================================================
   NAVIGATION
   =================================================== */

.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 70px;
  background: rgba(15, 14, 26, 0.9);
  backdrop-filter: blur(10px);
  z-index: 1000;
  transition: all var(--transition-base);
  border-bottom: 1px solid rgba(139, 127, 214, 0.1);
}

.navbar.scrolled {
  background: rgba(15, 14, 26, 0.95);
  box-shadow: var(--shadow-lg);
}

.nav-container {
  max-width: 1200px;
  height: 100%;
  margin: 0 auto;
  padding: 0 var(--space-lg);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  cursor: pointer;
  text-decoration: none;
}

.logo-icon {
  width: 36px;
  height: 36px;
  background: var(--gradient-dream);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
}

.logo-icon i {
  font-size: 1.25rem;
  color: white;
}

.nav-brand span {
  font-size: 1.5rem;
  font-weight: 600;
  color: white;
  font-family: var(--font-heading);
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: var(--space-lg);
}

.nav-link {
  color: var(--neutral-300);
  text-decoration: none;
  font-weight: 500;
  position: relative;
  transition: color var(--transition-base);
  padding: var(--space-xs) 0;
}

.nav-link:hover {
  color: var(--dream-moonlight);
}

.nav-link.active {
  color: var(--dream-lavender);
}

/* Dream Button */
.dream-button {
  background: var(--gradient-dream);
  color: white;
  border: none;
  padding: var(--space-xs) var(--space-lg);
  border-radius: var(--radius-full);
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-base);
}

.dream-button:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-dream);
}

/* User Menu */
.user-menu {
  position: relative;
}

.user-info {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  cursor: pointer;
  padding: var(--space-xs) var(--space-sm);
  border-radius: var(--radius-md);
  transition: background var(--transition-base);
}

.user-info:hover {
  background: rgba(139, 127, 214, 0.1);
}

.user-avatar {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-full);
  border: 2px solid var(--dream-lavender);
}

.user-name {
  color: white;
  font-weight: 500;
}

.user-info i {
  font-size: 0.75rem;
  color: var(--neutral-400);
  transition: transform var(--transition-base);
}

.dropdown-menu {
  position: absolute;
  top: calc(100% + var(--space-xs));
  right: 0;
  background: var(--dream-twilight);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(139, 127, 214, 0.2);
  border-radius: var(--radius-md);
  min-width: 220px;
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: all var(--transition-base);
}

.user-menu.dropdown-open .dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.dropdown-header {
  padding: var(--space-md);
  background: rgba(139, 127, 214, 0.1);
  border-bottom: 1px solid rgba(139, 127, 214, 0.2);
}

.user-email {
  font-size: 0.875rem;
  color: var(--neutral-300);
  margin-bottom: var(--space-xs);
}

.user-plan {
  font-size: 0.75rem;
  color: var(--dream-lavender);
  font-weight: 600;
  text-transform: uppercase;
}

.dropdown-menu a {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-sm) var(--space-md);
  color: var(--neutral-300);
  text-decoration: none;
  transition: all var(--transition-base);
}

.dropdown-menu a:hover {
  background: rgba(139, 127, 214, 0.1);
  color: white;
}

.dropdown-menu a i {
  width: 16px;
  text-align: center;
}

/* ===================================================
   BREADCRUMB NAVIGATION
   =================================================== */

.breadcrumb-nav {
  padding: var(--space-sm) 0;
  margin-bottom: var(--space-md);
}

.breadcrumb-list {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  list-style: none;
  font-size: 0.875rem;
}

.breadcrumb-item {
  color: var(--neutral-400);
}

.breadcrumb-item a {
  color: var(--neutral-400);
  text-decoration: none;
  transition: color var(--transition-base);
}

.breadcrumb-item a:hover {
  color: var(--dream-lavender);
}

.breadcrumb-separator {
  color: var(--neutral-600);
}

.breadcrumb-item.active {
  color: var(--dream-lavender);
  font-weight: 500;
}

/* ===================================================
   MAIN CONTENT
   =================================================== */

.main-content {
  margin-top: 70px;
  min-height: calc(100vh - 70px);
  position: relative;
}

/* ===================================================
   HERO SECTION
   =================================================== */

.hero-section {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

.hero-content {
  text-align: center;
  padding: var(--space-xl);
  max-width: 900px;
  margin: 0 auto;
  z-index: 1;
}

.hero-title {
  font-size: clamp(2.5rem, 6vw, 4rem);
  font-weight: 300;
  margin-bottom: var(--space-md);
  line-height: 1.2;
  font-family: var(--font-heading);
}

.dream-text {
  color: var(--dream-lavender);
  font-weight: 400;
}

.hero-subtitle {
  font-size: 1.25rem;
  color: var(--neutral-300);
  margin-bottom: var(--space-xl);
  font-weight: 300;
}

.hero-dream-box {
  max-width: 600px;
  margin: 0 auto var(--space-xl);
}

.quick-dream-input {
  width: 100%;
  background: rgba(37, 35, 57, 0.5);
  border: 1px solid rgba(139, 127, 214, 0.3);
  border-radius: var(--radius-lg);
  padding: var(--space-md);
  color: white;
  font-size: 1.05rem;
  resize: none;
  transition: all var(--transition-base);
}

.quick-dream-input:focus {
  outline: none;
  border-color: var(--dream-lavender);
  background: rgba(37, 35, 57, 0.7);
}

.quick-dream-input::placeholder {
  color: var(--neutral-500);
}

.try-button {
  margin-top: var(--space-md);
  background: var(--gradient-dream);
  color: white;
  border: none;
  padding: var(--space-sm) var(--space-xl);
  border-radius: var(--radius-full);
  font-size: 1.05rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-base);
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
}

.try-button:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-dream);
}

.hero-stats {
  display: flex;
  justify-content: center;
  gap: var(--space-xl);
  margin-top: var(--space-2xl);
}

.stat {
  text-align: center;
}

.stat-number {
  display: block;
  font-size: 2rem;
  font-weight: 300;
  color: var(--dream-lavender);
  font-family: var(--font-heading);
}

.stat-label {
  font-size: 0.875rem;
  color: var(--neutral-400);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

/* ===================================================
   DREAM CARD
   =================================================== */

.dream-card {
  background: rgba(37, 35, 57, 0.4);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(139, 127, 214, 0.2);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  transition: all var(--transition-base);
}

.dream-card:hover {
  transform: translateY(-2px);
  border-color: rgba(139, 127, 214, 0.4);
  box-shadow: var(--shadow-dream);
}

/* ===================================================
   DASHBOARD PAGE
   =================================================== */

.dashboard-page {
  padding: var(--space-xl) 0;
  min-height: calc(100vh - 70px);
}

.dashboard-container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 var(--space-lg);
}

.dashboard-header {
  margin-bottom: var(--space-xl);
}

.dashboard-welcome {
  font-size: 2rem;
  font-weight: 300;
  color: white;
  margin-bottom: var(--space-sm);
  font-family: var(--font-heading);
}

.dashboard-subtitle {
  color: var(--neutral-300);
  font-size: 1.1rem;
}

/* Dashboard Layout */
.dashboard-layout {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: var(--space-xl);
}

/* Sidebar */
.dashboard-sidebar {
  position: sticky;
  top: calc(70px + var(--space-lg));
  height: fit-content;
}

.sidebar-card {
  background: rgba(37, 35, 57, 0.4);
  border: 1px solid rgba(139, 127, 214, 0.2);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  margin-bottom: var(--space-lg);
}

.user-profile {
  text-align: center;
  padding-bottom: var(--space-lg);
  border-bottom: 1px solid rgba(139, 127, 214, 0.2);
}

.profile-avatar {
  width: 80px;
  height: 80px;
  border-radius: var(--radius-full);
  border: 3px solid var(--dream-lavender);
  margin: 0 auto var(--space-md);
}

.profile-name {
  font-size: 1.25rem;
  font-weight: 600;
  color: white;
  margin-bottom: var(--space-xs);
}

.profile-email {
  font-size: 0.875rem;
  color: var(--neutral-400);
}

/* Dream Stats */
.dream-stats {
  padding-top: var(--space-lg);
}

.stat-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--space-sm) 0;
}

.stat-item label {
  color: var(--neutral-400);
  font-size: 0.875rem;
}

.stat-item .value {
  color: white;
  font-weight: 600;
}

/* Quick Actions */
.quick-actions {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
}

.action-link {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-sm) var(--space-md);
  background: rgba(139, 127, 214, 0.1);
  border: 1px solid transparent;
  border-radius: var(--radius-md);
  color: var(--neutral-300);
  text-decoration: none;
  transition: all var(--transition-base);
}

.action-link:hover {
  background: rgba(139, 127, 214, 0.2);
  border-color: rgba(139, 127, 214, 0.3);
  color: white;
}

.action-link i {
  width: 20px;
  text-align: center;
}

/* Main Content Area */
.dashboard-main {
  min-width: 0; /* Prevent grid blowout */
}

/* Dream List Header */
.dream-list-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--space-lg);
  flex-wrap: wrap;
  gap: var(--space-md);
}

.dream-list-title {
  font-size: 1.5rem;
  font-weight: 600;
  color: white;
}

.dream-controls {
  display: flex;
  gap: var(--space-sm);
  align-items: center;
}

.filter-select {
  background: rgba(37, 35, 57, 0.5);
  border: 1px solid rgba(139, 127, 214, 0.3);
  border-radius: var(--radius-md);
  padding: var(--space-xs) var(--space-md);
  color: white;
  cursor: pointer;
}

.view-toggle {
  display: flex;
  background: rgba(37, 35, 57, 0.5);
  border: 1px solid rgba(139, 127, 214, 0.3);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.view-btn {
  background: transparent;
  border: none;
  color: var(--neutral-400);
  padding: var(--space-xs) var(--space-md);
  cursor: pointer;
  transition: all var(--transition-base);
}

.view-btn.active {
  background: rgba(139, 127, 214, 0.2);
  color: white;
}

/* Dream Limit Indicator */
.dream-limit-indicator {
  background: rgba(214, 127, 155, 0.1);
  border: 1px solid rgba(214, 127, 155, 0.3);
  border-radius: var(--radius-md);
  padding: var(--space-md);
  margin-bottom: var(--space-lg);
  text-align: center;
}

.limit-progress {
  width: 100%;
  height: 8px;
  background: rgba(214, 127, 155, 0.2);
  border-radius: var(--radius-full);
  overflow: hidden;
  margin: var(--space-sm) 0;
}

.limit-progress-bar {
  height: 100%;
  background: var(--gradient-mystic);
  transition: width var(--transition-slow);
}

.limit-text {
  font-size: 0.875rem;
  color: var(--dream-rose);
}

/* Dream Streak Visualization */
.streak-indicator {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
  padding: var(--space-sm);
  background: rgba(127, 200, 214, 0.1);
  border-radius: var(--radius-md);
  margin-bottom: var(--space-md);
}

.streak-flame {
  font-size: 1.5rem;
  color: var(--dream-gold);
  animation: flicker 2s ease-in-out infinite;
}

@keyframes flicker {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.8; transform: scale(1.05); }
}

.streak-text {
  font-weight: 600;
  color: var(--dream-aurora);
}

/* Dream Items */
.dreams-timeline {
  position: relative;
}

.dream-item {
  display: flex;
  gap: var(--space-lg);
  margin-bottom: var(--space-xl);
  position: relative;
}

.dream-date-badge {
  flex-shrink: 0;
  width: 100px;
  text-align: center;
}

.date-day {
  font-size: 2rem;
  font-weight: 300;
  color: var(--dream-lavender);
  font-family: var(--font-heading);
}

.date-month {
  font-size: 0.875rem;
  color: var(--neutral-400);
  text-transform: uppercase;
}

.dream-content-card {
  flex: 1;
  background: rgba(37, 35, 57, 0.4);
  border: 1px solid rgba(139, 127, 214, 0.2);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: all var(--transition-base);
  cursor: pointer;
  position: relative;
}

.dream-content-card:hover {
  transform: translateX(4px);
  border-color: rgba(139, 127, 214, 0.4);
  box-shadow: var(--shadow-dream);
}

.dream-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

/* Dream View Badge */
.dream-view-badge {
  position: absolute;
  top: var(--space-sm);
  right: var(--space-sm);
  background: rgba(15, 14, 26, 0.8);
  backdrop-filter: blur(10px);
  padding: var(--space-xs) var(--space-sm);
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  gap: var(--space-xs);
  font-size: 0.875rem;
  color: white;
}

.dream-view-badge i {
  color: var(--dream-aurora);
}

.dream-body {
  padding: var(--space-lg);
}

.dream-header {
  display: flex;
  justify-content: space-between;
  align-items: start;
  margin-bottom: var(--space-md);
}

.dream-title {
  font-size: 1.25rem;
  font-weight: 600;
  color: white;
  margin-bottom: var(--space-xs);
}

.emotion-tag {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  padding: 2px var(--space-sm);
  background: rgba(139, 127, 214, 0.2);
  border-radius: var(--radius-full);
  font-size: 0.875rem;
  color: var(--dream-lavender);
}

.dream-excerpt {
  color: var(--neutral-300);
  line-height: 1.8;
  margin-bottom: var(--space-md);
}

.dream-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: var(--space-md);
  border-top: 1px solid rgba(139, 127, 214, 0.1);
}

.dream-meta {
  display: flex;
  gap: var(--space-md);
  font-size: 0.875rem;
  color: var(--neutral-400);
}

.dream-meta span {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
}

.dream-actions {
  display: flex;
  gap: var(--space-xs);
}

.icon-btn {
  background: transparent;
  border: 1px solid transparent;
  color: var(--neutral-400);
  padding: var(--space-xs);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all var(--transition-base);
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.icon-btn:hover {
  background: rgba(139, 127, 214, 0.1);
  border-color: rgba(139, 127, 214, 0.3);
  color: var(--dream-lavender);
}

.icon-btn.delete:hover {
  background: rgba(214, 127, 155, 0.1);
  border-color: rgba(214, 127, 155, 0.3);
  color: var(--dream-rose);
}

/* Empty State */
.empty-dreams {
  text-align: center;
  padding: var(--space-2xl);
}

.empty-icon {
  font-size: 4rem;
  color: var(--dream-lavender);
  opacity: 0.3;
  margin-bottom: var(--space-lg);
}

.empty-dreams h3 {
  font-size: 1.5rem;
  color: white;
  margin-bottom: var(--space-sm);
  font-family: var(--font-heading);
}

.empty-dreams p {
  color: var(--neutral-400);
  margin-bottom: var(--space-lg);
}

/* Recurring Symbols */
.recurring-symbols {
  margin-top: var(--space-xl);
  padding: var(--space-lg);
  background: rgba(37, 35, 57, 0.4);
  border: 1px solid rgba(139, 127, 214, 0.2);
  border-radius: var(--radius-lg);
}

.recurring-symbols h3 {
  font-size: 1.25rem;
  color: var(--dream-lavender);
  margin-bottom: var(--space-md);
}

.symbol-list {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
}

.symbol-item {
  background: rgba(139, 127, 214, 0.1);
  border: 1px solid rgba(139, 127, 214, 0.3);
  border-radius: var(--radius-full);
  padding: var(--space-xs) var(--space-md);
  display: flex;
  align-items: center;
  gap: var(--space-xs);
}

.symbol-name {
  color: white;
  font-weight: 500;
}

.symbol-count {
  color: var(--dream-lavender);
  font-size: 0.875rem;
}

/* Symbol Insights Dashboard */
.symbol-insights-card {
  background: var(--gradient-dream);
  color: white;
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  margin-bottom: var(--space-lg);
}

.insights-header {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  margin-bottom: var(--space-md);
}

.insights-header i {
  font-size: 1.5rem;
}

.insight-metric {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--space-sm) 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

.insight-metric:last-child {
  border-bottom: none;
}

.metric-label {
  font-weight: 500;
}

.metric-value {
  font-size: 1.25rem;
  font-weight: 300;
  font-family: var(--font-heading);
}

.insight-recommendation {
  background: rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-md);
  padding: var(--space-md);
  margin-top: var(--space-md);
  font-style: italic;
}

/* ===================================================
   NEW DREAM PAGE
   =================================================== */

.new-dream-page {
  padding: var(--space-xl) 0;
  min-height: calc(100vh - 70px);
}

.dream-form-container {
  max-width: 800px;
  margin: 0 auto;
  padding: 0 var(--space-lg);
}

.form-header {
  text-align: center;
  margin-bottom: var(--space-xl);
}

.form-title {
  font-size: 2rem;
  font-weight: 300;
  color: white;
  margin-bottom: var(--space-sm);
  font-family: var(--font-heading);
}

.form-subtitle {
  color: var(--neutral-300);
}

.dream-form-card {
  background: rgba(37, 35, 57, 0.4);
  border: 1px solid rgba(139, 127, 214, 0.2);
  border-radius: var(--radius-lg);
  padding: var(--space-xl);
}

.form-group {
  margin-bottom: var(--space-lg);
}

.form-group label {
  display: block;
  font-weight: 600;
  color: white;
  margin-bottom: var(--space-sm);
}

.dream-textarea {
  width: 100%;
  background: rgba(15, 14, 26, 0.5);
  border: 1px solid rgba(139, 127, 214, 0.3);
  border-radius: var(--radius-md);
  padding: var(--space-md);
  color: white;
  font-size: 1rem;
  line-height: 1.8;
  resize: vertical;
  min-height: 150px;
  transition: all var(--transition-base);
}

.dream-textarea:focus {
  outline: none;
  border-color: var(--dream-lavender);
  background: rgba(15, 14, 26, 0.7);
}

.char-counter {
  text-align: right;
  font-size: 0.875rem;
  color: var(--neutral-500);
  margin-top: var(--space-xs);
}

/* Enhanced Symbol Selection */
.form-hint {
  font-size: 0.875rem;
  color: var(--neutral-400);
  margin-bottom: var(--space-sm);
}

.symbol-pills {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
  gap: var(--space-xs);
  margin-top: var(--space-sm);
}

.symbol-pill {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-xs) var(--space-sm);
  background: rgba(139, 127, 214, 0.1);
  border: 1px solid rgba(139, 127, 214, 0.3);
  border-radius: var(--radius-full);
  color: var(--neutral-300);
  font-size: 0.875rem;
  cursor: pointer;
  transition: all var(--transition-base);
  text-align: center;
}

.symbol-pill:hover {
  background: rgba(139, 127, 214, 0.2);
  border-color: var(--dream-lavender);
  color: white;
  transform: translateY(-2px);
}

.symbol-pill.active {
  background: var(--gradient-dream);
  border-color: var(--dream-lavender);
  color: white;
  font-weight: 600;
}

.selected-symbols-display {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-xs);
  margin-top: var(--space-sm);
  padding: var(--space-sm);
  background: rgba(139, 127, 214, 0.05);
  border-radius: var(--radius-md);
  min-height: 50px;
}

.selected-symbol {
  background: var(--dream-lavender);
  color: white;
  padding: var(--space-xs) var(--space-sm);
  border-radius: var(--radius-full);
  font-size: 0.875rem;
  display: flex;
  align-items: center;
  gap: var(--space-xs);
}

.selected-symbol .remove {
  cursor: pointer;
  opacity: 0.7;
  transition: opacity var(--transition-base);
}

.selected-symbol .remove:hover {
  opacity: 1;
}

/* Emotion Selector */
.emotion-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: var(--space-md);
}

.emotion-option {
  padding: var(--space-md);
  background: rgba(15, 14, 26, 0.5);
  border: 1px solid rgba(139, 127, 214, 0.3);
  border-radius: var(--radius-md);
  text-align: center;
  cursor: pointer;
  transition: all var(--transition-base);
}

.emotion-option:hover {
  background: rgba(139, 127, 214, 0.1);
  border-color: var(--dream-lavender);
}

.emotion-option.selected {
  background: rgba(139, 127, 214, 0.2);
  border-color: var(--dream-lavender);
  color: white;
}

.emotion-option i {
  font-size: 2rem;
  display: block;
  margin-bottom: var(--space-xs);
  color: var(--dream-lavender);
}

.emotion-option span {
  font-size: 0.875rem;
  font-weight: 500;
}

/* Toggle Switch - Fixed */
.toggle-switch {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-sm) 0;
  cursor: pointer;
}

.toggle-switch span {
  color: var(--neutral-300);
  user-select: none;
}

.toggle-switch input[type="checkbox"] {
  position: absolute;
  opacity: 0;
  cursor: pointer;
}

.switch {
  position: relative;
  width: 48px;
  height: 24px;
  background: rgba(139, 127, 214, 0.2);
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: background var(--transition-base);
  flex-shrink: 0;
}

.switch::after {
  content: '';
  position: absolute;
  top: 2px;
  left: 2px;
  width: 20px;
  height: 20px;
  background: white;
  border-radius: var(--radius-full);
  transition: transform var(--transition-base);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.toggle-switch input:checked + .switch {
  background: var(--dream-lavender);
}

.toggle-switch input:checked + .switch::after {
  transform: translateX(24px);
}

.toggle-switch:hover .switch {
  opacity: 0.8;
}

/* Form Actions */
.form-actions {
  display: flex;
  gap: var(--space-md);
  margin-top: var(--space-xl);
}

.btn-primary {
  flex: 1;
  background: var(--gradient-dream);
  color: white;
  border: none;
  padding: var(--space-sm) var(--space-xl);
  border-radius: var(--radius-md);
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-base);
}

.btn-primary:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: var(--shadow-dream);
}

.btn-primary:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.btn-secondary {
  background: transparent;
  color: var(--neutral-400);
  border: 1px solid rgba(139, 127, 214, 0.3);
  padding: var(--space-sm) var(--space-xl);
  border-radius: var(--radius-md);
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-base);
}

.btn-secondary:hover {
  border-color: var(--dream-lavender);
  color: white;
}

/* ===================================================
   DREAM DETAIL VIEW
   =================================================== */

.dream-detail-modal {
  position: fixed;
  inset: 0;
  background: rgba(15, 14, 26, 0.95);
  backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-lg);
  z-index: 2000;
  overflow-y: auto;
}

.dream-detail-content {
  max-width: 900px;
  width: 100%;
  background: var(--dream-twilight);
  border: 1px solid rgba(139, 127, 214, 0.2);
  border-radius: var(--radius-xl);
  overflow: hidden;
  max-height: 90vh;
  overflow-y: auto;
}

.dream-detail-header {
  padding: var(--space-xl);
  background: rgba(139, 127, 214, 0.05);
  border-bottom: 1px solid rgba(139, 127, 214, 0.2);
}

.detail-title {
  font-size: 2rem;
  font-weight: 300;
  color: white;
  margin-bottom: var(--space-md);
  font-family: var(--font-heading);
}

.detail-meta {
  display: flex;
  gap: var(--space-lg);
  flex-wrap: wrap;
  color: var(--neutral-400);
  font-size: 0.875rem;
}

.dream-detail-image {
  width: 100%;
  height: 400px;
  object-fit: cover;
}

.dream-detail-body {
  padding: var(--space-xl);
}

.detail-section {
  margin-bottom: var(--space-xl);
}

.detail-section h3 {
  font-size: 1.25rem;
  color: var(--dream-lavender);
  margin-bottom: var(--space-md);
  font-family: var(--font-heading);
}

.detail-section p {
  color: var(--neutral-300);
  line-height: 1.8;
}

.symbol-analysis {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: var(--space-md);
  margin-top: var(--space-md);
}

.symbol-card {
  background: rgba(139, 127, 214, 0.05);
  border: 1px solid rgba(139, 127, 214, 0.2);
  border-radius: var(--radius-md);
  padding: var(--space-md);
}

.symbol-card h4 {
  color: var(--dream-moonlight);
  margin-bottom: var(--space-xs);
}

.symbol-card p {
  font-size: 0.875rem;
  color: var(--neutral-400);
}

.detail-actions {
  padding: var(--space-lg) var(--space-xl);
  background: rgba(139, 127, 214, 0.05);
  border-top: 1px solid rgba(139, 127, 214, 0.2);
  display: flex;
  gap: var(--space-md);
  justify-content: flex-end;
}

.close-detail {
  position: absolute;
  top: var(--space-md);
  right: var(--space-md);
  background: transparent;
  border: none;
  color: var(--neutral-400);
  font-size: 1.5rem;
  cursor: pointer;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-md);
  transition: all var(--transition-base);
}

.close-detail:hover {
  background: rgba(139, 127, 214, 0.1);
  color: white;
}

/* Preview Text in Modal */
.preview-text {
  font-size: 1.1rem;
  color: var(--neutral-300);
  margin-bottom: var(--space-lg);
  font-style: italic;
  padding: var(--space-md);
  background: rgba(139, 127, 214, 0.05);
  border-radius: var(--radius-md);
  border-left: 4px solid var(--dream-lavender);
}

.preview-teaser {
  text-align: center;
  padding: var(--space-lg);
  background: rgba(139, 127, 214, 0.1);
  border-radius: var(--radius-md);
}

.preview-teaser i {
  font-size: 3rem;
  color: var(--dream-lavender);
  margin-bottom: var(--space-md);
  display: block;
}

.preview-teaser h3 {
  font-size: 1.5rem;
  color: white;
  margin-bottom: var(--space-sm);
}

.preview-teaser p {
  color: var(--neutral-300);
  line-height: 1.6;
}

/* ===================================================
   ACCOUNT PAGE
   =================================================== */

.account-page {
  padding: var(--space-xl) 0;
  min-height: calc(100vh - 70px);
}

.account-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--space-lg);
}

.account-header {
  text-align: center;
  margin-bottom: var(--space-xl);
}

.account-title {
  font-size: 2rem;
  font-weight: 300;
  color: white;
  margin-bottom: var(--space-sm);
  font-family: var(--font-heading);
}

.account-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: var(--space-lg);
}

.account-section {
  background: rgba(37, 35, 57, 0.4);
  border: 1px solid rgba(139, 127, 214, 0.2);
  border-radius: var(--radius-lg);
  padding: var(--space-xl);
}

.section-title {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  font-size: 1.25rem;
  color: white;
  margin-bottom: var(--space-lg);
}

.section-title i {
  color: var(--dream-lavender);
}

/* Settings Form */
.settings-form {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

.form-control {
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
}

.form-control label {
  font-weight: 500;
  color: white;
}

.form-control input,
.form-control select {
  background: rgba(15, 14, 26, 0.5);
  border: 1px solid rgba(139, 127, 214, 0.3);
  border-radius: var(--radius-md);
  padding: var(--space-sm) var(--space-md);
  color: white;
  transition: all var(--transition-base);
}

.form-control input:focus,
.form-control select:focus {
  outline: none;
  border-color: var(--dream-lavender);
}

/* Subscription Card */
.subscription-status {
  text-align: center;
  padding: var(--space-lg);
  background: rgba(139, 127, 214, 0.05);
  border-radius: var(--radius-md);
  margin-bottom: var(--space-lg);
}

.plan-name {
  font-size: 1.5rem;
  color: var(--dream-lavender);
  margin-bottom: var(--space-xs);
}

.plan-details {
  color: var(--neutral-400);
  margin-bottom: var(--space-md);
}

/* Export Options */
.export-options {
  display: flex;
  gap: var(--space-sm);
  flex-wrap: wrap;
}

/* Danger Zone */
.danger-zone .btn-secondary {
  border-color: rgba(214, 127, 155, 0.3);
  color: var(--dream-rose);
}

.danger-zone .btn-secondary:hover {
  background: rgba(214, 127, 155, 0.1);
  border-color: var(--dream-rose);
}

/* Dream Reminders Settings */
.reminder-settings {
  background: rgba(139, 127, 214, 0.05);
  border-radius: var(--radius-md);
  padding: var(--space-md);
  margin-top: var(--space-md);
}

.reminder-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-md);
}

.time-picker {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.time-input {
  background: rgba(15, 14, 26, 0.5);
  border: 1px solid rgba(139, 127, 214, 0.3);
  border-radius: var(--radius-sm);
  padding: var(--space-xs) var(--space-sm);
  color: white;
  width: 100px;
}

/* ===================================================
   EXPLORE PAGE
   =================================================== */

.explore-page {
  padding: var(--space-xl) 0;
  min-height: calc(100vh - 70px);
}

.explore-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--space-lg);
}

.explore-header {
  text-align: center;
  margin-bottom: var(--space-xl);
}

.explore-search {
  max-width: 600px;
  margin: 0 auto var(--space-xl);
  position: relative;
}

.search-input {
  width: 100%;
  background: rgba(37, 35, 57, 0.5);
  border: 1px solid rgba(139, 127, 214, 0.3);
  border-radius: var(--radius-full);
  padding: var(--space-sm) var(--space-sm) var(--space-sm) var(--space-2xl);
  color: white;
  font-size: 1rem;
  transition: all var(--transition-base);
}

.search-input:focus {
  outline: none;
  border-color: var(--dream-lavender);
}

.search-icon {
  position: absolute;
  left: var(--space-md);
  top: 50%;
  transform: translateY(-50%);
  color: var(--neutral-500);
}

.explore-filters {
  display: flex;
  justify-content: center;
  gap: var(--space-sm);
  flex-wrap: wrap;
  margin-bottom: var(--space-xl);
}

.filter-chip {
  padding: var(--space-xs) var(--space-md);
  background: transparent;
  border: 1px solid rgba(139, 127, 214, 0.3);
  border-radius: var(--radius-full);
  color: var(--neutral-400);
  cursor: pointer;
  transition: all var(--transition-base);
}

.filter-chip:hover,
.filter-chip.active {
  background: rgba(139, 127, 214, 0.2);
  border-color: var(--dream-lavender);
  color: white;
}

.public-dreams-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: var(--space-lg);
}

.public-dream-card {
  background: rgba(37, 35, 57, 0.4);
  border: 1px solid rgba(139, 127, 214, 0.2);
  border-radius: var(--radius-lg);
  overflow: hidden;
  cursor: pointer;
  transition: all var(--transition-base);
}

.public-dream-card:hover {
  transform: translateY(-4px);
  border-color: rgba(139, 127, 214, 0.4);
  box-shadow: var(--shadow-dream);
}

.public-dream-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.public-dream-content {
  padding: var(--space-lg);
}

.public-dream-title {
  font-size: 1.1rem;
  font-weight: 600;
  color: white;
  margin-bottom: var(--space-sm);
}

.public-dream-excerpt {
  color: var(--neutral-300);
  font-size: 0.95rem;
  line-height: 1.6;
  margin-bottom: var(--space-md);
}

.public-dream-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.dream-author {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
}

.author-avatar {
  width: 24px;
  height: 24px;
  border-radius: var(--radius-full);
}

.author-name {
  font-size: 0.875rem;
  color: var(--neutral-400);
}

/* Load More */
.load-more {
  text-align: center;
  margin-top: var(--space-xl);
}

/* ===================================================
   LOGIN/REGISTER PAGE
   =================================================== */

.auth-page {
  min-height: calc(100vh - 70px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-lg);
}

.auth-container {
  max-width: 450px;
  width: 100%;
}

.auth-card {
  overflow: hidden;
}

.auth-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  background: rgba(37, 35, 57, 0.3);
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
}

.auth-tab {
  background: transparent;
  border: none;
  padding: var(--space-md);
  color: var(--neutral-400);
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-base);
  position: relative;
}

.auth-tab.active {
  color: white;
  background: rgba(139, 127, 214, 0.1);
}

.auth-tab.active::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--gradient-dream);
}

.auth-form {
  padding: var(--space-xl);
}

.auth-form h2 {
  font-size: 1.75rem;
  margin-bottom: var(--space-xs);
  color: white;
  font-family: var(--font-heading);
}

.auth-form > p {
  color: var(--neutral-400);
  margin-bottom: var(--space-lg);
}

.form-input {
  width: 100%;
  background: rgba(15, 14, 26, 0.5);
  border: 1px solid rgba(139, 127, 214, 0.3);
  border-radius: var(--radius-md);
  padding: var(--space-sm) var(--space-md);
  color: white;
  font-size: 1rem;
  transition: all var(--transition-base);
}

.form-input:focus {
  outline: none;
  border-color: var(--dream-lavender);
  background: rgba(15, 14, 26, 0.7);
}

.checkbox-label {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  cursor: pointer;
  color: var(--neutral-300);
  user-select: none;
}

.checkbox-label input[type="checkbox"] {
  width: 20px;
  height: 20px;
  accent-color: var(--dream-lavender);
  cursor: pointer;
  flex-shrink: 0;
}

/* Custom checkbox styling */
.custom-checkbox {
  position: relative;
  display: inline-flex;
  align-items: center;
  cursor: pointer;
  user-select: none;
}

.custom-checkbox input[type="checkbox"] {
  position: absolute;
  opacity: 0;
  cursor: pointer;
}

.custom-checkbox .checkmark {
  width: 20px;
  height: 20px;
  background: rgba(139, 127, 214, 0.1);
  border: 2px solid rgba(139, 127, 214, 0.3);
  border-radius: var(--radius-sm);
  transition: all var(--transition-base);
  display: flex;
  align-items: center;
  justify-content: center;
}

.custom-checkbox input:checked ~ .checkmark {
  background: var(--dream-lavender);
  border-color: var(--dream-lavender);
}

.custom-checkbox .checkmark::after {
  content: '✓';
  color: white;
  font-size: 14px;
  opacity: 0;
  transform: scale(0);
  transition: all var(--transition-base);
}

.custom-checkbox input:checked ~ .checkmark::after {
  opacity: 1;
  transform: scale(1);
}

.custom-checkbox:hover .checkmark {
  border-color: var(--dream-lavender);
}

/* ===================================================
   PRICING PAGE
   =================================================== */

.pricing-page {
  padding: var(--space-xl) 0;
  min-height: calc(100vh - 70px);
}

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: var(--space-lg);
  max-width: 1100px;
  margin: 0 auto;
}

.pricing-card {
  background: rgba(37, 35, 57, 0.4);
  border: 1px solid rgba(139, 127, 214, 0.2);
  border-radius: var(--radius-lg);
  padding: var(--space-xl);
  position: relative;
  transition: all var(--transition-base);
}

.pricing-card:hover {
  transform: translateY(-4px);
  border-color: rgba(139, 127, 214, 0.4);
  box-shadow: var(--shadow-dream);
}

.pricing-card.featured {
  border-color: var(--dream-lavender);
  transform: scale(1.02);
}

.badge {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--gradient-dream);
  color: white;
  padding: var(--space-xs) var(--space-md);
  border-radius: var(--radius-full);
  font-size: 0.875rem;
  font-weight: 600;
  white-space: nowrap;
}

.premium-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  background: var(--gradient-dream);
  color: white;
  padding: 2px var(--space-sm);
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.premium-badge i {
  font-size: 0.875rem;
}

.pricing-card h3 {
  font-size: 1.5rem;
  text-align: center;
  color: white;
  margin-bottom: var(--space-md);
}

.price {
  text-align: center;
  margin-bottom: var(--space-lg);
}

.price .amount {
  font-size: 3rem;
  font-weight: 300;
  color: var(--dream-lavender);
  font-family: var(--font-heading);
}

.price .period {
  font-size: 1rem;
  color: var(--neutral-400);
  margin-left: var(--space-xs);
}

.pricing-card ul {
  list-style: none;
  margin-bottom: var(--space-lg);
}

.pricing-card li {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-xs) 0;
  color: var(--neutral-300);
}

.pricing-card li i.fa-check {
  color: var(--dream-aurora);
}

.pricing-card li i.fa-times {
  color: var(--neutral-600);
}

/* ===================================================
   FEATURES & HOW IT WORKS
   =================================================== */

/* Container */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--space-lg);
}

/* Sections */
section {
  padding: var(--space-2xl) 0;
  position: relative;
}

.section-header {
  text-align: center;
  margin-bottom: var(--space-2xl);
}

.section-header h1,
.section-header h2 {
  font-size: 2.5rem;
  font-weight: 300;
  color: white;
  margin-bottom: var(--space-sm);
  font-family: var(--font-heading);
}

.section-header p {
  font-size: 1.1rem;
  color: var(--neutral-300);
}

/* Features Grid */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: var(--space-lg);
  margin-top: var(--space-xl);
}

.feature-card {
  padding: var(--space-xl);
  text-align: center;
}

.feature-icon {
  width: 80px;
  height: 80px;
  margin: 0 auto var(--space-md);
  background: rgba(139, 127, 214, 0.1);
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
}

.feature-icon i {
  font-size: 2rem;
  color: var(--dream-lavender);
}

.feature-card h3 {
  font-size: 1.25rem;
  color: white;
  margin-bottom: var(--space-sm);
}

.feature-card p {
  color: var(--neutral-300);
  line-height: 1.6;
}

/* How It Works */
.how-it-works {
  background: rgba(139, 127, 214, 0.05);
}

.steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: var(--space-xl);
  max-width: 900px;
  margin: 0 auto;
}

.step {
  text-align: center;
  padding: var(--space-lg);
}

.step-number {
  width: 60px;
  height: 60px;
  margin: 0 auto var(--space-md);
  background: var(--gradient-dream);
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  font-weight: 600;
  color: white;
}

.step h3 {
  font-size: 1.25rem;
  color: white;
  margin-bottom: var(--space-sm);
}

.step p {
  color: var(--neutral-300);
  line-height: 1.6;
}

/* CTA Section */
.cta-section {
  background: rgba(37, 35, 57, 0.4);
  padding: var(--space-3xl) 0;
}

.cta-content {
  text-align: center;
  max-width: 600px;
  margin: 0 auto;
}

.cta-content h2 {
  font-size: 2rem;
  color: white;
  margin-bottom: var(--space-sm);
  font-family: var(--font-heading);
}

.cta-content p {
  font-size: 1.1rem;
  color: var(--neutral-300);
  margin-bottom: var(--space-lg);
}

/* ===================================================
   QUICK NOTES FEATURE
   =================================================== */

.quick-notes-widget {
  position: fixed;
  bottom: var(--space-lg);
  right: var(--space-lg);
  z-index: 100;
}

.notes-toggle {
  width: 56px;
  height: 56px;
  background: var(--gradient-dream);
  border: none;
  border-radius: var(--radius-full);
  color: white;
  cursor: pointer;
  box-shadow: var(--shadow-lg);
  transition: all var(--transition-base);
}

.notes-toggle:hover {
  transform: scale(1.05);
  box-shadow: var(--shadow-dream);
}

.notes-panel {
  position: absolute;
  bottom: calc(100% + var(--space-sm));
  right: 0;
  width: 320px;
  background: var(--dream-twilight);
  border: 1px solid rgba(139, 127, 214, 0.2);
  border-radius: var(--radius-lg);
  padding: var(--space-md);
  box-shadow: var(--shadow-lg);
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: all var(--transition-base);
}

.notes-panel.open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.notes-input {
  width: 100%;
  background: rgba(15, 14, 26, 0.5);
  border: 1px solid rgba(139, 127, 214, 0.3);
  border-radius: var(--radius-md);
  padding: var(--space-sm);
  color: white;
  resize: none;
  margin-bottom: var(--space-sm);
}

.saved-notes {
  max-height: 200px;
  overflow-y: auto;
  margin-top: var(--space-sm);
}

.note-item {
  background: rgba(139, 127, 214, 0.1);
  padding: var(--space-sm);
  border-radius: var(--radius-sm);
  margin-bottom: var(--space-xs);
  font-size: 0.875rem;
}

.note-date {
  font-size: 0.75rem;
  color: var(--neutral-500);
}

/* ===================================================
   MOOD TRACKER
   =================================================== */

.mood-tracker {
  background: rgba(37, 35, 57, 0.4);
  border: 1px solid rgba(139, 127, 214, 0.2);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  margin-bottom: var(--space-lg);
}

.mood-prompt {
  text-align: center;
  margin-bottom: var(--space-md);
}

.mood-options {
  display: flex;
  justify-content: center;
  gap: var(--space-md);
}

.mood-option {
  width: 60px;
  height: 60px;
  background: rgba(139, 127, 214, 0.1);
  border: 2px solid transparent;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  cursor: pointer;
  transition: all var(--transition-base);
}

.mood-option:hover {
  background: rgba(139, 127, 214, 0.2);
  border-color: var(--dream-lavender);
  transform: scale(1.1);
}

.mood-option.selected {
  background: rgba(139, 127, 214, 0.3);
  border-color: var(--dream-lavender);
}

.mood-history-chart {
  margin-top: var(--space-lg);
  height: 150px;
  background: rgba(15, 14, 26, 0.3);
  border-radius: var(--radius-md);
  position: relative;
  overflow: hidden;
}

/* ===================================================
   TOAST NOTIFICATIONS
   =================================================== */

.toast {
  position: fixed;
  bottom: var(--space-lg);
  right: var(--space-lg);
  background: var(--dream-twilight);
  backdrop-filter: blur(10px);
  border-radius: var(--radius-md);
  padding: var(--space-md) var(--space-lg);
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  z-index: 3000;
  border: 1px solid rgba(139, 127, 214, 0.3);
  box-shadow: var(--shadow-lg);
  max-width: 400px;
  animation: slideIn var(--transition-base), bounce 0.3s ease-out 0.2s;
}

@keyframes slideIn {
  from {
    transform: translateX(120%);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

@keyframes bounce {
  0%, 100% { transform: translateX(0); }
  50% { transform: translateX(-10px); }
}

.toast.success {
  border-left: 4px solid var(--dream-aurora);
}

.toast.error {
  border-left: 4px solid var(--dream-rose);
}

.toast.warning {
  border-left: 4px solid var(--dream-gold);
}

.toast.info {
  border-left: 4px solid var(--dream-lavender);
}

.toast-progress {
  position: absolute;
  bottom: 0;
  left: 0;
  height: 3px;
  background: currentColor;
  opacity: 0.3;
  animation: progress 3s linear;
}

@keyframes progress {
  from { width: 100%; }
  to { width: 0; }
}

/* ===================================================
   LOADING STATES
   =================================================== */

.loading-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 14, 26, 0.95);
  backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
}

.dream-loader {
  width: 60px;
  height: 60px;
  position: relative;
}

.loader-moon {
  width: 100%;
  height: 100%;
  border: 2px solid transparent;
  border-top-color: var(--dream-lavender);
  border-radius: var(--radius-full);
  animation: rotate 1s linear infinite;
}

@keyframes rotate {
  to { transform: rotate(360deg); }
}

/* Skeleton Loading */
.skeleton {
  background: linear-gradient(
    90deg,
    rgba(139, 127, 214, 0.1) 0%,
    rgba(139, 127, 214, 0.2) 50%,
    rgba(139, 127, 214, 0.1) 100%
  );
  background-size: 200% 100%;
  animation: skeleton-loading 1.5s ease-in-out infinite;
  border-radius: var(--radius-md);
}

@keyframes skeleton-loading {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

.skeleton-text {
  height: 1em;
  margin-bottom: var(--space-xs);
}

.skeleton-title {
  height: 1.5em;
  width: 60%;
  margin-bottom: var(--space-sm);
}

.skeleton-image {
  height: 200px;
  width: 100%;
  margin-bottom: var(--space-md);
}

/* ===================================================
   TRANSITIONS & ANIMATIONS
   =================================================== */

.fade-enter-active, .fade-leave-active {
  transition: opacity var(--transition-base);
}

.fade-enter-from, .fade-leave-to {
  opacity: 0;
}

.slide-enter-active, .slide-leave-active {
  transition: all var(--transition-base);
}

.slide-enter-from {
  transform: translateY(20px);
  opacity: 0;
}

.slide-leave-to {
  transform: translateY(-20px);
  opacity: 0;
}

/* ===================================================
   RESPONSIVE DESIGN
   =================================================== */

@media (max-width: 1024px) {
  .dashboard-layout {
    grid-template-columns: 1fr;
  }
  
  .dashboard-sidebar {
    position: static;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--space-lg);
  }
  
  .sidebar-card {
    margin-bottom: 0;
  }
}

@media (max-width: 768px) {
  .hero-title {
    font-size: 2rem;
  }
  
  .nav-link {
    display: none;
  }
  
  .dream-item {
    flex-direction: column;
  }
  
  .dream-date-badge {
    width: auto;
  }
  
  .account-grid {
    grid-template-columns: 1fr;
  }
  
  .public-dreams-grid {
    grid-template-columns: 1fr;
  }
  
  .quick-notes-widget {
    bottom: var(--space-md);
    right: var(--space-md);
  }
  
  .notes-panel {
    width: calc(100vw - var(--space-xl));
    right: calc(-1 * var(--space-md));
  }
  
  .mood-options {
    flex-wrap: wrap;
  }
  
  .symbol-pills {
    grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
  }
  
  .breadcrumb-nav {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  
  .breadcrumb-list {
    white-space: nowrap;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 var(--space-md);
  }
  
  .form-actions {
    flex-direction: column;
  }
  
  .btn-secondary {
    width: 100%;
  }
  
  .export-options {
    flex-direction: column;
  }
  
  .export-options button {
    width: 100%;
  }
}

/* ===================================================
   UTILITIES
   =================================================== */

.text-center { text-align: center; }
.hidden { display: none; }

/* Accessibility */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}

/* ===================================================
   PRINT STYLES
   =================================================== */

@media print {
  body {
    background: white;
    color: black;
  }
  
  .navbar,
  .quick-notes-widget,
  .dream-actions,
  .form-actions,
  .toast {
    display: none !important;
  }
  
  .dream-card {
    break-inside: avoid;
    page-break-inside: avoid;
  }
}

/* ===================================================
   FEATURE 5: DREAM JOURNAL INSIGHTS (AI-POWERED WEEKLY REPORT)
   =================================================== */

.insights-report-widget {
  background: var(--gradient-night);
  border: 1px solid rgba(139, 127, 214, 0.2);
  border-radius: var(--radius-lg);
  padding: var(--space-xl);
  margin-bottom: var(--space-xl);
  position: relative;
  overflow: hidden;
}

.insights-report-widget::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(139, 127, 214, 0.1) 0%, transparent 70%);
  animation: pulse 4s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { transform: scale(1); opacity: 0.5; }
  50% { transform: scale(1.1); opacity: 0.8; }
}

.insights-content {
  position: relative;
  z-index: 1;
}

.weekly-insight-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--space-lg);
}

.weekly-insight-title {
  font-size: 1.5rem;
  color: white;
  font-family: var(--font-heading);
}

.insight-date-range {
  font-size: 0.875rem;
  color: var(--neutral-400);
}

.insight-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: var(--space-md);
  margin-bottom: var(--space-lg);
}

.insight-card {
  background: rgba(255, 255, 255, 0.05);
  border-radius: var(--radius-md);
  padding: var(--space-md);
  text-align: center;
}

.insight-icon {
  width: 48px;
  height: 48px;
  margin: 0 auto var(--space-sm);
  background: rgba(139, 127, 214, 0.2);
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
}

.insight-value {
  font-size: 1.75rem;
  font-weight: 300;
  color: var(--dream-lavender);
  font-family: var(--font-heading);
}

.insight-label {
  font-size: 0.875rem;
  color: var(--neutral-400);
  margin-top: var(--space-xs);
}

.insight-summary {
  background: rgba(139, 127, 214, 0.1);
  border-radius: var(--radius-md);
  padding: var(--space-lg);
  margin-top: var(--space-lg);
}

.insight-summary h4 {
  color: var(--dream-moonlight);
  margin-bottom: var(--space-sm);
}

.insight-summary p {
  color: var(--neutral-300);
  line-height: 1.6;
}

.generate-report-btn {
  background: var(--gradient-dream);
  color: white;
  border: none;
  padding: var(--space-sm) var(--space-lg);
  border-radius: var(--radius-full);
  font-weight: 600;
  cursor: pointer;
  margin-top: var(--space-md);
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  transition: all var(--transition-base);
}

.generate-report-btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-dream);
}

/* ===================================================
   FEATURE 6: DREAM CONNECTIONS MAP (VISUAL NETWORK)
   =================================================== */

.dream-connections-widget {
  background: rgba(37, 35, 57, 0.4);
  border: 1px solid rgba(139, 127, 214, 0.2);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  margin-bottom: var(--space-xl);
  min-height: 400px;
  position: relative;
}

.connections-canvas {
  width: 100%;
  height: 350px;
  background: rgba(15, 14, 26, 0.3);
  border-radius: var(--radius-md);
  position: relative;
  overflow: hidden;
}

.connection-node {
  position: absolute;
  width: 60px;
  height: 60px;
  background: var(--gradient-dream);
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-base);
  box-shadow: var(--shadow-md);
}

.connection-node:hover {
  transform: scale(1.1);
  box-shadow: var(--shadow-dream);
  z-index: 10;
}

.connection-node.symbol {
  background: var(--gradient-mystic);
  width: 48px;
  height: 48px;
  font-size: 0.875rem;
}

.connection-node.emotion {
  background: rgba(127, 200, 214, 0.8);
  width: 40px;
  height: 40px;
  font-size: 0.75rem;
}

.connection-line {
  position: absolute;
  background: rgba(139, 127, 214, 0.2);
  height: 2px;
  transform-origin: left center;
  pointer-events: none;
}

.connection-legend {
  display: flex;
  gap: var(--space-lg);
  margin-top: var(--space-md);
  justify-content: center;
}

.legend-item {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
  font-size: 0.875rem;
  color: var(--neutral-400);
}

.legend-dot {
  width: 12px;
  height: 12px;
  border-radius: var(--radius-full);
}

.legend-dot.dream {
  background: var(--gradient-dream);
}

.legend-dot.symbol {
  background: var(--gradient-mystic);
}

.legend-dot.emotion {
  background: rgba(127, 200, 214, 0.8);
}

.connection-details {
  position: absolute;
  background: var(--dream-twilight);
  border: 1px solid rgba(139, 127, 214, 0.3);
  border-radius: var(--radius-md);
  padding: var(--space-sm);
  font-size: 0.875rem;
  color: white;
  opacity: 0;
  visibility: hidden;
  transition: all var(--transition-fast);
  pointer-events: none;
  z-index: 20;
}

.connection-node:hover + .connection-details {
  opacity: 1;
  visibility: visible;
}

/* ===================================================
   FEATURE 7: DREAM ACHIEVEMENT SYSTEM (GAMIFICATION)
   =================================================== */

.achievements-widget {
  background: rgba(37, 35, 57, 0.4);
  border: 1px solid rgba(139, 127, 214, 0.2);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  margin-bottom: var(--space-xl);
}

.achievements-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--space-lg);
}

.achievements-title {
  font-size: 1.25rem;
  color: white;
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.achievements-title i {
  color: var(--dream-gold);
}

.achievement-progress {
  font-size: 0.875rem;
  color: var(--neutral-400);
}

.achievements-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: var(--space-md);
}

.achievement-card {
  background: rgba(15, 14, 26, 0.5);
  border: 2px solid transparent;
  border-radius: var(--radius-lg);
  padding: var(--space-md);
  text-align: center;
  cursor: pointer;
  transition: all var(--transition-base);
  position: relative;
  overflow: hidden;
}

.achievement-card.unlocked {
  border-color: var(--dream-gold);
  background: rgba(214, 173, 127, 0.1);
}

.achievement-card.locked {
  opacity: 0.6;
  filter: grayscale(1);
}

.achievement-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.achievement-icon {
  width: 64px;
  height: 64px;
  margin: 0 auto var(--space-sm);
  background: rgba(139, 127, 214, 0.1);
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  position: relative;
}

.achievement-card.unlocked .achievement-icon {
  background: rgba(214, 173, 127, 0.2);
}

.achievement-shine {
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: linear-gradient(
    45deg,
    transparent 30%,
    rgba(255, 255, 255, 0.3) 50%,
    transparent 70%
  );
  transform: rotate(45deg) translateX(-100%);
  animation: shine 3s ease-in-out infinite;
}

@keyframes shine {
  0%, 100% { transform: rotate(45deg) translateX(-100%); }
  50% { transform: rotate(45deg) translateX(100%); }
}

.achievement-name {
  font-size: 0.875rem;
  font-weight: 600;
  color: white;
  margin-bottom: var(--space-xs);
}

.achievement-description {
  font-size: 0.75rem;
  color: var(--neutral-400);
  line-height: 1.4;
}

.achievement-progress-bar {
  width: 100%;
  height: 4px;
  background: rgba(139, 127, 214, 0.2);
  border-radius: var(--radius-full);
  margin-top: var(--space-sm);
  overflow: hidden;
}

.achievement-progress-fill {
  height: 100%;
  background: var(--gradient-dream);
  transition: width var(--transition-slow);
}

.achievement-badge {
  position: absolute;
  top: -8px;
  right: -8px;
  width: 32px;
  height: 32px;
  background: var(--dream-gold);
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 0.875rem;
  font-weight: bold;
  box-shadow: var(--shadow-md);
}

.achievement-notification {
  position: fixed;
  top: 90px;
  right: var(--space-lg);
  background: var(--gradient-dream);
  color: white;
  padding: var(--space-md) var(--space-lg);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  display: flex;
  align-items: center;
  gap: var(--space-md);
  z-index: 2500;
  animation: slideInRight 0.5s ease-out;
}

@keyframes slideInRight {
  from {
    transform: translateX(120%);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

.achievement-notification i {
  font-size: 2rem;
  color: var(--dream-gold);
}

.achievement-level-system {
  margin-top: var(--space-lg);
  padding: var(--space-lg);
  background: rgba(139, 127, 214, 0.05);
  border-radius: var(--radius-md);
}

.level-info {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--space-sm);
}

.current-level {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--dream-lavender);
}

.level-progress {
  width: 100%;
  height: 12px;
  background: rgba(139, 127, 214, 0.2);
  border-radius: var(--radius-full);
  overflow: hidden;
  position: relative;
}

.level-progress-fill {
  height: 100%;
  background: var(--gradient-dream);
  transition: width var(--transition-slow);
  position: relative;
}

.level-progress-text {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 0.75rem;
  color: white;
  font-weight: 600;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

/* ===================================================
   ENHANCED DREAM STATISTICS
   =================================================== */

.enhanced-stats-widget {
  background: rgba(37, 35, 57, 0.4);
  border: 1px solid rgba(139, 127, 214, 0.2);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  margin-bottom: var(--space-xl);
}

.stats-visualization {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: var(--space-lg);
}

.stat-chart {
  background: rgba(15, 14, 26, 0.3);
  border-radius: var(--radius-md);
  padding: var(--space-md);
  height: 200px;
  position: relative;
}

.chart-title {
  font-size: 0.875rem;
  color: var(--neutral-400);
  margin-bottom: var(--space-sm);
  text-align: center;
}

/* ===================================================
   END OF DRIARY CSS
   =================================================== */