title: Remove CSS applied by a click event
body: <p>So I'm having trouble toggling this switch to change the background color. Im not sure how to get it to remove the CSS that it applies to the document. I want it to toggle between to different colored backgrounds.  </p>
  
  <p>Here's my code:</p>
  
  <pre><code>&lt;!Doctype html&gt;
  &lt;html lang="en"&gt;
  &lt;head&gt;
      &lt;link rel="stylesheet" href="styles.css"&gt;
  &lt;/head&gt;
  &lt;body&gt;
      &lt;div class="container"&gt;
          &lt;label class="switch"&gt;&lt;input id="input" type="checkbox" /&gt;&lt;div&gt;&lt;/div&gt;&lt;/label&gt;
      &lt;/div&gt;
      &lt;footer&gt;
          &lt;script src="https://code.jquery.com/jquery-2.2.1.js"&gt;&lt;/script&gt;
          &lt;script type="text/javascript" src="js.js"&gt;&lt;/script&gt;
      &lt;/footer&gt;
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>The Styles:</p>
  
  <pre><code>html {
  background: #878476;
  }
  
  .container {
  position: absolute;
  top: 0; right: 0; bottom: 0; left: 0;
  height: 40px;
  margin: auto;
  text-align: center;
  }
  
  .switch input {
  position: absolute;
  opacity: 0;
  }
  
  .switch {
  display: inline-block;
  font-size: 20px; /* 1 */
  height: 1em;
  width: 2em;
  background: #BDB9A6;
  border-radius: 1em;
  }
  
  .switch div {
  height: 1em;
  width: 1em;
  border-radius: 1em;
  background: #FFF;
  box-shadow: 0 0.1em 0.3em rgba(0,0,0,0.3);
  transition: all 300ms;
  transition: all 300ms;
  transition: all 300ms;
  }
  
  .switch input:checked + div {
  transform: translate3d(100%, 0, 0);
  transform: translate3d(100%, 0, 0);
  transform: translate3d(100%, 0, 0);
  }
  </code></pre>
  
  <p>And the JS:</p>
  
  <pre><code>$(document).ready(function() {
  console.log( "Coffee Isn't strong enough for me to remember how to toggle the OnClick" );
  $(".switch").on("click", function() {
      $("html").css("background", "blue");
  });
  });
  </code></pre>