Slanted Button #166

CSS Slanted style button

Adding these style CSS buttons to your website is easier than you think. Simply copy and paste the CSS code provided with each button design into your stylesheet

Preview Button Style

You can view the default style of buttons, the disabled state mode style of buttons, and the full-width block style of the button here. Some buttons style may not display in full width format

Button style

Disabled style

Full width block style

Button Source Code HTML and CSS

Click the button below to download the source code or edit it live.
To copy this click on the icon at the top right of the code box
Button HTML
<button class="btn-166">
    <span>Button 166</span>
</button>
Button CSS
.btn-166 {
    --border_radius: 5px;
    background: #ff0000;
    color: #fff;
    border: none;
    padding: 10px 20px;
    font-size: 15px;
    font-weight: 600;
    text-transform: uppercase;
    transform: skew(-22deg);
    font-family: Arial, Helvetica, sans-serif;
    cursor: pointer;
    text-decoration: none;
    user-select: none;
    display: inline-flex;
    justify-content: center;
    align-items: center;
    z-index: 1;
    border-radius: var(--border_radius);
    /*** full width block ***/
    /* width: 100%; */
}

.btn-166 span {
    display: flex;
    transform: skew(22deg);
    align-items: center;
    justify-content: center;
}

.btn-166::before {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    right: 100%;
    left: 0;
    background: #141414;
    opacity: 0;
    z-index: -1;
    transition: all 0.5s;
    border-radius: var(--border_radius);
}

.btn-166:hover {
    color: #fff;
}

.btn-166:hover::before {
    left: 0;
    right: 0;
    opacity: 1;
}

/*** disabled style ***/
.btn-166:disabled {
    pointer-events: none;
    opacity: .65;
    color: #7e7e7e;
    background: #dcdcdc;
    box-shadow: none;
    text-shadow: none;
}