/* ACCESS Learning Journey — the journey map (/journey/map) and the mission overview (/journey/mNN).
   Unit palette variables (--jr-unit, --jr-ink, --jr-soft, --jr-glow) and the step pips are defined in journey.css. */

/* ── /journey/map ──────────────────────────────────────────────────────── */
.jr-map-head {
  display: grid;
  gap: var(--s-4);
}
.jr-map-head h1 {
  margin: 0 0 var(--s-2);
}
.jr-map-head .lead {
  margin: 0;
}
.jr-map-tools {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-2) var(--s-3);
}
.jr-units {
  display: grid;
  gap: var(--s-7);
  margin: 0;
  padding: 0;
  list-style: none;
}
.jr-unit {
  position: relative;
  display: grid;
  gap: var(--s-5);
  padding: var(--s-5) var(--s-4) var(--s-5);
  border: 1px solid color-mix(in srgb, var(--jr-unit) 20%, var(--line));
  border-radius: var(--r-xl);
  background:
    radial-gradient(
      70% 50% at 100% 0%,
      color-mix(in srgb, var(--jr-unit) 9%, transparent),
      transparent 70%
    ),
    var(--grain), color-mix(in srgb, var(--jr-soft) 55%, var(--surface));
  box-shadow: var(--edge-light), var(--shadow);
  scroll-margin-top: 5rem;
}
.jr-unit::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 0.5rem;
  border-radius: var(--r-xl) var(--r-xl) 0 0;
  background: var(--jr-unit);
}
.jr-unit + .jr-unit::after {
  /* the trail continues into the next unit */
  content: "";
  position: absolute;
  top: calc(-1 * var(--s-7));
  left: 50%;
  height: var(--s-7);
  border-left: 3px dotted color-mix(in srgb, var(--jr-unit) 55%, transparent);
}
.jr-unit-head {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: var(--s-3) var(--s-4);
  align-items: center;
}
.jr-unit-head .jr-unit-n {
  width: 3.25rem;
  height: 3.25rem;
  font-size: 1.7rem;
}
.jr-unit-copy h2 {
  margin: 0;
  font-size: clamp(1.3rem, 1.1rem + 0.9vw, 1.75rem);
}
.jr-unit-copy .fine {
  margin: 0.1rem 0 0;
}
.jr-unit-prog {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem var(--s-3);
  grid-column: 1 / -1;
  margin: 0;
  color: var(--jr-ink);
}
.jr-unit-prog .fine {
  color: var(--ink-2);
}
.jr-trail {
  display: grid;
  gap: var(--s-4);
  margin: 0;
  padding: 0;
  list-style: none;
}
.jr-node {
  position: relative;
  padding-left: 2.1rem;
  scroll-margin-top: 5rem;
}
.jr-node::before {
  /* the path on phones: a dashed spine with a stop at each mission */
  content: "";
  position: absolute;
  inset: 1.4rem auto calc(-1 * var(--s-4)) 0.6rem;
  border-left: 3px dashed color-mix(in srgb, var(--jr-unit) 50%, transparent);
}
.jr-node:last-child::before {
  display: none;
}
.jr-node::after {
  content: "";
  position: absolute;
  top: 1rem;
  left: 0.1rem;
  width: 1.2rem;
  height: 1.2rem;
  border-radius: 50%;
  background: var(--jr-unit);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--jr-soft) 55%, var(--surface));
}
.jr-node[data-status="in-progress"]::after {
  background: linear-gradient(90deg, var(--jr-unit) 50%, var(--surface) 50%);
  border: 2px solid var(--jr-unit);
}
.jr-node[data-status="not-started"]::after {
  background: var(--surface);
  border: 2px dashed var(--jr-unit);
}
.jr-card {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 0.55rem;
  align-content: start;
  padding: var(--s-4);
  border: 1px solid var(--line);
  border-top: 4px solid var(--jr-unit);
  border-radius: var(--jr-radius);
  background: var(--grain), var(--jr-card);
  box-shadow: var(--edge-light), var(--shadow);
}
.jr-node.is-current > .jr-card {
  box-shadow:
    0 0 0 3px var(--jr-unit),
    var(--shadow-lift);
}
.jr-card-top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-2);
}
.jr-num {
  display: grid;
  place-items: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  background: var(--jr-unit);
  color: #fff;
  font: 600 1.35rem/1 var(--font-display);
  box-shadow:
    0 0 0 3px var(--surface),
    0 0 0 4.5px color-mix(in srgb, var(--jr-unit) 50%, transparent);
}
.jr-page[data-band="3-5"] .jr-num {
  width: 3rem;
  height: 3rem;
  font-size: 1.6rem;
}
.jr-page[data-band="3-5"] .jr-env {
  padding: 0.3rem 0.85rem 0.3rem 0.4rem;
  font-size: 0.9375rem;
}
.jr-page[data-band="3-5"] .jr-env-glyph {
  box-sizing: content-box;
  width: 1.4rem;
  height: 1.4rem;
  padding: 0.2rem;
  border-radius: 50%;
  background: #fff;
}
.jr-kick {
  margin: 0.15rem 0 0;
  color: var(--jr-ink);
  font-size: 0.875rem;
  font-weight: 700;
}
.jr-card h3 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 600;
  line-height: 1.2;
}
.jr-page[data-band="6-8"] .jr-card h3 {
  font-size: 1.15rem;
  letter-spacing: -0.01em;
}
.jr-card h3 a {
  color: var(--ink);
  text-decoration-color: color-mix(in srgb, var(--jr-unit) 55%, transparent);
}
.jr-card h3 a:hover {
  color: var(--jr-ink);
}
.jr-marks {
  display: grid;
  gap: 0.15rem;
  margin: 0;
  padding: 0;
  list-style: none;
  color: var(--ink-2);
  font-size: 0.875rem;
}
.jr-mark {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.2rem 0.4rem;
  min-height: 1.75rem;
}
.jr-mark a {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  min-height: 1.75rem;
  color: var(--jr-ink);
  font-weight: 700;
}
.jr-spiral {
  flex: none;
  width: 1.1rem;
  height: 1.1rem;
  color: var(--ink-3);
}
.jr-mark .ico {
  width: 1rem;
  height: 1rem;
}
.jr-mark.is-review a,
.jr-mark.is-evidence a {
  padding: 0.1rem 0.6rem;
  border: 1.5px solid color-mix(in srgb, var(--jr-unit) 55%, transparent);
  border-radius: 999px;
  background: var(--jr-soft);
}

