/* Receptor tyrosine kinase biology: pinned scroll scene (js/sections/ron.js).
   Static alpha lives in fill-/stroke-opacity here; the `opacity` attribute is reserved for animation. */
#ron.panel { padding: 0; }
.ron-stage { --col: 0px; }
.ron-svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: hidden; }

/* ---- Tumor cell ---- */
.ron-mem { fill: none; stroke: var(--tumor); stroke-width: 2.6; stroke-linejoin: round; }
.ron-mem-in { fill: none; stroke: var(--tumor); stroke-width: 1.1; stroke-opacity: 0.5; }
.ron-mem-glow { fill: none; stroke: var(--tumor); stroke-width: 16; stroke-opacity: 0.12; }
.ron-cyto { fill: url(#ron-g-cyto); }
.ron-actfill { fill: url(#ron-g-act); }
/* blueprint outline shown before the membrane draws */
.ron-ghost { fill: none; stroke: var(--holo); stroke-width: 1.4; stroke-opacity: 0.45; stroke-dasharray: 2 7; vector-effect: non-scaling-stroke; }
.ron-ripple { fill: none; stroke: var(--accent); stroke-width: 1.6; vector-effect: non-scaling-stroke; }

.ron-nuc-fill { fill: url(#ron-g-nuc); }
.ron-nuc-env { fill: none; stroke: color-mix(in srgb, var(--tumor) 70%, var(--text)); stroke-width: 1.8; stroke-opacity: 0.75; }
.ron-nuc-env2 { fill: none; stroke: color-mix(in srgb, var(--tumor) 70%, var(--text)); stroke-width: 0.9; stroke-opacity: 0.4; }
.ron-nucleolus { fill: color-mix(in srgb, var(--tumor) 70%, var(--text)); fill-opacity: 0.16; }
.ron-chrom { fill: none; stroke: color-mix(in srgb, var(--tumor) 60%, var(--text)); stroke-width: 1.1; stroke-opacity: 0.22; stroke-linecap: round; }

.ron-er-sheet { fill: var(--muted); fill-opacity: 0.08; stroke: var(--muted); stroke-width: 1.2; stroke-opacity: 0.55; stroke-linejoin: round; }

.ron-mito-out { fill: color-mix(in srgb, var(--metab) 14%, #fff); stroke: var(--metab); stroke-width: 2; }
.ron-mito-in { fill: none; stroke: var(--metab); stroke-width: 1; stroke-opacity: 0.55; }
.ron-mito-cr { fill: none; stroke: var(--metab); stroke-width: 1.3; stroke-linejoin: round; stroke-opacity: 0.85; }
.ron-mito-flow { fill: none; stroke: #fff; stroke-width: 1.4; stroke-opacity: 0.75; stroke-linecap: round; stroke-dasharray: 3 16; }
.ron-mito-pulse { fill: none; stroke: var(--metab); stroke-width: 1.6; }
.ron-mito:not(.ron-mito-hero) .ron-mito-out { stroke-opacity: 0.55; fill-opacity: 0.7; }
.ron-mito:not(.ron-mito-hero) .ron-mito-cr { stroke-opacity: 0.45; }

.ron-sting-lobe { fill: color-mix(in srgb, var(--immune) 18%, #fff); stroke: var(--immune); stroke-width: 1.3; }
.ron-sting-tm { stroke: var(--immune); stroke-width: 2; stroke-linecap: round; }

.ron-si-path { fill: none; stroke: var(--immune); stroke-width: 2.2; stroke-linecap: round; }
.ron-crack path { fill: none; stroke: var(--accent); stroke-width: 1.8; stroke-linecap: round; }
.ron-ifn-core { fill: var(--immune); stroke: #fff; stroke-width: 1; }
.ron-ifn-halo { fill: var(--immune); fill-opacity: 0.16; }

.ron-flash { fill: none; stroke: var(--accent); stroke-width: 2; }

/* Arrows (glyphs.arrow): color = the actor doing the action */
.ron-svg .g-arrow path:first-child { stroke-width: 2.4; }
.ron-svg .g-inh .g-arrow-tip { stroke-width: 3.2; }
.ron-a-ron { color: var(--accent); }
.ron-a-sting { color: var(--immune); }
.ron-svg .ron-a-sting path:first-child { stroke-width: 2.2; }
.ron-a-good { color: var(--heal); }
.ron-a-bad { color: var(--bad); }
.ron-a-glow { color: var(--accent); }
.ron-svg .ron-a-glow path:first-child { stroke-width: 9; stroke-opacity: 0.14; }
.ron-a-glow .g-arrow-tip { display: none; }

/* Immune cells: a "good" copy (--heal) cross-fades to a "bad" copy (--bad) */
.ron-imm-good .ron-imm-body { fill: color-mix(in srgb, var(--heal) 13%, #fff); stroke: var(--heal); stroke-width: 2.2; }
.ron-imm-good .ron-imm-nuc { fill: var(--heal); fill-opacity: 0.2; stroke: var(--heal); stroke-width: 1.2; stroke-opacity: 0.7; }
.ron-imm-bad .ron-imm-body { fill: color-mix(in srgb, var(--bad) 13%, #fff); stroke: var(--bad); stroke-width: 2.2; }
.ron-imm-bad .ron-imm-nuc { fill: var(--bad); fill-opacity: 0.2; stroke: var(--bad); stroke-width: 1.2; stroke-opacity: 0.7; }
.ron-imm-flash { fill: none; stroke: var(--bad); stroke-width: 2; }

/* ---- HUD labels and badges (screen space, constant size) ---- */
.ron-lbl-ln { fill: none; stroke: var(--muted); stroke-width: 1; stroke-opacity: 0.75; }
.ron-lbl-dot { fill: var(--c); }
.ron-lbl-ring { fill: none; stroke: var(--c); stroke-width: 1; stroke-opacity: 0.55; }
.ron-lbl-bg { fill: #f4fafd; fill-opacity: 0.82; }
.ron-lbl-t { font: 600 12px var(--font-display); letter-spacing: 0.2em; fill: var(--text); }
.ron-wide .ron-lbl-t { font-size: 13px; }
.ron-badge circle { fill: #f7fcfe; stroke: var(--c); stroke-width: 1.6; }
.ron-badge text { font: 700 12px var(--font-display); fill: var(--text); text-anchor: middle; }

/* ---- HTML overlays ---- */
.ron-title { position: absolute; z-index: 2; left: 0; right: 0; top: calc(64px + 3vh); margin: 0; padding: 0 20px; text-align: center; pointer-events: none; }
.ron-tag { position: absolute; z-index: 2; left: max(var(--gutter), calc(50% - 560px)); bottom: clamp(28px, 6vh, 64px); width: min(760px, calc(100% - 2 * var(--gutter))); pointer-events: none; }
.ron-tag-idx { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; font: 600 12px/1 var(--font-display); letter-spacing: 0.3em; color: var(--faint); }
.ron-tag-idx::before { content: ""; width: 28px; height: 1px; background: var(--holo); box-shadow: 0 0 6px var(--holo); }
.ron-tag-idx b { color: var(--text); font-weight: 700; }
.ron-tag .tagline { margin: 0; }
.ron-tag .k-word { display: inline-block; white-space: nowrap; }
.ron-tag .k-ch { display: inline-block; }
/* taglines are not .kinetic, so mirror base.css: a collapsible space between words, so wrapped lines start flush */
.ron-tag .k-sp { display: inline; }
.ron-tag .k-sp::before { content: " "; }

.ron-legend { position: absolute; z-index: 2; list-style: none; margin: 0; padding: 0;
  left: max(var(--gutter), calc(50% - 560px)); right: max(var(--gutter), calc(50% - 560px)); bottom: clamp(24px, 5vh, 56px);
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.ron-legend li { display: flex; gap: 12px; align-items: flex-start; opacity: 0;
  font: 600 14px/1.4 var(--font-display); letter-spacing: 0.14em; text-transform: uppercase; color: var(--text); }
.ron-legend-n { flex: none; display: grid; place-items: center; width: 24px; height: 24px; margin-top: -2px; border-radius: 50%;
  border: 1.6px solid var(--c); background: #f7fcfe; font: 700 12px/1 var(--font-display); letter-spacing: 0; color: var(--text); }

/* Scrim behind the lower-third taglines so they stay legible over the figure */
.ron-scrim { position: absolute; z-index: 1; left: 0; right: 0; bottom: 0; height: var(--scrim, 34%); pointer-events: none; opacity: 0;
  background: linear-gradient(to top, rgba(226, 240, 246, 0.94) 0%, rgba(226, 240, 246, 0.78) 38%, rgba(226, 240, 246, 0) 100%); }
.ron-short .ron-scrim { top: 0; right: auto; height: auto; width: calc(var(--col) + 90px);
  background: linear-gradient(to right, rgba(230, 243, 248, 0.95) 0%, rgba(230, 243, 248, 0.8) 60%, rgba(230, 243, 248, 0) 100%); }

/* Portrait phones and tablets */
.ron-tall .ron-title { top: 72px; font-size: clamp(22px, 6.4vw, 34px); padding: 0 16px; }
.ron-tall .ron-tag { left: 20px; right: 20px; width: auto; bottom: 22px; }
.ron-tall .ron-tag-idx { margin-bottom: 8px; }
.ron-tall .ron-legend { left: 18px; right: 18px; bottom: 18px; grid-template-columns: 1fr; gap: 9px; }
.ron-tall .ron-legend li { font-size: 12px; letter-spacing: 0.1em; gap: 10px; line-height: 1.35; }
.ron-tall .ron-legend-n { width: 21px; height: 21px; font-size: 11px; }

/* Landscape phones: text column on the left, figure on the right */
.ron-short .ron-title { top: 70px; left: 22px; right: auto; width: var(--col); padding: 0; text-align: left; font-size: 22px; }
.ron-short .ron-tag { left: 22px; width: var(--col); top: 50%; bottom: auto; margin-top: -10px; transform: translateY(-50%); }
.ron-short .ron-tag .tagline { font-size: 17px; }
.ron-short .ron-legend { left: 22px; right: auto; width: var(--col); bottom: auto; grid-template-columns: 1fr; gap: 10px; }
.ron-short .ron-legend li { font-size: 12px; letter-spacing: 0.1em; gap: 10px; line-height: 1.35; }
.ron-short .ron-legend-n { width: 21px; height: 21px; font-size: 11px; }

@media (prefers-reduced-motion: reduce) {
  .ron-legend li { opacity: 1; }
}

/* Phones: draw on into the stage's bottom extension (base.css, --stage-ext); the scrim runs to its bottom */
@media (pointer: coarse) {
  .ron-svg { overflow: visible; }
  .ron-scrim { box-sizing: content-box; padding-bottom: var(--stage-ext); bottom: calc(-1 * var(--stage-ext)); }
}
