/* journey.css — the 3D-journey roadmap page (v2.37.0).
 * Base tokens come from style.css; this file owns everything jr-*.
 * The page's identity color is the journey PURPLE (a new station color
 * next to the orange/teal/green of the three products) used ONLY for the
 * road, rail and phase numbers — CTAs keep the site orange. */

:root {
  --jr-road: #7A4FBF;
  --jr-road-soft: #F3EDFB;
  --jr-road-soft-2: #E4D8F5;
  --jr-done: #1B9E4E;
}
@media (prefers-color-scheme: dark) {
  :root {
    --jr-road: #A98BDD;
    --jr-road-soft: #2A2138;
    --jr-road-soft-2: #3D2F52;
    --jr-done: #27B95F;
  }
}

.jr-main { max-width: 1080px; margin: 0 auto; padding: 2.5rem 20px 4rem; }

/* local copies of landing-only helpers (journey.html loads style.css only) */
.jr-main .eyebrow {
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--jr-road);
  margin: 0 0 0.6rem;
}
.btn-hero {
  display: inline-block;
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 600;
  color: #fff;
  background: var(--accent);
  padding: 15px 26px;
  border-radius: 13px;
  text-decoration: none;
  box-shadow: 0 10px 24px rgba(239, 78, 35, 0.28);
  transition: background 0.18s ease, transform 0.18s ease;
}
.btn-hero:hover { background: var(--accent-strong); color: #fff; transform: translateY(-1px); }
@media (prefers-color-scheme: dark) {
  .btn-hero { background: #EF4E23; }
  .btn-hero:hover { background: #C23D18; }
}

/* ============================== hero ============================== */
.jr-hero { text-align: center; margin-bottom: 1rem; }
.jr-hero h1 {
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, 3rem);
  margin: 0 0 0.75rem;
}
.jr-sub {
  max-width: 620px;
  margin: 0 auto 1.5rem;
  color: var(--text-muted);
  line-height: 1.6;
}
.jr-road { max-width: 860px; margin: 0 auto; }
.jr-road svg { width: 100%; height: auto; display: block; }
.jr-road-hint { font-size: 0.8rem; color: var(--text-muted); margin-top: 0.35rem; }

/* road SVG internals (journey.js builds it) */
.jr-road .road-base { stroke: var(--jr-road-soft-2); }
.jr-road .road-fill  { stroke: var(--jr-road); transition: stroke-dashoffset 0.9s ease; }
.jr-road .road-station circle { fill: var(--card-bg, #fff); stroke: var(--jr-road-soft-2); stroke-width: 2.5; transition: stroke 0.3s ease, fill 0.3s ease; cursor: pointer; }
.jr-road .road-station text { font: 700 13px var(--font-display, sans-serif); fill: var(--text-muted); cursor: pointer; }
.jr-road .road-station.is-done circle { stroke: var(--jr-done); fill: var(--jr-done); }
.jr-road .road-station.is-done text { fill: #fff; }
.jr-road .road-station:hover circle { stroke: var(--jr-road); }
.jr-road .road-nozzle { fill: var(--jr-road); transition: transform 0.9s ease; }
@media (prefers-reduced-motion: reduce) {
  .jr-road .road-fill, .jr-road .road-nozzle { transition: none; }
}

/* ============================== rail ============================== */
/* Wide screens: fixed right rail (same recipe as the guide tracker). The
 * article makes room so nothing overlaps. */
.jr-rail { display: none; }
@media (min-width: 1240px) {
  .jr-rail {
    display: block;
    position: fixed;
    top: 110px;
    right: max(16px, calc((100vw - 1080px) / 2 - 250px));
    width: 225px;
    background: var(--card-bg, var(--bg));
    border: 1px solid var(--border);
    border-radius: 14px;
    padding: 0.9rem 1rem;
    z-index: 30;
    box-shadow: 0 6px 22px rgba(0, 0, 0, 0.06);
  }
  body.jr-wide .jr-article, body.jr-wide .jr-hero { padding-right: 0; }
}
.jr-rail-title {
  font: 700 0.72rem var(--font-display, sans-serif);
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--text-muted);
  margin: 0 0 0.55rem;
}
.jr-rail-row {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.32rem 0;
  border: 0;
  background: none;
  width: 100%;
  text-align: left;
  cursor: pointer;
  font-size: 0.86rem;
  color: var(--ink);
  border-radius: 8px;
}
.jr-rail-row:hover { background: var(--jr-road-soft); }
.jr-rail-dot {
  flex: 0 0 auto;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 2px solid var(--border-strong);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font: 700 0.62rem var(--font-display, sans-serif);
  color: var(--text-muted);
  transition: background 0.25s ease, border-color 0.25s ease;
}
.jr-rail-row.is-done .jr-rail-dot { background: var(--jr-done); border-color: var(--jr-done); color: #fff; }
.jr-rail-row.is-active { background: var(--jr-road-soft); }
.jr-rail-row.is-active .jr-rail-dot { border-color: var(--jr-road); color: var(--jr-road); }
.jr-rail-row.is-active.is-done .jr-rail-dot { color: #fff; }
.jr-rail-bar { height: 6px; border-radius: 3px; background: var(--jr-road-soft-2); margin-top: 0.6rem; overflow: hidden; }
.jr-rail-bar span { display: block; height: 100%; width: 0; background: var(--jr-done); border-radius: 3px; transition: width 0.5s ease; }
.jr-rail-pct { font-size: 0.72rem; color: var(--text-muted); margin-top: 0.3rem; text-align: right; }

/* Narrow screens: sticky chip bar on top */
@media (max-width: 1239.98px) {
  .jr-rail {
    display: flex;
    gap: 0.4rem;
    position: sticky;
    top: 0;
    z-index: 30;
    background: var(--bg);
    padding: 0.55rem 0;
    overflow-x: auto;
    scrollbar-width: none;
    border-bottom: 1px solid var(--border);
    margin-bottom: 1rem;
  }
  .jr-rail::-webkit-scrollbar { display: none; }
  .jr-rail-title, .jr-rail-bar, .jr-rail-pct { display: none; }
  .jr-rail-row {
    flex: 0 0 auto;
    width: auto;
    border: 1px solid var(--border);
    border-radius: 999px;
    padding: 0.3rem 0.7rem 0.3rem 0.4rem;
    background: var(--card-bg, var(--bg));
    font-size: 0.8rem;
    white-space: nowrap;
  }
  .jr-rail-row.is-active { border-color: var(--jr-road); }
}

/* ============================= phases ============================= */
.jr-article { max-width: 760px; margin: 0 auto; }
@media (min-width: 1240px) {
  .jr-article { margin-right: 285px; }
  .jr-hero { max-width: 760px; margin-left: auto; margin-right: 285px; }
}
.jr-phase { margin: 3.2rem 0; scroll-margin-top: 90px; }
.jr-phase-head { display: flex; gap: 1rem; align-items: flex-start; margin-bottom: 1.2rem; }
.jr-phase-num {
  flex: 0 0 auto;
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: var(--jr-road-soft);
  border: 1px solid var(--jr-road-soft-2);
  color: var(--jr-road);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font: 700 1.25rem var(--font-display, sans-serif);
}
.jr-phase.is-done .jr-phase-num { background: var(--jr-done); border-color: var(--jr-done); color: #fff; }
.jr-phase h2 { margin: 0.2rem 0 0.4rem; font-family: var(--font-display); font-size: 1.55rem; }
.jr-phase-sub { margin: 0; color: var(--text-muted); line-height: 1.55; }

.jr-fold { margin-top: 1.1rem; border: 1px solid var(--border); border-radius: 12px; padding: 0.75rem 1rem; }
.jr-fold summary { cursor: pointer; font-weight: 600; }
.jr-fold p { color: var(--text-muted); line-height: 1.55; margin: 0.6rem 0 0; }

/* ========================== checklists ========================== */
.jr-check { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.6rem; }
.jr-check li {
  position: relative;
  padding: 0.85rem 1rem 0.85rem 3rem;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--card-bg, var(--bg));
  line-height: 1.5;
  cursor: pointer;
  transition: border-color 0.2s ease, background 0.2s ease;
}
.jr-check li:hover { border-color: var(--jr-road-soft-2); }
.jr-check li::before {
  content: "";
  position: absolute;
  left: 0.95rem;
  top: 0.95rem;
  width: 22px;
  height: 22px;
  border-radius: 7px;
  border: 2px solid var(--border-strong);
  background: var(--bg);
  transition: background 0.2s ease, border-color 0.2s ease;
}
.jr-check li.is-checked { border-color: var(--jr-done); background: color-mix(in srgb, var(--jr-done) 6%, var(--bg)); }
.jr-check li.is-checked::before {
  background: var(--jr-done);
  border-color: var(--jr-done);
  background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="white" stroke-width="3.4" stroke-linecap="round" stroke-linejoin="round"><path d="M20 6 9 17l-5-5"/></svg>');
  background-size: 14px;
  background-position: center;
  background-repeat: no-repeat;
}
.jr-check li.is-checked strong { text-decoration: line-through; text-decoration-thickness: 1.5px; opacity: 0.75; }
.jr-check strong { display: block; margin-bottom: 0.15rem; }
.jr-check span { color: var(--text-muted); font-size: 0.92rem; }
.jr-check a { color: var(--accent); }

/* ========================== chooser (phase 1) ========================== */
.jr-chooser { display: grid; gap: 1.1rem; }
.jr-q { border: 1px solid var(--border); border-radius: 14px; padding: 1rem 1.1rem; background: var(--card-bg, var(--bg)); }
.jr-q-label { font-weight: 700; margin: 0 0 0.6rem; display: flex; gap: 0.5rem; align-items: baseline; }
.jr-q-num { color: var(--jr-road); font-family: var(--font-display); }
.jr-opts { display: flex; flex-wrap: wrap; gap: 0.45rem; }
.jr-opt {
  border: 1.5px solid var(--border-strong);
  background: var(--bg);
  color: var(--ink);
  border-radius: 999px;
  padding: 0.45rem 0.95rem;
  font-size: 0.9rem;
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease, transform 0.15s ease;
}
.jr-opt:hover { border-color: var(--jr-road); transform: translateY(-1px); }
.jr-opt.is-picked { border-color: var(--jr-road); background: var(--jr-road-soft); color: var(--jr-road); font-weight: 600; }

.jr-chooser-result { margin-top: 1.4rem; }
.jr-result-head { font-family: var(--font-display); font-size: 1.15rem; margin: 0 0 0.8rem; }
.jr-recs { display: grid; gap: 0.8rem; }
@media (min-width: 720px) { .jr-recs { grid-template-columns: repeat(3, 1fr); } }
.jr-rec {
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 1rem;
  background: var(--card-bg, var(--bg));
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.jr-rec.is-top { border-color: var(--jr-road); box-shadow: 0 8px 22px rgba(122, 79, 191, 0.14); }
.jr-rec-badge {
  align-self: flex-start;
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--jr-road);
  background: var(--jr-road-soft);
  border-radius: 999px;
  padding: 0.18rem 0.6rem;
}
.jr-rec h4 { margin: 0; font-size: 1.02rem; font-family: var(--font-display); }
.jr-rec-price { font-size: 0.78rem; color: var(--text-muted); }
.jr-rec ul { margin: 0; padding-left: 1.1rem; font-size: 0.85rem; color: var(--text-muted); display: grid; gap: 0.25rem; }
.jr-rec-link { font-size: 0.85rem; color: var(--accent); text-decoration: none; margin-top: auto; }
.jr-rec-link:hover { text-decoration: underline; }
.jr-res-note {
  margin: 0.9rem 0 0;
  padding: 0.7rem 0.95rem;
  border-radius: 11px;
  border: 1px solid var(--accent-soft-2);
  background: var(--accent-soft);
  font-size: 0.86rem;
  line-height: 1.5;
}
.jr-redo { margin-top: 0.9rem; background: none; border: 0; color: var(--text-muted); font-size: 0.85rem; cursor: pointer; text-decoration: underline; }
.jr-redo:hover { color: var(--ink); }

/* ========================= products (phase 4) ========================= */
.jr-products { display: grid; gap: 0.9rem; }
@media (min-width: 720px) { .jr-products { grid-template-columns: repeat(3, 1fr); } }
.jr-product {
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 1.1rem;
  background: var(--card-bg, var(--bg));
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}
.jr-product h3 { margin: 0; font-size: 1.05rem; font-family: var(--font-display); }
.jr-product p { margin: 0; font-size: 0.88rem; color: var(--text-muted); line-height: 1.5; flex: 1; }
.jr-product-ico {
  width: 46px;
  height: 46px;
  border-radius: 13px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.jr-ico-diag { background: var(--accent-soft); color: var(--accent); }
.jr-ico-cal  { background: #E5EDFC; color: #1E63D6; }
.jr-ico-fil  { background: #E8F6EC; color: #1B9E4E; }
@media (prefers-color-scheme: dark) {
  .jr-ico-cal { background: #1B2A45; color: #5B9BFF; }
  .jr-ico-fil { background: #16301F; color: #27B95F; }
}
.jr-product-link { font-size: 0.88rem; color: var(--accent); text-decoration: none; font-weight: 600; }
.jr-product-link:hover { text-decoration: underline; }
.jr-product-done { display: flex; align-items: center; gap: 0.45rem; font-size: 0.85rem; color: var(--text-muted); cursor: pointer; border-top: 1px dashed var(--border); padding-top: 0.6rem; }
.jr-product-done input { width: 17px; height: 17px; accent-color: var(--jr-done); cursor: pointer; }
.jr-product.is-tried { border-color: var(--jr-done); }

/* ========================= maintenance (phase 5) ========================= */
.jr-cycles { display: grid; gap: 0.8rem; margin-bottom: 1.4rem; }
@media (min-width: 720px) { .jr-cycles { grid-template-columns: repeat(3, 1fr); } }
.jr-cycle { border: 1px solid var(--border); border-radius: 14px; padding: 1rem; background: var(--card-bg, var(--bg)); }
.jr-cycle-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  height: 30px;
  padding: 0 0.5rem;
  border-radius: 999px;
  background: var(--jr-road-soft);
  color: var(--jr-road);
  font: 700 0.9rem var(--font-display, sans-serif);
  margin-bottom: 0.5rem;
}
.jr-cycle-badge::after { content: " d"; font-weight: 600; font-size: 0.75rem; margin-left: 1px; }
.jr-cycle h3 { margin: 0 0 0.35rem; font-size: 0.98rem; }
.jr-cycle p { margin: 0; font-size: 0.85rem; color: var(--text-muted); line-height: 1.5; }

.jr-maint {
  border: 1.5px solid var(--jr-road-soft-2);
  border-radius: 16px;
  padding: 1.3rem;
  background: linear-gradient(180deg, var(--jr-road-soft), transparent 70%);
}
.jr-maint-cta { text-align: center; padding: 0.6rem 0; }
.jr-maint-cta h3 { margin: 0 0 0.4rem; font-family: var(--font-display); }
.jr-maint-cta p { color: var(--text-muted); margin: 0 0 1rem; }
.jr-maint h3 { font-size: 1.05rem; }

.jr-plist { list-style: none; margin: 0 0 1.1rem; padding: 0; display: grid; gap: 0.6rem; }
.jr-pcard {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem 1rem;
  align-items: center;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--card-bg, var(--bg));
  padding: 0.8rem 1rem;
}
.jr-pcard-name { font-weight: 700; }
.jr-pcard-name small { display: block; font-weight: 400; color: var(--text-muted); }
.jr-pcard-due { font-size: 0.8rem; color: var(--text-muted); margin-left: auto; text-align: right; }
.jr-pcard-due b { color: var(--jr-road); font-variant-numeric: tabular-nums; }
.jr-pcard-actions { display: flex; gap: 0.5rem; align-items: center; }
.jr-pcard button { background: none; border: 1px solid var(--border-strong); border-radius: 8px; padding: 0.25rem 0.6rem; font-size: 0.78rem; cursor: pointer; color: var(--text-muted); }
.jr-pcard button:hover { border-color: var(--accent); color: var(--accent); }
.jr-pcard .jr-remind-toggle { display: flex; align-items: center; gap: 0.35rem; font-size: 0.78rem; color: var(--text-muted); cursor: pointer; }
.jr-pcard .jr-remind-toggle input { accent-color: var(--jr-done); }

.jr-pform { display: grid; gap: 0.7rem; grid-template-columns: repeat(2, 1fr); }
@media (max-width: 640px) { .jr-pform { grid-template-columns: 1fr; } }
.jr-pform label { display: grid; gap: 0.25rem; font-size: 0.82rem; font-weight: 600; }
.jr-pform input[type="text"], .jr-pform input[type="date"], .jr-pform select {
  border: 1.5px solid var(--border-strong);
  border-radius: 10px;
  padding: 0.55rem 0.7rem;
  font: inherit;
  background: var(--bg);
  color: var(--ink);
  width: 100%;
}
.jr-pform input:focus, .jr-pform select:focus { outline: 2px solid var(--jr-road); outline-offset: 1px; }
.jr-pform-row2 { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 1rem; align-items: center; }
.jr-pform-row2 label { display: flex; align-items: center; gap: 0.4rem; font-weight: 400; font-size: 0.85rem; color: var(--text-muted); cursor: pointer; }
.jr-pform-row2 input[type="checkbox"] { width: 17px; height: 17px; accent-color: var(--jr-done); }
.jr-pform-submit {
  grid-column: 1 / -1;
  justify-self: start;
  background: var(--jr-road);
  color: #fff;
  border: 0;
  border-radius: 11px;
  padding: 0.7rem 1.4rem;
  font: 600 0.95rem var(--font-display, sans-serif);
  cursor: pointer;
  transition: transform 0.15s ease, opacity 0.15s ease;
}
.jr-pform-submit:hover { transform: translateY(-1px); opacity: 0.92; }
.jr-pform-submit[disabled] { opacity: 0.5; cursor: default; transform: none; }
.jr-maint-note { font-size: 0.78rem; color: var(--text-muted); margin: 0.8rem 0 0; }
.jr-maint-err { color: #C0392B; font-size: 0.85rem; margin: 0.5rem 0 0; }
.jr-maint-ok { color: var(--jr-done); font-size: 0.85rem; margin: 0.5rem 0 0; }

/* ========================= milestones (phase 6) ========================= */
.jr-miles { list-style: none; margin: 0; padding: 0 0 0 34px; position: relative; counter-reset: none; }
.jr-miles::before {
  content: "";
  position: absolute;
  left: 11px;
  top: 8px;
  bottom: 8px;
  width: 4px;
  border-radius: 2px;
  background: var(--jr-road-soft-2);
}
.jr-miles li { position: relative; padding: 0 0 1.6rem 0.4rem; cursor: pointer; }
.jr-miles li::before {
  content: "";
  position: absolute;
  left: -30.5px;
  top: 4px;
  width: 17px;
  height: 17px;
  border-radius: 50%;
  border: 3px solid var(--jr-road-soft-2);
  background: var(--bg);
  transition: background 0.25s ease, border-color 0.25s ease;
  z-index: 1;
}
.jr-miles li.is-reached::before { background: var(--jr-done); border-color: var(--jr-done); }
.jr-miles li.is-here::before { background: var(--jr-road); border-color: var(--jr-road); box-shadow: 0 0 0 5px var(--jr-road-soft); }
.jr-miles h3 { margin: 0 0 0.25rem; font-size: 1.02rem; display: flex; gap: 0.6rem; align-items: baseline; flex-wrap: wrap; }
.jr-mile-h {
  font-family: var(--font-display);
  color: var(--jr-road);
  font-variant-numeric: tabular-nums;
  min-width: 3.2em;
}
.jr-miles li.is-reached .jr-mile-h { color: var(--jr-done); }
.jr-miles p { margin: 0; color: var(--text-muted); font-size: 0.9rem; line-height: 1.55; max-width: 620px; }
.jr-miles a { color: var(--accent); }
.jr-mile-tag {
  font-size: 0.66rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-radius: 999px;
  padding: 0.15rem 0.55rem;
  background: var(--jr-road-soft);
  color: var(--jr-road);
  display: none;
}
.jr-miles li.is-here .jr-mile-tag { display: inline-block; }

/* ============================ bottom CTA ============================ */
.jr-bottom {
  text-align: center;
  margin-top: 3.5rem;
  border-top: 1px solid var(--border);
  padding-top: 2.5rem;
}
.jr-bottom h2 { font-family: var(--font-display); margin: 0 0 0.5rem; }
.jr-bottom p { color: var(--text-muted); max-width: 560px; margin: 0 auto 1.2rem; }

/* confetti canvas (journey.js) */
.jr-confetti { position: fixed; inset: 0; pointer-events: none; z-index: 999; }
