/* 記帳ポスト — 業務ソフトらしい落ち着いた見た目（白・グレー・青1色／線で区切る／角は小さめ） */
:root{
  --bg:#f3f4f6; --surface:#fff; --line:#e3e6ea; --line2:#cdd2d8;
  --text:#1f2329; --sub:#5c6570; --muted:#8b939c;
  --primary:#2158c6; --primary-h:#1a4aa9; --primary-l:#e9f0fc; --primary-ll:#f4f7fd;
  --ok:#1d7a4c; --ok-l:#e7f3ec; --warn:#9f5110; --warn-l:#fcf2e6; --warn-line:#f0d9bd; --danger:#c0392b; --danger-l:#fbeceb;
  --gray-l:#eff1f3;
  --r-lg:8px; --r:6px; --r-sm:4px;
  --top-h:52px;
  --ring:0 0 0 3px rgba(33,88,198,.22);
  --num:-apple-system,BlinkMacSystemFont,"SF Pro Text","Segoe UI","Helvetica Neue",Arial,"Hiragino Sans",sans-serif;
}
*{box-sizing:border-box}
html{-webkit-text-size-adjust:100%}
p,small,.fine,.empty span,.drop span{text-wrap:pretty}
body{margin:0;background:var(--bg);color:var(--text);font-family:"Hiragino Sans","Hiragino Kaku Gothic ProN",-apple-system,BlinkMacSystemFont,"Noto Sans JP","Yu Gothic UI",Meiryo,sans-serif;
  font-size:15px;line-height:1.6;-webkit-font-smoothing:antialiased}
button,input,select,textarea{font:inherit;color:inherit}
button{cursor:pointer;-webkit-tap-highlight-color:transparent}
a{color:var(--primary)}
.hidden{display:none!important}
.ic{width:20px;height:20px;flex:none}
:focus{outline:none}
:focus-visible{box-shadow:var(--ring)}
.sub{color:var(--sub)}
.center{text-align:center}
.mt{margin-top:12px}
.amt{font-family:var(--num);font-variant-numeric:tabular-nums;font-weight:600;white-space:nowrap;letter-spacing:.01em}
.amt.in{color:var(--ok)}
.boot{min-height:100dvh;display:flex;align-items:center;justify-content:center;gap:10px;color:var(--sub);font-size:14px}
.spin{display:inline-block;width:14px;height:14px;border:2px solid currentColor;border-right-color:transparent;border-radius:50%;animation:spin .8s linear infinite;flex:none;opacity:.75}
@keyframes spin{to{transform:rotate(360deg)}}
@media (prefers-reduced-motion:reduce){.spin{animation-duration:2.4s}}

/* ヘッダー */
.top{position:sticky;top:0;z-index:30;background:var(--surface);border-bottom:1px solid var(--line);padding-top:env(safe-area-inset-top)}
.top .bar{height:var(--top-h);max-width:1240px;margin:0 auto;padding:0 16px;display:flex;align-items:center;gap:12px}
.top .logo{display:flex;align-items:center;gap:9px;font-weight:700;font-size:16px;letter-spacing:.03em;white-space:nowrap}
.top .logo img{width:26px;height:26px;border-radius:6px}
.top .who{margin-left:auto;font-size:13px;color:var(--sub);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;min-width:0}
.tag{display:inline-flex;align-items:center;gap:3px;font-size:10.5px;font-weight:600;color:var(--sub);border:1px solid var(--line2);border-radius:3px;padding:0 5px;line-height:17px;letter-spacing:.04em;white-space:nowrap;background:var(--surface)}
.tag .ic{width:11px;height:11px}

