:root {
  color-scheme: dark;
}

* {
  scrollbar-width: thin;
  scrollbar-color: #475569 #0b0f19;
}

::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: #090e1a;
  border-radius: 9999px;
}

::-webkit-scrollbar-thumb {
  background: #334155;
  border-radius: 9999px;
  border: 2px solid #090e1a;
  background-clip: padding-box;
  transition: all 0.2s ease;
}

::-webkit-scrollbar-thumb:hover {
  background: #f59e0b;
}

::-webkit-scrollbar-corner {
  background: transparent;
}

.admin-body {
  background-color: #0b0f19;
  color: #f1f5f9;
}

.admin-layout {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.admin-nav {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 28px;
  background: rgba(11, 15, 25, 0.95);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid #1e293b;
}

.admin-badge {
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
  color: #000;
  font-family: 'JetBrains Mono', monospace;
  font-weight: 800;
  font-size: 0.75rem;
  padding: 4px 8px;
  border-radius: 6px;
  letter-spacing: 0.05em;
}

.admin-nav-actions {
  display: flex;
  align-items: center;
  gap: 14px;
}

.admin-user-pill {
  display: flex;
  align-items: center;
  gap: 6px;
  background: #1e293b;
  padding: 6px 12px;
  border-radius: 10px;
  font-size: 0.82rem;
  border: 1px solid #334155;
  color: #e2e8f0;
}

.admin-main {
  flex: 1;
  padding: 28px;
  max-width: 1280px;
  margin: 0 auto;
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.admin-panel {
  background: #131b2e;
  border: 1px solid #243048;
  border-radius: 18px;
  padding: 24px;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
}

.highlight-panel {
  border-color: rgba(56, 189, 248, 0.35);
  background: linear-gradient(180deg, #162038 0%, #131b2e 100%);
}

.panel-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 20px;
  border-bottom: 1px solid #243048;
  padding-bottom: 16px;
}

.title-wrap h2 {
  font-size: 1.25rem;
  font-weight: 700;
  color: #f8fafc;
}

.panel-subtitle {
  font-size: 0.82rem;
  color: #94a3b8;
  margin-top: 4px;
}

.month-selector-group {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #0f172a;
  padding: 6px 14px;
  border-radius: 10px;
  border: 1px solid #334155;
}

.month-selector-group label {
  font-size: 0.82rem;
  color: #94a3b8;
}

.admin-input-month {
  background: transparent;
  border: none;
  color: #38bdf8;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
}

.admin-input-month:focus {
  outline: none;
}

.employee-select-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 20px;
}

.row-label {
  font-size: 0.88rem;
  font-weight: 600;
  color: #cbd5e1;
}

.admin-select {
  background: #0f172a;
  color: #f8fafc;
  border: 1px solid #334155;
  padding: 8px 14px;
  border-radius: 8px;
  font-size: 0.9rem;
}

.hint-inline {
  font-size: 0.8rem;
  color: #64748b;
}

/* Mode Selection Tabs */
.mode-selector-tabs {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-bottom: 24px;
}

.mode-tab-card {
  position: relative;
  display: block;
  cursor: pointer;
}

.mode-tab-card input[type="radio"] {
  position: absolute;
  top: 14px;
  right: 14px;
  accent-color: #38bdf8;
  width: 18px;
  height: 18px;
}

.mode-tab-card .tab-content {
  background: #0f172a;
  border: 2px solid #243048;
  border-radius: 14px;
  padding: 16px;
  height: 100%;
  transition: all 0.2s ease;
}

.mode-tab-card:hover .tab-content {
  border-color: #475569;
}

.mode-tab-card input[type="radio"]:checked + .tab-content {
  border-color: #38bdf8;
  background: rgba(56, 189, 248, 0.08);
  box-shadow: 0 0 15px rgba(56, 189, 248, 0.15);
}

.tab-badge {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 6px;
  font-weight: 700;
  font-size: 0.85rem;
  margin-bottom: 8px;
}

.tab-badge.pt {
  background: rgba(168, 85, 247, 0.2);
  color: #c084fc;
}

.tab-badge.nft {
  background: rgba(16, 185, 129, 0.2);
  color: #34d399;
}

.tab-badge.ft {
  background: rgba(56, 189, 248, 0.2);
  color: #38bdf8;
}

.tab-desc {
  font-size: 0.8rem;
  color: #94a3b8;
  line-height: 1.5;
}

/* Rate Tweaks Grid */
.rate-tweaks-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  background: #0f172a;
  padding: 18px;
  border-radius: 12px;
  border: 1px solid #243048;
  margin-bottom: 20px;
}

