:root {
	--lme-auth-wine: #5b0f22;
	--lme-auth-wine-dark: #430919;
	--lme-auth-cream: #fffaf6;
	--lme-auth-rose: #f7ece9;
	--lme-auth-border: #e4d0ca;
	--lme-auth-text: #3f232a;
}

.lme-auth,
.lme-account-menu {
	box-sizing: border-box;
	color: var(--lme-auth-text);
	font-family: inherit;
}

.lme-auth *,
.lme-account-menu * { box-sizing: border-box; }

.lme-auth {
	display: grid;
	width: 100%;
	min-width: 0;
	min-height: 0;
	padding: clamp(18px, 4vw, 40px) 0;
	place-items: center;
	background: transparent;
}

.lme-auth-card {
	width: min(100%, 520px);
	padding: clamp(28px, 6vw, 52px);
	border: 1px solid var(--lme-auth-border);
	border-radius: 28px;
	background: rgba(255, 255, 255, .94);
	box-shadow: 0 18px 55px rgba(91, 15, 34, .07);
}

.lme-auth-card h1 {
	margin: 7px 0 12px;
	color: var(--lme-auth-wine);
	font-family: Georgia, "Times New Roman", serif;
	font-size: clamp(2rem, 6vw, 3rem);
	font-weight: 500;
	line-height: 1.08;
}

.lme-auth-eyebrow {
	margin: 0;
	color: #9b6873;
	font-size: .76rem;
	font-weight: 700;
	letter-spacing: .18em;
	text-transform: uppercase;
}

