* {
        padding: 0;
        margin: 0;
}

a {
        color: inherit;
}

body {
        color: #222;
        font-family: sans-serif;
}



div.categories, 
div.category{
  display: flex;
  flex-direction: column;
}


.questions li:not(:hover) input:not(:checked)+label{
    opacity: 0.5;
}



article {
   min-height: 100vh;
}




article > header {
        padding: 2em;
}

article h4{
    padding: 0 0 2em;
    margin: 3em 1em 0;
    border-top: 1px solid;
}
article h4 span{
        text-transform: uppercase;
        font-size: 0.8em;
        font-weight: normal;
    padding: 0.5em 0;

}

article h2 {
        padding-top: 1em;
        font-size: 3em;
        font-weight: normal;
}

form {
        padding: 3em 2em;
        display: flex;
        flex-direction: column;
}


h3{
   font-weight: normal;
   font-size: 1em;
   padding-bottom: 2em;
}


form.signup > div{
    display: flex;
    flex-direction: column;
    max-width: 16em;
    padding: 0 0 1em;
}

form.signup label {
        font-size: 0.7em;
        padding: 1em 0 0.5em;
        text-transform: uppercase;
}



form div {
        display: flex;
}

form input {
        padding: 0.5em;
}

ul.questions {
        max-width: 40em;
        margin-bottom: 2em;
        display: flex;
        flex-direction: column;
}

body > header {
        padding: 1em 0;
        margin-bottom: 3em;
}

body > header > h1 > a {
        text-decoration: none;
}

body > header > h1 {
        display: inline-block;
        font-weight: normal;
        font-size: 1em;
        padding: 0;
}
body > header > nav > *,
body > header a {
        padding: 2em;
        display: inline-block;
}
body > header > nav {
        float: right;
        display: inline-block;
}



ul.questions{
   list-style-type: none;
}
.questions li {
        padding: 0 0 3em;
}
.questions li p{
   padding: 1em;
}

.questions input[type="range"] {
        max-width: 40em;
}

form button[type=submit] {
        display: flex;
        margin-right: auto;
        cursor: pointer;
        padding: 1rem 3rem;
        background: black;
        border: none;
        color: white;
        border-radius: 3em;
}


form.survey button:not(.show){
        display: none;
}

form.survey button.show{
       animation: showup 1s ease 1s both;
}

@keyframes showup{
      from{
         opacity: 0;
      }
}


div.radio{
   display: flex;
   padding: 0;
}

div.radio input{
   display: none
}

div.radio input:checked+label{
   background: black;
   color: white;
}


div.radio input:not(:checked)+label:hover{
    background: #EEE;
}
/*
input:invalid+label{
  color: red;
}
*/


.questions li:not(.used) + li{
  display: none;
}




div.category:first-child ul.questions li:first-child{
  opacity: 1;
}

div.category.used + div.category{
    display: flex;
}

div.category:not(:first-child):not(.used){
    display: none;
}


.questions li.used,
.questions li.used+li{
   opacity: 1;
}

div.radio label{
        transition: opacity 0.3s ease;
        cursor: pointer;
   padding: 1em;
   border-radius: 3em;
   display: inline-block;
}

/*
.questions li label {
        display: inline-block;
        padding: 1em 0 0;
}
*/

footer a {
        padding: 2em;
        display: inline-block;
}

footer {
        margin-top: 5em;
}
