/* =========================================================
   TEMPLATE 11 — TECH BUSINESS PROFESSIONAL
   Professional Blue Corporate Invoice
   Version : 1.0.0
   ========================================================= */


/* =========================================================
   ROOT / INVOICE PAGE
   ========================================================= */

.tech-business-professional-invoice {

    width: 210mm;
    min-height: 297mm;

    margin: 0 auto;

    padding: 10mm;

    box-sizing: border-box;

    background: #ffffff;

    color: #1f2937;

    font-family:
        Arial,
        Helvetica,
        sans-serif;

    font-size: 10.5px;

    line-height: 1.45;

    position: relative;

    overflow: hidden;

}


/* =========================================================
   A4 INNER PAGE
   ========================================================= */

.tbp-page {

    width: 100%;

    height: 277mm;
    min-height: 277mm;
    max-height: 277mm;

    box-sizing: border-box;

    padding: 9mm 9mm 15mm;

    background: #ffffff;

    position: relative;
}

/* =========================================================
   TOP ACCENT
   ========================================================= */

.tbp-top-accent {

    display: none;

}


/* =========================================================
   HEADER — TECH BUSINESS PROFESSIONAL
   PREMIUM CORPORATE LAYOUT
   ========================================================= */

.tbp-header {

    width: 100%;

    height: 43mm;

    margin-bottom: 4mm;

    position: relative;

    box-sizing: border-box;

}


.tbp-header-content {

    width: 100%;

    height: 100%;

}


.tbp-header-inner {

    width: 100%;

    height: 100%;

    position: relative;

    box-sizing: border-box;

}


/* =========================================================
   LEFT BRAND AREA
   ========================================================= */

.tbp-brand-area {

    position: absolute;

    left: 0;

    top: 0;

    width: 47mm;

    height: 20mm;

}


/* =========================================================
   PREMIUM BLUE BRAND BLOCK
   ========================================================= */

.tbp-brand-block {

    width: 44mm;

    height: 18.5mm;

    display: flex;

    align-items: center;

    gap: 2.5mm;

    padding: 2.5mm 3mm;

    box-sizing: border-box;

    background: #1769aa;

    color: #ffffff;

    position: relative;

}


/* Premium angled right edge */

.tbp-brand-block::after {

    content: "";

    position: absolute;

    top: 0;

    right: -6mm;

    width: 8mm;

    height: 100%;

    background: #1769aa;

    clip-path: polygon(
        0 0,
        100% 50%,
        0 100%
    );

}


/* =========================================================
   LOGO
   ========================================================= */

.tbp-logo {

    width: 10.5mm;

    height: 10.5mm;

    flex: 0 0 10.5mm;

    display: flex;

    align-items: center;

    justify-content: center;

}


.tbp-logo img {

    width: 100%;

    height: 100%;

    object-fit: contain;

}


.tbp-logo-placeholder {

    width: 9mm;

    height: 9mm;

    border: 1.2px solid #ffffff;

    display: flex;

    align-items: center;

    justify-content: center;

    font-size: 14px;

}


/* =========================================================
   BRAND TEXT
   ========================================================= */

.tbp-brand-text {

    min-width: 0;

    display: flex;

    flex-direction: column;

    justify-content: center;

}


.tbp-company-name {

    max-width: 27mm;

    font-size: 9.5px;

    line-height: 1.2;

    font-weight: 700;

    color: #ffffff;

    white-space: normal;

    overflow-wrap: break-word;

}


.tbp-company-slogan {

    max-width: 27mm;

    margin-top: 1mm;

    font-size: 7px;

    line-height: 1.2;

    font-weight: 400;

    color: #ffffff;

    white-space: nowrap;

    overflow: hidden;

    text-overflow: ellipsis;

    opacity: 0.95;

}


/* =========================================================
   COMPANY ADDRESS
   ========================================================= */

.tbp-company-address {

    position: absolute;

    left: 52mm;

    top: 3mm;

    width: 45mm;

    font-size: 8.5px;

    line-height: 1.55;

    font-weight: 500;

    color: #303840;

}


.tbp-address-line {

    display: block;

    white-space: nowrap;

}


