/* Big ol' reset */
body, html{
    width:100%; height:100%;
    overflow:hidden;
    font-family: Helvetica, Arial, sans-serif;
    font-weight: 100;
}
b, strong{
    font-weight: bold;
}

/* Structure of this half-and-half page */
#container{

    /* Big ol' block */
    width: 1100px;
    height: 560px;

    /* In the middle */
    position:absolute;
    margin: auto;
    top:0; left:0; right:0; bottom:0;

}
#left-half, #right-half{
    position: absolute;
    width:540px;
    height:495px;
}
#left-half{     left:0;     }
#right-half{    right:0;    }
#bottom{
    position: absolute;
    bottom: 10px;
    width: 100%;
    text-align: center;
}
/* Copy Snow's CSS */
#right-half code, #right-half pre{
    background-color: #f0f0f0;
    border-radius: 3px;
    font-size: 85%;
    padding: 2px 4px;
}
#right-half blockquote{
    border-left: 4px solid #ccc;
    margin-bottom: 5px;
    margin-top: 5px;
    padding-left: 16px;
    margin-left:0;
}

/* Titles saying what's what */
.half-title{
    font-family: Helvetica, Arial, sans-serif;
    font-size: 28px;
    font-weight: 100;
    line-height: 1.3em;
}
.point-down{
    position:relative;
    top: 0.5em;
}
.inline-button{
    display: inline-block;
    border: 1px solid #000;
    border-radius: 1em;
    padding: 0 0.5em;
    cursor:pointer;
    position:relative;
    opacity:1;
    top:0px;
    transition: all 0.1s ease-in-out;
}
.inline-button:hover{
    opacity:0.5;
    top:-2px;
}
.inline-button:active{
    opacity:1;
    top:2px;
}

/* The EDITOR half */
#editor{
    position: absolute;
    bottom:0;
}
#editor-rich, #editor-md, #editor-html{
    display:none; /* don't clutter, to start */
}
#editor-rich-textbox{
    width: 540px;
    height: 360px;
    font-size: 16px;
}
#editor-md, #editor-html{
    width: 540px;
    height: 400px;
    border: 1px solid #ccc;
}
.CodeMirror {
    font-family: monospace;
    font-size: 16px;
}
.CodeMirror-code{
    margin: 20px 0 !important;
}
.CodeMirror-line{
    padding-left: 20px !important;
}
.ql-editor p{ /* WHY CAN'T YOU BE NORMAL?! */
    margin-block-start: 1em !important;
    margin-block-end: 1em !important;
}

/* The PREVIEW half */
#try-nutshell-output{

    position: absolute;
    bottom:0;
    width: 500px;
    height: 350px;
    padding: 20px;
    padding-top: 30px;
    border: 1px solid #ccc;

    font-family: Helvetica, Arial, sans-serif;
    font-size: 16px;
    line-height: 1.42;

    overflow-y: scroll;
    overflow-x: hidden;

}
#try-nutshell-output p img{
    max-width: 100%;
}

/* Hack */
#nutshell-close-all{
    font-size:15px;
}

/* MOBILE */
.show-only-when-desktop{
    display:inline;
}
.show-only-when-mobile{
    display:none;
}
@media (max-width: 600px){
    body, html{
        overflow:visible;
        font-weight: normal;
    }
    body{
        margin: 1em 0;
    }
    #container{
        width: 540px;
        height: 940px;
        position:relative;
        margin-bottom: 3em;
        margin-top: 1em;
    }
    #left-half {
      top: 0;
    }
    #right-half {
      top: 470px;
    }
    #left-half, #right-half {
      height: 455px;
    }
    #bottom{
        bottom: -18px;
    }
    .show-only-when-desktop{
        display:none;
    }
    .show-only-when-mobile{
        display:inline;
    }
    #editor-rich-textbox, #try-nutshell-output{
        font-size: 22px;
    }
}