.tweak-item {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.tweak-item label {
  font-size: 0.82rem;
  font-weight: 600;
  color: #cbd5e1;
}

.tweak-input {
  background: #1e293b;
  border: 1px solid #334155;
  color: #f8fafc;
  padding: 8px 12px;
  border-radius: 8px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.95rem;
  font-weight: 600;
}

.tweak-input:focus {
  outline: none;
  border-color: #38bdf8;
}

.tweak-item small {
  font-size: 0.72rem;
  color: #64748b;
}

.config-actions {
  display: flex;
  align-items: center;
  gap: 16px;
}

.save-msg {
  font-size: 0.85rem;
  font-weight: 600;
  color: #10b981;
}

/* Admin Tables */
.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
}

.admin-table th, .admin-table td {
  padding: 12px 16px;
  border-bottom: 1px solid #243048;
  text-align: left;
}

.admin-table th {
  background: #0f172a;
  color: #94a3b8;
  font-weight: 600;
  font-size: 0.82rem;
  text-transform: uppercase;
}

.admin-table tbody tr:hover {
  background: rgba(30, 41, 59, 0.4);
}

.status-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 6px;
  font-size: 0.75rem;
  font-weight: 600;
}

.status-badge.active {
  background: rgba(16, 185, 129, 0.15);
  color: #34d399;
}

.status-badge.inactive {
  background: rgba(148, 163, 184, 0.15);
  color: #94a3b8;
}

.action-btns {
  display: flex;
  gap: 8px;
}

.btn-sm {
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 0.78rem;
  cursor: pointer;
  border: 1px solid transparent;
}

.btn-edit {
  background: rgba(56, 189, 248, 0.15);
  color: #38bdf8;
  border-color: rgba(56, 189, 248, 0.3);
}

.btn-edit:hover {
  background: rgba(56, 189, 248, 0.25);
}

.btn-delete {
  background: rgba(244, 63, 94, 0.15);
  color: #fb7185;
  border-color: rgba(244, 63, 94, 0.3);
}

.btn-delete:hover {
  background: rgba(244, 63, 94, 0.25);
}

.checkbox-group label {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  font-size: 0.85rem;
}

/* ==========================================================================
   SOFTWARE UPDATE NOTICE TOAST (Lower Right Corner)
   ========================================================================== */
.update-notice-toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 100000;
  max-width: 390px;
  width: calc(100vw - 48px);
  background: rgba(15, 23, 42, 0.95);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(56, 189, 248, 0.45);
  border-radius: 14px;
  padding: 16px 18px;
  box-shadow: 0 20px 45px -10px rgba(0, 0, 0, 0.7),
              0 0 25px rgba(56, 189, 248, 0.25);
  animation: updateSlideUp 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