/* =========================================================
   RIGHT CONTACT AREA
   ========================================================= */

.tbp-contact-area {

    position: absolute;

    top: 0;

    right: 0;

    width: 51mm;

    box-sizing: border-box;

    padding-left: 5mm;

    border-left: 1px solid #d7dde3;

}


/* =========================================================
   CONTACT ROWS
   ========================================================= */

.tbp-contact-row {

    display: flex;

    align-items: center;

    gap: 2mm;

    width: 100%;

    white-space: nowrap;

    margin-bottom: 1.6mm;

    font-size: 8.5px;

    color: #20252b;

}


.tbp-contact-icon {

    width: 4mm;

    flex: 0 0 4mm;

    color: #1769aa;

    font-size: 10.5px;

    text-align: center;

}


/* =========================================================
   INVOICE BLOCK
   ========================================================= */

.tbp-invoice-block {

    margin-top: 5mm;

}


/* =========================================================
   INVOICE TITLE
   ========================================================= */

.tbp-invoice-title {

    display: inline-block;

    color: #1769aa;

    font-size: 34px;

    line-height: 1;

    font-weight: 300;

    letter-spacing: 0.5px;

    padding-bottom: 1.8mm;

    border-bottom: 1.5px solid #1769aa;

}


/* =========================================================
   INVOICE META
   ========================================================= */

.tbp-invoice-meta {

    margin-top: 2.5mm;

    display: flex;

    flex-direction: column;

    gap: 1.5mm;

}


.tbp-meta-row {

    display: flex;

    align-items: center;

    min-height: 3.5mm;

    font-size: 8.5px;

}


.tbp-meta-icon {

    width: 4mm;

    flex: 0 0 4mm;

    color: #1769aa;

    font-size: 8px;

}


.tbp-meta-label {

    min-width: 18mm;

    font-weight: 600;

    color: #30363d;

}


.tbp-meta-colon {

    margin-right: 1.5mm;

    color: #777f87;

}


.tbp-meta-value {

    color: #444b52;

}

/* =========================================================
   PARTIES
   ========================================================= */

.tbp-party-section {

    width: 100%;

    margin-top: -20mm;

    margin-bottom: 7mm;

}


.tbp-party-block {

    width: 48%;

}


.tbp-party-heading {

    font-size: 9px;

    font-weight: 700;

    letter-spacing: 0.8px;

    color: #20252b;

    margin-bottom: 1.5mm;

}


.tbp-party-name {

    font-size: 14px;

    line-height: 1.25;

    font-weight: 700;

    color: #1769aa;

    margin-bottom: 1.2mm;

}

.tbp-party-person {

    font-size: 9px;

    margin-bottom: 1mm;

    color: #4b5563;

}


.tbp-party-content {

    font-size: 9px;

    line-height: 1.55;

    color: #343a40;

}


/* =========================================================
   PARTY ADDRESS
   PROFESSIONAL LINE-BY-LINE FORMAT
   ========================================================= */

.tbp-party-address {

    margin-top: 0;

    font-size: 9px;

    line-height: 1.55;

    color: #343a40;

}

.tbp-party-address-line {

    display: block;

    white-space: normal;

}

/* =========================================================
   PARTY CONTACTS
   ========================================================= */

.tbp-party-contacts {

    margin-top: 1.5mm;

}


.tbp-party-contact {

    display: flex;

    align-items: center;

    gap: 2mm;

    margin-top: 0.8mm;

    font-size: 8.5px;

    line-height: 1.4;

}


.tbp-party-contact-icon {

    width: 4mm;

    flex: 0 0 4mm;

    color: #1769aa;

    text-align: center;

    font-size: 9px;

}


.tbp-party-contact-value {

    color: #3f474f;

}

.tbp-party-contact-icon {

    width: 4mm;

    color: #1769aa;

    text-align: center;

}


/* =========================================================
   PRODUCTS
   ========================================================= */

.tbp-products {

    width: 100%;

    margin-top: 2mm;

}


.tbp-products-heading {

    display: flex;

    align-items: center;

    gap: 3mm;

    margin-bottom: 2.5mm;

}


