.payroll-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 2px solid #e5e7eb;
}

.payroll-title {
  font-size: 2rem;
  font-weight: 700;
  color: #1f2937;
}

.payroll-actions {
  display: flex;
  gap: 0.75rem;
}

.btn {
  padding: 0.625rem 1rem;
  border-radius: 0.375rem;
  font-weight: 500;
  text-align: center;
  transition: all 0.2s ease-in-out;
  cursor: pointer;
  border: none;
  font-size: 0.875rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.btn-primary {
  background-color: #3b82f6;
  color: white;
}

.btn-primary:hover {
  background-color: #2563eb;
}

.btn-danger {
  background-color: #ef4444;
  color: white;
}

.btn-danger:hover {
  background-color: #dc2626;
}

.btn-success {
  background-color: #10b981;
  color: white;
}

.btn-success:hover {
  background-color: #059669;
}

.btn-warning {
  background-color: #f59e0b;
  color: white;
}

.btn-warning:hover {
  background-color: #d97706;
}

.btn-sm {
  padding: 0.375rem 0.75rem;
  font-size: 0.75rem;
}

.btn-lg {
  padding: 0.75rem 1.25rem;
  font-size: 1rem;
}

.payroll-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  background-color: white;
  border-radius: 0.5rem;
  overflow: hidden;
  box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
}

.payroll-table th {
  text-align: left;
  padding: 0.75rem 1rem;
  background-color: #f9fafb;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #6b7280;
  border-bottom: 1px solid #e5e7eb;
}

.payroll-table th:first-child {
  border-top-left-radius: 0.5rem;
}

.payroll-table th:last-child {
  border-top-right-radius: 0.5rem;
}

.payroll-table tr:last-child td:first-child {
  border-bottom-left-radius: 0.5rem;
}

.payroll-table tr:last-child td:last-child {
  border-bottom-right-radius: 0.5rem;
}

.payroll-table td {
  padding: 1rem;
  border-bottom: 1px solid #e5e7eb;
  color: #1f2937;
  vertical-align: middle;
}

.payroll-table tr:last-child td {
  border-bottom: none;
}

.payroll-table tr:hover td {
  background-color: #f3f4f6;
}

.status-badge {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 500;
  text-align: center;
}

.status-processed {
  background-color: #dbeafe;
  color: #1e40af;
}

.status-approved {
  background-color: #d1fae5;
  color: #065f46;
}

.status-not-processed {
  background-color: #f3f4f6;
  color: #4b5563;
}

.action-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.action-link {
  padding: 0.375rem 0.75rem;
  border-radius: 0.25rem;
  font-size: 0.75rem;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.2s ease-in-out;
  display: inline-flex;
  align-items: center;
}

.action-link:hover {
  transform: translateY(-1px);
}

.action-link-primary {
  background-color: #e0f2fe;
  color: #0369a1;
}

.action-link-primary:hover {
  background-color: #bae6fd;
}

.action-link-success {
  background-color: #dcfce7;
  color: #166534;
}

.action-link-success:hover {
  background-color: #bbf7d0;
}

.action-link-warning {
  background-color: #fff7ed;
  color: #c2410c;
}

.action-link-warning:hover {
  background-color: #fed7aa;
}

.action-link-danger {
  background-color: #fee2e2;
  color: #b91c1c;
}

.action-link-danger:hover {
  background-color: #fecaca;
}

.btn-icon {
  margin-right: 0.375rem;
}

.empty-state {
  text-align: center;
  padding: 3rem 1rem;
  background-color: white;
  border-radius: 0.5rem;
  box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
}

.empty-state-message {
  color: #6b7280;
  margin-bottom: 1.5rem;
  font-size: 0.875rem;
}

.payslip-container {
  max-width: 800px;
  margin: 0 auto;
  background-color: white;
  border-radius: 0.5rem;
  box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
  overflow: hidden;
}

.payslip-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1.5rem 1rem;
  border-bottom: 1px solid #e5e7eb;
}

