/* stylelint-disable selector-id-pattern */

/* Clear to evenly position the next list items after the separator */
#toplevel_page_spectra-blocks .wp-submenu li {
	clear: both;
}

/* Top separator: after the first item (Dashboard) */
#toplevel_page_spectra-blocks .wp-submenu li.wp-first-item::after {
	content: "";
	border-bottom: 1px solid rgb(255 255 255 / 0.2);
	display: block;
	float: left;
	margin: 8px 0;
	width: 100%;
}

/* Bottom separator: above Settings (and Get Spectra Pro when present) */
#toplevel_page_spectra-blocks
.wp-submenu
li:has(+ li > a[href*="path=settings"])::after {
	content: "";
	border-bottom: 1px solid rgb(255 255 255 / 0.2);
	display: block;
	float: left;
	margin: 8px 0;
	width: 100%;
}

.wp-submenu li:has(> a[href*="spectra-blocks&path=free-vs-pro"]) {
	background-color: #00a32a !important;
}

.wp-submenu li a[href*="spectra-blocks&path=free-vs-pro"] {
	color: #fff !important;
	font-weight: 500;
}

.wp-submenu li:has(> a[href*="spectra-blocks&path=free-vs-pro"]):hover {
	background-color: #008000 !important;
}

/* Negative margins for top separator when submenu is collapsed */
#toplevel_page_spectra-blocks.wp-not-current-submenu
.wp-submenu
li.wp-first-item::after {
	margin: 8px -3px;
}

/* Negative margins for bottom separator when submenu is collapsed */
#toplevel_page_spectra-blocks.wp-not-current-submenu
.wp-submenu
li:has(+ li > a[href*="path=settings"])::after {
	margin: 8px -3px;
}

/*
 * Plugins page (wp-admin/plugins.php) — "Get Spectra Pro" action link styling.
 * The link is added by Admin_Menu::add_action_links() when spectra-blocks-pro
 * is not active. Mirrors the rule UAGB ships in
 * admin/assets/admin-notice-spectra-pro-upgrade-pro.css — without this, the
 * link looked like a regular black link when only spectra-blocks (V3) was
 * active, but rendered correctly when UAGB (V2) was active because UAGB's
 * stylesheet provides the same global rule. Adding it here makes the link
 * self-styled regardless of whether UAGB is installed.
 */
a.spectra-plugins-go-pro {
	color: #6104ff;
	text-shadow: 1px 1px 1px #eee;
	font-weight: 700;
}

a.spectra-plugins-go-pro:hover {
	color: #5300e0;
}
