* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    user-select: none;
}

body {
    font-family: system-ui, -apple-system, sans-serif;
    background-color: #e5e9f0;
    display: flex;
    flex-direction: column;
    width: 100vw;
    height: 100vh;
    overflow: hidden;
    position: fixed;
}

.controls {
    background: white;
    padding: 10px 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    display: flex;
    gap: 15px;
    align-items: center;
    z-index: 100;
    flex-wrap: wrap;
    justify-content: flex-start;
    flex-shrink: 0;
}

.status {
    font-size: 13px;
    font-weight: bold;
    color: #e67e22;
    white-space: nowrap;
}
.status.connected { color: #2ecc71; }
.status.error { color: #e74c3c; }

.control-group {
    display: flex;
    align-items: center;
    gap: 8px;
}

input[type="color"] {
    width: 34px;
    height: 34px;
    border: none;
    border-radius: 50%;
    cursor: pointer;
}

input[type="range"] {
    width: 80px;
}

.bg-input-field {
    font-size: 13px;
    padding: 6px 12px;
    border: 1px solid #ccc;
    border-radius: 6px;
    width: 220px;
    outline: none;
    -webkit-user-select: text;
    user-select: text;
}
.bg-input-field:focus {
    border-color: #0070f3;
}

button {
    padding: 8px 14px;
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: bold;
    font-size: 13px;
    background-color: #ff4d4d;
    white-space: nowrap;
}
button:hover { background-color: #e03333; }

.debug-strip {
    background: #2c3e50;
    color: #ecf0f1;
    padding: 4px 20px;
    font-family: monospace;
    font-size: 10px;
    display: flex;
    justify-content: space-between;
    z-index: 90;
    flex-shrink: 0;
}

.canvas-container {
    flex-grow: 1;
    position: relative;
    width: 100%;
    background-color: #ffffff;
    background-size: 100% 100%;
    background-position: center;
    background-repeat: no-repeat;
}

canvas {
    display: block;
    cursor: crosshair;
    touch-action: none; 
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}
