/**
 * core/button block styles.
 *
 * Loaded only when a button block is rendered, in both the editor iframe and
 * the front-end, via wp_enqueue_block_style().
 */

/**
 * Default-style hover: opacity drop, no color change.
 *
 * Scoped to default style only.
 */
.wp-block-button:not(.is-style-fill-accent):not(.is-style-button-light):not(.is-style-link):not(.is-style-outline) .wp-block-button__link:hover {
	background-color: var(--wp--preset--color--primary-alt);
	color: var(--wp--preset--color--base);
	opacity: 0.85;
}

/**
 * "Fill" variation hover.
 */
.wp-block-button.is-style-fill-accent .wp-block-button__link:hover {
	background-color: var(--wp--preset--color--primary-alt);
}

/**
 * HubSpot CTA anchors that are rendered from stored HubSpot embed snippets.
 *
 * The clickable element is HubSpot's <a>, not WordPress' .wp-block-button__link,
 * so mirror the default core/button styling and use CSS for the trailing
 * external-link icon instead of mutating the tracked HubSpot markup.
 */
.wp-block-button.is-r2c-hubspot-cta .hs-web-interactive-inline,
.wp-block-button.is-r2c-hubspot-cta .r2c-cta-primary {
	width: 100%;
}

.lender-card .wp-block-buttons .wp-block-button.is-r2c-hubspot-cta,
.lender-card .wp-block-buttons .wp-block-button.is-r2c-hubspot-cta .hs-web-interactive-inline,
.lender-card .wp-block-buttons .wp-block-button.is-r2c-hubspot-cta .r2c-cta-primary {
	box-sizing: border-box;
	flex-basis: 100%;
	max-width: 100%;
	width: 100%;
}

.wp-block-button.is-r2c-hubspot-cta .r2c-cta-primary {
	align-items: center;
	background-color: var(--wp--preset--color--primary-alt);
	border: 2px solid transparent;
	border-radius: var(--wp--preset--border-radius--xs);
	box-sizing: border-box;
	color: var(--wp--preset--color--base);
	display: inline-flex;
	font-family: var(--wp--preset--font-family--primary);
	font-size: var(--wp--preset--font-size--small);
	font-weight: 500;
	gap: 0.5em;
	justify-content: center;
	line-height: inherit;
	padding: var(--wp--preset--spacing--x-small) var(--wp--preset--spacing--medium);
	text-align: center;
	text-decoration: none;
}

.wp-block-button.is-r2c-hubspot-cta .r2c-cta-primary:hover,
.wp-block-button.is-r2c-hubspot-cta .r2c-cta-primary:focus-visible {
	background-color: var(--wp--preset--color--primary-alt);
	color: var(--wp--preset--color--base);
	opacity: 0.85;
	text-decoration: none;
}

.wp-block-button.is-r2c-hubspot-cta .r2c-cta-primary::after {
	background-color: currentcolor;
	content: "";
	flex-shrink: 0;
	height: 1em;
	mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M15 3h6v6'/%3E%3Cpath d='M10 14 21 3'/%3E%3Cpath d='M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6'/%3E%3C/svg%3E") center / contain no-repeat;
	width: 1em;
	-webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M15 3h6v6'/%3E%3Cpath d='M10 14 21 3'/%3E%3Cpath d='M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6'/%3E%3C/svg%3E") center / contain no-repeat;
}

.r2c-comparison-table__cta-wrapper .hs-web-interactive-inline,
.r2c-comparison-table__cta-wrapper .wp-block-buttons,
.r2c-comparison-table__cta-wrapper .wp-block-button.is-r2c-hubspot-cta,
.r2c-comparison-table__cta-wrapper .wp-block-button.is-r2c-hubspot-cta .hs-web-interactive-inline {
	display: inline-flex;
	margin: 0;
}

