/* inconsolata-regular - latin */
@font-face {
  font-family: 'Inconsolata';
  font-style: normal;
  font-weight: 400;
  src: url('/static/inconsolata-v17-latin-regular.eot'); /* IE9 Compat Modes */
  src: local('Inconsolata Regular'), local('Inconsolata-Regular'),
       url('/static/inconsolata-v17-latin-regular.eot?#iefix') format('embedded-opentype'), /* IE6-IE8 */
       url('/static/inconsolata-v17-latin-regular.woff2') format('woff2'), /* Super Modern Browsers */
       url('/static/inconsolata-v17-latin-regular.woff') format('woff'), /* Modern Browsers */
       url('/static/inconsolata-v17-latin-regular.ttf') format('truetype'), /* Safari, Android, iOS */
       url('/static/inconsolata-v17-latin-regular.svg#Inconsolata') format('svg'); /* Legacy iOS */
}
/* inconsolata-700 - latin */
@font-face {
  font-family: 'Inconsolata';
  font-style: normal;
  font-weight: 700;
  src: url('/static/inconsolata-v17-latin-700.eot'); /* IE9 Compat Modes */
  src: local('Inconsolata Bold'), local('Inconsolata-Bold'),
       url('/static/inconsolata-v17-latin-700.eot?#iefix') format('embedded-opentype'), /* IE6-IE8 */
       url('/static/inconsolata-v17-latin-700.woff2') format('woff2'), /* Super Modern Browsers */
       url('/static/inconsolata-v17-latin-700.woff') format('woff'), /* Modern Browsers */
       url('/static/inconsolata-v17-latin-700.ttf') format('truetype'), /* Safari, Android, iOS */
       url('/static/inconsolata-v17-latin-700.svg#Inconsolata') format('svg'); /* Legacy iOS */
}

body {
    background: #C5E1A5;
}

* {
    font-family: "Inconsolata", "monospace";
}

a, h1 > a:visited {
    color: black;
    text-decoration: none;
}

h1 {
    text-align: center;
    font-weight: 700;
    font-size: 3em;
}

main {
    display: grid;
    grid-gap: 1em;
    margin: 0 1em;
}

control {
    display: grid;
    grid-template-columns: max-content max-content max-content max-content max-content max-content;
    grid-template-rows: max-content max-content max-content max-content;
    grid-gap: 1em;
    justify-content: center;
}

#btn-run {
    grid-column: 1 / span 2;
}
#btn-stop {
    grid-column: 3 / span 2;
}
#btn-step {
    grid-column: 5 / span 2;
}

.btn-ctrl {
    font-size: 1.2em;
}
.input-ctrl {
    grid-column: 4 / span 3;   
    font-size: 1em;
}
control label {
    grid-column: 1 / span 3;
    text-align: right;
    font-size: 1em;
}
control label:after {
    content: ":";
}

tape {
    display: grid;
    grid-template-columns: repeat(auto-fill, 4.16em);
    grid-gap: 1px;
}

tape > div {
    background: #fff;
    width: 4.16em;
    height: 4.16em;
    text-align: center;
    line-height: 4.16em;
    outline: 1px dashed;
}

@media (min-width: 768px) {
    main {
        grid-template-columns: 2fr 1fr;
        grid-gap: 2em;
        max-width: 60em;
        margin: 0 auto;
    }
    tape {
        grid-column: 1 / -1;
    }
    control {
        order: 3;
        grid-template-columns: max-content max-content;
        grid-template-rows: max-content max-content max-content max-content max-content max-content;
    }
    .btn-ctrl {
        grid-column: 1 / -1 !important;
    }
    control label, .input-ctrl {
        grid-column: auto;
    }
    error {
        width: 30em;
    }
}

editor-frame {
    display: grid;
    grid-template-columns: 1fr 19fr;
    min-height: 500px;
}

line-numbers, textarea {
    margin: 0;
    padding: 0.5em;
}

line-numbers {
    background: #c5cca6;
    text-align: right;
}

textarea {
    overflow-x: scroll;
    font-size: 1em;
    border: none;
    resize: none;
    box-sizing: border-box;
    background: #f8ffd7;
}

textarea:focus {
    outline: 0px solid transparent;
}

button {
    display: inline-block;
    position: relative;
    overflow: hidden;
    padding: .5em 1em;
    text-decoration: none;
    background: transparent;
    border: 1px grey solid;
    border-radius: .25em;
    font-weight: 700;
    cursor: pointer;
    text-align: center;
    transition: background 250ms ease-in-out,
                transform 150ms ease;
    -webkit-appearance: none;
    -moz-appearance: none;
    -webkit-tap-highlight-color: rgba(0,0,0,0);
    -webkit-tap-highlight-color: transparent;
}

*:focus::-webkit-input-placeholder { opacity: 0; } /* Chrome <=56, Safari < 10 */
*:focus:-moz-placeholder { opacity: 0; } /* FF 4-18 */
*:focus::-moz-placeholder { opacity: 0; } /* FF 19-50 */
*:focus:-ms-input-placeholder { opacity: 0; } /* IE 10+ */
*:focus::placeholder { opacity: 0; } /* Modern Browsers */

button:hover {
    background: rgba(0, 0, 0, 0.04);
}

button:focus {
    background: rgba(0, 0, 0, 0.08);
    outline: none;
}

.ripple {
  border-radius: 50%;
  transform: scale(0);
  position: absolute;
}
.rippleEffect {
    animation: rippleDrop .6s linear;
}
@keyframes rippleDrop {
  100% {
    transform: scale(2);
    opacity: 0;
  }
}

error {
    position: fixed;
    background: #333;
    opacity: 0;
    color: white;
    max-width: 30em;
    width: 80%;
    left: 0;
    right: 0;
    bottom: 0;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 8px;
    border-radius: 4px;
    box-shadow: 0 3px 5px -1px rgba(0,0,0,.2), 
                0 6px 10px 0 rgba(0,0,0,.14), 
                0 1px 18px 0 rgba(0,0,0,.12);
}
.fadeScale {
    opacity: 1;
    animation: fadescale 150ms cubic-bezier(0,0,.2,1);
}
@keyframes fadescale {
    0% {
        opacity: 0;
        transform: scale(.5);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}
.fadeOut {
    opacity: 0;
    animation: fadeout 150ms cubic-bezier(0,0,.2,1);
}
@keyframes fadeout {
    0% {
        opacity: 1;
    }
    100% {
        opacity: 0;
    }
}

#message {
    padding: 14px 16px;
    white-space: pre-wrap;
    margin: 0;
}

#btn-err {
    float: right;
    font-size: 1em;
    margin-bottom: .5em;
    margin-right: .5em;
    border: none;
    color: #caae53;
    padding: .5em;
}

#btn-err:hover {
    background: rgba(202, 174, 83, 0.04);
}

#btn-err:focus {
    background: rgba(202, 174, 83, 0.16);
}

footer {
    text-align: center;
    margin: 2em auto;
}