/* 人事ポータルと同じ系統：淡いグリーン白、白いカード＋細い線、落ち着いたグリーンのアクセント */
:root{
  --bg:#f7f8f5;--surface:#fff;--soft:#f3f5f1;
  --text:#3e4943;--mute:#737c76;--mute2:#8c948e;
  --line:#e5e9e4;--line2:#d3ddcd;--ink:#26342e;
  --accent:#426653;--accent-soft:#e7eee5;
  --today:#fff6d6;--sat:#3e5170;--sun:#a8443c;
  --r:12px;
}
*{box-sizing:border-box;-webkit-tap-highlight-color:transparent}
html,body{margin:0}
body{font-family:"Noto Sans JP","Hiragino Kaku Gothic ProN","Yu Gothic UI",system-ui,sans-serif;font-feature-settings:"palt" 1;-webkit-font-smoothing:antialiased;
  background:var(--bg);color:var(--text);font-size:14px;line-height:1.6;-webkit-text-size-adjust:100%;padding-bottom:calc(68px + env(safe-area-inset-bottom))}
button,select{font:inherit;color:inherit}

/* ---- 上のバー ---- */
header{position:sticky;top:0;z-index:20;background:rgba(255,255,255,.96);backdrop-filter:blur(10px);-webkit-backdrop-filter:blur(10px);
  border-bottom:1px solid var(--line);padding:8px 14px;display:flex;align-items:center;gap:10px;min-height:56px}
.brand{flex:1;min-width:0;display:flex;align-items:baseline;gap:10px;white-space:nowrap}
.brand b{font-size:17px;font-weight:700;letter-spacing:.05em;color:var(--ink)}
.brand small{display:inline;color:var(--mute2);font-size:11px;font-weight:500;padding-left:10px;border-left:1px solid var(--line)}
.mon{display:flex;align-items:center;border:1px solid var(--line2);border-radius:8px;background:var(--surface);overflow:hidden}
.mon button{border:0;background:none;width:38px;height:38px;font-size:12px;color:var(--mute);cursor:pointer}
.mon button:active{background:var(--soft)}
.mon button:disabled{opacity:.25}
.mon select{appearance:none;-webkit-appearance:none;border:0;border-left:1px solid var(--line);border-right:1px solid var(--line);border-radius:0;background:none;font-weight:700;font-size:13px;text-align:center;text-align-last:center;height:38px;padding:0 8px;cursor:pointer;color:var(--ink)}

/* ---- 下のタブ ---- */
nav{position:fixed;left:0;right:0;bottom:0;z-index:30;background:rgba(255,255,255,.97);border-top:1px solid var(--line);padding-bottom:env(safe-area-inset-bottom)}
nav .in{display:flex;max-width:760px;margin:0 auto}
nav button{flex:1;position:relative;border:0;background:none;padding:0;min-height:56px;font-weight:600;font-size:13px;color:var(--mute);cursor:pointer}
nav button.on{color:var(--accent);background:var(--accent-soft);font-weight:700}
nav button.on::before{content:"";position:absolute;left:22%;right:22%;top:0;height:3px;border-radius:0 0 3px 3px;background:var(--accent)}

main{max-width:760px;margin:0 auto;padding:14px 12px 16px}
main.mid{max-width:1040px}
main.wide{max-width:none;padding:12px 8px}
.card{background:var(--surface);border:1px solid var(--line);border-radius:var(--r);box-shadow:0 1px 2px rgba(38,52,46,.03);padding:14px;margin-bottom:12px}
.card h2{font-size:12px;letter-spacing:.05em;color:var(--mute2);margin:0 0 8px;font-weight:700}
.msg{color:var(--mute);text-align:center;padding:40px 12px;line-height:1.9}

