Pen Settings

HTML

CSS

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URLs added here will be added as <link>s in order, and before the CSS in the editor. You can use the CSS from another Pen by using its URL and the proper URL extension.

+ add another resource

JavaScript

Babel includes JSX processing.

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

Packages

Add Packages

Search for and use JavaScript packages from npm here. By selecting a package, an import statement will be added to the top of the JavaScript editor for this package.

Behavior

Auto Save

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.

Format on Save

If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.

Editor Settings

Code Indentation

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

Visit your global Editor Settings.

HTML

              
                <h1 class="title">Extracts from "Our Cats, by Harrison Weir"</h1>
	
	<article class="wrapper">
	
	<nav class="mainnav">
		<ul>
			<li><a href="">Introductory</a></li>
			<li><a href="">The First Cat Show</a></li>
			<li><a href="">Habits</a></li>
			<li><a href="">Trained Cats</a></li>
			<li><a href="">Usefulness of Cats</a></li>
		</ul>
	</nav>
	<h2 class="subhead">Usefulness of cats</h2>
	<div class="content">
	
	<p>In our urban and suburban houses what should we do without cats? In our sitting or bedrooms, our libraries, in our kitchens and storerooms, our farms, barns, and rickyards, in our docks, our granaries, our ships, and our wharves, in our corn markets, meat markets, and other places too numerous to mention, how useful they are! In our ships, however, the rats oft set them at defiance; still they are of great service.</p>

	<p>How wonderfully patient is the cat when watching for rats or mice, awaiting their egress from their place of refuge or that which is their home! How well Shakespeare in Pericles, Act iii., describes this keen attention of the cat to its natural pursuit!</p>

	<blockquote><p>The cat, with eyne of burning coal, Now crouches from (before) the mouse's hole.</p></blockquote>

	<p>A slight rustle, and the fugitive comes forth; a quick, sharp, resolute motion, and the cat has proved its usefulness. Let any one have a plague of rats and mice, as I once had, and let them be delivered therefrom by cats, as I was, and they will have a lasting and kind regard for them.</p>

	<p>A friend not long since informed me that a cat at Stone's Distillery was seen to catch two rats at one time, a fore foot on each. All the cats kept at this establishment, and there are several, are of the red tabby colour, and therefore most likely all males.</p>

	<p>I am credibly informed of a still more extraordinary feat of a cat in catching mice, that of a red tabby cat which on being taken into a granary at Sevenoaks where there were a number of mice, dashed in among a retreating group, and secured four, one with each paw and two in her mouth.</p>

	<p>At the office of The Morning Advertiser, I am informed by my old friend Mr. Charles Williams, they boast of a race of cats bred there for nearly half a century. In colour these are mostly tortoiseshell, and some are very handsome.</p>

	<p>The Government, mindful also of their utility, pay certain sums, which are regularly passed through the accounts quarterly, for the purpose of providing and keeping cats in our public offices, dockyards, stores, shipping, etc., thereby proving, if proof were wanting, their acknowledged worth.</p>

	<p>In Vienna four cats are employed by the town magistrates to catch mice on the premises of the municipality. A regular allowance is voted for their keep, and, after a limited period of active service, they are placed on the "retired list," with a comfortable pension.</p>

	<p>There are also a number of cats in the service of the United States Post Office. These cats are distributed over the different offices to protect the bags from being eaten by rats and mice, and the cost of providing for them is duly inscribed in the accounts. When a birth takes place, the local postmaster informs the district superintendent of the fact, and obtains an addition to his rations.
</p>
	</div>

	<blockquote class="quote">
		<p>Let any one have a plague of rats and mice, as I once had, and let them be delivered therefrom by cats, as I was, and they will have a lasting and kind regard for them.</p>
	</blockquote>
	
	</article>
              
            
!

CSS

              
                body {
	margin: 0;
	padding: 20px;
	color: #333;
	background-color: #efefef;
	font: 87.5%/1.4 HelveticaNeue, "Helvetica Neue", Helvetica, Arial, sans-serif;
}

img {
	max-width: 100%;
	display: block;
	height: auto;
}

figure {
	margin: 0;
	padding: 0;
}

figcaption {
	font-family: "Georgia","Times New Roman",serif;
	text-align: center;
	padding: 0.5em 0 1em 0;
}

h1, h2, h3, h4, h5, h6 {
    font-family: "Georgia","Times New Roman",serif;
    font-weight: normal;
    padding: 0;
    margin: 0;
}

h1 {
    font-size: 328.571%;
    margin-bottom: 0.2em;
}

h1.title {
	text-align: center;
}

h2 {
    font-size: 250%;
    margin-bottom: 0.2em;
}

h3 {
    font-size: 150%;
    margin-bottom: 0.2em;
}

p {
	margin:0;
	padding: 0 0 1em 0;
}

.wrapper {
	background-color: #fff;
	color: #444; 
	padding: 1em 3% 1em 3%;
	margin: 0 auto 1em auto;

}

.mainnav ul {
	margin: 0;
	padding: 0;
	list-style: none;
	font-size: 120%;
}

.mainnav a:link, .mainnav a:visited {
	text-decoration: none;
	color: #444;
}

.quote {
	font: 150%/1.4 "Georgia","Times New Roman",serif;
	padding: 0;
	margin: 0;
}

@media only screen and (min-width: 460px) {
				.wrapper {
					display: grid;
					width: 90%;
					grid-template-columns: auto ;
					grid-template-rows: auto ;
				}

				.mainnav {
					grid-row: 1 / 2;
				}

				.subhead {
					grid-row: 2 / 3;
				}

				.quote {
					grid-row: 3 / 4;
				}

				.content {
					grid-row: 4 / 5;
				}

				
			}

			@media only screen and (min-width: 700px) {
				.wrapper {
					grid-template-columns: 20% 5% auto ;
					grid-template-rows: auto ;
				}

				.mainnav {
					grid-column: 1 / 2;
					grid-row: 2 / 3;
				}

				.subhead {
					grid-row: 1 / 2;
					grid-column: 3 / 4;
				}

				.content {
					grid-column: 3 / 4;
					grid-row: 3 / 4;
				}

				.quote {
					grid-column: 3 / 4;
					grid-row: 2 / 3;
				}
			}

			@media only screen and (min-width: 980px) {
				.wrapper {
					grid-template-columns: 200px 40px auto 40px 200px;
					grid-template-rows: auto ;
					max-width: 960px;
				}

				.mainnav {
					grid-column: 1 / 2;
					grid-row: 2 / 3;
				}

				.subhead {
					grid-row: 1 / 2;
					grid-column: 3 / 4;
				}

				.content {
					grid-column: 3 / 4;
					grid-row: 2 / 3;
				}

				.quote {
					grid-column: 5 / 6;
					grid-row: 2 / 3;
				}

			}			
              
            
!

JS

              
                
              
            
!
999px

Console