* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: Arial, Helvetica, sans-serif;
  background: #0f172a;
  color: #e5e7eb;
}

.sidebar {
  position: fixed;
  left: 0;
  top: 0;
  width: 260px;
  height: 100vh;
  background: #020617;
  border-right: 1px solid #1e293b;
  display: flex;
  flex-direction: column;
}

.brand {
  padding: 24px 20px;
  border-bottom: 1px solid #1e293b;
}

.brand-title {
  font-size: 24px;
  font-weight: bold;
  letter-spacing: 1px;
}

.brand-subtitle {
  margin-top: 6px;
  font-size: 12px;
  color: #94a3b8;
}

nav {
  padding: 16px 12px;
  flex: 1;
}

.nav-link {
  display: block;
  padding: 12px 14px;
  margin-bottom: 6px;
  color: #cbd5e1;
  text-decoration: none;
  border-radius: 8px;
  font-size: 14px;
}

.nav-link:hover {
  background: #1e293b;
  color: #ffffff;
}

.nav-link.active {
  background: #2563eb;
  color: #ffffff;
}

.sidebar-footer {
  padding: 16px 20px;
  border-top: 1px solid #1e293b;
  font-size: 13px;
  color: #94a3b8;
}

.status-dot {
  display: inline-block;
  width: 9px;
  height: 9px;
  background: #22c55e;
  border-radius: 50%;
  margin-right: 8px;
}

.main {
  margin-left: 260px;
  min-height: 100vh;
}

.topbar {
  padding: 24px 32px;
  background: #111827;
  border-bottom: 1px solid #1f2937;
}

.topbar h1 {
  margin: 0;
  font-size: 26px;
}

.topbar p {
  margin: 6px 0 0 0;
  color: #94a3b8;
}

.content {
  padding: 32px;
}

.card {
  background: #111827;
  border: 1px solid #1f2937;
  border-radius: 12px;
  padding: 22px;
  margin-bottom: 20px;
}

.card h2 {
  margin-top: 0;
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 18px;
}

.badge-ok {
  color: #22c55e;
  font-weight: bold;
}

.badge-warning {
  color: #f59e0b;
  font-weight: bold;
}

.badge-critical {
  color: #ef4444;
  font-weight: bold;
}

iframe {
  width: 100%;
  height: calc(100vh - 170px);
  border: none;
  border-radius: 12px;
  background: #ffffff;
}


/* ==========================================================
   AS60427 NOC Portal - Nodes status page
   ========================================================== */

.hidden {
  display: none !important;
}

.noc-layout {
  min-height: 100vh;
  display: flex;
}

.noc-sidebar {
  width: 260px;
  min-width: 260px;
  background: rgba(13, 17, 23, 0.98);
  border-right: 1px solid rgba(255, 255, 255, 0.08);
  padding: 22px 16px;
}

.noc-brand {
  margin-bottom: 28px;
  padding: 0 8px;
}

.noc-brand-title {
  font-size: 22px;
  font-weight: 800;
}

.noc-brand-subtitle {
  color: #8b949e;
  font-size: 13px;
  margin-top: 4px;
}

.noc-nav {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.noc-nav a {
  color: #c9d1d9;
  text-decoration: none;
  padding: 10px 12px;
  border-radius: 10px;
  font-size: 14px;
}

.noc-nav a:hover,
.noc-nav a.active {
  background: rgba(88, 166, 255, 0.14);
  color: #79c0ff;
}

.noc-main {
  flex: 1;
  padding: 26px;
  overflow-x: auto;
}

.noc-page-header {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
  margin-bottom: 22px;
  flex-wrap: wrap;
}

.noc-page-header h1 {
  margin: 0;
  font-size: 28px;
}

.noc-page-header p {
  margin: 6px 0 0 0;
  color: #8b949e;
}

.noc-button {
  border: 1px solid rgba(88, 166, 255, 0.35);
  color: #79c0ff;
  background: rgba(88, 166, 255, 0.10);
  border-radius: 10px;
  padding: 9px 13px;
  cursor: pointer;
  font-size: 14px;
}

.noc-button:hover {
  background: rgba(88, 166, 255, 0.18);
}

.noc-alert {
  border-radius: 12px;
  padding: 13px 15px;
  margin-bottom: 18px;
}

.noc-alert-error {
  background: rgba(248, 81, 73, 0.12);
  color: #f85149;
  border: 1px solid rgba(248, 81, 73, 0.35);
}

.noc-stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(145px, 1fr));
  gap: 14px;
  margin-bottom: 22px;
}

