/* ═══════════════════════════════════════════════════════════════════
   MANORTHA ACADEMY — Sunset Gold Theme v12.0
   Real Estate Education Platform | Professional | Clean | Trustworthy
   Color scheme matches brand logo gradient: golden-yellow → red-orange
   ═══════════════════════════════════════════════════════════════════ */

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@400;500;600;700;800;900&family=Inter:wght@300;400;500;600;700;800&family=DM+Sans:wght@300;400;500;600;700&display=swap');

/* ── CSS Variables ── */
:root {
  /* Core Palette */
  --bg:       #FAFAF8;
  --bg2:      #F4F3EF;
  --bg3:      #EDECE8;
  --white:    #FFFFFF;
  --cream:    #FDF9F3;

  /* Brand Colors — Manortha Academy sunset gradient (gold → red-orange, from logo) */
  --p:        #B8341E;   /* Deep red-orange — logo base */
  --p2:       #C94A1F;
  --p3:       #E07A2C;
  --pl:       #F2B01E;   /* Golden yellow — logo top */
  --pl2:      #FBDA8E;

  /* Accent */
  --gold:     #E8A317;   /* Rich gold — matches logo gradient */
  --goldl:    #F5C842;
  --goldbg:   #FFF6E0;
  --amber:    #D97706;

  /* Text */
  --text:     #1A1A1A;
  --text2:    #3D3D3D;
  --text3:    #6B7280;
  --muted:    #9CA3AF;
  --border:   #E5E3DC;
  --border2:  #D1CFC6;

  /* Semantic */
  --green:    #16A34A;
  --red:      #DC2626;
  --blue:     #1D4ED8;
  --cyan:     #0891B2;
  --orange:   #EA580C;

  /* Shadows */
  --shadow-sm:  0 1px 3px rgba(0,0,0,0.08), 0 1px 2px rgba(0,0,0,0.04);
  --shadow:     0 4px 16px rgba(0,0,0,0.08), 0 2px 6px rgba(0,0,0,0.04);
  --shadow-lg:  0 12px 40px rgba(0,0,0,0.1), 0 4px 12px rgba(0,0,0,0.06);
  --shadow-xl:  0 24px 64px rgba(0,0,0,0.12), 0 8px 20px rgba(0,0,0,0.06);

  /* Typography */
  --font:       'DM Sans', 'Inter', system-ui, sans-serif;
  --font-head:  'Playfair Display', Georgia, serif;
  --font-body:  'Inter', system-ui, sans-serif;
  --font-mono:  'JetBrains Mono', 'Fira Code', monospace;

  /* Spacing & Shape */
  --radius-sm:  8px;
  --radius:     12px;
  --radius-lg:  20px;
  --radius-xl:  28px;
  --nav-h:      72px;
  --max-w:      1200px;
}

/* ── Reset ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { overflow-x: hidden; scroll-behavior: smooth; -webkit-tap-highlight-color: transparent; }
body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.6;
}

/* ── Scrollbar ── */
::-webkit-scrollbar { width: 4px; height: 4px; }
::-webkit-scrollbar-track { background: var(--bg2); }
::-webkit-scrollbar-thumb { background: var(--border2); border-radius: 99px; }
::-webkit-scrollbar-thumb:hover { background: var(--p3); }

/* ── Typography ── */
h1,h2,h3,h4,h5 {
  font-family: var(--font-head);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.01em;
  color: var(--text);
}
p { line-height: 1.7; }
a { color: inherit; text-decoration: none; }

/* ── Utilities ── */
.serif { font-family: var(--font-head); }
.text-center { text-align: center; }
.text-green { color: var(--p); }
.text-gold { color: var(--gold); }
.text-muted { color: var(--text3); }
.w-full { width: 100%; }
.divider { height: 1px; background: var(--border); margin: 24px 0; }
.no-data { text-align: center; padding: 60px 20px; color: var(--muted); }

/* Gradient text */
.grad-text {
  background: linear-gradient(135deg, var(--p) 0%, var(--p3) 40%, var(--goldl) 100%);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
}
.gold-text {
  background: linear-gradient(135deg, var(--gold) 0%, var(--goldl) 100%);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
}

/* ── NAVBAR ── */
#ma-nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  height: var(--nav-h);
  background: rgba(255,255,255,0.94);
  backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  transition: all 0.3s ease;
}
#ma-nav.scrolled {
  background: rgba(255,255,255,0.98);
  box-shadow: var(--shadow);
}
.nav-inner {
  max-width: var(--max-w); margin: 0 auto; padding: 0 28px;
  height: 100%; display: flex; align-items: center; justify-content: space-between; gap: 20px;
}
.nav-logo { display: flex; align-items: center; flex-shrink: 0; }
.nav-links { display: flex; align-items: center; gap: 2px; }
.nav-link {
  font-size: 14px; font-weight: 500; color: var(--text2);
  padding: 8px 14px; border-radius: var(--radius-sm);
  transition: all 0.18s; cursor: pointer;
  background: none; border: none; font-family: var(--font);
  display: flex; align-items: center; gap: 5px;
}
.nav-link:hover { color: var(--p); background: rgba(184,52,30,0.06); }
.nav-link.active { color: var(--p); background: rgba(184,52,30,0.08); font-weight: 600; }
.nav-actions { display: flex; align-items: center; gap: 10px; }

/* Mobile hamburger */
.nav-hamburger {
  display: none; flex-direction: column; gap: 5px; cursor: pointer;
  background: none; border: 1px solid var(--border); border-radius: var(--radius-sm);
  padding: 8px; width: 40px; height: 40px; align-items: center; justify-content: center;
}
.nav-hamburger span {
  display: block; width: 18px; height: 1.5px;
  background: var(--text2); border-radius: 99px; transition: all 0.3s;
}

