﻿@page {
    size: A4;
    margin: 1rem;
}

/*Circular*/
@media print {

    html {
        font-size: 12px;
    }

    /* Container */
    .circular-meas {
        height: 100%;
    }

        .circular-meas .print-container {
            display: flex;
            flex-direction: column;
            min-height: 100%;
            padding: 1rem;
            box-sizing: border-box;
            page-break-after: always;
        }

            .circular-meas .print-container:first-child {
                page-break-before: auto;
                break-before: auto;
            }

        /* Header */
        .circular-meas .print-header {
            flex-shrink: 0;
            display: flex;
            flex-direction: column;
            width: 100%;
            padding: 0.8rem 0 0.6rem 0;
            background: #fff;
            color: #000;
        }

            .circular-meas .print-header .header-logo {
                display: flex;
                justify-content: flex-end;
                margin-bottom: 0.2rem;
            }

        .circular-meas .print-logo {
            height: 4.5rem;
            width: auto;
            object-fit: contain;
        }

        .circular-meas .header-container {
            display: flex;
            justify-content: space-between;
            align-items: center;
            width: 100%;
            /*padding-bottom: 0.2rem;*/
            border-bottom: 0.1rem solid #000;
        }

        .circular-meas .print-header h6 {
            margin: 0;
            padding: 0;
            line-height: 1.4;
            font-size: 1.3rem;
            font-weight: bold;
        }

        .circular-meas .header-print-info {
            display: flex;
            justify-content: flex-end;
            width: 100%;
            margin-top: 0.4rem;
            font-size: 1rem;
            font-weight: normal;
        }

            .circular-meas .header-print-info p {
                margin: 0;
                padding: 0;
            }

        /* Body */
        .circular-meas .print-body {
            display: flex;
            flex-direction: column;
            flex: 1 1 auto;
            width: 100%;
            margin-top: 0.5rem;
            background: #fff;
            color: #000;
            box-sizing: border-box;
        }

        .circular-meas .top-container {
            display: grid;
            grid-template-columns: repeat(4, 1fr);
            width: 100%;
            border: 0.08rem solid #000;
            border-radius: 0.4rem;
            box-sizing: border-box;
            padding: 0.5rem 0;
        }

            .circular-meas .top-container .top-item {
                padding: 0 0.5rem;
                box-sizing: border-box;
            }

        .circular-meas .top-footer-line {
            align-content: end;
            padding: 0.25rem;
            grid-column: 1 / -1;
            font-size: 0.9rem;
            margin-top: 1rem;
        }

        .circular-meas .item-title {
            font-size: 1.1rem;
            font-weight: bold;
            font-style: italic;
            line-height: 1.2;
        }

        .circular-meas .item-label .fst-normal {
            font-size: 0.75rem;
            font-weight: bold;
        }

        .circular-meas .item-container {
            display: grid;
            grid-template-columns: 6rem 1fr;
            column-gap: 0.6rem;
            row-gap: 0.3rem;
            width: 100%;
            line-height: 1.4;
        }

        .circular-meas .item-label {
            font-size: 1rem;
            white-space: normal;
            font-style: italic;
            line-height: 1.4;
        }

        .circular-meas .item-value {
            font-size: 1rem;
            word-break: break-word;
            line-height: 1.4;
        }

        .circular-meas .bottom-container {
            flex: 1 1 auto;
            width: 100%;
            display: flex;
            padding: 0.8rem 0;
            gap: 0.8rem;
            overflow: hidden;
            background: #fff;
            color: #000;
            box-sizing: border-box;
            align-items: flex-start;
        }

            .circular-meas .bottom-container .table-container {
                flex: 0 0 auto;
                width: auto;
                max-width: 100%;
                height: auto;
                overflow: visible;
                box-sizing: border-box;
                border: 0.08rem solid #000;
                border-radius: 0.4rem;
                padding: 0.5rem;
            }

                .circular-meas .bottom-container .table-container .table-wrapper {
                    display: flex;
                    flex-direction: column;
                    height: auto;
                }

                .circular-meas .bottom-container .table-container .table-header {
                    display: grid;
                    grid-template-columns: 1fr 1fr;
                    font-weight: bold;
                    white-space: nowrap;
                    border-bottom: 0.08rem solid #000;
                    background: #fff;
                }

                .circular-meas .bottom-container .table-container .header-cell {
                    padding: 0.5rem;
                    text-align: center;
                    border-right: 0.08rem solid #000;
                    font-size: 1.1rem;
                }

                    .circular-meas .bottom-container .table-container .header-cell:last-child {
                        border-right: none;
                    }

                .circular-meas .bottom-container .table-container .table-body {
                    display: flex;
                    flex-direction: column;
                    height: auto;
                }

                .circular-meas .bottom-container .table-container .table-row {
                    display: grid;
                    grid-template-columns: 1fr 1fr;
                    white-space: nowrap;
                    align-items: center;
                }

                .circular-meas .bottom-container .table-container .cell-label {
                    text-align: center;
                    font-weight: bold;
                    border-right: 0.08rem solid #000;
                    font-size: 1rem;
                    line-height: 1.6;
                }

                .circular-meas .bottom-container .table-container .cell-value {
                    text-align: center;
                    font-size: 1rem;
                    line-height: 1.6;
                }

            .circular-meas .bottom-container .chart-container {
                flex: 1 1 0;
                min-width: 0;
                display: flex;
                flex-direction: column;
                align-items: stretch;
                box-sizing: border-box;
                overflow: hidden;
                background: #fff;
                border: 0.08rem solid #000;
                border-radius: 0.4rem;
            }

                .circular-meas .bottom-container .chart-container .top-chart {
                    flex: 1;
                    width: 100%;
                    overflow: hidden;
                }

                    .circular-meas .bottom-container .chart-container .top-chart > * {
                        height: 100%;
                    }

                .circular-meas .bottom-container .chart-container .bottom-chart {
                    width: 100%;
                    padding: 0.8rem 0.6rem 0.6rem 0.6rem;
                    box-sizing: border-box;
                }

                    .circular-meas .bottom-container .chart-container .bottom-chart .bottom-row {
                        display: grid;
                        grid-template-columns: 1fr 1fr 1fr;
                        width: 100%;
                        border: 0.08rem solid #000;
                        border-radius: 0.3rem;
                        overflow: hidden;
                    }

                    .circular-meas .bottom-container .chart-container .bottom-chart .bottom-cell {
                        text-align: center;
                        border-right: 0.08rem solid #000;
                        font-size: 1rem;
                        display: flex;
                        flex-direction: column;
                        gap: 0.3rem;
                        padding: 0.4rem;
                    }

                        .circular-meas .bottom-container .chart-container .bottom-chart .bottom-cell:last-child {
                            border-right: none;
                        }

                        .circular-meas .bottom-container .chart-container .bottom-chart .bottom-cell .label {
                            font-weight: bold;
                            font-size: 1rem;
                        }

                        .circular-meas .bottom-container .chart-container .bottom-chart .bottom-cell .value {
                            font-size: 1rem;
                        }
        /*Footer*/
        .circular-meas .print-footer {
            flex-shrink: 0;
            margin-top: auto;
            width: 100%;
            padding: 0.6rem 0;
            box-sizing: border-box;
        }

            .circular-meas .print-footer .print-logo {
                height: 4rem;
                width: auto;
                object-fit: contain;
            }

        .circular-meas .footer-container {
            display: flex;
            flex-direction: row;
            justify-content: space-between;
            align-items: center;
            width: 100%;
            padding-top: 0.5rem;
            border-top: 0.08rem solid #000;
        }
}

