/* Print Stylesheet for CLEDA.org */
@media print {
    /* Reset and Basic Styles */
    * {
        background: transparent !important;
        color: #000 !important;
        box-shadow: none !important;
        text-shadow: none !important;
    }
    
    body {
        font-family: Georgia, serif;
        font-size: 12pt;
        line-height: 1.5;
        margin: 2cm;
    }
    
    /* Hide unnecessary elements */
    nav, header, footer, aside,
    .no-print, .cookie-consent,
    #exit-intent-popup, #cookie-consent-banner,
    button, .btn, form, input, textarea,
    .social-share-buttons, .newsletter-signup,
    video, audio, iframe {
        display: none !important;
    }
    
    /* Headings */
    h1, h2, h3, h4, h5, h6 {
        page-break-after: avoid;
        page-break-inside: avoid;
        font-weight: bold;
    }
    
    h1 { font-size: 24pt; margin-bottom: 12pt; }
    h2 { font-size: 18pt; margin-bottom: 10pt; }
    h3 { font-size: 14pt; margin-bottom: 8pt; }
    
    /* Links */
    a {
        text-decoration: underline;
        color: #000 !important;
    }
    
    a[href]:after {
        content: " (" attr(href) ")";
        font-size: 90%;
        font-style: italic;
    }
    
    a[href^="#"]:after,
    a[href^="javascript:"]:after {
        content: "";
    }
    
    /* Images */
    img {
        max-width: 100% !important;
        page-break-inside: avoid;
    }
    
    /* Tables */
    table {
        border-collapse: collapse;
        width: 100%;
        page-break-inside: avoid;
    }
    
    th, td {
        border: 1px solid #ddd;
        padding: 8pt;
        text-align: left;
    }
    
    th {
        background: #f0f0f0 !important;
        font-weight: bold;
    }
    
    /* Avoid breaks */
    p, blockquote {
        page-break-inside: avoid;
        orphans: 3;
        widows: 3;
    }
    
    /* Page breaks */
    .page-break {
        page-break-before: always;
    }
    
    /* Header for each page */
    @page {
        margin: 2cm;
        
        @top-right {
            content: "CLEDA.org";
            font-size: 9pt;
            color: #666;
        }
        
        @bottom-right {
            content: "Page " counter(page) " of " counter(pages);
            font-size: 9pt;
            color: #666;
        }
    }
    
    /* First page special */
    @page :first {
        @top-right {
            content: "";
        }
    }
    
    /* Article/Content specific */
    article {
        page-break-after: always;
    }
    
    article:last-of-type {
        page-break-after: auto;
    }
    
    /* Code blocks */
    pre, code {
        border: 1px solid #ddd;
        page-break-inside: avoid;
        white-space: pre-wrap;
        font-family: monospace;
        font-size: 10pt;
    }
    
    /* Lists */
    ul, ol {
        page-break-inside: avoid;
    }
    
    /* Print-specific visibility */
    .print-only {
        display: block !important;
    }
    
    /* Company info for print */
    .print-footer {
        margin-top: 40pt;
        padding-top: 20pt;
        border-top: 2px solid #000;
        font-size: 10pt;
    }
}