/* 本文 */
main{max-width:720px;margin:0 auto;padding:4px 16px calc(92px + env(safe-area-inset-bottom))}
main.wide{max-width:1240px;padding-bottom:48px}
.sec{font-size:13px;font-weight:600;color:var(--sub);margin:26px 2px 8px;display:flex;align-items:center;gap:8px}
.sec .count{font-family:var(--num);font-size:12px;color:var(--warn);background:var(--warn-l);border-radius:3px;padding:0 6px;line-height:18px}
.page-title{font-size:19px;font-weight:700;margin:20px 2px 14px;letter-spacing:.02em;display:flex;align-items:center;gap:10px}
.page-title .count{font-family:var(--num);font-size:12px;font-weight:600;color:var(--warn);background:var(--warn-l);border-radius:3px;padding:0 7px;line-height:20px;letter-spacing:0}
.page-title + .sec{margin-top:0}
.page-title + .box,.page-title + .tx-group{margin-top:0}
.lead{margin:-6px 2px 14px;color:var(--sub);font-size:13.5px}
.fine{font-size:12.5px;color:var(--sub);line-height:1.75;margin:8px 0 0}
p.fine.center{margin:16px 8px 0}
.box{background:var(--surface);border:1px solid var(--line);border-radius:var(--r-lg)}
.pad{padding:16px}

