body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  line-height: 1.6;
  color: #333;
  background-color: #f5f7fa;
  margin: 0;
  padding: 0;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* remove side padding on small screens */
@media (max-width: 600px) {
  body {
    padding: 20px 0;
  }
}

.container {
  width: 100%;
  padding: 20px;
  max-width: 960px;
  margin: 0 auto;
  box-sizing: border-box;
}

.centered-container {

  padding: 20px;
  max-width: 960px;
  margin: 0 auto;
}

.card {
  background-color: white;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  padding: 2rem;
  width: 100%;
  margin: 0 auto;
  box-sizing: border-box;
}

.logo {
  font-family: 'Righteous', cursive;
  font-size: 2.5rem;
  text-align: center;
  margin-bottom: 1.5rem;
  color: #3498db;
}

.logo span {
  color: #e74c3c;
}

.greeting {
  font-size: 1.4rem;
  margin-bottom: 1.5rem;
  text-align: center;
  font-weight: 500;
  color: #2c3e50;
}

h1, h2 {
  text-align: left;
  margin: 10px;
  color: #2c3e50;
  font-weight: normal;
}

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

label {
  font-weight: 500;
  margin-bottom: 0.3rem; /* Reduced from 0.5rem */
  color: #4a5568;
  display: block;
}

input, select {
  padding: 8px 10px; /* Reduced from 10px 12px */
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 16px;
  margin-bottom: 0.8rem; /* Reduced from 1.2rem */
  transition: border-color 0.3s;
  width: 100%;
  box-sizing: border-box;
}

input:focus, select:focus {
  outline: none;
  border-color: #4299e1;
  box-shadow: 0 0 0 3px rgba(66, 153, 225, 0.15);
}

.button-group {
  display: flex;
  justify-content: space-between;
  margin-top: 1rem;
}

button.btn {
  background-color: #4299e1;
    color: white;
    border: none;
    padding: 8px 15px;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.3s;
    min-width: 100px;
}

button.btn.icon-only {
  background-color: transparent;
    color: #333;
    border: none;
    padding: 8px 15px;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.3s;
    min-width: auto;
}

button.btn.icon-only.danger {
  color:red;
}

button.btn.icon-only.danger {
  color:red;
}

button.btn:hover:not(:disabled) {
  background-color: #3182ce;
}

button.btn.icon-only:hover:not(:disabled) {
  background-color: transparent;
}

button:disabled {
  background-color: #a0aec0;
  cursor: not-allowed;
}

button.secondary {
  background-color: #e2e8f0;
  color: #4a5568;
}

button.secondary:hover:not(:disabled) {
  background-color: #cbd5e0;
}

button.danger {
  background-color: #e53e3e;
  color: white;
}

button.danger:hover:not(:disabled) {
  background-color: #c53030;
}

.message {
  margin-top: 1rem;
  padding: 0.75rem;
  border-radius: 4px;
  font-size: 14px;
  text-align: center;
}

.message.error {
  background-color: #fff5f5;
  color: #c53030;
  border: 1px solid #feb2b2;
}

.message.success {
  background-color: #f0fff4;
  color: #276749;
  border: 1px solid #9ae6b4;
}

.navigation-links {
  text-align: center;
  margin-top: 1.5rem;
  font-size: 14px;
  color: #718096;
}

.navigation-links a {
  color: #4299e1;
  text-decoration: none;
  transition: color 0.2s;
}

.navigation-links a:hover {
  color: #3182ce;
  text-decoration: underline;
}

.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 20px;
}

/* remove padding from modal overlay on small screens */
@media (max-width: 600px) {
  .modal-overlay {
    padding: 0;
  }
}

.modal {
  background: white;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);

  max-width: 500px;
  width: 100%;
  position: relative;
}

.modal .button-group{
  display: flex
          ;
              justify-content: end;
              margin-top: 1rem;
              gap: 15px;
              padding: 15px;
}

.modal-body{
  padding:15px;
}

.modal.compact {
  padding: 1.5rem;
}

.modal.compact h2 {
  margin-bottom: 15px;
}

.modal.compact .form-group {
  margin-bottom: 8px;
}

.employee-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
  margin-top: 20px;
}

.employee-card {
  background-color: white;
  border-radius: 8px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  padding: 1.5rem;
  position: relative;
  transition: transform 0.2s, box-shadow 0.2s;
}

.employee-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

.employee-card h3 {
  margin-top: 0;
  margin-bottom: 15px;
  color: #2c3e50;
  font-size: 1.2rem;
}

