/*
 * Bricks Tabs — login/register (WooCommerce shortcodes + registration-form-fields).
 */

.brxe-tabs:has(.woocommerce-form-login), .brxe-tabs-nested:has(.woocommerce-form-login),
.brxe-tabs:has(.woocommerce-form-register), .brxe-tabs-nested:has(.woocommerce-form-register),
.brxe-tabs:has(.registration-form-fields), .brxe-tabs-nested.registration-form,
.brxe-tabs-nested:has(.registration-form-fields) {
	--tabs-accent: rgba(249, 166, 2, 0.85);
}

.brxe-tabs:has(.woocommerce-form-login) .tab-menu,
.brxe-tabs-nested:has(.woocommerce-form-login) .tab-menu,
.brxe-tabs:has(.woocommerce-form-register) .tab-menu,
.brxe-tabs-nested:has(.woocommerce-form-register) .tab-menu,
.brxe-tabs:has(.registration-form-fields) .tab-menu,
.brxe-tabs-nested.registration-form .tab-menu,
.brxe-tabs-nested:has(.registration-form-fields) .tab-menu {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
	margin-bottom: 1.25rem;
	padding: 0.35rem;
	background: var(--ig-auth-surface);
	border: 1px solid var(--ig-auth-border);
	border-radius: var(--ig-auth-radius);
}

.brxe-tabs:has(.woocommerce-form-login) .tab-title,
.brxe-tabs-nested:has(.woocommerce-form-login) .tab-title,
.brxe-tabs:has(.woocommerce-form-register) .tab-title,
.brxe-tabs-nested:has(.woocommerce-form-register) .tab-title,
.brxe-tabs:has(.registration-form-fields) .tab-title,
.brxe-tabs-nested.registration-form .tab-title,
.brxe-tabs-nested:has(.registration-form-fields) .tab-title {
	flex: 1 1 auto;
	min-width: 120px;
	text-align: center;
	padding: 0.65rem 1rem !important;
	margin: 0 !important;
	border-radius: var(--ig-auth-radius-sm) !important;
	border: 1px solid transparent !important;
	background: transparent !important;
	color: var(--ig-auth-muted) !important;
	font-weight: 600 !important;
	font-size: 0.9375rem !important;
	transition: color 0.2s ease, background 0.2s ease, border-color 0.2s ease;
	cursor: pointer;
}

.brxe-tabs:has(.woocommerce-form-login) .tab-title:hover,
.brxe-tabs-nested:has(.woocommerce-form-login) .tab-title:hover,
.brxe-tabs:has(.woocommerce-form-register) .tab-title:hover,
.brxe-tabs-nested:has(.woocommerce-form-register) .tab-title:hover,
.brxe-tabs:has(.registration-form-fields) .tab-title:hover,
.brxe-tabs-nested.registration-form .tab-title:hover,
.brxe-tabs-nested:has(.registration-form-fields) .tab-title:hover {
	color: var(--ig-auth-text) !important;
	background: rgba(255, 255, 255, 0.04) !important;
}

.brxe-tabs:has(.woocommerce-form-login) .tab-title.brx-open,
.brxe-tabs-nested:has(.woocommerce-form-login) .tab-title.brx-open,
.brxe-tabs:has(.woocommerce-form-register) .tab-title.brx-open,
.brxe-tabs-nested:has(.woocommerce-form-register) .tab-title.brx-open,
.brxe-tabs:has(.registration-form-fields) .tab-title.brx-open,
.brxe-tabs-nested.registration-form .tab-title.brx-open,
.brxe-tabs-nested:has(.registration-form-fields) .tab-title.brx-open {
	color: var(--ig-auth-tab-active-text) !important;
	background: var(--ig-auth-tab-active-bg) !important;
	border-color: var(--ig-auth-tab-active-border) !important;
	box-shadow: var(--ig-auth-tab-active-glow), inset 0 1px 0 rgba(255, 255, 255, 0.12);
	font-weight: 700 !important;
}

.brxe-tabs:has(.woocommerce-form-login) .tab-content,
.brxe-tabs-nested:has(.woocommerce-form-login) .tab-content,
.brxe-tabs:has(.woocommerce-form-register) .tab-content,
.brxe-tabs-nested:has(.woocommerce-form-register) .tab-content,
.brxe-tabs:has(.registration-form-fields) .tab-content,
.brxe-tabs-nested.registration-form .tab-content,
.brxe-tabs-nested:has(.registration-form-fields) .tab-content {
	padding-top: 0.25rem;
}

.brxe-tabs:has(.registration-form-fields) .tab-title .brxe-text-basic,
.brxe-tabs-nested.registration-form .tab-title .brxe-text-basic,
.brxe-tabs-nested:has(.registration-form-fields) .tab-title .brxe-text-basic {
	color: inherit !important;
}

/* Nestable tabs: div.brxe-block.tab-menu / div.brxe-div.tab-title */
.brxe-tabs-nested.registration-form .tab-menu.brxe-block,
.brxe-tabs-nested:has(.registration-form-fields) .tab-menu.brxe-block {
	display: flex !important;
	flex-direction: row;
	flex-wrap: wrap;
	align-items: stretch;
	gap: 0.5rem;
}

.brxe-tabs-nested.registration-form .tab-title.brxe-div,
.brxe-tabs-nested:has(.registration-form-fields) .tab-title.brxe-div {
	display: flex !important;
	align-items: center;
	justify-content: center;
	box-sizing: border-box;
}

