/* ═══════════════════════════════════════════════════════════
   DreamCraft – Premium CSS Stylesheet
   Glassmorphism + Dark/Light Mode + Smooth Animations
═══════════════════════════════════════════════════════════ */

/* ─── CSS CUSTOM PROPERTIES ─── */
:root {
  /* Primary Palette */
  --accent-1: #7c3aed;
  --accent-2: #a855f7;
  --accent-3: #c084fc;
  --accent-grad: linear-gradient(135deg, #7c3aed, #a855f7, #ec4899);
  --accent-grad-alt: linear-gradient(135deg, #6366f1, #8b5cf6, #a855f7);

  /* Dark Mode (default) */
  --bg-primary: #0a0a0f;
  --bg-secondary: #111118;
  --bg-card: rgba(255, 255, 255, 0.05);
  --bg-card-hover: rgba(255, 255, 255, 0.08);
  --bg-card-border: rgba(255, 255, 255, 0.1);
  --bg-input: rgba(255, 255, 255, 0.07);
  --bg-input-focus: rgba(255, 255, 255, 0.1);
  --text-primary: #f1f0f5;
  --text-secondary: #a09cb5;
  --text-muted: #6b6785;
  --text-inverse: #0a0a0f;
  --nav-bg: rgba(10, 10, 15, 0.85);
  --shadow-card: 0 8px 32px rgba(0, 0, 0, 0.4);
  --shadow-glow: 0 0 40px rgba(124, 58, 237, 0.3);
  --orb-1: #7c3aed33;
  --orb-2: #ec489933;
  --orb-3: #0ea5e933;
  --orb-4: #a855f722;
  --progress-track: rgba(255,255,255,0.1);
}

[data-theme="light"] {
  --bg-primary: #f5f4ff;
  --bg-secondary: #eceafb;
  --bg-card: rgba(255, 255, 255, 0.75);
  --bg-card-hover: rgba(255, 255, 255, 0.9);
  --bg-card-border: rgba(124, 58, 237, 0.15);
  --bg-input: rgba(124, 58, 237, 0.05);
  --bg-input-focus: rgba(124, 58, 237, 0.08);
  --text-primary: #1a1630;
  --text-secondary: #4a4068;
  --text-muted: #8a7aa8;
  --text-inverse: #f1f0f5;
  --nav-bg: rgba(245, 244, 255, 0.9);
  --shadow-card: 0 4px 24px rgba(124, 58, 237, 0.1);
  --shadow-glow: 0 0 40px rgba(124, 58, 237, 0.15);
  --orb-1: #7c3aed11;
  --orb-2: #ec489911;
  --orb-3: #0ea5e911;
  --orb-4: #a855f711;
  --progress-track: rgba(124, 58, 237, 0.12);
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: 'Inter', sans-serif;
  background-color: var(--bg-primary);
  color: var(--text-primary);
  min-height: 100vh;
  overflow-x: hidden;
  transition: background-color 0.4s ease, color 0.4s ease;
  position: relative;
}

a {
  color: var(--accent-2);
  text-decoration: none;
  transition: opacity 0.2s;
}
a:hover { opacity: 0.8; }

/* ─── ANIMATED BACKGROUND ORBS ─── */
.bg-orbs {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  animation: floatOrb linear infinite;
  will-change: transform;
}

.orb-1 {
  width: 600px; height: 600px;
  top: -150px; left: -150px;
  background: var(--orb-1);
  animation-duration: 18s;
}
.orb-2 {
  width: 500px; height: 500px;
  bottom: -100px; right: -100px;
  background: var(--orb-2);
  animation-duration: 22s;
  animation-delay: -8s;
}
.orb-3 {
  width: 400px; height: 400px;
  top: 50%; left: 60%;
  background: var(--orb-3);
  animation-duration: 26s;
  animation-delay: -14s;
}
.orb-4 {
  width: 300px; height: 300px;
  top: 30%; left: 20%;
  background: var(--orb-4);
  animation-duration: 20s;
  animation-delay: -5s;
}

@keyframes floatOrb {
  0%, 100% { transform: translate(0, 0) scale(1); }
  25% { transform: translate(40px, -30px) scale(1.05); }
  50% { transform: translate(-20px, 50px) scale(0.95); }
  75% { transform: translate(30px, 20px) scale(1.02); }
}

/* ─── GLASS CARD ─── */
.glass-card {
  background: var(--bg-card);
  border: 1px solid var(--bg-card-border);
  border-radius: 20px;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: var(--shadow-card);
  transition: background 0.3s ease, box-shadow 0.3s ease, transform 0.3s ease, border-color 0.3s ease;
}

.glass-card:hover {
  background: var(--bg-card-hover);
  box-shadow: var(--shadow-card), 0 0 0 1px rgba(124,58,237,0.1);
}

/* ─── NAVBAR ─── */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: var(--nav-bg);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--bg-card-border);
  transition: background 0.4s;
}

.nav-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  display: flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  font-size: 1.2rem;
}

.logo-icon {
  font-size: 1.4rem;
  background: var(--accent-grad);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: spinGlow 4s ease-in-out infinite;
}

@keyframes spinGlow {
  0%, 100% { filter: drop-shadow(0 0 4px rgba(124,58,237,0.6)); }
  50% { filter: drop-shadow(0 0 12px rgba(168,85,247,0.8)); }
}

