/* ================================================================
   Objectives Journey — Scroll-Driven Winding Path Section
   Brand color: #0057B0 (TBI blue)
   ================================================================ */

/* ── Section wrapper ─────────────────────────────────────────── */
.obj-journey-section {
  background: #f8f8f6;
  padding: 65px 0 50px;
  overflow: hidden;
  position: relative;
}

/* ── Section header ──────────────────────────────────────────── */
.obj-journey-header {
  text-align: center;
  max-width: 640px;
  margin: 0 auto 36px;
  padding: 0 24px;
}
.obj-journey-eyebrow {
  display: block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: #0057B0;
  margin-bottom: 10px;
}
.obj-journey-title {
  font-family: 'Playfair Display', serif;
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 700;
  color: #0d1117;
  margin: 0 0 12px;
  line-height: 1.15;
}
.obj-journey-sub {
  font-size: 1rem;
  color: #64748b;
  line-height: 1.7;
  margin: 0;
}

/* ── Journey body: SVG + steps ───────────────────────────────── */
.obj-journey-body {
  position: relative;
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px;
  /* Height is set by JS to match the SVG viewport */
}

/* ── The SVG path overlay ────────────────────────────────────── */
.obj-svg {
  position: absolute;
  top: 0;
  left: 24px; /* match padding */
  right: 24px;
  width: calc(100% - 48px);
  height: 100%;
  pointer-events: none;
  overflow: visible;
}

/* Background (faded) path */
.obj-path-bg {
  stroke: #d1d5db;
  stroke-width: 2.5;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* Foreground (animated draw-in) path */
.obj-path-live {
  stroke: #0057B0;
  stroke-width: 2.5;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
  /* dasharray/dashoffset set by JS */
}

/* ── Walker figure ───────────────────────────────────────────── */
.obj-walker-group {
  transition: none;
}
.obj-walker-shadow {
  fill: rgba(0,0,0,0.12);
}
.obj-walker-body {
  fill: #0d1117;
  stroke: none;
}

/* ── Individual step items (absolutely positioned) ───────────── */
.obj-step {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 20px;
  width: 46%;
  opacity: 0;
  transform: translateY(24px) translateY(-50%);
  transition: opacity 0.65s cubic-bezier(0.16,1,0.3,1),
              transform 0.65s cubic-bezier(0.16,1,0.3,1);
}
.obj-step.is-visible {
  opacity: 1;
  transform: translateY(-50%);
}

/* Left steps: anchor right edge to the node's X position */
.obj-step--left {
  flex-direction: row-reverse;
  text-align: right;
}
/* Right steps: anchor left edge to the node's X position */
.obj-step--right {
  flex-direction: row;
  text-align: left;
}

/* ── Node circle ─────────────────────────────────────────────── */
.obj-node-circle {
  width: 88px;
  height: 88px;
  border-radius: 50%;
  flex-shrink: 0;
  background: #e9f0fb;
  border: 2.5px solid #bdd1f0;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  transition: background 0.5s ease, border-color 0.5s ease,
              box-shadow 0.5s ease, transform 0.5s cubic-bezier(0.16,1,0.3,1);
}
.obj-node-circle.is-active {
  background: #0057B0;
  border-color: #0057B0;
  box-shadow: 0 0 0 6px rgba(0,87,176,0.14),
              0 0 0 14px rgba(0,87,176,0.06);
  transform: scale(1.08);
}
.obj-node-circle.is-past {
  background: #0057B0;
  border-color: #0057B0;
  opacity: 0.7;
}

.obj-node-num {
  font-size: 1.7rem;
  font-weight: 800;
  line-height: 1;
  color: #0057B0;
  font-family: 'Oswald', sans-serif;
  letter-spacing: 0.02em;
  transition: color 0.4s ease;
}
.obj-node-circle.is-active .obj-node-num,
.obj-node-circle.is-past .obj-node-num {
  color: #ffffff;
}

/* Node icon (removed) */
.obj-node-icon {
  display: none;
}

/* ── Step text block (Redesigned Card Structure) ─────────────── */
.obj-step-text {
  flex: 1;
  min-width: 0;
  background: #ffffff;
  border: 1px solid rgba(226, 232, 240, 0.9);
  border-radius: 20px;
  padding: 16px 24px 20px;
  box-shadow: 0 10px 25px -4px rgba(15, 23, 42, 0.05), 0 4px 10px -2px rgba(15, 23, 42, 0.02);
  position: relative;
  z-index: 2; /* keep above the path */
  text-align: left;
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1),
              box-shadow 0.35s cubic-bezier(0.16, 1, 0.3, 1),
              border-color 0.35s ease;
}

