/* 条件の部品: 条件の表（js/conditions/ConditionTable.js）・設定＝標準の条件の画面（js/settings/。デザイン案 cond/03「標準の表」）・
   計画の中で条件を直す欄（js/conditions/ConditionEditor.js）。照合は ○範囲内＝--ok-*・△境目＝--part-*・×外れる＝--no-*
   （色だけで伝えない＝記号を添える）。字は 13px 以上。スマホ（767px 以下）は押す所 44px 以上・表は1条件ずつの札に組み替える。 */

/* ================================================================ 条件の表（.ctbl。設定と、条件を並べるほかの画面で共用） */
.ctbl { display: flex; flex-direction: column; min-width: 0; }
.ctbl-tr { position: relative; display: grid; grid-template-columns: 124px minmax(0, 1fr) 124px 116px 104px 44px; align-items: center; min-height: 54px;
  border-top: 1px solid var(--rule-1); }
.ctbl.nolatest .ctbl-tr { grid-template-columns: 124px minmax(0, 1fr) 124px 116px 44px; }
.ctbl-tr > * { padding: 0 8px; min-width: 0; }
.ctbl-tr > *:first-child { padding-left: 16px; }
.ctbl-th { min-height: 34px; border-top: 0; background: var(--bg-2); color: var(--fg-2); font-size: calc(13px * var(--fs-x)); font-weight: 600; }
.ctbl-empty { grid-template-columns: 1fr; color: var(--fg-1); font-size: calc(14px * var(--fs-x)); }

/* 名前（短い語＋補い）・直した印・ほかの作業にもある条件の帯 */
.ctbl .c-n { display: flex; flex-direction: column; line-height: 1.3; padding-top: 6px; padding-bottom: 6px; }
.ctbl .c-n b { font-size: calc(15px * var(--fs-x)); }
.ctbl .c-n em { font-style: normal; font-size: calc(13px * var(--fs-x)); color: var(--fg-2); }
.ctbl-tag { font-style: normal; font-size: calc(13px * var(--fs-x)); font-weight: 700; color: var(--sel); }
.ctbl-tr.same::before { content: ""; position: absolute; left: 0; top: 10px; bottom: 10px; width: 3px; border-radius: 2px; background: var(--sel); opacity: .35; }

/* ことば */
.ctbl .c-w { font-size: calc(14px * var(--fs-x)); line-height: 1.4; padding-top: 6px; padding-bottom: 6px; word-break: auto-phrase; }

/* 数（数の欄＋単位。上下限は2つ） */
.ctbl .c-v { display: flex; align-items: center; gap: 4px; white-space: nowrap; }
.ctbl .numf { gap: 4px; }
.ctbl .numf input { width: 48px; height: 34px; padding: 0 7px; border-radius: var(--r-s); }
.ctbl .numf.sm input { width: 38px; padding: 0 5px; }
.ctbl .c-v .unit { font-size: calc(13px * var(--fs-x)); color: var(--fg-1); }
.ctbl-plain { font-size: calc(13px * var(--fs-x)); color: var(--fg-1); }
.ctbl-tr.chg .numf input, .ctbl-tr.chg .sel select { border-color: var(--sel); }

/* 向き（選択欄。数でない条件は字だけの枠） */
.ctbl .c-d { display: flex; padding: 0 4px; }
.ctbl .sel { flex: 1 1 auto; min-width: 0; }
.ctbl .sel select { width: 100%; height: 34px; padding: 0 22px 0 8px; border-color: var(--line-strong); border-radius: var(--r-s); background: var(--bg-1);
  color: var(--fg-0); font-size: calc(14px * var(--fs-x)); }
.ctbl .sel::after { right: 9px; }
.ctbl-fix { display: flex; align-items: center; flex: 1 1 auto; min-width: 0; height: 34px; padding: 0 8px; border: 1px solid var(--rule-1); border-radius: var(--r-s);
  background: var(--bg-2); color: var(--fg-1); font-size: calc(14px * var(--fs-x)); white-space: nowrap; }

