<html>

<head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <link rel="preconnect" href="https://fonts.googleapis.com">
    <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
    <link href="https://fonts.googleapis.com/css2?family=Montserrat:wght@400;500;700;800;900&display=swap" rel="stylesheet">
    <title><?php echo e(__('pdf.report.title', [], $lang)); ?></title>
    <style>
        @page :first {
            size: A4 portrait;
            margin: 20px 5px 40px 5px;
            padding: 0px;
        }

        @page {
            size: A4 portrait;
            margin: 20px 5px 40px 5px;
            padding: 0px;

            @top-center {
                content: " ";
                display: block;
                margin-top: 1cm;
            }
        }

        main {
            color: #485460;
            margin: 0 40px;
        }

        body {
            margin: 0px;
            padding: 0px;
            font-family: 'Montserrat', sans-serif;
            font-weight: 500;
        }

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

        hr {
            margin: 1cm 0;
            height: 0;
            border: 0;
            border-top: 1mm solid var(--highlight-color);
        }

        header h1,
        header h2,
        header h3,
        header p {
            margin: 0;
        }

        header hr {
            margin: 1cm 0 .5cm 0;
        }

        main table {
            width: 100%;
            border-collapse: collapse;
        }

        main table thead th:nth-of-type(2),
        main table thead th:nth-of-type(3),
        main table thead th:last-of-type {
            width: 2.5cm;
        }

        main table thead th:last-of-type,
        main table tbody td:last-of-type {
            text-align: right;
        }

        main table th {
            text-align: left;
        }

        /* HEADER */
        .header {
            margin: 20px 40px 0 40px;
            padding: 40px;
            background-color: #313233;
            color: #fff;
        }

        .header .workspace-name {
            font-size: 14px;
            line-height: 1.3;
        }

        .header .logo {
            margin-bottom: 10px;
        }

        .header .logo img {
            width: 50px;
            height: 50px;
            border-radius: 50%;
            margin-right: 10px;
        }

        .header .title {
            font-size: 22px;
            font-weight: 700;
            letter-spacing: 1px;
            text-transform: uppercase;
            margin-top: 0;
            margin-bottom: 0;
        }

        .header .dates {
            font-size: 14px;
            font-weight: 500;
            margin: 4px 0 20px;
        }

        /* SUMMARY */
        .summary {
            padding: 0 40px;
        }

        .summary .heading {
            font-size: 18px;
            font-weight: 800;
            margin: 0;
            margin-top: 20px;
        }

        .summary .total {
            font-size: 40px;
            margin: 0;
            margin-top: -15px;
        }

        .summary .project_list-entry {
            margin: 5px 0;
            font-size: 13px;
        }

        .summary .workspace-name {
            font-size: 30px;
            font-weight: 800;
            margin: 30px 0;
        }

        /* ENTRIES */
        .entries .project--entry {
            padding: 5px 40px;
            font-weight: 500;
            font-size: 13px;
        }

        .entries .project--header {
            background-color: #485460;
            color: #fff;
            font-size: small;
        }

        .entries {
            margin: 0 !important;
            padding: 0 !important;
        }

        .entry-text {
            padding: 2px 40px;
            font-weight: 500;
            font-size: 13px;
        }

        /* FOOTER */
        #footer {
            position: fixed;
            left: 50%;
            transform: translateX(-50%);
            bottom: 0;
            color: #aaa;
            font-size: 0.9em;
        }

        .page-number:before {
            font-size: 12px;
            font-weight: lighter;
            color: #485460;
            content: "<?php echo e(__('pdf.report.page', [], $lang)); ?> " counter(page);
        }

        /* UTILS */
        .grey-text {
            color: #485460;
        }

        .margin-y-20 {
            margin: 20px 0 !important;
        }

        .first-entry-text {
            padding-top: 10px;
        }

        .page-break {
            page-break-after: always;
        }
    </style>
</head>

