/* FIXME: hack to reverse hack in theme CSS */
main.index .toctree-wrapper > .row:first-child > .col-md-3 {
    margin: 0 !important;
}

.intro-list {
    margin-top: 1em;
}
.intro-list p {
    margin: 0;
    cursor: pointer;
}

.related {
    background-color: hsl(219, 76%, 88%) !important;
}
.secondary {
    background-color: hsl(219, 67%, 94%) !important;
}
.highlight-op {
    background-color: hsl(219, 67%, 94%);
}

label:hover,
label:hover,
.highlighter-list li:hover {
    background-color: hsl(0, 0%, 94%);
    cursor: pointer;
}

.accounts-table {
    font-size: 90%;
}

.accounts-table dl {
    margin: 0;
}

.accounts-table h4, .accounts-table h5 {
    font-weight: normal;
}

.accounts-table h4 {
    text-align: center;
}
/* table root */
.accounts-table > div {
    display: flex;
    align-items: flex-start;
}
/* P&L & Balance Sheet columns */
.accounts-table > div > div {
    flex: 1;
    padding: 5px;
    margin: 0 5% 5% 5%;
    border: 2px solid #666;
    border-radius: 3px;
}

/* sections */
.accounts-table > div > div div {
    display: flex;
    flex-direction: column;
}

.accounts-table > div > div div > h5 {
    order: 99;

    text-transform: uppercase;

    padding: 0.3em 0;
    border-image: linear-gradient(to bottom, transparent, rgb(221, 225, 231), transparent, rgb(221, 225, 231), transparent) 5 0 10 / 3px 0 3px;
}
.accounts-table > div > div div div > h5 {
    /* slightly smaller than normal 14px h5 size */
    font-size: 12.5px;
    border-image: linear-gradient(to bottom, transparent, rgb(221, 225, 231), transparent, rgb(221, 225, 231), transparent) 5 0 5;
}
.accounts-table dt {
    font-weight: normal;
}
.accounts-table dt span {
    font-style: italic;
}
.accounts-table dt span:last-child {
    font-style: normal;
}

.values-table tr > * {
    text-align: right;
}
.values-table tr > :first-child {
    text-align: left;
}

/* 3-column (thing, debit, credit) tables */
/* 2nd and 3rd th & td of each row right-aligned and 1/4th width */
.d-c-table tr > :nth-child(2),
.d-c-table tr > :nth-child(3) {
    width: 25%;
    text-align: right;
}

@media (min-width: 992px) {
    .accounts-table, .doc-aside .highlighter-target {
        font-size: 90%;
        color: #888 !important;
    }
    .doc-aside .highlighter-target th {
        font-weight: normal;
        font-size: 110%;
    }
    .accounts-table .related, .doc-aside .highlighter-target .related {
        background-color: transparent !important;
        color: #eee !important;
    }
    .accounts-table .secondary, .doc-aside .highlighter-target .secondary {
        background-color: transparent !important;
        color: #aaa !important;
    }

    .chart-of-accounts .highlight-op,
    .valuation-chart .highlight-op {
        background-color: #030035;
    }

    .chart-of-accounts .highlight-op,
    .valuation-chart-continental .highlight-op {
        background-color: #030035;
    }

    .chart-of-accounts .highlight-op,
    .valuation-chart-anglo-saxon .highlight-op {
        background-color: #030035;
    }
}

.journal-entries .entries-listing p {
    font-style: italic;
}

#reconciliation .reconciliation-example div.buttons {
    display: flex;
    justify-content: center;
}
#reconciliation .reconciliation-example div.buttons button {
    margin: 0 0.5em;
}

@keyframes reconcile {
    0% {
        font-size: 100%;
        padding-top: 5px;
        padding-bottom: 5px;
        background-color: rgba(2, 0, 31, 0);
    }
    60% {
        background-color: rgba(2, 0, 31, 1);
    }
    80% {
        font-size: 100%;
        padding-top: 5px;
        padding-bottom: 5px;
    }
    100% {
        font-size: 0%;
        padding-top: 0;
        padding-bottom: 0;
        display: none;
    }
}
.reconcile1 .invoice1, .reconcile1 .invoice1 td {
    animation: reconcile 5s ease-in forwards;
}
.reconcile2 .invoice2, .reconcile2 .invoice2 td {
    animation: reconcile 5s ease-in forwards;
}

.invoice1.reconciled, .invoice2.reconciled {
    display: none;
}

blockquote.highlights {
    border: none;
    margin-bottom: 0;
    text-align: center;
}

/*
  lists of alternatives
*/
.alternatives-controls label {
    display: block;
}
dl.alternatives > dt,
dl.alternatives > dd {
    display: none;
}
dl.alternatives > dd {
    margin-left: 0;
}