/* 直前の計算（○△× と値の幅） */
.ctbl .c-r { display: flex; flex-direction: column; gap: 1px; line-height: 1.3; padding-right: 0; }
.ctbl .c-r em { font-style: normal; font-size: calc(13px * var(--fs-x)); color: var(--fg-2); white-space: nowrap; font-variant-numeric: tabular-nums; }
.ctbl-tr.hit .c-r em { color: var(--no-bar); }
.ctbl .stm, .std-legend .stm { align-items: center; gap: 5px; font-size: calc(14px * var(--fs-x)); font-weight: 700; }
.std-legend .stm { font-size: calc(13px * var(--fs-x)); }
.ctbl .stm b, .std-legend .stm b { display: inline-grid; place-items: center; flex: none; width: 18px; height: 18px; border-radius: 4px; font-size: calc(13px * var(--fs-x)); line-height: 1;
  background: var(--bg-2); color: var(--fg-2); }
.ctbl .stm.st-in b, .std-legend .stm.st-in b { background: var(--ok-bg); color: var(--ok-bar); }
.ctbl .stm.st-edge b, .std-legend .stm.st-edge b { background: var(--part-bg); color: var(--fg-0); box-shadow: inset 0 0 0 1px var(--part-bar); }
.ctbl .stm.st-out b, .std-legend .stm.st-out b { background: var(--no-bg); color: var(--fg-0); box-shadow: inset 0 0 0 1px var(--no-bar); }
.ctbl-nil { color: var(--fg-2); font-size: calc(14px * var(--fs-x)); }

/* 外す */
.ctbl .c-x { padding: 0 8px 0 0; text-align: right; }
.ctbl-x { height: 32px; padding: 0; border: 0; background: transparent; color: var(--fg-2); font-size: calc(13px * var(--fs-x)); white-space: nowrap; }
.ctbl-x:hover:not(:disabled) { color: var(--fg-0); text-decoration: underline; text-underline-offset: 3px; }
.ctbl-x:disabled { opacity: .5; }

/* ================================================================ 設定＝標準の条件の画面（.std-*。上部バーの下に重ねる＝shell.css の .overlay） */
.overlay > .stdscreen { min-width: 0; }
/* 頭: 左に題と説明、右に「直した所・初めの標準に戻す・保存して閉じる・閉じる」を1列に（釦の入れ物は中身だけを升に置く） */
.std-top { flex: none; display: grid; grid-template-columns: minmax(0, 1fr) auto auto auto auto; column-gap: 10px; align-items: end; padding: 18px 20px 16px;
  border-bottom: 1px solid var(--rule-1); }
.std-pre, .std-bar, .std-act { display: contents; }
.std-head { grid-column: 1; grid-row: 1; min-width: 0; padding-right: 14px; }
.std-crumb { font-size: calc(13px * var(--fs-x)); color: var(--fg-2); }
.std-crumb b { color: var(--fg-1); font-weight: 600; }
.std-head h1 { margin-top: 4px; font-size: calc(22px * var(--fs-x)); line-height: 1.3; outline: none; }
.std-lead { margin-top: 6px; font-size: calc(14px * var(--fs-x)); line-height: 1.5; color: var(--fg-1); word-break: auto-phrase; }
.std-pend { grid-column: 2; grid-row: 1; margin-right: 4px; font-size: calc(13px * var(--fs-x)); line-height: 44px; color: var(--fg-1); white-space: nowrap; }
.std-pend b { color: var(--sel); }
.std-reset { grid-column: 3; grid-row: 1; }
.std-save { grid-column: 4; grid-row: 1; }
.std-close { grid-column: 5; grid-row: 1; }
.btn.std-b { min-height: 44px; padding: 0 16px; font-size: calc(14.5px * var(--fs-x)); }
.btn.pri.std-b { padding: 0 18px; }
.std-close .i { width: 16px; height: 16px; }

/* 確かめの1行（初めの標準に戻す・保存していない直し）。頭の下の端いっぱいに出す */
.std-ask { grid-column: 1 / -1; grid-row: 2; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; margin: 14px -20px -16px; padding: 10px 20px;
  border-top: 1px solid var(--rule-1); background: var(--part-bg); color: var(--fg-0); font-size: calc(14px * var(--fs-x)); }
.std-askb { display: flex; flex-wrap: wrap; gap: 8px; }

