body {
    font-family: 'Inter', sans-serif;
    color: #1e293b;
    margin: 0;
    padding: 0;
    background-color: #f1f5f9;
}

/* Top Action / Preview Bar like cetak_rapor.php */
.no-print-bar {
    background-color: #ffffff;
    padding: 12px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #cbd5e1;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.btn-print-action {
    padding: 9px 20px;
    background-color: #2563eb;
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    font-size: 0.9rem;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: all 0.2s;
}

.btn-print-action:hover {
    background-color: #1d4ed8;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.25);
}

.btn-close-action {
    padding: 9px 16px;
    background-color: #64748b;
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    font-size: 0.9rem;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: all 0.2s;
}

.btn-close-action:hover {
    background-color: #475569;
}

.invoice-sheet-wrapper {
    padding: 30px 15px;
}

.invoice-container {
    max-width: 800px;
    margin: 0 auto;
    background-color: white;
    padding: 50px;
    border-radius: 8px;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.05);
    position: relative;
}

.header-section {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 2px solid #cbd5e1;
    padding-bottom: 20px;
    margin-bottom: 30px;
}

.title-invoice {
    font-size: 3.5rem;
    font-weight: 800;
    color: #0f172a;
    margin: 0;
    letter-spacing: -1.5px;
}

.title-invoice.title-nota {
    letter-spacing: 1px;
}

.logo-zanoba img {
    height: 90px;
    object-fit: contain;
}

.info-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 30px;
}

.info-table td {
    padding: 6px 0;
    font-size: 1rem;
    vertical-align: top;
    color: #0f172a;
}

.info-table tr td:first-child {
    width: 110px;
    color: #475569;
}

.info-table tr td:nth-child(2) {
    width: 20px;
    color: #475569;
}

.items-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
}

.items-table th {
    background-color: #0056b3;
    color: white;
    font-weight: 800;
    text-align: left;
    padding: 12px 16px;
    font-size: 0.9rem;
    letter-spacing: 0.5px;
}

.items-table th.center {
    text-align: center;
}

.items-table th.right {
    text-align: right;
}

.items-table td {
    padding: 14px 16px;
    border-bottom: 1px solid #e2e8f0;
    font-size: 0.95rem;
    color: #334155;
}

.items-table td.desc {
    color: #64748b;
    font-weight: 500;
}

.subtotal-bar {
    display: flex;
    justify-content: space-between;
    background-color: #0056b3;
    color: white;
    font-weight: 800;
    padding: 12px 20px;
    margin-top: 15px;
    width: 48%;
    margin-left: auto;
    font-size: 1rem;
    letter-spacing: 0.5px;
}

.invoice-footer-grid {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-top: 40px;
    gap: 20px;
}

.footer-left-col {
    flex: 1;
}

.footer-right-col {
    flex: 0 0 auto;
    text-align: center;
}

.signature-box {
    display: inline-block;
    text-align: center;
    min-width: 220px;
}

.sig-city-date {
    margin: 0 0 4px 0;
    font-size: 0.95rem;
    color: #475569;
}

.sig-title {
    margin: 0 0 8px 0;
    font-size: 0.95rem;
    font-weight: 600;
    color: #1e293b;
}

.sig-image-container {
    height: 75px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 6px;
}

.sig-img {
    max-height: 75px;
    max-width: 180px;
    object-fit: contain;
}

.sig-space {
    height: 65px;
}

.sig-name {
    margin: 0;
    font-size: 0.95rem;
    font-weight: 700;
    color: #0f172a;
    text-decoration: underline;
}

.payment-info {
    margin-top: 0;
    text-align: left;
}

.payment-info h3 {
    font-size: 1.05rem;
    color: #475569;
    margin-bottom: 12px;
    font-weight: 700;
}

.payment-table {
    border-collapse: collapse;
}

.payment-table td {
    padding: 4px 0;
    font-size: 1rem;
    color: #475569;
}

.payment-table tr td:first-child {
    width: 80px;
    color: #1e293b;
}

.payment-table tr td:nth-child(2) {
    width: 20px;
}

.payment-table tr td:last-child {
    color: #1e293b;
}

/* Print CSS rule to suppress browser header (URL) and footer (page number/link) */
@media print {
    @page {
        size: A4 portrait;
        margin: 0mm; /* Removes browser default header URL and footer page numbers */
    }
    html, body {
        background-color: #ffffff !important;
        margin: 0 !important;
        padding: 0 !important;
        -webkit-print-color-adjust: exact !important;
        print-color-adjust: exact !important;
    }
    .no-print-bar {
        display: none !important;
    }
    .invoice-sheet-wrapper {
        padding: 15mm 20mm !important;
    }
    .invoice-container {
        box-shadow: none !important;
        border-radius: 0 !important;
        padding: 0 !important;
        max-width: 100% !important;
        margin: 0 !important;
    }
}
