
:root {
    --background-color: white;
    --secondary-background-color: #f5f5f5;
    --tetriary-background-color: #a8a8a8;
    --border-color: #aaa;
    --text-color: #333;
    --selected-color: #B7E1CD;
    
    --hover-background-color: #e6e6e6;
    --hover-text-color: #262626;
    --hover-selected-color: #AED6C3;
    
    --background-image: linear-gradient(rgba(0, 0, 0, 0.1), rgba(0, 0, 0, 0.1)), url("assets/img/propertythingy_light_compressed.jpg") no-repeat center center fixed;
    --expand-btn-background-color: #ddd;
    --about-background-color: rgba(255, 255, 255, 0.856);
    --highlight-color: yellow;
}

@media (prefers-color-scheme: dark) {
    /* Must be duplicated to below */
    :root:not([data-theme="light"]) {
        --background-color: #111;
        --secondary-background-color: #1f1f1f;
        --tetriary-background-color: #5c5c5c;
        --border-color: #444;
        --text-color: #d9d9d9;
        --selected-color: hsl(151, 30.75%, 25%);
        
        --hover-background-color: #282828;
        --hover-text-color: #eee;
        --hover-selected-color: hsl(151, 25%, 30%);
        
        --background-image: url("assets/img/propertythingy_dark_compressed.jpg") no-repeat center center fixed;;
        --expand-btn-background-color: #333;
        --about-background-color: rgba(0, 0, 0, 0.6);
        --highlight-color: #880;
    }
}
/* Duplicated from above^ */
:root[data-theme="dark"] {
    --background-color: #111;
    --secondary-background-color: #1f1f1f;
    --tetriary-background-color: #5c5c5c;
    --border-color: #444;
    --text-color: #d9d9d9;
    --selected-color: hsl(151, 30.75%, 25%);
    
    --hover-background-color: #282828;
    --hover-text-color: #eee;
    --hover-selected-color: hsl(151, 25%, 30%);
    
    --background-image: url("assets/img/propertythingy_dark_compressed.jpg") no-repeat center center fixed;;
    --expand-btn-background-color: #333;
    --about-background-color: rgba(0, 0, 0, 0.6);
    --highlight-color: #880;
}

body {
    /* padding-bottom: 70px; */
    font-family: 'Montserrat', sans-serif;
    background: var(--background-image);
    -webkit-background-size: cover;
    -moz-background-size: cover;
    -o-background-size: cover;
    background-size: cover;
    height: 100vh;
    overflow-x: auto;
    color: var(--text-color);
}

#about-body {
    background-color: var(--about-background-color);
    padding: 10px 5px 5px 5px;
    margin: 5px;
}

.navbar {
    background: transparent;
    border-color: transparent;
    margin-bottom: 0;
}

.navbar-default .navbar-toggle .icon-bar {
    background-color: white;
}

.navbar-nav > li > a.navbar-item {
    color: white;
    text-shadow: 1px 1px 5px black;
    font-weight: 500;
    font-size: 20px;
}

.navbar-nav > li > a.navbar-disabled {
    color: #a8a8a8;
    text-decoration: underline;
}

.navbar-nav > li > a.navbar-item:hover {
    color: white;
    text-decoration: underline;
}

.navbar-nav > li > a.navbar-item.navbar-disabled:hover {
    color: #a8a8a8;
}
@media (max-width: 768px) {
    .nav>li>a {
        padding: 10px 25px;
    }
}

.vertical-divider {
    height: 40px;
    width: 2px;
    margin: 5px 9px;
    background-color: white;
    box-shadow: 1px 1px 5px black;
}

.horizontal-divider, hr {
    height: 1px;
    /* margin: 9px 0; */
    overflow: hidden;
    background-color: white;
    box-shadow: 0 0 5px black, 1px 1px 2px black;
}
#dark-mode-toggle>img {
    height: 20px;
    width: 20px;
    image-rendering: pixelated;
}

h1, h2, h3 {
    color: white;
    text-shadow: 0 0 5px black, 2px 2px 3px black;
}

:is(h1, h2, h3).card-text {
    color: var(--text-color);
    text-shadow: none;
}

h1 {
    font-size: 40px;
}

h2 {
    font-size: 35px;
}

h3 {
    font-size: 30px;
}
.about-text, .written-list {
    font-size: 22px;
}
.written-list:not(.compact-list)>li {
    margin: 10px 40px 0 0;
}

a {
    color: #2f90e6;
}

a:hover {
    color: #05447c;
}

