/* ==============================================================================
 * Responsive Stylesheet
 * ============================================================================== */

/* Mobile Bottom Navigation Bar (Hidden by default on Desktop) */
.mobile-bottom-nav {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(15, 20, 34, 0.95);
  backdrop-filter: blur(20px);
  border-top: 1px solid var(--border-color);
  padding: 8px 12px calc(8px + env(safe-area-inset-bottom, 0px));
  z-index: 100;
  justify-content: space-around;
  align-items: center;
}

.mobile-nav-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 0.72rem;
  font-weight: 500;
  cursor: pointer;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  transition: var(--transition);
}

.mobile-nav-btn .icon {
  font-size: 1.3rem;
}

.mobile-nav-btn.active {
  color: var(--primary);
  font-weight: 700;
}

.mobile-nav-btn.scan-primary-btn {
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  color: white;
  border-radius: 50%;
  width: 52px;
  height: 52px;
  padding: 0;
  margin-top: -24px;
  box-shadow: 0 4px 15px rgba(16, 185, 129, 0.4);
  border: 3px solid var(--bg-main);
  justify-content: center;
}

.mobile-nav-btn.scan-primary-btn .icon {
  font-size: 1.5rem;
}

/* Modal Confirmation Sheet for Mobile & Desktop */
.mobile-modal-backdrop {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(8px);
  z-index: 200;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.mobile-modal-backdrop.active {
  display: flex;
}

.mobile-modal-card {
  background: var(--bg-card-solid);
  border: 1px solid var(--border-color);
  border-radius: 20px;
  width: 100%;
  max-width: 500px;
  max-height: 90vh;
  overflow-y: auto;
  padding: 24px;
  box-shadow: var(--shadow-lg);
  animation: modalPopIn 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes modalPopIn {
  from { opacity: 0; transform: scale(0.95); }
  to { opacity: 1; transform: scale(1); }
}

@media (max-width: 768px) {
  .mobile-modal-backdrop {
    align-items: flex-end;
    padding: 0;
  }
  .mobile-modal-card {
    border-radius: 24px 24px 0 0;
    padding: 24px 24px calc(28px + env(safe-area-inset-bottom, 0px));
    animation: slideUpModal 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  }
}

@keyframes slideUpModal {
  from { transform: translateY(100%); }
  to { transform: translateY(0); }
}

/* Tablet Breakpoints */
@media (max-width: 1024px) {
  .scanner-grid {
    grid-template-columns: 1fr;
  }
}

/* Mobile Breakpoints */
@media (max-width: 768px) {
  .sidebar {
    display: none;
  }
  
  .top-bar {
    padding: 14px 18px;
  }
  
  .content-area {
    padding: 16px 14px;
  }
  
  .mobile-bottom-nav {
    display: none !important;
  }
  
  .live-clock-card {
    display: flex !important;
    padding: 6px 12px;
    font-size: 0.85rem;
  }
  
  .camera-wrapper {
    height: 300px;
    max-width: 100%;
  }

  .scanner-box {
    padding: 14px;
  }

  .action-type-selector {
    grid-template-columns: 1fr 1fr;
  }

  .btn-action-type {
    padding: 12px 10px;
    font-size: 0.85rem;
  }

  .glass-card {
    padding: 16px;
    border-radius: var(--radius-md);
  }

  .toast-container {
    bottom: 80px;
    right: 14px;
    left: 14px;
  }

  .toast {
    min-width: unset;
    width: 100%;
  }

  /* Responsive Settings Tab for Mobile */
  .settings-card {
    padding: 16px;
  }

  .settings-actions-grid {
    flex-direction: column;
    width: 100%;
  }

  .settings-actions-grid .btn {
    width: 100%;
    justify-content: center;
  }

  .gps-inputs-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .gps-actions-grid {
    flex-direction: column;
    width: 100%;
  }

  .gps-actions-grid .btn {
    width: 100%;
    justify-content: center;
  }

  .gps-actions-grid .btn-save-gps {
    margin-left: 0;
  }

  .tutorial-steps-grid {
    grid-template-columns: 1fr;
  }

  .settings-card .card-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }
}

/* Tablet Breakpoints for Settings */
@media (max-width: 992px) and (min-width: 769px) {
  .gps-inputs-grid {
    grid-template-columns: 1fr 1fr;
  }

  .tutorial-steps-grid {
    grid-template-columns: 1fr;
  }
}

/* ==============================================================================
 * Dedicated Staff Scan & Portal Responsive Design (All Devices)
 * ============================================================================== */

/* Staff Portal Container & Global Resets */
body.mode-staff-portal,
body.mode-scan-only,
body.mode-leave-only {
  background: radial-gradient(circle at 50% -10%, rgba(16, 185, 129, 0.12) 0%, rgba(11, 15, 25, 0.98) 60%), #0b0f19;
  min-height: 100vh;
  touch-action: manipulation;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Staff Portal Top Bar Responsive */
body.mode-staff-portal .top-bar,
body.mode-scan-only .top-bar,
body.mode-leave-only .top-bar {
  padding: 10px 16px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 10px !important;
  width: 100% !important;
  box-sizing: border-box !important;
  background: rgba(11, 15, 25, 0.88) !important;
  backdrop-filter: blur(20px) !important;
  -webkit-backdrop-filter: blur(20px) !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08) !important;
}

body.mode-staff-portal .top-bar-left {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
}

body.mode-staff-portal .top-bar-left .page-title {
  min-width: 0;
  overflow: hidden;
}

body.mode-staff-portal .top-bar-left .page-title h2 {
  display: none !important;
}

body.mode-staff-portal #live-date {
  font-size: clamp(0.72rem, 2.5vw, 0.86rem) !important;
  font-weight: 600 !important;
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  margin: 0 !important;
}

