:root {
  --bg: #0a0a0f;
  --bg-card: #13131a;
  --bg-card2: #1a1a24;
  --fg: #e8e6e1;
  --fg-muted: #9a9590;
  --gold: #d4af37;
  --gold-light: #f0d060;
  --gold-dim: #8b7325;
  --accent-glow: rgba(212, 175, 55, 0.08);
  --border: rgba(255, 255, 255, 0.06);
  --border-gold: rgba(212, 175, 55, 0.2);
  --radius: 12px;
  --font-display: 'Syne', sans-serif;
  --font-body: 'DM Sans', sans-serif;
  --success: #22c55e;
  --error: #ef4444;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

/* ===================== NAV ===================== */
.app-nav {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 32px;
  height: 60px;
  background: rgba(10, 10, 15, 0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}
.nav-brand {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.1rem;
  color: var(--gold);
  text-decoration: none;
  letter-spacing: -0.01em;
}
.nav-links { display: flex; gap: 8px; align-items: center; }
.nav-link {
  color: var(--fg-muted);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  padding: 6px 14px;
  border-radius: 8px;
  transition: all 0.15s;
}
.nav-link:hover { color: var(--fg); background: rgba(255,255,255,0.05); }
.nav-link.active { color: var(--gold); background: var(--accent-glow); }
.nav-step { font-size: 13px; color: var(--fg-muted); letter-spacing: 0.05em; }

/* ===================== SHARED ===================== */
.gold {
  color: var(--gold);
  background: linear-gradient(135deg, var(--gold-light), var(--gold), var(--gold-dim));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.lede {
  font-size: 1.1rem;
  color: var(--fg-muted);
  line-height: 1.7;
}
.hero-badge {
  display: inline-block;
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 3px;
  color: var(--gold);
  border: 1px solid var(--gold-dim);
  padding: 6px 18px;
  border-radius: 100px;
  margin-bottom: 24px;
}
.section-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 2px;
  color: var(--gold-dim);
  text-transform: uppercase;
  margin-bottom: 12px;
}
.required { color: var(--gold); }
.alert {
  padding: 12px 16px;
  border-radius: var(--radius);
  margin-bottom: 20px;
  font-size: 14px;
}
.alert-error { background: rgba(239,68,68,0.1); border: 1px solid rgba(239,68,68,0.3); color: #fca5a5; }
.alert-success { background: rgba(34,197,94,0.1); border: 1px solid rgba(34,197,94,0.3); color: #86efac; }

/* ===================== BUTTONS ===================== */
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--gold);
  color: #0a0a0f;
  border: none;
  padding: 12px 28px;
  border-radius: var(--radius);
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.15s;
}
.btn-primary:hover { background: var(--gold-light); transform: translateY(-1px); }
.btn-primary:disabled { opacity: 0.5; cursor: not-allowed; transform: none; }
.btn-primary.btn-large { padding: 14px 36px; font-size: 16px; }

.btn-outline {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: transparent;
  color: var(--fg-muted);
  border: 1px solid var(--border);
  padding: 10px 20px;
  border-radius: var(--radius);
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.15s;
}
.btn-outline:hover { color: var(--fg); border-color: var(--border-gold); }
.btn-outline.btn-sm { padding: 7px 14px; font-size: 13px; }

/* ===================== LOADING DOTS ===================== */
.loading-dots { display: flex; gap: 4px; align-items: center; }
.loading-dots span {
  width: 6px; height: 6px;
  background: var(--gold-dim);
  border-radius: 50%;
  animation: dot-bounce 1.2s infinite ease-in-out;
}
.loading-dots span:nth-child(2) { animation-delay: 0.2s; }
.loading-dots span:nth-child(3) { animation-delay: 0.4s; }
@keyframes dot-bounce {
  0%, 80%, 100% { transform: scale(0.6); opacity: 0.4; }
  40% { transform: scale(1); opacity: 1; }
}

/* ===================== ONBOARDING ===================== */
.onboarding-page {
  min-height: calc(100vh - 60px);
  padding: 60px 24px;
}
.onboarding-inner {
  max-width: 680px;
  margin: 0 auto;
}
.quiz-header { text-align: center; margin-bottom: 48px; }
.quiz-header h1 {
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, 3.2rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin-bottom: 16px;
}
.quiz-form { display: flex; flex-direction: column; gap: 32px; }
.quiz-section { display: flex; flex-direction: column; gap: 8px; }
.quiz-label { font-weight: 600; font-size: 15px; color: var(--fg); }
.quiz-hint { font-size: 13px; color: var(--fg-muted); margin-top: -4px; }

.quiz-textarea, .quiz-select {
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--fg);
  padding: 14px 16px;
  border-radius: var(--radius);
  font-family: var(--font-body);
  font-size: 15px;
  transition: border-color 0.15s;
  width: 100%;
}
.quiz-textarea { min-height: 100px; resize: vertical; }
.quiz-select { cursor: pointer; appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%239a9590' stroke-width='2'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; padding-right: 40px; }
.quiz-textarea:focus, .quiz-select:focus {
  outline: none;
  border-color: var(--gold-dim);
  box-shadow: 0 0 0 3px rgba(212,175,55,0.08);
}
.quiz-select option { background: var(--bg-card); }

.option-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.option-card {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 16px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  cursor: pointer;
  transition: all 0.15s;
}
.option-card:hover { border-color: var(--border-gold); background: var(--bg-card2); }
.option-card.selected { border-color: var(--gold); background: var(--accent-glow); }
.option-card input[type="radio"] { display: none; }
.option-title { font-weight: 600; font-size: 14px; margin-bottom: 2px; }
.option-desc { font-size: 12px; color: var(--fg-muted); }

.quiz-row { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 16px; }

.quiz-submit { text-align: center; padding-top: 8px; }
.submit-note { font-size: 13px; color: var(--fg-muted); margin-top: 12px; }

/* ===================== COACHING ===================== */
.coaching-layout {
  display: flex;
  height: calc(100vh - 60px);
  overflow: hidden;
}

/* Sidebar */
.coaching-sidebar {
  width: 260px;
  flex-shrink: 0;
  background: var(--bg-card);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  overflow-y: auto;
}
.sidebar-section { padding: 20px; border-bottom: 1px solid var(--border); }
.profile-card { display: flex; flex-direction: column; gap: 8px; margin-bottom: 4px; }
.profile-row { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; }
.profile-key { font-size: 12px; color: var(--fg-muted); font-weight: 500; white-space: nowrap; }
.profile-val { font-size: 12px; color: var(--fg); text-align: right; font-weight: 600; text-transform: capitalize; }
.profile-goals-text { font-size: 12px; color: var(--fg-muted); line-height: 1.5; }

.session-history { display: flex; flex-direction: column; gap: 2px; }
.session-item {
  padding: 10px;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.1s;
}
.session-item:hover { background: rgba(255,255,255,0.04); }
.session-item.active { background: var(--accent-glow); border: 1px solid var(--border-gold); }
.session-date { font-size: 11px; color: var(--fg-muted); margin-bottom: 3px; }
.session-preview { font-size: 12px; color: var(--fg); line-height: 1.4; }
.sidebar-empty { font-size: 13px; color: var(--fg-muted); }

.sidebar-actions {
  margin-top: auto;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  border-top: 1px solid var(--border);
}

/* Chat area */
.coaching-main {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.chat-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 24px;
  border-bottom: 1px solid var(--border);
  background: var(--bg);
}
.mentor-avatar {
  width: 36px;
  height: 36px;
  background: linear-gradient(135deg, var(--gold), var(--gold-dim));
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 14px;
  color: #0a0a0f;
  flex-shrink: 0;
}
.chat-header-info { flex: 1; }
.chat-title { font-weight: 700; font-size: 15px; }
.chat-status { font-size: 12px; color: var(--fg-muted); }

.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.chat-welcome {
  text-align: center;
  max-width: 520px;
  margin: auto;
  padding: 40px 0;
}
.welcome-icon {
  font-size: 28px;
  color: var(--gold);
  margin-bottom: 16px;
}
.chat-welcome h2 {
  font-family: var(--font-display);
  font-size: 1.8rem;
  font-weight: 800;
  margin-bottom: 12px;
}
.chat-welcome p { color: var(--fg-muted); font-size: 15px; margin-bottom: 28px; }
.starter-prompts { display: flex; flex-direction: column; gap: 8px; text-align: left; }
.starter-btn {
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--fg-muted);
  padding: 12px 16px;
  border-radius: var(--radius);
  font-family: var(--font-body);
  font-size: 14px;
  cursor: pointer;
  text-align: left;
  transition: all 0.15s;
}
.starter-btn:hover { border-color: var(--border-gold); color: var(--fg); background: var(--bg-card2); }

.chat-message { display: flex; }
.chat-message.user { justify-content: flex-end; }
.chat-message.assistant { justify-content: flex-start; }
.message-bubble {
  display: flex;
  gap: 10px;
  max-width: 72%;
}
.chat-message.user .message-bubble { flex-direction: row-reverse; }
.message-content {
  padding: 12px 16px;
  border-radius: 16px;
  font-size: 15px;
  line-height: 1.6;
}
.chat-message.user .message-content {
  background: var(--gold);
  color: #0a0a0f;
  border-bottom-right-radius: 4px;
}
.chat-message.assistant .message-content {
  background: var(--bg-card2);
  border: 1px solid var(--border);
  color: var(--fg);
  border-bottom-left-radius: 4px;
}

.chat-input-area {
  border-top: 1px solid var(--border);
  padding: 16px 24px;
  background: var(--bg);
}
.action-item-banner {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  background: var(--accent-glow);
  border: 1px solid var(--border-gold);
  border-radius: var(--radius);
  padding: 12px 16px;
  margin-bottom: 12px;
  font-size: 14px;
  color: var(--gold);
}
.action-item-icon { flex-shrink: 0; }
.chat-input-row { display: flex; gap: 10px; align-items: flex-end; }
.chat-input {
  flex: 1;
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--fg);
  padding: 12px 16px;
  border-radius: var(--radius);
  font-family: var(--font-body);
  font-size: 15px;
  resize: none;
  line-height: 1.5;
  max-height: 120px;
  overflow-y: auto;
  transition: border-color 0.15s;
}
.chat-input:focus { outline: none; border-color: var(--gold-dim); }
.chat-send-btn {
  width: 44px;
  height: 44px;
  background: var(--gold);
  border: none;
  border-radius: var(--radius);
  color: #0a0a0f;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: all 0.15s;
}
.chat-send-btn:hover:not(:disabled) { background: var(--gold-light); }
.chat-send-btn:disabled { opacity: 0.4; cursor: not-allowed; }
.chat-hint { font-size: 12px; color: var(--fg-muted); margin-top: 8px; }

