/* The Journey of a Concrete Cube. Page-only styles, prefix cj-. The specimen record fills in with a small script
   (cubejourney.js); without it every row shows. Scroll motion is progressive enhancement, off for reduced motion. */

/* Hero: the eleven stops as a strip */
.cj-strip{list-style:none;padding:0;display:grid;grid-template-columns:repeat(11,minmax(0,1fr));margin-top:clamp(36px,5vw,64px);border-top:1px solid rgba(255,255,255,.3)}
.cj-strip li{position:relative}
.cj-strip li::before{content:"";position:absolute;top:-5px;left:0;width:9px;height:9px;border-radius:50%;background:var(--orange)}
.cj-strip a{display:block;padding:16px 10px 0 0;color:#fff;text-decoration:none}
.cj-strip b{display:block;color:var(--orange);font-size:13px;font-weight:600;font-variant-numeric:tabular-nums}
.cj-strip span{display:block;margin-top:4px;color:#e8edf6;font-size:13.5px;line-height:1.3}
.cj-strip a:hover span{color:#fff;text-decoration:underline}

/* Before the cube exists */
.cj-before{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:20px;margin-top:clamp(28px,4vw,48px)}
.cj-before li{display:flex;flex-direction:column;padding:26px 28px 24px;border:1px solid var(--line);border-radius:4px;background:#fff;transition:translate .3s var(--ease),box-shadow .3s var(--ease)}
.cj-before li:hover{translate:0 -4px;box-shadow:0 22px 44px -30px rgba(0,34,91,.45)}
.cj-before h3{font-size:19px;margin-bottom:8px}
.cj-before p{flex:1;color:var(--muted);font-size:15.5px;line-height:1.5}
.cj-before a{display:inline-flex;align-items:center;gap:6px;margin-top:18px;color:var(--navy);font-weight:600;text-decoration:none}
.cj-before a:hover{text-decoration:underline}
.cj-before .arrow{width:14px;height:14px;color:var(--orange)}

/* Journey layout: stops on the left, the specimen record pinned right */
.cj-layout{display:grid;grid-template-columns:minmax(0,1fr) 360px;gap:clamp(28px,4vw,56px);align-items:start}
.cj-lead{max-width:62ch;margin-top:14px;color:var(--muted)}

/* Stops: a timeline spine with numbered nodes */
.cj-stops{position:relative;margin-top:clamp(28px,4vw,48px);view-timeline:--cjj block}
.cj-stops::before,.cj-stops::after{content:"";position:absolute;left:27px;top:28px;bottom:28px;width:2px;background:#cdd5e3}
.cj-stops::after{display:none;background:var(--orange);transform-origin:top}
.cj-stop{position:relative;display:grid;grid-template-columns:56px minmax(0,1fr) minmax(0,260px);gap:clamp(16px,2.4vw,32px);align-items:start;padding-bottom:clamp(24px,3vw,40px);scroll-margin-top:100px}
.cj-stop:last-child{padding-bottom:0}
.cj-stop>b{position:relative;z-index:1;display:grid;place-items:center;width:56px;height:56px;border-radius:50%;background:var(--navy);color:#fff;font-size:17px;font-weight:600;font-variant-numeric:tabular-nums;box-shadow:0 0 0 6px var(--ground)}
.cj-stop>div{background:#fff;border:1px solid var(--line);border-radius:4px;padding:clamp(20px,2.4vw,32px);box-shadow:0 18px 40px -32px rgba(0,34,91,.45)}
.cj-where{display:flex;flex-wrap:wrap;align-items:baseline;justify-content:space-between;gap:4px 16px;margin-bottom:10px;font-size:13.5px}
.cj-where span{color:var(--muted);font-weight:600;letter-spacing:.01em}
.cj-where em{color:var(--orange);font-style:normal;font-weight:600;font-variant-numeric:tabular-nums}
.cj-stop h3{margin-bottom:8px}
.cj-story{color:var(--ink);font-size:16px;line-height:1.55}
.cj-checks{margin-top:18px;border-top:1px solid var(--line)}
.cj-checks li{display:flex;flex-wrap:wrap;align-items:flex-start;gap:4px 10px;padding:11px 0;border-bottom:1px solid var(--line);font-size:15.5px;line-height:1.45}
.cj-checks li>span{flex:1 1 0;min-width:0}
.cj-checks .tick{margin-top:2px}
.cj-record{display:flex;flex-wrap:wrap;align-items:baseline;gap:6px 10px;margin-top:16px;color:var(--navy);font-size:14.5px;font-weight:500}
.cj-record span{padding:3px 8px;border-radius:2px;background:var(--ground);color:var(--muted);font-size:12.5px;font-weight:600}
.cj-stop figure{margin:0;aspect-ratio:4/3;overflow:hidden;border-radius:4px;background:var(--line)}
.cj-stop img{width:100%;height:100%;object-fit:cover;transition:transform .6s var(--ease)}
.cj-stop:hover img{transform:scale(1.04)}

/* The specimen record: a card that stays in view and fills in */
.cj-card{position:sticky;top:96px;background:var(--navy);color:var(--on-navy);border-radius:6px;padding:22px 22px 20px;box-shadow:0 30px 60px -40px rgba(0,23,63,.7)}
.cj-card-head{display:flex;justify-content:space-between;align-items:baseline;gap:10px;font-size:12.5px;font-weight:600;letter-spacing:.02em;text-transform:uppercase}
.cj-card-head span{color:#fff}
.cj-card-head em{font-style:normal;color:var(--orange)}
.cj-card-id{margin-top:10px;color:#fff;font-size:34px;font-weight:600;letter-spacing:-.02em;line-height:1;font-variant-numeric:tabular-nums}
.cj-card-id small{font-size:14px;font-weight:500;letter-spacing:0;color:var(--on-navy)}
.cj-route{list-style:none;padding:0;display:grid;grid-template-columns:repeat(11,minmax(0,1fr));gap:2px;margin:18px 0 0;position:relative}
.cj-route li{position:relative;padding-top:10px}
.cj-route li::before{content:"";position:absolute;top:0;left:0;right:0;height:3px;border-radius:2px;background:rgba(255,255,255,.18);transition:background .3s}
.cj-route a{display:block;color:var(--on-navy);text-decoration:none;font-size:10.5px;line-height:1.2;font-variant-numeric:tabular-nums}
.cj-route b{display:block;font-weight:500}
.cj-route span{display:none}
.cj-route-now{display:flex;justify-content:space-between;gap:10px;margin-top:8px;color:#fff;font-size:13px;font-weight:600}
.cj-route-now em{font-style:normal;color:var(--orange);font-variant-numeric:tabular-nums}
.cj-route li.is-past::before{background:rgba(255,255,255,.55)}
.cj-route li.is-now::before{background:var(--orange)}
.cj-route li.is-now a{color:#fff;font-weight:700}
.cj-rows{margin-top:16px;border-top:1px solid var(--rule-navy)}
.cj-rows li{display:grid;grid-template-columns:76px minmax(0,1fr);gap:10px;padding:8px 0;border-bottom:1px solid var(--rule-navy);font-size:13px;line-height:1.4;transition:opacity .35s var(--ease),translate .35s var(--ease)}
.cj-rows span{grid-column:1;grid-row:1;color:var(--on-navy);font-weight:600}
.cj-rows strong{grid-column:2;grid-row:1;color:#fff;font-weight:500}
.cj-card.is-live .cj-rows li:not(.is-reached){opacity:.28;translate:0 4px}
.cj-card.is-live .cj-rows li:not(.is-reached) strong{visibility:hidden}
.cj-card.is-live .cj-rows li:not(.is-reached)::after{content:"";grid-column:2;grid-row:1;width:60%;height:10px;margin-top:4px;border-radius:5px;background:rgba(255,255,255,.14)}
.cj-card.is-live .cj-rows li.is-now{background:linear-gradient(90deg,rgba(255,77,1,.16),transparent);margin:0 -10px;padding-left:10px;padding-right:10px}
.cj-card-foot{margin-top:14px;font-size:12.5px;color:var(--on-navy)}

/* The system behind the record */
.cj-system{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));margin-top:32px;border-top:1px solid var(--navy)}
.cj-system article{padding:24px 28px 26px;border-bottom:1px solid var(--line);border-left:1px solid var(--line)}
.cj-system article:nth-child(3n+1){border-left:0;padding-left:0}
.cj-system h3{display:flex;flex-wrap:wrap;align-items:center;gap:6px 10px;margin-bottom:8px;font-size:19px}
.cj-system h3::before{content:"";width:8px;height:8px;background:var(--orange);transition:transform .25s var(--ease)}
.cj-system article:hover h3::before{transform:rotate(45deg) scale(1.2)}
.cj-system p{color:var(--muted);font-size:15px;line-height:1.45}
.cj-more{margin-top:22px;color:var(--muted);font-size:15px}
.cj-more a{color:var(--navy);font-weight:600}

/* Accreditation statement */
.cj-state{max-width:900px}
.cj-state .accr-state{color:var(--navy)}
.cj-state p+p{color:var(--muted)}

@media (max-width:1180px){
  .cj-layout{grid-template-columns:minmax(0,1fr) 320px}
  .cj-stop{grid-template-columns:56px minmax(0,1fr)}
  .cj-stop figure{grid-column:2;aspect-ratio:16/7}
}
@media (max-width:900px){
  .cj-strip{grid-template-columns:repeat(3,minmax(0,1fr));row-gap:22px;border-top:0}
  .cj-strip li{border-top:1px solid rgba(255,255,255,.3)}
  .cj-before{grid-template-columns:1fr}
  .cj-layout{grid-template-columns:1fr}
  .cj-card{position:static;order:2;margin-top:28px}
  .cj-card.is-live .cj-rows li:not(.is-reached){opacity:1;translate:none}
  .cj-card.is-live .cj-rows li:not(.is-reached) strong{visibility:visible}
  .cj-card.is-live .cj-rows li:not(.is-reached)::after{display:none}
  .cj-card.is-live .cj-rows li.is-now{background:none;margin:0;padding-left:0;padding-right:0}
  .cj-route li.is-now::before{background:rgba(255,255,255,.55)}
  .cj-route li:last-child::before{background:var(--orange)}
  .cj-route li.is-now a{color:var(--on-navy);font-weight:500}
  .cj-route-now{display:none}
  .cj-stops::before,.cj-stops::after{left:21px;top:22px}
  .cj-stop{grid-template-columns:44px minmax(0,1fr);gap:14px}
  .cj-stop>b{width:44px;height:44px;font-size:15px;box-shadow:0 0 0 5px var(--ground)}
  .cj-stop figure{grid-column:2;grid-row:1;aspect-ratio:16/9}
  .cj-stop>div{grid-column:2}
  .cj-system{grid-template-columns:1fr 1fr}
  .cj-system article,.cj-system article:nth-child(3n+1){border-left:1px solid var(--line);padding-left:24px}
  .cj-system article:nth-child(2n+1){border-left:0;padding-left:0}
}
@media (max-width:640px){
  .cj-strip span{font-size:12.5px}
  .cj-system{grid-template-columns:1fr}
  .cj-system article,.cj-system article:nth-child(2n+1),.cj-system article:nth-child(3n+1){border-left:0;padding:20px 0}
  .cj-rows li{grid-template-columns:76px minmax(0,1fr)}
}

/* Scroll motion: the spine fills, nodes turn orange, cards rise in. */
@supports (animation-timeline:view()){
  @media (prefers-reduced-motion:no-preference){
    .cj-stops::after{display:block;animation:cj-fill linear both;animation-timeline:--cjj;animation-range:cover 50vh cover calc(100% - 50vh)}
    .cj-stop>b{animation:cj-node linear both;animation-timeline:view();animation-range:cover 35% cover 50%}
    .cj-stop>div,.cj-stop figure{animation:cj-up linear both;animation-timeline:view();animation-range:entry 0% entry 35%}
    .cj-system article,.cj-before li{animation:cj-up linear both;animation-timeline:view();animation-range:entry 0% entry 60%}
  }
}
@keyframes cj-fill{from{transform:scaleY(0)}to{transform:scaleY(1)}}
@keyframes cj-node{from{background:var(--navy)}to{background:var(--orange)}}
@keyframes cj-up{from{opacity:0;transform:translateY(28px)}to{opacity:1;transform:none}}
