* {
    box-sizing: border-box;
    user-select: none;
    color: #232323;
}

html {
    -webkit-animation: fadein 0.5s cubic-bezier(.4,.0,.23,1); /* Safari, Chrome and Opera > 12.1 */
       -moz-animation: fadein 0.5s cubic-bezier(.4,.0,.23,1); /* Firefox < 16 */
        -ms-animation: fadein 0.5s cubic-bezier(.4,.0,.23,1); /* Internet Explorer */
         -o-animation: fadein 0.5s cubic-bezier(.4,.0,.23,1); /* Opera < 12.1 */
            animation: fadein 0.5s cubic-bezier(.4,.0,.23,1);
}

html, body {
    margin: 0;
    height: 100%;
    font-size: 10px;
}

body {
    background: #FFFFFF;
    margin: 0;
    padding: 0;
    font-family: "Roboto", sans-serif;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
    -moz-osx-font-smoothing: grayscale;
    -moz-font-feature-settings: “liga” on;
}

body.semi {
    background: #FFFFFF url('semi_baseline.svg');
}

body.red {
    background: #FFFFFF url('baseline.svg');
}

.container {
    max-width: 760px;
    width: 80%;
    margin: 48px auto;

    display: flex;
    flex-direction: column;
    font-size: 1.4rem;
    line-height: 3.6rem;
    transition: width 250ms cubic-bezier(.4,.0,.23,1);
}

h1, h2, h3, h4, h5, h6, p {
    margin: 0;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Roboto', sans-serif;
    font-weight: 700;
}

h1 {
    font-size: 5.2rem;
    line-height: 6rem;
    margin-bottom: 6.3rem;
    margin-left: -0.02em;
}

h2 {
    font-size: 3rem;
    margin-left: -0.1rem;
    margin-bottom: 1.4rem;
    // line-height: 6rem;
    // margin-bottom: 2.3rem;
}

.container > p {
    padding: 1.5rem 1rem 1rem 1rem;
    margin: 0px 0px 0.6rem -1rem;
    transition: background-color 150ms cubic-bezier(.4,.0,.23,1);
    border-radius: 5px;
}

.container > p:hover,
.container > p.focused {
    background-color: #f4f4f4;
}

.container > p + h2 {
    margin-top: 34px;
}

input[type='checkbox']{
    width: 0px;
    height: 0px;
    position: absolute;
    left: -999999px;
    opacity: 0;
}

input[type='checkbox'] + label{
  position: relative;
  display: flex;
  // color: #9e9e9e;
  transition: color 125ms cubic-bezier(.4,.0,.23,1);
}

input[type='checkbox'] + label > span{
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
  margin-right: 24px;
  width: 24px;
  height: 24px;
  background: transparent;
  border: 2px solid #9E9E9E;
  border-radius: 2px;
  cursor: pointer;
  transition: all 125ms cubic-bezier(.4,.0,.23,1);
}

input[type='checkbox'] + label > p {
    max-width: 90%;
    font-size: 1.8rem;
    line-height: 3.6rem;
    margin-top: -7px;
    transition: all 125ms cubic-bezier(.4,.0,.23,1);
}



input[type='checkbox']:checked + label > span{
  border: 12px solid #6391f8;
  animation: shrink-bounce 125ms cubic-bezier(.4,.0,.23,1);
}

input[type='checkbox']:checked + label > span:before{
  content: "";
  position: absolute;
  top: -1px;
  left: -7px;
  border-right: 3px solid transparent;
  border-bottom: 3px solid transparent;
  transform: rotate(45deg);
  transform-origin: 0% 100%;
  animation: checkbox-check 125ms 125ms cubic-bezier(.4,.0,.23,1) forwards;
}

input[type='checkbox']:checked + label > p {
    color: #d1d1d1;
    text-decoration: line-through;
}

@media screen and (max-width: 600px) {
    .container {
        width: 90%;
        margin: 24px auto;
    }

    h1 {
        font-size: 3.2rem;
        margin-bottom: 2rem;
    }

    h2 {
        font-size: 2.4rem;
    }

    input[type='checkbox'] + label > p {
        max-width: 85%;
        font-size: 1.6rem;
        line-height: 3rem;
        margin-top: -5px;
    }

    input[type='checkbox'] + label > span {
        margin-right: 20px;
        width: 20px;
        height: 20px;
    }

    input[type='checkbox']:checked + label > span{
        border: 10px solid #6391f8;
    }
}

@keyframes shrink-bounce{
  0%{
    transform: scale(1);
  }
  33%{
    transform: scale(.85);
  }
  100%{
    transform: scale(1);
  }
}
@keyframes checkbox-check{
  0%{
    width: 0;
    height: 0;
    border-color: #FFFFFF;
    transform: translate3d(0,0,0) rotate(45deg);
  }
  33%{
    width: .3em;
    height: 0;
    transform: translate3d(0,0,0) rotate(45deg);
  }
  100%{
    width: .3em;
    height: .7em;
    border-color: #FFFFFF;
    transform: translate3d(0,-.75em,0) rotate(45deg);
  }
}

@keyframes fadein {
    from { opacity: 0; transform: scale(0.97);}
    to   { opacity: 1; transform: scale(1);}
}

@keyframes spin {
    from { -moz-transform: rotate(0deg); }
    to { -moz-transform: rotate(360deg); }
}

.clear {
    font: 2em/2.3em Arial, sans-serif;
    color: #696b6b;
    text-align: center;

    position: fixed;
    z-index: 5;
    bottom: 12px;
    right: 12px;
    cursor: pointer;

    width: 48px;
    height: 48px;
    display: inline-block;
    background: #6391f8 url('update.svg');
    background-size: 50% 50%;
    background-position: 50% 50%;
    background-repeat: no-repeat;
    border-radius: 999px;
    box-shadow: 0px 4px 17px 0px rgba(0, 0, 0, 0.12);
    opacity: .5;

    transition: all 250ms cubic-bezier(0.345, 0.005, 0.07, 1);

}

.clear:hover {
    opacity: 1;
    margin-bottom: 5px;
    box-shadow: 0px 8px 17px 0px rgba(0, 0, 0, 0.12);
}

@-webkit-keyframes rotating /* Safari and Chrome */ {
  from {
    -webkit-transform: rotate(0deg);
    -o-transform: rotate(0deg);
    transform: rotate(0deg);
  }
  to {
    -webkit-transform: rotate(360deg);
    -o-transform: rotate(360deg);
    transform: rotate(360deg);
  }
}
@keyframes rotating {
  from {
    -ms-transform: rotate(0deg);
    -moz-transform: rotate(0deg);
    -webkit-transform: rotate(0deg);
    -o-transform: rotate(0deg);
    transform: rotate(0deg);
  }
  to {
    -ms-transform: rotate(360deg);
    -moz-transform: rotate(360deg);
    -webkit-transform: rotate(360deg);
    -o-transform: rotate(360deg);
    transform: rotate(360deg);
  }
}

.pulse {
    animation: shrink-bounce 300ms cubic-bezier(.4,.0,.23,1) 1;
}