.employee-card p {
  margin: 8px 0;
  font-size: 0.9rem;
  color: #4a5568;
}

.status {
  display: inline-block;
  padding: 3px 8px;
  border-radius: 12px;
  font-size: 0.75rem;
  font-weight: 500;
  margin-left: 5px;
}

.status.active {
  background-color: #68d391;
  color: #22543d;
}

.status.inactive {
  background-color: #fc8181;
  color: #742a2a;
}



.form-group {
  margin-bottom: 12px; /* Reduced from 15px */
}

.error {
  color: #e53e3e;
  font-size: 0.8rem;
  margin-top: -10px;
  margin-bottom: 10px;
}

.add-another {
  margin-top: 20px;
  text-align: center;
  border-top: 1px solid #e2e8f0;
  padding-top: 20px;
}

.password-strength {
  margin-top: -10px;
  margin-bottom: 15px;
}

.strength-meter {
  height: 4px;
  background-color: #e2e8f0;
  border-radius: 2px;
  margin-bottom: 5px;
}

.strength-bar {
  height: 100%;
  border-radius: 2px;
  transition: width 0.3s, background-color 0.3s;
}

.strength-text {
  font-size: 0.75rem;
  text-align: right;
}



.card-action-button { 
  background: none;
  border: none;
  cursor: pointer;
  padding: 5px;
  align-items: center;
  justify-content: right;
  transition: color 0.2s;
  flex-grow: 0;
  min-width: 0px;
}

.card-action-button:hover {
background-color: transparent !important;
}

@media (max-width: 640px) {
  .container {
    padding: 0;
  }

  .card {
    padding: 1.5rem;
    box-shadow: none;
    border-radius: 0;
  }


  .modal-overlay {
    padding: 0;
  }

  .modal {
    border-radius: 0;
    max-width: none;
    height: 100%;
    overflow-y: auto;
  }

  .button-group {
    flex-direction: column-reverse;
    gap: 10px;
  }

  button {
    width: 100%;
  }
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.spinner {
  width: 50px;
  height: 50px;
  border: 5px solid #f5f7fa;
  border-top-color: #4299e1;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

#loading-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  z-index: 1001;
  display: flex;
  justify-content: center;
  align-items: center;
}

.app-container {
  width: 100%;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.material-icons{
  vertical-align: middle;
 
}

.page-content {
  flex: 1;
}

.header-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}

/* Specific styling for checkbox labels */
.checkbox-label {
  display: flex;
  align-items: center;
  cursor: pointer;
  margin-bottom: 0.5rem;
}

.checkbox-label input[type="checkbox"] {
  margin: 0 8px 0 0;
  padding: 0;
  width: auto;
  height: auto;
}

/* ========== Modal Styling ========== */
.modal-overlay {
  display: flex;
  justify-content: center;
  align-items: center;
  position: fixed;
  z-index: 10;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
}

.modal-content {
  background-color: white;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  width: 90%;
  max-width: 500px;
  max-height: 90vh;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
}

.modal-compact {
  max-width: 400px;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 20px;
  border-bottom: 1px solid #e2e8f0;
}

.modal-header h2 {
  margin: 0;
  color: #2c3e50;
  font-size: 18px;
}

.modal-body {
  padding: 20px;
  position: relative;
}

/* Scroll indicators using pseudo-elements */
.modal-body::before,
.modal-body::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  height: 20px;
  pointer-events: none;
  z-index: 1;
  opacity: 0;
  transition: opacity 0.3s;
}

/* Top shadow - appears when scrolled down */
.modal-body::before {
  top: 0;
  background: linear-gradient(to bottom, rgba(255, 255, 255, 0.9) 0%, rgba(255, 255, 255, 0) 100%);
}

/* Bottom shadow - appears when more content below */
.modal-body::after {
  bottom: 0;
  background: linear-gradient(to top, rgba(255, 255, 255, 0.9) 0%, rgba(255, 255, 255, 0) 100%);
}

/* Show bottom shadow when scrollable */
.modal-body:not([style*="overflow-y:hidden"]):not([style*="overflow-y: hidden"]) {
  -webkit-mask-image: linear-gradient(to top, transparent 0%, black 20px);
  mask-image: linear-gradient(to top, transparent 0%, black 20px);
}

/* For webkit browsers like Chrome and Safari */
.modal-body::-webkit-scrollbar {
  width: 6px;
}

.modal-body::-webkit-scrollbar-track {
  background: #f7fafc;
}

