/**
 * GetPaid invoice styles — MemberPress PDF Invoice layout match.
 *
 * @package RmdsGetPaid
 * @since   1.2.0
 */

/* A4 portrait paper dimensions: 210mm × 297mm */
.rmds-invoice-container {
	max-width: 210mm;
	min-height: 297mm;
	margin-left: auto;
	margin-right: auto;
	padding: 55px 80px;
	box-sizing: border-box;
}

.rmds-invoice-body {
	font-family: 'Open Sans', Arial, sans-serif;
	font-size: 13px;
	color: #333;
	margin: 15px 0;
}

/* Reset Bootstrap table styles inside our wrapper */
.rmds-invoice-body table {
	margin-bottom: 0;
	border: none;
}
.rmds-invoice-body table td,
.rmds-invoice-body table th {
	vertical-align: top;
}
.rmds-invoice-body h2 {
	margin: 0;
	padding: 0;
	border: none;
	background: none;
}
.rmds-invoice-body p {
	margin-top: 0;
	margin-bottom: 0.4em;
}
.rmds-invoice-body p:last-child {
	margin-bottom: 0;
}

/* Items table: cells and summary rows (!important needed to beat .bsui td { border-width: 0 } from ayecode-ui) */
.rmds-invoice-body .rmds-items-table td,
.rmds-invoice-body .rmds-items-table th {
	text-align: left;
	padding: 10px;
	border: 1px solid #000 !important;
	color: #333;
	font-size: 13px;
}
.rmds-invoice-body .rmds-items-table th {
	background-color: #000;
	color: #fff;
}
.rmds-invoice-body .rmds-items-table .rmds-summary-cell {
	border: none !important;
}
.rmds-invoice-body .rmds-items-table .rmds-summary-label {
	text-align: right;
	border: none !important;
}

/* Footer sections */
.rmds-footer-section {
	margin: 0;
	color: #333;
	font-size: 13.75px;
}

/* Header: primary action button (View Receipt) */
.bsui .getpaid-header-left-actions .btn {
	background-color: #7e0000 !important;
	border-color: #7e0000 !important;
	color: #fff !important;
	box-shadow: none !important;
}

/* Header: secondary buttons (Print Invoice, Invoice History, Edit Invoice) */
.bsui .getpaid-header-right-actions .btn {
	background-color: rgba(126, 0, 0, 0.05) !important;
	border: none !important;
	border-radius: 8px !important;
	color: #7e0000 !important;
	font-weight: 600 !important;
	font-size: 14px !important;
	padding: 8px 16px !important;
	box-shadow: none !important;
}
.bsui .getpaid-header-right-actions .btn:hover,
.bsui .getpaid-header-right-actions .btn:focus {
	background-color: rgba(126, 0, 0, 0.12) !important;
	color: #5e0000 !important;
}

@media print {
	body { margin: 0; padding: 0; }
	.rmds-invoice-container {
		max-width: 100% !important;
		min-height: auto !important;
		padding: 0 !important;
		margin: 0 !important;
		border: none !important;
		box-shadow: none !important;
	}
	.bg-light { background-color: #fff !important; }
	.mt-4, .mb-4 { margin: 0 !important; }

	/* Page size for browser print dialog */
	@page { size: A4 portrait; margin: 55px 80px; }

	.rmds-items-table th {
		background-color: #000 !important;
		color: #fff !important;
		-webkit-print-color-adjust: exact;
		print-color-adjust: exact;
	}
}
