:root{--bg:#f5f7fb;--panel:#fff;--text:#1f2937;--muted:#6b7280;--line:#e5e7eb;--blue:#2563eb;--blue-soft:#eff6ff;--green:#047857;--green-soft:#ecfdf5;--red:#b91c1c;--red-soft:#fef2f2;--amber:#92400e;--amber-soft:#fef3c7;--gray-soft:#f3f4f6}
.line-binding-request{display:grid;grid-template-columns:minmax(180px,1fr) minmax(160px,1fr) auto;align-items:center;gap:14px;padding:16px 0;border-top:1px solid #e0e6e1}.line-binding-request p{margin:6px 0;font-size:13px}.line-binding-request small{color:#69766f}.line-binding-request label{display:grid;gap:6px;font-size:13px}.line-binding-request select{padding:10px;border:1px solid #ccd8cf;border-radius:8px;min-height:42px;background:#fff}@media(max-width:700px){.line-binding-request{grid-template-columns:1fr}.line-binding-request .toolbar>button{flex:1}}
*{box-sizing:border-box}body{margin:0;font-family:system-ui,-apple-system,"Segoe UI","Noto Sans TC",sans-serif;color:var(--text);background:var(--bg)}button,input,select{font:inherit}.app-shell{min-height:100vh;display:grid;grid-template-columns:240px 1fr}.sidebar{background:#111827;color:#fff;padding:24px 16px}.brand{font-size:20px;font-weight:800}.brand-sub{font-size:12px;color:#9ca3af;margin:5px 0 24px}.nav-item{display:block;width:100%;border:0;background:transparent;color:#d1d5db;text-align:left;padding:11px 12px;border-radius:9px;margin:3px 0;cursor:pointer}.nav-item:hover,.nav-item.active{background:#1f2937;color:#fff}.main{padding:24px;overflow:hidden}.topbar{display:flex;justify-content:space-between;gap:16px;align-items:center;margin-bottom:18px}.topbar h1{margin:0;font-size:25px}.muted{color:var(--muted);font-size:12px}.page{display:none}.page.active{display:block}.card{background:var(--panel);border:1px solid var(--line);border-radius:14px;padding:17px;box-shadow:0 1px 3px rgba(0,0,0,.03);margin-bottom:16px}.stats-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:12px}.stat-label{color:var(--muted);font-size:12px}.stat-value{font-weight:800;font-size:30px;margin:5px 0}.small-value{font-size:19px}.pill{padding:7px 10px;background:var(--blue-soft);color:#1d4ed8;border-radius:999px;font-size:12px;font-weight:700}.section-head{display:flex;justify-content:space-between;gap:12px;align-items:center;margin-bottom:14px}.section-head h2,.section-head h3{margin:0}.btn{border:1px solid var(--line);background:#fff;padding:8px 11px;border-radius:8px;cursor:pointer;font-weight:700}.btn:hover{background:#f9fafb}.btn.primary{background:var(--blue);color:#fff;border-color:var(--blue)}.hidden{display:none!important}.flow{display:flex;flex-wrap:wrap;gap:8px;align-items:center}.flow span{padding:8px 10px;border:1px solid var(--line);border-radius:8px;background:#fff;font-size:12px;font-weight:700}.flow b{color:#9ca3af}.rule-list{margin:0;padding-left:20px;line-height:1.9}.form-card{padding:0;overflow:hidden}.form-card>.section-head{padding:16px 18px;margin:0;border-bottom:1px solid var(--line)}.form-section{padding:16px 18px;border-bottom:1px solid var(--line)}.form-section-title{font-size:13px;font-weight:800;margin-bottom:12px}.form-grid{display:grid;gap:12px}.cols-4{grid-template-columns:repeat(4,1fr)}.cols-3{grid-template-columns:repeat(3,1fr)}.cols-2{grid-template-columns:repeat(2,1fr)}.field>span{display:block;font-size:12px;color:#4b5563;font-weight:700;margin-bottom:6px}.field input,.field select{width:100%;border:1px solid #d1d5db;border-radius:8px;padding:8px 9px;background:#fff}.check-box,.skill-grid{border:1px solid var(--line);background:#f9fafb;border-radius:9px;padding:9px 10px}.check-box{display:flex;gap:18px;min-height:39px;align-items:center}.skill-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:7px}.range-scale{display:flex;justify-content:space-between;font-size:10px;color:#9ca3af}.form-actions{display:flex;justify-content:flex-end;gap:8px;padding:14px 18px}.table-wrap{overflow:auto}table{width:100%;border-collapse:collapse;font-size:12px}th,td{padding:10px 8px;border-bottom:1px solid var(--line);text-align:left;white-space:nowrap}th{background:#f9fafb;color:#4b5563}.tag{display:inline-block;padding:3px 7px;border-radius:999px;background:#eef2ff;color:#4338ca;font-weight:700}.tag.full{background:var(--green-soft);color:var(--green)}.row-actions{display:flex;gap:5px}.action{border:1px solid var(--line);border-radius:7px;background:#fff;padding:5px 8px;cursor:pointer;font-size:11px;font-weight:700}.action.edit{background:#eff6ff;color:#1d4ed8;border-color:#bfdbfe}.action.del{background:#fef2f2;color:#b91c1c;border-color:#fecaca}.two-col{display:grid;grid-template-columns:1fr 1fr;gap:14px}.requirement-table input{width:64px;padding:6px;border:1px solid #d1d5db;border-radius:7px}.note{padding:12px 14px;border:1px dashed #cbd5e1;background:#f8fafc;border-radius:10px;color:#475569;font-size:12px}.toolbar{display:flex;gap:7px;flex-wrap:wrap;align-items:center}.toolbar input{padding:8px;border:1px solid #d1d5db;border-radius:8px}.status-row{display:flex;gap:8px;flex-wrap:wrap;margin-bottom:12px}.schedule-card{padding:14px}.schedule-help{font-size:12px;color:var(--muted);margin-bottom:10px}.schedule-matrix-wrap{overflow:auto;border:1px solid var(--line);border-radius:10px;max-height:65vh}.schedule-matrix{border-collapse:separate;border-spacing:0;width:max-content}.schedule-matrix th,.schedule-matrix td{border-right:1px solid var(--line);border-bottom:1px solid var(--line);padding:6px;text-align:center;min-width:54px;height:33px;font-size:11px}.schedule-matrix th{position:sticky;top:0;z-index:4;background:#f8fafc}.schedule-matrix .sticky-name{position:sticky;left:0;z-index:3;width:68px;min-width:68px;max-width:68px;white-space:normal;overflow-wrap:anywhere;text-align:center;vertical-align:middle;background:#fff;font-weight:800}.schedule-matrix .sticky-shift{position:sticky;left:68px;z-index:3;width:46px;min-width:46px;max-width:46px;background:#fff;font-weight:700}.schedule-matrix th.sticky-name,.schedule-matrix th.sticky-shift{z-index:6;background:#f8fafc}.schedule-matrix .weekend{background:#fff7ed}.schedule-matrix .closed{background:var(--gray-soft);color:#9ca3af}.schedule-matrix .o{background:var(--green-soft);color:var(--green);font-weight:800}.schedule-matrix .x{background:var(--red-soft);color:var(--red);font-weight:800}.schedule-matrix .rest{background:#b91c1c;color:#fff;font-weight:800}.schedule-matrix td.editable{cursor:pointer}.schedule-matrix td.editable:hover{outline:2px solid #93c5fd;outline-offset:-2px}.legend{display:flex;gap:8px;flex-wrap:wrap;margin-top:10px}.lg{padding:4px 7px;border-radius:7px;font-size:11px}.lg.o{background:var(--green-soft);color:var(--green)}.lg.x{background:var(--red-soft);color:var(--red)}.lg.rest{background:#b91c1c;color:#fff}.lg.job{background:var(--blue-soft);color:#1d4ed8}.lg.closed{background:var(--gray-soft);color:#6b7280}.cell-menu{position:fixed;z-index:50;width:180px;background:#fff;border:1px solid var(--line);border-radius:10px;box-shadow:0 12px 30px rgba(0,0,0,.18);padding:6px;max-height:320px;overflow:auto}.cell-menu button{display:block;width:100%;border:0;background:#fff;text-align:left;padding:8px;border-radius:7px;cursor:pointer}.cell-menu button:hover{background:#f3f4f6}.version-list{display:grid;gap:8px}.version-item{padding:10px;border:1px solid var(--line);border-radius:9px;font-size:12px;display:flex;justify-content:space-between;gap:12px}.gap-bad{color:#b91c1c;font-weight:800}
@media(max-width:1050px){.app-shell{grid-template-columns:1fr}.sidebar{position:static}.stats-grid{grid-template-columns:1fr 1fr}.cols-4,.cols-3,.cols-2,.two-col{grid-template-columns:1fr}.skill-grid{grid-template-columns:repeat(2,1fr)}}

.custom-special-panel{margin-top:14px;padding:14px;border:1px solid var(--line);border-radius:10px;background:#fafcff}.custom-requirements{margin-top:12px}.special-day{position:relative}.special-mark{display:inline-block;margin-left:3px;color:#7c3aed;font-size:14px;line-height:1}.schedule-matrix th.special-day{box-shadow:inset 0 3px 0 #c4b5fd}


.modal-overlay{position:fixed;inset:0;z-index:100;background:rgba(15,23,42,.48);display:flex;align-items:center;justify-content:center;padding:20px}.modal-card{width:min(520px,96vw);background:#fff;border-radius:14px;box-shadow:0 24px 70px rgba(0,0,0,.25);padding:18px}.modal-card .field{display:block;margin:12px 0}.modal-card select,.modal-card textarea{width:100%;border:1px solid #d1d5db;border-radius:8px;padding:9px;background:#fff}.change-list{display:grid;gap:8px}.change-item{border:1px solid var(--line);border-radius:9px;padding:10px 12px;font-size:12px}.change-item>div:first-child{display:flex;gap:10px;align-items:center;flex-wrap:wrap}.change-arrow{font-weight:700;color:#1d4ed8}.change-reason{margin:5px 0;color:#475569}
.login-screen{min-height:100vh;display:grid;place-items:center;padding:24px;background:linear-gradient(135deg,#eff6ff,#f8fafc 55%,#ecfdf5)}.login-card{width:min(390px,100%);background:#fff;border:1px solid var(--line);border-radius:18px;padding:28px;box-shadow:0 24px 60px rgba(15,23,42,.12)}.login-brand{font-size:24px;font-weight:900;margin-bottom:5px}.login-card .field{display:block;margin:24px 0 12px}.login-submit{width:100%}.login-error{margin:0 0 12px;color:var(--red);font-size:13px;font-weight:700}.top-actions{display:flex;gap:8px;align-items:center;flex-wrap:wrap}
.storage-error{background:var(--red-soft);color:var(--red)}
.business-calendar-card{padding:16px}.calendar-weekdays,.business-calendar{display:grid;grid-template-columns:repeat(7,minmax(118px,1fr));gap:8px}.calendar-weekdays{margin-bottom:8px;text-align:center;color:#64748b;font-size:12px;font-weight:800}.calendar-weekdays span:nth-child(6),.calendar-weekdays span:nth-child(7){color:#9a3412}.calendar-day{min-height:112px;border:1px solid #dfe3e8;border-radius:11px;padding:10px;background:#fff;transition:border-color .15s,box-shadow .15s}.calendar-day.holiday{background:#fffaf1;border-color:#ead5ad}.calendar-day.closed{background:#eceeeb;border-color:#cfd3cf;color:#7b8184;filter:grayscale(1) saturate(0);opacity:.78}.calendar-day.today{box-shadow:0 0 0 2px #4f8f7b;border-color:#4f8f7b}.calendar-day-head{display:flex;align-items:center;justify-content:space-between;margin-bottom:9px}.calendar-day-head b{font-size:20px}.calendar-day-head span{font-size:11px;font-weight:800}.calendar-rule-row{display:grid;grid-template-columns:1fr 1fr;gap:5px}.calendar-day button{width:100%;min-height:25px;border:1px solid #dfe3e8;border-radius:9px;background:#fff;color:#4b5563;font-size:11px;cursor:pointer}.calendar-day button:hover{border-color:#94a3b8}.calendar-day button.selected{font-weight:800}.calendar-rule-row button:first-child.selected{background:#e7f1ed;border-color:#abcbbf;color:#245f4f}.calendar-rule-row button:last-child.selected{background:#f7ead3;border-color:#dfbd80;color:#8a5715}.calendar-day .calendar-closed{margin-top:5px}.calendar-day .calendar-closed.selected{background:#dedfdb;border-color:#c4c6c1;color:#51575a;font-weight:800}.calendar-empty{min-height:1px}.calendar-head{align-items:flex-end}
@media(max-width:1200px){.calendar-weekdays{display:none}.business-calendar{grid-template-columns:repeat(4,minmax(150px,1fr))}.calendar-empty{display:none}}
@media(max-width:760px){.business-calendar{grid-template-columns:repeat(2,minmax(130px,1fr))}.calendar-head{align-items:flex-start;flex-direction:column}}
@media(max-width:480px){.business-calendar{grid-template-columns:1fr}}

/* 全站共用「營業月曆」視覺：柔和綠、暖米色、細框與輕量卡片 */
:root{
  --bg:#f6f7f3;
  --panel:#ffffff;
  --text:#19251f;
  --muted:#6d7771;
  --line:#dde2dd;
  --blue:#3f7f6e;
  --blue-soft:#e7f1ed;
  --green:#2f6f5f;
  --green-soft:#e7f1ed;
  --amber:#8a5715;
  --amber-soft:#f7ead3;
  --gray-soft:#f0f1ee;
}
body{background:var(--bg);color:var(--text)}
.app-shell{grid-template-columns:224px minmax(0,1fr)}
.sidebar{
  background:#f2f4f0;
  color:var(--text);
  border-right:1px solid #d9ded9;
  padding:24px 14px;
}
.brand{color:#203d34;letter-spacing:.01em}
.brand-sub{color:#77817b}
.nav-item{
  color:#56625c;
  border:1px solid transparent;
  padding:10px 12px;
  border-radius:10px;
  transition:background .15s,border-color .15s,color .15s;
}
.nav-item:hover{background:#f9faf7;color:#2f5f51;border-color:#dce4df}
.nav-item.active{
  background:#e6f0eb;
  color:#245f4f;
  border-color:#b8cec4;
  box-shadow:inset 3px 0 0 #4f8f7b;
}
.main{padding:24px 28px}
.topbar{
  background:#fff;
  border:1px solid var(--line);
  border-radius:13px;
  padding:13px 16px;
  margin-bottom:16px;
}
.topbar h1{color:#20342d;font-size:23px}
.card{
  border-color:var(--line);
  border-radius:12px;
  box-shadow:none;
  margin-bottom:14px;
}
.stats-grid{gap:10px}
.stats-grid>.card{position:relative;overflow:hidden}
.stats-grid>.card::before{content:"";position:absolute;inset:0 auto 0 0;width:3px;background:#b7cec4}
.stat-label{color:#707a74;font-weight:700}
.stat-value{color:#285d4f}
.pill{background:#e7f1ed;color:#245f4f;border:1px solid #c7dcd3}
.btn{
  color:#46534d;
  border-color:#d8ded9;
  border-radius:9px;
  background:#fff;
  transition:background .15s,border-color .15s,color .15s;
}
.btn:hover{background:#f4f7f4;border-color:#b9cbc2;color:#285d4f}
.btn.primary{background:#4f8f7b;color:#fff;border-color:#4f8f7b}
.btn.primary:hover{background:#3f7968;border-color:#3f7968}
.btn:focus-visible,.nav-item:focus-visible,.action:focus-visible,input:focus-visible,select:focus-visible,textarea:focus-visible{
  outline:2px solid #4f8f7b;
  outline-offset:2px;
}
.flow span{background:#fafbf8;border-color:#dfe4df;color:#405048;border-radius:9px}
.flow b{color:#78a091}
.form-card>.section-head{background:#f7f8f5}
.form-section-title,.field>span{color:#44534c}
.field input,.field select,.toolbar input,.requirement-table input,.modal-card select,.modal-card textarea{
  border-color:#d6ddd8;
  color:var(--text);
}
.field input:focus,.field select:focus,.toolbar input:focus,.requirement-table input:focus,.modal-card select:focus,.modal-card textarea:focus{
  border-color:#82aa9b;
  box-shadow:0 0 0 3px rgba(79,143,123,.12);
}
.check-box,.skill-grid{background:#f8f9f6}
th{background:#f4f6f3;color:#4f5d56}
.tag{background:#e7f1ed;color:#285d4f}
.action{border-color:#d8ded9;color:#4b5852}
.action.edit{background:#e7f1ed;color:#245f4f;border-color:#c2d8ce}
.note{background:#fafaf7;border-color:#cbd5ce;color:#526159}
.schedule-matrix-wrap{border-radius:11px}
.schedule-matrix th,.schedule-matrix th.sticky-name,.schedule-matrix th.sticky-shift{background:#f4f6f3}
.schedule-matrix td.editable:hover{outline-color:#82aa9b}

.cell-menu{border-color:#d7ddd8;box-shadow:0 14px 35px rgba(36,62,51,.14)}
.cell-menu button:hover{background:#eef4f0}
.version-item,.change-item{background:#fff;border-color:#dce1dc}
.change-arrow{color:#3f7968}
.custom-special-panel{background:#fafbf8}
.modal-overlay{background:rgba(27,43,36,.42)}
.modal-card{border:1px solid var(--line);border-radius:13px;box-shadow:0 24px 70px rgba(26,48,38,.2)}
.login-screen{background:linear-gradient(135deg,#edf3ef,#faf9f4 55%,#f7ead3)}
.login-card{border-color:#dbe2dc;box-shadow:0 24px 60px rgba(37,64,52,.12)}
.business-calendar-card{border-color:#dfe2de}
.calendar-weekdays{color:#69756f}
.calendar-day{border-color:#dfe3e0}
.calendar-day button{border-color:#dfe3e0;color:#4c5852}

@media(max-width:1050px){
  .sidebar{padding:14px 16px;border-right:0;border-bottom:1px solid #d9ded9}
  .brand-sub{margin:3px 0 12px}
  .sidebar nav{display:flex;gap:6px;overflow-x:auto;padding-bottom:2px}
  .nav-item{width:auto;flex:0 0 auto;margin:0}
  .nav-item.active{box-shadow:inset 0 -3px 0 #4f8f7b}
  .main{padding:16px}
}
@media(max-width:650px){
  .stats-grid{grid-template-columns:1fr}
  .topbar{align-items:flex-start;flex-direction:column}
}

/* Closed dates remain editable, with a neutral appearance for every control. */
.calendar-day.closed{
  background:#eeeeee;
  border-color:#cccccc;
  color:#666666;
  filter:grayscale(1);
  opacity:1;
}
.calendar-day.closed.today{
  border-color:#999999;
  box-shadow:0 0 0 2px #999999;
}
.calendar-day.closed .calendar-day-head,
.calendar-day.closed .calendar-day-head b,
.calendar-day.closed .calendar-day-head span{
  color:#666666;
}
.calendar-day.closed button{
  background:#f7f7f7;
  border-color:#cccccc;
  color:#666666;
}
.calendar-day.closed .calendar-closed.selected{
  background:#d9d9d9;
  border-color:#aaaaaa;
  color:#444444;
}
.calendar-day.closed button:hover{
  background:#e3e3e3;
  border-color:#999999;
}

/* Freeze the date and weekday rows as one header, preserving left columns. */
.schedule-matrix thead{
  position:sticky;
  top:0;
  z-index:6;
}
.schedule-matrix thead th{
  top:auto;
}

/* 極簡班表：文字為主，只在選定職務時加上單一強調色。 */
.schedule-matrix{--row-bg:#fff;color:#37413c}
.schedule-matrix th,.schedule-matrix td{border-right-color:#f0f1ef;border-bottom-color:#f0f1ef}
.schedule-matrix td{background:var(--row-bg);padding:5px 4px}
.schedule-matrix tr.employee-alt{--row-bg:#fafbf9}
.schedule-matrix td.sticky-name,.schedule-matrix td.sticky-shift{background:var(--row-bg)}
.schedule-matrix .sticky-shift{color:#68716b;border-right-color:#d5dad5;font-weight:500}
.schedule-matrix tbody tr:nth-child(2n) td,.schedule-matrix td.sticky-name{border-bottom-color:#d9ded9}
.schedule-matrix th.weekend{background:#efefeb;color:#565e57}
.schedule-matrix th.special-day{box-shadow:none}
.schedule-matrix .special-mark{color:#d14343}
.schedule-matrix .job{color:#37413c;font-weight:500}
.schedule-matrix .o{background:transparent;color:#6a9678;font-weight:600}
.schedule-matrix .x{background:transparent;color:#bd7d79;font-weight:600}
.schedule-matrix .rest{background:#faf0ee;color:#945c55;font-weight:500}
.schedule-matrix .closed{background:#f0f1ee;color:#787e78;font-weight:400}
.schedule-matrix .job-highlight{background:#e3efe8;color:#245c43;font-weight:700;box-shadow:inset 0 -2px 0 #80a68e}
.schedule-matrix tbody tr:hover td:not(.job-highlight):not(.o):not(.x){box-shadow:inset 0 0 0 999px rgba(55,75,64,.035)}
.schedule-matrix td.editable:hover{outline:2px solid #8ca294;outline-offset:-2px}
.schedule-card .legend{gap:14px;color:#68716b}
.schedule-card .lg{padding:2px 4px;border-radius:3px;background:transparent}
.schedule-card .lg.o{background:transparent;color:#6a9678}
.schedule-card .lg.x{background:transparent;color:#bd7d79}
.schedule-card .lg.rest{background:#faf0ee;color:#945c55}
.schedule-card .lg.closed{background:#f0f1ee;color:#787e78}
.schedule-highlight-controls{display:flex;align-items:center;flex-wrap:wrap;gap:4px;margin:0 0 10px;font-size:12px}
.highlight-label{color:#68716b;margin-right:5px}
.schedule-highlight-controls button{border:1px solid transparent;border-radius:5px;background:transparent;color:#59635c;padding:5px 8px;cursor:pointer}
.schedule-highlight-controls button:hover{background:#f1f3ef}
.schedule-highlight-controls button[aria-pressed="true"]{background:#e7eee8;border-color:#c4d4c7;color:#315d42;font-weight:700}
.schedule-highlight-controls button:focus-visible{outline:2px solid #8ca294;outline-offset:2px}

.schedule-month-tabs{display:flex;gap:6px;overflow-x:auto;margin-bottom:12px;padding-bottom:4px}
.schedule-month-tabs button{flex:0 0 auto;border:1px solid #dce2dc;border-radius:8px;padding:8px 12px;background:#fff;color:#59635c;cursor:pointer}
.schedule-month-tabs button[aria-selected="true"]{background:#e7eee8;border-color:#9eb8a5;color:#254d35;font-weight:700}
.schedule-month-tabs small{display:block;margin-top:3px;font-weight:400;color:#68716b}
.schedule-month-tabs button:focus-visible{outline:2px solid #4f8f7b;outline-offset:2px}
.employee-link-input{width:100%;padding:10px;border:1px solid #cbd5ce;border-radius:6px}

.schedule-progress{align-items:center;justify-content:space-between}
.schedule-progress ol{display:flex;flex-wrap:wrap;gap:16px;list-style:none;margin:0;padding:0;color:#899189;font-size:12px}
.schedule-progress .current{color:#315f45;font-weight:700}
.schedule-next-step{display:flex;align-items:center;justify-content:space-between;gap:20px;padding:16px 18px;margin-bottom:16px;border:1px solid #dce2dc;border-radius:12px;background:#fff}
.schedule-next-step h3{margin:0 0 6px;font-size:16px}
.schedule-next-step p{margin:0 0 7px;color:#637167;line-height:1.6;font-size:13px;max-width:670px}
.schedule-next-step .muted+.muted{margin-left:14px}
.deadline-state{display:block;margin-top:7px;color:#66756a;font-size:12px}
.deadline-state.warning{color:#9a6a24;font-weight:700}
.deadline-state.overdue{color:#a34242;font-weight:700}
.schedule-step-actions{display:flex;align-items:center;gap:8px;flex-wrap:wrap;flex-shrink:0}
.schedule-step-actions details{position:relative;font-size:12px;color:#68776c}
.schedule-step-actions summary{cursor:pointer;padding:9px}
.schedule-step-actions details[open] .schedule-other-menu{position:absolute;right:0;top:36px;z-index:12;white-space:nowrap;box-shadow:0 5px 18px #0001;background:white;padding:8px;border:1px solid #dce2dc;border-radius:8px;display:grid;gap:8px}
@media(max-width:1100px){.schedule-next-step{align-items:flex-start;flex-direction:column}.schedule-step-actions{flex-shrink:1}.schedule-progress{gap:12px}.schedule-progress ol{gap:10px}}

/* 假日用淡鵝黃區分；排休保留淺紅底，O／X 沿用日期底色。 */
.schedule-matrix th.weekend,.schedule-matrix td.weekend:not(.rest){background:#fffbe8}
.schedule-matrix td.weekend.job-highlight{background:#e3efe8}
.history-link{display:block;margin:12px 0;padding:4px 0;border:0;background:none;color:#486757;font:inherit;font-size:13px;text-decoration:underline;text-underline-offset:3px;cursor:pointer}
.history-link:focus-visible{outline:2px solid #486757;outline-offset:4px}
.history-dialog{width:min(680px,calc(100vw - 32px));max-height:80vh;padding:20px;border:1px solid #dce2dc;border-radius:12px;box-sizing:border-box;box-shadow:0 24px 70px #1a302633}
.history-dialog::backdrop{background:rgba(27,43,36,.42)}
.history-dialog .section-head{margin-bottom:12px}
.history-scroll{max-height:60vh;overflow:auto;overscroll-behavior:contain}
.calendar-custom{width:100%;margin-top:5px;padding:5px;border:1px solid #dce2dc;border-radius:5px;background:white;color:#526358;cursor:pointer}
.calendar-custom.selected{background:#edf2ee;border-color:#6f8c79;font-weight:700}
.calendar-custom-name{font-size:11px;margin-top:5px;color:#526358;overflow-wrap:anywhere}
.custom-day-dialog .field+.field{display:block;margin-top:5px}
.custom-day-requirements{max-height:36vh;overflow:auto;margin:12px 0}

/* AI assistant */
.sr-only{position:absolute!important;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
button:disabled,textarea:disabled{cursor:not-allowed;opacity:.58}

.settings-card{max-width:1050px}.catalog-add{display:flex;gap:10px;max-width:480px;margin-top:22px}.catalog-add input,.catalog-row input{min-width:0;width:100%;border:1px solid var(--line);border-radius:8px;padding:10px 12px;background:#fff;font:inherit}.catalog-list{display:grid;gap:10px}.catalog-row{display:grid;grid-template-columns:28px minmax(120px,1fr) repeat(4,auto);align-items:center;gap:8px;padding:14px;background:#f8faf8;border:1px solid var(--line);border-radius:10px}.catalog-position{color:#738177;font-size:13px}.catalog-usage{grid-column:2/-1;color:#68756d;line-height:1.6}.catalog-message{color:#a13a32;min-height:1.5em}.catalog-add .btn{white-space:nowrap}@media(max-width:560px){.catalog-row{grid-template-columns:24px repeat(4,1fr)}.catalog-row input{grid-column:2/-1}.catalog-row button:nth-of-type(1){grid-column:2}.catalog-usage{grid-column:1/-1}.catalog-row .btn{padding:8px}.catalog-add{flex-wrap:wrap}}

.cell-menu{width:208px;max-height:min(380px,calc(100vh - 16px));padding:0;overflow:hidden;display:flex;flex-direction:column}.cell-menu-options{padding:6px;overflow-y:auto;min-height:0}.cell-menu-label{padding:9px 8px 4px;color:#748078;font-size:11px;font-weight:700;letter-spacing:.06em}.cell-menu-actions{flex-shrink:0;padding:6px;border-top:1px solid #dce3de;background:#f6f8f6}.cell-menu .cell-menu-clear{display:flex;gap:10px;align-items:center;background:transparent;color:#655047}.cell-menu-clear>span:first-child{font-size:23px}.cell-menu-clear strong{display:block;font-size:13px;font-weight:600}.cell-menu-clear small{display:block;margin-top:3px;color:#7b807c;font-size:11px}.cell-menu .cell-menu-clear:hover{background:#ede7e2}.cell-menu button:focus-visible{outline:2px solid #568375;outline-offset:-2px}

.special-job-badge{display:inline-block;margin-left:8px;padding:2px 6px;border-radius:4px;background:#f4edda;color:#7b6228;font-size:10px;font-weight:600;vertical-align:middle}.catalog-usage .special-job-badge{margin-left:0}.catalog-row input[readonly]{background:#f1f3f0;color:#536159}

.cell-menu button[data-value="排休"],.catalog-row input.rest-option[readonly]{color:#b91c1c;font-weight:700}
.schedule-convenience{display:flex;gap:8px;align-items:center;flex-wrap:wrap;margin:10px 0}
.schedule-convenience[hidden]{display:none}
.schedule-tool-dialog{width:min(1050px,94vw);max-height:88vh;border:1px solid #dce2dc;border-radius:12px;padding:20px;color:#263c30;background:white;box-sizing:border-box}
.schedule-tool-dialog::backdrop{background:#1b2b246b}
.schedule-tool-dialog header{display:flex;justify-content:space-between;align-items:center;gap:12px}
.schedule-tool-dialog h3{margin:0}
.tool-dialog-body{margin-top:14px}
.schedule-tool-dialog .field{display:flex;flex-direction:column;gap:5px;margin:12px 0}
.batch-date-range{display:grid;grid-template-columns:1fr 1fr;gap:14px}
.tool-table{border-collapse:collapse;width:100%;font-size:13px}
.tool-table th,.tool-table td{border:1px solid #dce2dc;padding:8px;text-align:left}
.snapshot-table{white-space:nowrap}
.tool-dialog-body .table-wrap{overflow:auto;max-height:62vh}
.version-item{align-items:center;flex-wrap:wrap}
.daily-view-tabs,.daily-date-controls{display:flex;flex-wrap:wrap;gap:8px;align-items:center;margin:12px 0}
.daily-view-tabs [aria-pressed="true"]{background:#e7eee8;border-color:#9eb8a5;color:#254d35}
#dailyStaffing[hidden],#scheduleMatrix[hidden],#scheduleHighlightControls[hidden]{display:none}
.daily-date-controls input{padding:7px;border:1px solid #dce2dc;border-radius:6px;font:inherit}
.daily-shifts{display:grid;grid-template-columns:1fr 1fr;gap:16px}
.daily-shift{min-width:0;border:1px solid #dce2dc;border-radius:10px;padding:12px}
.daily-shift h4{margin:0 0 10px;font-size:17px}
.daily-job{padding:10px 0;border-bottom:1px solid #e5e9e4}
.daily-job-title{border:0;background:none;color:#315d42;text-decoration:underline;text-underline-offset:3px;font-weight:700;cursor:pointer;padding:4px 8px 4px 0}
.daily-job>span{font-size:12px}
.daily-person{margin:5px 5px 0 0;padding:7px 10px;border:1px solid #dce2dc;border-radius:7px;background:white;cursor:pointer;color:#37413c}
.daily-rest{margin:12px 0;padding:10px;background:#faf0ee;border-radius:8px;color:#945c55;font-size:13px}
.daily-shift details{margin-top:12px;font-size:13px}.daily-shift summary{cursor:pointer}
.daily-closed{padding:18px;background:#f0f1ee;border-radius:8px;color:#787e78}
.daily-date-link{background:none;border:0;padding:0;color:inherit;font:inherit;cursor:pointer;width:100%;text-decoration:underline;text-underline-offset:3px}
@media(max-width:760px){.daily-shifts{grid-template-columns:1fr}.daily-date-controls label{flex-basis:100%}}

/* Compact staffing review: lists scroll inside the panel instead of extending the page. */
#gapPanel{margin-bottom:16px}
#gapPanel summary{cursor:pointer;font-weight:700;padding:4px}
.staffing-columns{display:grid;grid-template-columns:minmax(200px,1fr) minmax(240px,1.4fr);gap:16px}
.staffing-gap-list,.staffing-candidates{max-height:320px;overflow:auto;overscroll-behavior:contain;padding:4px}
.staffing-gap{display:block;width:100%;text-align:left;border:1px solid #dce2dc;background:white;border-radius:7px;padding:10px;margin-bottom:6px;cursor:pointer;color:#37413c}
.staffing-gap span{display:block;font-size:12px;margin-top:4px;color:#68716b}
.staffing-gap[aria-pressed="true"]{border-color:#4f8f7b;background:#edf5ef}
.staffing-overages{margin:0 0 16px;padding:12px;border:1px solid #ddc99d;border-radius:9px;background:#fffbf1}.staffing-overages h3{margin:0 0 8px;font-size:14px;color:#805717}.staffing-overages>.muted{font-size:12px;line-height:1.6}.staffing-overage-list{max-height:300px;overflow:auto;overscroll-behavior:contain;display:grid;gap:8px}.staffing-overage{padding:10px;border:1px solid #eadcc1;background:white;border-radius:7px;overflow-wrap:anywhere}.overage-locate{border:0;background:transparent;color:#754e17;text-align:left;font:inherit;font-weight:600;padding:2px 0;cursor:pointer;text-decoration:underline;text-underline-offset:3px}.staffing-overage-count{color:#805717;font-size:13px}.staffing-overage-count strong{font-weight:700}.staffing-overage-people{display:flex;flex-wrap:wrap;align-items:center;gap:6px;font-size:12px}.staffing-overage-people .daily-person{margin:0}.staffing-overage p{margin:7px 0}
.staffing-candidates h3{font-size:14px;margin:0 0 8px}
.staffing-person{background:white;border:1px solid #dce2dc;border-radius:8px;padding:10px;margin:8px 0}
.staffing-person p{line-height:1.6;margin:6px 0;font-size:12px}
.schedule-matrix td.gap-focus{outline:2px solid #4f8f7b;outline-offset:-2px}
.assignment-warnings{max-height:240px;overflow:auto;color:#9b3939;line-height:1.7}
.schedule-tool-dialog textarea{width:100%;font:inherit;border:1px solid #cbd5ce;border-radius:6px;padding:8px}
@media(max-width:700px){.staffing-columns{grid-template-columns:1fr}.staffing-gap-list{max-height:180px}.staffing-candidates{max-height:280px}}
.monthly-statistics{margin:12px 0;border:1px solid #dce3df;border-radius:10px;padding:12px;background:#fff}
.monthly-statistics>summary{cursor:pointer;font-weight:600;color:#355e52}
.monthly-statistics-scroll{overflow:auto;max-height:440px}
.monthly-statistics table{width:100%;border-collapse:separate;border-spacing:0;font-size:13px;white-space:nowrap}
.monthly-statistics caption{text-align:left;padding:8px 0;white-space:normal}
.monthly-statistics th,.monthly-statistics td{padding:9px 12px;text-align:center;border-bottom:1px solid #e5e7eb;background:#fff}
.monthly-statistics thead th{position:sticky;top:0;z-index:2;background:#f3f5f3}
.monthly-statistics tbody th{position:sticky;left:0;z-index:1;text-align:left}
.monthly-statistics small{display:block;font-weight:normal;color:#66736e;margin-top:4px}
.statistics-name{border:0;background:none;color:#355e52;text-decoration:underline;cursor:pointer;font:inherit;padding:3px 0}
.statistics-name[aria-pressed=true]{font-weight:700;text-decoration-thickness:2px}
.statistics-help{font-size:12px;line-height:1.7;margin-bottom:0}
.employee-focus-bar{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:10px;margin:10px 0;background:#f0f6f3;border:1px solid #b6cfc3;border-radius:8px;flex-wrap:wrap}
#monthlyStatistics[hidden],#employeeFocusBar[hidden],.schedule-matrix tbody tr[hidden]{display:none!important}
.schedule-matrix tr.employee-focused .sticky-name{box-shadow:inset 3px 0 #508b78}
.publication-review{width:min(800px,94vw)}
.review-section{border:1px solid #dce3df;border-radius:8px;margin:12px 0;padding:10px}
.review-section>summary{cursor:pointer;font-weight:600}
.review-list{max-height:230px;overflow:auto;overscroll-behavior:contain}
.review-list p{margin:8px 0;line-height:1.6}
.review-list article{border-bottom:1px solid #e5e7eb;padding:8px 0}
.review-locate{font:inherit;background:none;border:0;color:#355e52;text-decoration:underline;text-align:left;cursor:pointer;padding:3px}
.review-note{white-space:pre-wrap;font-size:12px;color:#68716b}
.review-ack{display:block;line-height:1.7;margin-top:12px}
.publication-review [data-error]{color:#a33d3d}
.publication-audit{font-size:12px;flex-basis:100%;line-height:1.6}
.publication-audit summary{cursor:pointer}
.absence-panel{margin:12px 0;border:1px solid #dce3df;border-radius:10px;padding:12px}
.absence-panel>summary{cursor:pointer;font-weight:600}
.absence-records{max-height:300px;overflow:auto}
.absence-records article{padding:10px 0;border-bottom:1px solid #e5e7eb}
.absence-records p{margin:6px 0;white-space:pre-wrap}
.absence-dialog .note{white-space:pre-wrap}
.absence-dialog [data-error]{color:#a33d3d}
#absencePanel[hidden]{display:none!important}
.dashboard-tasks{margin:16px 0}
.todo-counts{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px;margin:16px 0}
.todo-counts>span{padding:12px;border:1px solid #e0e6e2;border-radius:8px;font-size:13px;color:#5f6c65}
.todo-counts strong{display:block;margin-top:7px;color:#304c40;font-size:20px}
.todo-list{max-height:460px;overflow:auto;overscroll-behavior:contain}
.todo-list article{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:14px 2px;border-bottom:1px solid #e5e7eb}
.todo-list h3{font-size:15px;margin:5px 0}
.todo-list p{font-size:13px;color:#637168;line-height:1.6;margin:0;overflow-wrap:anywhere}
.todo-list .btn{flex-shrink:0}
.todo-kind{font-size:12px;color:#4f806d}
.todo-empty{padding:16px;text-align:center;color:#607268}
@media(max-width:700px){.todo-counts{grid-template-columns:repeat(2,minmax(0,1fr))}.todo-list article{align-items:flex-start;flex-direction:column}}

.workload-context{white-space:pre-line;font-size:13px;line-height:1.7;color:#475569;background:#f8fafc;padding:10px;border-radius:6px}.workload-context:empty{display:none}.fairness-summary{padding:8px 12px;border-bottom:1px solid #e5e7eb}.fairness-summary p{line-height:1.7}

/* Readable admin workspace: primary workflow first, secondary tools on demand. */
:root{--bg:#f5f6f3;--panel:#fff;--text:#263c34;--muted:#69766f;--line:#e0e6e1;--blue:#356b58;--blue-soft:#edf4ef}
body{line-height:1.5}.app-shell{grid-template-columns:208px minmax(0,1fr)}.sidebar{background:#203d32;padding:28px 16px}.brand{font-size:19px;letter-spacing:.04em}.brand-sub{color:#b5c9bd;letter-spacing:.13em;font-size:11px;margin:8px 0 28px}.nav-item{padding:12px 14px;color:#dce7df;font-size:14px;border-radius:10px;margin:5px 0}.nav-item.active{background:#f0f5ef;color:#264d3d;font-weight:750}.nav-item:hover:not(.active){background:#315345}.main{min-width:0;padding:24px 28px}.topbar{padding-bottom:20px;border-bottom:1px solid var(--line);gap:16px}.topbar h1{font-size:23px;letter-spacing:.03em}.top-actions{gap:8px;flex-wrap:wrap}.top-actions .pill{background:transparent;padding:4px;color:#62746a;font-size:12px}#clock{font-variant-numeric:tabular-nums;font-weight:400}.top-actions .btn{font-size:12px;min-height:36px}.card{border-radius:14px;border-color:var(--line);box-shadow:0 2px 8px #213c3205}.btn{min-height:40px;font-size:13px;font-weight:600;border-color:#d8e1da;padding:9px 14px;border-radius:9px;transition:background .15s,border-color .15s}.btn:hover{background:#f1f5ef;border-color:#adc5b6}.btn.primary{background:#356b58;border-color:#356b58;color:white}.btn.primary:hover{background:#285642;border-color:#285642}.btn:disabled{opacity:.48;cursor:not-allowed}button:focus-visible,summary:focus-visible,a:focus-visible{outline:3px solid #87ad9a;outline-offset:3px}.field input,.field select,.field textarea{min-height:42px;border-radius:8px}.form-section{padding:20px}.form-grid{gap:16px}.section-head h2{font-size:19px}.section-head h3{font-size:16px}
.schedule-head{margin:22px 0 14px}.schedule-head h2{margin:0 0 4px}.month-tabs{gap:8px}.month-tabs button{border-radius:10px;min-height:46px}.schedule-progress{margin:16px 0 0;padding:12px 18px;background:#fff;border:1px solid var(--line);border-radius:14px 14px 0 0;gap:14px}.schedule-progress #monthState{background:#edf4ef;color:#355b47;font-size:12px}.schedule-progress ol{gap:8px;flex-wrap:wrap}.schedule-progress li{font-size:12px;color:#718075;border-radius:6px;padding:5px 10px}.schedule-progress li.current{background:#eaf2ec;color:#285642;font-weight:700}.schedule-next-step{margin-top:0;margin-bottom:14px;padding:18px;background:#fff;border:1px solid var(--line);border-top:0;border-radius:0 0 14px 14px;box-shadow:0 4px 12px #213c3204}.schedule-next-step h3{font-size:20px;margin:0 0 6px}.schedule-next-step p{font-size:13px;color:#68776d;max-width:650px;margin:0 0 10px}.schedule-next-step #fillWindow,.schedule-next-step #publishState{display:inline-block;margin-right:12px}.schedule-step-actions{align-items:center;gap:8px}.schedule-step-actions .primary{min-width:128px;min-height:44px}.deadline-state{font-size:12px}#scheduleOtherActions>summary{font-size:13px;min-height:40px;padding:9px 12px;border-radius:9px}.schedule-other-menu{z-index:20;padding:12px;box-shadow:0 8px 28px #243b3220}.schedule-other-menu #btnRemoveMonth{color:#9d4845}
#gapPanel{padding:0;background:transparent;border:0;margin:0 0 18px}#gapPanel>details{background:white;border:1px solid var(--line);border-radius:10px;margin-top:8px}#gapPanel>details>summary{padding:10px 14px;font-size:12px;color:#63746b;cursor:pointer}.schedule-attention{padding:14px 16px;background:#edf2ed;border:1px solid #dfe7df;border-radius:12px}.attention-heading{display:flex;align-items:center;gap:12px;margin-bottom:10px}.attention-heading strong{font-size:13px}.attention-heading span{font-size:12px;color:#6e7c71}.attention-actions{display:flex;gap:10px}.attention-actions>button{flex:1;text-align:left;border:1px solid #dde5dd;background:#fff;border-radius:9px;padding:12px 14px;color:#314b3d;cursor:pointer;display:grid;gap:3px;min-width:0}.attention-actions>button:hover{border-color:#8caf99;background:#fcfefb}.attention-actions span{font-size:11px;color:#738073}.attention-actions strong{font-size:15px;font-weight:650}.attention-actions small{font-size:11px;color:#617b6b}.staffing-body{padding:14px}
.schedule-card{padding:16px;overflow:visible}.schedule-help{font-size:12px;color:#7a847d;margin-bottom:12px}.schedule-convenience{display:flex;gap:8px;align-items:center;flex-wrap:wrap;margin:8px 0 14px}.schedule-extra-tools{margin-left:auto}.schedule-extra-tools>summary{cursor:pointer;padding:9px 14px;border:1px solid #d8e1da;border-radius:9px;font-size:13px;min-height:40px;background:#fff}.schedule-extra-tools[open]{flex-basis:100%;margin-left:0}.schedule-extra-tools[open]>summary{width:max-content}.schedule-extra-content{display:flex;align-items:center;flex-wrap:wrap;gap:8px;background:#f7f9f6;border:1px solid #e3e9e1;border-radius:9px;padding:12px;margin-top:8px}.schedule-extra-content .muted{font-size:12px;margin-right:8px}.daily-view-tabs{border-bottom:1px solid var(--line);padding-bottom:12px;margin-bottom:12px}.daily-view-tabs .btn[aria-pressed=true]{background:#eaf2ec;color:#2d5e46;border-color:#b2cbb9}.monthly-statistics{margin:8px 0;border:1px solid #e2e7df;border-radius:9px}.monthly-statistics>summary{font-size:12px;padding:10px 12px;color:#607264}.schedule-highlight-controls{display:block!important;padding:0!important;border:0!important;background:transparent!important;margin:8px 0 12px}.schedule-highlight-controls>summary{cursor:pointer;font-size:12px;color:#607264;padding:8px 0}.highlight-options{display:flex;flex-wrap:wrap;gap:6px;padding:6px 0}.schedule-highlight-controls button{min-height:34px}.schedule-history>summary{cursor:pointer;font-size:14px;font-weight:650;color:#53695a}.schedule-history[open]>summary{margin-bottom:16px}.legend{font-size:11px;gap:10px;padding-top:12px}.history-link{font-size:12px}.stats-grid .stat{padding:20px}.stat-label{font-size:12px}.stat-value{color:#355c47}.todo-counts>span{background:#f8faf7}.schedule-tool-dialog{border:1px solid #d7e1d8;border-radius:16px;box-shadow:0 20px 70px #17352730}.schedule-tool-dialog::backdrop{background:#1f382b66;backdrop-filter:blur(2px)}
@media(max-width:1000px){.app-shell{grid-template-columns:170px minmax(0,1fr)}.sidebar{padding:22px 10px}.brand{font-size:16px}.main{padding:18px}.topbar{align-items:flex-start}.top-actions #clock{display:none}.schedule-next-step{flex-wrap:wrap}.schedule-step-actions{flex-wrap:wrap}.attention-heading{align-items:flex-start;flex-direction:column;gap:3px}}
@media(max-width:700px){.app-shell{display:block}.sidebar{padding:14px 12px}.brand{font-size:17px}.brand-sub{display:none}#nav{display:flex;gap:5px;overflow-x:auto;margin-top:10px;padding-bottom:4px;scrollbar-width:thin}.nav-item{width:auto;white-space:nowrap;margin:0;padding:10px 12px;min-height:44px;font-size:13px}.main{padding:14px 10px}.topbar{flex-wrap:wrap;gap:10px;margin-bottom:14px;padding-bottom:12px}.topbar h1{font-size:21px}.top-actions{width:100%;justify-content:flex-end}.top-actions #storageState{margin-right:auto}.schedule-head{margin-top:16px}.schedule-head h2{font-size:18px}.schedule-progress{padding:10px}.schedule-progress ol{padding:0;margin:4px 0;gap:4px}.schedule-progress li{padding:5px 6px;font-size:11px}.schedule-next-step{padding:14px 12px;gap:14px}.schedule-next-step h3{font-size:18px}.schedule-step-actions{width:100%}.schedule-step-actions .primary{flex:1}.attention-actions{flex-direction:column;gap:7px}.attention-actions>button{grid-template-columns:1fr auto;align-items:center;padding:10px 12px;min-height:64px}.attention-actions strong{grid-row:1 / 3;grid-column:2;font-size:14px}.attention-actions small{grid-column:1}.schedule-attention{padding:12px}.schedule-card{padding:12px 8px}.schedule-convenience .btn,.schedule-extra-tools>summary{min-height:44px}.schedule-extra-content{align-items:stretch}.schedule-extra-content .btn{flex:1 1 130px}.schedule-extra-content .muted{flex-basis:100%}.form-grid.cols-4,.form-grid.cols-3,.form-grid.cols-2{grid-template-columns:1fr}.section-head{flex-wrap:wrap;gap:10px}.stats-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.stat-value.small-value{font-size:17px}}
@media(prefers-reduced-motion:reduce){.btn{transition:none}html{scroll-behavior:auto}}

.sidebar .brand{color:#f0f5ef}.schedule-highlight-controls[hidden]{display:none!important}
@media(min-width:1001px){.topbar{padding:14px 18px;margin-bottom:14px}.schedule-head{margin:14px 0 10px}.schedule-progress{padding:9px 16px}.schedule-next-step{padding:14px 16px}.schedule-attention{padding:10px 14px}.attention-actions>button{padding:9px 12px}.attention-heading{margin-bottom:7px}}

.schedule-extra-content .history-link{margin:0;min-height:40px;padding:9px 14px;border:1px solid #d8e1da;border-radius:9px;background:white;text-decoration:none;color:#53695a}
@media(max-width:700px){#nav{scrollbar-width:none}#nav::-webkit-scrollbar{display:none}}

.employment-badge{font-size:12px;background:#edf2ed;border-radius:5px;padding:4px 7px;white-space:nowrap}.employment-upcoming{display:block;color:#866b3e;font-size:11px;margin-top:5px}.employment-dialog{width:min(720px,94vw)}.employment-dialog .field{display:block;margin-bottom:14px}.employment-dialog textarea{width:100%}.employment-impact{max-height:220px;overflow:auto}.employment-impact p{margin:5px 0;font-size:12px}.employment-history{margin-top:20px}.employment-dialog [data-error]{color:#a33d3d}.employment-dialog [data-preview]{padding:14px;background:#f5f8f3;border-radius:10px}.schedule-matrix td.inactive-cell{background:#f0f1ef!important;color:#8b928c;font-size:11px;cursor:default}

.employment-dialog [hidden]{display:none!important}
/* Scheduling relationship groups */
.relation-groups{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,320px),1fr));gap:16px;margin-top:12px}
.relation-card{border:1px solid #dde3e6;border-radius:12px;padding:18px;background:#fff;min-width:0}
.relation-card header{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:8px}
.relation-card h3{margin:0;font-size:17px}.relation-card p{line-height:1.7}
.relation-mode{font-size:12px;padding:4px 9px;border-radius:20px;background:#f1f4f5;color:#475569}
.relation-card .form-actions{display:flex;flex-wrap:wrap;gap:8px;margin:14px 0}
.relation-card details summary{cursor:pointer;min-height:36px;padding-top:8px}
.relation-members{display:grid;grid-template-columns:repeat(auto-fit,minmax(120px,1fr));gap:6px}
.relation-members label{display:flex;gap:8px;align-items:center;min-height:44px;padding:4px 8px;cursor:pointer}
.relation-dialog .field{display:flex;flex-direction:column;gap:8px;margin-bottom:16px}
.relation-dialog fieldset{margin:12px 0 20px;border:1px solid #dde3e6;border-radius:8px}
.relation-dialog .relation-options{display:grid;grid-template-columns:1fr 1fr;gap:16px}
.relation-dialog [data-roles]{display:grid;grid-template-columns:repeat(auto-fit,minmax(160px,1fr));gap:12px}
.relation-dialog [data-error]{color:#a63030}.relation-dialog [hidden]{display:none!important}
@media(max-width:560px){.relation-card{padding:14px}.relation-card .form-actions .btn{flex:1;min-height:44px}.relation-dialog .relation-options{grid-template-columns:1fr}}
.schedule-matrix tr.job-filter-hidden{display:none!important}

/* Distinguish key duties without changing day or leave backgrounds. */
.schedule-matrix td[data-job="帶位"]{color:#8b2635;font-weight:700}
.schedule-matrix td[data-job="櫃臺"]{color:#234b78;font-weight:700}

.department-catalogs{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:24px}
.department-catalogs section{min-width:0}
.department-catalogs .catalog-row{grid-template-columns:24px minmax(70px,1fr) repeat(4,auto);gap:4px}
@media(max-width:900px){.department-catalogs{grid-template-columns:1fr}}
@media(max-width:560px){.department-catalogs .catalog-row{grid-template-columns:24px repeat(4,1fr)}}

.kitchen-attendance{color:#15803d;font-size:12px;font-weight:700}

.employee-order-dialog{width:min(640px,94vw);max-height:90vh;border:1px solid #dce2dd;border-radius:14px;padding:22px;color:#29332f}.employee-order-dialog::backdrop{background:#0006}.employee-order-dialog h2{margin-top:0}.order-controls{display:flex;gap:10px;align-items:end;flex-wrap:wrap}.order-controls label{display:grid;gap:5px;flex:1;min-width:160px}.order-controls select{padding:9px;border:1px solid #cbd5e1;border-radius:7px;width:100%}.employee-order-list{padding:0;list-style:none;max-height:48vh;overflow:auto;border:1px solid #dce2dd;border-radius:8px}.employee-order-list li{display:flex;align-items:center;gap:12px;padding:8px;border-bottom:1px solid #edf0ed;background:white}.employee-order-list strong{flex:1}.employee-order-list small{color:#65706b}.order-handle{cursor:grab;border:0;border-radius:6px;background:#eef3ef;font-size:20px;padding:6px 10px;color:#496552}.order-handle:active{cursor:grabbing}.order-number,.employee-order-number{color:#65706b;min-width:22px;font-variant-numeric:tabular-nums}.employee-order-list .order-drop{box-shadow:inset 0 3px #15803d;background:#effaf1}.employee-order-dialog .form-actions{position:sticky;bottom:0;background:white;padding-top:10px}

.signup-list{display:grid;grid-template-columns:repeat(auto-fit,minmax(230px,1fr));gap:12px;max-height:60vh;overflow:auto;margin:14px 0}.signup-card{padding:14px;border:1px solid #dce2dd;border-radius:9px;background:#fff;white-space:normal}.signup-card small{display:block;margin-top:7px;color:#65706b}.signup-card p{margin:8px 0}.signup-link{display:inline-block;padding:8px 14px;border-radius:7px;background:#166534;color:white;text-decoration:none}#draftGaps,#shiftSignupAdmin{margin:16px 0;padding:14px;border:1px solid #dce2dd;border-radius:9px;background:#f8faf7}#draftGaps button{padding:8px 12px;border:1px solid #cbd5e1;border-radius:7px;background:white}#signupPanel button:disabled{opacity:.55;cursor:default}

#attendanceConfigForm .form-actions{align-items:center}#attendanceLocationStatus{max-width:420px}.attendance-status-complete{color:#166534;font-weight:700}.attendance-status-pending{color:#9a6700;font-weight:700}.attendance-policy-fields{margin-top:14px}.attendance-on-time{color:#166534;font-weight:700}.attendance-late{color:#b42318;font-weight:700}
.shift-definition-table-wrap{margin-top:14px}.shift-definition-table{width:100%;min-width:940px;border-collapse:collapse}.shift-definition-table th,.shift-definition-table td{padding:12px 10px;border:1px solid var(--line);vertical-align:middle;text-align:center}.shift-definition-table th{background:#f8faf8;color:#425247;font-size:13px}.shift-definition-table td:first-child,.shift-definition-table td:nth-child(2){min-width:118px}.shift-definition-table input{max-width:100%;margin:0}.shift-definition-table [data-shift-code]{width:82px;text-align:center;text-transform:uppercase}.shift-definition-table [data-shift-name]{width:135px;text-align:center}.shift-definition-table .shift-color-input{width:38px;height:30px;padding:2px;border:0;background:transparent;vertical-align:middle;cursor:pointer}.shift-definition-table .shift-time-range{display:flex;align-items:center;justify-content:center;gap:6px;white-space:nowrap}.shift-definition-table .shift-time-range input{width:112px}.shift-definition-table .shift-break{display:flex;align-items:center;justify-content:center;gap:5px;white-space:nowrap}.shift-definition-table .shift-break input{width:74px;text-align:right}.shift-work-hours{font-weight:700;color:#334b3d;white-space:nowrap}.shift-enabled{appearance:none;width:40px;height:22px;border:0;border-radius:999px;background:#aeb9b1;vertical-align:middle;cursor:pointer;position:relative;transition:background .18s}.shift-enabled::after{content:'';position:absolute;width:18px;height:18px;top:2px;left:2px;border-radius:50%;background:#fff;box-shadow:0 1px 3px #0003;transition:transform .18s}.shift-enabled:checked{background:#3694eb}.shift-enabled:checked::after{transform:translateX(18px)}.shift-definition-row.is-disabled{opacity:.62;background:#f6f7f6}.shift-definition-row.is-disabled .shift-work-hours{color:#76827a}@media(max-width:720px){.shift-definition-table{min-width:850px}.shift-definition-table th,.shift-definition-table td{padding:9px 7px}}

.settings-tabs{display:flex;gap:8px;flex-wrap:wrap;margin-bottom:18px;border-bottom:1px solid var(--line);padding-bottom:12px}.settings-tabs [role="tab"]{min-height:44px;padding:10px 18px;border:1px solid var(--line);border-radius:9px;background:#fff;color:#59635c;font:inherit;cursor:pointer}.settings-tabs [aria-selected="true"]{background:#e7eee8;border-color:#9eb8a5;color:#254d35;font-weight:700}.settings-tabs [role="tab"]:focus-visible,.settings-panel:focus-visible{outline:2px solid #4f8f7b;outline-offset:3px}.settings-panel[hidden]{display:none}

.shift-editor-dialog{width:min(620px,94vw);max-height:90vh;overflow:auto;border:1px solid var(--line);border-radius:14px;padding:24px;color:var(--text)}.shift-editor-dialog::backdrop{background:#0006}.shift-editor-dialog h2{margin-top:0}.shift-editor-guide{margin:-4px 0 16px;padding:10px 12px;border:1px solid #c9ddce;border-radius:8px;background:#f3f8f4;color:#315440;font-size:13px}.shift-editor-dialog .field small{display:block;margin-top:4px;color:#66756d;font-size:11px}.shift-editor-dialog .form-actions{margin-top:18px}.shift-color-swatch{display:inline-block;width:28px;height:28px;vertical-align:middle}.shift-row-actions{display:flex;gap:6px;justify-content:center;white-space:nowrap}#shiftEditorError{min-height:1.5em;margin:10px 0 0;color:#b42318;font-weight:700}
/* 每人每天一格：在格內堆疊班別與職務，點選後一次調整整天。 */
.schedule-slot-time-label{appearance:none;border:0;border-radius:5px;background:transparent;padding:2px 3px;color:#426055;font:inherit;cursor:pointer}.day-editor-controls>label{display:grid;gap:3px;min-width:0}.day-editor-controls>label>small{margin-left:0;text-align:left;color:#65756c;font-size:10px}
.schedule-slot.leave{background:#fff1f1}.schedule-slot.leave .schedule-slot-value{color:#b42318}.day-editor-controls{display:grid;grid-template-columns:minmax(0,1fr) 112px;gap:6px;min-width:0}@media(max-width:700px){.day-editor-shift{grid-template-columns:1fr}.day-editor-controls{grid-template-columns:minmax(0,1fr) 108px}}
.schedule-day-matrix .sticky-name{width:84px;min-width:84px;max-width:84px}.schedule-day-matrix th,.schedule-day-matrix td{min-width:49px}.schedule-day-matrix td.schedule-day-cell{height:auto;padding:0;vertical-align:top;cursor:pointer}.schedule-day-cell .schedule-slot{display:grid;grid-template-columns:minmax(0,1fr);grid-template-rows:20px 20px;align-items:center;gap:0;min-height:40px;padding:0 2px;border-bottom:1px solid #edf0ed;font-size:11px;text-align:center}.schedule-day-cell .schedule-slot:last-child{border-bottom:0}.schedule-slot-shift{display:flex;gap:4px;align-items:center;min-width:0;color:#607069;white-space:nowrap}.schedule-slot-shift b{font-size:10px;letter-spacing:.02em}.schedule-slot-shift i,.day-editor-shift i{display:inline-block;width:7px;height:7px;border-radius:50%;background:var(--shift-color);flex:0 0 auto}.schedule-slot-value{min-width:0;text-align:right;overflow:hidden;text-overflow:ellipsis;color:#33453d;font-weight:700;white-space:nowrap}.schedule-slot.o .schedule-slot-value{color:#6a9678}.schedule-slot.x .schedule-slot-value{color:#bd7d79}.schedule-slot.rest{background:#faf0ee}.schedule-slot.rest .schedule-slot-value{color:#945c55}.schedule-slot.job-highlight{background:#e3efe8;color:#245c43;box-shadow:inset 0 -2px 0 #80a68e}.schedule-slot.gap-focus{outline:2px solid #4f8f7b;outline-offset:-2px}.schedule-day-matrix td.schedule-day-cell.inactive-cell,.schedule-day-matrix td.schedule-day-cell.closed{text-align:center;vertical-align:middle}.cell-menu:has(.day-editor-fields){width:min(430px,calc(100vw - 16px));max-height:min(580px,calc(100vh - 16px));overflow:auto}.day-editor-head{padding:13px 14px 8px;border-bottom:1px solid #dce3de;background:#f7f9f7}.day-editor-head strong,.day-editor-head small{display:block}.day-editor-head small{margin-top:4px;color:#718078;font-size:11px}.day-editor-presets{display:flex;gap:6px;padding:8px 10px;border-bottom:1px solid #e5eae6;background:#fbfcfa}.day-editor-presets button,.day-leave{border:1px solid #d6e0da;border-radius:7px;background:#fff;color:#466357;padding:6px 8px;font-size:11px;font-weight:700;cursor:pointer}.day-editor-presets button:hover,.day-leave:hover{background:#eef5f0}.day-editor-fields{padding:8px 10px}.day-editor-shift{display:grid;grid-template-columns:minmax(110px,1fr) minmax(120px,1.1fr) auto;align-items:center;gap:8px;padding:8px 2px;border-bottom:1px solid #edf0ed}.day-editor-shift:last-child{border-bottom:0}.day-editor-shift>span{display:flex;align-items:center;gap:5px;min-width:0;color:#405049;font-size:12px}.day-editor-shift small{display:block;margin-left:auto;color:#7b8780;font-size:10px;white-space:nowrap}.day-editor-shift select{width:100%;min-width:0;padding:7px;border:1px solid #d6ddd8;border-radius:7px;background:#fff;color:#263b31}.day-leave{color:#8d5b54;border-color:#ead4d0}.day-editor-actions{position:sticky;bottom:0;justify-content:flex-end;background:#f6f8f6;border-top:1px solid #dce3de}.schedule-day-matrix tbody tr:hover td:not(.schedule-day-cell.inactive-cell):not(.schedule-day-cell.closed){box-shadow:inset 0 0 0 999px rgba(55,75,64,.035)}@media(max-width:700px){.schedule-day-matrix th,.schedule-day-matrix td{min-width:49px}.schedule-day-matrix .sticky-name{width:70px;min-width:70px;max-width:70px}.day-editor-shift{grid-template-columns:1fr 1fr}.day-leave{grid-column:1/-1}.day-editor-presets{flex-wrap:wrap}}
/* Stack each shift time above its job; keep empty shifts aligned across dates. */
.schedule-day-cell .schedule-slot-time-label{gap:2px;padding:2px 0;justify-content:center;align-self:stretch}
.schedule-day-cell .schedule-slot-value{text-align:center;line-height:20px}
.schedule-day-matrix tbody td{border-bottom-color:#cbd5ce}
.schedule-day-matrix td.editable:hover{outline:none}
.schedule-day-cell .schedule-slot{appearance:none;width:100%;border:0;border-bottom:1px solid #edf0ed;border-radius:0;background:transparent;font-family:inherit;color:inherit;cursor:pointer}
.schedule-day-cell .schedule-slot:hover,.schedule-day-cell .schedule-slot:focus-visible{outline:2px solid #8ca294;outline-offset:-2px}
.schedule-day-cell .schedule-slot.o{background:transparent}
.schedule-day-cell .schedule-slot.x{background:transparent}
.schedule-day-cell .schedule-slot.rest{background:#faf0ee}
.schedule-day-cell .schedule-slot.leave{background:#fff1f1}
.schedule-day-cell .schedule-slot.job-highlight{background:#e3efe8}

/* Shift editor: separate context, fields, secondary actions and save controls. */
.cell-menu:has(.day-editor-fields){width:min(440px,calc(100vw - 24px));padding:0;border:1px solid #cfdcd4;border-radius:14px;box-shadow:0 12px 40px #203d3226}
.day-editor-head{padding:18px 20px 14px}.day-editor-head strong{font-size:15px;line-height:1.6;overflow-wrap:anywhere}.day-editor-head small{font-size:12px;line-height:1.7;margin-top:6px}
.day-editor-fields{padding:16px 20px}.day-editor-fields .day-editor-shift{display:block;padding:0;border:0;margin:0}.day-editor-fields .day-editor-shift+.day-editor-shift{margin-top:20px}
.day-editor-shift>span{margin-bottom:14px;font-weight:700}.day-editor-shift>span small{font-size:12px;font-weight:400}.day-editor-shift .day-editor-controls{grid-template-columns:minmax(0,1fr) minmax(0,1.25fr);gap:14px}
.day-editor-controls>label>small{font-size:12px;font-weight:600;color:#52655a;margin-bottom:5px}.day-editor-controls select{height:42px;padding:8px 10px;font-size:14px;border-radius:8px;border-color:#bdcdc2;color:#263c34}.day-editor-controls select:focus-visible{outline:2px solid #4f8f7b;outline-offset:2px}
.day-editor-secondary{display:flex;align-items:center;gap:8px;margin-top:18px;padding-top:14px;border-top:1px solid #e5ebe6}.cell-menu .day-editor-secondary button{width:auto;min-width:64px;padding:7px 14px;border:1px solid #d4ddd6;border-radius:8px;text-align:center;background:#f4f6f3;color:#86928a;cursor:not-allowed;font-size:13px}.day-editor-secondary>small{margin-left:auto;font-size:11px;color:#7b8780}
.cell-menu .day-editor-actions{display:flex;gap:10px;padding:14px 20px;background:#f7f9f7}.cell-menu .day-editor-actions button{width:auto;min-height:42px;padding:9px 22px;border:1px solid #cbd8cf;text-align:center;font-weight:700}.cell-menu .day-editor-actions [data-day-cancel]{background:#fff;color:#52655a}.cell-menu .day-editor-actions [data-day-save]{background:#356b58;color:#fff;border-color:#356b58}.cell-menu .day-editor-actions [data-day-save]:hover{background:#295744}
.cross-department-mark{display:block;color:#c73535;font-size:16px;line-height:18px;font-weight:800}
@media(max-width:420px){.day-editor-shift .day-editor-controls{grid-template-columns:minmax(0,1fr);gap:12px}.day-editor-head,.day-editor-fields{padding:14px 16px}.cell-menu .day-editor-actions{padding:12px 16px}}

.day-editor-controls .day-editor-department{grid-column:1/-1}

.catalog-visibility{grid-column:2/-1;display:flex;align-items:center;gap:8px;font-size:12px;color:#52655a}.catalog-row .catalog-visibility input{width:16px;height:16px;padding:0;margin:0;accent-color:#356b58}

#attendancePolicyForm .section-head p{margin:6px 0 0}.attendance-rules-body{padding:20px 24px}.attendance-rules-summary{display:flex;gap:12px;align-items:center;padding:12px 16px;background:#edf4ef;border-radius:9px;font-size:13px;color:#315440}.attendance-rules-summary>span{color:#66776b;flex-shrink:0}.attendance-rule-block{padding:22px 0;border-bottom:1px solid #e0e6e1}.attendance-rule-block h3{font-size:15px;margin:0 0 6px}.attendance-rule-block p{font-size:12px;color:#68766e;line-height:1.7;margin:6px 0 14px}.attendance-rule-block>.field{display:block;max-width:440px;margin-top:16px}.attendance-rule-block .attendance-rule-hint{margin:10px 0 0}.attendance-rule-block fieldset{margin:18px 0 0;padding:16px;border:1px solid #dce5de;border-radius:9px;background:#fafbf9}.attendance-rule-block legend{font-size:12px;padding:0 6px;color:#56675c}.attendance-minute-input{display:flex;align-items:center;gap:10px}.attendance-minute-input input{max-width:110px;text-align:center}.attendance-minute-input>span{font-size:13px;color:#65746a}.attendance-late-heading{display:flex;justify-content:space-between;align-items:center;gap:18px}.attendance-late-heading p{margin-bottom:0}.attendance-rule-toggle{display:flex;align-items:center;gap:9px;white-space:nowrap;cursor:pointer;font-size:13px;font-weight:700;color:#456353}.attendance-rule-toggle input{appearance:none;width:40px;height:23px;border-radius:20px;background:#aebbb2;position:relative;margin:0;cursor:pointer;flex-shrink:0}.attendance-rule-toggle input::after{content:'';position:absolute;width:17px;height:17px;left:3px;top:3px;background:white;border-radius:50%;transition:transform .15s}.attendance-rule-toggle input:checked{background:#356b58}.attendance-rule-toggle input:checked::after{transform:translateX(17px)}.attendance-rule-toggle input:focus-visible{outline:2px solid #356b58;outline-offset:3px}#attendanceGraceFields{margin-top:16px}.attendance-rules-note{font-size:12px;color:#728078;line-height:1.7;margin:16px 0 0}.attendance-rules-footer{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:16px 24px;background:#f8faf7;border-top:1px solid #e0e6e1}.attendance-rules-footer .btn{flex-shrink:0;min-height:42px}.attendance-rules-footer [role=status]:empty{display:none}.attendance-rules-footer [role=status]{margin:6px 0 0}
@media(max-width:600px){.attendance-rules-body{padding:16px}.attendance-rules-summary{align-items:flex-start;flex-direction:column;gap:4px}.attendance-rule-block .cols-2{grid-template-columns:1fr}.attendance-late-heading{align-items:flex-start}.attendance-rules-footer{padding:16px;align-items:stretch;flex-direction:column}}

/* Attendance uses the same fixed 49px date columns as scheduling. */
.attendance-month{table-layout:fixed;width:calc(84px + var(--days)*49px);min-width:calc(84px + var(--days)*49px);border-collapse:separate;border-spacing:0;font-size:12px}
.attendance-month .attendance-person{width:84px}.attendance-month .attendance-day{width:49px}
.attendance-month th,.attendance-month td{padding:0;text-align:center;border-right:1px solid #ddd;border-bottom:1px solid #ddd;white-space:nowrap}
.attendance-month tr>th:first-child{position:sticky;left:0;z-index:2;background:#f4f7f5;width:84px;overflow:hidden;text-overflow:ellipsis}
.attendance-month thead th{height:44px}.attendance-month th small{display:block;font-weight:normal;color:#667}
.attendance-slot{display:flex;flex-direction:column;position:relative;width:100%;height:66px;padding:0;margin:0;border:0;border-bottom:1px solid #ddd;border-radius:0;background:transparent;color:#26332e;font:inherit;cursor:pointer;align-items:stretch;justify-content:center}
.attendance-slot span{display:block;height:22px;line-height:22px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.attendance-slot .attendance-late-in{color:#cf2525}
.attendance-slot .attendance-planned{background:#e6eee8;color:#466052;font-weight:600}.attendance-adjusted{color:#cf2525;font-weight:bold}
.attendance-slot i{position:absolute;right:0;bottom:0;font-size:9px;line-height:12px;background:#fff2cc;color:#804c00;font-style:normal}
.attendance-overlap{box-shadow:inset 0 0 0 1px #c57920}.attendance-month .attendance-closed{background:#f0f1ee;color:#787e78}.attendance-legacy{padding:16px}
.attendance-detail{width:min(560px,94vw);max-height:90vh;overflow:auto;border:1px solid #ddd;border-radius:14px;padding:24px}
.attendance-detail::backdrop{background:#0006}.attendance-detail label{display:grid;gap:6px;margin:12px 0}.attendance-detail input,.attendance-detail textarea{width:100%;box-sizing:border-box;padding:10px}
.attendance-short-review{width:min(560px,94vw);max-height:90dvh;overflow:auto;padding:24px}
.short-review-times{display:grid;grid-template-columns:1fr 1fr;gap:12px;background:#f4f7f4;border:1px solid #e0e7df;border-radius:12px;padding:14px;margin:16px 0}
.short-review-times span{display:grid;gap:6px;color:#64726a;font-size:13px}.short-review-times strong{font-size:24px;color:#2d4b3b}
.attendance-short-review fieldset{border:0;padding:0;margin:20px 0}.attendance-short-review legend{font-weight:650;margin-bottom:10px}
.attendance-short-review .short-review-choice{display:flex;align-items:flex-start;gap:12px;padding:14px;border:1px solid #dce4dc;border-radius:10px;margin:8px 0;cursor:pointer}
.attendance-short-review .short-review-choice:has(input:checked){background:#edf5ef;border-color:#52816a}.attendance-short-review input[type=radio]{width:18px;height:18px;flex-shrink:0;margin:2px 0;accent-color:#396b59}
.short-review-choice span{min-width:0}.short-review-choice small{display:block;line-height:1.6;margin-top:5px;color:#66746b}.attendance-short-review .form-actions{display:flex;justify-content:flex-end;gap:10px}.attendance-short-review [data-status]{color:#ad3636}
@media(max-width:520px){.attendance-short-review{padding:18px}.attendance-short-review .short-review-choice{padding:12px}.attendance-short-review h3{font-size:18px}}

#page-attendance .table-wrap{-webkit-text-size-adjust:100%;text-size-adjust:100%;overscroll-behavior-x:contain}.attendance-slot:focus-visible{outline:2px solid #356957;outline-offset:-2px}

/* Match schedule day/status colors; planned times use a muted green separator. */
.attendance-month .attendance-holiday{background:#fffbe8}.attendance-month .attendance-rest{background:#faf0ee;color:#945c55}.attendance-month .attendance-leave{background:#fff1f1;color:#b42318}.attendance-month .attendance-adjusted{color:#cf2525}.attendance-month .attendance-slot .attendance-adjusted{color:#cf2525}

/* Use the attendance planned-time color in the schedule grid. */
.schedule-day-cell .schedule-slot-time-label{background:#e6eee8;color:#466052;margin:0 -2px}.schedule-day-cell .schedule-slot-time-label b{font-weight:600}

/* Keep the full staffing workflow inside the monthly attention card. */
#gapPanel .schedule-attention{background:#fff;border:1px solid #dce3df;padding:16px;overflow:hidden}
#gapPanel .attention-heading{margin-bottom:12px}#gapPanel .attention-heading strong{font-size:15px}
#gapPanel .attention-actions>button{background:#f8faf8;border-color:#e0e6e1;color:#33473b}
#gapPanel .attention-actions>.attention-needs-action strong{color:#a65319}#gapPanel .attention-actions>.attention-needs-action{border-left:3px solid #d49657}
#gapPanel .attention-actions>.attention-review strong{color:#805717}
#gapPanel .attention-actions>button[aria-expanded=true]{border-color:#b8c7be;background:#f0f4f1}
#gapPanel .staffing-details{margin-top:14px;border-top:1px solid #e0e6e1}
#gapPanel .staffing-details>summary{padding:14px 0;font-size:13px;color:#40564a}
#gapPanel .staffing-body{padding:0}#gapPanel .staffing-body>p{margin:0 0 14px;line-height:1.7}
#gapPanel .staffing-columns{grid-template-columns:minmax(230px,1fr) minmax(260px,1.4fr);gap:16px}
#gapPanel .staffing-gaps,#gapPanel .staffing-candidates{min-width:0;border:1px solid #e1e6e2;border-radius:9px;padding:12px;background:#fafbf9}
#gapPanel .staffing-gaps h3,#gapPanel .staffing-candidates h3{font-size:13px;margin:0 0 12px;color:#40564a}
#gapPanel .staffing-gaps h3 small{font-weight:400;color:#78837c;margin-left:6px}
#gapPanel .staffing-candidates{max-height:390px}#gapPanel .staffing-candidates h4{margin:8px 0;font-size:14px}
#gapPanel .staffing-gap-list{padding:0;max-height:330px}
#gapPanel .staffing-gap{background:#fff;border-color:#e1e5df;padding:10px 12px;min-height:82px}
#gapPanel .staffing-gap[aria-pressed=true]{background:#fff8ef;border-color:#cc995e;box-shadow:inset 3px 0 #cc995e}
#gapPanel .staffing-gap:focus-visible{outline:2px solid #a66b32;outline-offset:-2px}
#gapPanel .staffing-gap .staffing-gap-heading{display:flex;align-items:center;justify-content:space-between;gap:10px;margin:0;color:#35453b}
#gapPanel .staffing-gap-count{font-size:12px;color:#a65319;background:#fff1df;padding:3px 7px;border-radius:5px;white-space:nowrap}
#gapPanel .staffing-gap .staffing-gap-job{color:#37493d;font-size:13px;margin-top:6px}
#gapPanel .staffing-gap .staffing-gap-meta{color:#758076;font-size:11px}
#gapPanel .staffing-empty{font-size:13px;color:#758076;line-height:1.8;padding:16px 8px;margin:0}
#gapPanel .staffing-overage-section{margin-top:14px;border-top:1px solid #e1e6e2}
#gapPanel .staffing-overage-section>summary{padding:12px 0;color:#805717;font-size:13px}
#gapPanel .staffing-overages{margin:0;background:#fffdf8}
@media(max-width:700px){#gapPanel .schedule-attention{padding:12px}#gapPanel .staffing-columns{grid-template-columns:minmax(0,1fr)}#gapPanel .staffing-gap-list{max-height:240px}#gapPanel .staffing-candidates{max-height:320px}}

#gapPanel .staffing-gap-item{display:grid;gap:4px;padding-bottom:8px;border-bottom:1px solid #e4e9e6}#gapPanel .staffing-dismiss{justify-self:end;border:1px solid #d9e0db;background:white;color:#627068;border-radius:6px;padding:6px 10px;font-size:12px;cursor:pointer}#gapPanel .staffing-dismiss:hover{background:#edf2ee}#gapPanel .staffing-ignored{border-top:1px solid #e1e7e2;margin-top:12px;padding-top:12px}#gapPanel .staffing-ignored-row{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:10px 0;border-bottom:1px solid #e6ebe7}#gapPanel [data-staffing-feedback]{color:#a44832}#gapPanel .staffing-gap{width:100%}

.row-actions .action.line-linked{background:#e4f1e7;border-color:#b9d5c0;color:#326146}.row-actions .action.line-linked:hover{background:#d4e9d9;border-color:#9cc3a7}

#employeeTbody .tag.part{background:#fbe9e8;color:#913f3c}


.attendance-method-options{display:flex;flex-wrap:wrap;gap:20px;padding:20px}.attendance-method-options label{display:flex;align-items:center;gap:8px;font-size:16px}.attendance-method-options input{width:20px;height:20px;accent-color:#396b59}.attendance-qr{padding:0 20px 20px}.attendance-qr img{display:block;max-width:100%;height:auto;background:white;margin:16px 0}.attendance-request{padding:18px 0;border-top:1px solid #dce2dc}.attendance-request h4{margin:0 0 10px}.attendance-request textarea{width:min(100%,520px);min-height:65px;padding:10px;font:inherit;border:1px solid #dce2dc;border-radius:8px}.attendance-request p{overflow-wrap:anywhere}.attendance-request-history{margin-top:20px}

.attendance-report{padding:16px;border-bottom:1px solid #dce2dd}
.attendance-report .table-wrap{max-height:320px;margin:12px 0}
.attendance-report table{width:100%;border-collapse:collapse}
.attendance-report th,.attendance-report td{padding:9px 12px;border-bottom:1px solid #e1e6e2;text-align:center;white-space:nowrap}
.attendance-report thead th{position:sticky;top:0;background:#edf3ee;z-index:1}
.attendance-report-flag{color:#a13e32;font-weight:700}
.attendance-report-totals{display:flex;gap:12px 24px;flex-wrap:wrap}
.attendance-report-totals strong{color:#a13e32}

/* Keep monthly records prominent; expand staff statistics only when needed. */
.attendance-report{padding:10px 16px}
.attendance-report-bar{display:flex;align-items:center;justify-content:space-between;gap:8px 16px;flex-wrap:wrap}
.attendance-report-totals{align-items:center;gap:6px 18px;font-size:13px}
.attendance-report-totals .attendance-report-title{color:#315943}
.attendance-report-bar [data-export]{flex-shrink:0;min-height:36px;padding:7px 12px}
.attendance-report [data-export-status]:empty{display:none}
.attendance-report [data-export-status]{margin:8px 0;font-size:13px}
.attendance-report-details{margin-top:8px}
.attendance-report-details>summary{cursor:pointer;color:#53695c;font-size:13px;line-height:1.6;min-height:32px}
.attendance-report-details>.muted{font-size:12px;line-height:1.6;margin:8px 0}
.attendance-report-details .table-wrap{max-height:260px;margin:8px 0}
@media(max-width:600px){.attendance-report{padding:10px 12px}.attendance-report-totals{gap:6px 12px}}


.attendance-tasks{padding:12px 16px;border:1px solid #e2d1ad;border-radius:12px;background:#fffdf6;margin-bottom:14px}.attendance-tasks h3{margin:0 0 8px}.attendance-tasks summary{cursor:pointer;padding:8px 0;font-weight:600}.attendance-task-list{max-height:360px;overflow:auto}.attendance-task-list p{line-height:1.6}.attendance-task-list .btn{margin:4px}.attendance-task-list input{max-width:320px}

.catalog-start-times{grid-column:2/-1;display:flex;flex-wrap:wrap;gap:8px 12px;align-items:end}.catalog-start-times label{display:grid;gap:4px;font-size:12px;color:#52655b;flex:1;min-width:135px}.catalog-start-times select{width:100%;min-width:0}.catalog-start-times>small{flex-basis:100%;color:#78857f}
.attendance-console .attendance-controls{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap;padding-bottom:16px}
.attendance-console .attendance-controls label{display:flex;align-items:center;gap:10px;font-weight:600;margin:0}
.attendance-console .attendance-controls input{width:auto;min-height:38px}
.attendance-console .attendance-control-actions{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.attendance-console .btn{width:auto;min-height:38px;margin:0;padding:8px 14px;font-size:14px;white-space:normal}
.attendance-console .attendance-report{padding:0}
.attendance-console .attendance-report-bar{padding:14px 0 4px}
.attendance-console .attendance-tasks{padding:0;margin:0;border:0;background:transparent}
.attendance-console .attendance-action-panel{border:1px solid #dce3df;border-radius:9px;margin:8px 0;background:#fff;overflow:hidden}
.attendance-console .attendance-action-panel>summary{display:flex;align-items:center;gap:10px;cursor:pointer;list-style:none;padding:12px 14px;min-height:48px;font-size:15px;font-weight:600;color:#304b40;line-height:1.5}
.attendance-console .attendance-action-panel>summary::-webkit-details-marker{display:none}
.attendance-console .attendance-action-panel>summary::before{content:'›';font-size:20px;line-height:1;transition:transform .15s}
.attendance-console .attendance-action-panel[open]>summary::before{transform:rotate(90deg)}
.attendance-console .attendance-action-panel>summary:hover{background:#f5f8f6}
.attendance-console .attendance-action-panel>summary:focus-visible{outline:2px solid #396b57;outline-offset:-3px}
.attendance-console .attendance-action-panel[open]>summary{border-bottom:1px solid #e6ebe8}
.attendance-console .attendance-action-panel small{font-size:12px;color:#78837d;font-weight:400;margin-left:6px}
.attendance-console .attendance-count{margin-left:auto;font-size:13px;font-weight:400;color:#78837d;text-align:right}
.attendance-console .attendance-count.has-items{color:#a13e32;font-weight:700}
.attendance-console .attendance-action-panel>p,.attendance-console .attendance-action-panel>.attendance-task-list,.attendance-console .attendance-action-body{margin:0;padding:12px 14px}
.attendance-console .attendance-request-toolbar{display:flex;align-items:center;justify-content:space-between;gap:12px}
.attendance-console .attendance-request-toolbar p{margin:0}
.attendance-console .attendance-stat-details{margin:0 0 12px}
.attendance-console .attendance-stat-details>summary{font-size:13px;padding:4px 0}
.attendance-console .attendance-report-totals strong{color:inherit}
.attendance-console .attendance-request{box-shadow:none}
@media(max-width:600px){.attendance-console .attendance-controls{align-items:stretch}.attendance-console .attendance-control-actions{width:100%}.attendance-console .attendance-controls label{width:100%}.attendance-console .attendance-controls input{flex:1;min-width:0}.attendance-console .attendance-action-panel small{display:block;margin-left:0}.attendance-console .attendance-action-panel>summary{padding:10px 12px}}

/* Scheduling controls only: the schedule matrix retains its existing layout. */
#page-schedule .schedule-workflow-card{padding:16px;margin-bottom:16px}
#page-schedule .schedule-workflow-card .schedule-month-tabs{margin:0 0 12px;gap:8px}
#page-schedule .schedule-workflow-card .schedule-progress{border:0;background:none;padding:0;margin:0;box-shadow:none;border-radius:0}
#page-schedule .schedule-workflow-card .schedule-next-step{border:0;border-top:1px solid var(--line);border-radius:0;box-shadow:none;background:none;margin:12px 0 0;padding:14px 0 0;align-items:center}
#page-schedule .schedule-next-step h3{font-size:17px;margin:0 0 6px}
#page-schedule .schedule-next-step p{margin:0 0 6px;font-size:13px}
#page-schedule .schedule-step-actions{gap:8px}
#page-schedule .schedule-review-card{padding:14px 16px;margin-bottom:16px}
#page-schedule .schedule-review-card #gapPanel{padding:0;margin:0;border:0;background:none}
#page-schedule #gapPanel .schedule-attention{padding:0;border:0;box-shadow:none;border-radius:0}
#page-schedule #gapPanel .attention-actions{gap:8px}
#page-schedule #gapPanel .attention-actions>button{padding:10px 12px;min-height:64px;border-radius:8px}
#page-schedule .schedule-review-card #shiftSignupAdmin{margin:0}
#page-schedule .schedule-review-card #shiftSignupAdmin>details,
#page-schedule .schedule-review-card .monthly-statistics,
#page-schedule .schedule-review-card #pairingWarnings .note{border:0;border-top:1px solid var(--line);border-radius:0;background:none;margin:0;padding:0;box-shadow:none}
#page-schedule .schedule-review-card #shiftSignupAdmin>details>summary,
#page-schedule .schedule-review-card .monthly-statistics>summary,
#page-schedule .schedule-review-card #pairingWarnings summary{padding:12px 0;font-size:13px;font-weight:600;color:#40564a;cursor:pointer}
#page-schedule .schedule-review-card .staffing-details{margin-top:12px}
#page-schedule .schedule-review-card .monthly-statistics[hidden]{display:none}
#page-schedule .schedule-tools-title{font-size:16px;margin:0 0 10px}
#page-schedule .schedule-instructions{margin:0 0 8px;color:var(--muted);font-size:12px}
#page-schedule .schedule-instructions>summary{cursor:pointer;padding:4px 0}
#page-schedule .schedule-instructions .schedule-help{padding:8px 0;margin:0}
#page-schedule .schedule-convenience{display:flex;align-items:flex-start;gap:8px;flex-wrap:wrap;margin:0 0 12px;padding:0}
#page-schedule .schedule-primary-tools{display:flex;align-items:center;flex-wrap:wrap;gap:8px;flex-basis:100%}
#page-schedule .schedule-convenience .btn,
#page-schedule .schedule-convenience>details>summary,
#page-schedule .schedule-step-actions .btn,
#page-schedule #scheduleOtherActions>summary{min-height:38px;padding:8px 12px;border-radius:8px;font-size:13px;margin:0}
#page-schedule .schedule-convenience>details{flex:1 1 220px;margin:0;border:1px solid var(--line);border-radius:8px;background:white}
#page-schedule .schedule-convenience>details>summary{cursor:pointer;color:#40564a;font-weight:600;border:0;background:transparent}
#page-schedule .schedule-convenience .schedule-extra-content{display:flex;flex-wrap:wrap;gap:8px;padding:10px;border-top:1px solid var(--line);position:static;box-shadow:none}
#page-schedule .schedule-convenience .schedule-extra-content .muted{flex-basis:100%}
#page-schedule .daily-view-tabs{margin:10px 0;padding:10px 0;border-top:1px solid var(--line);border-bottom:1px solid var(--line);gap:6px}
#page-schedule .daily-view-tabs .btn{min-height:36px;padding:7px 14px;font-size:13px}
@media(max-width:600px){#page-schedule .schedule-workflow-card,#page-schedule .schedule-review-card{padding:12px}#page-schedule .schedule-primary-tools .btn{flex:1 1 110px}#page-schedule .schedule-convenience>details{flex-basis:100%}}


@media(min-width:800px){#page-schedule .schedule-workflow-card{display:grid;grid-template-columns:auto 1fr;gap:0 20px}#page-schedule .schedule-workflow-card .schedule-month-tabs{margin:0}#page-schedule .schedule-workflow-card .schedule-progress{justify-content:flex-end;align-self:center;flex-wrap:wrap}#page-schedule .schedule-workflow-card .schedule-next-step{grid-column:1/-1}#page-schedule #gapPanel .attention-actions>button{display:flex;align-items:center;flex-wrap:wrap;gap:8px 14px;min-height:48px}#page-schedule #gapPanel .attention-actions>button small{margin-left:auto}}
#page-schedule .schedule-review-card #shiftSignupAdmin{padding:0;border:0;background:none;box-shadow:none;border-radius:0}
#page-schedule .schedule-review-card #shiftSignupAdmin>details{padding:0;background:none;border-radius:0;box-shadow:none}


/* Keep candidate actions beside the name; wrap gracefully in narrow panels. */
.staffing-person-heading{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:8px 12px}
.staffing-person-heading>strong{min-width:0;overflow-wrap:anywhere}
.staffing-person-actions{display:flex;flex-wrap:wrap;justify-content:flex-end;gap:6px;margin-left:auto;max-width:100%}
.staffing-person-actions .btn{margin:0;padding:6px 10px;min-height:36px;max-width:100%;white-space:normal}
@media(pointer:coarse){.staffing-person-actions .btn{min-height:44px}}

/* Keep the gap selector and dismissal as separate controls inside one card. */
#gapPanel .staffing-gap-item{grid-template-columns:minmax(0,1fr) auto;align-items:center;gap:8px;padding:0 10px 0 0;margin-bottom:8px;border:1px solid #e1e5df;border-radius:7px;background:#fff;overflow:hidden}
#gapPanel .staffing-gap-item:has(.staffing-gap[aria-pressed=true]){background:#fff8ef;border-color:#cc995e;box-shadow:inset 3px 0 #cc995e}
#gapPanel .staffing-gap-item .staffing-gap{min-width:0;margin:0;border:0;background:transparent;box-shadow:none;overflow-wrap:anywhere}
#gapPanel .staffing-gap-item .staffing-dismiss{margin:0;max-width:100px;min-height:36px;white-space:normal}
@media(pointer:coarse){#gapPanel .staffing-gap-item .staffing-dismiss{min-height:44px}}

.activity-filters{display:flex;gap:16px;align-items:end;flex-wrap:wrap}.activity-filters .field{min-width:180px}.activity-table-scroll{overflow:auto}.activity-history-view table{width:100%;min-width:780px;text-align:left}.activity-history-view td{vertical-align:top}.activity-history-view pre{white-space:pre-wrap;overflow-wrap:anywhere;font:inherit;max-width:420px;margin:8px 0 16px}.activity-history-view summary{cursor:pointer;white-space:nowrap}.activity-history-view small{overflow-wrap:anywhere}.activity-history-view [data-more]{margin-top:16px}

/* Employee editor: scoped panels and compact controls, with the same form IDs. */
#employeeFormCard.employee-editor{max-width:1180px;margin:20px auto 28px;padding:0 0 16px;background:#f4f7f4;border:1px solid #d9e3db;border-radius:18px;overflow:visible;box-shadow:0 10px 32px #203d320a}
#employeeFormCard>.employee-editor-header{padding:24px 28px;margin:0 0 20px;background:#eaf1eb;border-radius:18px 18px 0 0;align-items:flex-start;border-bottom:1px solid #d9e3db}
#employeeFormCard .employee-editor-eyebrow{font-size:11px;font-weight:700;color:#668474;letter-spacing:.16em}
#employeeFormCard #employeeFormTitle{font-size:24px;line-height:1.3;margin:5px 0 6px;color:#264b3a}
#employeeFormCard .employee-editor-header p{font-size:13px;color:#68796e;margin:0}
#employeeFormCard>.form-section{margin:14px 20px;padding:22px 24px;background:#fff;border:1px solid #e0e7e0;border-radius:12px}
#employeeFormCard .form-section-title{font-size:16px;line-height:1.5;font-weight:750;color:#284d3b;margin:0 0 6px}
#employeeFormCard .employee-section-caption{font-size:12px;color:#758278;margin:0 0 18px;line-height:1.6}
#employeeFormCard .form-grid{gap:18px 20px}
#employeeFormCard .field{min-width:0;gap:7px}
#employeeFormCard .field>span{font-size:12px;font-weight:650;color:#4d5f53}
#employeeFormCard input:not([type=checkbox]):not([type=range]),#employeeFormCard select{width:100%;min-width:0;box-sizing:border-box;min-height:42px;background:#fcfdfb;border:1px solid #d8e2d9;border-radius:8px;padding:9px 11px;color:#293d30;font-size:14px}
#employeeFormCard input:focus-visible,#employeeFormCard select:focus-visible{outline:2px solid #80a990;outline-offset:2px}
#employeeFormCard input[type=checkbox]{width:18px;height:18px;min-height:18px;flex:0 0 18px;margin:0;accent-color:#356b58;vertical-align:middle}
#employeeFormCard .check-box{display:flex;flex-wrap:wrap;gap:8px;padding:8px;background:#f6f8f5;border:1px solid #e4eae2;border-radius:9px;min-height:42px}
#employeeFormCard .check-box label{display:flex;align-items:center;gap:7px;min-height:34px;padding:5px 9px;border-radius:7px;font-size:13px;cursor:pointer}
#employeeFormCard .check-box label:has(input:checked){background:#e7f1e9;color:#29533b}
#employeeFormCard #employeeAvailabilityFields .check-box{display:grid;grid-template-columns:1fr;gap:3px}
#employeeFormCard #employeeAvailabilityFields .check-box label small{margin-left:auto;font-size:12px;white-space:nowrap}
#employeeFormCard .form-hint,#employeeFormCard .field small,#employeeFormCard .muted{font-size:12px;line-height:1.7;color:#738075}
#employeeFormCard .form-hint{margin-top:14px}
#employeeFormCard .range-field{padding:14px;background:#f7f9f6;border:1px solid #e7ece4;border-radius:10px}
#employeeFormCard .range-field>span{display:flex;justify-content:space-between;align-items:center}
#employeeFormCard .range-field b{font-size:17px;font-variant-numeric:tabular-nums;color:#356b58}
#employeeFormCard input[type=range]{width:100%;accent-color:#356b58;min-height:28px}
#employeeFormCard .range-scale{font-size:10px;color:#7b887c}
#employeeFormCard .employee-option{display:flex;align-items:center;gap:10px;padding:14px 16px;margin:16px 0 10px;background:#f2f7f1;border:1px solid #deeadc;border-radius:9px;font-size:13px;cursor:pointer}
#employeeFormCard .employee-setting-help{margin:12px 0;color:#627366;font-size:12px}
#employeeFormCard summary{cursor:pointer;padding:8px 0;min-height:36px}
#employeeFormCard .employee-advanced{margin-top:20px;border-top:1px solid #e3e9e1;padding-top:10px}
#employeeFormCard .employee-advanced>summary{font-size:14px;font-weight:700;color:#365841}
#employeeFormCard .employee-advanced>summary span{font-size:12px;font-weight:400;color:#7a877c;margin-left:14px}
#employeeFormCard .employee-advanced-content{padding-top:14px}
#employeeFormCard>.employee-editor-actions{position:sticky;bottom:12px;z-index:10;margin:20px 20px 0;padding:12px 16px;display:flex;align-items:center;gap:10px;background:#fffffff5;backdrop-filter:blur(10px);border:1px solid #d9e3da;border-radius:11px;box-shadow:0 5px 22px #203d3210}
#employeeFormCard .employee-editor-actions>span{margin-right:auto;font-size:12px;color:#738075}
#employeeFormCard .employee-editor-actions .primary{min-width:124px}
@media(max-width:900px){#employeeFormCard .form-grid.cols-4,#employeeFormCard .form-grid.cols-3{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:600px){#employeeFormCard>.employee-editor-header{padding:20px 16px}#employeeFormCard>.form-section{margin:12px 10px;padding:18px 14px}#employeeFormCard .form-grid.cols-3,#employeeFormCard .form-grid.cols-2{grid-template-columns:1fr}#employeeFormCard .form-grid.cols-4{grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}#employeeFormCard>.employee-editor-actions{margin:14px 10px 0;bottom:8px;padding:10px}#employeeFormCard .employee-editor-actions>span{display:none}#employeeFormCard .employee-editor-actions .primary{flex:1}#employeeFormCard .employee-advanced>summary span{display:block;margin-left:15px}#employeeFormCard #employeeAvailabilityFields .check-box label{flex-wrap:wrap}}
.replacement-trial{margin:20px 0;padding:16px;border:1px solid #cbd9d1;border-radius:12px;background:#f7faf8}
.replacement-trial-heading{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap}
.replacement-trial-card{padding:14px;margin-top:12px;border:1px solid #dce4df;border-radius:10px;background:#fff}
.replacement-trial li{margin:8px 0;overflow-wrap:anywhere}.replacement-trial small{display:block;color:#617168;margin-top:3px}
.replacement-trial-table{overflow-x:auto}.replacement-trial table{width:100%;border-collapse:collapse;text-align:left}.replacement-trial th,.replacement-trial td{padding:7px;border-bottom:1px solid #e1e7e3}.replacement-trial caption{text-align:left;color:#617168;font-size:12px;margin-bottom:6px}


/* Scheduling workspace: scoped to surrounding controls, not matrix geometry or cell colours. */
#page-schedule .schedule-head{margin:18px 0 14px;align-items:center}
#page-schedule .schedule-head h2{font-size:23px;letter-spacing:.02em;color:#264b3b}
#page-schedule .schedule-head .muted{margin-top:7px;line-height:1.6}
#page-schedule .schedule-workflow-card{display:block;padding:18px 20px;border-color:#d9e4dc;box-shadow:0 3px 12px #294b3c05}
#page-schedule .schedule-workflow-card .schedule-month-tabs{display:flex;gap:8px;margin:0 0 16px;overflow-x:auto;flex-wrap:nowrap;padding-bottom:2px}
#page-schedule .schedule-month-tabs button{flex:0 0 auto;min-width:130px;display:flex;align-items:center;gap:12px;padding:11px 14px;min-height:44px;border-radius:9px;background:#f7f9f6;border-color:#e1e7df;font-size:14px;color:#5c6b61}
#page-schedule .schedule-month-tabs button small{display:inline;font-size:11px;margin:0;padding:3px 7px;border-radius:5px;background:#e9eeea}
#page-schedule .schedule-month-tabs button[aria-selected=true]{background:#e9f2ec;border-color:#81a58f;box-shadow:inset 0 -2px #46755b;color:#284f3a;font-weight:750}
#page-schedule .schedule-workflow-card .schedule-progress{justify-content:space-between;gap:10px;padding:0;margin:0}
#page-schedule .schedule-progress ol{gap:5px}
#page-schedule .schedule-progress li{padding:5px 10px;color:#758078}
#page-schedule .schedule-progress li+li:before{content:'›';color:#a3afa6;margin-right:10px}
#page-schedule .schedule-progress li.current{background:#edf4ee;color:#315e44}
#page-schedule .schedule-workflow-card .schedule-next-step{display:flex;flex-direction:row;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:14px;margin-top:12px;padding-top:14px}
#page-schedule .schedule-next-step>div:first-child{flex:1 1 400px}
#page-schedule .schedule-step-actions{flex:0 1 auto;display:flex;align-items:center;flex-wrap:wrap}
#page-schedule .schedule-next-step h3{font-size:17px;font-weight:750;color:#294c3b}
#page-schedule .schedule-next-step p{max-width:none;font-size:12px;line-height:1.65}
#page-schedule .schedule-next-step .deadline-state{margin-top:5px;font-size:11px}
#page-schedule .schedule-next-step .muted{font-size:11px}
#page-schedule #btnAutoDraft,#page-schedule #btnPublish{min-height:42px;min-width:134px;box-shadow:0 2px 5px #315d4420}
#page-schedule .schedule-section-heading{display:flex;align-items:center;gap:12px;margin:0 0 12px}
#page-schedule .schedule-section-heading h3{margin:0;font-size:15px;color:#294c3b}
#page-schedule .schedule-section-heading>span{font-size:12px;color:#7a867d}
#page-schedule .schedule-review-card{padding:16px 20px;background:#fcfdfb}
#page-schedule #gapPanel .attention-heading{display:none}
#page-schedule #gapPanel .attention-actions{display:grid;grid-template-columns:repeat(auto-fit,minmax(240px,1fr));gap:10px;margin:0 0 8px}
#page-schedule #gapPanel .attention-actions>button{display:grid;grid-template-columns:1fr auto;gap:4px 10px;align-items:center;min-height:68px;padding:11px 14px;background:#fff;border:1px solid #e0e6dd;box-shadow:none}
#page-schedule #gapPanel .attention-actions>button strong{font-size:15px;grid-column:1;grid-row:2;color:#35553e}
#page-schedule #gapPanel .attention-actions>button small{grid-column:2;grid-row:1/3;margin:0;color:#62796a;font-size:11px}
#page-schedule #gapPanel .attention-actions>button:focus-visible{outline:2px solid #7ba58b;outline-offset:2px}
#page-schedule #gapPanel .staffing-details:not([open]){display:none}
#page-schedule .schedule-review-card #shiftSignupAdmin>details>summary,#page-schedule .schedule-review-card .monthly-statistics>summary{padding:10px 0;font-size:12px;color:#5c7162}
#page-schedule .schedule-card{border-color:#d8e2da}
#page-schedule .schedule-board-heading{display:flex;align-items:center;justify-content:space-between;gap:12px;margin:0 0 14px}
#page-schedule .schedule-board-heading h3{font-size:18px;color:#284e39;margin:0 0 5px}
#page-schedule .schedule-board-heading p{font-size:12px;color:#748176;margin:0;line-height:1.6}
#page-schedule #scheduleFocusMode{font-size:12px;min-height:38px;white-space:nowrap;background:#f5f8f4;border-color:#dbe4d9;color:#476a53}
#page-schedule #scheduleFocusMode[aria-pressed=true]{background:#e3efe6;border-color:#8cad96;color:#254d36}
#page-schedule .schedule-instructions{margin:0 0 8px}
#page-schedule .schedule-convenience{align-items:flex-start;padding:10px 0 14px;gap:8px;border-bottom:1px solid #e6ebe4;margin:0 0 12px}
#page-schedule .schedule-primary-tools{flex:1 1 auto;gap:7px}
#page-schedule .schedule-convenience>details{flex:0 1 auto;position:relative;background:#fafcf9;border-color:#e1e7dd}
#page-schedule .schedule-convenience>details>summary{padding:9px 13px;min-height:38px;font-size:12px;white-space:nowrap}
#page-schedule .schedule-convenience>details[open]{flex-basis:100%;order:5}
#page-schedule .schedule-convenience .schedule-extra-content{background:#f6f9f4;border-radius:0 0 8px 8px;margin:0;padding:12px;border-top:1px solid #e0e8dc}
#page-schedule .schedule-convenience .btn{font-size:12px;background:#fff;min-height:38px}
#page-schedule #btnBulkSchedule{background:#edf4ed;color:#315b3e;border-color:#c7d9c8;font-weight:700}
#page-schedule .schedule-view-controls{display:flex;align-items:end;justify-content:space-between;gap:14px;margin:12px 0;flex-wrap:wrap}
#page-schedule .schedule-view-options{display:flex;align-items:end;gap:16px;flex-wrap:wrap;flex:1}
#page-schedule .schedule-view-controls .daily-view-tabs{margin:0;padding:3px;background:#f0f3ef;border:1px solid #e0e6dc;border-radius:9px;display:flex;gap:3px}
#page-schedule .daily-view-tabs .btn{border:0;background:transparent;font-size:12px;min-height:34px;padding:7px 16px;color:#778276}
#page-schedule .daily-view-tabs .btn[aria-pressed=true]{background:white;box-shadow:0 1px 5px #23442c12;color:#2f593b}
#page-schedule .schedule-row-filter,#page-schedule .schedule-search{font-size:11px;color:#778273;display:grid;gap:5px;min-width:0}
#page-schedule .schedule-row-filter select,#page-schedule .schedule-search input{font:inherit;font-size:12px;color:#40583f;min-height:40px;padding:8px 10px;background:white;border:1px solid #dce4d7;border-radius:8px;max-width:100%;box-sizing:border-box}
#page-schedule .schedule-search input{width:180px}
#page-schedule .schedule-search[hidden],#page-schedule .schedule-search-result[hidden],#page-schedule .schedule-row-filter[hidden]{display:none}
#page-schedule .schedule-search-result{padding:10px 12px;background:#f1f6ed;color:#496343;border-radius:8px;font-size:12px;line-height:1.6}
#page-schedule .schedule-search-hidden{display:none!important}
#page-schedule .schedule-history-hint{font-size:12px;font-weight:400;color:#81907e;margin-left:12px}
#page-schedule.schedule-focus-mode>.schedule-head,#page-schedule.schedule-focus-mode>.schedule-workflow-card,#page-schedule.schedule-focus-mode>.schedule-review-card,#page-schedule.schedule-focus-mode>.schedule-history{display:none}
#page-schedule.schedule-focus-mode>.schedule-card{margin-top:8px}
@media(max-width:700px){
 #page-schedule .schedule-workflow-card,#page-schedule .schedule-review-card{padding:14px}
 #page-schedule .schedule-progress ol{width:100%;justify-content:space-between;gap:0}
 #page-schedule .schedule-progress li{padding:5px 4px;font-size:10px}
 #page-schedule .schedule-progress li+li:before{margin-right:4px}
 #page-schedule .schedule-next-step>div:first-child{flex-basis:100%}
 #page-schedule .schedule-section-heading{align-items:baseline;flex-wrap:wrap;gap:6px}
 #page-schedule #gapPanel .attention-actions{grid-template-columns:1fr}
 #page-schedule .schedule-primary-tools{flex:1 1 100%;flex-wrap:nowrap}
 #page-schedule .schedule-primary-tools .btn{flex:1;min-height:44px}
 #page-schedule .schedule-convenience>details{flex:1 1 30%;min-width:0}
 #page-schedule .schedule-convenience>details>summary{padding:10px 8px;font-size:11px}
 #page-schedule .schedule-convenience>details[open]{flex-basis:100%}
 #page-schedule .schedule-board-heading{align-items:flex-start}
 #page-schedule .schedule-board-heading p{max-width:220px}
 #page-schedule .schedule-view-options{flex-basis:100%;gap:10px}
 #page-schedule .schedule-view-controls .daily-view-tabs{flex:1 1 100%;flex-wrap:nowrap}
 #page-schedule .daily-view-tabs .btn{flex:1;white-space:nowrap}
 #page-schedule .schedule-row-filter{flex:1 1 160px}
 #page-schedule .schedule-search{width:100%}
 #page-schedule .schedule-search input{width:100%;font-size:16px}
 #page-schedule .schedule-history-hint{display:block;margin:6px 0 0 15px}
}

.attendance-attempt-list{display:grid;gap:12px;margin:14px 0}.attendance-attempt-card{border:1px solid #dce3ea;border-radius:10px;padding:14px;background:#fff;overflow-wrap:anywhere}.attendance-attempt-card p{margin:8px 0}.attendance-attempt-card small{color:#596675}

.calendar-confirmation{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:16px 20px;margin-bottom:16px;border:1px solid #cbd5e1;border-radius:12px;background:#f8fafc;color:#475569}.calendar-confirmation strong{display:block;margin-bottom:6px}.calendar-confirmation.confirmed{background:#edf8f0;border-color:#86b79a;color:#21613c}.calendar-confirmation.changed{background:#fff7e8;border-color:#dbac58;color:#855509}.calendar-confirmation .muted{font-size:13px;margin-top:4px}.calendar-confirmation button{flex-shrink:0}.calendar-confirmation button:disabled{opacity:.65}@media(max-width:640px){.calendar-confirmation{align-items:stretch;flex-direction:column}}


.dashboard-reminder-dialog{width:min(680px,calc(100vw - 32px));max-height:85dvh;overflow:auto;border:1px solid #dce5df;border-radius:16px;padding:20px;color:#243a2d}.dashboard-reminder-dialog::backdrop{background:#0006}.dashboard-reminder-dialog h2{font-size:20px}.dashboard-reminder-list article{display:grid;gap:6px;padding:12px 0;border-bottom:1px solid #e4e9e5}.dashboard-reminder-list small{color:#637267}.dashboard-reminder-message{white-space:pre-wrap;overflow-wrap:anywhere}.dashboard-reminder-actions{display:flex;gap:8px;margin:16px 0;flex-wrap:wrap}.dashboard-reminder-dialog .section-head{gap:12px;flex-wrap:wrap}

.reminder-template-editor{margin:20px 0;padding:16px;border:1px solid #dce2e8;border-radius:12px}.reminder-template-editor textarea{display:block;width:100%;box-sizing:border-box;resize:vertical;margin:12px 0;line-height:1.6}.reminder-template-editor pre{white-space:pre-wrap;overflow-wrap:anywhere;font:inherit;background:#f5f7fa;padding:12px;border-radius:8px}

.todo-list article>div:first-child{flex:1;min-width:0}.todo-actions{display:flex;align-items:center;justify-content:flex-end;gap:12px;flex-shrink:0;margin-left:auto;flex-wrap:wrap}@media(max-width:700px){.todo-actions{width:100%}}

.schedule-matrix .availability-confirmed-mark{display:inline-block;margin-left:4px;color:#15803d;font-weight:800;font-size:14px;line-height:1;vertical-align:middle}


.attendance-overtime-slot .attendance-overtime-approved,.attendance-detail .attendance-overtime-approved{color:#28643f;font-weight:600}

.attendance-month td.attendance-overtime-day{vertical-align:top}.attendance-overtime-day .attendance-overtime-slot{border-bottom:0}

.attendance-month td.attendance-closed-day{vertical-align:top;line-height:22px}
