@import url('https://fonts.googleapis.com/css2?family=Share+Tech+Mono&family=Inter:wght@300;400;500;600&display=swap');

:root {
  /* Corporate SOC Blue Theme */
  --bg-dark: #0a0e1a;
  --bg-panel: rgba(12, 18, 34, 0.85);
  --primary-blue: #00d4ff;
  --primary-blue-dim: rgba(0, 212, 255, 0.15);
  --primary-blue-glow: rgba(0, 212, 255, 0.4);

  /* Severity Colors */
  --neon-green: #00e676;
  --neon-yellow: #ffc400;
  --neon-orange: #ff6e00;
  --neon-red: #ff3366;

  /* Typography */
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --glass-border: rgba(255, 255, 255, 0.08);
  --border-glow: rgba(0, 212, 255, 0.2);
}

body {
  background-color: var(--bg-dark);
  background-image: 
    radial-gradient(circle at top, rgba(0, 212, 255, 0.08) 0%, transparent 50%),
    linear-gradient(rgba(255, 255, 255, 0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
  background-size: 100% 100%, 50px 50px, 50px 50px;
  color: var(--text-main);
  font-family: 'Inter', sans-serif;
  margin: 0;
  overflow-x: hidden;
}

/* NAVBAR */
.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 40px;
  background: rgba(10, 14, 26, 0.95);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-glow);
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.6);
}

.navbar h1, .navbar h2 {
  font-family: 'Share Tech Mono', monospace;
  color: var(--primary-blue);
  margin: 0;
  text-shadow: 0 0 12px var(--primary-blue-glow);
  letter-spacing: 1px;
}

.navbar input {
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid var(--glass-border);
  color: #fff;
  padding: 10px 20px;
  border-radius: 6px;
  width: 320px;
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  transition: all 0.3s ease;
}

.navbar input:focus {
  border-color: var(--primary-blue);
  box-shadow: 0 0 15px var(--primary-blue-dim);
  outline: none;
}
.navbar input::placeholder {
  color: var(--text-muted);
}

.navbar a, .navbar button {
  font-family: 'Inter', sans-serif;
  color: var(--primary-blue);
  text-decoration: none;
  background: transparent;
  border: 1px solid var(--primary-blue);
  padding: 8px 18px;
  border-radius: 4px;
  margin-left: 12px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.navbar a:hover, .navbar button:hover {
  background: var(--primary-blue-dim);
  box-shadow: 0 0 15px var(--primary-blue-glow);
  color: #fff;
}

/* CONTAINERS */
.dashboard-container, .admin-container {
  padding: 40px;
  max-width: 1600px;
  margin: 0 auto;
}

/* GRIDS */
.recent-grid, .top-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
  margin-bottom: 40px;
}

/* Keep stat-card and add-threat styles separate */
.stat-card, .add-threat {
  background: var(--bg-panel);
  border: 1px solid var(--glass-border);
  padding: 24px;
  border-radius: 12px;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  position: relative;
}

/* CARDS AND PANELS */
section, .notifications, .dashboard-map {
  margin-bottom: 40px;
}

section h2, .notifications h3, .dashboard-map h3 {
  font-family: 'Inter', sans-serif;
  color: #fff;
  font-weight: 600;
  font-size: 20px;
  margin-bottom: 24px;
  text-transform: uppercase;
  letter-spacing: 2px;
  display: flex;
  align-items: center;
}

section h2::before, .notifications h3::before, .dashboard-map h3::before {
  content: '';
  display: inline-block;
  width: 4px;
  height: 20px;
  background-color: var(--primary-blue);
  margin-right: 12px;
  border-radius: 2px;
  box-shadow: 0 0 8px var(--primary-blue-glow);
}

/* Cards internal layout improvement */
.threat-card {
  background: var(--bg-panel);
  border: 1px solid rgba(0, 212, 255, 0.18);
  padding: 22px 24px;
  border-radius: 10px;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 140px;
  transition: transform 0.25s, box-shadow 0.25s, border-color 0.25s;
}

.threat-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 32px rgba(0, 212, 255, 0.12);
  border-color: rgba(0, 212, 255, 0.5);
}

.threat-card::before {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 3px;
  background: var(--primary-blue);
  opacity: 0;
  transition: opacity 0.25s;
}

.threat-card:hover::before {
  opacity: 1;
}

.threat-card h3, .threat-card h4 {
  font-family: 'Inter', sans-serif;
  color: #fff;
  font-weight: 600;
  font-size: 15px;
  margin: 0;
  line-height: 1.4;
}

.threat-card p {
  color: var(--text-muted);
  font-size: 13px;
  line-height: 1.6;
  margin: 0;
}

/* Severity badge — solid filled pill style */
.threat-card .severity {
  display: inline-block;
  padding: 4px 14px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  font-family: 'Inter', sans-serif;
  color: #fff;
  border: none;
}