body.mode-staff-portal .top-bar-right {
  flex-shrink: 0;
  display: flex;
  align-items: center;
}

body.mode-staff-portal .live-clock-card {
  padding: 4px 10px !important;
  border-radius: 10px !important;
  background: rgba(15, 23, 42, 0.75) !important;
  border: 1px solid rgba(16, 185, 129, 0.25) !important;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3) !important;
  gap: 8px !important;
}

body.mode-staff-portal .clock-time {
  font-size: clamp(0.82rem, 2.8vw, 0.95rem) !important;
  font-weight: 700 !important;
  color: #34d399 !important;
  letter-spacing: 0.02em !important;
}

/* Staff Portal Navigation Tabs */
body.mode-staff-portal .staff-portal-bar {
  display: flex !important;
  justify-content: center;
  align-items: center;
  padding: 8px 12px 0 12px !important;
  margin: 0 auto 10px auto !important;
  width: 100% !important;
  max-width: 500px !important;
  box-sizing: border-box !important;
}

body.mode-staff-portal .staff-nav-tabs {
  display: grid !important;
  grid-template-columns: 1fr 1fr !important;
  gap: 6px !important;
  background: rgba(15, 23, 42, 0.85) !important;
  backdrop-filter: blur(20px) !important;
  -webkit-backdrop-filter: blur(20px) !important;
  padding: 4px !important;
  border-radius: 100px !important;
  border: 1px solid rgba(255, 255, 255, 0.12) !important;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.1) !important;
  width: 100% !important;
}

body.mode-staff-portal .btn-staff-tab {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 6px !important;
  padding: 9px 8px !important;
  border-radius: 100px !important;
  border: none !important;
  background: transparent !important;
  color: var(--text-muted) !important;
  font-size: clamp(0.78rem, 2.6vw, 0.88rem) !important;
  font-weight: 700 !important;
  font-family: inherit !important;
  cursor: pointer !important;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1) !important;
  white-space: nowrap !important;
  text-align: center !important;
}

body.mode-staff-portal .btn-staff-tab.active {
  background: linear-gradient(135deg, #10b981 0%, #059669 100%) !important;
  color: #ffffff !important;
  box-shadow: 0 4px 16px rgba(16, 185, 129, 0.45) !important;
}

body.mode-staff-portal .btn-staff-tab.leave-tab.active {
  background: linear-gradient(135deg, #8b5cf6 0%, #7c3aed 100%) !important;
  color: #ffffff !important;
  box-shadow: 0 4px 16px rgba(139, 92, 246, 0.45) !important;
}

/* Staff Account Selector Card */
.staff-account-card {
  background: linear-gradient(145deg, rgba(15, 23, 42, 0.95) 0%, rgba(17, 24, 39, 0.95) 100%);
  border: 1.5px solid rgba(16, 185, 129, 0.35);
  border-radius: 14px;
  padding: 10px 14px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
  margin-bottom: 12px;
  width: 100%;
  box-sizing: border-box;
}

.staff-select-dropdown {
  width: 100%;
  min-height: 44px;
  background: #090d16;
  color: #38bdf8;
  border: 1.5px solid rgba(56, 189, 248, 0.35);
  border-radius: 10px;
  padding: 8px 12px;
  font-size: clamp(0.82rem, 2.6vw, 0.92rem);
  font-weight: 600;
  outline: none;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.4);
  box-sizing: border-box;
}

.staff-select-dropdown:focus {
  border-color: #38bdf8;
  box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.25), inset 0 2px 4px rgba(0, 0, 0, 0.4);
}

