:root{
  --bg:#f3f6fb; --card:#fff; --ink:#1f2a44; --sub:#6b7793;
  --brand:#2f6df0; --brand-d:#1d4fc4; --accent:#16a34a;
  --warn:#b45309; --danger:#dc2626; --line:#e3e8f2; --radius:16px;
}
*{box-sizing:border-box}
html,body{margin:0;padding:0}
body{
  font-family:-apple-system,"Hiragino Kaku Gothic ProN","Noto Sans JP",Meiryo,sans-serif;
  background:var(--bg); color:var(--ink); line-height:1.6;
  -webkit-text-size-adjust:100%;
}
.wrap{max-width:560px;margin:0 auto;padding:16px 14px 60px}
.wrap.wide{max-width:1000px}
header.app{
  background:linear-gradient(135deg,var(--brand),var(--brand-d));
  color:#fff;padding:20px 16px;border-radius:0 0 var(--radius) var(--radius);
  text-align:center;box-shadow:0 6px 20px rgba(47,109,240,.25)
}
header.app h1{margin:0;font-size:20px;letter-spacing:.5px}
header.app p{margin:4px 0 0;font-size:13px;opacity:.9}
.card{background:var(--card);border:1px solid var(--line);border-radius:var(--radius);
  padding:16px;margin-top:16px;box-shadow:0 2px 10px rgba(31,42,68,.04)}
.card h2{font-size:15px;margin:0 0 12px;color:var(--brand-d);display:flex;align-items:center;gap:8px}
.card h2 .n{background:var(--brand);color:#fff;width:22px;height:22px;border-radius:50%;
  display:inline-flex;align-items:center;justify-content:center;font-size:13px;flex:0 0 auto}
