/* ================================================================
   Print Stylesheet — CFO AI Advisors
   Makes pages print-friendly: removes nav, dark backgrounds,
   uses readable typography, hides non-essential elements.
   ================================================================ */

/* Reset to white background, black text */
*,
*::before,
*::after {
  background: white !important;
  color: #111827 !important;
  box-shadow: none !important;
  text-shadow: none !important;
}

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

/* Hide navigation, footer, and non-content elements */
header,
nav,
footer,
.header,
.footer,
[role="banner"],
[role="navigation"],
[role="contentinfo"] {
  display: none !important;
}

/* Hide gradients, blurred backgrounds */
[class*="gradient"],
[class*="blur"],
[class*="backdrop"],
[style*="radial-gradient"],
[style*="linear-gradient"] {
  background: white !important;
  color: #111827 !important;
}

/* Make text in dark sections readable */
.text-white,
.text-slate-100,
.text-slate-200,
.text-slate-300,
.text-slate-400,
.text-slate-500,
.text-blue-200,
.text-blue-300,
.text-blue-400 {
  color: #111827 !important;
}

/* Restore proper heading hierarchy */
h1 {
  font-size: 24pt;
  font-weight: 700;
  margin-bottom: 12pt;
  page-break-after: avoid;
}

h2 {
  font-size: 18pt;
  font-weight: 700;
  margin-top: 18pt;
  margin-bottom: 8pt;
  page-break-after: avoid;
}

h3 {
  font-size: 14pt;
  font-weight: 600;
  margin-top: 14pt;
  margin-bottom: 6pt;
  page-break-after: avoid;
}

p {
  margin-bottom: 8pt;
  orphans: 3;
  widows: 3;
}

/* Remove all backgrounds from sections */
section,
[class*="bg-"] {
  background: white !important;
}

/* Collapse decorative elements */
[class*="fixed"],
[class*="absolute"],
[class*="opacity-"],
[class*="pointer-events-none"],
[class*="blur-"],
[class*="backdrop"],
[class*="rounded-full"],
.bg-gradient-to-br,
.bg-gradient-to-r,
.pointer-events-none {
  display: none !important;
}

/* Keep rounded badges/pills visible but clean */
[class*="rounded-full"]:not([class*="opacity"]):not([class*="blur"]) {
  display: inline !important;
  background: white !important;
  border: 1px solid #d1d5db !important;
}

/* Buttons and CTAs — hide most, keep links */
button,
[role="button"],
a:not([href]) {
  display: none !important;
}

a[href] {
  color: #111827 !important;
  text-decoration: underline;
}

/* Keep images but constrain width */
img {
  max-width: 100% !important;
  page-break-inside: avoid;
}

/* Show URL after links for reference */
a[href^="http"]::after {
  content: " (" attr(href) ")";
  font-size: 9pt;
  color: #6b7280 !important;
}

/* Don't show URL for internal links */
a[href^="/"]::after,
a[href^="#"]::after,
a[href^="mailto:"]::after,
a[href^="tel:"]::after {
  content: none;
}

/* Page breaks */
section {
  page-break-inside: avoid;
}

/* Lists */
ul, ol {
  padding-left: 18pt;
  margin-bottom: 8pt;
}

li {
  margin-bottom: 4pt;
}

/* Tables */
table {
  border-collapse: collapse;
  width: 100%;
  margin-bottom: 12pt;
}

th, td {
  border: 1px solid #d1d5db;
  padding: 4pt 8pt;
  text-align: left;
}

th {
  font-weight: 700;
}

/* Page setup */
@page {
  margin: 0.75in;
  size: letter;
}

@page :first {
  margin-top: 0.5in;
}
