/* ==========================================================================
   CMSELL — English homepage, content area redesign
   2026-12-01 · consolidated layer

   BOUNDARY (non-negotiable)
   The search band and the three-column floor under it — cm-searchband,
   cm-bandsearch, cm-bandperks, cm-floor — are untouched. No selector in this
   file targets them, in any state, at any viewport.

   Everything below the floor is redesigned here:
     · one surface language taken FROM the retained floor: grey block,
       8px radius, no stroke, 12px gutter, 16–24px inset
     · one type scale, one rhythm, one hover behaviour
     · section list shortened in below-freeze.php (two duplicated blocks merged)
   ========================================================================== */

/* ---------- Measure + rhythm --------------------------------------------- */
body.cm-home .cm-sec > .cm-container {
	/* 对齐基准 = 三列板块（.cm-floor__in）：它用 max-width 1440 + 左右内距 24，
	   所以内容区在 1440 视口下是 24…1401。这里必须用同一组数值，
	   否则每个板块两侧各缩 16px，整页左边界就断成两条线。
	   （实测：三列 24/1401，本文件改前是 40/1385。） */
	max-width: 1440px;
	margin-inline: auto;
	padding-inline: 24px;
}

body.cm-home .cm-sec {
	/* Alternating bands below the retained floor: the surface flips white /
	   #f4f4f4 section by section, and the card fill flips with it, so a card
	   is always one step away from the surface it sits on. */
	background: #fff;
	--cm-card: #F7F7F7;
	border-top: 0;
	/* 56 per side: neighbouring blocks meet at 112 between content, instead of
	   stacking two 112 paddings into 224. */
	padding-block: 56px;
}

/* The tinted bands. Order below the floor:
   cats W · rfq G · products W · promo G · suppliers W · services G ·
   flow W · editorial G (chips share this band) · suppliercta W */
body.cm-home .cm-rfq,
body.cm-home .cm-promo,
body.cm-home .cm-services,
body.cm-home .cm-markets,
body.cm-home .cm-editorial {
	background: #f4f4f4;
	--cm-card: #fff;
}

body.cm-home .cm-suppliercta {
	background: #fff;
	--cm-card: #F7F7F7;
}

/* The category grid follows the floor directly; a full gap would break the
   read from "pick a column" to "pick a category". */
body.cm-home .cm-cats.cm-sec {
	padding-top: 44px;
}

body.cm-home .cm-sec__head {
	align-items: flex-end;
	margin-bottom: 36px;
	gap: 16px 32px;
}

/* One alignment for every section head. The services band was the only
   centred head on the page. */
body.cm-home .cm-sec__head--center {
	justify-content: flex-start;
	text-align: left;
}

body.cm-home .cm-sec__head--center .cm-eyebrow {
	display: inline-block;
}

/* ---------- Type scale ---------------------------------------------------- */
body.cm-home .cm-eyebrow {
	color: var(--cm-ink-3);
	font-size: 11px;
	font-weight: 700;
	letter-spacing: .12em;
	text-transform: uppercase;
	margin: 0 0 12px;
}

body.cm-home .cm-sec__title {
	font-size: 32px;
	line-height: 1.18;
	font-weight: 700;
	letter-spacing: -.022em;
	color: var(--cm-ink);
	margin: 0;
	max-width: 820px;
	text-wrap: balance;
}

body.cm-home .cm-sec__sub {
	font-size: 15px;
	line-height: 1.62;
	color: var(--cm-ink-3);
	max-width: 68ch;
	margin: 12px 0 0;
}

body.cm-home .cm-sec__more {
	font-size: 13px;
	font-weight: 600;
	letter-spacing: 0;
	color: var(--cm-ink-2);
}

