/* Page Headers */
.page-header { margin-bottom: 1.5rem; }

.page-title {
  color: #1a202c;
  font-size: 1.75rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  letter-spacing: -0.02em;
}

.page-icon {
  width: 32px;
  height: 32px;
  color: var(--ps-blue);
  filter: drop-shadow(0 2px 4px rgba(0, 100, 162, 0.2));
}

.search-input { width: 250px; }

/* Badges */
.badge-count {
  background: var(--ps-blue);
  color: white;
  padding: 0.375rem 0.75rem;
  border-radius: 20px;
  font-size: 0.875rem;
  font-weight: 600;
  box-shadow: 0 2px 8px rgba(0, 100, 162, 0.2);
}

.badge-success {
  background: rgba(42, 157, 143, 0.15);
  color: var(--ps-green);
  border: 1px solid rgba(42, 157, 143, 0.3);
  padding: 0.375rem 0.75rem;
  border-radius: 20px;
  font-size: 0.875rem;
  font-weight: 600;
  box-shadow: 0 0 10px rgba(42, 157, 143, 0.1);
}

.badge-secondary {
  background: rgba(108, 117, 125, 0.15);
  color: #6c757d;
  border: 1px solid rgba(108, 117, 125, 0.3);
  padding: 0.375rem 0.75rem;
  border-radius: 20px;
  font-size: 0.875rem;
  font-weight: 600;
}

/* Cards */
.card-modern {
  background: white;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
  transition: all 0.3s ease;
}

.card-modern:hover {
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08), 0 0 20px rgba(0, 100, 162, 0.05);
}

.card-header {
  padding: 1rem;
  background: linear-gradient(180deg, #f8fafc 0%, #f1f5f9 100%);
  border-bottom: 1px solid #e2e8f0;
  position: relative;
}

.card-header::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent 0%, rgba(0, 100, 162, 0.1) 50%, transparent 100%);
}

.card-body { padding: 1.5rem; }

/* Tables */
.table-modern { margin: 0; }

.table-modern thead {
  background: linear-gradient(180deg, #f8fafc 0%, #f1f5f9 100%);
  border-bottom: 2px solid #e2e8f0;
  position: relative;
}

.table-modern thead::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent 0%, rgba(0, 100, 162, 0.2) 50%, transparent 100%);
}

.table-modern thead th {
  color: #64748b;
  font-weight: 600;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 1rem;
  border: none;
}

.table-modern tbody tr {
  border-bottom: 1px solid #f1f5f9;
  transition: all 0.15s ease;
}

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

.table-modern tbody tr:hover {
  background: linear-gradient(90deg, rgba(0, 100, 162, 0.02) 0%, rgba(0, 100, 162, 0.04) 50%, rgba(0, 100, 162, 0.02) 100%);
}

.table-modern tbody td {
  padding: 1rem;
  vertical-align: middle;
  border: none;
}

/* Device Lists */
.device-name {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-weight: 600;
  color: #1e293b;
}

.device-icon {
  width: 20px;
  height: 20px;
  color: var(--ps-blue);
  flex-shrink: 0;
  filter: drop-shadow(0 1px 2px rgba(0, 100, 162, 0.2));
}

/* Status Badges */
.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.375rem 0.75rem;
  border-radius: 20px;
  font-size: 0.8125rem;
  font-weight: 600;
  border: 1px solid;
}

.status-online {
  background: rgba(42, 157, 143, 0.1);
  color: var(--ps-green);
  border-color: rgba(42, 157, 143, 0.3);
}

.status-offline {
  background: rgba(148, 163, 184, 0.1);
  color: #64748b;
  border-color: rgba(148, 163, 184, 0.3);
}

.status-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
}

.status-online .status-dot { animation: pulse 2s ease-in-out infinite; }

/* Buttons */
.btn-primary {
  background: linear-gradient(135deg, var(--ps-blue), var(--ps-blue-dark));
  border-color: var(--ps-blue);
  font-weight: 600;
  position: relative;
  overflow: hidden;
}

.btn-primary::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  transition: all 0.5s ease;
}

.btn-primary:hover::before { width: 300px; height: 300px; }

.btn-primary:hover {
  background: linear-gradient(135deg, var(--ps-blue-dark), var(--ps-blue));
  border-color: var(--ps-blue-dark);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 100, 162, 0.3), 0 0 20px rgba(117, 255, 219, 0.2);
}

