/* Print stylesheet: branded multi-page Action Plan report. */

@page { margin: 14mm 12mm 18mm 12mm; }

body, .planner-root {
    background: #fff !important;
    color: #1a202c;
}
body {
    margin-bottom: 46px; /* room for the fixed footer on the last page */
}

/* Hide interactive chrome: sliders, reset, auth card, sidebar CTA, buttons.
   The project info card is redundant on paper (the report header and the
   snapshot table carry the same facts) and raw notes textareas clip long
   text, so both give way to print-specific blocks. */
.planner-hero,
.hero-login-btn,
.login-panel,
.save-subsection,
.slider-group,
.planner-reset-btn,
.reset-row,
.planner-sidebar,
.pdf-export-btn,
.save-chip,
.planner-toast,
.project-info-card,
.notes-input,
.pdf-gate-hint {
    display: none !important;
}

.planner-container { max-width: none; margin: 0; padding: 0; }

/* Branded report header */
.print-header {
    display: block !important;
    border-bottom: 3px solid #1b4332;
    padding-bottom: 10px;
    margin-bottom: 16px;
}
.print-header .ph-logo {
    display: block;
    height: 45px;
    width: auto;
    margin-bottom: 8px;
}
.print-header .ph-brand {
    font-family: 'Poppins', sans-serif;
    font-size: 20px;
    font-weight: 700;
    color: #1b4332;
}
.print-header .ph-site {
    font-size: 12px;
    color: #4a5568;
    margin: 4px 0 10px 0;
}
.print-header .ph-meta {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 6px 18px;
    font-size: 11.5px;
}
.print-header .ph-label {
    display: block;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 9.5px;
    letter-spacing: 0.5px;
    color: #718096;
}

/* Cover-page project snapshot table */
.print-snapshot {
    display: block !important;
    page-break-inside: avoid;
    margin-bottom: 16px;
}
.print-snapshot .ps-title {
    font-family: 'Poppins', sans-serif;
    font-weight: 700;
    font-size: 14px;
    color: #1b4332;
    margin-bottom: 6px;
}
.snapshot-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 10.5px;
}
.snapshot-table th {
    background: #1b4332;
    color: #fff;
    text-align: left;
    padding: 5px 8px;
    font-weight: 700;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
}
.snapshot-table td {
    padding: 5px 8px;
    border-bottom: 1px solid #e2e8f0;
    color: #2d3748;
}
.snapshot-table tr:nth-child(even) td {
    background: #f7faf8;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
}

/* Plain-language caption so first-time Gantt readers can use the calendar */
.print-gantt-caption {
    display: block !important;
    font-size: 10px;
    color: #4a5568;
    line-height: 1.5;
    margin: 10px 0 0 0;
    border-top: 1px solid #e2e8f0;
    padding-top: 8px;
}

/* Notes print from expanding mirrors instead of clipping textareas */
.print-notes-mirror {
    display: block !important;
    border: 1px solid #cbd5e0;
    border-radius: 6px;
    padding: 10px 12px;
    font-size: 12px;
    line-height: 1.6;
    white-space: pre-wrap;
    min-height: 52px;
    color: #2d3748;
}
.print-notes-mirror.empty {
    color: #94a3b8;
    font-style: italic;
}

/* Phase ownership badges print with their tones; the screen-only divider
   between phases 4 and 5 would strand at a page break, so the badges and
   the snapshot's Driven By column carry the message on paper. */
.construction-divider { display: none !important; }
.phase-owner-badge {
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
    font-size: 10.5px;
}

/* Binder sign-off line at the end of each phase page */
.print-signoff {
    display: block !important;
    margin-top: 20px;
    padding-top: 12px;
    border-top: 1px dashed #cbd5e0;
    font-size: 11px;
    color: #4a5568;
}

/* Footer disclaimer repeats on every printed page */
.print-footer {
    display: block !important;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    font-size: 9.5px;
    color: #4a5568;
    text-align: center;
    border-top: 1px solid #cbd5e0;
    padding-top: 5px;
    background: #fff;
}

/* Cards flatten for paper */
.planner-card, .task-section, .planner-sidebar-card {
    box-shadow: none !important;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
}
.planner-card { page-break-inside: avoid; }

/* Each phase section starts on a fresh page */
.task-section {
    page-break-before: always;
    break-before: page;
    border-left: 4px solid #1b4332;
}
.task-item { page-break-inside: avoid; }

/* Layout collapses to a single column (sidebar hidden) */
.planner-main-layout { display: block; }

/* Gantt renders full-width without a scrollbar */
.gantt-wrapper { overflow: visible; }
.gantt-chart { min-width: 0 !important; width: 100%; }

/* Keep brand colors on paper */
.gantt-bar, .gantt-fill, .planner-progress-bar, .planner-progress-bar-container,
.task-checkbox, .lead-time-banner, .model-line, .month-gridline, .today-marker {
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
}

/* Notes print with room to write */
.notes-input { border: 1px solid #cbd5e0; background: #fff; min-height: 60px; resize: none; }

a { color: inherit; text-decoration: none; }