/* ── /journey/mNN ──────────────────────────────────────────────────────── */
.jr-ov-hero {
  position: relative;
  display: grid;
  gap: var(--s-4);
  padding: clamp(1.25rem, 3.2vw, 2.5rem);
  border-radius: var(--r-xl);
  color: #fff;
  background:
    radial-gradient(
      60% 90% at 100% 0%,
      color-mix(in srgb, var(--jr-glow) 28%, transparent),
      transparent 70%
    ),
    var(--grain),
    linear-gradient(150deg, var(--jr-unit), color-mix(in srgb, var(--jr-unit) 52%, var(--mi-950)));
  box-shadow: var(--shadow-float), var(--edge-light-dark);
}
.jr-ov-copy {
  display: grid;
  gap: var(--s-2);
  min-width: 0;
}
.jr-ov-hero h1,
.jr-ov-hero .eyebrow,
.jr-ov-hero .lead,
.jr-ov-hero .jr-status,
.jr-ov-hero .jr-status strong,
.jr-ov-hero .jr-status .ico,
.jr-ov-hero .fine {
  color: #fff;
}
.jr-ov-hero .lead {
  margin: 0;
}
.jr-ov-hero h1 {
  margin: 0;
  font-size: clamp(1.9rem, 1.3rem + 2.5vw, 3rem);
}
.jr-ov-n {
  display: block;
  margin-bottom: 0.15em;
  font: 700 0.9375rem/1.2 var(--font);
  letter-spacing: 0;
}
.jr-goal {
  max-width: 56ch;
  margin: 0;
  padding: var(--s-3) var(--s-4);
  border-inline-start: 4px solid var(--jr-glow);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  background: rgb(255 255 255 / 12%);
  font-family: var(--font-display);
  font-size: 1.1rem;
}
.jr-goal strong {
  display: block;
  margin-bottom: 0.1rem;
  font: 700 0.875rem var(--font);
}
.jr-ov-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-2) var(--s-4);
  margin: 0;
}
.jr-ov-hero .jr-env {
  background: rgb(255 255 255 / 16%);
  color: #fff;
}
.jr-ov-hero .eyebrow .jr-klu {
  color: #fff;
}
.jr-ov-hero .jr-cta {
  margin-top: var(--s-2);
}
.jr-ov-hero .jr-cta .btn-primary {
  background: linear-gradient(180deg, var(--ivory), #efe6da);
  border-color: transparent;
  color: var(--mi-950);
}
.jr-ov-hero :focus-visible {
  outline-color: #fff;
  box-shadow: 0 0 0 6px rgb(8 14 37 / 85%);
}
.jr-ov-art {
  display: none;
}
.jr-steps {
  display: grid;
  gap: var(--s-3);
  margin: 0;
  padding: 0;
  list-style: none;
}
.jr-step-card {
  position: relative;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: var(--s-1) var(--s-3);
  align-items: start;
  height: 100%;
  min-height: 2.75rem;
  padding: var(--s-4);
  border: 1px solid var(--line);
  border-radius: var(--jr-radius);
  background: var(--jr-card);
  box-shadow: var(--edge-light), var(--shadow);
  color: var(--ink);
  text-decoration: none;
  transition:
    box-shadow var(--dur-2) var(--ease-out),
    border-color var(--dur-2) var(--ease-out);
}
.jr-step-card:hover {
  border-color: var(--jr-unit);
  box-shadow: var(--edge-light), var(--shadow-lift);
}
.jr-step.is-here .jr-step-card {
  border-color: var(--jr-unit);
  box-shadow:
    0 0 0 3px var(--jr-unit),
    var(--shadow-lift);
}
.jr-step-n {
  display: grid;
  place-items: center;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 50%;
  background: var(--jr-soft);
  color: var(--jr-ink);
  font: 600 1.2rem/1 var(--font-display);
}
.jr-step.is-done-supported .jr-step-n,
.jr-step.is-done-independent .jr-step-n {
  background: var(--jr-unit);
  color: #fff;
}
.jr-step-body {
  display: grid;
  gap: 0.15rem;
}
.jr-step-body strong {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  color: var(--jr-ink);
  font-size: 1.1rem;
}
.jr-step-body .fine {
  margin: 0;
}
.jr-step-state {
  display: inline-flex;
  grid-column: 2;
  align-items: center;
  gap: 0.35rem;
  color: var(--ink-2);
  font-size: 0.9375rem;
  font-weight: 700;
}
.jr-step-state .ico {
  width: 1.05rem;
  height: 1.05rem;
  color: var(--jr-ink);
}
.jr-step-card .jr-here {
  grid-column: 2;
}
.jr-ov-grid {
  display: grid;
  gap: var(--s-4);
}
.jr-panel {
  padding: var(--s-4) var(--s-5);
  border: 1px solid var(--line);
  border-radius: var(--jr-radius);
  background: var(--jr-card);
  box-shadow: var(--edge-light), var(--shadow);
}
.jr-chips,
.jr-domains,
.jr-reviews {
  display: grid;
  gap: var(--s-2);
  margin: 0;
  padding: 0;
  list-style: none;
}
.jr-chips {
  display: flex;
  flex-wrap: wrap;
}
.jr-chip {
  padding: 0.3rem 0.8rem;
  border: 1.5px solid color-mix(in srgb, var(--jr-unit) 40%, transparent);
  border-radius: 999px;
  background: var(--jr-soft);
  color: var(--jr-ink);
  font-weight: 700;
}
.jr-domains li {
  display: grid;
  gap: 0.15rem;
}
.jr-domain {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  justify-self: start;
  padding: 0.15rem 0.7rem 0.15rem 0.5rem;
  border-radius: 999px;
  background: var(--room-soft);
  color: var(--room-ink);
  font-weight: 700;
}
.jr-reviews a {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 0 var(--s-2);
  min-height: 2.75rem;
  align-items: center;
  color: var(--ink);
}
.jr-reviews a > .ico {
  grid-row: span 2;
  width: 1.3rem;
  height: 1.3rem;
  color: var(--brand-ink);
}
.jr-reviews a > strong,
.jr-reviews a > .fine {
  grid-column: 2;
}
.jr-reviews a:not(:has(> .ico)) {
  grid-template-columns: minmax(0, 1fr);
}

/* ── wider screens: a winding trail ────────────────────────────────────── */
@media (min-width: 640px) {
  .jr-steps,
  .jr-ov-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .jr-unit-head {
    grid-template-columns: auto minmax(0, 1fr) auto;
  }
  .jr-unit-prog {
    grid-column: auto;
    justify-content: flex-end;
    text-align: end;
  }
}
@media (min-width: 900px) {
  .jr-unit {
    padding: var(--s-6);
  }
  .jr-trail {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: var(--s-6);
    align-items: start;
    padding-top: var(--s-3);
  }
  .jr-node {
    padding-left: 0;
    margin-top: var(--s-5);
  }
  .jr-node:nth-child(2) {
    margin-top: 0;
  }
  .jr-node::before,
  .jr-node::after {
    all: unset;
  }
  .jr-node:not(:last-child)::after {
    content: "";
    position: absolute;
    z-index: 0;
    top: -1.2rem;
    left: 62%;
    width: 85%;
    height: 1.7rem;
    border: 3px dashed color-mix(in srgb, var(--jr-unit) 55%, transparent);
    border-bottom: 0;
    border-radius: 999px 999px 0 0;
    background: none;
    pointer-events: none;
  }
  .jr-node:nth-child(2):not(:last-child)::after {
    top: auto;
    bottom: -1.2rem;
    border: 3px dashed color-mix(in srgb, var(--jr-unit) 55%, transparent);
    border-top: 0;
    border-radius: 0 0 999px 999px;
  }
  .jr-ov-hero {
    grid-template-columns: auto minmax(0, 1fr);
    align-items: center;
    gap: var(--s-6);
  }
  .jr-ov-art {
    display: grid;
    place-items: center;
    width: 8rem;
    height: 8rem;
    border: 2px solid rgb(255 255 255 / 40%);
    border-radius: 50%;
    background: rgb(255 255 255 / 12%);
    color: #fff;
  }
  .jr-ov-art .jr-env-glyph {
    width: 3.75rem;
    height: 3.75rem;
  }
  .jr-steps {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}
@media (max-width: 640px) {
  .jr-panel {
    padding: var(--s-4);
  }
}
@media (prefers-reduced-motion: reduce) {
  .jr-step-card {
    transition: none;
  }
}
@media (forced-colors: active) {
  .jr-card,
  .jr-step-card,
  .jr-chip {
    border: 2px solid CanvasText;
  }
  .jr-node.is-current > .jr-card,
  .jr-step.is-here .jr-step-card {
    outline: 3px solid Highlight;
  }
}
