/* ==========================================================================
   ИНТЕГРАЦИЯ КНОПОК GUTENBERG (Принудительное перекрытие стилей Astra)
   ========================================================================== */

/* 1. Базовый вид кнопок (Основная кнопка bx-primary) */
body .wp-block-button .wp-block-button__link,
body .wp-block-button:not(.is-style-outline) .wp-block-button__link {
	min-height: 42px !important;
	display: inline-flex !important;
	align-items: center !important;
	justify-content me: center !important;
	padding-inline: var(--space-4) !important;
	background-color: #c9ff37 !important;
	background: #c9ff37 !important;
	color: var(--color-primary-ink) !important;
	border-radius: var(--radius-sm) !important;
	font-size: var(--text-sm) !important;
	font-weight: 700 !important;
	line-height: 1 !important;
	text-decoration: none !important;
	border: none !important;
	box-shadow: none !important;
	transition: background-color 0.4s, transform 0.4s, color 0.4s !important;
}

/* Hover, Focus, Active состояния для основной кнопки */
body .wp-block-button .wp-block-button__link:hover,
body .wp-block-button .wp-block-button__link:focus,
body .wp-block-button .wp-block-button__link:active {
	background-color: var(--color-primary-hover) !important;
	background: var(--color-primary-hover) !important;
	color: var(--color-primary-ink) !important;
	transform: translateY(-2px) !important;
	box-shadow: none !important;
}

/* 2. СВЕТЛАЯ ТЕКСТОВАЯ ССЫЛКА (стиль bx-text-light) */
body .wp-block-button.is-style-bx-text-light .wp-block-button__link {
	display: inline-flex !important;
	align-items: center !important;
	gap: var(--space-2) !important;
	color: #f3f2ec !important;
	font-size: var(--text-sm) !important;
	font-weight: 700 !important;
	text-decoration: underline !important;
	text-decoration-color: rgb(243 242 236 / 0.4) !important;
	text-underline-offset: 0.28em !important;

	/* Жесткий сброс оболочки кнопки Astra */
	background: transparent !important;
	background-color: transparent !important;
	border: none !important;
	padding: 0 !important;
	min-height: auto !important;
	border-radius: 0 !important;
	box-shadow: none !important;
	transform: none !important;
}

/* При добавлении класса .dark-button */
body .wp-block-button.dark-button .wp-block-button__link,
body .wp-block-button.is-style-bx-text-light .wp-block-button__link.dark-button {
	color: var(--color-text-muted) !important;
	text-decoration-color: color-mix(in oklab, var(--color-text-muted) 40%, transparent) !important;
}

body .site-main .wp-block-button.dark-button .wp-block-button__link:hover,
body .site-main .wp-block-button.is-style-bx-text-light .wp-block-button__link.dark-button:hover {
	color: var(--color-text-muted) !important;
	text-decoration-color: var(--color-text) !important;
}


body .wp-block-button.is-style-bx-text-light .wp-block-button__link:hover,
body .wp-block-button.is-style-bx-text-light .wp-block-button__link:focus,
body .wp-block-button.is-style-bx-text-light .wp-block-button__link:active {
	background: transparent !important;
	background-color: transparent !important;
	color: #ffffff !important;
	text-decoration-color: currentColor !important;
	border-color: transparent !important;
	transform: none !important;
	outline: none !important;
}

/* 3. ССЫЛКА С ПОДЧЁРКИВАНИЕМ (стиль bx-patent-link) */
body .wp-block-button.is-style-bx-patent-link .wp-block-button__link {
	display: inline-flex !important;
	font-size: var(--text-sm) !important;
	font-weight: 700 !important;
	color: var(--color-text) !important;
	text-decoration: underline !important;
	text-underline-offset: 0.28em !important;

	/* Жесткий сброс оболочки кнопки Astra */
	background: transparent !important;
	background-color: transparent !important;
	border: none !important;
	padding: 0 !important;
	min-height: auto !important;
	border-radius: 0 !important;
	box-shadow: none !important;
}

body .wp-block-button.is-style-bx-patent-link .wp-block-button__link:hover,
body .wp-block-button.is-style-bx-patent-link .wp-block-button__link:focus,
body .wp-block-button.is-style-bx-patent-link .wp-block-button__link:active {
	background: transparent !important;
	background-color: transparent !important;
	color: var(--color-text) !important;
	border-color: transparent !important;
	transform: translateY(-2px) !important;
	outline: none !important;
}