.payslip-logo {
  height: 4rem;
  margin-bottom: 1rem;
}

.payslip-title {
  font-size: 1.5rem;
  font-weight: 700;
  text-align: center;
  color: #1f2937;
}

.payslip-content {
  padding: 1.5rem;
}

.payslip-employee-info {
  display: flex;
  justify-content: space-between;
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid #e5e7eb;
}

.payslip-employee-name {
  font-size: 1.25rem;
  font-weight: 600;
  color: #1f2937;
}

.payslip-employee-title {
  font-size: 0.875rem;
  color: #6b7280;
}

.payslip-period-info {
  text-align: right;
}

.payslip-period-label {
  font-weight: 600;
  color: #1f2937;
}

.payslip-period-date {
  color: #6b7280;
}

.payslip-section {
  margin-bottom: 2rem;
}

.payslip-section-title {
  font-weight: 700;
  color: #1f2937;
  border-bottom: 2px solid #e5e7eb;
  padding-bottom: 0.5rem;
  margin-bottom: 1rem;
}

.payslip-table {
  width: 100%;
  border-collapse: collapse;
}

.payslip-table tr {
  border-bottom: 1px solid #e5e7eb;
}

.payslip-table tr:last-child {
  border-bottom: none;
}

.payslip-table td {
  padding: 0.75rem 0;
  color: #1f2937;
}

.payslip-table td:last-child {
  text-align: right;
  font-weight: 500;
}

.payslip-total-row {
  font-weight: 700;
  border-top: 2px solid #e5e7eb;
}

.payslip-holiday-row {
  background-color: #fffbeb;
}

.payslip-holiday-list {
  list-style: none;
  padding: 0;
  margin: 0;
  text-align: right;
}

.payslip-notes {
  margin-top: 1.5rem;
  padding: 1rem;
  background-color: #f9fafb;
  border-radius: 0.375rem;
}

.payslip-notes-title {
  font-weight: 700;
  color: #1f2937;
  margin-bottom: 0.5rem;
}

.payslip-footer {
  text-align: center;
  padding-top: 1.5rem;
  color: #6b7280;
  font-size: 0.75rem;
}

