/* ========================== RESET ========================== */

* {
	margin: 0;
	padding: 0;
	box-sizing: border-box;
}


/* ========================== GENERAL ========================== */

body {
	font-family: "Segoe UI", Arial, sans-serif;
	background-color: #f4f4f4;
	color: #333;
}


/* ========================== HEADER ========================== */

header {
	background-color: #007bff;
	padding: 10px 20px;
	color: white;
}

header .header-content {
	display: flex;
	justify-content: space-between;
	align-items: center;
}

header .logo img {
	max-width: 100%;
}

header .usuario p {
	font-size: 16px;
	font-weight: bold;
}


/* ========================== CONTENEDOR PRINCIPAL ========================== */

.main-container {
	display: flex;
}


/* ========================== MENÚ VERTICAL (REDISEÑADO CHINGÓN) ========================== */

nav.menu {
	width: 260px;
	background-color: #1e272e;
	/* Gris azulado profundo muy elegante */
	padding: 25px 15px;
	color: white;
	min-height: 100vh;
	box-shadow: 4px 0 15px rgba(0, 0, 0, 0.1);
	z-index: 100;
}

nav.menu ul {
	list-style-type: none;
}

nav.menu li {
	margin: 8px 0;
}

nav.menu li a {
	color: rgba(255, 255, 255, 0.7);
	text-decoration: none;
	font-size: 14px;
	font-weight: 500;
	display: flex;
	justify-content: flex-start;
	align-items: center;
	gap: 12px;
	padding: 12px 18px;
	background-color: transparent;
	border-radius: 12px;
	/* Estilo cápsula moderno */
	transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
	cursor: pointer;
}


/* Hover y Estado Activo */

nav.menu li a:hover,
nav.menu li a.active {
	background-color: #007bff;
	color: #ffffff;
	transform: translateX(8px);
	/* Efecto de empuje hacia la derecha */
	box-shadow: 0 4px 15px rgba(0, 123, 255, 0.4);
}

nav.menu li a i {
	font-size: 18px;
	width: 25px;
	text-align: center;
}


/* Estilos para el Submenú Desplegable */

.submenu {
	max-height: 0;
	overflow: hidden;
	transition: all 0.4s ease-in-out;
	padding: 0;
	list-style: none;
	background: rgba(255, 255, 255, 0.03);
	/* Fondo sutil para el área del submenú */
	border-radius: 10px;
	margin: 5px 5px 0 15px;
	/* Indentado para jerarquía */
}

.submenu.open {
	max-height: 500px;
	padding: 5px 0;
	margin-bottom: 10px;
}

.submenu li a {
	padding: 10px 15px;
	font-size: 13px;
	color: rgba(255, 255, 255, 0.6);
}

.submenu li a:hover {
	background-color: rgba(255, 255, 255, 0.1);
	transform: translateX(5px);
}

.menu-arrow {
	margin-left: auto;
	font-size: 12px;
	transition: transform 0.3s;
}

.has-submenu.open .menu-arrow {
	transform: rotate(180deg);
}


/* ========================== CONTENIDO PRINCIPAL ========================== */

.content {
	flex: 1;
	padding: 20px 20px 20px 40px;
	overflow-x: hidden;
}


/* ========================== DASHBOARD STAT BOXES ========================== */

.stats-container {
	display: flex;
	flex-wrap: wrap;
	gap: 20px;
	margin-top: 20px;
}

.stat-box {
	flex: 1 1 250px;
	background-color: white;
	padding: 20px;
	border-radius: 12px;
	box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
	text-align: center;
	transition: transform 0.3s, box-shadow 0.3s;
}

