/* ==========================================================================
   Shopzone — split-screen login.

   login_hero.js injects an <aside class="sz-hero"> before .page_content on the
   /login page only, adds .sz-login-grid to its parent and .sz-login-split to the
   body. All rules below are scoped to those classes, so no other portal/web page
   is affected. RTL-safe (logical properties); the grid start-column naturally
   flips to the right side under `dir="rtl"`.
   ========================================================================== */

/* The default website navbar is redundant once the hero carries the brand. */
body.sz-login-split .navbar {
	display: none !important;
}
body.sz-login-split {
	background: var(--card-bg, #fff);
}

/* Full-viewport two-column split. */
.sz-login-grid {
	max-width: none !important;
	width: 100%;
	margin: 0 !important;
	padding: 0 !important;
	min-height: 100vh;
	display: grid;
	grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
}

/* Right column: Frappe's auth card, vertically centered. */
.sz-login-grid > .page_content {
	grid-column: 2;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 32px 24px;
	min-height: 100vh;
}
.sz-login-grid > .page_content > section {
	width: 100%;
	max-width: 380px;
}

/* Left column: brand hero. */
.sz-hero {
	grid-column: 1;
	position: relative;
	overflow: hidden;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 48px;
	color: #fff;
	/* Brand palette sampled from the Shopzone logo (see setup/branding.py):
	   vivid orange (#f5821f) glow over a near-black (#231f20) base. */
	background:
		radial-gradient(1100px 600px at 18% 8%, rgba(245, 130, 31, 0.35), transparent 60%),
		linear-gradient(135deg, #1a1716 0%, #231f20 55%, #3a2a1c 100%);
}
.sz-hero-inner {
	position: relative;
	z-index: 2;
	max-width: 440px;
}
.sz-hero-logo {
	display: inline-flex;
	background: #fff;
	border-radius: 16px;
	padding: 14px 20px;
	box-shadow: 0 14px 34px rgba(0, 0, 0, 0.2);
	margin-bottom: 28px;
}
.sz-hero-logo img {
	height: 44px;
	width: auto;
	display: block;
}
.sz-hero-title {
	font-size: 2.3rem;
	font-weight: 800;
	line-height: 1.1;
	letter-spacing: -0.02em;
	margin: 0 0 10px;
	color: #fff;
}
.sz-hero-sub {
	font-size: 1.05rem;
	opacity: 0.92;
	margin: 0 0 30px;
}
.sz-hero-feats {
	list-style: none;
	padding: 0;
	margin: 0;
	display: flex;
	flex-direction: column;
	gap: 14px;
}
.sz-hero-feats li {
	display: flex;
	align-items: center;
	gap: 12px;
	font-size: 0.98rem;
	opacity: 0.96;
}
.sz-hero-feats li .sz-tick {
	flex: 0 0 24px;
	height: 24px;
	border-radius: 50%;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	background: rgba(255, 255, 255, 0.18);
	font-size: 13px;
	font-weight: 700;
}

/* Decorative blurred orbs. */
.sz-hero-orbs::before,
.sz-hero-orbs::after {
	content: "";
	position: absolute;
	border-radius: 50%;
	z-index: 1;
}
.sz-hero-orbs::before {
	width: 280px;
	height: 280px;
	background: rgba(245, 130, 31, 0.22);
	bottom: -90px;
	inset-inline-end: -70px;
}
.sz-hero-orbs::after {
	width: 190px;
	height: 190px;
	background: rgba(255, 255, 255, 0.08);
	top: -60px;
	inset-inline-start: 32%;
}

/* Polish the existing auth card, drop the now-duplicate card-head logo. */
body.sz-login-split .login-content.page-card {
	border: 1px solid var(--border-color);
	border-radius: 14px;
	box-shadow: 0 18px 50px rgba(17, 24, 39, 0.1);
}
body.sz-login-split .for-login .page-card-head .app-logo {
	display: none;
}
body.sz-login-split .page-card-head h4 {
	font-weight: 800;
}

/* Brand accents: pulled from the logo's vivid orange */
:root {
	--shopzone-accent: #f5821f;
	--shopzone-accent-contrast: #ffffff;
}

/* ---- AR/EN language switcher --------------------------------------------
   Floated in the top inline-start corner, which is always over the dark hero:
   inline-start maps to the hero column in both LTR and RTL, and on the stacked
   mobile layout the hero is the top row — so the translucent-white-on-dark pill
   stays readable in every layout. Injected by login_hero.js on /login only. */
.sz-lang {
	position: fixed;
	top: 18px;
	inset-inline-start: 18px;
	z-index: 1000;
	display: inline-flex;
	gap: 2px;
	padding: 3px;
	border-radius: 999px;
	background: rgba(255, 255, 255, 0.12);
	border: 1px solid rgba(255, 255, 255, 0.28);
	backdrop-filter: blur(6px);
	-webkit-backdrop-filter: blur(6px);
	box-shadow: 0 6px 18px rgba(0, 0, 0, 0.16);
}
.sz-lang-btn {
	appearance: none;
	-webkit-appearance: none;
	border: 0;
	cursor: pointer;
	padding: 6px 14px;
	border-radius: 999px;
	font-size: 0.85rem;
	font-weight: 600;
	line-height: 1;
	color: #fff;
	background: transparent;
	transition: background 0.15s ease, color 0.15s ease;
}
.sz-lang-btn:hover {
	background: rgba(255, 255, 255, 0.16);
}
.sz-lang-btn.is-active {
	background: var(--shopzone-accent);
	color: var(--shopzone-accent-contrast);
}
.sz-lang-btn:focus-visible {
	outline: 2px solid var(--shopzone-accent-contrast);
	outline-offset: 1px;
}
@media (max-width: 480px) {
	.sz-lang {
		top: 12px;
		inset-inline-start: 12px;
	}
	.sz-lang-btn {
		padding: 5px 11px;
		font-size: 0.8rem;
	}
}

/* Make primary actions match the logo accent */
body.sz-login-split .btn-primary,
body.sz-login-split button.btn-primary {
	background: var(--shopzone-accent) !important;
	border-color: var(--shopzone-accent) !important;
	color: var(--shopzone-accent-contrast) !important;
	box-shadow: 0 10px 20px rgba(245,130,31,0.12);
}

/* Links and interactive accents */
body.sz-login-split a {
	color: var(--shopzone-accent);
}

/* Focus and hover states */
body.sz-login-split .btn-primary:hover,
body.sz-login-split button.btn-primary:hover {
	filter: brightness(0.97);
}

/* Make small app-logo inside the auth card match spacing when shown */
body.sz-login-split .for-login .page-card-head .app-logo {
	display: none;
}

/* ---- responsive: stack under ~900px (tablet / half-screen laptop) ------- */
@media (max-width: 900px) {
	.sz-login-grid {
		grid-template-columns: 1fr;
	}
	.sz-login-grid > .sz-hero {
		grid-column: 1;
		grid-row: 1;
		min-height: auto;
		padding: 30px 24px;
	}
	.sz-login-grid > .page_content {
		grid-column: 1;
		min-height: auto;
		padding: 28px 20px;
	}
	.sz-hero-inner {
		max-width: 560px;
		text-align: center;
		margin: 0 auto;
	}
	.sz-hero-feats {
		display: none;
	}
	.sz-hero-sub {
		margin-bottom: 6px;
	}
}
@media (max-width: 480px) {
	.sz-hero-title {
		font-size: 1.7rem;
	}
	.sz-hero-logo img {
		height: 36px;
	}
	.sz-hero {
		padding: 24px 18px;
	}
}
