/* 点検報告書 試作2 */
:root {
  --bg: #f3f4f6; --card: #fff; --line: #d6d9de; --ink: #1f2328; --muted: #6b7280;
  --pri: #c8102e; --pri-ink: #fff; --sel: #dbe9fd; --cur: #1a73e8; --bad: #c00; --warn: #fde2e2;
  --ui: "BIZ UDPGothic", "Yu Gothic UI", "Meiryo", sans-serif;
  --mincho: "BIZ UDMincho", "Yu Mincho", "YuMincho", "MS Mincho", serif;
}
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--ink); font: 14px/1.5 var(--ui); }
a { color: #0b57d0; text-decoration: none; }
.muted { color: var(--muted); } .small { font-size: 12px; } .mono { font-family: Consolas, monospace; }
.ctr { text-align: center; } .right { text-align: right; } .nowrap { white-space: nowrap; }
.sp { flex: 1; }
.hint { color: var(--muted); font-size: 12px; margin: 6px 0; }
.tag { display: inline-block; font-size: 11px; background: #eee; color: #777; border-radius: 3px; padding: 0 5px; }

/* 上の帯 */
.top { display: flex; align-items: center; gap: 18px; height: 46px; padding: 0 16px; background: #fff; border-bottom: 3px solid var(--pri); position: sticky; top: 0; z-index: 20; }
.brand { display: flex; align-items: center; gap: 7px; font-weight: 700; color: var(--ink); font-size: 16px; white-space: nowrap; }
.brand-mark { width: 34px; height: 34px; display: block; }
.brand-type { height: 25px; display: block; }
.brand small { color: var(--muted); font-weight: 400; font-size: 11px; }

.acts[hidden] { display: none !important; }
/* 物件一覧：作った書類のバッジ */
.dbadge { display: inline-flex; align-items: center; gap: 3px; font-size: 11.5px; line-height: 1; padding: 3px 7px; border-radius: 10px; margin: 1px 3px 1px 0; white-space: nowrap; border: 1px solid transparent; }
.dbadge b { font-size: 10.5px; background: rgba(255,255,255,.75); border-radius: 8px; padding: 1px 4px; }
.dbadge:hover { filter: brightness(.95); text-decoration: none; }
.b-shobo { background: #fdecee; color: #a40f26; border-color: #f3c3ca; }
.b-boka { background: #fff2df; color: #8a4b00; border-color: #f3d6a8; }
.b-bosai { background: #eaf3ff; color: #1d4f91; border-color: #c4daf6; }
.b-chakko { background: #e8f5ec; color: #1e6b3a; border-color: #bfe0c9; }
.b-j12 { background: #f1ecfb; color: #5a3c99; border-color: #d9cdf2; }
.b-etc { background: #eef0f2; color: #555; }
.qimg { display: flex; align-items: center; gap: 12px; } .qimg img { max-width: 260px; max-height: 170px; border: 1px solid var(--line); }
/* 共通項目：資格者を選んで鑑に写す */
.qpick { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; background: #fff8e6; border: 1px solid #f0dca8; border-radius: 6px; padding: 8px 10px; margin-bottom: 10px; }
.qpick label { display: flex; align-items: center; gap: 6px; } .qpick label span { font-size: 12px; color: #6b5a2a; font-weight: 700; }
.qpick .hint { flex-basis: 100%; margin: 0; }

/* 着工届・設置届：設備のチェック */
.eqpick { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-bottom: 10px; }
.eqpick .eqh { font-size: 12px; font-weight: 700; color: #555; margin-right: 4px; }
.eqpick label { border: 1px solid #c9cdd3; border-radius: 16px; padding: 3px 10px; cursor: pointer; background: #fff; white-space: nowrap; }
.eqpick label.on { background: #fdecee; border-color: var(--pri); color: var(--pri); font-weight: 700; }
.eqpick .hint { flex-basis: 100%; margin: 2px 0 0; }

/* 物件の画面：書類の種類ごとのまとまり */
.pblock { border: 1px solid var(--line); border-radius: 8px; margin: 0 0 12px; overflow: hidden; }
.pblock.on { border-color: #e7a3ad; }
.pbh { display: flex; align-items: center; gap: 8px; padding: 8px 10px; background: #f7f8f9; border-bottom: 1px solid var(--line); }
.pbh { flex-wrap: wrap; } .pbh b { font-size: 15px; white-space: nowrap; } .pbh .btn, .pbh span { white-space: nowrap; }
.pblock .list { border: 0; }
.pblock tr[data-pid] { cursor: default; }

/* トップ画面 */
.home { min-height: calc(100vh - 46px); display: flex; flex-direction: column; }
.hero { background: #fff; border-bottom: 1px solid var(--line);
  background-image: radial-gradient(circle at 92% 20%, rgba(200,16,46,.07), transparent 42%), repeating-linear-gradient(0deg, transparent 0 27px, rgba(31,35,40,.035) 27px 28px); }
.hero-in { max-width: 1120px; margin: 0 auto; padding: 40px 24px 34px; display: flex; gap: 40px; align-items: center; }
.hero-txt { flex: 1; min-width: 0; }
.hero-kicker { color: var(--pri); font-weight: 700; letter-spacing: .12em; font-size: 15px; }
/* 11/21 深夜：トップの字を太く、AI に頼む欄 */
.hero-stat .hero-types { display: flex; flex-wrap: wrap; gap: 4px 12px; border-left-color: #c9cdd3; } .hero-stat .hero-types span { font-size: 12.5px; font-weight: 700; color: #444; }
.hero-stat .hero-types b { font-size: 14px; font-weight: 800; color: var(--pri); }
.home-body .ai { max-width: 1120px; margin: 0 auto; border-width: 2px; border-color: #e7c9ce; }
.ai h2 { display: flex; align-items: center; gap: 8px; font-size: 18px; font-weight: 800; }
.ai-mark { background: linear-gradient(135deg, #c8102e, #7a0a1c); color: #fff; font-size: 12px; font-weight: 800; border-radius: 6px; padding: 3px 7px; letter-spacing: .05em; }
.ai-row { display: flex; gap: 8px; }
.ai-row textarea { flex: 1; font: inherit; font-size: 16px; font-weight: 600; padding: 10px 12px; border: 2px solid #c9cdd3; border-radius: 8px; resize: vertical; }
.ai-row textarea:focus { outline: none; border-color: var(--pri); }
.ai-row .btn { font-size: 16px; font-weight: 700; padding: 0 22px; }
.ai-ex { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0 4px; }
.ai-chip { font: inherit; font-size: 13px; font-weight: 600; border: 1px solid #e3b8bf; background: #fff6f7; color: #8d0d22; border-radius: 16px; padding: 4px 12px; cursor: pointer; }
.ai-chip:hover { background: #fdecee; }
.ai-res { margin-top: 10px; border-top: 1px dashed #e3b8bf; padding-top: 10px; }
.ai-rt { font-weight: 800; font-size: 15px; margin-bottom: 6px; }
.ai-list { margin: 0 0 8px; padding-left: 18px; max-height: 320px; overflow: auto; } .ai-list li { margin: 3px 0; }
.hero-title { display: flex; align-items: center; gap: 16px; margin: 10px 0 8px; line-height: 1; }
.hero-title small { font-size: 14px; color: var(--muted); font-weight: 400; align-self: flex-end; margin-bottom: 4px; }
.hero-mark { width: 92px; height: 92px; }
.hero-type { height: 70px; }
.hero-lead { margin: 6px 0 18px; font-size: 15px; color: #3b4048; line-height: 1.8; }
.hero-search { display: flex; gap: 8px; max-width: 620px; margin-top: 14px; }
.hero-search input { flex: 1; font: inherit; font-size: 17px; font-weight: 600; padding: 11px 14px; border: 2px solid #b9bfc7; border-radius: 8px; }
.hero-search input:focus { outline: 2px solid #9ec2fa; border-color: #5b8def; }
.hero-search .btn { padding: 8px 24px; font-size: 16px; font-weight: 700; }
.hero-act { display: flex; gap: 8px; margin-top: 12px; flex-wrap: wrap; }
.hero-stat { display: grid; gap: 10px; min-width: 220px; max-width: 300px; }
.hero-stat div { background: #fff; border: 1px solid var(--line); border-left: 4px solid var(--pri); border-radius: 6px; padding: 8px 14px; display: flex; align-items: baseline; gap: 8px; }
.hero-stat b { font-size: 32px; font-weight: 800; font-variant-numeric: tabular-nums; } .hero-stat span { color: #444; font-size: 14px; font-weight: 700; }
.home-body { max-width: 1120px; width: 100%; margin: 0 auto; padding: 24px; flex: 1; }
.hh { font-size: 15px; margin: 0 0 10px; letter-spacing: .05em; }
.docs { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 12px; }
.doc { position: relative; display: grid; grid-template-columns: 44px 1fr; grid-template-rows: auto auto auto; column-gap: 12px; background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 14px 14px 12px; color: var(--ink); transition: border-color .15s, box-shadow .15s; }
.doc[href]:hover { border-color: var(--pri); box-shadow: 0 2px 10px rgba(200,16,46,.10); }
.doc-ico { grid-row: 1 / 4; width: 44px; height: 44px; border-radius: 8px; background: #fdecee; color: var(--pri); display: grid; place-items: center; }
.doc-ico svg { width: 26px; height: 26px; }
.doc-t { font-weight: 700; font-size: 15px; } .doc-s { font-size: 12px; color: var(--muted); }
.doc-st { justify-self: start; margin-top: 6px; font-size: 11px; border-radius: 10px; padding: 1px 8px; background: #e8f3ec; color: #1e6b3a; }
.doc.first { border-color: var(--pri); } .doc.first .doc-st { background: var(--pri); color: #fff; }
.doc.plan { background: #f7f8f9; color: #8a9099; cursor: default; } .doc.plan .doc-ico { background: #eceef1; color: #9aa0a8; }
.doc.plan .doc-st { background: #eceef1; color: #7b818a; }
.home-cols { display: grid; grid-template-columns: 1.3fr 1fr; gap: 14px; margin-top: 18px; }
.home-recent { border: 0; } .home-recent tr { cursor: pointer; } .home-recent tr:hover td { background: #fafbfc; }
.steps { list-style: none; margin: 0; padding: 0; }
.steps li { display: flex; gap: 10px; padding: 7px 0; border-bottom: 1px dashed #e3e5e8; } .steps li:last-child { border-bottom: 0; }
.step-n { flex: none; width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; font-size: 12px; font-weight: 700; background: #eceef1; color: #6b7280; }
.steps li.now .step-n { background: var(--pri); color: #fff; }
.step-now { font-size: 11px; color: var(--pri); border: 1px solid var(--pri); border-radius: 10px; padding: 0 6px; }
.home-foot { text-align: center; color: #555; font-size: 13px; font-weight: 700; letter-spacing: .1em; padding: 18px 16px 24px; font-family: var(--mincho); }
@media (max-width: 820px) {
  .hero-in { flex-direction: column; align-items: stretch; gap: 20px; padding: 28px 16px; }
  .hero-mark { width: 60px; height: 60px; } .hero-type { height: 44px; } .brand-type { height: 20px; }
  .hero-stat { grid-template-columns: repeat(3, 1fr); min-width: 0; }
  .home-body { padding: 16px; } .home-cols { grid-template-columns: 1fr; }
  .top { gap: 8px; padding: 0 10px; } .brand small, .who { display: none; } .nav a { white-space: nowrap; padding: 12px 6px; }
  .hero-stat div { flex-direction: column; gap: 0; padding: 6px 10px; } .hero-stat span { white-space: nowrap; }
}
@media print { .home { display: none; } }
.nav a { padding: 12px 10px; color: var(--ink); } .nav a.on { color: var(--pri); font-weight: 700; box-shadow: inset 0 -3px var(--pri); }
.who { font-size: 12px; color: var(--muted); }

/* 部品 */
.btn { display: inline-block; font: inherit; border: 1px solid #bbb; background: #fff; border-radius: 6px; padding: 6px 12px; cursor: pointer; }
.btn:hover { background: #f5f5f5; } .btn:disabled { opacity: .45; cursor: default; }
.btn.pri { background: var(--pri); border-color: var(--pri); color: var(--pri-ink); } .btn.pri:hover { filter: brightness(1.08); }
.btn.danger { color: var(--bad); border-color: #e6b3b3; }
.btn.sm { padding: 2px 9px; font-size: 13px; }
.in, .fi { font: inherit; border: 1px solid #c9cdd3; border-radius: 4px; padding: 4px 6px; background: #fff; }
.fi:focus, .in:focus { outline: 2px solid #9ec2fa; border-color: #5b8def; }
.page { max-width: 1280px; margin: 0 auto; padding: 16px; }
.bar { display: flex; align-items: center; gap: 8px; margin: 4px 0 12px; }
.bar h1 { font-size: 20px; margin: 0; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: 8px; padding: 14px 16px; margin-bottom: 14px; }
.card h2 { font-size: 16px; margin: 0 0 10px; } .card h3 { font-size: 14px; margin: 14px 0 6px; }
.crumb { margin-bottom: 10px; color: var(--muted); }
.filters { display: flex; gap: 14px; align-items: center; margin-bottom: 10px; flex-wrap: wrap; }
.list { width: 100%; border-collapse: collapse; background: #fff; border: 1px solid var(--line); }
.list th { background: #f0f1f3; text-align: left; font-weight: 600; font-size: 12px; color: #444; }
.list th, .list td { border-bottom: 1px solid #e6e8eb; padding: 7px 8px; vertical-align: middle; }
.list tbody tr[data-id], .list tbody tr[data-pid] { cursor: pointer; } .list tbody tr[data-id]:hover, .list tbody tr[data-pid]:hover { background: #fff7f8; }
.list.small td, .list.small th { padding: 4px 6px; font-size: 13px; }
.list.mt .fi { width: 100%; } .list.mt .fi.w { min-width: 260px; }
.toast { position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%); background: #222; color: #fff; padding: 8px 16px; border-radius: 6px; z-index: 99; }
kbd { border: 1px solid #bbb; border-bottom-width: 2px; border-radius: 3px; padding: 0 4px; font-size: 11px; background: #fff; font-family: inherit; }

/* 物件 */
.cols2 { display: grid; grid-template-columns: minmax(420px, 5fr) 6fr; gap: 14px; align-items: start; }
.form { display: grid; grid-template-columns: 1fr; gap: 6px; }
.form label { display: grid; grid-template-columns: 140px 1fr; align-items: center; gap: 8px; }
.form label > span:first-child { color: #555; font-size: 13px; }
.form .fi { width: 100%; } .form .inline .fi { width: auto; }
.form.two { grid-template-columns: 1fr 1fr; column-gap: 20px; }
.form .sub { margin-top: 10px; font-weight: 700; font-size: 13px; color: var(--pri); border-top: 1px dashed var(--line); padding-top: 8px; }
.inline { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.rb { display: inline-flex !important; grid-template-columns: none !important; gap: 4px !important; margin-right: 10px; }
.blk { display: block; margin-top: 10px; } .blk span { display: block; font-size: 13px; color: #555; }
.ptypes { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-bottom: 14px; }
.ptype { font: inherit; font-weight: 700; border: 2px solid var(--line); background: #fff; border-radius: 8px; padding: 14px 6px; cursor: pointer; }
.ptype.on { border-color: var(--pri); color: var(--pri); background: #fff5f6; }
.ptype.off { color: #999; } .ptype small { display: block; font-weight: 400; font-size: 11px; }

/* 点検画面 */
.pbar { display: flex; align-items: center; gap: 12px; padding: 8px 16px; background: #fff; border-bottom: 1px solid var(--line); position: sticky; top: 49px; z-index: 15; }
.pbar .back { font-weight: 700; }
.tabs { display: flex; gap: 2px; padding: 6px 12px 0; background: #e7e9ec; overflow-x: auto; position: sticky; top: 94px; z-index: 14; border-bottom: 1px solid #c9cdd3; }
.tab { padding: 6px 12px; border: 1px solid #c9cdd3; border-bottom: none; border-radius: 6px 6px 0 0; background: #f6f7f8; color: #333; white-space: nowrap; font-size: 13px; }
.tab.on { background: #fff; color: var(--pri); font-weight: 700; position: relative; top: 1px; }
.tab.ctab { background: #fff3d6; } .tab.ctab.on { background: #fff; }
.tab.todo { color: #999; }
.tabbody { padding: 14px 16px 60px; }
.common { max-width: 1100px; margin: 0 auto; }
.forms { width: 100%; border-collapse: collapse; }
.forms th { text-align: left; font-size: 12px; color: #555; border-bottom: 1px solid var(--line); padding: 4px; }
.forms td { padding: 2px 4px; border-bottom: 1px solid #f0f1f3; }
.forms tr.on td { background: #fff8e6; } .forms tr.sub td { background: #fffcf3; }
.forms tr.grp td { background: #f0f1f3; font-weight: 700; font-size: 12px; padding: 5px 6px; }
.forms .fname { cursor: pointer; } .forms .fi { width: 100%; } .forms .qty { width: 60px; }
.forms input[type=checkbox] { width: 17px; height: 17px; }

.sheetbar { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; max-width: 210mm; margin: 0 auto 8px; background: #fff; border: 1px solid var(--line); border-radius: 6px; padding: 6px 10px; position: sticky; top: calc(94px + var(--tabsH, 40px)); z-index: 10; }
/* タブが増えたら横スクロールではなく段を増やす（消防点検・着工設置。11/22 土谷さん）。下の固定位置はタブの高さ --tabsH（app.js で測る）に合わせる */
.tabs.wrap { flex-wrap: wrap; overflow-x: visible; row-gap: 3px; }
.tabs.wrap .tab { border-bottom: 1px solid #c9cdd3; border-radius: 6px; }
.tabs.wrap .tab.on { border-bottom-color: #fff; border-radius: 6px 6px 0 0; }
.sheetbar .btn.j { font-family: var(--mincho); min-width: 34px; font-size: 15px; } .sheetbar .btn.bad { color: var(--bad); }
.selinfo { font-size: 12px; color: var(--cur); min-width: 90px; }
.keys { font-size: 11px; color: var(--muted); }
.sheetwrap { display: flex; flex-direction: column; align-items: center; gap: 16px; }

/* ───────── 様式（紙） */
.sheet { width: 210mm; min-height: 297mm; background: #fff; padding: 10mm 10mm 8mm; box-shadow: 0 1px 4px rgba(0, 0, 0, .18); font-family: var(--mincho); font-size: 10.5pt; color: #000; }
.sh-top { display: flex; justify-content: space-between; font-size: 9.5pt; margin-bottom: 1mm; font-family: var(--ui); font-weight: 700; }
.sheet h2.t1, .sheet h2.t2 { text-align: center; font-weight: 400; font-size: 13pt; margin: 2mm 0 4mm; letter-spacing: .05em; }
.sheet h2.t1 { font-size: 14pt; margin: 6mm 0 6mm; }
table.f { width: 100%; border-collapse: collapse; table-layout: fixed; }
table.f + table.f { border-top: none; }
table.f th, table.f td { border: 1px solid #000; padding: 1px 3px; font-weight: 400; vertical-align: middle; }
table.f th { text-align: center; }
table.f .ttl { letter-spacing: .3em; }
table.f th.dist { text-align: justify; text-align-last: justify; padding: 1px 4px; }
table.f .small, .sheet .small { font-size: 8.5pt; }
table.f tr.tall td, table.f tr.tall th { height: 16mm; }
table.f .fi { font-family: var(--mincho); font-size: 10pt; border: 1px dashed #b7c4dd; background: #fbfdff; padding: 1px 3px; width: 100%; }
table.f td .fi[style] { width: auto; }
table.f .fi.ta { resize: vertical; width: 100%; display: block; }
table.f select.fi { width: auto; }
.maru { display: inline-block; border: 1.3px solid #000; border-radius: 50%; padding: 0 .35em; line-height: 1.25; }
.pick { cursor: pointer; } .pick:hover { background: #eef4ff; }
.pre { white-space: pre-wrap; }
.hint { font-family: var(--ui); }
.notes { font-size: 8pt; margin-top: 1.5mm; line-height: 1.45; }
.empty { text-align: center; color: #666; padding: 16mm 0; font-family: var(--ui); }
.warn { background: var(--warn); }

/* 点検票の表 */
table.grid { margin-top: -1px; }
table.grid td { height: 5.6mm; font-size: 9.5pt; }
table.grid tr.sec td { text-align: center; letter-spacing: .4em; background: #fff; height: 5.6mm; }
table.grid td.g1, table.grid td.g2 { text-align: center; font-size: 8.5pt; line-height: 1.15; padding: 1px; }
table.grid td.v { writing-mode: vertical-rl; text-orientation: upright; letter-spacing: .1em; }
table.grid td.lbl { text-align: justify; text-align-last: justify; padding: 1px 4px; font-size: 9pt; white-space: nowrap; overflow: hidden; }
table.grid td.c { cursor: cell; user-select: none; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
table.grid td.c.j { text-align: center; font-size: 11pt; }
table.grid td.c.t { font-size: 8.5pt; }
table.grid td.c.bad { color: var(--bad); font-weight: 700; }
table.grid td.c.auto { color: #444; }
table.grid td.c.sel { background: var(--sel); }
table.grid td.c.cur { outline: 2px solid var(--cur); outline-offset: -2px; }
table.grid td.c:hover { background: #f1f6ff; } table.grid td.c.sel:hover { background: var(--sel); }
input.ced { width: 100%; border: none; outline: none; font: inherit; padding: 0; background: #fffbe0; }
table.hd2 { margin-top: -1px; } table.hd2 td, table.hd2 th { height: 6mm; }
table.bt { margin-top: -1px; } table.bt td, table.bt th { font-size: 8.5pt; height: 5.6mm; }
table.bt th.vt { writing-mode: vertical-rl; letter-spacing: .3em; font-size: 9pt; }
table.bt td.biko { height: 26mm; vertical-align: top; } table.bt td.biko .ta { min-height: 24mm; }
table.bt .fi { font-size: 8.5pt; width: 100%; }

/* 表紙 */
.hyoshi .right { text-align: right; margin: 2mm 0 4mm; }
.hyoshi .dono { margin: 2mm 0 4mm; }
.hyoshi table.todoke { margin: 0 0 4mm auto; border-collapse: collapse; }
.hyoshi table.todoke td { padding: 1.5mm 2mm; } .hyoshi .todoke .lb { vertical-align: top; } .hyoshi .todoke .k { white-space: nowrap; }
.hyoshi .honbun { margin: 4mm 0; text-indent: 1em; line-height: 1.8; }
.hyoshi .ki { text-align: center; margin: 3mm 0; }
table.hy td, table.hy th { height: 13mm; } table.hy th.v { writing-mode: vertical-rl; letter-spacing: .5em; }
table.uk { margin-top: 6mm; } table.uk td { height: 32mm; } table.uk th { width: 33%; }

/* 総括表 */
table.sk tr.srow td { height: 21mm; vertical-align: top; font-size: 9.5pt; } table.sk tr.srow td.ctr { vertical-align: middle; }
table.sk .hint { font-size: 8pt; color: #888; }

/* 点検者一覧表 */
table.tk { margin-bottom: 5mm; font-size: 9pt; } table.tk td, table.tk th { height: 5.2mm; }
table.tk th.left { text-align: left; padding-left: 3mm; background: #fafafa; }
table.tk td.setsubi { vertical-align: top; padding: 2mm; line-height: 1.7; }
table.tk .big { font-size: 11pt; font-weight: 400; }

/* マスタ */
.subtabs { display: flex; gap: 4px; margin-bottom: 12px; }
.subtabs a { padding: 6px 14px; border-radius: 6px; background: #fff; border: 1px solid var(--line); color: #333; }
.subtabs a.on { background: var(--pri); color: #fff; border-color: var(--pri); }
.qwrap { display: grid; grid-template-columns: 200px 1fr; gap: 14px; align-items: start; }
.qlist { display: flex; flex-direction: column; gap: 4px; }
.qlist a { padding: 7px 10px; background: #fff; border: 1px solid var(--line); border-radius: 6px; cursor: pointer; color: #333; }
.qlist a.on { border-color: var(--pri); color: var(--pri); font-weight: 700; }
.qdetail .list .fi { width: 100%; }

/* ───────── 印刷 */
#print-root { display: none; }
@page { size: A4; margin: 0; }
@media print {
  html, body { background: #fff; }
  #app { display: none !important; }
  #print-root { display: block; }
  #print-root .sheet { box-shadow: none; margin: 0; page-break-after: always; break-after: page; min-height: auto; }
  #print-root .sheet:last-child { page-break-after: auto; break-after: auto; }
  table.f tr { break-inside: avoid; }
}
table.grid th.tc { font-size: 8pt; padding: 0; white-space: nowrap; }

/* ───────── 11/20 追加 */
.page.wide { max-width: 1600px; }
.common { max-width: 1500px; }
.chkinfo { font-size: 13px; color: var(--cur); }
.list tr.ck td { background: #eef4ff; }
.memodot { display: inline-block; font-size: 10px; background: #fff1b8; color: #8a5a00; border: 1px solid #f0d36b; border-radius: 3px; padding: 0 4px; vertical-align: 1px; font-weight: 400; }
.memo-in textarea { width: 100%; background: #fffbe6; }
.mt8 { margin-top: 8px; }
.in.sm { padding: 1px 4px; font-size: 12px; }

/* 小窓 */
.modal { position: fixed; inset: 0; background: rgba(0, 0, 0, .35); z-index: 50; display: flex; align-items: flex-start; justify-content: center; padding: 6vh 16px; overflow: auto; }
.mbox { background: #fff; border-radius: 10px; padding: 18px 20px; width: min(980px, 100%); box-shadow: 0 10px 30px rgba(0, 0, 0, .25); }
.mbox h2 { font-size: 17px; margin: 0 0 8px; }
.mscroll { max-height: 55vh; overflow: auto; border: 1px solid var(--line); }
table.bulk { width: 100%; border-collapse: collapse; }
table.bulk th { text-align: left; font-weight: 600; font-size: 13px; width: 170px; padding: 4px 8px; }
table.bulk td { padding: 3px 4px; } table.bulk .fi { width: 100%; }
table.bulk input[type=checkbox] { width: 17px; height: 17px; }
.bulknames { display: flex; flex-wrap: wrap; gap: 4px 10px; font-size: 12px; color: #444; background: #f6f7f8; border-radius: 6px; padding: 6px 10px; margin-bottom: 8px; }

/* 点検画面の上の帯：メモと出力 */
.pbar .memo { flex: 1; min-width: 0; background: #fff6c8; border: 2px solid #f0c419; color: #6b3d00; font-weight: 700; border-radius: 6px; padding: 3px 10px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 14px; }
.pbar .memo b { background: #c8102e; color: #fff; border-radius: 3px; padding: 0 6px; margin-right: 8px; font-size: 12px; }
.dd { position: relative; }
.ddm { position: absolute; right: 0; top: calc(100% + 4px); background: #fff; border: 1px solid var(--line); border-radius: 8px; box-shadow: 0 6px 20px rgba(0, 0, 0, .15); min-width: 290px; padding: 6px; z-index: 30; }
.ddm button { display: block; width: 100%; text-align: left; font: inherit; background: none; border: none; padding: 7px 10px; border-radius: 5px; cursor: pointer; }
.ddm button:hover { background: #f3f5f8; }
.ddm hr { border: none; border-top: 1px solid var(--line); margin: 4px 0; }
/* 出力メニューの中の「出力するもの」（11/20 夜） */
.ddm.outm { min-width: 320px; }
.ddm .outl { max-height: 50vh; overflow: auto; padding: 2px 4px; }
.ddm .outi { display: flex; gap: 6px; align-items: center; padding: 3px 6px; border-radius: 4px; cursor: pointer; font-size: 13px; }
.ddm .outi:hover { background: #f3f5f8; }
.ddm .outq { display: flex; gap: 4px; padding: 4px; }
.ddm .outq button { width: auto; flex: 1; text-align: center; border: 1px solid var(--line); padding: 4px 6px; font-size: 12px; }
.ddh { font-size: 12px; color: var(--muted); padding: 4px 10px; }

/* タブ（出力のチェック付き） */
.tabs { align-items: flex-end; }
div.tab { display: flex; align-items: center; gap: 4px; padding: 4px 10px 4px 6px; }
div.tab a { color: inherit; }
div.tab.off a { color: #aaa; text-decoration: line-through; }
.outck { width: 14px; height: 14px; margin: 0; }
.autosel { margin: 0 0 4px auto; white-space: nowrap; }

/* 共通項目：左に様式の一覧、右に使う様式 */
.form.three { grid-template-columns: repeat(3, 1fr); column-gap: 20px; }
.form.three label { grid-template-columns: 110px 1fr; }
.acts { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-top: 10px; }
.fsel { display: grid; grid-template-columns: 340px 1fr; gap: 14px; align-items: start; }
.fcat { position: sticky; top: calc(100px + var(--tabsH, 40px)); }
.fcat .in { width: 100%; margin-bottom: 6px; }
.clist { max-height: calc(100vh - 260px); overflow: auto; }
.cgrp { font-weight: 700; font-size: 12px; background: #f0f1f3; padding: 4px 8px; margin-top: 6px; border-radius: 4px; }
.crow { display: flex; align-items: center; gap: 6px; padding: 4px 6px; border-bottom: 1px solid #f2f3f5; cursor: pointer; font-size: 13px; }
.crow.sub { padding-left: 26px; font-size: 12px; } .crow.sub .cn::before { content: '└ '; color: #aaa; }
.crow:hover { background: #f7f9fc; } .crow.on { background: #fff8e6; font-weight: 700; }
.crow input { width: 16px; height: 16px; flex: none; } .crow .cn { flex: 1; } .crow .cno { font-size: 11px; color: var(--muted); font-weight: 400; white-space: nowrap; }
.fitem { border: 1px solid var(--line); border-radius: 8px; padding: 6px 10px; margin-bottom: 6px; background: #fff; }
.fitem.k-fixed { background: #fbfbfc; }
.fitem.k-list { border-style: dashed; }
.fitem.child { margin-left: 28px; position: relative; }
.fitem.child::before { content: '└'; position: absolute; left: -20px; top: 8px; color: #aaa; }
.fitem.dragging { opacity: .4; }
.fitem.dropb { box-shadow: 0 -3px 0 var(--cur); } .fitem.dropa { box-shadow: 0 3px 0 var(--cur); }
.fhead { display: flex; align-items: center; gap: 8px; }
.grip { cursor: grab; color: #999; letter-spacing: -2px; user-select: none; padding: 0 2px; }
.fno { display: inline-block; min-width: 22px; text-align: center; font-size: 11px; background: #e7e9ec; border-radius: 10px; }
.qtyl { font-size: 12px; color: #555; } .qty { width: 58px; }
table.insts { width: 100%; border-collapse: collapse; margin-top: 4px; }
table.insts td { padding: 2px 4px; } table.insts td:first-child { width: 48px; } table.insts td:last-child { width: 260px; }
table.insts .fi { width: 100%; }
/* 使う様式：1行＝1部（11/20） */
.fitem .irow { display: grid; grid-template-columns: 1fr 260px; gap: 8px; align-items: center; margin-top: 4px; }
.fitem .irow .fi { width: 100%; }
.fitem .sono { font-weight: bold; color: var(--cur, #c00); margin-left: 0; }
/* 1行に並べる（11/20 深夜）：名前 → 部の名前 → 点検者 → 部数 → 外す */
.fitem { padding: 4px 8px; margin-bottom: 4px; }
.fhead { gap: 6px; }
.fhead .fname { flex: 1 1 auto; min-width: 7em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fhead .flabel { flex: 0 1 150px; min-width: 70px; }
.fhead .finsp { flex: 0 1 170px; min-width: 90px; }
.fhead .finsp .fi { width: 100%; }
.fhead .qtyl { white-space: nowrap; } .fhead .qty { width: 48px; }
.fhead .btn { white-space: nowrap; flex: none; }
/* 11/21：一覧表の点検者の欄はグレーで入力できない。見出しの1行（編集できない） */
.fhead .finsp .fi:disabled { background: #e9eaec; border-color: #d6d8dc; cursor: not-allowed; }
.fhdr { padding: 2px 9px 2px; margin: 8px 0 2px; font-size: 12px; color: var(--muted); font-weight: 700; user-select: none; }
.fhdr .fname { font-weight: 700; }
.fhdr .grip, .fhdr .fno, .fhdr .btn { visibility: hidden; }
.fhdr .flabel, .fhdr .finsp { padding-left: 4px; }
/* 点検設備名：機器ごとに1行（防排煙の旧様式） */
.pg.eq table.hdg th.vth { font-size: 10pt; padding: 0.4mm 0; text-align: center; vertical-align: middle; }
.pg.eq table.hdg th.vth .vtx { line-height: 1.25; letter-spacing: 0; }
table.hdg td.num { text-align: right; padding-right: 1mm; white-space: nowrap; } table.hdg td.num .fi { text-align: center; }
table.hdg .dai { margin-left: 2mm; }
.tchs { font-size: 7pt; margin-left: 1mm; white-space: nowrap; letter-spacing: 0; }
.tchs .tch { cursor: pointer; } .tchs .tch:hover { background: #fff3c4; }
.fon h2 { display: flex; align-items: center; gap: 8px; }

/* 点検者を探す欄 */
.combobox { position: fixed; z-index: 60; background: #fff; border: 1px solid #b9c3d3; border-radius: 6px; box-shadow: 0 6px 18px rgba(0, 0, 0, .18); max-height: 280px; overflow: auto; font-family: var(--ui); font-size: 13px; }
.combobox .ci { padding: 5px 10px; cursor: pointer; display: flex; gap: 8px; align-items: baseline; }
.combobox .ci small { color: var(--muted); } .combobox .ci .q { margin-left: auto; color: #0b57d0; }
.combobox .ci.on, .combobox .ci:hover { background: #e8f0fe; }
.combobox.shobo .ci { flex-direction: column; gap: 0; }
.combobox.shobo .ci .q { margin-left: 0; color: var(--muted); font-size: 11px; }
.combobox.shobo .ci .q.warn { color: #b06000; }
.combobox .ci.clear { color: var(--muted); border-top: 1px solid #eee; } .combobox .ci.none { color: var(--muted); cursor: default; }
table.f input.combo { width: 50mm; }

/* 点検票：フィルハンドル・総合点検の／ */
.sheetbar { max-width: none; top: 138px; }
.fillopt { font-size: 12px; background: #fff8d6; border-radius: 4px; padding: 0 6px; }
.fillopt:empty { display: none; }
.fillopt label { margin-left: 4px; }
table.grid td.c { position: relative; }
.fillh { position: absolute; right: 0; bottom: 0; width: 7px; height: 7px; background: var(--cur); border: 1px solid #fff; cursor: crosshair; z-index: 2; }
table.grid td.c.fillp { outline: 1.5px dashed var(--cur); outline-offset: -2px; }
#app table.grid td.c.lock { background: #f4f5f6; color: #888; cursor: default; }
.lockmsg { font-size: 8pt; letter-spacing: 0; color: #888; font-family: var(--ui); }
.kforms { font-size: 11px; } .kforms label { white-space: nowrap; margin-right: 6px; } .kforms input { vertical-align: -2px; }
table.lst td.c.t { font-size: 8.5pt; }
.rowsbar { margin-top: 4px; font-family: var(--ui); }
table.bt select.fi { width: 100%; max-width: 100%; }

/* ───────── 1ページ＝A4 1枚の枠（FireNET の寸法に合わせる。11/20） */
/* .sheet.pg：210×297mm、余白なし。中身は .pin（左20mm・上19.8mm・幅185mm）に入れる。様式番号は .pno（表のすぐ上・左・10pt） */
.sheet.pg { width: 210mm; height: 297mm; min-height: 0; padding: 0; position: relative; overflow: hidden; font-size: 10pt; }
.pg .pin { position: absolute; left: 20mm; top: 19.8mm; width: 185mm; }
.pg .pno { position: absolute; left: 20mm; top: 14.2mm; font-size: 10pt; line-height: 1; font-family: var(--mincho); white-space: nowrap; }
.pg .pnr { position: absolute; right: 5mm; top: 14.2mm; font-size: 10pt; line-height: 1; font-family: var(--mincho); white-space: nowrap; }
.pg .pnote { font-size: 9pt; line-height: 3.5mm; margin-top: 3.5mm; }
.pg table.f th, .pg table.f td { padding: 0 1mm; line-height: 1.15; }
.pg table.f { border: 0.35mm solid #000; }
.pg .jt { text-align: justify; text-align-last: justify; } /* 均等割付 */
.pg .vt { writing-mode: vertical-rl; text-orientation: upright; text-align: justify; text-align-last: justify; letter-spacing: 0; padding: 1mm 0 !important; }

/* 点検票（.eq） */
.pg.eq table.f { table-layout: fixed; width: 185mm; border-collapse: collapse; }
.pg.eq table.f + table.f { margin-top: -0.35mm; }
.pg.eq table.f th, .pg.eq table.f td { font-size: 10pt; vertical-align: middle; height: auto; overflow: hidden; }
.pg.eq span.jt { display: inline-block; }
.pg.eq th .jt, .pg.eq td .jt { display: inline-block; text-align: justify; text-align-last: justify; }
.pg.eq .w8 { width: 8mm; } .pg.eq .w20 { width: 20mm; } .pg.eq .w30 { width: 26mm; } .pg.eq .w40 { width: 34mm; } .pg.eq .w50 { width: 40mm; }
.pg.eq th.jt, .pg.eq td.jt { text-align: justify; text-align-last: justify; padding: 0 1.2mm; }
.pg.eq .sm2 { font-size: 8.5pt; line-height: 1.15; text-align: justify; text-align-last: justify; padding: 0 1mm; }
.pg.eq .sm3 { font-size: 8.5pt; line-height: 1.1; }
.pg.eq table.hd1 td, .pg.eq table.hd2x td { font-size: 10pt; }
.pg.eq table.hd1 th.jt { font-size: 9.5pt; padding: 0 0.6mm; white-space: nowrap; }
.pg.eq table.hd1 .fi, .pg.eq table.hd2x .fi, .pg.eq table.hd3 .fi { width: 100%; }
.pg.eq table.grid td.g { text-align: center; padding: 0.5mm 0; font-size: 9pt; line-height: 1.05; }
.pg.eq table.grid td.g.vt { writing-mode: vertical-rl; text-orientation: upright; letter-spacing: 0; text-align: justify; text-align-last: justify; }
.pg.eq table.grid td.g.hz { writing-mode: horizontal-tb; font-size: 8.5pt; padding: 0.5mm; }
.pg.eq table.grid td.lbl { font-size: 10pt; white-space: nowrap; padding: 0 1.2mm; line-height: 1.1; }
.pg.eq table.grid td.lbl.lft { text-align: left; text-align-last: left; white-space: normal; font-size: 9pt; }
.pg.eq table.grid td.c { height: auto; font-size: 9.5pt; padding: 0 1mm; }
.pg.eq table.grid td.c.j { font-size: 11pt; text-align: center; padding: 0; }
.pg.eq table.grid td.c[data-unit]::after { content: attr(data-unit); float: right; font-size: 8pt; color: #000; }
/* 絶縁抵抗の 常用・非常（内容欄に2つ並べる） */
.pg.eq table.grid td.dual { font-size: 8pt; padding: 0 0.6mm; white-space: nowrap; }
.pg.eq table.grid td.dual .dp { display: inline-flex; align-items: baseline; gap: 0.4mm; width: 50%; box-sizing: border-box; }
.pg.eq table.grid td.dual .dv { display: inline-block; width: 9mm; text-align: right; font-size: 9.5pt; }
.pg.eq table.grid td.dual input.dv { padding: 0 0.5mm; height: 4.6mm; border: 1px solid #bbb; background: #fffbe6; }
/* よく使う文言：不良内容のマスに入れる文 */
.ph.phf { border-left: 3px solid #d9534f; }
/* 自火報（その５）感知器の数 */
.kc table.lstg th { font-size: 8.5pt; text-align: center; padding: 0; }
.kc table.lstg th.vtt { font-size: 6.6pt; line-height: 1; }
.kc table.lstg td.num { text-align: center; padding: 0; font-size: 9pt; }
.kc input.kc-tot { width: 100%; text-align: center; padding: 0; border: 0; background: #fffbe6; font-size: 9pt; }
/* 11/20 照合で FireNET に合わせた所 */
/* 欄外の注記：表の下 3.4mm に1行目、行送り 3.7mm（折り返しは 3.2mm）。番号の後ろに本文、折り返しは本文の頭にそろえる */
.pg .pnote { margin-top: 0.6mm; line-height: 3.2mm; letter-spacing: 0.02em; }
.pg .pnote .nl + .nl { margin-top: 0.5mm; }
.pg .pnote .nn { flex: none; width: 3.1mm; }
.pg .pnote .nt { flex: 1; min-width: 0; }
/* 点検者の欄：見出しが上、値が下（FireNET） */
.pg.eq table.hd1 td.insp { position: relative; vertical-align: top; padding: 0; }
.pg.eq table.hd1 td.insp .lb { position: absolute; left: 2mm; top: 0.9mm; }
.pg.eq table.hd1 td.insp .iv { position: absolute; left: 11mm; right: 1mm; top: 50%; transform: translateY(-40%); }
.pg.eq table.hd1 td.co { vertical-align: top; padding: 0 2mm; height: 8.9mm; overflow: hidden; }
.pg.eq table.hd1 .co2 { display: flex; }
.pg.eq table.hd1 .lv.w70 { width: 70mm; flex: none; }
.pg.eq table.hd1 .lv { line-height: 4.3mm; white-space: nowrap; overflow: hidden; max-height: 8.6mm; }
.pg.eq table.hd1 .lv .lb, .pg.eq table.hd1 .lv .vv { height: 4.3mm; overflow: hidden; }
.pg.eq table.hd1 th.jtc { padding: 0 2mm; }
/* 点検設備名の下と、見出しの下は二重線（FireNET は 0.3〜0.4mm 空けた2本の線） */
.pg.eq table.grid.dbl { margin-top: 0.05mm !important; }
.pg.eq table.hdl th { padding: 0 1mm; }
.pg.eq table.grid td.g.hz.hj { font-size: 10pt; padding: 0 1mm; text-align: center; }
.pg.eq table.bt2 tr.kl td { font-size: 7pt; line-height: 1; padding-top: 0; padding-bottom: 0; }
.pg.eq table.bt2 tr.kl td .fi { font-size: 7pt; padding: 0; height: 3.6mm; }
.pg.eq table.grid tr.sec.low td { font-size: 8pt; line-height: 1; padding-top: 0; padding-bottom: 0; }
.pg.eq table.grid td.lbl.fit { white-space: nowrap; text-align: left; text-align-last: left; padding: 0 1.2mm; line-height: 1; overflow: hidden; }/* 様式番号と「（その１）」の高さ（FireNET の字の下端 18.7mm） */
.pg.eq .pno, .pg.eq .pnr { top: 15.3mm; }
/* 選択肢に○（内容欄。11/20 夜） */
.pg.eq table.grid td.chc { padding: 0 0.5mm; font-size: 8.5pt; white-space: nowrap; overflow: hidden; }
.pg.eq table.grid td.chc .chs { display: flex; justify-content: space-around; align-items: center; width: 100%; }
.pg.eq table.grid td.chc .chx { display: block; font-size: 8pt; line-height: 1; }
.pg.eq table.grid td.chc .cho { padding: 0.2mm 0.6mm; border: 0.3mm solid transparent; border-radius: 50%; line-height: 1.1; font-size: 7.5pt; letter-spacing: -0.02em; white-space: nowrap; }
.pg.eq table.grid td.chc .cho.on { border-color: #000; }
.pg.eq table.grid td.chc .cho[data-cho] { cursor: pointer; }
.pg.eq table.grid td.chc.abs { position: relative; }
.pg.eq table.grid td.chc.abs .chs { position: absolute; inset: 0; display: block; }
.pg.eq table.grid td.chc.abs .cho { position: absolute; transform: translate(-50%, -50%); }
.pg.eq table.grid td.chc.abs .chx { position: absolute; right: 1mm; top: 50%; transform: translateY(-50%); }
.pg.eq table.grid td.chc .cho[data-cho]:hover { background: #eef4ff; }
/* 届出なしの表紙（自社書式。11/20 夜） */
.hyk .hykt { text-align: center; font-size: 20pt; font-family: var(--mincho); letter-spacing: 0.15em; margin-bottom: 22mm; }
.hyk table.hykb { width: 185mm; table-layout: fixed; border-collapse: collapse; }
.hyk table.hykb th, .hyk table.hykb td { font-size: 13pt; padding: 0 4mm; vertical-align: middle; }
.hyk table.hykb .fi { width: 100%; font-size: 12pt; }
.hyk .hykn { margin-top: 30mm; border: 0.35mm solid #000; padding: 8mm 10mm; font-size: 14pt; line-height: 1.9; text-align: center; font-family: var(--mincho); }
/* 表の形のページ（sheets_hyo.js。11/20） */
.yk table.lstg th, .ju table.lstg th, .mu table.lstg th { font-size: 8.5pt; text-align: center; padding: 0 0.3mm; }
.yk table.lstg th.sm2 { font-size: 8pt; line-height: 1.15; text-align: center; text-align-last: center; }
.yk table.lstg td.c { font-size: 9pt; padding: 0 0.8mm; }
.yk table.lstg td.c.num { text-align: right; }
.yk table.lstg td.c.ctr { text-align: center; }
.yk table.lstg td.c.yt { vertical-align: middle; }
.yk table.lstg td.c.yb { font-size: 7.5pt; white-space: nowrap; padding: 0; line-height: 1; }
.yk table.lstg td.c.yb .maru { padding: 0 0.1em; }
.yk table.lstg td.c, .yk table.lstg td.c .maru { line-height: 1; }
.yk table.lstg td.c[data-unit]::after { content: attr(data-unit); float: right; font-size: 7.5pt; margin-left: 0.5mm; }
.yk table.lstg td.c.ub { vertical-align: bottom; }
.ju table.lstg th.vtt { font-size: 6.5pt; line-height: 1; padding: 0.3mm 0; letter-spacing: 0; white-space: nowrap; }
.ju table.lstg td.c.num { text-align: center; padding: 0; }
.ju table.lstg th.vb { padding: 0; vertical-align: middle; }
.ju table.lstg th.vb .vbx { writing-mode: vertical-rl; text-orientation: upright; font-size: 6.5pt; line-height: 1; letter-spacing: 0; margin: 0 auto; overflow: hidden; text-align: center; }
.ju .jupg { position: absolute; right: 5mm; top: 19.8mm; font-size: 9pt; font-family: var(--mincho); }
.ju .pnote { font-size: 8pt; line-height: 2.8mm; }
.pg.ju .pnote .nh { width: 13mm; white-space: nowrap; }
.mu table.lstg th.vtt { font-size: 9pt; white-space: nowrap; letter-spacing: 0.1em; }
.mu table.lstg td.c { font-size: 9pt; }
.mu table.lstg td.c.ctr { text-align: center; }
.mu .mut { position: absolute; right: 5mm; top: 10.6mm; text-align: right; font-size: 10pt; line-height: 4.6mm; font-family: var(--mincho); }
.mu .mun { position: absolute; left: 20mm; top: 284.6mm; font-size: 9pt; font-family: var(--mincho); }
/* 総括表：※から自動で入った不良内容（手で書いた文の下に1行空けて） */
.sk2 .skauto { margin-top: 1em; }
.sk2 .skre { text-align: right; font-size: 11px; margin-top: 2px; }
.sk2 .skre .pick { color: #1a5fb4; text-decoration: underline; cursor: pointer; }
.sk2 .skre .skst { color: #c0392b; }
.sk2 .skman { font-size: 9px; color: #c0392b; margin-top: 1px; }
.form .span3 { grid-column: 1 / -1; }
.pg.eq table.grid tr.sec td { height: auto; letter-spacing: 0; }
.pg.eq table.grid th { font-size: 10pt; padding: 0 0.5mm; }
.pg.eq table.grid th.small { font-size: 8.5pt; }
.pg.eq table.grid th.tc { font-size: 9pt; }
.pg.eq.tight table.grid td.lbl, .pg.eq.tight table.grid td.c { font-size: 8.5pt; }
.pg.eq.tight table.grid td.g { font-size: 7.5pt; }
.pg.eq.tight table.grid td, .pg.eq.tight table.grid th { line-height: 1; padding-top: 0; padding-bottom: 0; }
.pg.eq.tight table.grid td.c.j { font-size: 8.5pt; line-height: 1; }
.pg.eq.tight table.grid td.lbl, .pg.eq.tight table.grid td.c { font-size: 8pt; line-height: 1; }
.pg.eq table.bt2 th.vt { writing-mode: vertical-rl; text-orientation: upright; letter-spacing: .3em; font-size: 10pt; }
/* 備考欄（11/21 深夜 FireNET に合わせた）：1行 4.62mm 送り（10pt × 1.309）、1行目のベースラインは欄の上端から 4.13mm、
   字の左端は 30.2mm（欄の左 25.6mm から 4.45mm）、折り返しは 203mm まで。空行も1行分。共有ドライブ 150件の備考を測った値 */
.pg.eq table.bt2 td.biko { vertical-align: top; padding: 0.6mm 1.6mm 0 4.45mm; font-size: 10pt; line-height: 1.309; }
.pg.eq table.bt2 td.biko .pre { white-space: pre-wrap; }
.pg.eq table.bt2 td.biko textarea { width: 100%; resize: none; font-size: 10pt; line-height: 1.309; }
.pg.eq table.bt2 th, .pg.eq table.bt2 td { font-size: 8.5pt; }
.pg.eq table.smy td.num .fi { text-align: right; }
.pg.eq table.smy td { font-size: 9pt; }
.pg.eq table.grid td.g.vt { writing-mode: horizontal-tb; padding: 0; }
.pg.eq .vtx { writing-mode: vertical-rl; text-orientation: upright; margin: 0 auto; text-align: justify; text-align-last: justify; line-height: 1.02; overflow: hidden; display: block; width: fit-content; }
.pg.eq .hzx { overflow: hidden; line-height: 1.1; }
.pg .fi { padding: 0 2px; line-height: 1.1; font-size: 9pt; height: auto; }
.pg .maru { line-height: 1.05; padding: 0 .25em; }
.pg.eq table.hd2x th.sm3 { font-size: 7.5pt; line-height: 1; white-space: normal; }
/* 点検設備名（FireNET の形：機器名を2行結合、製造者名／型式等を上下に。11/20） */
.pg.eq table.hdn th.hn { font-size: 9pt; line-height: 1.05; text-align: center; padding: 0 0.5mm; white-space: normal; }
.pg.eq table.hdn td.hv, .pg.eq table.hd3 td.hv { padding: 0 1mm; white-space: nowrap; }
.pg.eq td.hv .hk { display: inline-block; width: 13.5mm; font-size: 8.5pt; vertical-align: middle; }
.pg.eq td.hv .hvv { display: inline-block; width: calc(100% - 14mm); vertical-align: middle; overflow: hidden; }
.pg.eq td.hv .hvv .fi { width: 100%; }
/* 総括表・点検者一覧表・表紙（FireNET の寸法） */
.sk2 table.f, .tk2 table.f, .hy2 table.f { width: 185mm; table-layout: fixed; border-collapse: collapse; }
.sk2 table.f + table.f { margin-top: -0.35mm; }
.pg span.jt { display: inline-block; text-align: justify; text-align-last: justify; }
.pg .w8 { width: 8mm; } .pg .w20 { width: 17mm; } .pg .w30 { width: 24mm; } .pg .w40 { width: 34mm; }
.pg th.vjt { text-align: justify; text-align-last: justify; padding: 0 1.8mm; }
.pg .sm2 { font-size: 9pt; line-height: 1.2; }
.pg .pnote.big { font-size: 10pt; line-height: 4mm; }
.sk2 .sktitle { position: absolute; left: 20mm; width: 185mm; top: 20mm; text-align: center; font-size: 11pt; font-family: var(--mincho); }
.sk2 .sksono { position: absolute; right: 5mm; top: 26.5mm; font-size: 10pt; font-family: var(--mincho); }
.sk2 table.sk tr.srow td { height: auto; vertical-align: top; font-size: 10pt; padding: 1mm; }
.sk2 table.sk tr.srow td.ctr { vertical-align: middle; }
.sk2 table.sk .maru { font-size: 9.5pt; padding: 0 .15em; }
.sk2 table.sk tr.srow td.nowrap { font-size: 9.5pt; padding: 0; white-space: nowrap; letter-spacing: 0; }
.sk2 th { font-size: 9.5pt; }
.sk2 table.f td.ctr .maru { font-size: 9.5pt; padding: 0 .1em; }
.sk2 table.f td.ctr { white-space: nowrap; font-size: 9.5pt; }
.sk2 table.sk tr.srow td.sknm { white-space: normal; word-break: break-all; line-height: 1.25; padding: 0 1mm; text-align: center; }
.tk2 .tktitle { position: absolute; left: 20mm; width: 185mm; top: 14.5mm; text-align: center; font-size: 10pt; font-family: var(--mincho); }
/* 点検者一覧表を FireNET の組み方に（11/21）。1行 6.0mm、太線は見出しの下・社名の下・資格の行の上下・設備名の左 */
.tk2 table.tk3 { width: 185mm; table-layout: fixed; border-collapse: collapse; border: 0.35mm solid #000; font-size: 10pt; font-family: var(--mincho); }
.tk2 table.tk3 th, .tk2 table.tk3 td { height: 6mm; padding: 0; line-height: 1; white-space: nowrap; overflow: hidden; font-weight: 400; text-align: center; vertical-align: middle; }
.tk2 table.tk3 tr.bb > * { border-bottom: 0.35mm solid #000; }
.tk2 table.tk3 .bl { border-left: 0.35mm solid #000; }
.tk2 table.tk3 td.v { text-align: left; padding-left: 0.5mm; }
.tk2 table.tk3 td.dt { text-align: left; }
.tk2 table.tk3 .ds { display: inline-block; text-align: right; }
.tk2 table.tk3 td.setsubi { vertical-align: top; text-align: left; white-space: normal; padding: 0.5mm 0 0 0.5mm; line-height: 4.25mm; }
.tk2 table.tk3 .maru { border: 0; padding: 0; position: relative; line-height: 1; }
.tk2 table.tk3 .maru::before { content: ''; position: absolute; left: 50%; top: 50%; width: 4.4mm; height: 4.4mm; transform: translate(-50%, -50%); border: 0.25mm solid #000; border-radius: 50%; }
.tk2 .tkgap { height: 4.95mm; }
.tk2 .tkempty { position: absolute; left: 20mm; top: 1mm; margin: 0; font-size: 9pt; }
.tk2 .tknote { position: absolute; left: 20.5mm; top: 258.5mm; font-size: 9pt; line-height: 3.17mm; font-family: var(--mincho); }
.tk2 .tknote .tl { white-space: nowrap; }
.tk2 .tknote .tl > span { display: inline-block; vertical-align: top; }
.tk2 .tknote .th { width: 10.6mm; letter-spacing: 0.3em; }
.tk2 .tknote .tl:not(.c) .tt { margin-left: 0; }
.tk2 .tknote .tl:not(.c):not(:first-child) { padding-left: 10.6mm; }
.tk2 .tknote .tn { width: 7.1mm; }
.tk2 .tknote .tl.c { padding-left: 14.1mm; }
.tk2 .tknote .tl.f .tt { text-align: justify; text-align-last: justify; width: 161.3mm; }
.tk2 .tknote .tl.c.f .tt { width: 164.9mm; }
.hy2 table.hyf { border: 0.5mm solid #000; }
.hy2 td.hytop { vertical-align: top; padding: 4mm 3mm 0; position: relative; }
.hy2 .hyt { text-align: center; font-size: 13pt; margin-top: 1mm; }
.hy2 .hyd { text-align: right; margin: 6mm 2mm 0; }
.hy2 .hyto { margin: 3mm 0 0 2mm; }
.hy2 .hyp { display: flex; margin: 2mm 0 0 82mm; }
.hy2 .hyl { width: 15mm; padding-top: 1mm; }
.hy2 .hyr { flex: 1; } .hy2 .hyr > div { border-bottom: 0.2mm solid #000; height: 8.5mm; display: flex; align-items: flex-end; gap: 2mm; padding-bottom: 0.5mm; }
.hy2 .hyr .k { flex: none; width: 15mm; text-align: justify; text-align-last: justify; }
.hy2 .hyr .fi { flex: 1; width: auto; }
/* 届出者の住所・氏名は複数行（11/20 夜）。2行までは同じ枠に収める */
.hy2 .hyr > div { height: auto; min-height: 8.5mm; }
.hy2 .hyr textarea.fi { height: 8mm; resize: vertical; line-height: 3.8mm; }
.hy2 .hyr .pre { flex: 1; white-space: pre-wrap; line-height: 4.2mm; }
.hy2 .hyb { font-size: 11pt; text-indent: 1em; margin: 4mm 1mm 0; line-height: 1.6; }
.hy2 .hyk { text-align: center; margin-top: 1mm; }
.hy2 th.vtc { writing-mode: vertical-rl; text-orientation: upright; letter-spacing: .4em; font-size: 10pt; padding: 0; }
.hy2 td.hyset { vertical-align: top; padding: 2mm; }
.hy2 table.hyf td .fi { width: 100%; }
/* 一覧表（.lst2） */
.lst2 table.f { width: 185mm; table-layout: fixed; border-collapse: collapse; }
.lst2 table.lstg td, .lst2 table.lstg th { height: auto; font-size: 9pt; padding: 0 0.8mm; line-height: 1.1; overflow: hidden; }
.lst2 table.lstg td.c.j { font-size: 10pt; text-align: center; padding: 0; }
.lst2 table.lstg td.c { white-space: nowrap; text-overflow: clip; word-break: normal; overflow-wrap: anywhere; }
.lst2 table.lstg th.lt { font-size: 12pt; }
.lst2 table.lstg th.lt .lpg { font-size: 9pt; margin-left: 4mm; }
.lst2 table.lstg th.sm2 { font-size: 8.5pt; line-height: 1.1; text-align: center; text-align-last: center; padding: 0 0.3mm; }
.lst2 table.lstg th.vtt { writing-mode: vertical-rl; text-orientation: upright; font-size: 8.5pt; padding: 0; letter-spacing: 0; }
.lst2 table.lstg td.num { font-size: 8.5pt; }
.lst2 table.lstg td.lbiko { vertical-align: top; padding: 1mm; } .lst2 table.lstg td.lbiko textarea { height: 40mm; resize: none; }
.pg .pnote .nl { display: flex; } .pg .pnote .nh { flex: none; width: 10.1mm; }
.pg .lockmsg { font-size: 8pt; color: #888; margin-left: 2mm; font-family: var(--ui); }
#print-root .pg .lockmsg { display: none; }

/* よく使う文言（様式の右） */
.sheetlayout.withphr { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 14px; align-items: start; }
.sheetmain { min-width: 0; overflow-x: auto; }
.phr { position: sticky; top: calc(142px + var(--tabsH, 40px)); background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 10px; max-height: calc(100vh - 156px - var(--tabsH, 40px)); display: flex; flex-direction: column; gap: 6px; font-size: 13px; }
.phh b { display: block; font-size: 14px; }
.phh .hint { margin: 2px 0 0; }
.phl { overflow: auto; flex: 1; min-height: 80px; }
.phg { font-weight: 700; font-size: 12px; background: #f0f1f3; border-radius: 4px; padding: 3px 8px; margin: 6px 0 4px; }
.ph { border: 1px solid #dde2ea; border-left: 4px solid #9ec2fa; border-radius: 5px; padding: 5px 8px; margin-bottom: 4px; cursor: grab; background: #fbfcfe; line-height: 1.45; user-select: none; }
.ph:hover { background: #eef4ff; border-color: #9ec2fa; }
.ph:active { cursor: grabbing; }
.phadd { display: flex; flex-direction: column; gap: 3px; border-top: 1px solid var(--line); padding-top: 6px; }
.phdragging textarea[data-b] { outline: 2px dashed var(--cur); background: #eef6ff; }
textarea.flash { background: #fff6c8 !important; transition: background .6s; }

/* まとめて追加 */
.addgrid-wrap { overflow: auto; max-height: calc(100vh - 230px); border: 1px solid var(--line); background: #fff; }
table.addgrid { border-collapse: collapse; font-size: 13px; }
table.addgrid th { position: sticky; top: 0; background: #f0f1f3; font-weight: 600; font-size: 12px; padding: 5px 6px; border: 1px solid #d9dce0; white-space: nowrap; z-index: 1; }
table.addgrid th.req::after { content: '＊'; color: var(--pri); }
table.addgrid td { border: 1px solid #e3e5e8; padding: 0; }
table.addgrid td.rn { background: #f6f7f8; color: #888; text-align: center; font-size: 11px; padding: 0 6px; }
table.addgrid input { border: none; font: inherit; padding: 4px 6px; width: 100%; min-width: 60px; background: transparent; }
table.addgrid input:focus { outline: 2px solid var(--cur); outline-offset: -2px; background: #fff; }
table.addgrid tr.err td { background: #fdecec; } table.addgrid tr.ok td { background: #eef9ef; }
table.addgrid td.msg { font-size: 11px; color: var(--bad); padding: 0 6px; white-space: nowrap; min-width: 160px; }
table.addgrid tr.ok td.msg { color: #237a2b; }
.tk2 table.tk3 td.setsubi .ssl { max-height: 106mm; overflow: hidden; }
/* 一覧表4種を FireNET の寸法に（11/21 夜）。名称・点検年月日は列とは別の表（見出し 20〜70.5mm）、備考欄も別の表（左 5.5mm に「備考」） */
.lst2 table.f + table.f { margin-top: -0.35mm; }
.lst2 table.lstt th, .lst2 table.lstt td, .lst2 table.lstb th, .lst2 table.lstb td { font-size: 10pt; padding: 0; line-height: 1.1; font-weight: 400; white-space: nowrap; overflow: hidden; }
.lst2 table.lstt th { text-align: center; }
.lst2 table.lstt th.lt { font-size: 12pt; }
.lst2 table.lstt td.lnm { padding-left: 2mm; }
.lst2 table.lstt td.ldt { padding-left: 8.1mm; }
.lst2 table.lstt td.ldt .d1 { display: inline-block; width: 34.2mm; }
.lst2 table.lstt td.ldt .d2 { display: inline-block; width: 13.5mm; }
.lst2 input.lsuf { width: 45mm; font-size: 9pt; margin-left: 2mm; vertical-align: middle; }
.lst2 table.lstg th.lhd { font-size: 10pt; line-height: 1.1; padding: 0; text-align: center; white-space: nowrap; overflow: hidden; }
.lst2 table.lstg td.c.ac { text-align: center; padding: 0 0.3mm; }
.lst2 table.lstg td.c.ar { text-align: right; }
.lst2 table.lstg tr.ltot th, .lst2 table.lstg tr.ltot td { font-size: 10pt; padding: 0; text-align: center; }
@media screen { .lst2 table.lstg td.c.auto { color: #8a8a8a; } }
.lst2 table.lstb th.vtt { writing-mode: horizontal-tb; display: table-cell; vertical-align: middle; text-align: center; white-space: normal; line-height: 1; }
.lst2 table.lstb th.vtt::before { content: '備'; display: block; margin-bottom: 9mm; }
.lst2 table.lstb th.vtt { font-size: 0; } .lst2 table.lstb th.vtt::before, .lst2 table.lstb th.vtt::after { font-size: 10pt; }
.lst2 table.lstb th.vtt::after { content: '考'; display: block; }
.lst2 table.lstb td.lbiko { vertical-align: top; padding: 1mm 1.5mm; white-space: pre-wrap; }
.lst2 .ptl { position: absolute; left: 20mm; top: 15.2mm; font-size: 10pt; line-height: 1; font-weight: 700; font-family: "BIZ UDGothic", "Yu Gothic", "Meiryo", sans-serif; white-space: nowrap; }
.lst2.l_yudoto .ptl { top: 15.8mm; }
.lst2 .pnr.ltr { top: 10.6mm; }
.lst2 .pnote.sp { letter-spacing: 0.13em; }
.lst2 .pnote.sp .nb { display: inline-block; width: 10.6mm; letter-spacing: 0.3em; }
.lst2.l_yudoto table.lstg th { padding: 0; white-space: nowrap; font-size: 10pt; line-height: 1; overflow: hidden; }
.lst2.l_yudoto table.lstg th.vtt { font-size: 10pt; letter-spacing: 0.06em; }

/* 11/22 トップ：いまの段階と進み具合（progress.js） */
.pg-card h2 { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.pg-card h3 { font-size: 15px; margin: 14px 0 6px; color: #1f3a68; }
.pg-stages { list-style: none; padding: 0; margin: 8px 0 4px; display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; counter-reset: st; }
.pg-stages li { position: relative; border: 1px solid #dfe5ee; border-radius: 8px; padding: 10px 10px 10px; background: #f8fafc; color: #667; font-size: 13px; line-height: 1.45; }
.pg-stages li b { display: block; font-size: 15px; color: #445; margin-bottom: 2px; }
.pg-stages li.now { background: #fff7e6; border-color: #e7a33e; color: #333; box-shadow: 0 0 0 2px rgba(231, 163, 62, .25); }
.pg-stages li.now b { color: #9a5b00; }
.pg-stages li em { position: absolute; top: -9px; right: 8px; font-style: normal; font-size: 12px; font-weight: 700; background: #e7a33e; color: #fff; border-radius: 10px; padding: 1px 8px; }
.pg-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.pg-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.pg-doc { border: 1px solid #e6ebf2; border-radius: 6px; padding: 8px 10px; background: #fff; }
.pg-h { display: flex; align-items: center; gap: 8px; }
.pg-n { font-weight: 700; font-size: 14px; flex: 0 0 auto; max-width: 55%; }
.pg-bar { flex: 1; height: 10px; border-radius: 5px; background: #e9edf3; overflow: hidden; min-width: 60px; }
.pg-bar i { display: block; height: 100%; background: linear-gradient(90deg, #3b82f6, #1d4ed8); border-radius: 5px; }
.pg-pct { font-size: 14px; width: 3em; text-align: right; color: #1d4ed8; }
.pg-d { font-size: 12.5px; color: #444; line-height: 1.5; margin-top: 4px; }
.pg-ok, .pg-todo { display: inline-block; font-size: 11px; font-weight: 700; border-radius: 3px; padding: 0 5px; margin-right: 6px; }
.pg-ok { background: #e3f4e8; color: #17703a; } .pg-todo { background: #fdeee0; color: #9a4b00; }
.pg-road { margin: 0; padding-left: 1.4em; display: grid; gap: 5px; font-size: 13.5px; }
.pg-tag { display: inline-block; font-size: 11px; font-weight: 700; border-radius: 10px; padding: 0 7px; margin-right: 6px; white-space: nowrap; }
.pg-tag.now { background: #fff1d6; color: #9a5b00; } .pg-tag.next { background: #eef1f5; color: #667; } .pg-tag.done, .pg-tag.ok { background: #e3f4e8; color: #17703a; } .pg-tag.part { background: #e6efff; color: #1d4ed8; }
.pg-issues { margin-top: 14px; } .pg-issues summary { cursor: pointer; font-weight: 700; color: #1f3a68; font-size: 14px; }
.pg-issues table { border-collapse: collapse; width: 100%; font-size: 13px; margin-top: 6px; }
.pg-issues td { border-bottom: 1px solid #eef1f5; padding: 5px 6px; vertical-align: top; }
.pg-issues td:first-child { width: 38%; color: #445; }
@media (max-width: 760px) { .pg-stages { grid-template-columns: 1fr 1fr; } .pg-cols { grid-template-columns: 1fr; } .pg-n { max-width: 60%; } }

/* 11/22 使用機器マスタ：1台ずつのカード（字が全部見えるように） */
.kk-list { display: grid; gap: 10px; margin: 10px 0; }
.kk { border: 1px solid #dfe5ee; border-left: 4px solid #3b82f6; border-radius: 6px; background: #fff; padding: 8px 10px; position: relative; }
.kk.late { border-left-color: #dc2626; background: #fff7f7; }
.kk-g { display: grid; grid-template-columns: minmax(220px, 2fr) repeat(2, minmax(160px, 1.2fr)) repeat(2, minmax(150px, 1fr)); gap: 6px 10px; align-items: end; padding-right: 60px; }
.kk-g label { display: flex; flex-direction: column; gap: 2px; margin: 0; min-width: 0; }
.kk-g label > span { font-size: 12px; color: #556; }
.kk-g .fi { width: 100%; min-width: 0; font-size: 14px; }
.kk-g label.warn > span { color: #dc2626; font-weight: 700; }
.kk-ks { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; font-size: 13px; padding: 4px 8px; border-radius: 4px; background: #f4f6fa; }
.kk-ks > span { font-size: 12px; color: #556; }
.kk-ks.need b { color: #1d4ed8; } .kk-ks.no b { color: #17703a; } .kk-ks.opt b { color: #9a5b00; } .kk-ks.q b { color: #777; }
.kk-ks small { color: #555; font-size: 12px; }
.kk-f { margin-top: 6px; font-size: 13px; } .kk-f summary { cursor: pointer; color: #1f3a68; line-height: 1.5; }
.kk-fg { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 2px 12px; margin-top: 6px; padding: 6px 8px; background: #f8fafc; border-radius: 4px; }
.kk-fg label { display: flex; align-items: center; gap: 4px; font-size: 13px; margin: 0; }
.kk-del { position: absolute; top: 8px; right: 8px; }
.kk-help { margin: 6px 0 10px; } .kk-help summary { cursor: pointer; font-weight: 700; color: #1f3a68; }
.kk-ht { border-collapse: collapse; margin: 6px 0; font-size: 13px; width: 100%; max-width: 900px; }
.kk-ht th, .kk-ht td { border: 1px solid #dfe5ee; padding: 4px 6px; text-align: left; vertical-align: top; }
.kk-ht th { background: #f4f6fa; }
@media (max-width: 900px) { .kk-g { grid-template-columns: 1fr 1fr; padding-right: 0; } .kk-name { grid-column: 1 / -1; } .kk-del { position: static; margin-top: 6px; text-align: right; } }

/* 11/22 書類の種類ごとのテーマカラー：消防点検＝赤、防火対象物・防災管理＝黄、設置・着工＝青、12条＝緑（T.themeOf） */
:root { --th-red: #d62839; --th-red-bg: #fdecee; --th-red-ink: #a40f26; --th-red-line: #f3c3ca;
  --th-yellow: #e5a800; --th-yellow-bg: #fff6d6; --th-yellow-ink: #7a5600; --th-yellow-line: #f1dc93;
  --th-blue: #1d64c8; --th-blue-bg: #e8f1fd; --th-blue-ink: #154a96; --th-blue-line: #bcd3f3;
  --th-green: #1e8a46; --th-green-bg: #e6f5ea; --th-green-ink: #17683a; --th-green-line: #b9e0c6; }
.th-red { --th: var(--th-red); --th-bg: var(--th-red-bg); --th-ink: var(--th-red-ink); --th-line: var(--th-red-line); }
.th-yellow { --th: var(--th-yellow); --th-bg: var(--th-yellow-bg); --th-ink: var(--th-yellow-ink); --th-line: var(--th-yellow-line); }
.th-blue { --th: var(--th-blue); --th-bg: var(--th-blue-bg); --th-ink: var(--th-blue-ink); --th-line: var(--th-blue-line); }
.th-green { --th: var(--th-green); --th-bg: var(--th-green-bg); --th-ink: var(--th-green-ink); --th-line: var(--th-green-line); }
.b-shobo { background: var(--th-red-bg); color: var(--th-red-ink); border-color: var(--th-red-line); }
.b-boka, .b-bosai { background: var(--th-yellow-bg); color: var(--th-yellow-ink); border-color: var(--th-yellow-line); }
.b-chakko { background: var(--th-blue-bg); color: var(--th-blue-ink); border-color: var(--th-blue-line); }
.b-j12 { background: var(--th-green-bg); color: var(--th-green-ink); border-color: var(--th-green-line); }
.th-dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; background: var(--th, #999); margin-right: 6px; vertical-align: 0; flex: 0 0 auto; }
.th-chip { background: var(--th-bg); color: var(--th-ink); border: 1px solid var(--th-line); border-radius: 12px; padding: 1px 9px; }
.pblock[class*="th-"] { border-left: 5px solid var(--th); }
.pblock[class*="th-"] .pbh { background: var(--th-bg); }
.pblock[class*="th-"] .pbh b { color: var(--th-ink); }
.pblock.on[class*="th-"] { border-color: var(--th-line); border-left-color: var(--th); }
#main[data-th="red"] { --th: var(--th-red); --th-bg: var(--th-red-bg); --th-ink: var(--th-red-ink); --th-line: var(--th-red-line); }
#main[data-th="yellow"] { --th: var(--th-yellow); --th-bg: var(--th-yellow-bg); --th-ink: var(--th-yellow-ink); --th-line: var(--th-yellow-line); }
#main[data-th="blue"] { --th: var(--th-blue); --th-bg: var(--th-blue-bg); --th-ink: var(--th-blue-ink); --th-line: var(--th-blue-line); }
#main[data-th="green"] { --th: var(--th-green); --th-bg: var(--th-green-bg); --th-ink: var(--th-green-ink); --th-line: var(--th-green-line); }
#main[data-th]:not([data-th=""]) .pbar { border-top: 4px solid var(--th); background: linear-gradient(90deg, var(--th-bg), #fff 60%); }
#main[data-th]:not([data-th=""]) .pbar > b { color: var(--th-ink); }
#main[data-th]:not([data-th=""]) .tab.on { color: var(--th-ink); box-shadow: inset 0 3px 0 var(--th); }

/* 11/22 ファーストビューの5つのコンセプト（丸） */
.concepts { list-style: none; max-width: 1120px; margin: 0 auto; padding: 0 24px 30px; display: grid; grid-template-columns: repeat(5, 1fr); gap: 14px; }
.cpt { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 8px; }
.cpt-o { width: 138px; height: 138px; border-radius: 50%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; color: #fff;
  background: radial-gradient(circle at 32% 26%, rgba(255,255,255,.55), rgba(255,255,255,0) 42%), radial-gradient(circle at 50% 60%, var(--c1), var(--c2) 78%);
  box-shadow: 0 10px 18px -8px var(--c2), inset 0 -6px 12px rgba(0,0,0,.18), inset 0 4px 8px rgba(255,255,255,.25); transition: transform .15s; }
.cpt:hover .cpt-o { transform: translateY(-3px); }
.cpt-o svg { width: 30px; height: 30px; fill: none; stroke: #fff; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; margin-bottom: 2px; filter: drop-shadow(0 1px 1px rgba(0,0,0,.25)); }
.cpt-o b { font-size: 17px; font-weight: 800; letter-spacing: .02em; text-shadow: 0 1px 2px rgba(0,0,0,.3); line-height: 1.2; }
.cpt-o span { font-size: 11.5px; font-weight: 700; opacity: .95; }
.cpt p { margin: 0; font-size: 12.5px; color: #4a5160; line-height: 1.5; max-width: 15em; }
.cpt.c1 { --c1: #f2556a; --c2: #b3132b; } .cpt.c2 { --c1: #ffb43a; --c2: #d07a00; } .cpt.c3 { --c1: #3fbf72; --c2: #17703a; }
.cpt.c4 { --c1: #5b93f0; --c2: #1d4fb0; } .cpt.c5 { --c1: #9b7ae8; --c2: #5a3c99; }
@media (max-width: 860px) { .concepts { grid-template-columns: repeat(3, 1fr); } .cpt-o { width: 112px; height: 112px; } .cpt-o b { font-size: 15px; } }
@media (max-width: 520px) { .concepts { grid-template-columns: repeat(2, 1fr); padding: 0 16px 24px; } }

/* 11/22 AI 欄の案内役（3D 風キャラクター）と吹き出し */
.home-body .ai { position: relative; padding-left: 190px; min-height: 200px; }
.chara { position: absolute; left: 14px; top: 10px; width: 160px; }
.chara img { width: 150px; height: auto; display: block; filter: drop-shadow(0 6px 8px rgba(27,42,68,.18)); animation: chara-b 3.2s ease-in-out infinite; }
.chara-say { position: absolute; left: 118px; top: -4px; white-space: nowrap; background: #fff; border: 2px solid #d62839; color: #a40f26; font-weight: 800; font-size: 15px; border-radius: 16px; padding: 5px 12px; box-shadow: 0 4px 10px -4px rgba(0,0,0,.25); z-index: 1; }
.chara-say::after { content: ''; position: absolute; left: 10px; bottom: -9px; border: 8px solid transparent; border-top-color: #d62839; border-bottom: 0; }
@keyframes chara-b { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-4px); } }
@media (prefers-reduced-motion: reduce) { .chara img { animation: none; } }
@media (max-width: 700px) { .home-body .ai { padding-left: 16px; padding-top: 150px; } .chara { left: 50%; transform: translateX(-80px); top: 8px; width: 120px; } .chara img { width: 110px; } .chara-say { left: 96px; } }
/* 吹き出しが見出しにかからないように */
.home-body .ai { padding-left: 232px; }
.chara { top: 30px; }
.chara-say { left: 58px; top: -26px; font-size: 14px; }
@media (max-width: 700px) { .home-body .ai { padding-left: 16px; padding-top: 170px; } .chara { top: 34px; } .chara-say { left: 70px; top: -28px; } }
