/* Styles for one manual page (rendered inside the reader's iframe).
   Printed service-manual look: ink on white, hairline rules, square callout tags. */
@import url("fonts.css");
:root {
  --paper: #f3f0e8; --paper-2: #e9e4d7; --ink: #15171a; --ink-2: #3b4046; --muted: #6b6e70; --hair: #d3ccbc;
  --signal: #e8590c; --link: #0e5a61; --mark: #ffd60a; --zh: #7b7d7f; --yes: #1b6a33; --no: #b8141f;
  --f-body: "Barlow", "PingFang SC", "Noto Sans SC", "Microsoft YaHei", sans-serif;
  --f-cond: "Barlow Condensed", "Barlow", "PingFang SC", sans-serif;
  --f-mono: "IBM Plex Mono", ui-monospace, Menlo, monospace;
}
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; padding: 16px 26px 90px; background: #fff; color: var(--ink);
  font: 16px/1.55 var(--f-body); -webkit-font-smoothing: antialiased;
}
b, strong { font-weight: 600; }
.pg-head { border-bottom: 1px solid var(--ink); margin: 0 0 18px; padding-bottom: 8px; }
.crumbs { font: 12px/1.4 var(--f-mono); color: var(--ink-2); }
.pg-zh { font: 12px/1.4 var(--f-mono); color: var(--muted); margin-top: 3px; }
.manual { overflow-x: auto; }