@media print {
  @page {
    size: portrait;
    margin: 0.5cm;
  }
  
  body, html {
    margin: 0 !important;
    padding: 0 !important;
    height: auto !important;
    width: 100% !important;
    background-color: white !important;
    color: black !important;
  }
  
  body, html, #payslip-content, .container, .payslip-container, 
  .payslip-content, .payslip-header, .payslip-footer,
  .payslip-employee-info, .payslip-sections-container {
    background-color: white !important;
    background: white !important;
  }
  
  .container {
    width: 100% !important;
    max-width: 100% !important;
    padding: 0 !important;
    margin: 0 !important;
    background: white !important;
  }
  
  #payslip-content {
    background: white !important;
    padding: 0 !important;
    margin: 0 !important;
  }
  
  .print-hide,
  .template-tag-testing,
  nav, header, footer, button, .sidebar,
  .payslip-container ~ * {
    display: none !important;
  }
  
  .payslip-container {
    width: 100% !important;
    max-width: 100% !important;
    box-shadow: none !important;
    border-radius: 0 !important;
    transform: none !important;
    height: auto !important;
    overflow: visible !important;
    margin: 0 !important;
    padding: 0 !important;
    background: white !important;
  }
  
  .payslip-header {
    padding: 0.5rem !important;
    background: white !important;
  }
  
  .payslip-logo {
    height: 3.5rem !important;
    margin-bottom: 0.5rem !important;
  }
  
  .payslip-title {
    font-size: 1.1rem !important;
    margin-bottom: 0.5rem !important;
  }
  
  .payslip-content {
    padding: 0.5rem !important;
    background: white !important;
  }
  
  .payslip-employee-info {
    margin-bottom: 0.75rem !important;
    padding-bottom: 0.5rem !important;
    background: white !important;
  }
  
  .payslip-employee-name {
    font-size: 1.3rem !important;
  }
  
  .payslip-employee-title {
    font-size: 1rem !important;
  }
  
  .payslip-period-info {
    font-size: 1rem !important;
  }
  
  .payslip-section {
    margin-bottom: 0.75rem !important;
    background: white !important;
  }
  
  .payslip-section-title {
    font-size: 1.1rem !important;
    padding-bottom: 0.3rem !important;
    margin-bottom: 0.5rem !important;
  }
  
  .payslip-table td {
    padding: 0.3rem 0 !important;
    font-size: 1rem !important;
  }
  
  .payslip-sections-container .grid {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 0.5rem !important;
    background: white !important;
  }
  
  .border.rounded-lg {
    border-radius: 0.25rem !important;
    background: white !important;
  }
  
  .bg-blue-50, .bg-green-50, .bg-yellow-50, .bg-red-50 {
    background-color: white !important;
  }
  
  .border.rounded-lg .p-3 {
    padding: 0.5rem !important;
    background: white !important;
  }
  
  .border.rounded-lg .p-4 {
    padding: 0.5rem !important;
    background: white !important;
  }
  
  .list-disc.pl-5.space-y-1 {
    padding-left: 1rem !important;
    margin: 0 !important;
  }
  
  .list-disc.pl-5.space-y-1 li {
    margin: 0 !important;
    padding: 0 !important;
    font-size: 0.9rem !important;
  }
  
  .payslip-footer {
    padding-top: 0.75rem !important;
    font-size: 0.75rem !important;
    margin-top: 0.5rem !important;
    background: white !important;
  }
  
  .payslip-container,
  .payslip-content,
  .payslip-sections-container,
  .payslip-section {
    page-break-inside: avoid !important;
    break-inside: avoid !important;
  }
  
  * {
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
    color-adjust: exact !important;
  }
  
  html, body, div, section, article, aside, header, footer, nav, main {
    background-color: white !important;
    background: white !important;
  }
  
  html, body {
    margin: 0 !important;
    padding: 0 !important;
  }
  
  .payslip-table {
    width: 100% !important;
    margin: 0 !important;
  }
  
  .payslip-sections-container {
    width: 100% !important;
  }
  
  .gap-4 {
    gap: 0.5rem !important;
  }
  
  .gap-8 {
    gap: 0.75rem !important;
  }
  
  h3.payslip-section-title {
    font-size: 1.2rem !important;
  }
  
  @page {
    margin-top: 0.5cm !important;
    margin-bottom: 0.5cm !important;
    margin-left: 0.5cm !important;
    margin-right: 0.5cm !important;
  }
}

.payroll-periods-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
  background-color: #fff;
}

.payroll-periods-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
  padding: 1rem 0;
}

.payroll-periods-title {
  font-size: 1.75rem;
  font-weight: 600;
  color: #1f2937;
  margin: 0;
}

.payroll-periods-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.payroll-periods-btn {
  font-family: inherit;
  font-size: 0.875rem;
  font-weight: 500;
  border: none;
  outline: none;
  background: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  border-radius: 0.375rem;
  padding: 0.5rem 1rem;
  height: 2.5rem;
  transition: all 0.2s;
}

.payroll-periods-btn-icon {
  margin-right: 0.375rem;
}

.payroll-periods-create-btn {
  background-color: #065f46;
  color: white;
}

.payroll-periods-create-btn:hover {
  background-color: #2563eb;
}

.payroll-periods-delete-all-btn {
  background-color: #ef4444;
  color: white;
}

.payroll-periods-delete-all-btn:hover {
  background-color: #dc2626;
}

.payroll-periods-table-container {
  background-color: white;
  border-radius: 0.5rem;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  margin-bottom: 2rem;
}

.payroll-periods-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
}

.payroll-periods-table th {
  text-align: left;
  padding: 0.75rem 1rem;
  background-color: #f9fafb;
  font-size: 0.75rem;
  font-weight: 600;
  color: #6b7280;
  border-bottom: 1px solid #e5e7eb;
  text-transform: uppercase;
}

