/**
 * Share My Ride — public Login / Register screens.
 * Self-contained (no Tailwind dependency): a split hero/form layout on
 * desktop that stacks on mobile, in the plugin's own teal brand.
 */
.smr-auth {
	--smr-auth-brand: #00808c;
	--smr-auth-brand-dark: #006670;
	--smr-auth-navy: #0f2942;
	--smr-auth-bg: #f3f4f6;
	--smr-auth-border: #e5e7eb;
	--smr-auth-text: #111827;
	--smr-auth-text-muted: #6b7280;
	--smr-auth-text-faint: #9ca3af;
	--smr-auth-danger: #dc2626;
	--smr-auth-danger-tint: #fef2f2;
	--smr-auth-success: #059669;
	--smr-auth-success-tint: #ecfdf5;

	font-family: "Inter", -apple-system, "Segoe UI", Roboto, sans-serif;
	color: var(--smr-auth-text);
	background: #fff;
	border-radius: 20px;
	overflow: hidden;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06), 0 12px 40px rgba(15, 41, 66, 0.08);
	max-width: 1100px;
	margin: 32px auto;
	display: flex;
	min-height: 620px;
}
.smr-auth * { box-sizing: border-box; }

/* ---------- Left panel ---------- */
.smr-auth-hero {
	width: 46%;
	position: relative;
	padding: 44px 40px;
	display: flex;
	flex-direction: column;
	justify-content: space-between;
	background:
		radial-gradient(120% 90% at 15% 100%, rgba(0, 128, 140, 0.16), transparent 60%),
		radial-gradient(90% 70% at 90% 0%, rgba(15, 41, 66, 0.08), transparent 55%),
		#f6fbfb;
	overflow: hidden;
}
.smr-auth-hero::before {
	content: "";
	position: absolute;
	inset: 0;
	background-image:
		repeating-linear-gradient(120deg, rgba(0, 128, 140, 0.05) 0 2px, transparent 2px 34px);
	pointer-events: none;
}
.smr-auth-hero-inner { position: relative; z-index: 1; display: flex; flex-direction: column; height: 100%; }
.smr-auth-brand-row {
	display: flex;
	align-items: center;
	gap: 12px;
	margin-bottom: 56px;
}
.smr-auth-brand-icon {
	width: 46px; height: 46px; border-radius: 13px;
	background: var(--smr-auth-navy);
	color: #fff;
	display: flex; align-items: center; justify-content: center;
	flex-shrink: 0;
}
.smr-auth-brand-name {
	font-weight: 700; font-size: 20px; line-height: 1.15; color: var(--smr-auth-navy);
}
.smr-auth-copy-wrap { flex: 1 1 auto; display: flex; flex-direction: column; justify-content: center; min-height: 0; }
.smr-auth-copy { max-width: 320px; }
.smr-auth-copy h2 {
	font-size: 32px; font-weight: 700; color: var(--smr-auth-navy);
	line-height: 1.2; margin: 0 0 16px;
}
.smr-auth-copy p { font-size: 15.5px; color: #4b5f6d; line-height: 1.6; margin: 0; }

.smr-auth-hero-stats {
	position: relative; z-index: 1;
	display: flex; gap: 22px; margin-top: 28px; flex-shrink: 0;
}
.smr-auth-hero-stat strong { display: block; font-size: 18px; font-weight: 700; color: var(--smr-auth-navy); }
.smr-auth-hero-stat span { font-size: 12px; color: #64798c; }

/* ---------- Right panel ---------- */
.smr-auth-panel {
	width: 54%;
	position: relative;
	padding: 44px 48px;
	display: flex;
	align-items: center;
	justify-content: center;
	background: #fcfdfd;
}
.smr-auth-welcome {
	position: absolute; top: 40px; right: 48px; text-align: right;
}
.smr-auth-welcome strong { display: block; color: var(--smr-auth-brand); font-weight: 600; font-size: 15px; }
.smr-auth-welcome span { font-size: 12.5px; color: var(--smr-auth-text-muted); }

.smr-auth-card { width: 100%; max-width: 400px; }
.smr-auth-card h1 { font-size: 26px; font-weight: 700; color: var(--smr-auth-navy); margin: 0 0 6px; }
.smr-auth-card-sub { font-size: 13.5px; color: var(--smr-auth-text-muted); margin: 0 0 26px; }

.smr-auth-alert {
	display: flex; align-items: flex-start; gap: 9px;
	padding: 11px 13px; border-radius: 11px; font-size: 13px; margin-bottom: 18px;
}
.smr-auth-alert-error { background: var(--smr-auth-danger-tint); color: #991b1b; }
.smr-auth-alert-success { background: var(--smr-auth-success-tint); color: #065f46; }
.smr-auth-alert svg { flex-shrink: 0; margin-top: 1px; }

/* ---------- Toast notification (floating popup for form errors) ---------- */
.smr-toast-wrap {
	position: fixed; top: 20px; left: 50%; transform: translateX(-50%);
	z-index: 9999; width: 100%; max-width: 420px; padding: 0 16px;
	pointer-events: none;
}
.smr-toast {
	display: flex; align-items: flex-start; gap: 10px;
	background: #fff; border-radius: 12px; padding: 14px 16px;
	box-shadow: 0 10px 34px rgba(15, 41, 66, 0.18), 0 2px 8px rgba(15, 41, 66, 0.08);
	border-left: 4px solid var(--smr-auth-danger);
	font-size: 13.5px; color: #1f2937; line-height: 1.45;
	opacity: 0; transform: translateY(-14px); pointer-events: auto;
	transition: opacity 0.25s ease, transform 0.25s ease;
}
.smr-toast.is-visible { opacity: 1; transform: translateY(0); }
.smr-toast.is-success { border-left-color: var(--smr-auth-success); }
.smr-toast svg { flex-shrink: 0; margin-top: 1px; color: var(--smr-auth-danger); }
.smr-toast.is-success svg { color: var(--smr-auth-success); }
.smr-toast span { flex: 1; }
.smr-toast-close {
	background: none; border: none; padding: 0; margin: -2px -2px 0 0; cursor: pointer;
	color: #9ca3af; font-size: 17px; line-height: 1; flex-shrink: 0;
}
.smr-toast-close:hover { color: #6b7280 !important; background: none !important; }

.smr-auth-field { margin-bottom: 16px; }
.smr-auth-field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.smr-auth-field-row .smr-auth-field { margin-bottom: 16px; }
.smr-auth-field-optional { font-weight: 400; color: var(--smr-auth-text-faint); }
.smr-auth-field label { display: block; font-size: 13px; font-weight: 600; color: #374151; margin-bottom: 7px; }
.smr-auth-photo-picker {
	display: flex; align-items: center; gap: 12px; cursor: pointer;
	padding: 8px 12px 8px 8px; border: 1.5px dashed var(--smr-auth-border); border-radius: 12px;
	transition: border-color 0.15s ease;
}
.smr-auth-photo-picker:hover { border-color: var(--smr-auth-brand); }
.smr-auth-photo-preview {
	width: 42px; height: 42px; border-radius: 50%; flex-shrink: 0; overflow: hidden;
	background: var(--smr-auth-bg); color: var(--smr-auth-text-faint);
	display: flex; align-items: center; justify-content: center;
}
.smr-auth-photo-preview img { width: 100%; height: 100%; object-fit: cover; }
.smr-auth-photo-picker-text { font-size: 12.5px; font-weight: 600; color: var(--smr-auth-text-muted); }
.smr-auth-photo-input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.smr-auth-input-wrap { position: relative; }
.smr-auth-input-wrap svg.smr-auth-input-icon {
	position: absolute; left: 12px; top: 50%; transform: translateY(-50%);
	color: #9ca3af; pointer-events: none;
}
.smr-auth-input-wrap input {
	width: 100%;
	padding: 12px 14px 12px 40px;
	border: 1px solid var(--smr-auth-border);
	border-radius: 12px;
	font-size: 14px;
	font-family: inherit;
	color: var(--smr-auth-text);
	background: #fff;
}
.smr-auth-input-wrap input:focus {
	outline: none;
	border-color: var(--smr-auth-brand);
	box-shadow: 0 0 0 3px rgba(0, 128, 140, 0.14);
}
.smr-auth-input-wrap.has-toggle input { padding-right: 42px; }
.smr-auth-toggle-visibility {
	position: absolute; right: 10px; top: 50%; transform: translateY(-50%);
	background: none; border: none; padding: 4px; cursor: pointer;
	color: #9ca3af; display: flex;
}
.smr-auth-toggle-visibility:hover { color: #6b7280 !important; background: none !important; }
.smr-auth-field-error { font-size: 12px; color: var(--smr-auth-danger); margin-top: 6px; }
.smr-auth-field-hint { font-size: 11.5px; color: var(--smr-auth-text-faint); margin-top: 6px; }

.smr-auth-row { display: flex; align-items: center; justify-content: space-between; margin-bottom: 24px; font-size: 13.5px; }
.smr-auth-check { display: flex; align-items: center; gap: 8px; color: #374151; }
.smr-auth-check input { width: 16px; height: 16px; accent-color: var(--smr-auth-brand); }
.smr-auth-link { color: var(--smr-auth-brand); font-weight: 600; text-decoration: none; }
.smr-auth-link:hover { color: var(--smr-auth-brand-dark); text-decoration: underline; }

.smr-auth-terms { font-size: 12.5px; color: var(--smr-auth-text-muted); line-height: 1.5; margin-bottom: 22px; display: flex; gap: 8px; align-items: flex-start; }
.smr-auth-terms input { width: 16px; height: 16px; accent-color: var(--smr-auth-brand); margin-top: 2px; flex-shrink: 0; }

.smr-auth-submit {
	width: 100%;
	padding: 13px 16px;
	border: none;
	border-radius: 12px;
	background: var(--smr-auth-brand);
	color: #fff;
	font-size: 14px;
	font-weight: 700;
	cursor: pointer;
	transition: background 0.15s ease;
}
.smr-auth-submit:hover { background: var(--smr-auth-brand-dark); }
.smr-auth-submit:disabled { opacity: 0.6; cursor: not-allowed; }

.smr-auth-divider { position: relative; text-align: center; margin: 26px 0 20px; font-size: 12.5px; color: var(--smr-auth-text-muted); }
.smr-auth-divider::before {
	content: ""; position: absolute; left: 0; right: 0; top: 50%;
	border-top: 1px solid var(--smr-auth-border);
}
.smr-auth-divider span { position: relative; background: #fcfdfd; padding: 0 12px; }

.smr-auth-social { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 24px; }
.smr-auth-social-btn {
	display: flex; align-items: center; justify-content: center; gap: 9px;
	padding: 10px 12px; border: 1px solid var(--smr-auth-border); border-radius: 12px;
	background: #fff; font-size: 13px; font-weight: 600; color: #374151;
	cursor: pointer;
}
.smr-auth-social-btn:hover { background: #f9fafb !important; border-color: #d1d5db !important; }
.smr-auth-social-note { font-size: 11px; color: var(--smr-auth-text-faint); text-align: center; margin: -12px 0 20px; display: none; }
.smr-auth-social-note.is-visible { display: block; }

.smr-auth-switch { text-align: center; font-size: 13.5px; color: var(--smr-auth-text-muted); }

/* ---------- Role selector (register step 1) ---------- */
.smr-auth-role-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 6px; }
.smr-auth-role-card {
	display: flex; flex-direction: column; align-items: center; text-align: center;
	background: #fff; border: 1.5px solid var(--smr-auth-border); border-radius: 16px;
	padding: 24px 16px 20px; cursor: pointer; font-family: inherit;
	transition: border-color 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease;
}
.smr-auth-role-card { background-color: #fff; }
.smr-auth-role-grid .smr-auth-role-card:hover {
	border-color: #2563eb !important;
	background-color: #eff6ff !important;
	color: inherit !important;
	box-shadow: 0 8px 24px rgba(37, 99, 235, 0.15);
	transform: translateY(-1px);
}
.smr-auth-role-icon {
	width: 58px; height: 58px; border-radius: 50%; margin-bottom: 14px;
	display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.smr-auth-role-icon-driver { background: #dbeafe; color: #2563eb; }
.smr-auth-role-icon-passenger { background: var(--smr-auth-success-tint); color: var(--smr-auth-success); }
.smr-auth-role-card-title { display: block; font-size: 15.5px; font-weight: 700; color: var(--smr-auth-navy); margin-bottom: 6px; }
.smr-auth-role-card-desc { display: block; font-size: 12px; color: var(--smr-auth-text-muted); line-height: 1.45; margin-bottom: 16px; }
.smr-auth-role-arrow {
	width: 32px; height: 32px; border-radius: 50%; flex-shrink: 0;
	display: flex; align-items: center; justify-content: center;
	background: var(--smr-auth-bg); color: var(--smr-auth-text-muted);
	transition: background 0.15s ease, color 0.15s ease;
}
.smr-auth-role-card:hover .smr-auth-role-arrow-driver { background: #2563eb; color: #fff; }
.smr-auth-role-card:hover .smr-auth-role-arrow-passenger { background: var(--smr-auth-success); color: #fff; }

.smr-auth-role-back {
	display: inline-flex; align-items: center; gap: 5px;
	background: none; border: none; padding: 0; margin-bottom: 16px; cursor: pointer;
	font-family: inherit; font-size: 12.5px; font-weight: 600; color: var(--smr-auth-text-muted);
}
.smr-auth-role-back:hover { color: #2563eb !important; background: none !important; }
.smr-auth-role-chosen {
	display: flex; align-items: center; justify-content: space-between; gap: 10px;
	background: var(--smr-auth-bg); border-radius: 10px; padding: 10px 14px;
	font-size: 12.5px; color: var(--smr-auth-text-muted); margin-bottom: 18px;
}
.smr-auth-role-chosen strong { color: var(--smr-auth-navy); font-weight: 700; }

/* ---------- Feature strip ---------- */
.smr-auth-features {
	max-width: 1100px; margin: 0 auto; padding: 30px 24px 10px;
	display: flex; gap: 8px;
	font-family: "Inter", -apple-system, "Segoe UI", Roboto, sans-serif;
}
.smr-auth-feature { flex: 1; text-align: center; padding: 0 12px; }
.smr-auth-feature + .smr-auth-feature { border-left: 1px solid #f1f1f1; }
.smr-auth-feature-icon {
	width: 38px; height: 38px; margin: 0 auto 10px; color: #00808c;
	display: flex; align-items: center; justify-content: center;
}
.smr-auth-feature h4 { font-size: 13px; font-weight: 700; color: #111827; margin: 0 0 4px; }
.smr-auth-feature p { font-size: 11.5px; color: #6b7280; margin: 0; line-height: 1.5; }

/* ---------- Responsive ---------- */
@media (max-width: 880px) {
	.smr-auth { flex-direction: column; margin: 0; border-radius: 0; min-height: 0; }
	.smr-auth-hero, .smr-auth-panel { width: 100%; }
	.smr-auth-hero { padding: 32px 24px; }
	.smr-auth-copy { max-width: none; }
	.smr-auth-hero-stats { margin-top: 22px; }
	.smr-auth-panel { padding: 32px 24px; }
	.smr-auth-welcome { display: none; }
	.smr-auth-features { flex-wrap: wrap; }
	.smr-auth-feature { flex: 1 1 45%; margin-bottom: 20px; border-left: none !important; }
	.smr-auth-role-grid { grid-template-columns: 1fr; }
	.smr-auth-field-row { grid-template-columns: 1fr; gap: 0; }
}
@media (max-width: 460px) {
	.smr-auth-social { grid-template-columns: 1fr; }
}
