/* === AINavigatorLab® Learning App Styles === */

/* ----- CSS Variables ----- */
:root {
  --bg-primary: #0f172a;
  --bg-secondary: #1e293b;
  --bg-card: #1e293b;
  --bg-overlay: rgba(15, 23, 42, 0.95);
  --text-primary: #f1f5f9;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  --accent-primary: #38bdf8;
  --accent-secondary: #22d3ee;
  --accent-gradient: linear-gradient(135deg, #38bdf8, #22d3ee);
  --pro-gradient: linear-gradient(135deg, #f59e0b, #f97316);
  --success: #22c55e;
  --warning: #f59e0b;
  --error: #ef4444;
  --border: #334155;
  --border-light: #475569;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 20px;
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.2);
  --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.3);
  --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.4);
  --transition: all 0.3s ease;
}

/* ----- Reset & Base Styles ----- */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  padding-bottom: 80px;
}

/* ----- Typography ----- */
h1, h2, h3, h4, h5, h6 {
  font-weight: 600;
  line-height: 1.3;
  margin-bottom: 0.5rem;
}

h1 {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
}

h2 {
  font-size: clamp(1.5rem, 3vw, 2rem);
}

p {
  margin-bottom: 1rem;
}

/* ----- Layout Components ----- */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
}

.app-header {
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(10px);
}

.nav-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 0;
}




/* === Brand Logo (Dynamic Gradient + Cross-Device Safe) === */
.brand-logo {
  font-size: 2.6rem;
  font-weight: 800;
  letter-spacing: 0.5px;
  display: inline-block;
  margin-bottom: 0.4rem;
  user-select: none;
}

/* --- Animated “AI” highlight --- */
.brand-ai {
  font-weight: 900;
  letter-spacing: 1px;
  background: linear-gradient(
    90deg,
    #60a5fa,
    #93c5fd,
    #e0f2fe,
    #60a5fa
  );
  background-size: 300% 300%;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  color: transparent;
  text-shadow: 0 0 10px rgba(147, 197, 253, 0.5);
  animation: shiftGradient 6s ease-in-out infinite;
}

/* --- Rest of the name --- */
.brand-text {
  color: #f9fafb;
  font-weight: 700;
  margin-left: 6px;
}


/* ===== Entrance Animation ===== */
@keyframes logoReveal {
  0% {
    opacity: 0;
    transform: translateY(-10px) scale(0.95);
    filter: blur(3px);
  }
  60% {
    opacity: 1;
    transform: translateY(0) scale(1.02);
    filter: blur(0);
  }
  100% {
    transform: scale(1);
  }
}

/* Apply animation on load */
.animated-logo {
  animation: logoReveal 1s ease-out 0.2s both;
}




/* ----- Header Actions ----- */
.header-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.user-progress {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.progress-bar {
  width: 100px;
  height: 6px;
  background: var(--border);
  border-radius: 3px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: var(--accent-gradient);
  border-radius: 3px;
  transition: width 0.3s ease;
  width: 0%;
}

.progress-text {
  font-size: 0.875rem;
  color: var(--text-secondary);
  min-width: 40px;
}

/* ----- Learning Path Guide ----- */
.learning-path {
  background: var(--bg-card);
  border-bottom: 1px solid var(--border);
  padding: 1rem 0;
}

.path-guide {
  display: flex;
  justify-content: center;
  gap: 2rem;
}

.path-step {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--text-muted);
  transition: var(--transition);
}

.path-step.active {
  color: var(--accent-primary);
  font-weight: 600;
}

.step-icon {
  font-size: 1.25rem;
}

/* ----- Learning Guidance ----- */
.learning-guidance {
  margin: 1.5rem 0;
}

.guidance-card {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1.5rem;
  background: linear-gradient(135deg, rgba(56, 189, 248, 0.1), rgba(34, 211, 238, 0.05));
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  border-left: 4px solid var(--accent-primary);
}

.guidance-card i {
  color: var(--accent-primary);
  font-size: 1.5rem;
  margin-top: 0.25rem;
}