/* 中身（縦に巻き取る） */
.std-body { flex: 1 1 auto; min-height: 0; min-width: 0; overflow-x: hidden; overflow-y: auto; scrollbar-width: thin; scrollbar-color: var(--line-strong) transparent; }
.std-wait { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; padding: 24px 20px 0; font-size: calc(14px * var(--fs-x)); color: var(--fg-1); }
/* 作業の札は幅に合わせて折り返す（1枚 640px から。作業が3つ以上でも表の「ことば」の列が潰れない） */
.std-cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 640px), 1fr)); gap: 16px; padding: 18px 20px 8px; }

/* 作業ごとの札 */
.std-card { display: flex; flex-direction: column; min-width: 0; overflow: hidden; border: 1px solid var(--line-strong); border-radius: var(--r-l); background: var(--bg-1); }
.std-chead { display: flex; align-items: center; gap: 12px; padding: 12px 14px 12px 16px; border-bottom: 1px solid var(--rule-1); }
.std-wk { display: grid; place-items: center; flex: none; width: 34px; height: 34px; border-radius: var(--r-m); background: var(--sel-soft); color: var(--sel); }
.std-wk .i { width: 20px; height: 20px; }
.std-ct { min-width: 0; }
.std-chead h2 { font-size: calc(17px * var(--fs-x)); line-height: 1.4; }
.std-meta { font-size: calc(13px * var(--fs-x)); line-height: 1.35; color: var(--fg-2); }
.std-add { display: inline-flex; align-items: center; gap: 4px; flex: none; height: 38px; margin-left: auto; padding: 0 12px; border: 1px dashed var(--sel);
  border-radius: var(--r-m); background: var(--bg-1); color: var(--sel); font-size: calc(14px * var(--fs-x)); font-weight: 700; white-space: nowrap; }
.std-add:hover:not(:disabled) { background: var(--sel-soft); }
.std-add:disabled { opacity: .5; }
.std-add .i { width: 16px; height: 16px; }
.std-addrow { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 10px 16px; background: var(--sel-soft); border-bottom: 1px solid var(--rule-1); }
.std-addrow .sel { flex: 1 1 200px; min-width: 0; }
.std-addrow .sel select { width: 100%; height: 44px; font-size: calc(14.5px * var(--fs-x)); background: var(--bg-1); color: var(--fg-0); border-color: var(--line-strong); }
.std-addnote { flex-basis: 100%; font-size: calc(13px * var(--fs-x)); color: var(--fg-1); }
.std-cfoot { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 16px; margin-top: auto; padding: 10px 16px; border-top: 1px solid var(--rule-1);
  background: var(--bg-2); font-size: calc(13px * var(--fs-x)); color: var(--fg-1); }
.std-cfoot b { color: var(--fg-0); }

/* 足（凡例・説明・作業ごとの直前の計画） */
.std-below { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px 24px; align-items: start; padding: 10px 20px 22px; }
.std-legend { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 16px; font-size: calc(13px * var(--fs-x)); color: var(--fg-1); }
.std-samekey i { display: inline-block; width: 3px; height: 14px; margin-right: 6px; border-radius: 2px; background: var(--sel); opacity: .35; vertical-align: -2px; }
/* T47 の 10/28 の直し（全体管理の決め V22・点検 N3）: 足の行は独りの行（凡例の下・全部の幅）。前は凡例｜足の行の 2 列（auto の列）で、V15 で足の行に値の性質の断り
   （LATEST_NOTE）を足すと auto の列が字の長さまで広がり、幅 1100 以上で凡例が約 31px の列に押し込まれて縦に 5 段・「○ 範囲内」と足の行が 7px 重なった */
.std-note { grid-column: 1 / -1; font-size: calc(13px * var(--fs-x)); color: var(--fg-1); }
.std-uses { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); margin: 0; padding: 0; list-style: none; overflow: hidden;
  border: 1px solid var(--rule-1); border-radius: var(--r-l); }
.std-uses li { display: flex; flex-wrap: wrap; align-items: center; gap: 2px 10px; min-width: 0; padding: 10px 14px; font-size: calc(13px * var(--fs-x)); color: var(--fg-1);
  box-shadow: -1px 0 0 var(--rule-1), 0 -1px 0 var(--rule-1); }