@keyframes updateSlideUp {
  from {
    opacity: 0;
    transform: translateY(24px) scale(0.96);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.update-notice-content {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.update-icon-wrapper {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  min-width: 38px;
  border-radius: 10px;
  background: rgba(56, 189, 248, 0.15);
  border: 1px solid rgba(56, 189, 248, 0.35);
}

.update-pulse-ring {
  position: absolute;
  width: 100%;
  height: 100%;
  border-radius: 10px;
  border: 2px solid rgba(56, 189, 248, 0.65);
  animation: pulseUpdate 2s cubic-bezier(0.455, 0.03, 0.515, 0.955) infinite;
}

@keyframes pulseUpdate {
  0% { transform: scale(0.9); opacity: 0.8; }
  50% { transform: scale(1.22); opacity: 0; }
  100% { transform: scale(0.9); opacity: 0; }
}

.update-icon {
  font-size: 1.2rem;
}

.update-text-group {
  flex: 1;
  min-width: 0;
}

.update-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 4px;
}

.update-title {
  font-size: 0.95rem;
  font-weight: 700;
  color: #f8fafc;
  letter-spacing: -0.01em;
}

.update-version-tag {
  font-size: 0.72rem;
  font-family: 'JetBrains Mono', monospace;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 6px;
  background: rgba(56, 189, 248, 0.18);
  color: #38bdf8;
  border: 1px solid rgba(56, 189, 248, 0.35);
  white-space: nowrap;
}

.update-desc {
  font-size: 0.82rem;
  color: #94a3b8;
  line-height: 1.45;
  margin: 0;
}

.update-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  padding-top: 2px;
}

.btn-update-dismiss {
  background: transparent;
  border: 1px solid rgba(148, 163, 184, 0.3);
  color: #94a3b8;
  padding: 6px 14px;
  border-radius: 8px;
  font-size: 0.82rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-update-dismiss:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #f1f5f9;
}

.btn-update-refresh {
  background: linear-gradient(135deg, #0284c7 0%, #0369a1 100%);
  border: 1px solid rgba(56, 189, 248, 0.5);
  color: #ffffff;
  padding: 7px 18px;
  border-radius: 8px;
  font-size: 0.84rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  box-shadow: 0 2px 10px rgba(2, 132, 199, 0.45);
  transition: all 0.2s ease;
}

.btn-update-refresh:hover {
  background: linear-gradient(135deg, #0ea5e9 0%, #0284c7 100%);
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(56, 189, 248, 0.55);
}

.btn-update-refresh:active {
  transform: translateY(0);
}

.refresh-spin-icon {
  display: inline-block;
  font-size: 0.9rem;
  transition: transform 0.3s ease;
}

.btn-update-refresh:hover .refresh-spin-icon {
  transform: rotate(180deg);
}

/* Minimized Floating Update Badge */
.minimized-update-badge {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 99998;
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(15, 23, 42, 0.95);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(56, 189, 248, 0.5);
  color: #38bdf8;
  font-size: 0.82rem;
  font-weight: 600;
  padding: 8px 14px;
  border-radius: 9999px;
  cursor: pointer;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5), 0 0 15px rgba(56, 189, 248, 0.3);
  animation: updateSlideUp 0.3s ease;
}

.minimized-update-badge:hover {
  background: rgba(30, 41, 59, 0.98);
  border-color: #38bdf8;
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.6), 0 0 20px rgba(56, 189, 248, 0.45);
}

@media (max-width: 900px) {
  .mode-selector-tabs, .rate-tweaks-grid {
    grid-template-columns: 1fr;
  }
}

.employers-table-wrap,
.roster-table-wrap {
  width: 100%;
  overflow-x: auto;
  border-radius: 12px;
  background: #0f172a;
  border: 1px solid #243048;
}

.employers-table-wrap table,
.roster-table-wrap table {
  min-width: 650px;
}

/* ==========================================================================
   BATCH EXPORT & ZIP ARCHIVE SECTION
   ========================================================================== */
.batch-export-card {
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.export-config-group {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.export-group-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.95rem;
  font-weight: 700;
  color: #f8fafc;
}

.step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: linear-gradient(135deg, #0284c7 0%, #0369a1 100%);
  color: #ffffff;
  font-size: 0.78rem;
  font-weight: 800;
}

.export-employee-checkboxes {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  background: #0f172a;
  padding: 14px;
  border-radius: 12px;
  border: 1px solid #243048;
}

.emp-check-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #1e293b;
  border: 1px solid #334155;
  padding: 8px 14px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 0.85rem;
  color: #f1f5f9;
  transition: all 0.2s ease;
}

.emp-check-pill:hover {
  border-color: #38bdf8;
  background: #243048;
}

.emp-check-pill.all-pill {
  background: rgba(56, 189, 248, 0.15);
  border-color: rgba(56, 189, 248, 0.4);
  color: #38bdf8;
}

.range-radio-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.range-card-label {
  cursor: pointer;
}

.range-card-label input[type="radio"] {
  display: none;
}

.range-card-box {
  background: #0f172a;
  border: 2px solid #243048;
  border-radius: 12px;
  padding: 14px 16px;
  height: 100%;
  transition: all 0.2s ease;
}

.range-card-label:hover .range-card-box {
  border-color: #475569;
}

.range-card-label input[type="radio"]:checked + .range-card-box {
  border-color: #38bdf8;
  background: rgba(56, 189, 248, 0.08);
  box-shadow: 0 0 16px rgba(56, 189, 248, 0.16);
}

.range-card-title {
  font-size: 0.92rem;
  font-weight: 700;
  color: #f8fafc;
  margin-bottom: 6px;
}

.range-card-desc {
  font-size: 0.8rem;
  color: #94a3b8;
  line-height: 1.4;
}

.highlight-text {
  color: #38bdf8;
  font-weight: 700;
}

.custom-range-controls {
  background: #0f172a;
  border: 1px dashed rgba(56, 189, 248, 0.4);
  border-radius: 12px;
  padding: 16px 20px;
}

.range-picker-row {
  display: flex;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
}

.picker-col {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.picker-label {
  font-size: 0.82rem;
  font-weight: 600;
  color: #cbd5e1;
}

.select-ym-pair {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  color: #94a3b8;
}

.picker-arrow {
  font-size: 1.3rem;
  color: #38bdf8;
  margin-top: 18px;
}

.format-and-preview-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.formats-selector {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.format-check-label {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  background: #0f172a;
  border: 1px solid #243048;
  border-radius: 12px;
  padding: 14px 16px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.format-check-label:hover {
  border-color: #38bdf8;
}

.format-check-label input[type="checkbox"] {
  width: 18px;
  height: 18px;
  accent-color: #38bdf8;
  margin-top: 3px;
}

.format-check-label div strong {
  display: block;
  font-size: 0.9rem;
  color: #f8fafc;
  margin-bottom: 4px;
}

.format-check-label div small {
  display: block;
  font-size: 0.78rem;
  color: #94a3b8;
  line-height: 1.4;
}

.zip-structure-preview {
  background: #0f172a;
  border: 1px solid #243048;
  border-radius: 12px;
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.preview-title {
  font-size: 0.82rem;
  font-weight: 700;
  color: #38bdf8;
}

.folder-tree-box {
  background: #090e1a;
  border: 1px solid #1e293b;
  border-radius: 8px;
  padding: 12px;
  margin: 0;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.78rem;
  color: #a7f3d0;
  line-height: 1.5;
  overflow-x: auto;
}

.export-actions-bar {
  display: flex;
  align-items: center;
  gap: 16px;
  padding-top: 6px;
}

.export-status-msg {
  font-size: 0.88rem;
  font-weight: 600;
}

@media (max-width: 900px) {
  .range-radio-cards,
  .format-and-preview-row {
    grid-template-columns: 1fr;
  }
}

/* Employee Roster Actions & Badges */
.status-badge.archived {
  background: rgba(100, 116, 139, 0.2);
  color: #94a3b8;
  border: 1px solid rgba(148, 163, 184, 0.3);
}

.btn-archive {
  background: rgba(245, 158, 11, 0.15);
  color: #fbbf24;
  border-color: rgba(245, 158, 11, 0.35);
}

.btn-archive:hover {
  background: rgba(245, 158, 11, 0.25);
  border-color: #fbbf24;
}

.btn-unarchive {
  background: rgba(16, 185, 129, 0.15);
  color: #34d399;
  border-color: rgba(16, 185, 129, 0.35);
}

.btn-unarchive:hover {
  background: rgba(16, 185, 129, 0.25);
  border-color: #34d399;
}

.btn-delete {
  background: rgba(239, 68, 68, 0.15);
  color: #f87171;
  border-color: rgba(239, 68, 68, 0.35);
}

.btn-delete:hover {
  background: rgba(239, 68, 68, 0.25);
  border-color: #f87171;
}

.date-text {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.8rem;
  color: #cbd5e1;
}

.date-text.empty {
  color: #64748b;
  font-style: italic;
}

.field-hint {
  display: block;
  margin-top: 5px;
  font-size: 0.78rem;
  color: #94a3b8;
}