.tbp-products-heading-line {

    width: 8mm;

    height: 2px;

    background: #1769aa;

}


.tbp-section-kicker {

    font-size: 8px;

    font-weight: 700;

    letter-spacing: 0.8px;

    color: #1769aa;

}


.tbp-products-subtitle {

    font-size: 9px;

    color: #68717a;

}


/* =========================================================
   PRODUCT TABLE
   ========================================================= */

.tbp-products-table-wrap {

    width: 100%;

    overflow: hidden;

}


.tbp-products-table {

    width: 100%;

    border-collapse: collapse;

    table-layout: fixed;

}


/* =========================================================
   TABLE HEADER
   ========================================================= */

.tbp-products-table thead th {

    height: 11mm;

    padding: 2.5mm 2mm;

    background: #f0f2f4;

    border-bottom: 1.5px solid #1769aa;

    color: #20252b;

    font-size: 8.5px;

    font-weight: 700;

    text-align: left;

    vertical-align: middle;

}

/* =========================================================
   PRODUCT HEADER ALIGNMENT
   KEEP HEADERS ALIGNED WITH THEIR VALUES
   ========================================================= */

.tbp-products-table thead th.tbp-col-price {

    text-align: right;

}


.tbp-products-table thead th.tbp-col-tax {

    text-align: center;

}


.tbp-products-table thead th.tbp-col-qty {

    background: #e6e9ec;

    text-align: center;

}


.tbp-products-table thead th.tbp-col-amount {

    background: #1769aa;

    color: #ffffff;

    text-align: right;

}


/* =========================================================
   TABLE COLUMNS
   ========================================================= */

.tbp-col-number {

    width: 7%;

}


.tbp-col-item {

    width: 31%;

}


.tbp-col-sku {

    width: 12%;

}


.tbp-col-qty {

    width: 11%;

}


.tbp-col-price {

    width: 14%;

}


.tbp-col-tax {

    width: 10%;

}


.tbp-col-amount {

    width: 15%;

}


/* =========================================================
   PRODUCT ROW
   ========================================================= */

.tbp-product-row {

    height: 13mm;

}


.tbp-product-row td {

    padding: 3mm 2mm;

    border-bottom: 1px solid #1769aa;

    font-size: 9px;

    color: #30363d;

    vertical-align: middle;

}


.tbp-product-row:nth-child(even) td {

    background: #f5f6f7;

}


.tbp-product-number {

    color: #5c6670;

}


.tbp-product-item {

    font-weight: 500;

}


.tbp-product-name {

    font-weight: 500;

}


.tbp-product-sku {

    color: #69737d;

    font-size: 8.5px;

}


.tbp-product-qty {

    text-align: center;

}


.tbp-product-price {

    text-align: right;

}


.tbp-product-tax {

    text-align: center;

}


.tbp-product-amount {

    text-align: right;

    font-weight: 600;

}


/* =========================================================
   EMPTY PRODUCTS
   ========================================================= */

.tbp-products-empty {

    height: 22mm;

    text-align: center;

    color: #8a939c !important;

    font-style: italic;

}


/* =========================================================
   BOTTOM GRID
   ========================================================= */

.tbp-bottom-grid {

    width: 100%;

    display: grid;

    grid-template-columns:
        minmax(0, 1fr)
        72mm;

    column-gap: 8mm;

    margin-top: 4mm;

}

/* =========================================================
   LEFT BOTTOM
   ========================================================= */

.tbp-left-bottom {

    min-width: 0;

}


/* =========================================================
   NOTES
   ========================================================= */

.tbp-notes-section {

    width: 100%;

    margin-bottom: 6mm;

}


.tbp-notes-header {

    display: flex;

    align-items: center;

    gap: 2mm;

    margin-bottom: 2mm;

}


.tbp-notes-accent {

    color: #1769aa;

    font-size: 15px;

}


.tbp-notes-heading {

    color: #1769aa;

    font-size: 9px;

    font-weight: 700;

    letter-spacing: 0.7px;

}


.tbp-notes-rule {

    height: 1px;

    width: 100%;

    background: #1769aa;

    margin-top: 1mm;

}


.tbp-notes-body {

    padding-left: 6mm;

}