.logo-text {
  color: var(--text-primary);
  letter-spacing: -0.02em;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

/* ─── BUTTONS ─── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  border-radius: 12px;
  font-family: 'Inter', sans-serif;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: all 0.2s ease;
  text-decoration: none;
  position: relative;
  overflow: hidden;
  white-space: nowrap;
}

.btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(255,255,255,0.1);
  opacity: 0;
  transition: opacity 0.2s;
}
.btn:hover::before { opacity: 1; }
.btn:active { transform: scale(0.97); }

.btn-primary {
  background: var(--accent-grad);
  color: #fff;
  box-shadow: 0 4px 20px rgba(124, 58, 237, 0.4);
}
.btn-primary:hover {
  box-shadow: 0 6px 28px rgba(124, 58, 237, 0.6);
  transform: translateY(-1px);
}

.btn-ghost {
  background: var(--bg-card);
  color: var(--text-secondary);
  border: 1px solid var(--bg-card-border);
}
.btn-ghost:hover {
  color: var(--text-primary);
  border-color: rgba(124,58,237,0.4);
  background: var(--bg-card-hover);
}

.btn-social {
  background: var(--bg-card);
  color: var(--text-primary);
  border: 1px solid var(--bg-card-border);
  justify-content: center;
}
.btn-social:hover {
  background: var(--bg-card-hover);
  border-color: rgba(124,58,237,0.3);
}

.btn-danger {
  background: rgba(239, 68, 68, 0.15);
  color: #f87171;
  border: 1px solid rgba(239, 68, 68, 0.2);
}
.btn-danger:hover {
  background: rgba(239, 68, 68, 0.25);
}

.btn-xl {
  padding: 14px 28px;
  font-size: 1rem;
  border-radius: 14px;
}
.btn-sm {
  padding: 6px 14px;
  font-size: 0.8rem;
  border-radius: 8px;
}
.btn-arrow {
  transition: transform 0.2s;
}
.btn-primary:hover .btn-arrow { transform: translateX(4px); }
.w-full { width: 100%; justify-content: center; }

/* Theme Toggle */
.theme-toggle {
  background: var(--bg-card);
  border: 1px solid var(--bg-card-border);
  border-radius: 10px;
  padding: 8px 12px;
  cursor: pointer;
  font-size: 1.1rem;
  transition: all 0.2s;
  line-height: 1;
}
.theme-toggle:hover {
  background: var(--bg-card-hover);
  transform: rotate(20deg);
}

/* ─── GRADIENT TEXT ─── */
.gradient-text {
  background: var(--accent-grad);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ─── LANDING PAGE ─── */
.landing-page {
  position: relative;
  z-index: 1;
}

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

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(124, 58, 237, 0.15);
  border: 1px solid rgba(124, 58, 237, 0.3);
  color: var(--accent-3);
  padding: 6px 16px;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 28px;
  animation: fadeInDown 0.6s ease both;
}

.badge-dot {
  width: 8px;
  height: 8px;
  background: var(--accent-2);
  border-radius: 50%;
  animation: pulse 2s ease-in-out infinite;
}

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

.hero-title {
  font-family: 'Outfit', sans-serif;
  font-size: clamp(2.5rem, 7vw, 5rem);
  font-weight: 900;
  line-height: 1.1;
  letter-spacing: -0.03em;
  margin-bottom: 24px;
  animation: fadeInDown 0.6s ease 0.1s both;
}

.hero-subtitle {
  font-size: clamp(1rem, 2.5vw, 1.2rem);
  color: var(--text-secondary);
  line-height: 1.7;
  max-width: 640px;
  margin: 0 auto 36px;
  animation: fadeInDown 0.6s ease 0.2s both;
}

.hero-cta {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 48px;
  animation: fadeInDown 0.6s ease 0.3s both;
}

.hero-stats {
  display: inline-flex;
  align-items: center;
  gap: 0;
  background: var(--bg-card);
  border: 1px solid var(--bg-card-border);
  border-radius: 16px;
  padding: 16px 32px;
  animation: fadeInDown 0.6s ease 0.4s both;
}

.stat-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0 24px;
}
.stat-number {
  font-family: 'Outfit', sans-serif;
  font-size: 1.4rem;
  font-weight: 800;
  background: var(--accent-grad);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.stat-label {
  font-size: 0.78rem;
  color: var(--text-muted);
  font-weight: 500;
}
.stat-divider {
  width: 1px;
  height: 40px;
  background: var(--bg-card-border);
}

/* DEMO PREVIEW */
.demo-preview {
  max-width: 700px;
  margin: 0 auto 80px;
  padding: 0 24px;
  animation: fadeInUp 0.8s ease 0.5s both;
}

.demo-card {
  padding: 0;
  overflow: hidden;
}

.demo-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 20px;
  border-bottom: 1px solid var(--bg-card-border);
  background: rgba(124, 58, 237, 0.06);
}
.demo-dots {
  display: flex;
  gap: 6px;
}
.demo-dots span {
  width: 10px; height: 10px;
  border-radius: 50%;
  background: var(--bg-card-border);
}
.demo-dots span:nth-child(1) { background: #ef4444; }
.demo-dots span:nth-child(2) { background: #f59e0b; }
.demo-dots span:nth-child(3) { background: #10b981; }
.demo-title-label {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-left: auto;
}

.demo-input-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 16px 20px;
  border-bottom: 1px solid var(--bg-card-border);
}
.demo-input-label {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--accent-3);
  white-space: nowrap;
}
.demo-input-text {
  font-size: 0.9rem;
  color: var(--text-primary);
  font-style: italic;
}
.demo-cursor {
  animation: blink 1s step-end infinite;
  color: var(--accent-2);
  font-weight: 300;
}
@keyframes blink { 0%, 100% { opacity: 1; } 50% { opacity: 0; } }

.demo-roadmap { padding: 16px 20px; display: flex; flex-direction: column; gap: 10px; }
.demo-phase {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 12px;
  background: var(--bg-input);
  border: 1px solid transparent;
  transition: all 0.2s;
}
.active-phase {
  border-color: rgba(124, 58, 237, 0.4);
  background: rgba(124, 58, 237, 0.1);
}
.demo-phase-icon { font-size: 1.2rem; }
.demo-phase-info {
  display: flex;
  flex-direction: column;
  flex: 1;
}
.demo-phase-name { font-size: 0.85rem; font-weight: 600; color: var(--text-primary); }
.demo-phase-tasks { font-size: 0.75rem; color: var(--text-muted); }
.demo-phase-badge {
  font-size: 0.72rem;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 999px;
  background: rgba(124, 58, 237, 0.2);
  color: var(--accent-3);
}
.demo-phase-badge.locked {
  background: var(--bg-input);
  color: var(--text-muted);
}

.demo-progress-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 20px 4px;
  font-size: 0.8rem;
  color: var(--text-secondary);
}
.demo-pct { font-weight: 700; color: var(--accent-3); }
.demo-progress-bar {
  height: 6px;
  background: var(--progress-track);
  border-radius: 999px;
  margin: 0 20px 18px;
  overflow: hidden;
}
.demo-progress-fill {
  height: 100%;
  background: var(--accent-grad);
  border-radius: 999px;
  animation: progressGrow 2s ease 1s both;
}
@keyframes progressGrow { from { width: 0% !important; } }

/* HOW IT WORKS */
.how-it-works {
  max-width: 1100px;
  margin: 0 auto 80px;
  padding: 0 24px;
}
.section-header {
  text-align: center;
  margin-bottom: 48px;
}
.section-badge {
  display: inline-block;
  background: rgba(124, 58, 237, 0.15);
  border: 1px solid rgba(124, 58, 237, 0.25);
  color: var(--accent-3);
  padding: 5px 14px;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 600;
  margin-bottom: 12px;
}
.section-title {
  font-family: 'Outfit', sans-serif;
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 12px;
  line-height: 1.2;
}
.section-subtitle {
  color: var(--text-secondary);
  font-size: 1rem;
  line-height: 1.6;
}

.steps-grid {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: nowrap;
}
.step-card {
  flex: 1;
  padding: 32px 24px;
  text-align: center;
  position: relative;
}
.step-number {
  font-family: 'Outfit', sans-serif;
  font-size: 3rem;
  font-weight: 900;
  background: var(--accent-grad);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  opacity: 0.3;
  position: absolute;
  top: 16px;
  right: 16px;
  line-height: 1;
}
.step-icon {
  font-size: 2.5rem;
  margin-bottom: 16px;
  display: block;
}
.step-card h3 {
  font-family: 'Outfit', sans-serif;
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 10px;
  color: var(--text-primary);
}
.step-card p { color: var(--text-secondary); font-size: 0.9rem; line-height: 1.6; }
.step-connector {
  font-size: 1.5rem;
  color: var(--text-muted);
  flex-shrink: 0;
}

