:root {
  --bg-primary: #070a11;
  --bg-secondary: #0f1523;
  --bg-card: rgba(18, 25, 41, 0.75);
  --bg-card-hover: rgba(28, 38, 62, 0.85);
  --border-color: rgba(255, 255, 255, 0.08);
  --border-active: rgba(246, 211, 101, 0.35);
  
  --gold-primary: #F6D365;
  --gold-secondary: #FDA085;
  --gold-gradient: linear-gradient(135deg, #F6D365 0%, #FDA085 100%);
  --cyan-primary: #00F2FE;
  --cyan-secondary: #4FACFE;
  --cyan-gradient: linear-gradient(135deg, #00F2FE 0%, #4FACFE 100%);
  --purple-gradient: linear-gradient(135deg, #A18CD1 0%, #FBC2EB 100%);
  --emerald-gradient: linear-gradient(135deg, #11998e 0%, #38ef7d 100%);

  --text-primary: #FFFFFF;
  --text-secondary: #94A3B8;
  --text-muted: #64748B;
  
  --font-heading: 'Outfit', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-full: 9999px;
  
  --shadow-glow: 0 0 25px rgba(246, 211, 101, 0.18);
  --shadow-card: 0 10px 30px -10px rgba(0, 0, 0, 0.5);
  --bottom-nav-height: 72px;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

body {
  font-family: var(--font-body);
  background-color: var(--bg-primary);
  color: var(--text-primary);
  min-height: 100vh;
  display: flex;
  justify-content: center;
  overflow-x: hidden;
  background-image: 
    radial-gradient(circle at 15% 10%, rgba(246, 211, 101, 0.05) 0%, transparent 40%),
    radial-gradient(circle at 85% 80%, rgba(0, 242, 254, 0.04) 0%, transparent 40%);
  background-attachment: fixed;
}

/* Mobile App Wrapper */
.app-container {
  width: 100%;
  max-width: 480px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  position: relative;
  background: var(--bg-primary);
  border-left: 1px solid rgba(255, 255, 255, 0.03);
  border-right: 1px solid rgba(255, 255, 255, 0.03);
  padding-bottom: calc(var(--bottom-nav-height) + 25px);
}

/* Header */
.app-header {
  position: sticky;
  top: 0;
  z-index: 50;
  padding: 14px 18px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: rgba(7, 10, 17, 0.88);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-color);
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
}

.brand-icon {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-md);
  box-shadow: 0 4px 12px rgba(246, 211, 101, 0.2);
}

.brand-info h1 {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  background: var(--gold-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.brand-info p {
  font-size: 0.68rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 600;
}

.streak-badge {
  display: flex;
  align-items: center;
  gap: 6px;
  background: rgba(246, 211, 101, 0.12);
  border: 1px solid rgba(246, 211, 101, 0.3);
  padding: 5px 10px;
  border-radius: var(--radius-full);
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.82rem;
  color: var(--gold-primary);
  box-shadow: 0 2px 10px rgba(246, 211, 101, 0.15);
}

.streak-flame {
  animation: pulseFlame 1.8s infinite ease-in-out;
}

@keyframes pulseFlame {
  0%, 100% { transform: scale(1); filter: drop-shadow(0 0 4px #FDA085); }
  50% { transform: scale(1.18); filter: drop-shadow(0 0 10px #F6D365); }
}

/* Views & Screens */
.screen-view {
  display: none;
  padding: 18px;
  animation: fadeIn 0.25s ease-out forwards;
}

.screen-view.active {
  display: block;
}

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

/* Section Common Titles */
.section-header {
  margin-bottom: 18px;
}

.section-tag {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--cyan-primary);
  margin-bottom: 4px;
}

.section-title {
  font-family: var(--font-heading);
  font-size: 1.45rem;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -0.02em;
}

.section-desc {
  font-size: 0.84rem;
  color: var(--text-secondary);
  margin-top: 4px;
  line-height: 1.45;
}

/* Cards & Containers */
.glass-card {
  background: var(--bg-card);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 18px;
  box-shadow: var(--shadow-card);
  margin-bottom: 16px;
  transition: border-color 0.2s ease, transform 0.2s ease;
}

.glass-card:hover {
  border-color: var(--border-active);
}

.glass-card.highlight {
  border: 1px solid rgba(246, 211, 101, 0.4);
  background: linear-gradient(180deg, rgba(246, 211, 101, 0.08) 0%, rgba(18, 25, 41, 0.85) 100%);
}

/* Phase & Progress Indicator */
.phase-banner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border-color);
}

.phase-pill {
  font-size: 0.72rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: var(--radius-full);
  background: var(--cyan-gradient);
  color: #050b14;
}

.week-indicator {
  font-size: 0.8rem;
  color: var(--gold-primary);
  font-weight: 600;
}

/* Mission Box */
.mission-card {
  position: relative;
  overflow: hidden;
}

.mission-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
  background: var(--gold-gradient);
}

.mission-title {
  font-family: var(--font-heading);
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 8px;
  color: #FFFFFF;
}

.mission-text {
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.5;
  margin-bottom: 16px;
}

.mission-steps {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 16px;
}

.step-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 0.84rem;
  color: #CBD5E1;
  line-height: 1.4;
}

.step-num {
  background: rgba(255, 255, 255, 0.08);
  color: var(--gold-primary);
  font-weight: 700;
  min-width: 22px;
  height: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  font-size: 0.75rem;
}

.action-btn {
  width: 100%;
  padding: 13px;
  border-radius: var(--radius-md);
  border: none;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.92rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: all 0.2s ease;
}

.action-btn.primary {
  background: var(--gold-gradient);
  color: #090e17;
  box-shadow: 0 4px 18px rgba(246, 211, 101, 0.3);
}

.action-btn.primary:active {
  transform: scale(0.98);
}

.action-btn.completed {
  background: var(--emerald-gradient);
  color: #FFFFFF;
}

.action-btn.secondary {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-primary);
  border: 1px solid var(--border-color);
}

.action-btn.secondary:hover {
  background: rgba(255, 255, 255, 0.1);
}

/* Quick Tools Grid */
.tools-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin-top: 12px;
}

.tool-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 14px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  cursor: pointer;
  transition: all 0.2s ease;
}

.tool-card:active {
  transform: scale(0.97);
}

.tool-icon {
  width: 34px;
  height: 34px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
  margin-bottom: 8px;
}

.tool-icon.gold { background: rgba(246, 211, 101, 0.15); color: var(--gold-primary); }
.tool-icon.cyan { background: rgba(0, 242, 254, 0.15); color: var(--cyan-primary); }
.tool-icon.purple { background: rgba(161, 140, 209, 0.15); color: #FBC2EB; }
.tool-icon.green { background: rgba(56, 239, 125, 0.15); color: #38ef7d; }

.tool-title {
  font-family: var(--font-heading);
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 2px;
}

.tool-desc {
  font-size: 0.72rem;
  color: var(--text-muted);
  line-height: 1.3;
}

/* ACADEMY / LESSONS SYSTEM */
.academy-progress-bar {
  width: 100%;
  height: 8px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-full);
  margin-top: 10px;
  overflow: hidden;
  position: relative;
}

.academy-progress-fill {
  height: 100%;
  background: var(--gold-gradient);
  border-radius: var(--radius-full);
  transition: width 0.4s ease;
}

.lesson-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  margin-bottom: 10px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.lesson-card:hover {
  border-color: var(--border-active);
  background: var(--bg-card-hover);
}

.lesson-card.completed {
  border-color: rgba(56, 239, 125, 0.35);
  background: linear-gradient(90deg, rgba(56, 239, 125, 0.06) 0%, rgba(18, 25, 41, 0.75) 100%);
}

.lesson-info {
  display: flex;
  align-items: center;
  gap: 12px;
}

.lesson-number {
  min-width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.06);
  color: var(--gold-primary);
  font-family: var(--font-heading);
  font-size: 0.8rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

.lesson-card.completed .lesson-number {
  background: rgba(56, 239, 125, 0.2);
  color: #38ef7d;
}

.lesson-title-text {
  font-family: var(--font-heading);
  font-size: 0.92rem;
  font-weight: 600;
  color: #FFFFFF;
}

.lesson-subtitle {
  font-size: 0.72rem;
  color: var(--text-muted);
}

.lesson-status-icon {
  font-size: 1rem;
  color: var(--text-muted);
}

.lesson-card.completed .lesson-status-icon {
  color: #38ef7d;
}

/* Modal / Lesson Reader */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  z-index: 300;
  display: none;
  justify-content: center;
  align-items: flex-end;
  animation: fadeIn 0.2s ease-out;
}

.modal-overlay.open {
  display: flex;
}

.lesson-modal {
  width: 100%;
  max-width: 480px;
  height: 88vh;
  background: var(--bg-secondary);
  border-top-left-radius: var(--radius-lg);
  border-top-right-radius: var(--radius-lg);
  border: 1px solid var(--border-color);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.8);
}

