body.admin-body {
  background-color: #f4f6f9;
  color: #1f2a37;
}

.admin-navbar {
  /* background: linear-gradient(90deg, #1e3a8a, #312e81); */
  background: #0d0d0df2;
  color: #fff;
}

.admin-navbar .navbar-brand {
  color: #fff;
}

.admin-navbar .navbar-brand:hover,
.admin-navbar .btn-outline-light:hover {
  color: #0ea5e9;
}

.admin-brand-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  font-size: 16px;
}

.admin-auth-wrapper {
  max-width: 420px;
  margin: 0 auto;
}

.admin-auth-card {
  /* background-color: #f4f6f9;
  border: 1px solid #e5e7eb;
  
  */
  /* box-shadow: 0 20px 45px rgba(15, 23, 42, 0.08); */
  border-radius: 16px;
  min-height: calc(100vh - 6rem);
  display: flex;
  align-items: center;
  justify-content: center;
  padding:  1rem;
}

.admin-dashboard-wrapper {
  padding-bottom: 60px;
}

.admin-section-title {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 1rem;
}

.admin-metrics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
}

.admin-metric-card {
  background: #fff;
  border-radius: 16px;
  border: 1px solid #e5e7eb;
  padding: 20px;
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.06);
  display: flex;
  flex-direction: column;
}

.admin-metric-card .metric-label {
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #6b7280;
}

.admin-metric-card .metric-value {
  font-size: 2rem;
  font-weight: 700;
  margin-top: 0.2rem;
  color: #1e3a8a;
}

.admin-filters {
  background: #fff;
  border-radius: 16px;
  border: 1px solid #e5e7eb;
  padding: 16px;
  margin-bottom: 20px;
}

.admin-table-wrapper {
  background: #fff;
  border-radius: 16px;
  border: 1px solid #e5e7eb;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.05);
}

.admin-table thead {
  background: #eef2ff;
  color: #1e3a8a;
  text-transform: uppercase;
  font-size: 0.75rem;
  letter-spacing: 0.05em;
}

.admin-table tbody tr:hover {
  background: #f8fafc;
}

.admin-status-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.25rem 0.6rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
}

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

.admin-status-badge.inactive {
  background: rgba(248, 113, 113, 0.15);
  color: #b91c1c;
}

.admin-actions .btn {
  margin-right: 6px;
  margin-bottom: 6px;
}

.admin-pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  padding: 16px;
}

.admin-pagination button {
  min-width: 42px;
}

.admin-modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.55);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1050;
  padding: 24px;
}

.admin-modal {
  background: #fff;
  border-radius: 18px;
  width: min(960px, 100%);
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 25px 50px -12px rgba(15, 23, 42, 0.35);
}

.admin-modal-header {
  padding: 20px 28px 12px;
  border-bottom: 1px solid #e5e7eb;
}

.admin-modal-body {
  padding: 24px 28px;
}

.admin-modal-footer {
  padding: 16px 28px 24px;
  border-top: 1px solid #e5e7eb;
  display: flex;
  justify-content: flex-end;
  gap: 12px;
}

.admin-modal-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.admin-modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  padding-top: 16px;
  margin-top: 8px;
  border-top: 1px solid #e5e7eb;
}

.admin-form-section {
  background: #f9fafc;
  border: 1px solid #e5e7eb;
  border-radius: 16px;
  padding: 20px 22px;
}

.admin-form-section + .admin-form-section {
  margin-top: 4px;
}

.admin-form-section-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 16px;
}

.admin-form-section-title {
  font-size: 0.95rem;
  font-weight: 600;
  margin-bottom: 4px;
  color: #1e3a8a;
}

.admin-form-section-text {
  margin: 0;
  font-size: 0.82rem;
  color: #6b7280;
}

.admin-service-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
}

.admin-service-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border: 1px solid #dbeafe;
  border-radius: 12px;
  background: #eef2ff;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  cursor: pointer;
}

.admin-service-option:hover {
  border-color: #93c5fd;
  box-shadow: 0 6px 16px rgba(30, 64, 175, 0.12);
}

.admin-service-option.is-selected {
  border-color: #2563eb;
  background: #dbeafe;
  box-shadow: 0 8px 20px rgba(37, 99, 235, 0.18);
}

.admin-service-option .form-check-input {
  margin: 0;
  position: relative;
  top: 0;
}

.admin-service-option .form-check-label {
  font-size: 0.9rem;
  font-weight: 500;
  color: #1f2937;
  cursor: pointer;
  flex: 1;
}

.admin-tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.admin-tag {
  background: #eef2ff;
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 0.75rem;
  color: #1e3a8a;
}

.admin-device-card,
.admin-service-card {
  border: 1px solid #e5e7eb;
  border-radius: 14px;
  padding: 14px;
  margin-bottom: 12px;
  background: #f9fafc;
}

.admin-service-card.selected {
  background: #e0f2fe;
  border-color: #38bdf8;
}

.admin-empty-state {
  text-align: center;
  padding: 34px 16px;
  color: #6b7280;
}

.admin-footer {
  background: transparent;
}

.admin-loading .spinner-border {
  width: 2.75rem;
  height: 2.75rem;
}

@media (max-width: 768px) {
  .admin-auth-card {
    padding: 24px;
  }
  .admin-metric-card .metric-value {
    font-size: 1.7rem;
  }
  .admin-modal {
    width: 100%;
  }
}