/* ── SIDEBAR ── */
.ma-sidebar {
  position: fixed; top: var(--nav-h); left: 0; bottom: 0;
  width: 240px; background: var(--white);
  border-right: 1px solid var(--border);
  display: flex; flex-direction: column;
  overflow-y: auto; z-index: 100;
  transition: transform 0.3s ease;
}
.sidebar-nav { padding: 16px 12px; display: flex; flex-direction: column; gap: 2px; flex: 1; }
.sidebar-item {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 14px; border-radius: var(--radius-sm);
  color: var(--text2); font-size: 13.5px; font-weight: 500;
  cursor: pointer; transition: all 0.18s; border: none;
  background: none; width: 100%; text-align: left; font-family: var(--font);
}
.sidebar-item:hover { background: rgba(184,52,30,0.06); color: var(--p); }
.sidebar-item.active { background: rgba(184,52,30,0.1); color: var(--p); font-weight: 600; }
.sidebar-item .ms { font-size: 18px; flex-shrink: 0; }
.sidebar-overlay { display: none; position: fixed; inset: 0; background: rgba(0,0,0,0.3); z-index: 99; }
.sidebar-overlay.show { display: block; }

/* ── LAYOUT ── */
.with-sidebar { margin-left: 240px; min-height: 100vh; }
.page-wrap { padding: 96px 36px 60px; max-width: 1060px; }

/* ── BUTTONS ── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 11px 24px; border-radius: var(--radius-sm);
  font-family: var(--font); font-size: 14px; font-weight: 600;
  border: none; cursor: pointer; transition: all 0.22s ease;
  text-decoration: none; white-space: nowrap; letter-spacing: 0.1px;
  -webkit-tap-highlight-color: transparent;
}
.btn:active { transform: scale(0.97); }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }

.btn-primary {
  background: var(--p); color: white;
  box-shadow: 0 2px 8px rgba(184,52,30,0.25);
}
.btn-primary:hover:not(:disabled) { background: var(--p2); transform: translateY(-1px); box-shadow: 0 4px 16px rgba(184,52,30,0.3); }

.btn-gold {
  background: linear-gradient(135deg, var(--gold) 0%, var(--goldl) 100%);
  color: white; font-weight: 700;
  box-shadow: 0 2px 8px rgba(232,163,23,0.3);
}
.btn-gold:hover:not(:disabled) { transform: translateY(-1px); box-shadow: 0 4px 16px rgba(232,163,23,0.4); }

.btn-ghost {
  background: transparent; border: 1.5px solid var(--border2); color: var(--text2);
}
.btn-ghost:hover { border-color: var(--p); color: var(--p); background: rgba(184,52,30,0.04); }

.btn-outline {
  background: transparent; border: 1.5px solid var(--p); color: var(--p);
}
.btn-outline:hover { background: var(--p); color: white; }

.btn-sm { padding: 7px 16px; font-size: 13px; border-radius: 8px; }
.btn-lg { padding: 14px 36px; font-size: 15px; border-radius: var(--radius); }
.btn-xl { padding: 18px 48px; font-size: 17px; border-radius: var(--radius-lg); }
.btn-icon { width: 40px; height: 40px; padding: 0; border-radius: var(--radius-sm); }

/* ── INPUTS ── */
.inp-wrap {
  position: relative; display: flex; align-items: center;
  background: var(--white); border: 1.5px solid var(--border);
  border-radius: var(--radius-sm); transition: all 0.2s; overflow: hidden;
}
.inp-wrap:focus-within { border-color: var(--p); box-shadow: 0 0 0 3px rgba(184,52,30,0.1); }
.inp-wrap input, .inp-wrap textarea, .inp-wrap select {
  width: 100%; background: transparent; border: none; outline: none;
  color: var(--text); font-family: var(--font); font-size: 15px;
  padding: 13px 14px 13px 46px;
}
.inp-wrap .inp-icon {
  position: absolute; left: 14px; font-size: 18px; color: var(--text3);
  pointer-events: none; font-family: 'Material Symbols Outlined'; z-index: 1;
}
.inp-wrap .inp-right {
  position: absolute; right: 12px; cursor: pointer; color: var(--text3);
  font-family: 'Material Symbols Outlined'; font-size: 18px; transition: color 0.2s;
}
.inp-wrap .inp-right:hover { color: var(--p); }
.inp-wrap input::placeholder { color: var(--muted); }
.inp-label { font-size: 12px; font-weight: 600; color: var(--text2); margin-bottom: 6px; display: block; }

/* ── SECTION HELPERS ── */
.section { padding: 96px 0; }
.section-inner { max-width: var(--max-w); margin: 0 auto; padding: 0 32px; }
.section-tag {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 2px;
  color: var(--p3); margin-bottom: 16px; font-family: var(--font-body);
}
.section-title { font-size: clamp(26px, 4vw, 42px); margin-bottom: 16px; }
.section-sub { font-size: 16px; color: var(--text3); max-width: 580px; line-height: 1.75; font-family: var(--font-body); }

/* ── CARDS ── */
.card {
  background: var(--white); border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: 28px;
  transition: all 0.25s ease;
}
.card:hover { box-shadow: var(--shadow-lg); transform: translateY(-2px); border-color: var(--border2); }
.card-sm { border-radius: var(--radius); padding: 20px; }

