.component { position: relative; } .component:hover { background-color: #000; } .button { width: 34px; height: 34px; background: none; border: 0; color: inherit; font: inherit; line-height: normal; overflow: visible; padding: 0; cursor: pointer; } .button:focus { outline: 0; } .icon { padding: 5px; } .speedList { position: absolute; right: 0; bottom: 100%; display: none; background-color: rgba(0,0,0,0.7); list-style: none; padding: 0; margin: 0; color: #fff; } .component:hover .speedList { display: block; } .speedItem { padding: 7px; cursor: pointer; } .activeSpeedItem, .speedItem:hover { background: #000; } .activeSpeedItem { composes: speedItem; text-decoration: underline; }