/* Button Loading States */
.btn-loading {
  position: relative;
  color: transparent !important;
  pointer-events: none;
}

.btn-loading::after {
  content: '';
  position: absolute;
  width: 16px;
  height: 16px;
  top: 50%;
  left: 50%;
  margin-left: -8px;
  margin-top: -8px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top-color: white;
  border-radius: 50%;
  animation: btnSpinner 0.6s linear infinite;
}

.btn-loading.btn-outline-secondary::after,
.btn-loading.btn-secondary::after {
  border-color: rgba(100, 116, 139, 0.3);
  border-top-color: #64748b;
}

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

.btn:disabled, .btn.disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.btn-action {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.5rem 0.875rem;
  font-size: 0.8125rem;
  font-weight: 600;
  border-radius: 8px;
  border: 1.5px solid;
  transition: all 0.3s ease;
  text-decoration: none;
  position: relative;
  overflow: hidden;
}

.btn-action::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  background: rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  transition: all 0.4s ease;
}

.btn-action:hover::before { width: 200px; height: 200px; }

.btn-ssh { background: transparent; color: var(--ps-blue); border-color: var(--ps-blue); }
.btn-ssh:hover:not(.disabled) {
  background: var(--ps-blue); color: white; transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 100, 162, 0.2), 0 0 20px rgba(0, 100, 162, 0.1);
}

.btn-vnc { background: transparent; color: var(--ps-green); border-color: var(--ps-green); }
.btn-vnc:hover:not(.disabled) {
  background: var(--ps-green); color: white; transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(42, 157, 143, 0.2), 0 0 20px rgba(42, 157, 143, 0.1);
}

.btn-action.disabled { opacity: 0.4; pointer-events: none; }
.btn-icon-only { padding: 0.375rem; display: inline-flex; align-items: center; justify-content: center; }

.btn-logout {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.2) 0%, rgba(255, 255, 255, 0.1) 100%);
  color: white;
  border: 2px solid rgba(255, 255, 255, 0.4);
  padding: 0.75rem 1.5rem;
  font-weight: 600;
  font-size: 0.875rem;
  border-radius: 10px;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2), inset 0 1px 2px rgba(255, 255, 255, 0.2);
  margin-left: 0.5rem;
}

.btn-logout::before {
  content: ''; position: absolute; top: 50%; left: 50%; width: 0; height: 0;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.3) 0%, transparent 70%);
  border-radius: 50%; transform: translate(-50%, -50%); transition: all 0.5s ease;
}

.btn-logout:hover::before { width: 300px; height: 300px; }

.btn-logout:hover {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.3) 0%, rgba(255, 255, 255, 0.2) 100%);
  color: white; border-color: var(--ps-teal);
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 6px 20px rgba(117, 255, 219, 0.4), 0 0 30px rgba(117, 255, 219, 0.2), inset 0 1px 2px rgba(255, 255, 255, 0.3);
}

.btn-logout .btn-icon {
  width: 18px; height: 18px; position: relative; z-index: 1; transition: all 0.3s ease;
}

.btn-logout:hover .btn-icon {
  transform: translateX(3px); filter: drop-shadow(0 0 6px rgba(255, 255, 255, 0.8));
}

