/* ==========================================================
   Our journey page — Kalpokotha
   ========================================================== */
:root {
  --text: #d4d4d8;
  --bright: #e4e4e7;
  --muted: #a1a1aa;
  --border: #26262c;
  --accent: #6366f1;
  --pad-x: clamp(20px, 7vw, 100px);
}
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
html, body {
  background: #000;
  color: var(--text);
  font-family: 'Outfit', system-ui, sans-serif;
  overflow-x: hidden;
}

#sky { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 0; }
.page { position: relative; z-index: 2; }

.eyebrow { color: var(--accent); font-size: 12px; letter-spacing: .18em; text-transform: uppercase; margin-bottom: 18px; }
.eyebrow.center { text-align: center; margin-bottom: 10px; }

/* ---------- 1. Intro ---------- */
.intro {
  min-height: 82vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 80px var(--pad-x) 40px;
  text-align: center;
}
.intro h1 {
  max-width: 900px;
  color: var(--bright);
  font-size: clamp(28px, 4.4vw, 58px);
  font-weight: 400;
  line-height: 1.18;
  letter-spacing: -.02em;
  animation: rise 1.2s .1s both;
}
.intro .eyebrow { animation: rise 1s both; }
@keyframes rise { from { opacity: 0; transform: translateY(22px); } to { opacity: 1; transform: none; } }

/* ---------- 2. Cartoon rows ---------- */
.toons { padding: 20px 0 clamp(70px, 9vw, 120px); }
.row {
  overflow: hidden;
  margin-bottom: 18px;
  -webkit-mask-image: linear-gradient(to right, transparent, #000 7%, #000 93%, transparent);
          mask-image: linear-gradient(to right, transparent, #000 7%, #000 93%, transparent);
}
.lane {
  display: flex;
  gap: 14px;
  width: max-content;
  padding-right: 14px;
  animation: var(--dir) var(--dur, 60s) linear infinite;
}
.lane.rtl { --dir: toLeft; }
.lane.ltr { --dir: toRight; }
.row:hover .lane { animation-play-state: paused; }
@keyframes toLeft  { from { transform: translateX(0); }    to { transform: translateX(-50%); } }
@keyframes toRight { from { transform: translateX(-50%); } to { transform: translateX(0); } }

.pill {
  flex: 0 0 auto;
  padding: 14px 26px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: rgba(14, 14, 18, .8);
  color: var(--bright);
  font-size: 17px;
  font-weight: 300;
  white-space: nowrap;
  transition: border-color .3s, color .3s;
}
.pill:hover { border-color: #3b3b8f; color: #fff; }

/* ---------- 3. Timeline ---------- */
.story { padding: 0 var(--pad-x); }
.story h2 {
  margin-bottom: clamp(40px, 6vw, 80px);
  text-align: center;
  color: var(--text);
  font-size: clamp(28px, 3.6vw, 46px);
  font-weight: 500;
  letter-spacing: -.02em;
}
.timeline { position: relative; }
.timeline::before {                      /* centre line */
  content: "";
  position: absolute;
  top: 0; bottom: 0; left: 50%;
  width: 1px;
  transform: translateX(-50%);
  background: linear-gradient(to bottom, transparent, #4b4b9a 6%, #4b4b9a 94%, transparent);
}
.item { position: relative; width: 50%; padding-bottom: clamp(36px, 6vw, 70px); }
.item:last-child { padding-bottom: 0; }
.item::after {                           /* dot on the line */
  content: "";
  position: absolute;
  top: 26px;
  width: 11px; height: 11px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 5px rgba(99, 102, 241, .18);
}
.item.right { margin-left: 50%; padding-left: clamp(22px, 4vw, 56px); }
.item.right::after { left: -6px; }
.item.left  { padding-right: clamp(22px, 4vw, 56px); }
.item.left::after  { right: -5px; }

.card {
  padding: 24px 26px;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: rgba(14, 14, 18, .78);
  -webkit-backdrop-filter: blur(8px);
          backdrop-filter: blur(8px);
  transition: border-color .3s;
}
.card:hover { border-color: #3b3b8f; }
.card .year { color: #a5b4fc; font-size: 28px; font-weight: 500; letter-spacing: -.01em; margin-bottom: 10px; }
.card p { color: var(--muted); font-size: 16px; font-weight: 300; line-height: 1.55; }

/* slide in from its own side */
.item.reveal { opacity: 0; transition: opacity .8s ease, transform .8s ease; }
.item.right.reveal { transform: translateX(50px); }
.item.left.reveal  { transform: translateX(-50px); }
.item.reveal.show  { opacity: 1; transform: none; }

/* ---------- 4. Back button ---------- */
.back-wrap { padding: clamp(70px, 9vw, 110px) 0; text-align: center; }
.back {
  display: inline-block;
  padding: 14px 34px;
  border: 1px solid #2a2a30;
  border-radius: 14px;
  background: rgba(24, 24, 28, .8);
  color: var(--bright);
  font-size: 16px;
  text-decoration: none;
  transition: border-color .3s, background .3s, transform .3s;
}
.back:hover { border-color: #3b3b8f; background: rgba(40, 40, 80, .5); transform: translateY(-2px); }

/* ---------- Mobile: line on the left, all cards on the right ---------- */
/* ---------- Mobile: same centre-line layout, just smaller ---------- */
@media (max-width: 700px) {
  .item { padding-bottom: 26px; }
  .item.right { padding-left: 14px; }
  .item.left  { padding-right: 14px; }

  .item::after {
    top: 18px;
    width: 9px; height: 9px;
    box-shadow: 0 0 0 4px rgba(99, 102, 241, .18);
  }
  .item.right::after { left: -4.5px; }
  .item.left::after  { right: -4.5px; }

  .item.right.reveal { transform: translateX(24px); }
  .item.left.reveal  { transform: translateX(-24px); }

  .card { padding: 12px; border-radius: 12px; }
  .card .year { font-size: 18px; margin-bottom: 6px; }
  .card p { font-size: 12.5px; line-height: 1.45; }

  .pill { font-size: 15px; padding: 12px 20px; }
}
