Pen Settings

HTML

CSS

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URL's added here will be added as <link>s in order, and before the CSS in the editor. If you link to another Pen, it will include the CSS from that Pen. If the preprocessor matches, it will attempt to combine them before processing.

+ add another resource

JavaScript

Babel is required to process package imports. If you need a different preprocessor remove all packages first.

Add External Scripts/Pens

Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.

+ add another resource

Behavior

Save Automatically?

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.

HTML Settings

Here you can Sed posuere consectetur est at lobortis. Donec ullamcorper nulla non metus auctor fringilla. Maecenas sed diam eget risus varius blandit sit amet non magna. Donec id elit non mi porta gravida at eget metus. Praesent commodo cursus magna, vel scelerisque nisl consectetur et.

HTML

            
              <head>
  <link href="https://fonts.googleapis.com/css?family=Cutive" rel="stylesheet"/>
  <link href="https://fonts.googleapis.com/css?family=Gudea" rel="stylesheet"/>
  <meta name="viewport" content="width=device-width"/>
</head>
<div class="container">
  <div class="expandable-boxes">
    <div class="expandable-box">
       <h1>What to Expect</h1>
      <h2>Our basic exam (click to expand):</h2>
      <ul>
        <li>We'll ask about your <b>medical history</b> and any vision problems you might be experiencing.</li>
        <li>Next, we evaluate your <b>visual field</b> to determine if you have difficulty seeing in any particular area.</li>
        <li>Your eye doctor will then perform a visual <b>acuity test</b> and a <b>refraction test</b> to measure how clearly you see. From here we can perscribe corrective lenses for your glasses or contacts. </li>
        <li>We now check the <b>health of your eyes</b>, using lights to evaluate the front and inside of each eye. We'll perform a special test for glaucoma and may have you dilate your eyes so we can examine them in greater detail.</li>
    <li>Finally, we will discuss the outcome of the exam and answers any questions you have about your eyes.</li>
</ul>
    </div>
     <div class="expandable-box">
      <h1>How often should I visit?</h1>
      <h2> 
        <u>Regular Eye Exams</u>
        <t>are important for all of us. </t>
      </h2>
      <ul class="list1">
        <li> <b>Infants</b>
          <t>should be seen as early as 6 months to look for signs of crossed or lazy eyes.</t>
        </li>
        <li> <b>Kindergarteners</b>
          <t>should be examined before school starts to ensure that they can see comfortably. Eye strain can cause stress and greatly impair a student's ability to learn. Try to revisit the doctor at the beginning of each school year.</t>
        </li>
        <li> <b>College students</b>
          <t>handle an increased reading load and extra computer usage. A significant number of young adults become myopic or near-sighted as a consequence. Check-ups are essential during this time as early myopia can lead to other conditions later in life.</t>
        </li>
        <li> <b>Adults</b>
          <t>often find themselves seeing blurred or with health issues such as diabetes, or high blood pressure, which can be manifested in the eye. Visit every 1-2 years.</t>
        </li>
        <li> <b>Seniors</b>
          <t>are most at risk for optic disorders and should see the doctor at least once a year.</t>
        </li>
      </ul>
    </div>
    <div class="expandable-box">
       <h1>Contact Lenses</h1>
      <h2>Learn more about contacts.</h2><p>Contact lens fittings require an additional exam. We will help you select the style of contact you would like and help you get used to wearing them. <br><br> We carry many varieties of contacts: <ul><li>Conventional soft contacts</li><li>Rigid Gas Permeable contacts</li><li>Disposable Contacts</li> </ul> and ensure that your orders with us are ready for prompt pick-up.<br><br>Link: <a href="http://www.aoa.org/patients-and-public/caring-for-your-vision/contact-lenses/advantages-and-disadvantages-of-various-types-of-contact-lenses?sso=y">Types of Contacts: Pros and Cons </a></p>
    </div>
    
    <div class="expandable-box">
       <h1>Eye Care Articles</h1>
      <h2>More information:</h2>
      <ul><li><a href="https://medlineplus.gov/eyediseases.html">Common Eye Disease</li></a><li><a href="http://www.allaboutvision.com/resources/anatomy.htm">Eye Anatomy</li><li><a href="http://www.mayoclinic.org/tests-procedures/eye-exam/home/ovc-20189446">Mayo Clinic Eye Exam Overview</li><li><a href="https://www.vsp.com/eyeglasses-lenses.html">Types of Lenses & Coatings</li><li><a href="http://www.allaboutvision.com/conditions/cataracts.htm">Cataracts: The Most Common Cause of Vision Loss for Ages 40+</a></li><li><a href="http://www.aoa.org/patients-and-public/caring-for-your-vision/diet-and-nutrition/lutein?sso=y">Lutein & Zeaxanthin: Eye Disease Preventing Antioxidants</a></li><li><a href="https://www.thevisioncouncil.org/content/digital-eye-strain/adults">What Is Digital Eye Strain?</a></li><li><a href="http://www.nature.com/news/the-myopia-boom-1.17120">Myopia Near-Sightedness Epidemic</a></li></ul>
    </div>
  </div>
</div>
            
          
!

CSS

            
              @import "compass/css3";
body {
  background: #FFFFFF;
  background-repeat: no-repeat;
  height: 100vh;
  font-size: 15px;
  line-height: 1.6;
  font-family: Gudea;
  color: #424242;
  overflow: hidden;
}
body h1 {
  padding: 0;
  line-height: 1.4;
  padding-left: 0.1cm;
  margin: 0;
  font-family: "Cutive", Arial, sans-serif;
  font-weight: bold;
  font-style: italic;
  font-size: 18px;
}
body h2 {
  line-height: 0.2;
  padding-left: 0.4cm;
  padding-bottom: 0.1cm;
  font-weight: normal;
  font-size: 16px;
}
body ul {margin-top: 20px;  list-style-type: circle;}
body li {padding-bottom: 12px;}
body p {padding-left: 10px;}
.container {
  width: 520px;
  margin: 5px auto;
}

.expandable-boxes {
  position: relative;
}
.expandable-box {
  width: 100%;
  height: 78px;
  float: left;
  margin: 0% 0% 2% 0%;
  border: 5px solid #EBDA9D;
  border-radius: 12px;
  overflow: hidden;
  padding: 10px;
  box-sizing: border-box;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12), 0 1px 2px rgba(0, 0, 0, 0.24);
  cursor:pointer;
  -webkit-transition: all .6s ease-in-out;
  -moz-transition: all .6s ease-in-out;
  -o-transition: all .6s ease-in-out;
  -ms-transition: all .6s ease-in-out;
  transition: all .6s ease-in-out;
  
  &.open {
    width: 100%;
    height: 100%;
    margin: 0;
  }
  
  &.out {
    overflow: hidden;
    width: 100%;
    height: 78px;
  }
}
            
          
!

JS

            
              $(document).ready(function() {
  $('.expandable-box').click(function(e) {
    if($(this).hasClass('open')) {
      $('.expandable-box.out').not($(this)).removeClass('out');
      $(this).removeClass('open');
    }
    else {
      $('.expandable-box').not($(this)).addClass('out');
      $(this).addClass('open');
      $(this).removeClass('out');
    }
  });
});
            
          
!
999px

Console