/* Print overrides for Bootstrap */
@media print {

    /* General reset for print */
    * {
        background: transparent !important;
        box-shadow: none !important;
    }

    html, body {
        margin: 0;
        padding: 0;
        background: #ffffff !important;
        color: #000000 !important;
    }

    /* Hide navigation & UI chrome */
    .navbar,
    .navbar-fixed-top,
    .navbar-fixed-bottom,
    .nav,
    .pagination,
    .pager,
    .breadcrumb,
    .dropdown-menu,
    .btn,
    .btn-group,
    .btn-toolbar,
    .card-footer,
    .modal,
    .toast,
    .alert,
    footer,
    .footer,
    header,
    .header,
    .offcanvas,
    .no-print {
        display: none !important;
    }

    /* Make content full-width */
    .container,
    .container-fluid {
        max-width: none !important;
        width: 100% !important;
    }

    /* Let Bootstrap columns stack nicely on print */
    [class^="col-"],
    [class*=" col-"] {
        float: none !important;
        width: 100% !important;
        max-width: 100% !important;
    }

    /* Tables: clean, with borders, no backgrounds */
    .table {
        border-collapse: collapse !important;
    }

    .table th,
    .table td {
        background-color: #ffffff !important;
        border: 1px solid #000000 !important;
    }

    /* Keep table headers on each page */
    thead {
        display: table-header-group;
    }

    /* Avoid awkward page breaks */
    h1, h2, h3, h4, h5, h6 {
        page-break-after: avoid;
    }

    h1, h2 {
        font-size: 1.25rem;
    }

    h3 {
        font-size: 1.1rem;
    }

    table,
    tr,
    img {
        page-break-inside: avoid;
    }

    /* Optional: show URLs after links in print */
    a[href]:after {
        content: " (" attr(href) ")";
        font-size: 90%;
    }

    /* Don’t show empty hrefs or JS links */
    a[href^="javascript:"]:after,
    a[href^="#"]:after {
        content: "";
    }

    img {
        display: none !important;
    }
}
