/* T-20261006-017 · 第一交 §1–3 · load after modules + v1.1. */
/* §1 Self-hosted Latin families; fonts/fonts.css loaded on English pages only. */
html[lang="en"] {
  --font-body: "IBM Plex Sans", "Helvetica Neue", Arial, system-ui, "PingFang SC", "Microsoft YaHei", "Noto Sans CJK SC", sans-serif; /* v4 --font-body: Latin first, explicit CJK sans fallback. */
  --font-serif-cn: "Fraunces", "Iowan Old Style", Georgia, "Noto Serif", "Times New Roman", "PingFang SC", "Microsoft YaHei", "Noto Sans CJK SC", serif; /* v4 --font-serif-cn: Latin serif, Android generic serif fallback. */
  --font-display: var(--font-serif-cn); /* v4 --font-display: same Latin display family; mono unchanged. */
}
html[lang="en"] :lang(zh) { font-family: "PingFang SC", "Microsoft YaHei", "Noto Sans CJK SC", sans-serif; line-height: 1.7; letter-spacing: 0; } /* ed3 source quotations: retain Chinese script. */
html[lang="en"] :is(h1,h2,h3,h4):lang(zh) { font-family: "Songti SC", "Noto Serif CJK SC", serif !important; } /* v4 headings: explicit Chinese quotation heading. */
/* §2 Reading measure and rhythm. */
html[lang="en"] body { line-height: 1.55; } /* v1.1 §2: 1.7 → 1.55. */
html[lang="en"] :is(p,li) { text-wrap: pretty; hyphens: manual; } /* v1.1 body: avoid short final lines; no auto hyphenation above 360. */
html[lang="en"] .page-hero > h1 { max-width: 24ch; line-height: 1.12 !important; letter-spacing: -.02em !important; } /* v1.1 §4: 16ch → 24ch, existing balance retained. */
html[lang="en"] .page-hero__intro { max-width: 68ch; font-family: var(--font-body); line-height: 1.55; text-wrap: pretty; } /* v1.1 §4: 58ch CJK serif → 68ch Latin sans. */
html[lang="en"] .v1-mod-title { max-width: 48ch; line-height: 1.2 !important; } /* v1.1 §5: 34ch / 1.35 → 48ch / 1.2. */
html[lang="en"] :is(.home-method > p,.ed3-module > .intro,.ed3-module > .sub) { max-width: 68ch; line-height: 1.55; } /* home + module introductions: 60–75ch prose target. */
html[lang="en"] .page-hero__fig, html[lang="en"] .ed3-module::before { letter-spacing: .08em; } /* v1.1 §4–5: .12/.14em kicker → .08em. */
html[lang="en"] :is(.v1-toc,.ed3-foot) { letter-spacing: 0; line-height: 1.55; } /* v1.1 §4/7: .04em → 0. */
html[lang="en"] .ed3-module .ce-legend-name { overflow-wrap: break-word; } /* v1.1 §6: anywhere → break-word; don't split ordinary words. */
html[lang="en"] :is(.m3-card,.m3-evidence td,.m3-evidence th,.m3-evidence pre,.b-evidence,.gpt-language-table td,.gpt-language-table th) { overflow-wrap: break-word !important; } /* m3 template + b-common + t1/t2: anywhere → break-word. */
/* §3 Navigation and controls. */
html[lang="en"] .ed3-nav .inner { gap: 8px 20px; align-items: center; } /* v1.1 §3: fit six short labels + language link. */
html[lang="en"] .ed3-nav .brand { letter-spacing: 0; } /* v1.1 §3: .02em → 0. */
html[lang="en"] .ed3-nav a { white-space: nowrap; } /* v1.1 §3: never split a short navigation label. */
html[lang="en"] .ed3-nav .language-switch { margin-left: 0; font-family: var(--font-body); } /* Keep the language link beside the right-aligned navigation group. */
html[lang="en"] .ed3-module :is(.seg,.pick) { display: flex; flex-wrap: wrap; max-width: 100%; overflow: visible; gap: 4px; } /* d2/s1/s3/m2 segmented controls: allow complete buttons to wrap. */
html[lang="en"] .ed3-module :is(.seg,.pick) button { min-width: 5.5rem; max-width: 100%; min-height: 44px; padding: 9px 12px; white-space: normal; overflow-wrap: break-word; font: 13px/1.3 var(--font-body); } /* v1.1 §10 + module buttons: longer Latin labels, full words. */
html[lang="en"] .ed3-module :is(.seg,.pick) button[aria-pressed="true"] { background: var(--ink) !important; color: var(--paper) !important; border-color: var(--ink) !important; } /* v1.1 §10: preserve ink/paper active state in both themes. */
html[lang="en"] :is(#m1,#m3) .case-category { min-height: 44px; padding: 12px 16px; } /* cases.html: category door padding and touch target. */
html[lang="en"] :is(#m1,#m3) .case-category-name { min-width: 0; font: 600 16px/1.3 var(--font-body); text-wrap: balance; overflow-wrap: break-word; } /* cases.html: long English category titles wrap naturally. */
@media (max-width: 600px) {
  html[lang="en"] .page-hero > h1 { max-width: 100%; font-size: var(--layout-h1,42px); } /* v1.1 §8: retain mobile scale, no desktop measure. */
  /* 10-12 使用者:手機導覽改一行可滑動(見 ed3.css),原三欄格線停用 */ /* v1.1 §8: 375 = brand/language row + two three-item rows. */
  html[lang="en"] .ed3-nav .brand { grid-column: 1 / 3; grid-row: 1; } /* v1.1 §3: first row identity. */
  html[lang="en"] .ed3-nav .language-switch { grid-column: 3; grid-row: 1; justify-self: end; } /* English brief: top right, no horizontal scroll. */
  html[lang="en"] .ed3-nav a { font-size: 12px; min-width: 0; } /* v1.1 §8: six short labels fit three columns. */
}
@media (max-width: 360px) {
  html[lang="en"] :is(.page-hero__intro,.ed3-module p) { hyphens: auto; } /* economy §2: optional hyphenation only at ≤360. */
}
/* §4 Statistic cards: adapters preserve values, separate number/unit/label markup. */
html[lang="en"] :is(#m1 .stats,.en-stat-grid) { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 12px; align-items: stretch; } /* cases.html:130/301: flex statistic cards → equal-height grid; shared adapter for future home cards. */
html[lang="en"] :is(#m1 .stat,.en-stat) { min-width: 0; display: flex; flex-direction: column; padding: 14px; border: 1px solid var(--hairline-strong); background: var(--paper-raise); } /* cases.html:130: align two-line labels without fixed card height. */
html[lang="en"] :is(#m1 .stat > b,.en-stat-value) { display: flex; flex-wrap: wrap; gap: 4px 8px; align-items: baseline; font-family: var(--font-display); font-size: 36px; line-height: 1.12; font-variant-numeric: lining-nums tabular-nums; } /* cases.html:301: numeric value separated from denominator/unit. */
html[lang="en"] :is(#m1 .stat > b > small,.en-stat-unit) { font: 500 14px/1.3 var(--font-body); white-space: nowrap; } /* economy §4-3 + cases.html:300: whole unit group can move below number. */
html[lang="en"] :is(.en-stat-label,#m1 .stat > copy-text) { margin-top: 10px; font: 14px/1.4 var(--font-body); min-height: 2.8em; text-wrap: pretty; } /* cases.html:301: reserve two label lines, grow naturally beyond two. */
/* §5 M1 left label column: compact mobile puts full layer name above the bar. */
html[lang="en"] #m1 .wrow { grid-template-columns: 160px minmax(0,1fr) 80px; gap: 8px 12px; } /* cases.html:130/148: original 180px label / 55px value → 160px / 80px Latin measure. */
html[lang="en"] #m1 .wrow > b { font: 500 14px/1.3 var(--font-body); overflow-wrap: break-word; } /* cases.html:302: six full English layer names. */
html[lang="en"] #m1 .wrow > span { font: 12px/1.3 var(--font-body); white-space: nowrap; } /* cases.html:302: denominator plus cases stays intact. */
/* §6 Six indicators: full labels below glyphs, never single-letter codes. */
html[lang="en"] #m1 .case-row { grid-template-columns: minmax(0,1fr) 360px; } /* cases.html:130: 270px strip → 360px for full layer names. */
html[lang="en"] #m1 .strip { grid-template-columns: repeat(3,minmax(0,1fr)); gap: 8px; } /* cases.html:177: keep three columns / two rows; no compressed six-column strip. */
html[lang="en"] #m1 .strip button { min-height: 86px; padding: 8px 4px; gap: 5px; font: 500 12px/1.25 var(--font-body); } /* cases.html:178: 66px → 86px; full label occupies at most two normal lines. */
html[lang="en"] #m1 .strip .layer-name { max-width: 100%; text-wrap: balance; overflow-wrap: break-word; } /* cases.html:179: 6em → actual cell width. */
html[lang="en"] #m1 :is(.strip,.circle-legend) .g { width: 24px; height: 24px; flex: none; } /* cases.html:180: 16px glyph → 24px, state shapes and stroke preserved. */
html[lang="en"] #m1 .strip :is(.unmeasured-glyph,.unseparated-glyph) { width: 24px; height: 24px; flex: none; } /* current M1 runtime: glyph spans for not measured / language not split. */
html[lang="en"] #m1 .strip .unseparated-note { font: 11px/1.3 var(--font-body); max-width: 100%; text-wrap: pretty; } /* cases.html:277: full language status may need more than two lines; button grows. */
html[lang="en"] .en-state-specimen { margin-block: 32px; padding: 16px; border: 1px solid var(--hairline-strong); } /* measurement-only specimen wrapper: token-only frame. */
html[lang="en"] .en-state-specimen .strip { grid-row: auto !important; grid-column: auto !important; width: 100%; } /* cases.html:177: fixture does not inherit case-row placement. */
html[lang="en"] .en-state-specimen .en-state-name { font: 12px/1.4 var(--font-body); text-align: center; } /* state specimen: visible state labels distinguish empty/missing/language flags. */
/* §7 Heatmap/table headers: horizontal scrolling belongs only to the table container. */
html[lang="en"] .dh-scroll { max-width: 100%; overflow-x: auto; overscroll-behavior-x: contain; } /* modules/bench/domain-heatmap.css:16: preserve local scroller. */
html[lang="en"] .dh-table { min-width: 1544px; table-layout: fixed; } /* domain-heatmap.css:17: 144px sticky + ten 140px domains. */
html[lang="en"] .dh-table th:first-child { width: 144px; position: sticky; left: 0; z-index: 2; background: var(--paper-raise); } /* domain-heatmap.css:23: 168px → 144px for rank / model. */
html[lang="en"] .dh-table thead th:first-child { background: var(--paper); } /* domain-heatmap.css:24: header remains opaque over scrolling cells. */
html[lang="en"] .dh-table th button { display: grid; grid-template-columns: minmax(0,1fr) 12px; gap: 4px; align-items: center; min-height: 64px; padding: 8px 6px; font: 500 12.5px/1.25 var(--font-body); white-space: normal; } /* domain-heatmap.css:25 + JS:95: full label plus independent sort-arrow column. */
html[lang="en"] .dh-table .en-domain-name { text-wrap: balance; overflow-wrap: break-word; } /* domain-heatmap.js:95: adapter span permits deliberate two-line labels. */
html[lang="en"] .dh-table .en-sort-arrow { font: 14px/1 var(--font-body); justify-self: end; } /* domain-heatmap.js:95: arrow stays beside label, never consumes a text line. */
html[lang="en"] :is(.dh-source,.dh-sources code,.dh-kicker) { overflow-wrap: break-word; letter-spacing: 0; } /* domain-heatmap.css:5/33/34: anywhere / .08em → normal Latin wrapping. */
html[lang="en"] .home-versions { table-layout: fixed; width: 100%; } /* modules/home/home.css: model version table must fit English labels at 375. */
html[lang="en"] .home-versions :is(th,td) { overflow-wrap: break-word; font-size: 12px; line-height: 1.4; } /* home.css: version identifiers may break only when longer than available cell. */
/* §8 Date/punctuation: source copy/formatters must output 6 Oct 2026 and ASCII punctuation. */
html[lang="en"] time { white-space: nowrap; font-variant-numeric: tabular-nums; } /* ed3 date adapter: intact day/month/year; content change belongs to copy/JS. */
/* §9 SVG font bridge only; geometry changes are listed in README/SVG-NOTES.md. */
html[lang="en"] .ed3-module svg text { font-family: var(--font-body); letter-spacing: 0; } /* t1/t2/b-common + bench renderers: Latin sans for chart text, no geometry/data change. */
@media (max-width: 600px) {
  html[lang="en"] :is(#m1 .stats,.en-stat-grid) { grid-template-columns: 1fr; } /* cases.html:131: retain one-column statistic cards at 375. */
  html[lang="en"] #m1 .wrow { grid-template-columns: minmax(0,1fr) 80px; gap: 6px 8px; } /* cases.html:131: remove 110px left label from mobile bar track. */
  html[lang="en"] #m1 .wrow > b { grid-column: 1 / -1; } /* M1 compact: full label above track, preserving inline data-driven bar width. */
  html[lang="en"] #m1 .case-row { grid-template-columns: minmax(0,1fr); } /* cases.html:188: mobile text then full-width three-column strip. */
  html[lang="en"] .dh-table { min-width: 1528px; } /* domain-heatmap.css mobile: 128px sticky + ten 140px domains. */
  html[lang="en"] .dh-table th:first-child { width: 128px; } /* domain-heatmap.css mobile: visible model column leaves 207px of scroll viewport. */
}
html[lang="en"] #m1 .unseparated-glyph { display: inline-block; border: 1px dashed var(--muted); border-radius: 50%; } /* cases.html:277: language-unseparated has its own status, not a measured-zero ring. */
html[lang="en"] #m1 .unmeasured-glyph::after { top: 11px; } /* cases.html:182: centre missing-data dash in 24px glyph. */
html[lang="en"] .en-stat-value time { font-size: 24px; font-family: var(--font-body); } /* date specimen: date is a complete unit, not a 36px statistic. */
html[lang="en"] :is(#m1 .stat > b,.en-stat-value) { min-height: 41px; } /* §4: reserve equal number-row height when a small unit/date or long unit wraps. */
html[lang="en"] .en-stat-label { margin-bottom: 0; } /* §4: consistent label budget across paragraph and copy-text adapters. */
html[lang="en"] :is(pre,code,.sb-name,.sb-meta dd,.sb-source,.sb-evidence,#c-s2 .chip,#c-s3 .h,#m1 .model-sentence) { overflow-wrap: break-word !important; } /* WRAP-AUDIT.md: remaining ed3/c-profiles/bench/cases anywhere sources; preserve whole English words and permit long identifiers to wrap. */