/* ── HERO ── */
.hero-section {
  min-height: 100vh; display: flex; align-items: center;
  position: relative; overflow: hidden;
  background: var(--white);
  padding-top: var(--nav-h);
}
.hero-bg-pattern {
  position: absolute; inset: 0; pointer-events: none; z-index: 0;
  background-image: radial-gradient(circle at 20px 20px, rgba(184,52,30,0.04) 1px, transparent 1px);
  background-size: 40px 40px;
}
.hero-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 72px; align-items: center;
}
.hero-title {
  font-size: clamp(32px, 5vw, 56px);
  line-height: 1.1; margin-bottom: 24px;
}
.hero-subtitle { font-size: 17px; color: var(--text3); margin-bottom: 36px; max-width: 440px; line-height: 1.75; font-family: var(--font-body); }
.hero-cta { display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 48px; align-items: center; }

/* ── SKETCH ILLUSTRATIONS (SVG inline) ── */
.sketch-wrap {
  position: relative; width: 100%;
  display: flex; align-items: center; justify-content: center;
}

/* ── STATS BAR ── */
.stats-bar {
  display: grid; grid-template-columns: repeat(4,1fr);
  background: var(--p); border-radius: var(--radius-lg);
  overflow: hidden; margin: 0;
}
.stat-item {
  padding: 32px 24px; text-align: center;
  border-right: 1px solid rgba(255,255,255,0.12);
}
.stat-item:last-child { border-right: none; }
.stat-val { font-size: 32px; font-weight: 800; color: white; font-family: var(--font-head); line-height: 1; }
.stat-lbl { font-size: 12px; color: rgba(255,255,255,0.65); font-weight: 500; margin-top: 6px; text-transform: uppercase; letter-spacing: 0.5px; font-family: var(--font-body); }

/* ── TICKER ── */
.ticker-wrap {
  background: var(--bg2); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border);
  padding: 0; overflow: hidden;
}
.ticker-inner {
  display: inline-block; white-space: nowrap;
  animation: ticker 40s linear infinite;
  font-size: 13px; color: var(--text3); font-family: var(--font-body);
  padding: 11px 0;
}
@keyframes ticker { 0%{transform:translateX(100vw)} 100%{transform:translateX(-100%)} }
.ticker-badge {
  display: inline-flex; align-items: center; gap: 5px;
  background: var(--p); color: white;
  font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 1px;
  padding: 0 20px; height: 100%; flex-shrink: 0;
}

