/* 共通の部品の見た目: 釦・切替・入力（時刻・数・選択欄）・物差し・場所を探す欄・チャット欄・札（出典・照合の記号）・小窓・表。
   部品は js/parts.js と js/components/。照合は ○△× を添える（色だけで伝えない）。字は 13px 以上・スマホ（767px 以下）の押す所は 44px 以上。 */

/* ---------------------------------------------------------------- 釦（.btn）。.pri＝主の釦・.ghost＝枠なし・.sm＝小さい・.wide＝幅いっぱい */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: var(--tap); padding: 3px 12px;
  border: 1px solid var(--line-strong); border-radius: var(--r-m); background: var(--bg-1); color: var(--fg-0);
  font-size: calc(13.5px * var(--fs-x)); font-weight: 600; line-height: 1.35; white-space: nowrap; text-decoration: none;
  transition: background-color .12s, border-color .12s, color .12s; }
.btn.sm { min-height: 28px; padding: 2px 9px; font-size: calc(13px * var(--fs-x)); }
.btn.wide { width: 100%; min-height: 44px; }
.btn:disabled { opacity: .5; }
.btn[aria-pressed="true"] { border-color: var(--sel); box-shadow: inset 0 0 0 1px var(--sel); }
.btn.making { border-style: dashed; color: var(--fg-1); cursor: default; }       /* 帳票を作っている間（押せない） */
.btn:hover { background: var(--bg-2); border-color: var(--line-strong); }
.btn.pri { background: var(--sel); border-color: var(--sel); color: var(--on-sel); font-weight: 700; }
.btn.pri:hover { background: var(--sel-hover); border-color: var(--sel-hover); }
.btn.ghost { border-color: transparent; background: transparent; color: var(--fg-1); }
.btn.ghost:hover { background: var(--bg-2); color: var(--fg-0); }
.btn.making:hover { border-color: var(--rule-1); }

/* 印だけの釦（.ibtn）と、文の中の押せる字（.link） */
.ibtn { display: inline-grid; place-items: center; width: 32px; height: 32px; flex: none; border: 1px solid transparent; border-radius: var(--r-m);
  background: transparent; color: var(--fg-2); transition: background-color .12s, color .12s; }
.ibtn:hover { background: var(--bg-2); color: var(--fg-0); }
.ibtn.sm { width: 28px; height: 28px; }
.ibtn:disabled { opacity: .4; }
.link { padding: 0; border: 0; background: none; color: var(--sel); font-size: inherit; font-weight: 600; text-align: left;
  text-decoration: none; text-underline-offset: 3px; }
.link:hover { text-decoration: underline; }

/* ---------------------------------------------------------------- 切替（parts.js の Seg。押した物に aria-pressed）・チェック・釦の列 */
.seg { display: inline-flex; flex: none; gap: 2px; max-width: 100%; padding: 3px; border-radius: 10px; background: var(--bg-2); overflow: hidden; }
.seg button { min-height: 30px; padding: 3px 10px; border: 0; border-radius: 7px; background: transparent; color: var(--fg-1);
  font-size: calc(13px * var(--fs-x)); font-weight: 500; white-space: nowrap; }
.seg button:disabled { color: var(--fg-3); }
.seg button[aria-pressed="true"] { background: var(--bg-1); color: var(--fg-0); font-weight: 700; box-shadow: var(--sh-1); }
.chk { display: inline-flex; align-items: center; gap: 6px; min-height: 30px; font-size: calc(13.5px * var(--fs-x)); }
.chk input { width: 18px; height: 18px; }
.btnrow { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }

/* ---------------------------------------------------------------- 時刻の欄・数の欄・選択欄（components/fields.js）
   T30 B2: 時刻の欄は「🕘 09:30」の形の釦（.tf。押すと選び枠＝下の「時刻の選び枠」の節）。枠・角・高さは前の字の欄のまま */
button.tf { display: inline-flex; align-items: center; justify-content: center; gap: 5px; flex: none; height: 36px; padding: 0 10px 0 8px; border: 1px solid var(--line-strong);
  border-radius: var(--r-m); background: var(--bg-1); color: var(--fg-0); font-family: var(--f-mono); font-size: calc(14px * var(--fs-x)); font-variant-numeric: tabular-nums; white-space: nowrap; cursor: pointer; }