.popup-panel {
    width: fit-content;
    margin: 10px auto;
    border-color: var(--border-color);
}
.popup-panel>.panel-heading {
    color: var(--text-color);
    background-color: var(--secondary-background-color);
    border-color: var(--border-color);
    font-size: 20px;
    width: 100%;
}
.popup-panel>.panel-body {
    font-size: 16px;
    background-color: var(--background-color);
}
.panel-body>ul {
    padding-inline-start: 0;
}

.modal-content {
    background-color: var(--background-color);
    color: var(--text-color);
    border-color: var(--border-color);
}
.modal-footer>button.btn-secondary {
    background-color: var(--background-color);
    color: var(--text-color);
    border-color: var(--border-color);
}

.select-option, .selection-category {
    font-size: 14px;
    padding: 6px 16px !important;
    margin: 0;
}

.select-category-description {
    font-size: 14px;
    font-style: italic;
    padding: 10px 10px !important;
    margin: 0;
    color: var(--text-color);
    background-color: var(--secondary-background-color);
}

.dropdown-actions {
    padding: 0 0 5px;
}

.selected {
    background-color: var(--selected-color);
}

.selected:hover {
    background-color: var(--hover-selected-color) !important;
}

#search {
    margin: 6px;
    width: 100%;
}
.search, .form-control {    
    color: var(--text-color);
    background-color: var(--background-color);
    border-color: var(--border-color);
}

@media (min-width: 768px) {
    #search {
        width: 400px;
    }
}

.col-sm-12, .container-fluid {
    padding: 0;
}

.results {
    max-width: fit-content;
    margin: auto;
    padding: 0;
    display: flex;
    align-items: center;
    /* overflow-x: auto; */
    height: 100%;
    flex-grow: 1;
}

#output-table {
    width: fit-content;
    align-items: center;
    margin-bottom: 10;
    background-color: var(--background-color);
    filter: drop-shadow(0px 0px 4px gray);
    @media (prefers-color-scheme: dark) {
        filter: drop-shadow(0px 0px 4px black);
    }
}

#output-table > * > * > td, .table.nested-table > * > * > td {
    padding: 4px 6px;
    background-color: var(--background-color);
}

li {
    list-style-position: inside;
}

.table-header {
    display: flex;
    justify-content: space-between;
    text-decoration: none;
    color: var(--text-color);
    background-color: var(--secondary-background-color);
    margin: 0 auto;
    padding: 6px 8px;
    height: 100%;
    /* cursor: progress; */
}
a.table-header {
    cursor: pointer;
}

a.table-header:hover {
    text-decoration: none;
    color: #666;
}

#output-table>tbody>tr>td:first-child {
    text-align: center;
}
th:first-child>*>* {
    justify-content: center;
    padding-left: 0;
    padding-right: 0;
}

.noselect {
    -webkit-touch-callout: none; /* iOS Safari */
    -webkit-user-select: none; /* Safari */
    -khtml-user-select: none; /* Konqueror HTML */
    -moz-user-select: none; /* Old versions of Firefox */
    -ms-user-select: none; /* Internet Explorer/Edge */
    user-select: none;
    /* Non-prefixed version, currently supported by Chrome, Edge, Opera and Firefox */
}

.justify-start {
    margin-right: auto;
}

.dropdown-scrollable {
    max-height: 50vh;
    overflow-y: auto;
}

.dropdown-scrollable > li > a:focus, .dropdown-scrollable > li > a:hover {
    color: var(--text-color);
    text-decoration: none;
    background-color: var(--secondary-background-color);
}

.dropdown-scrollable > li > a {
    display: block;
    padding: 3px 20px;
    clear: both;
    font-weight: 400;
    line-height: 1.42857143;
    color: var(--text-color);
    white-space: nowrap;
}

.dropdown-option {
    display: flex !important;
    justify-content: space-between;
}

.dropdown-option > .glyphicon-ok, .icons {
    margin-left: 10px;
    white-space: nowrap;
}

.modify-filter {
    padding: 3px 15px !important;
}

.dropdown-menu {
    min-width: 21.1rem; /* To match with the width of buttons, this weird width is required */
    background-color: var(--background-color);
}

.dropdown-menu > p {
    line-height: 1.42857143;
    font-weight: normal;
    padding: 3px 15px;
    margin: 0;
}

.dropdown-submenu {
    position: relative;
}

.dropdown-submenu > .dropdown-menu {
    top: 0;
    left: 100%;
    min-width: 250px;
    margin-top: -6px;
    margin-left: -1px;
    -webkit-border-radius: 0 6px 6px 6px;
    -moz-border-radius: 0 6px 6px;
    border-radius: 0 6px 6px 6px;
}

