I have a group of buttons in HTML:
<div class="controls">
<div id="s-controls">
<button class="control-btn" style="background-color: #2de7f6">1</button>
<button class="control-btn" style="background-color: #69a6ea">2</button>
<button class="control-btn" style="background-color: #736ace">3</button>
<button class="control-btn" style="background-color: #372ac3">4</button>
</div>
</div>
When I try to make the page smaller, the buttons maintain their original size and it looks messy.
I have experimented with CSS, but I am not very skilled. Here is what I have tried so far:
.controls {
background-color: #1F1F1F;
min-height: 50px;
}
button {
margin: 20px auto;
max-width: 100%;
}
#s-controls, #p-controls {
text-align: center;
}
#s-controls > *, #p-controls > * {
font-family: "Titillium Web", sans-serif;
font-weight: 600;
color: white;
cursor: pointer;
}
.control-btn {
display: inline-block;
box-shadow: inset 0 1px 0 rgba(255,255,255,0.2);
line-height: 2.5em;
padding: 0 3em;
text-decoration: none;
}
line-height: 1.75em;
padding: 0 0.75em;
}
.control-btn:hover {
box-shadow: inset 0 1px 1px rgba(255,255,255,0.5),
inset 0 1.5em 1em rgba(255,255,255,0.3);
}
I am looking for a solution using only HTML and CSS to shrink the buttons so they maintain their original design on one row.
Any guidance would be greatly appreciated!