.std-uses b { color: var(--fg-0); font-size: calc(14px * var(--fs-x)); }
.std-open { display: inline-flex; align-items: center; gap: 2px; min-height: 32px; margin-left: auto; font-size: calc(14px * var(--fs-x)); font-weight: 700; white-space: nowrap; }
.std-open .i { width: 14px; height: 14px; }

/* 用意の目安の欄（T20・決め P7。旅行の札だけ＝js/settings/PrepCard.js）。頭の釦で開く。行＝条件（要素と向き）｜お客の分｜ガイドの分。
   開いている間は札の高さをそろえない（隣の札に空きを作らない） */
.std-cols:has(.std-prep.open) { align-items: start; }
.std-prep { border-top: 1px solid var(--rule-1); }
.std-ph { margin: 0; font-size: calc(15px * var(--fs-x)); }
.std-ptog { display: flex; align-items: center; gap: 8px; width: 100%; min-height: 44px; padding: 8px 16px; border: 0; background: none; color: var(--fg-0);
  font: inherit; font-size: calc(15px * var(--fs-x)); font-weight: 700; text-align: left; cursor: pointer; }
.std-ptog:hover { background: var(--bg-2); }
.std-ptog .i { flex: none; width: 14px; height: 14px; color: var(--fg-2); transition: transform .15s; }
.std-prep.open .std-ptog .i { transform: rotate(90deg); }
.std-pst { margin-left: auto; font-size: calc(13px * var(--fs-x)); font-weight: 400; color: var(--fg-1); white-space: nowrap; }
/* 口が読む時に外した語・辞書を読めずに出していない一覧の知らせ（T20 の点検 F7。閉じていても見える1行） */
.std-pblk { margin: 0 16px 10px; padding: 6px 10px; border-left: 3px solid var(--rule-2); background: var(--bg-2); font-size: calc(13px * var(--fs-x)); line-height: 1.5; color: var(--fg-1); }
.std-pbody { padding: 0 16px 14px; }
.std-plead { font-size: calc(13px * var(--fs-x)); line-height: 1.5; color: var(--fg-1); word-break: auto-phrase; }
.std-pslots { margin: 8px 0 0; padding: 0; list-style: none; overflow: hidden; border: 1px solid var(--rule-1); border-radius: var(--r-l); }
.std-pslot { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 6px 16px; align-items: start; padding: 10px 12px 12px; border-top: 1px solid var(--rule-1); }
.std-pslot:first-child { border-top: 0; }
.std-pcond { grid-column: 1 / -1; min-width: 0; font-size: calc(14px * var(--fs-x)); line-height: 1.5; color: var(--fg-1); word-break: auto-phrase; }
.std-pcond b { font-size: calc(15px * var(--fs-x)); color: var(--fg-0); }
.std-pwho { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.std-pwl { font-size: calc(13px * var(--fs-x)); font-weight: 700; color: var(--fg-1); }
.std-pchips { display: flex; flex-wrap: wrap; gap: 6px; min-width: 0; margin: 0; padding: 0; list-style: none; }
.std-pchip { gap: 2px; min-height: 30px; padding: 2px 2px 2px 10px; font-size: calc(14px * var(--fs-x)); overflow-wrap: anywhere; }
.std-pdel { display: grid; place-items: center; flex: none; width: 26px; height: 26px; padding: 0; border: 0; border-radius: 50%; background: none; color: var(--fg-2); cursor: pointer; }
.std-pdel:hover:not(:disabled) { background: var(--no-bg); color: var(--fg-0); }
.std-pdel:disabled { opacity: .5; cursor: default; }
.std-pdel .i { width: 12px; height: 12px; }
.std-pnil { font-size: calc(13px * var(--fs-x)); line-height: 30px; color: var(--fg-2); }
.std-padd { display: flex; gap: 6px; min-width: 0; }
.std-padd .std-pin { flex: 1 1 auto; font-size: calc(14px * var(--fs-x)); }
.btn.std-pgo { flex: none; min-height: 36px; }
.std-pnone, .std-prest { margin-top: 8px; font-size: calc(13px * var(--fs-x)); line-height: 1.5; color: var(--fg-1); }
.std-pfoot { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; margin-top: 10px; }
.std-pask { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; padding: 8px 12px; border-radius: var(--r-m); background: var(--part-bg); color: var(--fg-0); font-size: calc(14px * var(--fs-x)); }
@media (prefers-reduced-motion: reduce) { .std-ptog .i { transition: none; } }

/* ================================================================ 計画の中で条件を直す欄（.cedit。1日の升目の列の見出し・［＋条件］から開く）
   条件は1行ずつの表（名前｜ことば｜数と向き｜外す）。ことばの選びが在る行は .hasw、数でない行は .txt、足す行は .add・.addw・.more */
.cedit { display: flex; flex-direction: column; gap: 10px; padding: 6px 12px 8px; }
.cset { padding-top: 8px; border-top: 1px solid var(--rule-1); }
.csethd { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 8px; margin-bottom: 6px; font-size: calc(14px * var(--fs-x)); }
.csethd .i { width: 15px; height: 15px; align-self: center; color: var(--fg-2); }
.csethd small { font-size: calc(13px * var(--fs-x)); color: var(--fg-2); }
.csethd .busy { color: var(--sel); }
.clist { list-style: none; margin: 0; padding: 0; border: 1px solid var(--rule-1); border-radius: var(--r-l); overflow: hidden; }
.citem { display: grid; grid-template-columns: 7.5em auto minmax(0, 1fr) 36px; align-items: center; gap: 6px; min-height: 44px; padding: 4px 4px 4px 12px;
  border-top: 1px solid var(--rule-1); background: var(--bg-1); }
.citem:first-child { border-top: 0; }
.citem .cl { min-width: 0; font-size: calc(14px * var(--fs-x)); font-weight: 600; overflow-wrap: anywhere; }
.citem .cval, .citem .cnum { display: inline-flex; align-items: center; gap: 4px; }
.citem.hasw { grid-template-columns: 7.5em 12em auto minmax(0, 1fr) 36px; }
.citem .sel.cw, .citem .sel.cw select { width: 100%; }
.citem .sel.cw select { font-weight: 600; text-overflow: ellipsis; }
.citem.hasw .cnum .ctext { color: var(--fg-1); font-size: calc(13.5px * var(--fs-x)); }
.citem .cwnone { padding-left: 10px; font-size: calc(13px * var(--fs-x)); color: var(--fg-2); }
.citem .unit { min-width: 2.2em; font-size: calc(13px * var(--fs-x)); color: var(--fg-2); }
.citem > .cx { grid-column: -2; }
.citem.txt { grid-template-columns: 7.5em minmax(0, 1fr) 36px; }
.citem .ctext { font-size: calc(14px * var(--fs-x)); color: var(--fg-0); }
/* 数の欄。直す欄（.cvn）は字の欄（type=text。T16 第9回: 数の欄は打った字そのものを返さないので、打った字を読む欄にした）・足す欄は数の欄。見た目は同じ */
.cedit input[type="number"], .cedit input.cvn { width: 4.6em; height: 32px; padding: 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)); font-variant-numeric: tabular-nums; text-align: right; -moz-appearance: textfield; }
.cedit input[type="number"]::-webkit-inner-spin-button, .cedit input[type="number"]::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
.cedit input:focus-visible { outline: 2px solid var(--sel); outline-offset: 1px; border-color: var(--sel); }
.cedit input:disabled { opacity: .6; }
/* 受けない数の断りの1行（T16 第8回・t9: 波 51m・気温 532℃ などは送らずに、欄の下にわけを出す。行の全部の幅・色だけで伝えない＝文で言う） */
.cbad { grid-column: 1 / -1; flex-basis: 100%; margin: 0; font-size: calc(13px * var(--fs-x)); font-weight: 700; line-height: 1.5; color: var(--no-bar); overflow-wrap: anywhere; }
/* 外す釦（×） */
.cx { display: grid; place-items: center; width: 32px; height: 32px; border: 0; border-radius: 50%; background: none; color: var(--fg-2); cursor: pointer; }
.cx:hover:not(:disabled) { background: var(--no-bg); color: var(--no-bar); }
.cx:disabled { opacity: .35; cursor: default; }
.cx .i { width: 14px; height: 14px; }
/* 条件を足す: ことばで選ぶ札（気象庁の用語集の区分）・数で決める行・［条件を足す］ */
.citem.addw { display: block; padding: 8px 10px 10px 12px; background: var(--bg-2); }
.awhead { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; margin-bottom: 6px; font-size: calc(14px * var(--fs-x)); }
.awhead small { color: var(--fg-2); font-size: calc(13px * var(--fs-x)); }
.awgrp { display: grid; grid-template-columns: 6.5em minmax(0, 1fr); gap: 6px; align-items: start; padding: 6px 0; border-top: 1px solid var(--rule-1); }
.awel { padding-top: 8px; color: var(--fg-1); font-size: calc(13.5px * var(--fs-x)); font-weight: 600; }
.awchips { display: flex; flex-wrap: wrap; gap: 6px; }
/* 足せない要素のわけ（環境省の暑さ指数の提供の期間の外。T16 第3回） */
.awoff { flex-basis: 100%; margin: 6px 0 0; padding-top: 6px; border-top: 1px solid var(--rule-1); color: var(--fg-2); font-size: calc(13px * var(--fs-x)); line-height: 1.5; }
.wchip { display: inline-flex; flex-direction: column; align-items: flex-start; gap: 0; min-height: 44px; padding: 4px 12px; border: 1px solid var(--rule-2);
  border-radius: var(--r-m); background: var(--bg-1); color: var(--fg-0); font: inherit; text-align: left; cursor: pointer; }
