/*
 * components.css
 *
 * Shared building blocks used by more than one template: section
 * shells, headings, the red page head, the CTA band, number strips,
 * tags and chips, and the Woodmart page-title treatment.
 * Part of the Unitex child theme. Enqueued from inc/enqueue.php.
 */

/* ==========================================================
   1. SECTION SHELL & HEADINGS
   ========================================================== */
.ux-section { max-width: 1400px; margin: 0 auto; padding: 74px 32px 0; }

/* section header */
.ux-head {
	display: flex;
	align-items: flex-end;
	justify-content: space-between;
	gap: 40px;
	margin-bottom: 26px;
}
.ux-head h2 { margin: 8px 0 0; }
.ux-kicker {
	display: block;
	font-family: 'Archivo', sans-serif;
	font-size: 13px;
	font-weight: 700;
	color: var(--ux-red);
	letter-spacing: .08em;
	text-transform: uppercase;
}
.ux-head-btn {
	flex-shrink: 0;
	background: var(--ux-dark);
	color: #fff;
	font-family: 'Archivo', sans-serif;
	font-weight: 700;
	font-size: 14px;
	letter-spacing: .03em;
	text-transform: uppercase;
	padding: 15px 26px;
	transition: background .2s ease, color .2s ease;
}
.ux-head-btn:hover { background: var(--ux-red); color: #fff; }
.ux-head-note {
	flex-shrink: 0;
	max-width: 40ch;
	margin: 0;
	font-size: 16.5px;
	line-height: 1.6;
	color: var(--ux-muted);
	text-wrap: pretty;
}

@media (max-width: 1024px) {
	.ux-section { padding-top: 54px; }
	.ux-head { flex-direction: column; align-items: flex-start; gap: 16px; }
	.ux-head-note { max-width: none; }
}

/* ==========================================================
   2. CORNER BADGE
   ========================================================== */
.ux-badge {
	position: absolute;
	top: 0; left: 0;
	z-index: 3;
	background: var(--ux-red);
	color: #fff;
	font-family: 'Archivo', sans-serif;
	font-weight: 700;
	font-size: 12px;
	letter-spacing: .06em;
	text-transform: uppercase;
	padding: 8px 14px;
}

/* ==========================================================
   3. CHECK MARK
   ========================================================== */
.ux-check {
	flex: 0 0 26px;
	width: 26px;
	height: 26px;
	display: flex;
	align-items: center;
	justify-content: center;
	background: #fff;
	color: var(--ux-red);
	font-size: 14px;
}

/* ==========================================================
   4. RED PAGE HEAD
   ========================================================== */
.ux-phead {
	position: relative;
	overflow: hidden;
	background: var(--ux-red);
	border-top: 1px solid #fff;
	padding: 70px 0 78px;
}
.ux-phead::before {
	content: "";
	position: absolute;
	inset: 0;
	pointer-events: none;
	background-image: repeating-linear-gradient(135deg,
		rgba(255,255,255,.075) 0 2px, transparent 2px 13px);
}
.ux-phead::after {
	content: "";
	position: absolute;
	top: 0; right: 0; bottom: 0;
	width: 36%;
	background: var(--ux-dark);
	opacity: .9;
	clip-path: polygon(28% 0, 100% 0, 100% 100%, 0 100%);
	pointer-events: none;
}
.ux-phead-in { position: relative; z-index: 2; }

.ux-crumbs {
	margin-bottom: 22px;
	font-size: 14px;
	color: rgba(255,255,255,.75);
}
.ux-crumbs a { color: rgba(255,255,255,.75); }
.ux-crumbs a:hover { color: #fff; }
.ux-crumbs span { padding: 0 6px; }
.ux-crumbs b { font-weight: 400; color: #fff; }

.ux-phead h1 {
	margin: 0;
	max-width: 22ch;
	color: #fff;
	font-size: clamp(46px, 4.6vw, 68px);
	line-height: 1;
	letter-spacing: -.035em;
	text-wrap: pretty;
}
.ux-phead-lead {
	margin: 24px 0 0;
	max-width: 52ch;
	font-size: 18.5px;
	line-height: 1.6;
	color: rgba(255,255,255,.9);
	text-wrap: pretty;
}
.ux-phead-btns {
	display: flex;
	gap: 12px;
	flex-wrap: wrap;
	align-items: center;
	margin-top: 36px;
}
.ux-phead-btns a {
	font-family: 'Archivo', sans-serif;
	font-weight: 700;
	font-size: 15px;
	letter-spacing: .03em;
	text-transform: uppercase;
	padding: 18px 32px;
	transition: background .2s ease, color .2s ease;
}
.ux-phead-btns .ux-a1 { background: var(--ux-dark); color: #fff; }
.ux-phead-btns .ux-a1:hover { background: #fff; color: var(--ux-red); }
.ux-phead-btns .ux-a2 { color: #fff; border: 1.5px solid #fff; }
.ux-phead-btns .ux-a2:hover { background: #fff; color: var(--ux-red); }

/* spacing fixes scoped to pages that contain .ux-phead,
   so the front page is never affected */
.wd-content-layout:has(.ux-phead) { padding-block: 0 !important; }

.entry-content:has(.ux-phead) > *,
.entry-content:has(.ux-phead) > p:has(> .ux-duo),
.entry-content:has(.ux-phead) > p:has(> .ux-numbers) {
	margin-top: 0 !important;
	margin-bottom: 0 !important;
}
.entry-content:has(.ux-phead) > .ux-section,
.entry-content:has(.ux-phead) > *:has(> .ux-section) { padding-top: 0; }

@media (max-width: 1024px) {
	.ux-phead { padding: 48px 0 54px; }
	.ux-phead::after { display: none; }
	.ux-phead h1 { font-size: 36px; max-width: none; }
}

/* ==========================================================
   5. RED CTA BAND & NUMBER STRIP
   ========================================================== */
/* --- red CTA band --- */
.ux-cta {
	position: relative;
	overflow: hidden;
	background: var(--ux-red);
	margin-top: 80px;
}
.ux-cta::before {
	content: "";
	position: absolute;
	inset: 0;
	pointer-events: none;
	background-image: repeating-linear-gradient(135deg,
		rgba(255,255,255,.08) 0 2px, transparent 2px 13px);
}
.ux-cta-in {
	position: relative;
	z-index: 2;
	max-width: 1400px;
	margin: 0 auto;
	padding: 64px 32px;
	display: grid;
	grid-template-columns: minmax(0, 1fr) auto;
	gap: 48px;
	align-items: center;
}
.ux-cta .ux-kicker { color: #fff; opacity: .8; }
.ux-cta h2 {
	margin: 10px 0 0;
	max-width: 36ch;
	color: #fff;
	font-size: 42px;
	line-height: 1.05;
	text-wrap: pretty;
}
.ux-cta-btn {
	flex-shrink: 0;
	white-space: nowrap;
	background: #fff;
	color: var(--ux-red);
	font-family: 'Archivo', sans-serif;
	font-weight: 700;
	font-size: 15px;
	letter-spacing: .03em;
	text-transform: uppercase;
	padding: 19px 34px;
	transition: background .2s ease, color .2s ease;
}
.ux-cta-btn:hover { background: var(--ux-dark); color: #fff; }

/* --- four numbers, attached to the band above --- */
.ux-numbers {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	margin-top: 0;
	background: #fff;
	border: 1px solid var(--ux-line);
	border-top: 0;
}
.ux-numbers > div {
	padding: 34px 28px;
	border-left: 1px solid var(--ux-line-soft);
}
.ux-numbers > div:first-child { border-left: 0; }
.ux-numbers strong {
	display: block;
	font-family: 'Archivo', sans-serif;
	font-weight: 900;
	font-size: 38px;
	letter-spacing: -.02em;
	color: var(--ux-red);
}
.ux-numbers span {
	display: block;
	margin-top: 8px;
	font-size: 13.5px;
	line-height: 1.4;
	color: var(--ux-muted);
	letter-spacing: .03em;
	text-transform: uppercase;
}

/* the CTA band is the last thing before the footer */
.ux-cta { margin-bottom: 0 !important; }

@media (max-width: 1024px) {
	.ux-cta { margin-top: 54px; }
	.ux-cta-in { grid-template-columns: 1fr; gap: 26px; padding: 44px 32px; }
	.ux-cta h2 { font-size: 30px; }
	.ux-numbers { grid-template-columns: 1fr 1fr; }
	.ux-numbers > div:nth-child(3) { border-left: 0; }
	.ux-numbers > div:nth-child(n+3) { border-top: 1px solid var(--ux-line-soft); }
}

@media (max-width: 600px) {
	.ux-numbers { grid-template-columns: 1fr; }
	.ux-numbers > div { border-left: 0; }
	.ux-numbers > div + div { border-top: 1px solid var(--ux-line-soft); }
}

/* ==========================================================
   6. TAGS & CHIPS
   ========================================================== */
.ux-tag {
	display: inline-flex;
	align-self: flex-start;
	margin-bottom: 20px;
	background: var(--ux-tint);
	color: var(--ux-red);
	font-family: 'Archivo', sans-serif;
	font-size: 12px;
	font-weight: 700;
	letter-spacing: .08em;
	text-transform: uppercase;
	padding: 7px 13px;
}
.ux-tag-dark { background: rgba(255,255,255,.12); color: #FF8078; }

.ux-chips { display: flex; gap: 10px; flex-wrap: wrap; }
.ux-chips span {
	border: 1px solid var(--ux-line);
	font-family: 'Archivo', sans-serif;
	font-weight: 700;
	font-size: 13px;
	padding: 11px 16px;
}
.ux-chips .ux-chip-dark {
	background: var(--ux-dark);
	color: #fff;
	border-color: var(--ux-dark);
}

/* ==========================================================
   7. WOODMART PAGE TITLE - red head on every non-product page
   ========================================================== */
/* --- red archive head (never on a single product) --- */
body:not(.single-product) .page-title,
body:not(.single-product) .wd-page-title {
	position: relative;
	overflow: hidden;
	background: var(--ux-red) !important;
	padding: 40px 0 46px !important;
	border: 0 !important;
}
body:not(.single-product) .page-title::before,
body:not(.single-product) .wd-page-title::before {
	content: "";
	position: absolute;
	inset: 0;
	pointer-events: none;
	background-image: repeating-linear-gradient(135deg,
		rgba(255,255,255,.075) 0 2px, transparent 2px 13px);
}
body:not(.single-product) .page-title::after,
body:not(.single-product) .wd-page-title::after {
	content: "";
	position: absolute;
	top: 0; right: 0; bottom: 0;
	width: 34%;
	background: var(--ux-dark);
	opacity: .9;
	clip-path: polygon(30% 0, 100% 0, 100% 100%, 0 100%);
	pointer-events: none;
}
.page-title .container,
.page-title > div,
.wd-page-title .container { position: relative; z-index: 2; }

body:not(.single-product) .page-title .entry-title,
body:not(.single-product) .wd-page-title .entry-title {
	margin: 0;
	color: #fff !important;
	font-size: 56px;
	line-height: 1;
	letter-spacing: -.035em;
}
.page-title .wd-breadcrumbs,
.page-title .woocommerce-breadcrumb,
.page-title .yoast-breadcrumb {
	margin-bottom: 18px !important;
	font-size: 14px;
	color: rgba(255,255,255,.75) !important;
}
.page-title .woocommerce-breadcrumb a,
.page-title .wd-breadcrumbs a { color: rgba(255,255,255,.75) !important; }
.page-title .woocommerce-breadcrumb a:hover { color: #fff !important; }
.page-title .category-description,
.page-title .term-description {
	margin-top: 14px;
	max-width: 56ch;
	font-size: 17px;
	line-height: 1.6;
	color: rgba(255,255,255,.9);
}

@media (max-width: 1024px) {
	body:not(.single-product) .page-title::after,
	body:not(.single-product) .wd-page-title::after { display: none; }
	body:not(.single-product) .page-title .entry-title,
	body:not(.single-product) .wd-page-title .entry-title { font-size: 34px; }
}