.payroll-periods-table td {
  padding: 1rem;
  border-bottom: 1px solid #e5e7eb;
  color: #374151;
}

.payroll-periods-table tr:last-child td {
  border-bottom: none;
}

.payroll-periods-actions-cell {
  text-align: right;
  white-space: nowrap;
}

.payroll-periods-row-actions {
  display: flex;
  justify-content: flex-start;
  gap: 0.5rem;
}

.payroll-periods-row-btn {
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 500;
  border: none;
  outline: none;
  background: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  padding: 0.375rem 0.75rem;
  border-radius: 0.25rem;
  transition: all 0.2s;
}

.payroll-periods-row-btn-icon {
  margin-right: 0.25rem;
}

.payroll-periods-view-btn {
  background-color: #dbeafe;
  color: #1e40af;
}

.payroll-periods-view-btn:hover {
  background-color: #bfdbfe;
}

.payroll-periods-generate-btn {
  background-color: #d1fae5;
  color: #065f46;
}

.payroll-periods-generate-btn:hover {
  background-color: #a7f3d0;
}

.payroll-periods-delete-btn {
  background-color: #fee2e2;
  color: #b91c1c;
}

.payroll-periods-delete-btn:hover {
  background-color: #fecaca;
}

.payroll-periods-status-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.25rem 0.625rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 500;
}

.payroll-periods-status-not-processed {
  background-color: #f3f4f6;
  color: #4b5563;
}

.payroll-periods-status-processed {
  background-color: #dbeafe;
  color: #1e40af;
}

.payroll-periods-status-approved {
  background-color: #d1fae5;
  color: #065f46;
}

.payroll-periods-empty-state {
  padding: 4rem 2rem;
  text-align: center;
  background-color: white;
  border-radius: 0.5rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.payroll-periods-empty-message {
  color: #6b7280;
  margin-bottom: 1.5rem;
  font-size: 0.875rem;
}

.payperiod-detail-actions {
  display: flex;
  gap: 0.75rem;
  align-items: center;
}

.payperiod-detail-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.875rem;
  font-weight: 500;
  padding: 0.5rem 1rem;
  border-radius: 0.375rem;
  transition: all 0.15s ease-in-out;
  text-decoration: none;
  border: none;
  height: 2.5rem;
}

.payperiod-detail-actions form {
  margin: 0 !important;
  padding: 0 !important;
  display: inline-block !important;
}

.payperiod-detail-actions form button[type="submit"] {
  margin: 0 !important;
  width: auto !important;
  display: inline-flex !important;
  height: 2.5rem !important;
}

.payperiod-detail-generate-btn {
  background-color: #3b82f6;
  color: white;
}

.payperiod-detail-generate-btn:hover {
  background-color: #2563eb;
}

.payperiod-detail-review-btn {
  background-color: #10b981;
  color: white;
}

.payperiod-detail-review-btn:hover {
  background-color: #059669;
}

.payperiod-detail-export-btn {
  background-color: #ffffff;
  color: #374151;
  border: 1px solid #d1d5db;
}

.payperiod-detail-export-btn:hover {
  background-color: #f3f4f6;
}

.payperiod-detail-delete-btn {
  background-color: #ef4444;
  color: white;
}

.payperiod-detail-delete-btn:hover {
  background-color: #dc2626;
}

.payperiod-detail-btn.payperiod-detail-generate-btn {
  background-color: #3b82f6 !important;
  color: white !important;
}

.payperiod-detail-btn.payperiod-detail-review-btn {
  background-color: #10b981 !important;
  color: white !important;
}

.payperiod-detail-btn.payperiod-detail-export-btn {
  background-color: #ffffff !important;
  color: #374151 !important;
  border: 1px solid #d1d5db !important;
}

.payperiod-detail-btn.payperiod-detail-delete-btn {
  background-color: #ef4444 !important;
  color: white !important;
}