.dropdown-submenu:hover > .dropdown-menu,
.dropdown-submenu.open > .dropdown-menu {
    display: block;
}

.dropdown-menu > li.dropdown-submenu.open > a {
    background-color: var(--secondary-background-color);
}

.dropdown-submenu > a:after {
    display: block;
    content: " ";
    float: right;
    width: 0;
    height: 0;
    border-color: transparent;
    border-style: solid;
    border-width: 5px 0 5px 5px;
    border-left-color: var(--border-color);
    margin-top: 5px;
    margin-right: -10px;
}

.dropdown-submenu:hover > a:after {
    border-left-color: #000;
}

.dropdown-submenu.pull-left {
    float: none;
}

.dropdown-submenu.pull-left > .dropdown-menu {
    left: -100%;
    margin-left: 10px;
    -webkit-border-radius: 6px 0 6px 6px;
    -moz-border-radius: 6px 0 6px 6px;
    border-radius: 6px 0 6px 6px;
}

.dropdown-menu>li>a,
.custom-submenu>li>a {
    color: var(--text-color);
}
.dropdown-menu>li>a:hover,
.custom-submenu>li>a:hover {
    color: var(--hover-text-color);
    background-color: var(--hover-background-color);
}

.dropdown-menu>li>a.description-button,
.custom-submenu>li>a.description-button {
    color: var(--text-color);
}

.dropdown-menu > .divider,
.custom-submenu > .divider {
    background-color: var(--border-color);
}

.custom-collapsible {
    display: none;
    opacity: 0;
    max-height: 0;
    border-left: #ccc 1px solid;
}

.custom-submenu > ul {
    margin-left: 1.5rem;
}

.custom-submenu a {
    color: var(--text-color);
    overflow: hidden;
    white-space: nowrap;
    display: block;
}

.custom-submenu a:hover {
    text-decoration: none;
    background: var(--hover-background-color);
}

.dot {
    height: 18px;
    width: 18px;
    border-radius: 50%;
    display: inline-block;
    margin-left: -2px;
    margin-right: 3px;
}

.sprite {
    display: inline-block;
    vertical-align: text-top;
    height: 16px;
    width: 16px;
    background-repeat: no-repeat;
    image-rendering: pixelated;
}

.block-sprite {
    background-image: url(assets/img/BlockCSS.png);
}
.block-sprite2 {
    background-image: url(assets/img/BlockCSS2.png);
}
.block-sprite3 {
    background-image: url(assets/img/BlockCSS_1.20.png);
}

.entity-sprite {
    background-image: url(assets/img/EntityCSS.png);
}

.item-sprite {
    background-image: url(assets/img/ItemCSS.png);
}

.unicolor-block-sprite {
    background-image: url(assets/img/UnicolorBlockCSS.png);
}

.search-highlight {
    background-color: var(--highlight-color);
}

.display-none {
    display: none !important;
}

.user-select-all {
    -webkit-touch-callout: all;
    -webkit-user-select: all;
    -khtml-user-select: all;
    -moz-user-select: all;
    -ms-user-select: all;
    user-select: all;
}

.user-select-text {
    -webkit-touch-callout: text;
    -webkit-user-select: text;
    -khtml-user-select: text;
    -moz-user-select: text;
    -ms-user-select: text;
    user-select: text;
}

.icons {
    align-self: center;
}

.table-bordered > tbody > tr > td,
.table-bordered > thead > tr > th,
.table-bordered {
    border-color: var(--border-color);
}

th {
    background-color: var(--secondary-background-color);
    border-bottom-width: 0 !important;
    box-shadow: inset 0 -1px 0 var(--border-color);
    padding: 2px 0 !important;
    position: sticky;
    top: -1px;
    /* z-index: 2; */
}