.guidance-content h3 {
  margin-bottom: 0.5rem;
  color: var(--text-primary);
}

.guidance-content p {
  color: var(--text-secondary);
  margin-bottom: 0;
  line-height: 1.6;
}

.module-tag {
  padding: 0.25rem 0.5rem;
  border-radius: 6px;
  font-weight: 600;
  font-size: 0.875rem;
}

.module-tag.life { background: rgba(147, 197, 253, 0.2); color: #93c5fd; }
.module-tag.work { background: rgba(134, 239, 172, 0.2); color: #86efac; }
.module-tag.career { background: rgba(253, 230, 138, 0.2); color: #fde68a; }
.module-tag.business { background: rgba(252, 165, 165, 0.2); color: #fca5a5; }
.module-tag.domain { background: rgba(192, 132, 252, 0.2); color: #c084fc; }

/* ----- Module Tabs ----- */
.module-tabs {
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 80px;
  z-index: 90;
}

.tab-scroll-container {
  display: flex;
  gap: 0.5rem;
  padding: 1rem 0;
  overflow-x: auto;
  scrollbar-width: none;
}

.tab-scroll-container::-webkit-scrollbar {
  display: none;
}

.module-tab {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.25rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  color: var(--text-secondary);
  text-decoration: none;
  white-space: nowrap;
  transition: var(--transition);
  cursor: pointer;
  border: none;
  font-family: inherit;
}

.module-tab:hover {
  border-color: var(--accent-primary);
  color: var(--text-primary);
}

.module-tab.active {
  background: var(--accent-gradient);
  border-color: transparent;
  color: white;
  font-weight: 600;
}

.module-tab.locked {
  opacity: 0.6;
  position: relative;
}

.module-tab.locked::after {
  content: '🔒';
  margin-left: 0.25rem;
  font-size: 0.75rem;
}

/* ----- Current Module ----- */
.current-module {
  padding: 2rem 0;
}

.module-header {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 1.5rem;
  align-items: start;
  margin-bottom: 2rem;
  padding: 2rem;
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  border: 1px solid var(--border);
}

.module-icon {
  font-size: 3rem;
  width: 80px;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-primary);
  border-radius: var(--radius-lg);
  border: 2px solid var(--border-light);
}

.module-info h1 {
  margin-bottom: 0.5rem;
  background: var(--accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.module-info p {
  color: var(--text-secondary);
  font-size: 1.1rem;
  margin-bottom: 0;
}

.module-stats {
  display: flex;
  gap: 1.5rem;
}

.stat {
  text-align: center;
}

.stat-number {
  display: block;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--accent-primary);
}

.stat-label {
  font-size: 0.875rem;
  color: var(--text-secondary);
}

/* ----- Content Sections ----- */
.module-content {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.content-section {
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  border: 1px solid var(--border);
  overflow: hidden;
}

.section-title {
  padding: 1.5rem 2rem;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 1.25rem;
}

.section-title i {
  color: var(--accent-primary);
}

/* ----- Prompts Grid ----- */
.prompts-grid {
  display: grid;
  gap: 1.5rem;
  padding: 2rem;
}

.prompt-card {
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  transition: var(--transition);
  position: relative;
}

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

.prompt-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 1rem;
}

.prompt-title {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-primary);
  flex: 1;
}

.prompt-actions {
  display: flex;
  gap: 0.5rem;
}

.prompt-content {
  background: rgba(0, 0, 0, 0.3);
  border-radius: var(--radius-md);
  padding: 1rem;
  margin-bottom: 1rem;
  border-left: 4px solid var(--accent-primary);
}

.prompt-content pre {
  white-space: pre-wrap;
  font-family: 'Courier New', monospace;
  font-size: 0.9rem;
  line-height: 1.5;
  color: var(--text-primary);
  margin: 0;
}

.prompt-note {
  background: rgba(245, 158, 11, 0.1);
  border: 1px solid rgba(245, 158, 11, 0.3);
  border-radius: var(--radius-md);
  padding: 1rem;
  font-size: 0.9rem;
  color: var(--warning);
}

/* ----- Videos Grid ----- */
.videos-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
  padding: 2rem;
}

.video-card {
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: var(--transition);
}

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

.video-thumbnail {
  position: relative;
  aspect-ratio: 16/9;
  background: var(--bg-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  font-size: 3rem;
}

.video-thumbnail::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(56, 189, 248, 0.1), transparent);
}

.video-info {
  padding: 1.5rem;
}

.video-title {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: var(--text-primary);
}

.video-description {
  color: var(--text-secondary);
  font-size: 0.9rem;
  margin-bottom: 1rem;
}

/* ----- Core Concepts Accordion ----- */
.concepts-accordion {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.accordion-header {
  padding: 1.5rem 2rem;
  background: var(--bg-secondary);
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 1.1rem;
  font-weight: 600;
  list-style: none;
  transition: var(--transition);
}

.accordion-header:hover {
  background: var(--bg-card);
}

.accordion-header::-webkit-details-marker {
  display: none;
}

.accordion-arrow {
  margin-left: auto;
  transition: transform 0.3s ease;
}

.concepts-accordion[open] .accordion-arrow {
  transform: rotate(180deg);
}

.accordion-content {
  padding: 2rem;
  background: var(--bg-card);
}

/* ----- Buttons ----- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  border: none;
  border-radius: var(--radius-md);
  font-weight: 600;
  font-size: 0.9rem;
  text-decoration: none;
  cursor: pointer;
  transition: var(--transition);
  background: var(--bg-primary);
  color: var(--text-primary);
  border: 1px solid var(--border);
}

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

.btn-primary {
  background: var(--accent-gradient);
  color: white;
  border: none;
}

.btn-pro {
  background: var(--pro-gradient);
  color: white;
  border: none;
}

.btn-compact {
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
}

.btn-action {
  padding: 0.5rem;
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-secondary);
}

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

.btn-action.copied {
  background: var(--success);
  border-color: var(--success);
  color: white;
}


/* === Bottom Navigation === */
.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(15, 23, 42, 0.95);
  backdrop-filter: blur(20px);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  z-index: 100;
  padding: 0.75rem 0;
}

.bottom-nav .nav-container {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.5rem;
  max-width: 500px;
  margin: 0 auto;
}

.nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
  padding: 0.5rem;
  background: none;
  border: none;
  color: var(--text-secondary);
  cursor: pointer;
  transition: var(--transition);
  border-radius: var(--radius-md);
  text-decoration: none;
  font-family: inherit;
}

.nav-item:hover,
.nav-item:focus {
  color: var(--accent-primary);
  background: rgba(56, 189, 248, 0.1);
}

.nav-item.active {
  color: var(--accent-primary);
  background: rgba(56, 189, 248, 0.1);
}

.nav-item i {
  font-size: 1.25rem;
}

.nav-item span {
  font-size: 0.75rem;
  font-weight: 500;
}

/* Remove active state styling since we're using links */
.nav-item.active {
  background: transparent;
  color: var(--text-secondary);
}

.nav-item:focus {
  outline: 2px solid var(--accent-primary);
  outline-offset: 2px;
}







/* ----- FAB Container ----- */
.fab-container {
  position: fixed;
  bottom: 80px;
  right: 1rem;
  z-index: 99;
}

.fab {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--accent-gradient);
  border: none;
  color: white;
  font-size: 1.25rem;
  cursor: pointer;
  box-shadow: var(--shadow-lg);
  transition: var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
}