/* Subtle top gradient accent on card hover / active */
.obj-step-text::before {
  content: '';
  position: absolute;
  top: 0;
  left: 24px;
  right: 24px;
  height: 3px;
  border-radius: 0 0 4px 4px;
  background: transparent;
  transition: background 0.35s ease;
}

.obj-step-text:hover {
  transform: translateY(-4px);
  box-shadow: 0 18px 36px -6px rgba(0, 87, 176, 0.12), 0 6px 16px -3px rgba(15, 23, 42, 0.04);
  border-color: rgba(0, 87, 176, 0.22);
}

.obj-step-text:hover::before {
  background: linear-gradient(90deg, #0057B0, #3b82f6);
}

.obj-step.is-active .obj-step-text {
  border-color: rgba(0, 87, 176, 0.28);
  box-shadow: 0 16px 36px -6px rgba(0, 87, 176, 0.12), 0 6px 14px -2px rgba(15, 23, 42, 0.04);
}

.obj-step.is-active .obj-step-text::before {
  background: linear-gradient(90deg, #0057B0, #3b82f6);
}

.obj-step-title {
  font-family: inherit;
  font-size: 1.45rem;
  font-weight: 700;
  color: #0f172a;
  margin: 0 0 8px;
  letter-spacing: -0.015em;
  line-height: 1.25;
  transition: color 0.3s ease;
  overflow-wrap: break-word;
  word-wrap: break-word;
}

.obj-step.is-active .obj-step-title,
.obj-step-text:hover .obj-step-title {
  color: #0057B0;
}

.obj-step-desc {
  font-size: 0.9375rem;
  color: #475569;
  line-height: 1.68;
  margin: 0;
  font-weight: 400;
}

/* Legacy selectors kept harmless for backward compatibility */
.obj-step-eyebrow,
.obj-step-tags,
.obj-step-tag {
  display: none;
}

/* ── Mobile (single column) ──────────────────────────────────── */
@media (max-width: 768px) {
  .obj-journey-section { padding: 60px 0 40px; }

  /* On mobile we switch to a normal flow layout (JS adds class) */
  .obj-journey-body.is-mobile {
    padding-bottom: 40px;
  }
  .obj-journey-body.is-mobile .obj-svg {
    left: 50%;
    transform: translateX(-50%);
    width: 3px;   /* thin straight line */
    height: 100%;
  }
  .obj-journey-body.is-mobile .obj-step {
    position: relative;
    top: auto !important;
    left: auto !important;
    right: auto !important;
    width: 100%;
    flex-direction: row !important;
    text-align: left !important;
    margin-bottom: 48px;
    opacity: 0;
    transform: translateX(-16px);
  }
  .obj-journey-body.is-mobile .obj-step.is-visible {
    opacity: 1;
    transform: translateX(0);
  }
  .obj-journey-body.is-mobile .obj-step-text {
    background: #ffffff;
    border: 1px solid rgba(226, 232, 240, 0.9);
    border-radius: 16px;
    padding: 18px 20px;
    box-shadow: 0 4px 16px rgba(15, 23, 42, 0.04);
    text-align: left !important;
  }
  .obj-node-circle {
    width: 70px;
    height: 70px;
  }
  .obj-node-num { font-size: 1.3rem; }
  .obj-step-title { font-size: 1.05rem; }
}

@media (max-width: 480px) {
  .obj-node-circle { width: 58px; height: 58px; }
  .obj-node-num { font-size: 1.1rem; }
  .obj-step-title { font-size: 0.975rem; }
  .obj-step-desc { font-size: 0.8rem; }
}