/* ===================== DAILY CHECK-IN ===================== */
.checkin-page {
  min-height: calc(100vh - 60px);
  padding: 60px 24px;
}
.checkin-inner { max-width: 660px; margin: 0 auto; }
.checkin-header { text-align: center; margin-bottom: 48px; }
.checkin-header h1 {
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin-bottom: 16px;
}

.yesterday-action-display {
  background: var(--bg-card);
  border: 1px solid var(--border-gold);
  border-radius: var(--radius);
  padding: 20px;
  margin-bottom: 32px;
}
.yesterday-action-text { color: var(--gold); font-weight: 500; font-size: 15px; }

.checkin-form { display: flex; flex-direction: column; gap: 28px; }

.result-options {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
}
.result-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 16px 8px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  cursor: pointer;
  transition: all 0.15s;
  text-align: center;
}
.result-card:hover { border-color: var(--border-gold); background: var(--bg-card2); }
.result-card.selected { border-color: var(--gold); background: var(--accent-glow); }
.result-card input[type="radio"] { display: none; }
.result-emoji { font-size: 24px; margin-bottom: 6px; }
.result-title { font-size: 12px; font-weight: 600; color: var(--fg-muted); }
.result-card.selected .result-title { color: var(--fg); }

/* Done card */
.checkin-done-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 32px;
  text-align: center;
  margin-bottom: 48px;
}
.done-icon {
  width: 48px; height: 48px;
  background: rgba(34,197,94,0.15);
  border: 1px solid rgba(34,197,94,0.3);
  color: var(--success);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  margin: 0 auto 16px;
}
.checkin-done-card h2 {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 800;
  margin-bottom: 24px;
}
.done-ai-response {
  background: var(--bg-card2);
  border-radius: var(--radius);
  padding: 20px;
  text-align: left;
  margin-bottom: 20px;
}
.ai-response-text { font-size: 15px; color: var(--fg); line-height: 1.7; }
.todays-focus-card {
  background: var(--accent-glow);
  border: 1px solid var(--border-gold);
  border-radius: var(--radius);
  padding: 16px;
  text-align: left;
  margin-bottom: 24px;
}
.focus-label { font-size: 11px; font-weight: 700; letter-spacing: 2px; color: var(--gold-dim); margin-bottom: 8px; }
.focus-text { font-size: 15px; color: var(--gold); font-weight: 500; }
.done-actions { display: flex; justify-content: center; }