.noc-stat-card {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  padding: 16px;
}

.noc-stat-label {
  display: block;
  color: #8b949e;
  font-size: 13px;
  margin-bottom: 8px;
}

.noc-stat-card strong {
  font-size: 28px;
}

.noc-panel {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  overflow: hidden;
}

.noc-panel-header {
  padding: 16px 18px;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  flex-wrap: wrap;
}

.noc-panel-header h2 {
  margin: 0;
  font-size: 18px;
}

.noc-muted {
  color: #8b949e;
  font-size: 13px;
}

.noc-table-wrapper {
  overflow-x: auto;
}

.noc-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 1250px;
}

.noc-table th,
.noc-table td {
  padding: 12px 14px;
  text-align: left;
  vertical-align: top;
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
  font-size: 14px;
}

.noc-table th {
  color: #8b949e;
  font-weight: 600;
  background: rgba(255, 255, 255, 0.03);
  white-space: nowrap;
}

.noc-table tr:last-child td {
  border-bottom: none;
}

.node-name {
  font-weight: 700;
  white-space: nowrap;
}

.node-fqdn {
  color: #8b949e;
  font-size: 12px;
  margin-top: 4px;
  white-space: nowrap;
}

.heartbeat-age {
  font-weight: 700;
  white-space: nowrap;
}

.heartbeat-date {
  color: #8b949e;
  font-size: 12px;
  margin-top: 4px;
  white-space: nowrap;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 4px 9px;
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  white-space: nowrap;
}

.status-online {
  background: rgba(35, 134, 54, 0.18);
  color: #3fb950;
  border: 1px solid rgba(63, 185, 80, 0.35);
}

.status-warning {
  background: rgba(187, 128, 9, 0.18);
  color: #d29922;
  border: 1px solid rgba(210, 153, 34, 0.35);
}

.status-offline {
  background: rgba(248, 81, 73, 0.16);
  color: #f85149;
  border: 1px solid rgba(248, 81, 73, 0.35);
}

.status-disabled {
  background: rgba(139, 148, 158, 0.16);
  color: #8b949e;
  border: 1px solid rgba(139, 148, 158, 0.35);
}

.capabilities-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  max-width: 280px;
}

.capability-pill {
  display: inline-flex;
  padding: 3px 8px;
  border-radius: 999px;
  background: rgba(88, 166, 255, 0.12);
  color: #79c0ff;
  border: 1px solid rgba(88, 166, 255, 0.25);
  font-size: 12px;
  white-space: nowrap;
}

.services-list {
  display: flex;
  flex-direction: column;
  gap: 5px;
  min-width: 150px;
}

.service-ok {
  color: #3fb950;
}

.service-warning {
  color: #d29922;
}

.service-na {
  color: #8b949e;
}

.node-links {
  display: flex;
  flex-direction: column;
  gap: 4px;
  white-space: nowrap;
}

.node-links a,
.services-list a {
  color: #79c0ff;
  text-decoration: none;
}

.node-links a:hover,
.services-list a:hover {
  text-decoration: underline;
}

@media (max-width: 900px) {
  .noc-layout {
    display: block;
  }

  .noc-sidebar {
    width: auto;
    min-width: 0;
    border-right: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  }

  .noc-main {
    padding: 18px;
  }

  .noc-nav {
    flex-direction: row;
    overflow-x: auto;
  }

  .noc-nav a {
    white-space: nowrap;
  }
}


/* ==========================================================
   AS60427 NOC Portal - Nodes page only
   ========================================================== */

.hidden {
  display: none !important;
}

.nodes-page {
  width: 100%;
}

