/* ====== print.css (Assignment 6 Final) ====== */

@media print {

    /* 1. Global Reset for Ink Efficiency */
    body {
        background: none !important;
        background-color: white !important;
        color: #000;
        font-size: 12pt;
        font-family: "Times New Roman", Times, serif;
        margin: 0;
        width: 100%;
    }

    /* 2. Hide Non-Printable Elements (Requirement 2 & 7) */
    nav,
    header,
    footer,
    input[type="submit"],
    input[type="reset"],
    .animation {
        display: none !important;
    }

    /* 3. Link Handling */
    a {
        color: #000;
        text-decoration: underline;
    }

    /* Append URLs to links for physical reference */
    a::after {
        content: " (" attr(href) ")";
        font-size: 90%;
        font-style: italic;
    }

    /* 4. Images */
    img {
        max-width: 100%;
        height: auto;
        border: 1px solid #ccc;
        page-break-inside: avoid;
        /* Prevents splitting images across pages */
    }

    /* 5. Tables (Requirement 10) */
    table {
        border: 1px solid #000;
        width: 100%;
        border-collapse: collapse;
        margin-top: 15px;
    }

    th,
    td {
        border: 1px solid #000;
        padding: 8px;
        text-align: left;
    }

    thead {
        display: table-header-group;
        /* Repeats header on multiple pages */
    }

    /* 6. Form Clean-up for Print */
    fieldset {
        border: 1px solid #000;
        padding: 10px;
        margin-top: 20px;
        page-break-inside: avoid;
    }

    /* Reset absolute/relative positioning for print readability */
    label {
        position: static !important;
        display: block;
        width: 100% !important;
        font-weight: bold;
        margin-top: 10px;
    }

    input,
    select,
    textarea {
        border: none;
        border-bottom: 1px solid #000;
        /* Minimal line for written info */
        position: static !important;
        width: 100% !important;
        left: 0 !important;
        background: transparent !important;
    }
}