.tbp-notes-text {
    white-space: pre-line;
}


.tbp-notes-empty {

    color: #68717a;

}


/* =========================================================
   PAYMENT
   ========================================================= */

.tbp-payment-section {

    width: 100%;

    margin-bottom: 4mm;

}


.tbp-payment-header {

    display: flex;

    align-items: center;

    gap: 2.5mm;

    margin-bottom: 2mm;

}


.tbp-payment-accent {

    color: #1769aa;

    font-size: 14px;

    font-weight: 700;

}


.tbp-payment-heading {

    color: #1769aa;

    font-size: 9px;

    font-weight: 700;

    letter-spacing: 0.7px;

}


.tbp-payment-rule {

    width: 100%;

    height: 1px;

    background: #1769aa;

    margin-top: 1mm;

}


.tbp-payment-card {

    padding-left: 6mm;

}


.tbp-payment-item {

    display: flex;

    align-items: baseline;

    gap: 2mm;

    margin-bottom: 1.2mm;

    font-size: 8.8px;

}


.tbp-payment-label {

    font-weight: 700;

    color: #30363d;

}


.tbp-payment-value {

    font-weight: 400;

    color: #424a52;

}


.tbp-payment-instructions {

    margin-top: 2mm;

}


.tbp-payment-instruction-text {

    margin-top: 1mm;

    font-size: 8.8px;

    line-height: 1.5;

    color: #424a52;

}


/* =========================================================
   TOTALS
   ========================================================= */

.tbp-totals-section {

    width: 72mm;

    margin-left: auto;

}


.tbp-totals-heading {

    display: none;

}


.tbp-totals-box {

    width: 100%;

    box-sizing: border-box;

}


.tbp-total-row {

    min-height: 6mm;

    display: flex;

    align-items: center;

    justify-content: space-between;

    gap: 3mm;

    font-size: 9px;

    color: #363d44;

}


.tbp-total-row strong {

    font-weight: 500;

    text-align: right;

}


.tbp-discount-row strong {

    color: #3d454d;

}


/* =========================================================
   TOTAL DIVIDER
   ========================================================= */

.tbp-total-divider {

    width: 100%;

    height: 1px;

    background: #cbd1d6;

    margin: 1.5mm 0;

}


/* =========================================================
   GRAND TOTAL
   ========================================================= */

.tbp-total-grand {

    display: grid;

    grid-template-columns: 1fr auto;

    align-items: stretch;

    min-height: 12mm;

    margin-top: 2mm;

}


.tbp-grand-label {

    display: flex;

    align-items: center;

    height: 100%;

    padding: 3mm 4mm;

    box-sizing: border-box;

    background: #eceeef;

    font-size: 10px;

    font-weight: 700;

    color: #22272c;

}

.tbp-grand-caption {

    display: none;

}


.tbp-total-grand strong {

    min-width: 32mm;

    display: flex;

    align-items: center;

    justify-content: center;

    padding: 3mm 4mm;

    box-sizing: border-box;

    background: #1769aa;

    color: #ffffff;

    font-size: 12px;

    font-weight: 700;

    white-space: nowrap;

}


/* =========================================================
   PAID / BALANCE
   ========================================================= */

.tbp-total-payment {

    margin-top: 3mm;

}


.tbp-paid-row,

.tbp-balance-row {

    font-size: 8.5px;

}


/* =========================================================
   FINAL FOOTER
   ========================================================= */


.tbp-final-footer {

    position: absolute;

    left: 0;
    right: 0;
    bottom: 15mm;

    width: 100%;

    margin: 0;
    padding: 0 9mm;

    box-sizing: border-box;

    break-inside: avoid;
    page-break-inside: avoid;
}


.tbp-footer {

    width: 100%;

    margin: 0;

    padding: 0;

    position: static;

    break-inside: avoid;

    page-break-inside: avoid;

}

.tbp-footer-line {

    width: 100%;

    height: 1px;

    background: #1769aa;

    margin-bottom: 2mm;

}


.tbp-footer-content {

    width: 100%;

    display: grid;

    grid-template-columns: 1fr 65mm;

    gap: 7mm;

    align-items: end;

    break-inside: avoid;

    page-break-inside: avoid;

}


