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

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    background: #e8e8e8;
    color: #333;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 24px;
}

h1 {
    font-size: 1.6rem;
    font-weight: 700;
    color: #222;
    margin-bottom: 20px;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

#grid {
    display: flex;
    gap: 24px;
    align-items: center;
    flex-wrap: wrap;
    justify-content: center;
}

canvas {
    border: 3px solid #222;
    border-radius: 4px;
    background: #ffffff;
    outline: none;
}

.controls {
    background: #c0c0c0;
    border: 1px solid #aaa;
    border-radius: 8px;
    padding: 20px;
    width: 230px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.property {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.property label {
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    color: white;
    text-align: center;
}

.slider-row {
    display: flex;
    align-items: center;
    gap: 10px;
}

.slider-row span {
    font-size: 0.9rem;
    font-weight: 700;
    color: white;
    min-width: 20px;
    text-align: left;
}

input[type="range"] {
    flex: 1;
    accent-color: #ff6b6b;
    cursor: pointer;
}

input[type="number"] {
    background: #ffffff;
    border: 1px solid #aaa;
    border-radius: 4px;
    color: #333;
    padding: 6px 10px;
    font-size: 0.9rem;
    width: 100%;
    outline: none;
}

input[type="number"]:focus {
    border-color: #666;
}

select {
    background: #ffffff;
    border: 1px solid #aaa;
    border-radius: 4px;
    color: #333;
    padding: 6px 10px;
    font-size: 0.85rem;
    width: 100%;
    outline: none;
    cursor: pointer;
}

select:focus {
    border-color: #666;
}

#drawButton {
    background: #aaa;
    color: white;
    border: none;
    border-radius: 6px;
    padding: 10px 0;
    font-size: 0.9rem;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s;
    width: 100%;
    text-transform: uppercase;
}

#drawButton:hover {
    background: #bbb;
}

#drawButton:active {
    background: #999;
}

.status-bar {
    display: flex;
    justify-content: space-between;
    font-size: 0.72rem;
    color: #666;
    border-top: 1px solid #aaa;
    padding-top: 12px;
    margin-top: 4px;
}