.payroll-entries-container {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  width: 100%;
}

.payroll-entry-card {
  background-color: white;
  border-radius: 0.5rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  overflow: hidden;
  border: 1px solid #e5e7eb;
}

.payroll-entry-card:hover {
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.payroll-entry-card.has-discrepancy {
  border-left: 4px solid #4f46e5;
}

.entry-header {
  padding: 1rem;
  border-bottom: 1px solid #e5e7eb;
  background-color: #f9fafb;
  display: flex;
  justify-content: space-between;
}

.employee-info {
  display: flex;
  flex-direction: column;
}

.employee-name {
  font-size: 1.125rem;
  font-weight: 600;
  color: #111827;
}

.employee-email {
  font-size: 0.875rem;
  color: #6b7280;
  margin-top: 0.25rem;
}

.entry-status {
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 500;
  height: fit-content;
}

.status-draft {
  background-color: #dbeafe;
  color: #1e40af;
}

.status-approved {
  background-color: #d1fae5;
  color: #065f46;
}

.status-pending {
  background-color: #f3f4f6;
  color: #4b5563;
}

.entry-hours {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 1rem;
  padding: 1rem;
  border-bottom: 1px solid #e5e7eb;
}

.hours-item {
  display: flex;
  flex-direction: column;
}

.hours-label {
  font-size: 0.75rem;
  color: #6b7280;
  font-weight: 500;
  margin-bottom: 0.25rem;
}

.hours-value {
  font-size: 1.125rem;
  font-weight: 600;
  color: #111827;
}

.hours-difference {
  color: #b45309;
  font-weight: 500;
}

.hours-difference.positive {
  color: #065f46;
}

.entry-components {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 1rem;
  padding: 1rem;
  border-bottom: 1px solid #e5e7eb;
}

.pay-component {
  display: flex;
  flex-direction: column;
}

.component-label {
  font-size: 0.75rem;
  color: #6b7280;
  font-weight: 500;
  margin-bottom: 0.25rem;
}

.component-value {
  font-size: 1.125rem;
  font-weight: 600;
  color: #111827;
}

.component-value.zero {
  color: #9ca3af;
  font-weight: normal;
}

.entry-absences {
  padding: 1rem;
  border-bottom: 1px solid #e5e7eb;
}

.absences-title {
  font-size: 0.875rem;
  color: #6b7280;
  margin-bottom: 0.5rem;
}

.absence-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.absence-badge {
  padding: 0.25rem 0.5rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 500;
}

.badge-holiday {
  background-color: #dbeafe;
  color: #1e40af;
}

.badge-vacation {
  background-color: #d1fae5;
  color: #065f46;
}

.badge-unpaid {
  background-color: #fff7ed;
  color: #c2410c;
}

.badge-sick {
  background-color: #fee2e2;
  color: #b91c1c;
}

.entry-actions {
  padding: 1rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background-color: #f9fafb;
}

.total-pay {
  display: flex;
  align-items: baseline;
}

.total-label {
  font-size: 0.875rem;
  font-weight: 500;
  color: #374151;
  margin-right: 0.5rem;
}

.total-value {
  font-size: 1.25rem;
  font-weight: 700;
  color: #111827;
}

.view-payslip {
  display: inline-flex;
  align-items: center;
  padding: 0.5rem 0.75rem;
  border-radius: 0.375rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: #4f46e5;
  background-color: #eef2ff;
}

.view-payslip:hover {
  background-color: #e0e7ff;
}

.discrepancy-button {
  background-color: transparent !important;
  color: #b45309;
  border: none;
  padding: 0;
  font-size: 0.875rem;
  cursor: pointer;
  text-decoration: underline;
}

.discrepancy-button:hover {
  color: #92400e;
}

.toggle-view-button {
  display: inline-flex;
  align-items: center;
  padding: 0.5rem 1rem;
  margin: 1rem;
  background-color: #4f46e5;
  color: white;
  border: none;
  border-radius: 0.375rem;
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
}

.toggle-view-button:hover {
  background-color: #4338ca;
}

.toggle-view-button i {
  margin-right: 0.5rem;
}

.currency-selector {
  max-width: 250px;
  margin-bottom: 1rem;
}

.currency-selector select {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  background-image: none;
  padding-right: 2.5rem;
}

.currency-selector .absolute {
  pointer-events: none;
  display: flex;
  align-items: center;
  justify-content: center;
  right: 0;
  top: 0;
  bottom: 0;
  width: 2.5rem;
}

.currency-selector select {
  width: 100%;
  border: 1px solid #d1d5db;
  border-radius: 0.375rem;
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
  line-height: 1.25rem;
  color: #111827;
  background-color: #fff;
  transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}

.currency-selector select:focus {
  outline: none;
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.3);
}

