/* ═══════════════════════════════════════════════
   PAGOS DE COMPRAS — Cuentas x Pagar
═══════════════════════════════════════════════ */

:root {
	--pc-primary: #052767;
	--pc-blue: #1565c0;
	--pc-border: #dce6f0;
	--pc-shadow: 0 1px 5px rgba(5, 39, 103, .07);
	--pc-radius: 6px;
}

/* ── Layout ──────────────────────────────────── */
.pc-page {
	display: flex;
	flex-direction: column;
	flex: 1;
	min-height: 0;
	overflow: hidden;
}
.pc-scroll {
	flex: 1;
	overflow-y: auto;
	padding: 0.85rem 1rem 1.5rem;
	display: flex;
	flex-direction: column;
	gap: 0.85rem;
}

/* ── Cabecera: grid de dos columnas alineadas ─── */
.pc-cabecera-grid {
	display: grid;
	grid-template-columns: minmax(340px, 500px) 1fr minmax(270px, 360px);
	row-gap: 1rem;
	align-items: start;
}
.pc-cg-l { grid-column: 1; }
.pc-cg-r { grid-column: 3; }
.pc-cab-subrow {
	display: flex;
	gap: 0.5rem;
	align-items: flex-end;
}

/* ── Barra de estado (encima del formulario) ─── */
.pc-status-bar {
	display: flex;
	justify-content: space-between;
	align-items: flex-end;
	padding: 0.35rem 0 0.6rem;
	border-bottom: 1px solid var(--pc-border);
	margin-bottom: 0.75rem;
}
.pc-status-left {
	display: flex;
	align-items: center;
}
.pc-status-right {
	display: flex;
	align-items: center;
	gap: 0.75rem;
}
.pc-status-num {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	height: 26px;
	padding: 0 14px;
	font-size: 12px;
	font-weight: 700;
	color: #052767;
	letter-spacing: .04em;
	border: 1.5px solid #c5d4e8;
	border-radius: 6px;
	background: #f0f5fb;
	white-space: nowrap;
}
.pc-status-num--pendiente {
	color: #1d4ed8;
	background: #eff6ff;
	border-color: #bfdbfe;
}

/* ── Fecha en status bar ─────────────────────── */
.pc-status-fecha {
	margin-left: 0.5rem;
}
.pc-status-fecha .rz-inputwrapper,
.pc-status-fecha .rz-datepicker-input,
.pc-status-fecha input {
	height: 26px !important;
	min-height: 26px !important;
	font-size: 12px !important;
	font-weight: 700 !important;
	color: #052767 !important;
	border: 1.5px solid #c5d4e8 !important;
	border-radius: 6px !important;
	background: #f0f5fb !important;
	box-shadow: none !important;
	padding: 0 8px !important;
	line-height: 26px !important;
}
.pc-status-fecha .rz-inputwrapper {
	padding: 0 !important;
}
.pc-status-fecha button.rz-datepicker-trigger {
	height: 26px !important;
	width: 26px !important;
	border: none !important;
	border-left: 1.5px solid #c5d4e8 !important;
	background: #e8f0fb !important;
	border-radius: 0 6px 6px 0 !important;
	color: #052767 !important;
}

/* ── Tabla detalle HTML ──────────────────────── */
.pc-det-table {
	width: 100%;
	border-collapse: collapse;
	margin-top: 1rem;
	font-size: 12px;
}
.pc-det-table thead th {
	padding: 6px 8px;
	font-size: 11px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: .05em;
	color: #333;
	background: #e0e0e0;
	border-bottom: none;
	text-align: left;
}
.pc-det-table tbody td {
	padding: 3px 6px;
	vertical-align: middle;
	border-bottom: 1px solid #e8eef5;
}
.pc-det-table tbody tr:last-child td {
	border-bottom: none;
}

/* Inputs dentro de la tabla: sin borde */
.pc-det-table td input,
.pc-det-table td .rz-inputwrapper,
.pc-det-table td .rz-numeric,
.pc-det-table td [class*="rz-"] {
	border: none !important;
	box-shadow: none !important;
	background: transparent !important;
	border-radius: 0 !important;
	outline: none !important;
}
.pc-det-table td input:focus {
	outline: none !important;
	box-shadow: none !important;
}

/* ── Totales ─────────────────────────────────── */
.pc-totales {
	background: #fff;
	border: 1px solid var(--pc-border);
	border-radius: var(--pc-radius);
	overflow: hidden;
	box-shadow: var(--pc-shadow);
	width: 300px;
	flex-shrink: 0;
}
.pc-tot-head {
	display: flex;
	align-items: center;
	gap: 0.5rem;
	padding: 0.5rem 1rem;
	background: linear-gradient(90deg, #eef3f9, #f8fafc);
	border-bottom: 1px solid var(--pc-border);
	font-size: 10.5px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: .07em;
	color: var(--pc-primary);
}
.pc-tot-body {
	padding: 0.65rem 1rem;
	display: flex;
	flex-direction: column;
	gap: 0;
}
.pc-tot-row {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 0.28rem 0;
	font-size: 0.85rem;
	color: #64748b;
}
.pc-tot-row span:last-child {
	font-weight: 600;
	color: #1e293b;
}
.pc-tot-hr {
	border: none;
	border-top: 1px solid var(--pc-border);
	margin: 0.35rem 0;
}
.pc-tot-total {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 0.7rem 1rem;
	background: var(--pc-primary);
}
.pc-tot-total-lbl {
	font-size: 13px;
	font-weight: 700;
	color: #fff;
}
.pc-tot-total-val {
	font-size: 21px;
	font-weight: 800;
	color: #fff;
}

/* ── Badge lista ─────────────────────────────── */
.pc-badge {
	font-size: 0.68rem;
	padding: 2px 9px;
	border-radius: 10px;
	font-weight: 600;
}

/* ── Overlay de cobro ────────────────────────── */
.pc-cobro-overlay {
	position: fixed;
	inset: 0;
	background: rgba(0, 0, 0, .45);
	display: flex;
	align-items: center;
	justify-content: center;
	z-index: 900;
}
.pc-cobro-dialog {
	width: min(644px, 70vw);
	overflow: hidden;
	display: flex;
	flex-direction: column;
	border-radius: 10px;
	box-shadow: 0 16px 48px rgba(0, 0, 0, .35);
	background: #fff;
}