.lesson-modal-header {
  padding: 16px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--border-color);
  background: rgba(7, 10, 17, 0.9);
}

.lesson-modal-content {
  padding: 20px;
  overflow-y: auto;
  flex: 1;
}

.lesson-modal-footer {
  padding: 14px 20px;
  border-top: 1px solid var(--border-color);
  background: rgba(7, 10, 17, 0.9);
  display: flex;
  gap: 10px;
}

.example-box {
  background: rgba(0, 242, 254, 0.05);
  border-left: 3px solid var(--cyan-primary);
  border-radius: var(--radius-sm);
  padding: 12px;
  margin: 12px 0;
  font-size: 0.85rem;
  color: #E2E8F0;
  line-height: 1.45;
}

.example-label {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--cyan-primary);
  text-transform: uppercase;
  margin-bottom: 4px;
}

.drill-selector {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 8px;
  margin-bottom: 16px;
  scrollbar-width: none;
}

.drill-selector::-webkit-scrollbar {
  display: none;
}

.pill-btn {
  padding: 7px 14px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-full);
  color: var(--text-secondary);
  font-size: 0.78rem;
  font-weight: 600;
  white-space: nowrap;
  cursor: pointer;
  transition: all 0.2s ease;
}

.pill-btn.active {
  background: var(--gold-gradient);
  color: #0A0E17;
  border-color: transparent;
  font-weight: 700;
  box-shadow: 0 2px 10px rgba(246, 211, 101, 0.2);
}

