/* Station refresh: shared layout corrections for station.html, station-v1.html, station-v2-project.html.
   Loaded last. Uses the site's Manrope / Source Sans 3, indigo / lavender / orange palette. */

/* ---------- Shared type roles ---------- */
.station-project .sp-section-head h2,
.station-project .sp-world h2,
.station-project .sp-faq h2{font:550 clamp(2rem,3.2vw,2.9rem)/1.15 Manrope,sans-serif;letter-spacing:-.045em;margin:0 0 .9rem}
.station-project .sp-label,
.research-explorer .rx-native .finding .tag{display:block;margin:0 0 .7rem;font:650 15px/1.4 Manrope,sans-serif;letter-spacing:.1em;text-transform:uppercase;color:#5d5d7b}
.research-explorer h4,
.research-explorer .rx-chart h4{margin:0 0 .75rem;font:600 18px/1.35 Manrope,sans-serif;letter-spacing:-.015em;color:#242447}

/* ---------- 1. Premise: copy left, diagram right, cards below ---------- */
.station-project .sp-premise{padding:clamp(2rem,3vw,2.75rem) 0}
.sp-premise .approach-grid{display:grid;grid-template-columns:minmax(0,.62fr) minmax(0,1.38fr);gap:clamp(1.5rem,3vw,2.4rem);align-items:center}
.sp-premise .premise-copy{display:block;min-width:0}
.sp-premise .premise-copy .eyebrow{margin:0 0 1.2rem}
.station-project .sp-premise .eyebrow,.station-project .sp-section-head .eyebrow,.station-project .sp-world-head .eyebrow{font:600 15px/1.65 "Source Sans 3",sans-serif;letter-spacing:.12em;text-transform:uppercase;color:#5d5d7b}
.station-project .sp-premise .pull{font:550 clamp(1.5rem,2.4vw,2.05rem)/1.32 Manrope,sans-serif;letter-spacing:-.035em;margin:0 0 1.5rem;max-width:24ch}
.sp-premise .premise-prose p{font-size:1.15rem;line-height:1.65;margin:0 0 1.1em;color:#4d5175}
.sp-premise .premise-prose p:last-child{margin:0}
.sp-premise .approach-figure{margin:0;max-width:none;width:100%;background:#fff;border:1px solid var(--studio-line,#d7d5ce);border-radius:6px;padding:clamp(.35rem,.8vw,.6rem)}
.sp-premise .pillars{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:1.2rem;margin-top:clamp(2rem,4vw,3.2rem)}
.sp-premise .pillar{background:#fff;border:1px solid var(--studio-line,#d7d5ce);border-radius:6px;padding:1.5rem 1.6rem}
.sp-premise .pillar+.pillar{border-top:1px solid var(--studio-line,#d7d5ce);padding-top:1.5rem}
.sp-premise .pillar .num{display:block;font:650 14px/1.4 Manrope,sans-serif;letter-spacing:.1em;text-transform:uppercase;color:#5d5d7b;margin:0 0 .6rem}
.sp-premise .pillar h3{font:600 1.05rem/1.15 "Source Sans 3",sans-serif;letter-spacing:-.01em;margin:0 0 .4rem}
.sp-premise .pillar p{font-size:.95rem;line-height:1.65;margin:.3rem 0 0;color:#4d5175}
@media(max-width:860px){
  .sp-premise .approach-grid{grid-template-columns:minmax(0,1fr);gap:2.5rem}
  .sp-premise .pillars{grid-template-columns:1fr;gap:1.2rem}
}

/* ---------- 2. Study blocks: tight editorial stack ---------- */
.station-project .sp-study{display:block;padding:clamp(2.25rem,4vw,3.25rem) 0;border-bottom:1px solid var(--studio-line,#d7d5ce)}
.station-project .sp-study:last-child{border-bottom:0}
.station-project .sp-study .sp-study-copy{display:block;max-width:none;margin:0}
.station-project .sp-study h3{margin:0 0 .7rem;font-size:clamp(1.7rem,2.4vw,2.25rem)}
.station-project .sp-study-copy p:not(.sp-label){margin:0 0 1rem;max-width:none;font-size:1.1875rem;line-height:1.6}
.station-project .sp-study-copy .sp-links{margin:0}
.station-project .sp-study .research-explorer,
.station-project .sp-study .sp-open-results{margin:1.75rem 0 0}
.station-project .sp-open-results .native-figure{margin:0}

/* ---------- 6. Tabs: fit on desktop, wrap cleanly on mobile ---------- */
.research-explorer .rx-tabs{display:flex;flex-wrap:wrap;overflow:visible;gap:0;padding:0}
.research-explorer .rx-tab{flex:1 1 auto;text-align:center;white-space:nowrap;padding:1rem .9rem .95rem;border-radius:0}
.research-explorer .rx-tab:first-child{border-top-left-radius:6px}
.research-explorer .rx-tab:last-child{border-top-right-radius:6px}
.research-explorer .rx-tab[aria-selected=true],
.research-explorer .rx-tab:first-child[aria-selected=true]{box-shadow:inset 1px 0 var(--rx-line),inset -1px 0 var(--rx-line)}
@media(max-width:700px){
  .research-explorer .rx-tabs{display:grid;grid-template-columns:repeat(2,minmax(0,1fr))}
  .research-explorer .rx-tab{white-space:normal;padding:.8rem .6rem .75rem;font-size:15px;border-bottom:1px solid var(--rx-line-soft)}
  .research-explorer .rx-tab:last-child:nth-child(odd){grid-column:1/-1}
  .research-explorer .rx-tab:last-child{border-top-right-radius:0}
  .research-explorer .rx-tab:nth-child(2){border-top-right-radius:4px}
}

/* ---------- 3. Panel intros: title, paragraph directly below, same left edge as figure ---------- */
.research-explorer .rx-intro{display:block;margin:0 0 1.25rem;padding:0;border:0}
.research-explorer .rx-intro h3{margin:0 0 .6rem}
.research-explorer .rx-intro p{max-width:66ch;margin:0}
.research-explorer .rx-keyline{margin:0 0 .9rem;padding:.75rem 0 0;border-top:1px solid var(--rx-line-soft);font-size:17px;line-height:1.45;color:var(--rx-muted);font-variant-numeric:tabular-nums}
.research-explorer .rx-keyline strong{margin-right:.2rem;font:600 21px/1.2 Manrope,sans-serif;letter-spacing:-.02em;color:var(--rx-station-ink)}
.research-explorer .rx-note{margin:0;font-size:16px;line-height:1.55;color:var(--rx-muted);max-width:60ch}
.research-explorer .rx-sub{margin:-.35rem 0 .9rem;font-size:16px;line-height:1.45;color:var(--rx-muted);font-variant-numeric:tabular-nums}
.research-explorer .rx-sub strong{color:var(--rx-station-ink);font-weight:600}

/* ---------- 4/5. Original paper figures ---------- */
.research-explorer .rx-paper{margin:0;min-width:0;background:#fff}
.research-explorer .rx-img{display:block;width:100%;height:auto;max-width:none;background:#fff}
.research-explorer .rx-figure>figcaption{max-width:90ch}

/* Text column + figure column; each column owns its own left edge. */
.research-explorer .rx-split{display:grid;grid-template-columns:minmax(0,.85fr) minmax(0,1.15fr);gap:clamp(1.75rem,4vw,3.5rem);align-items:center}
.research-explorer .rx-split-copy{min-width:0}
.research-explorer .rx-split-copy .rx-intro{margin-bottom:1.1rem}
.research-explorer .rx-split>.rx-paper h4{margin-bottom:.6rem}
.research-explorer .rx-illustration .rx-img{max-height:440px;width:auto;max-width:100%;margin:0}
.research-explorer .rx-wide{margin-top:clamp(1.75rem,3vw,2.5rem);padding-top:clamp(1.25rem,2vw,1.6rem);border-top:1px solid var(--rx-line-soft)}

/* Circle packing: two equal pairs; packing and timeline share one height. */
.research-explorer .rx-pack-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:clamp(1.75rem,4vw,3.5rem)}
.research-explorer .rx-pack{min-width:0;container-type:inline-size}
.research-explorer .rx-pack-row{display:flex;align-items:center;gap:1rem}
.research-explorer .rx-pack-row .rx-img{display:block;width:min(100%,400px);height:auto;flex:0 1 auto}
.research-explorer .rx-config{border:1px solid var(--rx-line-soft)}

/* Scrollable frame used only on narrow screens for wide original result figures. */
.research-explorer .rx-scroll{min-width:0}
.research-explorer .rx-scroll:focus-visible{outline:2px solid var(--rx-indigo);outline-offset:3px}

/* ---------- 7. Kissing number: original comparison figure ---------- */
.research-explorer .rx-native .finding--wide .finding-body{display:block}
.research-explorer .rx-native .finding--wide .finding-body>p:not(.headline){max-width:75ch}
.research-explorer .rx-comparison{display:grid;grid-template-columns:minmax(0,1fr) minmax(300px,500px);gap:clamp(1.75rem,4vw,3.5rem);align-items:center;
  margin:clamp(1.75rem,3vw,2.5rem) 0 0;padding:clamp(1.5rem,2.5vw,2rem) 0 0;border-top:1px solid var(--rx-line);background:#fff}
.research-explorer .rx-compare-copy{min-width:0}
.research-explorer .rx-compare-copy h4{font:600 clamp(24px,2.2vw,30px)/1.2 Manrope,sans-serif;letter-spacing:-.03em;margin:0 0 .6rem}
.research-explorer .rx-compare-copy>p:not(.rx-keyline):not(.rx-note){margin:0 0 1rem;max-width:62ch;font-size:18px;line-height:1.6;color:var(--rx-ink-2)}
.research-explorer .rx-compare-fig{min-width:0}
.research-explorer .rx-compare-fig .rx-img{width:100%;max-height:640px;object-fit:contain;object-position:left top}

/* ---------- 8. Calls to action: equal headings, balanced columns ---------- */
.station-project .sp-start{grid-template-columns:repeat(2,minmax(0,1fr));gap:0;padding:clamp(2.5rem,4vw,3.5rem) 0 clamp(3rem,5vw,4rem)}
.station-project .sp-start>div{display:flex;flex-direction:column;align-items:flex-start;min-width:0;padding-right:3rem}
.station-project .sp-start>div+div{border-left:1px solid var(--studio-line,#d7d5ce);padding:0 0 0 3rem}
.station-project .sp-start h2,
.station-project .sp-start h3{font:550 clamp(1.5rem,2.2vw,1.875rem)/1.2 Manrope,sans-serif;letter-spacing:-.04em;margin:0 0 1rem}
.station-project .sp-start p{margin:0 0 1.5rem;max-width:none;font-size:1.1875rem;line-height:1.6}
.station-project .sp-start .sp-links,
.station-project .sp-start>div>a{margin-top:auto}
/* One separator between FAQ and CTA. */
.station-project .sp-faq-item:last-child{border-bottom:0}

/* ---------- Responsive ---------- */
@media(max-width:1000px){
  .research-explorer .rx-split{grid-template-columns:minmax(0,1fr);gap:1.5rem}
  .research-explorer .rx-illustration .rx-img{max-height:380px}
  .research-explorer .rx-comparison{grid-template-columns:minmax(0,1fr)}
  .research-explorer .rx-compare-fig .rx-img{max-width:520px}
}
@media(max-width:900px){
  .research-explorer .rx-pack-grid{grid-template-columns:minmax(0,1fr)}
  .research-explorer .rx-pack+.rx-pack{padding-top:1.5rem;border-top:1px solid var(--rx-line-soft)}
}
@media(max-width:832px){
  .station-project .sp-start{grid-template-columns:1fr}
  .station-project .sp-start>div{padding:0}
  .station-project .sp-start>div+div{border-left:0;border-top:1px solid var(--studio-line,#d7d5ce);padding:2rem 0 0;margin-top:2rem}
}
@media(max-width:700px){
  .research-explorer .rx-scroll{overflow-x:auto;-webkit-overflow-scrolling:touch;margin-inline:calc(-1 * var(--rx-pad));padding-inline:var(--rx-pad)}
  .research-explorer .rx-scroll .rx-img{width:720px}
  .research-explorer .rx-keyline strong{font-size:19px}
}
@media(max-width:560px){
  .research-explorer .rx-pack-row{flex-direction:column;align-items:stretch}
  .research-explorer .rx-pack-row .rx-img{height:auto;width:100%}
  .research-explorer .rx-pack-row .rx-config{width:min(100%,260px)}
  .research-explorer .rx-illustration .rx-img{width:100%;max-height:none}
}

/* Final composition and readable scientific figures. */
.research-explorer .rx-split{align-items:start}
.research-explorer .rx-illustration .rx-img{width:100%;max-width:540px;height:auto;max-height:none}
.research-explorer .rx-comparison{display:block;max-width:700px;margin-left:auto;margin-right:auto}
.research-explorer .rx-compare-copy{margin-bottom:1.5rem}
.research-explorer .rx-compare-fig .rx-img{width:100%;max-width:640px;height:auto;max-height:none;margin:0 auto;object-fit:initial}
.research-explorer .rx-native .finding--wide .finding-fig{display:block}
.station-project .sp-study .rx-intro h3{font-size:clamp(24px,2.2vw,30px);line-height:1.2}
@media(max-width:700px){
 .research-explorer .rx-scroll .rx-img{width:1000px;max-width:none}
 .research-explorer .rx-compare-fig .rx-img{width:640px;max-width:none;margin:0}
 .research-explorer .rx-scroll::before{content:"Scroll figure horizontally →";display:block;position:sticky;left:0;width:fit-content;max-width:100%;margin:0 0 .65rem;font:500 14px/1.4 "Source Sans 3",sans-serif;color:#64667b}
 .research-explorer .rx-native .plot--static-svg svg text{font-size:16px}
}

.research-explorer .rx-pack-row .rx-config{width:min(100%,280px);height:auto;max-width:280px}

/* Compact v1 results: one primary figure, with supporting diagrams on demand. */
.research-explorer .rx-intro h3{text-wrap:wrap}
.research-explorer .rx-intro p,
.research-explorer .rx-note,
.research-explorer .rx-figure>figcaption{max-width:none;width:100%}
.research-explorer .rx-method{margin-top:1rem;border-top:1px solid var(--rx-line-soft);padding-top:.8rem}
.research-explorer .rx-method summary{width:fit-content;cursor:pointer;font:600 17px/1.5 Manrope,sans-serif;color:var(--rx-ink)}
.research-explorer .rx-method summary:hover{color:var(--rx-station-ink)}
.research-explorer .rx-method-content{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:2rem;margin-top:1.25rem;align-items:start}
.research-explorer .rx-method .rx-illustration .rx-img{max-width:400px}
.research-explorer .rx-panel-batch .rx-split{grid-template-columns:minmax(0,.85fr) minmax(0,1.15fr)}
.research-explorer .rx-panel-batch .rx-figure>figcaption{font-size:15px;line-height:1.4;margin-top:.7rem;padding-top:.6rem}
@media(max-width:1000px){
 .research-explorer .rx-panel-batch .rx-split{grid-template-columns:1fr}
}
@media(max-width:700px){
 .research-explorer .rx-method-content{grid-template-columns:1fr;gap:1rem}
}

.station-project .sp-study .sp-study-compact p{max-width:none}
.station-project .sp-study-compact .sp-inline-links{gap:.55rem}
.station-project .sp-study-compact .sp-inline-links>span{color:#77768b}

.research-explorer .rx-circle-split .rx-pack-grid{gap:1.5rem}
.research-explorer .rx-circle-split .rx-config{width:min(100%,280px)}
.research-explorer .rx-enlarge{display:block;cursor:zoom-in;border:0;text-decoration:none}
.research-explorer .rx-enlarge:focus-visible{outline:2px solid var(--rx-indigo);outline-offset:4px}
