/* falakbin.ir/lab/expansion: this lab's own rules, after sims.css (docs/plans/lab-wave3.md).
   Three scenes in one simulator, each with a numbered head across its grid. */

.flk-exp { gap: 34px; }
.flk-exp .flk-sim { margin-top: 0; }
.flk-exp-head { grid-column: 1 / -1; display: flex; align-items: flex-start; gap: 12px; margin-top: 8px; }
.flk-exp-head h2 { margin: 0; font-size: 1.18rem; line-height: 1.6; }
.flk-exp-head p { margin: 2px 0 0; color: var(--muted); font-size: .88rem; line-height: 1.8; }
.flk-exp-n {
    flex: none; display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%;
    background: var(--teal-soft); color: var(--teal-ink); font-weight: 900; font-size: 1rem; margin-top: 2px;
}

/* The scenes: a tap on the galaxies, a horizontal drag on the chart (the page still scrolls), nothing on the journey. */
.flk-exp-tap .flk-sim-canvas { touch-action: manipulation; cursor: pointer; }
.flk-exp-builder .flk-sim-canvas { touch-action: pan-y; cursor: crosshair; }
.flk-exp-calc .flk-sim-canvas { touch-action: auto; cursor: default; }
.flk-exp-plot { border-radius: 12px; overflow: hidden; border: 1px solid rgba(147, 184, 182, .2); background: #03141a; }
.flk-exp-plot .flk-sim-canvas { touch-action: auto; cursor: default; }

/* On a wide screen the scene stays in view while its long panel scrolls past. */
@media (min-width: 921px) { .flk-exp .flk-sim-stage { position: sticky; top: 84px; } }

/* Readouts a little larger where they are the answer. */
.flk-exp .flk-sim-read dd .flk-exp-big, .flk-exp .flk-sim-read dd.flk-exp-big { font-size: 1.12rem; color: var(--orange-ink); }

/* A symbol before its words (Ωm, H0), isolated so the parentheses and digits around it stay put. */
.flk-exp-sym { color: var(--teal-ink); font-weight: 800; font-family: Tahoma, sans-serif; }
.flk-exp-sym sub { font-size: .72em; }

/* Keys of the eras and of today's mix. */
.flk-exp-key { display: inline-block; width: 12px; height: 8px; border-radius: 3px; vertical-align: middle; margin-inline: 6px 4px; }
.flk-exp-key-m { background: #3fcac3; }
.flk-exp-key-l { background: #b4a8ff; }
.flk-exp-key-r { background: #ffd166; }
.flk-exp-key-k { background: #93b8b6; }
.flk-exp-mix { display: flex; height: 12px; border-radius: 999px; overflow: hidden; background: var(--bg-2); border: 1px solid var(--line-soft); }
.flk-exp-mix span { width: var(--w, 0); flex: none; transition: width .25s ease; }
.flk-exp-mix-m { background: #3fcac3; }
.flk-exp-mix-l { background: #b4a8ff; }
.flk-exp-mix-r { background: #ffd166; }
.flk-exp-mix-k { background: repeating-linear-gradient(45deg, #93b8b6 0 4px, #5f7e7c 4px 8px); }
.flk-exp-legend { list-style: none; margin: -6px 0 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 4px 10px; font-size: .8rem; color: var(--muted); }
.flk-exp-legend .flk-exp-key { margin-inline: 0 6px; }
.flk-exp-legend b { color: var(--fg); font-variant-numeric: tabular-nums; margin-inline-start: 4px; }

/* The redshift field. */
.flk-exp-z { display: inline-flex; align-items: center; gap: 6px; margin-inline-start: auto; font-weight: 800; color: var(--muted); direction: ltr; }
.flk-exp-z input {
    width: 7.5em; font: inherit; font-weight: 800; font-size: 1rem; color: var(--fg); background: var(--bg-2);
    border: 1px solid var(--line); border-radius: 10px; padding: 6px 10px; text-align: center; font-variant-numeric: tabular-nums;
}
.flk-exp-z input:focus-visible { outline: 2px solid var(--teal-ink); outline-offset: 1px; }

/* Three guided tries under the why. */
.flk-exp-try { list-style: none; margin: 18px 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 10px; }
.flk-exp-try button {
    display: flex; align-items: center; gap: 12px; width: 100%; height: 100%; padding: 12px 14px; text-align: start;
    background: var(--surface); border: 1px solid var(--line); border-radius: 14px; color: var(--fg); font: inherit; cursor: pointer;
}
.flk-exp-try button:hover { background: var(--teal-soft); }
.flk-exp-try button > span:nth-child(2) { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.flk-exp-try small { color: var(--muted); font-size: .8rem; line-height: 1.8; }
.flk-exp-try .flk-i { flex: none; width: 16px; height: 16px; color: var(--orange-ink); }
.flk-exp-try-n { flex: none; display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; border: 1.5px solid var(--orange-ink); color: var(--orange-ink); font-weight: 900; }

@media (max-width: 560px) {
    .flk-exp { gap: 26px; }
    .flk-exp-head h2 { font-size: 1.05rem; }
    .flk-exp-head p { font-size: .82rem; }
    .flk-exp-n { width: 28px; height: 28px; font-size: .9rem; }
    .flk-exp-z input { width: 6.5em; }
}
@media (prefers-reduced-motion: reduce) { .flk-exp-mix span { transition: none; } }