/* FEATURES */
.features-section {
  max-width: 1100px;
  margin: 0 auto 80px;
  padding: 0 24px;
}
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
}
.feature-card {
  padding: 28px;
}
.feature-icon { font-size: 2rem; margin-bottom: 14px; display: block; }
.feature-card h3 {
  font-family: 'Outfit', sans-serif;
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 8px;
  color: var(--text-primary);
}
.feature-card p { color: var(--text-secondary); font-size: 0.88rem; line-height: 1.6; }

/* PRICING */
.pricing-section {
  max-width: 1200px;
  margin: 0 auto 80px;
  padding: 0 24px;
}
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
}
.pricing-card {
  padding: 32px 28px;
  position: relative;
  transition: transform 0.3s ease;
}
.pricing-card:hover { transform: translateY(-4px); }
.featured-plan {
  border-color: rgba(124, 58, 237, 0.5) !important;
  box-shadow: var(--shadow-card), var(--shadow-glow) !important;
}
.plan-badge {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--accent-grad);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 4px 16px;
  border-radius: 999px;
  white-space: nowrap;
}
.plan-name {
  font-family: 'Outfit', sans-serif;
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-secondary);
  margin-bottom: 12px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.plan-price {
  margin-bottom: 24px;
}
.price-amount {
  font-family: 'Outfit', sans-serif;
  font-size: 2.8rem;
  font-weight: 900;
  color: var(--text-primary);
}
.price-period {
  font-size: 0.9rem;
  color: var(--text-muted);
}
.plan-features {
  list-style: none;
  margin-bottom: 24px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.plan-features li {
  font-size: 0.88rem;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 0;
}
.plan-features li:not(:has(✗)) { color: var(--text-primary); }

/* FOOTER */
.footer {
  border-top: 1px solid var(--bg-card-border);
  padding: 40px 24px;
}
.footer-inner {
  max-width: 600px;
  margin: 0 auto;
  text-align: center;
}
.footer-logo {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  font-size: 1.1rem;
  margin-bottom: 8px;
}
.footer-tagline {
  color: var(--text-secondary);
  font-size: 0.88rem;
  margin-bottom: 20px;
}
.footer-links {
  display: flex;
  gap: 20px;
  justify-content: center;
  margin-bottom: 16px;
}
.footer-links a {
  font-size: 0.82rem;
  color: var(--text-muted);
}
.footer-copy {
  font-size: 0.78rem;
  color: var(--text-muted);
}

/* ─── DASHBOARD ─── */
.dashboard-page {
  position: relative;
  z-index: 1;
  padding-top: 64px;
  min-height: 100vh;
}

.dashboard-container {
  display: flex;
  gap: 0;
  min-height: calc(100vh - 64px);
}

/* SIDEBAR */
.sidebar {
  width: 260px;
  flex-shrink: 0;
  border-radius: 0;
  border-right: 1px solid var(--bg-card-border);
  border-top: none;
  border-left: none;
  border-bottom: none;
  display: flex;
  flex-direction: column;
  padding: 24px 16px;
  gap: 4px;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  position: sticky;
  top: 64px;
  height: calc(100vh - 64px);
}

.sidebar-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  margin-bottom: 16px;
  border-radius: 12px;
  background: var(--bg-input);
  transition: background 0.2s ease;
}
.sidebar-header:hover {
  background: rgba(111, 89, 243, 0.1);
}
.user-avatar {
  width: 40px;
  height: 40px;
  background: var(--accent-grad);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1rem;
  color: white;
  flex-shrink: 0;
}
.user-info { display: flex; flex-direction: column; overflow: hidden; }
.user-name {
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.user-plan { font-size: 0.75rem; color: var(--text-muted); }

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

.sidebar-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 14px;
  border-radius: 10px;
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-secondary);
  background: transparent;
  border: none;
  cursor: pointer;
  transition: all 0.2s;
  text-align: left;
  width: 100%;
}
.sidebar-btn:hover {
  background: var(--bg-card);
  color: var(--text-primary);
}
.sidebar-btn.active {
  background: rgba(124, 58, 237, 0.15);
  color: var(--accent-3);
  font-weight: 600;
}
.sidebar-btn.danger-btn:hover {
  background: rgba(239, 68, 68, 0.1);
  color: #f87171;
}
.sidebar-icon { font-size: 1.1rem; }
.sidebar-footer {
  border-top: 1px solid var(--bg-card-border);
  padding-top: 12px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-top: auto;
}

/* DASHBOARD MAIN */
.dashboard-main {
  flex: 1;
  padding: 32px;
  overflow-y: auto;
  max-height: calc(100vh - 64px);
}

.dashboard-tab { display: none; }
.dashboard-tab.active-tab { display: block; }

.tab-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 24px;
}
.tab-header h2 {
  font-family: 'Outfit', sans-serif;
  font-size: 1.6rem;
  font-weight: 800;
  flex: 1;
}
.tab-count {
  background: rgba(124, 58, 237, 0.2);
  color: var(--accent-3);
  padding: 2px 10px;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 700;
}

/* DREAMS LIST */
.dreams-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.dream-item {
  padding: 24px;
  cursor: pointer;
  transition: all 0.3s;
}
.dream-item:hover {
  transform: translateY(-2px);
}
.dream-item-header {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  margin-bottom: 14px;
}
.dream-category-icon {
  font-size: 1.8rem;
  flex-shrink: 0;
}
.dream-item-info { flex: 1; }
.dream-item-title {
  font-family: 'Outfit', sans-serif;
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 4px;
}
.dream-item-desc {
  font-size: 0.83rem;
  color: var(--text-secondary);
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.dream-item-meta {
  display: flex;
  gap: 8px;
  align-items: center;
}
.dream-item-badge {
  background: rgba(124, 58, 237, 0.15);
  color: var(--accent-3);
  font-size: 0.72rem;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 999px;
}
.dream-item-progress-row {
  display: flex;
  align-items: center;
  gap: 12px;
}
.dream-item-bar {
  flex: 1;
  height: 6px;
  background: var(--progress-track);
  border-radius: 999px;
  overflow: hidden;
}
.dream-item-fill {
  height: 100%;
  background: var(--accent-grad);
  border-radius: 999px;
  transition: width 0.6s ease;
}
.dream-item-pct {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--accent-3);
  min-width: 36px;
  text-align: right;
}

/* EMPTY STATE */
.empty-state {
  text-align: center;
  padding: 60px 32px;
}
.empty-icon { font-size: 3rem; margin-bottom: 16px; }
.empty-state h3 {
  font-family: 'Outfit', sans-serif;
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 8px;
}
.empty-state p { color: var(--text-secondary); margin-bottom: 24px; }

