/**
 * WoodMart + WooCommerce storefront — isolate Phone Auth from theme login UI.
 */

/* Above WoodMart sticky header, side panels, and mobile overlays */
body.ocpa-theme-woodmart .ocpa-modal.ocpa-auth-modal-root {
	z-index: 1000000;
}

body.ocpa-theme-woodmart.ocpa-auth-modal-open .wd-side-hidden,
body.ocpa-theme-woodmart.ocpa-auth-modal-open .login-form-side,
body.ocpa-theme-woodmart.ocpa-auth-modal-open .wd-login-side {
	pointer-events: none;
}

/* Branded auth embed inside theme content areas */
body.ocpa-theme-woodmart .ocpa-auth-embed,
body.ocpa-woo-branded-account .ocpa-auth-embed {
	max-width: 480px;
	margin: 0 auto 2rem;
}

body.ocpa-theme-woodmart .ocpa-auth-embed .ocpa-panel,
body.ocpa-woo-branded-account .ocpa-auth-embed .ocpa-panel {
	box-sizing: border-box;
}

/* Hide default WooCommerce login/register when branded forms are shown */
body.ocpa-woo-branded-account:has(.ocpa-auth-embed) #customer_login,
body.ocpa-woo-branded-account:has(.ocpa-auth-embed) form.woocommerce-form-login,
body.ocpa-woo-branded-account:has(.ocpa-auth-embed) form.woocommerce-form-register,
body.ocpa-woo-branded-account:has(.ocpa-auth-embed) .wd-registration-page,
body.ocpa-woo-branded-account:has(.ocpa-auth-embed) .wd-el-my-account-register,
body.ocpa-woo-branded-account:has(.ocpa-auth-embed) .e-con.e-child:has(> .wd-el-my-account-register),
body.ocpa-woo-branded-account:has(.ocpa-auth-embed) .elementor-column:has(> .elementor-widget-wrap > .wd-el-my-account-register) {
	display: none !important;
}

body.ocpa-woo-branded-account:has(.ocpa-auth-embed) .woocommerce-account h2:not(.ocpa-auth-embed h2) {
	display: none;
}

/* Prevent theme button styles from breaking OTP inputs */
body.ocpa-theme-woodmart .ocpa-modal .ocpa-otp-input,
body.ocpa-woo-branded-account .ocpa-otp-input {
	font-family: inherit;
	letter-spacing: 0.15em;
	text-align: center;
}

/* WoodMart two-column account layout: the one remaining column takes the middle of the page. */
body.ocpa-woo-branded-account:has(.ocpa-auth-embed) .e-con.e-child:has(> .wd-el-my-account-login),
body.ocpa-woo-branded-account:has(.ocpa-auth-embed) .elementor-column:has(> .elementor-widget-wrap > .wd-el-my-account-login) {
	width: 100% !important;
	max-width: 620px;
	margin-inline: auto;
}
