body {
    margin: 0 auto;    
    font-family: Courier New,Courier,Lucida Sans Typewriter,Lucida Typewriter,monospace;
}

.editor {
    /*box-shadow: 0 2px 2px 0 rgba(0, 0, 0, 0.14), 0 1px 5px 0 rgba(0, 0, 0, 0.12), 0 3px 1px -2px rgba(0, 0, 0, 0.2);*/
    border: 1px solid grey;
    font-family: 'Source Code Pro', monospace;
    font-size: 14px;
    font-weight: 400;
    min-height: 340px;
    height: auto;
    letter-spacing: normal;
    line-height: 20px;
    padding: 10px;
    resize: none !important;
    tab-size: 4;
}

#header {
    width: 100%;
    height: 150px;
    display: grid;
    grid-template-columns: auto;
    justify-content: center;
    align-items: center;
}

#logo {
    color: #ababab;    
    font-family: Courier New,Courier,Lucida Sans Typewriter,Lucida Typewriter,monospace;
    font-size: 42px;
    font-weight: bold;
    text-align: center;
    height: 50px;
}

#bender {
    height: 100px;
}

#nojs-warning {
    width: 100%;
    height: 30px;
    display: flex;
    justify-content: center;
    align-items: center;
    background: #eeaaaa;
    color: white;
}

#no-cookies-warning {
    width: 100%;
    height: 30px;
    display: flex;
    justify-content: center;
    align-items: center;
    background: #eeaaaa;
    color: white;   
}

#footer {
    width: 100%;
    height: 50px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    color: #505050;    
    font-family: Courier New,Courier,Lucida Sans Typewriter,Lucida Typewriter,monospace;
    font-size: 10px;
}

#content {
    width: 800px;
    margin: 0 auto;
    font-family: Courier New,Courier,Lucida Sans Typewriter,Lucida Typewriter,monospace;
}

/*
    SASM
*/

#sasm_control_area {
    display: flex;
    flex-direction: row;
    justify-content: center;
    margin: 20px;
}

#errors_area {
    margin-top: 20px;
    margin-bottom: 20px;
}

.error_line {
    margin: 1px auto;
    color: red;
    font-family: Courier New,Courier,Lucida Sans Typewriter,Lucida Typewriter,monospace;
}

/*
    SCPU
*/

#scpu_area {
    display: none;
}

#scpu_vm_area {
    display: grid;
    grid-template-columns: auto auto;
    justify-items: center;
    align-items: center;
    font-family: Courier New,Courier,Lucida Sans Typewriter,Lucida Typewriter,monospace;
    margin: 20px;
}

#scpu_control_area {
    display: grid;
    grid-template-columns: auto 160px 170px 160px auto;
    justify-items: center;
    align-items: center;
    margin: 20px;
}

/*
    SCPU error box
*/

#scpu-error {
    display: none;
    position: fixed;
    left: 50%;
    top: 50%;
    width: 500px;
    height: 100px;
    transform: translate(-50%, -50%);
    background: #ff3333;
    outline: 1px solid white;
    outline-offset: -10px;
}

#scpu-error-title {
    position: relative;
    top: 5px;
    left:50%;
    transform: translate(-50%, -5px);
    width: 200px;
    height: 20px;
    background: #ff3333;
    color: white;
    text-align: center;
}

#scpu-error-message {
    position: relative;
    width: 400px;
    height: 50px;
    line-height: 50px;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -80%);
    background: #ff3333;
    color: white;
    text-align: center;
}

/*
    SCPU regs
*/

#scpu_regs_area {
    display: grid;
    grid-template-columns: 40px auto;
    justify-items: start;
    align-items: center;
    row-gap: 4px;
}

.scpu_reg {
    grid-template-columns: repeat(8, 25px);
    border: 1px solid #ababab;
    display: grid;
}

.scpu_reg_bit {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 25px;    
}

.scpu_reg_label {
    display: flex;
    align-items: center;
    font-weight: bold;
    color: #505050;
    height: 25px;
}

/*
    SCPU mem
*/

#scpu_mem_area {
    display: grid;
    grid-gap: 2px;
    grid-template-columns: repeat(17, 25px);
    grid-template-rows: repeat(17, 25px);
    justify-items: center;
    align-items: center;
}

.scpu_mem_header {
    display: flex;
    justify-content: center;
    align-items: center;
    color: blue;
}

.scpu_mem_cell {
    display: flex;
    justify-content: center;
    align-items: center;
}

/*
    Buttons
*/

.button {
    width: 150px;
    padding: 8px 30px;
    border: 1px solid #ababab;
    margin: 5px;    
    font-family: arial;
    color: #505050;
    text-decoration: none;
    transition: background .1s linear, color .1s linear;
}

.button:hover {
    background-color: #ababab;
    color: white;
}

.button:disabled {
    background-color: #ffffff;
    color: #cccccc;
}

.button:focus {
    outline: none;
}

#scpu-speed {
    color: #efefef;
    font-size: 10px;
    cursor: pointer;
}

/*
    Help
*/

.fixed {
    font-family: 'Source Code Pro', monospace;
    font-size: 14px;
    color: #333333;
}

.fixed-code {
    font-family: Courier New,Courier,Lucida Sans Typewriter,Lucida Typewriter,monospace;
    font-size: 14px;
    color: #333333;
}

h1 {
    background-color: #ababab;
    color: #ffffff;
    font-size: 20px;
    height: 30px;
    display: flex;
    align-items: center;
    padding-left: 20px;
    margin-top: 25px;
}

h2 {
    font-size: 15px;
    height: 30px;
    display: flex;
    align-items: center;
    padding-left: 20px;
    margin-top: 15px;
}

.scpu-reg {
    background-color: #88ddff;
    font-family: Courier New,Courier,Lucida Sans Typewriter,Lucida Typewriter,monospace;
    font-weight: bold;
}

.scpu-instr {
    background-color: #cccccc;
    font-family: Courier New,Courier,Lucida Sans Typewriter,Lucida Typewriter,monospace;
    font-weight: bold;

}

.sasm-code {
    background-color: #eebbff;
    font-family: Courier New,Courier,Lucida Sans Typewriter,Lucida Typewriter,monospace;
    font-weight: bold;
}

code {
  display: block;
  white-space: pre-wrap;
  margin-top: 10px;
}

.code-ok {
    background-color: #eeffee;
}

.code-notok {
    background-color: #ffeeee;
}