.currency-selector select:hover {
  border-color: #9ca3af;
}

.currency-selector svg {
  width: 1rem;
  height: 1rem;
  color: #6b7280;
}

.convertible-amount {
  position: relative;
  transition: opacity 0.3s ease;
}

.convertible-amount.converting {
  opacity: 0.7;
}

#conversion-info {
  font-size: 0.75rem;
  color: #6b7280;
  margin-top: 0.25rem;
}

@media (max-width: 768px) {
  .delete-btn {
    width: 100%;
    margin-top: 0.5rem;
  }
  
  .action-links {
    flex-direction: column;
  }
  
  .payroll-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
  }
  
  .payroll-actions {
    width: 100%;
  }
  
  .btn {
    flex: 1;
  }
}

.dropdown {
    display: inline-flex;
}

.dropdown-toggle {
    height: 2.5rem;
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    white-space: nowrap;
    padding: 0.5rem 1rem !important;
    width: auto !important;
}

.dropdown-menu {
    min-width: 10rem;
    right: 0;
    left: auto;
    margin-top: 0.125rem;
    border-radius: 0.375rem;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

.payperiod-detail-export-btn i,
.payroll-periods-generate-btn i {
    margin-right: 0.25rem;
}

.payroll-periods-row-actions {
    display: flex;
    align-items: center;
    justify-content: flex-start;
}

.payroll-periods-row-btn,
.payroll-periods-row-actions .dropdown-toggle,
.payroll-periods-row-actions form button {
    height: 2.25rem !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
}

.dropdown:hover .dropdown-menu {
    display: block;
}

.dropdown-item {
    color: #374151;
    padding: 8px 16px;
    text-decoration: none;
    display: flex;
    align-items: center;
    font-size: 0.875rem;
}

.dropdown-item:hover {
    background-color: #f3f4f6;
}

.ml-1 {
    margin-left: 0.25rem;
}

.mr-2 {
    margin-right: 0.5rem;
}

/* Payroll Information Form Styles */
.payroll-info-container {
  max-width: 800px;
  margin: 0 auto;
  padding: 2rem;
  background-color: white;
  border-radius: 0.5rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.payroll-info-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 2px solid #e5e7eb;
}

.payroll-info-title {
  font-size: 1.75rem;
  font-weight: 600;
  color: #1f2937;
  margin: 0;
}

.payroll-info-description {
  color: #6b7280;
  margin-bottom: 1.5rem;
  font-size: 0.875rem;
}

.payroll-info-form {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.form-group {
  display: flex;
  flex-direction: column;
}

.form-group label {
  font-weight: 500;
  color: #374151;
  margin-bottom: 0.5rem;
}

.form-group input {
  padding: 0.75rem;
  border: 1px solid #d1d5db;
  border-radius: 0.375rem;
  font-size: 1rem;
  transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}

.form-group input:focus {
  outline: none;
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.3);
}

.form-group .form-text {
  margin-top: 0.375rem;
  font-size: 0.75rem;
  color: #6b7280;
}

.btn-save-payroll {
  background-color: #3b82f6;
  color: white;
  border: none;
  border-radius: 0.375rem;
  padding: 0.75rem 1rem;
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: background-color 0.15s ease-in-out;
  margin-top: 1rem;
}

.btn-save-payroll:hover {
  background-color: #2563eb;
}

.encryption-notice {
  display: flex;
  align-items: center;
  padding: 1rem;
  background-color: #f3f4f6;
  border-radius: 0.375rem;
  margin-bottom: 1.5rem;
}

.encryption-notice-icon {
  margin-right: 0.75rem;
  color: #4b5563;
}

.encryption-notice-text {
  font-size: 0.875rem;
  color: #4b5563;
}

/* Responsive adjustments */
@media (max-width: 640px) {
  .payroll-info-container {
    padding: 1.5rem;
  }
  
  .payroll-info-title {
    font-size: 1.5rem;
  }
}

/* Dropdown menu styling fix */
.dropdown {
  position: relative;
  display: inline-block;
}

.dropdown-toggle {
  cursor: pointer;
}

.dropdown-menu {
  position: absolute;
  right: 0;
  top: 100%;
  z-index: 1000;
  display: none;
  min-width: 10rem;
  padding: 0.5rem 0;
  margin: 0.125rem 0 0;
  font-size: 0.875rem;
  color: #212529;
  text-align: left;
  list-style: none;
  background-color: #fff;
  background-clip: padding-box;
  border: 1px solid rgba(0, 0, 0, 0.15);
  border-radius: 0.25rem;
  box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.175);
}

