body {
    font-size: 16px;
}
button {
    font-size: 1em;
}
input {
    font-size: 1em;
}
textarea {
    font-size: 1em;
}

.wholepage {
    display: flex;
    height: 100%;
}

/* side-bar */

.sidebar {
    height: 100%;
    display: none;
}

.consolepanel {
    height: 100%;
    width: 10em;
    background-color: yellow;
}

/* workspaces */

.workspace {
    display: flex;
    flex-direction: column;
    height: 100%;
    margin: 0 10px;
}

.workspacebar {
    width: 100%;
}

.workspace .panelcontainer {
    display: flex;
    flex-grow: 1;
    flex-shrink: 1;
    overflow-y: hidden;
}

.panel {
    display: flex;
    flex-direction: column;
    width: 45em;
    margin: 5px;
    box-shadow: 0 0 3px #ccc;
    /* border: solid 1px #ccc; */
    border-radius: 10px;
    padding: 5px 10px;
    overflow-y: scroll;
}
  
.compact.itemcard {
    max-height: 100px;
    overflow: hidden;
    flex-grow: 0;
    flex-shrink: 0;
    background-color: white;
}

.hidden {
    display: none;
}

.itemcard {
    background-color: #f7f7f7;
    margin: 5px 0px;
    box-shadow: 1px 1px 5px #ccc;
    border-radius: 5px;
    padding: 5px;
    flex-shrink: 0;
}

.entityview {
    min-height: 2em;
}

.editor > textarea {
    width: 100%;
    height: 5em;
}

.tag, .key, .inferred_tag, .ref_count {
    padding: 0 2px;
    margin: 0 2px;
    line-height: 1.3;
    font-family: monospace;
    font-size: 0.6em;
}

.ref_count::before {
    content: "ref:";
}
.ref_count {
    border: 1px solid;
    border-radius: 3px;
    color: green;
}

.mention {
    padding: 0 2px;
    margin: 0 2px;
    font-family: monospace;
    font-size: 0.9em;
}

.inferred_tag {
    color: #aaaaaa;
}
.key {
    background-color: #777;
    color: #fff;
    padding: 3px;
}
.tag::before {
    content: "#"
}
.inferred_tag::before {
    content: "{"
}
.inferred_tag::after {
    content: "}"
}
.mention::before {
    content: "@"
}
.compact.itemcard .inferred_tag {
    display: none;
}

.tag:hover, .inferred_tag:hover, .mention:hover, .key:hover {
    color: #eeeeee;
    background-color: #777777;
}

.name {
    font-weight: bold;
    font-size: 1.2em;
    padding-bottom: 0.5em;
}

.trait {
    margin: 0.2em;
}
.trait_label {
    font-size: 0.6em;
    font-family: monospace;
}
.trait_label::after {
    content: ': ';
}

.alias {
    font-style: italic;
}
.alias::before {
    content: ' / '
}

/* tags with style */
.tag_todo {
    color: #ff7777;
    background-color: #ffddee;
}
.tag_todo:hover {
    color: #ffddee;
    background-color: #ff7777;
}

.tag_done {
    color: #559955;
    background-color: #eeffee;
}
.tag_done:hover {
    color: #eeffee;
    background-color: #559955;
}

.cursor {
    box-shadow: 0 0 7px orange;
}

#debug {
    overflow-y: auto;
    max-height: 100px;
    width: 100%;
}

/* CSS for mobile device */
/*
@media only screen and (max-device-width: 900px) {
    body {
        font-size: 4vw;
    }
}
*/

.status_bar {
    font-family: monospace;
    font-size: 0.8em;
}

h1, h2, h3, h4 {
    font-weight: bold;
}

h1 {
    font-size: 1.2em;
}
h2 {
    font-size: 1.1em;
}
h3 {
    font-size: 1.05em;
}
h4 {
    font-size: 1em;
}

h1::before {
    content: '#';
    color: lightgray;
    padding-right: 0.2em
}
h2::before {
    content: '##';
    color: lightgray;
    padding-right: 0.2em
}
h3::before {
    content: '###';
    color: lightgray;
    padding-right: 0.2em
}
h4::before {
    content: '####';
    color: lightgray;
    padding-right: 0.2em
}

/* sidebar and tabs */
.sidebar {
    display: flex;
    flex-direction: column;
    width: 20em;
    margin: 5px;
    padding: 5px 10px;
    overflow-y: scroll;
}
.tabcontent {
    display: none;
}
.tab {
    overflow: hidden;
}
  
/* Style the buttons inside the tab */
.tab button {
    background-color: inherit;
    float: left;
    border: none;
    outline: none;
    padding: 4px;
    transition: 0.3s;
}
  
/* Change background color of buttons on hover */
.tab button:hover {
    background-color: #ddd;
}
  
/* Create an active/current tablink class */
.tab button.active {
    background-color: #ccc;
}

/* =============================
* Right panel
* =============================
*/
.right .itemcard {
    background-color: #fff;
    border: #eee solid 1px;
    color: #777;
    box-shadow: none;
}

.itemcard.compact {
    max-height: 150px;
    overflow: hidden;
    flex-grow: 0;
    flex-shrink: 0;
}

.right .key{
    background-color: #fff;
    color: #777;
    padding: 3px;
    text-decoration: underline;
}

.right .tag{
    background-color: #fff;
    color: #777;
    padding: 3px;
    text-decoration: underline;
}

.right .ref_count {
    border: 1px solid;
    border-radius: 3px;
    color: #777;
}