.btn-terminal { background: transparent; color: #6366f1; border-color: #6366f1; }
.btn-terminal:hover:not(.disabled) {
  background: #6366f1; color: white; transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(99, 102, 241, 0.2), 0 0 20px rgba(99, 102, 241, 0.1);
}

.btn-edit { background: transparent; color: var(--ps-blue); border-color: var(--ps-blue); position: relative; overflow: hidden; }
.btn-edit::before {
  content: ''; position: absolute; top: 50%; left: 50%; width: 0; height: 0;
  background: rgba(0, 100, 162, 0.1); border-radius: 50%;
  transform: translate(-50%, -50%); transition: all 0.4s ease;
}
.btn-edit:hover:not(.disabled)::before { width: 200px; height: 200px; }
.btn-edit:hover:not(.disabled) {
  background: var(--ps-blue); color: white; box-shadow: 0 0 15px rgba(0, 100, 162, 0.3);
}

.btn-delete { background: transparent; color: #dc3545; border-color: #dc3545; position: relative; overflow: hidden; }
.btn-delete::before {
  content: ''; position: absolute; top: 50%; left: 50%; width: 0; height: 0;
  background: rgba(220, 53, 69, 0.1); border-radius: 50%;
  transform: translate(-50%, -50%); transition: all 0.4s ease;
}
.btn-delete:hover:not(.disabled)::before { width: 200px; height: 200px; }
.btn-delete:hover:not(.disabled) {
  background: #dc3545; color: white; box-shadow: 0 0 15px rgba(220, 53, 69, 0.3);
}

/* Dropdowns - Base z-index for Bootstrap dropdowns */
.dropdown-menu {
  z-index: 1050 !important;
}

/* Tabs */
.nav-tabs { border-bottom: 2px solid #e2e8f0; margin-bottom: 0; }
.nav-tabs .nav-item { margin-bottom: -2px; }
.nav-tabs .nav-link {
  color: #64748b !important; background: transparent; border: none;
  border-bottom: 3px solid transparent; padding: 1rem 1.5rem !important;
  font-weight: 600; transition: all 0.3s ease; position: relative;
  margin: 0 !important; border-radius: 0;
}
.nav-tabs .nav-link:hover {
  color: var(--ps-blue) !important; background: rgba(0, 100, 162, 0.05);
  border-bottom-color: rgba(0, 100, 162, 0.3); transform: none; box-shadow: none;
}
.nav-tabs .nav-link:hover::before, .nav-tabs .nav-link:hover::after { display: none; }
.nav-tabs .nav-link.active {
  color: var(--ps-blue) !important; background: white;
  border-bottom-color: var(--ps-blue); box-shadow: none;
}
.nav-tabs .nav-link.active::before, .nav-tabs .nav-link.active::after { display: none; }
.nav-tabs .nav-link .badge { margin-left: 0.5rem; font-size: 0.75rem; padding: 0.25rem 0.5rem; }
.tab-content {
  background: white; border: 1px solid #e2e8f0; border-top: none;
  border-radius: 0 0 12px 12px; padding: 1.5rem;
}
.tab-pane { animation: fadeIn 0.3s ease-in; }
.nav-tabs .nav-link::before { content: none !important; }
.col-lg-4 .nav-tabs { border-radius: 12px 12px 0 0; background: #f8f9fa; padding: 0.5rem 0.5rem 0; }
.col-lg-4 .nav-tabs .nav-link { padding: 0.75rem 1rem !important; font-size: 0.875rem; }
.col-lg-4 .tab-content { border-radius: 0 0 12px 12px; padding: 0; }
.col-lg-4 .tab-content .card { border-radius: 0 0 12px 12px; border-top: none; }

/* Alerts / Flash Messages */
.alert {
  border-radius: var(--radius-lg);
  border: none;
  box-shadow: var(--shadow-md);
  padding: 1rem 1.25rem;
  animation: alertSlideIn 0.3s ease-out;
  position: relative;
  overflow: hidden;
}

@keyframes alertSlideIn {
  from { opacity: 0; transform: translateY(-10px); }
  to { opacity: 1; transform: translateY(0); }
}

.alert::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
}

.alert-success {
  background: linear-gradient(135deg, rgba(42, 157, 143, 0.1) 0%, rgba(42, 157, 143, 0.05) 100%);
  color: #166856;
}
.alert-success::before { background: var(--color-success); }

.alert-danger {
  background: linear-gradient(135deg, rgba(220, 53, 69, 0.1) 0%, rgba(220, 53, 69, 0.05) 100%);
  color: #9b2c34;
}
.alert-danger::before { background: var(--color-danger); }

.alert-warning {
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.1) 0%, rgba(245, 158, 11, 0.05) 100%);
  color: #92610a;
}
.alert-warning::before { background: var(--color-warning); }

.alert-info {
  background: linear-gradient(135deg, rgba(59, 150, 210, 0.1) 0%, rgba(59, 150, 210, 0.05) 100%);
  color: #1a5f8a;
}
.alert-info::before { background: var(--color-info); }

.alert-icon { width: 20px; height: 20px; flex-shrink: 0; }
.alert .btn-close { opacity: 0.5; transition: opacity var(--transition-fast); }
.alert .btn-close:hover { opacity: 1; }

/* User Info & Stats */
.user-info-cell { display: flex; align-items: center; gap: 0.75rem; }
.user-avatar {
  width: 40px; height: 40px; border-radius: 8px;
  background: linear-gradient(135deg, var(--ps-blue), var(--ps-blue-dark));
  color: white; display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 1rem; flex-shrink: 0;
  box-shadow: 0 2px 8px rgba(0, 100, 162, 0.3); position: relative;
}
.user-avatar::after {
  content: ''; position: absolute; inset: -2px; border-radius: 8px;
  background: linear-gradient(135deg, var(--ps-teal), var(--ps-blue));
  z-index: -1; opacity: 0; transition: opacity 0.3s ease;
}
.user-avatar:hover::after { opacity: 0.3; }
.user-avatar-sm {
  width: 28px; height: 28px; border-radius: 6px;
  background: linear-gradient(135deg, var(--ps-blue), var(--ps-blue-dark));
  color: white; display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 0.75rem; flex-shrink: 0;
  box-shadow: 0 2px 4px rgba(0, 100, 162, 0.2);
}
.user-name-cell { font-weight: 600; color: #1e293b; }
.role-badge {
  display: inline-flex; align-items: center; gap: 0.375rem;
  padding: 0.375rem 0.75rem; border-radius: 20px; font-size: 0.8125rem;
  font-weight: 600; border: 1px solid; box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
  transition: all 0.2s ease;
}
.role-badge:hover { transform: translateY(-1px); box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1); }
.role-admin { background: rgba(0, 100, 162, 0.1); color: var(--ps-blue); border-color: rgba(0, 100, 162, 0.3); }
.role-user { background: rgba(148, 163, 184, 0.1); color: #64748b; border-color: rgba(148, 163, 184, 0.3); }

.stat-card {
  background: white; border: 1px solid #e2e8f0; border-radius: 12px;
  padding: 1.5rem; display: flex; flex-direction: column; gap: 0.75rem;
  transition: all 0.3s ease; position: relative; overflow: hidden;
}
.stat-card::before {
  content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 2px;
  background: linear-gradient(90deg, transparent 0%, var(--ps-blue) 50%, transparent 100%);
  opacity: 0; transition: opacity 0.3s ease;
}
.stat-card:hover::before { opacity: 1; }
.stat-card:hover {
  transform: translateY(-4px); box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12), 0 0 30px rgba(0, 100, 162, 0.1);
  border-color: rgba(0, 100, 162, 0.2);
}
.stat-icon {
  width: 48px; height: 48px; border-radius: 12px; display: flex;
  align-items: center; justify-content: center; transition: all 0.3s ease;
}
.stat-card:hover .stat-icon { transform: scale(1.1); }
.stat-icon svg { width: 24px; height: 24px; }
.stat-primary .stat-icon { background: rgba(0, 100, 162, 0.1); color: var(--ps-blue); box-shadow: 0 0 20px rgba(0, 100, 162, 0.1); }
.stat-success .stat-icon { background: rgba(42, 157, 143, 0.1); color: var(--ps-green); box-shadow: 0 0 20px rgba(42, 157, 143, 0.1); }
.stat-info .stat-icon { background: rgba(59, 150, 210, 0.1); color: #3B96D2; box-shadow: 0 0 20px rgba(59, 150, 210, 0.1); }
.stat-secondary .stat-icon { background: rgba(148, 163, 184, 0.1); color: #64748b; }
.stat-value { font-size: 2rem; font-weight: 700; color: #1e293b; line-height: 1; }
.stat-label { font-size: 0.875rem; color: #64748b; font-weight: 500; }
@media (max-width: 576px) { .stat-card { padding: 1rem; } .stat-value { font-size: 1.5rem; } }

/* Activity Badges */
.activity-badge {
  display: inline-flex; align-items: center; gap: 0.375rem; padding: 0.375rem 0.75rem;
  border-radius: 20px; font-size: 0.8125rem; font-weight: 600; border: 1px solid;
  transition: all 0.2s ease;
}
.activity-badge:hover { transform: translateX(2px); }
.activity-login { background: rgba(42, 157, 143, 0.1); color: var(--ps-green); border-color: rgba(42, 157, 143, 0.3); }
.activity-logout { background: rgba(148, 163, 184, 0.1); color: #64748b; border-color: rgba(148, 163, 184, 0.3); }
.activity-ssh { background: rgba(0, 100, 162, 0.1); color: var(--ps-blue); border-color: rgba(0, 100, 162, 0.3); }
.activity-vnc { background: rgba(59, 150, 210, 0.1); color: #3B96D2; border-color: rgba(59, 150, 210, 0.3); }
.activity-success { background: rgba(42, 157, 143, 0.1); color: var(--ps-green); border-color: rgba(42, 157, 143, 0.3); }
.activity-warning { background: rgba(249, 199, 79, 0.1); color: #f59e0b; border-color: rgba(249, 199, 79, 0.3); }
.activity-danger { background: rgba(220, 53, 69, 0.1); color: #dc3545; border-color: rgba(220, 53, 69, 0.3); }
.activity-default { background: rgba(148, 163, 184, 0.1); color: #64748b; border-color: rgba(148, 163, 184, 0.3); }

/* Compact Table Styling */
.table-compact {
    font-size: 0.875rem;
}

.table-compact th {
    background: rgba(0, 100, 162, 0.05);
    padding: 0.75rem 0.5rem;
    font-weight: 600;
    color: #666;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 2px solid rgba(0, 100, 162, 0.2);
    white-space: nowrap;
}

.table-compact td {
    padding: 0.6rem 0.5rem;
    vertical-align: middle;
}

.table-compact tbody tr {
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    transition: all 0.2s ease;
}

.table-compact tbody tr:hover {
    background: rgba(0, 100, 162, 0.03);
}

.fw-600 {
    font-weight: 600;
}

.text-sm {
    font-size: 0.85rem;
}

.code-sm {
    background: rgba(0, 100, 162, 0.1);
    color: #0064A2;
    padding: 0.2rem 0.4rem;
    border-radius: 3px;
    font-size: 0.8rem;
    font-family: 'Courier New', monospace;
}

.badge-mini {
    display: inline-block;
    padding: 0.2rem 0.5rem;
    border-radius: 3px;
    font-size: 0.75rem;
    font-weight: 600;
    color: white;
}

.badge-mini.bg-info {
    background: #0064A2;
}

.status-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    margin-right: 0.4rem;
}

.status-dot.online {
    background: #2A9D8F;
    box-shadow: 0 0 8px rgba(42, 157, 143, 0.6);
}

.status-dot.offline {
    background: #999;
}

.cpu-temp {
    padding: 0.2rem 0.4rem;
    border-radius: 3px;
    font-weight: 500;
}

.cpu-temp.temp-cool {
    color: #333333;
    background: transparent;
}

.cpu-temp.temp-warm {
    color: #f59e0b;
    background: rgba(245, 158, 11, 0.1);
}

.cpu-temp.temp-hot {
    color: #dc3545;
    background: rgba(220, 53, 69, 0.1);
}


.progress-bar-tiny {
    height: 4px;
    background: rgba(0, 0, 0, 0.1);
    border-radius: 2px;
    overflow: hidden;
    margin-bottom: 0.2rem;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #2A9D8F, #75FFDB);
    border-radius: 2px;
    transition: width 0.3s ease;
}

.action-buttons {
    display: flex;
    gap: 0.3rem;
    justify-content: flex-end;
}

.btn-xs {
    padding: 0.3rem 0.6rem;
    font-size: 0.7rem;
    border-radius: 3px;
    text-decoration: none;
    border: 1px solid;
    display: inline-flex;
    align-items: center;
    font-weight: 500;
    transition: all 0.2s ease;
}

.btn-vnc {
    background: #0064A2;
    color: white;
    border-color: #0064A2;
}

.btn-vnc:hover:not(.disabled) {
    background: #005289;
    box-shadow: 0 2px 6px rgba(0, 100, 162, 0.3);
}

.btn-terminal {
    background: #2A9D8F;
    color: white;
    border-color: #2A9D8F;
}

.btn-terminal:hover:not(.disabled) {
    background: #1f7a6f;
    box-shadow: 0 2px 6px rgba(42, 157, 143, 0.3);
}

.btn-xs.disabled {
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
}

/* Section Header Styling */
.section-header {
    background: linear-gradient(90deg, rgba(0, 100, 162, 0.15), rgba(0, 100, 162, 0.05));
    border-top: 3px solid #0064A2;
    border-bottom: 2px solid rgba(0, 100, 162, 0.2);
}

.section-header td {
    padding: 1rem 0.5rem;
    vertical-align: middle;
}

.section-title {
    color: #0064A2;
    font-size: 0.95rem;
    letter-spacing: 1px;
    margin-right: 0.5rem;
}

.section-count {
    color: #666;
    font-size: 0.8rem;
    font-weight: 400;
}

.table-compact tbody tr:has(+ .section-header) {
    border-bottom: none;
}

.status-dot.warning {
    background: #FFC107;
    box-shadow: 0 0 8px rgba(255, 193, 7, 0.8);
    margin-left: 0.2rem;
}

.status-dot.warning:hover {
    cursor: help;
}

.status-dot {
    display: inline-block;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    margin-right: 0.4rem;
}

.status-dot.error {
    background-color: #dc3545; /* Red */
    box-shadow: 0 0 8px rgba(220, 53, 69, 0.5);
}

.status-dot.warning {
    background-color: #ffc107; /* Amber/Yellow */
    box-shadow: 0 0 8px rgba(255, 193, 7, 0.5);
}

.status-dot.online {
    background-color: #28a745; /* Green */
    box-shadow: 0 0 8px rgba(40, 167, 69, 0.5);
}

.status-dot.offline {
    background-color: #6c757d; /* Gray */
    box-shadow: 0 0 8px rgba(108, 117, 125, 0.5);
}

.status-dot.warning:hover {
    cursor: help;
    box-shadow: 0 0 15px rgba(255, 193, 7, 1);
}

@keyframes pulse-warning {
    0%, 100% {
        opacity: 1;
        box-shadow: 0 0 10px rgba(255, 193, 7, 0.9);
    }
    50% {
        opacity: 0.7;
        box-shadow: 0 0 15px rgba(255, 193, 7, 1);
    }
}

.btn-ghost {
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: inherit;
    transition: transform 0.2s ease;
}

.btn-ghost:hover {
    opacity: 0.7;
}

.expand-collapse .expand-icon {
    transition: transform 0.2s ease;
    transform: rotate(0deg);
}

.expand-collapse.expanded .expand-icon {
    transform: rotate(90deg);
}

.section-header {
    background-color: #f8f9fa;
    cursor: pointer;
}

.section-header:hover {
    background-color: #e9ecef;
}

.section-summary {
    display: flex;
    gap: 2rem;
    align-items: center;
    font-size: 0.85rem;
}


    .section-header {
        background-color: #f8f9fa;
        cursor: pointer;
        user-select: none;
    }

    .section-header:hover {
        background-color: #e9ecef;
    }

    .section-header-content {
        padding: 1rem 0.5rem !important;
    }

    .section-header:focus-visible {
        outline: 2px solid var(--ps-blue);
        outline-offset: -2px;
    }


    /* ========================================
   ASSET MODAL STYLES
   ======================================== */

/* Modal Container */
.modal-asset {
    border: none;
    border-radius: 14px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
    overflow: hidden;
    background: white;
}

.modal-asset .modal-content {
    background: white;
}

/* Modal Header */
.modal-asset-header {
    background: linear-gradient(135deg, rgba(0, 100, 162, 0.05) 0%, rgba(0, 118, 191, 0.05) 100%);
    border-bottom: 1px solid rgba(0, 100, 162, 0.1);
    padding: 1.75rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.modal-header-content {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    flex: 1;
}

.modal-header-icon {
    color: var(--ps-blue);
    flex-shrink: 0;
    margin-top: 0.25rem;
}

.modal-title {
    margin: 0;
    font-size: 1.25rem;
    font-weight: 700;
    color: #1e293b;
}

.modal-subtitle {
    margin: 0.5rem 0 0;
    font-size: 0.875rem;
    color: #64748b;
}

.btn-close-custom {
    padding: 0.5rem;
    color: #64748b;
    opacity: 1;
    transition: all 0.2s;
    border: none;
    background: transparent;
    cursor: pointer;
}

.btn-close-custom:hover,
.btn-close-custom:focus {
    color: var(--ps-blue);
    opacity: 1;
    background: rgba(0, 100, 162, 0.1);
    border-radius: 6px;
}

/* Modal Body */
.modal-asset-body {
    padding: 2rem;
    max-height: calc(100vh - 300px);
    overflow-y: auto;
}

.modal-asset-body::-webkit-scrollbar {
    width: 6px;
}

.modal-asset-body::-webkit-scrollbar-track {
    background: transparent;
}

.modal-asset-body::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 3px;
}

.modal-asset-body::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

/* Form Sections */
.form-section {
    margin-bottom: 2rem;
}

.form-section:last-child {
    margin-bottom: 0;
}

.form-section-title {
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--ps-blue);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 1.25rem;
    padding-bottom: 0.75rem;
    border-bottom: 2px solid rgba(0, 100, 162, 0.15);
}

/* ===========================================
   STANDARDIZED FORM CONTROLS
   Use these classes consistently across all pages
   =========================================== */

/* Base form control - modern styling */
.form-control-modern,
.form-select.form-control-modern,
.form-control,
.form-select {
    border: 1.5px solid #e2e8f0;
    border-radius: 8px;
    padding: 0.75rem 1rem;
    font-size: 0.875rem;
    color: #1e293b;
    background: white;
    transition: all 0.2s ease;
    font-family: inherit;
    width: 100%;
}

.form-control-modern::placeholder,
.form-control::placeholder {
    color: #94a3b8;
}

.form-control-modern:focus,
.form-select.form-control-modern:focus,
.form-control:focus,
.form-select:focus {
    border-color: var(--ps-blue);
    box-shadow: 0 0 0 3px rgba(0, 100, 162, 0.1);
    outline: none;
}

.form-control-modern:hover:not(:focus),
.form-select.form-control-modern:hover:not(:focus),
.form-control:hover:not(:focus),
.form-select:hover:not(:focus) {
    border-color: #cbd5e1;
}

/* Size variants */
.form-control-lg,
.form-select-lg,
.form-control-modern-lg {
    padding: 0.875rem 1.25rem;
    font-size: 1rem;
    border-radius: 10px;
}

.form-control-sm,
.form-select-sm,
.form-control-modern-sm {
    padding: 0.5rem 0.75rem;
    font-size: 0.8125rem;
    border-radius: 6px;
}

/* Disabled state */
.form-control:disabled,
.form-select:disabled,
.form-control-modern:disabled {
    background: #f8fafc;
    color: #94a3b8;
    cursor: not-allowed;
}

/* Invalid state */
.form-control.is-invalid,
.form-select.is-invalid,
.form-control-modern.is-invalid {
    border-color: #ef4444;
}

.form-control.is-invalid:focus,
.form-select.is-invalid:focus {
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1);
}

/* Form help text */
.form-text {
    font-size: 0.8125rem;
    color: #64748b;
    margin-top: 0.375rem;
}

/* Form Labels */
.form-label {
    font-size: 0.875rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 0.5rem;
    display: block;
}

.required {
    color: #ef4444;
    margin-left: 0.25rem;
}

/* Textarea */
textarea.form-control-modern {
    resize: vertical;
    min-height: 80px;
    font-family: inherit;
}

textarea.form-control-modern:focus {
    resize: vertical;
}

/* Modal Footer */
.modal-asset-footer {
    background: rgba(0, 100, 162, 0.03);
    border-top: 1px solid rgba(0, 100, 162, 0.1);
    padding: 1.5rem 1.75rem;
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
}

/* Button Styles */
.btn-modern {
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    font-size: 0.875rem;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

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

.btn-primary.btn-modern {
    background: linear-gradient(135deg, var(--ps-blue) 0%, var(--ps-blue-light) 100%);
    color: white;
    box-shadow: 0 4px 12px rgba(0, 100, 162, 0.3);
}

.btn-primary.btn-modern:hover {
    box-shadow: 0 8px 20px rgba(0, 100, 162, 0.4);
    background: linear-gradient(135deg, var(--ps-blue-dark) 0%, var(--ps-blue) 100%);
}

.btn-primary.btn-modern:active {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(0, 100, 162, 0.3);
}

.btn-secondary.btn-modern {
    background: #f1f5f9;
    color: #1e293b;
    border: 1px solid #e2e8f0;
}

.btn-secondary.btn-modern:hover {
    background: #e2e8f0;
    border-color: #cbd5e1;
}

.btn-secondary.btn-modern:active {
    transform: translateY(0);
    background: #cbd5e1;
}

/* Responsive Design */
@media (max-width: 576px) {
    .modal-asset-header {
        padding: 1.25rem;
    }

    .modal-header-content {
        flex-direction: column;
        gap: 0.75rem;
    }

    .modal-asset-body {
        padding: 1.5rem;
    }

    .form-section-title {
        margin-bottom: 1rem;
    }

    .modal-asset-footer {
        flex-direction: column-reverse;
        gap: 0.75rem;
    }

    .btn-modern {
        width: 100%;
        justify-content: center;
    }

    .row.g-3 > [class*="col-"] {
        margin-bottom: 0;
    }
}

/* ===========================================
   UTILITY CLASSES
   Use these instead of inline styles
   =========================================== */

/* Width utilities */
.w-auto { width: auto; }
.w-15 { width: 15%; }
.w-20 { width: 20%; }
.w-25 { width: 25%; }
.w-30 { width: 30%; }
.w-40 { width: 40%; }
.w-50 { width: 50%; }

/* Max-width utilities */
.mw-200 { max-width: 200px; }
.mw-250 { max-width: 250px; }
.mw-300 { max-width: 300px; }
.mw-400 { max-width: 400px; }
.mw-500 { max-width: 500px; }
.mw-600 { max-width: 600px; }

/* Max-height with scroll */
.scroll-300 { max-height: 300px; overflow-y: auto; }
.scroll-400 { max-height: 400px; overflow-y: auto; }
.scroll-420 { max-height: 420px; overflow-y: auto; }
.scroll-500 { max-height: 500px; overflow-y: auto; }

/* Display utilities */
.d-none { display: none; }
.d-block { display: block; }
.d-inline { display: inline; }
.d-inline-block { display: inline-block; }
.d-flex { display: flex; }
.d-grid { display: grid; }

/* Flex utilities */
.flex-center { display: flex; align-items: center; justify-content: center; }
.flex-between { display: flex; align-items: center; justify-content: space-between; }
.flex-align-center { display: flex; align-items: center; }

/* Section summary (used for collapsible sections) */
.section-summary-flex {
    gap: 2rem;
    align-items: center;
}
.gap-1 { gap: 0.25rem; }
.gap-2 { gap: 0.5rem; }
.gap-3 { gap: 1rem; }
.gap-4 { gap: 2rem; }

/* Grid utilities */
.grid-1 { grid-template-columns: 1fr; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }

/* Text utilities */
.text-muted-sm { color: #64748b; font-size: 0.85rem; }
.text-center { text-align: center; }
.text-right { text-align: right; }
.text-left { text-align: left; }
.font-sm { font-size: 0.8rem; }
.font-xs { font-size: 0.75rem; }

/* Cursor utilities */
.cursor-pointer { cursor: pointer; }
.cursor-help { cursor: help; }

/* Avatar utilities */
.avatar-lg {
    width: 80px;
    height: 80px;
    margin: 0 auto;
    font-size: 2rem;
}

/* Opacity */
.opacity-0 { opacity: 0; }
.opacity-50 { opacity: 0.5; }
.opacity-100 { opacity: 1; }

/* Background utilities */
.bg-highlight { background-color: rgba(0, 100, 162, 0.05); }
.bg-muted { background-color: #f8fafc; }

/* Table column width utilities */
.col-w-10 { width: 10%; }
.col-w-12 { width: 12%; }
.col-w-15 { width: 15%; }
.col-w-18 { width: 18%; }
.col-w-20 { width: 20%; }
.col-w-25 { width: 25%; }
.col-w-30 { width: 30%; }

/* Clickable row styling */
.row-clickable {
    cursor: pointer;
    transition: background-color 0.15s ease;
}

.row-clickable:hover {
    background-color: rgba(0, 100, 162, 0.04);
}

/* Row highlight for "latest" or "active" items */
.row-highlight {
    background-color: rgba(0, 100, 162, 0.05);
}

/* QR code container */
.qr-container {
    display: inline-block;
    padding: 1rem;
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
}

.qr-container img {
    max-width: 250px;
}

/* Secret code display */
.secret-code {
    font-size: 1.1em;
    letter-spacing: 0.1em;
    font-weight: 600;
}

/* Scrollbar styling for scroll utilities */
.scroll-300::-webkit-scrollbar,
.scroll-400::-webkit-scrollbar,
.scroll-420::-webkit-scrollbar,
.scroll-500::-webkit-scrollbar {
    width: 6px;
}

.scroll-300::-webkit-scrollbar-thumb,
.scroll-400::-webkit-scrollbar-thumb,
.scroll-420::-webkit-scrollbar-thumb,
.scroll-500::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 3px;
}

.scroll-300::-webkit-scrollbar-thumb:hover,
.scroll-400::-webkit-scrollbar-thumb:hover,
.scroll-420::-webkit-scrollbar-thumb:hover,
.scroll-500::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}