* { margin: 0; padding: 0; box-sizing: border-box; }

body { font-family: Arial, sans-serif; background-color: aliceblue; }

.container {
    position: relative;
    display: flex;
    flex-direction: column;
    width: 100%;
    height: 100vh;
    overflow: hidden;
}

.header {
    flex: 0 0 auto;
    padding: 6px 10px 8px 10px;
    background-color: #f0f8ff;
    border-bottom: 1px solid #c5cae9;
}

.header .title {
    text-align: center;
    font-size: 18px;
    font-weight: bold;
    color: #1a237e;
    margin-bottom: 4px;
}

.header-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
}

#network {
    flex: 1 1 auto;
    min-height: 0;
    width: 100%;
    background-color: aliceblue;
}

.legend { display: flex; flex-wrap: wrap; gap: 12px; font-size: 12.5px; }
.legend-item { display: flex; align-items: center; }

.swatch {
    display: inline-block;
    width: 16px; height: 12px;
    margin-right: 5px;
    border-radius: 3px;
    border: 2px solid #1565c0;
    background-color: #90caf9;
}

.line { display: inline-block; width: 20px; height: 0; margin-right: 5px; }
.line.rest  { border-top: 3px solid #ef6c00; }
.line.grpc  { border-top: 3px solid #6a1b9a; }
.line.async { border-top: 3px dotted #2e7d32; }
.line.db    { border-top: 3px dashed #c62828; }

.view-selector { font-size: 13px; white-space: nowrap; }
.view-selector label { font-weight: bold; margin-right: 5px; }
.view-selector select {
    font-size: 13px;
    padding: 3px 5px;
    border-radius: 5px;
    border: 1px solid #999;
}

.infobox {
    flex: 0 0 auto;
    height: 116px;
    margin: 0 10px 10px 10px;
    overflow-y: auto;
    background-color: rgba(255, 255, 255, 0.97);
    border: 1px solid #c5cae9;
    border-left: 5px solid #3949ab;
    border-radius: 8px;
    padding: 10px 14px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.15);
}

.infobox-title { font-size: 15px; font-weight: bold; color: #1a237e; margin-bottom: 5px; }
.infobox-body { font-size: 14px; line-height: 1.5; color: #333; }
.infobox-body .tradeoff { color: #c62828; font-weight: bold; }
