{
  "dashboard": {
    "id": null,
    "title": "Infrastructure Overview - User Friendly",
    "tags": ["infrastructure", "overview", "user-friendly"],
    "style": "dark",
    "timezone": "browser",
    "panels": [
      {
        "id": 1,
        "title": "🟢 Service Health Status",
        "type": "stat",
        "targets": [
          {
            "expr": "up",
            "legendFormat": "{{job}} - {{instance}}"
          }
        ],
        "fieldConfig": {
          "defaults": {
            "color": {
              "mode": "thresholds"
            },
            "thresholds": {
              "steps": [
                {"color": "red", "value": 0},
                {"color": "green", "value": 1}
              ]
            },
            "mappings": [
              {
                "options": {
                  "0": {"text": "🔴 DOWN", "color": "red"},
                  "1": {"text": "🟢 UP", "color": "green"}
                },
                "type": "value"
              }
            ],
            "unit": "short",
            "displayName": "Status"
          }
        },
        "gridPos": {"h": 8, "w": 12, "x": 0, "y": 0},
        "options": {
          "colorMode": "value",
          "graphMode": "none",
          "justifyMode": "auto",
          "orientation": "auto",
          "reduceOptions": {
            "calcs": ["lastNotNull"],
            "fields": "",
            "values": false
          },
          "textMode": "auto"
        }
      },
      {
        "id": 2,
        "title": "📊 System Resource Usage",
        "type": "stat",
        "targets": [
          {
            "expr": "100 - (avg by (instance) (irate(node_cpu_seconds_total{mode=\"idle\"}[5m])) * 100)",
            "legendFormat": "CPU Usage - {{instance}}"
          },
          {
            "expr": "(1 - (node_memory_MemAvailable_bytes / node_memory_MemTotal_bytes)) * 100",
            "legendFormat": "Memory Usage - {{instance}}"
          }
        ],
        "fieldConfig": {
          "defaults": {
            "color": {
              "mode": "thresholds"
            },
            "thresholds": {
              "steps": [
                {"color": "green", "value": 0},
                {"color": "yellow", "value": 70},
                {"color": "red", "value": 90}
              ]
            },
            "unit": "percent",
            "min": 0,
            "max": 100
          }
        },
        "gridPos": {"h": 8, "w": 12, "x": 12, "y": 0}
      },
      {
        "id": 3,
        "title": "🌐 Network Traffic",
        "type": "graph",
        "targets": [
          {
            "expr": "rate(node_network_receive_bytes_total[5m]) / 1024 / 1024",
            "legendFormat": "📥 Receive - {{device}}"
          },
          {
            "expr": "rate(node_network_transmit_bytes_total[5m]) / 1024 / 1024",
            "legendFormat": "📤 Transmit - {{device}}"
          }
        ],
        "yAxes": [
          {
            "label": "MB/s",
            "min": 0
          }
        ],
        "gridPos": {"h": 8, "w": 12, "x": 0, "y": 8}
      },
      {
        "id": 4,
        "title": "💾 Disk Usage",
        "type": "graph",
        "targets": [
          {
            "expr": "(1 - (node_filesystem_avail_bytes / node_filesystem_size_bytes)) * 100",
            "legendFormat": "{{device}} - {{mountpoint}}"
          }
        ],
        "yAxes": [
          {
            "label": "Usage %",
            "min": 0,
            "max": 100
          }
        ],
        "gridPos": {"h": 8, "w": 12, "x": 12, "y": 8}
      },
      {
        "id": 5,
        "title": "🔧 Service Response Times",
        "type": "graph",
        "targets": [
          {
            "expr": "probe_duration_seconds{job=\"http-service-health\"}",
            "legendFormat": "{{instance}}"
          }
        ],
        "yAxes": [
          {
            "label": "Response Time (seconds)",
            "min": 0
          }
        ],
        "gridPos": {"h": 8, "w": 12, "x": 0, "y": 16}
      },
      {
        "id": 6,
        "title": "📈 Container Resource Usage",
        "type": "graph",
        "targets": [
          {
            "expr": "rate(container_cpu_usage_seconds_total[5m]) * 100",
            "legendFormat": "CPU - {{name}}"
          },
          {
            "expr": "container_memory_usage_bytes / 1024 / 1024",
            "legendFormat": "Memory MB - {{name}}"
          }
        ],
        "yAxes": [
          {
            "label": "CPU % / Memory MB"
          }
        ],
        "gridPos": {"h": 8, "w": 12, "x": 12, "y": 16}
      }
    ],
    "time": {
      "from": "now-1h",
      "to": "now"
    },
    "refresh": "30s",
    "templating": {
      "list": [
        {
          "name": "service",
          "type": "query",
          "query": "label_values(up, job)",
          "refresh": 1,
          "includeAll": true,
          "multi": true
        }
      ]
    }
  }
}