/* Action Type Buttons (Check-In vs Check-Out) */
.action-type-selector {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 12px;
  width: 100%;
  max-width: 480px;
  margin-left: auto;
  margin-right: auto;
  box-sizing: border-box;
}

.btn-action-type {
  min-height: 52px;
  box-sizing: border-box;
}

.btn-action-type.check-in.active {
  background: linear-gradient(135deg, #10b981 0%, #059669 100%) !important;
  border-color: #34d399 !important;
  color: #ffffff !important;
  box-shadow: 0 4px 20px rgba(16, 185, 129, 0.5) !important;
}

.btn-action-type.check-out.active {
  background: linear-gradient(135deg, #ef4444 0%, #b91c1c 100%) !important;
  border-color: #f87171 !important;
  color: #ffffff !important;
  box-shadow: 0 4px 20px rgba(239, 68, 68, 0.5) !important;
}

/* Camera Wrapper Responsive Ratio */
.camera-wrapper {
  position: relative;
  width: 100%;
  max-width: 480px;
  height: clamp(280px, 78vw, 380px);
  margin: 0 auto 12px auto;
  border-radius: 16px;
  overflow: hidden;
  background: #000000;
  border: 1.5px solid rgba(16, 185, 129, 0.35);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.55), inset 0 0 20px rgba(0, 0, 0, 0.8);
  box-sizing: border-box;
}

.camera-wrapper #reader {
  width: 100% !important;
  height: 100% !important;
  position: relative;
}

.camera-wrapper #reader video {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  border-radius: 14px;
}

/* Scanner Action Buttons */
.scanner-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  width: 100%;
  max-width: 480px;
  margin: 0 auto;
  box-sizing: border-box;
}

.scanner-actions .btn {
  min-height: 42px;
  border-radius: 10px;
  font-size: clamp(0.76rem, 2.5vw, 0.86rem);
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 6px;
  box-sizing: border-box;
  text-align: center;
}

/* ==============================================================================
 * Responsive Device Breakpoints for Staff Scan
 * ============================================================================== */

/* Desktop & Large Screens (>= 1024px) */
@media (min-width: 1024px) {
  body.mode-staff-portal .content-area,
  body.mode-scan-only .content-area {
    padding: 14px 20px 32px 20px !important;
    max-width: 540px !important;
    margin: 0 auto;
    box-sizing: border-box !important;
  }

  body.mode-staff-portal .scanner-grid,
  body.mode-scan-only .scanner-grid {
    display: flex !important;
    flex-direction: column !important;
    gap: 12px !important;
    max-width: 500px !important;
    margin: 0 auto !important;
    width: 100% !important;
  }

  body.mode-staff-portal .scanner-box {
    padding: 16px 18px !important;
    border-radius: 18px !important;
  }

  body.mode-staff-portal .camera-wrapper,
  body.mode-scan-only .camera-wrapper {
    height: 380px !important;
    max-height: 380px !important;
    max-width: 460px !important;
  }

  body.mode-staff-portal .result-display-card {
    position: static !important;
    margin-top: 0 !important;
    gap: 8px !important;
  }
}

/* Tablets (768px to 1023px) */
@media (max-width: 1023px) and (min-width: 768px) {
  body.mode-staff-portal .content-area,
  body.mode-scan-only .content-area {
    padding: 12px 16px 24px 16px !important;
    max-width: 520px !important;
    margin: 0 auto;
    box-sizing: border-box !important;
  }

  body.mode-staff-portal .scanner-grid,
  body.mode-scan-only .scanner-grid {
    display: flex !important;
    flex-direction: column !important;
    gap: 12px !important;
    max-width: 480px !important;
    margin: 0 auto !important;
    width: 100% !important;
  }

  body.mode-staff-portal .camera-wrapper,
  body.mode-scan-only .camera-wrapper {
    height: 380px !important;
    max-height: 380px !important;
    max-width: 460px !important;
  }
}

/* Mobile Phones (< 768px) */
@media (max-width: 767px) {
  body.mode-staff-portal .content-area,
  body.mode-scan-only .content-area,
  body.mode-leave-only .content-area {
    padding: 6px 10px 24px 10px !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }

  body.mode-staff-portal .scanner-grid,
  body.mode-scan-only .scanner-grid {
    display: flex !important;
    flex-direction: column !important;
    gap: 10px !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 auto !important;
  }

  body.mode-staff-portal .scanner-box {
    padding: 12px 12px !important;
    border-radius: 16px !important;
    box-sizing: border-box !important;
  }

  body.mode-staff-portal .camera-wrapper,
  body.mode-scan-only .camera-wrapper {
    height: clamp(290px, 82vw, 380px) !important;
    max-height: 380px !important;
    max-width: 100% !important;
    border-radius: 16px !important;
  }

  body.mode-staff-portal .result-display-card {
    margin-top: 0 !important;
    gap: 6px !important;
    width: 100% !important;
    max-width: 100% !important;
  }

  body.mode-staff-portal .result-display-card .glass-card {
    padding: 10px 12px !important;
    border-radius: 14px !important;
  }
}