/* language modes: body.lang-en | lang-both | lang-zh */
.lang-en .tx .zh, .lang-zh .tx .en { display: none; }
.lang-both .tx .zh { display: block; font-size: .86em; color: var(--zh); line-height: 1.4; }
.lang-both a .tx .zh, .lang-both .figno ~ .tx .zh { display: inline; }
.lang-both a .tx .zh::before, .lang-both .figno ~ .tx .zh::before { content: " · "; }
.tx.untr .en { background: #fff3b0; }       /* not translated: shows Chinese */

/* Arbortext manual structure */
.x--ufe-imageoffset-1-0:has(> img[src*="gentext/setiao"]), img[src*="gentext/setiao"] { display: none; }   /* the manual's coloured bar before titles */
.x-title-8-0, .x-title-14-0 { font: 700 32px/1.08 var(--f-cond); letter-spacing: .005em; margin: 4px 0 20px; }
.x-title-17-0, .x-p-8-0.x-p-8-2 {
  font: 700 15px/1.2 var(--f-cond); text-transform: uppercase; letter-spacing: .1em;
  margin: 28px 0 10px; padding-bottom: 5px; border-bottom: 1.5px solid var(--ink);
}
.x-p-2-0 { font-weight: 600; font-size: 16.5px; margin: 18px 0 6px; }
.x-p-4-0, .x-p-3-0 { margin: 2px 0 8px; }
.x-p-1-0 { margin: 5px 0; }
.manual [style*="font-family"] { font-family: inherit !important; }   /* manual asks for 思源黑体, which devices lack */

/* WARNING / CAUTION / NOTE blocks. Every one is: wrapper > div.x-table-2-0 > 2-row table
   (row 1: icon + signal word, row 2: text). Styled as a workshop label: coloured bar + bordered body. */
.x-note-1-0, .x-note-4-0 { display: block; margin: 14px 0; }
:is(.x-note-1-0, .x-note-4-0) > .x-table-2-0 > table { width: 100% !important; max-width: 980px; border-collapse: collapse; border: 2px solid var(--ink); }
:is(.x-note-1-0, .x-note-4-0) > .x-table-2-0 > table > tbody > tr > td { background: #fff !important; padding: 9px 13px !important; }
:is(.x-note-1-0, .x-note-4-0) > .x-table-2-0 > table > tbody > tr:first-child > td { background: var(--ink) !important; color: #fff; padding: 5px 12px 4px !important; }
:is(.x-note-1-0, .x-note-4-0) > .x-table-2-0 > table > tbody > tr:first-child > td span[style] {
  font: 700 15px/1.2 var(--f-cond) !important; letter-spacing: .1em; text-transform: uppercase; color: inherit !important; }
:is(.x-note-1-0, .x-note-4-0) .x--ufe-noteoffset-1-0 { display: none; }
:is(.x-note-1-0, .x-note-4-0) > .x-table-2-0 > table:has(img[src*="G_warning"]) { border-color: var(--no); }
:is(.x-note-1-0, .x-note-4-0) > .x-table-2-0 > table:has(img[src*="G_warning"]) > tbody > tr:first-child > td { background: var(--no) !important; }
:is(.x-note-1-0, .x-note-4-0) > .x-table-2-0 > table:has(img[src*="G_caution"]) > tbody > tr:first-child > td { background: #f5c400 !important; color: var(--ink); }
:is(.x-note-1-0, .x-note-4-0) > .x-table-2-0 > table:has(img[src*="G_note"]) { border-color: #1d4a86; }
:is(.x-note-1-0, .x-note-4-0) > .x-table-2-0 > table:has(img[src*="G_note"]) > tbody > tr:first-child > td { background: #1d4a86 !important; }
.figno {
  display: inline-flex; align-items: center; justify-content: center; min-width: 1.6em; height: 1.6em; padding: 0 .25em;
  margin-right: 7px; background: var(--ink); color: #fff; font: 600 .76em/1 var(--f-mono); vertical-align: .1em;
}
a.xref { color: var(--link); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
a.xref:hover { text-decoration-thickness: 2px; }
a.xref.missing { color: #a33; text-decoration: line-through; }
td { vertical-align: top; }
.manual td:is([style*="DEE9EA" i], [style*="DBEEF0" i], [style*="CCEDEF" i], [style*="9AD1D5" i]) {
  background-color: var(--paper-2) !important; }   /* the manual's four teal header shades */
main img[src*="graphics/img"] { max-width: 100%; height: auto; cursor: zoom-in; border: 1px solid var(--hair); }
mark { background: var(--mark); color: inherit; padding: 0 1px; }

.zoom {
  position: fixed; inset: 0; z-index: 99; background: rgba(21, 23, 26, .93);
  display: flex; align-items: center; justify-content: center; cursor: zoom-out; padding: 14px;
}
.zoom img { max-width: 100%; max-height: 100%; width: auto; height: auto; background: #fff; }

@media (max-width: 760px) {
  body { padding: 12px 12px 64px; font-size: 15.5px; }
  .x-title-8-0, .x-title-14-0 { font-size: 26px; }
  /* procedure steps are laid out as [310px figure column | text column with 100px indent] */
  td[style*="padding-left:100px"] { padding-left: 6px !important; }
  .x-procsteps-1-0 td, .x-procsteps-1-0 tr { display: block; width: auto !important; }
  col { width: auto !important; }
}
@media print {
  body { padding: 0; }
  .pg-head { border: 0; }
  a.xref { color: inherit; }
}

/* added by build: full-width step tables, Yes/No branch labels */
table.onecol { width: 100%; max-width: 980px; }
.yn { display: inline-block; font: 600 .7em/1 var(--f-mono); letter-spacing: .08em; text-transform: uppercase;
  border: 1.5px solid currentColor; padding: .28em .45em .24em; background: #fff; }
.yn.yes { color: var(--yes); }
.yn.no { color: var(--no); }
.lang-both .yn .tx .zh { display: inline; font-size: 1em; color: inherit; }
.lang-both .yn .tx .zh::before { content: " "; }
:is(.x-note-1-0, .x-note-4-0) > .x-table-2-0 > table > tbody > tr:first-child .tx .zh { color: inherit; opacity: .8; }

/* ---- Guided check (button under the page header opens a popup; page.js) ---- */
.g-launch { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; margin: -4px 0 22px; padding: 10px 12px;
  border: 1.5px solid var(--ink); background: var(--paper); }
.g-start { font: 700 15px/1 var(--f-cond); letter-spacing: .1em; text-transform: uppercase; background: var(--ink); color: #fff;
  border: 0; padding: 11px 16px 10px; cursor: pointer; }
.g-start:hover { background: var(--signal); color: var(--ink); }
.g-hint { font-size: 14px; color: var(--ink-2); flex: 1 1 260px; }
html.g-lock, html.g-lock body { overflow: hidden; }
.g-ov { position: fixed; inset: 0; z-index: 90; background: rgba(21, 23, 26, .55); display: flex; justify-content: center;
  align-items: flex-start; padding: 28px 16px; overflow: auto; }
.g-ov[hidden] { display: none; }
.g-dlg { width: 100%; max-width: 780px; background: #fff; border: 2px solid var(--ink); box-shadow: 8px 8px 0 rgba(21, 23, 26, .3); }
.g-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; background: var(--ink); color: #fff; padding: 10px 14px 11px; }
.g-ttl small { display: block; font: 500 11px/1.5 var(--f-mono); letter-spacing: .14em; text-transform: uppercase; color: var(--signal); }
.g-ttl b { font: 700 21px/1.15 var(--f-cond); }
.g-x { flex: none; width: 34px; height: 34px; background: none; border: 1px solid #6b6e70; color: #fff; font-size: 15px; cursor: pointer; }
.g-x:hover { background: #fff; color: var(--ink); }
.g-trail { list-style: none; margin: 0; padding: 8px 14px; background: var(--paper); border-bottom: 1px solid var(--hair); font: 12.5px/1.5 var(--f-mono); }
.g-trail li { display: flex; gap: 8px; align-items: baseline; padding: 1px 0; }
.g-trail .g-t { flex: 1; min-width: 0; color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.g-a { font-weight: 600; flex: none; }
.g-a.yes { color: var(--yes); } .g-a.no { color: var(--no); } .g-a.done { color: var(--muted); }
.g-main { padding: 16px 16px 4px; }
.g-sh { margin-bottom: 10px; }
.g-of { display: block; font: 500 11.5px/1.4 var(--f-mono); letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.g-stitle { font: 700 25px/1.15 var(--f-cond); margin-top: 2px; }
.g-note { border: 1.5px solid var(--ink); background: #fffdf2; padding: 8px 12px; margin: 0 0 12px; }
.g-note b { font: 700 13px/1 var(--f-cond); letter-spacing: .1em; text-transform: uppercase; }
.g-body { margin: 4px 0 6px; }
.g-q { font-weight: 600; font-size: 17.5px; margin: 14px 0 10px; }
.g-ans { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.g-btn { display: flex; flex-direction: column; gap: 6px; text-align: left; background: #fff; border: 2px solid var(--ink);
  padding: 12px 14px; cursor: pointer; font: inherit; color: var(--ink); }
.g-btn .g-yn { font: 700 24px/1 var(--f-cond); letter-spacing: .08em; text-transform: uppercase; }
.g-btn .g-d { font-size: 14.5px; line-height: 1.4; color: var(--ink-2); }
.g-btn.yes { border-color: var(--yes); } .g-btn.yes .g-yn { color: var(--yes); } .g-btn.yes:hover { background: #eef6f0; }
.g-btn.no { border-color: var(--no); } .g-btn.no .g-yn { color: var(--no); } .g-btn.no:hover { background: #fbeeee; }
.g-btn.cont { font: 700 16px/1 var(--f-cond); letter-spacing: .08em; text-transform: uppercase; padding: 14px; background: var(--ink); color: #fff; }
.g-res { border: 2px solid var(--ink); margin: 2px 0 8px; }
.g-res .g-rh { padding: 8px 13px 7px; font: 700 20px/1.1 var(--f-cond); letter-spacing: .08em; text-transform: uppercase; color: #fff; background: var(--ink); }
.g-res.ok { border-color: var(--yes); } .g-res.ok .g-rh { background: var(--yes); }
.g-res.fix .g-rh { background: #f5c400; color: var(--ink); }
.g-res.info { border-color: #1d4a86; } .g-res.info .g-rh { background: #1d4a86; }
.g-res.err .g-rh { background: var(--muted); }
.g-res .g-rb { padding: 10px 13px 12px; }
.g-res .g-rb p { margin: 0 0 8px; }
.g-what { font-weight: 600; font-size: 16.5px; }
.g-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 14px 16px 16px; border-top: 1px solid var(--hair); margin-top: 12px; }
.g-foot button { font: 600 13px/1 var(--f-cond); letter-spacing: .08em; text-transform: uppercase; background: #fff; color: var(--ink);
  border: 1px solid var(--ink); padding: 9px 12px 8px; cursor: pointer; }
.g-foot button:hover:not(:disabled) { background: var(--ink); color: #fff; }
.g-foot button.primary { background: var(--ink); color: #fff; }
.g-foot button:disabled { opacity: .35; cursor: default; }
.g-msg { font: 12.5px var(--f-mono); color: var(--ink-2); }
.g-copy { width: 100%; height: 150px; margin-top: 10px; font: 12.5px/1.4 var(--f-mono); border: 1px solid var(--ink); padding: 8px; }
@media (max-width: 640px) {
  .g-ov { padding: 0; }
  .g-dlg { max-width: none; min-height: 100%; border: 0; box-shadow: none; }
  .g-ans { grid-template-columns: 1fr; }
  .g-stitle { font-size: 22px; }
}
@media print { .g-launch, .g-ov { display: none !important; } }

/* inside the reader the path is already in the top bar: keep only the Chinese title + page ID */
.in-reader .crumbs { display: none; }

/* ---- EWD circuit diagrams (inline SVG) ---- */
.manual svg { max-width: 100%; height: auto; background: #fff; cursor: zoom-in; }
.lang-en .svg-zh, .lang-zh .svg-en, .lang-both .svg-en { display: none; }
.svg-legend { margin: 6px 0 18px; font-size: 14px; }
.svg-legend summary { cursor: pointer; }
.svg-legend table { border-collapse: collapse; margin-top: 6px; }
.svg-legend td { border: 1px solid #d3ccbc; padding: 3px 8px; vertical-align: top; }
.svg-view { position: fixed; inset: 0; z-index: 95; background: #fff; overflow: hidden; touch-action: none; }
.svg-view .svg-stage { position: absolute; left: 0; top: 0; transform-origin: 0 0; }
.svg-view .svg-stage svg { display: block; cursor: grab; background: #fff; max-width: none; }
.svg-view .svg-tools { position: absolute; right: 12px; top: 12px; display: flex; gap: 6px; z-index: 2; }
.svg-view .svg-tools button { width: 40px; height: 40px; font-size: 18px; background: #fff; border: 1.5px solid #15171a; cursor: pointer; }
.svg-view .svg-hint { position: absolute; left: 12px; bottom: 10px; font: 12px/1.4 ui-monospace, Menlo, monospace; color: #6b6e70; background: rgba(255,255,255,.85); padding: 2px 6px; }

/* ---- Circuit diagrams: pages that differ between the 2024 and 2025-refresh editions ---- */
.ed[data-ed="2025"] { display: none; }
html.ed-2025 .ed[data-ed="2025"] { display: block; }
html.ed-2025 .ed[data-ed="2024"] { display: none; }
.ed-bar { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin: -4px 0 12px; padding: 8px 10px;
  border: 1.5px solid var(--ink); background: var(--paper); }
.ed-bar span { flex: 1 1 220px; font-size: 14px; color: var(--ink-2); }
.ed-bar button { font: 600 13px/1 var(--f-cond); letter-spacing: .08em; text-transform: uppercase; background: #fff; color: var(--ink);
  border: 1px solid var(--ink); padding: 8px 12px 7px; cursor: pointer; }
.ed-bar button.on { background: var(--ink); color: #fff; }
.ed-changes { margin: 0 0 18px; border: 1px solid var(--hair); background: #fffdf2; padding: 6px 12px; }
.ed-changes summary { font: 700 14px/1.6 var(--f-cond); letter-spacing: .08em; text-transform: uppercase; cursor: pointer; }
.ed-changes ul { margin: 4px 0 6px; padding-left: 18px; font-size: 14.5px; }
.ed-changes li { margin: 2px 0; }
.ed-lab { display: inline-block; font: 12px/1.5 var(--f-mono); border: 1px solid var(--hair); background: #fff; padding: 0 4px; margin: 1px 4px 1px 0; }
.ed-note { font: 12px/1.4 var(--f-mono); color: var(--muted); margin: -6px 0 14px; }
.ed-note.china { font: 14.5px/1.5 var(--f-body); color: var(--ink); border: 1.5px solid var(--no); background: #fdf3f2; padding: 8px 12px; margin: 0 0 16px; }
.ed-note.china b { color: var(--no); }

/* sticky year bar; "What changed" opens as a panel under it */
.ed-bar { position: sticky; top: 0; z-index: 6; }
.ed-bar .ed-changes { flex-basis: 100%; margin: 2px 0 0; position: relative; }
.ed-bar .ed-changes[open] ul { position: absolute; left: -11px; right: -11px; top: 100%; z-index: 7; max-height: 55vh; overflow: auto;
  background: #fffdf2; border: 1.5px solid #15171a; padding: 8px 12px 8px 30px; margin: 4px 0 0; box-shadow: 0 6px 18px rgba(0,0,0,.18); }
.ed-bar .ed-changes { border: 0; background: none; padding: 0; }

/* page opened on its own (search result, bookmark): link into the full reader */
.solo-bar { display: flex; flex-wrap: wrap; gap: 4px 14px; align-items: baseline; margin: -16px -26px 18px; padding: 10px 26px;
  background: var(--ink); color: #fff; text-decoration: none; font: 14px/1.4 var(--f-body); }
.solo-bar b { font: 600 13px/1.4 var(--f-mono); letter-spacing: .06em; text-transform: uppercase; }
.solo-bar span { color: var(--mark); }
.solo-bar:hover span { text-decoration: underline; }
@media (max-width: 760px) { .solo-bar { margin: -12px -12px 16px; padding: 10px 12px; } }
@media print { .solo-bar { display: none; } }

/* circuit pages: the diagram heading is the page's <h1> for search engines; keep the look of the source's <h3> */
.manual h1.topictitle1 { font-size: 1.17em; font-weight: bold; margin: 1em 0; }