.severity-LOW      { background-color: #16a34a; }
.severity-MEDIUM   { background-color: #d97706; }
.severity-HIGH     { background-color: #ea580c; }
.severity-CRITICAL { background-color: #dc2626; animation: pulse-critical 2s infinite; }

/* ANIMATIONS */
@keyframes pulse-critical {
  0% { box-shadow: 0 0 0 0 rgba(220, 38, 38, 0.5); }
  70% { box-shadow: 0 0 0 8px rgba(220, 38, 38, 0); }
  100% { box-shadow: 0 0 0 0 rgba(220, 38, 38, 0); }
}

@keyframes slideIn {
  from { opacity: 0; transform: translateY(15px); }
  to { opacity: 1; transform: translateY(0); }
}

.threat-card {
  animation: slideIn 0.4s ease backwards;
}

/* MAP */
#map {
  height: 600px;
  border-radius: 12px;
  border: 1px solid var(--glass-border);
  box-shadow: 0 0 40px rgba(0, 0, 0, 0.6);
  background-color: var(--bg-dark);
}

/* CUSTOM SCROLLBAR */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: var(--bg-dark); }
::-webkit-scrollbar-thumb { background: rgba(0, 212, 255, 0.3); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--primary-blue); }

/* GLOW EFFECT */
.glow {
  text-shadow: 0 0 5px var(--primary-blue), 0 0 15px var(--primary-blue-glow);
}

/* AUTHENTICATION PAGES */
.auth-wrapper {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 20px;
}

.auth-card {
  background: var(--bg-panel);
  border: 1px solid var(--glass-border);
  box-shadow: 0 15px 50px rgba(0, 0, 0, 0.5), inset 0 0 20px rgba(0, 212, 255, 0.05);
  border-radius: 16px;
  padding: 40px;
  width: 100%;
  max-width: 440px;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  text-align: center;
  position: relative;
  overflow: hidden;
  animation: slideIn 0.6s ease backwards;
}

.auth-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; height: 4px;
  background: var(--primary-blue);
  box-shadow: 0 0 20px var(--primary-blue);
}

.auth-header h2 {
  font-family: 'Inter', sans-serif;
  font-weight: 600;
  color: #fff;
  font-size: 28px;
  margin-top: 10px;
  margin-bottom: 30px;
  letter-spacing: 1px;
}

.auth-header h2 span {
  color: var(--primary-blue);
}

.auth-card input {
  box-sizing: border-box;
  width: 100%;
  margin-bottom: 20px;
  background: rgba(0, 0, 0, 0.5);
  border: 1px solid var(--glass-border);
  color: #fff;
  padding: 15px 18px;
  border-radius: 6px;
  font-family: 'Inter', sans-serif;
  font-size: 15px;
  transition: all 0.3s;
}

.auth-card input:focus {
  border-color: var(--primary-blue);
  box-shadow: 0 0 15px var(--primary-blue-dim);
  background: rgba(0, 212, 255, 0.05);
  outline: none;
}

.auth-card input::placeholder {
  color: #64748b;
}

.btn-glow {
  box-sizing: border-box;
  width: 100%;
  padding: 15px;
  margin-top: 10px;
  background: var(--primary-blue-dim);
  color: var(--primary-blue);
  border: 1px solid var(--primary-blue);
  font-size: 15px;
  font-weight: 600;
  font-family: 'Inter', sans-serif;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.3s ease;
  letter-spacing: 2px;
  text-transform: uppercase;
}

.btn-glow:hover {
  background: var(--primary-blue);
  box-shadow: 0 0 25px var(--primary-blue-glow);
  color: #000;
}

.auth-footer {
  margin-top: 25px;
  font-family: 'Inter', sans-serif;
  color: var(--text-muted);
  font-size: 14px;
}

.auth-footer a {
  color: var(--primary-blue);
  text-decoration: none;
  font-weight: 500;
  transition: all 0.3s;
}

.auth-footer a:hover {
  color: #fff;
  text-shadow: 0 0 8px var(--primary-blue-glow);
}

/* STATS ROW — single line, no wrapping */
.stats {
  display: flex;
  gap: 16px;
  padding: 20px 40px;
  flex-wrap: nowrap;
}

.stat-card {
  flex: 1;
  min-width: 0;       /* allow cards to shrink below their content width */
  text-align: center;
}

.stat-card h4 {
  font-family: 'Inter', sans-serif;
  color: var(--text-muted);
  font-size: 14px;
  margin-top: 0;
  margin-bottom: 15px;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.stat-card p {
  font-family: 'Share Tech Mono', monospace;
  color: #fff;
  font-size: 40px;
  margin: 0;
  text-shadow: 0 0 15px var(--primary-blue-glow);
}