• I want to make these buttons responsive in css. I tried setting the width to a percentage value but they just overlap each other at lower resolutions.
    Website: chirecmun.org
    Here is the code for them:

    .enter-container {
        position: relative;
        display: table-cell;
        text-align: center;
        vertical-align: middle;
    width:10%;
    }
    
    .enter-button, .enter-button2 {
        border: 3px solid #2EA3F2;
        color: #2EA3F2;
        outline: none;
        font-family: inherit;
        font-size: inherit;
        background: none;
        cursor: pointer;
        padding: 2em 6em;
        display: inline-block;
        text-transform: uppercase;
        letter-spacing: 1px;
        font-weight: 700;
        outline: none;
        -webkit-transition: all 0.3s;
        -moz-transition: all 0.3s;
        transition: all 0.3s;
        z-index: 101;
       top: 65%;
       position: absolute;
    width:10%;
    
    }
     .enter-button {
    left:25%;
    
    }
    .enter-button2{
    right:25%;
    
    }
    .enter-button:hover {
        background-color: #008CBA;
        color: white;
    }
    .enter-button2:hover {
        background-color: #008CBA;
        color: white;
    }
Viewing 1 replies (of 1 total)
  • Andrew Nevins

    (@anevins)

    WCLDN 2018 Contributor | Volunteer support

    Do absolute positioning the other way around, absolutely position the image instead. Or remove absolute positioning of the buttons on mobile via media queries.

Viewing 1 replies (of 1 total)
  • The topic ‘How to make buttons responsive?’ is closed to new replies.