.r2c-comparison-table__cta-wrapper .r2c-cta-primary,
.r2c-comparison-table__cta-wrapper .wp-block-button.is-r2c-hubspot-cta .r2c-cta-primary {
	align-items: center;
	background: #830075 !important;
	border: 0 !important;
	border-radius: 0.25rem !important;
	box-shadow: none !important;
	box-sizing: border-box;
	color: #fff !important;
	display: inline-flex;
	font-family: inherit !important;
	font-size: 0.75rem !important;
	font-weight: 500 !important;
	gap: 0.5rem;
	height: 2.25rem;
	justify-content: center;
	letter-spacing: normal !important;
	line-height: 1 !important;
	padding: 0 0.75rem !important;
	text-decoration: none !important;
	text-transform: none !important;
	white-space: nowrap !important;
}

.r2c-comparison-table__cta-wrapper .r2c-cta-primary:hover,
.r2c-comparison-table__cta-wrapper .r2c-cta-primary:focus-visible {
	color: #fff !important;
	opacity: 0.88;
	text-decoration: none !important;
	transform: translateY(-1px);
}

.r2c-comparison-table__cta-wrapper .r2c-cta-primary::after {
	background-color: currentcolor;
	content: "";
	flex: 0 0 1rem;
	height: 1rem;
	margin-left: 0.25rem;
	mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M15 3h6v6'/%3E%3Cpath d='M10 14 21 3'/%3E%3Cpath d='M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6'/%3E%3C/svg%3E") center / contain no-repeat;
	width: 1rem;
	-webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M15 3h6v6'/%3E%3Cpath d='M10 14 21 3'/%3E%3Cpath d='M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6'/%3E%3C/svg%3E") center / contain no-repeat;
}

.r2c-comparison-table__card-cta .r2c-comparison-table__cta-wrapper,
.r2c-comparison-table__card-cta .r2c-comparison-table__cta-wrapper .hs-web-interactive-inline,
.r2c-comparison-table__card-cta .r2c-comparison-table__cta-wrapper .wp-block-buttons,
.r2c-comparison-table__card-cta .r2c-comparison-table__cta-wrapper .wp-block-button.is-r2c-hubspot-cta,
.r2c-comparison-table__card-cta .r2c-comparison-table__cta-wrapper .wp-block-button.is-r2c-hubspot-cta .hs-web-interactive-inline,
.r2c-comparison-table__card-cta .r2c-comparison-table__cta-wrapper .r2c-cta-primary {
	width: 100%;
}

.r2c-provider-cards__cta-wrapper,
.r2c-provider-cards__cta-wrapper .hs-web-interactive-inline,
.r2c-provider-cards__cta-wrapper .wp-block-buttons,
.r2c-provider-cards__cta-wrapper .wp-block-button.is-r2c-hubspot-cta,
.r2c-provider-cards__cta-wrapper .wp-block-button.is-r2c-hubspot-cta .hs-web-interactive-inline,
.r2c-provider-cards__cta-wrapper .r2c-cta-primary {
	box-sizing: border-box;
	width: 100%;
}

/**
 * "Light" variation hover.
 *
 */
.wp-block-button.is-style-button-light .wp-block-button__link:hover {
	opacity: 0.85;
}

/**
 * "Outline" base and hover.
 *
 * For core variations, neither the per-partial path (e.g. /styles/blocks/button/button-*.json) produces output or theme.json. Full CSS override is required.
 */

.wp-block-button.is-style-outline .wp-block-button__link {
	background-color: var(--wp--preset--color--base);
	border: 2px solid var(--wp--preset--color--primary-accent);
	color: var(--wp--preset--color--primary-accent-accessible);
	outline: unset;
	padding: var(--wp--preset--spacing--x-small) var(--wp--preset--spacing--medium);
}

.wp-block-button.is-style-outline .wp-block-button__link:hover {
	background-color: var(--wp--preset--color--primary-accent-accessible);
	color: var(--wp--preset--color--base);
}

/**
 * "Link" variation — link-style CTA.
 */
.wp-block-button.is-style-link .wp-block-button__link {
	&:hover {
		text-decoration: underline;
	}
}

/**
 * "Link" variation — with background. Requires custom class manually added to the button called .icon-has-background.
 */
.wp-block-button.is-style-link.icon-has-background .wp-block-button__link {
	svg {
		background-color: var(--wp--preset--color--primary-accent);
		border-radius: var(--wp--preset--border-radius--xs);
		height: 32px;
		padding: var(--wp--preset--spacing--x-small);
		width: 32px;
	}
}
