/* ---- shift request table (grid) ---- */
.table-wrap{ background:var(--card); border:1px solid var(--line); border-radius:10px; overflow:auto; max-height:66vh; position:relative; }
.grid{ display:grid; font-size:12px; min-width:max-content; }
.cell{ border-right:1px solid var(--line-soft); border-bottom:1px solid var(--line-soft); display:flex; align-items:center; justify-content:center; padding:2px 4px; background:var(--card); }
.head-name, .head-memo, .head-total{ position:sticky; top:0; z-index:5; background:var(--navy-deep); color:#fff; font-weight:700; min-height:var(--header-h); }
.head-name{ left:0; z-index:6; }
.head-total{ left:96px; z-index:6; font-size:11px; }
.head-day{
  position:sticky; top:0; z-index:4; background:var(--navy-deep); color:#fff; font-weight:700;
  min-height:var(--header-h); flex-direction:column; justify-content:center; gap:3px; line-height:1.1; padding:6px 3px;
}
.head-day-date{ display:flex; flex-direction:column; align-items:center; gap:1px; }
.head-day .dow{ font-size:9px; font-weight:400; opacity:.75; }
.head-day.weekend{ background:#3a5580; }
.head-day.sat .dow{ color:#bcd4ff; }
.head-day.sun .dow{ color:#ffc7c7; }
.head-day.is-holiday{ background:#6e3232; }
.holiday-toggle{
  display:flex; align-items:center; gap:3px; font-size:9px; font-weight:400;
  color:#fff; cursor:pointer; user-select:none;
}
.holiday-toggle input{ width:11px; height:11px; cursor:pointer; accent-color:#ff8a80; }
.day-memo-list{ display:flex; flex-direction:column; gap:2px; width:100%; }
.day-memo-input{
  width:100%; box-sizing:border-box; font-size:9px; padding:2px 3px;
  border:1px solid rgba(255,255,255,.35); border-radius:3px;
  background:rgba(255,255,255,.14); color:#fff; text-align:center; font-family:inherit;
}
.day-memo-input::placeholder{ color:rgba(255,255,255,.55); }
.day-memo-input:focus{ background:#fff; color:var(--ink); outline:2px solid var(--accent); outline-offset:1px; }
.name-cell{ position:sticky; left:0; z-index:3; background:var(--paper); font-weight:700; color:var(--navy-deep); padding:8px 10px; justify-content:flex-start; min-width:96px; border-right:1px solid var(--line); }
.total-cell{
  position:sticky; left:96px; z-index:2; background:var(--accent-soft); color:var(--accent);
  font-weight:700; font-size:12px; border-right:1px solid var(--line); font-variant-numeric:tabular-nums;
}
.memo-cell{ padding:6px; min-width:220px; align-items:stretch; }
.memo-cell textarea{ width:100%; height:100%; min-height:60px; resize:none; border:1px solid var(--line); border-radius:6px; padding:6px 8px; font-size:12px; font-family:inherit; background:#fff; color:var(--ink); }
.memo-cell textarea:focus{ outline:2px solid var(--accent); outline-offset:1px; }
.day-col{ min-width:72px; }
.day-col.holiday-col{ background:#f5f0f0; }
.day-col.holiday-col .time-input,
.day-col.holiday-col .attend-select{ cursor:not-allowed; }
.sub-row{ height:var(--sub-h); flex-direction:column; padding:0; }
.time-input{ appearance:none; -webkit-appearance:none; width:56px; border:1px solid transparent; background:transparent; text-align:center; font-size:12px; color:var(--ink); border-radius:5px; padding:3px 2px; cursor:pointer; font-family:inherit; line-height:normal; }
.time-input:disabled{ color:#c3cad3; cursor:not-allowed; }
.time-input:not(.filled){ color:#c3cad3; }
.time-input:hover{ border-color:var(--line); background:#fff; }
.time-input.filled{ font-weight:700; color:var(--navy-deep); }
.attend-select{ width:56px; border:1px solid transparent; background:transparent; text-align:center; font-size:13px; font-weight:700; border-radius:5px; padding:3px 2px; cursor:pointer; color:var(--ink); font-family:inherit; }
.attend-select:disabled{ color:#c3cad3; cursor:not-allowed; }
.attend-select:hover{ border-color:var(--line); background:#fff; }
.attend-select:focus{ outline:2px solid var(--accent); outline-offset:1px; background:#fff;}
.day-col.state-tri .sub-row.attend{ background:var(--warn-bg); }
.day-col.state-tri .attend-select{ color:var(--warn-fg); }
.day-col.state-x .sub-row.attend{ background:var(--off-bg); }
.day-col.state-x .attend-select{ color:var(--off-fg); }
.weekend-col{ background:#fafbfd; }

.tp-card{
  background:#fff; border-radius:14px; box-shadow:0 16px 40px rgba(20,30,50,.28);
  padding:16px; font-size:12px; width:min(240px, 88vw);
  transform:translateY(8px); transition:.15s;
}
.modal-overlay.show .tp-card{ transform:translateY(0); }
.tp-selected{
  text-align:center; font-size:22px; font-weight:700; color:var(--navy-deep);
  padding:2px 0 12px; font-variant-numeric:tabular-nums; letter-spacing:.02em;
}
.tp-hour-grid{
  display:grid; grid-template-columns:repeat(3, 1fr); gap:6px; margin-bottom:10px;
}
.tp-hour-btn{
  border:1px solid var(--line); background:var(--paper); color:var(--ink);
  border-radius:8px; padding:9px 0; font-size:13px; font-weight:600; cursor:pointer;
  font-variant-numeric:tabular-nums; transition:.1s;
}
.tp-hour-btn:hover{ border-color:var(--accent); background:var(--accent-soft); }
.tp-hour-btn.selected{ background:var(--accent); border-color:var(--accent); color:#fff; }
.tp-minute-row{ display:flex; gap:6px; margin-bottom:12px; }
.tp-minute-btn{
  flex:1; border:1px solid var(--line); background:var(--paper); color:var(--ink);
  border-radius:8px; padding:9px 0; font-size:13px; font-weight:600; cursor:pointer;
  font-variant-numeric:tabular-nums; transition:.1s;
}
.tp-minute-btn:hover{ border-color:var(--accent); background:var(--accent-soft); }
.tp-minute-btn.selected{ background:var(--accent); border-color:var(--accent); color:#fff; }
.tp-minute-btn:disabled{ opacity:.35; cursor:not-allowed; background:var(--paper); border-color:var(--line); }
.tp-actions{ display:flex; gap:8px; justify-content:space-between; }
.tp-actions button{ flex:1; border:none; border-radius:8px; padding:10px 0; font-size:13px; font-weight:700; cursor:pointer; }
.tp-clear{ background:var(--paper); color:#8792a0; border:1px solid var(--line) !important; }
.tp-ok{ background:var(--navy-deep); color:#fff; }
.tp-ok:hover{ background:var(--accent); }