/* Sleight of Mouth Simulator */
.som-card {
  background: rgba(255, 255, 255, 0.03);
  border-radius: var(--radius-md);
  padding: 16px;
  border: 1px dashed rgba(255, 255, 255, 0.15);
  margin-bottom: 14px;
}

.som-objection-label {
  font-size: 0.72rem;
  text-transform: uppercase;
  color: #FDA085;
  font-weight: 700;
  letter-spacing: 0.06em;
  margin-bottom: 4px;
}

.som-objection-text {
  font-family: var(--font-heading);
  font-size: 1.12rem;
  font-weight: 600;
  color: #FFFFFF;
}

.pattern-answer-box {
  background: rgba(0, 242, 254, 0.04);
  border: 1px solid rgba(0, 242, 254, 0.2);
  border-radius: var(--radius-md);
  padding: 14px;
  margin-top: 12px;
}

.pattern-name {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--cyan-primary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 4px;
}

.pattern-response {
  font-size: 0.88rem;
  color: #E2E8F0;
  line-height: 1.45;
}

/* Breathing & State Control Trainer */
.breath-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 26px 10px;
}

.breath-circle {
  width: 160px;
  height: 160px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(246, 211, 101, 0.3) 0%, rgba(0, 242, 254, 0.05) 70%);
  border: 2px solid var(--gold-primary);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 35px rgba(246, 211, 101, 0.25);
  transition: transform 4s cubic-bezier(0.4, 0, 0.2, 1), border-color 0.5s ease;
}

.breath-circle.inhale {
  transform: scale(1.35);
  border-color: var(--cyan-primary);
  box-shadow: 0 0 45px rgba(0, 242, 254, 0.4);
}

.breath-circle.hold {
  transform: scale(1.35);
  border-color: var(--gold-primary);
  box-shadow: 0 0 50px rgba(246, 211, 101, 0.5);
}

.breath-circle.exhale {
  transform: scale(0.9);
  border-color: rgba(255, 255, 255, 0.2);
  box-shadow: 0 0 15px rgba(0, 0, 0, 0.5);
}

.breath-instruction {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 700;
  color: #FFFFFF;
}

.breath-timer {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--gold-primary);
  margin-top: 4px;
}

/* Cheat Sheet Accordions */
.accordion-item {
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  margin-bottom: 10px;
  overflow: hidden;
  background: var(--bg-card);
}

.accordion-header {
  padding: 14px 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
  font-family: var(--font-heading);
  font-size: 0.92rem;
  font-weight: 600;
  color: #FFFFFF;
}

.accordion-icon {
  font-size: 0.8rem;
  transition: transform 0.2s ease;
  color: var(--text-muted);
}

.accordion-item.open .accordion-icon {
  transform: rotate(180deg);
  color: var(--gold-primary);
}

.accordion-content {
  display: none;
  padding: 14px 16px;
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.5;
  border-top: 1px solid var(--border-color);
  background: rgba(7, 10, 17, 0.5);
}

.accordion-item.open .accordion-content {
  display: block;
}

.field-badge {
  display: inline-block;
  font-size: 0.68rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: var(--radius-full);
  background: rgba(246, 211, 101, 0.15);
  color: var(--gold-primary);
  margin-bottom: 4px;
}

/* Bottom Navigation Bar (5 Items) */
.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: 480px;
  height: var(--bottom-nav-height);
  background: rgba(10, 14, 23, 0.94);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-top: 1px solid var(--border-color);
  display: flex;
  justify-content: space-around;
  align-items: center;
  z-index: 100;
  padding: 0 4px;
}

.nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 0.68rem;
  font-weight: 600;
  gap: 3px;
  cursor: pointer;
  padding: 6px 8px;
  border-radius: var(--radius-md);
  transition: all 0.2s ease;
  flex: 1;
}

.nav-item svg {
  width: 20px;
  height: 20px;
  stroke: var(--text-muted);
  transition: all 0.2s ease;
}

.nav-item.active {
  color: var(--gold-primary);
}

.nav-item.active svg {
  stroke: var(--gold-primary);
  filter: drop-shadow(0 0 6px rgba(246, 211, 101, 0.4));
}

/* Toast Notifications */
.toast {
  position: fixed;
  top: 75px;
  left: 50%;
  transform: translateX(-50%) translateY(-20px);
  background: var(--gold-gradient);
  color: #070A10;
  padding: 10px 20px;
  border-radius: var(--radius-full);
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.85rem;
  box-shadow: 0 10px 25px rgba(246, 211, 101, 0.4);
  opacity: 0;
  pointer-events: none;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  z-index: 400;
}

.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}
