/**
 * Puntos Ya - Páginas Login y Recuperar contraseña
 */

/* ─── Layout de la página de login: panel bienvenida + formulario ─── */
.puntos-ya-login-layout {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 40px;
	max-width: 900px;
	margin: 0 auto;
	align-items: stretch;
}

@media (max-width: 768px) {
	.puntos-ya-login-layout {
		grid-template-columns: 1fr;
		gap: 24px;
	}
	/* Formulario primero, tarjeta de información después */
	.puntos-ya-login-form-col {
		order: 1;
	}
	.puntos-ya-login-welcome {
		order: 2;
	}
	/* Sin margen automático en móvil */
	.puntos-ya-login-card,
	.puntos-ya-lost-password-card {
		margin: 0;
	}
}

/* ─── Panel derecho: bienvenida ─── */
.puntos-ya-login-welcome {
	background: linear-gradient(160deg, var(--color-orange) 0%, var(--color-orange-dark, #c44d03) 100%);
	border-radius: 16px;
	padding: 40px 32px;
	color: #fff;
	box-shadow: 0 8px 32px rgba(232, 93, 4, 0.35);
	position: sticky;
	top: calc(var(--header-offset) + 24px);
	display: flex;
	flex-direction: column;
}

.puntos-ya-login-welcome__inner {
	flex: 1;
	display: flex;
	flex-direction: column;
}

.puntos-ya-login-welcome__logo {
	width: 48px;
	height: 48px;
	margin-bottom: 24px;
}
.puntos-ya-login-welcome__logo svg {
	width: 100%;
	height: 100%;
}

.puntos-ya-login-welcome__title {
	font-size: 1.5rem;
	font-weight: 700;
	line-height: 1.25;
	margin: 0 0 16px;
	letter-spacing: -0.02em;
	color: #fff;
}

.puntos-ya-login-welcome__desc {
	font-size: 0.9375rem;
	line-height: 1.65;
	color: rgba(255, 255, 255, 0.88);
	margin: 0;
}

.puntos-ya-login-welcome__contacts {
	display: flex;
	flex-direction: column;
	gap: 14px;
	margin-top: auto;
	padding-top: 28px;
}

.puntos-ya-login-contact-item {
	display: flex;
	align-items: center;
	gap: 12px;
	color: rgba(255, 255, 255, 0.92);
	font-size: 0.9375rem;
	font-weight: 500;
	text-decoration: none;
	transition: color 0.2s;
}
.puntos-ya-login-contact-item:hover {
	color: #fff;
}

.puntos-ya-login-contact-item__icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	background: rgba(255, 255, 255, 0.2);
	border-radius: 10px;
	flex-shrink: 0;
	transition: background 0.2s;
}
.puntos-ya-login-contact-item:hover .puntos-ya-login-contact-item__icon {
	background: rgba(255, 255, 255, 0.3);
}
.puntos-ya-login-contact-item__icon svg {
	width: 18px;
	height: 18px;
	stroke: #fff;
	fill: none;
	stroke-width: 2;
	stroke-linecap: round;
	stroke-linejoin: round;
}

/* ─── Panel derecho: formulario ─── */
.puntos-ya-login-form-col {
	display: flex;
	flex-direction: column;
}

/* Ocultar <br> que WooCommerce o wpautop inyectan en los formularios de login/contraseña */
.puntos-ya-login-form br,
.puntos-ya-lost-password-form br,
.puntos-ya-password-form br {
	display: none;
}

/* Espaciado entre hero y footer */
/* .puntos-ya-content y .puntos-ya-woocommerce-content: sin padding-top */
.puntos-ya-account .puntos-ya-content,
.puntos-ya-account .puntos-ya-woocommerce-content {
	padding-top: 0 !important;
}
/* Solo .woocommerce recibe padding-top 32px */
.puntos-ya-account .woocommerce {
	padding: 32px 20px 20px;
}

.puntos-ya-login-card,
.puntos-ya-lost-password-card {
	background: var(--color-bg);
	border-radius: 16px;
	padding: 32px;
	box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
	border: 1px solid var(--color-border);
}

.puntos-ya-login-card__title {
	font-size: 1.25rem;
	font-weight: 700;
	margin: 0 0 24px;
	letter-spacing: -0.02em;
}

.puntos-ya-login-form .form-row,
.puntos-ya-lost-password-form .form-row {
	margin-bottom: 20px;
}

.puntos-ya-login-form label,
.puntos-ya-lost-password-form label {
	display: block;
	font-size: 0.75rem;
	font-weight: 500;
	color: var(--color-text-muted);
	text-transform: uppercase;
	letter-spacing: 0.05em;
	margin-bottom: 6px;
}

.puntos-ya-login-form .required,
.puntos-ya-lost-password-form .required {
	color: var(--color-orange);
}

.puntos-ya-login-form input[type="text"],
.puntos-ya-login-form input[type="email"],
.puntos-ya-login-form input[type="password"],
.puntos-ya-lost-password-form input[type="text"],
.puntos-ya-lost-password-form input[type="email"] {
	width: 100%;
	padding: 12px 14px;
	border: 1px solid var(--color-border);
	border-radius: 10px;
	font-size: 0.9375rem;
	font-family: inherit;
	transition: border-color 0.2s, box-shadow 0.2s;
}

.puntos-ya-login-form input:focus,
.puntos-ya-lost-password-form input:focus {
	outline: none;
	border-color: var(--color-orange);
	box-shadow: 0 0 0 3px rgba(232, 93, 4, 0.12);
}

.puntos-ya-login-actions {
	display: flex;
	flex-direction: column;
	gap: 16px;
	margin-top: 24px;
}

.puntos-ya-login-actions .woocommerce-form-login__rememberme {
	font-size: 0.9375rem;
	font-weight: 500;
	text-transform: none;
	letter-spacing: 0;
	color: var(--color-text);
}

.puntos-ya-login-actions .woocommerce-form-login__rememberme input {
	margin-right: 8px;
}

.puntos-ya-LostPassword {
	margin-top: 16px;
}

.puntos-ya-LostPassword a {
	color: var(--color-orange);
	font-weight: 500;
}

.puntos-ya-LostPassword a:hover {
	text-decoration: underline;
}

/* Columnas login + registro */
.puntos-ya-login-columns {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 32px;
	max-width: 900px;
	margin: 0 auto;
}

@media (max-width: 768px) {
	.puntos-ya-login-columns {
		grid-template-columns: 1fr;
	}
}

/* Lost password */
.puntos-ya-lost-password-intro {
	font-size: 0.9375rem;
	color: var(--color-text-muted);
	line-height: 1.6;
	margin: 0 0 24px;
}

.puntos-ya-lost-password-confirmation p {
	margin-bottom: 16px;
}

.puntos-ya-lost-password-confirmation .puntos-ya-btn {
	margin-top: 8px;
	text-decoration: none;
	display: inline-block;
}

/* Botón Mostrar contraseña (añadido por WooCommerce JS) - icono ojo dentro del input */
.puntos-ya-login-form .password-input,
.puntos-ya-lost-password-form .password-input,
.puntos-ya-password-form .password-input {
	display: block;
	position: relative;
	width: 100%;
}

.puntos-ya-login-form .password-input input,
.puntos-ya-lost-password-form .password-input input,
.puntos-ya-password-form .password-input input {
	display: block;
	width: 100%;
	box-sizing: border-box;
	padding-right: 44px;
}

.puntos-ya-login-form .show-password-input,
.puntos-ya-lost-password-form .show-password-input,
.puntos-ya-password-form .show-password-input {
	position: absolute;
	right: 12px;
	top: 0;
	bottom: 0;
	width: 24px;
	height: auto;
	margin: auto 0;
	padding: 0;
	background: transparent;
	border: none;
	cursor: pointer;
	font-size: 0;
	overflow: hidden;
	display: flex;
	align-items: center;
	justify-content: center;
}

.puntos-ya-login-form .show-password-input::before,
.puntos-ya-lost-password-form .show-password-input::before,
.puntos-ya-password-form .show-password-input::before {
	content: "";
	position: absolute;
	inset: 0;
	background-color: var(--color-text-muted);
	mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1 12s4-8 11-8 11 8 11 8-4 8-11 8-11-8-11-8z'/%3E%3Ccircle cx='12' cy='12' r='3'/%3E%3C/svg%3E") no-repeat center;
	mask-size: 20px 20px;
	-webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1 12s4-8 11-8 11 8 11 8-4 8-11 8-11-8-11-8z'/%3E%3Ccircle cx='12' cy='12' r='3'/%3E%3C/svg%3E") no-repeat center;
	-webkit-mask-size: 20px 20px;
	transition: background-color 0.2s;
}

/* Ojo cerrado: mismo ojo abierto + línea diagonal que lo cruza */
.puntos-ya-login-form .show-password-input.display-password::before,
.puntos-ya-lost-password-form .show-password-input.display-password::before,
.puntos-ya-password-form .show-password-input.display-password::before {
	mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1 12s4-8 11-8 11 8 11 8-4 8-11 8-11-8-11-8z'/%3E%3Ccircle cx='12' cy='12' r='3'/%3E%3Cline x1='2' y1='2' x2='22' y2='22'/%3E%3C/svg%3E") no-repeat center;
	mask-size: 20px 20px;
	-webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1 12s4-8 11-8 11 8 11 8-4 8-11 8-11-8-11-8z'/%3E%3Ccircle cx='12' cy='12' r='3'/%3E%3Cline x1='2' y1='2' x2='22' y2='22'/%3E%3C/svg%3E") no-repeat center;
	-webkit-mask-size: 20px 20px;
}

.puntos-ya-login-form .show-password-input:hover::before,
.puntos-ya-lost-password-form .show-password-input:hover::before,
.puntos-ya-password-form .show-password-input:hover::before {
	background-color: var(--color-orange);
}