.lme-auth-intro { margin: 0 0 28px; color: #75535a; line-height: 1.65; }
.lme-auth-form { display: grid; gap: 18px; }
.lme-auth-form label:not(.lme-auth-check) { display: grid; gap: 8px; font-weight: 650; }
.lme-auth-form label small,
.lme-auth-help { color: #86646b; font-size: .82rem; font-weight: 400; }

.lme-auth-form input[type="text"],
.lme-auth-form input[type="email"],
.lme-auth-form input[type="password"] {
	width: 100%;
	min-height: 52px;
	padding: 12px 15px;
	border: 1px solid var(--lme-auth-border);
	border-radius: 14px;
	background: #fff;
	color: var(--lme-auth-text);
	font: inherit;
}

.lme-auth-form input[readonly] { background: #f8f1ee; color: #765b61; }
.lme-password-field { position: relative; display: block; min-width: 0; }
.lme-password-field input[type="password"],
.lme-password-field input[type="text"] { padding-right: 54px; }
.lme-password-toggle {
	position: absolute;
	top: 50%;
	right: 8px;
	display: grid;
	width: 38px;
	height: 38px;
	padding: 0;
	border: 0;
	border-radius: 10px;
	background: transparent;
	box-shadow: none;
	color: #81535d;
	cursor: pointer;
	place-items: center;
	transform: translateY(-50%);
}
.lme-password-toggle:hover { background: var(--lme-auth-rose); color: var(--lme-auth-wine); }
.lme-password-toggle svg { fill: none; stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; stroke-width: 1.7; }
.lme-password-toggle[aria-pressed="true"] .lme-password-toggle__slash { display: none; }
.lme-auth-form input:focus-visible,
.lme-auth a:focus-visible,
.lme-auth button:focus-visible,
.lme-account-menu a:focus-visible,
.lme-account-menu button:focus-visible { outline: 3px solid rgba(91, 15, 34, .28); outline-offset: 3px; }

.lme-auth-form__row { display: flex; align-items: center; justify-content: space-between; gap: 16px; font-size: .9rem; }
.lme-auth-check { display: inline-flex; align-items: center; gap: 8px; }
.lme-auth a { color: var(--lme-auth-wine); font-weight: 650; }

.lme-auth-button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 50px;
	padding: 13px 24px;
	border: 1px solid var(--lme-auth-wine);
	border-radius: 999px;
	background: var(--lme-auth-wine);
	color: #fff !important;
	font: inherit;
	font-weight: 750;
	text-decoration: none !important;
	cursor: pointer;
}

.lme-auth-button:hover { background: var(--lme-auth-wine-dark); }
.lme-auth-footer { margin: 25px 0 0; text-align: center; }
.lme-auth-notice { margin: 0 0 20px; padding: 14px 16px; border: 1px solid #dbc4bd; border-radius: 14px; background: var(--lme-auth-rose); line-height: 1.45; }
.lme-auth-notice--error { border-color: #d98686; background: #fff1f0; color: #8b1d1d; }
.lme-auth-notice--success { border-color: #a6c3a9; background: #f1faf2; color: #285b31; }

@media (max-width: 560px) {
	.lme-auth { min-height: 0; padding-inline: 0; }
	.lme-auth-card { padding: 28px 20px; border-radius: 22px; }
	.lme-auth-form__row { align-items: flex-start; flex-direction: column; }
}

.lme-account-menu {
	position: relative;
	display: inline-flex;
	align-items: center;
	z-index: 50;
	--lme-menu-transition: 220ms ease;
}
.lme-account-menu a { color: var(--lme-auth-wine); text-decoration: none; }
.lme-account-menu__guest,
.lme-account-menu__authenticated { position: relative; display: inline-flex; }
.lme-account-menu__trigger {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 9px;
	min-height: 48px;
	padding: 5px 11px 5px 5px;
	border: 1px solid var(--lme-auth-border);
	border-radius: 999px;
	appearance: none;
	background: transparent;
	box-shadow: none;
	color: var(--lme-auth-wine);
	font: inherit;
	font-weight: 750;
	cursor: pointer;
	transition: border-color var(--lme-menu-transition), background-color var(--lme-menu-transition), box-shadow var(--lme-menu-transition), transform var(--lme-menu-transition);
}
.lme-account-menu__trigger:hover,
.lme-account-menu__trigger[aria-expanded="true"] { border-color: #895052; background: #895052; color: #fff; transform: translateY(-1px); }
.lme-account-menu__trigger img { width: 36px; height: 36px; border-radius: 50%; object-fit: cover; background: var(--lme-auth-rose); }
.lme-account-menu__trigger--guest {
	width: 50px;
	height: 50px;
	min-height: 50px;
	padding: 12px;
	border-color: var(--lme-auth-wine);
	border-radius: 12px;
	background: transparent;
	box-shadow: none;
}
.lme-account-menu__account-icon,
.lme-account-menu__chevron,
.lme-account-menu__item-icon svg { fill: none; stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; stroke-width: 1.7; }
.lme-account-menu__account-icon { display: block; width: 24px; height: 24px; }
.lme-account-menu__chevron { flex: 0 0 auto; transition: transform var(--lme-menu-transition); }
.lme-account-menu__trigger[aria-expanded="true"] .lme-account-menu__chevron { transform: rotate(180deg); }
.lme-account-menu__dropdown {
	position: absolute;
	top: calc(100% + 10px);
	right: 0;
	width: 310px;
	max-width: calc(100vw - 24px);
	padding: 10px;
	border: 1px solid var(--lme-auth-border);
	border-radius: 15px;
	background: #fffdfb;
	box-shadow: 0 18px 50px rgba(67, 8, 23, .12);
}
.lme-account-menu__dropdown[hidden] { display: none; }
.lme-account-menu__dropdown--authenticated a {
	display: flex;
	align-items: center;
	gap: 13px;
	min-height: 48px;
	padding: 10px 12px;
	border-radius: 10px;
	color: var(--lme-auth-text);
	font-size: .92rem;
	font-weight: 400;
	line-height: 1.3;
	transition: color var(--lme-menu-transition), background-color var(--lme-menu-transition);
}
.lme-account-menu__dropdown--authenticated a:hover,
.lme-account-menu__dropdown--authenticated a:focus-visible { background: var(--lme-auth-rose); color: var(--lme-auth-wine); }
.lme-account-menu__item-icon { display: grid; flex: 0 0 24px; width: 24px; color: #a16972; place-items: center; }
.lme-account-menu__item-icon svg { display: block; width: 22px; height: 22px; }
.lme-account-menu__dropdown--authenticated .lme-account-menu__logout { margin-top: 7px; border-top: 1px solid var(--lme-auth-border); border-radius: 0 0 10px 10px; color: #9c162f; }
.lme-account-menu__dropdown--guest { width: 258px; padding: 17px; }
.lme-account-menu__guest-title { margin: 0 0 13px; color: #8d5964; font-size: .92rem; font-weight: 700; }
.lme-account-menu__dropdown--guest .lme-account-menu__login {
	display: flex;
	align-items: center;
	justify-content: center;
	min-height: 44px;
	padding: 10px 16px;
	border: 1px solid var(--lme-auth-wine);
	border-radius: 5px;
	background: var(--lme-auth-wine);
	color: #fff;
	font-size: .92rem;
	font-weight: 750;
	transition: border-color var(--lme-menu-transition), background-color var(--lme-menu-transition), transform var(--lme-menu-transition);
}
.lme-account-menu__dropdown--guest .lme-account-menu__login:hover { border-color: var(--lme-auth-wine-dark); background: var(--lme-auth-wine-dark); transform: translateY(-1px); }
.lme-account-menu__guest-footer { margin-top: 17px; padding-top: 16px; border-top: 1px solid var(--lme-auth-border); text-align: center; }
.lme-account-menu__guest-footer p { margin: 0 0 7px; color: #86646b; font-size: .82rem; font-weight: 400; }
.lme-account-menu__guest-footer .lme-account-menu__register { color: var(--lme-auth-wine); font-size: .84rem; font-weight: 700; text-decoration: underline; text-underline-offset: 3px; }
.lme-account-menu__guest-footer .lme-account-menu__register:hover { color: var(--lme-auth-wine-dark); }

@media (max-width: 480px) {
	.lme-account-menu__trigger { min-height: 44px; }
	.lme-account-menu__trigger--guest { width: 44px; height: 44px; min-height: 44px; padding: 10px; }
	.lme-account-menu__dropdown { width: min(310px, calc(100vw - 24px)); }
	.lme-account-menu__dropdown--guest { width: min(258px, calc(100vw - 24px)); }
	.lme-account-menu__name { max-width: 110px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
}

@media (prefers-reduced-motion: reduce) {
	.lme-account-menu__trigger,
	.lme-account-menu__chevron,
	.lme-account-menu__dropdown a { transition-duration: .01ms; }
}