/* ---------- Card language, inherited from the retained floor --------------- */
body.cm-home .cm-catcard,
body.cm-home .cm-product,
body.cm-home .cm-supplier,
body.cm-home .cm-post,
body.cm-home .cm-service,
body.cm-home .cm-markets__i,
body.cm-home .cm-intent__route {
	background: var(--cm-card, #fff);
	border: 0;
	border-radius: 8px;
	box-shadow: none;
	height: 100%;
	align-self: stretch;
	transition: background-color .18s ease, box-shadow .18s ease, transform .18s ease;
}

body.cm-home .cm-catcard:hover,
body.cm-home .cm-product:hover,
body.cm-home .cm-supplier:hover,
body.cm-home .cm-post:hover,
body.cm-home .cm-service:hover,
body.cm-home .cm-markets__i:hover,
body.cm-home .cm-intent__route:hover {
	box-shadow: 0 4px 16px rgba(18, 26, 34, .09);
	transform: translateY(-2px);
}

/* Media sits inside the block with the same corner. */
body.cm-home .cm-product__art,
body.cm-home .cm-post__art,
body.cm-home .cm-supplier__art {
	overflow: hidden;
	border-radius: 8px 8px 0 0;
}

body.cm-home .cm-product__art img,
body.cm-home .cm-post__art img,
body.cm-home .cm-supplier__art img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

/* Panels that still painted white inside a grey block. */
body.cm-home .cm-post__body {
	background: transparent;
}

body.cm-home .cm-supplier__main,
body.cm-home .cm-supplier__main > div,
body.cm-home .cm-supplier__main > p {
	background: transparent;
	border: 0;
	box-shadow: none;
}

body.cm-home .cm-supplier__main {
	padding: 10px 0 0;
}

/* Icons are line work, as in the floor's category tree — no colour plate. */
body.cm-home .cm-catcard__icon,
body.cm-home .cm-service__icon {
	width: 40px;
	height: 40px;
	background: transparent;
	color: var(--cm-ink-2);
	border-radius: 0;
	margin-bottom: 12px;
}

/* Badges read as metadata, not as a second accent colour. */
body.cm-home .cm-product__badge,
body.cm-home .cm-post__tag {
	background: rgba(255, 255, 255, .94);
	color: var(--cm-ink-2);
	border: 1px solid #E8EBEE;
	border-radius: 6px;
	font-size: 10.5px;
	font-weight: 600;
	letter-spacing: .02em;
	padding: 3px 8px;
}

body.cm-home .cm-product__save {
	background: #fff;
	color: var(--cm-ink-2);
	border-radius: 6px;
	font-weight: 600;
}

/* ---------- Price line ---------------------------------------------------- */
/* At 17px the range plus the unit/FOB note overflowed a 246px block and the
   second half was clipped. */
body.cm-home .cm-product__price {
	flex-wrap: nowrap;
	align-items: baseline;
	gap: 6px;
}

body.cm-home .cm-product__price strong {
	font-size: 16px;
	letter-spacing: -.03em;
	white-space: nowrap;
}

body.cm-home .cm-product__price span {
	white-space: nowrap;
	flex: 0 0 auto;
}

/* A dashed rule under the price is decoration where spacing already separates. */
body.cm-home .cm-product__supplier {
	border-top: 0;
	padding-top: 10px;
}

/* ---------- Intent bridge -------------------------------------------------- */
body.cm-home .cm-intent__title {
	font-size: 26px;
	line-height: 1.25;
	letter-spacing: -.02em;
}

body.cm-home .cm-intent__note {
	font-size: 12.5px;
	color: var(--cm-ink-3);
}

/* ---------- Grids --------------------------------------------------------- */
body.cm-home .cm-markets__grid {
	gap: 12px;
	background: transparent;
	border: 0;
	border-radius: 0;
	overflow: visible;
}

body.cm-home .cm-markets__i {
	padding: 18px;
}

/* ---------- Tabs ---------------------------------------------------------- */
body.cm-home .cm-tabs__list {
	border-bottom: 1px solid #E8EBEE;
	gap: 0;
}

body.cm-home .cm-tabs__tab {
	font-size: 14px;
	font-weight: 600;
	padding: 10px 0;
	margin-right: 28px;
	color: var(--cm-ink-3);
}

/* ---------- Dark blocks --------------------------------------------------- */
body.cm-home .cm-promo__main {
	background: #102A3A;
	background-image: none;
	border-radius: 12px;
	padding: 40px;
}

body.cm-home .cm-source-card,
body.cm-home .cm-source-card__in {
	border-radius: 8px;
	box-shadow: none;
}

body.cm-home .cm-promocard {
	border: 0;
	border-radius: 8px;
	box-shadow: none;
}

body.cm-home .cm-promocard:not(.cm-promocard--navy) {
	background: var(--cm-card, #fff);
}

/* The navy variant keeps its fill: white-on-dark copy would otherwise vanish. */
body.cm-home .cm-promocard--navy {
	background: var(--cm-navy);
}

/* ---------- Supplier strip: the closing white band ------------------------ */
body.cm-home .cm-suppliercta {
	background: #fff;
	--cm-card: #F7F7F7;
	border-top: 0;
	padding-block: 56px;
}

body.cm-home .cm-suppliercta__in {
	background: var(--cm-card, #fff);
	border-radius: 8px;
	padding: 32px 36px;
}

/* ---------- Responsive ---------------------------------------------------- */
/* Chips belong to the reading block above them, not a block of their own. */
body.cm-home .cm-markets {
	padding-block: 44px 0;
}

body.cm-home .cm-markets__row {
	padding-bottom: 18px;
}

body.cm-home .cm-editorial.cm-sec {
	padding-top: 28px;
}

/* The programme band is a strip, not a section: shorter head, tighter card. */
body.cm-home .cm-promo.cm-sec {
	padding-block: 40px;
}

body.cm-home .cm-promo .cm-sec__head {
	margin-bottom: 16px;
}

body.cm-home .cm-promo .cm-sec__title {
	font-size: 20px;
	max-width: none;
}

body.cm-home .cm-promo .cm-eyebrow {
	margin-bottom: 6px;
}

body.cm-home .cm-promo__main {
	padding: 28px;
}

/* Price must stay on one line; the 5-up row is too narrow for a wrap. */
body.cm-home .cm-product__price {
	flex-wrap: nowrap !important;
	overflow: hidden;
}

body.cm-home .cm-product__price strong {
	font-size: 15px !important;
	white-space: nowrap !important;
	letter-spacing: -.03em;
}

body.cm-home .cm-product__price span {
	white-space: nowrap !important;
}

/* The "can't find the model" strip is a fallback, not the main action:
   it reads as an outlined button so the request band keeps the only solid CTA. */
body.cm-home .cm-source-card .cm-btn--primary {
	background: transparent;
	border: 1px solid rgba(255, 255, 255, .38);
	color: #fff;
}

body.cm-home .cm-source-card .cm-btn--primary:hover {
	background: rgba(255, 255, 255, .1);
	border-color: rgba(255, 255, 255, .6);
	color: #fff;
}

/* Trust block: the protection half reads as a sub-group of the factory half,
   so the two sections scan as one block instead of two equal ones. */
/* Services now owns its own tinted band, so it reads as a peer section
   rather than a sub-group of the factory block. */
body.cm-home .cm-services.cm-sec {
	padding-block: 56px;
}

@media (max-width: 1200px) {
	body.cm-home .cm-sec {
		padding-block: 48px;
	}
	body.cm-home .cm-sec__title {
		font-size: 29px;
	}
}

@media (max-width: 900px) {
	/* The retained band overflows the viewport on phones (its own issue, outside
	   this layer), which widens <body> and drags every percentage-width block
	   with it. Pin the content sections to the viewport instead of to <body>. */
	body.cm-home .cm-sec {
		width: 100%;
		max-width: min(100%, 100dvw);
		overflow-x: clip;
		padding-block: 40px;
	}
	body.cm-home .cm-cats.cm-sec {
		padding-top: 36px;
	}
	body.cm-home .cm-sec > .cm-container {
		padding-inline: 24px;
	}
	body.cm-home .cm-sec__head {
		margin-bottom: 26px;
	}
	body.cm-home .cm-sec__title {
		font-size: 25px;
		max-width: none;
	}
	/* Declared as repeat(2, 1fr): a 1fr track floors at max-content, so the
	   longest category label widened the row past the container. */
	body.cm-home .cm-cats__grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

@media (max-width: 600px) {
	body.cm-home .cm-sec {
		padding-block: 32px;
	}
	body.cm-home .cm-sec > .cm-container {
		padding-inline: 16px;
	}
	body.cm-home .cm-sec__title {
		font-size: 21px;
		line-height: 1.26;
	}
	body.cm-home .cm-sec__sub {
		font-size: 14px;
		margin-top: 10px;
	}
	body.cm-home .cm-sec__head {
		margin-bottom: 20px;
	}
	body.cm-home .cm-intent__title {
		font-size: 20px;
	}
	body.cm-home .cm-markets__i {
		padding: 16px;
	}
	body.cm-home .cm-suppliercta__in {
		padding: 22px 20px;
	}
}

/* --------------------------------------------------------------------------
   10. Redesign additions: request band, process flow, market chips
   -------------------------------------------------------------------------- */

/* Main conversion block: copy on the left, three fields on the right. */
body.cm-home .cm-rfq__in {
	display: grid;
	grid-template-columns: minmax(0, 1fr) minmax(0, 520px);
	gap: 48px;
	align-items: center;
}

body.cm-home .cm-rfq__pts {
	list-style: none;
	margin: 20px 0 0;
	padding: 0;
	display: flex;
	flex-wrap: wrap;
	gap: 8px 20px;
}

body.cm-home .cm-rfq__pts li {
	position: relative;
	padding-left: 18px;
	font-size: 13px;
	color: var(--cm-ink-2);
}

body.cm-home .cm-rfq__pts li::before {
	content: "";
	position: absolute;
	left: 0;
	top: 6px;
	width: 6px;
	height: 6px;
	border-radius: 50%;
	background: var(--cm-ink-3);
}

body.cm-home .cm-rfq__form {
	background: var(--cm-card, #fff);
	box-shadow: 0 1px 2px rgba(18, 26, 34, .04);
	border-radius: 8px;
	padding: 24px;
	display: flex;
	flex-direction: column;
	gap: 12px;
}

body.cm-home .cm-rfq__row {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 12px;
}

body.cm-home .cm-rfq__f {
	display: flex;
	flex-direction: column;
	gap: 6px;
}

body.cm-home .cm-rfq__f span {
	font-size: 11px;
	font-weight: 700;
	letter-spacing: .08em;
	text-transform: uppercase;
	color: var(--cm-ink-3);
}

body.cm-home .cm-rfq__f input {
	width: 100%;
	min-height: 44px;
	padding: 10px 12px;
	border: 1px solid #E1E5EA;
	border-radius: 6px;
	background: #fff;
	font-size: 14px;
	color: var(--cm-ink);
}

body.cm-home .cm-rfq__f input::placeholder {
	color: #9AA4B0;
}

body.cm-home .cm-rfq__f input:focus {
	outline: none;
	border-color: var(--cm-ink-2);
	box-shadow: 0 0 0 3px rgba(18, 26, 34, .06);
}

body.cm-home .cm-rfq__go {
	width: 100%;
	margin-top: 4px;
}

body.cm-home .cm-rfq__fine {
	margin: 2px 0 0;
	font-size: 12px;
	line-height: 1.5;
	color: var(--cm-ink-3);
}

/* Process flow: four numbered steps, no cards, no stroke. */
body.cm-home .cm-flow__list {
	list-style: none;
	margin: 0;
	padding: 0;
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 32px;
	counter-reset: none;
}

body.cm-home .cm-flow__i {
	position: relative;
	padding-top: 18px;
	border-top: 1px solid rgba(18, 26, 34, .12);
	display: flex;
	flex-direction: column;
	gap: 6px;
}

body.cm-home .cm-flow__n {
	font-size: 11px;
	font-weight: 700;
	letter-spacing: .1em;
	color: var(--cm-ink-3);
	margin-bottom: 4px;
}

body.cm-home .cm-flow__i strong {
	font-size: 15px;
	font-weight: 650;
	line-height: 1.35;
	color: var(--cm-ink);
}

body.cm-home .cm-flow__i p {
	margin: 0;
	font-size: 13.5px;
	line-height: 1.55;
	color: var(--cm-ink-3);
}

/* Market chips: one line of links instead of a nine-cell grid. */
body.cm-home .cm-markets__row {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px 10px;
}

body.cm-home .cm-markets__label {
	font-size: 11px;
	font-weight: 700;
	letter-spacing: .1em;
	text-transform: uppercase;
	color: var(--cm-ink-3);
	margin-right: 4px;
}

body.cm-home .cm-chip {
	display: inline-flex;
	align-items: center;
	padding: 5px 12px;
	background: var(--cm-card, #fff);
	border-radius: 999px;
	font-size: 13px;
	color: var(--cm-ink-2);
	text-decoration: none;
	transition: background-color .15s ease;
}

body.cm-home .cm-chip:hover {
	background: #EEF0F2;
}

body.cm-home .cm-markets__all {
	margin-left: auto;
	font-size: 13px;
	font-weight: 600;
	color: var(--cm-ink-2);
	text-decoration: none;
}

body.cm-home .cm-markets__all:hover {
	text-decoration: underline;
	text-underline-offset: 3px;
}

@media (max-width: 900px) {
	body.cm-home .cm-rfq__in {
		grid-template-columns: 1fr;
		gap: 24px;
	}
	body.cm-home .cm-flow__list {
		grid-template-columns: 1fr 1fr;
		gap: 22px;
	}
}

@media (max-width: 600px) {
	body.cm-home .cm-rfq__form {
		padding: 18px;
	}
	body.cm-home .cm-rfq__row {
		grid-template-columns: 1fr;
	}
	body.cm-home .cm-flow__list {
		grid-template-columns: 1fr;
		gap: 18px;
	}
	body.cm-home .cm-markets__all {
		margin-left: 0;
	}
}