.fab:hover {
  transform: scale(1.1);
}

.fab-actions {
  position: absolute;
  bottom: 60px;
  right: 0;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  opacity: 0;
  transform: translateY(10px);
  pointer-events: none;
  transition: var(--transition);
}

.fab-container:hover .fab-actions {
  opacity: 1;
  transform: translateY(0);
  pointer-events: all;
}

.fab-action {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--text-primary);
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
}

.fab-action:hover {
  background: var(--accent-primary);
  color: white;
}

/* ----- Modals ----- */
.modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(5px);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 1rem;
}

.modal.active {
  display: flex;
}

.modal-content {
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  border: 1px solid var(--border);
  max-width: 500px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  animation: modalSlideIn 0.3s ease;
}

@keyframes modalSlideIn {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.5rem 2rem;
  border-bottom: 1px solid var(--border);
}

.modal-header h3 {
  margin: 0;
  flex: 1;
}

.close-modal {
  background: none;
  border: none;
  color: var(--text-secondary);
  font-size: 1.5rem;
  cursor: pointer;
  padding: 0.25rem;
}

.close-modal:hover {
  color: var(--text-primary);
}

/* Pro Features List */
.pro-features {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin: 1.5rem 0;
}

.pro-feature {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem;
  background: rgba(245, 158, 11, 0.1);
  border-radius: var(--radius-md);
  border: 1px solid rgba(245, 158, 11, 0.2);
}

