/**
 * Shared child-theme button primitives.
 */

.ych-button {
	display: inline-flex;
	min-height: var(--ych-control-height);
	align-items: center;
	gap: var(--ych-space-1);
	justify-content: center;
	padding: 0.7rem var(--ych-control-padding-inline);
	border: 0.0625rem solid transparent;
	border-radius: var(--ych-radius-button);
	background-color: var(--ych-accent-blue);
	background: var(--ych-accent-gradient);
	box-shadow: var(--ych-shadow-small);
	color: var(--ych-bg-primary);
	font-size: 0.9375rem;
	font-weight: 700;
	letter-spacing: 0.01em;
	line-height: 1.2;
	text-align: center;
	text-decoration: none;
	text-underline-offset: 0.22em;
	transition: background-color var(--ych-transition), border-color var(--ych-transition), box-shadow var(--ych-transition), color var(--ych-transition), transform var(--ych-transition);
}

.ych-button:visited {
	color: var(--ych-bg-primary);
}

.ych-button:hover:not([aria-disabled="true"], :disabled) {
	border-color: transparent;
	box-shadow: var(--ych-shadow-medium);
	color: var(--ych-bg-primary);
	transform: translateY(-0.125rem);
}

.ych-button:active:not([aria-disabled="true"], :disabled) {
	box-shadow: var(--ych-shadow-small);
	transform: translateY(0);
}

.ych-button--primary {
	background-color: var(--ych-accent-blue);
	background-image: var(--ych-accent-gradient);
	color: var(--ych-bg-primary);
}

.ych-button--secondary {
	border-color: var(--ych-border-on-light);
	background: var(--ych-surface-white);
	box-shadow: none;
	color: var(--ych-text-on-light);
}

.ych-button--secondary:visited {
	color: var(--ych-text-on-light);
}

.ych-button--secondary:hover:not([aria-disabled="true"], :disabled) {
	border-color: var(--ych-accent-border);
	background: var(--ych-surface-soft);
	box-shadow: var(--ych-shadow-small);
	color: var(--ych-text-on-light);
}

.ych-button--light {
	border-color: var(--ych-border-strong);
	background: transparent;
	box-shadow: none;
	color: var(--ych-text-primary);
}

.ych-button--light:visited {
	color: var(--ych-text-primary);
}

.ych-button--light:hover:not([aria-disabled="true"], :disabled) {
	border-color: var(--ych-accent-blue);
	background: var(--ych-bg-card-hover);
	box-shadow: none;
	color: var(--ych-text-primary);
}

.ych-button--tertiary {
	min-height: 2.75rem;
	padding-inline: 0;
	border: 0;
	border-radius: 0;
	background: transparent;
	box-shadow: none;
	color: var(--ych-accent-blue);
	text-decoration: underline;
	text-decoration-color: rgba(120, 169, 228, 0.48);
	text-decoration-thickness: 0.125rem;
}

.ych-button--tertiary:visited {
	color: var(--ych-accent-blue);
}

.ych-button--tertiary:hover:not([aria-disabled="true"], :disabled) {
	background: transparent;
	box-shadow: none;
	color: var(--ych-text-primary);
	text-decoration-color: currentColor;
	transform: none;
}

.ych-button:focus-visible {
	outline: 0.1875rem solid var(--ych-focus);
	outline-offset: 0.25rem;
}

.ych-button[aria-disabled="true"],
.ych-button:disabled {
	cursor: not-allowed;
	filter: grayscale(0.35);
	opacity: 0.58;
	pointer-events: none;
}