/* NEW DREAM FORM */
.new-dream-form { padding: 32px; }
.form-group { margin-bottom: 20px; }
.form-label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.form-input,
.form-select,
.form-textarea {
  width: 100%;
  background: var(--bg-input);
  border: 1px solid var(--bg-card-border);
  border-radius: 12px;
  padding: 12px 16px;
  font-family: 'Inter', sans-serif;
  font-size: 0.9rem;
  color: var(--text-primary);
  transition: all 0.2s;
  outline: none;
  appearance: none;
  -webkit-appearance: none;
}
.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  background: var(--bg-input-focus);
  border-color: rgba(124, 58, 237, 0.5);
  box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.12);
}
.form-input::placeholder,
.form-textarea::placeholder { color: var(--text-muted); }
.form-textarea { resize: vertical; min-height: 120px; }
.form-select {
  cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23a09cb5' stroke-width='2' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
  padding-right: 40px;
}
.form-select option {
  background-color: var(--bg-primary);
  color: var(--text-primary);
}
.form-hint {
  display: block;
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 6px;
  line-height: 1.5;
}

/* SPINNER */
.spinner {
  width: 18px;
  height: 18px;
  border: 2px solid rgba(255,255,255,0.3);
  border-top-color: white;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  display: inline-block;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ROADMAP */
.overall-progress {
  padding: 28px;
  margin-bottom: 24px;
}
.progress-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 16px;
}
.progress-header h3 {
  font-family: 'Outfit', sans-serif;
  font-size: 1.2rem;
  font-weight: 700;
}
.category-badge {
  display: inline-block;
  background: rgba(124, 58, 237, 0.15);
  color: var(--accent-3);
  font-size: 0.75rem;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 999px;
  margin-top: 4px;
}
.progress-pct-big {
  font-family: 'Outfit', sans-serif;
  font-size: 2rem;
  font-weight: 900;
  background: var(--accent-grad);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.big-progress-bar {
  height: 10px;
  background: var(--progress-track);
  border-radius: 999px;
  margin-bottom: 20px;
  overflow: hidden;
}
.big-progress-fill {
  height: 100%;
  background: var(--accent-grad);
  border-radius: 999px;
  transition: width 0.8s ease;
}
.progress-stats-row {
  display: flex;
  gap: 32px;
}
.pstat { display: flex; flex-direction: column; }
.pstat-val {
  font-family: 'Outfit', sans-serif;
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--text-primary);
}
.pstat-lbl { font-size: 0.78rem; color: var(--text-muted); }

/* PHASES */
.phases-container {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.phase-card {
  padding: 0;
  overflow: hidden;
}
.phase-header {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 20px 24px;
  cursor: pointer;
  transition: background 0.2s;
  border-radius: 20px;
}
.phase-header:hover { background: var(--bg-card-hover); }
.phase-icon-wrap {
  width: 44px; height: 44px;
  background: rgba(124, 58, 237, 0.15);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  flex-shrink: 0;
}
.phase-meta { flex: 1; }
.phase-name {
  font-family: 'Outfit', sans-serif;
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 2px;
}
.phase-info-row {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.78rem;
  color: var(--text-muted);
}
.phase-progress-mini {
  display: flex;
  align-items: center;
  gap: 8px;
}
.mini-bar {
  width: 80px;
  height: 4px;
  background: var(--progress-track);
  border-radius: 999px;
  overflow: hidden;
}
.mini-fill {
  height: 100%;
  background: var(--accent-grad);
  border-radius: 999px;
}
.phase-pct-label { font-size: 0.75rem; font-weight: 700; color: var(--accent-3); min-width: 30px; }
.phase-chevron {
  font-size: 0.9rem;
  color: var(--text-muted);
  transition: transform 0.3s;
}
.phase-card.open .phase-chevron { transform: rotate(90deg); }

.tasks-list {
  border-top: 1px solid var(--bg-card-border);
  display: none;
  flex-direction: column;
  gap: 0;
  padding: 8px 16px 16px;
}
.phase-card.open .tasks-list { display: flex; }

.task-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 12px;
  border-radius: 10px;
  transition: background 0.2s;
  cursor: pointer;
}
.task-item:hover { background: var(--bg-input); }
.task-checkbox {
  width: 22px;
  height: 22px;
  border: 2px solid var(--bg-card-border);
  border-radius: 6px;
  flex-shrink: 0;
  margin-top: 1px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  transition: all 0.2s;
  cursor: pointer;
  background: transparent;
}
.task-checkbox.checked {
  background: var(--accent-grad);
  border-color: transparent;
  color: white;
}
.task-info { flex: 1; }
.task-name {
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-primary);
  transition: all 0.2s;
  line-height: 1.4;
  margin-bottom: 3px;
}
.task-item.done .task-name {
  text-decoration: line-through;
  color: var(--text-muted);
}
.task-detail { font-size: 0.85rem; color: var(--text-2); margin-top: 0.25rem; line-height: 1.4; }
.task-time { font-size: 0.8rem; color: var(--accent-1); margin-top: 0.35rem; font-weight: 500; }

/* PHASE SUMMARY CHIPS */
.phase-summary-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 0 24px 16px;
  border-top: 1px solid var(--bg-card-border);
}
.chip {
  background: var(--bg-input);
  border: 1px solid var(--bg-card-border);
  border-radius: 8px;
  padding: 5px 10px;
  font-size: 0.75rem;
  color: var(--text-secondary);
}

/* PROGRESS TAB */
.progress-overview {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}
.progress-card {
  padding: 28px 24px;
  text-align: center;
}
.pcard-icon { font-size: 2rem; margin-bottom: 10px; }
.pcard-value {
  font-family: 'Outfit', sans-serif;
  font-size: 2rem;
  font-weight: 900;
  color: var(--text-primary);
  margin-bottom: 4px;
}
.pcard-label { font-size: 0.82rem; color: var(--text-muted); }

.motivation-card { padding: 28px; }
.motivation-header {
  font-family: 'Outfit', sans-serif;
  font-size: 1rem;
  font-weight: 700;
  color: var(--accent-3);
  margin-bottom: 12px;
}
.motivation-quote {
  font-size: 1rem;
  line-height: 1.7;
  color: var(--text-secondary);
  font-style: italic;
}

