/**
 * Solo-Millionär Book - Print Stylesheet
 * For PDF export via browser print
 */

@media print {
  /* Reset page */
  * {
    box-shadow: none !important;
  }

  html, body {
    background: #fff !important;
    font-size: 11pt;
    line-height: 1.6;
  }

  /* Hide non-print elements */
  .header,
  .sidebar,
  .mobile-menu-toggle,
  .mobile-sidebar-overlay,
  .chapter-pagination,
  .cta-button {
    display: none !important;
  }

  /* Content adjustments */
  .book-layout {
    display: block;
    padding: 0;
    min-height: auto;
  }

  .content {
    margin: 0;
    padding: 0;
    display: block;
  }

  .chapter {
    max-width: none;
    animation: none;
  }

  /* Chapter header */
  .chapter-header {
    margin-bottom: 1cm;
    padding-bottom: 0.5cm;
    border-bottom: 1pt solid #ccc;
  }

  .chapter-number {
    font-size: 9pt;
    color: #666;
  }

  .chapter-header-emoji {
    font-size: 14pt;
  }

  /* Typography for print */
  .chapter-content h1 {
    font-size: 24pt;
    margin-bottom: 0.5cm;
    page-break-after: avoid;
  }

  .chapter-content h2 {
    font-size: 16pt;
    margin-top: 1cm;
    margin-bottom: 0.4cm;
    page-break-after: avoid;
  }

  .chapter-content h3 {
    font-size: 12pt;
    margin-top: 0.7cm;
    margin-bottom: 0.3cm;
    page-break-after: avoid;
  }

  .chapter-content p {
    margin-bottom: 0.4cm;
    orphans: 3;
    widows: 3;
  }

  .chapter-content ul,
  .chapter-content ol {
    margin-bottom: 0.4cm;
    padding-left: 1cm;
  }

  .chapter-content li {
    margin-bottom: 0.2cm;
  }

  /* Links */
  .chapter-content a {
    color: #000;
    text-decoration: underline;
  }

  .chapter-content a[href^="http"]::after {
    content: " (" attr(href) ")";
    font-size: 9pt;
    color: #666;
  }

  /* Code blocks */
  .chapter-content pre {
    background: #f5f5f5 !important;
    border: 1pt solid #ddd;
    padding: 0.4cm;
    font-size: 9pt;
    overflow: visible;
    white-space: pre-wrap;
    word-wrap: break-word;
  }

  .chapter-content code {
    background: #f5f5f5;
    font-size: 9pt;
  }

  /* Blockquotes */
  .chapter-content blockquote {
    border-left: 3pt solid #c9a227;
    background: #faf8f2;
    padding: 0.3cm 0.5cm;
    margin: 0.4cm 0;
  }

  /* Horizontal rule */
  .chapter-content hr {
    border: none;
    border-top: 1pt solid #ccc;
    margin: 0.8cm 0;
  }

  /* Images */
  .chapter-content img {
    max-width: 100%;
    page-break-inside: avoid;
  }

  /* Page breaks */
  h1, h2, h3 {
    page-break-after: avoid;
  }

  p, li, blockquote {
    page-break-inside: avoid;
  }

  /* Page setup */
  @page {
    size: A4;
    margin: 2cm 2.5cm;
  }

  @page :first {
    margin-top: 3cm;
  }

  /* Footer with page numbers */
  @page {
    @bottom-center {
      content: counter(page);
      font-family: 'Inter', sans-serif;
      font-size: 9pt;
      color: #999;
    }
  }
}