.wchip b { font-size: calc(14px * var(--fs-x)); font-weight: 600; }
.wchip small { font-size: calc(13px * var(--fs-x)); color: var(--fg-2); font-variant-numeric: tabular-nums; }
.wchip:hover { border-color: var(--sel); background: var(--sel-soft); }
.wchip:focus-visible { outline: 2px solid var(--sel); outline-offset: 1px; }
.citem.add { grid-template-columns: auto auto auto; justify-content: start; flex-wrap: wrap; background: var(--bg-2); }
.citem.add .cbtns { grid-column: 1 / -1; display: flex; gap: 6px; justify-content: flex-end; }
.citem.more { display: block; min-height: 0; padding: 0; }
.cadd { display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding: 0 12px; border: 0; background: none; color: var(--sel); font: inherit; font-size: calc(14px * var(--fs-x)); cursor: pointer; }
.cadd .i { width: 14px; height: 14px; }
.cadd:disabled { opacity: .5; cursor: default; }
.citem.more .cadd { width: 100%; }
.cadd:hover:not(:disabled) { text-decoration: underline; }

/* ================================================================ 幅 1099px 以下: 頭の釦を題の下へ */
@media (max-width: 1099px) {
  .std-top { grid-template-columns: auto auto auto auto minmax(0, 1fr); row-gap: 10px; }
  .std-head { grid-column: 1 / -1; padding-right: 0; }
  .std-pend { grid-column: 1; grid-row: 2; }
  .std-reset { grid-column: 2; grid-row: 2; }
  .std-save { grid-column: 3; grid-row: 2; }
  .std-close { grid-column: 4; grid-row: 2; }
  .std-ask { grid-row: 3; margin-top: 4px; }
  .std-below { grid-template-columns: minmax(0, 1fr); }
}

