/*
 * Print Stylesheet — Maxvidel Theme
 *
 * Basic print styles for readability. Removes backgrounds, navigation,
 * footer, sliders, and decorative elements. Shows URLs after links.
 * No background colours wasting ink.
 *
 * Loaded via @media print in enqueue.php.
 *
 * @package Maxvidel
 * @since 1.0.0
 */

@media print {

    /* ---- Reset colours and backgrounds ---- */

    *,
    *::before,
    *::after {
        background: transparent;
        color: #000;
        box-shadow: none;
        text-shadow: none;
    }

    /* ---- Typography ---- */

    body {
        font-family: Georgia, "Times New Roman", serif;
        font-size: 12pt;
        line-height: 1.5;
        color: #000;
    }

    h1, h2, h3, h4, h5, h6 {
        color: #000;
        page-break-after: avoid;
        orphans: 3;
        widows: 3;
    }

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

    p, li, blockquote {
        orphans: 3;
        widows: 3;
    }

    /* ---- Links — show URL after text ---- */

    a,
    a:visited {
        color: #000;
        text-decoration: underline;
    }

    a[href]::after {
        content: " (" attr(href) ")";
        font-size: 0.85em;
        font-weight: normal;
        word-break: break-all;
    }

    /* Don't print URLs for anchors, JS links, or buttons */
    a[href^="#"]::after,
    a[href^="javascript:"]::after,
    .btn-primary::after,
    .btn-secondary::after,
    .btn-accent::after,
    .btn-outline::after,
    .nav__menu a::after,
    .footer__nav a::after {
        content: "";
    }

    /* ---- Hide non-essential elements ---- */

    .site-header,
    .site-nav,
    .header__topbar,
    .nav__toggle,
    .nav__mobile,
    .nav__overlay,
    .site-footer,
    .hero-slider,
    .hero-slider__arrow,
    .hero-slider__dots,
    .testimonials-carousel,
    .testimonials-dot,
    .cta-banner,
    .cta,
    .newsletter-form,
    .newsletter-section,
    .filter-bar,
    .pagination,
    .skip-link,
    .breadcrumbs,
    .contact-map,
    .back-to-top,
    .cookie-notice,
    [data-aos] {
        display: none;
    }

    /* ---- Images ---- */

    img {
        max-width: 100%;
        page-break-inside: avoid;
    }

    /* ---- Layout simplification ---- */

    .container,
    .container--narrow {
        max-width: 100%;
        padding: 0;
        margin: 0;
    }

    .section {
        padding: 1em 0;
    }

    .page-hero {
        padding: 0.5em 0;
        border-bottom: 2px solid #000;
        margin-bottom: 1em;
    }

    /* Flatten grids to single column */
    .services-grid,
    .values-grid,
    .projects-grid,
    .team-grid,
    .blog-grid,
    .posts-grid--latest,
    .contact-grid,
    .overview-grid,
    .approach-grid,
    .stats-grid,
    .jobs-grid,
    .case-studies-grid,
    .blog-layout {
        display: block;
    }

    /* Cards — simple borders */
    .service-card,
    .value-card,
    .card--project,
    .card--post,
    .team-card,
    .job-card,
    .card--case-study {
        border: 1px solid #ccc;
        padding: 0.5em;
        margin-bottom: 1em;
        page-break-inside: avoid;
    }

    /* Avoid page breaks inside articles */
    article,
    .card,
    table,
    pre {
        page-break-inside: avoid;
    }

    /* Forms — hide on print */
    form,
    .contact-form,
    .rfp-form,
    .search-form {
        display: none;
    }

    /* ---- Page margins ---- */

    @page {
        margin: 2cm;
    }
}
