/* Vista /pixels — oficina pixelada con personajes que reaccionan a eventos WS.
   Hoja propia para no inflar style.css con reglas que solo aplican aquí.
   Hereda variables de :root (--accent-rgb, etc.) definidas en style.css. */

html,
body.pixels-view {
    height: 100%;
    margin: 0;
    padding: 0;
    overflow: hidden;
    background: #0a0d12;
    color: rgba(255, 255, 255, 0.92);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
}

body.pixels-view {
    display: flex;
    flex-direction: column;
    height: 100dvh;
}

.pixels-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 18px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    background: linear-gradient(
        180deg,
        rgba(var(--accent-rgb, 0, 200, 255), 0.10) 0%,
        rgba(0, 0, 0, 0) 100%
    );
    flex-shrink: 0;
}

.pixels-title {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.pixels-title h1 {
    margin: 0;
    font-size: 18px;
    letter-spacing: 3px;
    font-weight: 600;
    color: rgba(var(--accent-rgb, 0, 200, 255), 0.95);
}

.pixels-subtitle {
    font-size: 11px;
    opacity: 0.55;
    letter-spacing: 1px;
}

.pixels-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
}

.pixels-status {
    display: inline-block;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    transition: background 0.2s ease;
    text-indent: -9999px;
    overflow: hidden;
}

.pixels-status.connected {
    background: #5cffae;
    box-shadow: 0 0 8px rgba(92, 255, 174, 0.6);
}

.pixels-status.disconnected {
    background: #ff7a7a;
    box-shadow: 0 0 8px rgba(255, 122, 122, 0.6);
}

#pixels-stage {
    position: relative;
    flex: 1;
    min-height: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background:
        radial-gradient(ellipse at center, rgba(var(--accent-rgb, 0, 200, 255), 0.06) 0%, rgba(0, 0, 0, 0) 70%),
        #0a0d12;
}

#pixels-canvas {
    display: block;
    image-rendering: pixelated;
    image-rendering: crisp-edges;
    max-width: 100%;
    max-height: 100%;
}

.pixels-tooltip {
    position: absolute;
    pointer-events: none;
    padding: 4px 8px;
    background: rgba(10, 13, 18, 0.92);
    border: 1px solid rgba(var(--accent-rgb, 0, 200, 255), 0.4);
    border-radius: 4px;
    font-size: 11px;
    letter-spacing: 0.4px;
    white-space: nowrap;
    transform: translate(-50%, -130%);
    z-index: 5;
}