/*Shape*/
@media print {
    /*Kontainer*/
    .shape-meas .print-container {
        display: flex;
        flex-direction: column;
        min-height: 100%;
        padding: 1rem;
        box-sizing: border-box;
        page-break-after: always;
    }

        .shape-meas .print-container:first-child {
            page-break-before: auto;
            break-before: auto;
        }

    /* Header */
    .shape-meas .print-header {
        flex-shrink: 0;
        display: flex;
        flex-direction: column;
        width: 100%;
        padding: 0.8rem 0 0.6rem 0;
        background: #fff;
        color: #000;
    }

    .shape-meas .header-logo {
        display: flex;
        justify-content: flex-end;
        margin-bottom: 0.3rem;
    }

    .shape-meas .print-logo {
        height: 4.5rem;
        width: auto;
        object-fit: contain;
    }

    .shape-meas .header-container {
        display: flex;
        justify-content: space-between;
        align-items: center;
        width: 100%;
        border-bottom: 0.08rem solid #000;
    }

    .shape-meas .print-header h6 {
        margin: 0;
        padding: 0;
        line-height: 1.4;
        font-size: 1.3rem;
        font-weight: bold;
    }

    .shape-meas .header-print-info {
        display: flex;
        justify-content: flex-end;
        width: 100%;
        margin-top: 0.4rem;
        font-size: 1rem;
        font-weight: normal;
    }

        .shape-meas .header-print-info p {
            margin: 0;
            padding: 0;
        }
    
    /*Body*/
    .shape-meas .print-body {
        display: flex;
        flex-direction: column;
        flex: 1 1 auto;
        width: 100%;
        margin-top: 0.5rem;
        background: #fff;
        color: #000;
        box-sizing: border-box;
    }

    .shape-meas .top-container {
        display: grid;
        grid-template-columns: repeat(4, 1fr);
        width: 100%;
        border: 0.08rem solid #000;
        border-radius: 0.4rem;
        box-sizing: border-box;
        padding: 0.5rem 0;
    }

        .shape-meas .top-container .top-item {
            padding: 0 0.5rem;
            box-sizing: border-box;
        }

    .shape-meas .top-footer-line {
        align-content: end;
        padding: 0.25rem;
        grid-column: 1 / -1;
        font-size: 0.9rem;
        margin-top: 1rem;
    }

    .shape-meas .item-title {
        font-size: 1.1rem;
        font-weight: bold;
        font-style: italic;
        line-height: 1.2;
    }

    .shape-meas .item-container {
        display: grid;
        grid-template-columns: 6rem 1fr;
        column-gap: 0.6rem;
        row-gap: 0.3rem;
        width: 100%;
        line-height: 1.4;
    }

    .shape-meas .item-label {
        font-size: 1rem;
        white-space: normal;
        font-style: italic;
        line-height: 1.4;
    }

        .shape-meas .item-label .fst-normal {
            font-size: 0.75rem;
            font-weight: bold;
        }

    .shape-meas .item-value {
        font-size: 1rem;
        word-break: break-word;
        line-height: 1.4;
    }

    /* Bottom Container */
    .shape-meas .bottom-container {
        flex: 1 1 auto;
        width: 100%;
        display: flex;
        padding: 0.8rem 0;
        gap: 0.8rem;
        overflow: hidden;
        background: #fff;
        color: #000;
        box-sizing: border-box;
        align-items: flex-start;
    }

        .shape-meas .bottom-container .chart-container {
            flex: 1 1 0;
            min-width: 0;
            display: flex;
            flex-direction: column;
            align-items: stretch;
            box-sizing: border-box;
            overflow: hidden;
            background: #fff;
        }

    .shape-meas .bold-row {
        font-size: 1rem;
        font-weight: bold;
    }

    /*Footer*/
    .shape-meas .print-footer {
        flex-shrink: 0;
        margin-top: auto;
        width: 100%;
        padding: 0.6rem 0;
        box-sizing: border-box;
    }

        .shape-meas .print-footer .print-logo {
            height: 4rem;
            width: auto;
            object-fit: contain;
        }

    .shape-meas .footer-container {
        display: flex;
        justify-content: space-between;
        align-items: center;
        width: 100%;
        padding-top: 0.5rem;
        border-top: 0.08rem solid #000;
    }   
}

@media print {

    body * {
        visibility: hidden;
    }

    .print-container,
    .print-container * {
        visibility: visible;
    }

    .print-container {
        position: absolute;
        left: 0;
        top: 0;
        width: 100%;
    }  
}