/* Shared typography for the custom templates, Woodmart and Elementor. */
html:root {
	--wd-text-font: var(--dac-font);
	--wd-text-font-weight: 400;
	--wd-text-font-size: 16px;
	--wd-text-line-height: 1.6;
	--wd-text-color: var(--dac-text);
	--wd-title-font: var(--dac-font);
	--wd-title-font-weight: 700;
	--wd-title-color: var(--dac-heading);
	--wd-entities-title-font: var(--dac-font);
	--wd-entities-title-font-weight: 700;
	--wd-entities-title-color: var(--dac-heading);
	--wd-alternative-font: var(--dac-font);
	--wd-header-el-font: var(--dac-font);
	--wd-header-el-font-size: 14px;
	--wd-header-el-font-weight: 600;
	--btn-font-family: var(--dac-font);
	--btn-accented-font-family: var(--dac-font);
	--btn-default-font-family: var(--dac-font);
	--btn-accented-font-weight: 600;
	--btn-default-font-weight: 600;
}

/* The kit declares these variables on its body, so set them there too. */
body.wp-theme-woodmart {
	--e-global-typography-primary-font-family: var(--dac-font);
	--e-global-typography-primary-font-weight: 700;
	--e-global-typography-secondary-font-family: var(--dac-font);
	--e-global-typography-secondary-font-weight: 700;
	--e-global-typography-text-font-family: var(--dac-font);
	--e-global-typography-text-font-weight: 400;
	--e-global-typography-accent-font-family: var(--dac-font);
	--e-global-typography-accent-font-weight: 600;
	font-family: var(--dac-font);
	font-size: 16px;
	font-weight: 400;
	line-height: 1.6;
	color: var(--dac-text);
}

/* Target text elements without overriding the theme's icon fonts. */
body :is(h1, h2, h3, h4, h5, h6, button, input, textarea, select),
body .elementor :is(.elementor-heading-title, .elementor-widget-text-editor, .elementor-button, .elementor-button-text, .elementor-icon-list-text),
body .elementor .dac-service-menu {
	font-family: var(--dac-font);
}

body :is(h1, h2, h3, h4, h5, h6) {
	font-weight: 700;
	line-height: 1.3;
	letter-spacing: 0;
}

body :is(button, input, textarea, select) {
	font-weight: 400;
}

body.single-product .product_title {
	font-size: clamp(24px, 2.4vw, 32px);
	color: var(--dac-heading);
}

body .product-grid-item .wd-entities-title {
	font-size: 15px;
	line-height: 1.4;
}

body :is(.woocommerce-product-details__short-description, .woocommerce-Tabs-panel) {
	font-size: 16px;
	line-height: 1.7;
	color: var(--dac-text);
}

body .elementor .elementor-widget-text-editor {
	font-size: 16px;
	font-weight: 400;
	line-height: 1.7;
	color: var(--dac-text);
}

body .elementor .elementor-heading-title {
	font-weight: 700;
	line-height: 1.3;
}

body .elementor h1 {
	font-size: clamp(24px, 2.4vw, 32px);
}

body .elementor h2 {
	font-size: 22px;
}

body .elementor h3 {
	font-size: 18px;
}

body .elementor h4 {
	font-size: 16px;
}

body .elementor .dac-service-menu__list a {
	font-size: 14px;
	font-weight: 400;
}

body .elementor .dac-service-menu__list :is(.current-menu-item, .current-menu-ancestor) > a {
	color: var(--dac-heading);
	font-weight: 700;
	box-shadow: inset 3px 0 var(--dac-yellow);
}

/* Keep inputs at 16px on touch screens to avoid focus zoom on iOS. */
@media (max-width: 767px) {
	body :is(input[type="text"], input[type="search"], input[type="email"], input[type="tel"], input[type="password"], input[type="number"], textarea, select),
	body .dac-cat-search-form input[type="search"],
	body .dac-quote__form :is(input, textarea, select),
	body .elementor form.dac-inquiry-form :is(input:not([type="hidden"]), textarea) {
		font-size: 16px;
	}

	body .elementor h2 {
		font-size: 20px;
	}
}