.brxe-tabs:has(.woocommerce-form-login) .woocommerce-form-login,
.brxe-tabs-nested:has(.woocommerce-form-login) .woocommerce-form-login,
.brxe-tabs:has(.woocommerce-form-login) .woocommerce-form-register,
.brxe-tabs-nested:has(.woocommerce-form-login) .woocommerce-form-register,
.brxe-tabs:has(.woocommerce-form-register) .woocommerce-form-login,
.brxe-tabs-nested:has(.woocommerce-form-register) .woocommerce-form-login,
.brxe-tabs:has(.woocommerce-form-register) .woocommerce-form-register,
.brxe-tabs-nested:has(.woocommerce-form-register) .woocommerce-form-register {
	background: var(--ig-auth-surface);
	border: 1px solid var(--ig-auth-border);
	border-radius: var(--ig-auth-radius);
	padding: 1.5rem;
	box-shadow: 0 12px 40px rgba(0, 0, 0, 0.45);
}

.brxe-tabs:has(.woocommerce-form-login) .woocommerce-form-login label,
.brxe-tabs-nested:has(.woocommerce-form-login) .woocommerce-form-login label,
.brxe-tabs:has(.woocommerce-form-login) .woocommerce-form-register label,
.brxe-tabs-nested:has(.woocommerce-form-login) .woocommerce-form-register label,
.brxe-tabs:has(.woocommerce-form-register) .woocommerce-form-login label,
.brxe-tabs-nested:has(.woocommerce-form-register) .woocommerce-form-login label,
.brxe-tabs:has(.woocommerce-form-register) .woocommerce-form-register label,
.brxe-tabs-nested:has(.woocommerce-form-register) .woocommerce-form-register label {
	color: var(--ig-auth-text);
}

.brxe-tabs:has(.woocommerce-form-login) .woocommerce-form-login input.input-text,
.brxe-tabs-nested:has(.woocommerce-form-login) .woocommerce-form-login input.input-text,
.brxe-tabs:has(.woocommerce-form-login) .woocommerce-form-register input.input-text,
.brxe-tabs-nested:has(.woocommerce-form-login) .woocommerce-form-register input.input-text,
.brxe-tabs:has(.woocommerce-form-register) .woocommerce-form-login input.input-text,
.brxe-tabs-nested:has(.woocommerce-form-register) .woocommerce-form-login input.input-text,
.brxe-tabs:has(.woocommerce-form-register) .woocommerce-form-register input.input-text,
.brxe-tabs-nested:has(.woocommerce-form-register) .woocommerce-form-register input.input-text {
	background: var(--ig-auth-input-bg) !important;
	border: 1px solid var(--ig-auth-border) !important;
	border-radius: var(--ig-auth-radius-sm) !important;
	color: var(--ig-auth-text) !important;
	padding: 0.65rem 0.85rem !important;
}

.brxe-tabs:has(.woocommerce-form-login) .woocommerce-form-login input.input-text:focus,
.brxe-tabs-nested:has(.woocommerce-form-login) .woocommerce-form-login input.input-text:focus,
.brxe-tabs:has(.woocommerce-form-login) .woocommerce-form-register input.input-text:focus,
.brxe-tabs-nested:has(.woocommerce-form-login) .woocommerce-form-register input.input-text:focus,
.brxe-tabs:has(.woocommerce-form-register) .woocommerce-form-login input.input-text:focus,
.brxe-tabs-nested:has(.woocommerce-form-register) .woocommerce-form-login input.input-text:focus,
.brxe-tabs:has(.woocommerce-form-register) .woocommerce-form-register input.input-text:focus,
.brxe-tabs-nested:has(.woocommerce-form-register) .woocommerce-form-register input.input-text:focus {
	border-color: var(--ig-auth-border-strong) !important;
	box-shadow: 0 0 0 3px rgba(249, 166, 2, 0.15);
	outline: none;
}

.brxe-tabs:has(.woocommerce-form-login) .woocommerce-button.button,
.brxe-tabs-nested:has(.woocommerce-form-login) .woocommerce-button.button,
.brxe-tabs:has(.woocommerce-form-login) button[type="submit"],
.brxe-tabs-nested:has(.woocommerce-form-login) button[type="submit"],
.brxe-tabs:has(.woocommerce-form-register) .woocommerce-button.button,
.brxe-tabs-nested:has(.woocommerce-form-register) .woocommerce-button.button,
.brxe-tabs:has(.woocommerce-form-register) button[type="submit"],
.brxe-tabs-nested:has(.woocommerce-form-register) button[type="submit"] {
	background: var(--ig-auth-gold) !important;
	color: #0a0a0a !important;
	border: none !important;
	border-radius: var(--ig-auth-radius-sm) !important;
	font-weight: 600 !important;
	padding: 0.7rem 1.35rem !important;
	box-shadow: 0 2px 12px rgba(249, 166, 2, 0.25);
}

.brxe-tabs:has(.woocommerce-form-login) .woocommerce-button.button:hover,
.brxe-tabs-nested:has(.woocommerce-form-login) .woocommerce-button.button:hover,
.brxe-tabs:has(.woocommerce-form-login) button[type="submit"]:hover,
.brxe-tabs-nested:has(.woocommerce-form-login) button[type="submit"]:hover,
.brxe-tabs:has(.woocommerce-form-register) .woocommerce-button.button:hover,
.brxe-tabs-nested:has(.woocommerce-form-register) .woocommerce-button.button:hover,
.brxe-tabs:has(.woocommerce-form-register) button[type="submit"]:hover,
.brxe-tabs-nested:has(.woocommerce-form-register) button[type="submit"]:hover {
	background: var(--ig-auth-gold-hover) !important;
}

.brxe-tabs:has(.woocommerce-form-login) .lost_password a,
.brxe-tabs-nested:has(.woocommerce-form-login) .lost_password a,
.brxe-tabs:has(.woocommerce-form-register) .lost_password a,
.brxe-tabs-nested:has(.woocommerce-form-register) .lost_password a {
	color: var(--ig-auth-gold);
}
