/* Estilos compartidos de las pantallas y cuadros de diálogo nuevos de Logística (regímenes, programación de pagos, ítems, presupuestos, almacén).
   Antes cada página y cada diálogo repetía estas reglas en su propio <style>. Los prefijos adm-/rcp-/overstay- son los de las pantallas ya existentes. */

/* ---- pantallas ---- */
.adm-pagina { padding: 16px; font-family: Inter, sans-serif; color: #23232A; }
.adm-barra { display: flex; gap: 12px; margin-bottom: 12px; flex-wrap: wrap; align-items: flex-end; }
.adm-estado { display: flex; align-items: center; gap: 16px; padding: 32px 0; color: #404048; }
.adm-alerta { margin-bottom: 12px; }
.adm-btn { height: 35px; min-width: 90px; padding: 0 16px; border-radius: 4px; font: inherit; font-size: 14px; font-weight: 500; cursor: pointer; }
.adm-btn-primario { background: #272789; color: #ffffff; border: 1px solid #272789; }
.adm-btn-primario:hover:not(:disabled) { background: #4F487E; border-color: #4F487E; }
.adm-btn-secundario { background: #ffffff; color: #272789; border: 1px solid #272789; }
.adm-btn-secundario:hover:not(:disabled) { background: #E5E5EE; }
.adm-btn:disabled { opacity: .6; cursor: default; }
.adm-tag { display: inline-block; padding: 2px 10px; border-radius: 4px; font-size: 12px; color: #404048; }
.adm-tag + .adm-tag { margin-left: 4px; }
.adm-tag-activo, .adm-tag-procesado { background: #C5DCAB; }
.adm-tag-inactivo, .adm-tag-anulado { background: #E0E0E0; }
.adm-tag-pendiente, .adm-tag-alerta { background: #F5D7A1; }
.rcp-tabs { display: flex; flex-wrap: wrap; gap: 4px; align-items: center; margin-bottom: 12px; border-bottom: 2px solid #E5E5EE; }
.rcp-tab { background: none; border: none; border-bottom: 3px solid transparent; margin-bottom: -2px; padding: 8px 14px; font: inherit; font-size: 14px; font-weight: 500; color: #404048; cursor: pointer; }
.rcp-tab:hover { color: #272789; }
.rcp-tab-act { color: #272789; border-bottom-color: #272789; }
.rcp-actualizar { margin-left: auto; margin-bottom: 4px; }
.rcp-ayuda { font-size: 13px; color: #404048; margin: 0 0 10px; max-width: 920px; }
.rcp-ant { margin-left: 6px; font-size: 11px; color: #848494; }
.overstay-grid-window thead { position: sticky; top: 0; z-index: 3; }
.overstay-grid-window thead tr:first-child th { position: sticky; top: 0; z-index: 4; background: linear-gradient(180deg, #E5ECF3 0%, #FFFFFF 100%) !important; }
.overstay-grid-window thead tr:nth-child(2) th { position: sticky; top: 44px; z-index: 3; background: #FFFFFF !important; box-shadow: inset 0 -1px 0 rgba(0,0,0,0.08); }
.overstay-grid-window .mud-table-root .mud-table-head th { background: linear-gradient(180deg, #E5ECF3 0%, #FFFFFF 100%) !important; color: #333F46; font-weight: 600; border: 1px solid rgba(175,195,218,.98); white-space: normal; text-align: center; }
.overstay-grid-window tbody tr:nth-child(even) { background-color: #eef6fe; }
.overstay-grid-window tbody td { border-bottom: none !important; border-top: none !important; vertical-align: middle; padding: 4px 8px; }

/* ---- cuadros de diálogo ---- */
.dlg-form { display: flex; flex-direction: column; gap: 10px; padding-top: 4px; font-family: Inter, sans-serif; color: #23232A; }
.dlg-fila { display: flex; flex-wrap: wrap; gap: 12px; align-items: flex-end; }
.dlg-campo { display: flex; flex-direction: column; gap: 3px; font-size: 12px; color: #404048; flex: 1; min-width: 140px; }
.dlg-campo input, .dlg-campo select { height: 35px; padding: 0 10px; border: 1px solid #B2B2C2; border-radius: 4px; font: inherit; font-size: 14px; background: #fff; color: #23232A; }
.dlg-campo input:focus, .dlg-campo select:focus { outline: 2px solid #5050D1; border-color: #5050D1; }
.dlg-chk { font-size: 13px; display: inline-flex; align-items: center; gap: 6px; min-height: 35px; }
.dlg-ayuda { font-size: 12px; color: #404048; }
.dlg-btn { height: 35px; min-width: 90px; padding: 0 16px; border-radius: 4px; font: inherit; font-size: 14px; font-weight: 500; cursor: pointer; margin-left: 8px; }
.dlg-btn-pri { background: #272789; color: #fff; border: 1px solid #272789; }
.dlg-btn-pri:hover:not(:disabled) { background: #4F487E; border-color: #4F487E; }
.dlg-btn-sec { background: #fff; color: #272789; border: 1px solid #272789; }
.dlg-btn:disabled { opacity: .6; cursor: default; }

/* Celular: los formularios de los diálogos usan «min-width: min(Npx, Xvw)» y se salen del ancho útil (margen y relleno del diálogo).
   En pantallas angostas el contenido toma el ancho disponible, con menos relleno lateral. */
@media (max-width: 600px) {
    .mud-dialog { margin: 8px; max-width: calc(100% - 16px); }
    .mud-dialog .mud-dialog-content { padding-left: 12px; padding-right: 12px; overflow-x: auto; }
    .mud-dialog .mud-dialog-content > * { min-width: 0 !important; max-width: 100%; box-sizing: border-box; }
}
