Pen Settings



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


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


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.


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.

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.


                <!DOCTYPE html>
<html lang="en">
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Rotating Navigation</title>
    <link rel="stylesheet" href="style.css">

        <div class="menu-trigger"><span class="close">+</span> <span>+</span></div>

    <main class="container">
            <h1>Amazing Article</h1>
            <h2 class="subheading">Florin Pop</h2>

            <p>Lorem ipsum dolor sit amet consectetur adipisicing elit. Accusantium quia in ratione dolores cupiditate, maxime aliquid impedit dolorem nam dolor omnis atque fuga labore modi veritatis porro laborum minus, illo, maiores recusandae cumque ipsa quos. Tenetur, consequuntur mollitia labore pariatur sunt quia harum aut. Eum maxime dolorem provident natus veritatis molestiae cumque quod voluptates ab non, tempore cupiditate? Voluptatem, molestias culpa. Corrupti, laudantium iure aliquam rerum sint nam quas dolor dignissimos in error placeat quae temporibus minus optio eum soluta cupiditate! Cupiditate saepe voluptates laudantium. Ducimus consequuntur perferendis consequatur nobis exercitationem molestias fugiat commodi omnis. Asperiores quia tenetur nemo ipsa.</p>

            <h3>My Dog</h3>

            <img src="" />

            <p>Lorem, ipsum dolor sit amet consectetur adipisicing elit. Sit libero deleniti rerum quo, incidunt vel consequatur culpa ullam. Magnam facere earum unde harum. Ea culpa veritatis magnam at aliquid. Perferendis totam placeat molestias illo laudantium? Minus id minima doloribus dolorum fugit deserunt qui vero voluptas, ut quia cum amet temporibus veniam ad ea ab perspiciatis, enim accusamus asperiores explicabo provident. Voluptates sint, neque fuga cum illum, tempore autem maxime similique laborum odio, magnam esse. Aperiam?</p>


    <script src="script.js"></script>



                @import url('');

* {
    box-sizing: border-box;

body {
    font-family: 'Lato', sans-serif;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin: 0;
    color: rgba(0, 0, 0, 0.9);
    letter-spacing: 1.5;
    line-height: 1.5;
    background-color: #666;
    overflow-x: hidden;

h1, h2, h3 {
    margin: 0;

.container {
    width: 100vw;
    background-color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1;
    transition: transform .5s ease-in;
    padding: 0px 60px;

    transform: translate(200px, -300px) rotate(-20deg);

.container aside {
    position: absolute;
    left: -150px;
    top: 300px;

    transform: rotate(20deg) scale(0.9);

    color: white;
    font-size: 1.5rem;
    text-transform: uppercase;

.container aside ul {
    list-style: none;

.container aside ul li{
    cursor: pointer;

article {
    padding: 80px 0px 160px;
    max-width: 960px;

h1 {
    font-size: 2rem;

h2 {
    font-size: 1.5rem;

.subheading {
    font-size: 0.8rem;
    font-style: italic;
    color: rgba(0, 0, 0, 0.7);

article img {
    max-width: 100%;
    margin: 16px 0;
    background-color: white;

header {
    width: 240px;
    height: 240px;
    border-radius: 50%;
    background-color: #ff7979;

    position: absolute;
    top: -120px;
    left: -120px;

    z-index: 2;

    transition: transform .5s ease-in;

header.rotated {
    transform: rotate(-90deg);

header .menu-trigger {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: flex-end;
    justify-content: space-around;
    padding: 0 20px 40px;

header .menu-trigger span{
    cursor: pointer;
    color: white;
    font-size:  3rem;

.close {
    transform: rotate(45deg);



                !(function () {
  "use strict";

  function onMenuTriggerClick() {
    let container = document.querySelector(".container");

    let header = document.querySelector("header");

    let isOpen = container.classList.contains("rotated");

    if (isOpen) {
    } else {

  let menuTrigger = document.querySelector(".menu-trigger");
  menuTrigger.addEventListener("click", onMenuTriggerClick);