.nodes-summary-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(145px, 1fr));
  gap: 14px;
  margin-bottom: 22px;
}

.nodes-stat-card {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  padding: 16px;
}

.nodes-stat-card span {
  display: block;
  color: #8b949e;
  font-size: 13px;
  margin-bottom: 8px;
}

.nodes-stat-card strong {
  font-size: 28px;
}

.nodes-panel {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  overflow: hidden;
}

.nodes-panel-header {
  padding: 16px 18px;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  flex-wrap: wrap;
}

.nodes-panel-header h2 {
  margin: 0;
  font-size: 18px;
}

.nodes-table-wrapper {
  overflow-x: auto;
}

.nodes-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 1250px;
}

.nodes-table th,
.nodes-table td {
  padding: 12px 14px;
  text-align: left;
  vertical-align: top;
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
  font-size: 14px;
}

.nodes-table th {
  color: #8b949e;
  font-weight: 600;
  background: rgba(255, 255, 255, 0.03);
  white-space: nowrap;
}

.nodes-table tr:last-child td {
  border-bottom: none;
}

.node-name {
  font-weight: 700;
  white-space: nowrap;
}

.node-fqdn {
  color: #8b949e;
  font-size: 12px;
  margin-top: 4px;
  white-space: nowrap;
}

.heartbeat-age {
  font-weight: 700;
  white-space: nowrap;
}

.heartbeat-date {
  color: #8b949e;
  font-size: 12px;
  margin-top: 4px;
  white-space: nowrap;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 4px 9px;
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  white-space: nowrap;
}

.status-online {
  background: rgba(35, 134, 54, 0.18);
  color: #3fb950;
  border: 1px solid rgba(63, 185, 80, 0.35);
}

.status-warning {
  background: rgba(187, 128, 9, 0.18);
  color: #d29922;
  border: 1px solid rgba(210, 153, 34, 0.35);
}

.status-offline {
  background: rgba(248, 81, 73, 0.16);
  color: #f85149;
  border: 1px solid rgba(248, 81, 73, 0.35);
}

.status-disabled {
  background: rgba(139, 148, 158, 0.16);
  color: #8b949e;
  border: 1px solid rgba(139, 148, 158, 0.35);
}

.capabilities-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  max-width: 280px;
}

.capability-pill {
  display: inline-flex;
  padding: 3px 8px;
  border-radius: 999px;
  background: rgba(88, 166, 255, 0.12);
  color: #79c0ff;
  border: 1px solid rgba(88, 166, 255, 0.25);
  font-size: 12px;
  white-space: nowrap;
}

.services-list {
  display: flex;
  flex-direction: column;
  gap: 5px;
  min-width: 150px;
}

.service-ok {
  color: #3fb950;
}

.service-warning {
  color: #d29922;
}

.service-na {
  color: #8b949e;
}

.node-links {
  display: flex;
  flex-direction: column;
  gap: 4px;
  white-space: nowrap;
}

.node-links a,
.services-list a {
  color: #79c0ff;
  text-decoration: none;
}

.node-links a:hover,
.services-list a:hover {
  text-decoration: underline;
}

.noc-alert {
  border-radius: 12px;
  padding: 13px 15px;
  margin-bottom: 18px;
}

.noc-alert-error {
  background: rgba(248, 81, 73, 0.12);
  color: #f85149;
  border: 1px solid rgba(248, 81, 73, 0.35);
}

.noc-muted {
  color: #8b949e;
  font-size: 13px;
}


/* ==========================================================
   AS60427 NOC Portal - Nodes polish
   ========================================================== */

.page-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 22px;
  flex-wrap: wrap;
}

.page-header h1 {
  margin: 0;
  font-size: 26px;
}

.page-header p {
  margin: 6px 0 0 0;
  color: #94a3b8;
}

.noc-button {
  border: 1px solid #2563eb;
  color: #ffffff;
  background: #2563eb;
  border-radius: 8px;
  padding: 10px 14px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
}

.noc-button:hover {
  background: #1d4ed8;
  border-color: #1d4ed8;
}