/* ================================================================ スマホ 〜767px: 表を1条件ずつの札に（名前と直前の計算｜ことば｜数・向き・外す） */
@media (max-width: 767px) {
  /* 画面ごと縦に巻き取る。題と説明は流れ、［保存して閉じる］［閉じる］の帯だけ上に残す */
  .overlay > .stdscreen { overflow-x: hidden; overflow-y: auto; }
  .std-top { display: contents; }
  .std-head { flex: none; padding: 14px 16px 10px; }
  .std-pre { display: flex; flex: none; padding: 0 16px 12px; }
  .std-bar { display: block; flex: none; position: sticky; top: 0; z-index: 3; background: var(--bg-1); border-top: 1px solid var(--rule-1); border-bottom: 1px solid var(--rule-1); }
  .std-act { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 8px 16px; }
  .std-pend { flex: 1 1 auto; margin: 0; line-height: 1.4; }
  .btn.std-b, .btn.pri.std-b { padding: 0 12px; }
  .std-ask { margin: 0; padding: 10px 16px; }
  .std-body { flex: none; overflow: visible; }
  .std-cols { padding: 14px 16px 6px; }
  .std-chead { flex-wrap: wrap; }
  .std-add { height: 44px; margin-left: 0; flex-basis: 100%; justify-content: center; }
  .std-below { padding: 10px 16px 22px; }
  .std-uses li { min-height: 52px; }
  .std-open { min-height: 44px; min-width: 44px; }
  /* 用意の目安（T20）: 1行を縦に（条件 → お客の分 → ガイドの分）。札の［×］と足す欄は 44px */
  .std-pbody { padding: 0 14px 14px; }
  .std-pslot { grid-template-columns: minmax(0, 1fr); gap: 10px; }
  .std-pdel { width: 44px; height: 44px; }
  .btn.std-pgo { min-height: 44px; }

  .ctbl .ctbl-tr.ctbl-th { display: none; }
  .ctbl-tr, .ctbl.nolatest .ctbl-tr { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; min-height: 0; padding: 12px 14px; }
  .ctbl-tr > *, .ctbl-tr > *:first-child { padding: 0; }
  .ctbl .c-n { order: 1; flex: 1 1 0; flex-direction: row; flex-wrap: wrap; align-items: baseline; gap: 0 8px; }
  .ctbl .c-r { order: 2; flex: 0 0 auto; align-items: flex-end; text-align: right; }
  .ctbl .c-w { order: 3; flex: 0 0 100%; }
  .ctbl .c-v { order: 4; flex: 0 0 auto; }
  .ctbl .c-d { order: 5; flex: 1 1 96px; min-width: 96px; padding: 0; }
  .ctbl .c-x { order: 6; flex: 0 0 auto; padding: 0; }
  .ctbl .numf input { width: 60px; height: 44px; }
  .ctbl .numf.sm input { width: 48px; }
  .ctbl .sel select, .ctbl-fix { height: 44px; }
  .ctbl-x { height: 44px; min-width: 44px; padding: 0 12px; border: 1px solid var(--line-strong); border-radius: var(--r-m); background: var(--bg-1); }
  .ctbl-tr.same::before { display: none; }

  /* 条件を直す欄: ことばの行は2段（上にことば、下に数と向き）。T47 の 10/28 の直し（V26・ui-10 の残り）: 外す釦の列は 44px（前は 32px。下の節） */
  .citem { grid-template-columns: 5.6em auto minmax(0, 1fr) 44px; gap: 4px; padding-left: 10px; }
  .citem.txt { grid-template-columns: 5.6em minmax(0, 1fr) 44px; }
  .citem.hasw { grid-template-columns: 5.6em minmax(0, 1fr) 44px; grid-template-areas: "l w x" "l n x"; row-gap: 4px; padding-top: 6px; padding-bottom: 6px; }
  .citem.hasw > .cl { grid-area: l; } .citem.hasw > .cw { grid-area: w; } .citem.hasw > .cnum { grid-area: n; } .citem.hasw > .cx { grid-area: x; }
  .citem .unit { min-width: 1.8em; }
  .cedit input[type="number"], .cedit input.cvn { width: 4em; }
  .awgrp { grid-template-columns: 1fr; gap: 4px; }
  .awel { padding-top: 0; }
}

/* ================================================================ T47 の 10/28 の直し（全体管理の決め V26・点検 ui-10 の残り）: 指で押す幅（スマホ 〜767・指で触る端末の 〜899）の
   条件を直す欄（.cedit。1 日の表の列の頭・旅行の条件から開く）の選び・数の欄・外す釦（×）と、欄を閉じる釦は 44px（前は 390 で選び 192×32・数 56×32・向き 78×32・
   外す 32×40、768 の指の端末で外す 32×32・閉じる 28×28）。PC と横向きの iPad（幅 900 以上）の高さは前のまま */
@media (max-width: 767px), (pointer: coarse) and (max-width: 899px) {
  .cedit .sel select, .cedit input[type="number"], .cedit input.cvn { height: 44px; }
  .cedit .cx { width: 44px; height: 44px; }
  .pedith .ibtn { width: 44px; height: 44px; }
}
@media (pointer: coarse) and (min-width: 768px) and (max-width: 899px) {
  .citem { grid-template-columns: 7.5em auto minmax(0, 1fr) 44px; }
  .citem.hasw { grid-template-columns: 7.5em 12em auto minmax(0, 1fr) 44px; }
  .citem.txt { grid-template-columns: 7.5em minmax(0, 1fr) 44px; }
}