/* AI response panel */
.ai-response-panel {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 28px;
  margin-top: 32px;
}
.ai-response-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 20px;
}
.ai-response-title { font-weight: 700; font-size: 15px; }
.ai-response-actions {
  display: flex;
  gap: 12px;
  margin-top: 24px;
  flex-wrap: wrap;
}

/* Check-in history */
.checkin-history-section { margin-top: 48px; }
.checkin-history-list { display: flex; flex-direction: column; gap: 2px; margin-top: 16px; }
.checkin-history-item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 12px 16px;
  background: var(--bg-card);
  border-radius: var(--radius);
  border: 1px solid var(--border);
}
.checkin-date { font-size: 13px; color: var(--fg-muted); min-width: 100px; }
.checkin-result-badge {
  font-size: 13px;
  font-weight: 600;
  text-transform: capitalize;
  white-space: nowrap;
}
.checkin-focus { font-size: 13px; color: var(--fg-muted); flex: 1; }

/* ===================== LANDING PAGE STYLES ===================== */
/* These extend the existing landing page classes */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 80px 24px;
  background:
    radial-gradient(ellipse 60% 50% at 50% 0%, rgba(212, 175, 55, 0.06) 0%, transparent 70%),
    var(--bg);
  position: relative;
}
.hero::before {
  content: '';
  position: absolute;
  top: 0; left: 50%;
  transform: translateX(-50%);
  width: 1px; height: 120px;
  background: linear-gradient(to bottom, transparent, var(--gold-dim), transparent);
}
.hero-inner { max-width: 740px; text-align: center; }
.hero h1 {
  font-family: var(--font-display);
  font-size: clamp(3rem, 7vw, 5.5rem);
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: -0.02em;
  margin-bottom: 28px;
}
.lede {
  font-size: 1.15rem;
  color: var(--fg-muted);
  max-width: 580px;
  margin: 0 auto 48px;
  line-height: 1.7;
}
.hero-stats {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 32px;
  flex-wrap: wrap;
}
.stat { display: flex; flex-direction: column; gap: 4px; text-align: center; }
.stat-num { font-family: var(--font-display); font-size: 1.6rem; font-weight: 800; color: var(--gold); }
.stat-label { font-size: 12px; color: var(--fg-muted); letter-spacing: 0.05em; text-transform: uppercase; }
.stat-divider { width: 1px; height: 40px; background: var(--border); }