.dropdown-item {
  display: block;
  width: 100%;
  padding: 0.25rem 1.5rem;
  clear: both;
  font-weight: 400;
  color: #212529;
  text-align: inherit;
  white-space: nowrap;
  background-color: transparent;
  border: 0;
  text-decoration: none;
}

.dropdown-item:hover, .dropdown-item:focus {
  color: #16181b;
  text-decoration: none;
  background-color: #f8f9fa;
}

.dropdown-item.active, .dropdown-item:active {
  color: #fff;
  text-decoration: none;
  background-color: #007bff;
}

.dropdown-item.disabled, .dropdown-item:disabled {
  color: #6c757d;
  pointer-events: none;
  background-color: transparent;
}


/* Additional CSS to improve payslip print layout */
@media print {
  /* Adjust overall container to reduce excess bottom space */
  .payslip-container {
    margin-bottom: 0 !important;
    height: auto !important;
    max-height: none !important;
  }
  
  /* Improve spacing between main sections */
  .payslip-content {
    padding: 1rem !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: space-between !important;
    height: auto !important;
  }
  
  /* Add more space between main sections */
  .payslip-employee-info {
    margin-bottom: 1.25rem !important;
    padding-bottom: 0.75rem !important;
  }
  
  .payslip-sections-container {
    margin-bottom: 1.25rem !important;
  }
  
  /* Better spacing for the hours and earnings grid */
  .payslip-sections-container .grid {
    gap: 1.5rem !important;
    margin-bottom: 1.5rem !important;
  }
  
  /* Add spacing between sections */
  .payslip-section {
    margin-bottom: 1.5rem !important;
  }
  
  /* Increase spacing for section titles */
  .payslip-section-title {
    margin-bottom: 0.75rem !important;
    padding-bottom: 0.5rem !important;
  }
  
  /* Improve table cell spacing */
  .payslip-table td {
    padding: 0.5rem 0 !important;
  }
  
  /* Make the Extra Information section more compact */
  .payslip-section.mt-8 {
    margin-top: 1.5rem !important;
  }
  
  /* Improve spacing for the absence info grid */
  .grid.grid-cols-1.md\\:grid-cols-2.gap-4 {
    gap: 1rem !important;
  }
  
  /* Adjust footer spacing */
  .payslip-footer {
    margin-top: 1.5rem !important;
    padding-top: 1rem !important;
  }
  
  /* Force content to fit on a single page */
  @page {
    size: portrait;
    margin: 1cm;
  }
  
  /* Ensure proper spacing on the page */
  html, body {
    height: 100% !important;
  }
  
  #payslip-content {
    height: auto !important;
    display: flex !important;
    flex-direction: column !important;
  }
  
  /* Distribute content more evenly on the page */
  .payslip-container {
    display: flex !important;
    flex-direction: column !important;
    justify-content: flex-start !important;
    height: auto !important;
    page-break-inside: avoid !important;
  }
  
  /* Ensure notes don't get too much space */
  .payslip-notes {
    margin-top: 1rem !important;
    padding: 0.75rem !important;
  }
}