/* MARKETPLACE */
.marketplace-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
}
.marketplace-card { padding: 24px; position: relative; }
.market-badge {
  position: absolute;
  top: 16px;
  right: 16px;
  background: rgba(124, 58, 237, 0.15);
  color: var(--accent-3);
  font-size: 0.7rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 999px;
  text-transform: uppercase;
}
.market-icon { font-size: 2.5rem; margin-bottom: 12px; }
.marketplace-card h3 {
  font-family: 'Outfit', sans-serif;
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 6px;
}
.marketplace-card p {
  font-size: 0.83rem;
  color: var(--text-secondary);
  line-height: 1.5;
  margin-bottom: 16px;
}
.market-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.market-price {
  font-family: 'Outfit', sans-serif;
  font-size: 1.2rem;
  font-weight: 800;
  background: var(--accent-grad);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ─── GENERATION OVERLAY ─── */
.gen-overlay {
  position: fixed;
  inset: 0;
  z-index: 500;
  background: var(--bg-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  color: var(--text-primary);
  transition: opacity 0.5s ease;
}
.gen-overlay.hidden { display: none; }
.gen-content { text-align: center; }
.gen-orb {
  width: 80px; height: 80px;
  border-radius: 50%;
  background: radial-gradient(circle at 50% 50%, #d8b8ff 0%, #6f59f3 60%, #3a229c 100%);
  margin: 0 auto 30px;
  animation: pulseGlow 1.5s infinite alternate;
  box-shadow: var(--shadow-glow);
  transition: transform 0.15s ease-out;
}
.gen-content h2 { font-family: 'Outfit', sans-serif; font-size: 2rem; margin-bottom: 10px; }
.gen-content p { color: var(--text-secondary); font-size: 1rem; }

/* ─── AI CHAT WIDGET ─── */
.ai-chat-widget {
  position: fixed;
  bottom: 30px;
  right: 30px;
  z-index: 900;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
}
.ai-chat-toggle {
  width: 65px; height: 65px;
  border-radius: 50%;
  background: var(--accent-grad);
  border: none;
  color: white;
  font-size: 1.5rem;
  cursor: pointer;
  box-shadow: 0 4px 20px rgba(111, 89, 243, 0.4);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  display: flex; align-items: center; justify-content: center;
}
.ai-chat-toggle:hover {
  transform: scale(1.08) translateY(-3px);
  box-shadow: 0 8px 25px rgba(111, 89, 243, 0.6);
}
.ai-chat-window {
  position: absolute;
  bottom: 85px;
  right: 0;
  width: 360px;
  max-height: 550px;
  height: calc(100vh - 150px);
  display: flex;
  flex-direction: column;
  border: 1px solid var(--bg-card-border);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 10px 40px rgba(0,0,0,0.4);
  background: var(--bg-primary);
  transition: opacity 0.3s ease, transform 0.3s ease;
  transform-origin: bottom right;
}
.ai-chat-window.hidden {
  opacity: 0;
  pointer-events: none;
  transform: scale(0.9) translateY(20px);
}
.chat-header {
  padding: 16px;
  background: rgba(255, 255, 255, 0.03);
  border-bottom: 1px solid var(--bg-card-border);
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.chat-header-info { display: flex; align-items: center; gap: 8px; }
.chat-bot-icon { color: var(--accent); font-size: 1.2rem; }
.chat-header h3 { font-size: 1.1rem; margin: 0; font-family: 'Outfit', sans-serif;}
.chat-messages {
  flex: 1;
  padding: 16px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.chat-msg {
  max-width: 85%;
  padding: 12px 16px;
  border-radius: 14px;
  font-size: 0.95rem;
  line-height: 1.4;
  word-wrap: break-word;
}
.chat-msg.bot-msg {
  align-self: flex-start;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--bg-card-border);
  border-bottom-left-radius: 4px;
}
.chat-msg.user-msg {
  align-self: flex-end;
  background: var(--accent-grad);
  color: white;
  border-bottom-right-radius: 4px;
  box-shadow: 0 4px 15px rgba(111, 89, 243, 0.3);
}
.chat-msg p { margin: 0; }
.chat-input-area {
  padding: 16px;
  border-top: 1px solid var(--bg-card-border);
  display: flex;
  gap: 10px;
  background: rgba(0,0,0,0.1);
}
.chat-input-area input {
  flex: 1;
  background: var(--bg-input);
  border: 1px solid var(--bg-card-border);
  border-radius: 24px;
  padding: 10px 16px;
  color: var(--text-primary);
  font-family: inherit;
  font-size: 0.95rem;
  outline: none;
  transition: border-color 0.2s;
}
.chat-input-area input:focus { border-color: var(--accent); }
.chat-input-area button {
  width: 42px; height: 42px;
  border-radius: 50%;
  background: var(--accent);
  color: white;
  border: none;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: transform 0.2s, background 0.2s;
}
.chat-input-area button:hover { transform: scale(1.1); background: var(--accent-2); }

/* ─── MODALS ─── */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.6);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  animation: fadeIn 0.2s ease;
}
.modal-overlay.hidden { display: none; }

.modal-card {
  width: 100%;
  max-width: 440px;
  max-height: 90vh;
  overflow-y: auto;
  padding: 36px 32px;
  border-radius: 24px;
  position: relative;
  animation: scaleIn 0.25s ease;
}

#settingsModal .modal-card {
  max-width: 580px;
  padding: 40px;
}
@keyframes scaleIn {
  from { opacity: 0; transform: scale(0.95) translateY(10px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}

.modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 32px;
  height: 32px;
  background: var(--bg-input);
  border: 1px solid var(--bg-card-border);
  border-radius: 8px;
  cursor: pointer;
  font-size: 0.85rem;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
}
.modal-close:hover { color: var(--text-primary); background: var(--bg-card-hover); }

.modal-logo {
  text-align: center;
  font-size: 2rem;
  margin-bottom: 8px;
  color: var(--accent-2);
}
.modal-title {
  font-family: 'Outfit', sans-serif;
  font-size: 1.5rem;
  font-weight: 800;
  text-align: center;
  margin-bottom: 6px;
}
.modal-subtitle {
  font-size: 0.88rem;
  color: var(--text-secondary);
  text-align: center;
  margin-bottom: 20px;
}
.modal-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--text-muted);
  font-size: 0.8rem;
  margin: 16px 0;
}
.modal-divider::before,
.modal-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--bg-card-border);
}
.modal-switch {
  text-align: center;
  font-size: 0.83rem;
  color: var(--text-secondary);
  margin-top: 14px;
}

.settings-section {
  margin-bottom: 24px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--bg-card-border);
}
.settings-section:last-of-type { border-bottom: none; }
.settings-section-title {
  font-family: 'Outfit', sans-serif;
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--text-secondary);
  margin-bottom: 16px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* ─── TOAST SYSTEM ─── */
.toast-container {
  position: fixed;
  top: 80px;
  right: 20px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 10px;
  pointer-events: none;
}
.toast {
  background: var(--bg-card);
  border: 1px solid var(--bg-card-border);
  backdrop-filter: blur(20px);
  border-radius: 12px;
  padding: 14px 18px;
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.88rem;
  color: var(--text-primary);
  box-shadow: 0 8px 32px rgba(0,0,0,0.3);
  pointer-events: all;
  max-width: 320px;
  animation: toastIn 0.3s ease;
  transition: opacity 0.3s ease, transform 0.3s ease;
}
.toast.removing {
  opacity: 0;
  transform: translateX(20px);
}
.toast-icon { font-size: 1.2rem; }
.toast-msg { flex: 1; line-height: 1.4; }
.toast-success .toast-icon::before { content: '✅'; }
.toast-error .toast-icon::before { content: '❌'; }
.toast-info .toast-icon::before { content: 'ℹ️'; }
@keyframes toastIn {
  from { opacity: 0; transform: translateX(20px); }
  to { opacity: 1; transform: translateX(0); }
}