button.tf .i { width: 15px; height: 15px; color: var(--fg-2); }
button.tf:hover:not(:disabled) { border-color: var(--rule-2); }
button.tf[aria-expanded="true"] { border-color: var(--sel); box-shadow: 0 0 0 3px var(--sel-ring); }
button.tf:disabled { opacity: .6; cursor: default; }
.numf { display: inline-flex; align-items: center; gap: 6px; }
.numf input { width: 4.4em; height: 36px; padding: 0 8px; border: 1px solid var(--line-strong); border-radius: var(--r-m); background: var(--bg-1); color: var(--fg-0);
  text-align: right; font-size: calc(15px * var(--fs-x)); font-weight: 700; font-variant-numeric: tabular-nums; }
.numf input:focus-visible, button.tf:focus-visible, input.txf:focus-visible { outline: 2px solid var(--sel); outline-offset: 0; border-color: var(--sel); }
/* 字の欄（名前など。T16 第2回） */
input.txf { width: 100%; min-width: 0; height: 36px; padding: 0 10px; border: 1px solid var(--line-strong); border-radius: var(--r-m); background: var(--bg-1); color: var(--fg-0);
  font: inherit; font-size: calc(14px * var(--fs-x)); }
.numf .unit { font-size: calc(13.5px * var(--fs-x)); color: var(--fg-1); white-space: nowrap; }
/* 選択欄: 下向きの印は文字の色で描く（明暗の両方で見える） */
.sel { position: relative; display: inline-flex; flex: 0 0 auto; }
.sel select { height: 32px; max-width: 100%; padding: 0 26px 0 8px; border: 1px solid var(--in-bd); border-radius: var(--r-m); background: var(--in-bg); color: var(--in-fg);
  font: inherit; font-size: calc(14px * var(--fs-x)); appearance: none; -webkit-appearance: none; cursor: pointer; }
.sel select:focus-visible { outline: 2px solid var(--sel); outline-offset: 1px; border-color: var(--sel); }
.sel select:disabled { opacity: .6; }
.sel::after { content: ""; position: absolute; right: 10px; top: 50%; width: 6px; height: 6px; margin-top: -5px; border-right: 1.5px solid var(--fg-1);
  border-bottom: 1.5px solid var(--fg-1); transform: rotate(45deg); pointer-events: none; }
.sel.wide { flex: 1 1 auto; min-width: 0; }
.sel.wide select { width: 100%; }

