* { margin: 0; padding: 0; box-sizing: border-box; }
body {
    font-family: 'Segoe UI', Arial, sans-serif;
    overflow: hidden;
    background: #0a0e27;
}
#renderCanvas {
    width: 100vw;
    height: 100vh;
    display: block;
    touch-action: none;
    outline: none;
}

/* Panel de controles */
.controls {
    position: fixed;
    top: 20px;
    left: 20px;
    background: rgba(10, 14, 39, 0.85);
    color: white;
    padding: 15px 20px;
    border-radius: 8px;
    border: 1px solid #2a3f5f;
    z-index: 100;
    min-width: 250px;
}
.controls h3 {
    margin-bottom: 10px;
    color: #4fc3f7;
    font-size: 16px;
}
.controls button {
    background: #1976d2;
    color: white;
    border: none;
    padding: 8px 15px;
    margin-right: 8px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 13px;
    transition: background 0.2s;
}
.controls button:hover { background: #1565c0; }
.controls button.active { background: #4caf50; }
.controls .hint {
    font-size: 12px;
    color: #90a4ae;
    margin-top: 10px;
    line-height: 1.5;
}

/* Panel de información del servidor */
.server-info {
    position: fixed;
    top: 20px;
    right: 20px;
    background: rgba(10, 14, 39, 0.92);
    color: white;
    padding: 20px;
    border-radius: 8px;
    border: 1px solid #2a3f5f;
    z-index: 100;
    min-width: 280px;
    display: none;
}
.server-info.visible { display: block; }
.server-info h3 {
    color: #4fc3f7;
    margin-bottom: 15px;
    font-size: 18px;
}
.server-info .data-row {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid #2a3f5f;
}
.server-info .data-row:last-child { border-bottom: none; }
.server-info .label { color: #90a4ae; }
.server-info .value { font-weight: bold; }
.server-info .value.ok { color: #4caf50; }
.server-info .value.warning { color: #ff9800; }
.server-info .value.critical { color: #f44336; }
.server-info .close-btn {
    position: absolute;
    top: 10px;
    right: 15px;
    background: none;
    border: none;
    color: white;
    cursor: pointer;
    font-size: 20px;
}

/* Leyenda de temperatura */
.legend {
    position: fixed;
    bottom: 20px;
    left: 20px;
    background: rgba(10, 14, 39, 0.85);
    color: white;
    padding: 12px 18px;
    border-radius: 8px;
    border: 1px solid #2a3f5f;
    z-index: 100;
    font-size: 13px;
}
.legend h4 {
    color: #4fc3f7;
    margin-bottom: 8px;
    font-size: 14px;
}
.legend-item {
    display: flex;
    align-items: center;
    margin: 4px 0;
}
.color-box {
    width: 16px;
    height: 16px;
    border-radius: 3px;
    margin-right: 10px;
}

/* Crosshair */
.crosshair {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 20px;
    height: 20px;
    pointer-events: none;
    z-index: 50;
    display: none;
}
.crosshair.visible { display: block; }
.crosshair::before,
.crosshair::after {
    content: '';
    position: absolute;
    background: white;
    opacity: 0.7;
}
.crosshair::before {
    left: 50%; top: 0; bottom: 0;
    width: 2px; transform: translateX(-50%);
}
.crosshair::after {
    top: 50%; left: 0; right: 0;
    height: 2px; transform: translateY(-50%);
}

/* Indicador de carga */
.loading {
    position: fixed;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 20px;
    z-index: 200;
}
