/* Global reset and box-sizing */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html, body {
    width: 100%;
    height: 100%;
    overflow: hidden; /* Prevent scrollbars */
    /* Robot/Metallic background gradient */
    background: linear-gradient(160deg, #cad2d9 0%, #aab8c5 50%, #8798a8 100%);
    color: #1a1a1a; /* Darker text for light background */
    font-family: 'Orbitron', 'Courier New', monospace; /* Use Orbitron if loaded, fallback */
    position: relative;
    /* Simple background elements (can be enhanced) */
    background-image:
      linear-gradient(45deg, rgba(180, 190, 200, 0.1) 25%, transparent 25%, transparent 75%, rgba(180, 190, 200, 0.1) 75%),
      linear-gradient(-45deg, rgba(180, 190, 200, 0.1) 25%, transparent 25%, transparent 75%, rgba(180, 190, 200, 0.1) 75%);
    background-size: 30px 30px;
}


/* Container for the p5.js canvas - SQUARE */
#canvasContainer {
    /* Use vmin to make it square and fit viewport */
    width: 90vmin;
    height: 90vmin;
    max-width: 650px; /* Adjust max size as needed */
    max-height: 650px;
    margin: 15px auto; /* Center */
    position: relative;
    box-shadow: 0 5px 15px rgba(0, 0, 20, 0.3); /* Darker shadow */
    border: 2px solid #505560; /* Thicker border */
    border-radius: 6px; /* Less rounded */
    overflow: hidden;
}

/* p5.js canvas styling */
canvas {
    display: block;
    width: 100%;
    height: 100%; /* Fill square container */
}

/* Container for remote buttons */
#remote {
    text-align: center;
    padding: 10px;
    margin-top: 5px;
}

/* Remote button styling - Robot/Metal theme */
.remote-button {
    padding: 9px 15px;
    margin: 4px;
    cursor: pointer;
    background: linear-gradient(180deg, #8890a0, #687080); /* Gradient background */
    color: #ffffff; /* White text */
    border: 1px solid #404550; /* Dark border */
    border-radius: 3px; /* Sharp corners */
    font-family: inherit;
    font-size: 0.95em;
    font-weight: bold;
    text-shadow: 0 1px 1px rgba(0,0,0,0.4); /* Text shadow */
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.2), 0 1px 2px rgba(0,0,0,0.3); /* Inset highlight */
    transition: background 0.2s ease, box-shadow 0.1s ease;
}

.remote-button:hover {
    background: linear-gradient(180deg, #99a0b0, #788090); /* Lighter gradient */
    color: #fff;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.3), 0 2px 4px rgba(0,0,0,0.4);
}

.remote-button:active {
    background: linear-gradient(180deg, #687080, #8890a0); /* Inverted gradient */
    box-shadow: inset 0 2px 3px rgba(0,0,0,0.3);
    transform: translateY(1px); /* Press down */
}