/* ---------------------------------------------------------------- 物差し（Ruler）: 範囲内の帯と今の数の印 */
.ruler { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.rtrack { position: relative; height: 22px; border-radius: 4px; cursor: pointer; touch-action: none;
  background: linear-gradient(var(--bg-3), var(--bg-3)) center / 100% 6px no-repeat; }
.rtrack .rin { position: absolute; top: 8px; height: 6px; border-radius: 3px; background: var(--sel); opacity: .45; }
.rtrack .rknob { position: absolute; top: 1px; width: 3px; height: 20px; margin-left: -1px; border-radius: 2px; background: var(--sel); }
.ruler.off .rtrack { cursor: default; }
.rscale { position: relative; display: flex; justify-content: space-between; font-size: calc(13px * var(--fs-x)); color: var(--fg-2); font-variant-numeric: tabular-nums; }
.rscale .rnow { position: absolute; transform: translateX(-50%); color: var(--sel); font-weight: 700; }
.rscale .rhide { visibility: hidden; }      /* 今の数が端に近い時の端の数（重ならない。T16 第3回 UI-10） */

/* ---------------------------------------------------------------- 場所を探す欄（PlaceSearch。候補の一覧。決まるのは押した時） */
.psearch { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.psform input::-webkit-search-cancel-button { display: none; }      /* 消す釦は自前の × だけ（T16 第2回 UI-26・ir7.17: × が2つ並んだ） */
.psform { display: flex; align-items: center; gap: 6px; padding: 4px 4px 4px 10px; border: 1.5px solid var(--sel); border-radius: var(--r-l); background: var(--bg-1); }
.psform .psic .i { width: 18px; height: 18px; color: var(--fg-2); }
.psform input { flex: 1 1 auto; min-width: 0; height: 40px; border: 0; outline: 0; background: none; color: var(--fg-0); font-size: calc(15px * var(--fs-x)); }
/* T47 UI-23: 字の欄に焦点がある間は、欄の枠の外にほかの欄と同じ 2px の枠（前は焦点の前後で見た目が替わらなかった。欄の中の釦の焦点は釦の枠） */
.psform:has(input:focus-visible) { outline: 2px solid var(--sel); outline-offset: 2px; }
/* T47 UI-23: 利用条件の本文の巻く欄（login/Terms.js の main.terms。画面いっぱいの箱で Tab で入る）の焦点の枠は内側に描く（外に描くと画面の外で見えなかった）。
   置き場は css/shell.css の .terms の近くが本来（全体管理が合わせる時に移す） */
.terms:focus-visible { outline: 2px solid var(--sel); outline-offset: -3px; }
.psform .psgo { min-height: 40px; padding: 0 16px; flex: none; }
.pslist { list-style: none; margin: 0; padding: 0; border: 1px solid var(--rule-1); border-radius: var(--r-l); overflow: hidden; background: var(--bg-1); }
.pslist li + li { border-top: 1px solid var(--rule-1); }
.psitem { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 44px; padding: 6px 12px; border: 0; background: none; color: var(--fg-0); text-align: left; }
.psitem:hover, .psitem.on { background: var(--sel-soft); }
.psno { display: grid; place-items: center; flex: none; width: 22px; height: 22px; border-radius: 50%; border: 1.5px dashed var(--sel); color: var(--sel); font-size: calc(13px * var(--fs-x)); }
.pstx { display: flex; flex-direction: column; min-width: 0; line-height: 1.35; }
.psnm { font-size: calc(14.5px * var(--fs-x)); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pstx small, .pshint, .psnone, .pserr { font-size: calc(13px * var(--fs-x)); color: var(--fg-2); }
.pshint { padding: 6px 12px; }
.pserr { color: var(--no-bar); }

/* ---------------------------------------------------------------- チャット欄（components/ChatBox.js）: 頭｜やり取り（新しい物が下）｜入力（複数行の欄・［PDF］・［送る］）
   業務の道具の控えの欄（吹き出しを大きくしない）: 利用者の文＝右寄せの白い札（.u）・サーバーの一言＝左の地の字（.m）・誤り＝左の印つき（.e）・
   画面の一言＝左の薄い字（.n）。どの行も、3行を超える文はたたむ（.fold。長い行は押せる札＝button で、押すと全部）。
   面は薄い地の1枚で、線で囲まない。青は［送る］だけ。幅 300〜420px・高さ 220〜320px の中に収まる（高さは置く所が決めてよい） */
.cbx { display: flex; flex-direction: column; min-width: 0; height: 100%; min-height: 220px; max-height: 320px; border-radius: var(--r-l); background: var(--bg-2); overflow: hidden; }
.cbx.over { box-shadow: inset 0 0 0 2px var(--sel); }                         /* ファイルを欄の上に引いている間 */
.cbxh { display: flex; flex-direction: column; gap: 2px; flex: none; padding: 8px 12px 4px; }
.cbxt { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.cbxt b { font-size: calc(14px * var(--fs-x)); line-height: 1.4; color: var(--fg-0); }
.cbxn { font-size: calc(13px * var(--fs-x)); color: var(--fg-1); font-variant-numeric: tabular-nums; white-space: nowrap; }
.cbxn.no { color: var(--err); font-weight: 700; }
.cbxoff { display: flex; align-items: flex-start; gap: 6px; font-size: calc(13px * var(--fs-x)); line-height: 1.45; color: var(--fg-1); }
.cbxoff .i { margin-top: 2px; }
.cbxlog { display: flex; flex-direction: column; gap: 6px; flex: 1 1 auto; min-height: 0; padding: 4px 12px 8px; overflow-y: auto; overscroll-behavior: contain; }
.cbxit { flex: none; max-width: 100%; margin: 0; font-size: calc(13px * var(--fs-x)); line-height: 1.5; color: var(--fg-1); white-space: pre-wrap; overflow-wrap: anywhere; }
button.cbxit { padding: 0; border: 0; background: none; font: inherit; font-size: calc(13px * var(--fs-x)); line-height: 1.5; text-align: left; cursor: pointer; }
.cbxit.fold { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 3; overflow: hidden; }
.cbxit.u { align-self: flex-end; max-width: 92%; padding: 4px 9px; border: 1px solid var(--line-strong); border-radius: var(--r-m); background: var(--bg-1);
  color: var(--fg-0); }
.cbxit.e { color: var(--err); font-weight: 600; }
.cbxit.e .i { margin-right: 6px; vertical-align: -2px; }
.cbxit.n { color: var(--fg-2); }
.cbxph { display: flex; align-items: center; gap: 6px; flex: none; font-size: calc(13px * var(--fs-x)); line-height: 1.5; color: var(--fg-1); }
.cbxph .link { margin-left: auto; }
.cbxempty { display: flex; flex-direction: column; gap: 8px; margin-top: auto; }
.cbxguide, .cbxfile { font-size: calc(13px * var(--fs-x)); line-height: 1.5; color: var(--fg-2); }
.cbxfile { display: flex; align-items: center; gap: 6px; }
.cbxsmp { display: flex; flex-wrap: wrap; gap: 6px; }
.cbxsmp .btn { max-width: 100%; white-space: normal; text-align: left; font-weight: 500; }
.cbxin { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 6px; flex: none; padding: 0 8px 8px; }
.cbxin textarea { display: block; width: 100%; height: 68px; padding: 6px 10px; border: 1px solid var(--line-strong); border-radius: var(--r-m); background: var(--bg-1);
  color: var(--fg-0); font-size: calc(14px * var(--fs-x)); line-height: 1.5; resize: none; }
.cbxin textarea::placeholder { color: var(--fg-2); }
.cbxin textarea:focus-visible { outline: 2px solid var(--sel); outline-offset: 0; border-color: var(--sel); }
.cbxin textarea:disabled { background: var(--bg-2); }
.cbxbt { display: flex; flex-direction: column; justify-content: flex-end; gap: 4px; }
.cbxbt .btn { min-width: 60px; }
/* 入力欄の下の小さな1行（送った文がどう扱われるかの添え書き。渡した時だけ） */
.cbxfoot { flex: none; margin: -2px 0 0; padding: 0 12px 8px; font-size: calc(13px * var(--fs-x)); line-height: 1.4; color: var(--fg-2); }

/* ---------------------------------------------------------------- 吹き出し（components/Popover.js）: 寄せる先の横に浮く小さな板（矢印つき）
   向きは .s-right（寄せる先の右に出る＝矢印は板の左）・.s-left・.s-below・.s-above。幅 900px 未満は下からの板（.sheet。後ろに薄い幕 .povscrim）。
   中の並びは、頭（.povh）・欄の行（.povr）・釦の行（.povb）・添え書き（.povnote）を、使う画面が組む */
.pov { position: fixed; z-index: 70; display: flex; flex-direction: column; gap: 10px; width: 320px; max-width: calc(100vw - 16px); padding: 14px;
  border: 1px solid var(--rule-1); border-radius: var(--r-l); background: var(--bg-1); color: var(--fg-0); box-shadow: var(--sh-3); font-size: calc(14px * var(--fs-x)); line-height: 1.5; }
.pov:focus { outline: none; }
.povarr { position: absolute; width: 12px; height: 12px; border: 1px solid var(--rule-1); background: var(--bg-1); transform: rotate(45deg); }
.pov.s-right .povarr { left: -7px; margin-top: -6px; border-top: 0; border-right: 0; }
.pov.s-left .povarr { right: -7px; margin-top: -6px; border-bottom: 0; border-left: 0; }
.pov.s-below .povarr { top: -7px; margin-left: -6px; border-right: 0; border-bottom: 0; }
.pov.s-above .povarr { bottom: -7px; margin-left: -6px; border-top: 0; border-left: 0; }
.pov.sheet { left: 0; right: 0; bottom: 0; width: auto; max-width: none; max-height: min(78dvh, 620px); overflow-y: auto; padding: 16px 16px 20px; border: 0;
  border-radius: var(--r-xl) var(--r-xl) 0 0; }
.povscrim { position: fixed; inset: 0; z-index: 69; background: var(--scrim); }
.povh { display: flex; align-items: center; gap: 8px; min-width: 0; }
.povh > b { flex: 1 1 auto; min-width: 0; overflow: hidden; font-size: calc(15px * var(--fs-x)); text-overflow: ellipsis; white-space: nowrap; }
.povh .ibtn { margin: -4px -6px -4px 0; }
.povr { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; }
.povr label { display: inline-flex; align-items: center; gap: 6px; font-size: calc(13.5px * var(--fs-x)); color: var(--fg-1); }
.povb { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.povnote { margin: 0; font-size: calc(13px * var(--fs-x)); line-height: 1.5; color: var(--fg-2); }

/* ---------------------------------------------------------------- 時刻の選び枠（components/TimePick.js。T30 B2〜B4）: 時刻の欄の下（入らなければ上）に浮く小さな枠。
   頭の字の欄（.tpkin）・「時」の 24 の釦（6 列×4 行）・「分」の 12 の釦（6 列×2 行）。釦は PC 32px・スマホ 44px。今の値の時と分は青の面（aria-pressed）。
   吹き出し（.pov＝70）と、その幕（69）の上に出す 95（知らせの .toast＝100 より下）。幅 767px 以下は左右 8px で画面の幅いっぱい */
.tpk { position: fixed; z-index: 95; display: flex; flex-direction: column; gap: 6px; width: 252px; padding: 10px; border: 1px solid var(--rule-1); border-radius: var(--r-l);
  background: var(--bg-1); color: var(--fg-0); box-shadow: var(--sh-3); }
.tpkt { display: flex; }
.tpkin { flex: 1 1 auto; min-width: 0; height: 36px; padding: 0 10px; border: 1px solid var(--line-strong); border-radius: var(--r-m); background: var(--bg-1); color: var(--fg-0);
  font-family: var(--f-mono); font-size: calc(15px * var(--fs-x)); font-variant-numeric: tabular-nums; text-align: center; }
.tpkin:focus-visible { outline: 2px solid var(--sel); outline-offset: 0; border-color: var(--sel); }
.tpkl { margin: 2px 0 0; font-size: calc(13px * var(--fs-x)); line-height: 1.3; color: var(--fg-2); }
.tpkg { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 4px; }
.tpkb { height: 32px; min-width: 32px; padding: 0; border: 0; border-radius: var(--r-m); background: var(--bg-2); color: var(--fg-0); font: inherit; font-size: calc(14px * var(--fs-x));
  font-variant-numeric: tabular-nums; cursor: pointer; }
.tpkb:hover { background: var(--bg-3); }
.tpkb[aria-pressed="true"] { background: var(--sel); color: var(--on-sel); font-weight: 700; }
.tpkb:focus-visible { outline: 2px solid var(--sel); outline-offset: 1px; }
@media (max-width: 767px) {
  .tpk { right: 8px; width: auto; }
  .tpkin { height: 44px; font-size: calc(16px * var(--fs-x)); }       /* 欄の字 16px（iOS が欄に入った時に拡大しない大きさ） */
  .tpkb { height: 44px; font-size: calc(15px * var(--fs-x)); }
}

/* ---------------------------------------------------------------- 引いて入れられる物（components/dnd.js を使う行・印・札の頭）: 指の形と、つまみの印 */
.dragsrc { cursor: grab; }
.dragsrc:active { cursor: grabbing; }
.draggrip { display: inline-grid; place-items: center; flex: none; color: var(--fg-3); }
.draggrip .i { width: 14px; height: 14px; }

/* ---------------------------------------------------------------- 出典の短いラベル（parts.js の Src。公式・海外の値・幾何を形と色で分ける） */
.src { display: inline-flex; align-items: center; padding: 0 6px; border-radius: 3px; font-size: calc(13px * var(--fs-x)); font-weight: 700; line-height: 20px; white-space: nowrap; vertical-align: 1px; }
.src.k0 { padding: 0 5px; border: 3px double var(--k0); color: var(--k0); line-height: 14px; }
.src.k1, .src.k4 { background: var(--k1); color: var(--k1-on); }
.src.k2 { border: 1.5px dashed var(--k2); color: var(--k2); line-height: 17px; }
.src.k3 { border: 1.5px solid var(--k3); color: var(--k3); line-height: 17px; }
.src.k5 { border: 1.5px solid var(--k5); border-radius: 10px; color: var(--k5); line-height: 17px; }

/* ---------------------------------------------------------------- 値の出どころの1行と、気象庁の発表の欄（components/Provenance.js。T16 d3） */
.srcline { display: flex; flex-direction: column; gap: 4px; font-size: calc(13px * var(--fs-x)); line-height: 1.6; color: var(--fg-1); }
.srcline p { margin: 0; }
.srcrow { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; }
.srclead { color: var(--fg-2); }
.srcitem { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 4px; min-width: 0; }
.srcwhat { color: var(--fg-1); }
.srcnote { color: var(--fg-2); }
.jman { display: flex; flex-direction: column; gap: 8px; padding: 10px 12px; border: 1px solid var(--line-strong); border-radius: var(--r-s); background: var(--bg-1);
  font-size: calc(13px * var(--fs-x)); line-height: 1.6; color: var(--fg-0); }
.jmar { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.jmah { display: flex; flex-wrap: wrap; align-items: center; gap: 2px; margin: 0; font-weight: 700; }
.jmaht { min-width: 0; overflow-wrap: anywhere; }
.jmad { display: flex; flex-direction: column; gap: 2px; padding-left: 4px; border-left: 3px double var(--k0); }
.jmadw { margin: 0; padding-left: 6px; font-weight: 700; }
.jmaa { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 12px; margin: 0; padding-left: 6px; }
.jmaan { font-weight: 700; overflow-wrap: anywhere; }
.jmav { overflow-wrap: anywhere; }
.jmaq { font-weight: 700; }
.jman-notes { display: flex; flex-direction: column; gap: 2px; margin: 0; padding-left: 18px; color: var(--fg-1); }
.jman-notes li.must { font-weight: 700; color: var(--fg-0); }
.jmasrc { margin: 0; color: var(--fg-2); }

/* ---------------------------------------------------------------- 照合の記号（StateMark）と、1時間ごとの升の帯（StateStrip）: 3色（--ok-*・--part-*・--no-*） */
.stm { display: inline-flex; align-items: baseline; gap: 4px; font-size: calc(13.5px * var(--fs-x)); white-space: nowrap; }
.stm b { font-weight: 800; }
.stm.st-in { color: var(--ok-bar); } .stm.st-edge { color: var(--fg-0); } .stm.st-out { color: var(--no-bar); }
.stm.st-unknown, .stm.st-deferred { color: var(--fg-2); }
.stm.st-split { color: var(--fg-2); }      /* T28: 前の結果の分かれるは値なしの ？ と同じ */
.stm .stv { font-variant-numeric: tabular-nums; }
.ststrip { display: inline-grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); gap: 2px; width: 100%; }
.ststrip i { display: grid; place-items: center; min-height: 20px; border-radius: 4px; font-style: normal; font-size: calc(13px * var(--fs-x)); line-height: 1; background: var(--bg-2); color: var(--fg-2); }
.ststrip .st-in { background: var(--ok-bg); color: var(--ok-bar); }
.ststrip .st-edge { background: var(--part-bg); color: var(--fg-0); box-shadow: inset 0 0 0 1px var(--part-bar); }
.ststrip .st-out { background: var(--no-bg); color: var(--no-bar); box-shadow: inset 0 0 0 1px var(--no-bar); }
.ststrip .st-unknown, .ststrip .st-split { background: var(--unk-bg); color: var(--unk-fg); }     /* T28: 縞はやめた（前の結果の分かれるも値なしの灰） */

/* ---------------------------------------------------------------- 照合の札（parts.js の State・地図の面の札）: 4状態を無地の色＋記号で（--in-*・--edge-*・--out-*・--unk-*。
   T28＝本人の答え 10/19: 前の点描・斜線・横縞はやめた） */
   蓄熱の待ち（warm）・余熱（hold）は赤外線の熱の時間。.cell は型の表の状態の帯の升（下の「型の表」） */
.stw { display: inline-flex; align-items: center; gap: 4px; vertical-align: 1px; }
.stl { font-size: calc(13px * var(--fs-x)); }
.st { display: inline-grid; place-items: center; min-width: 22px; height: 22px; padding: 0 4px; border-radius: 4px; font-size: calc(13px * var(--fs-x)); font-weight: 700; line-height: 1; }
.st.in, .cell.in { background: var(--in-bg); color: var(--in-fg); box-shadow: inset 0 0 0 1px var(--in-bd); }
.st.edge, .cell.edge { background-color: var(--edge-bg); color: var(--edge-fg); box-shadow: inset 0 0 0 1px var(--edge-dot); }
.st.out, .cell.out { background: var(--out-bg); color: var(--out-fg); box-shadow: inset 3px 0 0 var(--out-bar); }
.st.unknown, .cell.unknown, .st.split, .cell.split { background-color: var(--unk-bg); color: var(--unk-fg); box-shadow: inset 0 0 0 1px var(--unk-bar); }
.st.deferred, .cell.deferred { background: var(--bg-2); color: var(--fg-1); outline: 1px solid var(--fg-3); outline-offset: -1px; }   /* 当日に確かめる（照らしていない。T28: 破線の枠をやめた） */
/* 熱の時間軸: 温まり待ち（蓄）＝淡い琥珀の地・余熱（余）＝白い地（どちらも琥珀の枠。字で分ける。T28: 余熱の横縞はやめた） */
.st.warm, .cell.warm { background: var(--q-amber-lo); color: var(--fg-0); box-shadow: inset 0 0 0 1.5px var(--k5); }
.st.hold, .cell.hold { background-color: var(--bg-1); color: var(--fg-0); box-shadow: inset 0 0 0 1.5px var(--k5); }

/* ---------------------------------------------------------------- 小窓（押すと出る一覧。上部バーの下に出る）と表 */
.pop { position: absolute; top: 100%; left: 12px; z-index: 60; width: min(420px, calc(100vw - 24px)); max-height: min(70vh, 560px); overflow: auto;
  padding: 6px 0 10px; border: 1px solid var(--rule-1); border-radius: var(--r-l); background: var(--bg-1); box-shadow: var(--sh-3); font-size: calc(13.5px * var(--fs-x)); }
.pop.pop-r { left: auto; right: 12px; }
.pop-h { display: flex; flex-direction: column; gap: 2px; padding: 6px 12px; border-bottom: 1px solid var(--rule-1); font-weight: 700; }
.mtab { width: 100%; margin-top: 6px; border-collapse: collapse; font-size: calc(13px * var(--fs-x)); }
.mtab th, .mtab td { padding: 4px 6px; border-bottom: 1px solid var(--rule-1); text-align: left; vertical-align: top; }
.mtab thead th { white-space: nowrap; }      /* 列の見出しは折り返さない */
.mtab td.v { font-family: var(--f-mono); text-align: right; white-space: nowrap; }
.mtab caption { padding: 4px 0; text-align: left; font-size: calc(13px * var(--fs-x)); font-weight: 700; }
/* T16 第3回 UI-12（g1.12・t3.10・t5.12・t8.8・t9.10・ir2.9・ir3.13）: データの時刻の表はスマホ幅で右の列が切れ、「10/9 15時」が折れた＝
   表を横に送れる入れ物に入れ、時刻の字は折らない */
.mtabw { max-width: 100%; overflow-x: auto; }
.mtab.mtime td.mono, .mtab.mtime td .mono { white-space: nowrap; }
/* T21 の歩きの直し W9: PC の幅でも表が小窓（前は 420px）からはみ出し、右の列の見出し「次の目安」が「次の目」で切れ、遅れの行の字は 1 字ずつ細く
   折れて切れた（品目の札「気象庁 2週間〜1か月のアンサンブル」が長い）。小窓を表の入る幅にし、遅れの字の升は 8 字ほどの幅で折る（字の長さで
   ほかの列を押さない）。品目の札は、小窓が表より狭い幅（560px まで）だけ語の間で折る */
.pop.pop-time { width: min(520px, calc(100vw - 24px)); }
.mtab.mtime td.mlate { min-width: 8em; }
@media (max-width: 560px) {
  .mtab.mtime td .src { white-space: normal; }
}
/* T16 第4回（t9.12・ir3.15）: スマホ幅で表が 442px になり、右の列（次の目安）が切れた。狭い幅は升を詰め、品目の札と日付つきの時刻は
   語の切れ目で折る（時刻の「10/10」と「05:30」の間など。字の途中では割らない） */
@media (max-width: 480px) {
  .mtab.mtime th, .mtab.mtime td { padding: 4px 3px; }
  .mtab.mtime td.mono, .mtab.mtime td .mono { white-space: normal; word-break: keep-all; }
}
.tbl-wrap { max-width: 100%; overflow-x: auto; }

/* ---------------------------------------------------------------- 型の表が使う部品（js/types/*.js の Tables・TimeInfo）
   今は型の表を出す画面が無い（入口を閉じた型。T0 の T-D4）。型を画面に出すときのために、js が出す class の見た目だけを残している */
.strip { position: relative; width: 100%; height: 18px; border-radius: 3px; background: var(--dim-bg); overflow: hidden; cursor: pointer; }   /* 状態の帯（時間帯を横に並べる） */
.strip .cell { position: absolute; top: 0; bottom: 0; display: grid; place-items: center; overflow: hidden; font-size: calc(13px * var(--fs-x)); font-weight: 700; }
.cell.info { background: var(--dim-bg); }
.cell.none { background: var(--dim-bg); color: var(--fg-3); }
.cell.withheld { background: var(--bg-2); color: var(--fg-1); outline: 1px solid var(--fg-3); outline-offset: -1px; }
details.fold > summary { display: flex; align-items: center; gap: 6px; min-height: 32px; color: var(--fg-1); font-size: calc(13px * var(--fs-x)); cursor: pointer; list-style: none; }
details.fold > summary::-webkit-details-marker { display: none; }
details.fold > summary .i { transition: transform .15s; }
details.fold[open] > summary .i { transform: rotate(90deg); }
.chip { display: inline-flex; align-items: center; gap: 6px; max-width: 100%; min-height: 32px; padding: 3px 10px; border: 1px solid var(--line-strong); border-radius: var(--r-pill);
  background: var(--bg-1); font-size: calc(13px * var(--fs-x)); line-height: 1.4; text-align: left; }
.tper-h { display: flex; flex-wrap: nowrap; align-items: baseline; gap: 10px; min-width: 0; overflow: hidden; font-size: calc(13px * var(--fs-x)); white-space: nowrap; text-overflow: ellipsis; }
.tper-h b { font-weight: 700; }
.tper-chips { display: flex; align-items: center; gap: 4px; min-width: 0; overflow-x: auto; }
.tper-chips .tper { flex: none; padding: 1px 8px; border: 1.5px solid var(--k3); border-radius: var(--r-s); background: var(--bg-1); color: var(--fg-0); font-size: calc(13px * var(--fs-x)); line-height: 20px; white-space: nowrap; }
@media (prefers-reduced-motion: reduce) { details.fold > summary .i { transition: none; } }

/* ================================================================ スマホ 〜767: 押す所 44px */
@media (max-width: 767px) {
  .btn { min-width: 44px; }
  .btn.sm { min-height: 44px; }
  .ibtn, .ibtn.sm { width: 44px; height: 44px; }
  .link { display: inline-flex; align-items: center; min-height: 44px; }
  .seg button { min-width: 44px; min-height: 44px; }
  .chk { min-height: 44px; }
  button.tf, .numf input, input.txf { height: 44px; }
  .rtrack { height: 32px; background-size: 100% 8px; }
  .rtrack .rin { top: 12px; height: 8px; }
  .rtrack .rknob { top: 4px; width: 4px; height: 24px; }
  .psform input { height: 44px; }
  .psform .psgo, .psform .psclr { min-width: 44px; min-height: 44px; }
  /* チャット欄: 釦は 44px（.btn の決まり）を2つ縦に並べるので、欄も同じ高さに。欄の字は 16px（iOS が欄に入った時に拡大しない大きさ） */
  .cbx { min-height: 260px; max-height: 360px; }
  .cbxin textarea { height: 92px; font-size: calc(16px * var(--fs-x)); }
  .cbxph .link { justify-content: center; min-width: 44px; }
  .chip { min-height: 44px; }
}
