/**
 * Momo Space CMMS - Custom Styles
 */

/* Additional custom styles beyond the inline styles in css.ejs */

/* Avatar styles */
.avatar-initial {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  font-size: 1rem;
  font-weight: 600;
  color: #fff;
}

.avatar-online::after {
  content: '';
  position: absolute;
  bottom: 0;
  right: 0;
  width: 10px;
  height: 10px;
  background-color: #71dd37;
  border: 2px solid #fff;
  border-radius: 50%;
}

/* Form styles */
.form-label {
  font-weight: 500;
  margin-bottom: 0.5rem;
}

.form-control:focus,
.form-select:focus {
  border-color: #696cff;
  box-shadow: 0 0 0 0.2rem rgba(105, 108, 255, 0.25);
}

/* Card hover effect */
.card-hover:hover {
  transform: translateY(-4px);
  box-shadow: 0 4px 25px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
}

/* Scrollable containers */
.scrollable-container {
  max-height: 300px;
  overflow-y: auto;
}

/* Dropdown styles */
.dropdown-shortcuts-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background-color: rgba(105, 108, 255, 0.1);
  border-radius: 50%;
  margin-right: 0.75rem;
}

/* Loading spinner */
.spinner-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(255, 255, 255, 0.8);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
}

/* DataTables customization */
.dataTables_wrapper .dataTables_length select {
  padding: 0.375rem 2rem 0.375rem 0.75rem;
}

.dataTables_wrapper .dataTables_filter input {
  margin-left: 0.5rem;
}

/* Status indicators */
.status-indicator {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  margin-right: 0.5rem;
}

.status-indicator.active { background-color: #71dd37; }
.status-indicator.inactive { background-color: #8592a3; }
.status-indicator.warning { background-color: #ffab00; }
.status-indicator.danger { background-color: #ff3e1d; }

/* Quick action buttons */
.quick-action-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  border-radius: 0.5rem;
  text-decoration: none;
  transition: all 0.2s ease;
}

.quick-action-btn:hover {
  transform: translateY(-2px);
}

.quick-action-btn i {
  font-size: 2rem;
  margin-bottom: 0.5rem;
}

/* Print styles */
@media print {
  .no-print {
    display: none !important;
  }

  .layout-menu,
  .layout-navbar,
  .content-footer {
    display: none !important;
  }

  .layout-page {
    margin-left: 0 !important;
  }

  .content-wrapper {
    padding-top: 0 !important;
  }
}

/* QR Code modal */
#qr-code-image {
  max-width: 200px;
  margin: 0 auto;
}

/* Timeline styles for work order history */
.timeline {
  position: relative;
  padding-left: 30px;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 10px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: #e4e6e8;
}

.timeline-item {
  position: relative;
  padding-bottom: 1.5rem;
}

.timeline-item::before {
  content: '';
  position: absolute;
  left: -24px;
  top: 0;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #696cff;
  border: 2px solid #fff;
  box-shadow: 0 0 0 2px #696cff;
}

.timeline-item.completed::before {
  background: #71dd37;
  box-shadow: 0 0 0 2px #71dd37;
}

/* Checklist styles */
.checklist-item {
  display: flex;
  align-items: center;
  padding: 0.5rem 0;
  border-bottom: 1px solid #f0f0f0;
}

.checklist-item:last-child {
  border-bottom: none;
}

.checklist-item input[type="checkbox"] {
  margin-right: 0.75rem;
}

.checklist-item.completed label {
  text-decoration: line-through;
  color: #8592a3;
}

/* Metric cards */
.metric-card {
  text-align: center;
  padding: 1.5rem;
}

.metric-value {
  font-size: 2.5rem;
  font-weight: 700;
  color: #566a7f;
  line-height: 1;
}

.metric-label {
  font-size: 0.875rem;
  color: #8592a3;
  margin-top: 0.5rem;
}

.metric-change {
  font-size: 0.75rem;
  margin-top: 0.25rem;
}

.metric-change.positive { color: #71dd37; }
.metric-change.negative { color: #ff3e1d; }

/* Calendar styles */
.calendar-event {
  padding: 0.25rem 0.5rem;
  border-radius: 0.25rem;
  font-size: 0.75rem;
  margin-bottom: 0.25rem;
}

.calendar-event.pm { background-color: rgba(3, 195, 236, 0.2); color: #03c3ec; }
.calendar-event.wo { background-color: rgba(255, 171, 0, 0.2); color: #ffab00; }

/* Dark mode support (future) */
@media (prefers-color-scheme: dark) {
  /* Dark mode styles can be added here */
}
