/* Override styles when printing */
@media print {

    /* Hide certain content when printing */
    #database-nav-toggler,
    nav,
    .sidebar,
    .sidebar-toggler,
    .tabs,
    .quicksearch-input,
    #itemimage-controls {
        display: none;
    }

    main {
        width: 100%;
        margin: 0;
    }

    h2 {
        margin: 0;
    }

    table {
        display: table;
    }

    tr {
        display: table-row;
    }

    td {
        border: 1px solid #AAA;
        border-collapse: collapse;
        display: table-cell;
    }

    /* To stop an element (e.g. an image) from splitting across pages */
    .nosplitprint {
        break-inside: avoid;
    }

    /* ----- researchdata ----- */

    .tabbed {
        display: block;
    }

    .tabbed-title {
        display: block;
        font-weight: bold;
        font-size: 2em;
        margin: 3em 0 1em 0;
    }

    #itemimage {
        height: 40em;
        border: none;
        margin-top: 2em;
    }

    #itemimage-container {
        height: 40em;
    }

    #itemimage-image {
        width: auto;
        height: 40em;
    }

    /* ----- handbook ----- */

    #handbook-detail-tableofcontents,
    #handbook-detail-main,
    #handbook-detail-footnotes {
        display: block;
        width: 100%;
        height: fit-content;
        position: initial;
        padding-bottom: 3em;
        border: none;
    }

    #handbook-detail-tableofcontents {
        margin-top: 15rem;
    }

    #handbook-detail-main-header {
        position: absolute;
        top: 0;
        left: 0;
    }

    /* Hide some elements, e.g. buttons */
    #handbook-detail-main-header-functions,
    .footnote-toggle {
        display: none;
    }

}