.hero-cta {
  margin-top: 48px;
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
  align-items: center;
}
.hero-cta .btn-primary { padding: 16px 40px; font-size: 17px; }
.hero-cta .btn-outline { padding: 16px 28px; font-size: 15px; }

/* Features */
.features { padding: 100px 24px; }
.features-inner { max-width: 1100px; margin: 0 auto; text-align: center; }
.features h2 {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 800;
  margin-bottom: 16px;
}
.section-sub { color: var(--fg-muted); max-width: 580px; margin: 0 auto 60px; font-size: 1.05rem; }
.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
}
.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 28px;
  text-align: left;
  transition: border-color 0.2s;
}
.feature-card:hover { border-color: var(--border-gold); }
.feature-icon { color: var(--gold); font-size: 18px; margin-bottom: 14px; }
.feature-card h3 { font-family: var(--font-display); font-weight: 700; margin-bottom: 10px; }
.feature-card p { color: var(--fg-muted); font-size: 14px; line-height: 1.6; }

/* How section */
.how { padding: 100px 24px; background: var(--bg-card); }
.how-inner { max-width: 800px; margin: 0 auto; text-align: center; }
.how h2 {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 800;
  margin-bottom: 48px;
  line-height: 1.2;
}
.comparison { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; text-align: left; }
.comp-col {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 28px;
}
.comp-col.new { border-color: var(--border-gold); background: var(--accent-glow); }
.comp-header {
  font-family: var(--font-display);
  font-weight: 700;
  margin-bottom: 20px;
  font-size: 1rem;
}
.comp-col.new .comp-header { color: var(--gold); }
.comp-col ul { list-style: none; display: flex; flex-direction: column; gap: 12px; }
.comp-col li { font-size: 14px; color: var(--fg-muted); padding-left: 16px; position: relative; }
.comp-col li::before { content: '—'; position: absolute; left: 0; color: var(--border); }
.comp-col.new li::before { content: '→'; color: var(--gold-dim); }
.comp-col.new li { color: var(--fg); }

/* Closing */
.closing { padding: 120px 24px; text-align: center; }
.closing-inner { max-width: 700px; margin: 0 auto; }
.closing h2 {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 800;
  line-height: 1.25;
  margin-bottom: 28px;
}
.closing-text { color: var(--fg-muted); font-size: 1.05rem; max-width: 560px; margin: 0 auto; }
.closing-cta { margin-top: 40px; }

/* Footer */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 40px 24px;
}
.footer-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.footer-brand { font-family: var(--font-display); font-weight: 800; color: var(--gold); }
.footer-tagline { font-size: 13px; color: var(--fg-muted); }

/* ===================== RESPONSIVE ===================== */
@media (max-width: 768px) {
  .coaching-layout { flex-direction: column; height: auto; }
  .coaching-sidebar { width: 100%; height: auto; max-height: 200px; }
  .coaching-main { height: calc(100vh - 260px); }
  .option-grid { grid-template-columns: 1fr; }
  .quiz-row { grid-template-columns: 1fr; }
  .result-options { grid-template-columns: repeat(2, 1fr); }
  .comparison { grid-template-columns: 1fr; }
  .app-nav { padding: 0 16px; }
  .hero-stats { gap: 20px; }
}