label.fld{display:block;font-size:13px;font-weight:600;color:var(--sub);margin:12px 0 5px}
label.fld .req{color:var(--danger);font-size:11px;margin-left:4px}
select,input[type=text],input[type=date],input[type=password],textarea{
  width:100%;padding:11px 12px;border:1.5px solid var(--line);border-radius:12px;
  font-size:16px;background:#fff;color:var(--ink);font-family:inherit}
select:focus,input:focus,textarea:focus{outline:none;border-color:var(--brand)}
textarea{min-height:78px;resize:vertical}
/* 日付入力：他の入力欄と同じ高さ・左寄せに揃える（appearance:noneはAndroidでタップ不可になるため使わない） */
/* iOSは日付枠が内部最小幅で縮まず右にはみ出すので min-width:0 で親幅まで縮める */
input[type=date]{text-align:left;min-width:0;max-width:100%}
input[type=date]::-webkit-date-and-time-value{text-align:left}
.btn{display:block;width:100%;border:none;border-radius:14px;padding:15px;font-size:16px;
  font-weight:700;cursor:pointer;margin-top:18px;transition:.15s}
.btn.primary{background:var(--brand);color:#fff}
.btn.primary:hover{background:var(--brand-d)}
.btn.primary:disabled{background:#aab6cf;cursor:not-allowed}
.btn.ghost{background:#eef2fb;color:var(--brand-d)}
.hint{font-size:12px;color:var(--sub);margin-top:6px}
.notice{background:#fff7ed;border:1px solid #fed7aa;color:var(--warn);
  padding:10px 12px;border-radius:12px;font-size:13px;margin-top:10px}
/* 保護者トップ：振替はLINEで（強調） */
.line-notice{background:#06c755;color:#fff;
  border-radius:14px;padding:13px 14px;margin-top:4px;box-shadow:0 6px 16px rgba(6,199,85,.32)}
.line-notice b{display:block;font-size:15px;line-height:1.45;white-space:nowrap}
.line-notice span{font-size:12.5px;opacity:.95}
.pin-help{background:#eff5ff;border:1px solid #cfe0ff;border-radius:12px;
  padding:11px 13px;margin-top:8px;font-size:13px;color:var(--ink);line-height:1.6}
.pin-help-t{font-weight:800;color:var(--brand-d);margin-bottom:4px;font-size:13.5px}
.pin-help p{margin:0 0 6px}
.pin-help ul{margin:0;padding-left:18px}
.pin-help li{margin:3px 0}
.pin-help strong{color:var(--brand-d)}
.sendsplit{display:flex;align-items:center;gap:6px;flex-wrap:wrap;margin:2px 0 12px}
.sendsplit .ss-label{font-size:13px;color:var(--sub);font-weight:700}
.ss-btn{border:1.5px solid var(--line);background:#fff;color:var(--ink);
  border-radius:999px;padding:7px 14px;font-size:13px;font-weight:700;cursor:pointer}
.ss-btn.active{background:var(--brand);border-color:var(--brand);color:#fff}
.send-section{margin-top:16px}
.send-section-h{display:inline-flex;align-items:center;gap:8px;font-size:15px;font-weight:800;
  padding:7px 13px;border-radius:10px}
.send-section-h .c{font-size:13px;font-weight:700;opacity:.85}
.send-section-d{font-size:12px;color:var(--sub);margin:5px 0 9px}
.sec-todo .send-section-h{background:#fff1f0;color:#c0341d;border:1px solid #ffb3a8}
.sec-wait .send-section-h{background:#fffbeb;color:#92600e;border:1px solid #fcd96b}
.sec-set  .send-section-h{background:#eafaf0;color:#15803d;border:1px solid #9be0b4}
.sec-none .send-section-h{background:#f3f5f9;color:#6b7793;border:1px solid #e3e8f2}
.sec-todo{border-left:4px solid #ef4444;padding-left:10px}
.sec-wait{border-left:4px solid #f59e0b;padding-left:10px}
.sec-set{border-left:4px solid #22c55e;padding-left:10px}
.sec-none{border-left:4px solid #cbd5e1;padding-left:10px}
.send-section .empty-mini{font-size:13px;color:var(--sub);padding:2px 4px 8px}
/* 名前検索：状態チップ（アラート風） */
#searchState{display:flex;gap:7px;flex-wrap:wrap;margin:0 0 12px}
#searchState:empty{display:none}
.state-chip{font-size:13.5px;font-weight:800;border-radius:999px;padding:7px 13px}
.state-chip.sec-todo{background:#fff1f0;color:#c0341d;border:1px solid #ffb3a8}
.state-chip.sec-wait{background:#fffbeb;color:#92600e;border:1px solid #fcd96b}
.state-chip.sec-set{background:#eafaf0;color:#15803d;border:1px solid #9be0b4}
.state-chip.sec-none{background:#f3f5f9;color:#6b7793;border:1px solid #e3e8f2}
/* 生徒カード内の1件（縦並びで崩れない） */
.sc-badges{display:flex;gap:6px;flex-wrap:wrap;align-items:center}
.abs-row{border-top:1px solid var(--line);padding:10px 2px 4px;margin-top:8px}
.abs-row:first-of-type{border-top:none}
.abs-head{display:flex;justify-content:space-between;align-items:flex-start;gap:10px;flex-wrap:wrap}
.abs-date{font-size:14px}
.abs-sub{font-size:13px;margin:5px 0;overflow-wrap:anywhere;word-break:break-word}
.abs-actions{margin-top:6px}
.cell-reason{overflow-wrap:anywhere;word-break:break-word}
/* コンパクト一覧（日付＋名前＋状態／タップで詳細展開） */
.lgroup{margin:10px 0}
.lgroup-h{font-size:13px;font-weight:800;color:var(--ink);padding:2px 2px 4px;display:flex;align-items:center;flex-wrap:wrap;gap:4px}
.lgroup-h .lg-name{font-size:15px}
.lrow{display:flex;align-items:center;gap:10px;padding:12px 12px;border:1px solid var(--line);
  border-radius:12px;margin:7px 0;cursor:pointer;background:#fff;-webkit-tap-highlight-color:transparent}
.lrow:hover{background:#f7f9fd}
.lrow.open{border-bottom-left-radius:0;border-bottom-right-radius:0;margin-bottom:0;background:#f7f9fd}
.lrow-todo{border-left:5px solid #ef4444}
.lrow-wait{border-left:5px solid #f59e0b}
.lrow-set{border-left:5px solid #22c55e}
.lrow-none{border-left:5px solid #cbd5e1}
.lr-date{font-weight:800;font-size:15px;flex:0 0 auto;min-width:58px;line-height:1.15}
.lr-date small{display:block;font-weight:600;color:var(--sub);font-size:11px}
.lr-name{font-weight:700;font-size:15px;flex:1 1 auto;min-width:0;overflow-wrap:anywhere;line-height:1.3}
.lr-meta{font-weight:600;font-size:12px;color:var(--sub)}
.lr-tag{flex:0 0 auto;font-size:12px;font-weight:800;border-radius:999px;padding:5px 11px;white-space:nowrap}
.lr-tag.sec-todo{background:#fff1f0;color:#c0341d;border:1px solid #ffb3a8}
.lr-tag.sec-wait{background:#fffbeb;color:#92600e;border:1px solid #fcd96b}
.lr-tag.sec-set{background:#eafaf0;color:#15803d;border:1px solid #9be0b4}
.lr-tag.sec-none{background:#f3f5f9;color:#6b7793;border:1px solid #e3e8f2}
.lr-caret{flex:0 0 auto;color:var(--sub);font-weight:800;transition:transform .15s}
.lrow.open .lr-caret{transform:rotate(180deg)}
.ldetail{border:1px solid var(--line);border-top:none;border-radius:0 0 12px 12px;
  margin:0 0 9px;padding:12px;background:#fcfdff}
/* やりとり（チャット）共通 */
.thread{margin-top:10px;border-top:1px dashed var(--line);padding-top:8px}
.thread-h{font-size:12px;font-weight:700;color:var(--sub);margin:0 0 5px}
.tm{display:flex;flex-direction:column;max-width:90%;border-radius:12px;padding:7px 11px;margin:5px 0;
  font-size:13px;line-height:1.55;overflow-wrap:anywhere;word-break:break-word}
.tm-meta{font-size:10.5px;opacity:.85;margin-bottom:2px}
.tm-who{font-weight:800}
.tm-text{white-space:pre-wrap}
.tm-staff{background:#e7efff;border:1px solid #cfe0ff;color:#1d4fc4;margin-right:auto}
.tm-parent{background:#eafaf0;border:1px solid #c3edd2;color:#15803d;margin-left:auto}
/* メッセージ送信欄 */
.msgbox{display:flex;gap:7px;margin-top:8px}
.msg-in{flex:1;min-width:0;padding:9px 11px;border:1.5px solid var(--line);border-radius:10px;font-size:14px;font-family:inherit}
.msg-send{flex:0 0 auto;border:none;background:var(--brand);color:#fff;font-weight:800;
  border-radius:10px;padding:9px 16px;font-size:14px;cursor:pointer;font-family:inherit}
.msg-send:disabled{opacity:.6}
.msgbox-staff .msg-send{background:#06914a}
/* 新着アラート（LINE風） */
.newalert{position:sticky;top:6px;z-index:40;display:flex;align-items:center;gap:10px;flex-wrap:wrap;
  background:#06c755;color:#fff;border-radius:12px;padding:11px 14px;margin:8px 0;box-shadow:0 6px 18px rgba(6,199,85,.35)}
.newalert b{font-size:15px}
.newalert .na-list{font-size:13px;opacity:.95;font-weight:600;flex:1 1 200px;min-width:0}
.newalert .na-btn{border:none;background:#fff;color:#06914a;font-weight:800;border-radius:9px;padding:8px 14px;cursor:pointer;font-family:inherit}
.newalert .na-btn.ghost{background:rgba(255,255,255,.22);color:#fff}
.newalert .na-dot{width:11px;height:11px;border-radius:50%;background:#fff;animation:napulse 1.2s infinite;flex:0 0 auto}
@keyframes napulse{0%,100%{opacity:1}50%{opacity:.25}}
/* 最初のメニュー（3つの入口） */
.menu-lead{font-size:15px;font-weight:700;color:var(--ink);text-align:center;margin:10px 0 16px}
.menu-btn{display:flex;align-items:center;gap:14px;width:100%;text-decoration:none;
  border:none;cursor:pointer;text-align:left;border-radius:16px;padding:18px;margin-bottom:13px;
  color:#fff;box-shadow:0 4px 14px rgba(31,42,68,.16);font-family:inherit}
.menu-btn:active{transform:translateY(1px)}
.menu-btn .ic{font-size:30px;line-height:1;flex:0 0 auto}
.menu-btn .tx{display:flex;flex-direction:column;gap:3px}
.menu-btn .tt{font-size:19px;font-weight:800}
.menu-btn .sb{font-size:12.5px;font-weight:600;opacity:.92}
.menu-btn .ar{margin-left:auto;font-size:20px;font-weight:800;opacity:.9}
.menu-btn.m-absence{background:linear-gradient(135deg,#2f6df0,#1d4fc4)}
.menu-btn.m-makeup{background:linear-gradient(135deg,#f5576c,#dc2626)}
.menu-btn.m-tel{background:linear-gradient(135deg,#22c55e,#16a34a)}
.backlink{background:none;border:none;color:var(--brand);font-size:14px;font-weight:700;
  padding:6px 2px;margin:2px 0 6px;cursor:pointer;font-family:inherit}
.errbar{background:#fee2e2;border:1.5px solid #fecaca;color:#dc2626;font-weight:700;
  padding:12px 14px;border-radius:12px;font-size:14px;margin-top:14px}
.chips{display:flex;gap:8px;flex-wrap:wrap;margin-top:4px}
.chip{display:inline-flex;align-items:center;gap:6px;background:#eef2fb;border:1.5px solid #cfe0fb;
  color:var(--brand-d);border-radius:999px;padding:9px 14px;font-size:14px;font-weight:700;cursor:pointer;font-family:inherit}
.chip:hover{background:#dbe7fd}
.chip .x{color:#9aa7c2;font-weight:700;font-size:13px;padding:0 2px}
.savedbox{background:#f7f9fd;border:1px dashed #cfe0fb;border-radius:12px;padding:10px 12px;margin-bottom:6px}
.savedlist{display:flex;flex-direction:column;gap:8px;margin-top:4px}
.saved-item{display:flex;gap:8px;align-items:stretch}
.saved-pick{flex:1;text-align:left;background:#eef2fb;border:1.5px solid #cfe0fb;border-radius:12px;
  padding:13px 14px;font-size:17px;font-weight:800;color:var(--brand-d);cursor:pointer;font-family:inherit;line-height:1.3}
.saved-pick:active{background:#dbe7fd}
.saved-pick .saved-sub{display:block;font-size:12px;color:var(--sub);font-weight:600;margin-top:2px}
.saved-del{flex:0 0 auto;background:#fff;border:1.5px solid #f1c4c4;color:#dc2626;border-radius:12px;
  padding:0 16px;font-size:13px;font-weight:700;cursor:pointer;font-family:inherit}
/* iOS風 時間ホイール */
.wheel{position:relative;display:flex;align-items:stretch;justify-content:center;gap:10px;height:200px;
  background:#f7f9fd;border:1.5px solid var(--line);border-radius:14px;overflow:hidden;margin-top:6px;
  -webkit-mask-image:linear-gradient(180deg,transparent,#000 26%,#000 74%,transparent);
  mask-image:linear-gradient(180deg,transparent,#000 26%,#000 74%,transparent)}
.wheel-col{height:200px;overflow-y:scroll;scroll-snap-type:y mandatory;flex:0 0 92px;text-align:center;
  scrollbar-width:none;-ms-overflow-style:none;overscroll-behavior:contain;-webkit-overflow-scrolling:touch}
.wheel-col::-webkit-scrollbar{display:none}
.wheel-col .it{height:40px;line-height:40px;scroll-snap-align:center;font-size:28px;color:#9aa7c2;
  font-variant-numeric:tabular-nums}
.wheel-col .it.sel{color:var(--brand-d);font-weight:800}
.wheel-col .pad{height:80px}
.wheel-sep{align-self:center;font-size:28px;font-weight:800;color:var(--ink)}
.wheel-center{position:absolute;left:10px;right:10px;top:80px;height:40px;background:rgba(47,109,240,.10);
  border-top:1.5px solid #cfe0fb;border-bottom:1.5px solid #cfe0fb;border-radius:8px;pointer-events:none}
/* calendar */
.cal-head{display:flex;align-items:center;justify-content:space-between;margin-bottom:8px}
.cal-head button{background:#eef2fb;border:none;border-radius:10px;width:38px;height:38px;
  font-size:18px;cursor:pointer;color:var(--brand-d)}
.cal-head .mlabel{font-weight:700;font-size:15px}
.cal{display:grid;grid-template-columns:repeat(7,1fr);gap:4px}
.cal .dow{text-align:center;font-size:11px;color:var(--sub);padding:4px 0;font-weight:600}
.cal .day{aspect-ratio:1;display:flex;align-items:center;justify-content:center;border-radius:10px;
  font-size:15px;cursor:pointer;border:1.5px solid transparent;background:#f7f9fd}
.cal .day.empty{background:transparent;cursor:default}
.cal .day.past{color:#c2c9d8;background:#f2f3f6;cursor:not-allowed}
.cal .day.today{border-color:var(--brand)}
.cal .day.sel{background:var(--brand);color:#fff;font-weight:700}
.cal .day.sun{color:var(--danger)}
.cal .day.sat{color:var(--brand-d)}
.cal .day.sel.sun,.cal .day.sel.sat{color:#fff}
.selbar{margin-top:10px;font-size:14px;font-weight:700;text-align:center;color:var(--brand-d)}
/* result */
.result{text-align:center;padding:24px 8px}
.result .ok{font-size:52px}
.result h2{margin:8px 0;font-size:19px}
.result .detail{background:#f7f9fd;border-radius:12px;padding:14px;text-align:left;font-size:14px;margin:14px 0}
.result .detail div{margin:3px 0}
.result.err .ok{color:var(--danger)}
.row{display:flex;gap:8px;flex-wrap:wrap}
.row>*{flex:1}
/* 講師画面のタブ（スマホで折り返してもラベルが壊れない） */
.tabbar{display:flex;gap:6px;flex-wrap:wrap;margin-top:8px}
.tabbar .btn{width:auto;flex:1 1 auto;white-space:nowrap;margin:0;padding:11px 12px;font-size:15px}
.tabbar .btn.logout{flex:0 0 auto;background:#f0f2f7;color:var(--sub)}
@media(max-width:440px){ .tabbar .btn{font-size:13px;padding:10px 9px} }
.links{text-align:center;margin-top:18px;font-size:13px}
.links a{color:var(--sub);text-decoration:none;margin:0 8px}
/* board / admin tables */
table{width:100%;border-collapse:collapse;font-size:14px}
th,td{padding:9px 8px;border-bottom:1px solid var(--line);text-align:left;vertical-align:top}
th{font-size:12px;color:var(--sub);background:#f7f9fd;position:sticky;top:0}
.tag{display:inline-block;padding:2px 9px;border-radius:999px;font-size:11px;font-weight:700}
.tag.pending{background:#fef3c7;color:#92600e}
.tag.none{background:#eef0f4;color:#6b7793}
.tag.requested{background:#fef3c7;color:#92600e}
.tag.proposed{background:#ede9fe;color:#6d28d9}
.tag.scheduled{background:#dbeafe;color:#1d4fc4}
.tag.done{background:#dcfce7;color:#15803d}
.slot{display:inline-block;background:#eef2fb;color:var(--brand-d);padding:2px 8px;border-radius:8px;font-size:12px;font-weight:700}
.muted{color:var(--sub)}
.toolbar{display:flex;gap:8px;flex-wrap:wrap;align-items:end;margin-bottom:12px}
.toolbar .fld-inline{flex:1;min-width:120px}
/* 履歴の検索：氏名は1行フル幅、期間＋検索は別の行 */
.hsearch-name{margin-bottom:12px}
.hsearch-name input{width:100%;padding:13px 14px;font-size:16px;border:1.5px solid var(--line);border-radius:12px;font-family:inherit}
.hsearch-period{display:flex;gap:10px;align-items:flex-end;flex-wrap:wrap}
.hsearch-period .fld-inline{flex:1 1 130px;min-width:0}
.hsearch-period .fld-inline input{width:100%;min-width:0;max-width:100%;padding:11px;font-size:15px;border:1.5px solid var(--line);border-radius:10px;font-family:inherit}
.hsearch-period .btn{flex:0 0 auto;width:auto;margin:0;padding:12px 20px}
.bigclock{font-size:13px;color:var(--sub);text-align:center;margin-top:4px}
.empty-state{text-align:center;color:var(--sub);padding:30px 10px;font-size:14px}
.iconbtn{background:#eef2fb;border:none;border-radius:8px;padding:5px 9px;cursor:pointer;font-size:12px;color:var(--brand-d);font-weight:600}
.minilabel{font-size:11px;color:var(--sub);font-weight:700;margin-bottom:2px}
.iconbtn.danger{background:#fee2e2;color:var(--danger)}
.studentcard{border:1px solid var(--line);border-radius:14px;padding:12px;margin-bottom:12px;background:#fff}
.studentcard .sc-head{display:flex;justify-content:space-between;align-items:center;margin-bottom:8px}
.studentcard .sc-name{font-weight:700;font-size:16px}
.studentcard .sc-meta{font-size:12px;color:var(--sub)}
.count-badge{background:var(--brand);color:#fff;border-radius:999px;padding:2px 10px;font-size:12px;font-weight:700}

/* ===== シンプル版 講師画面 ===== */
.tcard{border:1px solid var(--line);border-left:5px solid var(--brand);border-radius:12px;padding:11px 12px;margin:8px 0;background:#fff}
.tc-top{display:flex;align-items:baseline;gap:10px;flex-wrap:wrap}
.tc-slot{font-weight:800;font-size:14px;color:var(--brand-d);flex:0 0 auto}
.tc-name{font-weight:700;font-size:15px;flex:1 1 auto;min-width:0;overflow-wrap:anywhere}
.tc-subj{flex:0 0 auto;font-weight:700;background:#eef3ff;color:#1d4fc4;border-radius:8px;padding:3px 9px;font-size:13px}
.tc-reason{font-size:13px;color:var(--sub);margin:5px 0 8px;overflow-wrap:anywhere}
.tc-bottom{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-top:6px}
.tc-bottom .tc-reason{margin:0;flex:1 1 auto;min-width:0}
.tc-teacher{display:flex;align-items:center;gap:8px;flex-wrap:wrap;background:#f7f9fd;border-radius:10px;padding:8px 10px}
.tc-teacher label{font-size:12px;font-weight:700;color:var(--sub);flex:0 0 auto}
.tc-teacher input{flex:1 1 140px;min-width:0;padding:8px 10px;border:1.5px solid var(--line);border-radius:9px;font-size:14px;font-family:inherit}
.tc-auto{font-size:11px;font-weight:700;color:#15803d;background:#eafaf0;border:1px solid #c3edd2;border-radius:999px;padding:2px 8px;flex:0 0 auto}
.tc-del{flex:0 0 auto;border:none;background:#fee2e2;color:#dc2626;font-weight:700;border-radius:8px;padding:7px 11px;font-size:12px;cursor:pointer;font-family:inherit}
/* 生徒別履歴 */
.count-badge.big{font-size:14px;padding:5px 12px}
.hstu{border:1px solid var(--line);border-radius:12px;margin:8px 0;overflow:hidden}
.hstu-h{display:flex;align-items:center;gap:10px;padding:12px;cursor:pointer;background:#fff}
.hstu-h:hover{background:#f7f9fd}
.hstu-name{font-weight:800;font-size:16px;flex:1 1 auto;min-width:0;overflow-wrap:anywhere}
.hstu-body{padding:4px 12px 10px;background:#fcfdff;border-top:1px solid var(--line)}
.habs{padding:9px 0;border-bottom:1px dashed var(--line)}
.habs:last-child{border-bottom:none}
.habs-row{display:flex;align-items:center;gap:10px;flex-wrap:wrap}
.habs-date{font-weight:800;font-size:14px;flex:0 0 auto;min-width:52px;line-height:1.15}
.habs-date small{display:block;font-weight:600;color:var(--sub);font-size:11px}
.habs-main{flex:1 1 200px;min-width:0;font-size:13px;overflow-wrap:anywhere}
/* 振替済みチェック */
.mkbox{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin-top:6px;background:#f7f9fd;border-radius:10px;padding:8px 10px}
.mk-label{font-size:12.5px;color:var(--sub);font-weight:700}
.mk-btn{width:100%;border:1.5px solid #9be0b4;background:#eafaf0;color:#15803d;font-weight:800;
  border-radius:10px;padding:11px 14px;font-size:14px;cursor:pointer;font-family:inherit}
.mk-btn:hover{background:#dcf5e5}
.mk-modal-date,.mk-modal-teacher,.mk-modal-sel{display:block;width:100%;max-width:100%;min-width:0;padding:13px 14px;
  font-size:16px;border:1.5px solid var(--line);border-radius:12px;font-family:inherit;background:#fff}
.mk-done{font-size:14px;font-weight:800;color:#15803d}
.mk-undo{border:none;background:#eef2fb;color:var(--sub);font-weight:700;border-radius:8px;padding:6px 12px;font-size:12px;cursor:pointer;font-family:inherit}
/* 振替日決定（予定）の表示＋完了ボタン */
.mk-sched{width:100%;font-size:14px;font-weight:700;color:#92600e;background:#fffbeb;border:1px solid #fcd96b;border-radius:8px;padding:7px 11px}
.mk-done-btn{border:none;background:#22c55e;color:#fff;font-weight:800;border-radius:10px;padding:10px 16px;font-size:14px;cursor:pointer;font-family:inherit}
.mk-done-btn:hover{background:#16a34a}
.tcard.is-sched{border-left-color:#f59e0b;background:#fffdf5}
.tcard.is-done{border-left-color:#22c55e;background:#f6fdf9}
.habs.is-done .mkbox{background:#eafaf0}
.mk-badge{font-size:12px;font-weight:800;border-radius:999px;padding:4px 10px;flex:0 0 auto}
.mk-badge.undone{background:#fff1f0;color:#c0341d;border:1px solid #ffb3a8}
.mk-badge.alldone{background:#eafaf0;color:#15803d;border:1px solid #9be0b4}
/* 新着の欠席連絡アラート（LINE風・赤） */
.newabs{position:sticky;top:6px;z-index:40;display:flex;align-items:center;gap:10px;flex-wrap:wrap;
  background:#dc2626;color:#fff;border-radius:12px;padding:11px 14px;margin:8px 0;box-shadow:0 6px 18px rgba(220,38,38,.35)}
.newabs b{font-size:15px}
.newabs .na-list{font-size:13px;opacity:.95;font-weight:600;flex:1 1 200px;min-width:0}
.newabs .na-btn{border:none;background:#fff;color:#c0341d;font-weight:800;border-radius:9px;padding:8px 14px;cursor:pointer;font-family:inherit}
.newabs .na-btn.ghost{background:rgba(255,255,255,.22);color:#fff}
.newabs .na-dot{width:11px;height:11px;border-radius:50%;background:#fff;animation:napulse 1.2s infinite;flex:0 0 auto}
@keyframes napulse{0%,100%{opacity:1}50%{opacity:.25}}
/* 新着一覧モーダルの行 */
.newrow{display:flex;align-items:center;gap:12px;padding:12px 10px;border:1px solid var(--line);border-left:5px solid #dc2626;
  border-radius:12px;margin:8px 0;cursor:pointer;background:#fff}
.newrow:hover{background:#fff5f5}
.nr-date{flex:0 0 auto;min-width:52px;font-size:16px;font-weight:800;line-height:1.15;text-align:center}
.nr-date small{display:block;font-size:11px;font-weight:600;color:var(--sub)}
.nr-main{flex:1 1 auto;min-width:0;overflow-wrap:anywhere}
.nr-name{font-weight:800;font-size:16px}
.nr-sub{font-size:13px;margin-top:3px}
.nr-go{flex:0 0 auto;color:#c0341d;font-weight:800;font-size:14px}
/* 月ごと一覧 */
.month-nav{display:flex;align-items:center;justify-content:space-between;gap:8px}
.month-label{font-size:18px;font-weight:800;color:var(--brand-d)}
.month-nav .iconbtn{flex:0 0 auto;padding:9px 12px;white-space:nowrap}
.tcard.not-lined{border-left-color:#f59e0b}
/* LINEで連絡済み */
.linebox{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin-top:6px}
.line-btn{width:100%;border:1.5px solid #cfe0ff;background:#eef3ff;color:#1d4fc4;font-weight:800;
  border-radius:10px;padding:10px 14px;font-size:14px;cursor:pointer;font-family:inherit}
.line-btn:hover{background:#e0eaff}
.line-done{font-size:14px;font-weight:800;color:#1d4fc4;background:#eef3ff;border:1px solid #cfe0ff;border-radius:999px;padding:5px 12px}
/* 備考 */
.notebox{margin-top:6px}
.notebox label{font-size:12px;font-weight:700;color:var(--sub);display:block;margin-bottom:3px}
.notebox input{width:100%;padding:9px 11px;border:1.5px solid var(--line);border-radius:9px;font-size:14px;font-family:inherit}
.habs-teacher{flex:0 0 auto;font-size:12px;color:var(--sub);display:flex;align-items:center;gap:5px}
.habs-teacher input{padding:6px 9px;border:1.5px solid var(--line);border-radius:8px;font-size:13px;font-family:inherit;width:120px}
