cpu-emulator {
    background:none;
    border:none;
    bottom:auto;
    clear:none;
    cursor:default;
    float:none;
    font-size:medium;
    font-style:normal;
    font-weight:normal;
    height:auto;
    left:auto;
    letter-spacing:normal;
    line-height:normal;
    max-height:none;
    max-width:none;
    min-height:0;
    min-width:0;
    overflow:visible;
    position:static;
    right:auto;
    text-align:left;
    text-decoration:none;
    text-indent:0;
    text-transform:none;
    top:auto;
    visibility:visible;
    white-space:normal;
    z-index:auto;

    width: 850px;
    display: block;
}

.left-container {
    height: 100%;
    float: left;
}

.right-container {
    height: 100%;
    float: right;
}

/** Buttons **/
.button-container {
    margin-bottom: 10px;
}

.button-container > button {
    box-sizing: border-box;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    background-color: transparent;
    border: 2px solid #e74c3c;
    border-radius: 0.6em;
    color: #e74c3c;
    cursor: pointer;
    align-self: center;
    font-size: 1rem;
    font-weight: 400;
    line-height: 1;
    padding: 0.2em 0.8em;
    text-decoration: none;
    text-align: center;
    text-transform: uppercase;
    font-family: sans-serif;
    font-weight: 700;
    border-radius: 3em;
    border-color: #2ecc71;
    color: #2ecc71;
    background-image: linear-gradient(to bottom, transparent 50%, #2ecc71 50%);
    background-position: 0 0;
    background-size: 210% 3em;
    transition: background 150ms ease-in-out, color 150ms ease-in-out;
}

.active-running {
    box-sizing: border-box;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    background-color: transparent;
    border: 2px solid #e74c3c;
    border-radius: 0.6em;
    color: #e74c3c;
    cursor: pointer;
    align-self: center;
    font-size: 1rem;
    font-weight: 400;
    line-height: 1;
    padding: 0.2em 0.8em;
    text-decoration: none;
    text-align: center;
    text-transform: uppercase;
    font-family: sans-serif;
    font-weight: 700;
    border-radius: 3em;
    border-color: #2ecc71;
    color: white !important;
    background-image: linear-gradient(to bottom, transparent 0%, #2ecc71 0%) !important;
    background-position: 0% 0%;
    background-size: 210%;
    transition: background 150ms ease-in-out, color 150ms ease-in-out;
}

.disabled-running {
    box-sizing: border-box;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    background-color: transparent;
    border: 2px solid #e74c3c;
    border-radius: 0.6em;
    color: #e74c3c;
    cursor: pointer;
    align-self: center;
    font-size: 1rem;
    font-weight: 400;
    line-height: 1;
    padding: 0.2em 0.8em;
    text-decoration: none;
    text-align: center;
    text-transform: uppercase;
    font-family: sans-serif;
    font-weight: 700;
    border-radius: 3em;
    border-color: #b3b3b3 !important;
    color: white !important;
    background-image: linear-gradient(to bottom, transparent 0%, #cbcbcb 0%) !important;
    background-position: 0% 0%;
    background-size: 210%;
    transition: background 150ms ease-in-out, color 150ms ease-in-out;
}

.button-container > button:hover {
    color: #fff;
    background-position: 0 100%;
}



/** Code view **/

cpu-assembly {
    font-family: monospace;
    width: 350px;
    display: flex;
    flex-direction: column;
    order: 3;
    overflow-y: scroll;
    max-height: 605px;
}

cpu-assembly div:nth-child(2n) {
    background-color: aliceblue;
}

.code-line {
    display: flex;
    min-height: 20px;
    line-height: 20px;
}

.current-line {
    background-color: rgba(141, 219, 144, 0.5) !important;
}

.address {
    width: 3em;
    margin-right: 4px;
    border-width: 0;
    border-style: solid;
    border-right-width: 6px;
    background-color: #ececec;
    border-color: rgb(225, 225, 225);
}

.arrow {
    width: 0;
    height: 0;
    border-top: 10px solid transparent;
    border-bottom: 10px solid transparent;
    border-left: 10px solid rgba(141, 219, 144, 1);
    margin-left: -10px;
    display: none;
}

.current-line>.address {
    background-color: rgba(141, 219, 144, 1) !important;
}

.current-line>.arrow {
    display: block;
    border-left: 10px solid rgba(141, 219, 144, 1) !important;
}

.breakpoint {
    /*background-color: rgba(116, 215, 237, 0.5) !important;*/
}

.breakpoint>.arrow {
    display: block;
    border-left: 10px solid rgba(63, 153, 247, 1);
}

.breakpoint>.address {
    background-color: rgba(63, 153, 247, 1) !important;
    color: white;
}

.mnemonic {
    width: 50px;
    font-weight: bold;
    color: black;
}

.code-label {
    display: flex;
    min-height: min-content;
}

.label-name {
    margin-top: 20px;
}

.label-entrypoint {
    margin-top: 0;
}

.label-entrypoint, .label-name {
    color: #6e6e6e;
    font-weight: bold;
}

.op_str-label {
    color: #6e6e6e;
    font-weight: bold;
}

.op_str-register {
    color: #e74c3c;
}

.op_str-number {
    color: blue;
}

/** Registers **/

cpu-registers {
    display: flex;
    flex-wrap: wrap;
    font-family: monospace;
    font-size: 18px;
    margin-top: 5px;
    margin-bottom: 10px;
    width: 500px;
}

cpu-register {
    margin-top: 10px;
    margin-right: 10px;
}

.reg-name {
    background-color: #575757;
    border-top-left-radius: 3px;
    border-bottom-left-radius: 3px;
    color: white;
    padding: 2px;
}

.reg-value {
    padding: 2px;
    background-color: #b3d8e9;
    border-bottom-right-radius: 3px;
    border-top-right-radius: 3px;
}

/** Memory **/

cpu-memory {
    display: flex;
    flex-wrap: wrap;
    font-family: monospace;
    width: 416px;
    border-radius: 5px;
    margin-left: 10px;
}

.byte {
    height: 50px;
    width: 50px;
    margin-left: 2px;
    margin-bottom: 2px;
    background-color: #b3d8e9;
}


.byte:first-child {
    border-top-left-radius: 5px;
}

.byte:nth-child(8) {
   border-top-right-radius: 5px;
}

.byte:nth-last-child(8) {
    border-bottom-left-radius: 5px;
}

.byte:last-child {
    border-bottom-right-radius: 5px;
}

.ascii-byte {
    font-family: sans-serif;
    text-align: center;
    font-size: 14px;
    font-weight: bold;
    height: 16px;
}

.hex-byte {
    text-align: right;
    margin-right: 2px;
}

.hex-byte::before {
    content: "0x";
    font-size: 10px;
    color: #525252;
}

.mem-address::before {
    content: "0x";
    font-size: 10px;
    color: #525252;
}

.mem-address {
    border-bottom-width: 1px;
    border-bottom-style: solid;
    border-bottom-color: white;
}

.byte span {
    display: block;
}

/** Console **/

emulator-console {
    display: flex;
    position: relative;
    background-color: black;
    color: white;
    font-family: monospace;
    font-size: 18px;
    width: 500px;
    height: 200px;
}

.console-window {
    font-size: 14px;
    border: 0;
    resize: none;
    box-shadow: none;
}

textarea { outline: none; }