/* ─── LOADING SKELETON ─── */
.skeleton {
  background: linear-gradient(90deg, var(--bg-input) 25%, var(--bg-card-hover) 50%, var(--bg-input) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  border-radius: 8px;
}
@keyframes shimmer {
  from { background-position: 200% 0; }
  to { background-position: -200% 0; }
}

/* ─── UTILITIES ─── */
.hidden { display: none !important; }

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}
@keyframes fadeInDown {
  from { opacity: 0; transform: translateY(-16px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ─── RESPONSIVE ─── */
@media (max-width: 768px) {
  .nav-actions .btn-ghost:first-of-type { display: none; }
  .steps-grid {
    flex-direction: column;
  }
  .step-connector { transform: rotate(90deg); }
  .dashboard-container { flex-direction: column; }
  .sidebar {
    width: 100%;
    border-right: none;
    border-bottom: 1px solid var(--bg-card-border);
    flex-direction: row;
    height: auto;
    position: sticky;
    top: 64px;
    padding: 8px 16px;
    flex-wrap: nowrap;
    overflow-x: auto;
  }
  .sidebar-header { display: none; }
  .sidebar-nav {
    flex-direction: row;
    flex: 1;
    min-width: 0;
    overflow-x: auto;
  }
  .sidebar-btn { white-space: nowrap; }
  .sidebar-footer {
    border-top: none;
    border-left: 1px solid var(--bg-card-border);
    flex-direction: row;
    padding-top: 0;
    padding-left: 12px;
    margin-top: 0;
    margin-left: 8px;
  }
  .dashboard-main { padding: 20px 16px; }
  .hero { padding: 120px 20px 48px; }
  .hero-stats { flex-direction: column; gap: 16px; }
  .stat-divider { width: 40px; height: 1px; }
  .progress-stats-row { gap: 16px; }
}

@media (max-width: 480px) {
  .modal-card { padding: 24px 20px; }
}

/* ═══════════════════════════════════════════════════
   SIDEBAR UPGRADE BUTTON
   ═══════════════════════════════════════════════════ */
.sidebar-upgrade-nav {
  padding: 0 16px;
  margin-bottom: 16px;
}

.upgrade-nav-btn {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  border: 1px solid rgba(200, 80, 192, 0.4);
  background: linear-gradient(135deg, rgba(111,89,243,0.1) 0%, rgba(200,80,192,0.1) 100%);
  border-radius: 12px;
  cursor: pointer;
  text-align: left;
  transition: all 0.3s ease;
}

.upgrade-nav-btn:hover {
  background: linear-gradient(135deg, rgba(111,89,243,0.2) 0%, rgba(200,80,192,0.2) 100%);
  transform: translateY(-2px);
  box-shadow: 0 8px 16px rgba(0,0,0,0.2), 0 0 15px rgba(200,80,192,0.3);
}

.upgrade-icon {
  font-size: 1.5rem;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: glowPulse 2s infinite ease-in-out;
}

.upgrade-text {
  display: flex;
  flex-direction: column;
}

.upg-title {
  font-family: 'Outfit', sans-serif;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 2px;
}

.upg-sub {
  font-size: 0.75rem;
  color: var(--accent-2);
  font-weight: 600;
}

/* ═══════════════════════════════════════════════════
   PRICING GRID MODAL
   ═══════════════════════════════════════════════════ */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
  margin-bottom: 12px;
}

.pricing-card {
  padding: 32px 24px;
  border-radius: 20px;
  display: flex;
  flex-direction: column;
  position: relative;
  background: var(--bg-input);
  border: 1px solid var(--bg-card-border);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  overflow: hidden;
}

.pricing-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-glow);
}

.popular-tier {
  border: 2px solid var(--accent);
  background: rgba(111, 89, 243, 0.08);
  transform: scale(1.05);
  z-index: 10;
}

.popular-tier:hover {
  transform: scale(1.05) translateY(-5px);
  box-shadow: 0 0 30px rgba(124, 58, 237, 0.3);
}

.popular-badge {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  background: linear-gradient(to right, var(--accent), var(--accent-2));
  color: white;
  padding: 8px 16px;
  text-align: center;
  font-size: 0.75rem;
  font-weight: bold;
  letter-spacing: 2px;
  text-transform: uppercase;
  z-index: 5;
}

.popular-tier .tier-name {
  margin-top: 16px;
}

.tier-name {
  font-family: 'Outfit', sans-serif;
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

.tier-price {
  font-family: 'Outfit', sans-serif;
  font-size: 2.8rem;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 8px;
  display: flex;
  align-items: baseline;
  gap: 4px;
}

.tier-price span {
  font-size: 1.1rem;
  color: var(--text-muted);
  font-weight: 500;
  font-family: 'Inter', sans-serif;
}

.tier-desc {
  font-size: 0.95rem;
  color: var(--text-secondary);
  margin-bottom: 24px;
  line-height: 1.5;
}

.tier-features {
  list-style: none;
  padding: 0;
  margin: 0 0 32px 0;
  flex: 1;
}

.tier-features li {
  margin-bottom: 14px;
  font-size: 0.95rem;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 10px;
}

@media (max-width: 800px) {
  .pricing-grid {
    grid-template-columns: 1fr;
  }
  .popular-tier {
    transform: scale(1);
    order: -1;
  }
  .popular-tier:hover {
    transform: translateY(-5px);
  }
}

/* ═══════════════════════════════════════════════════
   PAYMENT SELECTOR
   ═══════════════════════════════════════════════════ */
.payment-box {
  flex: 1;
  cursor: pointer;
}
.payment-box input {
  display: none;
}
.payment-box-inner {
  border: 2px solid var(--bg-card-border);
  border-radius: 12px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  background: var(--bg-input);
  transition: all 0.2s ease;
  color: var(--text-secondary);
  font-weight: 600;
}
.payment-box input:checked + .payment-box-inner {
  border-color: var(--accent-2);
  background: rgba(200, 80, 192, 0.1);
  color: var(--text-primary);
  box-shadow: 0 0 15px rgba(200, 80, 192, 0.2);
}
.payment-box:hover .payment-box-inner {
  border-color: rgba(200, 80, 192, 0.5);
}

/* ═══════════════════════════════════════════════════
   PREMIUM PLAN TEXT (SIDEBAR)
   ═══════════════════════════════════════════════════ */
.pro-plan-text {
  background: var(--accent-grad);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-weight: 600;
  display: inline-block;
}

/* ═══════════════════════════════════════════════════
   TIER BADGES (SIDEBAR)
   ═══════════════════════════════════════════════════ */
.sidebar-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 0 16px 12px;
}
.tier-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.3px;
}
.priority-badge {
  background: rgba(251, 191, 36, 0.15);
  color: #fbbf24;
  border: 1px solid rgba(251, 191, 36, 0.3);
}
.early-badge {
  background: rgba(59, 130, 246, 0.15);
  color: #60a5fa;
  border: 1px solid rgba(59, 130, 246, 0.3);
}
.theme-badge {
  background: rgba(168, 85, 247, 0.15);
  color: #c084fc;
  border: 1px solid rgba(168, 85, 247, 0.3);
}

