/*
 * History - Colours.
 *
 * Read from cp-all-designer about-us/about-cp-all/history/ (section history-colors, .abhcolor) and css/about-us-history.css:765-805, 860-880. What the Style tab sets arrives through
 * the widget's selectors; a size left empty there scales the way the
 * design's does.
 */
.custom-history-colors {
	--custom-vwu: 14.4px;
	--custom-vhu: clamp(5.2px, 1svh, 9px);
	--custom-pad: 90px;
	--custom-rhythm: min(clamp(52px, calc(8.6 * var(--custom-vwu)), 160px), calc(13.7 * var(--custom-vhu)));
	--custom-gap: min(clamp(32px, calc(4.5 * var(--custom-vwu)), 64px), calc(4.4 * var(--custom-vhu)));
	--custom-pair-gap: clamp(28px, calc(3.6 * var(--custom-vwu)), 60px);
	--custom-curl: clamp(56px, calc(6 * var(--custom-vwu)), 96px);
	--custom-curl-sm: clamp(30px, calc(3.2 * var(--custom-vwu)), 50px);
	--custom-sh: 0 18px 44px -14px rgba(22, 65, 140, 0.2);
	--custom-sh-lg: 0 34px 80px -20px rgba(22, 65, 140, 0.3);
	--custom-ease: cubic-bezier(0.2, 0.8, 0.2, 1);
	position: relative;
	display: block;
	box-sizing: border-box;
	overflow: hidden;
	/* app.css:385-389 .sec--rhythm, .container --pad */
	padding: var(--custom-rhythm) var(--custom-pad);
	letter-spacing: normal;
	background: #FFFFFF;
	font-size: 16px;
	line-height: 1.6;
}

@media (max-width: 1280px) { .custom-history-colors { --custom-vwu: 12.2px; --custom-vhu: clamp(5.2px, 1svh, 8.5px); } }
@media (max-width: 1200px) { .custom-history-colors { --custom-vwu: 11.2px; --custom-vhu: clamp(5.2px, 1svh, 8.35px); } }
@media (max-width: 1024px) { .custom-history-colors { --custom-vwu: 9.2px; --custom-vhu: clamp(5.2px, 1svh, 8px); --custom-pad: 40px; } }
@media (max-width: 860px)  { .custom-history-colors { --custom-vwu: 7.7px; --custom-vhu: clamp(5.2px, 1svh, 7.8px); } }
@media (max-width: 640px)  { .custom-history-colors { --custom-vwu: 4.2px; --custom-vhu: clamp(5.2px, 1svh, 7.6px); --custom-pad: 24px; } }
@media (max-width: 380px)  { .custom-history-colors { --custom-vwu: 3.6px; --custom-vhu: clamp(5.2px, 1svh, 7.2px); } }

.custom-history-colors *,
.custom-history-colors *::before,
.custom-history-colors *::after {
	box-sizing: border-box;
}

.custom-history-colors .nb {
	white-space: nowrap;
}

/* ------------------------------------------------------------------ */
/* The head — app.css:230-252 (.h-sec), 291-294 (.lead), 404           */
/* ------------------------------------------------------------------ */

.custom-history-colors__head {
	max-width: 900px;
	margin: 0 auto var(--custom-gap);
	font-size: 16px;
	line-height: 1.6;
	text-align: center;
}

.custom-history-colors__title {
	margin: 0;
	padding: 0;
	font-size: min(clamp(28px, calc(3.9 * var(--custom-vwu)), 56px), calc(6.2 * var(--custom-vhu)));
	font-weight: 600;
	line-height: 1.3;
	letter-spacing: 0;
	text-transform: none;
	text-wrap: wrap;
	color: #16418C;
}

.custom-history-colors__title strong { font-weight: 700; }

.custom-history-colors__title em {
	position: relative;
	display: inline-block;
	font-style: italic;
	font-weight: 700;
	color: #50A3D5;
}

.custom-history-colors__title em::after {
	content: "";
	position: absolute;
	left: 0;
	right: 0;
	bottom: 0.06em;
	height: 0.16em;
	border-radius: 3px;
	background: currentColor;
	opacity: 0.18;
}

.custom-history-colors [data-custom-sweep-ghost] em::after { opacity: 0.12; }

.custom-history-colors__intro {
	max-width: 870px;
	margin: min(22px, calc(2.4 * var(--custom-vhu))) 0 0;
	font-size: clamp(16px, calc(1.25 * var(--custom-vwu)), 18px);
	font-weight: 400;
	line-height: 1.7;
	color: #475569;
}

@media (max-width: 640px) {
	.custom-history-colors__title { font-size: clamp(22px, calc(6.2 * var(--custom-vwu)), 56px); }
	.custom-history-colors__intro { margin-top: 14px; font-size: 14px; line-height: 1.5; }
}

.custom-history-colors__inner {
	width: 100%;
	max-width: calc(1440px - 2 * var(--custom-pad));
	margin: 0 auto;
}

/* about-us-history.css:771-777 — the band runs out to the section's edges */
.custom-history-colors__list {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 0;
	margin: 0 calc(var(--custom-pad) * -1);
	padding: 0;
	list-style: none;
}

.custom-history-colors__item {
	display: grid;
	grid-template-rows: 1fr;
	min-width: 0;
	margin: 0;
	padding: 0;
}

.custom-history-colors__item::before,
.custom-history-colors__item::marker {
	content: none;
}

.custom-history-colors__field {
	display: flex;
	flex-direction: column;
	justify-content: center;
	align-items: center;
	gap: 12px;
	min-height: clamp(240px, calc(22 * var(--custom-vwu)), 320px);
	padding: clamp(34px, calc(3.8 * var(--custom-vwu)), 62px) clamp(20px, calc(2.2 * var(--custom-vwu)), 38px);
	text-align: center;
	background: var(--custom-sw, #16418C);
	color: #FFFFFF;
}

.custom-history-colors__name {
	margin: 0;
	font-size: clamp(20px, calc(1.8 * var(--custom-vwu)), 28px);
	font-weight: 700;
	line-height: 1.25;
	color: #FFFFFF;
}

.custom-history-colors__en {
	margin: 0;
	font-size: clamp(12px, calc(0.95 * var(--custom-vwu)), 14px);
	font-weight: 600;
	line-height: 1.5;
	letter-spacing: 0.04em;
	color: rgba(255, 255, 255, 0.86);
}

.custom-history-colors__en::after {
	content: "";
	display: block;
	width: 34px;
	height: 1px;
	margin: 16px auto 4px;
	background: rgba(255, 255, 255, 0.45);
}

.custom-history-colors__desc {
	max-width: 30ch;
	margin: 0;
	font-size: clamp(14px, calc(1.02 * var(--custom-vwu)), 16px);
	font-weight: 300;
	line-height: 1.8;
	color: rgba(255, 255, 255, 0.95);
}

@media (max-width: 999px) {
	.custom-history-colors__list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 699px) {
	.custom-history-colors__list { grid-template-columns: minmax(0, 1fr); }
	.custom-history-colors__field {
		min-height: 0;
		padding: clamp(34px, calc(9 * var(--custom-vwu)), 48px) clamp(22px, calc(6 * var(--custom-vwu)), 32px);
	}
}

/* the design wraps text plainly; some themes set "pretty" wrapping on
   paragraphs, which moves Thai line breaks */
.custom-history-colors p,
.custom-history-colors h2,
.custom-history-colors h3,
.custom-history-colors li,
.custom-history-colors dt,
.custom-history-colors dd,
.custom-history-colors span {
	text-wrap: wrap;
	text-rendering: optimizeLegibility;
}
