/* ==================================================
   STAFF PORTAL — PROFESSIONAL DESIGN
   ================================================== */
* { margin: 0; padding: 0; box-sizing: border-box; font-family: 'Inter', -apple-system, sans-serif; }
html, body { max-width: 100%; overflow-x: hidden; }
body { background: #f4f6fa; color: #1a1a1a; line-height: 1.5; -webkit-font-smoothing: antialiased; }
button { font-family: inherit; cursor: pointer; }

/* ==================================================
   LOGIN SCREEN
   ================================================== */
.staff-login-screen {
  display: flex; align-items: center; justify-content: center;
  min-height: 100vh;
  background: linear-gradient(135deg, #0b2545 0%, #1e3a8a 50%, #0b2545 100%);
  padding: 20px; position: relative; overflow: hidden;
}
.staff-login-screen::before {
  content: ''; position: absolute; top: -50%; right: -20%;
  width: 600px; height: 600px; border-radius: 50%;
  background: radial-gradient(circle, rgba(230,57,70,0.15) 0%, transparent 70%);
}
.staff-login-screen::after {
  content: ''; position: absolute; bottom: -30%; left: -15%;
  width: 500px; height: 500px; border-radius: 50%;
  background: radial-gradient(circle, rgba(42,157,143,0.12) 0%, transparent 70%);
}
.staff-login-box {
  background: #fff; border-radius: 24px;
  padding: 48px 40px; width: 100%; max-width: 440px;
  box-shadow: 0 30px 80px rgba(0,0,0,0.4);
  text-align: center; position: relative; z-index: 1;
}
.staff-login-logo {
  width: 80px; height: 80px; margin: 0 auto 20px;
  background: linear-gradient(135deg, #e63946, #c92a37);
  border-radius: 20px; display: flex; align-items: center; justify-content: center;
  font-size: 40px; box-shadow: 0 12px 30px rgba(230,57,70,0.35);
}
.staff-login-box h1 { font-size: 26px; color: #0b2545; margin-bottom: 6px; font-weight: 800; }
.staff-login-box p { color: #64748b; font-size: 14px; margin-bottom: 20px; font-weight: 500; }
.staff-login-divider {
  height: 1px; background: linear-gradient(90deg, transparent, #e2e8f0, transparent);
  margin-bottom: 24px;
}
.staff-input-group {
  position: relative; margin-bottom: 14px;
}
.staff-input-icon {
  position: absolute; left: 16px; top: 50%; transform: translateY(-50%);
  font-size: 16px; opacity: 0.5;
}
.staff-input-group input {
  width: 100%; padding: 14px 16px 14px 46px;
  border: 1.5px solid #e2e8f0; border-radius: 12px;
  font-size: 14.5px; outline: none; font-family: inherit;
  background: #f8fafc; transition: all 0.2s;
}
.staff-input-group input:focus {
  border-color: #e63946; background: #fff;
  box-shadow: 0 0 0 4px rgba(230,57,70,0.1);
}
.staff-login-btn {
  width: 100%; background: linear-gradient(135deg, #e63946, #c92a37);
  color: #fff; border: none; padding: 15px;
  border-radius: 12px; font-size: 15px; font-weight: 700;
  margin-top: 6px; transition: all 0.3s;
  box-shadow: 0 8px 20px rgba(230,57,70,0.3);
}
.staff-login-btn:hover { transform: translateY(-2px); box-shadow: 0 12px 28px rgba(230,57,70,0.4); }
.staff-back-link {
  display: inline-block; margin-top: 20px; color: #64748b;
  font-size: 13px; text-decoration: none; font-weight: 600;
  transition: color 0.2s;
}
.staff-back-link:hover { color: #0b2545; }
.staff-error {
  background: #fef2f2; color: #b91c1c;
  padding: 12px 16px; border-radius: 10px;
  font-size: 13px; margin-bottom: 16px;
  display: none; text-align: left;
  border-left: 3px solid #e63946;
  font-weight: 500;
}
.staff-error.show { display: block; }

/* ==================================================
   HEADER
   ================================================== */
.staff-header {
  background: linear-gradient(135deg, #0b2545 0%, #1e3a8a 100%);
  padding: 16px 28px;
  display: flex; justify-content: space-between; align-items: center;
  box-shadow: 0 4px 20px rgba(11,37,69,0.15);
  position: sticky; top: 0; z-index: 100;
}
.staff-header-left { display: flex; align-items: center; gap: 14px; color: #fff; }
.staff-header-logo {
  width: 42px; height: 42px; border-radius: 10px;
  background: linear-gradient(135deg, #e63946, #c92a37);
  display: flex; align-items: center; justify-content: center;
  font-size: 22px; box-shadow: 0 4px 12px rgba(230,57,70,0.3);
}
.staff-header-left strong { display: block; font-size: 15px; font-weight: 800; }
.staff-header-left small { font-size: 11px; color: #94a3b8; font-weight: 500; }
.staff-logout-btn {
  background: rgba(255,255,255,0.1);
  border: 1.5px solid rgba(255,255,255,0.2);
  color: #fff; padding: 9px 18px; border-radius: 10px;
  font-size: 13px; font-weight: 600;
  display: flex; align-items: center; gap: 6px;
  transition: all 0.2s;
}
.staff-logout-btn:hover { background: #e63946; border-color: #e63946; }

/* ==================================================
   CONTENT
   ================================================== */
.staff-content { max-width: 760px; margin: 0 auto; padding: 24px 20px 60px; }

/* ==================================================
   PROFILE CARD
   ================================================== */
.staff-profile-card {
  background: #fff; border-radius: 18px;
  padding: 24px; box-shadow: 0 4px 24px rgba(11,37,69,0.06);
  margin-bottom: 16px;
  display: flex; align-items: center; gap: 18px;
  border: 1px solid #eef2f7;
  transition: all 0.3s;
}
.staff-profile-card:hover { box-shadow: 0 8px 32px rgba(11,37,69,0.1); }
.staff-profile-avatar {
  width: 72px; height: 72px; border-radius: 18px;
  background: linear-gradient(135deg, #e63946, #c92a37);
  color: #fff; display: flex; align-items: center; justify-content: center;
  font-size: 28px; font-weight: 800; text-transform: uppercase;
  flex-shrink: 0;
  box-shadow: 0 8px 20px rgba(230,57,70,0.25);
}
.staff-profile-info { flex: 1; min-width: 0; }
.staff-profile-info h2 { font-size: 22px; color: #0b2545; margin-bottom: 4px; font-weight: 800; }
.staff-code {
  font-size: 12px; color: #94a3b8; font-weight: 700;
  letter-spacing: 0.5px; margin-bottom: 10px;
  display: inline-block; padding: 3px 10px;
  background: #f1f5f9; border-radius: 8px;
}
.staff-profile-meta { display: flex; gap: 8px; flex-wrap: wrap; font-size: 12px; }
.staff-profile-meta span {
  background: #f1f5f9; color: #475569;
  padding: 5px 12px; border-radius: 12px;
  font-weight: 600; display: inline-flex; align-items: center; gap: 4px;
}

/* ==================================================
   TIME CARD
   ================================================== */
.staff-time-card {
  background: linear-gradient(135deg, #0b2545 0%, #1e3a8a 100%);
  color: #fff; border-radius: 18px;
  padding: 28px; text-align: center;
  margin-bottom: 16px;
  box-shadow: 0 12px 32px rgba(11,37,69,0.2);
  position: relative; overflow: hidden;
}
.staff-time-card::before {
  content: ''; position: absolute; top: -50%; right: -30%;
  width: 300px; height: 300px; border-radius: 50%;
  background: radial-gradient(circle, rgba(230,57,70,0.15), transparent 70%);
}
.staff-time-header {
  font-size: 11.5px; color: #94a3b8; font-weight: 700;
  letter-spacing: 1.2px; margin-bottom: 10px;
  display: flex; align-items: center; justify-content: center; gap: 8px;
  position: relative; z-index: 1;
}
.staff-time-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: #2a9d8f;
  box-shadow: 0 0 0 0 rgba(42,157,143,0.7);
  animation: pulse 2s infinite;
}
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(42,157,143,0.7); }
  70% { box-shadow: 0 0 0 10px rgba(42,157,143,0); }
  100% { box-shadow: 0 0 0 0 rgba(42,157,143,0); }
}
.staff-time-value {
  font-size: 44px; font-weight: 800;
  letter-spacing: -1.5px;
  font-variant-numeric: tabular-nums;
  margin-bottom: 6px; position: relative; z-index: 1;
}
.staff-date-value { font-size: 14px; color: #cbd5e1; font-weight: 500; position: relative; z-index: 1; }

/* ==================================================
   STATUS CARD
   ================================================== */
.staff-status-card {
  background: #fff; border-radius: 18px;
  padding: 34px 24px; text-align: center;
  box-shadow: 0 4px 24px rgba(11,37,69,0.06);
  margin-bottom: 16px;
  border: 1px solid #eef2f7;
  transition: all 0.4s;
  position: relative; overflow: hidden;
}
.staff-status-card::before {
  content: ''; position: absolute; top: 0; left: 0;
  width: 100%; height: 4px;
  background: linear-gradient(90deg, #94a3b8, #cbd5e1);
  transition: all 0.4s;
}
.staff-status-card.checked-in { background: linear-gradient(135deg, #f0fdf4, #dcfce7); border-color: #86efac; }
.staff-status-card.checked-in::before { background: linear-gradient(90deg, #10b981, #059669); }
.staff-status-card.checked-out { background: linear-gradient(135deg, #eff6ff, #dbeafe); border-color: #93c5fd; }
.staff-status-card.checked-out::before { background: linear-gradient(90deg, #3b82f6, #1e40af); }
.staff-status-card.absent { background: linear-gradient(135deg, #fef2f2, #fee2e2); border-color: #fca5a5; }
.staff-status-card.absent::before { background: linear-gradient(90deg, #ef4444, #dc2626); }
.staff-status-card.week-off { background: linear-gradient(135deg, #f8fafc, #e2e8f0); border-color: #cbd5e1; }
.staff-status-card.week-off::before { background: linear-gradient(90deg, #64748b, #475569); }
.staff-status-icon {
  font-size: 60px; margin-bottom: 14px;
  display: inline-block; line-height: 1;
  animation: fadeInScale 0.5s ease;
}
@keyframes fadeInScale {
  from { opacity: 0; transform: scale(0.8); }
  to { opacity: 1; transform: scale(1); }
}
.staff-status-card h3 { font-size: 24px; color: #0b2545; margin-bottom: 8px; font-weight: 800; }
.staff-status-card.absent h3 { color: #991b1b; }
.staff-status-card.week-off h3 { color: #334155; }
.staff-status-card p { font-size: 14px; color: #64748b; font-weight: 500; }
.staff-status-card.absent p { color: #b91c1c; }

/* ==================================================
   ACTIONS
   ================================================== */
.staff-actions { display: grid; grid-template-columns: 1fr; gap: 12px; margin-bottom: 20px; }
.staff-action-btn {
  padding: 22px; border: none; border-radius: 16px;
  font-size: 17px; font-weight: 700;
  display: flex; align-items: center; justify-content: center; gap: 10px;
  transition: all 0.3s;
}
.btn-icon { font-size: 20px; }
.staff-action-btn.checkin {
  background: linear-gradient(135deg, #2a9d8f, #21867a);
  color: #fff; box-shadow: 0 10px 25px rgba(42,157,143,0.3);
}
.staff-action-btn.checkout {
  background: linear-gradient(135deg, #e63946, #c92a37);
  color: #fff; box-shadow: 0 10px 25px rgba(230,57,70,0.3);
}
.staff-action-btn:hover { transform: translateY(-3px); }
.staff-action-btn:active { transform: translateY(-1px); }
.staff-action-btn:disabled {
  background: #cbd5e1; cursor: not-allowed;
  transform: none; box-shadow: none;
}

/* ==================================================
   STATS
   ================================================== */
.staff-stats-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-bottom: 20px; }
.staff-stat-box {
  background: #fff; padding: 22px;
  border-radius: 16px;
  box-shadow: 0 4px 24px rgba(11,37,69,0.06);
  text-align: center;
  border: 1px solid #eef2f7;
  transition: all 0.3s;
}
.staff-stat-box:hover { transform: translateY(-3px); box-shadow: 0 8px 28px rgba(11,37,69,0.1); }
.stat-icon { font-size: 24px; margin-bottom: 8px; }
.staff-stat-box .label {
  font-size: 11px; color: #94a3b8; font-weight: 800;
  text-transform: uppercase; letter-spacing: 0.8px; margin-bottom: 8px;
}
.staff-stat-box .value { font-size: 26px; font-weight: 800; color: #0b2545; margin-bottom: 4px; }
.staff-stat-box .sub { font-size: 12px; color: #64748b; font-weight: 600; }

/* ==================================================
   SECTIONS
   ================================================== */
.staff-section-box {
  background: #fff; border-radius: 18px;
  padding: 24px;
  box-shadow: 0 4px 24px rgba(11,37,69,0.06);
  margin-bottom: 16px;
  border: 1px solid #eef2f7;
}
.staff-section-header {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 18px; padding-bottom: 14px;
  border-bottom: 2px solid #f1f5f9;
}
.staff-section-box h3 { font-size: 16px; color: #0b2545; font-weight: 800; }
.staff-section-count {
  font-size: 11px; color: #64748b; font-weight: 700;
  background: #f1f5f9; padding: 4px 10px; border-radius: 10px;
  text-transform: uppercase; letter-spacing: 0.5px;
}

/* TODAY'S LOG */
.staff-today-log .log-row {
  display: flex; justify-content: space-between;
  padding: 14px 0;
  border-bottom: 1px solid #f1f5f9;
  font-size: 14px;
}
.staff-today-log .log-row:last-child { border-bottom: none; }
.staff-today-log .log-row .label { color: #64748b; font-weight: 500; }
.staff-today-log .log-row .value { font-weight: 700; color: #0b2545; }

/* MONTH RECORDS */
.staff-attendance-list { max-height: 500px; overflow-y: auto; padding-right: 4px; }
.staff-attendance-list::-webkit-scrollbar { width: 6px; }
.staff-attendance-list::-webkit-scrollbar-track { background: #f1f5f9; border-radius: 3px; }
.staff-attendance-list::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 3px; }
.staff-attendance-list::-webkit-scrollbar-thumb:hover { background: #94a3b8; }

.att-item {
  padding: 14px 16px;
  border-radius: 12px;
  margin-bottom: 8px;
  background: #f8fafc;
  border: 1px solid #eef2f7;
  transition: all 0.2s;
}
.att-item:hover { background: #f1f5f9; }
.att-item:last-child { margin-bottom: 0; }
.att-row-1 {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 6px;
}
.att-date { font-size: 14px; font-weight: 800; color: #0b2545; }
.att-status-badge {
  font-size: 10.5px; font-weight: 800;
  padding: 4px 12px; border-radius: 20px;
  text-transform: uppercase; letter-spacing: 0.5px;
  background: #d1fae5; color: #065f46;
}
.att-status-badge.late { background: #fef3c7; color: #92400e; }
.att-status-badge.absent { background: #fee2e2; color: #991b1b; }
.att-status-badge.off { background: #e2e8f0; color: #334155; }
.att-status-badge.pending { background: #dbeafe; color: #1e40af; }
.att-row-2 {
  display: flex; gap: 16px;
  font-size: 12.5px; color: #64748b;
  flex-wrap: wrap; font-weight: 500;
}
.att-row-2 span { display: flex; align-items: center; gap: 4px; }
.att-hours { color: #2a9d8f; font-weight: 800; }

/* Absent / Off row styles */
.att-item.att-absent {
  background: linear-gradient(135deg, #fef2f2 0%, #fee2e2 100%);
  border-left: 4px solid #ef4444;
  border-color: #fecaca;
}
.att-item.att-absent .att-date { color: #991b1b; }
.att-item.att-absent .att-row-2 { color: #b91c1c; }

.att-item.att-off {
  background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
  border-left: 4px solid #94a3b8;
  border-color: #cbd5e1;
}
.att-item.att-off .att-date { color: #334155; }

/* ==================================================
   FOOTER
   ================================================== */
.staff-footer {
  text-align: center; padding: 24px 0;
  color: #94a3b8; font-size: 12px;
  border-top: 1px solid #e2e8f0;
  margin-top: 20px;
}
.staff-footer p { font-weight: 500; }

/* ==================================================
   TOAST
   ================================================== */
.staff-toast {
  position: fixed; bottom: 30px; right: 30px;
  background: #0b2545; color: #fff;
  padding: 14px 24px; border-radius: 12px;
  font-weight: 600; z-index: 5000;
  opacity: 0; transform: translateY(20px);
  transition: all 0.3s;
  font-size: 14px;
  box-shadow: 0 12px 30px rgba(11,37,69,0.3);
  border-left: 4px solid #2a9d8f;
  max-width: 340px;
}
.staff-toast.show { opacity: 1; transform: translateY(0); }
.staff-toast.error {
  border-left-color: #e63946;
  background: #1a0505;
}

/* ==================================================
   RESPONSIVE
   ================================================== */
@media (max-width: 640px) {
  .staff-content { padding: 16px 14px 60px; }
  .staff-header { padding: 14px 16px; }
  .logout-text { display: none; }
  .staff-logout-btn { padding: 9px 12px; }
  .staff-time-value { font-size: 34px; }
  .staff-profile-card { padding: 18px; gap: 14px; }
  .staff-profile-avatar { width: 60px; height: 60px; font-size: 24px; border-radius: 14px; }
  .staff-profile-info h2 { font-size: 18px; }
  .staff-stat-box .value { font-size: 22px; }
  .staff-status-card { padding: 26px 18px; }
  .staff-status-icon { font-size: 48px; }
  .staff-status-card h3 { font-size: 20px; }
  .staff-action-btn { padding: 18px; font-size: 15px; }
  .staff-toast { right: 14px; left: 14px; bottom: 20px; max-width: none; }
  .staff-login-box { padding: 36px 26px; }
  .staff-login-logo { width: 68px; height: 68px; font-size: 34px; }
}
/* ===== JOB INSPECTION PORTAL ===== */
.staff-inspection-box{margin-top:18px}
.staff-mini-btn{border:1px solid #dbe3ef;background:#fff;color:#0b2545;border-radius:8px;padding:7px 10px;font-weight:700;cursor:pointer}
.staff-inspection-list{display:grid;gap:10px;padding:12px}
.staff-inspection-job{border:1px solid #e2e8f0;border-radius:12px;padding:14px;background:#fff;display:flex;justify-content:space-between;gap:12px;align-items:center}
.staff-inspection-job h4{margin:0 0 5px;color:#0b2545;font-size:14px}.staff-inspection-job p{margin:2px 0;color:#64748b;font-size:12px}
.staff-inspection-open{border:0;background:#0b2545;color:#fff;border-radius:8px;padding:9px 12px;font-weight:700;cursor:pointer}
.staff-inspection-modal{display:none;position:fixed;inset:0;background:rgba(2,12,27,.65);z-index:9999;padding:20px;overflow:auto}
.staff-inspection-modal.open{display:flex;align-items:flex-start;justify-content:center}.staff-inspection-dialog{width:min(980px,100%);background:#fff;border-radius:16px;box-shadow:0 20px 60px rgba(0,0,0,.25);margin:20px auto;position:relative;overflow:hidden}
.staff-inspection-close{position:absolute;right:14px;top:12px;border:0;background:#f1f5f9;border-radius:8px;width:34px;height:34px;cursor:pointer;font-size:16px}.staff-inspection-head{background:linear-gradient(135deg,#0b2545,#1e3a8a);color:#fff;padding:22px 24px}.staff-inspection-head h3{margin:0 0 5px}.staff-inspection-head p{margin:0;color:#cbd5e1;font-size:13px}
.staff-inspection-table-wrap{padding:18px;overflow:auto}.staff-inspection-table{width:100%;border-collapse:collapse;min-width:700px}.staff-inspection-table th{background:#f8fafc;color:#475569;text-align:left;padding:10px;font-size:11px}.staff-inspection-table td{border-top:1px solid #e2e8f0;padding:10px;vertical-align:middle;font-size:13px}.staff-insp-status{display:flex;gap:6px;flex-wrap:wrap}.staff-insp-status button{border:1px solid #cbd5e1;background:#fff;border-radius:7px;padding:7px 9px;cursor:pointer;font-weight:700;font-size:11px}.staff-insp-status button.active{box-shadow:0 0 0 2px #0b2545 inset}.staff-insp-remark{width:100%;min-width:180px;border:1px solid #cbd5e1;border-radius:7px;padding:8px;box-sizing:border-box}.staff-inspection-submit{margin:0 18px 18px;width:calc(100% - 36px);border:0;background:#0b2545;color:#fff;border-radius:10px;padding:12px;font-weight:800;cursor:pointer}.staff-empty-inspection{text-align:center;padding:24px;color:#94a3b8}
@media(max-width:700px){.staff-inspection-job{align-items:flex-start;flex-direction:column}.staff-inspection-open{width:100%}}


/* ==================================================
   MY ROT PERFORMANCE — SELF ONLY REPORT
   ================================================== */
.staff-rot-performance-box{padding:0;overflow:hidden}
.staff-rot-report-head{padding:22px 24px;margin:0;background:linear-gradient(135deg,#0b2545,#173f73);border:0;color:#fff}
.staff-rot-report-head h3{color:#fff;font-size:19px;margin:0 0 5px}
.staff-rot-report-head p{margin:0;color:#cbd5e1;font-size:12px;font-weight:600}
.staff-self-only-badge{font-size:10px;font-weight:900;letter-spacing:.65px;background:rgba(255,255,255,.14);border:1px solid rgba(255,255,255,.22);padding:7px 10px;border-radius:999px;color:#fff;white-space:nowrap}
.staff-rot-report-toolbar{display:grid;grid-template-columns:minmax(170px,1fr) minmax(170px,1fr) auto;gap:12px;padding:18px 24px;background:#f8fafc;border-bottom:1px solid #e2e8f0;align-items:end}
.staff-rot-report-toolbar label{display:grid;gap:6px;color:#475569;font-size:11px;font-weight:800;text-transform:uppercase;letter-spacing:.45px}
.staff-rot-report-toolbar input,.staff-rot-report-toolbar select{width:100%;box-sizing:border-box;border:1px solid #cbd5e1;border-radius:10px;background:#fff;color:#0f172a;padding:10px 12px;font:inherit;font-size:13px;outline:none}
.staff-rot-report-toolbar input:focus,.staff-rot-report-toolbar select:focus{border-color:#0b2545;box-shadow:0 0 0 3px rgba(11,37,69,.08)}
.staff-rot-refresh{height:40px;background:#0b2545;color:#fff;border-color:#0b2545}
.staff-rot-summary-grid{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:12px;padding:20px 24px 10px}
.staff-rot-summary-card{border:1px solid #e2e8f0;border-radius:14px;padding:15px;background:#fff;min-width:0}
.staff-rot-summary-card span{display:block;color:#64748b;font-size:10px;font-weight:900;text-transform:uppercase;letter-spacing:.6px;margin-bottom:6px}
.staff-rot-summary-card strong{display:block;color:#0b2545;font-size:22px;line-height:1.15;margin-bottom:5px}
.staff-rot-summary-card small{display:block;color:#94a3b8;font-size:10.5px;font-weight:600;line-height:1.35}
.staff-rot-report-note{margin:10px 24px 18px;border:1px solid #bfdbfe;background:#eff6ff;color:#1e3a8a;padding:11px 13px;border-radius:10px;font-size:11.5px;line-height:1.55}
.staff-rot-report-table-wrap{overflow:auto;border-top:1px solid #e2e8f0}
.staff-rot-report-table{width:100%;border-collapse:collapse;min-width:1120px}
.staff-rot-report-table th{position:sticky;top:0;background:#f8fafc;color:#475569;text-align:left;font-size:10px;text-transform:uppercase;letter-spacing:.45px;padding:11px 12px;border-bottom:1px solid #e2e8f0;white-space:nowrap}
.staff-rot-report-table td{padding:12px;border-bottom:1px solid #eef2f7;color:#334155;font-size:11.5px;vertical-align:top;line-height:1.45}
.staff-rot-report-table tbody tr:hover{background:#f8fafc}
.staff-rot-empty{text-align:center!important;color:#94a3b8!important;padding:28px!important}
.staff-rot-empty.error{color:#b91c1c!important;background:#fef2f2}
.staff-rot-status{display:inline-flex;align-items:center;padding:5px 9px;border-radius:999px;font-size:9.5px;font-weight:900;text-transform:uppercase;letter-spacing:.45px;background:#e2e8f0;color:#334155;white-space:nowrap}
.staff-rot-status.status-completed{background:#dcfce7;color:#166534}
.staff-rot-status.status-running{background:#dbeafe;color:#1d4ed8}
.staff-rot-status.status-paused{background:#fef3c7;color:#92400e}
.staff-rot-status.status-assigned{background:#f1f5f9;color:#475569}
@media(max-width:900px){.staff-rot-summary-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.staff-rot-report-toolbar{grid-template-columns:1fr 1fr}.staff-rot-refresh{grid-column:1/-1}}
@media(max-width:640px){.staff-rot-report-head{padding:18px 16px}.staff-rot-report-toolbar{grid-template-columns:1fr;padding:14px 16px}.staff-rot-refresh{grid-column:auto;width:100%}.staff-rot-summary-grid{grid-template-columns:1fr 1fr;padding:16px}.staff-rot-summary-card:last-child{grid-column:1/-1}.staff-rot-report-note{margin:0 16px 16px}.staff-rot-report-table th,.staff-rot-report-table td{padding:10px}}

/* ==================================================
   STAFF PORTAL v220 — FULL SCREEN WORKSHOP ERP LAYOUT
   ================================================== */
#staffDashboard{min-height:100vh;background:#eef2f7}
.staff-app-shell{min-height:100vh;display:grid;grid-template-columns:210px minmax(0,1fr);background:#eef2f7}
.staff-sidebar{position:sticky;top:0;height:100vh;background:#0b2b4d;color:#fff;display:flex;flex-direction:column;border-right:1px solid rgba(255,255,255,.07);z-index:300}
.staff-sidebar-brand{height:82px;display:flex;align-items:center;gap:11px;padding:0 18px;border-bottom:1px solid rgba(255,255,255,.09)}
.staff-sidebar-logo{font-size:23px}.staff-sidebar-brand strong{display:block;font-size:14px}.staff-sidebar-brand small{display:block;color:#8fb2d1;font-size:10px;margin-top:2px}
.staff-sidebar-user{margin:16px 12px 8px;padding:12px;border:1px solid rgba(255,255,255,.1);border-radius:12px;background:rgba(255,255,255,.05);display:flex;align-items:center;gap:10px;min-width:0}
.staff-sidebar-avatar{width:38px;height:38px;border-radius:10px;background:#173f73;display:grid;place-items:center;font-weight:900;flex:0 0 auto}.staff-sidebar-user div:last-child{min-width:0}.staff-sidebar-user strong{display:block;font-size:12px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.staff-sidebar-user small{display:block;color:#9bb8d2;font-size:9.5px;margin-top:2px}
.staff-sidebar-nav{padding:8px;display:grid;gap:5px}.staff-nav-item{border:0;width:100%;background:transparent;color:#e8f1fa;display:flex;align-items:center;gap:11px;text-align:left;padding:11px 12px;border-radius:9px;font-size:12px}.staff-nav-item span{width:22px;text-align:center;font-size:15px}.staff-nav-item b{font-weight:700}.staff-nav-item:hover{background:rgba(255,255,255,.07)}.staff-nav-item.active{background:#173f73;box-shadow:inset 3px 0 0 #3b82f6;color:#fff}
.staff-sidebar-bottom{margin-top:auto;padding:10px;display:grid;gap:7px}.staff-side-link,.staff-side-logout{width:100%;border:1px solid rgba(255,255,255,.16);background:rgba(255,255,255,.05);color:#e8f1fa;border-radius:8px;padding:10px 12px;text-decoration:none;text-align:left;font-size:11px;font-weight:700}.staff-side-logout{border-color:rgba(248,113,113,.4);color:#fecaca}.staff-side-link:hover,.staff-side-logout:hover{background:rgba(255,255,255,.1)}
.staff-main-area{min-width:0;min-height:100vh}.staff-workshop-topbar{height:82px;background:linear-gradient(90deg,#0b2b4d,#1e3f7d);color:#fff;display:flex;align-items:center;justify-content:space-between;padding:0 26px;box-shadow:0 2px 10px rgba(15,23,42,.12);position:sticky;top:0;z-index:200}.staff-workshop-topbar h1{font-size:19px;margin:0;font-weight:800}.staff-workshop-topbar p{font-size:10.5px;color:#bdd0e4;margin:3px 0 0}.staff-topbar-right{display:flex;align-items:center;gap:12px;font-size:10.5px;color:#d7e3ef;font-weight:700}.staff-live-badge{padding:5px 10px;border-radius:999px;border:1px solid rgba(255,255,255,.2);background:rgba(255,255,255,.1);font-size:9.5px}.staff-live-badge::first-letter{color:#4ade80}
.staff-content.staff-content-wide{max-width:none;width:100%;margin:0;padding:22px 24px 50px}.staff-view{display:none}.staff-view.active{display:block}.staff-profile-hero{margin-bottom:16px;border-radius:14px;box-shadow:0 2px 12px rgba(15,23,42,.05)}
.staff-dashboard-grid{display:grid;grid-template-columns:minmax(280px,.9fr) minmax(340px,1.1fr);gap:15px}.staff-dashboard-grid .staff-time-card,.staff-dashboard-grid .staff-status-card{margin-bottom:0;min-height:230px}.staff-dashboard-grid .staff-status-card{padding:25px 22px}.staff-dashboard-grid .staff-actions{margin-top:16px}.staff-stats-wide{grid-template-columns:repeat(2,minmax(0,1fr));margin:15px 0}.staff-quick-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px}.staff-quick-grid button{border:1px solid #dbe4ef;background:#fff;border-radius:14px;padding:18px;text-align:left;box-shadow:0 2px 12px rgba(15,23,42,.04)}.staff-quick-grid button:hover{border-color:#93b4da;transform:translateY(-1px)}.staff-quick-grid button span{display:block;font-size:24px;margin-bottom:11px}.staff-quick-grid button strong{display:block;color:#0b2545;font-size:14px;margin-bottom:4px}.staff-quick-grid button small{color:#64748b;font-size:10.5px;line-height:1.4}
.staff-section-box{border-radius:14px;box-shadow:0 2px 12px rgba(15,23,42,.05);border:1px solid #dde5ef;background:#fff}.staff-section-header{padding:18px 20px;border-bottom:1px solid #e7edf4;display:flex;align-items:center;justify-content:space-between;gap:16px}.staff-section-header h3{margin:0;color:#0b2545;font-size:15px}.staff-section-header p{margin:4px 0 0;color:#7b8da3;font-size:10.5px}.staff-mini-btn{border-color:#cbd8e6;background:#fff;color:#0b2b4d}.staff-mini-btn:hover{background:#f5f8fb}
.staff-work-rule{margin:16px 18px 0;padding:11px 13px;border:1px solid #bfdbfe;border-radius:9px;background:#eff6ff;color:#1e3a8a;font-size:10.5px;line-height:1.5}
.staff-rot-loading{padding:35px;text-align:center;color:#7c8da0;font-size:12px}.staff-rot-service-error{margin:18px;border:1px solid #fecaca;background:#fff1f2;border-radius:12px;padding:20px;text-align:center;display:grid;gap:7px;justify-items:center;color:#991b1b}.staff-rot-service-error b{font-size:15px}.staff-rot-service-error span{font-size:11px}.staff-rot-service-error button{border:0;background:#991b1b;color:#fff;padding:8px 13px;border-radius:8px;font-weight:700}
.staff-rot-work-summary{display:flex;align-items:center;gap:10px;padding:18px 20px 5px}.staff-rot-work-summary b{font-size:25px;color:#0b2545}.staff-rot-work-summary span{font-size:11px;color:#64748b;font-weight:700}.staff-rot-work-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:13px;padding:12px 18px 18px}.staff-rot-work-card{border:1px solid #d9e3ee;border-radius:13px;background:#fff;overflow:hidden;box-shadow:0 2px 10px rgba(15,23,42,.04)}.staff-rot-work-card.is-completed{background:#fbfdfc}.staff-rot-work-top{padding:15px 16px 11px;display:flex;justify-content:space-between;gap:14px;align-items:flex-start;border-bottom:1px solid #edf2f7}.staff-rot-code{font-size:9px;font-weight:900;letter-spacing:.65px;color:#1d4ed8;text-transform:uppercase}.staff-rot-work-top h4{font-size:14px;color:#0f2745;margin:4px 0 0;line-height:1.35}.staff-rot-work-status{flex:0 0 auto;border-radius:999px;padding:5px 9px;font-size:9px;font-weight:900;text-transform:uppercase;letter-spacing:.4px;background:#e2e8f0;color:#475569}.staff-rot-work-status.running{background:#dbeafe;color:#1d4ed8}.staff-rot-work-status.paused{background:#fef3c7;color:#92400e}.staff-rot-work-status.completed{background:#dcfce7;color:#166534}.staff-rot-work-meta{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:0;background:#f8fafc}.staff-rot-work-meta span{padding:11px 14px;border-right:1px solid #e9eef4;border-bottom:1px solid #e9eef4;min-width:0}.staff-rot-work-meta small{display:block;color:#8494a8;font-size:8.5px;font-weight:900;letter-spacing:.55px;margin-bottom:4px}.staff-rot-work-meta b{display:block;color:#243b55;font-size:11px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.staff-rot-work-note{padding:9px 14px;background:#fffbea;border-top:1px solid #f7e7a8;border-bottom:1px solid #f7e7a8;color:#725b16;font-size:10px;line-height:1.45}.staff-rot-work-note b{color:#5b4508}.staff-rot-work-actions{padding:13px 15px;display:flex;gap:8px;align-items:center;flex-wrap:wrap}.staff-rot-action{border:0;border-radius:8px;padding:9px 13px;font-size:10.5px;font-weight:800}.staff-rot-action.primary{background:#0b2b4d;color:#fff}.staff-rot-action.pause{background:#f59e0b;color:#fff}.staff-rot-action.complete{background:#16a34a;color:#fff}.staff-rot-action:disabled{background:#cbd5e1;color:#64748b;cursor:not-allowed}.staff-rot-action-note{color:#b45309;font-size:9.5px;font-weight:700}.staff-rot-completed-line{padding:10px 14px;color:#166534;font-size:9.5px;font-weight:700}.staff-recent-completed{border-top:1px solid #e8eef5;margin-top:4px}.staff-recent-completed>h4{padding:16px 20px 0;color:#334155;font-size:12px}.completed-grid{padding-top:10px}.staff-rot-empty-state{margin:18px;padding:34px;text-align:center;border:1px dashed #cbd5e1;border-radius:12px;color:#7b8da3;display:grid;gap:6px}.staff-rot-empty-state div{font-size:30px}.staff-rot-empty-state b{color:#334155;font-size:13px}.staff-rot-empty-state span{font-size:10.5px}.staff-rot-empty-state.compact{margin-top:12px;padding:24px}
.staff-rot-performance-box{border-radius:14px}.staff-rot-report-head{border-radius:13px 13px 0 0}.staff-rot-summary-grid{grid-template-columns:repeat(5,minmax(150px,1fr))}.staff-rot-report-table-wrap{max-width:100%}
@media(max-width:1050px){.staff-app-shell{grid-template-columns:176px minmax(0,1fr)}.staff-sidebar-brand{padding:0 13px}.staff-nav-item{padding:10px 9px}.staff-rot-work-grid{grid-template-columns:1fr}.staff-quick-grid{grid-template-columns:1fr 1fr}.staff-dashboard-grid{grid-template-columns:1fr}.staff-rot-summary-grid{grid-template-columns:repeat(3,minmax(150px,1fr));overflow:auto}}
@media(max-width:760px){.staff-app-shell{display:block}.staff-sidebar{position:sticky;height:auto;top:0;display:block}.staff-sidebar-brand{height:58px}.staff-sidebar-user{display:none}.staff-sidebar-nav{display:flex;overflow:auto;padding:6px}.staff-nav-item{min-width:max-content;width:auto;padding:9px 11px}.staff-nav-item b{font-size:10px}.staff-sidebar-bottom{display:none}.staff-workshop-topbar{height:66px;padding:0 14px}.staff-workshop-topbar h1{font-size:16px}.staff-workshop-topbar p{display:none}.staff-topbar-right #staffTopDate{display:none}.staff-content.staff-content-wide{padding:14px 12px 40px}.staff-profile-hero{align-items:flex-start}.staff-dashboard-grid{grid-template-columns:1fr}.staff-quick-grid{grid-template-columns:1fr}.staff-stats-wide{grid-template-columns:1fr 1fr}.staff-rot-work-grid{padding:10px 12px 14px}.staff-rot-work-meta{grid-template-columns:1fr 1fr}.staff-rot-summary-grid{grid-template-columns:repeat(2,minmax(145px,1fr));padding:14px;overflow:auto}.staff-section-header{padding:15px}.staff-work-rule{margin:12px 12px 0}.staff-rot-report-toolbar{padding:14px}.staff-rot-report-note{margin:0 14px 14px}}


/* ==================================================
   STAFF PORTAL v242 — WORKSHOP ERP / CUSTOMER DB STYLE
   ================================================== */
@media (min-width: 761px) {
  body.staff-portal-v242 { overflow: hidden; background:#eef2f7; }
  body.staff-portal-v242 #staffDashboard { height:100vh; overflow:hidden; }
  body.staff-portal-v242 .staff-app-shell {
    height:100vh; min-height:100vh;
    grid-template-columns:200px minmax(0,1fr);
    background:#eef2f7;
  }
  body.staff-portal-v242 .staff-sidebar {
    position:relative; top:auto; height:100vh; overflow:hidden;
    background:#0d2d50;
  }
  body.staff-portal-v242 .staff-sidebar-brand { height:74px; padding:0 18px; }
  body.staff-portal-v242 .staff-sidebar-user { margin:12px 10px 6px; padding:10px; }
  body.staff-portal-v242 .staff-sidebar-nav { padding:8px 7px; gap:5px; overflow-y:auto; }
  body.staff-portal-v242 .staff-nav-item {
    min-height:42px; border-radius:8px; padding:10px 11px;
    color:#edf5ff; font-size:11.5px;
  }
  body.staff-portal-v242 .staff-nav-item.active {
    background:#163d72; box-shadow:inset 3px 0 0 #ef3340;
  }
  body.staff-portal-v242 .staff-main-area {
    height:100vh; overflow:auto; background:#eef2f7;
  }
  body.staff-portal-v242 .staff-workshop-topbar {
    position:sticky; top:0; height:74px; padding:0 24px;
    background:linear-gradient(90deg,#123563,#1c4381);
    border-bottom:1px solid rgba(255,255,255,.08);
  }
  body.staff-portal-v242 .staff-content.staff-content-wide {
    padding:20px 22px 34px; max-width:none; width:100%;
  }
  body.staff-portal-v242 .staff-view { width:100%; }
  body.staff-portal-v242 .staff-profile-card,
  body.staff-portal-v242 .staff-section-box,
  body.staff-portal-v242 .staff-time-card,
  body.staff-portal-v242 .staff-status-card,
  body.staff-portal-v242 .staff-stat-box,
  body.staff-portal-v242 .staff-quick-grid button {
    border-radius:12px;
    box-shadow:0 2px 10px rgba(15,23,42,.05);
  }
  body.staff-portal-v242 .staff-profile-hero {
    padding:18px 20px; margin-bottom:14px;
    border:1px solid #dbe4ef;
  }
  body.staff-portal-v242 .staff-profile-avatar {
    width:58px; height:58px; border-radius:12px; font-size:23px;
  }
  body.staff-portal-v242 .staff-profile-info h2 { font-size:19px; }
  body.staff-portal-v242 .staff-dashboard-grid {
    grid-template-columns:minmax(360px,1fr) minmax(360px,1fr);
    gap:14px;
  }
  body.staff-portal-v242 .staff-dashboard-grid .staff-time-card,
  body.staff-portal-v242 .staff-dashboard-grid .staff-status-card {
    min-height:190px; padding:22px;
  }
  body.staff-portal-v242 .staff-time-value { font-size:38px; }
  body.staff-portal-v242 .staff-stats-row.staff-stats-wide { gap:14px; margin:14px 0; }
  body.staff-portal-v242 .staff-stat-box { border:1px solid #dbe4ef; background:#fff; }
  body.staff-portal-v242 .staff-quick-grid { gap:14px; }
  body.staff-portal-v242 .staff-quick-grid button { min-height:118px; }
  body.staff-portal-v242 .staff-section-box { overflow:hidden; }
  body.staff-portal-v242 .staff-section-header { background:#fff; }
  body.staff-portal-v242 .staff-footer { margin-top:22px; }
}

/* Hide legacy top-level stacked layout artifacts if older CSS remains cached. */
.staff-portal-v242 #staffDashboard .staff-view:not(.active){display:none!important}
.staff-portal-v242 #staffDashboard .staff-view.active{display:block!important}
.staff-portal-v242 #staffDashboard .staff-content{max-width:none!important;width:100%!important;margin:0!important}

/* ==================================================
   ATTENDANCE MONTH HISTORY V250
   ================================================== */
.staff-attendance-head p{
  margin:5px 0 0;
  color:#64748b;
  font-size:12.5px;
  font-weight:600;
}
.staff-attendance-toolbar{
  display:flex;
  align-items:flex-end;
  gap:10px;
  flex-wrap:wrap;
  margin:0 0 16px;
  padding:14px;
  background:#f8fafc;
  border:1px solid #dbe5f1;
  border-radius:12px;
}
.staff-attendance-toolbar label{
  display:grid;
  gap:6px;
  min-width:210px;
}
.staff-attendance-toolbar label span{
  font-size:10px;
  color:#64748b;
  text-transform:uppercase;
  letter-spacing:.8px;
  font-weight:800;
}
.staff-attendance-toolbar input[type="month"]{
  height:40px;
  border:1px solid #cbd5e1;
  border-radius:9px;
  background:#fff;
  color:#0b2545;
  padding:0 12px;
  font-weight:700;
  outline:none;
}
.staff-attendance-toolbar input[type="month"]:focus{
  border-color:#2563eb;
  box-shadow:0 0 0 3px rgba(37,99,235,.10);
}
.staff-attendance-refresh{
  background:#0b2545!important;
  color:#fff!important;
  border-color:#0b2545!important;
}
.staff-attendance-summary-grid{
  display:grid;
  grid-template-columns:repeat(6,minmax(0,1fr));
  gap:10px;
  margin-bottom:16px;
}
.staff-att-summary{
  min-height:88px;
  border:1px solid #dbe5f1;
  background:#fff;
  border-radius:12px;
  padding:14px;
  display:flex;
  flex-direction:column;
  justify-content:center;
}
.staff-att-summary span{
  font-size:10px;
  text-transform:uppercase;
  letter-spacing:.75px;
  color:#64748b;
  font-weight:800;
  margin-bottom:7px;
}
.staff-att-summary strong{
  color:#0b2545;
  font-size:22px;
  line-height:1;
}
.staff-attendance-table-wrap{
  width:100%;
  overflow:auto;
  border:1px solid #dbe5f1;
  border-radius:12px;
  background:#fff;
}
.staff-attendance-table{
  width:100%;
  min-width:760px;
  border-collapse:collapse;
}
.staff-attendance-table th{
  background:#f8fafc;
  color:#475569;
  font-size:10px;
  text-transform:uppercase;
  letter-spacing:.7px;
  font-weight:800;
  text-align:left;
  padding:12px 14px;
  border-bottom:1px solid #dbe5f1;
  white-space:nowrap;
}
.staff-attendance-table td{
  color:#334155;
  font-size:12.5px;
  padding:12px 14px;
  border-bottom:1px solid #eef2f7;
  white-space:nowrap;
}
.staff-attendance-table tr:last-child td{border-bottom:none;}
.staff-attendance-table tbody tr:hover{background:#f8fbff;}
.staff-att-empty{
  text-align:center!important;
  color:#94a3b8!important;
  padding:30px 16px!important;
  white-space:normal!important;
}
.att-status-badge.present{background:#dcfce7;color:#166534;}
.att-status-badge.half-day{background:#ede9fe;color:#6d28d9;}
.att-status-badge.leave{background:#dbeafe;color:#1d4ed8;}

@media (max-width:1100px){
  .staff-attendance-summary-grid{grid-template-columns:repeat(3,minmax(0,1fr));}
}
@media (max-width:640px){
  .staff-attendance-toolbar{align-items:stretch;}
  .staff-attendance-toolbar label{min-width:100%;}
  .staff-attendance-toolbar .staff-mini-btn{flex:1 1 calc(50% - 5px);}
  .staff-attendance-summary-grid{grid-template-columns:repeat(2,minmax(0,1fr));}
}

/* ROT std-vs-actual performance impact */
.staff-rot-summary-grid{grid-template-columns:repeat(6,minmax(145px,1fr))}
#myRotVariance.over,.rot-diff.over{color:#b42318}.rot-diff.under,#myRotVariance.under{color:#047857}.rot-diff.target{color:#1d4ed8}
.rot-impact{display:inline-flex;padding:4px 7px;border-radius:999px;font-size:10px;font-weight:800}.rot-impact.over-standard{background:#fee2e2;color:#991b1b}.rot-impact.faster{background:#dcfce7;color:#166534}.rot-impact.on-target{background:#dbeafe;color:#1d4ed8}.rot-impact.not-started{background:#f1f5f9;color:#64748b}.staff-rot-report-table td small{display:block;color:#64748b;margin-top:3px}
@media(max-width:1100px){.staff-rot-summary-grid{grid-template-columns:repeat(3,minmax(145px,1fr))}}


/* ==========================================================
   STAFF PORTAL V5.34 — MOBILE APP INTERFACE
   ========================================================== */
:root{
  --staff-mobile-top:60px;
  --staff-mobile-nav:66px;
  --staff-safe-top:env(safe-area-inset-top,0px);
  --staff-safe-bottom:env(safe-area-inset-bottom,0px);
}
.staff-mobile-menu-btn,
.staff-mobile-drawer-close,
.staff-mobile-backdrop,
.staff-mobile-bottom-nav{display:none}

@media(max-width:760px){
  html,body{
    width:100%;max-width:100%;min-height:100%;
    overflow-x:hidden;
    -webkit-text-size-adjust:100%;
    text-size-adjust:100%;
    overscroll-behavior-x:none;
  }
  body.staff-portal-v250{background:#eef3f8;overflow:hidden}
  button,input,select,textarea{touch-action:manipulation}
  input,select,textarea{font-size:16px!important}

  .staff-login-screen{
    min-height:100vh;min-height:100dvh;
    padding:calc(18px + var(--staff-safe-top)) 14px calc(18px + var(--staff-safe-bottom));
    align-items:center;
  }
  .staff-login-box{max-width:420px;border-radius:22px;padding:28px 20px 24px;box-shadow:0 24px 60px rgba(0,0,0,.32)}
  .staff-login-logo{width:64px;height:64px;border-radius:16px;font-size:31px;margin-bottom:15px}
  .staff-login-box h1{font-size:22px}
  .staff-login-box p{font-size:12px;margin-bottom:16px}
  .staff-input-group input{min-height:50px;border-radius:12px;padding:12px 14px 12px 44px}
  .staff-login-btn{min-height:50px;font-size:14px}

  #staffDashboard{height:100vh;height:100dvh;overflow:hidden}
  .staff-app-shell{display:block!important;width:100%;height:100vh;height:100dvh;min-height:0!important;overflow:hidden}
  .staff-main-area{width:100%;height:100vh;height:100dvh;min-height:0!important;overflow:hidden!important;background:#eef3f8}

  .staff-sidebar{
    display:flex!important;position:fixed!important;inset:0 auto 0 0!important;
    width:min(86vw,330px)!important;max-width:330px!important;
    height:100vh!important;height:100dvh!important;
    z-index:5200!important;transform:translateX(-105%);
    transition:transform .22s cubic-bezier(.2,.8,.2,1)!important;
    background:#0b2b4d!important;box-shadow:18px 0 45px rgba(2,16,34,.28)!important;
    overflow:hidden!important;
  }
  body.staff-mobile-drawer-open .staff-sidebar{transform:translateX(0)}
  .staff-sidebar-brand{height:72px!important;min-height:72px;padding:calc(8px + var(--staff-safe-top)) 14px 8px!important;display:flex!important}
  .staff-mobile-drawer-close{
    display:grid;place-items:center;margin-left:auto;width:36px;height:36px;
    border:1px solid rgba(255,255,255,.15);border-radius:10px;background:rgba(255,255,255,.07);color:#fff;font-size:16px;
  }
  .staff-sidebar-user{display:flex!important;margin:12px 10px 6px!important}
  .staff-sidebar-nav{display:grid!important;padding:8px!important;overflow-y:auto!important;gap:5px!important;-webkit-overflow-scrolling:touch}
  .staff-nav-item{width:100%!important;min-width:0!important;min-height:46px;padding:10px 12px!important;border-radius:10px!important;font-size:12px!important}
  .staff-nav-item b{font-size:12px!important}
  .staff-sidebar-bottom{display:grid!important;margin-top:auto!important;padding:10px!important;padding-bottom:calc(10px + var(--staff-safe-bottom))!important}
  .staff-side-link,.staff-side-logout{min-height:44px;display:flex;align-items:center}
  .staff-mobile-backdrop{
    display:block;position:fixed;inset:0;z-index:5100;background:rgba(3,18,36,.58);backdrop-filter:blur(2px);
    opacity:0;visibility:hidden;transition:opacity .18s,visibility .18s;
  }
  body.staff-mobile-drawer-open .staff-mobile-backdrop{opacity:1;visibility:visible}

  .staff-workshop-topbar{
    position:relative!important;top:auto!important;z-index:300;height:auto!important;min-height:var(--staff-mobile-top);
    padding:calc(8px + var(--staff-safe-top)) 10px 8px!important;gap:8px;justify-content:flex-start!important;
    background:linear-gradient(110deg,#0b315b,#21448a)!important;box-shadow:0 3px 14px rgba(14,38,68,.14)!important;
  }
  .staff-mobile-menu-btn{
    display:grid;place-items:center;flex:0 0 40px;width:40px;height:40px;
    border:1px solid rgba(255,255,255,.18);border-radius:11px;background:rgba(255,255,255,.11);color:#fff;font-size:19px;
  }
  .staff-mobile-title-wrap{flex:1;min-width:0}
  .staff-workshop-topbar h1{font-size:15px!important;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
  .staff-workshop-topbar p{display:none!important}
  .staff-topbar-right{gap:5px!important;flex:0 0 auto}
  .staff-topbar-right #staffTopDate{display:none!important}
  .staff-live-badge{padding:4px 7px!important;font-size:8px!important}

  .staff-content.staff-content-wide{
    width:100%!important;max-width:none!important;
    height:calc(100vh - var(--staff-mobile-top))!important;height:calc(100dvh - var(--staff-mobile-top))!important;
    overflow-y:auto!important;overflow-x:hidden!important;-webkit-overflow-scrolling:touch;overscroll-behavior-y:contain;
    padding:10px 9px calc(var(--staff-mobile-nav) + 18px + var(--staff-safe-bottom))!important;
  }
  .staff-view{width:100%;min-width:0}
  .staff-footer{display:none}

  .staff-mobile-bottom-nav{
    display:grid;grid-template-columns:repeat(5,minmax(0,1fr));
    position:fixed;left:7px;right:7px;bottom:calc(6px + var(--staff-safe-bottom));
    height:var(--staff-mobile-nav);z-index:2800;padding:5px;
    border:1px solid rgba(195,210,226,.95);border-radius:18px;
    background:rgba(255,255,255,.97);box-shadow:0 12px 34px rgba(8,34,65,.22);backdrop-filter:blur(16px);
  }
  .staff-mobile-bottom-nav button{
    min-width:0;border:0;border-radius:12px;background:transparent;color:#687b90;padding:4px 2px;
    display:flex;flex-direction:column;align-items:center;justify-content:center;gap:2px;
  }
  .staff-mobile-bottom-nav button span{font-size:18px;line-height:1}
  .staff-mobile-bottom-nav button small{
    max-width:100%;font-size:7.5px;font-weight:800;line-height:1.1;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;
  }
  .staff-mobile-bottom-nav button.active{color:#154d91;background:#eaf2ff}

  .staff-profile-card.staff-profile-hero{padding:12px!important;gap:11px!important;margin-bottom:9px!important;border-radius:13px!important;align-items:center!important}
  .staff-profile-avatar{width:50px!important;height:50px!important;border-radius:13px!important;font-size:20px!important}
  .staff-profile-info h2{font-size:16px!important;margin-bottom:2px}
  .staff-code{font-size:9px!important;margin-bottom:6px;padding:2px 7px}
  .staff-profile-meta{gap:4px!important;font-size:9px!important}
  .staff-profile-meta span{padding:4px 7px!important;border-radius:8px!important}
  #staffEmailDisplay,#staffAddress{display:none!important}

  .staff-dashboard-grid{grid-template-columns:1fr!important;gap:9px!important}
  .staff-dashboard-grid .staff-time-card,.staff-dashboard-grid .staff-status-card{min-height:0!important;margin:0!important;border-radius:13px!important}
  .staff-time-card{padding:17px!important}
  .staff-time-value{font-size:31px!important}
  .staff-date-value{font-size:11px!important}
  .staff-status-card{padding:18px 14px!important}
  .staff-status-icon{font-size:39px!important;margin-bottom:8px!important}
  .staff-status-card h3{font-size:18px!important;margin-bottom:4px!important}
  .staff-status-card p{font-size:11px!important}
  .staff-actions{margin:12px 0 0!important}
  .staff-action-btn{min-height:50px;padding:12px!important;font-size:14px!important;border-radius:11px!important}
  .staff-stats-row.staff-stats-wide{grid-template-columns:1fr 1fr!important;gap:8px!important;margin:9px 0!important}
  .staff-stat-box{min-width:0;padding:12px!important;border-radius:12px!important}
  .staff-stat-box .label{font-size:8px!important}
  .staff-stat-box .value{font-size:18px!important}
  .staff-stat-box .sub{font-size:9px!important}
  .staff-quick-grid{grid-template-columns:1fr 1fr!important;gap:8px!important}
  .staff-quick-grid button{min-height:105px!important;padding:13px!important;border-radius:12px!important}
  .staff-quick-grid button:last-child{grid-column:1/-1}
  .staff-quick-grid button span{font-size:21px!important;margin-bottom:7px!important}
  .staff-quick-grid button strong{font-size:12px!important}
  .staff-quick-grid button small{font-size:9px!important}

  .staff-section-box{border-radius:13px!important;overflow:hidden}
  .staff-section-header{padding:12px!important;gap:8px!important;align-items:flex-start!important}
  .staff-section-header h3{font-size:13px!important}
  .staff-section-header p{font-size:9.5px!important}
  .staff-mini-btn{min-height:40px;padding:8px 10px!important}

  .staff-attendance-toolbar{margin:0 10px 10px!important;padding:10px!important;gap:7px!important;border-radius:10px!important}
  .staff-attendance-toolbar label{min-width:100%!important}
  .staff-attendance-toolbar input[type="month"]{min-height:44px;width:100%;font-size:16px!important}
  .staff-attendance-toolbar .staff-mini-btn{flex:1 1 calc(50% - 4px)!important}
  .staff-attendance-summary-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:7px!important;margin:0 10px 10px!important}
  .staff-att-summary{min-height:72px!important;padding:10px!important;border-radius:10px!important}
  .staff-att-summary span{font-size:8px!important;margin-bottom:5px}
  .staff-att-summary strong{font-size:18px!important}
  .staff-attendance-table-wrap{margin:0 10px 10px;border:0!important;overflow:visible!important;background:transparent!important}
  .staff-attendance-table{min-width:0!important;width:100%!important;display:block}
  .staff-attendance-table thead{display:none}
  .staff-attendance-table tbody{display:block}
  .staff-attendance-table tbody tr{
    display:grid;grid-template-columns:1fr 1fr;gap:0;margin:0 0 8px;padding:7px 10px;
    border:1px solid #dce6f0;border-radius:11px;background:#fff;box-shadow:0 2px 8px rgba(15,39,68,.04);
  }
  .staff-attendance-table td{
    display:grid;grid-template-columns:75px minmax(0,1fr);gap:7px;align-items:center;
    padding:6px 0!important;border:0!important;white-space:normal!important;font-size:10px!important;
  }
  .staff-attendance-table td::before{color:#7b8da3;font-size:7px;font-weight:900;text-transform:uppercase;letter-spacing:.04em}
  .staff-attendance-table td:nth-child(1)::before{content:"Date"}
  .staff-attendance-table td:nth-child(2)::before{content:"Day"}
  .staff-attendance-table td:nth-child(3)::before{content:"Check In"}
  .staff-attendance-table td:nth-child(4)::before{content:"Check Out"}
  .staff-attendance-table td:nth-child(5)::before{content:"Total"}
  .staff-attendance-table td:nth-child(6)::before{content:"Status"}
  .staff-attendance-table .staff-att-empty{grid-column:1/-1;display:block!important}
  .staff-attendance-table .staff-att-empty::before{display:none}

  .staff-inspection-list{padding:10px!important;gap:8px!important}
  .staff-inspection-job{padding:12px!important;border-radius:11px!important}
  .staff-inspection-job h4{font-size:12px!important}
  .staff-inspection-job p{font-size:10px!important}
  .staff-inspection-open{width:100%;min-height:44px}
  .staff-inspection-modal{padding:0!important;align-items:stretch!important;overflow:hidden!important}
  .staff-inspection-dialog{width:100vw!important;height:100vh!important;height:100dvh!important;max-width:none!important;margin:0!important;border-radius:0!important;overflow-y:auto!important}
  .staff-inspection-close{position:fixed!important;top:calc(10px + var(--staff-safe-top))!important;right:10px!important;z-index:10050!important;width:40px!important;height:40px!important}
  .staff-inspection-head{padding:calc(18px + var(--staff-safe-top)) 58px 14px 14px!important;position:sticky;top:0;z-index:10000}
  .staff-inspection-head h3{font-size:15px!important}
  .staff-inspection-head p{font-size:9.5px!important}
  .staff-inspection-table-wrap{padding:10px!important;overflow:visible!important}
  .staff-inspection-table{min-width:0!important;width:100%!important;display:block}
  .staff-inspection-table thead{display:none}
  .staff-inspection-table tbody{display:block}
  .staff-inspection-table tr.staff-insp-row{display:block;margin-bottom:9px;padding:11px;border:1px solid #dce6f0;border-radius:11px;background:#fff}
  .staff-inspection-table td{display:block!important;padding:4px 0!important;border:0!important;font-size:11px!important}
  .staff-insp-status{display:grid!important;grid-template-columns:repeat(3,1fr);gap:5px!important;margin:5px 0}
  .staff-insp-status button{min-height:40px;padding:6px 3px!important;font-size:9px!important}
  .staff-insp-remark{min-width:0!important;min-height:44px;font-size:16px!important}
  .staff-inspection-submit{
    position:sticky;bottom:0;margin:0!important;width:100%!important;min-height:54px;border-radius:0!important;
    padding-bottom:calc(12px + var(--staff-safe-bottom))!important;z-index:10000;
  }

  .staff-work-rule{margin:10px 10px 0!important;padding:9px 10px!important;font-size:9px!important}
  .staff-rot-work-summary{padding:12px 12px 3px!important}
  .staff-rot-work-summary b{font-size:21px!important}
  .staff-rot-work-grid{grid-template-columns:1fr!important;padding:8px 10px 12px!important;gap:8px!important}
  .staff-rot-work-card{border-radius:12px!important}
  .staff-rot-work-top{padding:11px 12px 9px!important}
  .staff-rot-work-top h4{font-size:12px!important}
  .staff-rot-work-meta{grid-template-columns:1fr 1fr!important}
  .staff-rot-work-meta span{padding:9px 10px!important}
  .staff-rot-work-meta small{font-size:7px!important}
  .staff-rot-work-meta b{font-size:10px!important}
  .staff-rot-work-actions{padding:10px!important;gap:6px!important}
  .staff-rot-action{min-height:44px;flex:1 1 105px;padding:9px 10px!important;font-size:10px!important}
  .staff-recent-completed>h4{padding:12px 12px 0!important}

  .staff-rot-report-head{padding:14px 12px!important}
  .staff-rot-report-head h3{font-size:15px!important}
  .staff-self-only-badge{font-size:7px!important;padding:5px 7px!important}
  .staff-rot-report-toolbar{grid-template-columns:1fr!important;gap:8px!important;padding:10px!important}
  .staff-rot-report-toolbar input,.staff-rot-report-toolbar select{min-height:44px;font-size:16px!important}
  .staff-rot-refresh{width:100%;min-height:44px}
  .staff-rot-summary-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:7px!important;padding:10px!important;overflow:visible!important}
  .staff-rot-summary-card{min-width:0!important;padding:10px!important;border-radius:10px!important}
  .staff-rot-summary-card span{font-size:7px!important}
  .staff-rot-summary-card strong{font-size:16px!important}
  .staff-rot-summary-card small{font-size:8px!important}
  .staff-rot-report-note{margin:0 10px 10px!important;padding:9px!important;font-size:8.5px!important}
  .staff-rot-report-table-wrap{margin:0 10px 10px;overflow:visible!important;border:0!important}
  .staff-rot-report-table{min-width:0!important;width:100%!important;display:block}
  .staff-rot-report-table thead{display:none}
  .staff-rot-report-table tbody{display:block}
  .staff-rot-report-table tbody tr{display:block;margin-bottom:9px;padding:8px 10px;border:1px solid #dce6f0;border-radius:11px;background:#fff}
  .staff-rot-report-table td{
    display:grid!important;grid-template-columns:92px minmax(0,1fr)!important;gap:7px;
    padding:5px 0!important;border:0!important;white-space:normal!important;font-size:9.5px!important;overflow-wrap:anywhere;
  }
  .staff-rot-report-table td::before{color:#7b8da3;font-size:7px;font-weight:900;text-transform:uppercase}
  .staff-rot-report-table td:nth-child(1)::before{content:"Date"}
  .staff-rot-report-table td:nth-child(2)::before{content:"Job Card"}
  .staff-rot-report-table td:nth-child(3)::before{content:"Vehicle"}
  .staff-rot-report-table td:nth-child(4)::before{content:"ROT / Labour"}
  .staff-rot-report-table td:nth-child(5)::before{content:"Std Time"}
  .staff-rot-report-table td:nth-child(6)::before{content:"Productive"}
  .staff-rot-report-table td:nth-child(7)::before{content:"First Start"}
  .staff-rot-report-table td:nth-child(8)::before{content:"Complete"}
  .staff-rot-report-table td:nth-child(9)::before{content:"TAT"}
  .staff-rot-report-table td:nth-child(10)::before{content:"Difference"}
  .staff-rot-report-table td:nth-child(11)::before{content:"Impact"}
  .staff-rot-report-table td:nth-child(12)::before{content:"Status"}
  .staff-rot-report-table .staff-rot-empty{display:block!important;text-align:center}
  .staff-rot-report-table .staff-rot-empty::before{display:none}

  .staff-toast{
    left:9px!important;right:9px!important;
    bottom:calc(var(--staff-mobile-nav) + 12px + var(--staff-safe-bottom))!important;
    max-width:none!important;text-align:center;padding:12px 14px!important;border-radius:11px!important;font-size:11px!important;
  }
}
@media(max-width:390px){
  .staff-mobile-bottom-nav button small{font-size:6.7px}
  .staff-profile-meta span{font-size:8px!important}
  .staff-stats-row.staff-stats-wide{grid-template-columns:1fr!important}
}

/* ===== V5.36 STAFF REMINDER PANEL ===== */
.staff-reminder-panel{margin:0 0 18px;background:#fff7ed;border:1px solid #fed7aa;border-left:5px solid #f59e0b;border-radius:14px;padding:14px 16px;box-shadow:0 8px 22px rgba(15,23,42,.06)}
.staff-reminder-panel.critical{background:#fef2f2;border-color:#fecaca;border-left-color:#dc2626}
.staff-reminder-panel-head{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:8px}
.staff-reminder-panel-head>div{display:flex;align-items:center;gap:8px;color:#7c2d12;font-size:15px}
.staff-reminder-panel.critical .staff-reminder-panel-head>div{color:#991b1b}
.staff-reminder-panel-head button{border:0;background:#fff;border-radius:9px;width:34px;height:30px;cursor:pointer;font-weight:800;box-shadow:0 1px 4px rgba(15,23,42,.12)}
.staff-reminder-item{display:flex;align-items:flex-start;justify-content:space-between;gap:12px;padding:10px 0;border-top:1px dashed rgba(124,45,18,.18)}
.staff-reminder-item:first-child{border-top:0}
.staff-reminder-item-text b{display:block;color:#7c2d12;font-size:13px;margin-bottom:3px}.staff-reminder-panel.critical .staff-reminder-item-text b{color:#991b1b}
.staff-reminder-item-text p{margin:0;color:#475569;font-size:12px;line-height:1.45}
.staff-reminder-item button{flex:0 0 auto;border:0;border-radius:9px;background:#0b315b;color:white;padding:8px 11px;font-size:11px;font-weight:800;cursor:pointer}
.staff-reminder-escalated{display:inline-block;margin-left:6px;padding:2px 6px;border-radius:999px;background:#fee2e2;color:#991b1b;font-size:9px;font-weight:900;letter-spacing:.04em}
@media(max-width:760px){.staff-reminder-panel{margin:0 0 12px;padding:12px}.staff-reminder-item{display:block}.staff-reminder-item button{margin-top:8px;width:100%}}