/* =========================================================
   FOOTER MESSAGE
   ========================================================= */

.tbp-footer-message {

    min-width: 0;

}


.tbp-footer-thank-you {

    font-size: 9.5px;

    font-weight: 600;

    color: #30363d;

}


.tbp-footer-website {

    margin-top: 1mm;

    font-size: 8px;

    color: #1769aa;

}


.tbp-footer-tagline {

    margin-top: 1.5mm;

    font-size: 8px;

    color: #6b747d;

}


/* =========================================================
   SIGNATURE
   ========================================================= */

.tbp-signature-section {

    width: 100%;

    text-align: center;

}


.tbp-signature-label {

    margin-bottom: 1mm;

    color: #1769aa;

    font-size: 8px;

    font-weight: 700;

    letter-spacing: 0.5px;

}


.tbp-signature-line {

    width: 65%;

    height: 7mm;

    border-bottom: 1.2px solid #1769aa;

    display: flex;

    align-items: flex-end;

    justify-content: center;

    position: relative;

    margin-left: auto;

    margin-right: auto;

}

.tbp-signature-image {

    max-width: 42mm;

    max-height: 6mm;

    object-fit: contain;

    margin-bottom: 0.5mm;

}


.tbp-signature-name {

    margin-top: 1mm;

    font-size: 9px;

    font-weight: 700;

    color: #30363d;

}


.tbp-signature-title {

    font-size: 7.5px;

    line-height: 1.2;

    color: #69737d;

}


/* =========================================================
   PRINT
   ========================================================= */

@media print {

    @page {

        size: A4 portrait;

        margin: 0;

    }


    html,
    body {

        margin: 0;

        padding: 0;

        background: #ffffff;

    }


    .tech-business-professional-invoice {

        width: 210mm;

        min-height: 297mm;

        margin: 0;

        padding: 10mm;

        box-sizing: border-box;

        page-break-after: always;

    }


   .tbp-page {

    height: 277mm;

    min-height: 277mm;

    max-height: 277mm;

    box-sizing: border-box;

}


    .tbp-product-row,

    .tbp-payment-section,

    .tbp-notes-section,

    .tbp-footer {

        break-inside: avoid;

        page-break-inside: avoid;

    }


    .tbp-products-table {

        break-inside: auto;

    }


    .tbp-products-table tr {

        break-inside: avoid;

        page-break-inside: avoid;

    }


    .tbp-total-grand strong {

        print-color-adjust: exact;

        -webkit-print-color-adjust: exact;

    }


    .tbp-brand-block,

    .tbp-products-table thead th.tbp-col-amount {

        print-color-adjust: exact;

        -webkit-print-color-adjust: exact;

    }

}


/* =========================================================
   SCREEN
   ========================================================= */

@media screen {

    .tech-business-professional-invoice {

        box-shadow:
            0 12px 35px rgba(0, 0, 0, 0.08);

    }

}


/* =========================================================
   RESPONSIVE PREVIEW
   ========================================================= */

@media (max-width: 900px) {

    .tech-business-professional-invoice {

        width: 100%;

        min-height: auto;

        padding: 12px;

    }


    .tbp-page {

        min-height: auto;

        padding: 24px;

    }

}


@media (max-width: 700px) {

    .tbp-company-area,
    .tbp-contact-area {

        position: static;

        width: 100%;

    }


    .tbp-company-area {

        margin-bottom: 8mm;

    }


    .tbp-contact-area {

        border-left: 0;

        border-top: 1px solid #d7dde3;

        padding-left: 0;

        padding-top: 5mm;

    }


    .tbp-party-section {

        margin-top: 5mm;

    }


    .tbp-bottom-grid {

        grid-template-columns: 1fr;

        row-gap: 7mm;

    }


    .tbp-footer-content {

        grid-template-columns: 1fr;

        gap: 8mm;

    }


    .tbp-products-table {

        min-width: 700px;

    }


    .tbp-products-table-wrap {

        overflow-x: auto;

    }

}


/* =========================================================
   END — TECH BUSINESS PROFESSIONAL CSS
   ========================================================= */