﻿/* =========================================================
   GLOBAL REPORT FRAMEWORK
   RANA Solutions Corp.
   Azure / Browser Print Optimized
========================================================= */

/* ===== Report Page ===== */
.report-page {
    padding: 14px 22px;
    background: #fff;
    color: #1f2937;
    font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
    max-width: 1400px;
    margin: auto;
}

/* ===== Report Header ===== */
.report-header {
    display: flex;
    gap: 14px;
    align-items: center;
    margin-bottom: 14px;
    border-bottom: 1px solid #d1d5db;
    padding-bottom: 10px;
}

    .report-header .left {
        width: 90px;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .report-header .logo-print {
        width: 80px;
        height: 80px;
        object-fit: contain;
        display: block;
    }

    .report-header .logo-placeholder {
        width: 80px;
        height: 80px;
        border: 1px solid #d1d5db;
        border-radius: 6px;
        background: #f9fafb;
    }

    .report-header .center {
        flex: 1;
        text-align: center;
    }

    .report-header .right {
        width: 240px;
        text-align: right;
        font-size: 12px;
    }

    .report-header .company {
        font-size: 28px;
        font-weight: 700;
        line-height: 1.1;
        color: #111827;
    }

    .report-header .line {
        font-size: 13px;
        line-height: 1.35;
        color: #374151;
    }

    .report-header .doc-title {
        font-size: 14px;
        font-weight: 800;
        letter-spacing: 0.08em;
        color: #111827;
        margin-bottom: 4px;
    }

    .report-header .meta {
        font-size: 12px;
        line-height: 1.4;
        color: #374151;
    }

/* ===== Report Table ===== */
.report-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
    table-layout: fixed;
}

    .report-table thead th {
        background: #f3f4f6;
        color: #111827;
        font-weight: 700;
        border-bottom: 1px solid #d1d5db;
        padding: 7px 8px;
        vertical-align: middle;
    }

    .report-table tbody td {
        padding: 6px 8px;
        border-bottom: 1px solid #e5e7eb;
        vertical-align: middle;
        word-wrap: break-word;
    }

    .report-table tfoot th,
    .report-table tfoot td {
        padding: 7px 8px;
        border-top: 2px solid #9ca3af;
        font-weight: 700;
        background: #f9fafb;
    }

    .report-table tbody tr:nth-child(even) {
        background: #fafafa;
    }

/* ===== Report Helpers ===== */
.report-number {
    text-align: right;
    white-space: nowrap;
}

.report-center {
    text-align: center;
}

.report-muted {
    color: #6b7280;
}

.report-total-row {
    font-weight: 700;
    background: #f9fafb;
    border-top: 2px solid #6b7280;
    font-size: 14px;
}

/* ===== Report Footer ===== */
.report-footer {
    margin-top: 20px;
    padding-top: 8px;
    border-top: 1px solid #d1d5db;
    font-size: 11px;
    color: #6b7280;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* ===== Visibility Helpers ===== */
.print-only {
    display: none;
}

.screen-only {
    display: revert;
}

/* ===== Wide Report Support ===== */
.report-scroll {
    width: 100%;
    overflow-x: auto;
}

.report-table-wide {
    table-layout: auto !important;
    min-width: 1300px;
}

    .report-table-wide th,
    .report-table-wide td {
        white-space: normal;
    }


/* =========================================================
   PRINT MODE
========================================================= */
@media print {

    @page {
        margin: 0.4in;
        size: landscape;
    }

    html,
    body {
        background: white !important;
        margin: 0 !important;
        padding: 0 !important;
        height: auto !important;
        overflow: visible !important;
    }

    body {
        font-size: 12px;
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
    }

    .screen-only,
    .btn,
    .pagination,
    input,
    nav,
    .sidebar,
    .topbar,
    .navbar,
    .modal,
    .modal-backdrop {
        display: none !important;
    }

    .print-only {
        display: block !important;
    }

    .report-page {
        padding: 0 !important;
        margin: 0 !important;
        max-width: none !important;
        height: auto !important;
        overflow: visible !important;
    }

    .table-responsive {
        overflow: visible !important;
        height: auto !important;
        max-height: none !important;
    }

    .report-table {
        width: 100% !important;
        font-size: 11px;
        border-collapse: collapse;
        page-break-inside: auto;
    }

        .report-table th,
        .report-table td {
            padding: 4px 5px !important;
        }

    table {
        width: 100% !important;
        page-break-inside: auto;
    }

    tr {
        page-break-inside: avoid;
        page-break-after: auto;
    }

    thead {
        display: table-header-group;
    }

    tfoot {
        display: table-footer-group;
    }

    .report-footer {
        position: static !important;
        margin-top: 18px;
        page-break-inside: avoid;
    }

    .report-scroll {
        overflow: visible !important;
    }

    .report-table-wide {
        min-width: 100% !important;
        table-layout: auto !important;
        font-size: 10px !important;
    }

}
