/* =====================================================
   PHONE SHELL
===================================================== */
.phone-wrapper {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
  padding: 20px;
  background: var(--charcoal);
}

.phone-shell {
  position: relative;
  width: 100%;
  max-width: 430px;
  height: 100vh;
  max-height: 932px;
  background: var(--off-white);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  border-radius: 8px;
  box-shadow: 0 40px 80px rgba(0,0,0,0.6);
}

/* =====================================================
   PHASE INDICATOR BAR
===================================================== */
#phase-bar {
  flex-shrink: 0;
  background: var(--white);
  border-bottom: 1px solid var(--border);
  padding: 10px 16px 8px;
  z-index: 20;
}

.phase-track {
  display: flex;
  align-items: center;
  position: relative;
}

.phase-line {
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--border);
  transform: translateY(-50%);
  z-index: 0;
}

.phase-line-fill {
  height: 100%;
  background: var(--sage);
  transition: width 0.6s ease;
}

.phase-dot-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex: 1;
  position: relative;
  z-index: 1;
}

.phase-dot {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--white);
  border: 2px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  font-weight: 700;
  color: var(--muted);
  transition: all 0.4s ease;
  margin-bottom: 4px;
}

.phase-dot.done {
  background: var(--sage);
  border-color: var(--sage);
  color: var(--white);
}

.phase-dot.active {
  background: var(--white);
  border-color: var(--sage);
  color: var(--sage);
  animation: pulseDot 1.8s infinite;
}

.phase-label {
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  transition: color 0.3s;
  white-space: nowrap;
}

.phase-dot-wrap.done .phase-label  { color: var(--sage); }
.phase-dot-wrap.active .phase-label { color: var(--sage); }

/* =====================================================
   TOP STATS BAR
===================================================== */
#top-bar {
  flex-shrink: 0;
  height: 44px;
  background: var(--white);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
  z-index: 10;
}

.top-stat {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 13px;
  font-weight: 700;
  color: var(--charcoal);
}

.xp-badge {
  display: flex;
  align-items: center;
  gap: 4px;
  background: var(--amber-12);
  border: 1px solid var(--amber-25);
  border-radius: 20px;
  padding: 3px 10px 3px 7px;
}

.xp-badge span { font-size: 12px; font-weight: 700; color: var(--amber); }

#avatar-btn {
  width: 32px; height: 32px;
  border-radius: 50%;
  background: var(--sage);
  color: var(--white);
  font-size: 13px; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
  border: none; cursor: pointer;
}

/* =====================================================
   PHASE PANELS (SLIDES)
===================================================== */
#journey-container {
  flex: 1;
  position: relative;
  overflow: hidden;
}

.phase-panel {
  position: absolute;
  inset: 0;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  background: var(--off-white);
  display: none;
  flex-direction: column;
}

.phase-panel.active {
  display: flex;
  animation: slideInRight 0.35s ease forwards;
}

.phase-panel.exiting {
  display: flex;
  animation: slideOutLeft 0.35s ease forwards;
  pointer-events: none;
}

/* =====================================================
   SHARED SECTION STYLES
===================================================== */
.section-header {
  padding: 20px 16px 12px;
}

.section-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--charcoal);
  margin-bottom: 4px;
}

.section-subtitle {
  font-size: 13px;
  color: var(--muted);
}

/* =====================================================
   FLOATING MENTOR BUBBLE
===================================================== */
#mentor-float {
  position: absolute;
  bottom: 16px;
  right: 16px;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: var(--sage);
  border: 3px solid var(--white);
  box-shadow: 0 4px 16px rgba(98,125,112,0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  cursor: pointer;
  z-index: 50;
  transition: opacity 0.3s, transform 0.3s;
  animation: floatMentor 3s ease-in-out infinite;
}

#mentor-float.faded {
  opacity: 0.35;
  transform: scale(0.88);
}
