/* GREEN SIGHT 段取り — スマホで使うのが基本 */
:root {
  color-scheme: light;
  --bg: #f3f5f1; --paper: #fff; --ink: #1f2a24; --muted: #5e6b63; --line: #d5ddd6; --accent: #1d5c4a;
  /* 行き先の色：つむぎ＝緑、谷田邸＝オレンジ、小田工場＝水色、在宅＝薄紫 */
  --tsumugi: #d4eac4; --tsumugi-ink: #2f6b33;
  --yatei: #fbd9bd; --yatei-ink: #a24f0d;
  --oda: #cfe9f7; --oda-ink: #135f82;
  --zaitaku: #e6defa; --zaitaku-ink: #5b4a8a;
  --other: #eceae4;
  --blue: #1d63c9; --blue-bg: #d8e6fa;
  --red: #b42318; --red-bg: #fde4e1;
  --amber: #8a5a00; --amber-bg: #fff3cd;
  --ok: #1a7f37; --ok-bg: #e3f3e6;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 16px/1.5 "Hiragino Sans", "Noto Sans JP", "BIZ UDPGothic", Meiryo, system-ui, sans-serif; }
.wrap { max-width: 860px; margin: 0 auto; padding: 0 max(16px, env(safe-area-inset-left)) 0 max(16px, env(safe-area-inset-right)); }
main.wrap { padding-bottom: calc(96px + env(safe-area-inset-bottom)); }
h1 { font-size: 20px; margin: 16px 0 8px; }
h2 { font-size: 17px; margin: 22px 0 8px; }
h3 { font-size: 15px; margin: 14px 0 6px; }
a { color: var(--accent); }
.muted { color: var(--muted); } .small { font-size: 14px; }
.red { color: var(--red); } .amber { color: var(--amber); } .blue { color: var(--blue); }
[hidden] { display: none !important; }

/* header / nav */
.top { background: var(--paper); border-bottom: 1px solid var(--line); padding-top: env(safe-area-inset-top); position: sticky; top: 0; z-index: 5; }
.top .wrap { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; min-height: 48px; }
.logo { color: var(--accent); font-size: 16px; }
.who { margin-left: auto; font-size: 13px; color: var(--muted); }
.demo { background: var(--amber-bg); color: var(--amber); padding: 2px 8px; border-radius: 999px; font-weight: 700; }
.nav { position: fixed; left: 0; right: 0; bottom: 0; z-index: 6; display: grid; grid-template-columns: repeat(6, 1fr); background: var(--paper); border-top: 1px solid var(--line); padding-bottom: env(safe-area-inset-bottom); }
.nav a { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 8px 2px; font-size: 12px; color: var(--muted); text-decoration: none; min-height: 56px; }
.nav a span { font-size: 20px; line-height: 1; }
.nav a.on { color: var(--accent); font-weight: 700; box-shadow: inset 0 3px 0 var(--accent); }

/* controls */
button, .btn { font: inherit; font-size: 15px; border: 1px solid var(--line); background: var(--paper); color: var(--ink); border-radius: 10px; padding: 8px 12px; min-height: 44px; cursor: pointer; text-decoration: none; display: inline-flex; align-items: center; justify-content: center; gap: 4px; }
button:disabled { opacity: .45; cursor: not-allowed; }
button.primary { background: var(--accent); border-color: var(--accent); color: #fff; font-weight: 700; }
button.danger { color: var(--red); }
button.small, .small button { min-height: 34px; padding: 4px 10px; font-size: 14px; }
button.icon, .btn.icon { min-width: 44px; padding: 6px; }
button.wide { width: 100%; margin-top: 8px; }
button.x { border: none; background: none; color: var(--muted); min-height: 32px; min-width: 32px; padding: 0; }
input, select, textarea { font: inherit; font-size: 16px; color: var(--ink); background: var(--paper); border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; min-height: 44px; min-width: 0; max-width: 100%; }
textarea { width: 100%; }
:focus-visible { outline: 3px solid #5aa88f; outline-offset: 1px; }
fieldset { border: 0; padding: 0; margin: 0; min-width: 0; }
fieldset:disabled { opacity: .85; }
.btnrow { display: flex; flex-wrap: wrap; gap: 8px; margin: 8px 0; align-items: center; }
.card { background: var(--paper); border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px; margin: 12px 0; }
.note { background: var(--paper); border-left: 4px solid var(--accent); padding: 8px 12px; border-radius: 6px; font-size: 14px; }
.note.amber { border-color: var(--amber); background: var(--amber-bg); }
.note.red { border-color: var(--red); background: var(--red-bg); }
.toast { position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(76px + env(safe-area-inset-bottom)); background: var(--ink); color: #fff; padding: 10px 16px; border-radius: 10px; z-index: 20; max-width: calc(100% - 32px); font-size: 15px; }

/* date bar */
.datebar { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; padding: 12px 0 4px; }
.datebar input { font-weight: 700; }
.big { font-size: 20px; font-weight: 800; }
.status { font-size: 13px; color: var(--muted); width: 100%; }

/* 確定 */
.conf { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; border: 2px solid var(--line); border-radius: 14px; padding: 10px 12px; margin: 8px 0; background: var(--paper); }
.conf span { flex: 1; min-width: 12em; font-size: 14px; color: var(--muted); }
.conf.ok { border-color: var(--ok); background: var(--ok-bg); } .conf.ok b { color: var(--ok); }
.conf.draft { border-color: #d9b44a; background: var(--amber-bg); }

/* チェック結果 */
.issues { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.issues li { padding: 8px 12px; border-radius: 8px; font-size: 15px; }
.issues li.error { background: var(--red-bg); color: var(--red); font-weight: 700; border-left: 5px solid var(--red); }
.issues li.warn { background: var(--amber-bg); color: var(--amber); border-left: 5px solid #d9b44a; }
.issues.in { margin-top: 10px; }
.issues-box h2 { margin-top: 14px; }
.okmsg { color: var(--ok); font-weight: 700; margin: 10px 0; }

/* 出勤 */
details > summary { cursor: pointer; font-size: 16px; padding: 4px 0; }
.alist { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 4px; }
.arow { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; padding: 4px 0; border-bottom: 1px solid #eef1ec; }
.arow > label:first-child { min-width: 7em; font-size: 17px; display: flex; align-items: center; gap: 8px; min-height: 40px; }
.arow:not(.on) > label:first-child { color: var(--muted); }
.arow input[type=checkbox] { width: 22px; height: 22px; }
.mini { font-size: 14px; display: inline-flex; align-items: center; gap: 4px; }
.mini.blue { color: var(--blue); }

/* 行き先の色 */
.s-tsumugi { background: var(--tsumugi) !important; }
.s-yatei { background: var(--yatei) !important; }
.s-oda { background: var(--oda) !important; }
.s-zaitaku { background: var(--zaitaku) !important; }
.s-other { background: var(--other) !important; }
.tag { display: inline-block; padding: 2px 10px; border-radius: 6px; font-size: 14px; font-weight: 700; }
.tag.none { background: #eee; color: var(--muted); }

/* 車 */
.car { background: var(--paper); border: 2px solid var(--line); border-radius: 14px; padding: 12px; margin: 10px 0; }
.car.has-error { border-color: var(--red); }
.carhead { display: flex; align-items: baseline; gap: 10px; font-size: 18px; }
.cap { font-size: 14px; color: var(--muted); } .cap.bad { color: var(--red); font-weight: 700; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 8px 0; }
.grid2 label { display: flex; flex-direction: column; font-size: 13px; color: var(--muted); gap: 2px; }
.grid2 select { width: 100%; }
select.drv { font-weight: 700; border: 2px solid var(--ink); }
.co { font-size: 14px; display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin: 4px 0 8px; }
.co select { min-height: 36px; font-size: 14px; padding: 4px 8px; }
.chip { display: inline-flex; align-items: center; gap: 2px; padding: 2px 4px 2px 10px; background: #eef1ec; border-radius: 999px; }
.stops { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; border-top: 3px solid var(--ink); padding-top: 8px; }
.stop { display: grid; grid-template-columns: minmax(0, 1fr) 88px auto; grid-template-areas: "nm time ops" "place place place"; gap: 4px 6px; align-items: center; }
.stop .nm { grid-area: nm; } .stop .time { grid-area: time; } .stop .ops { grid-area: ops; display: flex; }
.stop input { grid-area: place; font-size: 14px; min-height: 36px; padding: 4px 8px; }
.nm { display: flex; flex-direction: column; border-radius: 8px; padding: 6px 10px; font-size: 18px; font-weight: 700; background: #f1f1f1; line-height: 1.25; min-width: 0; overflow-wrap: anywhere; }
.nm small { font-size: 12px; font-weight: 400; color: var(--muted); }
.nm.staff { border: 2px solid var(--ink); }
.nm.busy { background: var(--blue-bg); color: var(--blue); border-left: 6px solid var(--blue); }
.nm.off { text-decoration: line-through; color: var(--muted); }
.time { font-weight: 700; font-variant-numeric: tabular-nums; }
@media (min-width: 640px) {
  .stop { grid-template-columns: minmax(0, 1fr) 96px minmax(0, 1fr) auto; grid-template-areas: "nm time place ops"; }
}

/* 自走・在宅 */
.plist { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.plist li { display: flex; align-items: center; gap: 8px; }
.plist .nm { flex: 1; }
.plist select { max-width: 50%; }
.count { font-size: 14px; color: var(--red); }

/* 食事 */
.meals ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.meals li { display: grid; grid-template-columns: 7em 3em 1fr; align-items: center; gap: 8px; }
.meals b { font-size: 22px; text-align: right; font-variant-numeric: tabular-nums; }
.meals small { color: var(--muted); font-size: 13px; }
.meals .total { border-top: 1px dashed var(--line); padding-top: 6px; }

/* 乗車記録 */
.carpick { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; }
.carpick button { flex-direction: column; font-weight: 700; min-height: 60px; }
.carpick small { font-weight: 400; font-size: 13px; }
.stopnote { background: var(--amber-bg); color: var(--amber); font-weight: 700; padding: 10px 12px; border-radius: 10px; margin: 0 0 8px; }
.seats { font-size: 16px; } .seats b { font-size: 22px; }
.rides { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.rbtn { width: 100%; min-height: 68px; flex-direction: column; align-items: flex-start; border: 2px solid var(--ink); border-radius: 12px; text-align: left; }
.rname { font-size: 22px; font-weight: 800; }
.rmeta { font-size: 14px; color: var(--muted); }
.ride.done { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; background: var(--ok-bg); border-radius: 12px; padding: 10px 12px; }
.ride.done .rname { color: var(--ok); font-size: 18px; }
.ride.done button { margin-left: auto; }
.ride.other { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; background: #eee; border-radius: 12px; padding: 10px 12px; color: var(--muted); }
.ride.other .rname { font-size: 18px; }

/* 月の集計 */
.tiles { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; margin: 10px 0; }
@media (min-width: 640px) { .tiles { grid-template-columns: repeat(4, 1fr); } }
.tile { background: var(--paper); border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; }
.tile small { display: block; color: var(--muted); font-size: 13px; }
.tile b { font-size: 28px; font-variant-numeric: tabular-nums; }
.tblwrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
table { border-collapse: collapse; font-size: 13px; background: var(--paper); }
th, td { border: 1px solid var(--line); padding: 4px 6px; text-align: center; white-space: nowrap; }
.matrix tbody th, .list td:nth-child(3) { text-align: left; position: sticky; left: 0; background: var(--paper); }
th.we { color: var(--red); }
tr.void td { text-decoration: line-through; color: var(--muted); }

/* 名簿 */
.tabs { display: flex; gap: 4px; overflow-x: auto; margin-bottom: 10px; }
.tabs a { white-space: nowrap; padding: 8px 12px; border-radius: 999px; text-decoration: none; color: var(--ink); background: var(--paper); border: 1px solid var(--line); font-size: 14px; }
.tabs a.on { background: var(--accent); color: #fff; border-color: var(--accent); }
.rows { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.rowbtn { width: 100%; flex-direction: column; align-items: flex-start; text-align: left; }
.rowbtn small { color: var(--muted); font-size: 13px; }
.rowbtn.inactive { opacity: .5; }
.inv { display: flex; align-items: center; gap: 8px; background: var(--paper); border: 1px solid var(--line); border-radius: 10px; padding: 8px 12px; }
.inv span { flex: 1; display: flex; flex-direction: column; overflow-wrap: anywhere; } .inv small { color: var(--muted); font-size: 12px; }
form.edit { border: 2px solid var(--accent); }
.f { display: flex; flex-direction: column; gap: 2px; margin-bottom: 10px; }
.f label { font-size: 14px; font-weight: 700; }
.f input:not([type=checkbox]), .f select, .f textarea { width: 100%; }
.check { display: flex !important; align-items: center; gap: 8px; font-weight: 400 !important; min-height: 36px; }
.check input { width: 20px; height: 20px; }
.checks { border: 1px solid var(--line); border-radius: 8px; padding: 6px 10px; }
.checks legend { font-size: 14px; font-weight: 700; }
.login { margin-top: 24px; }
.login input { width: 100%; margin-bottom: 12px; }
.login label { display: block; font-weight: 700; font-size: 14px; margin-top: 4px; }

/* LINE用の画像（画面の外で組み立てて、絵にする） */
.li-wrap { position: fixed; left: -12000px; top: 0; width: 1040px; }
.li-sheet { width: 1040px; background: #bfc3be; padding: 10px 12px 14px; font-family: "Hiragino Sans", "Noto Sans JP", sans-serif; color: #2b2b2b; }
.li-top { display: flex; align-items: center; padding: 2px 4px 10px; }
.li-legend { font-size: 16px; display: flex; align-items: center; gap: 6px; }
.li-legend i { display: inline-block; width: 22px; height: 16px; border-radius: 3px; margin-left: 10px; }
.li-date { margin-left: auto; font-size: 20px; font-weight: 800; }
.li-body { background: #fdfdfb; border-radius: 6px; display: grid; grid-template-columns: repeat(var(--n), minmax(0, 1fr)) minmax(0, 1.05fr); padding: 14px 0 16px; min-height: 420px; }
.li-car, .li-side { padding: 0 12px; display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.li-car { border-right: 3px solid #b8363b; }
.li-carno { text-align: center; font-weight: 800; font-size: 19px; }
.li-drv { border: 2px solid #2b2b2b; border-radius: 4px; padding: 6px 10px; font-size: 19px; font-weight: 700; background: #f1f1f1; }
.li-drv.s-busy { background: #d6e6fb; border-color: #3f7fd6; color: #16438a; }
.li-veh { font-size: 13px; color: #6b6b6b; border-bottom: 3px solid #2b2b2b; padding-bottom: 6px; }
.li-head { display: grid; grid-template-columns: minmax(0, 1fr) 52px; background: #efd660; font-size: 13px; font-weight: 700; padding: 3px 8px; }
.li-row { display: grid; grid-template-columns: minmax(0, 1fr) 52px; gap: 4px; align-items: center; }
.li-nm { display: block; border-radius: 4px; padding: 7px 9px; font-size: 19px; background: #f1f1f1; line-height: 1.25; overflow-wrap: anywhere; }
.li-nm small { display: block; font-size: 12px; color: #555; }
.li-t { font-size: 18px; font-weight: 700; font-variant-numeric: tabular-nums; border-bottom: 1px solid #d6d6d6; padding: 6px 2px; }
.li-shead { background: #efd660; font-size: 13px; font-weight: 700; padding: 4px 8px; margin-top: 8px; }
.li-shead:first-child { margin-top: 0; }
.li-blue { background: #3f7fd6; color: #fff; }
.li-staff { border: 2px solid #2b2b2b; }
.li-busy { background: #d6e6fb; color: #16438a; border-left: 6px solid #3f7fd6; font-weight: 700; }
.li-memo { font-size: 16px; white-space: pre-wrap; padding: 4px 2px; }
.li-meals { border-top: 3px solid #b8363b; margin-top: 12px; padding-top: 8px; display: flex; flex-direction: column; gap: 6px; }
.li-meal { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; font-size: 16px; }
.li-meal span { border-radius: 4px; padding: 5px 8px; }
.li-meal b { font-size: 21px; padding-left: 10px; }
.li-sheet .s-zaitaku { background: #e6defa !important; }

/* 画像を見せる画面 */
.shot { position: fixed; inset: 0; z-index: 30; background: rgba(0,0,0,.65); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; padding: max(16px, env(safe-area-inset-top)) 16px max(16px, env(safe-area-inset-bottom)); }
.shot img { max-width: 100%; max-height: 70vh; border-radius: 8px; background: #fff; }
.shot p { color: #fff; margin: 0; text-align: center; }

/* 365の出勤表との連動 */
.att { border-width: 2px; }
.att.changed { border-color: #d9b44a; background: var(--amber-bg); }
.att.ok { border-color: var(--ok); }
.att-head { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; }
.att-head button { margin-left: auto; }
.att-title { font-weight: 800; color: var(--amber); font-size: 17px; margin: 8px 0 4px; }
.att-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.att-list li { display: flex; align-items: center; gap: 8px; background: var(--paper); border-radius: 10px; padding: 8px 10px; }
.att-list li span { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.att-list small { color: var(--muted); font-size: 13px; }
.att .okmsg { margin: 6px 0 0; }

/* 休けい表 */
.bt-wrap { overflow-x: auto; }
.bt { width: 100%; border-collapse: collapse; background: var(--paper); font-size: 16px; }
.bt th, .bt td { border: 1px solid #c9cfc9; padding: 6px 8px; text-align: left; white-space: normal; vertical-align: middle; }
.bt th { width: 7.5em; white-space: nowrap; font-variant-numeric: tabular-nums; background: #f6f7f4; }
.bt td { display: table-cell; }
.bt tr.bt-blue th, .bt tr.bt-blue td { background: #d8e6fa; }
.bt tr.bt-marche th, .bt tr.bt-marche td { background: #fff3cd; }
.bt-nm { display: inline-block; margin: 2px 4px 2px 0; padding: 3px 8px; border-radius: 6px; background: rgba(255,255,255,.7); border: 2px solid transparent; font-weight: 700; }
.bt-nm.bt-staff { border-color: #1f2a24; }
.bt-people li { gap: 8px; }
.bt-people select { max-width: 50%; }
.bt-edit { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; padding: 8px 0; border-bottom: 1px solid #eef1ec; }
.bt-edit .nm { min-width: 6em; font-size: 16px; }
.bt-slot { display: inline-flex; align-items: center; gap: 2px; padding: 2px 4px; border-radius: 8px; background: #eef1ec; }
.bt-slot.blue { background: #d8e6fa; }
.bt-slot select { min-height: 36px; font-size: 15px; padding: 2px 6px; }
.bt-sheet { width: 760px; }
.bt-paper { background: #fdfdfb; border-radius: 6px; padding: 12px; }
.bt-sheet .bt { font-size: 19px; }
.bt-sheet .bt th { width: 8em; }
.bt-sheet .li-legend b { font-size: 21px; }

/* 作業できる表 */
.chips-row { display: flex; flex-wrap: wrap; gap: 6px; margin: 6px 0 10px; }
.sk-wrap { max-height: 70vh; overflow: auto; border: 1px solid var(--line); border-radius: 10px; background: var(--paper); }
.sk { border-collapse: separate; border-spacing: 0; font-size: 14px; }
.sk th, .sk td { border: 0; border-right: 1px solid #e3e7e2; border-bottom: 1px solid #e3e7e2; padding: 0; }
.sk thead th { position: sticky; top: 0; z-index: 2; background: #f6f7f4; padding: 6px 4px; font-size: 13px; writing-mode: vertical-rl; text-orientation: upright; height: 5.5em; }
.sk thead th.sk-task { writing-mode: horizontal-tb; z-index: 3; left: 0; }
.sk tbody th.sk-task { position: sticky; left: 0; z-index: 1; background: var(--paper); text-align: left; min-width: 9em; max-width: 11em; }
.sk tbody th.sk-task.all { background: #e3f3e6; }
.sk tbody th.sk-task.few { background: #fde4e1; }
.sk-name { all: unset; cursor: pointer; display: block; padding: 6px 8px; font-weight: 700; font-size: 14px; line-height: 1.3; }
.sk-tag { display: inline-block; font-style: normal; font-size: 10px; font-weight: 700; background: #fde4e1; color: #b42318; border-radius: 4px; padding: 0 4px; margin-left: 4px; }
.sk-tag.blue { background: #d8e6fa; color: #1d63c9; }
.sk-cell { all: unset; cursor: pointer; display: flex; align-items: center; justify-content: center; width: 40px; height: 40px; font-size: 20px; font-weight: 800; }
.sk-cell.m-o { color: #1a7f37; } .sk-cell.m-t { color: #b07800; background: #fff6d6; } .sk-cell.m-x { color: #b42318; background: #fde4e1; }
.sk-cell:focus-visible { outline: 3px solid #5aa88f; outline-offset: -3px; }
.sk-legend { padding: 1px 6px; border-radius: 4px; } .sk-legend.all { background: #e3f3e6; } .sk-legend.few { background: #fde4e1; }

/* 配置 */
.nav a { font-size: 11px; padding: 8px 0; }
.pl-board { display: flex; flex-direction: column; gap: 10px; }
.pl-site { background: var(--paper); border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; }
.pl-site h3 { margin: 0 0 6px; display: flex; align-items: baseline; gap: 8px; } .pl-site h3 small { color: var(--muted); font-weight: 400; }
.pl-row { display: grid; grid-template-columns: 8.5em minmax(0, 1fr); gap: 6px; align-items: center; padding: 4px 0; border-top: 1px solid #eef1ec; }
.pl-task { font-weight: 700; font-size: 14px; }
.pl-nm { display: inline-flex; align-items: center; gap: 2px; margin: 2px 4px 2px 0; padding: 3px 8px; border-radius: 6px; background: #eef1ec; border: 2px solid transparent; font-weight: 700; }
.pl-nm.pl-staff { border-color: #1f2a24; background: #fff; }
.pl-nm.m-t { background: #fff6d6; } .pl-nm.m-x { background: #fde4e1; color: #b42318; }
.pl-nm b { font-size: 13px; }
.pl-edit { flex-wrap: wrap; }
.pl-edit .nm { flex: 1 1 6em; }
.pl-edit select { flex: 1 1 8em; max-width: none !important; }
.pl-sheet { width: 900px; }
.pl-paper { background: #fdfdfb; border-radius: 6px; padding: 12px; display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.pl-sheet .pl-site { border-color: #c9cfc9; }
.pl-sheet .pl-nm { font-size: 18px; }
.pl-sheet .pl-site h3 { font-size: 21px; }
.pl-sheet .pl-task { font-size: 17px; }
.pl-sheet .pl-row { grid-template-columns: 9.5em minmax(0, 1fr); }

/* 使い方 */
.helplink { font-size: 13px; font-weight: 700; text-decoration: none; padding: 4px 10px; border-radius: 999px; background: #eef1ec; }
.help-lead { font-size: 15px; }
.help-h { margin-top: 26px; padding-bottom: 4px; border-bottom: 2px solid var(--accent); color: var(--accent); }
.help-step h2 { margin: 0 0 6px; display: flex; align-items: center; gap: 8px; font-size: 17px; }
.help-step p { margin: 6px 0; }
.help-n { display: inline-flex; align-items: center; justify-content: center; width: 28px; height: 28px; border-radius: 50%; background: var(--accent); color: #fff; font-size: 15px; flex: none; }
.help-red { color: var(--red); font-weight: 700; } .help-amber { color: var(--amber); font-weight: 700; }
.bt-legend { display: flex; flex-wrap: wrap; gap: 4px 14px; margin: 4px 0 8px; font-weight: 700; font-size: 15px; }
.bt-legend i { display: inline-block; width: 22px; height: 16px; border-radius: 3px; margin-right: 6px; vertical-align: -2px; }
.bt-10 { display: inline-block; background: #1f4f9a; color: #fff; font-size: 12px; font-weight: 700; border-radius: 4px; padding: 6px 6px; margin: 2px 6px 2px 0; vertical-align: middle; }
.bt tr.bt-blue th, .bt tr.bt-blue td { background: #e7eef9; }
.bt-sheet .bt-legend { font-size: 18px; }

/* 横に動かないように（iPhone で長い名前の選択ボックスが画面をおし広げないように） */
html, body { max-width: 100%; overflow-x: hidden; }
body { overscroll-behavior-x: none; }
#view, .top .wrap { overflow-wrap: anywhere; }
select, input, textarea { max-width: 100%; min-width: 0; }
select { text-overflow: ellipsis; }
.grid2 { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.grid2 label, .stop > *, .plist li > *, .pl-edit > *, .arow > *, .co > * { min-width: 0; }
.who { min-width: 0; overflow-wrap: anywhere; }

/* iPhone は 16px より小さい入力欄を押すと自動で拡大して、戻らない。全部 16px にする */
input, select, textarea, .co select, .stop input, .bt-slot select { font-size: 16px !important; }

/* 名前を押すと出るメニュー */
button.nmbtn { border: 0; text-align: left; justify-content: flex-start; align-items: flex-start; flex-direction: column; min-height: 0; color: var(--ink); cursor: pointer; font: inherit; font-size: 18px; font-weight: 700; padding: 6px 10px; border-radius: 8px; }
button.nmbtn.open { outline: 3px solid var(--accent); outline-offset: 1px; }
.stop-menu { list-style: none; }
.plist li { flex-wrap: wrap; }
.nm-menu { width: 100%; background: var(--paper); border: 2px solid var(--accent); border-radius: 12px; padding: 8px 10px; display: flex; flex-direction: column; gap: 8px; }
.nm-menu-row { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.nm-menu-row > span { width: 3.5em; font-size: 13px; font-weight: 700; color: var(--muted); }
.nm-menu-row button.on { outline: 3px solid var(--ink); font-weight: 800; }
.nm-menu .ghost { align-self: flex-end; }

/* AIにまかせる */
.ai { border: 2px solid #9db8e8; background: #f3f7ff; }
.ai-head { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; justify-content: space-between; }
.ai-note { margin-top: 8px; padding: 8px 10px; background: #fff; border-radius: 8px; border: 1px solid #c9d8f2; }
.ai-note p { margin: 4px 0 0; }
.ai-ask { margin-top: 10px; display: grid; gap: 6px; }
.ai-ask textarea { width: 100%; box-sizing: border-box; }
.ai-ask button { justify-self: start; }

/* 1枚の表（送迎ボード） */
.sv { margin-bottom: 12px; }
.sv-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(165px, 1fr)); gap: 8px; margin-bottom: 8px; }
.sv-car { background: #fdfdfb; border: 2px solid #c9ccc7; border-radius: 10px; padding: 6px; display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.sv-car.bad { border-color: #b8363b; box-shadow: 0 0 0 2px #f6d5d6 inset; }
.sv-head { display: grid; grid-template-columns: auto 1fr; gap: 0 6px; align-items: baseline; text-align: left; background: #f1f1f1; border: 2px solid #2b2b2b; border-radius: 6px; padding: 5px 8px; color: var(--ink); font: inherit; cursor: pointer; min-height: 0; }
.sv-head.open { outline: 3px solid var(--accent); }
.sv-no { font-weight: 800; font-size: 14px; }
.sv-drv { font-weight: 800; font-size: 17px; }
.sv-drv em { color: #b8363b; font-style: normal; }
.sv-head small { grid-column: 1 / -1; font-size: 12px; color: #666; }
.sv-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px; align-items: center; }
.sv-nm { display: block; width: 100%; text-align: left; border: 0; border-radius: 6px; padding: 6px 8px; font: inherit; font-size: 16px; font-weight: 700; line-height: 1.2; color: var(--ink); background: #f1f1f1; cursor: pointer; min-height: 0; overflow-wrap: anywhere; }
.sv-nm small { display: block; font-size: 11px; font-weight: 400; color: #555; }
.sv-nm.open { outline: 3px solid var(--accent); }
.sv-side .sv-nm { margin-bottom: 2px; }
select.sv-t { width: 4.6em; padding: 4px 2px; font-variant-numeric: tabular-nums; }
select.sv-add { width: 100%; margin-top: 2px; }
.sv-sh { background: #efd660; font-size: 12px; font-weight: 700; padding: 3px 6px; border-radius: 4px; margin-top: 4px; }
.sv-sh.red { background: #b8363b; color: #fff; }
.sv-staff { font-size: 13px; margin: 2px 0; }
.sv-menu { background: var(--paper); border: 2px solid var(--accent); border-radius: 10px; padding: 6px; display: flex; flex-direction: column; gap: 6px; }
.sv-menu label { display: grid; gap: 2px; font-size: 12px; font-weight: 700; }
.sv-menu .nm-menu { border: 0; padding: 0; }
.sv-car.editing { grid-column: 1 / -1; }
select.sv-route { background: #fff8d6; }
.ai-rules { margin-top: 10px; border-top: 1px dashed #9db8e8; padding-top: 8px; }
.ai-rules summary { cursor: pointer; }
.ai-rule-list { list-style: none; padding: 0; margin: 6px 0; display: grid; gap: 4px; }
.ai-rule-list li { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 6px; align-items: center; background: #fff; border: 1px solid #c9d8f2; border-radius: 8px; padding: 5px 8px; }
.ai-rule-add { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 6px; }
.ai-mic { font-size: 18px; font-weight: 800; padding: 14px; border-radius: 14px; background: #1f5c4a; color: #fff; border: 0; }
.ai-mic.on { background: #b8363b; animation: micpulse 1.2s infinite; }
@keyframes micpulse { 50% { opacity: .75; } }
.ai-note { position: relative; }
.ai-say { float: right; margin-left: 6px; }
.ai-voice { margin-top: 8px; font-size: 13px; } .ai-voice select { width: 100%; margin-top: 2px; }
