/* Used in valuation cheat_sheet.rst, on top of cheat-sheet.css */

/* Prevent titles from wrapping upwards */
h3 { clear: both !important; }

.full-width { width: 100% !important; }

/* Boxes holding the examples */
.alternatives, .accounting-entries, .journal-entries {
    border: 1px solid #d5d5d5;
    background-color: #f8f8f8;
    padding: 0 !important;
    font-size: 14px;
}

/* Costing methods table - see valuation-cheat-sheet.js */
.alternatives-controls {
    padding-bottom: 24px;
}
dl.alternatives > dd {
    margin-left: 0;
}

/* Controls of the accounting and journal entries */
.valuation-controls {
    .control-heading {
        font-weight: 700;
    }
    .control-heading:not(:first-child), .control-group {
        margin-top: 1rem;
    }
    .is-relevant {
        font-weight: 700;
    }
}

/* Journal entries: plain listings */
.journal-entries {
    .entries-listing > p:not(.rubric) {
        font-style: normal;
    }
}

/* Static tables */
.feature-table, .config-table {
    table {
        /* width: unset; */
        margin: auto;
        white-space: nowrap;
        text-align: center;
    }
    tbody td:first-child {
        text-align: left;
    }
}
.config-table {
    font-size: 90%;
}

.feature-table {
    font-size: 14px;
    overflow-x: auto;
}

.accounting-app-paragraph:hover ~ .feature-table tr > td:first-child:has(+ td .good),
.inventory-app-paragraph:hover ~ .feature-table tr > td:first-child:has(+ td + td .good)
{ font-weight: bold; }

.feature-table {
    td { width: 32px; }
    td:has(.good) { background-color: #d9ead3 !important; }
    td:has(.meh)  { background-color: #fce5cd !important; }
    td:has(.bad)  { background-color: #f4cccc !important; }
}
.config-table {
    th, td {
        padding-top: 0px !important;
        padding-bottom: 0px !important;
    }
    td:has(.washed) { color: var(--bs-gray); }
}

.yellow,   td:has(.yellow),   th:has(.yellow)   { background-color: #fff2cc !important; }
.green,    td:has(.green),    th:has(.green)    { background-color: #d9ead3 !important; }
.blue,     td:has(.blue),     th:has(.blue)     { background-color: #cfe2f3 !important; }
.darkblue, td:has(.darkblue), th:has(.darkblue) { background-color: #6d9eeb !important; }
.purple,   td:has(.purple),   th:has(.purple)   { background-color: #d9d2e9 !important; }
