nav 
{
    width: 100%;
    max-width:1024px;
    background: #AA504D;
}
 
nav .main_pages 
{
    display: flex;
    justify-content: space-around;
    align-items: center;
}
 
nav .main_pages a 
{
    width: 20%;
    padding: 1em;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: white;
}
 
nav a:hover 
{
    background: #AA504D;
}
label, #toggle
{
    display: none;
}
 
@media all and (max-width: 600px)
{
    nav
    {
        /*height: 60px;*/
    }
 
    nav .main_pages 
    {
        display: none;
        flex-direction: column;
        background: #AA504D;
        height: 140px;
    }

    nav .main_pages a {
      width: 50%;
      padding: 1%;
    }

    label 
    {
        width: 30px;
        display: flex;
        justify-content: center;
        align-items: center;
        margin: 0 auto;
        font-size: 20px;
        color: white;
        cursor: pointer;
    }
    #toggle:checked + .main_pages {
      display: flex;
  }
}