:root {
	--pmx-primary: #1B6297;
	--pmx-primary-dark: #154B74;
	--pmx-primary-light: #EFF7FF;
	--pmx-secondary: #38A2D7;
	--pmx-secondary-dark: #1B6297;
	--pmx-dark: #0f172a;
	--pmx-slate: #1e293b;
	--pmx-muted: #64748b;
	--pmx-border: #e2e8f0;
	--pmx-danger: #ef4444;
	--pmx-success: #10b981;
	--pmx-radius: 10px;
}

* {
	box-sizing: border-box;
	margin: 0;
	padding: 0;
}

body {
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
	background: linear-gradient(135deg, #0b1726 0%, #13273e 45%, #154B74 100%);
	min-height: 100vh;
	display: flex;
	flex-direction: column;
	justify-content: center;
	align-items: center;
	padding: 20px;
	color: #1e293b;
	position: relative;
	overflow-x: hidden;
}

/* Decoración de fondo */
body::before {
	content: "";
	position: absolute;
	top: -100px;
	right: -100px;
	width: 350px;
	height: 350px;
	background: radial-gradient(circle, rgba(27, 98, 151, 0.35) 0%, rgba(0, 0, 0, 0) 70%);
	border-radius: 50%;
	pointer-events: none;
}

body::after {
	content: "";
	position: absolute;
	bottom: -100px;
	left: -100px;
	width: 350px;
	height: 350px;
	background: radial-gradient(circle, rgba(56, 162, 215, 0.25) 0%, rgba(0, 0, 0, 0) 70%);
	border-radius: 50%;
	pointer-events: none;
}

.login-card {
	background: #ffffff;
	width: 100%;
	max-width: 440px;
	border-radius: 16px;
	box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.35), 0 0 0 1px rgba(255, 255, 255, 0.1);
	padding: 36px 32px;
	position: relative;
	z-index: 10;
	backdrop-filter: blur(10px);
	animation: card-appear 0.4s ease-out;
}

@keyframes card-appear {
	from {
		opacity: 0;
		transform: translateY(15px) scale(0.98);
	}

	to {
		opacity: 1;
		transform: translateY(0) scale(1);
	}
}

.brand-header {
	text-align: center;
	margin-bottom: 25px;
}

.logo-container {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 15px;
	margin-bottom: 15px;
}

.logo-pemex {
	height: 110px;
	max-width: 350px;
	object-fit: contain;
}

.logo-divider {
	height: 30px;
	width: 1px;
	background-color: #cbd5e1;
}

.logo-damora {
	height: 110px;
	max-width: 350px;
	object-fit: contain;
	border-radius: 4px;
}

.brand-header h1 {
	font-size: 20px;
	font-weight: 700;
	color: var(--pmx-dark);
	margin: 0 0 6px 0;
	letter-spacing: -0.2px;
}

.brand-header p {
	font-size: 13px;
	color: var(--pmx-muted);
	margin: 0;
	line-height: 1.4;
}

/* Alerta de Error */
.alert-error {
	display: none;
	background-color: #fef2f2;
	border: 1px solid #fecaca;
	border-radius: 8px;
	padding: 12px 14px;
	margin-bottom: 20px;
	font-size: 13px;
	color: #991b1b;
	align-items: center;
	gap: 10px;
	animation: shake 0.3s ease;
}

@keyframes shake {

	0%,
	100% {
		transform: translateX(0);
	}

	25% {
		transform: translateX(-5px);
	}

	75% {
		transform: translateX(5px);
	}
}

.alert-error.visible {
	display: flex;
}

.form-group {
	margin-bottom: 20px;
	text-align: left;
}

.form-label {
	display: block;
	font-size: 12.5px;
	font-weight: 600;
	color: #334155;
	margin-bottom: 7px;
}

.input-wrapper {
	position: relative;
	display: flex;
	align-items: center;
}

.input-icon {
	position: absolute;
	left: 14px;
	color: #94a3b8;
	pointer-events: none;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: color 0.2s ease;
}

.input-icon svg {
	width: 18px;
	height: 18px;
	stroke: currentColor;
	display: block;
}

.form-input {
	width: 100%;
	padding: 12px 42px 12px 42px;
	font-size: 14px;
	font-family: inherit;
	color: #0f172a;
	background-color: #f8fafc;
	border: 1.5px solid #cbd5e1;
	border-radius: 8px;
	outline: none;
	transition: all 0.2s ease;
}

.form-input:focus {
	background-color: #ffffff;
	border-color: var(--pmx-primary);
	box-shadow: 0 0 0 3px rgba(27, 98, 151, 0.18);
}

.form-input:focus+.input-icon,
.input-wrapper:focus-within .input-icon {
	color: var(--pmx-primary);
}

.btn-toggle-pwd {
	position: absolute;
	right: 10px;
	background: transparent;
	border: none;
	color: #64748b;
	cursor: pointer;
	padding: 6px;
	border-radius: 6px;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: all 0.2s ease;
	outline: none;
}

.btn-toggle-pwd:hover {
	color: #0f172a;
	background-color: #e2e8f0;
}

.btn-toggle-pwd:focus {
	box-shadow: 0 0 0 2px rgba(27, 98, 151, 0.25);
}

.btn-toggle-pwd svg {
	width: 18px;
	height: 18px;
	stroke: currentColor;
	display: block;
}

/* Aviso de Bloqueo de Mayúsculas */
.caps-warning {
	display: none;
	font-size: 12px;
	color: #b45309;
	margin-top: 6px;
	align-items: center;
	gap: 6px;
}

.caps-warning svg {
	width: 14px;
	height: 14px;
	stroke: currentColor;
	flex-shrink: 0;
}

.caps-warning.visible {
	display: flex;
}

.btn-submit {
	width: 100%;
	background: linear-gradient(to bottom, #2372ad, #1B6297);
	color: #ffffff;
	border: none;
	padding: 13px;
	font-size: 14.5px;
	font-weight: 700;
	letter-spacing: 0.3px;
	border-radius: 8px;
	cursor: pointer;
	box-shadow: 0 4px 6px -1px rgba(27, 98, 151, 0.35);
	transition: all 0.2s ease;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	margin-top: 25px;
}

.btn-submit:hover {
	background: linear-gradient(to bottom, #2981c2, #154B74);
	transform: translateY(-1px);
	box-shadow: 0 6px 12px -2px rgba(27, 98, 151, 0.45);
}

.btn-submit:active {
	transform: translateY(0);
	box-shadow: 0 2px 4px rgba(27, 98, 151, 0.25);
}

/* Footer de la Tarjeta */
.login-footer {
	margin-top: 25px;
	padding-top: 20px;
	border-top: 1px solid var(--pmx-border);
	text-align: center;
}

.security-badge {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	font-size: 11.5px;
	color: var(--pmx-muted);
	font-weight: 500;
}

.security-badge span.dot {
	width: 7px;
	height: 7px;
	background-color: var(--pmx-success);
	border-radius: 50%;
	box-shadow: 0 0 0 2px rgba(16, 185, 129, 0.25);
}

.legal-copy {
	margin-top: 20px;
	font-size: 11.5px;
	color: #94a3b8;
	text-align: center;
}