/*
 * GuardNet AI — application styles
 */

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  color: #1a1a2e;
  background-color: #f8f9fb;
}

/* Navbar */
.gn-navbar {
  background: #fff;
  border-bottom: 1px solid #eaedf0;
}

.gn-navbar .navbar-brand {
  font-weight: 700;
  font-size: 1.1rem;
  color: #1a1a2e;
}

.gn-navbar .nav-link {
  color: #555;
  font-size: 0.95rem;
  padding: 0.5rem 1rem;
  border-radius: 6px;
}

.gn-navbar .nav-link:hover,
.gn-navbar .nav-link.active {
  color: #1a1a2e;
  background: #f0f2f5;
}

.gn-navbar .nav-link.active {
  font-weight: 600;
}

/* Cards */
.gn-card {
  background: #fff;
  border: 1px solid #eaedf0;
  border-radius: 12px;
  box-shadow: none;
}

/* Status banner */
.gn-status-safe {
  background: #f0faf4;
  border: 1px solid #c3e6cb;
  border-radius: 12px;
  color: #1a5c36;
}

.gn-status-warning {
  background: #fffbf0;
  border: 1px solid #fce5a0;
  border-radius: 12px;
  color: #7a5500;
}

.gn-status-danger {
  background: #fff5f5;
  border: 1px solid #f5c6cb;
  border-radius: 12px;
  color: #7a1f1f;
}

/* Risk / severity pills */
.gn-pill {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.01em;
}

.gn-pill-danger  { background: #fff0f0; color: #c0392b; }
.gn-pill-warning { background: #fffbeb; color: #b7770d; }
.gn-pill-info    { background: #eef4ff; color: #2563eb; }
.gn-pill-success { background: #f0faf4; color: #1a6b3c; }

/* Device cards */
.gn-device-card {
  border-radius: 12px;
  border: 1px solid #eaedf0;
  background: #fff;
  transition: box-shadow 0.15s, border-color 0.15s;
  cursor: pointer;
  text-decoration: none;
  color: inherit;
  display: block;
}

.gn-device-card:hover {
  box-shadow: 0 4px 16px rgba(0,0,0,0.08);
  border-color: #c8cdd4;
  color: inherit;
}

.gn-device-card.risk-critical { border-left: 4px solid #e74c3c; }
.gn-device-card.risk-high     { border-left: 4px solid #f0ad4e; }
.gn-device-card.risk-medium   { border-left: 4px solid #5bc0de; }
.gn-device-card.risk-low      { border-left: 4px solid #5cb85c; }

/* Alert rows */
.gn-alert-row {
  border-bottom: 1px solid #f0f2f5;
  transition: background 0.1s;
}

.gn-alert-row:last-child { border-bottom: none; }
.gn-alert-row:hover { background: #fafbfc; }

.gn-alert-row.severity-critical { border-left: 4px solid #e74c3c; }
.gn-alert-row.severity-warning  { border-left: 4px solid #f0ad4e; }
.gn-alert-row.severity-info     { border-left: 4px solid #5bc0de; }

/* Status dot */
.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  display: inline-block;
  margin-right: 5px;
}

.status-dot.online  { background: #27ae60; }
.status-dot.offline { background: #bdc3c7; }

/* AI explanation block */
.gn-explanation {
  background: #f8f9ff;
  border-left: 3px solid #4a6cf7;
  border-radius: 0 8px 8px 0;
  padding: 14px 16px;
}

/* Action block */
.gn-action {
  background: #fffdf0;
  border-left: 3px solid #f0ad4e;
  border-radius: 0 8px 8px 0;
  padding: 14px 16px;
}

/* Section heading */
.gn-section-label {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #8a94a6;
  margin-bottom: 12px;
}

/* Misc */
.page-title { font-size: 1.4rem; font-weight: 700; }
.text-soft   { color: #8a94a6; }
