/*********
** Main layout
*********/
#content {
    max-width: 100%;
}

caption {
    text-align: left;
    padding-top: 2px;
}

#output {
    padding: 10px;
    overflow: auto;
}

#output h2 {
    margin: -10px 0 10px -10px;
}

#output table {
    font-family: monospace;
}

table caption {
    font-weight: bold;
}

/*********
** Result banner
*********/
.banner {
    border: 2px solid gray;
    border-radius: 5px;
    margin-top: 1em;
    padding: 1em;
}

.banner.success {
    border-color: green;
    background: #CFC;
}

.banner.error {
    border-color: red;
    background: #FCC;
}

.save-metadata {
    margin-top: 1em;
    font-size: 0.8em;
    opacity: 0.3;
}

/*********
** Log metadata & filters
*********/
.table, #filters {
    border-bottom: 1px dashed #888888;
    margin-bottom: 5px;
}

#metadata th {
    text-align: right;
    padding-right: 0.7em;
}

.table {
    border: 1px solid #000000;
    background: #ffffff;
    border-radius: 5px;
    border-spacing: 1px;
    overflow: hidden;
    cursor: default;
    box-shadow: 1px 1px 1px 1px #dddddd;
}

.mod-entry {
    height: 1.8em;
}

.table > caption {
    min-height: 1.3em;
}

#fix-list {
    margin-bottom: 2em;
}

#updates {
    min-width: 10em;
}

#mods {
    min-width: 400px;
}

#mods .color-red {
    color: red;
}

#mods .color-green {
    color: green;
}

#mods tr {
    cursor: pointer;
}

#mods.filters-disabled tr {
    cursor: default;
}

.table tr {
    background: #eee;
}

#mods span.notice {
    font-weight: normal;
    font-size: 11px;
    position: relative;
    top: -1px;
    display: none;
}

#mods span.notice.btn {
    cursor: pointer;
    border: 1px solid #000;
    border-radius: 5px;
    position: relative;
    top: -1px;
    padding: 0 2px;
    background: #eee;
}

#mods span.notice.txt {
    display: inline-block;
}

.table .hidden {
    opacity: 0.5;
}

.table .content-packs {
    margin-left: 1em;
    font-size: 0.9em;
    font-style: italic;
}

.table .content-packs-collapsed {
    opacity: 0.75;
    font-size: 0.9em;
    font-style: italic;
}

#metadata td:first-child {
    padding-right: 5px;
}

.table tr:nth-child(even) {
    background: #fff;
}

#filters {
    margin: 1em 0 0 0;
    padding: 0 0 0.5em;
    display: flex;
    justify-content: space-between;
    width: calc(100vw - 16em);
}

#filters > div {
    align-self: center;
}

#filters .toggles {
    display: flex;
}

#filters .toggles > div:first-child {
    font-weight: bold;
    padding: 0.2em 1em 0 0;
}

#filters .filter-text {
    margin-top: 0.5em;
}

#filters .stats {
    margin-top: 0.5em;
    font-size: 0.75em;
}

#filters.sticky {
    position: fixed;
    top: 0;
    left: 0em;
    background: #fff;
    margin: 0;
    padding: 0.5em;
    width: calc(100% - 1em);
}

@media (min-width: 1020px) and (max-width: 1199px) {
    #filters:not(.sticky) {
        width: calc(100vw - 13em);
    }
}

@media (max-width: 1019px) {
    #filters:not(.sticky) {
        width: calc(100vw - 3em);
    }

    #filters {
        display: block;
    }
}

#filters span {
    padding: 3px 1em;
    display: inline-block;
    border: 1px solid #000000;
    border-radius: 3px;
    font-family: monospace;
    cursor: pointer;
    font-weight: bold;
    color: #000;
    border-color: #880000;
    background-color: #fcc;

    user-select: none;
}

#filters .filter-text span {
    padding: 3px 0.5em;
}

#filters .whole-word i {
    padding: 0 1px;
    border: 1px dashed;
}

#filters span:hover {
    background-color: #fee;
}

#filters span.active {
    background: #cfc;
    border-color: #008800;
}

#filters span.active:hover {
    background: #efe;
}

#filters .pager {
    margin-top: 0.5em;
    text-align: right;
}

#filters .pager div {
    margin-top: 0.5em;
}

#filters .pager div span {
    padding: 0 0.5em;
    margin: 0 1px;
}

#filters .pager span {
    background-color: #eee;
    border-color: #888;
}

#filters .pager span.active {
    font-weight: bold;
    border-color: transparent;
    background: transparent;
    cursor: unset;
}

#filters .pager span.disabled {
    opacity: 0.3;
    cursor: unset;
}

#filters .pager span:not(.disabled):hover {
    background-color: #fff;
}


/*********
** Log
*********/
#log .mod-repeat {
    font-size: 0.85em;
    font-style: italic;
}

#log .trace {
    color: #999;
}

#log .debug {
    color: #595959;
}

#log .info {
    color: #000;
}

#log .alert {
    color: #b0b;
}

#log .warn {
    color: #f80;
}

#log .error {
    color: #f00;
}

#log .critical {
    background-color: #c00;
    color: #fff;
    font-weight: bold;
}

#log .section-start {
    cursor: pointer;
}

#log .section-toggle-message {
    color: blue;
}

#log .log-message-text {
    white-space: pre-wrap;
}

#log .log-message-text strong {
    background-color: yellow;
    font-weight: normal;
}

#log {
    border-spacing: 0;
}

#log tr {
    background: #fff;
}

#log td {
    padding: 0 1px;
    background: inherit;
    border-bottom: 1px dotted #ccc;
    border-top: 2px solid #fff;
    vertical-align: top;
}

#log td:not(:last-child) {
    max-width: 175px;
    padding: 0 4px;
    overflow: hidden;
    white-space: nowrap;
}

#log td[data-title]:hover {
    overflow: inherit;
    position: relative;
}

#log td:nth-child(3):hover:after {
    content: attr(data-title);
    display: block;
    position: absolute;
    border-radius: 4px;
    box-shadow: 1px 1px 2px #ccc;
    background: inherit;
    border: 1px solid #ccc;
    background: #efefef;
    padding: 1px 1px 0 1px;
    font-size: 10pt;
    top: -2px;
    left: 2px;
    color: #000;
}

#log td:last-child {
    width: 100%;
}

#error {
    color: #f00;
}


/*********
** OS instructions
*********/
#os-instructions {
    display: grid;
    grid-template-columns: minmax(16em, auto) 30em;
}

#os-instructions [role="tablist"] {
    border: 0;
}

#os-instructions [role="tab"] {
    display: block;
    border: 0;
    position: relative;
}

#os-instructions [role="tab"][aria-selected="true"] {
    font-weight: bold;
    border-radius: 0 10px 10px 0;
}

[role="tab"][aria-selected="true"]::after {
    content: "▶";
    padding-left: 0.5em;
}