/* ============================================================
   nws.RO — PRINT STYLESHEET
   Optimizat pentru imprimare A4, text curat
   Se ascund elementele interactive, se fixează layout-ul

   Autor: nrg evolution srl
   ============================================================ */

@media print {

    /* ── Reset pentru print ── */
    * {
        background: white !important;
        color: #000 !important;
        box-shadow: none !important;
        text-shadow: none !important;
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
    }

    /* ── Configurare pagină A4 ── */
    @page {
        size: A4;
        margin: 2cm 2.5cm;
    }

    /* ── Body — font serif pentru lizibilitate ── */
    body {
        font-family: 'Georgia', 'Times New Roman', Times, serif !important;
        font-size: 12pt !important;
        line-height: 1.6 !important;
        color: #000 !important;
        background: white !important;
        margin: 0 !important;
        padding: 0 !important;
    }


    /* ── Ascunde elementele non-esențiale la print ── */
    .site-header,
    .site-nav,
    .mega-menu,
    .header-actions,
    .mobile-toggle,
    .site-footer,
    .footer-bottom,
    .back-to-top,
    .drawer,
    .drawer-overlay,
    .search-overlay,
    .cookie-banner,
    .share-row,
    .share-buttons,
    .cta-section,
    .cta-banner,
    .contact-cta,
    .newsletter-block,
    .newsletter-section,
    .btn,
    .btn-primary,
    .btn-outline,
    .loading-spinner,
    .breadcrumb-nav,
    .skip-link,
    .scroll-indicator,
    .hero-scroll,
    .industries-section,
    .tech-section,
    .theme-toggle,
    #darkModeToggle,
    .sidebar,
    .related-posts,
    .social-links,
    video,
    iframe,
    .no-print {
        display: none !important;
    }


    /* ── Container — lățime completă la print ── */
    .container,
    .page-wrapper,
    .page-content,
    main {
        max-width: 100% !important;
        width: 100% !important;
        padding: 0 !important;
        margin: 0 !important;
        display: block !important;
    }


    /* ── Headings ── */
    h1, h2, h3, h4, h5, h6 {
        font-family: 'Georgia', serif !important;
        page-break-after: avoid;
        break-after: avoid;
        color: #000 !important;
    }

    h1 {
        font-size: 22pt !important;
        line-height: 1.3 !important;
        margin-bottom: 0.5em !important;
    }

    h2 {
        font-size: 18pt !important;
        margin-top: 1.5em !important;
        margin-bottom: 0.5em !important;
    }

    h3 {
        font-size: 14pt !important;
        margin-top: 1.2em !important;
        margin-bottom: 0.4em !important;
    }

    h4 {
        font-size: 12pt !important;
        margin-top: 1em !important;
        margin-bottom: 0.3em !important;
    }


    /* ── Paragrafe ── */
    p {
        margin-bottom: 0.8em !important;
        orphans: 3;
        widows: 3;
        color: #000 !important;
    }


    /* ── Imagini ── */
    img {
        max-width: 100% !important;
        height: auto !important;
        page-break-inside: avoid;
        break-inside: avoid;
    }

    figure {
        page-break-inside: avoid;
        break-inside: avoid;
        margin: 1em 0 !important;
    }

    figcaption {
        font-size: 9pt !important;
        font-style: italic !important;
        color: #555 !important;
    }


    /* ── Link-uri: afișează URL-ul ── */
    .content-text a[href]::after,
    main a[href]::after {
        content: " (" attr(href) ")";
        font-size: 9pt;
        color: #555 !important;
        font-weight: normal;
        word-break: break-all;
    }

    /* Nu afișa URL-ul pentru ancore interne sau javascript */
    a[href^="#"]::after,
    a[href^="javascript"]::after,
    a[href^="tel"]::after,
    a[href^="mailto"]::after {
        content: "" !important;
    }


    /* ── Blockquote ── */
    blockquote {
        border-left: 3px solid #333 !important;
        padding: 10pt 12pt !important;
        margin: 12pt 0 !important;
        page-break-inside: avoid;
        break-inside: avoid;
        font-style: italic !important;
    }


    /* ── Tabele ── */
    table {
        border-collapse: collapse !important;
        width: 100% !important;
        page-break-inside: avoid;
    }

    table th,
    table td {
        border: 1px solid #ccc !important;
        padding: 6pt 8pt !important;
        font-size: 10pt !important;
    }

    table th {
        background: #f0f0f0 !important;
        font-weight: bold !important;
    }


    /* ── Prevenire page breaks pe elemente cheie ── */
    blockquote,
    pre,
    table,
    figure,
    .card {
        page-break-inside: avoid;
        break-inside: avoid;
    }


    /* ── Text utilitar ── */
    .text-muted,
    .text-sm,
    .text-soft {
        font-size: 9pt !important;
        color: #555 !important;
    }


    /* ── Grid → block la print ── */
    .grid-2,
    .grid-3,
    .grid-4 {
        display: block !important;
    }

    .grid-2 > *,
    .grid-3 > *,
    .grid-4 > * {
        margin-bottom: 12pt !important;
    }


    /* ── Hero section — simplificat la print ── */
    .hero {
        background: white !important;
        padding: 12pt 0 !important;
    }

    .hero h1 {
        color: #000 !important;
        font-size: 24pt !important;
    }


    /* ── Carduri de servicii — simplificat ── */
    .service-card,
    .portfolio-card {
        border: 1px solid #ddd !important;
        padding: 10pt !important;
        margin-bottom: 12pt !important;
        page-break-inside: avoid;
    }


    /* ── URL-ul site-ului la finalul paginii ── */
    body::after {
        content: "Tipărit de pe nws.ro — nrg evolution srl";
        display: block;
        text-align: center;
        font-size: 8pt;
        color: #999 !important;
        margin-top: 24pt;
        padding-top: 12pt;
        border-top: 1px solid #ddd;
    }
}