.stat-box:hover {
	transform: translateY(-5px);
	box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.stat-box h3 {
	font-size: 20px;
	color: #555;
	margin-bottom: 10px;
}

.stat-box p {
	font-size: 28px;
	font-weight: bold;
	color: #007bff;
}


/* ========================== CHARTS CONTAINER ========================== */

.charts-container {
	display: flex;
	flex-wrap: wrap;
	gap: 20px;
	margin-top: 30px;
	justify-content: center;
}

.chart-box {
	flex: 1 1 400px;
	min-width: 300px;
	background-color: white;
	padding: 20px;
	border-radius: 12px;
	box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
	transition: transform 0.3s, box-shadow 0.3s;
	display: flex;
	flex-direction: column;
	align-items: center;
	height: 400px;
}

.chart-box:hover {
	transform: translateY(-5px);
	box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.chart-box h3 {
	text-align: center;
	margin-bottom: 15px;
	color: #333;
	font-size: 20px;
}

.chart-box canvas {
	width: 100% !important;
	height: 100% !important;
	max-width: 100%;
	transition: transform 0.3s;
}

.chart-box:hover canvas {
	transform: scale(1.02);
}


/* ========================== BOTONES (DASHBOARD) ========================== */

.btn-group {
	display: flex;
	flex-wrap: wrap;
	gap: 20px;
	justify-content: center;
	margin-top: 30px;
}

.btn {
	display: inline-block;
	width: 200px;
	height: 200px;
	background-color: #007bff;
	color: white;
	text-decoration: none;
	text-align: center;
	line-height: 200px;
	font-size: 18px;
	font-weight: bold;
	border-radius: 15px;
	transition: transform 0.3s, box-shadow 0.3s;
	box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.btn i {
	font-size: 30px;
	margin-bottom: 10px;
}

.btn:hover {
	transform: scale(1.1);
	box-shadow: 0 6px 15px rgba(0, 0, 0, 0.2);
}


/* ========================== FOOTER ========================== */

footer {
	background-color: #333;
	color: white;
	padding: 10px 0;
	text-align: center;
}

footer .footer-content p {
	margin: 0;
	font-size: 14px;
}


/* ========================== LOGIN ========================== */

.login-container {
	width: 100%;
	max-width: 400px;
	padding: 20px;
	background-color: #fff;
	border-radius: 8px;
	box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
	text-align: center;
	margin: 50px auto;
}

.login-form h2 {
	font-size: 24px;
	color: #333;
	margin-bottom: 20px;
}

.input-group {
	margin-bottom: 15px;
	text-align: left;
	width: 100%;
}

.input-group label {
	font-size: 14px;
	color: #555;
	display: block;
	margin-bottom: 5px;
}

.input-group input {
	width: 100%;
	padding: 10px;
	border: 1px solid #ccc;
	border-radius: 5px;
	font-size: 16px;
	outline: none;
}

.input-group input:focus {
	border-color: #007bff;
}

.btn-login {
	width: 100%;
	padding: 12px;
	background-color: #007bff;
	color: white;
	border: none;
	border-radius: 5px;
	font-size: 16px;
	cursor: pointer;
	transition: background-color 0.3s;
}

.btn-login:hover {
	background-color: #45a049;
}


/* ========================== RESPONSIVE (Ajustes Globales) ========================== */

@media (max-width: 1024px) {
	.main-container {
		flex-direction: column;
	}
	nav.menu li a {
		padding: 10px 15px;
		border-radius: 10px;
	}
	.content {
		margin-left: 0;
		padding: 15px;
		overflow-x: hidden;
	}
	.stats-container,
	.charts-container {
		flex-direction: column;
		gap: 20px;
	}
	.chart-box {
		flex: 1 1 100%;
		height: 350px;
	}
	.chart-box canvas {
		height: 100% !important;
	}
}

@media (max-width: 768px) {
	nav.menu li a {
		flex-direction: row;
		justify-content: flex-start;
		padding: 5px 10px;
		font-size: 13px;
		text-align: left;
		gap: 5px;
		min-height: 40px;
	}
	nav.menu li a i {
		font-size: 16px;
		margin: 0;
	}
	.content> a.btn-agregar,
	.content> a.btn-exportar {
		width: 100%;
		text-align: center;
		margin-left: 0;
		margin-bottom: 10px;
	}
}

@media (max-width: 480px) {
	.btn {
		width: 150px;
		height: 150px;
		line-height: 150px;
		font-size: 16px;
	}
	.stat-box p {
		font-size: 24px;
	}
	.chart-box {
		padding: 15px;
		height: 300px;
	}
	.chart-box h3 {
		font-size: 18px;
	}
}


/* ========================== CRUD / TABLAS ========================== */

.crud-container {
	background-color: #fff;
	padding: 30px;
	border-radius: 15px;
	box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
	margin: 20px auto;
	max-width: 1000px;
}

.crud-container h2 {
	text-align: center;
	margin-bottom: 25px;
	color: #333;
	font-size: 26px;
}


/* ========================== AGRUPADOR DE BOTONES CRUD ========================== */

.crud-actions-container {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin-bottom: 20px;
	align-items: center;
}

.crud-actions-container form {
	margin: 0;
}

a.btn-agregar {
	display: inline-block;
	background-color: #007bff;
	color: white;
	padding: 10px 20px;
	text-decoration: none;
	border-radius: 8px;
	font-weight: bold;
	transition: background-color 0.3s, transform 0.3s;
}

a.btn-agregar:hover {
	background-color: #45a049;
	transform: scale(1.05);
}

a.btn-exportar {
	display: inline-block;
	background-color: #28a745;
	color: white;
	padding: 10px 20px;
	text-decoration: none;
	border-radius: 8px;
	font-weight: bold;
	transition: background-color 0.3s, transform 0.3s;
}

a.btn-exportar:hover {
	background-color: #218838;
	transform: scale(1.05);
}

.btn-reporte {
	display: inline-block;
	padding: 10px 15px;
	background-color: #dc3545;
	color: white;
	text-decoration: none;
	border-radius: 5px;
	font-weight: bold;
	transition: background-color 0.3s;
	border: none;
	cursor: pointer;
}

.btn-reporte:hover {
	background-color: #c82333;
}

.table-responsive {
	overflow-x: auto;
	width: 100%;
	margin-top: 20px;
}

table {
	width: 100%;
	border-collapse: collapse;
	margin-top: 15px;
	background-color: #fff;
	border-radius: 10px;
	overflow: hidden;
}

table th,
table td {
	border: 1px solid #ddd;
	padding: 8px 10px;
	text-align: center;
	font-size: 13px;
	white-space: nowrap;
}

.table-responsive table td:nth-child(9) {
	white-space: normal;
	max-width: 250px;
	text-align: left;
}

table th {
	background-color: #007bff;
	color: white;
}

table tr:nth-child(even) {
	background-color: #f9f9f9;
}

table tr:hover {
	background-color: #f1f1f1;
}

table td.acciones a,
table td.acciones button {
	padding: 4px 8px;
	color: white;
	border-radius: 4px;
	margin: 0 1px;
	font-weight: bold;
	font-size: 11px;
	transition: transform 0.2s, opacity 0.3s;
	display: inline-block;
	cursor: pointer;
	border: none;
	line-height: 1.2;
}

table td.acciones a {
	text-decoration: none;
}

a.btn-editar {
	background-color: #2196F3;
}

a.btn-eliminar {
	background-color: #f44336;
}

.btn-detalle {
	background-color: #007bff;
}

.btn-info {
	background-color: #007bff;
	color: white;
}

.btn-danger {
	background-color: #dc3545;
	color: white;
}

.btn-success {
	background-color: #28a745;
	color: white;
}

table td.acciones a:hover,
table td.acciones button:hover {
	transform: scale(1.1);
	opacity: 0.9;
}

a.btn-volver {
	display: inline-block;
	padding: 10px 20px;
	background-color: #6c757d;
	color: white;
	text-decoration: none;
	border-radius: 8px;
	margin-top: 20px;
	transition: background-color 0.3s;
}

a.btn-volver:hover {
	background-color: #5a6268;
}

@media (max-width: 768px) {
	.table-responsive table td.acciones {
		min-width: 120px;
		white-space: normal;
	}
	.table-responsive table td.acciones a {
		margin: 5px 2px;
	}
}


/* ========================== FORMULARIOS MODERNOS ========================== */

form.form-crud {
	background-color: #fff;
	padding: 30px;
	border-radius: 12px;
	box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
	max-width: 600px;
	margin: 30px auto;
	transition: transform 0.3s, box-shadow 0.3s;
}

form.form-crud:hover {
	transform: translateY(-3px);
	box-shadow: 0 12px 25px rgba(0, 0, 0, 0.15);
}

form label {
	display: block;
	margin-bottom: 5px;
	font-weight: bold;
	color: #333;
}

form input[type="text"],
form input[type="number"],
form select,
form textarea,
form input[type="date"] {
	width: 100%;
	padding: 12px;
	margin-bottom: 15px;
	border: 1px solid #ccc;
	border-radius: 8px;
	font-size: 16px;
	outline: none;
	transition: border-color 0.3s, box-shadow 0.3s;
}

form input[type="text"]:focus,
form input[type="number"]:focus,
form select:focus,
form textarea:focus,
form input[type="date"]:focus {
	border-color: #007bff;
	box-shadow: 0 0 5px rgba(76, 175, 80, 0.4);
}


/* ========================== ESTILOS PARA INPUTS ESPECÍFICOS ========================== */

form input[type="email"],
form input[type="password"] {
	width: 100%;
	padding: 12px;
	margin-bottom: 15px;
	border: 1px solid #ccc;
	border-radius: 8px;
	font-size: 16px;
	outline: none;
	background-color: #fff;
	transition: border-color 0.3s, box-shadow 0.3s;
}

form input[type="email"]:focus,
form input[type="password"]:focus {
	border-color: #007bff;
	box-shadow: 0 0 5px rgba(0, 123, 255, 0.4);
}

form input[name="smtp_password"] {
	background-color: #fffaf0;
	border: 1px dashed #ff9800;
}


/* ================================================================================================= */

form textarea[name="caracteristicas"] {
	min-height: 120px;
	resize: vertical;
	font-family: "Segoe UI", Arial, sans-serif;
}

form input[type="submit"],
form button {
	background-color: #007bff;
	color: white;
	padding: 12px 25px;
	border: none;
	border-radius: 8px;
	font-size: 16px;
	cursor: pointer;
	transition: background-color 0.3s, transform 0.3s;
}

form input[type="submit"]:hover,
form button:hover {
	background-color: #45a049;
	transform: scale(1.05);
}


/* Estilos de Paginación */

.btn-paginacion {
	padding: 5px 10px;
	background-color: #009bff;
	color: white;
	text-decoration: none;
	margin: 0 3px;
	border-radius: 10px;
	font-size: 12px;
	display: inline-block;
	text-align: center;
}

.btn-paginacion:hover {
	background-color: #009bff;
}

.btn-paginacion.activo {
	font-weight: bold;
	background-color: #004bff;
}


/* Estilos para el formulario de búsqueda */

.formulario-busqueda {
	display: flex;
	justify-content: flex-end;
	margin-bottom: 20px;
}

.formulario-busqueda input[type="text"] {
	padding: 8px 12px;
	font-size: 16px;
	width: 250px;
	border: 1px solid #ccc;
	border-radius: 5px;
	margin-right: 10px;
	box-sizing: border-box;
}

.formulario-busqueda button {
	background-color: #007bff;
	color: white;
	padding: 8px 20px;
	border: none;
	border-radius: 5px;
	cursor: pointer;
	font-size: 16px;
	transition: background-color 0.3s ease;
}

.formulario-busqueda button:hover {
	background-color: #45a049;
}

@media (max-width: 768px) {
	.formulario-busqueda {
		flex-direction: column;
		align-items: flex-end;
	}
	.formulario-busqueda input[type="text"] {
		width: 100%;
	}
	.formulario-busqueda button {
		width: 100%;
		margin-top: 10px;
	}
}


/* ========================== CONFIGURACIÓN (Panel de Opciones) ========================== */

.btn-group-config {
	display: flex;
	flex-wrap: wrap;
	gap: 25px;
	justify-content: center;
	margin-top: 30px;
}

.btn-config {
	display: flex;
	flex-direction: column;
	justify-content: center;
	align-items: center;
	text-align: center;
	width: 200px;
	height: 120px;
	padding: 10px 5px;
	background-color: white;
	color: #333;
	text-decoration: none;
	border-radius: 15px;
	border: 1px solid rgba(0, 123, 255, 0.1);
	box-shadow: 0 6px 20px rgba(0, 0, 0, 0.08);
	font-weight: 600;
	font-size: 14px;
	word-break: break-word;
	white-space: normal;
	transition: all 0.35s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.btn-config:hover {
	background-color: #007BFF;
	color: white;
	transform: translateY(-8px);
	box-shadow: 0 15px 30px rgba(0, 123, 255, 0.4);
}

.btn-config i {
	font-size: 36px;
	line-height: 1;
	margin-bottom: 0px;
	color: #007BFF;
	transition: color 0.35s;
}

.btn-config span {
	display: flex;
	justify-content: center;
	align-items: center;
	margin-top: 5px;
	line-height: 1.2;
	padding: 0 5px;
}

.btn-config:hover i {
	color: white;
}


/* --- RESPONSIVE CONFIG --- */

@media (max-width: 650px) {
	.btn-group-config {
		gap: 15px;
		margin-top: 20px;
	}
	.btn-config {
		flex: 1 1 100%;
		width: auto;
		height: auto;
		padding: 10px 15px;
		flex-direction: row;
		justify-content: flex-start;
		font-size: 15px;
		box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
		white-space: nowrap;
		overflow: hidden;
		align-items: center;
	}
	.btn-config:hover {
		transform: translateY(-2px);
	}
	.btn-config i {
		font-size: 22px;
		margin-right: 12px;
		margin-bottom: 0;
		flex-shrink: 0;
		vertical-align: middle;
	}
	.btn-config span {
		margin-top: 0;
		padding: 0;
	}
}


/* ======================================= */


/* Estilos para campos de Fecha/Hora */


/* ======================================= */

input[type="datetime-local"] {
	width: 100%;
	padding: 10px;
	margin-bottom: 15px;
	box-sizing: border-box;
	border: 1px solid #ccc;
	border-radius: 4px;
	background-color: #fff;
	font-family: inherit;
	font-size: 1em;
	color: #333;
	transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

input[type="datetime-local"]:focus {
	border-color: #007bff;
	box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
	outline: none;
}

input[type="datetime-local"]::-webkit-calendar-picker-indicator {
	padding: 0 5px;
	cursor: pointer;
}


/* ======================================= */


/* ESTILOS DEL HEADER RESPONSIVO */


/* ======================================= */

.header-content {
	max-width: 1200px;
	margin: 0 auto;
}

header .logo {
	padding-right: 20px;
	margin-left: 0 !important;
}

header .logo img {
	max-width: 120px;
	height: auto;
}

header .usuario {
	text-align: right;
	font-size: 0.95em;
	color: white;
}

header .usuario p {
	margin: 0;
	font-weight: bold;
	color: white;
}


/* ======================================= */


/* MEDIA QUERIES (Responsividad del Header) */


/* ======================================= */

@media (max-width: 768px) {
	header {
		padding: 10px 15px;
	}
	header .logo img {
		max-width: 100px;
	}
	header .usuario {
		font-size: 0.85em;
	}
}

@media (max-width: 576px) {
	header .logo img {
		max-width: 80px;
	}
}


/* ======================================= */


/* 🍔 MENÚ HAMBURGUESA (Side Nav Móvil) */


/* ======================================= */

.hamburger-menu {
	display: none;
	background: none;
	border: none;
	color: #fff;
	font-size: 24px;
	padding: 0 10px;
	cursor: pointer;
	z-index: 1001;
}

@media (max-width: 1024px) {
	.hamburger-menu {
		display: block;
		position: absolute;
		left: 15px;
		top: 10px;
	}
	header .header-content {
		justify-content: flex-end;
		margin-left: 50px;
	}
	nav.menu {
		position: fixed;
		top: 0;
		left: -260px;
		width: 260px;
		height: 100%;
		transition: left 0.3s ease-in-out;
		overflow-y: auto;
		padding-top: 60px;
	}
	nav.menu.open {
		left: 0;
		box-shadow: 2px 0 10px rgba(0, 0, 0, 0.5);
	}
	nav.menu ul {
		padding: 0 10px;
	}
}


/* ========================== ESTÉTICA ENTERPRISE (ULTRA-SLIM) ========================== */


/* 1. Contenedor: Menos sombras, más bordes finos */

.tabla-crud,
.table-responsive {
	background: #ffffff !important;
	border-radius: 6px !important;
	border: 1px solid #e2e8f0 !important;
	box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03) !important;
	padding: 0 !important;
	margin-top: 0px !important;
}


/* 2. La Tabla: Dieta rigurosa de altura */

table {
	border-collapse: collapse !important;
	width: 100% !important;
}

table thead th {
	background-color: #f8fafc !important;
	color: #475569 !important;
	font-size: 10.5px !important;
	font-weight: 700 !important;
	text-transform: uppercase !important;
	letter-spacing: 0.05em !important;
	padding: 8px 12px !important;
	border-bottom: 2px solid #e2e8f0 !important;
	text-align: left !important;
}

table tbody td {
	padding: 6px 12px !important;
	font-size: 12.5px !important;
	color: #1e293b !important;
	border-bottom: 1px solid #f1f5f9 !important;
	vertical-align: middle !important;
	line-height: 1.2 !important;
}


/* --- AJUSTE DE FECHA Y HORA (MAS NOTORIA) --- */

table tbody td small {
	font-size: 12.5px !important;
	/* Igualamos al tamaño base para legibilidad */
	color: #475569 !important;
	/* Gris slate oscuro */
	font-weight: 500;
}

table tbody tr:hover {
	background-color: #f1f5f9 !important;
}


/* 3. Botones de Acción: Pequeños y Elegantes */

.acciones {
	display: flex !important;
	gap: 4px !important;
	justify-content: center !important;
}

.btn-accion {
	width: 26px !important;
	height: 26px !important;
	border-radius: 4px !important;
	display: inline-flex !important;
	align-items: center !important;
	justify-content: center !important;
	transition: all 0.2s ease !important;
	border: none !important;
	text-decoration: none !important;
	background-color: #f1f5f9 !important;
}

.btn-accion i {
	font-size: 12px !important;
	color: #64748b !important;
}

.btn-ver:hover {
	background-color: #3b82f6 !important;
}

.btn-ver:hover i {
	color: #ffffff !important;
}

.btn-pdf:hover {
	background-color: #ef4444 !important;
}

.btn-pdf:hover i {
	color: #ffffff !important;
}

.btn-email:hover {
	background-color: #10b981 !important;
}

.btn-email:hover i {
	color: #ffffff !important;
}

.btn-cancelar:hover {
	background-color: #f59e0b !important;
}

.btn-cancelar:hover i {
	color: #ffffff !important;
}


/* 4. Badges: Estilo Flat Slim */

.badge-estado,
.badge {
	padding: 2px 6px !important;
	border-radius: 3px !important;
	font-size: 9px !important;
	font-weight: 800 !important;
	text-transform: uppercase !important;
}

.completada {
	background: #dcfce7 !important;
	color: #15803d !important;
	border: 1px solid #bbf7d0 !important;
}

.cancelada {
	background: #fee2e2 !important;
	color: #b91c1c !important;
	border: 1px solid #fecaca !important;
}


/* --- ESTILOS MODERNOS CONFIGURACIÓN EMPRESA --- */

.config-container {
	max-width: 750px;
	/* Tamaño ajustado para que no se vea gigante */
	margin: 20px auto;
	background: #fff;
	border-radius: 12px;
	box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
	border: 1px solid #eef2f6;
	overflow: hidden;
}

.config-header {
	padding: 30px 20px;
	text-align: center;
	background: #fafbfc;
	border-bottom: 1px solid #eee;
}

.logo-preview {
	width: 120px;
	height: 120px;
	object-fit: contain;
	border-radius: 12px;
	padding: 8px;
	border: 2px dashed #cbd5e0;
	margin-bottom: 10px;
	background: #fff;
}

.config-body {
	padding: 30px;
}

.config-grid {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 20px;
}

.config-full {
	grid-column: span 2;
}

.config-group label {
	display: block;
	font-size: 12px;
	font-weight: 700;
	color: #64748b;
	text-transform: uppercase;
	margin-bottom: 6px;
}

.config-input {
	width: 100%;
	padding: 10px 14px;
	border: 2px solid #e2e8f0;
	border-radius: 8px;
	font-size: 14px;
	box-sizing: border-box;
	transition: 0.3s;
}

.config-input:focus {
	border-color: #3b82f6;
	outline: none;
	box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.config-input:disabled {
	background: #f8fafc;
	color: #94a3b8;
	cursor: not-allowed;
}


/* Switches Estilo iOS */

.switch-row {
	display: flex;
	align-items: center;
	justify-content: space-between;
	background: #f8fafc;
	padding: 12px 15px;
	border-radius: 10px;
	border: 1px solid #e2e8f0;
}

.switch-label-box strong {
	display: block;
	font-size: 14px;
	color: #334155;
}

.switch-label-box small {
	color: #94a3b8;
	font-size: 11px;
}

.ios-switch {
	position: relative;
	display: inline-block;
	width: 44px;
	height: 24px;
}

.ios-switch input {
	opacity: 0;
	width: 0;
	height: 0;
}

.ios-slider {
	position: absolute;
	cursor: pointer;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	background-color: #cbd5e0;
	transition: .4s;
	border-radius: 34px;
}

.ios-slider:before {
	position: absolute;
	content: "";
	height: 18px;
	width: 18px;
	left: 3px;
	bottom: 3px;
	background-color: white;
	transition: .4s;
	border-radius: 50%;
}

.ios-switch input:checked+ .ios-slider {
	background-color: #22c55e;
}

.ios-switch input:checked+ .ios-slider:before {
	transform: translateX(20px);
}

.ios-switch input:disabled+ .ios-slider {
	opacity: 0.5;
}

.config-footer {
	display: flex;
	gap: 10px;
	margin-top: 30px;
}


/* --- CENTRO DE REPORTES INTELIGENTE --- */

.report-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
	gap: 20px;
	margin-top: 20px;
}

.report-card {
	background: white;
	padding: 25px;
	border-radius: 15px;
	border-top: 5px solid #007bff;
	box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
	text-align: center;
	cursor: pointer;
	transition: all 0.3s ease;
	display: flex;
	flex-direction: column;
	align-items: center;
}

.report-card:hover {
	transform: translateY(-8px);
	border-top-color: #28a745;
	box-shadow: 0 12px 25px rgba(0, 0, 0, 0.1);
}

.report-card i {
	font-size: 2.8rem;
	color: #007bff;
	margin-bottom: 15px;
}

.report-card h3 {
	margin-bottom: 10px;
	color: #333;
	font-size: 1.1rem;
	font-weight: 700;
}

.report-card p {
	color: #777;
	font-size: 0.85rem;
	line-height: 1.4;
}

.filter-section {
	background: #fff;
	padding: 30px;
	border-radius: 15px;
	margin-top: 40px;
	display: none;
	box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
	animation: slideUp 0.4s ease-out;
}

@keyframes slideUp {
	from {
		opacity: 0;
		transform: translateY(20px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

.form-row {
	display: flex;
	gap: 20px;
	flex-wrap: wrap;
	margin-bottom: 20px;
}

.filter-group {
	flex: 1;
	min-width: 200px;
}

.filter-group label {
	display: block;
	font-weight: 600;
	margin-bottom: 8px;
	color: #555;
}

.input-report {
	width: 100%;
	padding: 12px;
	border: 1px solid #ddd;
	border-radius: 8px;
	font-size: 1rem;
	outline: none;
	transition: 0.3s;
}

.input-report:focus {
	border-color: #007bff;
	box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.1);
}

.actions-report {
	border-top: 1px solid #eee;
	padding-top: 25px;
	display: flex;
	gap: 15px;
}

.btn-report {
	padding: 12px 28px;
	border-radius: 8px;
	cursor: pointer;
	font-weight: 700;
	display: flex;
	align-items: center;
	gap: 10px;
	border: none;
	transition: 0.3s;
	color: white;
}

.btn-pdf {
	background: #dc3545;
}

.btn-excel {
	background: #28a745;
}

.btn-report:hover {
	transform: scale(1.05);
	filter: brightness(1.1);
}

.stock-bajo {
	color: #e74c3c;
	font-weight: bold;
	background: #fdf2f2;
}

.stock-ok {
	color: #27ae60;
	font-weight: bold;
}

.badge {
	padding: 4px 8px;
	border-radius: 4px;
	font-size: 0.85rem;
}

.badge-warning {
	background: #fff3cd;
	color: #856404;
}

.badge-success {
	background: #d4edda;
	color: #155724;
}


/* Estilos para Modo Ajuste */

.col-ajuste {
	display: none;
}

.input-ajuste {
	width: 80px;
	padding: 5px;
	border: 1px solid #ccc;
	border-radius: 4px;
	text-align: center;
}

.btn-ajuste-mensual {
	background: #6c757d;
	color: white;
	border: none;
	padding: 10px;
	border-radius: 5px;
	cursor: pointer;
}

.btn-ajuste-mensual.activo {
	background: #dc3545;
}

.btn-guardar-ajuste {
	display: none;
	background: #28a745;
	color: white;
	padding: 10px;
	border-radius: 5px;
	border: none;
	cursor: pointer;
}

.header-acciones {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-bottom: 20px;
	flex-wrap: wrap;
	gap: 10px;
}

.grupo-botones {
	display: flex;
	gap: 8px;
}

:root {
	--primary: #1e3c72;
	--secondary: #2a5298;
	--success: #27ae60;
	--danger: #e74c3c;
	--warning: #f39c12;
}

.stats-container {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
	gap: 20px;
	margin-bottom: 30px;
}

.stat-card {
	position: relative;
	padding: 25px;
	border-radius: 20px;
	color: white;
	box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
	transition: all 0.3s ease;
	overflow: hidden;
	border: 1px solid rgba(255, 255, 255, 0.1);
}

.stat-card:hover {
	transform: translateY(-10px);
	box-shadow: 0 15px 30px rgba(0, 0, 0, 0.2);
}

.stat-card i {
	position: absolute;
	right: -10px;
	bottom: -10px;
	font-size: 5rem;
	opacity: 0.15;
	transform: rotate(-15deg);
}

.stat-card h3 {
	margin: 0;
	font-size: 0.85rem;
	text-transform: uppercase;
	letter-spacing: 1px;
	opacity: 0.9;
}

.stat-card p {
	margin: 12px 0 0;
	font-size: 1.9rem;
	font-weight: 800;
}

.bg-1 {
	background: linear-gradient(135deg, #0f2027, #203a43, #2c5364);
}

.bg-2 {
	background: linear-gradient(135deg, #ed213a, #93291e);
}

.bg-3 {
	background: linear-gradient(135deg, #f2994a, #f2c94c);
}

.bg-4 {
	background: linear-gradient(135deg, #11998e, #38ef7d);
}

.charts-grid {
	display: grid;
	grid-template-columns: 1.6fr 1fr;
	gap: 25px;
	margin-bottom: 30px;
}

.chart-card {
	background: #ffffff;
	padding: 25px;
	border-radius: 20px;
	box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
	border: 1px solid #eee;
}

.chart-header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-bottom: 20px;
	border-bottom: 1px solid #f0f0f0;
	padding-bottom: 10px;
}

.chart-header h3 {
	font-size: 1.1rem;
	color: #2c3e50;
	margin: 0;
}

.filter-bar {
	background: white;
	padding: 15px 25px;
	border-radius: 15px;
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-bottom: 30px;
	box-shadow: 0 4px 10px rgba(0, 0, 0, 0.03);
}

.btn-update {
	background: var(--primary);
	color: white;
	border: none;
	padding: 10px 20px;
	border-radius: 10px;
	cursor: pointer;
	font-weight: 600;
	transition: 0.3s;
}

.btn-update:hover {
	background: #000;
}

@media (max-width: 900px) {
	.charts-grid {
		grid-template-columns: 1fr;
	}
}


/* (Tus estilos de pestañas, link-origen y modales se mantienen igual) */

.tabs-container {
	display: flex;
	gap: 10px;
	margin-bottom: 20px;
	border-bottom: 2px solid #eee;
	padding-bottom: 10px;
}

.tab-item {
	padding: 10px 20px;
	border-radius: 8px;
	text-decoration: none;
	color: #7f8c8d;
	font-weight: 600;
	font-size: 14px;
	transition: 0.3s;
	background: #f8f9fa;
}

.tab-item:hover {
	background: #e2e8f0;
	color: #2c3e50;
}

.tab-item.active {
	background: #34495e;
	color: white;
	box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.fila-cancelada td {
	color: #a0aec0 !important;
}

.link-origen {
	text-decoration: none;
	color: #64748b;
	font-weight: 700;
	font-size: 12px;
	display: inline-flex;
	align-items: center;
	gap: 4px;
}

.link-origen:hover {
	color: #3b82f6;
	text-decoration: underline;
}

.modal {
	display: none;
	position: fixed;
	z-index: 10000;
	left: 0;
	top: 0;
	width: 100%;
	height: 100%;
	background-color: rgba(0, 0, 0, 0.6);
	backdrop-filter: blur(5px);
	align-items: center;
	justify-content: center;
	animation: fadeIn 0.3s ease;
}

.modal-card {
	background: #fff;
	padding: 25px;
	border-radius: 12px;
	box-shadow: 0 15px 35px rgba(0, 0, 0, 0.3);
	position: relative;
	width: 90%;
	max-width: 500px;
}

.modal-card h3 {
	margin-top: 0;
	color: #2c3e50;
	border-bottom: 2px solid #f1f1f1;
	padding-bottom: 15px;
	font-size: 1.3rem;
}

.modal-close {
	position: absolute;
	top: 15px;
	right: 20px;
	font-size: 24px;
	cursor: pointer;
	color: #95a5a6;
}

.modal-close:hover {
	color: #e74c3c;
}

.form-group {
	margin-top: 15px;
	text-align: left;
}

.form-group label {
	display: block;
	font-weight: bold;
	margin-bottom: 5px;
	font-size: 13px;
	color: #34495e;
}

.form-control {
	width: 100%;
	padding: 10px;
	border: 1px solid #ddd;
	border-radius: 6px;
	box-sizing: border-box;
	font-size: 14px;
	font-family: inherit;
}

@keyframes fadeIn {
	from {
		opacity: 0;
		transform: translateY(-20px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}


/* ============================================================
   BOTONES MAESTROS (EXPORTAR, IMPORTAR, AJUSTES)
   ============================================================ */


/* Contenedor de la cabecera */

.header-acciones {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-bottom: 25px;
	padding-bottom: 10px;
	border-bottom: 1px solid #e2e8f0;
}

.grupo-botones {
	display: flex;
	gap: 10px;
	align-items: center;
}


/* Estilo Base para todos los botones de acción */

.btn-editar,
.btn-detalle,
.btn-ajuste-mensual,
.btn-guardar-ajuste {
	padding: 10px 18px !important;
	border-radius: 8px !important;
	font-size: 13px !important;
	font-weight: 600 !important;
	border: none !important;
	cursor: pointer !important;
	display: inline-flex !important;
	align-items: center !important;
	justify-content: center !important;
	gap: 8px !important;
	transition: all 0.2s ease !important;
	text-decoration: none !important;
	box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05) !important;
}


/* BOTÓN EXPORTAR (Verde Esmeralda) */

.btn-editar[href*="exportar"],
.btn-editar {
	background-color: #10b981 !important;
	/* Verde moderno */
	color: white !important;
}

.btn-editar:hover {
	background-color: #059669 !important;
	transform: translateY(-1px);
	box-shadow: 0 4px 6px rgba(16, 185, 129, 0.2) !important;
}


/* BOTÓN IMPORTAR (Azul Eléctrico) */

.btn-detalle[href*="importar"],
.btn-detalle {
	background-color: #3b82f6 !important;
	color: white !important;
}

.btn-detalle:hover {
	background-color: #2563eb !important;
	transform: translateY(-1px);
	box-shadow: 0 4px 6px rgba(59, 130, 246, 0.2) !important;
}


/* BOTÓN AJUSTE MENSUAL (Gris Oxford / Slate) */

.btn-ajuste-mensual {
	background-color: #475569 !important;
	color: white !important;
}

.btn-ajuste-mensual:hover {
	background-color: #334155 !important;
}

.btn-ajuste-mensual.activo {
	background-color: #ef4444 !important;
	/* Rojo cuando está activo */
}


/* BOTÓN GUARDAR CAMBIOS (Verde Lima / Success) */

.btn-guardar-ajuste {
	background-color: #16a34a !important;
	color: white !important;
}

.btn-guardar-ajuste:hover {
	background-color: #15803d !important;
	transform: scale(1.02);
}


/* Ajuste de Iconos */

.grupo-botones i {
	font-size: 14px;
}


/* ============================================================
   BOTONES DE COBRANZA (ABONOS, CARTERA, FECHAS)
   ============================================================ */

.acciones-header {
	display: flex;
	gap: 10px;
	align-items: center;
}


/* Estilo Base para Botones del Header de Cobranza */

.btn-pago,
.btn-cartera,
.btn-cobranza {
	padding: 10px 18px !important;
	border-radius: 8px !important;
	font-size: 13px !important;
	font-weight: 600 !important;
	border: none !important;
	cursor: pointer !important;
	display: inline-flex !important;
	align-items: center !important;
	justify-content: center !important;
	gap: 8px !important;
	transition: all 0.2s ease !important;
	text-decoration: none !important;
	box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05) !important;
}


/* BOTÓN NUEVO ABONO (Azul Connect) */

.btn-pago {
	background-color: #2563eb !important;
	color: white !important;
}

.btn-pago:hover {
	background-color: #1d4ed8 !important;
	transform: translateY(-1px);
	box-shadow: 0 4px 12px rgba(37, 99, 235, 0.2) !important;
}


/* BOTÓN CARTERA (Rojo Alerta / Auditoría) */

.btn-cartera {
	background-color: #ef4444 !important;
	color: white !important;
}

.btn-cartera:hover {
	background-color: #dc2626 !important;
	transform: translateY(-1px);
	box-shadow: 0 4px 12px rgba(239, 68, 68, 0.2) !important;
}


/* BOTÓN POR FECHAS (Gris Slate / Reporte) */

.btn-cobranza {
	background-color: #475569 !important;
	color: white !important;
}

.btn-cobranza:hover {
	background-color: #334155 !important;
	transform: translateY(-1px);
}


/* --- ESTILOS EXTRAS PARA LA TABLA DE ABONOS --- */


/* Badge del Método de Pago */

.badge-metodo {
	background: #f1f5f9;
	color: #475569;
	padding: 3px 10px;
	border-radius: 20px;
	font-size: 11px;
	font-weight: 700;
	text-transform: uppercase;
}


/* Resaltar el Monto en la tabla */

.monto-abono {
	color: #16a34a;
	font-weight: 800;
	font-size: 14px;
}


/* Botones de acción dentro de la tabla (Slim) */

.btn-imprimir,
.btn-editar-abono,
.btn-eliminar-abono {
	width: 32px;
	height: 32px;
	border-radius: 6px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	background-color: #f8fafc;
	color: #64748b;
	border: 1px solid #e2e8f0;
	transition: all 0.2s;
	cursor: pointer;
	text-decoration: none;
	margin: 0 2px;
}

.btn-imprimir:hover {
	color: #2563eb;
	border-color: #2563eb;
	background: #eff6ff;
}

.btn-editar-abono:hover {
	color: #f59e0b;
	border-color: #f59e0b;
	background: #fffbeb;
}

.btn-eliminar-abono:hover {
	color: #ef4444;
	border-color: #ef4444;
	background: #fef2f2;
}


/* ============================================================
   ESTADOS Y BOTONES DE CONTRATOS (SLIM STYLE)
   ============================================================ */


/* 1. Badges de Estado del Contrato */

.estado-contrato {
	padding: 3px 10px;
	border-radius: 20px;
	font-size: 10.5px;
	font-weight: 700;
	text-transform: uppercase;
	display: inline-block;
}

.estado-activo {
	background-color: #dcfce7;
	color: #166534;
}


/* Verde */

.estado-pendiente {
	background-color: #fef3c7;
	color: #92400e;
}


/* Naranja */

.estado-expirado {
	background-color: #fee2e2;
	color: #b91c1c;
}


/* Rojo */


/* 2. Botones de Acción en la Tabla */

.acciones {
	display: flex;
	gap: 6px;
	justify-content: center;
	align-items: center;
}


/* Base común para botones de icono */

.btn-editar,
.btn-generar-pdf,
.btn-email-contrato,
.btn-renovar,
.btn-eliminar {
	width: 32px;
	height: 32px;
	border-radius: 6px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	background-color: #f8fafc;
	/* Fondo gris muy tenue */
	color: #64748b;
	/* Icono gris slate */
	border: 1px solid #e2e8f0;
	transition: all 0.2s ease;
	cursor: pointer;
	text-decoration: none;
	font-size: 14px;
}


/* Hover: Colores específicos por acción */

.btn-editar:hover {
	background-color: #eff6ff;
	color: #2563eb;
	border-color: #2563eb;
}


/* Azul */

.btn-generar-pdf:hover {
	background-color: #fef2f2;
	color: #ef4444;
	border-color: #ef4444;
}


/* Rojo PDF */

.btn-email-contrato:hover {
	background-color: #f0fdf4;
	color: #10b981;
	border-color: #10b981;
}


/* Verde Email */

.btn-renovar:hover {
	background-color: #fffbeb;
	color: #f59e0b;
	border-color: #f59e0b;
}


/* Naranja Renovación */

.btn-eliminar:hover {
	background-color: #451a03;
	color: #ffffff;
	border-color: #451a03;
}


/* Negro/Rojo Oscuro */


/* 3. Estilo para las Alertas de Notificación */

.alerta-notificacion {
	padding: 12px 20px;
	border-radius: 8px;
	margin-bottom: 20px;
	font-size: 14px;
	font-weight: 500;
}

.alerta-notificacion.exito {
	background: #dcfce7;
	color: #166534;
	border-left: 5px solid #22c55e;
}

.alerta-notificacion.error {
	background: #fee2e2;
	color: #991b1b;
	border-left: 5px solid #ef4444;
}


/* 4. Modales (Mejora visual) */

.modal {
	background-color: rgba(15, 23, 42, 0.7);
	/* Fondo oscuro transparente */
	backdrop-filter: blur(4px);
}

.modal-contenido {
	background-color: #ffffff;
	border-radius: 12px;
	box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
	border: none;
	padding: 30px;
	max-width: 450px;
}


/* ============================================================
   ESTILOS PARA EL DIRECTORIO DE CLIENTES (SLIM)
   ============================================================ */


/* 1. Botones de Cabecera */

.btn-agregar {
	background-color: #2563eb !important;
	/* Azul Primario */
	color: white !important;
	padding: 10px 18px !important;
	border-radius: 8px !important;
	font-size: 13px !important;
	font-weight: 600 !important;
	display: inline-flex !important;
	align-items: center !important;
	gap: 8px !important;
	text-decoration: none !important;
	transition: all 0.2s ease !important;
}

.btn-agregar:hover {
	background-color: #1d4ed8 !important;
	transform: translateY(-1px);
	box-shadow: 0 4px 12px rgba(37, 99, 235, 0.2) !important;
}


/* 2. Resaltado de Saldos */

.deuda-positiva {
	color: #dc2626 !important;
	/* Rojo para deudas */
	font-weight: 800 !important;
	font-size: 14px !important;
}

.sin-deuda {
	color: #94a3b8 !important;
	/* Gris suave para saldo en ceros */
	font-weight: 500 !important;
}


/* 3. Botones de Acción en la Tabla (Slim Icons) */

.btn-editar,
.btn-detalle,
.btn-eliminar {
	width: 32px;
	height: 32px;
	border-radius: 6px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	background-color: #f8fafc;
	color: #64748b;
	border: 1px solid #e2e8f0;
	transition: all 0.2s ease;
	cursor: pointer;
	text-decoration: none;
	margin: 0 2px;
}


/* Hover específicos para Clientes */

.btn-editar:hover {
	background-color: #eff6ff;
	color: #2563eb;
	border-color: #2563eb;
}

.btn-detalle:hover {
	background-color: #f0fdf4;
	color: #10b981;
	border-color: #10b981;
}


/* Verde para ver perfil */

.btn-eliminar:hover {
	background-color: #fef2f2;
	color: #ef4444;
	border-color: #ef4444;
}


/* 4. Estilos del Modal de Detalle Cliente */

.modal {
	background-color: rgba(15, 23, 42, 0.7);
	backdrop-filter: blur(4px);
	display: none;
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	z-index: 1000;
	justify-content: center;
	align-items: center;
}

.modal-card {
	background: white;
	padding: 30px;
	border-radius: 12px;
	width: 90%;
	max-width: 500px;
	position: relative;
	box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

.modal-close {
	position: absolute;
	top: 15px;
	right: 15px;
	font-size: 24px;
	cursor: pointer;
	color: #94a3b8;
}


/* ============================================================
   REPARACIÓN DE BOTONES DE ACCIÓN (ESTILO SLIM)
   ============================================================ */


/* Forzamos a que la celda de acciones no se estire */

table td.acciones {
	display: flex !important;
	justify-content: center !important;
	align-items: center !important;
	gap: 5px !important;
	padding: 5px 10px !important;
	/* Dieta para la fila */
	border-bottom: 1px solid #f1f5f9 !important;
	white-space: nowrap !important;
	width: auto !important;
}


/* El secreto: Reset total para los botones de la tabla */

table td.acciones .btn-editar,
table td.acciones .btn-eliminar,
table td.acciones .btn-detalle,
table td.acciones .btn-generar-pdf,
table td.acciones .btn-email-contrato,
table td.acciones .btn-renovar,
table td.acciones .btn-imprimir,
table td.acciones .btn-editar-abono,
table td.acciones .btn-eliminar-abono {
	/* Reset de dimensiones */
	width: 30px !important;
	height: 30px !important;
	min-width: 30px !important;
	padding: 0 !important;
	margin: 0 !important;
	/* Estética Slim */
	display: inline-flex !important;
	align-items: center !important;
	justify-content: center !important;
	border-radius: 6px !important;
	border: 1px solid #e2e8f0 !important;
	background-color: #f8fafc !important;
	color: #64748b !important;
	font-size: 13px !important;
	text-decoration: none !important;
	transition: all 0.2s ease !important;
	cursor: pointer !important;
}


/* Colores de interacción (Hover) */

table td.acciones .btn-editar:hover,
table td.acciones .btn-editar-abono:hover {
	color: #2563eb !important;
	border-color: #2563eb !important;
	background: #eff6ff !important;
}

table td.acciones .btn-eliminar:hover,
table td.acciones .btn-eliminar-abono:hover {
	color: #ef4444 !important;
	border-color: #ef4444 !important;
	background: #fef2f2 !important;
}

table td.acciones .btn-detalle:hover,
table td.acciones .btn-email-contrato:hover {
	color: #10b981 !important;
	border-color: #10b981 !important;
	background: #f0fdf4 !important;
}

table td.acciones .btn-renovar:hover {
	color: #f59e0b !important;
	border-color: #f59e0b !important;
	background: #fffbeb !important;
}

table td.acciones .btn-generar-pdf:hover,
table td.acciones .btn-imprimir:hover {
	color: #dc2626 !important;
	border-color: #dc2626 !important;
	background: #fef2f2 !important;
}


/* Aseguramos que los botones de proveedores también entren en la dieta Slim */

table td.acciones .btn-editar,
table td.acciones .btn-detalle,
table td.acciones .btn-eliminar {
	width: 30px !important;
	height: 30px !important;
	display: inline-flex !important;
	align-items: center !important;
	justify-content: center !important;
	border-radius: 6px !important;
	border: 1px solid #e2e8f0 !important;
	background-color: #f8fafc !important;
	text-decoration: none !important;
}


/* Colores específicos para que se vea Pro */

table td.acciones .btn-editar:hover {
	color: #2563eb !important;
	border-color: #2563eb !important;
	background: #eff6ff !important;
}

table td.acciones .btn-detalle:hover {
	color: #10b981 !important;
	border-color: #10b981 !important;
	background: #f0fdf4 !important;
}

table td.acciones .btn-eliminar:hover {
	color: #ef4444 !important;
	border-color: #ef4444 !important;
	background: #fef2f2 !important;
}


/* --- FIX PARA INVENTARIOS --- */


/* 1. Botones de Cabecera (Grandes y con texto visible) */

.btn-header {
	height: 38px !important;
	width: auto !important;
	/* Que el ancho dependa del texto */
	padding: 0 15px !important;
	border-radius: 8px !important;
	font-size: 13px !important;
	font-weight: 600 !important;
	display: inline-flex !important;
	align-items: center !important;
	gap: 8px !important;
	color: white !important;
	border: none !important;
	cursor: pointer !important;
	text-decoration: none !important;
}

.btn-exportar-inv {
	background-color: #16a34a !important;
}

.btn-importar-inv {
	background-color: #2563eb !important;
}

.btn-ajuste-mensual {
	background-color: #475569 !important;
}

.btn-ajuste-mensual.activo {
	background-color: #ef4444 !important;
}

.btn-guardar-ajuste {
	background-color: #059669 !important;
	border: 2px solid #bbf7d0 !important;
}


/* 2. Badges de Inventario */

.badge-bajo {
	background-color: #fee2e2;
	color: #b91c1c;
	border: 1px solid #fecaca;
}

.badge-ok {
	background-color: #dcfce7;
	color: #15803d;
	border: 1px solid #bbf7d0;
}


/* 3. Inputs de Ajuste (Para que no deformen la fila) */

.input-ajuste {
	width: 70px !important;
	padding: 4px !important;
	border: 1px solid #cbd5e0 !important;
	border-radius: 4px !important;
	text-align: center !important;
	font-size: 13px !important;
}


/* 4. Resaltado de stock bajo */

.stock-bajo {
	background-color: #fff1f2 !important;
	/* Rojo muy tenue */
}

.stock-bajo td {
	color: #991b1b !important;
}


/* --- KARDEX PRO STYLES --- */

.filtros-kardex-pro {
	background: #ffffff;
	padding: 15px 20px;
	border-radius: 12px;
	border: 1px solid #e2e8f0;
	display: flex;
	gap: 20px;
	align-items: flex-end;
	margin-bottom: 20px;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.grupo-filtro {
	display: flex;
	flex-direction: column;
	gap: 5px;
}

.lbl-pro {
	font-size: 11px;
	font-weight: 700;
	text-transform: uppercase;
	color: #64748b;
	letter-spacing: 0.025em;
}

.in-pro {
	height: 38px;
	border: 1px solid #cbd5e0;
	border-radius: 8px;
	padding: 0 12px;
	font-size: 13px;
	color: #1e293b;
	background-color: #f8fafc;
	transition: all 0.2s;
}

.in-pro:focus {
	border-color: #3b82f6;
	outline: none;
	background-color: #fff;
}

.acciones-filtro {
	display: flex;
	gap: 8px;
}


/* Badges de Movimiento */

.badge-entrada {
	background: #dcfce7;
	color: #15803d;
	border: 1px solid #bbf7d0;
	font-size: 10px;
	padding: 3px 8px;
	border-radius: 6px;
	font-weight: 800;
}

.badge-salida {
	background: #fee2e2;
	color: #b91c1c;
	border: 1px solid #fecaca;
	font-size: 10px;
	padding: 3px 8px;
	border-radius: 6px;
	font-weight: 800;
}

.badge-ajuste {
	background: #fef3c7;
	color: #92400e;
	border: 1px solid #fde68a;
	font-size: 10px;
	padding: 3px 8px;
	border-radius: 6px;
	font-weight: 800;
}

.text-entrada {
	color: #16a34a;
	font-weight: 700;
}

.text-salida {
	color: #dc2626;
	font-weight: 700;
}


/* Responsivo para filtros */

@media (max-width: 768px) {
	.filtros-kardex-pro {
		flex-direction: column;
		align-items: stretch;
	}
	.in-pro {
		width: 100% !important;
	}
}


/* (Tus estilos KARDEX PRO que definimos antes) */

.filtros-kardex-pro {
	background: #ffffff;
	padding: 15px 20px;
	border-radius: 12px;
	border: 1px solid #e2e8f0;
	display: flex;
	gap: 20px;
	align-items: flex-end;
	margin-bottom: 20px;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.grupo-filtro {
	display: flex;
	flex-direction: column;
	gap: 5px;
}

.lbl-pro {
	font-size: 11px;
	font-weight: 700;
	text-transform: uppercase;
	color: #64748b;
	letter-spacing: 0.025em;
}

.in-pro {
	height: 38px;
	border: 1px solid #cbd5e0;
	border-radius: 8px;
	padding: 0 12px;
	font-size: 13px;
	color: #1e293b;
	background-color: #f8fafc;
}

.acciones-filtro {
	display: flex;
	gap: 8px;
}

.badge-entrada {
	background: #dcfce7;
	color: #15803d;
	border: 1px solid #bbf7d0;
	font-size: 10px;
	padding: 3px 8px;
	border-radius: 6px;
	font-weight: 800;
}

.badge-salida {
	background: #fee2e2;
	color: #b91c1c;
	border: 1px solid #fecaca;
	font-size: 10px;
	padding: 3px 8px;
	border-radius: 6px;
	font-weight: 800;
}

.badge-ajuste {
	background: #fef3c7;
	color: #92400e;
	border: 1px solid #fde68a;
	font-size: 10px;
	padding: 3px 8px;
	border-radius: 6px;
	font-weight: 800;
}

.text-entrada {
	color: #16a34a !important;
	font-weight: 700;
}

.text-salida {
	color: #dc2626 !important;
	font-weight: 700;
}


/* Paginación Slim */

.paginacion {
	display: flex;
	justify-content: center;
	gap: 5px;
	margin-top: 25px;
	padding-bottom: 20px;
}

.btn-pag {
	padding: 8px 14px;
	background: #fff;
	border: 1px solid #e2e8f0;
	color: #64748b;
	text-decoration: none;
	border-radius: 8px;
	font-size: 13px;
	font-weight: 600;
	transition: 0.2s;
}

.btn-pag:hover {
	background: #f8fafc;
	color: #3b82f6;
	border-color: #3b82f6;
}

.btn-pag.activo {
	background: #3b82f6;
	color: #fff;
	border-color: #3b82f6;
}


/* =========================================
   ESTILOS VENTAS (MODAL TICKET Y FILTROS)
   ========================================= */


/* Modal Ticket Flotante */

.modal-venta-pro {
	display: none;
	position: fixed;
	z-index: 10000;
	left: 0;
	top: 0;
	width: 100%;
	height: 100%;
	background-color: rgba(15, 23, 42, 0.75);
	backdrop-filter: blur(4px);
	align-items: center;
	justify-content: center;
	animation: fadeIn 0.2s ease;
}

.modal-card-ticket {
	background: #fff;
	width: 95%;
	max-width: 600px;
	border-radius: 12px;
	position: relative;
	max-height: 90vh;
	overflow-y: auto;
	box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.2);
}

.close-ticket {
	position: absolute;
	right: 20px;
	top: 15px;
	font-size: 24px;
	color: #64748b;
	cursor: pointer;
	z-index: 10;
}

@keyframes fadeIn {
	from {
		opacity: 0;
	}
	to {
		opacity: 1;
	}
}


/* Contenedor de Filtros (Fechas) */

.filtros-container {
	display: flex;
	gap: 15px;
	align-items: center;
	background: #f8fafc;
	padding: 10px;
	border-radius: 8px;
	border: 1px solid #e2e8f0;
	margin-bottom: 0px;
	flex-wrap: wrap;
}

.filtro-item {
	display: flex;
	align-items: center;
	gap: 8px;
}

.filtro-item label {
	font-weight: 600;
	color: #64748b;
	font-size: 14px;
}

.filtro-input {
	padding: 8px 12px;
	border: 1px solid #cbd5e1;
	border-radius: 6px;
	font-size: 14px;
	color: #334155;
}

.btn-filtrar {
	background-color: #3b82f6;
	color: white;
	border: none;
	padding: 8px 16px;
	border-radius: 6px;
	cursor: pointer;
	font-weight: 600;
	display: flex;
	align-items: center;
	gap: 5px;
	transition: background 0.2s;
}

.btn-filtrar:hover {
	background-color: #2563eb;
}

.btn-limpiar {
	color: #64748b;
	text-decoration: none;
	font-size: 14px;
	border-bottom: 1px dashed #64748b;
}


/* ============================================================
   💎 SISTEMA MAESTRO DE BOTONES (VERSIÓN SLIM PRO)
   ============================================================ */


/* --- 1. CLASE BASE (La estructura común) --- */

.btn-m,
.btn-icon {
	border: none;
	border-radius: 6px;
	/* Radio base intermedio */
	cursor: pointer;
	font-family: "Segoe UI", sans-serif;
	font-weight: 600;
	text-decoration: none;
	transition: all 0.2s cubic-bezier(0.25, 0.8, 0.25, 1);
	/* Transición más rápida y técnica */
	box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
	/* Sombra base sutil */
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	/* Espacio entre icono y texto */
	color: white !important;
	/* Texto siempre blanco */
}


/* Efecto Hover: Botones Normales (Con Texto) */

.btn-m:hover {
	transform: translateY(-2px);
	box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
	filter: brightness(1.1);
}


/* Efecto Hover: Botones Icono (Más sutil y serio) */

.btn-icon:hover {
	transform: translateY(-1px);
	/* Movimiento mínimo */
	box-shadow: 0 3px 6px rgba(0, 0, 0, 0.15);
	filter: brightness(1.1);
}

.btn-m:active,
.btn-icon:active {
	transform: translateY(0);
	box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}


/* --- 2. TAMAÑOS (AQUÍ ESTÁ LA MAGIA) --- */


/* Botón Normal (Compacto y Ejecutivo) */

.btn-m {
	padding: 8px 16px;
	/* Reducido de 10px 20px para verse más Pro */
	font-size: 13px;
	/* Letra un poco más fina */
}


/* Botón Icono (Tablas - Estilo "Sistema Bancario") */

.btn-icon {
	width: 26px;
	/* Tamaño perfecto: ni muy chico ni muy grande */
	height: 26px;
	padding: 0;
	font-size: 11px;
	/* Icono nítido y pequeño */
	border-radius: 4px;
	/* Bordes casi cuadrados, muy técnico */
}


/* --- 3. COLORES (GRADIENTES MODERNOS) --- */


/* AZUL (Nuevo, Agregar, Guardar, Ver Detalle) */

.b-azul {
	background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%) !important;
}


/* VERDE (Excel, Exportar, Completado) */

.b-verde {
	background: linear-gradient(135deg, #10b981 0%, #059669 100%) !important;
}


/* ROJO (PDF, Cancelar, Eliminar, Cartera) */

.b-rojo {
	background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%) !important;
}


/* NARANJA (Editar, Email, Alerta) */

.b-naranja {
	background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%) !important;
}


/* GRIS OSCURO (Ajustes, Filtros, Volver) */

.b-gris {
	background: linear-gradient(135deg, #64748b 0%, #475569 100%) !important;
}


/* VIOLETA (Filtrar, Especiales) */

.b-violeta {
	background: linear-gradient(135deg, #8b5cf6 0%, #6d28d9 100%) !important;
}


/* --- 4. RESET PARA TABLAS (Mantiene la fila delgada) --- */

table td.acciones {
	display: flex !important;
	gap: 4px !important;
	/* Menos espacio entre botoncitos */
	justify-content: center !important;
	padding: 4px 6px !important;
	/* Celda ajustada al contenido */
	background: transparent !important;
	align-items: center !important;
}


/* Estilos para el formulario en tarjeta */

.card-form {
	background: #fff;
	padding: 30px;
	border-radius: 12px;
	box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
	border: 1px solid #e5e7eb;
	max-width: 800px;
	margin: 0 auto;
}

.form-grid {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 20px;
}

.form-full {
	grid-column: span 2;
}

.form-group label {
	display: block;
	margin-bottom: 8px;
	font-weight: 600;
	color: #374151;
	font-size: 14px;
}

.form-group input,
.form-group select,
.form-group textarea {
	width: 100%;
	padding: 10px;
	border: 1px solid #d1d5db;
	border-radius: 6px;
	font-size: 14px;
	transition: border-color 0.3s;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
	border-color: #3b82f6;
	outline: none;
	box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.form-group small {
	color: #6b7280;
	font-size: 12px;
	margin-top: 4px;
	display: block;
}


/* Estilo input readonly */

input[readonly] {
	background-color: #f3f4f6;
	color: #6b7280;
	cursor: not-allowed;
}


/* Botones alineados a la derecha */

.form-actions {
	margin-top: 25px;
	display: flex;
	justify-content: flex-end;
	gap: 10px;
	border-top: 1px solid #e5e7eb;
	padding-top: 20px;
}

@media (max-width: 768px) {
	.form-grid {
		grid-template-columns: 1fr;
	}
	.form-full {
		grid-column: span 1;
	}
}


/* =======================================================
   RESPONSIVE PARA DASHBOARD (FILTROS Y BARRA)
   ======================================================= */


/* Estilo base para asegurar que el flex sepa qué hacer */

.filter-bar {
	display: flex;
	justify-content: space-between;
	align-items: center;
	flex-wrap: wrap;
	/* Permite que salte de línea si no cabe */
	gap: 20px;
	margin-bottom: 25px;
}

.filter-bar form {
	display: flex;
	gap: 15px;
	align-items: center;
}


/* Media Query para Celulares y Tablets */

@media (max-width: 768px) {
	.filter-bar {
		flex-direction: column;
		/* Título arriba, filtros abajo */
		align-items: flex-start;
		/* Alineado a la izquierda */
	}
	.filter-bar form {
		width: 100%;
		/* El formulario ocupa todo el ancho */
		flex-direction: column;
		/* Inputs uno debajo del otro */
		gap: 10px;
	}
	.input-standard,
	.btn-update {
		width: 100% !important;
		/* Forzamos el ancho completo */
		margin: 0;
		box-sizing: border-box;
		/* Para que el padding no ensanche el input */
	}
	.btn-update {
		justify-content: center;
		padding: 12px;
		/* Más gordito para el touch */
	}
	/* Ajuste extra para las gráficas en móvil */
	.charts-grid {
		grid-template-columns: 1fr !important;
		/* Una sola columna de gráficas */
	}
	.stats-container {
		grid-template-columns: 1fr 1fr !important;
		/* Tarjetas de 2 en 2 en móvil */
	}
}

@media (max-width: 480px) {
	.stats-container {
		grid-template-columns: 1fr !important;
		/* Tarjetas de 1 en 1 en cel muy chico */
	}
}


/* Estilos específicos que no estaban en el CSS global pero son útiles aquí */

.info-box {
	background: #f0f9ff;
	border-left: 4px solid #007bff;
	padding: 15px;
	margin-bottom: 20px;
	border-radius: 4px;
	font-size: 0.9em;
	color: #2c3e50;
}


/* Grid para los checkboxes de permisos */

.grid-permisos {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
	gap: 15px;
	background: #f8fafc;
	padding: 20px;
	border-radius: 8px;
	border: 1px solid #e2e8f0;
}

.permiso-item {
	display: flex;
	align-items: center;
	gap: 10px;
	font-size: 0.9em;
	cursor: pointer;
	padding: 8px;
	background: white;
	border: 1px solid #e2e8f0;
	border-radius: 6px;
	transition: 0.2s;
}

.permiso-item:hover {
	border-color: #3b82f6;
	background: #eff6ff;
}

.permiso-item input {
	width: 16px;
	height: 16px;
	cursor: pointer;
	accent-color: #007bff;
}


/* Separadores visuales */

.section-divider {
	margin: 30px 0 20px 0;
	border-bottom: 1px solid #e5e7eb;
	padding-bottom: 10px;
	font-size: 1.1em;
	font-weight: 700;
	color: #1e293b;
	display: flex;
	align-items: center;
	gap: 10px;
}

.section-divider i {
	color: #3b82f6;
}

.edit-header-card {
	background: #fff;
	padding: 20px;
	border-radius: 12px;
	display: flex;
	align-items: center;
	gap: 20px;
	margin-bottom: 25px;
	border: 1px solid #e2e8f0;
}

.current-avatar {
	width: 80px;
	height: 80px;
	border-radius: 50%;
	object-fit: cover;
	border: 3px solid #3b82f6;
}

.section-divider {
	grid-column: 1 / -1;
	padding: 10px 0;
	border-bottom: 1px solid #f1f5f9;
	margin-bottom: 10px;
	color: #475569;
	font-weight: 700;
	font-size: 0.85rem;
	text-transform: uppercase;
	letter-spacing: 0.5px;
}

#preview-box {
	width: 80px;
	height: 80px;
	border-radius: 50%;
	object-fit: cover;
	display: none;
	border: 3px solid #10b981;
}

.form-layout {
	display: block;
	max-width: 900px;
	margin: 0 auto;
}

.section-card {
	background: white;
	padding: 30px;
	border-radius: 12px;
	box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
	border: 1px solid #e2e8f0;
	margin-bottom: 25px;
}

.section-title {
	font-size: 1.1em;
	font-weight: bold;
	color: #1e293b;
	margin-bottom: 20px;
	display: flex;
	align-items: center;
	gap: 10px;
	border-bottom: 2px solid #f1f5f9;
	padding-bottom: 10px;
}

.hidden {
	display: none;
}

.highlight-blue {
	border-left: 5px solid #3b82f6;
}

.highlight-amber {
	border-left: 5px solid #f59e0b;
}


/* Estilos para los Switches / Radio Buttons */

.switch-container {
	display: flex;
	gap: 20px;
	margin: 15px 0;
	background: #f0f9ff;
	padding: 15px;
	border-radius: 10px;
	border: 1px dashed #3b82f6;
}

.radio-option {
	display: flex;
	align-items: center;
	gap: 8px;
	cursor: pointer;
	font-weight: bold;
	color: #0369a1;
}

.radio-option input {
	width: 18px;
	height: 18px;
	cursor: pointer;
}

.promo-box {
	background: #fff7ed;
	border: 1px solid #ffedd5;
	padding: 20px;
	border-radius: 10px;
	margin-top: 15px;
}

.input-group-flex {
	display: flex;
	gap: 15px;
	align-items: center;
}

.btn-large {
	width: 100%;
	padding: 18px;
	font-size: 1.1em;
	font-weight: bold;
	border-radius: 10px;
	border: none;
	cursor: pointer;
	transition: 0.3s;
}

/* ============================================================
   ESTILOS DE BUSCADORES Y FILTROS (HEADER UNIFICADO)
   ============================================================ */

/* Contenedor Principal del Header (Título a la izq, Controles a la der) */
.header-acciones {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    flex-wrap: wrap;
    gap: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid #f1f5f9; /* Línea separadora sutil */
}

/* Grupo de Botones, Filtros y Buscador alineados a la derecha */
.grupo-botones-header {
    display: flex;
    gap: 8px;
    align-items: center;
    flex-wrap: wrap;
}

/* --- BUSCADOR CON LUPA (Search Wrapper) --- */
.search-wrapper {
    position: relative;
    width: 260px; /* Ancho estándar */
}

.search-wrapper input {
    padding-left: 35px; /* Espacio para el icono de lupa */
    padding-right: 30px; /* Espacio para la X de limpiar */
    border-radius: 20px; /* Bordes totalmente redondos */
    height: 38px;        /* Altura consistente */
    width: 100%;
    border: 1px solid #cbd5e1;
    background-color: #fff;
    outline: none;
    color: #334155;
    font-size: 14px;
    transition: all 0.3s ease;
}

.search-wrapper input:focus {
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1); /* Brillo azul al escribir */
}

/* Icono de Lupa */
.search-wrapper i.fa-search {
    position: absolute;
    left: 12px;
    top: 11px;
    color: #94a3b8;
    font-size: 14px;
    pointer-events: none; /* Para que el click pase al input */
}

/* Botón "X" para limpiar búsqueda */
.clear-search {
    position: absolute;
    right: 12px;
    top: 8px;
    color: #9ca3af;
    text-decoration: none;
    font-size: 18px;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.2s;
    line-height: 1;
}

.clear-search:hover {
    color: #ef4444; /* Rojo al pasar el mouse */
}

/* --- FILTROS (Selects y Fechas) --- */
.input-filtro {
    padding: 0 12px;
    border-radius: 20px;
    border: 1px solid #cbd5e1;
    background-color: #fff;
    color: #475569;
    outline: none;
    height: 38px; /* Misma altura que el buscador y botones */
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: border-color 0.2s;
}

.input-filtro:focus {
    border-color: #3b82f6;
}

/* Contenedor para rango de fechas (Desde - Hasta) */
.fechas-container {
    display: flex;
    gap: 5px;
    align-items: center;
}

/* --- RESPONSIVE (MÓVIL Y TABLET VERTICAL) --- */
@media (max-width: 992px) {
    /* En pantallas chicas, todo se pone en columna */
    .header-acciones {
        flex-direction: column;
        align-items: stretch; /* Estirar a todo el ancho */
        gap: 15px;
    }

    .grupo-botones-header {
        flex-direction: column;
        align-items: stretch;
        width: 100%;
        gap: 10px;
    }

    /* Inputs ocupan todo el ancho */
    .search-wrapper {
        width: 100%;
    }

    .input-filtro {
        width: 100%;
        text-align: center;
    }

    /* Las fechas se ponen una al lado de la otra (50% cada una) */
    .fechas-container {
        width: 100%;
        gap: 10px;
    }

    .fechas-container input {
        width: 50%; 
    }
    
    /* Botones de acción (Nuevo, Exportar) al 100% de ancho */
    .grupo-botones-header .btn-m {
        width: 100%;
        justify-content: center;
    }
}

/* ============================================================
   ESTILO PRO / ENTERPRISE (Corrección Visual)
   ============================================================ */

/* --- 1. BADGES DE ESTADO (El adiós al estilo "bebé") --- */
.badge-contrato {
    padding: 3px 8px;           /* Mucho menos relleno */
    border-radius: 4px;         /* Bordes apenas redondeados (serio) */
    font-size: 11px;            /* Letra pequeña y nítida */
    font-weight: 600;           /* Semi-negrita, no extra-gorda */
    text-transform: uppercase;
    letter-spacing: 0.5px;      /* Espaciado para legibilidad */
    display: inline-block;
    line-height: 1;
    border: 1px solid transparent; /* Para dar definición */
}

/* Colores más sobrios y profesionales */
.badge-activo {
    background-color: #ecfdf5; /* Verde muy claro */
    color: #059669;            /* Texto verde oscuro */
    border-color: #a7f3d0;
}

.badge-atencion {
    background-color: #fffbeb; /* Amarillo muy claro */
    color: #d97706;            /* Texto ocre */
    border-color: #fde68a;
}

.badge-vencido {
    background-color: #fef2f2; /* Rojo muy claro */
    color: #dc2626;            /* Texto rojo oscuro */
    border-color: #fecaca;
}

.badge-futuro {
    background-color: #f8fafc;
    color: #475569;
    border-color: #e2e8f0;
}

/* --- 2. BOTONES DE ACCIÓN (Alineación Perfecta) --- */

/* Contenedor FLEX que prohíbe saltos de línea */
.acciones-group {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 4px;                 /* Espacio milimétrico entre botones */
    flex-wrap: nowrap;        /* IMPORTANTE: Prohíbe que bajen de línea */
    width: 100%;
}

/* Botón individual "Slim" */
.btn-action-slim {
    width: 28px;              /* Tamaño fijo cuadrado pequeño */
    height: 28px;
    display: inline-flex;
    justify-content: center;
    align-items: center;
    border-radius: 4px;       /* Borde suave */
    border: 1px solid #e2e8f0;/* Borde gris muy sutil */
    background-color: #ffffff;/* Fondo blanco limpio */
    color: #64748b;           /* Icono gris medio */
    transition: all 0.2s ease;
    cursor: pointer;
    text-decoration: none;
    box-shadow: 0 1px 2px rgba(0,0,0,0.05); /* Sombra micro */
}

.btn-action-slim i {
    font-size: 12px;          /* Icono pequeño */
}

/* Efectos Hover (Solo se colorean al tocar) */
.btn-action-slim.editar:hover {
    background-color: #eff6ff; border-color: #3b82f6; color: #2563eb;
}
.btn-action-slim.pdf:hover {
    background-color: #fef2f2; border-color: #ef4444; color: #dc2626;
}
.btn-action-slim.email:hover {
    background-color: #f0fdf4; border-color: #10b981; color: #059669;
}
.btn-action-slim.renovar:hover {
    background-color: #fffbeb; border-color: #f59e0b; color: #d97706;
}
.btn-action-slim.eliminar:hover {
    background-color: #18181b; border-color: #18181b; color: #ffffff;
}

/* Asegurar que la celda de la tabla no aplaste el contenido */
table td.acciones {
    white-space: nowrap;      /* Fuerza a la celda a estirarse */
    width: 1%;                /* Truco CSS: se ajusta al contenido mínimo */
    padding: 4px 8px;
}