/* ── PILLAR CARDS ── */
.pillar-card {
  background: var(--white); border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: 32px;
  position: relative; overflow: hidden;
  transition: all 0.3s ease; cursor: pointer;
  display: flex; flex-direction: column;
}
.pillar-card::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 4px;
  background: linear-gradient(90deg, var(--p), var(--pl));
  border-radius: 20px 20px 0 0;
}
.pillar-card:hover { box-shadow: var(--shadow-xl); transform: translateY(-4px); border-color: var(--pl2); }
.pillar-card.gold::before { background: linear-gradient(90deg, var(--gold), var(--goldl)); }
.pillar-card.blue::before { background: linear-gradient(90deg, #1D4ED8, #60A5FA); }
.pillar-icon { width: 56px; height: 56px; border-radius: var(--radius); display: flex; align-items: center; justify-content: center; font-size: 28px; margin-bottom: 20px; }
.pillar-icon.green { background: rgba(184,52,30,0.08); }
.pillar-icon.gold { background: rgba(232,163,23,0.1); }
.pillar-icon.blue { background: rgba(29,78,216,0.08); }

/* ── HOW IT WORKS ── */
.how-step { text-align: center; position: relative; }
.how-num {
  width: 48px; height: 48px; border-radius: 50%;
  background: var(--p); color: white;
  display: flex; align-items: center; justify-content: center;
  font-size: 18px; font-weight: 800; font-family: var(--font-head);
  margin: 0 auto 20px; box-shadow: 0 4px 16px rgba(184,52,30,0.25);
}
.how-connector {
  position: absolute; top: 24px; left: calc(50% + 28px);
  right: calc(-50% + 28px); height: 1px;
  border-top: 2px dashed rgba(184,52,30,0.2);
}

/* ── TESTIMONIAL ── */
.testi-card {
  background: var(--white); border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: 28px;
  transition: all 0.25s; position: relative;
}
.testi-card:hover { box-shadow: var(--shadow-lg); border-color: var(--pl2); transform: translateY(-2px); }
.testi-quote { font-size: 60px; color: var(--border2); font-family: Georgia; position: absolute; top: 10px; right: 20px; line-height: 1; }

/* ── FAQ ── */
.faq-item { border: 1px solid var(--border); border-radius: var(--radius); margin-bottom: 10px; overflow: hidden; transition: all 0.2s; }
.faq-item.open { border-color: var(--p3); }
.faq-q { display: flex; justify-content: space-between; align-items: center; padding: 18px 22px; cursor: pointer; font-size: 14.5px; font-weight: 600; color: var(--text); transition: background 0.2s; background: var(--white); }
.faq-q:hover { background: rgba(184,52,30,0.03); }
.faq-item.open .faq-q { background: rgba(184,52,30,0.04); color: var(--p); }
.faq-a { padding: 0 22px 18px; font-size: 14px; color: var(--text3); line-height: 1.75; display: none; background: var(--white); font-family: var(--font-body); }
.faq-item.open .faq-a { display: block; }

/* ── KPI CARDS ── */
.kpi-grid { display: grid; grid-template-columns: repeat(4,1fr); gap: 16px; }
.kpi-card {
  background: var(--white); border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: 24px;
  transition: all 0.22s; position: relative; overflow: hidden;
}
.kpi-card:hover { box-shadow: var(--shadow); border-color: var(--border2); }
.kpi-val { font-size: 30px; font-weight: 800; font-family: var(--font-head); line-height: 1; margin-bottom: 6px; color: var(--p); }
.kpi-lbl { font-size: 11px; color: var(--text3); font-weight: 600; text-transform: uppercase; letter-spacing: 1px; font-family: var(--font-body); }

/* ── PROGRESS BAR ── */
.prog-bar { height: 6px; background: var(--bg2); border-radius: 99px; overflow: hidden; }
.prog-fill { height: 100%; border-radius: 99px; background: var(--p); transition: width 0.9s ease; }

/* ── BADGES ── */
.badge {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 4px 12px; border-radius: 99px; font-size: 11px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.5px; font-family: var(--font-body);
}
.badge-green { background: rgba(184,52,30,0.1); color: var(--p); border: 1px solid rgba(184,52,30,0.2); }
.badge-gold { background: var(--goldbg); color: var(--gold); border: 1px solid rgba(232,163,23,0.25); }
.badge-purple { background: rgba(232,163,23,0.1); color: var(--p2); border: 1px solid rgba(232,163,23,0.25); }
.badge-blue { background: rgba(29,78,216,0.08); color: var(--blue); border: 1px solid rgba(29,78,216,0.2); }
.badge-red { background: rgba(220,38,38,0.08); color: var(--red); border: 1px solid rgba(220,38,38,0.2); }
.badge-gray { background: var(--bg2); color: var(--text3); border: 1px solid var(--border); }

/* ── TOAST ── */
.ma-toast {
  position: fixed; top: 84px; right: 24px; z-index: 99999;
  padding: 14px 20px; border-radius: var(--radius);
  font-size: 14px; font-weight: 500; max-width: 360px; min-width: 220px;
  display: flex; align-items: center; gap: 12px;
  box-shadow: var(--shadow-xl); background: var(--white);
  transform: translateX(120%) scale(0.95); transition: transform 0.35s cubic-bezier(0.34,1.56,0.64,1), opacity 0.3s;
  border: 1px solid var(--border); color: var(--text); opacity: 0;
  font-family: var(--font-body);
}
.ma-toast.show { transform: translateX(0) scale(1); opacity: 1; }
.ma-toast-success { border-left: 4px solid var(--green); }
.ma-toast-error { border-left: 4px solid var(--red); }
.ma-toast-info { border-left: 4px solid var(--p); }
.ma-toast-warning { border-left: 4px solid var(--amber); }

/* ── HEATMAP ── */
.heatmap-grid { display: grid; grid-template-columns: repeat(10,1fr); gap: 5px; }
.heat-cell { aspect-ratio: 1; border-radius: 4px; cursor: pointer; transition: transform 0.15s; }
.heat-cell:hover { transform: scale(1.3); z-index: 2; position: relative; }
.heat-empty { background: var(--bg2); border: 1px solid var(--border); }
.heat-done { background: var(--p); box-shadow: 0 0 6px rgba(184,52,30,0.3); }
.heat-today { background: var(--gold); box-shadow: 0 0 8px rgba(232,163,23,0.4); animation: heatPulse 2s infinite; }
.heat-locked { background: var(--bg3); }
@keyframes heatPulse { 0%,100%{box-shadow:0 0 8px rgba(232,163,23,0.4)} 50%{box-shadow:0 0 16px rgba(232,163,23,0.7)} }

/* ── QUIZ ── */
.quiz-opt {
  display: flex; align-items: center; gap: 16px;
  padding: 16px 20px; border-radius: var(--radius); cursor: pointer;
  border: 1.5px solid var(--border); transition: all 0.2s;
  background: var(--white); font-size: 14px; color: var(--text2);
  user-select: none; font-family: var(--font-body);
}
.quiz-opt:hover { border-color: var(--p3); background: rgba(184,52,30,0.04); color: var(--text); transform: translateX(4px); }
.quiz-opt.selected { border-color: var(--gold); background: var(--goldbg); color: var(--text); }
.quiz-opt.correct { border-color: var(--green); background: rgba(22,163,74,0.08); color: var(--green); }
.quiz-opt.wrong { border-color: var(--red); background: rgba(220,38,38,0.06); color: var(--red); }
.opt-num { width: 30px; height: 30px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 700; flex-shrink: 0; background: var(--bg2); color: var(--text3); transition: all 0.2s; }
.quiz-opt.selected .opt-num { background: var(--gold); color: white; }
.quiz-opt.correct .opt-num { background: var(--green); color: white; }

/* ── TABLE ── */
.ma-table { width: 100%; border-collapse: collapse; }
.ma-table th { padding: 10px 14px; text-align: left; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.8px; color: var(--text3); border-bottom: 1px solid var(--border); font-family: var(--font-body); }
.ma-table td { padding: 12px 14px; font-size: 13px; color: var(--text2); border-bottom: 1px solid var(--border); font-family: var(--font-body); }
.ma-table tr:last-child td { border-bottom: none; }
.ma-table tbody tr:hover { background: rgba(184,52,30,0.03); }

/* ── ADMIN TABS ── */
.admin-tabs { display: flex; gap: 4px; flex-wrap: wrap; background: var(--bg2); padding: 4px; border-radius: var(--radius); }
.admin-tab { padding: 8px 16px; border-radius: 8px; font-size: 13px; font-weight: 600; border: none; cursor: pointer; background: transparent; color: var(--text3); font-family: var(--font); transition: all 0.18s; }
.admin-tab:hover { color: var(--text2); background: rgba(0,0,0,0.04); }
.admin-tab.active { background: var(--white); color: var(--p); box-shadow: var(--shadow-sm); }

/* ── AUTH SHELL ── */
.auth-shell { min-height: 100vh; display: grid; grid-template-columns: 1fr 1fr; }
.auth-left { display: flex; align-items: center; justify-content: center; padding: 48px; position: relative; background: var(--white); }
.auth-card { width: 100%; max-width: 420px; }
.auth-deco {
  background: linear-gradient(160deg, #B8341E 0%, #C94A1F 35%, #E07A2C 70%, #F2B01E 100%);
  display: flex; align-items: center; justify-content: center; position: relative; overflow: hidden;
  padding: 60px;
}
.auth-deco-pattern {
  position: absolute; inset: 0; pointer-events: none;
  background-image: radial-gradient(circle at 20px 20px, rgba(255,255,255,0.06) 1px, transparent 1px);
  background-size: 36px 36px;
}

/* Step wizard */
.step-wrap { display: flex; align-items: center; margin-bottom: 28px; }
.step-circle { width: 34px; height: 34px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 700; flex-shrink: 0; transition: all 0.3s; font-family: var(--font-body); }
.step-done   { background: var(--p); color: white; }
.step-active { background: var(--gold); color: white; }
.step-pending{ background: var(--bg2); color: var(--muted); border: 1.5px solid var(--border); }
.step-line   { flex: 1; height: 2px; background: var(--border); position: relative; min-width: 24px; }
.step-line.done::after { content: ''; position: absolute; inset: 0; background: var(--p); }

/* ── CHATBOT (Clean White) ── */
.chat-fab {
  position: fixed; bottom: 28px; right: 28px; z-index: 9990;
  width: 60px; height: 60px; border-radius: 50%;
  background: var(--p); border: none; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 4px 24px rgba(184,52,30,0.35), 0 0 0 0 rgba(184,52,30,0.2);
  transition: all 0.3s ease;
}
.chat-fab:hover { transform: scale(1.08); box-shadow: 0 8px 36px rgba(184,52,30,0.45), 0 0 0 6px rgba(184,52,30,0.08); }
.chat-fab.pulse { animation: chatPulse 2.5s ease-out infinite; }
@keyframes chatPulse {
  0%{ box-shadow: 0 4px 24px rgba(184,52,30,0.35), 0 0 0 0 rgba(184,52,30,0.3); }
  70%{ box-shadow: 0 4px 24px rgba(184,52,30,0.35), 0 0 0 18px rgba(184,52,30,0); }
  100%{ box-shadow: 0 4px 24px rgba(184,52,30,0.35), 0 0 0 0 rgba(184,52,30,0); }
}
.chat-notif-dot {
  position: absolute; top: 2px; right: 2px;
  width: 14px; height: 14px; border-radius: 50%;
  background: var(--gold); border: 2px solid white;
  font-size: 8px; font-weight: 900; color: white;
  display: flex; align-items: center; justify-content: center;
}

/* Chat Panel */
.chat-panel {
  position: fixed; bottom: 104px; right: 24px; z-index: 9991;
  width: 380px; height: 580px;
  background: var(--white); border: 1px solid var(--border);
  border-radius: 20px;
  box-shadow: var(--shadow-xl);
  display: flex; flex-direction: column; overflow: hidden;
  transform: scale(0.9) translateY(20px); opacity: 0;
  pointer-events: none;
  transition: all 0.35s cubic-bezier(0.34,1.56,0.64,1);
  transform-origin: bottom right;
}
.chat-panel.open { transform: scale(1) translateY(0); opacity: 1; pointer-events: all; }

.chat-header {
  background: var(--p); padding: 16px 20px;
  display: flex; align-items: center; gap: 12px; flex-shrink: 0;
}
.chat-avatar {
  width: 40px; height: 40px; border-radius: 50%;
  background: rgba(255,255,255,0.2); border: 2px solid rgba(255,255,255,0.3);
  display: flex; align-items: center; justify-content: center; font-size: 18px; flex-shrink: 0;
}
.chat-avatar-wrap { position: relative; }
.chat-online-dot {
  position: absolute; bottom: 0; right: 0;
  width: 11px; height: 11px; border-radius: 50%;
  background: #4ade80; border: 2px solid var(--p);
  animation: onlinePulse 2s infinite;
}
@keyframes onlinePulse { 0%,100%{opacity:1} 50%{opacity:0.6} }
.chat-header-info h4 { font-size: 14px; font-weight: 700; color: white; font-family: var(--font); }
.chat-header-info p { font-size: 11px; color: rgba(255,255,255,0.65); margin-top: 1px; font-family: var(--font-body); }
.chat-header-actions { margin-left: auto; display: flex; gap: 6px; }
.chat-header-btn { width: 30px; height: 30px; border-radius: 8px; background: rgba(255,255,255,0.12); border: none; cursor: pointer; color: rgba(255,255,255,0.8); display: flex; align-items: center; justify-content: center; transition: all 0.15s; font-size: 14px; }
.chat-header-btn:hover { background: rgba(255,255,255,0.2); color: white; }

.chat-capabilities { display: flex; gap: 7px; padding: 12px 14px; overflow-x: auto; flex-shrink: 0; border-bottom: 1px solid var(--border); scrollbar-width: none; }
.chat-capabilities::-webkit-scrollbar { display: none; }
.chat-cap-pill { display: flex; align-items: center; gap: 4px; padding: 5px 12px; border-radius: 99px; background: var(--bg2); border: 1px solid var(--border); font-size: 11px; font-weight: 600; color: var(--text2); white-space: nowrap; flex-shrink: 0; cursor: pointer; transition: all 0.15s; font-family: var(--font-body); }
.chat-cap-pill:hover { background: rgba(184,52,30,0.08); border-color: var(--p3); color: var(--p); }

.chat-messages { flex: 1; overflow-y: auto; padding: 16px; display: flex; flex-direction: column; gap: 10px; scrollbar-width: thin; scrollbar-color: var(--border) transparent; }
.chat-messages::-webkit-scrollbar { width: 3px; }
.chat-messages::-webkit-scrollbar-thumb { background: var(--border); border-radius: 99px; }

.chat-bubble { max-width: 82%; padding: 10px 14px; border-radius: 14px; font-size: 13.5px; line-height: 1.6; font-family: var(--font-body); animation: bubbleIn 0.22s ease; word-break: break-word; }
@keyframes bubbleIn { 0%{opacity:0;transform:scale(0.9) translateY(8px)} 100%{opacity:1;transform:scale(1) translateY(0)} }
.chat-bubble.ai { background: var(--bg2); border: 1px solid var(--border); color: var(--text2); align-self: flex-start; border-radius: 4px 14px 14px 14px; }
.chat-bubble.user { background: var(--p); color: white; align-self: flex-end; border-radius: 14px 14px 4px 14px; }
.chat-bubble-icon { font-size: 14px; vertical-align: middle; margin-right: 5px; }

.chat-typing { display: flex; align-items: center; gap: 5px; padding: 12px 14px; align-self: flex-start; background: var(--bg2); border: 1px solid var(--border); border-radius: 4px 14px 14px 14px; animation: bubbleIn 0.22s ease; }
.chat-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--text3); animation: typingDot 1.4s ease-in-out infinite; }
.chat-dot:nth-child(2){ animation-delay: 0.2s; }
.chat-dot:nth-child(3){ animation-delay: 0.4s; }
@keyframes typingDot { 0%,60%,100%{transform:translateY(0);opacity:0.4} 30%{transform:translateY(-6px);opacity:1} }

.chat-suggestions { padding: 10px 14px; display: flex; gap: 6px; flex-wrap: wrap; border-top: 1px solid var(--border); flex-shrink: 0; background: var(--bg); }
.chat-sug-btn { padding: 6px 12px; border-radius: 99px; background: var(--white); border: 1px solid var(--border); color: var(--text3); font-size: 12px; font-weight: 500; cursor: pointer; transition: all 0.15s; font-family: var(--font-body); }
.chat-sug-btn:hover { background: rgba(184,52,30,0.06); border-color: var(--p3); color: var(--p); }

.chat-input-area { padding: 12px; display: flex; gap: 8px; align-items: flex-end; background: var(--white); border-top: 1px solid var(--border); flex-shrink: 0; }
.chat-input-wrap { flex: 1; background: var(--bg2); border: 1.5px solid var(--border); border-radius: 16px; padding: 10px 14px; display: flex; align-items: flex-end; transition: all 0.2s; }
.chat-input-wrap:focus-within { border-color: var(--p); background: var(--white); }
.chat-input { flex: 1; background: transparent; border: none; outline: none; color: var(--text); font-size: 14px; font-family: var(--font-body); resize: none; max-height: 80px; min-height: 20px; line-height: 1.5; }
.chat-input::placeholder { color: var(--muted); }
.chat-send { width: 40px; height: 40px; border-radius: 50%; background: var(--p); border: none; cursor: pointer; display: flex; align-items: center; justify-content: center; color: white; flex-shrink: 0; transition: all 0.22s; font-family: 'Material Symbols Outlined'; font-size: 18px; }
.chat-send:hover { background: var(--p2); transform: scale(1.08); }
.chat-send:active { transform: scale(0.95); }
.chat-time { font-size: 10px; color: var(--muted); text-align: center; margin: 2px 0; font-family: var(--font-body); }
.chat-action-row { display: flex; gap: 6px; margin-top: 8px; flex-wrap: wrap; }
.chat-action-btn { padding: 4px 10px; border-radius: 99px; background: rgba(184,52,30,0.08); border: 1px solid rgba(184,52,30,0.2); color: var(--p); font-size: 11px; font-weight: 600; cursor: pointer; font-family: var(--font-body); transition: all 0.15s; }
.chat-action-btn:hover { background: rgba(184,52,30,0.15); }

/* ── Animations ── */
@keyframes fadeUp { 0%{opacity:0;transform:translateY(24px)} 100%{opacity:1;transform:translateY(0)} }
@keyframes scaleIn { 0%{opacity:0;transform:scale(0.92)} 100%{opacity:1;transform:scale(1)} }
.animate-fadeUp { animation: fadeUp 0.6s ease forwards; }
.animate-scaleIn { animation: scaleIn 0.6s ease forwards; }

/* ── COURSE PAGE ── */
.lesson-content { line-height: 1.85; font-size: 15px; color: var(--text2); font-family: var(--font-body); }
.lesson-content h3 { font-family: var(--font-head); color: var(--text); font-size: 18px; margin: 24px 0 10px; }
.lesson-content p { margin-bottom: 14px; }
.lesson-content ul,ol { padding-left: 22px; margin-bottom: 14px; }
.lesson-content li { margin-bottom: 7px; }
.lesson-content strong { color: var(--text); font-weight: 700; }
.lesson-content .highlight { background: var(--goldbg); border-left: 3px solid var(--gold); padding: 12px 16px; border-radius: 0 var(--radius-sm) var(--radius-sm) 0; margin: 16px 0; }

.day-sidebar { display: flex; flex-direction: column; gap: 4px; max-height: 440px; overflow-y: auto; }
.day-item { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border-radius: var(--radius-sm); cursor: pointer; transition: all 0.18s; border: 1px solid transparent; }
.day-item:hover { background: rgba(184,52,30,0.06); }
.day-item.active { background: rgba(184,52,30,0.1); border-color: rgba(184,52,30,0.2); }
.day-num { width: 26px; height: 26px; border-radius: 6px; display: flex; align-items: center; justify-content: center; font-size: 11px; font-weight: 700; flex-shrink: 0; }

/* Dholera case study teaser */
.dholera-teaser { background: var(--goldbg); border: 1px solid rgba(232,163,23,0.3); border-radius: var(--radius); padding: 16px 18px; margin: 20px 0; }

/* ── REFERRAL ── */
.ref-hero { background: linear-gradient(135deg, rgba(184,52,30,0.05), rgba(232,163,23,0.05)); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 36px; text-align: center; }
.ref-balance { font-size: 48px; font-weight: 800; font-family: var(--font-head); color: var(--p); }
.ref-link-box { display: flex; align-items: center; gap: 0; background: var(--white); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.ref-link-text { flex: 1; padding: 12px 16px; font-size: 13px; color: var(--text2); font-family: monospace; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ref-link-copy { padding: 12px 20px; background: var(--p); color: white; font-size: 13px; font-weight: 600; cursor: pointer; border: none; font-family: var(--font); transition: opacity 0.2s; white-space: nowrap; }
.ref-link-copy:hover { opacity: 0.9; }

/* ── CERTIFICATE ── */
.cert-wrap { background: linear-gradient(135deg, #FDFCF8, #F8F5EE); border: 2px solid var(--gold); border-radius: 20px; padding: 48px; text-align: center; position: relative; overflow: hidden; }
.cert-wrap::before { content: ''; position: absolute; inset: 6px; border: 1px solid rgba(232,163,23,0.2); border-radius: 14px; pointer-events: none; }

/* ── FOOTER ── */
.ma-footer { background: var(--text); padding: 64px 0 32px; }
.footer-inner { max-width: var(--max-w); margin: 0 auto; padding: 0 32px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 48px; margin-bottom: 48px; }
.footer-col h4 { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: 1.2px; color: rgba(255,255,255,0.9); margin-bottom: 16px; font-family: var(--font-body); }
.footer-col a { display: block; font-size: 13.5px; color: rgba(255,255,255,0.5); margin-bottom: 10px; transition: color 0.18s; cursor: pointer; font-family: var(--font-body); }
.footer-col a:hover { color: rgba(255,255,255,0.9); }
.footer-bottom { border-top: 1px solid rgba(255,255,255,0.08); padding-top: 24px; display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; }
.footer-bottom p { font-size: 13px; color: rgba(255,255,255,0.4); font-family: var(--font-body); }
.social-btn { width: 36px; height: 36px; border-radius: 8px; background: rgba(255,255,255,0.08); border: 1px solid rgba(255,255,255,0.12); display: flex; align-items: center; justify-content: center; color: rgba(255,255,255,0.5); transition: all 0.18s; cursor: pointer; font-size: 14px; text-decoration: none; }
.social-btn:hover { background: rgba(255,255,255,0.15); color: white; transform: translateY(-2px); }

/* ── MISC ── */
.glass { background: rgba(255,255,255,0.8); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); border: 1px solid var(--border); border-radius: var(--radius-lg); }
.surface { background: var(--white); border: 1px solid var(--border); border-radius: var(--radius-lg); }
.ms { font-family: 'Material Symbols Outlined'; font-size: 20px; line-height: 1; }
.ms-fill { font-variation-settings: 'FILL' 1; }

/* Landing section patterns */
.section-alt { background: var(--bg2); }
.section-green { background: linear-gradient(160deg, #B8341E 0%, #E07A2C 100%); }

/* Nav user dropdown */
#nav-user-menu { animation: dropIn 0.2s ease; }
@keyframes dropIn { 0%{opacity:0;transform:translateY(-6px)} 100%{opacity:1;transform:translateY(0)} }

/* Skeleton loader */
.skeleton { background: linear-gradient(90deg, var(--bg2) 25%, var(--bg3) 50%, var(--bg2) 75%); background-size: 200% 100%; animation: skeleton 1.5s infinite; border-radius: var(--radius-sm); }
@keyframes skeleton { 0%{background-position:200% 0} 100%{background-position:-200% 0} }

/* ═══════════════════════════════════════════════════════════════════
   AUTOMATION FLOW PAGE — interactive flowchart nodes
   ═══════════════════════════════════════════════════════════════════ */
.auto-node { will-change: transform, box-shadow, border-color; }
.auto-node:hover {
  transform: translateY(-4px) scale(1.015);
  box-shadow: var(--shadow-lg);
  border-color: var(--pl2);
}
.auto-node:hover .auto-node-icon { transform: scale(1.12) rotate(-4deg); }
.auto-node:active { transform: translateY(-1px) scale(0.995); }
.auto-node-icon, .auto-node-count { will-change: transform; }
#automation-detail { border-color: var(--pl2) !important; }

@media (max-width: 900px) {
  #automation-nodes { grid-template-columns: 1fr !important; }
}
@media (min-width: 901px) and (max-width: 1200px) {
  #automation-nodes { grid-template-columns: repeat(2,1fr) !important; }
}

/* ═══════════════════════════════════════════════════════════════════
   NEXT-LEVEL MICRO-INTERACTIONS — buttons, cards, links
   ═══════════════════════════════════════════════════════════════════ */
.btn { position: relative; overflow: hidden; }
.btn::after {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(circle at var(--mx,50%) var(--my,50%), rgba(255,255,255,0.35) 0%, transparent 60%);
  opacity: 0; transition: opacity 0.3s;
  pointer-events: none;
}
.btn:hover::after { opacity: 1; }
.btn:active { transform: scale(0.97) !important; }

.kpi-card, .pillar-card, .testi-card, .glass { will-change: transform; }

/* Scroll-reveal utility (JS toggles .in-view) */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity 0.7s cubic-bezier(.16,1,.3,1), transform 0.7s cubic-bezier(.16,1,.3,1); }
.reveal.in-view { opacity: 1; transform: translateY(0); }

/* Chat security badge */
.chat-security-badge {
  display: inline-flex; align-items: center; gap: 5px;
  background: rgba(22,163,74,0.1); border: 1px solid rgba(22,163,74,0.25);
  color: #16a34a; border-radius: 99px; padding: 3px 10px;
  font-size: 10.5px; font-weight: 700; white-space: nowrap;
}
.chat-blocked-note {
  background: rgba(220,38,38,0.06); border: 1px solid rgba(220,38,38,0.2);
  color: #dc2626; border-radius: 4px 14px 14px 14px; padding: 10px 14px;
  font-size: 12.5px; align-self: flex-start; max-width: 82%;
}

/* Gradient shimmer border for hero/featured elements */
@keyframes borderShimmer { 0%{background-position:0% 50%} 100%{background-position:200% 50%} }
.shimmer-border {
  position: relative; border-radius: inherit;
}
.shimmer-border::before {
  content: ''; position: absolute; inset: -1px; border-radius: inherit;
  background: linear-gradient(90deg, var(--p), var(--gold), var(--pl), var(--p));
  background-size: 200% 100%; animation: borderShimmer 4s linear infinite;
  z-index: -1;
}

/* ── Pro Courses & Market News: interactive card polish ── */
#pro-courses-grid .glass, #market-news-list .glass, #market-news-list a.glass {
  transition: transform 0.25s cubic-bezier(.16,1,.3,1), box-shadow 0.25s ease, border-color 0.25s ease;
}
#pro-courses-grid .glass:hover {
  box-shadow: var(--shadow-xl);
  border-color: var(--pl2);
}
#dash-motion-section, #pc-motion-canvas, #mn-motion-canvas {
  background: linear-gradient(135deg, rgba(184,52,30,0.04), rgba(232,163,23,0.03));
}
#dash-motion-section { border: 1px solid var(--border); }

/* ── MOBILE RESPONSIVE ── */
@media (max-width: 1024px) {
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 32px; }
}
@media (max-width: 900px) {
  .ma-sidebar { transform: translateX(-100%); }
  .ma-sidebar.open { transform: translateX(0); }
  .with-sidebar { margin-left: 0 !important; }
  .page-wrap { padding: 80px 16px 40px; }
  .kpi-grid { grid-template-columns: repeat(2,1fr); gap: 12px; }
  .hero-grid { grid-template-columns: 1fr; gap: 40px; }
  .hero-visual-wrap { display: none; }
  .nav-links { display: none !important; }
  .nav-actions { display: none !important; }
  .nav-hamburger { display: flex !important; }
  .section { padding: 64px 0; }
  .section-inner { padding: 0 20px; }
  .chat-panel { width: calc(100vw - 20px); right: 10px; }
  .auth-shell { grid-template-columns: 1fr; }
  .auth-deco { display: none; }
  .stats-bar { grid-template-columns: repeat(2,1fr); }
}
@media (max-width: 640px) {
  .hero-title { font-size: 30px; }
  .section-title { font-size: 26px; }
  .kpi-grid { grid-template-columns: repeat(2,1fr); }
  .chat-panel { width: 100vw; right: 0; border-radius: 20px 20px 0 0; bottom: 0; height: 70vh; }
  .chat-fab { bottom: 20px; right: 16px; width: 54px; height: 54px; }
  .footer-grid { grid-template-columns: 1fr; gap: 24px; }
  .stats-bar { grid-template-columns: repeat(2,1fr); }
}

/* ═══════════════════════════════════════════════════════════════════
   PENCIL-SKETCH DRAW-ON ANIMATION + REAL ESTATE CHARACTER
   Minimalist, hand-drawn "building sketching itself" effect using SVG
   stroke-dasharray/stroke-dashoffset draw-on, plus a friendly line-art
   "partner" character that idles/waves. All pure CSS — zero JS needed
   to animate once .sketch-draw is in the DOM.
   ═══════════════════════════════════════════════════════════════════ */
@keyframes sketchDraw {
  to { stroke-dashoffset: 0; }
}
.sketch-draw path,
.sketch-draw line,
.sketch-draw polyline,
.sketch-draw rect,
.sketch-draw circle,
.sketch-draw ellipse {
  stroke-dasharray: 1000;
  stroke-dashoffset: 1000;
  animation: sketchDraw 2.6s cubic-bezier(.65,0,.35,1) forwards;
}
.sketch-draw .sk-fill-in {
  opacity: 0;
  animation: sketchFadeIn 0.6s ease forwards;
  animation-delay: 2.4s;
}
@keyframes sketchFadeIn { to { opacity: 1; } }

/* Pencil tip that "travels" while drawing (decorative, purely visual) */
@keyframes pencilFloat {
  0%, 100% { transform: translateY(0) rotate(-8deg); }
  50% { transform: translateY(-6px) rotate(-4deg); }
}
.sketch-pencil-icon {
  position: absolute; font-size: 22px; pointer-events: none;
  animation: pencilFloat 2.4s ease-in-out infinite;
  filter: drop-shadow(0 2px 4px rgba(0,0,0,0.15));
}

/* Minimalist line-art real-estate character — gentle idle bob + wave */
@keyframes charBob {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-5px); }
}
@keyframes charWave {
  0%, 100% { transform: rotate(0deg); }
  25% { transform: rotate(-18deg); }
  50% { transform: rotate(4deg); }
  75% { transform: rotate(-10deg); }
}
.realty-character { animation: charBob 3.2s ease-in-out infinite; }
.realty-character .char-arm-wave { transform-origin: 70% 20%; animation: charWave 2.2s ease-in-out infinite; }

/* Reduced motion accessibility: skip all sketch/character animation */
@media (prefers-reduced-motion: reduce) {
  .sketch-draw path, .sketch-draw line, .sketch-draw polyline,
  .sketch-draw rect, .sketch-draw circle, .sketch-draw ellipse {
    animation: none; stroke-dashoffset: 0;
  }
  .sketch-draw .sk-fill-in { animation: none; opacity: 1; }
  .sketch-pencil-icon, .realty-character, .realty-character .char-arm-wave { animation: none; }
}