/* ホーム：今月のまとめ */
.summary{margin-top:16px;padding:16px 18px 0;overflow:hidden}
.summary-head{display:flex;justify-content:space-between;align-items:center;gap:8px;font-size:13px;color:var(--sub)}
.summary-amt{font-size:32px;font-weight:700;line-height:1.25;margin:6px 0 2px;letter-spacing:-.005em}
.summary-note{font-size:12.5px;color:var(--muted);margin-bottom:14px}
.stats{display:grid;grid-template-columns:repeat(3,1fr);border-top:1px solid var(--line);margin:0 -18px}
.stat{display:flex;flex-direction:column;gap:2px;padding:11px 16px 13px;border:0;background:none;text-align:left;min-width:0}
.stat + .stat{border-left:1px solid var(--line)}
button.stat{transition:background-color .15s}
button.stat:hover{background:#fafbfc}
.stat .k{font-size:11.5px;color:var(--sub);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.stat .v{font-family:var(--num);font-size:21px;font-weight:700;line-height:1.3;font-variant-numeric:tabular-nums}
.stat .v small{font-family:inherit;font-size:12px;font-weight:500;color:var(--sub);margin-left:2px}
.stat .v.warn{color:var(--warn)}

/* やること・お知らせ */
.todo{display:flex;align-items:center;gap:12px;width:100%;margin-top:12px;padding:13px 14px 13px 16px;background:var(--warn-l);border:1px solid var(--warn-line);border-radius:var(--r-lg);text-align:left;color:var(--text);transition:filter .15s}
.todo:hover{filter:brightness(.985)}
.todo > .ic{color:var(--warn)}
.todo b{display:block;font-size:14.5px;font-weight:600}
.todo small{display:block;color:var(--sub);font-size:12.5px}
.chev{margin-left:auto;color:var(--muted);width:18px;height:18px}
.notice{display:flex;align-items:center;gap:10px;margin:12px 0 0;padding:11px 14px;background:var(--primary-ll);border:1px solid #d5e1f7;border-radius:var(--r-lg);color:var(--primary);font-size:13.5px}
.alert{display:flex;align-items:flex-start;gap:8px;margin:0 0 10px;padding:10px 14px;background:var(--danger-l);border:1px solid #f1cdc9;border-radius:var(--r-lg);color:var(--danger);font-size:13px}
.alert .ic{width:17px;height:17px;margin-top:2px}

/* メニュー行 */
.menu{overflow:hidden}
.menu-row{display:flex;align-items:center;gap:14px;width:100%;padding:13px 14px 13px 16px;background:none;border:0;text-align:left;transition:background-color .15s}
.menu-row + .menu-row{border-top:1px solid var(--line)}
.menu-row:hover{background:#fafbfc}
.menu-row:active{background:#f4f5f7}
.mi{width:38px;height:38px;border-radius:var(--r);background:var(--primary-l);color:var(--primary);display:flex;align-items:center;justify-content:center;flex:none}
.menu-row b{display:block;font-size:15px;font-weight:600}
.menu-row small{display:block;font-size:12.5px;color:var(--sub)}

/* ご利用の流れ */
.steps{list-style:none;margin:0;padding:2px 16px;counter-reset:s}
.steps li{display:flex;gap:12px;padding:12px 0;align-items:flex-start;counter-increment:s}
.steps li + li{border-top:1px solid var(--line)}
.steps li::before{content:counter(s);width:22px;height:22px;border-radius:50%;border:1.5px solid var(--primary);color:var(--primary);font-family:var(--num);font-size:12px;font-weight:700;display:flex;align-items:center;justify-content:center;flex:none;margin-top:1px}
.steps b{display:block;font-size:14px;font-weight:600}
.steps li span span{display:block;font-size:12.5px;color:var(--sub)}

/* ボタン */
.btn{display:inline-flex;align-items:center;justify-content:center;gap:6px;height:44px;padding:0 18px;border-radius:var(--r);border:1px solid transparent;font-size:15px;font-weight:600;white-space:nowrap;
  transition:background-color .15s,border-color .15s,box-shadow .15s,transform .06s;text-decoration:none;cursor:pointer;margin:0}
.btn:active{transform:translateY(1px)}
.btn .ic{width:17px;height:17px}
.btn.primary{background:var(--primary);color:#fff}
.btn.primary:hover{background:var(--primary-h)}
.btn.outline{background:var(--surface);border-color:var(--line2);color:var(--text)}
.btn.outline:hover{background:#f7f8fa;border-color:#b6bdc6}
.btn.sm{height:34px;padding:0 12px;font-size:13.5px}
.btn.xs{height:28px;padding:0 10px;font-size:12.5px;font-weight:600}
.btn.block{display:flex;width:100%}
.btn.mt{margin-top:10px}
.btn:disabled{opacity:.5;cursor:default;transform:none}

/* 入力欄（スマホは16px＝タップで画面が拡大されない大きさ） */
label{display:block;font-size:12.5px;color:var(--sub);font-weight:600;margin:12px 0 5px}
label.lbl0{margin-top:0}
input[type=text],input[type=date],input[type=number],input[type=month],select,textarea{width:100%;height:42px;border:1px solid var(--line2);border-radius:var(--r-sm);padding:0 11px;background:#fff;font-size:16px;transition:border-color .15s,box-shadow .15s}
select{appearance:none;-webkit-appearance:none;padding-right:32px;cursor:pointer;
  background:#fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%235c6570' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m7 10 5 5 5-5'/%3E%3C/svg%3E") no-repeat right 9px center/16px}
textarea{height:auto;min-height:84px;padding:10px 11px;line-height:1.6;resize:vertical}
input:focus,select:focus,textarea:focus{border-color:var(--primary);box-shadow:var(--ring)}
input::placeholder,textarea::placeholder{color:#a3aab2}
input[type=checkbox]{width:16px;height:16px;accent-color:var(--primary);margin:0;flex:none}
label.check{display:flex;align-items:center;gap:8px;font-weight:500;color:var(--text);font-size:13.5px;margin:12px 0;cursor:pointer}

/* 下のメニュー（スマホ） */
.tabs{position:fixed;left:0;right:0;bottom:0;z-index:30;background:rgba(255,255,255,.98);border-top:1px solid var(--line);display:grid;grid-template-columns:repeat(4,1fr);padding-bottom:env(safe-area-inset-bottom)}
.tabs button{position:relative;background:none;border:0;padding:8px 0 7px;display:flex;flex-direction:column;align-items:center;gap:3px;font-size:10.5px;font-weight:600;color:var(--muted);transition:color .15s}
.tabs .ic{width:23px;height:23px}
.tabs button.on{color:var(--primary)}
.badge{position:absolute;top:4px;left:calc(50% + 7px);min-width:17px;height:17px;padding:0 5px;border-radius:9px;background:var(--danger);color:#fff;font-family:var(--num);font-size:10.5px;font-weight:700;line-height:17px;text-align:center}

/* 送る */
.drop{display:flex;flex-direction:column;align-items:center;gap:4px;padding:28px 16px 26px;margin:0;background:var(--surface);border:1.5px dashed var(--line2);border-radius:var(--r-lg);text-align:center;cursor:pointer;
  color:var(--text);font-size:inherit;font-weight:400;transition:border-color .15s,background-color .15s}
.drop:hover{border-color:var(--primary);background:var(--primary-ll)}
.drop .di{width:52px;height:52px;border-radius:50%;background:var(--primary-l);color:var(--primary);display:flex;align-items:center;justify-content:center;margin-bottom:6px}
.drop .di .ic{width:26px;height:26px}
.drop b{font-size:15.5px;font-weight:600}
.drop > span:last-of-type{font-size:12.5px;color:var(--sub)}
.uplist{display:flex;flex-direction:column;margin-top:10px}
.uplist:empty{display:none}
.up{display:flex;justify-content:space-between;gap:12px;align-items:center;padding:10px 14px;background:var(--surface);border:1px solid var(--line);font-size:13px}
.up + .up{border-top:0}
.up:first-child{border-radius:var(--r) var(--r) 0 0}
.up:last-child{border-radius:0 0 var(--r) var(--r)}
.up:only-child{border-radius:var(--r)}
.up > span:first-child{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;min-width:0}
.up .ok{color:var(--ok);font-weight:600;white-space:nowrap}
.up .ng{color:var(--danger);font-weight:600}
.up .wip{display:inline-flex;align-items:center;gap:6px;color:var(--sub);white-space:nowrap}

/* サムネイル */
.thumb{width:44px;height:44px;border-radius:var(--r-sm);border:1px solid var(--line);background:var(--bg);flex:none;display:flex;align-items:center;justify-content:center;color:var(--sub);overflow:hidden}
.thumb img{width:100%;height:100%;object-fit:cover;display:block}
.thumb .ic{width:21px;height:21px}
.thumb.ng{color:var(--danger);background:var(--danger-l);border-color:#f1cdc9}

/* 質問 */
.qcard{margin-bottom:12px;overflow:hidden}
.q-doc{display:flex;align-items:center;gap:12px;padding:12px 16px;border-bottom:1px solid var(--line)}
.q-doc .thumb{width:52px;height:52px}
.q-meta{flex:1;min-width:0}
.q-meta b{display:block;font-weight:600;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.q-meta span{font-size:12.5px;color:var(--sub)}
.q-body{padding:14px 16px 16px}
.q-body + .q-body{border-top:1px dashed var(--line)}
.q-text{margin:0 0 10px;padding:9px 12px;border-left:3px solid var(--warn);background:var(--warn-l);border-radius:0 var(--r-sm) var(--r-sm) 0;font-size:14.5px;font-weight:600;line-height:1.65}
.q-actions{display:grid;grid-template-columns:1fr 1.35fr;gap:8px;margin-top:10px}

/* 送ったもの（日付ごと） */
.tx-group{margin-top:14px}
.tx-group:first-of-type{margin-top:0}
.tx-date{font-size:12.5px;font-weight:600;color:var(--sub);margin:0 2px 6px}
.tx-list{background:var(--surface);border:1px solid var(--line);border-radius:var(--r-lg);overflow:hidden}
.tx{display:flex;align-items:center;gap:12px;padding:11px 14px}
.tx + .tx{border-top:1px solid var(--line)}
.tx-mid{flex:1;min-width:0}
.tx-name{font-weight:600;font-size:14.5px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.tx-sub{font-size:12px;color:var(--sub);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.tx-right{display:flex;flex-direction:column;align-items:flex-end;gap:3px}

/* 状態のラベル */
.st{display:inline-block;font-size:11px;font-weight:600;line-height:19px;padding:0 7px;border-radius:3px;white-space:nowrap;background:var(--gray-l);color:#5f6670}
.st-question{background:var(--warn-l);color:var(--warn)}
.st-check{background:var(--primary-l);color:var(--primary)}
.st-approved{background:var(--ok-l);color:var(--ok)}
.flag{display:inline-flex;align-items:center;gap:3px;font-size:11.5px;font-weight:600;color:var(--warn);margin:3px 8px 0 0;white-space:nowrap}
.flag .ic{width:13px;height:13px}

/* 空のとき */
.empty{display:flex;flex-direction:column;align-items:center;gap:3px;padding:40px 16px;text-align:center;color:var(--sub)}
.empty .ei{width:44px;height:44px;border-radius:50%;background:var(--gray-l);display:flex;align-items:center;justify-content:center;margin-bottom:8px;color:var(--muted)}
.empty b{color:var(--text);font-weight:600;font-size:14.5px}
.empty span{font-size:12.5px}
.empty .btn{margin-top:14px}

/* 専用リンクなし */
.login{max-width:400px;margin:0 auto;padding:14vh 20px 40px}
.login .brand{text-align:center;margin-bottom:20px}
.login .brand img{width:52px;height:52px;border-radius:12px}
.login h1{font-size:20px;margin:12px 0 4px;letter-spacing:.03em;display:flex;align-items:center;justify-content:center;gap:8px}
.login .brand p{margin:0;color:var(--sub);font-size:13px}
.login .lg{margin:0;font-size:15px;font-weight:600;line-height:1.7}

/* スタッフ画面 */
.staff-head{display:flex;flex-wrap:wrap;gap:10px 12px;align-items:center;justify-content:space-between;padding:16px 0 12px}
.staff-head .l,.staff-head .r{display:flex;flex-wrap:wrap;gap:8px;align-items:center}
.staff-head select{width:auto;min-width:190px;height:34px;font-weight:600}
.staff-head input[type=month]{width:auto;height:34px}
.staff-head label.check{margin:0 4px}
.subtabs{display:flex;gap:2px;border-bottom:1px solid var(--line);margin-bottom:14px;overflow-x:auto;scrollbar-width:none}
.subtabs::-webkit-scrollbar{display:none}
.subtabs button{background:none;border:0;border-bottom:2px solid transparent;margin-bottom:-1px;padding:9px 12px 9px;font-size:14px;font-weight:600;color:var(--sub);white-space:nowrap;display:flex;gap:6px;align-items:center;transition:color .15s,border-color .15s}
.subtabs button:hover{color:var(--text)}
.subtabs button.on{color:var(--primary);border-bottom-color:var(--primary)}
.subtabs .n{font-family:var(--num);font-size:11.5px;min-width:20px;padding:0 6px;line-height:18px;border-radius:9px;background:var(--gray-l);color:var(--sub);text-align:center}
.subtabs button.on .n{background:var(--primary-l);color:var(--primary)}
.split{display:grid;grid-template-columns:minmax(0,1fr) 400px;gap:16px;align-items:start}
.tbl{background:var(--surface);border:1px solid var(--line);border-radius:var(--r-lg);overflow:hidden}
table.grid{width:100%;border-collapse:collapse;font-size:13.5px}
table.grid th{background:#f7f8fa;color:var(--sub);font-size:12px;font-weight:600;text-align:left;padding:8px 12px;border-bottom:1px solid var(--line);white-space:nowrap}
table.grid td{padding:10px 12px;border-bottom:1px solid var(--line);vertical-align:top}
table.grid tbody tr:last-child td{border-bottom:0}
table.grid tr[data-row]{cursor:pointer}
table.grid tr[data-row] td{transition:background-color .12s}
table.grid tr[data-row]:hover td{background:#f8f9fb}
table.grid tr.sel td,table.grid tr.sel:hover td{background:var(--primary-ll)}
table.grid tr.sel td:first-child{box-shadow:inset 3px 0 0 var(--primary)}
table.grid .num{text-align:right;white-space:nowrap;font-family:var(--num);font-variant-numeric:tabular-nums;font-weight:600}
table.grid .num.in{color:var(--ok)}
table.grid .date{white-space:nowrap;font-family:var(--num);color:var(--sub)}
table.grid .right{text-align:right}
table.grid.compact td{padding:7px 10px;vertical-align:middle}
table.grid.compact th{padding:6px 10px}
.payee{font-weight:600}
.payee,table.grid.compact td:first-child,.side-title,.doc-line span,.qa p,.hist li span{overflow-wrap:anywhere}
table.grid td.sub,table.grid td.acc{white-space:nowrap}
.sp-only{display:none}
.tbl-foot{display:flex;gap:18px;justify-content:flex-end;padding:9px 12px;border-top:1px solid var(--line);background:#fafbfc;font-size:12.5px;color:var(--sub)}
.tbl-foot b{color:var(--text);font-family:var(--num);font-variant-numeric:tabular-nums;margin-left:4px}

/* 右の確認欄 */
.side{position:sticky;top:calc(var(--top-h) + 16px);background:var(--surface);border:1px solid var(--line);border-radius:var(--r-lg);max-height:calc(100dvh - var(--top-h) - 32px);overflow:auto;padding:0 16px 16px}
.side > .empty{padding:56px 8px}
.side-head{display:flex;justify-content:space-between;align-items:flex-start;gap:10px;padding:14px 0 12px;border-bottom:1px solid var(--line);position:sticky;top:0;background:var(--surface);z-index:1}
.side-title{font-size:15.5px;font-weight:700;line-height:1.45}
.side-sub{font-size:12.5px;color:var(--sub);font-family:var(--num)}
.doc-img{display:block;margin-top:14px;border:1px solid var(--line);border-radius:var(--r);background:var(--bg);overflow:hidden}
.doc-img img{display:block;width:100%;max-height:300px;object-fit:contain}
.doc-line{display:flex;gap:10px;align-items:center;margin-top:14px;padding:10px 12px;background:var(--bg);border-radius:var(--r);font-size:13px;color:var(--sub)}
.doc-line .ic{width:18px;height:18px}
.blk{margin-top:18px}
.blk h3{font-size:12px;font-weight:700;color:var(--sub);margin:0 0 6px;letter-spacing:.04em}
.ai-box{padding:10px 12px;border:1px solid var(--line);border-radius:var(--r);background:#fafbfc}
.ai-box .fine{margin-top:4px}
.ai-line{display:flex;align-items:center;gap:8px;font-size:14px}
.conf{font-family:var(--num);font-size:11.5px;color:var(--sub);border:1px solid var(--line2);border-radius:3px;padding:0 5px;line-height:17px;background:#fff}
.qa{padding:8px 0}
.qa + .qa{border-top:1px solid var(--line)}
.qa .q{margin:0;font-size:12.5px;color:var(--sub)}
.qa .a{margin:2px 0 0;font-size:13.5px;font-weight:600}
.qa .a.wait{color:var(--warn)}
.fields{display:grid;grid-template-columns:1fr 1fr;gap:0 10px}
.fields .full{grid-column:1/-1}
.fields label{margin-top:10px}
.actions{display:grid;grid-template-columns:1.7fr 1fr;gap:8px;margin-top:16px}
.actions-sub{display:flex;flex-wrap:wrap;gap:6px;margin-top:8px}
.hist ul{list-style:none;margin:0;padding:0;font-size:12px;color:var(--sub)}
.hist li{display:flex;gap:10px;padding:5px 0;border-top:1px solid var(--line)}
.hist li:first-child{border-top:0}
.hist time{font-family:var(--num);white-space:nowrap;color:var(--muted)}

.toast{position:fixed;left:50%;bottom:calc(84px + env(safe-area-inset-bottom));transform:translateX(-50%);background:#24292f;color:#fff;padding:10px 16px;border-radius:var(--r);font-size:13.5px;z-index:50;max-width:calc(100vw - 32px);box-shadow:0 6px 20px rgba(20,30,45,.18)}

/* PC：メニューを上に・スタッフ画面は小さめの文字で密度を上げる */
@media (min-width:900px){
  .tabs{position:sticky;top:calc(var(--top-h) + 1px);bottom:auto;display:flex;justify-content:center;gap:6px;border-top:0;border-bottom:1px solid var(--line);padding:0;background:var(--surface);z-index:29}
  .tabs button{flex-direction:row;gap:7px;padding:12px 14px 11px;font-size:14px;border-bottom:2px solid transparent;margin-bottom:-1px;color:var(--sub)}
  .tabs button:hover{color:var(--text)}
  .tabs button.on{border-bottom-color:var(--primary);color:var(--primary)}
  .tabs .ic{width:18px;height:18px}
  .badge{position:static}
  main{padding-bottom:56px}
  main.client{padding-top:12px}
  .toast{bottom:28px}
  main.wide input[type=text],main.wide input[type=date],main.wide input[type=number],main.wide input[type=month],main.wide select,main.wide textarea{height:36px}
  main.wide textarea{height:auto;min-height:72px}
}
/* マウス操作のPCだけ文字を小さく（iPadは16pxのまま＝入力時に拡大されない） */
@media (min-width:900px) and (hover:hover) and (pointer:fine){
  main.wide input[type=text],main.wide input[type=date],main.wide input[type=number],main.wide input[type=month],main.wide select,main.wide textarea{font-size:14px}
}
@media (max-width:899px){
  .split{grid-template-columns:1fr}
  .side{position:static;max-height:none;scroll-margin-top:calc(var(--top-h) + 8px)}
  .side-head{position:static}
  .staff-head{padding-top:12px}
  .staff-head .l{width:100%}
  .staff-head select{flex:1 1 100%;min-width:0}
  .staff-head input[type=month]{flex:1;min-width:0}
  .staff-head .r{display:grid;grid-template-columns:repeat(3,1fr);width:100%;gap:6px}
  .staff-head .r .btn{padding:0 6px;font-size:13px}
  .staff-head .r .btn .ic{display:none}
  .side:has(> .empty){display:none}
}
@media (max-width:640px){
  .sp-hide{display:none}
  .sp-only{display:block;margin-top:4px}
  table.grid td,table.grid th{padding-left:10px;padding-right:10px}
  .tbl-foot{gap:12px}
}

/* ヘッダーの小ボタン・デモの案内帯 */
.top .who{display:flex;align-items:center;gap:8px}
.top .who .nm{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;min-width:0}
.hbtn{flex:none;height:28px;padding:0 10px;border:1px solid var(--line2);border-radius:var(--r-sm);background:var(--surface);font-size:12px;font-weight:600;color:var(--sub);transition:background-color .15s}
.hbtn:hover{background:#f6f7f9;color:var(--text)}
.demo-bar{background:#fff7e0;border-bottom:1px solid #f0dfa8;color:#7a5a00;font-size:12px;text-align:center;padding:6px 12px;line-height:1.5}
.linkbtn{background:none;border:0;color:var(--primary);font-size:13px;text-decoration:underline;cursor:pointer;padding:4px}
/* Googleでログイン */
.gbtn{background:#fff;border:1px solid var(--line2);color:var(--text);margin-top:14px;gap:10px}
.gbtn:hover{background:#f7f8fa}
.gbtn .g{width:20px;height:20px}
.login .box .alert{margin-bottom:14px}
/* デモの入口 */
.wide-login{max-width:640px}
.demo-pick{display:grid;grid-template-columns:1fr 1fr;gap:12px}
.pick{display:flex;flex-direction:column;align-items:flex-start;gap:6px;padding:18px;text-align:left;cursor:pointer;transition:border-color .15s,box-shadow .15s}
.pick:hover{border-color:var(--primary);box-shadow:0 0 0 3px rgba(33,88,198,.10)}
.pick b{font-size:16px;font-weight:700;margin-top:4px}
.pick span:last-child{font-size:12.5px;color:var(--sub);line-height:1.7}
.samples{display:grid;grid-template-columns:repeat(3,1fr);gap:10px}
.sample{display:flex;flex-direction:column;align-items:center;gap:8px;padding:12px 8px 14px;background:var(--surface);border:1px solid var(--line);border-radius:var(--r-lg);cursor:pointer;font-size:12.5px;font-weight:600;transition:border-color .15s}
.sample:hover{border-color:var(--primary)}
.sample img{width:100%;height:110px;object-fit:cover;object-position:top;border-radius:var(--r-sm);border:1px solid var(--line)}
@media (max-width:560px){.demo-pick{grid-template-columns:1fr}.hbtn{padding:0 8px}}
@media (max-width:420px){.top .who .nm{display:none}}
