/* ==========================================================================
   Cheetah Print Styles
   ==========================================================================
   Optimizes pages for printing. Hides navigation, shows URLs,
   and improves typography for physical media.
   ========================================================================== */

@media print {
    /* ─── Reset ─── */
    *,
    *::before,
    *::after {
        background: transparent !important;
        color: #000 !important;
        box-shadow: none !important;
        text-shadow: none !important;
    }

    /* ─── Page Setup ─── */
    @page {
        margin: 2cm;
    }

    body {
        font-size: 12pt;
        line-height: 1.5;
        color: #000;
        background: #fff;
    }

    /* ─── Hide Non-Essential Elements ─── */
    .site-header,
    .primary-navigation,
    .mobile-menu-toggle,
    .mobile-navigation,
    .site-footer,
    .cheetah-breadcrumbs,
    .cheetah-pagination,
    .back-to-top,
    .social-share,
    .comments-area,
    .skip-link,
    .geo-freshness-badge,
    iframe,
    embed,
    object,
    video,
    audio,
    .woocommerce-mini-cart,
    .product-gallery__thumbnails,
    .add-to-cart,
    .wc-tabs {
        display: none !important;
    }

    /* ─── Show URLs for Links ─── */
    a[href]::after {
        content: " (" attr(href) ")";
        font-size: 90%;
        opacity: 0.8;
        word-break: break-all;
    }

    a[href^="javascript:"]::after,
    a[href^="#"]::after {
        content: "";
    }

    /* ─── Typography ─── */
    h1, h2, h3, h4, h5, h6 {
        page-break-after: avoid;
        page-break-inside: avoid;
        color: #000;
    }

    h1 { font-size: 24pt; }
    h2 { font-size: 20pt; }
    h3 { font-size: 16pt; }
    h4 { font-size: 14pt; }

    p {
        orphans: 3;
        widows: 3;
    }

    /* ─── Content ─── */
    .cheetah-main {
        width: 100% !important;
        max-width: 100% !important;
        flex: none !important;
    }

    .entry-content {
        width: 100%;
    }

    .entry-content img {
        max-width: 100% !important;
        page-break-inside: avoid;
    }

    pre,
    blockquote,
    table {
        page-break-inside: avoid;
    }

    thead {
        display: table-header-group;
    }

    tr {
        page-break-inside: avoid;
    }

    /* ─── WooCommerce Print ─── */
    .product {
        page-break-inside: avoid;
    }

    .product .price {
        font-size: 14pt;
        font-weight: bold;
    }

    /* ─── Utility Overrides ─── */
    .d-print-none {
        display: none !important;
    }

    .d-print-block {
        display: block !important;
    }
}