<body>
    <div id="footer">
        <div class="page-number"></div>
    </div>
    <header class="header">
        <div class="logo">
            <img src="<?php echo e($logo); ?>" alt="" />
            <h2 class="workspace-name"><?php echo e($workspace_name); ?></h2>
        </div>
        <div>
            <h1 class="title"><?php echo e(__('pdf.report.title', [], $lang)); ?></h1>
            <p class="dates"><?php echo e($startDate); ?> - <?php echo e($endDate); ?></p>
        </div>
    </header>

    <main class="padding">
        <section class="summary" style="padding: 0 40px;">
            <h2 class="heading"><?php echo e(__('pdf.report.hours_project', [], $lang)); ?></h2>
            <?php $__currentLoopData = $entries; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $entry): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
            <?php if($entry['rate'] && !$onlyHours): ?>
            <p class="project_list-entry"><?php echo e($entry['project']['name']); ?> <b style="font-size: 11px"><?php echo e($entry['rounded_duration']); ?> x <?php echo e((int)$entry['rate']); ?> <?php echo e($currency); ?> = <?php echo e($entry['value']); ?> <?php echo e($currency); ?></b>
            </p>
            <?php else: ?>
            <p class="project_list-entry"><?php echo e($entry['project']['name']); ?> <b style="font-size: 11px"><?php echo e($entry['rounded_duration']); ?> h</b>
            </p>
            <?php endif; ?>
            <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>

            <div class="value_summary">
                <?php if(!$onlyHours): ?>
                <h2 class="heading margin-y-20"><?php echo e(__('pdf.report.hours_summary', [], $lang)); ?>: <?php echo e($summary['rounded_duration']); ?> h</h2>
                <h2 class="heading"><?php echo e(__('pdf.report.projects_sum', [], $lang)); ?> </h2>
                <h1 class="total"> <?php echo e($summary['value']); ?>

                    <span style="font-size: 13px; padding-bottom: 5px">
                        <?php echo e($currency); ?> (<?php echo e(__('pdf.report.net', [], $lang)); ?>)
                    </span>
                </h1>
                <?php else: ?>
                <h1 class="total"><?php echo e(__('pdf.report.hours_summary', [], $lang)); ?>: <?php echo e($summary['rounded_duration']); ?> h</h1>
                <?php endif; ?>
            </div>
            </div>
        </section>

        <section class="entries">
            <?php $__currentLoopData = $entries; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $entry): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
            <hr style="margin: 20px;" />
            <table>
                <thead>
                    <tr class="project--header">
                        <th class="project--entry"><?php echo e($entry['project']['name']); ?> (<?php echo e($entry['client']); ?>)</th>
                        <th class="project--entry"><?php echo e($entry['rounded_duration']); ?></th>
                    </tr>
                </thead>
                <?php $isFirst = true; ?>
                <?php $__currentLoopData = $entry['entries']; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $groupedEntry): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                <tbody>
                    <tr class="entry-record">
                        <td class="<?php echo e($isFirst ? 'first-entry-text' : ''); ?> grey-text entry-text"><?php echo e($groupedEntry['name']); ?></td>
                        <td class="<?php echo e($isFirst ? 'first-entry-text' : ''); ?> grey-text entry-text"><?php echo e($groupedEntry['rounded_duration']); ?></td>
                    </tr>
                </tbody>
                <?php $isFirst = false; ?>
                <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
            </table>
            <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>

            <?php if($shouldGenerateDocs && count($docs) > 0): ?>
            <div class="page-break"></div>
            <h1><?php echo e(__('pdf.report.docs', [], $lang)); ?></h1>

            <?php $__currentLoopData = $docs; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $doc): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
            <img src="<?php echo e($doc); ?>" style="width: 100%; margin-bottom: 20px;">
            <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>

            <?php endif; ?>
        </section>

        </div>
    </main>
</body>

</html>
<?php /**PATH /var/www/esteamate/esteamate-api/resources/views/pdf/report.blade.php ENDPATH**/ ?>