/* Conditional formatting: */
.cf-yes         { background-color: #B7E1CD !important; }
.cf-no          { background-color: #F4C7C3 !important; }
.cf-neutral     { background-color: #FCE8B2 !important; }
.cf-neutral-yes { background-color: #DDE6BA !important; }
.cf-neutral-no  { background-color: #F9D9B8 !important; }
.cf-invalid     { background-color: #CCC !important; }

@media (prefers-color-scheme: dark) {
    
    .cf-yes         :not([data-theme="light"]) { background-color: hsl(151, 30.75%, 25%) !important; }
    .cf-no          :not([data-theme="light"]) { background-color: hsl(5, 51.75%, 25%) !important; }
    .cf-neutral     :not([data-theme="light"]) { background-color: hsl(44, 69.75%, 25%) !important; }
    .cf-neutral-yes :not([data-theme="light"]) { background-color: hsl(72, 35.25%, 25%) !important; }
    .cf-neutral-no  :not([data-theme="light"]) { background-color: hsl(30, 63%, 25%) !important; }
    .cf-invalid     :not([data-theme="light"]) { background-color: hsl(0, 0%, 25%) !important; }
}

[data-theme="dark"] {
    .cf-yes         { background-color: hsl(151, 30.75%, 25%) !important; }
    .cf-no          { background-color: hsl(5, 51.75%, 25%) !important; }
    .cf-neutral     { background-color: hsl(44, 69.75%, 25%) !important; }
    .cf-neutral-yes { background-color: hsl(72, 35.25%, 25%) !important; }
    .cf-neutral-no  { background-color: hsl(30, 63%, 25%) !important; }
    .cf-invalid     { background-color: hsl(0, 0%, 25%) !important; }
}

.dot.NONE                   { background-color: rgb(0, 0, 0) !important }
.dot.GRASS                  { background-color: rgb(127, 178, 56) !important }
.dot.SAND                   { background-color: rgb(247, 233, 163) !important }
.dot.WOOL                   { background-color: #C7C7C7 !important }
.dot.FIRE                   { background-color: #FF0000 !important }
.dot.ICE                    { background-color: #A0A0FF !important }
.dot.METAL                  { background-color: #A7A7A7 !important }
.dot.PLANT                  { background-color: rgb(0, 124, 0) !important }
.dot.SNOW                   { background-color: #FFFFFF !important }
.dot.CLAY                   { background-color: rgb(164, 168, 184) !important }
.dot.DIRT                   { background-color: rgb(151, 109, 77) !important }
.dot.STONE                  { background-color: #707070 !important }
.dot.WATER                  { background-color: #4040FF !important }
.dot.WOOD                   { background-color: rgb(143, 119, 72) !important }
.dot.QUARTZ                 { background-color: #FFFCF5 !important }
.dot.COLOR_ORANGE           { background-color: rgb(216, 127, 51) !important }
.dot.COLOR_MAGENTA          { background-color: rgb(178, 76, 216) !important }
.dot.COLOR_LIGHT_BLUE       { background-color: rgb(102, 153, 216) !important }
.dot.COLOR_YELLOW           { background-color: #E5E533 !important }
.dot.COLOR_LIGHT_GREEN      { background-color: rgb(127, 204, 25) !important }
.dot.COLOR_PINK             { background-color: rgb(242, 127, 165) !important }
.dot.COLOR_GRAY             { background-color: #4C4C4C !important }
.dot.COLOR_LIGHT_GRAY       { background-color: #999999 !important }
.dot.COLOR_CYAN             { background-color: rgb(76, 127, 153) !important }
.dot.COLOR_PURPLE           { background-color: rgb(127, 63, 178) !important }
.dot.COLOR_BLUE             { background-color: rgb(51, 76, 178) !important }
.dot.COLOR_BROWN            { background-color: rgb(102, 76, 51) !important }
.dot.COLOR_GREEN            { background-color: rgb(102, 127, 51) !important }
.dot.COLOR_RED              { background-color: #993333 !important }
.dot.COLOR_BLACK            { background-color: #191919 !important }
.dot.GOLD                   { background-color: rgb(250, 238, 77) !important }
.dot.DIAMOND                { background-color: rgb(92, 219, 213) !important }
.dot.LAPIS                  { background-color: rgb(74, 128, 255) !important }
.dot.EMERALD                { background-color: rgb(0, 217, 58) !important }
.dot.PODZOL                 { background-color: rgb(129, 86, 49) !important }
.dot.NETHER                 { background-color: #700200 !important }
.dot.TERRACOTTA_WHITE       { background-color: rgb(209, 177, 161) !important }
.dot.TERRACOTTA_ORANGE      { background-color: rgb(159, 82, 36) !important }
.dot.TERRACOTTA_MAGENTA     { background-color: rgb(149, 87, 108) !important }
.dot.TERRACOTTA_LIGHT_BLUE  { background-color: rgb(112, 108, 138) !important }
.dot.TERRACOTTA_YELLOW      { background-color: rgb(186, 133, 36) !important }
.dot.TERRACOTTA_LIGHT_GREEN { background-color: rgb(103, 117, 53) !important }
.dot.TERRACOTTA_PINK        { background-color: rgb(160, 77, 78) !important }
.dot.TERRACOTTA_GRAY        { background-color: #392923 !important }
.dot.TERRACOTTA_LIGHT_GRAY  { background-color: rgb(135, 107, 98) !important }
.dot.TERRACOTTA_CYAN        { background-color: #575C5C !important }
.dot.TERRACOTTA_PURPLE      { background-color: rgb(122, 73, 88) !important }
.dot.TERRACOTTA_BLUE        { background-color: rgb(76, 62, 92) !important }
.dot.TERRACOTTA_BROWN       { background-color: rgb(76, 50, 35) !important }
.dot.TERRACOTTA_GREEN       { background-color: rgb(76, 82, 42) !important }
.dot.TERRACOTTA_RED         { background-color: rgb(142, 60, 46) !important }
.dot.TERRACOTTA_BLACK       { background-color: rgb(37, 22, 16) !important }
.dot.CRIMSON_NYLIUM         { background-color: rgb(189, 48, 49) !important }
.dot.CRIMSON_STEM           { background-color: rgb(148, 63, 97) !important }
.dot.CRIMSON_HYPHAE         { background-color: rgb(92, 25, 29) !important }
.dot.WARPED_NYLIUM          { background-color: rgb(22, 126, 134) !important }
.dot.WARPED_STEM            { background-color: rgb(58, 142, 140) !important }
.dot.WARPED_HYPHAE          { background-color: rgb(86, 44, 62) !important }
.dot.WARPED_WART_BLOCK      { background-color: rgb(20, 180, 133) !important }
.dot.DEEPSLATE              { background-color: #646464 !important }
.dot.RAW_IRON               { background-color: rgb(216, 175, 147) !important }
.dot.GLOW_LICHEN            { background-color: rgb(127, 167, 150) !important }

td.numeric-cell {
    text-align: right;
}

.nested-table {
    margin-bottom: 0;
    width: 100%;
    /* border-collapse: collapse;
    border-style: hidden; */
}

.nested-cell {
    height: auto;
    padding: 0 !important;
}

td .nested-table {
    width: 100%;
    white-space: nowrap
}

.nested-table:not(.preview-table) > tbody > tr > td:last-child {
    width: 22px;
    /* text-align: right; */
    white-space: nowrap;
}

.expand-btn {
    color: var(--text-color);
    /* background-color: #A3D6FC; */
    background-color: var(--expand-btn-background-color);
    border-color: var(--border-color);
    cursor: pointer;
}
.expand-btn:hover {
    color: var(--hover-text-color);
}

table.table.expand-btn {
    width: fit-content;
}
table.table.expand-btn>tbody>tr>td {
    padding: 4px 6px 3px 6px;
    background-color: var(--expand-btn-background-color);
}

.settings {
    margin: 3px;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
}

.settings-box {
    min-width: fit-content;
    margin: 5px;
    padding: 7px;
    background-color: var(--secondary-background-color);
    box-shadow: 0 0 4px black;
    height: fit-content;
}

.settings-box > p {
    color: var(--text-color);
    text-shadow: none;
    font-size: 24px;
}

.settings-box > button,
.settings-box > .btn-group,
.settings-box > a {
    border-radius: 4px;
    box-shadow: 1px 1px 4px rgba(47, 47, 47, 0.828);
}

.btn-default {
    background-color: var(--background-color);
    color: var(--text-color) !important;
    border-color: var(--border-color);
}
.btn-default:hover,
.btn-default.active,
.btn-default:focus,
.open>.dropdown-toggle.btn-default {
    background-color: var(--hover-background-color) !important;
}

#scrollButton {
    display: none;
    position: fixed;
    bottom: 30px;
    right: 40px;
    z-index: 99;
    border: var(--border-color);
    background-color: var(--background-color);
    color: var(--tetriary-background-color);
    cursor: pointer;
    width: 50px;
    height: 50px;
    border-radius: 25px;
    font-size: 30px;
    box-shadow: 1px 1px 4px rgba(47, 47, 47, 0.828);
}

#scrollButton:hover {
    background-color: var(--hover-background-color);
}

/* Scrollbar Deco */
::-webkit-scrollbar {
    width: 0.8em;
}

::-webkit-scrollbar-track {
    background: var(--background-color);

}

::-webkit-scrollbar-thumb {
    background: var(--tetriary-background-color);
    border-radius: 90vw;
    border: 2px solid var(--background-color);
}

html {
    scroll-behavior: smooth;
}