/* ---- 名前選び ---- */
.who{margin-bottom:12px}
.who select{width:100%;appearance:none;-webkit-appearance:none;border:1px solid var(--line2);background:var(--surface) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23426653' stroke-width='2' fill='none'/%3E%3C/svg%3E") no-repeat right 16px center;border-radius:var(--r);padding:0 40px 0 16px;height:52px;font-size:17px;font-weight:700;color:var(--ink)}

/* ---- 今日 ---- */
.hero{border-radius:var(--r);padding:18px 18px 16px;margin-bottom:12px;position:relative;overflow:hidden;border:1px solid rgba(0,0,0,.06)}
.hero .k{font-size:12px;font-weight:700;opacity:.85;letter-spacing:.05em}
.hero .big{font-size:34px;font-weight:700;line-height:1.2;margin:4px 0 0;letter-spacing:.02em}
.hero .sub{font-size:13px;opacity:.9;margin-top:2px}
.hero .num{position:absolute;right:12px;top:-6px;font-size:96px;font-weight:700;opacity:.13;line-height:1}
.hero.rest{background:var(--surface);color:var(--ink);border-color:var(--line)}
.hero.rest .big{font-size:26px;color:var(--mute)}
.hero .with{margin-top:12px;padding-top:10px;border-top:1px solid color-mix(in srgb,currentColor 28%,transparent)}
.hero .with small{color:inherit;opacity:.85;font-size:11px;font-weight:700;letter-spacing:.05em}
.hero .wn{display:flex;gap:6px;flex-wrap:wrap;margin-top:6px}
.hero .wn span{background:rgba(255,255,255,.9);color:var(--ink);border-radius:8px;padding:3px 12px;font-weight:700;font-size:15px}

/* ---- 部品 ---- */
.chip{display:inline-block;border-radius:8px;padding:2px 10px;font-weight:700;white-space:nowrap}
.chip.xl{font-size:20px;padding:5px 14px}
.tag{display:inline-block;font-size:10.5px;background:var(--soft);color:var(--mute);border:1px solid var(--line);border-radius:6px;padding:0 6px;margin-left:5px;vertical-align:middle;font-weight:600}
.leave{color:var(--mute2);font-weight:600}
.stats{display:flex;gap:8px;flex-wrap:wrap;align-items:center}
.stats .pill{display:flex;align-items:center;gap:6px;font-size:12.5px;color:var(--mute);background:var(--soft);border:1px solid var(--line);border-radius:999px;padding:3px 12px 3px 4px}
.stats .pill b{color:var(--ink)}
.big-n{font-size:26px;font-weight:700;color:var(--ink)}
small{display:block;font-size:10px;color:var(--mute2);line-height:1.15}

/* ---- セクション見出し＋切り替え ---- */
.tg{display:flex;align-items:center;justify-content:space-between;gap:8px;margin:16px 2px 8px}
.tg h2{margin:0;font-size:13.5px;font-weight:700;color:var(--ink);letter-spacing:.01em}
.seg{display:flex;border:1px solid var(--line2);border-radius:8px;background:var(--surface);overflow:hidden;flex:none}
.seg button{border:0;background:none;padding:0 14px;height:34px;font-weight:600;font-size:12.5px;color:var(--mute);cursor:pointer}
.seg button+button{border-left:1px solid var(--line2)}
.seg button.on{background:var(--accent);color:#fff}

/* ---- 医院選び ---- */
.chips{display:grid;grid-template-columns:repeat(5,1fr);gap:6px}
.chips button{border:2px solid transparent;border-radius:8px;min-height:40px;padding:4px 2px;font-weight:700;cursor:pointer;font-size:12.5px;line-height:1.2;letter-spacing:-.02em}
.chips button.off{opacity:.3}
.chips button.sel{box-shadow:0 0 0 2px var(--surface),0 0 0 4px var(--ink)}
.names{display:flex;gap:6px;flex-wrap:wrap}
.names>span{background:var(--soft);border:1px solid var(--line);border-radius:8px;padding:2px 11px;font-weight:600}

/* ---- リスト ---- */
.card.list{padding:4px 12px}
.row{display:flex;align-items:center;gap:12px;padding:10px 4px;border-bottom:1px solid var(--line)}
.row:last-child{border-bottom:0}
.row .d{width:50px;font-weight:700;flex:none;font-variant-numeric:tabular-nums;color:var(--ink)}
.row .d small{display:inline;color:var(--mute);font-weight:600;font-size:11px}
.row.sat .d small{color:var(--sat)}.row.sun .d small{color:var(--sun)}
.row.today{background:var(--today);border-radius:8px;padding-left:8px;margin:0 -4px}
.row .w{flex:1;min-width:0}
.day{display:flex;gap:12px;align-items:center;padding:11px 4px 11px 10px;border-bottom:1px solid var(--line);border-left:4px solid var(--c,transparent);margin-left:-4px}
.day:last-child{border-bottom:0}
.day .dd{width:38px;flex:none;text-align:center;line-height:1.1}
.day .dd b{display:block;font-size:21px;font-weight:700;font-variant-numeric:tabular-nums;color:var(--ink)}
.day .dd small{font-size:11px;font-weight:700;color:var(--mute)}
.day.sat .dd small{color:var(--sat)}.day.sun .dd small{color:var(--sun)}
.day .bd{flex:1;min-width:0}
.day .cl{display:flex;align-items:center;gap:4px;flex-wrap:wrap}
.day .cl .chip{font-size:15px;padding:2px 11px}
.day .wn{display:flex;gap:5px;flex-wrap:wrap;margin-top:6px}
.day .wn span{background:var(--soft);border:1px solid var(--line);border-radius:7px;padding:0 9px;font-weight:600;font-size:13.5px}
.day .wn em{color:var(--mute2);font-size:12.5px;font-style:normal}
.day.off{padding-top:6px;padding-bottom:6px;border-left-color:transparent}
.day.off .dd b{font-size:16px;color:var(--mute2)}
.day.today{background:var(--today);border-radius:8px}
.past{margin-top:6px}
.past summary{cursor:pointer;color:var(--mute);font-weight:600;font-size:12.5px;padding:10px 4px;list-style:none}
.past summary::before{content:"▸ "}
.past[open] summary::before{content:"▾ "}

/* ---- 月カレンダー ---- */
.cal{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:3px}
.cal .h{text-align:center;font-size:11px;color:var(--mute);padding:2px 0 4px;font-weight:700}
.cal .h.sat{color:var(--sat)}.cal .h.sun{color:var(--sun)}
.card.calc{padding:8px 6px 10px}
.cell{min-width:0;min-height:88px;border:1px solid var(--line);border-radius:7px;background:var(--surface);padding:3px;display:flex;flex-direction:column;gap:3px;overflow:hidden}
.cell.empty{background:none;border-color:transparent}
.cell.off{min-height:52px;background:var(--soft)}
.cell .n{font-size:11px;font-weight:700;color:var(--mute);line-height:1.1}
.cell .c{display:block;font-size:clamp(8.5px,2.55vw,11px);font-weight:700;line-height:1.2;border-radius:5px;padding:3px 1px;text-align:center;white-space:nowrap;letter-spacing:-.03em;overflow:hidden}
.cell .c i{display:block;font-style:normal;font-weight:600;font-size:8.5px;opacity:.9;letter-spacing:0}
.cell .m{display:flex;flex-direction:column;gap:2px;min-width:0}
.cell .m span{background:var(--soft);border:1px solid var(--line);border-radius:4px;font-size:clamp(9.5px,2.9vw,11px);font-weight:600;text-align:center;padding:0;line-height:1.5;overflow:hidden;white-space:nowrap;letter-spacing:-.03em}
.cell .m span i{font-style:normal;font-size:8px;color:var(--mute);margin-left:1px}
.cell .lv{margin:auto 0 0;font-size:10.5px;color:var(--mute2);text-align:center;font-weight:600;white-space:nowrap;overflow:hidden}
.cell.today{border:2px solid #d9a400;background:var(--today)}
.cell.today .n{color:#9a6f00}
@media(min-width:700px){
  main{padding:18px 16px}
  .cal{gap:6px}
  .cell{min-height:116px;padding:6px 7px;border-radius:9px;gap:5px}
  .cell .n{font-size:13px}
  .cell .c{font-size:14px;padding:5px 4px;border-radius:7px;letter-spacing:0}
  .cell .c i{font-size:11px}
  .cell .m{flex-direction:row;flex-wrap:wrap;gap:4px}
  .cell .m span{font-size:13px;padding:1px 8px;border-radius:6px;letter-spacing:0}
  .cell.off{min-height:68px}
}

/* ---- 全体表 ---- */
.tw{overflow:auto;max-height:calc(100vh - 200px);border:1px solid var(--line);border-radius:var(--r);background:var(--surface);-webkit-overflow-scrolling:touch}
table{border-collapse:separate;border-spacing:0;font-size:13px}
th,td{border-right:1px solid var(--line);border-bottom:1px solid var(--line);padding:2px 4px;text-align:center;min-width:42px;height:32px;white-space:nowrap}
thead th{position:sticky;top:0;background:var(--surface);z-index:3;font-size:12px;font-weight:700;padding:6px 4px;color:var(--ink)}
th.dt{position:sticky;left:0;z-index:4;background:var(--surface);min-width:58px;text-align:left;font-variant-numeric:tabular-nums;color:var(--ink)}
tbody th.dt{z-index:2}
th.me{background:#ffe9a8}
td.sat,th.sat{background:#f1f4f9}td.sun,th.sun{background:#fbf1ef}
tr.today th.dt,tr.today td.e{box-shadow:inset 0 2px 0 #d9a400,inset 0 -2px 0 #d9a400}
td.dim .chip{opacity:.12}
td .chip{padding:0 7px;border-radius:6px}
.gh{border-left:3px solid var(--line2)}
.foot{color:var(--mute2);font-size:12px;margin:10px 4px}
@media print{header,nav,.chips{display:none}.tw{max-height:none;overflow:visible}body{font-size:10px;padding:0}}

/* ---- シート修正のお願い ---- */
.warn{border:1px solid #f0dfae;background:#fffaf0;border-radius:var(--r);margin:0 0 12px;overflow:hidden;color:#7a5a12;font-size:13px}
.warn summary{cursor:pointer;padding:11px 14px;font-weight:700;list-style:none}
.warn summary::-webkit-details-marker{display:none}
.warn ul{margin:0;padding:0 14px 4px;list-style:none}
.warn li{padding:8px 0;border-top:1px solid #f6ecd2;color:var(--text)}
.warn li small{display:block;color:var(--mute2);margin-top:1px}
.warn p{margin:0;padding:6px 14px 12px;font-size:12px;color:var(--mute)}
.warn.mute{padding:8px 14px;font-size:12px;color:var(--mute);background:var(--soft);border-color:var(--line)}

/* ---- 名前の一覧 ---- */
.namegrid{display:grid;grid-template-columns:repeat(3,1fr);gap:8px;margin-bottom:12px}
.namegrid button{min-height:48px;border:1px solid var(--line2);background:var(--surface);border-radius:10px;font-weight:700;font-size:16px;color:var(--ink);cursor:pointer;padding:0 4px;white-space:nowrap;overflow:hidden}
.namegrid button:active{background:var(--accent-soft);border-color:var(--accent)}
.bl{font-size:11.5px;font-weight:700;color:var(--mute2);margin:10px 2px 6px;letter-spacing:.05em}
.hint{color:var(--mute2);font-size:12px;margin:4px 2px 0;text-align:center}
@media(min-width:700px){.namegrid{grid-template-columns:repeat(6,1fr)}}

/* ---- 全体：日ごと ---- */
.strip{display:flex;gap:4px;overflow-x:auto;padding:2px 2px 10px;margin:0 -12px 6px;padding-left:12px;padding-right:12px;-webkit-overflow-scrolling:touch;scrollbar-width:none}
.strip::-webkit-scrollbar{display:none}
.strip button{flex:none;width:44px;border:1px solid var(--line);background:var(--surface);border-radius:10px;padding:5px 0 6px;cursor:pointer;text-align:center;line-height:1.2}
.strip button b{display:block;font-size:17px;font-weight:700;color:var(--ink);font-variant-numeric:tabular-nums}
.strip button small{font-size:10.5px;font-weight:700;color:var(--mute)}
.strip button.sat small{color:var(--sat)}.strip button.sun small{color:var(--sun)}
.strip button.today{border-color:#d9a400;background:var(--today)}
.strip button.sel{background:var(--accent);border-color:var(--accent)}
.strip button.sel b,.strip button.sel small{color:#fff}
.cc{background:var(--surface);border:1px solid var(--line);border-left:5px solid var(--c);border-radius:var(--r);padding:11px 12px;margin-bottom:10px}
.cc.off{border-left-color:var(--line2);background:var(--soft)}
.cc .ch{display:flex;align-items:center;justify-content:space-between;margin-bottom:8px}
.cc .ch .chip{font-size:16px;padding:2px 12px}
.cc .cn{color:var(--mute2);font-size:12px;font-weight:700}
.cc .names>span{font-size:15px}
.cc .names>span.me{background:#ffe9a8;border-color:#e8c860}

/* ---- 医院ごとの人数 ---- */
.tiles{display:grid;grid-template-columns:repeat(5,1fr);gap:6px;margin:0 0 10px}
.tile{border:1px solid transparent;border-radius:10px;padding:6px 2px 5px;cursor:pointer;text-align:center;line-height:1.15;min-width:0}
.tile span{display:block;font-size:11.5px;font-weight:700;white-space:nowrap;overflow:hidden;letter-spacing:-.03em}
.tile b{display:block;font-size:22px;font-weight:700;font-variant-numeric:tabular-nums}
.tile.z{background:var(--soft);color:var(--mute2);border-color:var(--line)}
.tile.z b{font-weight:500}
.cell .n{display:flex;justify-content:space-between;align-items:baseline}
.cell .n em{font-style:normal;font-size:9.5px;font-weight:700;color:var(--accent);letter-spacing:-.03em}
@media(min-width:700px){.tiles{grid-template-columns:repeat(13,1fr)}.cell .n em{font-size:12px}}

/* ---- 人数表 ---- */
.cnt th,.cnt td{min-width:40px;padding:2px 3px}
.cnt thead th{font-size:10.5px;letter-spacing:-.03em;padding:6px 2px}
.cnt td.tot{font-weight:700;color:var(--ink);background:var(--soft);min-width:34px}
.cnt .nb{border:0;border-radius:8px;min-width:30px;height:28px;font-weight:700;font-size:14px;cursor:pointer;font-variant-numeric:tabular-nums}
.cnt .z{color:var(--line2)}
.cnt tr.sum td,.cnt tr.sum th{border-top:2px solid var(--line2);font-weight:700;color:var(--ink);position:sticky;bottom:0;background:var(--surface);z-index:2}
.cell.flash{animation:fl 1.6s ease 1}
@keyframes fl{0%,60%{box-shadow:0 0 0 3px #d9a400}100%{box-shadow:0 0 0 0 transparent}}

/* ---- シートとの照合 ---- */
.chk{border:1px solid var(--line);background:var(--surface);border-radius:var(--r);margin:14px 0 4px;font-size:13px}
.chk summary{cursor:pointer;padding:12px 14px;font-weight:700;color:var(--accent);list-style:none;display:flex;justify-content:space-between;gap:8px;align-items:center}
.chk summary::-webkit-details-marker{display:none}
.chk summary small{display:inline;color:var(--mute2);font-weight:500}
.chk.ng{border-color:#f0dfae;background:#fffaf0}.chk.ng summary{color:#7a5a12}
.chk .ci{padding:0 14px 8px;border-top:1px solid var(--line)}
.chk p{margin:10px 0;line-height:1.7}
.chk p small{display:block}
.chk ul{margin:0;padding:0;list-style:none}
.chk li{padding:7px 0;border-top:1px solid var(--line)}
.chk li small{display:block;color:var(--mute2)}
.chk .na{color:var(--mute)}
.chk .mm{color:#7a5a12}
.cell .lv.memo{font-weight:500;font-size:9.5px;white-space:normal;line-height:1.2;color:var(--mute)}

/* ---- 技工士さん（人数には数えない） ---- */
.tk{background:transparent!important;border:1px dashed var(--line2)!important;color:var(--mute)!important}
.cc.tech{border-left-color:var(--line2);border-style:dashed;background:var(--surface)}
.cell .m span.tk{font-size:9.5px;font-weight:600}

/* ---- 午前・午後で医院が違う日 ---- */
.herosplit{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin-bottom:12px}
.herosplit .hero{margin-bottom:0;padding:14px 14px 12px}
.herosplit .hero .big{font-size:26px}
.herosplit .hero .num{display:none}
.cell .c.lvp{background:var(--soft);color:var(--mute);border:1px dashed var(--line2)}

/* ======== 一画面にまとめる（コンパクト） ======== */
main{padding-top:8px}
.warn{margin:0 0 8px}
.warn summary{padding:7px 12px;font-size:12.5px}
.toprow{display:flex;gap:8px;align-items:center;margin-bottom:8px}
.toprow .who{flex:1;margin:0;min-width:0}
.toprow .who select{height:42px;font-size:16px;padding-left:12px}
.toprow .seg button{height:40px;padding:0 11px;font-size:12px}
.tb{display:flex;gap:6px;margin-bottom:8px}
.tbp{flex:1;display:flex;align-items:center;justify-content:space-between;gap:10px;padding:8px 12px;border-radius:12px;border:1px solid rgba(0,0,0,.06);min-width:0}
.tbp.rest{background:var(--surface);color:var(--ink);border-color:var(--line)}
.tbp .tk2{font-size:10.5px;font-weight:700;opacity:.85;letter-spacing:.03em;white-space:nowrap}
.tbp .tn{font-size:22px;font-weight:700;line-height:1.15}
.tbp.rest .tn{color:var(--mute)}
.tbp .tw2{font-size:12.5px;line-height:1.35;text-align:right;opacity:.95;font-weight:600}
.sumline{font-size:12px;color:var(--mute);margin:6px 2px 0;line-height:1.7}
.sumline b{color:var(--ink)}
.sumline .dot{display:inline-block;width:9px;height:9px;border-radius:3px;margin-right:3px;vertical-align:-1px}
.card.calc{padding:6px 4px 8px;margin-bottom:0}
.cal{gap:2px}
.cal .h{padding:0 0 2px;font-size:10.5px}
.cell{min-height:62px;padding:2px;gap:2px;border-radius:6px}
.cell.off{min-height:40px}
.cell .n{font-size:10.5px}
.cell .c{padding:2px 1px;font-size:clamp(8.5px,2.5vw,10.5px);border-radius:4px}
.cell .c i{font-size:8px}
.cell .m{flex-direction:row;flex-wrap:wrap;gap:1px 3px;justify-content:center}
.cell .m span{background:none;border:0;border-radius:0;padding:0;font-size:clamp(9px,2.6vw,10.5px);line-height:1.3;width:auto;color:var(--text)}
.cell .m span i{font-size:7.5px}
.cell .lv{font-size:9.5px}
/* 医院ごと */
.chips.hs{display:flex;overflow-x:auto;gap:6px;margin:0 -12px 8px;padding:2px 12px;scrollbar-width:none;-webkit-overflow-scrolling:touch}
.chips.hs::-webkit-scrollbar{display:none}
.chips.hs button{flex:none;min-height:36px;padding:4px 13px;font-size:13px}
.two{display:grid;grid-template-columns:1fr 1fr;gap:6px;margin-bottom:6px}
.mini{background:var(--surface);border:1px solid var(--line);border-radius:10px;padding:7px 9px;min-width:0}
.mini .mt{font-size:10.5px;font-weight:700;color:var(--mute2);margin-bottom:4px}
.mini .names{gap:4px}
.mini .names>span{padding:0 7px;font-size:12.5px}
.tg{margin:8px 2px 6px}
.tg h2{font-size:12.5px}
.seg button{height:30px}
@media(min-width:700px){
  main{padding-top:10px}
  .cell{min-height:78px;padding:4px 6px;gap:3px}
  .cell.off{min-height:46px}
  .cell .n{font-size:12px}
  .cell .c{font-size:13px;padding:3px 4px}
  .cell .c i{font-size:10px}
  .cell .m{gap:2px 6px;justify-content:flex-start}
  .cell .m span{font-size:12px}
  .tbp .tn{font-size:24px}
  .tbp .tw2{font-size:14px}
}

/* ---- 全体表：1か月を1画面に ---- */
.tt{margin:2px 2px 4px}
.chips.sm{display:flex;flex-wrap:wrap;gap:3px;margin:0 0 6px}
.chips.sm button{min-height:24px;padding:0 8px;font-size:11px;border-radius:6px;border-width:1px;letter-spacing:0}
.chips.sm button.sel,.chips.sm button.off{box-shadow:none}
.tw{max-height:calc(100vh - 172px)}
.tw th,.tw td{height:23px;padding:0 2px;min-width:32px;font-size:11px;line-height:1.1}
.tw thead th{font-size:11px;padding:3px 2px;height:24px}
.tw th.dt{min-width:44px;padding:0 4px;font-size:11.5px;font-weight:700;white-space:nowrap}
.tw th.dt small{display:inline;font-size:9.5px;margin-left:1px;color:var(--mute2);font-weight:600}
.tw th.dt.sat small{color:var(--sat)}.tw th.dt.sun small{color:var(--sun)}
.tw td .chip{padding:0 5px;font-size:11px;line-height:17px;border-radius:5px;min-width:19px;text-align:center}
.tw td .chip+.chip{margin-left:1px}
.tw td .leave{font-size:10px;font-weight:500}
.tw td{position:relative}
.nd{position:absolute;right:2px;top:2px;width:4px;height:4px;border-radius:50%;background:#d9a400}
.cnt th,.cnt td{height:23px}
.cnt .nb{height:19px;min-width:24px;font-size:12px;border-radius:5px}
.cnt thead th{font-size:10px}
.cnt td.tot{min-width:28px;font-size:11px}
@media(max-width:699px){
  .tw{max-height:calc(100vh - 150px)}
  .tw th,.tw td{height:20px;min-width:28px}
  .tw td .chip{line-height:15px;font-size:10.5px;min-width:17px}
  .cnt .nb{height:17px;min-width:21px;font-size:11px}
  .tw th.dt{min-width:40px}
}
/* 1画面に収める最終調整 */
.tw{max-height:calc(100dvh - 232px)}
.tw th,.tw td{height:20px}
.tw td .chip{line-height:15px;font-size:10.5px;min-width:18px}
.tw thead th{height:22px;padding:2px}
.cnt th,.cnt td{height:20px}
.cnt .nb{height:16px;font-size:11px}
@media(max-width:699px){.tw{max-height:calc(100dvh - 215px)}}

/* ======== UI 全見直し：スマホもPCも、なるべく1画面 ======== */
/* 警告は細い1行に */
.warn{margin:0 0 6px;border-radius:10px}
.warn summary{padding:5px 12px;font-size:12px}
.warn ul{max-height:50vh;overflow:auto}
/* 全体（日ごと）：医院カードを並べて、1画面に */
.strip{margin-bottom:2px;padding-bottom:6px}
.strip button{width:40px;padding:3px 0 4px}
.strip button b{font-size:15px}
.tiles{grid-template-columns:repeat(7,1fr);gap:4px;margin-bottom:6px}
.tile{padding:3px 1px 2px;border-radius:8px}
.tile span{font-size:10.5px}
.tile b{font-size:17px}
#main .foot{margin:0 2px 6px}
.ccs{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:5px}
.cc{margin:0;padding:7px 9px;border-radius:10px}
.cc.wide{grid-column:1/-1}
.cc .ch{margin-bottom:5px}
.cc .ch .chip{font-size:13px;padding:1px 9px}
.cc .cn{font-size:11px}
.cc .names{gap:4px}
.cc .names>span{font-size:13px;padding:0 8px}
.cc .names>span .tag{font-size:9.5px;margin-left:3px}

/* ---- PC（幅が広いとき）---- */
@media(min-width:900px){
  header{min-height:52px;padding:0 20px}
  main{max-width:1400px;padding:10px 20px 8px}
  main.mid{max-width:1400px}
  /* 私のシフト：左に名前・今日・まとめ、右に大きなカレンダー */
  .me2{display:grid;grid-template-columns:330px minmax(0,1fr);grid-template-areas:"lc rc" "sc rc";grid-template-rows:auto 1fr;gap:0 18px;align-items:start}
  .me2 .lc{grid-area:lc}.me2 .rc{grid-area:rc}.me2 .sc{grid-area:sc}
  .me2 .toprow{flex-direction:column;align-items:stretch}
  .me2 .toprow .seg{align-self:flex-start}
  .me2 .tb{flex-direction:column}
  .me2 .tbp{flex-direction:column;align-items:flex-start;gap:6px;padding:12px 14px}
  .me2 .tbp .tn{font-size:30px}
  .me2 .tbp .tw2{text-align:left;font-size:14px}
  .me2 .sumline{font-size:13px;line-height:2}
  .rc .card.calc{padding:10px}
  .cal{gap:6px}
  .cell{min-height:calc((100dvh - 190px)/5.4);padding:5px 7px}
  .cell.off{min-height:calc((100dvh - 190px)/8)}
  /* 全体（日ごと） */
  .tiles{grid-template-columns:repeat(13,1fr);gap:6px}
  .tile span{font-size:12px}.tile b{font-size:22px}
  .ccs{grid-template-columns:repeat(auto-fill,minmax(230px,1fr));gap:8px}
  .cc .names>span{font-size:14px}
  .strip{justify-content:center;overflow:visible;flex-wrap:wrap}
  .strip button{width:calc((100% - 30*4px)/31);min-width:34px}
  .tw{max-height:calc(100dvh - 150px)}
  .two{max-width:760px}
}
@media(min-width:1500px){ .cell{min-height:calc((100dvh - 200px)/5.4)} }
@media(min-width:900px){
  .tw{max-height:calc(100dvh - 205px)}
  main[data-view=clinic] .cell{min-height:calc((100dvh - 330px)/5.4)}
  main[data-view=clinic] .cell.off{min-height:calc((100dvh - 330px)/8)}
  main[data-view=clinic] .chips.hs{flex-wrap:wrap;overflow:visible;margin:0 0 8px;padding:0}
  main[data-view=clinic] .chips.hs button{min-height:32px}
}
.chk{margin:6px 0 0;border-radius:10px}
.chk summary{padding:6px 12px;font-size:12px}
#main .foot:last-of-type{margin:6px 2px 0}

/* ---- スマホ：表と人数も1画面に ---- */
@media(max-width:899px){
  .chips.sm{flex-wrap:nowrap;overflow-x:auto;margin:0 -12px 6px;padding:0 12px;scrollbar-width:none}
  .chips.sm::-webkit-scrollbar{display:none}
  .chips.sm button{flex:none}
  .tw{max-height:calc(100dvh - 262px)}
  .tw th,.tw td{height:18px;min-width:27px}
  .tw thead th{height:20px;font-size:10px}
  .tw td .chip{line-height:14px;font-size:10px;min-width:16px;border-radius:4px}
  .tw th.dt{font-size:10.5px;min-width:36px;padding:0 3px}
  .cnt .nb{height:15px;min-width:20px;font-size:10.5px;border-radius:4px}
  #main .foot:last-of-type{display:none}
  .tg{margin:6px 2px 5px}
}
.tot2{font-size:11.5px;font-weight:600;color:var(--mute);margin-left:2px}

/* ---- 背の低い画面（小さめのスマホ） ---- */
@media(max-height:720px) and (max-width:899px){
  header{min-height:48px;padding:4px 12px}
  .mon button,.mon select{height:34px}
  .toprow{margin-bottom:6px}
  .toprow .who select{height:38px}
  .toprow .seg button{height:36px}
  .tbp{padding:6px 12px}.tbp .tn{font-size:19px}
  .cell{min-height:50px}.cell.off{min-height:32px}
  .cal .h{font-size:10px}
  .sumline{margin-top:4px;line-height:1.5}
  .warn summary{padding:4px 10px}
  .tiles{margin-bottom:4px}
  .strip button{padding:2px 0 3px}
  .tw{max-height:calc(100dvh - 240px)}
  .tw th,.tw td{height:17px}
}
@media(max-height:720px) and (max-width:899px){
  nav button{min-height:46px}
  .cell{min-height:47px}
  .cell.off{min-height:30px}
  .warn{margin-bottom:4px}
  main{padding-top:6px}
}
@media(max-height:720px) and (max-width:899px){ .sumline{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;line-height:1.4} }

/* ---- 上の帯を隠す／印刷 ---- */
.tools{display:flex;gap:6px}
.tb2{border:1px solid var(--line2);background:var(--surface);border-radius:8px;height:34px;padding:0 11px;font-size:12px;font-weight:600;color:var(--mute);cursor:pointer;white-space:nowrap}
.tb2:active{background:var(--soft)}
#show{display:none;position:fixed;top:6px;right:8px;z-index:60;border:1px solid var(--line2);background:rgba(255,255,255,.96);border-radius:999px;height:30px;padding:0 12px;font-size:12px;font-weight:700;color:var(--accent);box-shadow:0 2px 10px rgba(20,40,30,.15);cursor:pointer}
body.fs header,body.fs nav,body.fs .warn,body.fs .chk{display:none}
body.fs #show{display:block}
body.fs{padding-bottom:0}
body.fs main{padding-top:40px}
body.fs .tw{max-height:calc(100dvh - 118px)}
body.fs .cell{min-height:calc((100dvh - 150px)/5.4)}
body.fs[data-x] {}
@media(max-width:560px){ .brand small{display:none} .tb2{padding:0 8px} header{gap:6px;padding-left:10px;padding-right:10px} }
.pm{display:none;position:fixed;top:54px;right:12px;z-index:70;width:290px;background:var(--surface);border:1px solid var(--line2);border-radius:12px;box-shadow:0 8px 30px rgba(20,40,30,.22);padding:8px}
.pm.on{display:block}
.pm .pmh{font-size:11px;font-weight:700;color:var(--mute2);padding:4px 8px 6px}
.pm button{display:block;width:100%;text-align:left;border:0;background:none;border-radius:8px;padding:9px 10px;font-size:14px;font-weight:600;color:var(--ink);cursor:pointer}
.pm button small{display:block;font-size:11px;font-weight:400;color:var(--mute2)}
.pm button:hover{background:var(--soft)}
.pm button:disabled{opacity:.4;cursor:default}
#print{display:none}

/* ---- 人・医院を押すと、その人／医院のシフトへ ---- */
[data-p],[data-k]{cursor:pointer}
[data-p]:hover{text-decoration:underline;text-decoration-color:var(--accent);text-underline-offset:2px}
th[data-p]:hover,th[data-k]:hover{filter:brightness(.95)}
.peek{display:flex;align-items:center;justify-content:space-between;gap:8px;background:var(--accent-soft);border:1px solid var(--line2);border-radius:10px;padding:5px 6px 5px 12px;margin-bottom:8px;font-size:12.5px;font-weight:700;color:var(--accent)}
.peek button{border:0;background:var(--accent);color:#fff;border-radius:8px;height:30px;padding:0 12px;font-size:12px;font-weight:700;cursor:pointer}
.cell .m span[data-p]{cursor:pointer}

/* ---- 日付を押すと、その行（日）が目立つ ---- */
tr.hl th.dt{background:#ffd34d!important;color:#26342e}
tr.hl td{background:#fff1bd!important;box-shadow:inset 0 2px 0 #d9a400,inset 0 -2px 0 #d9a400}
tr.hl td.dim{background:#fff1bd!important}
.cell.hl{border:2px solid #d9a400;background:#fff1bd;box-shadow:0 0 0 2px rgba(217,164,0,.28)}
.cell.hl .n{color:#7a5a12}
th.dt,.cell .n{cursor:pointer}
/* ---- タッチの使いやすさ ---- */
html{touch-action:manipulation;overscroll-behavior-y:none}
button,select,[data-p],[data-k],th.dt{touch-action:manipulation;-webkit-user-select:none;user-select:none}
button:active,[data-p]:active,[data-k]:active{opacity:.78}
nav button:active{background:var(--accent-soft)}
.tw{overscroll-behavior:contain}
input,select,textarea{font-size:16px}

/* ======== 案B：白地＋色の小さな印（医院の色は印と線で残す） ======== */
.cb{background:var(--surface)!important;color:var(--ink)!important;border:1px solid var(--line2)!important;font-weight:700}
.chip.cb{display:inline-flex;align-items:center;gap:6px;padding:2px 10px 2px 8px}
.chip.cb::before,.chips button.cb::before{content:"";flex:none;width:9px;height:9px;border-radius:3px;background:var(--c)}
.chip.cb.xl{padding:5px 14px 5px 11px}
.day .cl .chip.cb{font-size:15px}
/* カレンダーの医院名：上に色の線 */
.cell .c.cb{display:flex;align-items:center;justify-content:center;flex-wrap:wrap;gap:0 3px;border:1px solid var(--line2)!important;border-top:3px solid var(--c)!important;border-radius:5px;padding:1px 1px 2px;background:var(--surface)!important}
.cell .c.cb::before{display:none}
.cell .c.cb i{color:var(--mute);font-weight:600}
/* 医院ボタン */
.chips button.cb{display:inline-flex;align-items:center;gap:6px;border:1px solid var(--line2)!important;border-bottom:3px solid var(--c)!important}
.chips button.cb.sel{box-shadow:none;border-color:var(--ink)!important;border-bottom:3px solid var(--c)!important;background:var(--soft)!important}
.chips button.cb.off{opacity:.4}
.chips.sm button.cb{border-bottom-width:2px!important;padding:0 8px}
.chips.sm button.cb::before{width:7px;height:7px}
/* 人数タイル：上に色の線、数字は濃い文字 */
.tile.cb{border:1px solid var(--line2)!important;border-top:3px solid var(--c)!important;background:var(--surface)!important;color:var(--ink)!important}
.tile.cb span{color:var(--mute);font-weight:600}
.tile.cb b{color:var(--ink)}
/* 医院カード（日ごと）の見出しチップ */
.cc .ch .chip.cb{font-size:14px}

/* ---- カレンダーのドクター名：余白とそろえ方を整える ---- */
.cell .m{display:flex;flex-wrap:wrap;justify-content:center;align-content:flex-start;gap:2px 6px;padding:2px 2px 3px;margin-top:1px}
.cell .m span{white-space:nowrap;line-height:1.35;padding:0}
.cell .m span .hf{font-size:7.5px;color:var(--mute);margin-left:1px;font-weight:700}
.nd2{display:inline-block;width:4px;height:4px;border-radius:50%;background:#d9a400;margin-left:2px;vertical-align:super}
.cell{padding:3px 3px 4px}
.cell .n{display:flex;justify-content:space-between;align-items:baseline;padding:0 1px 1px}
.cell .c.cb{margin-bottom:1px}
@media(min-width:700px){ .cell .m{justify-content:flex-start;gap:2px 8px;padding:3px 2px} }

/* ---- 上の帯：スマホで「シフトPortal」が切れないように ---- */
@media(max-width:430px){
  header{gap:6px;padding:6px 10px}
  .brand b{font-size:15.5px;letter-spacing:.02em;white-space:nowrap}
  .tools{gap:4px}
  .tb2{height:32px;padding:0 8px;font-size:11.5px}
  .mon button{width:30px;height:32px}
  .mon select{height:32px;font-size:12.5px;padding:0 4px;max-width:92px}
}
@media(max-width:360px){ .brand b{font-size:14px} .tb2{padding:0 6px} .mon select{max-width:84px} }

/* ======== 背景を白に：灰色背景をやめて、文字をはっきり ======== */
:root{--bg:#ffffff;--soft:#f5f7f4;--line:#dde4dc;--line2:#c6d1c3;--mute:#56615a;--mute2:#66716a}
body{background:#fff}
header{background:rgba(255,255,255,.97)}
.card,.cc,.mini,.chk,.warn{box-shadow:0 1px 3px rgba(38,52,46,.07)}
.card,.cc,.mini{border-color:var(--line)}
.names>span,.mini .names>span,.cc .names>span{background:#fff;border:1px solid var(--line2);color:var(--ink)}
.cell{border-color:var(--line2)}
.cell.off{background:var(--soft)}
.mini .mt,.hero .with small{color:var(--mute)}
.card h2,.sec h2,.tg .tot2{color:var(--mute)}
.tw{border-color:var(--line2)}
.tw th,.tw td{border-color:var(--line)}
.chips.hs,.chips.sm{background:transparent}
.day{border-bottom-color:var(--line)}
.stats .pill{background:#fff;border-color:var(--line2)}
.tag{background:#fff;border-color:var(--line2);color:var(--mute)}
.peek{background:#eaf3ec}

/* ---- 上のタブは広い画面だけ（タブレット幅では下のタブ） ---- */
@media(min-width:1100px){
  body{padding-bottom:0}
  /* 画面下のタブは、上の帯の中央へ */
  nav{top:0;bottom:auto;left:50%;right:auto;transform:translateX(-50%);width:auto;background:none;border:0;padding:0;z-index:30}
  nav .in{width:460px;max-width:none}
  nav button{min-height:52px;font-size:14px;border-radius:0}
  nav button.on{background:none;box-shadow:inset 0 -3px 0 var(--accent)}
  nav button.on::before{display:none}
}

/* ---- 今日・明日の枠：医院の色を入れる ---- */
.mini{border-top:4px solid var(--c)}
.mini .mt{display:flex;justify-content:space-between;align-items:center;gap:6px;color:var(--mute);font-weight:700}
.chip.cb.sm{font-size:11px;padding:0 7px 0 6px;gap:4px;font-weight:700;border-radius:6px}
.chip.cb.sm::before{width:7px;height:7px}
.mini .names>span{background:color-mix(in srgb,var(--c) 11%,#fff);border-color:color-mix(in srgb,var(--c) 42%,#fff)}
.card.list.cl{border-top:4px solid var(--c)}
.card.list.cl .names>span{background:color-mix(in srgb,var(--c) 11%,#fff);border-color:color-mix(in srgb,var(--c) 42%,#fff)}

/* ======== PC見直し：上に帯、下に大きなカレンダー。色・文字・中央ぞろえ ======== */
@media(min-width:900px){
  main,main.mid{max-width:1760px;padding:12px 28px 10px}
  /* 私のシフト：上の帯（名前・今日・まとめ）＋全幅カレンダー */
  .me2{grid-template-columns:minmax(0,1fr) auto;grid-template-areas:"lc sc" "rc rc";grid-template-rows:auto 1fr;gap:0 28px;align-items:center}
  .me2 .lc{display:flex;flex-wrap:wrap;gap:8px 16px;align-items:stretch;margin-bottom:8px}
  .me2 .peek{flex-basis:100%;margin-bottom:0}
  .me2 .toprow{flex-direction:row;align-items:center;flex:0 0 440px;margin:0}
  .me2 .toprow .seg{align-self:auto}
  .me2 .tb{flex-direction:row;flex:1;min-width:420px;margin:0}
  .me2 .tbp{flex-direction:row;align-items:center;gap:18px;padding:8px 18px}
  .me2 .tbp .tn{font-size:26px}
  .me2 .tbp .tw2{text-align:right;font-size:15px}
  .me2 .sc{align-self:center}
  .me2 .sumline{margin:0 0 8px;font-size:14px;white-space:nowrap}
  /* カレンダー全体 */
  .rc .card.calc{padding:12px 14px 14px}
  .cal{gap:8px}
  .cal .h{font-size:clamp(13px,.9vw,16px);padding-bottom:4px}
  .cell{min-height:calc((100dvh - 268px)/5.15);padding:6px 10px 8px;border-radius:10px;gap:6px;align-items:stretch}
  body.fs .cell{min-height:calc((100dvh - 200px)/5.15)}
  .cell.off{min-height:calc((100dvh - 268px)/6.5)}
  .cell .n{font-size:clamp(13px,.9vw,16px);font-weight:700}
  /* 色を大きく：医院の色の淡い地＋太い上線 */
  .cell[style*="--c"]{background:color-mix(in srgb,var(--c) 7%,#fff)}
  .cell .c.cb{border:1px solid color-mix(in srgb,var(--c) 40%,#fff)!important;border-top:6px solid var(--c)!important;background:color-mix(in srgb,var(--c) 15%,#fff)!important;border-radius:8px;padding:5px 4px 6px;font-size:clamp(15px,1.15vw,20px);font-weight:700;color:var(--ink)!important;gap:4px}
  .cell .c.cb i{font-size:clamp(11px,.8vw,14px)}
  /* 名前：中央ぞろえで、読みやすい大きさ */
  .cell .m{justify-content:center;align-content:flex-start;gap:3px 12px;padding:2px 2px 0}
  .cell .m span{font-size:clamp(14px,1.05vw,18px);font-weight:700;color:var(--ink)}
  .cell .m span .hf{font-size:11px}
  .cell .n em{font-size:clamp(12px,.85vw,15px)}
  .cell .lv{font-size:clamp(12px,.85vw,15px)}
  /* 医院ごと */
  main[data-view=clinic] .cell{min-height:calc((100dvh - 350px)/5.15)}
  body.fs main[data-view=clinic] .cell{min-height:calc((100dvh - 230px)/5.15)}
  main[data-view=clinic] .cell .n{justify-content:space-between}
}
@media(min-width:1500px){ .me2 .tbp .tn{font-size:30px} }

/* ---- PC：画面の大きさに合わせて、表・日ごと・医院ごとを大きく ---- */
@media(min-width:1100px){
  /* 全体表・人数：幅いっぱい・高さいっぱいに */
  .tw table{width:100%;table-layout:fixed;min-width:1040px}
  .tw th.dt{width:58px;min-width:58px;font-size:clamp(12px,.85vw,15px)}
  .tw th,.tw td{height:clamp(20px,calc((100dvh - 262px)/32),38px);min-width:0;font-size:clamp(11px,.8vw,14px)}
  .tw thead th{height:clamp(24px,2vh,34px);font-size:clamp(11px,.8vw,14px)}
  .tw td .chip{min-width:clamp(19px,1.35vw,28px);line-height:clamp(15px,calc((100dvh - 262px)/32 - 5px),30px);font-size:clamp(11px,.85vw,15px);padding:0 4px}
  .tw td .leave{font-size:clamp(10px,.75vw,13px)}
  .cnt .nb{height:clamp(16px,calc((100dvh - 262px)/32 - 4px),30px);min-width:clamp(24px,1.8vw,38px);font-size:clamp(12px,.9vw,16px)}
  /* 全体（日ごと） */
  .strip button{height:clamp(44px,4.4vh,56px)}
  .strip button b{font-size:clamp(15px,1.1vw,20px)}
  .strip button small{font-size:clamp(10.5px,.75vw,13px)}
  .tile{padding:clamp(4px,.6vh,10px) 2px}
  .tile span{font-size:clamp(12px,.9vw,16px)}
  .tile b{font-size:clamp(22px,1.8vw,34px)}
  .ccs{grid-template-columns:repeat(auto-fill,minmax(clamp(250px,18vw,360px),1fr));gap:12px}
  .cc{padding:12px 14px}
  .cc .ch .chip{font-size:clamp(15px,1.1vw,19px)}
  .cc .cn{font-size:clamp(12px,.85vw,15px)}
  .cc .names>span{font-size:clamp(15px,1.1vw,20px);padding:2px 11px}
  .tg h2{font-size:clamp(14px,1vw,17px)}
  /* 医院ごと：ボタンと今日・明日を大きく */
  .chips.hs button{font-size:clamp(13px,.95vw,17px);min-height:clamp(36px,3.4vh,46px);padding:4px 16px}
  .two{max-width:none;grid-template-columns:repeat(2,minmax(0,520px))}
  .mini{padding:10px 14px}
  .mini .mt{font-size:clamp(12px,.85vw,15px)}
  .mini .names>span{font-size:clamp(15px,1.1vw,19px);padding:1px 11px}
  .chip.cb.sm{font-size:clamp(11px,.8vw,14px)}
  main[data-view=clinic] .cell .m span{font-size:clamp(15px,1.15vw,20px)}
  main[data-view=clinic] .cell .n em{font-size:clamp(13px,.9vw,16px)}
}
/* 背の低いPC画面（ノートPCなど）：中身を詰めて1画面に */
@media(min-width:900px) and (max-height:860px){
  .me2 .tbp{padding:5px 16px}.me2 .tbp .tn{font-size:22px}
  .cell{padding:4px 8px 5px;gap:4px}
  .cell .c.cb{padding:3px 4px 4px;font-size:15px;border-top-width:5px!important}
  .cell .m span{font-size:14px}
  .cell .n{font-size:13px}
  .cell{min-height:calc((100dvh - 250px)/5.15)}
  main[data-view=clinic] .cell{min-height:calc((100dvh - 320px)/5.15)}
}
@media(min-width:1100px){ .cc .ch .chip.cb{font-size:clamp(15px,1.1vw,19px)} .tile.cb span{font-size:clamp(12px,.9vw,16px)} }

/* ======== 余白の見直し：スペースを有効に使う ======== */
main{padding:8px 8px 10px}
.card{padding:10px;margin-bottom:8px;border-radius:10px}
.card.list{padding:2px 10px}
.card.calc{padding:5px 4px 6px}
.toprow{margin-bottom:6px}
.tb{margin-bottom:6px}
.tg{margin:6px 2px 5px}
.warn{margin-bottom:5px}
.cc{padding:6px 8px}
.row{padding:7px 3px}
.day{padding:8px 4px 8px 10px}
.day.off{padding-top:4px;padding-bottom:4px}
.hero{padding:12px 14px;margin-bottom:8px}
.chk{margin-top:4px}
.sumline{margin-top:4px}
/* 名前の札は、そろった幅の格子に（余白を均等に使う） */
.mini .names,.cc .names,.row .w.names{display:grid;grid-template-columns:repeat(auto-fill,minmax(66px,1fr));gap:4px}
.mini .names>span,.cc .names>span,.row .w.names>span{text-align:center;padding:2px 4px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.row .w.names{margin-right:0}
.mini{padding:6px 8px}
.mini .mt{margin-bottom:5px}
/* 医院ごとの並び（スマホは縦） */
.cl2{display:block}
.cside .chips.hs{margin-bottom:6px}
.chips.hs button em{font-style:normal;font-size:11px;font-weight:700;color:var(--mute);margin-left:6px;background:var(--soft);border-radius:999px;padding:0 6px}
@media(min-width:900px){
  main,main.mid,main[data-view]{max-width:none;padding:8px 14px 8px}
  .cl2{display:grid;grid-template-columns:232px minmax(0,1fr);gap:14px;align-items:start}
  .cside{position:sticky;top:58px}
  .cside .chips.hs{display:grid;grid-template-columns:1fr;gap:4px;margin:0 0 10px;padding:0;overflow:visible}
  .cside .chips.hs button{width:100%;justify-content:flex-start;min-height:36px;padding:0 10px;font-size:14px}
  .cside .chips.hs button em{margin-left:auto}
  .cside .two{grid-template-columns:1fr;max-width:none;gap:8px}
  .cmain .tg{margin-top:0}
  main[data-view=clinic] .cell{min-height:calc((100dvh - 215px)/5.4)}
  main[data-view=clinic] .cell.off{min-height:calc((100dvh - 215px)/8)}
  /* 表・人数：横幅いっぱいに広げる */
  .tw table{width:100%}
  .tw th,.tw td{min-width:0}
  .tw th.dt{width:52px}
  .ccs{grid-template-columns:repeat(auto-fill,minmax(210px,1fr));gap:6px}
}

/* ---- 休診日（グレー） ---- */
.cell.closed{background:#eceeec;border-color:#d4d9d3}
.cell.closed .n{color:var(--mute2)}
.cell.closed .lv{display:block;margin:auto 0;text-align:center;color:#7d877f;font-size:11px;font-weight:700;letter-spacing:.05em}
.tile.closed b{font-size:13px;color:#7d877f;font-weight:700}
.cnt .z.cz{color:#8a948c;font-size:10px;font-weight:700}
@media(min-width:900px){
  .cside .mini .names{grid-template-columns:repeat(auto-fill,minmax(84px,1fr))}
  .cside .mini .names>span{white-space:normal;overflow:visible;text-overflow:clip;line-height:1.25}
}

/* 名前の札：切れずに、タグは下に折り返す */
.mini .names,.cc .names,.row .w.names{grid-template-columns:repeat(auto-fill,minmax(58px,1fr))}
.mini .names>span,.cc .names>span,.row .w.names>span{white-space:normal;overflow:visible;text-overflow:clip;display:flex;flex-wrap:wrap;justify-content:center;align-items:center;gap:0 3px;line-height:1.2;padding:3px 4px}
.mini .names>span .tag,.cc .names>span .tag,.row .w.names>span .tag{margin-left:0;font-size:9.5px;padding:0 5px}

/* ---- PC：リスト表示は幅いっぱいに引き伸ばさず、列に分ける ---- */
@media(min-width:900px){
  main[data-view=me]:not(.mid) .toprow,main[data-view=me]:not(.mid) .tb,main[data-view=me]:not(.mid) .peek{max-width:780px}
  main[data-view=me]:not(.mid) .card.list{column-count:2;column-gap:32px}
  .card.list .day,.card.list .row{break-inside:avoid}
  main[data-view=clinic] .card.list.cl{column-count:2;column-gap:32px}
}
@media(min-width:1500px){
  main[data-view=me]:not(.mid) .card.list{column-count:3}
  main[data-view=clinic] .card.list.cl{column-count:3}
}

/* ---- 制作中（確定前）の帯 ---- */
.ribbon{display:flex;align-items:center;gap:10px;background:repeating-linear-gradient(135deg,#fff6d6 0 12px,#fff0bd 12px 24px);border:1px solid #e3c25a;border-radius:10px;padding:5px 12px;margin:0 0 6px;color:#6b4e0c;font-size:12.5px;line-height:1.4}
.ribbon b{background:#d9a400;color:#fff;border-radius:6px;padding:1px 9px;font-size:12px;letter-spacing:.06em;white-space:nowrap}

/* ---- 確定にするボタン／トースト ---- */
.ribbon{flex-wrap:wrap}
.ribbon span{flex:1;min-width:180px}
.rbtn{border:0;background:#2f6b4d;color:#fff;border-radius:8px;height:32px;padding:0 14px;font-size:13px;font-weight:700;cursor:pointer;white-space:nowrap}
.rbtn:active{opacity:.8}
.rbtn.ghost{background:#fff;color:#2f6b4d;border:1px solid #2f6b4d;height:30px;font-size:12.5px}
.stl{margin:8px 0 4px;font-size:13px;color:var(--mute)}
.toast{position:fixed;left:50%;bottom:90px;transform:translateX(-50%);background:#26342e;color:#fff;padding:10px 18px;border-radius:999px;font-size:14px;font-weight:700;z-index:90;box-shadow:0 6px 20px rgba(0,0,0,.25)}
/* ---- 狭い幅：上の帯が切れないように、印刷ボタンは隠す ---- */
@media(max-width:520px){ #prt{display:none} .brand b{font-size:15.5px} }

/* ---- シフトPortalの横の「制作中／確定」ボタン ---- */
.brand{align-items:center}
.stbtn{border:1px solid;border-radius:999px;height:28px;padding:0 11px;font-size:12px;font-weight:700;cursor:pointer;white-space:nowrap;letter-spacing:.04em}
.stbtn.draft{background:#fff3c4;border-color:#d9a400;color:#7a5a12}
.stbtn.final{background:#e3f1e8;border-color:#2f6b4d;color:#1f5a3c}
.stbtn::after{content:" ⇄";font-weight:400;opacity:.7}
.stbtn[hidden]{display:none}
@media(max-width:430px){ .stbtn{height:26px;padding:0 8px;font-size:11.5px} .stbtn::after{content:""} }
@media(max-width:380px){ #hide{display:none} }

/* ======== PC：カレンダーをスクロールなしで1画面に ======== */
/* 高さは app.js の fitCal() が画面に合わせて決める（.cal.fit）。入りきらない日は文字を詰める（.cell.t1／.t2） */
@media(min-width:900px){
  /* 私のシフト：名前・今日・まとめを1行に */
  .me2{grid-template-columns:minmax(0,1fr) auto;gap:0 20px}
  .me2 .lc{gap:6px 10px;margin-bottom:6px}
  .me2 .toprow{flex:0 0 auto;gap:6px}
  .me2 .tb{flex:1 1 0}
  .me2 .toprow .who{width:200px;flex:none}
  .me2 .toprow .who select{height:38px;font-size:15px}
  .me2 .toprow .seg button{height:36px}
  .me2 .tb{min-width:0;gap:6px}
  .me2 .tbp,.me2 .tbp.rest{padding:3px 14px;border-radius:9px;min-height:38px;gap:12px}
  .me2 .tbp>div:first-child{display:flex;align-items:baseline;gap:10px;min-width:0;white-space:nowrap}
  .me2 .tbp .tn{font-size:19px}
  .me2 .tbp .tw2{font-size:14px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
  .me2 .sumline{margin:0 0 6px;font-size:13px;line-height:1.45;white-space:normal;word-break:keep-all;max-width:360px}
  .me2 .sc{align-self:start}
  /* 画面に合わせた高さ：週の数で等分 */
  .cal.fit .h{padding-bottom:2px}
  .cal.fit .cell,.cal.fit .cell.off{min-height:0!important;overflow:hidden}
  .cal.fit .cell>*{flex-shrink:0}
  .rc .card.calc,.cmain .card.calc{padding:8px 10px 10px;margin-bottom:0}
  .cal.fit{gap:6px}
  /* 入りきらない日：少し詰める → もっと詰める */
  .cell.t1{padding:3px 6px 4px;gap:3px}
  .cell.t1 .n{font-size:13px}
  .cell.t1 .c.cb{padding:2px 4px 3px;font-size:14px;border-top-width:4px!important}
  .cell.t1 .m{gap:1px 8px}
  .cell.t1 .m span{font-size:13.5px;line-height:1.3}
  .cell.t2{padding:2px 5px 3px;gap:2px}
  .cell.t2 .n{font-size:12px;line-height:1.2}
  .cell.t2 .c.cb{padding:1px 3px 2px;font-size:12.5px;border-top-width:3px!important;flex-wrap:nowrap}
  .cell.t2 .c.cb i{font-size:10.5px}
  .cell.t2 .m{gap:0 6px;padding-top:0}
  .cell.t2 .m span{font-size:12px;line-height:1.25}
  /* 午前・午後の2つの医院は横に並べる */
  .cell.t2:has(.c+.c){display:grid;grid-template-columns:1fr 1fr;grid-template-rows:auto auto 1fr;column-gap:4px}
  .cell.t2:has(.c+.c) .n,.cell.t2:has(.c+.c) .m{grid-column:1/-1}
}
@media(min-width:900px){
  /* 医院ごと：左の医院ボタンを2列にして、今日・明日まで1画面に */
  .cside .chips.hs{grid-template-columns:1fr 1fr;gap:4px;margin-bottom:8px}
  .cside .chips.hs button{min-height:30px;padding:0 7px;font-size:13px;gap:5px}
  .cside .chips.hs button em{padding:0 5px;font-size:10.5px}
  .cside .mini{padding:6px 10px}
  .cside .two{gap:6px}
}

/* ======== 案3：文字中心・ミニマル（枠と影をなくし、色は医院名の左の細い線だけ） ======== */
:root{--ink:#1d2622;--line:#e6e9e6;--line2:#d5dbd5}
.card,.cc,.mini,.chk,.warn,.card.calc{box-shadow:none}
.card.calc{border:0;background:transparent}
/* カレンダー：マスの枠をやめ、上の線だけ */
.cal{gap:0!important}
.cal .h{text-align:left;padding:0 8px 4px;font-weight:600}
.cell,.cell.off,.cell.closed{border:0!important;border-top:1px solid var(--line)!important;border-radius:0!important;background:transparent!important;box-shadow:none!important}
.cal .cell:not(.empty){border-left:1px solid var(--line)!important}
.cal .h+.cell,.cal .cell:nth-child(7n+8){border-left:0!important}
.cell.empty{border-top-color:transparent!important}
.cell .n{font-size:16px;font-weight:700;color:var(--ink);line-height:1.1}
.cell.sun .n{color:var(--sun)}.cell.sat .n{color:var(--sat)}
.cell.today{border-top:3px solid var(--accent)!important}
.cell.today .n{color:var(--accent)}
.cell.today .n::after{content:"今日";font-size:11px;font-weight:700;margin-left:6px;color:var(--accent)}
.cell.past{opacity:.42}
.cell.hl{background:#fff6d6!important}
/* 医院名：色の文字＋左の線。名前：その下に同じ線 */
.cell .c.cb{display:flex;justify-content:flex-start;background:transparent!important;border:0!important;border-left:3px solid var(--c)!important;border-radius:0!important;color:var(--c)!important;padding:0 0 0 7px!important;font-size:13px!important;text-align:left;margin:0}
.cell .c.cb i{color:var(--mute)!important;font-size:11px!important}
.cell[style*="--c"] .m{border-left:3px solid var(--c);padding:0 0 1px 7px;margin:0}
.cell .m{justify-content:flex-start!important;gap:0 8px!important}
.cell .m span{color:var(--ink)}
.cell .lv{text-align:left;margin:4px 0 0;color:var(--mute2)}
.cell.closed .lv{margin:4px 0 0;text-align:left}
/* 医院ごと：人数は数字だけ控えめに */
.cell .n em{font-weight:600;color:var(--mute)}
/* 私のシフト：今日の帯は塗らずに文字で */
.tbp{background:transparent!important;color:var(--ink)!important;border:0!important;border-left:3px solid var(--c,var(--line2))!important;border-radius:0!important}
.tbp .tn{color:var(--c,var(--mute))!important}
.tbp .tk2{color:var(--mute);opacity:1}
.tbp .tw2{color:var(--ink)}
/* リスト・チップ：塗りをやめて色の点＋文字 */
.chip.cb,.cc .ch .chip.cb{border:0!important;background:transparent!important;color:var(--ink)!important;padding-left:0!important}
.day{border-left:3px solid var(--c,transparent)}
.mini,.card.list.cl{border:1px solid var(--line);border-top:3px solid var(--c)}
.mini .names>span,.card.list.cl .names>span,.cc .names>span,.names>span{background:transparent!important;border:0!important;padding-left:0!important;padding-right:0!important;font-weight:600}
.mini .names,.cc .names{gap:2px 12px}
/* 全体（日ごと）：カードは上の線だけ */
.cc{border:0;border-top:3px solid var(--c,var(--line2));border-radius:0;background:transparent;padding-left:4px}
.tile.cb{border:0!important;border-top:3px solid var(--c)!important;border-radius:0!important}
.tile{border-radius:0}
/* 人数表の見出し：塗らずに下の線 */
.cnt thead th[data-k]{background:transparent!important;color:var(--ink)!important;box-shadow:inset 0 -3px 0 var(--c)}
/* 医院ボタン：下の線だけ */
.chips button.cb{border:0!important;border-bottom:3px solid var(--c)!important;border-radius:0!important;background:transparent!important}
.chips button.cb.sel{background:var(--soft)!important;border-bottom-width:3px!important}
@media(min-width:900px){
  .cell .n{font-size:clamp(16px,1.2vw,20px)}
  .cell .c.cb{font-size:clamp(13px,.95vw,16px)!important}
  .cell .m span{font-size:clamp(14px,1.05vw,18px)}
  .cal.fit{gap:0!important}
  .me2 .tbp,.me2 .tbp.rest{padding:2px 0 2px 12px}
  .me2 .tbp .tn{font-size:20px}
}
/* 案3の続き：リストも枠なし、今日の帯は左に寄せる */
.tbp{justify-content:flex-start!important;gap:16px!important}
.tbp .tw2{text-align:left!important}
.card.list{border:0;background:transparent;padding-left:0;padding-right:0}
.day .wn span{background:transparent;border:0;padding:0;font-size:14.5px;font-weight:700;color:var(--ink)}
.day .wn{gap:2px 12px}
.day.today{background:transparent;border-radius:0;box-shadow:inset 0 3px 0 var(--accent)}
.day.today .dd b{color:var(--accent)}
/* 医院名と名前を見分けやすく：医院は色の札、名前は線なしの濃い文字 */
.cell .c.cb{align-self:flex-start;display:inline-flex!important;gap:4px;border:0!important;border-radius:999px!important;background:color-mix(in srgb,var(--c) 14%,#fff)!important;color:color-mix(in srgb,var(--c) 75%,#000)!important;padding:1px 10px 2px!important;font-size:12.5px!important;line-height:1.4;margin:1px 0 0}
.cell .c.cb i{font-size:10.5px!important}
.cell[style*="--c"] .m{border-left:0;padding:2px 0 0 2px}
.cell .m span{font-weight:700}
.cell .c.cb+.c.cb{margin-top:0}
@media(min-width:900px){
  .cell .c.cb{font-size:clamp(12px,.85vw,14.5px)!important}
  .cell .m span{font-size:clamp(15px,1.15vw,19px)}
}
/* 医院の札を大きく、札と名前は中央ぞろえ */
.cell .c.cb{align-self:center;padding:2px 16px 3px!important;font-size:14px!important}
.cell .m{justify-content:center!important;padding-left:0}
.cell .lv,.cell.closed .lv{text-align:center}
@media(min-width:900px){
  .cell .c.cb{font-size:clamp(14px,1.1vw,18px)!important;padding:2px clamp(14px,1.3vw,22px) 3px!important}
  .cell .c.cb i{font-size:clamp(11px,.8vw,13px)!important}
  .cell.t1 .c.cb{font-size:14px!important;padding:1px 14px 2px!important}
  .cell.t2 .c.cb{font-size:12.5px!important;padding:0 10px 1px!important}
}
/* 札と名前は、日付の下の残りの高さの真ん中に置く（下に空白が偏らないように） */
.cal.fit .cell{padding-bottom:12px}
.cal.fit .cell>.n+*{margin-top:auto!important}
.cal.fit .cell>:last-child:not(.n){margin-bottom:auto!important}
.cal.fit .cell .m{row-gap:4px!important}
.cal.fit .cell .m span{line-height:1.4}
.cal.fit .cell>.c+.m{margin-top:4px}
/* PC：名前を選ぶパネル（全員を1画面に） */
.whopk{position:absolute;z-index:80;width:min(820px,calc(100vw - 40px));max-height:calc(100dvh - 140px);overflow:auto;background:#fff;border:1px solid var(--line2);border-radius:14px;box-shadow:0 10px 32px rgba(20,40,30,.2);padding:6px 14px 12px}
.whopk .namegrid{grid-template-columns:repeat(8,minmax(0,1fr));gap:6px;margin-bottom:4px}
.whopk .namegrid button{min-height:38px;font-size:15px;border-radius:8px}
.whopk .namegrid button:hover{background:var(--soft);border-color:var(--accent)}
.whopk .namegrid button.on{background:var(--accent);border-color:var(--accent);color:#fff}
.whopk .bl{margin:8px 2px 5px}
/* ---- 共有URL：発行パネルと、共有で開いたときの画面 ---- */
.tb2[hidden]{display:none}
.pm .shm{display:flex;align-items:center;gap:8px;padding:6px 8px 8px;font-size:14px;font-weight:600;color:var(--ink);cursor:pointer}
.pm .shm input{width:18px;height:18px;margin:0}
.pm .shu{width:100%;height:36px;border:1px solid var(--line2);border-radius:8px;padding:0 10px;font-size:12px;color:var(--mute);background:var(--soft)}
.pm .shb{display:flex;align-items:center;gap:12px;margin:8px 0 4px}
.pm .shb a{font-size:13px;font-weight:600;color:var(--accent)}
.pm .shn{margin:6px 2px 2px;font-size:11.5px;color:var(--mute2);line-height:1.5}
body.share nav,body.share #prt,body.share #stbtn,body.share #shr{display:none!important}
body.share{padding-bottom:0}
.who.sharet{display:flex;align-items:center;min-height:38px;padding:0 2px;font-size:18px;font-weight:700;color:var(--ink);white-space:nowrap}
@media(min-width:900px){ .me2 .toprow .who.sharet{width:auto} }
.pm .shb button.rbtn{display:inline-flex;align-items:center;width:auto;background:#2f6b4d;color:#fff;border-radius:8px;height:34px;padding:0 16px;font-size:13px;font-weight:700}
.pm .shb button.rbtn:hover{background:#26593f}
.pm .shb a{white-space:nowrap}
/* スマホ：細いマスでは医院の札を小さく、1行に収める */
@media(max-width:899px){
  .cell .c.cb{align-self:stretch;justify-content:center;padding:1px 2px 2px!important;font-size:clamp(9.5px,2.7vw,12px)!important;border-radius:6px!important;gap:0 2px;white-space:nowrap;overflow:hidden}
  .cell .c.cb i{display:inline;font-size:9px!important}
  .cell.today .n::after{content:none}
}
/* 名前の一覧：院長には小さな「院長」の印 */
.namegrid button.dir{position:relative}
.namegrid button.dir::after{content:"院長";position:absolute;top:2px;right:5px;font-size:9.5px;font-weight:700;color:var(--accent);letter-spacing:0}
.namegrid button.dir.on::after{color:#fff}
.whopk .ordn{margin:8px 2px 0;font-size:12px;color:var(--mute2)}

/* ---- 希望（休み希望・出勤希望） ---- */
/* 上のタブは4つになったので、左の「シフトPortal」と右の共有・月の間に収める（真ん中に置くと右のボタンに重なっていた。2026-10-29） */
@media(min-width:1100px){
  nav{left:var(--navl,220px);right:var(--navr,430px);transform:none;display:flex;justify-content:center}
  nav .in{width:100%;max-width:600px}
}
.rqhead{display:flex;flex-wrap:wrap;align-items:center;gap:8px 12px;margin:2px 0 10px}
.rqdl{font-size:13px;font-weight:700;color:var(--accent)}
.rqban{background:var(--soft);border-left:3px solid var(--accent);padding:8px 12px;margin:0 0 10px;font-size:13.5px;color:var(--ink);line-height:1.6}
.rqban.done{border-left-color:#d9a400;background:#fff8e0}
.rqpen{margin:0 0 10px;width:max-content}
.rqpen button{height:38px;padding:0 18px;font-size:14px}
.rqpen button[data-pen="off"].on{background:#b3412f;color:#fff}
.rqpen button[data-pen="on"].on{background:#2f6b4d;color:#fff}
.rqcal{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));border-top:1px solid var(--line);margin-bottom:10px}
.rqcal .h{text-align:center;font-size:12px;font-weight:700;color:var(--mute);padding:4px 0}
.rqcal .h.sun{color:var(--sun)}.rqcal .h.sat{color:var(--sat)}
.rqc{min-height:64px;min-width:0;border:0;border-bottom:1px solid var(--line);border-right:1px solid var(--line);background:#fff;padding:4px 5px;display:flex;flex-direction:column;align-items:center;gap:3px;font:inherit;color:var(--ink)}
.rqc.empty{background:transparent;border-right-color:transparent}
.rqc .rd{align-self:flex-start;font-size:14px;font-weight:700}
.rqc.sun .rd{color:var(--sun)}.rqc.sat .rd{color:var(--sat)}
.rqc.tap{cursor:pointer}
.rqc.tap:hover{background:var(--soft)}
.rqc.tap.off{background:#fbecea}.rqc.tap.on{background:#e6f2ea}
.rq{display:inline-flex;align-items:baseline;gap:3px;border-radius:999px;padding:1px 9px;font-size:12.5px;font-weight:700}
.rq small{font-size:10.5px}
.rq.off{background:#f6d9d4;color:#8f2f20}
.rq.on{background:#d3eadb;color:#1f5a3c}
.rqn{font-size:12px;font-weight:700;line-height:1.35;white-space:nowrap}
.rqn.off{color:#a3392a}.rqn.on{color:#1f6b45}
.rqn small{font-size:10px;margin-left:2px;color:var(--mute)}
.rqrow{display:flex;gap:8px;align-items:center;margin:6px 0}
.rqrow input{flex:1;min-width:0;height:40px;border:1px solid var(--line2);border-radius:8px;padding:0 10px}
.rqrow .rbtn{height:40px;padding:0 20px;font-size:14px}
.rqnote{font-size:12px;color:var(--mute2);margin:4px 2px}
.rqsum{font-size:13px;color:var(--ink);line-height:1.9}
.rqsum .rq{margin-right:4px}
.rqnot{font-size:12.5px;color:var(--mute)}
.rqkey{max-width:460px}
.rqkey p{font-size:13px;color:var(--mute)}
.rqadm{margin:14px 0 0;text-align:right}
.rqadm button{border:0;background:none;color:var(--mute2);font-size:11.5px;text-decoration:underline;cursor:pointer}
@media(max-width:600px){ .rqc{min-height:52px;padding:3px 2px} .rq{padding:0 5px;font-size:11px} .rqn{font-size:10.5px} .rqhead .seg button{padding:0 9px} }
body.rqv .mon,body.rqv #prt,body.rqv #shr{display:none!important}
@media(max-width:600px){ .rq{flex-direction:column;align-items:center;gap:0;line-height:1.15;border-radius:8px;padding:1px 4px} .rq small{font-size:9.5px} }
.rqadm{display:flex;flex-wrap:wrap;justify-content:flex-end;align-items:center;gap:4px 12px;font-size:11.5px;color:var(--mute2)}
/* 全体表：希望の印（休希・出希）と、休み希望の日に出勤が入っているセル */
.rqm{display:inline-block;font-style:normal;font-size:9.5px;font-weight:700;line-height:14px;border-radius:4px;padding:0 3px;margin-left:2px;vertical-align:middle;white-space:nowrap}
.rqm.off{background:#f6d9d4;color:#8f2f20}
.rqm.on{background:#d3eadb;color:#1f5a3c}
.tw td.rqx{box-shadow:inset 0 0 0 2px #d9534f}
/* 表のセルは狭いので、希望の印は右下の小さな札に */
.tw td.e{position:relative}
.tw td .rqm{position:absolute;right:1px;bottom:1px;margin:0;font-size:8.5px;line-height:11px;padding:0 2px;border-radius:3px;opacity:.95}
.tw td.e:not(:has(.chip,.leave)) .rqm{position:static;font-size:9.5px;line-height:14px;padding:0 3px}
.tw td .rqm{top:0;right:0;bottom:auto;font-size:8px;line-height:10px;padding:0 2px;border-radius:0 0 0 4px}
.rqwho{display:flex;align-items:center;gap:10px;margin:0 0 8px;font-size:16px;color:var(--ink)}
.rqwho button{border:1px solid var(--line2);background:#fff;border-radius:8px;height:30px;padding:0 12px;font-size:12.5px;font-weight:600;color:var(--mute);cursor:pointer}
.namegrid button.on{background:var(--accent);border-color:var(--accent);color:#fff}
/* PC：右の共有・印刷・月が出たり消えたりしても、上のタブが左右に動かないように場所だけは取っておく（見えなくするだけ） */
@media(min-width:1100px){
  body:not(.share) header #shr[hidden],body.rqv:not(.share) header #shr,body.rqv:not(.share) header #prt{display:inline-block!important;visibility:hidden}
  body.rqv:not(.share) header .mon{display:flex!important;visibility:hidden}
}
/* PC：全体表を1画面に（app.js の fitTable が行の高さ --rh などを決める。2026-10-29） */
.tw.fit{max-height:none!important;overflow-y:hidden}
.tw.fit tbody th,.tw.fit tbody td{height:var(--rh)!important;padding-top:0!important;padding-bottom:0!important;line-height:1}
.tw.fit tbody th.dt{font-size:min(var(--cf),15px)}
.tw.fit td .chip{line-height:var(--ch)!important;font-size:var(--cf)!important;vertical-align:middle}
.tw.fit td .leave{font-size:var(--lf)!important}
.tw.fit .nb{height:var(--ch)!important;font-size:var(--cf)!important}
/* 私のシフト：「他の先生を隠す」ボタン（押すと一緒に入る先生の名前を出さない。2026-10-29） */
.mtg{flex:none;border:1px solid var(--line2);border-radius:8px;background:var(--surface);height:40px;padding:0 11px;font-size:12px;font-weight:600;color:var(--mute);cursor:pointer;white-space:nowrap}
.mtg.on{background:var(--accent-soft);color:var(--accent);border-color:var(--accent)}
@media(max-width:899px){ .mtg{height:36px;padding:0 8px;font-size:11.5px} }
@media(min-width:900px){ .me2 .toprow{flex-basis:560px} }
/* 医院ごと：見出しの医院名を、医院の色の大きな札に（2026-10-29） */
.clhd h2{display:flex;align-items:center;gap:12px;margin:0}
.clhd .clnm{display:inline-flex;align-items:center;font-size:22px;font-weight:800;letter-spacing:.04em;line-height:1;padding:9px 18px;border-radius:10px;box-shadow:0 1px 0 rgba(0,0,0,.08)}
.clhd .clsub{font-size:15px;font-weight:700;color:var(--mute)}
@media(max-width:899px){ .clhd .clnm{font-size:18px;padding:7px 14px} .clhd .clsub{font-size:13px} }
/* 医院ごと：左の医院ボタンも、選んでいる医院は医院の色を薄く塗って目立たせる */
.chips.hs button.cb.sel{background:color-mix(in srgb,var(--c) 22%,#fff)!important;border-color:var(--c)!important;box-shadow:inset 4px 0 0 var(--c)!important;font-weight:800}
/* 希望：締め切った月は「過去の希望」として受付中の月の後ろに（色を控えめに） */
.rqpast{display:flex;align-items:center;gap:6px}
.rqpast>span{font-size:12px;font-weight:700;color:var(--mute2)}
.rqpast .seg button:not(.on){color:var(--mute2)}
/* 管理：締め切る／再開する（事務が押すボタンなので、下線の文字より少しはっきり） */
.rqadm button.strong{text-decoration:none;border:1px solid var(--line,#d9d9d9);border-radius:8px;padding:5px 10px;color:var(--ink,#333);font-weight:700;background:#fff}