.pro-feature i {
  color: var(--warning);
}

.license-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.license-form input {
  padding: 0.75rem 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--bg-primary);
  color: var(--text-primary);
  font-size: 1rem;
}

.license-form input:focus {
  outline: 2px solid var(--accent-primary);
  outline-offset: 2px;
}

.license-footer {
  text-align: center;
  margin-top: 1.5rem;
  color: var(--text-secondary);
}

.license-footer a {
  color: var(--accent-primary);
  text-decoration: none;
}

.license-footer a:hover {
  color: var(--accent-secondary);
}

/* ----- Toast Notifications ----- */
.toast-container {
  position: fixed;
  top: 1rem;
  right: 1rem;
  z-index: 1001;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.toast {
  padding: 1rem 1.5rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  display: flex;
  align-items: center;
  gap: 0.75rem;
  animation: toastSlideIn 0.3s ease;
  max-width: 350px;
}

.toast.success {
  border-left: 4px solid var(--success);
}

.toast.error {
  border-left: 4px solid var(--error);
}

.toast.warning {
  border-left: 4px solid var(--warning);
}

@keyframes toastSlideIn {
  from {
    opacity: 0;
    transform: translateX(100%);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* ----- Locked State ----- */
.locked-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(5px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-lg);
  z-index: 10;
}

.lock-icon {
  font-size: 3rem;
  color: var(--text-secondary);
  margin-bottom: 1rem;
}

/* ----- Responsive Design ----- */
@media (max-width: 768px) {
  .module-header {
    grid-template-columns: 1fr;
    gap: 1rem;
    text-align: center;
  }
  
  .module-stats {
    justify-content: center;
  }
  
  .header-actions {
    flex-direction: column;
    gap: 0.5rem;
  }
  
  .user-progress {
    order: -1;
    width: 100%;
    justify-content: center;
  }
  
  .path-guide {
    flex-direction: column;
    gap: 1rem;
    align-items: center;
  }
  
  .videos-grid {
    grid-template-columns: 1fr;
  }
  
  .prompts-grid {
    padding: 1rem;
  }
  
  .guidance-card {
    flex-direction: column;
    text-align: center;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 0.5rem;
  }
  
  .module-header {
    padding: 1.5rem;
  }
  
  .section-title {
    padding: 1rem 1.5rem;
  }
  
  .prompts-grid,
  .videos-grid {
    padding: 1rem;
  }
}

/* ----- Utility Classes ----- */
.text-center { text-align: center; }
.text-muted { color: var(--text-muted); }
.mb-0 { margin-bottom: 0; }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }

/* ----- Loading States ----- */
.loading {
  opacity: 0.6;
  pointer-events: none;
}

.skeleton {
  background: linear-gradient(90deg, var(--border) 25%, var(--border-light) 50%, var(--border) 75%);
  background-size: 200% 100%;
  animation: loading 1.5s infinite;
  border-radius: var(--radius-md);
}

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

