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

body {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    min-height: 100vh;
    font-family: 'Arial', sans-serif;
    background-color: #f0f0f0;
    color: #333;
}

header {
    width: 100%;
    padding: 20px 0;
    background-color: #4a4a4a;
    color: white;
    text-align: center;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

h1 {
    font-size: 2.5em;
}

main {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    width: 100%;
    max-width: 1200px;
    margin: 20px 0;
    padding: 0 20px;
}

.controls {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-right: 20px;
}

button, .color-picker {
    padding: 10px 15px;
    font-size: 1em;
    cursor: pointer;
    background-color: #3498db;
    color: white;
    border: none;
    border-radius: 5px;
    transition: background-color 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

button:hover {
    background-color: #2980b9;
}

.color-picker {
    background-color: #2ecc71;
}

.color-picker:hover {
    background-color: #27ae60;
}

#colorPicker {
    margin-right: 10px;
}

#container {
    display: flex;
    flex-wrap: wrap;
    width: 600px;
    height: 600px;
    border: 2px solid #333;
    box-shadow: 0 0 10px rgba(0,0,0,0.1);
}

#container div {
    transition: background-color 0.2s ease;
}

footer {
    width: 100%;
    padding: 20px 0;
    background-color: #4a4a4a;
    color: white;
    text-align: center;
}

footer a {
    color: #3498db;
    text-decoration: none;
}

footer a:hover {
    text-decoration: underline;
}