/**
 * WP PowerSuite Admin Styles
 *
 * Styles for the module management interface.
 *
 * @package WP_PowerSuite\Admin\Assets
 * @since 1.0.0
 */

/* Accent aliases mirror WordPress profile admin color variables. */
.wpps-admin-wrap,
.wp-powersuite-admin,
.wp-powersuite-modal,
.wp-powersuite-settings,
.wp-powersuite-module-settings,
.wpps-command-palette,
.wpps-bf-wrap {
	--wpps-accent: var(--wp-admin-theme-color, #2271b1);
	--wpps-accent-hover: var(--wp-admin-theme-color-darker-10, #135e96);
	--wpps-font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
}

/* Module admin pages — fill the WP admin content column (fluid on wide viewports / zoom out). */
.wrap[class*="wpps-"] {
	max-width: 100%;
	box-sizing: border-box;
}

/* Module settings callouts — accent tints follow the active admin color scheme. */
.wp-powersuite-module-settings .wp-powersuite-info-box {
	padding: 12px;
	margin: 0 0 16px;
}

.wp-powersuite-module-settings .wp-powersuite-info-box p {
	margin: 0;
}

.wp-powersuite-module-settings .wp-powersuite-info-box--warning {
	background: #fcf0f1;
	border-left: 4px solid #d63638;
}

.wp-powersuite-module-settings .wp-powersuite-info-box--accent {
	background: var(--wpps-accent-surface, color-mix(in srgb, var(--wp-admin-theme-color, #2271b1) 12%, #fff));
	border-left: 4px solid var(--wp-admin-theme-color, #2271b1);
	margin: 20px 0;
}

.wp-powersuite-module-settings .wp-powersuite-field-error {
	color: #d63638;
	margin-top: 8px;
}

/* Admin buttons: dashicons match button label color (overrides WP color-scheme .button .dashicons). */
[class*="branch-"].wp-core-ui .wp-powersuite-admin .button .dashicons,
[class*="branch-"].wp-core-ui .wp-powersuite-admin .button .dashicons::before,
[class*="branch-"].wp-core-ui .wp-powersuite-modal .button .dashicons,
[class*="branch-"].wp-core-ui .wp-powersuite-modal .button .dashicons::before,
[class*="branch-"].wp-core-ui .wp-powersuite-settings .button .dashicons,
[class*="branch-"].wp-core-ui .wp-powersuite-settings .button .dashicons::before,
.wp-powersuite-admin .button .dashicons,
.wp-powersuite-admin .button .dashicons::before,
.wp-powersuite-modal .button .dashicons,
.wp-powersuite-modal .button .dashicons::before,
.wp-powersuite-settings .button .dashicons,
.wp-powersuite-settings .button .dashicons::before {
	color: inherit;
	line-height: 1;
}

/* --------------------------------------------------------------------------
   Shared page hero (Modules, Settings, License, module admin screens)
   -------------------------------------------------------------------------- */
.wpps-page-hero {
	--wpps-accent: var(--wp-admin-theme-color, #2271b1);
	--wpps-accent-hover: var(--wp-admin-theme-color-darker-10, #135e96);
}
.wpps-page-hero.wpps-settings-hero {
	margin: 0 0 24px;
	padding: 22px 26px;
	border-radius: 0;
	background: linear-gradient(
		128deg,
		var(--wpps-accent, #2271b1) 0%,
		var(--wpps-accent-hover, #135e96) 52%,
		#1d2327 100%
	);
	box-shadow: 0 1px 2px rgba(0, 0, 0, .06), 0 8px 24px rgba(0, 0, 0, .1);
}
.wpps-page-hero.wpps-settings-hero h1 {
	margin: 0;
	padding: 0;
	color: #fff;
	font-size: 26px;
	line-height: 1.2;
	font-family: var(--wpps-font-sans);
	font-weight: 600;
}
.wpps-page-hero.wpps-settings-hero p.wpps-page-hero__tagline {
	max-width: 36em;
	margin: 6px 0 0;
	font-size: 14px;
	line-height: 1.45;
	color: rgba(255, 255, 255, .88);
}
.wpps-page-hero__layout {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 20px 28px;
	width: 100%;
}
.wpps-page-hero__brand {
	display: flex;
	align-items: center;
	gap: 16px;
	min-width: 0;
	flex: 1 1 280px;
}
.wpps-page-hero__logo-wrap,
.wpps-page-hero__icon-wrap {
	display: flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
	width: 56px;
	height: 56px;
	border-radius: 0;
	background: rgba(255, 255, 255, .14);
	border: 1px solid rgba(255, 255, 255, .22);
	box-shadow: inset 0 1px 0 rgba(255, 255, 255, .12);
}
.wpps-page-hero__icon-wrap .dashicons {
	font-size: 28px;
	width: 28px;
	height: 28px;
	color: #fff;
}
.wpps-page-hero__copy {
	flex: 1;
	min-width: 0;
}
.wpps-page-hero__eyebrow {
	display: block;
	margin: 0 0 4px;
	font-size: 11px;
	font-weight: 600;
	letter-spacing: .06em;
	text-transform: uppercase;
	color: rgba(255, 255, 255, .72);
}
.wpps-page-hero__title-row {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 10px;
}
.wpps-page-hero__status {
	display: inline-flex;
	align-items: center;
	padding: 3px 9px;
	font-size: 10px;
	font-weight: 600;
	line-height: 1.2;
	letter-spacing: .04em;
	text-transform: uppercase;
	color: #fff;
	border-radius: 0;
	background: rgba(255, 255, 255, .18);
	border: 1px solid rgba(255, 255, 255, .32);
	box-shadow: none;
}
.wpps-page-hero__status--inactive {
	color: rgba(255, 255, 255, .92);
	background: rgba(0, 0, 0, .18);
	border-color: rgba(255, 255, 255, .22);
}
.wpps-page-hero__aside {
	display: flex;
	flex-direction: column;
	align-items: flex-end;
	gap: 12px;
	flex: 0 1 auto;
	min-width: 0;
}
.wpps-page-hero__actions {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: flex-end;
	gap: 8px;
	margin: 0;
	padding: 0;
}
.wpps-page-hero__action {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	min-height: 32px;
	padding: 6px 14px;
	font-size: 13px;
	font-weight: 500;
	line-height: 1.4;
	text-decoration: none;
	color: #fff;
	border-radius: 0;
	border: 1px solid rgba(255, 255, 255, .28);
	background: rgba(255, 255, 255, .1);
	box-sizing: border-box;
	transition: background .15s ease, border-color .15s ease, color .15s ease;
}
.wpps-page-hero__action:hover,
.wpps-page-hero__action:focus {
	color: #fff;
	background: rgba(255, 255, 255, .2);
	border-color: rgba(255, 255, 255, .45);
	box-shadow: none;
	outline: none;
}
.wpps-page-hero__action .dashicons {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
	font-size: 16px;
	width: 16px;
	height: 16px;
	line-height: 1;
}
.wpps-page-hero__stats {
	display: flex;
	flex-wrap: nowrap;
	border-radius: 0;
	overflow: hidden;
	border: 1px solid rgba(255, 255, 255, .2);
	background: rgba(0, 0, 0, .14);
}
.wpps-page-hero__stat {
	display: flex;
	flex-direction: column;
	justify-content: center;
	min-width: 88px;
	padding: 10px 16px;
	text-align: center;
	border-right: 1px solid rgba(255, 255, 255, .12);
}
.wpps-page-hero__stat:last-child {
	border-right: none;
}
.wpps-page-hero__stat strong {
	color: #fff;
	font-size: 22px;
	line-height: 1;
	font-weight: 700;
	font-variant-numeric: tabular-nums;
}
.wpps-page-hero__stat span {
	margin-top: 4px;
	color: rgba(255, 255, 255, .72);
	font-size: 10px;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: .05em;
}
.wpps-page-hero__meta {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: flex-end;
	gap: 8px;
}
.wpps-page-hero__meta .button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	margin: 0;
	border-radius: 0;
	min-height: 32px;
	padding: 0 12px;
	line-height: 1.4;
	box-sizing: border-box;
	vertical-align: middle;
}
.wpps-page-hero__meta .button-primary {
	background: rgba(255, 255, 255, .95);
	border-color: rgba(255, 255, 255, .95);
	color: #1d2327;
}
.wpps-page-hero__meta .button-primary:hover,
.wpps-page-hero__meta .button-primary:focus {
	background: #fff;
	border-color: #fff;
	color: #1d2327;
}
.wpps-page-hero__meta .button-secondary,
.wpps-page-hero__meta .button:not(.button-primary) {
	background: rgba(255, 255, 255, .1);
	border-color: rgba(255, 255, 255, .28);
	color: #fff;
}
.wpps-page-hero__meta .button-secondary:hover,
.wpps-page-hero__meta .button:not(.button-primary):hover {
	background: rgba(255, 255, 255, .2);
	border-color: rgba(255, 255, 255, .45);
	color: #fff;
}

@media (max-width: 960px) {
	.wpps-page-hero__layout {
		flex-direction: column;
		align-items: stretch;
	}
	.wpps-page-hero__aside {
		align-items: stretch;
		width: 100%;
	}
	.wpps-page-hero__actions {
		justify-content: flex-start;
	}
	.wpps-page-hero__stats {
		width: 100%;
	}
	.wpps-page-hero__stat {
		flex: 1;
		min-width: 0;
	}
}
@media (max-width: 782px) {
	.wpps-page-hero.wpps-settings-hero {
		box-sizing: border-box;
		width: 100%;
		margin: 0 0 16px;
		padding: 16px;
	}
	.wpps-page-hero.wpps-settings-hero h1 {
		font-size: 20px;
	}
	.wpps-page-hero.wpps-settings-hero p.wpps-page-hero__tagline {
		font-size: 13px;
	}
	.wpps-page-hero__brand {
		flex: 1 1 100%;
		gap: 12px;
	}
	.wpps-page-hero__logo-wrap,
	.wpps-page-hero__icon-wrap {
		width: 48px;
		height: 48px;
	}
	.wpps-page-hero__logo {
		width: 32px;
		height: 32px;
	}
	.wpps-page-hero__actions {
		width: 100%;
	}
	.wpps-page-hero__action {
		flex: 1 1 auto;
		justify-content: center;
		padding: 8px 10px;
		font-size: 12px;
	}
	.wpps-page-hero__stats {
		flex-wrap: wrap;
	}
	.wpps-page-hero__stat {
		flex: 1 1 30%;
		min-width: 72px;
		padding: 8px 10px;
	}
	.wpps-page-hero__stat strong {
		font-size: 18px;
	}
}

/* Branded buttons – WP PowerSuite (WordPress admin blue) */
.wp-powersuite-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	padding: 7px 16px;
	font-size: 13px;
	font-weight: 500;
	line-height: 1.4;
	text-decoration: none;
	border-radius: 4px;
	border: 1px solid transparent;
	transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
	box-shadow: none;
	cursor: pointer;
}

.wp-powersuite-btn--secondary {
	background: #f6f7f7;
	border-color: #c3c4c7;
	color: #2c3338;
}

.wp-powersuite-btn--secondary:hover {
	background: #f0f0f1;
	border-color: #8c8f94;
	color: #1d2327;
}

.wp-powersuite-btn--primary {
	background: var(--wp-admin-theme-color, #2271b1);
	border-color: var(--wp-admin-theme-color, #2271b1);
	color: #fff;
}

.wp-powersuite-btn--primary:hover {
	background: var(--wp-admin-theme-color-darker-10, #135e96);
	border-color: var(--wp-admin-theme-color-darker-10, #135e96);
	color: #fff;
}

.wp-powersuite-page-header__license {
	background: #8dd3d3;
	border: 1px solid #8dd3d3;
	color: #000000;
}

.wp-powersuite-page-header__license:hover {
	background: #6fbaba;
	border-color: #6fbaba;
	color: #000000;
}

.wp-powersuite-page-header__actions .wp-powersuite-btn .dashicons {
	font-size: 16px;
	width: 16px;
	height: 16px;
	flex-shrink: 0;
}

.wpps-page-hero__logo {
	display: block;
	width: 40px;
	height: 40px;
	object-fit: contain;
	filter: brightness(0) invert(1);
	opacity: .95;
}

/* Settings Page – WordPress-style cards and buttons */
.wp-powersuite-settings {
	margin-top: 1em;
	max-width: none;
	width: 100%;
	box-sizing: border-box;
}

.wp-powersuite-settings__card {
	margin-bottom: 20px;
	padding: 20px 24px;
	width: 100%;
	box-sizing: border-box;
}

.wp-powersuite-settings__card-title {
	margin: 0 0 0.5em 0;
	font-size: 1.1em;
	font-weight: 600;
}

.wp-powersuite-settings__card .description {
	margin: 0 0 1em 0;
	color: #646970;
}

.wp-powersuite-settings__card p:last-child {
	margin-bottom: 0;
}

.wp-powersuite-settings__card--danger {
	border-left: 4px solid #d63638;
}

.wp-powersuite-button-danger {
	color: #b32d2e;
	border-color: #b32d2e;
}

.wp-powersuite-button-danger:hover {
	background: #b32d2e;
	color: #fff;
	border-color: #b32d2e;
}

.wp-powersuite-button-danger.is-busy {
	opacity: 0.7;
	pointer-events: none;
}

/* Wipe modal – matches main plugin modal pattern */
.wp-powersuite-modal__content--sm {
	max-width: 520px;
	width: 100%;
	min-width: 0;
}

.wp-powersuite-wipe-modal__confirm {
	margin: 1.25em 0 0 0;
	padding: 12px 16px;
	background: #fcf0f1;
	border-left: 4px solid #d63638;
	border-radius: 0 4px 4px 0;
}

.wp-powersuite-wipe-modal__confirm-label {
	display: flex;
	align-items: center;
	gap: 8px;
	font-weight: 500;
	cursor: pointer;
}

.wp-powersuite-wipe-modal__confirm input[type="checkbox"] {
	margin: 0;
}

.wp-powersuite-wipe-modal__submit {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
}

.wp-powersuite-wipe-modal__submit .dashicons {
	font-size: 18px;
	width: 18px;
	height: 18px;
	flex-shrink: 0;
	line-height: 1;
}

.wp-powersuite-wipe-modal__submit:not(:disabled) {
	background: #d63638;
	border-color: #d63638;
	color: #fff;
}

.wp-powersuite-wipe-modal__submit:not(:disabled):hover {
	background: #b32d2e;
	border-color: #b32d2e;
	color: #fff;
}

.wp-powersuite-wipe-modal__submit:disabled {
	opacity: 0.5;
	cursor: not-allowed;
}

/* Admin Container */
.wp-powersuite-admin {
	margin-top: 16px;
}

/* Toolbar */
.wp-powersuite-admin__toolbar {
	position: sticky;
	top: 32px; /* WordPress admin bar height */
	z-index: 99;
	display: flex;
	flex-wrap: wrap;
	gap: 15px;
	align-items: center;
	margin-bottom: 20px;
	padding: 15px;
	background: #fff;
	border: 1px solid #ccd0d4;
	box-shadow: 0 2px 2px rgba(0, 0, 0, 0.05);
}

/* Category Filter Buttons */
.wp-powersuite-admin__category-filters {
	position: sticky;
	top: 96px; /* WordPress admin bar + toolbar height */
	z-index: 98;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 8px;
	margin-bottom: 20px;
	padding: 15px;
	background: #fff;
	border: 1px solid #ccd0d4;
	box-shadow: 0 2px 2px rgba(0, 0, 0, 0.05);
}

.wp-powersuite-admin__category-buttons {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px;
	flex: 1;
}

.wp-powersuite-admin__category-filters > .wp-powersuite-refresh-page {
	flex-shrink: 0;
	margin-left: auto;
}

.wp-powersuite-category-filter.button {
	margin: 0;
	border-radius: 0;
	min-height: 30px;
	line-height: 1.4;
	padding: 0 12px;
	vertical-align: middle;
}

.wp-powersuite-category-filter.button:hover {
	border-color: var(--wpps-accent, #2271b1);
}

.wp-powersuite-category-filter.button.is-active,
.wp-powersuite-category-filter.button.is-active:hover,
.wp-powersuite-category-filter.button.is-active:focus {
	background: var(--wpps-accent, #2271b1);
	border-color: var(--wpps-accent, #2271b1);
	color: #fff;
	box-shadow: none;
}

/* Refresh Page Button — match WordPress admin color scheme (same as .button-primary) */
.wp-powersuite-refresh-page.button.button-primary {
	margin-left: auto;
	display: none; /* Hidden by default, shown when changes are made */
	align-items: center;
	gap: 6px;
	border-radius: 0;
	min-height: 30px;
	line-height: 1.4;
	padding: 0 12px;
	height: auto;
	background: var(--wp-admin-theme-color, var(--wpps-accent, #2271b1));
	border-color: var(--wp-admin-theme-color, var(--wpps-accent, #2271b1));
	color: #fff;
	box-shadow: none;
}

.wp-powersuite-refresh-page.button.button-primary:hover,
.wp-powersuite-refresh-page.button.button-primary:focus {
	background: var(--wp-admin-theme-color-darker-10, var(--wpps-accent-hover, #135e96));
	border-color: var(--wp-admin-theme-color-darker-10, var(--wpps-accent-hover, #135e96));
	color: #fff;
}

.wp-powersuite-refresh-page .wp-powersuite-refresh-icon {
	display: block;
	width: 16px;
	height: 16px;
	flex-shrink: 0;
	color: inherit;
	fill: currentColor;
}


/* Layout Controls */
.wp-powersuite-admin__layout-controls {
	display: flex;
	align-items: center;
	gap: 10px;
}

.wp-powersuite-admin__layout-options {
	display: flex;
	align-items: center;
	gap: 15px;
}

.wp-powersuite-admin__layout-options select {
	min-width: 140px;
}

.wp-powersuite-admin__layout-options label {
	display: flex;
	align-items: center;
	gap: 5px;
	font-size: 13px;
	cursor: pointer;
}

.wp-powersuite-admin__layout-options select {
	border: 1px solid #8c8f94;
	border-radius: 3px;
	font-size: 13px;
}

.wp-powersuite-admin__search {
	flex: 1;
	min-width: 150px;
	max-width: 300px;
}

.wp-powersuite-search {
	width: 100%;
	padding: 6px 10px;
	border: 1px solid #8c8f94;
	border-radius: 3px;
	font-size: 14px;
}

.wp-powersuite-admin__filters {
	display: flex;
	gap: 10px;
	flex-wrap: wrap;
}

.wp-powersuite-filter,
.wp-powersuite-sort {
	padding: 4px 8px;
	border: 1px solid #8c8f94;
	border-radius: 3px;
	font-size: 13px;
	background: #fff;
}


.wp-powersuite-admin__view-toggle {
	display: flex;
	gap: 10px;
}

.wp-powersuite-view-toggle {
	padding: 5px 10px;
	border: 1px solid #8c8f94;
	background: #fff;
	cursor: pointer;
	border-radius: 3px;
	transition: all 0.2s;
}

.wp-powersuite-view-toggle:hover {
	background: #f0f0f1;
	border-color: var(--wpps-accent, #2271b1);
}

.wp-powersuite-view-toggle.is-active {
	background: var(--wpps-accent, #2271b1);
	border-color: var(--wpps-accent, #2271b1);
	color: #fff;
}

.wp-powersuite-view-toggle.is-active .dashicons {
	color: #fff;
}

.wp-powersuite-admin:not(.is-js-ready) #wp-powersuite-modules-list {
	display: none !important;
}

/* No-JS fallback table: hidden when JS is available; shown only if html.no-js remains */
.wp-powersuite-nojs-fallback {
	display: none;
	margin-top: 12px;
}

html.no-js .wp-powersuite-nojs-fallback {
	display: block;
}

.wp-powersuite-admin:not(.is-js-ready) .wp-powersuite-loading {
	display: flex;
}

.wp-powersuite-admin.is-js-ready .wp-powersuite-nojs-fallback {
	display: none;
}

.wp-powersuite-nojs-table {
	margin-top: 8px;
}

/* Description mode (single cycling icon next to grid/list) */
.wp-powersuite-admin__description-mode {
	display: flex;
	align-items: center;
	gap: 6px;
	margin-left: 8px;
}

.wp-powersuite-description-mode-label {
	font-size: 13px;
	color: #50575e;
}

.wp-powersuite-description-mode-btn {
	padding: 5px 8px;
	border: 1px solid #8c8f94;
	background: #fff;
	cursor: pointer;
	border-radius: 3px;
	transition: all 0.2s;
	color: #50575e;
}

.wp-powersuite-description-mode-btn:hover {
	background: #f0f0f1;
	border-color: var(--wpps-accent, #2271b1);
	color: var(--wpps-accent, #2271b1);
}

.wp-powersuite-description-mode-btn.is-active {
	background: var(--wpps-accent, #2271b1);
	border-color: var(--wpps-accent, #2271b1);
	color: #fff;
}

.wp-powersuite-description-mode-icon,
.wp-powersuite-description-mode-btn .dashicons {
	font-size: 18px;
	width: 18px;
	height: 18px;
}

/* Modules Container */
.wp-powersuite-admin__modules {
	margin-top: 20px;
}

/* When loading, center the spinner (shell is block; grid lives on #wp-powersuite-modules-list). */
.wp-powersuite-admin__modules > .wp-powersuite-loading {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	margin: 40px auto;
	max-width: 100%;
}

.wp-powersuite-admin.is-js-ready .wp-powersuite-admin__modules {
	display: block;
}

/* Grid View */
.wp-powersuite-modules-list.wp-powersuite-view-grid,
.wp-powersuite-modules-list:not(.wp-powersuite-view-list) {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 20px;
}

/* Grid columns will be set dynamically via JavaScript */

.wp-powersuite-module--grid {
	background: #fff;
	border: 1px solid #ccd0d4;
	border-radius: 4px;
	box-shadow: 0 1px 1px rgba(0, 0, 0, 0.04);
	display: flex;
	flex-direction: column;
	transition: box-shadow 0.2s;
	min-width: 0; /* Allow shrinking so truncate doesn't expand card */
	overflow: visible;
}

.wp-powersuite-module--grid:hover {
	box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.wp-powersuite-module__header {
	display: flex;
	justify-content: space-between;
	align-items: flex-start;
	padding: 15px;
	border-bottom: 1px solid #f0f0f1;
	overflow: visible;
}

.wp-powersuite-module__title {
	margin: 0;
	font-size: 16px;
	font-weight: 600;
	color: #1d2327;
	flex: 1;
}

.wpps-pro-badge {
	display: inline-block;
	vertical-align: middle;
	font-size: 10px;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	padding: 2px 6px;
	margin-left: 6px;
	border-radius: 3px;
	background: linear-gradient(
		135deg,
		var(--wpps-accent, var(--wp-admin-theme-color, #2271b1)) 0%,
		var(--wpps-accent-hover, var(--wp-admin-theme-color-darker-10, #135e96)) 100%
	);
	color: #fff;
	box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

.wpps-pro-badge--modal {
	font-size: 14px;
	padding: 6px 14px;
	margin-left: 8px;
	border-radius: 4px;
}

.wpps-pro-badge--inactive {
	background: #f0f0f1;
	color: #646970;
	box-shadow: none;
	text-transform: none;
	font-weight: 500;
	font-size: 12px;
}

.wpps-freemium-badge {
	display: inline-block;
	vertical-align: middle;
	font-size: 10px;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	padding: 2px 6px;
	margin-left: 6px;
	border-radius: 3px;
	background: var(--wpps-accent-surface, color-mix(in srgb, var(--wp-admin-theme-color, #2271b1) 12%, #fff));
	color: var(--wp-admin-theme-color-darker-10, #135e96);
	border: 1px solid var(--wpps-accent-border-soft, color-mix(in srgb, var(--wp-admin-theme-color, #2271b1) 35%, #c3c4c7));
	box-shadow: none;
}

.wpps-freemium-badge--modal {
	font-size: 14px;
	padding: 6px 14px;
	margin-left: 8px;
	border-radius: 4px;
}

/* Grid column control: hidden in list view, visible in grid view (see .wp-powersuite-admin--view-* on container) */
.wp-powersuite-admin--view-list #wp-powersuite-grid-columns {
	display: none !important;
}

.wp-powersuite-admin--view-grid #wp-powersuite-grid-columns {
	display: inline-block;
}

.wp-powersuite-favorite {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	background: none;
	border: none;
	cursor: pointer;
	padding: 4px;
	margin: 0;
	color: #8c8f94;
	transition: color 0.2s;
	line-height: 1;
}

/* Grid: favorite icon only visible on hover, always visible when favorited */
.wp-powersuite-module--grid .wp-powersuite-favorite {
	opacity: 0;
	transition: opacity 0.2s, color 0.2s;
}

.wp-powersuite-module--grid:hover .wp-powersuite-favorite,
.wp-powersuite-module--grid .wp-powersuite-favorite.is-active {
	opacity: 1;
}

.wp-powersuite-favorite:hover {
	color: #f0b849;
}

.wp-powersuite-favorite.is-active {
	color: #f0b849;
}

.wp-powersuite-favorite .dashicons {
	font-size: 18px;
	width: 18px;
	height: 18px;
}

/* Description info icon (when description hidden/truncate) - always visible, hover shows 300px panel above */
.wp-powersuite-description-info-wrap {
	position: relative;
	display: inline-flex;
	align-items: center;
	justify-content: center;
}

.wp-powersuite-description-info {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	cursor: help;
	padding: 4px;
	margin: 0;
	border: none;
	border-radius: 50%;
	background: transparent;
	color: #646970;
	transition: background 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
}

.wp-powersuite-description-info-wrap:hover .wp-powersuite-description-info,
.wp-powersuite-description-info:hover,
.wp-powersuite-description-info:focus-visible {
	background: var(--wpps-accent-surface, color-mix(in srgb, var(--wp-admin-theme-color, #2271b1) 12%, #fff));
	color: var(--wp-admin-theme-color, #2271b1);
	outline: none;
}

.wp-powersuite-description-info .dashicons {
	font-size: 15px;
	width: 18px;
	height: 13px;
	color: inherit;
}

.wp-powersuite-description-info .dashicons::before {
	color: inherit;
}

/* Description panel — WP admin popover (visible border + shadow, no clip) */
.wp-powersuite-module--grid .wp-powersuite-module__header-actions {
	overflow: visible;
}

.wp-powersuite-description-hover-panel {
	position: absolute;
	bottom: 100%;
	right: 0;
	margin-bottom: 8px;
	width: 300px;
	max-width: min(300px, calc(100vw - 24px));
	padding: 12px 14px;
	overflow: visible;
	background: #fff;
	border: 1px solid #8c8f94;
	border-radius: 4px;
	box-shadow:
		0 4px 16px rgba(0, 0, 0, 0.12),
		0 1px 3px rgba(0, 0, 0, 0.08);
	z-index: 200;
	opacity: 0;
	visibility: hidden;
	transition: opacity 0.15s, visibility 0.15s;
	pointer-events: none;
}

/* Small arrow pointing down to the info icon (panel stays above, not over icon) */
.wp-powersuite-description-hover-panel::after {
	content: '';
	position: absolute;
	top: 100%;
	right: 10px;
	width: 0;
	height: 0;
	border-left: 6px solid transparent;
	border-right: 6px solid transparent;
	border-top: 6px solid #fff;
	filter: drop-shadow(0 1px 0 #8c8f94);
}

.wp-powersuite-description-info-wrap:hover,
.wp-powersuite-description-info-wrap:focus-within {
	z-index: 201;
}

.wp-powersuite-description-info-wrap:hover .wp-powersuite-description-hover-panel,
.wp-powersuite-description-info-wrap:focus-within .wp-powersuite-description-hover-panel {
	opacity: 1;
	visibility: visible;
}

.wp-powersuite-description-hover-panel p {
	margin: 0;
	font-size: 13px;
	line-height: 1.5;
	color: #1d2327;
}

.wp-powersuite-module__body {
	padding: 15px;
	flex: 1;
	min-width: 0; /* Prevent flex child from expanding card when description truncates */
}

.wp-powersuite-module__body--no-description {
	padding: 0;
}

.wp-powersuite-module__description {
	margin: 0 0 10px 0;
	color: #646970;
	font-size: 14px;
	line-height: 1.5;
}

.wp-powersuite-module__description--truncate {
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
	min-width: 0; /* Allow shrinking within flex parent so box width stays fixed */
}

.wp-powersuite-module__dependency {
	display: flex;
	align-items: center;
	gap: 6px;
	margin: 8px 0 0 0;
	padding: 8px 10px;
	background: #fff8e5;
	border-left: 3px solid #dba617;
	border-radius: 0 3px 3px 0;
	font-size: 12px;
	color: #3c434a;
}

.wp-powersuite-module__dependency .dashicons {
	color: #b45309;
	font-size: 16px;
	width: 16px;
	height: 16px;
}

.wp-powersuite-module__dependency-inline {
	display: inline-block;
	margin-left: 6px;
	padding: 2px 6px;
	background: #fff8e5;
	border-radius: 3px;
	font-size: 12px;
	color: #3c434a;
}

.wp-powersuite-module__dependency-inline .dashicons {
	color: #b45309;
	font-size: 14px;
	width: 14px;
	height: 14px;
	vertical-align: middle;
}

.wp-powersuite-module__meta {
	display: flex;
	gap: 10px;
	align-items: center;
	font-size: 12px;
	color: #8c8f94;
}

.wp-powersuite-module__category {
	padding: 2px 8px;
	background: #f0f0f1;
	border-radius: 3px;
}

.wp-powersuite-module__footer {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 15px;
	border-top: 1px solid #f0f0f1;
	background: #f9f9f9;
	overflow: visible;
}

.wp-powersuite-toggle-group {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	position: relative;
	overflow: visible;
}

/* Conflict warning — red icon + hover tooltip beside Enable/Disable */
.wp-powersuite-conflict-wrap {
	position: relative;
	display: inline-flex;
	align-items: center;
	flex-shrink: 0;
}

.wp-powersuite-conflict-trigger {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	margin: 0;
	padding: 0;
	border: none;
	background: transparent;
	cursor: help;
	color: #d63638;
	line-height: 1;
}

.wp-powersuite-conflict-trigger .dashicons {
	font-size: 20px;
	width: 20px;
	height: 20px;
}

.wp-powersuite-conflict-trigger:hover,
.wp-powersuite-conflict-trigger:focus {
	color: #b32d2e;
	outline: none;
}

.wp-powersuite-conflict-hover-panel {
	position: absolute;
	bottom: 100%;
	left: 50%;
	transform: translateX(-50%);
	margin-bottom: 8px;
	width: max-content;
	max-width: min(280px, calc(100vw - 24px));
	padding: 10px 12px;
	background: #fcf0f1;
	border: 1px solid #d63638;
	border-radius: 4px;
	box-shadow:
		0 4px 16px rgba(214, 54, 56, 0.15),
		0 1px 3px rgba(0, 0, 0, 0.08);
	z-index: 200;
	opacity: 0;
	visibility: hidden;
	transition: opacity 0.15s, visibility 0.15s;
	pointer-events: none;
}

.wp-powersuite-conflict-hover-panel::after {
	content: '';
	position: absolute;
	top: 100%;
	left: 50%;
	transform: translateX(-50%);
	width: 0;
	height: 0;
	border-left: 6px solid transparent;
	border-right: 6px solid transparent;
	border-top: 6px solid #fcf0f1;
	filter: drop-shadow(0 1px 0 #d63638);
}

.wp-powersuite-conflict-hover-panel p {
	margin: 0;
	font-size: 12px;
	line-height: 1.45;
	color: #3c434a;
	font-weight: 600;
}

.wp-powersuite-conflict-wrap:hover,
.wp-powersuite-conflict-wrap:focus-within {
	z-index: 201;
}

.wp-powersuite-conflict-wrap:hover .wp-powersuite-conflict-hover-panel,
.wp-powersuite-conflict-wrap:focus-within .wp-powersuite-conflict-hover-panel {
	opacity: 1;
	visibility: visible;
}

.wp-powersuite-module__footer-right {
	display: flex;
	align-items: center;
	gap: 8px;
}

.wp-powersuite-module__status {
	font-size: 12px;
	font-weight: 600;
	padding: 4px 8px;
	border-radius: 3px;
}

.wp-powersuite-module__status.is-enabled {
	color: #00a32a;
	background: #e7f5e9;
}

.wp-powersuite-module__status.is-disabled {
	color: #8c8f94;
	background: #f0f0f1;
}

.wp-powersuite-toggle {
	margin: 0;
}

/* Premium module locked (license required) - lock icon outside button */
.wp-powersuite-toggle-wrapper--locked {
	display: inline-flex;
	align-items: center;
	gap: 8px;
}

.wp-powersuite-lock-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	color: #8c8f94;
	flex-shrink: 0;
}

.wp-powersuite-lock-icon .dashicons {
	font-size: 18px;
	width: 18px;
	height: 18px;
}

.wp-powersuite-toggle--locked {
	opacity: 0.7;
	cursor: not-allowed;
}

/* License required modal – matches main plugin modal design */
.wp-powersuite-license-modal .wp-powersuite-modal__title .dashicons {
	font-size: 22px;
	width: 22px;
	height: 22px;
	color: #8c8f94;
}

.wp-powersuite-license-modal__message {
	margin: 0;
	font-size: 14px;
	line-height: 1.6;
	color: #1d2327;
}

.wp-powersuite-license-modal__activate {
	text-decoration: none;
	display: inline-flex;
	align-items: center;
}

/* List View */
.wp-powersuite-modules-list.wp-powersuite-view-list {
	display: block;
}

.wp-powersuite-module--list .column-name {
	width: 25%;
}

.wp-powersuite-module--list .column-description {
	width: 25%;
	max-width: 300px;
	color: #646970;
	font-size: 13px;
	overflow: hidden;
}

.wp-powersuite-module--list .wp-powersuite-list-description {
	display: block;
}

.wp-powersuite-module--list .wp-powersuite-list-description.wp-powersuite-module__description--truncate {
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.wp-powersuite-module--list .column-category {
	width: 12%;
}

.wp-powersuite-module--list .column-version {
	width: 10%;
}

.wp-powersuite-module--list .column-actions {
	width: auto;
}

/* List: no gaps between icons */
.wp-powersuite-module--list .wp-powersuite-actions-wrapper {
	gap: 0;
}

/* List: favorite icon only on hover, always visible when favorited */
.wp-powersuite-module--list .wp-powersuite-favorite {
	margin: 0;
	opacity: 0;
	transition: opacity 0.2s;
}

.wp-powersuite-module--list:hover .wp-powersuite-favorite,
.wp-powersuite-module--list .wp-powersuite-favorite.is-active {
	opacity: 1;
}

/* List: description tooltip icon (when hide/truncate) - before favorite, always visible */
.wp-powersuite-module--list .wp-powersuite-description-info-wrap {
	display: inline-flex;
	align-items: center;
}

.wp-powersuite-module--list .wp-powersuite-description-hover-panel {
	z-index: 1000;
}

.wp-powersuite-module--list .wp-powersuite-actions-wrapper {
	overflow: visible;
}

/* Loading State */
.wp-powersuite-loading {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	padding: 60px 20px;
	width: 100%;
	text-align: center;
	position: relative;
}

.wp-powersuite-loading .spinner {
	float: none !important;
	margin: 0 auto 15px auto !important;
	display: block;
	width: 20px;
	height: 20px;
	position: relative;
	left: auto;
	right: auto;
}

.wp-powersuite-loading p {
	margin: 0;
	font-size: 14px;
	color: #646970;
	font-weight: 500;
	text-align: center;
	width: 100%;
}

/* Empty State */
.wp-powersuite-admin__empty {
	text-align: center;
	padding: 60px 20px;
	background: #fff;
	border: 1px solid #ccd0d4;
	border-radius: 4px;
}

.wp-powersuite-admin__empty p {
	margin: 0;
	color: #646970;
	font-size: 14px;
}

/* Responsive */
@media (max-width: 900px) {
	.wp-powersuite-modal__content {
		width: 90%;
		min-width: auto;
		max-width: 90%;
	}
}

@media (max-width: 782px) {
	.wp-powersuite-admin__toolbar,
	.wp-powersuite-admin__category-filters {
		position: static;
		top: auto;
	}

	.wp-powersuite-admin__toolbar {
		flex-direction: column;
		align-items: stretch;
	}

	.wp-powersuite-admin__search,
	.wp-powersuite-admin__filters,
	.wp-powersuite-admin__sort {
		width: 100%;
	}

	.wp-powersuite-admin__search {
		max-width: none;
	}

	.wp-powersuite-admin__filters {
		flex-direction: column;
	}

	.wp-powersuite-admin__filters .wp-powersuite-filter {
		width: 100%;
	}

	.wp-powersuite-admin__sort .wp-powersuite-sort {
		width: 100%;
	}

	/* Mobile: grid only, 1 column, truncated descriptions — hide desktop layout controls */
	.wp-powersuite-admin__layout-controls,
	.wp-powersuite-admin__view-toggle {
		display: none;
	}

	.wp-powersuite-modules-list.wp-powersuite-view-grid,
	.wp-powersuite-modules-list:not(.wp-powersuite-view-list) {
		grid-template-columns: 1fr !important;
	}

	.wp-powersuite-module__description {
		overflow: hidden;
		text-overflow: ellipsis;
		white-space: nowrap;
	}

	.wp-powersuite-module--list .column-name,
	.wp-powersuite-module--list .column-description,
	.wp-powersuite-module--list .column-category,
	.wp-powersuite-module--list .column-version,
	.wp-powersuite-module--list .column-actions {
		width: auto;
	}
}

/* Advanced Settings Icon */
.wp-powersuite-module__header-actions {
	display: flex;
	gap: 0;
	align-items: center;
}

.wp-powersuite-advanced-settings {
	background: none;
	border: none;
	padding: 4px;
	cursor: pointer;
	color: #50575e;
	transition: color 0.2s;
}

.wp-powersuite-advanced-settings:hover {
	color: var(--wpps-accent, #2271b1);
}

.wp-powersuite-advanced-settings .dashicons {
	font-size: 18px;
	width: 18px;
	height: 18px;
}

/* Modal Styles */
.wp-powersuite-modal {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	z-index: 100000;
	display: none; /* Changed from flex to none, will be set to flex when shown */
	align-items: center;
	justify-content: center;
	overflow-y: auto;
}

.wp-powersuite-modal[style*="flex"] {
	display: flex !important;
}

/* Overlay to disable background interaction */
.wp-powersuite-modal__overlay {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background: rgba(0, 0, 0, 0.7);
	z-index: 100000;
	cursor: pointer;
}

/* Prevent body scroll when modal is open */
body.wp-powersuite-modal-open {
	overflow: hidden;
	position: fixed;
	width: 100%;
}

.wp-powersuite-advanced-settings--disabled {
	opacity: 0.5;
	cursor: not-allowed !important;
	pointer-events: none;
}

.wp-powersuite-advanced-settings--disabled .dashicons {
	color: #8c8f94 !important;
}

/* Advanced Settings Icon (List View) */
.wp-powersuite-actions-wrapper {
	display: flex;
	align-items: center;
	gap: 8px;
}

.wp-powersuite-advanced-settings-icon {
	background: none;
	border: none;
	padding: 0;
	cursor: pointer;
	color: var(--wpps-accent, #2271b1);
	font-size: 18px;
	line-height: 1;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 24px;
	height: 24px;
	transition: color 0.2s;
}

.wp-powersuite-advanced-settings-icon:hover {
	color: var(--wpps-accent-hover, #135e96);
}

.wp-powersuite-advanced-settings-icon .dashicons {
	width: 18px;
	height: 18px;
	font-size: 18px;
}

.wp-powersuite-custom-page-link,
.wp-powersuite-custom-page-link-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 4px;
	border: none;
	background: transparent;
	color: var(--wpps-accent, #2271b1);
	cursor: pointer;
	text-decoration: none;
	border-radius: 3px;
	transition: all 0.2s;
}

.wp-powersuite-custom-page-link:hover,
.wp-powersuite-custom-page-link-icon:hover {
	background: #f0f0f1;
	color: var(--wpps-accent-hover, #135e96);
}

.wp-powersuite-custom-page-link .dashicons,
.wp-powersuite-custom-page-link-icon .dashicons {
	font-size: 18px;
	width: 18px;
	height: 18px;
}

.wp-powersuite-advanced-settings-icon--disabled {
	opacity: 0.5;
	cursor: not-allowed;
	color: #8c8f94;
}

.wp-powersuite-modal__content {
	position: relative;
	background: #fff;
	border-radius: 4px;
	box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
	max-width: 800px;
	width: 800px;
	min-width: 800px;
	max-height: 90vh;
	display: flex;
	flex-direction: column;
	z-index: 100001;
	margin: auto;
}

.wp-powersuite-modal__header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 20px;
	border-bottom: 1px solid #ddd;
}

.wp-powersuite-modal__title {
	margin: 0;
	font-size: 18px;
	display: flex;
	align-items: center;
	gap: 8px;
	flex: 1;
	min-width: 0;
}

.wp-powersuite-modal__title h3 {
	margin: 0;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
	flex-shrink: 0;
}

.wp-powersuite-modal__module-name {
	font-weight: normal;
	color: #666;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
	flex: 1;
	min-width: 0;
}

.wp-powersuite-modal__close {
	background: none;
	border: none;
	padding: 0;
	cursor: pointer;
	color: #666;
	font-size: 20px;
	line-height: 1;
}

.wp-powersuite-modal__close:hover {
	color: #000;
}

.wp-powersuite-modal__body {
	padding: 20px;
	overflow-y: auto;
	overflow-x: hidden;
	max-height: calc(100vh - 200px); /* Limit height to prevent viewport overflow */
	flex: 1;
	min-width: 0;
	box-sizing: border-box;
}

/* Turnstile / captcha module settings — compact modal layout */
.wp-powersuite-modal .wpps-settings-alert {
	padding: 10px 12px;
	border-radius: 6px;
	margin: 0 0 16px;
	font-size: 13px;
	line-height: 1.45;
	border: 1px solid #dcdcde;
}

.wp-powersuite-modal .wpps-settings-alert p {
	margin: 0;
}

.wp-powersuite-modal .wpps-settings-alert--warning {
	background: linear-gradient(135deg, #fcf9e8 0%, #fff 100%);
	border-color: #dba617;
	box-shadow: inset 3px 0 0 0 #dba617;
}

.wp-powersuite-modal .wpps-captcha-overlap-notice__list {
	margin: 8px 0 0;
	padding-left: 1.25em;
}

.wp-powersuite-modal .wpps-captcha-overlap-notice__list li {
	margin: 0.35em 0;
}

.wp-powersuite-modal .wpps-settings-alert--info {
	background: linear-gradient(135deg, #f0f6fc 0%, #fff 100%);
	border-color: #c5d9ed;
	box-shadow: inset 3px 0 0 0 var(--wp-admin-theme-color, #2271b1);
}

.wp-powersuite-modal .wpps-force-ssl-safety-link__url {
	display: block;
	width: 100%;
	max-width: 100%;
	box-sizing: border-box;
	margin: 0 0 10px;
}

.wp-powersuite-modal .wpps-force-ssl-safety-link__actions {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px;
}

.wp-powersuite-modal .wpps-force-ssl-safety-link__copy,
.wp-powersuite-modal .wpps-force-ssl-safety-link__regenerate {
	display: inline-flex;
	align-items: center;
	gap: 4px;
}

.wp-powersuite-modal .wpps-force-ssl-safety-link__copy .dashicons,
.wp-powersuite-modal .wpps-force-ssl-safety-link__regenerate .dashicons {
	font-size: 16px;
	width: 16px;
	height: 16px;
	line-height: 1;
}

.wp-powersuite-modal .wpps-force-ssl-safety-link__regenerate.is-busy {
	opacity: 0.7;
	pointer-events: none;
}

.wp-powersuite-modal .wpps-force-ssl-safety-link__feedback.is-success {
	color: #00a32a;
	font-weight: 500;
}

.wp-powersuite-modal .wpps-force-ssl-safety-link__feedback.is-error {
	color: #d63638;
	font-weight: 500;
}

.wp-powersuite-modal .wpps-module-settings-lead {
	margin-top: 0;
}

.wp-powersuite-modal .wpps-settings-option-spaced {
	display: block;
	margin-top: 15px;
}

.wp-powersuite-modal .wpps-settings-intro {
	margin-top: 0;
}

.wp-powersuite-modal .wpps-settings-panel__title {
	margin: 24px 0 12px;
	padding-bottom: 8px;
	font-size: 13px;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.04em;
	color: #646970;
	border-bottom: 1px solid #f0f0f1;
}

.wp-powersuite-modal .wpps-settings-panel__title:first-child {
	margin-top: 0;
}

/* Module advanced settings — accordion stack (Cloudflare Turnstile / Code Snippet pattern) */
.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-accordions {
	display: flex;
	flex-direction: column;
	gap: 12px;
	margin: 0;
}

.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-accordion {
	background: #fff;
	border: 1px solid #dcdcde;
	border-radius: 4px;
	box-shadow: 0 1px 1px rgba(0, 0, 0, 0.04);
	overflow: visible;
}

.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-accordion-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	width: 100%;
	padding: 14px 18px;
	margin: 0;
	background: transparent;
	border: none;
	border-radius: 4px;
	font-size: 14px;
	font-weight: 600;
	color: #1d2327;
	text-align: left;
	cursor: pointer;
	transition: background 0.15s ease;
	box-sizing: border-box;
	font-family: inherit;
	line-height: 1.35;
}

.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-accordion-header:hover {
	background: #f6f7f7;
}

.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-accordion-title {
	display: flex;
	align-items: center;
	gap: 6px;
}

.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-accordion-chevron {
	flex-shrink: 0;
	font-size: 18px;
	width: 18px;
	height: 18px;
	color: #787c82;
	transition: transform 0.2s ease;
}

.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-accordion.is-open .wpps-ts-accordion-chevron {
	transform: rotate(180deg);
}

.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-accordion:not(.is-open) .wpps-ts-accordion-body {
	display: none;
}

.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-accordion-body {
	padding: 0 18px 18px;
	border-top: 1px solid #f0f0f1;
	margin-top: -1px;
	padding-top: 16px;
	overflow: visible;
}

.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-accordion-body .form-table {
	margin: 0;
}

.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-accordion-body .form-table th {
	padding-left: 0;
	width: 200px;
}

.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-field + .wpps-ts-field {
	margin-top: 18px;
	padding-top: 18px;
	border-top: 1px solid #f0f0f1;
}

.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-field__label-row {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 6px;
	margin-bottom: 8px;
	font-weight: 600;
	font-size: 13px;
	color: #1d2327;
	line-height: 1.35;
}

.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-field__label-row label {
	font-weight: 600;
	margin: 0;
}

.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-field__control input[type="text"],
.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-field__control input[type="password"],
.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-field__control select,
.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-field__control textarea {
	width: 100%;
	max-width: 100%;
	box-sizing: border-box;
}

.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-field__control textarea.code {
	font-family: Consolas, Monaco, monospace;
	font-size: 12px;
	line-height: 1.45;
}

.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-inline-check {
	display: inline-flex;
	align-items: flex-start;
	gap: 8px;
	margin: 0;
	font-weight: normal;
	line-height: 1.35;
}

.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-inline-check input {
	margin-top: 3px;
	flex-shrink: 0;
}

.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-empty-form-plugins {
	grid-column: 1 / -1;
	margin: 4px 0 0;
	line-height: 1.45;
}

.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-integration--unavailable {
	opacity: 0.55;
	cursor: not-allowed;
}

.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-integration__badge {
	display: inline-block;
	margin-left: 6px;
	font-size: 11px;
	font-weight: 500;
	color: #787c82;
	vertical-align: baseline;
}

.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-custom-width-row input[type="number"] {
	max-width: 140px;
	margin-top: 6px;
}

.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-inline-keys {
	display: grid;
	grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
	gap: 16px;
	align-items: start;
	width: 100%;
}

.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-inline-keys__cell .wpps-ts-field__label-row {
	margin-bottom: 6px;
}

.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-inline-keys__cell input[type="text"],
.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-inline-keys__cell input[type="password"] {
	width: 100%;
	max-width: 100%;
	box-sizing: border-box;
}

.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-dashboard-link {
	margin: 10px 0 0;
}

@media screen and (max-width: 782px) {
	.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-inline-keys {
		grid-template-columns: 1fr;
	}
}

.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-controls-row--502525 {
	display: grid;
	grid-template-columns: minmax(0, 2fr) minmax(0, 1fr) minmax(0, 1fr);
	gap: 12px 16px;
	align-items: start;
	width: 100%;
}

.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-controls-row__cell .wpps-ts-field__label-row {
	margin-bottom: 6px;
}

.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-controls-row__cell .wpps-captcha-test-row {
	flex-direction: column;
	align-items: stretch;
	gap: 10px;
}

.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-controls-row__cell .wpps-captcha-test-connection {
	align-self: flex-start;
}

/* Turnstile Advanced row: equal columns; inputs/selects shrink inside grid (avoid clipped selects). */
.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-controls-row--adv-2col {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 12px 16px;
	align-items: start;
	width: 100%;
}

.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-controls-row__cell input[type="text"],
.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-controls-row__cell input[type="password"],
.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-controls-row__cell input[type="number"],
.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-controls-row__cell select {
	width: 100%;
	max-width: 100%;
	min-width: 0;
	box-sizing: border-box;
}

@media screen and (max-width: 782px) {
	.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-controls-row--502525 {
		grid-template-columns: 1fr;
	}

	.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-controls-row--adv-2col {
		grid-template-columns: 1fr;
	}
}

.wp-powersuite-modal .wpps-settings-panel--accordion-stack .wpps-ts-field__control .wpps-captcha-test-status.description {
	margin-top: 12px;
}

/* Modal field help — fixed-position panel (JS-placed) so it stays visible while modal body clips overflow. */
.wp-powersuite-modal .wpps-modal-tooltip {
	position: relative;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	vertical-align: middle;
	flex-shrink: 0;
	z-index: 1;
}

.wp-powersuite-modal .wpps-modal-tooltip:hover,
.wp-powersuite-modal .wpps-modal-tooltip:focus-within {
	z-index: 2;
}

.wp-powersuite-modal .wpps-modal-tooltip__trigger {
	display: inline-grid;
	place-items: center;
	width: 22px;
	height: 22px;
	padding: 0;
	margin: 0;
	border: none;
	border-radius: 50%;
	background: #f0f0f1;
	color: #646970;
	cursor: help;
	transition: background 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
}

.wp-powersuite-modal .wpps-modal-tooltip:hover .wpps-modal-tooltip__trigger,
.wp-powersuite-modal .wpps-modal-tooltip__trigger:hover,
.wp-powersuite-modal .wpps-modal-tooltip__trigger:focus {
	background: var(--wpps-accent-surface, color-mix(in srgb, var(--wp-admin-theme-color, #2271b1) 12%, #fff));
	color: var(--wp-admin-theme-color, #2271b1);
	outline: none;
	box-shadow: 0 0 0 1px var(--wp-admin-theme-color, #2271b1);
}

.wp-powersuite-modal .wpps-modal-tooltip__glyph {
	display: block;
	margin: 0;
	padding: 0;
	font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
	font-size: 11px;
	font-weight: 700;
	line-height: 1;
	letter-spacing: 0;
	text-align: center;
	transform: translateY(0.5px);
	color: inherit;
}

.wp-powersuite-modal .wpps-modal-tooltip__panel {
	--wpps-tip-x: 16px;
	position: fixed;
	/* JS sets left/top when open; (0,0) is only a fallback — see :not(.is-active) rule to avoid hide flashes */
	left: 0;
	top: 0;
	box-sizing: border-box;
	margin: 0;
	min-width: 220px;
	width: min(320px, calc(100vw - 20px));
	max-width: min(320px, calc(100vw - 20px));
	padding: 12px 14px;
	font-size: 13px;
	font-weight: 400;
	line-height: 1.5;
	color: #1d2327;
	text-align: left;
	background: #fff;
	border: 1px solid #c3c4c7;
	border-radius: 8px;
	box-shadow:
		0 4px 20px rgba(0, 0, 0, 0.12),
		0 2px 6px rgba(0, 0, 0, 0.06);
	opacity: 0;
	visibility: hidden;
	pointer-events: none;
	transition: opacity 0.12s ease, visibility 0.12s ease;
	z-index: 2147483647;
	transform: none;
}

/* When hiding, inline left/top are cleared before opacity finishes fading — without this the panel
   briefly paints at (0,0). Park off-screen and kill transitions for inactive tooltips. */
.wp-powersuite-modal .wpps-modal-tooltip:not(.is-active) .wpps-modal-tooltip__panel {
	left: -9999px !important;
	top: -9999px !important;
	transition: none;
	opacity: 0;
	visibility: hidden;
}

.wp-powersuite-modal .wpps-modal-tooltip.is-active .wpps-modal-tooltip__panel {
	opacity: 1;
	visibility: visible;
}

.wp-powersuite-modal .wpps-modal-tooltip.is-active:not(.wpps-modal-tooltip--panel-ready) .wpps-modal-tooltip__panel {
	opacity: 0;
	visibility: hidden;
	pointer-events: none;
}

.wp-powersuite-modal .wpps-modal-tooltip__panel::before {
	content: "";
	position: absolute;
	bottom: 100%;
	left: var(--wpps-tip-x);
	margin-left: -7px;
	border: 7px solid transparent;
	border-bottom-color: #c3c4c7;
}

.wp-powersuite-modal .wpps-modal-tooltip__panel::after {
	content: "";
	position: absolute;
	bottom: 100%;
	left: var(--wpps-tip-x);
	margin-left: -6px;
	margin-bottom: -1px;
	border: 6px solid transparent;
	border-bottom-color: #fff;
}

/* Panel above trigger: caret on bottom edge pointing down (default ::before/::after sit on top for panel-below). */
.wp-powersuite-modal .wpps-modal-tooltip__panel.wpps-modal-tooltip__panel--above::before {
	bottom: auto;
	top: 100%;
	left: var(--wpps-tip-x);
	margin-left: -7px;
	margin-top: -1px;
	border: 7px solid transparent;
	border-top-color: #c3c4c7;
	border-bottom-color: transparent;
}

.wp-powersuite-modal .wpps-modal-tooltip__panel.wpps-modal-tooltip__panel--above::after {
	bottom: auto;
	top: 100%;
	left: var(--wpps-tip-x);
	margin-left: -6px;
	margin-top: -2px;
	border: 6px solid transparent;
	border-top-color: #fff;
	border-bottom-color: transparent;
}

.wp-powersuite-modal .wpps-settings-subtle-link {
	margin: 8px 0 0;
	font-size: 12px;
	line-height: 1.4;
}

.wp-powersuite-modal .wpps-settings-subtle-link a {
	text-decoration: none;
}

.wp-powersuite-modal .wpps-settings-subtle-link a:focus {
	outline: 1px solid var(--wp-admin-theme-color, #2271b1);
	outline-offset: 1px;
}

.wp-powersuite-modal .wpps-captcha-test-row {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-end;
	gap: 12px;
	margin-bottom: 4px;
}

.wp-powersuite-modal .wpps-captcha-test-row .wpps-captcha-test-widget {
	margin-bottom: 0 !important;
	box-sizing: border-box;
	max-width: min(100%, 320px);
	min-width: 0;
	min-height: 70px;
	overflow: visible;
	text-align: left;
}

.wp-powersuite-modal .wpps-captcha-test-status.description {
	margin: 10px 0 0;
	min-height: 1.35em;
	clear: both;
}

.wp-powersuite-modal .wpps-check-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
	gap: 4px 12px;
	align-items: start;
}

.wp-powersuite-modal .wpps-check-grid label {
	display: flex;
	align-items: flex-start;
	gap: 8px;
	padding: 6px 0;
	margin: 0;
	line-height: 1.35;
	font-weight: normal;
}

.wp-powersuite-modal .wpps-check-grid label input {
	margin-top: 3px;
	flex-shrink: 0;
}

.wp-powersuite-modal .wpps-check-grid--roles {
	max-height: 176px;
	overflow-y: auto;
	padding: 8px 12px;
	border: 1px solid #dcdcde;
	border-radius: 6px;
	background: #fcfcfc;
}

.wp-powersuite-modal .wpps-check-grid--roles label {
	display: inline-flex;
	margin-right: 12px;
}

.wp-powersuite-modal .wpps-check-grid .wpps-check-grid__label-with-tip {
	grid-column: 1 / -1;
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 6px;
}

.wp-powersuite-modal .wpps-check-grid .wpps-check-grid__label-with-tip input {
	margin-top: 0;
}

/* Multiselect dropdown component – used in module settings (post types, roles, etc.) */
.wpps-ct-multiselect {
	position: relative;
	max-width: 360px;
}
.wpps-ct-multiselect__trigger {
	display: flex;
	align-items: center;
	justify-content: space-between;
	width: 100%;
	padding: 8px 12px;
	border: 1px solid #8c8f94;
	border-radius: 4px;
	background: #fff;
	font-size: 14px;
	text-align: left;
	cursor: pointer;
	line-height: 1.4;
	color: #1d2327;
}
.wpps-ct-multiselect__trigger:hover {
	border-color: var(--wp-admin-theme-color, #2271b1);
}
.wpps-ct-multiselect__trigger--disabled,
.wpps-ct-multiselect__trigger:disabled {
	opacity: 0.55;
	cursor: not-allowed;
	pointer-events: none;
}
.wpps-ct-multiselect__chevron {
	font-size: 18px;
	width: 18px;
	height: 18px;
	color: #787c82;
	flex-shrink: 0;
	margin-left: 8px;
}
.wpps-ct-multiselect__trigger[aria-expanded="true"] .wpps-ct-multiselect__chevron {
	transform: rotate(180deg);
}
.wpps-ct-multiselect__dropdown {
	position: absolute;
	top: 100%;
	left: 0;
	right: 0;
	margin-top: 4px;
	border: 1px solid #8c8f94;
	border-radius: 4px;
	background: #fff;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
	z-index: 100;
	max-height: 280px;
	display: flex;
	flex-direction: column;
}
.wpps-ct-multiselect__dropdown[hidden] {
	display: none !important;
}
.wpps-ct-multiselect__dropdown--fixed {
	position: fixed !important;
	right: auto;
	margin-top: 0;
	z-index: 100050;
}
.wpps-ct-multiselect__search {
	width: 100%;
	padding: 8px 12px;
	border: none;
	border-bottom: 1px solid #dcdcde;
	font-size: 13px;
	box-sizing: border-box;
	outline: none;
}
.wpps-ct-multiselect__search::placeholder {
	color: #a7aaad;
}
.wpps-ct-multiselect__actions {
	padding: 6px 10px;
	border-bottom: 1px solid #dcdcde;
	display: flex;
	gap: 12px;
	flex-shrink: 0;
}
.wpps-ct-multiselect__action {
	background: none;
	border: none;
	color: var(--wp-admin-theme-color, #2271b1);
	cursor: pointer;
	font-size: 12px;
	padding: 0;
}
.wpps-ct-multiselect__action:hover {
	color: var(--wp-admin-theme-color-darker-10, #135e96);
	text-decoration: underline;
}
.wpps-ct-multiselect__options {
	overflow-y: auto;
	padding: 4px 0;
	max-height: 200px;
}
.wpps-ct-multiselect__option {
	display: flex;
	align-items: center;
	gap: 6px;
	padding: 6px 12px;
	cursor: pointer;
	font-size: 13px;
	white-space: nowrap;
}
.wpps-ct-multiselect__option:hover {
	background: #f0f0f1;
}
.wpps-ct-multiselect__option input {
	flex-shrink: 0;
	margin: 0;
}
.wpps-ct-multiselect__option-slug {
	color: #646970;
	font-size: 12px;
}
.wpps-ct-multiselect__option.wpps-ct-multiselect__option--hidden {
	display: none;
}

.wp-powersuite-modal__loading {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	padding: 60px 20px;
	width: 100%;
	box-sizing: border-box;
	text-align: center;
	position: relative;
	min-height: 200px;
	max-width: 100%;
}

.wp-powersuite-modal__loading .spinner {
	float: none !important;
	margin: 0 auto 15px auto !important;
	display: block;
	width: 20px;
	height: 20px;
	position: relative;
	left: auto;
	right: auto;
}

.wp-powersuite-modal__loading p {
	margin: 0;
	font-size: 14px;
	color: #646970;
	font-weight: 500;
	text-align: center;
	width: 100%;
}

.wp-powersuite-modal__settings {
	min-height: 200px;
}

.wp-powersuite-modal__footer {
	padding: 15px 20px;
	border-top: 1px solid #ddd;
	display: flex;
	justify-content: flex-end;
	gap: 10px;
	background: #f6f7f7;
}

.wp-powersuite-modal__footer .button {
	margin: 0;
}

/* Modal refresh button – match category bar (.wp-powersuite-refresh-page) */
.wp-powersuite-modal__refresh.button.button-primary {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 6px 12px;
	height: auto;
	line-height: 1.5;
	border-radius: 0;
	background: var(--wp-admin-theme-color, var(--wpps-accent, #2271b1));
	border-color: var(--wp-admin-theme-color, var(--wpps-accent, #2271b1));
	color: #fff;
	box-shadow: none;
}

.wp-powersuite-modal__refresh.button.button-primary:hover,
.wp-powersuite-modal__refresh.button.button-primary:focus {
	background: var(--wp-admin-theme-color-darker-10, var(--wpps-accent-hover, #135e96));
	border-color: var(--wp-admin-theme-color-darker-10, var(--wpps-accent-hover, #135e96));
	color: #fff;
}

.wp-powersuite-modal__refresh .wp-powersuite-refresh-icon {
	display: block;
	width: 16px;
	height: 16px;
	flex-shrink: 0;
	color: inherit;
	fill: currentColor;
}

/* Custom Admin CSS – code-style textarea (fallback when CodeMirror unavailable) */
.wp-powersuite-modal__settings textarea.wp-powersuite-css-editor {
	display: block;
	font-family: ui-monospace, "Cascadia Code", "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
	font-size: 13px;
	line-height: 1.5;
	background: #f6f7f7;
	color: #1d2327;
	border: 1px solid #c3c4c7;
	border-radius: 4px;
	padding: 12px 16px;
	width: 100%;
	min-height: 280px;
	box-sizing: border-box;
}
.wp-powersuite-modal__settings textarea.wp-powersuite-css-editor::placeholder {
	color: #a7aaad;
}
/* CodeMirror placeholder – light grey so it’s distinct from entered text */
.wp-powersuite-modal__settings .CodeMirror-placeholder,
.wp-powersuite-modal__settings .cm-placeholder {
	color: #a7aaad !important;
	opacity: 1;
}
.wp-powersuite-modal__settings textarea.wp-powersuite-css-editor:focus {
	border-color: var(--wp-admin-theme-color, #2271b1);
	background: #fff;
	outline: none;
	box-shadow: 0 0 0 1px var(--wp-admin-theme-color, #2271b1);
}

/* CodeMirror in modal – ensure visible height when code editor loads */
.wp-powersuite-modal__settings .CodeMirror {
	min-height: 420px;
	height: auto;
	border-radius: 4px;
	border: 1px solid #c3c4c7;
}

.wpps-wpconfig-editor {
	width: 100%;
}

.wpps-wpconfig-editor .wpps-wpconfig-mask-notice {
	display: none;
	width: 100%;
	box-sizing: border-box;
	margin: 0 0 12px;
	padding: 10px 12px;
	background: #f0f6fc;
	border-left: 4px solid var(--wp-admin-theme-color, #2271b1);
	font-size: 13px;
	line-height: 1.5;
}

.wpps-wpconfig-editor .wpps-wpconfig-actions {
	margin: 0 0 12px;
}

.wp-powersuite-modal__settings .wpps-wpconfig-editor .CodeMirror {
	width: 100%;
	min-height: 420px;
	height: 420px;
	margin-top: 0;
	font-family: Consolas, Monaco, monospace;
	font-size: 13px;
}

.wp-powersuite-modal__settings .wpps-wpconfig-editor .CodeMirror .CodeMirror-scroll {
	min-height: 420px;
	height: 100%;
}

.wp-powersuite-modal__settings .wpps-wpconfig-editor .CodeMirror-gutters {
	min-height: 100%;
}

.wpps-robots-actions,
.wpps-ads-actions {
	margin: 0 0 12px;
}

.wp-powersuite-modal__settings .wpps-robots-txt .CodeMirror,
.wp-powersuite-modal__settings .wpps-ads-txt .CodeMirror {
	width: 100%;
	min-height: 360px;
	height: 360px;
	font-family: Consolas, Monaco, monospace;
	font-size: 13px;
}

.wp-powersuite-modal__settings .wpps-robots-txt .CodeMirror .CodeMirror-scroll,
.wp-powersuite-modal__settings .wpps-ads-txt .CodeMirror .CodeMirror-scroll {
	min-height: 360px;
	height: 100%;
}

.wp-powersuite-modal__settings .wpps-robots-txt .CodeMirror-gutters,
.wp-powersuite-modal__settings .wpps-ads-txt .CodeMirror-gutters {
	min-height: 100%;
}

.wpps-robots-txt .button.is-busy,
.wpps-ads-txt .button.is-busy {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	vertical-align: middle;
}

.wpps-robots-txt .button.is-busy .spinner,
.wpps-ads-txt .button.is-busy .spinner {
	float: none;
	margin: 0;
	visibility: visible;
}

.wp-powersuite-modal__settings .button.is-busy,
.wpps-wpconfig-editor .button.is-busy,
.wpps-debug-settings .button.is-busy {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	vertical-align: middle;
}

.wp-powersuite-modal__settings .button.is-busy .spinner,
.wpps-wpconfig-editor .button.is-busy .spinner,
.wpps-debug-settings .button.is-busy .spinner {
	float: none;
	margin: 0;
	visibility: visible;
}

/* Header & Footer Code panel (legacy) & login custom CSS – VS Code–style dark theme */
.wp-powersuite-hfc-panel .CodeMirror,
.wpps-login-custom-css-editor .CodeMirror {
	font-family: "Cascadia Code", "Fira Code", "JetBrains Mono", "SF Mono", Consolas, Monaco, "Andale Mono", monospace !important;
	font-size: 13px;
	line-height: 1.5;
	min-height: 220px;
	border-radius: 6px;
	border: 1px solid #3c3c3c;
	background: #1e1e1e !important;
	color: #d4d4d4 !important;
}
/* Base text color so untokenized text (plain text/whitespace) is never black-on-black. */
.wp-powersuite-hfc-panel .CodeMirror pre.CodeMirror-line,
.wpps-login-custom-css-editor .CodeMirror pre.CodeMirror-line {
	color: #d4d4d4;
}
.wpps-login-custom-css-editor textarea.wp-powersuite-css-editor {
	min-height: 180px;
}
.wpps-login-custom-css-editor .CodeMirror {
	min-height: 180px;
}
.wp-powersuite-hfc-panel .CodeMirror-gutters {
	background: #252526 !important;
	border-right: 1px solid #3c3c3c;
	min-width: 36px;
}
.wp-powersuite-hfc-panel .CodeMirror-linenumber {
	color: #858585;
	padding: 0 8px 0 4px;
}
.wp-powersuite-hfc-panel .CodeMirror-sizer {
	margin-left: 36px !important;
}
.wp-powersuite-hfc-panel .CodeMirror-cursor {
	border-left-color: #aeafad;
}
.wp-powersuite-hfc-panel .CodeMirror-selected {
	background: #264f78 !important;
}
.wp-powersuite-hfc-panel .CodeMirror-focused .CodeMirror-selected {
	background: #094771 !important;
}
.wp-powersuite-hfc-panel .CodeMirror-activeline-background {
	background: #2a2d2e;
}
.wp-powersuite-hfc-panel .CodeMirror-line {
	color: #d4d4d4;
}
/* Token colors – legacy HFC panels (always dark). Header & Footer module modal uses cs-admin.css theme toggle. */
.wp-powersuite-hfc-panel .CodeMirror .cm-tag { color: #569cd6; }
.wp-powersuite-hfc-panel .CodeMirror .cm-attribute { color: #9cdcfe; }
.wp-powersuite-hfc-panel .CodeMirror .cm-string { color: #ce9178; }
.wp-powersuite-hfc-panel .CodeMirror .cm-string-2 { color: #ce9178; }
.wp-powersuite-hfc-panel .CodeMirror .cm-comment { color: #6a9955; }
.wp-powersuite-hfc-panel .CodeMirror .cm-keyword { color: #569cd6; }
.wp-powersuite-hfc-panel .CodeMirror .cm-atom { color: #569cd6; }
.wp-powersuite-hfc-panel .CodeMirror .cm-property { color: #9cdcfe; }
.wp-powersuite-hfc-panel .CodeMirror .cm-number { color: #b5cea8; }
.wp-powersuite-hfc-panel .CodeMirror .cm-def { color: #dcdcaa; }
.wp-powersuite-hfc-panel .CodeMirror .cm-variable { color: #9cdcfe; }
.wp-powersuite-hfc-panel .CodeMirror .cm-variable-2 { color: #9cdcfe; }
.wp-powersuite-hfc-panel .CodeMirror .cm-variable-3,
.wp-powersuite-hfc-panel .CodeMirror .cm-type { color: #4ec9b0; }
.wp-powersuite-hfc-panel .CodeMirror .cm-operator { color: #d4d4d4; }
.wp-powersuite-hfc-panel .CodeMirror .cm-qualifier { color: #d7ba7d; }
.wp-powersuite-hfc-panel .CodeMirror .cm-builtin { color: #dcdcaa; }
.wp-powersuite-hfc-panel .CodeMirror .cm-bracket { color: #d4d4d4; }
.wp-powersuite-hfc-panel .CodeMirror .cm-link { color: #569cd6; }
.wp-powersuite-hfc-panel .CodeMirror .cm-error { color: #f44747; }
.wp-powersuite-hfc-panel .CodeMirror .cm-meta { color: #569cd6; }
.wp-powersuite-hfc-panel .CodeMirror-matchingbracket {
	color: #ffd700 !important;
	border-bottom: 1px solid #ffd700;
}

.wp-powersuite-hfc-panel {
	padding: 12px;
	background: #1e1e1e;
	border-radius: 6px;
}
.wp-powersuite-hfc-panel textarea.wp-powersuite-hfc-editor,
.wp-powersuite-hfc-panel textarea.wp-powersuite-css-editor {
	display: block;
	font-family: "Cascadia Code", "Fira Code", "JetBrains Mono", "SF Mono", Consolas, monospace;
	font-size: 13px;
	line-height: 1.5;
	background: #1e1e1e;
	color: #d4d4d4;
	border: none;
	border-radius: 4px;
	padding: 12px 16px;
	width: 100%;
	min-height: 200px;
	box-sizing: border-box;
}
.wp-powersuite-hfc-panel textarea.wp-powersuite-hfc-editor::placeholder,
.wp-powersuite-hfc-panel textarea.wp-powersuite-hfc-editor::-webkit-input-placeholder,
.wp-powersuite-hfc-panel textarea.wp-powersuite-css-editor::placeholder,
.wp-powersuite-hfc-panel textarea.wp-powersuite-css-editor::-webkit-input-placeholder {
	color: #858585;
}
.wp-powersuite-hfc-panel textarea.wp-powersuite-hfc-editor:focus,
.wp-powersuite-hfc-panel textarea.wp-powersuite-css-editor:focus {
	outline: none;
	box-shadow: none;
}
/* CodeMirror placeholder – visible grey on dark background (legacy panels) */
.wp-powersuite-hfc-panel .CodeMirror-placeholder,
.wp-powersuite-hfc-panel .cm-placeholder {
	color: #858585 !important;
	opacity: 1;
}

/* Character counter under each Header & Footer editor */
.wp-powersuite-hfc-counter {
	margin-top: 6px;
	text-align: right;
	font-family: "Cascadia Code", "Fira Code", "JetBrains Mono", "SF Mono", Consolas, monospace;
	font-size: 11px;
	color: #858585;
	user-select: none;
}
.wp-powersuite-hfc-counter.is-over {
	color: #f48771;
	font-weight: 600;
}

/* Bulk Actions */
.wp-powersuite-bulk-actions {
	display: none;
	align-items: center;
	justify-content: space-between;
	padding: 10px 15px;
	background: #f0f6fc;
	border: 1px solid var(--wp-admin-theme-color, #2271b1);
	border-radius: 4px;
	margin-bottom: 15px;
}

.wp-powersuite-bulk-actions__selected {
	font-size: 14px;
}

.wp-powersuite-bulk-actions__buttons {
	display: flex;
	gap: 10px;
}

.wp-powersuite-module--list.selected {
	background-color: #f0f6fc;
}

/* Module Highlight (from command palette) */
.wp-powersuite-module--highlighted {
	animation: wp-powersuite-highlight 0.5s ease-in-out;
	box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.3);
}

.wp-powersuite-module--list.wp-powersuite-module--highlighted {
	background-color: #eff6ff;
	border-left: 4px solid var(--wp-admin-theme-color, #2271b1);
}

@keyframes wp-powersuite-highlight {
	0% {
		box-shadow: 0 0 0 0 rgba(37, 99, 235, 0.7);
	}
	50% {
		box-shadow: 0 0 0 8px rgba(37, 99, 235, 0);
	}
	100% {
		box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.3);
	}
}

/* List: checkbox vertically centered (header + body rows) */
.wp-powersuite-view-list th.check-column,
.wp-powersuite-view-list td.check-column,
.wp-powersuite-module--list th.check-column,
.wp-powersuite-module--list td.check-column {
	width: 2.2em;
	padding: 11px 0 11px 3px;
	vertical-align: middle;
}

.wp-powersuite-module--list td {
	vertical-align: middle;
}

.wp-powersuite-module--list th {
	vertical-align: middle;
}

/* Bulk Loader – modal overlay and content */
.wp-powersuite-bulk-loader {
	position: fixed;
	inset: 0;
	width: 100%;
	height: 100%;
	background: rgba(0, 0, 0, 0.6);
	z-index: 100001;
	display: none;
	align-items: center;
	justify-content: center;
	padding: 20px;
	box-sizing: border-box;
}

.wp-powersuite-bulk-loader__content {
	background: #fff;
	padding: 24px 28px;
	border-radius: 4px;
	min-width: 320px;
	max-width: 440px;
	box-shadow: 0 4px 24px rgba(0, 0, 0, 0.15);
	display: flex;
	flex-direction: column;
	gap: 16px;
}

.wp-powersuite-bulk-loader__progress-area {
	display: flex;
	align-items: flex-start;
	gap: 14px;
}

.wp-powersuite-bulk-loader__spinner {
	display: inline-block;
	margin: 2px 0 0 0;
	flex-shrink: 0;
}

.wp-powersuite-bulk-loader__text {
	flex: 1;
	min-width: 0;
}

.wp-powersuite-bulk-loader__message {
	margin: 0 0 12px 0;
	font-size: 14px;
	line-height: 1.4;
	color: #1d2327;
	font-weight: 500;
}

.wp-powersuite-bulk-loader__progress {
	width: 100%;
	height: 8px;
	background: #f0f0f1;
	border-radius: 4px;
	overflow: hidden;
}

.wp-powersuite-bulk-loader__progress-bar {
	height: 100%;
	background: var(--wp-admin-theme-color, #2271b1);
	transition: width 0.25s ease-out;
	border-radius: 4px;
}

.wp-powersuite-bulk-loader__actions {
	display: flex;
	justify-content: flex-end;
	gap: 8px;
	margin-top: 4px;
}

.wp-powersuite-bulk-loader__result-area {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 14px;
}

.wp-powersuite-bulk-loader__result-message {
	margin: 0;
	font-size: 14px;
	line-height: 1.5;
	color: #1d2327;
}

.wp-powersuite-bulk-loader-done {
	min-width: 80px;
}

/* Toast notification (e.g. "Added to favorites") */
.wp-powersuite-toast {
	position: fixed;
	top: 50px;
	left: 50%;
	transform: translateX(-50%);
	padding: 12px 20px;
	background: #1d2327;
	color: #fff;
	border-radius: 4px;
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
	font-size: 14px;
	z-index: 100002;
	animation: wp-powersuite-toast-in 0.2s ease-out;
}

@keyframes wp-powersuite-toast-in {
	from { opacity: 0; transform: translateX(-50%) translateY(-10px); }
	to { opacity: 1; transform: translateX(-50%) translateY(0); }
}

/* Quick Launcher / Command palette — Ctrl/Cmd+Shift+K etc. */
.wpps-command-palette {
	position: fixed;
	inset: 0;
	z-index: 100000;
	display: none;
	align-items: flex-start;
	justify-content: center;
	padding: clamp(48px, 10vh, 120px) 16px 24px;
	box-sizing: border-box;
	animation: wpps-cp-backdrop-in 0.22s ease-out;
}
.wpps-command-palette.is-open {
	display: flex;
}
@keyframes wpps-cp-backdrop-in {
	from { opacity: 0; }
	to { opacity: 1; }
}
.wpps-command-palette-backdrop {
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, 0.7);
}
.wpps-command-palette-box {
	position: relative;
	width: 100%;
	max-width: 560px;
	max-height: min(72vh, 640px);
	display: flex;
	flex-direction: column;
	background: #fff;
	border: 1px solid #c3c4c7;
	border-radius: 0;
	box-shadow: 0 3px 6px rgba(0, 0, 0, 0.3);
	overflow: hidden;
	font-family: var(--wpps-font-sans);
	animation: wpps-cp-box-in 0.2s cubic-bezier(0.2, 0.85, 0.4, 1);
}
@keyframes wpps-cp-box-in {
	from {
		opacity: 0;
		transform: translateY(-12px) scale(0.98);
	}
	to {
		opacity: 1;
		transform: translateY(0) scale(1);
	}
}
.wpps-command-palette-header {
	display: flex;
	align-items: flex-start;
	gap: 12px;
	padding: 14px 16px 10px;
	background: linear-gradient(
		128deg,
		var(--wpps-accent, #2271b1) 0%,
		var(--wpps-accent-hover, #135e96) 52%,
		#1d2327 100%
	);
	color: #fff;
	border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}
.wpps-command-palette-dashicon {
	font-size: 22px;
	width: 22px;
	height: 22px;
	line-height: 22px;
	color: rgba(255, 255, 255, 0.95);
	flex-shrink: 0;
	margin-top: 2px;
}
.wpps-command-palette-headings {
	flex: 1;
	min-width: 0;
}
.wpps-command-palette-title {
	margin: 0;
	font-size: 16px;
	font-weight: 700;
	line-height: 1.25;
	letter-spacing: -0.01em;
	color: inherit;
	border: none;
	padding: 0;
	box-shadow: none;
}
.wpps-command-palette-sub {
	margin: 2px 0 0;
	font-size: 12px;
	line-height: 1.35;
	color: rgba(255, 255, 255, 0.85);
}
.wpps-command-palette-input-wrap {
	position: relative;
	display: grid;
	grid-template-columns: 52px minmax(0, 1fr);
	align-items: stretch;
	column-gap: 0;
	min-height: 56px;
	border-bottom: 1px solid #dcdcde;
	background: #f6f7f7;
	border-radius: 0;
}
.wpps-command-palette-input-wrap::before {
	content: "";
	grid-column: 1;
	grid-row: 1;
	justify-self: center;
	align-self: center;
	width: 24px;
	height: 24px;
	border-radius: 0;
	background: url('data:image/svg+xml,%3Csvg xmlns=%22http://www.w3.org/2000/svg%22 fill=%22none%22 viewBox=%220 0 24 24%22 stroke-width=%221.75%22 stroke=%22%23646970%22%3E%3Cpath stroke-linecap=%22round%22 stroke-linejoin=%22round%22 d=%22M21 21l-6-6m2-5a7 7 0 11-14 0 7 7 0 0114 0z%22/%3E%3C/svg%3E') center / 21px 21px no-repeat;
	pointer-events: none;
	z-index: 1;
	opacity: 0.92;
}
.wpps-command-palette-input {
	grid-column: 2;
	grid-row: 1;
	align-self: stretch;
	min-height: 56px;
	min-width: 0;
	margin: 0;
	padding: 16px 18px;
	border: none;
	border-radius: 0;
	background: transparent;
	font-size: 15px;
	line-height: 1.45;
	color: #1d2327;
	box-sizing: border-box;
	box-shadow: none;
	-webkit-appearance: none;
	appearance: none;
}
.wpps-command-palette-input::placeholder {
	color: #757575;
}
.wpps-command-palette-input:focus {
	outline: 2px solid var(--wp-admin-theme-color, #2271b1);
	outline-offset: -2px;
	border-radius: 0;
	box-shadow: none;
	background: #fff;
}
.wpps-command-palette-list-wrap {
	flex: 1;
	min-height: 0;
	overflow: hidden;
}
.wpps-command-palette-list {
	max-height: 320px;
	margin: 0;
	padding: 6px 0;
	list-style: none;
	overflow-y: auto;
	scrollbar-gutter: stable;
}
.wpps-command-palette-footer {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 6px 4px;
	padding: 10px 14px;
	font-size: 11px;
	line-height: 1.5;
	color: #646970;
	border-top: 1px solid #dcdcde;
	background: #f6f7f7;
}
.wpps-cp-footer-txt {
	margin: 0 1px;
}
.wpps-cp-footer-sep {
	opacity: 0.55;
	margin: 0 2px;
}
.wpps-cp-kbd {
	display: inline-block;
	padding: 2px 6px;
	font-size: 10px;
	font-family: ui-monospace, Menlo, Consolas, monospace;
	font-weight: 600;
	color: #1d2327;
	background: #fff;
	border: 1px solid #c3c4c7;
	border-radius: 3px;
	box-shadow: 0 1px 0 #c3c4c7;
	vertical-align: middle;
}
.wpps-command-palette-item {
	margin: 0;
	padding: 0;
	outline: none;
}
.wpps-command-palette-item:not(.wpps-cp-section):hover {
	background: #f6f7f7;
}
.wpps-command-palette-item.is-selected {
	background: var(--wpps-accent-surface, color-mix(in srgb, var(--wp-admin-theme-color, #2271b1) 12%, #fff));
	box-shadow: inset 3px 0 0 var(--wp-admin-theme-color, #2271b1);
}
.wpps-command-palette-item.is-selected .wpps-cp-label {
	color: var(--wp-admin-theme-color-darker-10, #135e96);
}
.wpps-command-palette-item.wpps-cp-section {
	font-size: 11px;
	font-weight: 600;
	color: #646970;
	text-transform: uppercase;
	letter-spacing: 0.05em;
	padding: 10px 14px 4px;
	cursor: default;
	pointer-events: none;
	user-select: none;
}
.wpps-command-palette-item.wpps-cp-section:hover {
	background: transparent;
}
.wpps-cp-row-main {
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 10px;
	width: 100%;
	padding: 10px 14px;
	box-sizing: border-box;
	cursor: pointer;
	min-height: 44px;
}
.wpps-command-palette-item.wpps-cp-section + .wpps-command-palette-item:not(.wpps-cp-section) .wpps-cp-row-main,
.wpps-command-palette-item:not(.wpps-cp-section) .wpps-cp-row-main {
	padding-top: 8px;
	padding-bottom: 8px;
}
.wpps-cp-label {
	flex: 1;
	min-width: 0;
	font-size: 14px;
	font-weight: 500;
	line-height: 1.35;
	color: #1d2327;
	word-break: break-word;
}
.wpps-cp-badge {
	flex-shrink: 0;
	display: inline-block;
	padding: 3px 8px;
	font-size: 11px;
	font-weight: 600;
	line-height: 1.2;
	text-transform: uppercase;
	letter-spacing: 0.03em;
	border-radius: 4px;
}
.wpps-cp-badge--nav {
	background: var(--wpps-accent-surface, color-mix(in srgb, var(--wp-admin-theme-color, #2271b1) 12%, #fff));
	color: var(--wp-admin-theme-color-darker-10, #135e96);
	border: 1px solid var(--wpps-accent-border-soft, color-mix(in srgb, var(--wp-admin-theme-color, #2271b1) 35%, #c3c4c7));
}
.wpps-cp-badge--on {
	background: rgba(214, 54, 56, 0.12);
	color: #8a1114;
	border: 1px solid rgba(214, 54, 56, 0.35);
}
.wpps-cp-badge--off {
	background: rgba(0, 128, 0, 0.1);
	color: #005a00;
	border: 1px solid rgba(0, 100, 0, 0.25);
}
.wpps-cp-meta {
	display: block;
	padding: 0 14px 10px;
	margin-top: -4px;
	font-size: 12px;
	line-height: 1.35;
	color: #757575;
}
.wpps-command-palette-item:not(.wpps-cp-section) .wpps-cp-meta:last-child {
	margin-top: -2px;
}
.wpps-command-palette-item--empty {
	padding: 28px 20px !important;
	text-align: center;
	list-style: none;
}
.wpps-cp-empty-title {
	font-size: 14px;
	font-weight: 600;
	color: #50575e;
	margin: 0 0 6px;
}
.wpps-cp-empty-hint {
	font-size: 13px;
	color: #757575;
	line-height: 1.45;
	max-width: 28em;
	margin: 0 auto;
}
@media (prefers-reduced-motion: reduce) {
	.wpps-command-palette,
	.wpps-command-palette-box {
		animation: none;
	}
}
.wp-powersuite-toast.wpps-command-palette-toast {
	top: auto;
	bottom: 28px;
	transform: translateX(-50%);
}

/* data-wpps-min / max / step number fields – inline validation (number-clamp.js) */
input[type="number"].wpps-number-invalid {
	border-color: #d63638 !important;
	box-shadow: 0 0 0 1px #d63638;
}

span.wpps-number-field-error {
	display: block;
	font-size: 12px;
	line-height: 1.35;
	color: #d63638;
	margin-top: 6px;
	width: 100%;
}

span.wpps-number-field-error:empty,
span.wpps-number-field-error[hidden] {
	display: none;
	margin-top: 0;
}

/* --------------------------------------------------------------------------
   Login notification – compact modal sheet (shared wpps-al-* patterns)
   -------------------------------------------------------------------------- */
.wp-powersuite-modal__settings .wpps-al-modal-settings {
	margin: -4px 0 0;
}

.wpps-al-modal-lead {
	margin: 0 0 10px !important;
	font-size: 12px;
	line-height: 1.4;
	max-width: 48em;
	color: #646970;
}

.wpps-al-modal-sheet {
	border: 1px solid #c3c4c7;
	border-radius: 4px;
	background: #fff;
	margin-bottom: 10px;
	overflow: hidden;
}

.wpps-al-modal-section {
	padding: 12px 14px 10px;
	border-top: 1px solid #dcdcde;
}

.wpps-al-modal-section:first-child {
	border-top: 0;
	padding-top: 12px;
}

.wpps-al-modal-section--retention .wpps-al-retention-row {
	align-items: center;
}

.wpps-al-modal-section__title {
	margin: 0 0 8px;
	padding: 0;
	font-size: 12px;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.04em;
	color: #50575e;
	line-height: 1.25;
}

.wpps-al-check-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
	gap: 2px 14px;
	align-items: start;
}

.wpps-al-check-grid .wpps-al-check-note {
	grid-column: 1 / -1;
}

.wpps-al-check {
	display: flex;
	align-items: flex-start;
	gap: 8px;
	margin: 0;
	padding: 2px 0;
	font-size: 13px;
	line-height: 1.3;
	cursor: pointer;
	min-height: 0;
}

.wpps-al-check--inline {
	padding: 0;
}

.wpps-al-check input[type="checkbox"] {
	margin: 2px 0 0;
	flex-shrink: 0;
}

.wpps-al-check__text {
	color: #1d2327;
}

.wpps-al-check-note {
	margin: -2px 0 6px !important;
	padding-left: 26px !important;
	font-size: 11px !important;
	line-height: 1.35 !important;
	color: #787c82 !important;
}

.wpps-al-check-grid .wpps-al-check-note:last-child {
	margin-bottom: 0 !important;
}

.wpps-al-retention-row {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 16px 24px;
}

.wpps-al-retention-days {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	font-size: 13px;
	font-weight: 500;
	color: #1d2327;
	margin: 0;
}

.wpps-al-retention-days input.small-text {
	width: 4.5em;
	margin: 0;
}

.wpps-al-modal-details {
	margin: 0 0 10px;
	border: 1px solid #c3c4c7;
	border-radius: 4px;
	background: #f6f7f7;
	overflow: hidden;
}

.wpps-al-modal-details__summary {
	padding: 10px 14px;
	font-size: 13px;
	font-weight: 600;
	cursor: pointer;
	color: #1d2327;
	list-style: none;
	user-select: none;
}

.wpps-al-modal-details__summary::-webkit-details-marker {
	display: none;
}

.wpps-al-modal-details__summary::before {
	content: "▸";
	display: inline-block;
	margin-right: 8px;
	font-size: 10px;
	color: #646970;
	transition: transform 0.15s ease;
}

.wpps-al-modal-details[open] .wpps-al-modal-details__summary::before {
	transform: rotate(90deg);
}

.wpps-al-modal-details__body {
	padding: 8px 14px 10px;
	border-top: 1px solid #dcdcde;
	background: #fff;
}

.wpps-al-modal-footnote {
	margin: 8px 0 0 !important;
	padding: 0;
	background: none;
	border: none;
	font-size: 12px;
}

.wpps-al-modal-footnote a {
	font-weight: 500;
	text-decoration: underline;
	text-underline-offset: 2px;
}

.wp-powersuite-modal:has(.wpps-al-modal-settings) .wp-powersuite-modal__body {
	max-height: min(80vh, 640px);
	overflow-y: auto;
}

@media screen and (max-width: 600px) {
	.wpps-al-check-grid {
		grid-template-columns: 1fr;
	}

	.wpps-al-retention-row {
		flex-direction: column;
		align-items: flex-start;
	}
}

/* --------------------------------------------------------------------------
   Admin Login Notification – extends Activity Log modal patterns
   -------------------------------------------------------------------------- */
.wp-powersuite-modal__settings .wpps-aln-modal-settings {
	margin: -4px 0 0;
}

.wpps-aln-field {
	margin: 0;
}

.wpps-aln-field--spaced {
	margin-top: 12px;
}

.wpps-aln-field-label {
	display: block;
	margin: 0 0 6px;
	font-size: 13px;
	font-weight: 500;
	color: #1d2327;
}

.wpps-aln-input,
.wpps-aln-textarea {
	width: 100% !important;
	max-width: 100%;
	box-sizing: border-box !important;
	margin: 0;
	border-radius: 4px;
	border: 1px solid #c3c4c7;
	box-shadow: 0 0 0 transparent;
	font-size: 13px;
}

.wpps-aln-input {
	padding: 6px 8px !important;
}

.wpps-aln-input:focus,
.wpps-aln-textarea:focus {
	border-color: var(--wp-admin-theme-color, #2271b1);
	box-shadow: 0 0 0 1px var(--wp-admin-theme-color, #2271b1);
	outline: none;
}

.wpps-aln-textarea {
	font-family: ui-monospace, "Cascadia Code", Menlo, Consolas, monospace;
	font-size: 12px;
	line-height: 1.45;
	padding: 8px 10px !important;
	resize: vertical;
	min-height: 5.5rem;
}

.wpps-aln-field-note {
	margin: 6px 0 0 !important;
	font-size: 11px !important;
	line-height: 1.35 !important;
	color: #787c82 !important;
}

.wpps-aln-field-note--inline {
	margin: 0 !important;
	align-self: center;
}

.wpps-aln-callout {
	margin: 10px 0 0;
	padding: 10px 12px;
	font-size: 12px;
	line-height: 1.45;
	color: #50575e;
	background: #f6f7f7;
	border-left: 3px solid #1a1a1a;
	border-radius: 0 3px 3px 0;
}

.wpps-aln-test-panel {
	margin-top: 12px;
	padding: 12px 14px;
	background: #f6f7f7;
	border: 1px solid #dcdcde;
	border-radius: 4px;
}

.wpps-aln-test-panel__title {
	margin: 0 0 8px;
	font-size: 12px;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.04em;
	color: #50575e;
}

.wpps-aln-test-panel__row {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	align-items: center;
}

.wpps-aln-test-panel__row .wpps-aln-input {
	flex: 1 1 200px;
	max-width: none;
}

.wpps-aln-test-feedback {
	margin-top: 8px;
	font-size: 12px;
	line-height: 1.4;
	font-weight: 500;
}

.wpps-aln-test-feedback.is-success {
	color: #00a32a;
}

.wpps-aln-test-feedback.is-error {
	color: #d63638;
}

.wpps-aln-test-feedback.is-pending {
	color: #646970;
}

.wpps-aln-retention-row {
	margin-top: 10px;
}

.wpps-aln-token-list {
	margin: 0;
	padding: 0;
	list-style: none;
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
	gap: 6px 16px;
	font-size: 12px;
	line-height: 1.4;
	color: #50575e;
}

.wpps-aln-token-list code {
	font-size: 11px;
	padding: 1px 5px;
	background: #f0f0f1;
	border-radius: 3px;
	color: #1d2327;
}

.wp-powersuite-modal:has(.wpps-aln-modal-settings) .wp-powersuite-modal__body {
	max-height: min(80vh, 640px);
	overflow-y: auto;
}

@media screen and (max-width: 600px) {
	.wpps-aln-test-panel__row {
		flex-direction: column;
		align-items: stretch;
	}

	.wpps-aln-test-panel__row .button {
		width: 100%;
		justify-content: center;
	}

	.wpps-aln-token-list {
		grid-template-columns: 1fr;
	}
}

/* Performance Monitor (hidden admin screen) */
.wpps-performance-wrap {
	margin: 20px 20px 20px 0;
}

.wpps-performance-wrap .wpps-performance-dashboard {
	margin-top: 8px;
}

.wpps-performance-toolbar {
	display: flex;
	flex-wrap: wrap;
	gap: 12px 20px;
	align-items: center;
	margin: 0 0 16px;
	padding: 10px 14px;
	background: #fff;
	border: 1px solid #c3c4c7;
	border-radius: 4px;
}

.wpps-performance-context,
.wpps-performance-budget {
	font-size: 13px;
	color: #50575e;
}

.wpps-performance-context {
	font-weight: 600;
	color: #1d2327;
}

.wpps-settings-toggle {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	cursor: pointer;
}

.wpps-performance-warning {
	background-color: #fff3cd !important;
}

.wpps-performance-critical {
	background-color: #f8d7da !important;
}

.wpps-status-enabled {
	color: #00a32a;
	font-weight: 600;
}

.wpps-status-disabled {
	color: #646970;
}

.wpps-module-id {
	font-size: 11px;
	color: #646970;
	font-weight: normal;
}

.wpps-warning-icon {
	margin-left: 4px;
	font-size: 16px;
	width: 16px;
	height: 16px;
	vertical-align: middle;
	color: #dba617;
}

.wpps-metric-na {
	color: #a7aaad;
	font-style: italic;
}

.wpps-hook-meter-wrap {
	display: flex;
	align-items: center;
	gap: 10px;
	min-width: 120px;
}

.wpps-hook-count {
	min-width: 2ch;
	font-variant-numeric: tabular-nums;
}

.wpps-hook-meter {
	flex: 1;
	height: 6px;
	background: #dcdcde;
	border-radius: 999px;
	overflow: hidden;
}

.wpps-hook-meter__fill {
	display: block;
	height: 100%;
	background: var(--wpps-accent, #2271b1);
	border-radius: inherit;
}

.wpps-performance-table tr.wpps-performance-warning .wpps-hook-meter__fill {
	background: #dba617;
}

.wpps-performance-table tr.wpps-performance-critical .wpps-hook-meter__fill {
	background: #d63638;
}

.wpps-performance-legend {
	margin-top: 24px;
	padding: 16px 18px;
	background: #f6f7f7;
	border: 1px solid #dcdcde;
	border-radius: 4px;
}

.wpps-performance-legend h3 {
	margin: 0 0 10px;
	font-size: 14px;
}

.wpps-performance-legend ul {
	list-style: none;
	margin: 0;
	padding: 0;
}

.wpps-performance-legend li {
	margin-bottom: 8px;
	font-size: 13px;
}

.wpps-performance-legend .wpps-performance-warning,
.wpps-performance-legend .wpps-performance-critical {
	display: inline-block;
	width: 18px;
	height: 18px;
	border-radius: 3px;
	margin-right: 8px;
	vertical-align: middle;
}

.wpps-performance-legend .wpps-performance-warning {
	background-color: #fff3cd;
}

.wpps-performance-legend .wpps-performance-critical {
	background-color: #f8d7da;
}

.wpps-performance-table.wp-list-table thead th.sortable a {
	display: flex;
	align-items: center;
	justify-content: space-between;
	text-decoration: none;
	color: inherit;
}

.wpps-performance-table.wp-list-table thead th.sortable a:hover {
	color: var(--wpps-accent, #2271b1);
}