/**
 * Base: site-wide defaults built on the design tokens.
 * Keep selectors low-specificity; component/page files handle overrides.
 */

body,
button,
input,
select,
textarea,
h1, h2, h3, h4, h5, h6 {
	font-family: var(--cac-font-family);
}

.h1, .h2, .h3, .h4, .h5, .h6, address, h1, h2, h3, h4, h5, h6, hr, .wp-block-buttons {
	margin: 0 0 1rem;
}

p {
    margin: 0 0 0.75em;
	margin-bottom: 0.75lh;
}


/*
 * Visible keyboard focus. !important because BuddyBoss removes outlines on :focus in many places.
 * Text fields keep BuddyBoss's own focus style (components/forms.css).
 */
:focus-visible:not(input:not([type="checkbox"], [type="radio"], [type="submit"], [type="button"]), select, textarea) {
	outline: var(--cac-focus-width) solid var(--cac-color-focus) !important;
	outline-offset: var(--cac-focus-offset) !important;
}

/* BuddyBoss's styled checkboxes/radios hide the input; outline the visible box instead. */
:is(.bs-styled-checkbox, .bs-styled-radio):focus-visible + label::before {
	outline: var(--cac-focus-width) solid var(--cac-color-focus);
	outline-offset: var(--cac-focus-offset);
}

/* ---------- Layout ---------- */

.container {
	max-width: var(--cac-container-max);
}

@media (prefers-reduced-motion: reduce) {
	*,
	*::before,
	*::after {
		animation-duration: 0.01ms !important;
		animation-iteration-count: 1 !important;
		scroll-behavior: auto !important;
		transition-duration: 0.01ms !important;
	}
}