/* ═══════════════════════════════════════════════════
   MARKETPLACE V2
   ═══════════════════════════════════════════════════ */
.marketplace-grid-v2 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
@media (max-width: 1000px) {
  .marketplace-grid-v2 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 600px) {
  .marketplace-grid-v2 { grid-template-columns: 1fr; }
}

.mp-card {
  overflow: hidden;
  padding: 0;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
}
.mp-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-card), 0 0 30px rgba(124,58,237,0.15);
}

.mp-card-img {
  position: relative;
  width: 100%;
  height: 180px;
  overflow: hidden;
}
.mp-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}
.mp-card:hover .mp-card-img img {
  transform: scale(1.05);
}

.mp-type-badge {
  position: absolute;
  bottom: 12px;
  left: 12px;
  padding: 4px 12px;
  border-radius: 6px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.3px;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.mp-type-ebook {
  background: rgba(255,255,255,0.12);
  color: #e0e0e0;
  border: 1px solid rgba(255,255,255,0.15);
}
.mp-type-course {
  background: rgba(255,255,255,0.12);
  color: #e0e0e0;
  border: 1px solid rgba(255,255,255,0.15);
}
.mp-type-template {
  background: rgba(255,255,255,0.12);
  color: #e0e0e0;
  border: 1px solid rgba(255,255,255,0.15);
}

.mp-premium-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  padding: 4px 12px;
  border-radius: 6px;
  font-size: 0.72rem;
  font-weight: 700;
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: #fff;
  letter-spacing: 0.3px;
  box-shadow: 0 2px 8px rgba(245, 158, 11, 0.4);
}

.mp-card-body {
  padding: 20px;
  display: flex;
  flex-direction: column;
  flex: 1;
}
.mp-card-body h3 {
  font-family: 'Outfit', sans-serif;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 8px;
}
.mp-card-body p {
  font-size: 0.84rem;
  color: var(--text-secondary);
  line-height: 1.55;
  margin-bottom: 14px;
  flex: 1;
}

.mp-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
  gap: 8px;
}
.mp-rating {
  font-size: 0.82rem;
  font-weight: 600;
  color: #f59e0b;
}
.mp-reviews {
  color: var(--text-muted);
  font-weight: 400;
}
.mp-author {
  font-size: 0.76rem;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.mp-card-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top: 1px solid var(--bg-card-border);
  padding-top: 14px;
}
.mp-price {
  font-family: 'Outfit', sans-serif;
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--text-primary);
}
.mp-price-free {
  font-family: 'Outfit', sans-serif;
  font-size: 0.95rem;
  font-weight: 700;
  color: #22c55e;
  letter-spacing: 0.5px;
}
.mp-price-full.mp-struck {
  text-decoration: line-through;
  opacity: 0.4;
  font-size: 1rem;
}

/* ═══════════════════════════════════════════════════
   CUSTOM THEMES (Lifetime Exclusive)
   ═══════════════════════════════════════════════════ */