/* Small Screens (< 420px - iPhone SE, Small Androids) */
@media (max-width: 420px) {
  body.mode-staff-portal .clock-date {
    display: none !important;
  }

  body.mode-staff-portal .staff-nav-tabs {
    max-width: 100% !important;
    padding: 3px !important;
  }

  body.mode-staff-portal .btn-staff-tab {
    padding: 8px 4px !important;
    font-size: 0.76rem !important;
    gap: 4px !important;
  }

  .action-type-selector {
    gap: 8px;
  }

  .btn-action-type {
    min-height: 44px;
    font-size: 0.78rem;
    padding: 6px 4px;
    gap: 4px;
  }

  .scanner-actions {
    gap: 8px;
  }

  .scanner-actions .btn {
    font-size: 0.74rem;
    padding: 8px 4px;
  }
}

/* ==============================================================================
 * Comprehensive Responsive UI for Time-Based Payroll & Tab Logs (All Devices)
 * ============================================================================== */

/* Mobile Sidebar Drawer Navigation */
@media (max-width: 768px) {
  .sidebar {
    display: flex !important;
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    width: 280px;
    z-index: 9999;
    transform: translateX(-100%);
    transition: transform 0.28s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: none;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }
  .sidebar.mobile-open {
    transform: translateX(0);
    box-shadow: 0 0 35px rgba(0, 0, 0, 0.85);
  }
  .mobile-sidebar-backdrop {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    z-index: 9998;
  }
  .mobile-sidebar-backdrop.active {
    display: block;
  }
  .menu-toggle-btn {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
  }
  .top-bar {
    padding: 10px 14px;
    gap: 8px;
  }
  .top-bar-left {
    gap: 8px;
    min-width: 0;
  }
  .page-title h2 {
    font-size: clamp(0.85rem, 3.5vw, 1.1rem) !important;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .top-bar-right {
    gap: 6px !important;
  }
  .user-auth-badge {
    padding: 3px 6px !important;
    font-size: 0.76rem !important;
  }
}

/* Tablet Screens (769px to 1080px) */
@media (max-width: 1080px) and (min-width: 769px) {
  .v19-layout-container {
    grid-template-columns: 1fr !important;
    gap: 16px;
  }
  .v19-summary-card {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 10px !important;
  }
  .v19-summary-card .v19-sum-item.total-pay-highlight {
    grid-column: 1 / -1 !important;
    justify-content: space-between !important;
  }
  .v19-action-buttons-stack {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 8px !important;
  }
}

/* Mobile Screens (<= 768px) */
@media (max-width: 768px) {
  .content-area {
    padding: 10px 10px 30px 10px !important;
  }

  .v19-layout-container {
    grid-template-columns: 1fr !important;
    gap: 14px !important;
  }

  /* Left Sidebar Input Form */
  .v19-left-sidebar {
    padding: 14px !important;
    border-radius: 14px !important;
  }
  .v19-panel-title {
    font-size: 0.96rem !important;
    margin-bottom: 12px !important;
  }
  .v19-action-buttons-stack {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 8px !important;
    margin-top: 10px !important;
  }
  .v19-action-buttons-stack .btn {
    min-height: 42px !important;
    padding: 8px 6px !important;
    font-size: 0.78rem !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;
    line-height: 1.25 !important;
  }

  /* Top Summary KPI Card on Mobile */
  .v19-summary-card {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 8px !important;
    padding: 10px !important;
    border-radius: 14px !important;
  }
  .v19-sum-item {
    background: rgba(255, 255, 255, 0.04) !important;
    padding: 8px 10px !important;
    border-radius: 10px !important;
    border: 1px solid rgba(255, 255, 255, 0.07) !important;
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    font-size: 0.78rem !important;
  }
  .v19-sum-item .sum-label {
    font-size: 0.76rem !important;
  }
  .v19-sum-item .sum-val {
    font-size: 0.88rem !important;
  }
  .v19-sum-item.total-pay-highlight {
    grid-column: 1 / -1 !important;
    background: linear-gradient(135deg, rgba(241, 196, 15, 0.15) 0%, rgba(217, 119, 6, 0.15) 100%) !important;
    border: 1px solid rgba(241, 196, 15, 0.4) !important;
    padding: 10px 14px !important;
    border-radius: 12px !important;
    justify-content: space-between !important;
  }
  .v19-sum-item.total-pay-highlight .sum-label {
    font-size: 0.84rem !important;
    font-weight: 700 !important;
    color: #fef08a !important;
  }
  .v19-sum-item.total-pay-highlight .sum-val {
    font-size: 1.15rem !important;
  }

  /* Filter Bar on Mobile */
  .v19-filter-bar {
    padding: 12px !important;
    border-radius: 14px !important;
    gap: 10px !important;
  }
  .v19-filter-controls {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 8px !important;
    width: 100% !important;
  }
  .v19-filter-controls .filter-group {
    width: 100% !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 3px !important;
  }
  .v19-filter-controls .filter-group:first-child {
    grid-column: 1 / -1 !important;
  }
  .v19-filter-controls .filter-group label {
    font-size: 0.76rem !important;
  }
  .filter-input-sm {
    width: 100% !important;
    min-width: unset !important;
    min-height: 40px !important;
    padding: 6px 10px !important;
    font-size: 0.84rem !important;
    box-sizing: border-box !important;
  }
  .v19-filter-actions-inline {
    display: flex !important;
    width: 100% !important;
    gap: 6px !important;
  }
  .v19-filter-actions-inline .btn {
    flex: 1 !important;
    min-height: 38px !important;
    padding: 6px 8px !important;
    font-size: 0.78rem !important;
    justify-content: center !important;
    text-align: center !important;
  }

  /* Bulk Actions Bar on Mobile */
  .v19-bulk-actions-bar {
    position: sticky !important;
    top: 8px !important;
    z-index: 85 !important;
    padding: 10px !important;
    border-radius: 12px !important;
    flex-direction: column !important;
    gap: 8px !important;
    background: linear-gradient(135deg, rgba(20, 29, 47, 0.98) 0%, rgba(10, 16, 30, 0.99) 100%) !important;
    backdrop-filter: blur(12px) !important;
    -webkit-backdrop-filter: blur(12px) !important;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.65), 0 0 16px rgba(59, 130, 246, 0.35) !important;
  }
  .bulk-selected-info {
    width: 100% !important;
    justify-content: center !important;
  }
  .bulk-badge {
    width: 100% !important;
    text-align: center !important;
    font-size: 0.82rem !important;
    padding: 5px 8px !important;
  }
  .bulk-action-buttons {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 6px !important;
    width: 100% !important;
  }
  .btn-bulk-action,
  .btn-bulk-delete,
  .btn-bulk-cancel {
    min-height: 38px !important;
    padding: 6px 4px !important;
    font-size: 0.74rem !important;
    justify-content: center !important;
    text-align: center !important;
    display: flex !important;
    align-items: center !important;
  }
  .btn-bulk-delete {
    grid-column: span 2 !important;
  }

  /* Table on Mobile */
  .v19-table-wrapper {
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch !important;
    border-radius: 12px !important;
    margin-top: 4px !important;
  }
  .v19-table {
    min-width: 780px !important;
    font-size: 0.82rem !important;
  }
  .v19-table th {
    padding: 10px 8px !important;
    font-size: 0.8rem !important;
  }
  .v19-table td {
    padding: 8px 8px !important;
    font-size: 0.8rem !important;
  }
  .log-action-select {
    min-height: 34px !important;
    font-size: 0.76rem !important;
    padding: 4px 6px !important;
  }

  /* Table Footer & Pagination on Mobile */
  .v19-table-footer {
    flex-direction: column !important;
    gap: 10px !important;
    padding: 12px 10px !important;
    align-items: center !important;
    text-align: center !important;
  }
  .pagination-wrapper {
    flex-wrap: wrap !important;
    justify-content: center !important;
    gap: 4px !important;
  }
  .pagination-btn {
    min-width: 32px !important;
    height: 32px !important;
    font-size: 0.8rem !important;
  }
}

/* Very Small Mobile Screens (< 420px - iPhone SE, Small Devices) */
@media (max-width: 420px) {
  .bulk-action-buttons {
    grid-template-columns: 1fr 1fr !important;
  }
  .btn-bulk-delete {
    grid-column: 1 / -1 !important;
  }
  .btn-bulk-cancel {
    grid-column: 1 / -1 !important;
  }
  .v19-action-buttons-stack {
    grid-template-columns: 1fr !important;
  }
  .time-inputs-row {
    flex-direction: column !important;
    gap: 8px !important;
  }
}