.modal-body::-webkit-scrollbar-thumb {
  background-color: #cbd5e0;
  border-radius: 6px;
}

.modal-footer {
  padding: 15px 20px;
  border-top: 1px solid #e2e8f0;
  text-align: center;
}

.close {
  font-size: 24px;
  font-weight: bold;
  color: #a0aec0;
  cursor: pointer;
}

.close:hover {
  color: #4a5568;
}

.button-group {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  padding: 15px 20px;
  border-top: 1px solid #e2e8f0;
}

.button-group button {
  padding: 8px 16px;
  border: none;
  border-radius: 4px;
  font-size: 16px;
  font-weight: 500;
  cursor: pointer;
}

.button-group button.secondary {
  background-color: #e2e8f0;
  color: #4a5568;
}

.button-group button.secondary:hover {
  background-color: #cbd5e0;
}

.button-group button:not(.secondary):not(.danger) {
  background-color: #4299e1;
  color: white;
}

.button-group button:not(.secondary):not(.danger):hover {
  background-color: #3182ce;
}

.button-group button.danger {
  background-color: #e53e3e;
  color: white;
}

.button-group button.danger:hover {
  background-color: #c53030;
}

/* Info sections for modals */
.info-section {
  background-color: #f8fafc;
  border-radius: 6px;
  padding: 12px;
  margin-bottom: 16px;
}

.info-section p {
  margin: 6px 0;
  display: flex;
  align-items: center;
  font-size: 14px;
}

.info-section .material-icons {
  font-size: 18px;
  margin-right: 8px;
  color: #4a5568;
}

/* Loading spinner modal */
#loading-modal {
  display: flex;
  justify-content: center;
  align-items: center;
  position: fixed;
  z-index: 20;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(255, 255, 255, 0.7);
}

.spinner {
  width: 50px;
  height: 50px;
  border: 5px solid rgba(66, 153, 225, 0.3);
  border-radius: 50%;
  border-top-color: #4299e1;
  animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* Mobile optimizations */
@media (max-width: 767px) {
  .modal-content {
    width: 95%;
    max-height: 80vh;
  }
  
  .modal-body {
    padding: 15px;
  }
  
  .button-group {
    padding: 10px 15px;
  }
}

/* Modal Dialog Styling */
.modal-overlay {
  display: flex;
  justify-content: center;
  align-items: center;
  position: fixed;
  z-index: 10;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
}

.modal-container {
  background-color: white;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  width: 90%;
  max-width: 500px;
  max-height: 90vh;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 20px;
  border-bottom: 1px solid #e2e8f0;
  flex: 0 0 auto;
}

.modal-header h2 {
  margin: 0;
  color: #2c3e50;
  font-size: 18px;
}

.modal-close {
  font-size: 24px;
  font-weight: bold;
  color: #a0aec0;
  cursor: pointer;
}

.modal-close:hover {
  color: #4a5568;
}

.modal-body {
  flex: 1 1 auto;
  overflow-y: auto;
  padding: 15px 20px;
}

.modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  padding: 15px 20px;
  border-top: 1px solid #e2e8f0;
  flex: 0 0 auto;
}

.modal-footer button {
  padding: 8px 16px;
  border: none;
  border-radius: 4px;
  font-size: 16px;
  font-weight: 500;
  cursor: pointer;
}

.btn-secondary {
  background-color: #e2e8f0;
  color: #4a5568;
}

.btn-secondary:hover {
  background-color: #cbd5e0;
}

.btn-primary {
  background-color: #4299e1;
  color: white;
}

.btn-primary:hover {
  background-color: #3182ce;
}

/* Mobile optimizations */
@media (max-width: 767px) {
  .modal-container {
    width: 95%;
    max-height: 80vh;
  }
  
  .modal-footer {
    flex-direction: column;
  }
  
  .modal-footer button {
    width: 100%;
  }
}

/* Append at end of file to ensure precedence */
button:disabled,
button.btn:disabled,
button.icon-only:disabled,
button.secondary:disabled,
button.danger:disabled {
  background-color: #a0aec0 !important;
  cursor: not-allowed !important;
}

/* ========== Settings Section Styles (moved here) ========== */
.settings-section {
    padding: 15px 20px;
    border-bottom: 1px solid #e2e8f0;
}

.settings-section h3 {
    margin: 0 0 15px 0;
    font-size: 16px;
    color: #2c3e50;
}

/* Remove border on last settings-section */
.settings-section:last-child {
    border-bottom: none;
}