/* Theme Picker Grid */
.theme-picker-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}
@media (max-width: 520px) {
  .theme-picker-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.theme-swatch {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 14px 10px;
  border-radius: 16px;
  border: 2px solid var(--bg-card-border);
  background: var(--bg-input);
  cursor: pointer;
  transition: all 0.25s ease;
  position: relative;
}
.theme-swatch:hover {
  border-color: rgba(168, 85, 247, 0.5);
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(0,0,0,0.25);
}
.theme-swatch.active-swatch {
  border-color: var(--accent-2);
  background: rgba(168, 85, 247, 0.1);
  box-shadow: 0 0 20px rgba(168, 85, 247, 0.25);
}
.theme-swatch.active-swatch::after {
  content: '✓';
  position: absolute;
  top: 6px;
  right: 8px;
  font-size: 0.7rem;
  font-weight: 900;
  color: #fff;
  background: var(--accent-grad);
  width: 18px;
  height: 18px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.swatch-preview {
  width: 100%;
  height: 48px;
  border-radius: 10px;
  display: block;
  transition: transform 0.2s ease;
}
.theme-swatch:hover .swatch-preview {
  transform: scale(1.04);
}

.swatch-label {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-primary);
  letter-spacing: 0.02em;
}

/* ─── OCEAN THEME ─── */
[data-custom-theme="ocean"] {
  --accent-1: #0284c7;
  --accent-2: #0ea5e9;
  --accent-3: #38bdf8;
  --accent-grad: linear-gradient(135deg, #0ea5e9, #0284c7, #7c3aed);
  --accent-grad-alt: linear-gradient(135deg, #0369a1, #0ea5e9, #38bdf8);
  --shadow-glow: 0 0 40px rgba(14, 165, 233, 0.3);
}

/* ─── SUNSET THEME ─── */
[data-custom-theme="sunset"] {
  --accent-1: #ef4444;
  --accent-2: #f97316;
  --accent-3: #fb923c;
  --accent-grad: linear-gradient(135deg, #f97316, #ef4444, #ec4899);
  --accent-grad-alt: linear-gradient(135deg, #ea580c, #dc2626, #f43f5e);
  --shadow-glow: 0 0 40px rgba(249, 115, 22, 0.3);
}

/* ─── FOREST THEME ─── */
[data-custom-theme="forest"] {
  --accent-1: #16a34a;
  --accent-2: #22c55e;
  --accent-3: #4ade80;
  --accent-grad: linear-gradient(135deg, #22c55e, #16a34a, #0d9488);
  --accent-grad-alt: linear-gradient(135deg, #15803d, #22c55e, #34d399);
  --shadow-glow: 0 0 40px rgba(34, 197, 94, 0.3);
}

/* ─── ROSE THEME ─── */
[data-custom-theme="rose"] {
  --accent-1: #ec4899;
  --accent-2: #f43f5e;
  --accent-3: #fb7185;
  --accent-grad: linear-gradient(135deg, #f43f5e, #ec4899, #d946ef);
  --accent-grad-alt: linear-gradient(135deg, #e11d48, #db2777, #c026d3);
  --shadow-glow: 0 0 40px rgba(236, 72, 153, 0.3);
}

/* ─── AMBER THEME ─── */
[data-custom-theme="amber"] {
  --accent-1: #d97706;
  --accent-2: #f59e0b;
  --accent-3: #fbbf24;
  --accent-grad: linear-gradient(135deg, #f59e0b, #eab308, #d97706);
  --accent-grad-alt: linear-gradient(135deg, #b45309, #f59e0b, #fcd34d);
  --shadow-glow: 0 0 40px rgba(245, 158, 11, 0.3);
}

/* ─── CYBERPUNK THEME ─── */
[data-custom-theme="cyberpunk"] {
  --accent-1: #8b5cf6;
  --accent-2: #06b6d4;
  --accent-3: #22d3ee;
  --accent-grad: linear-gradient(135deg, #06b6d4, #8b5cf6, #ec4899);
  --accent-grad-alt: linear-gradient(135deg, #0891b2, #7c3aed, #d946ef);
  --shadow-glow: 0 0 40px rgba(6, 182, 212, 0.3);
}

/* ─── MIDNIGHT THEME ─── */
[data-custom-theme="midnight"] {
  --accent-1: #4338ca;
  --accent-2: #6366f1;
  --accent-3: #818cf8;
  --accent-grad: linear-gradient(135deg, #6366f1, #4338ca, #1e1b4b);
  --accent-grad-alt: linear-gradient(135deg, #3730a3, #6366f1, #a5b4fc);
  --shadow-glow: 0 0 40px rgba(99, 102, 241, 0.3);
}

/* ─── LAVENDER THEME ─── */
[data-custom-theme="lavender"] {
  --accent-1: #c084fc;
  --accent-2: #a78bfa;
  --accent-3: #e879f9;
  --accent-grad: linear-gradient(135deg, #a78bfa, #c084fc, #e879f9);
  --accent-grad-alt: linear-gradient(135deg, #8b5cf6, #a78bfa, #f0abfc);
  --shadow-glow: 0 0 40px rgba(167, 139, 250, 0.3);
}

/* ═══════════════════════════════════════════════════
   MY LIBRARY
   ═══════════════════════════════════════════════════ */
.library-sub-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 24px;
}
.library-sub-btn {
  flex: 1;
  padding: 12px 16px;
  border-radius: 12px;
  border: 1px solid var(--bg-card-border);
  background: var(--bg-card);
  color: var(--text-secondary);
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.25s ease;
}
.library-sub-btn:hover {
  background: var(--bg-card-hover);
  color: var(--text-primary);
}
.library-sub-btn.active {
  background: var(--accent-grad);
  color: white;
  border-color: transparent;
  box-shadow: var(--shadow-glow);
}
.library-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 20px;
}
.library-card {
  display: flex;
  flex-direction: column;
  border-radius: 16px;
  overflow: hidden;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.library-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-glow);
}
.library-card-img {
  width: 100%;
  height: 160px;
  overflow: hidden;
}
.library-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.library-card-body {
  padding: 16px;
}
.library-card-body h3 {
  font-size: 1.05rem;
  margin-bottom: 4px;
}

/* ═══════════════════════════════════════════════════
   EBOOK READER
   ═══════════════════════════════════════════════════ */
.reader-layout {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 20px;
  min-height: 70vh;
}
.reader-sidebar {
  padding: 20px;
  border-radius: 16px;
  overflow-y: auto;
  max-height: 75vh;
}
.reader-chapter-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.reader-chapter-btn {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s ease;
  text-align: left;
  width: 100%;
  font-size: 0.88rem;
}
.reader-chapter-btn:hover {
  background: var(--bg-card-hover);
  color: var(--text-primary);
}
.reader-chapter-btn.active {
  background: rgba(111, 89, 243, 0.15);
  border-color: var(--accent);
  color: var(--accent-2);
  font-weight: 600;
}
.ch-num {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--accent-grad);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: bold;
  flex-shrink: 0;
}
.reader-content {
  padding: 32px 40px;
  border-radius: 16px;
  overflow-y: auto;
  max-height: 75vh;
}

/* ═══════════════════════════════════════════════════
   COURSE PLAYER
   ═══════════════════════════════════════════════════ */
.course-layout {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 20px;
}
.video-container {
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
  overflow: hidden;
  border-radius: 16px;
}
.video-container iframe {
  position: absolute;
  top: 0; left: 0;
  width: 100%;
  height: 100%;
  border-radius: 16px;
}
.now-playing {
  padding: 20px;
  border-radius: 16px;
  margin-top: 16px;
}
.now-playing h3 {
  font-size: 1.15rem;
  color: var(--text-primary);
}
.course-sidebar {
  padding: 20px;
  border-radius: 16px;
  overflow-y: auto;
  max-height: 75vh;
}
.course-lesson-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.course-lesson-btn {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px;
  border-radius: 10px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s ease;
  text-align: left;
  width: 100%;
}
.course-lesson-btn:hover {
  background: var(--bg-card-hover);
  color: var(--text-primary);
}
.course-lesson-btn.active {
  background: rgba(111, 89, 243, 0.15);
  border-color: var(--accent);
  color: var(--accent-2);
}
.lesson-num {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--accent-grad);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  font-weight: bold;
  flex-shrink: 0;
}
.lesson-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.lesson-title {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-primary);
}
.lesson-duration {
  font-size: 0.75rem;
  color: var(--text-secondary);
}

/* ═══════════════════════════════════════════════════
   AGENDA PLANNER
   ═══════════════════════════════════════════════════ */
.agenda-date-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 24px;
  border-radius: 16px;
  margin-bottom: 20px;
}
.agenda-sections {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.agenda-section {
  border-radius: 16px;
  padding: 20px 24px;
}
.agenda-section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--bg-card-border);
}
.agenda-section-header h3 {
  font-size: 1.1rem;
  margin: 0;
}
.agenda-time-slot {
  font-size: 0.8rem;
  color: var(--accent-2);
  font-weight: 600;
  padding: 4px 10px;
  background: rgba(111, 89, 243, 0.1);
  border-radius: 8px;
}
.agenda-tasks {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.agenda-task {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.2s ease;
  background: rgba(255, 255, 255, 0.02);
}
.agenda-task:hover {
  background: var(--bg-card-hover);
}
.agenda-task.done {
  opacity: 0.55;
}
.agenda-task.done .agenda-task-name {
  text-decoration: line-through;
}
.agenda-checkbox {
  width: 24px;
  height: 24px;
  border-radius: 6px;
  border: 2px solid var(--bg-card-border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: bold;
  color: white;
  flex-shrink: 0;
  transition: all 0.2s ease;
}
.agenda-checkbox.checked {
  background: var(--accent-grad);
  border-color: transparent;
}
.agenda-task-name {
  font-size: 0.95rem;
  color: var(--text-primary);
}

/* ═══════ RESPONSIVE: CONTENT VIEWERS ═══════ */
@media (max-width: 768px) {
  .reader-layout { grid-template-columns: 1fr; }
  .reader-sidebar { max-height: 40vh; }
  .course-layout { grid-template-columns: 1fr; }
  .course-sidebar { order: -1; max-height: 30vh; }
  .library-sub-tabs { flex-wrap: wrap; }
}