/* Payslip Single Page Layout Fix */
@media print {
  /* Ensure everything fits on one page by controlling vertical spacing */
  .payslip-container {
    /* Control max height to fit on a single page */
    max-height: 100% !important;
    height: auto !important;
    page-break-inside: avoid !important;
    page-break-after: avoid !important;
    page-break-before: avoid !important;
  }
  
  /* Add space after logo but prevent page break */
  .payslip-header {
    padding: 1.5rem 1rem 1rem !important; 
    margin-bottom: 0.5rem !important;
    page-break-after: avoid !important;
  }
  
  /* Make logo slightly larger but not too much */
  .payslip-logo {
    height: 4.5rem !important;
    margin-bottom: 1rem !important;
  }
  
  /* Reduce excessive white space between header and employee info */
  .payslip-employee-info {
    margin-top: 0.5rem !important;
    margin-bottom: 1.75rem !important;
    padding-bottom: 0.75rem !important;
    page-break-after: avoid !important;
  }
  
  /* Keep hours and earnings together */
  .payslip-sections-container .grid {
    page-break-inside: avoid !important;
    gap: 1.5rem !important;
    margin-bottom: 1.5rem !important;
  }
  
  /* Make sure section titles don't break */
  .payslip-section-title {
    page-break-after: avoid !important;
    margin-bottom: 0.75rem !important;
    padding-bottom: 0.5rem !important;
  }
  
  /* Adjust spacing for tables */
  .payslip-table {
    margin-bottom: 0.5rem !important;
  }
  
  .payslip-table td {
    padding: 0.5rem 0 !important;
  }
  
  /* Optimize Extra Information section */
  .payslip-section.mt-8 {
    margin-top: 1.5rem !important;
    page-break-before: avoid !important;
  }
  
  /* Adjust absence info grid */
  .grid.grid-cols-1.md\\:grid-cols-2.gap-4 {
    gap: 1rem !important;
  }
  
  /* Keep footer compact */
  .payslip-footer {
    margin-top: 1rem !important;
    padding-top: 0.75rem !important;
  }
  
  /* Optimize page margins */
  @page {
    size: portrait;
    margin: 0.75cm;
  }
  
  /* Ensure all content is visible */
  html, body {
    height: auto !important;
    overflow: visible !important;
  }
  
  /* Prevent unwanted page breaks */
  .payslip-content, 
  .payslip-sections-container,
  .payslip-section {
    page-break-inside: avoid !important;
  }
  
  /* Ensure the Extra Information stays on same page */
  #Extra-Information {
    page-break-before: avoid !important;
  }
}

/* Final adjustment to move logo higher */
@media print {
  /* Adjust logo position to be higher */
  .payslip-header {
    padding-top: 2.5rem !important; /* Increased from 1.5rem */
    padding-bottom: 1rem !important;
  }
  
  /* Make logo slightly larger */
  .payslip-logo {
    height: 5rem !important;
    margin-top: -1rem !important; /* Negative margin to move logo up */
    margin-bottom: 1.25rem !important;
  }
  
  /* Adjust header spacing */
  .payslip-title {
    margin-bottom: 1.25rem !important;
  }
  
  /* Make sure this change doesn't affect other spacing */
  .payslip-container {
    max-height: 100% !important;
    height: auto !important;
    page-break-inside: avoid !important;
  }
  
  /* Keep everything on one page */
  @page {
    size: portrait;
    margin: 0.7cm;
  }
}