﻿/* Shared typography, spacing and navigation come from the homepage stylesheet. */
.project-intro h1 { font-size: clamp(1.8rem, 4.2vw, 2.55rem); letter-spacing: -.035em; margin-bottom: 12px; }
.project-intro .context { margin-bottom: 8px; }
.project-intro > p:not(.context,.project-links) { max-width: 72ch; }
.project-intro .project-links { margin-top: 14px; }
.model-card { margin-top: 24px; padding: 15px 20px; border-left: 3px solid #7496b6; background: #f5f8fb; }
.model-card h2 { font-size: 16px; margin-bottom: 8px; }
.equation { margin: 0 0 8px; font: clamp(1.15rem, 2.8vw, 1.55rem)/1.5 Georgia, serif; }
.model-card p:last-child { margin-bottom: 0; }
.intro { max-width: 72ch; }
.lab { margin: 0; border: 1px solid var(--line); padding: 18px; }
.control-row, .plot-head, .inspect { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; }
.control-row, .plot-head { justify-content: space-between; }
fieldset { min-width: 0; padding: 0; border: 0; margin: 0; }
legend { font-size: .875rem; font-weight: 600; padding: 0; margin-bottom: 6px; }
.seg { display: flex; flex-wrap: wrap; gap: 5px; }
button { border: 1px solid #c5ccd3; border-radius: 3px; background: #fff; color: var(--ink); padding: .35rem .6rem; font: inherit; font-size: .875rem; cursor: pointer; }
button:hover { border-color: var(--link); }
button[aria-pressed="true"] { background: #eaf2fa; color: #174675; border-color: #7d9dbc; font-weight: 600; }
button:focus-visible, input:focus-visible, summary:focus-visible { outline: 2px solid var(--link); outline-offset: 3px; }
.plot-head { border-top: 1px solid var(--line); padding-top: 14px; margin: 16px 0 10px; }
.plot-head h3 { margin-bottom: 3px; }
.plot-head p { font-size: .875rem; color: var(--muted); margin: 0; }
.legend { display: flex; flex-wrap: wrap; gap: 4px 12px; font-size: .875rem; color: var(--muted); }
.legend span::before { content: ""; display: inline-block; width: 13px; height: 3px; vertical-align: middle; margin-right: 5px; background: var(--series); }
canvas { display: block; width: 100%; height: 320px; background: #fff; border: 1px solid var(--line); }
.inspect { margin: 10px 0 18px; font-size: .875rem; gap: 6px 14px; }
.inspect input { accent-color: var(--link); flex: 1; min-width: 100px; }
output, #values, table { font-variant-numeric: tabular-nums; }
#values { flex-basis: 100%; color: var(--muted); }
.readouts, .reference { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 20px; }
.readouts h3 { font-size: 1rem; }
table { width: 100%; border-collapse: collapse; text-align: right; font-size: .875rem; }
th, td { padding: 5px 4px; border-bottom: 1px solid var(--line); }
th { color: var(--muted); font-weight: 550; }
th:first-child { text-align: left; }
.metrics { display: flex; flex-wrap: wrap; gap: 6px 24px; margin: 14px 0 6px; }
.metrics dd { font-variant-numeric: tabular-nums; }
.note { margin-bottom: 0; }
.method article { margin-bottom: 16px; }
.method article:last-child { margin-bottom: 0; }
.method article p { margin: 0; }
.code-wrap { min-width: 0; align-self: start; border: 1px solid var(--line); background: #f7f8fa; }
.code-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 8px 10px; border-bottom: 1px solid var(--line); color: var(--muted); font-size: .875rem; }
pre { margin: 0; padding: 12px; overflow: auto; color: #1a3c61; font-size: .875rem; }
code { font-family: ui-monospace, Consolas, monospace; overflow-wrap: anywhere; }
pre code { overflow-wrap: normal; }
.api { margin: 0; }
.api dt { color: var(--link); font-weight: 600; }
.api dd { margin: 0 0 10px; }
details { margin-block: 18px; padding-block: 10px; border-block: 1px solid var(--line); }
details p { margin: 10px 0 0; }
summary { cursor: pointer; font-weight: 600; }
.helper-list { padding-inline-start: 20px; }
.resources { display: flex; flex-wrap: wrap; gap: 5px 16px; font-size: .875rem; }
@media(max-width: 650px) {
  .readouts, .reference { grid-template-columns: 1fr; gap: 14px; }
  .lab { padding: 12px; }
  canvas { height: 280px; }
}
