/* ==========================================================================
   Hengxin Environmental — base layer
   Tokens, reset, typography, buttons, header, hero, section scaffolding
   ========================================================================== */

:root {
	--ink: #0c1417;
	--ink-2: #121e23;
	--ink-3: #1a2a30;
	--accent: #17b890;
	--accent-dark: #0f8f6f;
	--accent-soft: rgba(23, 184, 144, 0.12);
	--gold: #c9a227;
	--paper: #f5f6f3;
	--paper-2: #eceee9;
	--white: #ffffff;
	--text: #16232a;
	--text-soft: #4d6068;
	--text-dim: #8b9aa1;
	--line: #dde2dc;
	--line-dark: rgba(255, 255, 255, 0.12);

	--font-display: "Barlow", "Helvetica Neue", Arial, sans-serif;
	--font-body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;

	--shell: 1200px;
	--gutter: 24px;
	--radius: 2px;
	--section-y: 104px;

	--ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}

*,
*::before,
*::after {
	box-sizing: border-box;
}

html {
	-webkit-text-size-adjust: 100%;
	scroll-behavior: smooth;
}

body.hx-body {
	margin: 0;
	background: var(--white);
	color: var(--text);
	font-family: var(--font-body);
	font-size: 16px;
	line-height: 1.68;
	-webkit-font-smoothing: antialiased;
	overflow-x: hidden;
}

img,
svg {
	max-width: 100%;
	display: block;
}

a {
	color: inherit;
	text-decoration: none;
	transition: color 0.25s var(--ease);
}

a:hover {
	color: var(--accent);
}

p {
	margin: 0 0 1.1em;
}

ul,
ol {
	margin: 0;
	padding: 0;
	list-style: none;
}

h1,
h2,
h3,
h4,
h5 {
	font-family: var(--font-display);
	font-weight: 600;
	line-height: 1.1;
	margin: 0 0 0.5em;
	color: var(--text);
	letter-spacing: -0.01em;
}

h1 {
	font-size: clamp(2.5rem, 5.4vw, 4.4rem);
	line-height: 1.02;
	text-transform: uppercase;
	letter-spacing: 0.005em;
}

h2 {
	font-size: clamp(1.85rem, 3.3vw, 2.85rem);
	line-height: 1.12;
}

h3 {
	font-size: clamp(1.1rem, 1.6vw, 1.32rem);
	line-height: 1.3;
}

h4 {
	font-size: 1rem;
	line-height: 1.4;
}

.shell {
	width: 100%;
	max-width: var(--shell);
	margin: 0 auto;
	padding: 0 var(--gutter);
}

.shell--narrow {
	max-width: 820px;
}

.sr-only {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

.skip-link {
	position: absolute;
	left: -9999px;
	top: 0;
	z-index: 999;
	background: var(--accent);
	color: var(--ink);
	padding: 10px 18px;
	font-size: 0.8rem;
}

.skip-link:focus {
	left: 12px;
	top: 12px;
}

/* --------------------------------------------------------------------------
   Eyebrow + section heads
   -------------------------------------------------------------------------- */

.eyebrow {
	display: inline-flex;
	align-items: center;
	gap: 12px;
	margin: 0 0 18px;
	font-family: var(--font-body);
	font-size: 0.7rem;
	font-weight: 600;
	letter-spacing: 0.26em;
	text-transform: uppercase;
	color: var(--accent-dark);
}

.eyebrow::before {
	content: "";
	width: 26px;
	height: 1px;
	background: currentColor;
	opacity: 0.7;
}

.section--dark .eyebrow,
.hero .eyebrow {
	color: var(--accent);
}

.section-head {
	max-width: 660px;
	margin-bottom: 52px;
}

.section-head p {
	color: var(--text-soft);
	font-size: 1.02rem;
	margin-bottom: 0;
}

.section-head--center {
	margin-left: auto;
	margin-right: auto;
	text-align: center;
}

.section-head--center .eyebrow::before {
	display: none;
}

/* --------------------------------------------------------------------------
   Buttons
   -------------------------------------------------------------------------- */

.btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	padding: 15px 28px;
	border: 1px solid transparent;
	border-radius: var(--radius);
	font-family: var(--font-body);
	font-size: 0.76rem;
	font-weight: 600;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	cursor: pointer;
	transition: background 0.25s var(--ease), color 0.25s var(--ease), border-color 0.25s var(--ease), transform 0.25s var(--ease);
}

.btn svg {
	flex: none;
}

.btn--sm {
	padding: 11px 20px;
	font-size: 0.7rem;
}

.btn--accent {
	background: var(--accent);
	color: #04201a;
}

.btn--accent:hover {
	background: #1ecf9f;
	color: #04201a;
	transform: translateY(-1px);
}

.btn--ghost {
	border-color: rgba(255, 255, 255, 0.32);
	color: var(--white);
	background: transparent;
}

.btn--ghost:hover {
	border-color: var(--accent);
	color: var(--accent);
}

.btn--outline {
	border-color: var(--ink);
	color: var(--ink);
	background: transparent;
}

.btn--outline:hover {
	background: var(--ink);
	color: var(--white);
}

.btn--line {
	border-color: var(--line);
	color: var(--text);
	background: transparent;
}

.btn--line:hover {
	border-color: var(--ink);
	background: var(--ink);
	color: var(--white);
}

.link-arrow {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	font-size: 0.74rem;
	font-weight: 600;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--text);
}

.link-arrow::after {
	content: "";
	width: 18px;
	height: 1px;
	background: currentColor;
	transition: width 0.25s var(--ease);
}

.link-arrow:hover {
	color: var(--accent-dark);
}

.link-arrow:hover::after {
	width: 28px;
}

/* --------------------------------------------------------------------------
   Header
   -------------------------------------------------------------------------- */

.site-header {
	position: fixed;
	inset: 0 0 auto 0;
	z-index: 100;
	padding: 18px 0;
	background: transparent;
	border-bottom: 1px solid transparent;
	transition: background 0.3s var(--ease), padding 0.3s var(--ease), border-color 0.3s var(--ease);
}

.site-header.is-scrolled,
body:not(.hx-front) .site-header {
	background: rgba(9, 16, 19, 0.96);
	backdrop-filter: blur(10px);
	padding: 12px 0;
	border-bottom-color: rgba(255, 255, 255, 0.08);
}

.site-header__inner {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 28px;
}

.brand {
	display: inline-flex;
	align-items: center;
	gap: 11px;
	color: var(--white);
}

.brand:hover {
	color: var(--white);
}

.brand__mark {
	display: grid;
	place-items: center;
	width: 38px;
	height: 38px;
	border: 1px solid rgba(255, 255, 255, 0.28);
	color: var(--accent);
	flex: none;
}

.brand__text {
	display: flex;
	flex-direction: column;
	line-height: 1;
}

.brand__text strong {
	font-family: var(--font-display);
	font-size: 1.16rem;
	font-weight: 600;
	letter-spacing: 0.16em;
	text-transform: uppercase;
}

.brand__text em {
	font-style: normal;
	font-size: 0.56rem;
	letter-spacing: 0.34em;
	text-transform: uppercase;
	color: var(--accent);
	margin-top: 5px;
}

.site-nav .nav-list {
	display: flex;
	align-items: center;
	gap: 34px;
}

.site-nav .nav-list a {
	position: relative;
	font-size: 0.72rem;
	font-weight: 500;
	letter-spacing: 0.16em;
	text-transform: uppercase;
	color: rgba(255, 255, 255, 0.82);
	padding: 8px 0;
}

.site-nav .nav-list a::after {
	content: "";
	position: absolute;
	left: 0;
	bottom: 0;
	width: 0;
	height: 1px;
	background: var(--accent);
	transition: width 0.25s var(--ease);
}

.site-nav .nav-list a:hover,
.site-nav .nav-list .current-menu-item > a,
.site-nav .nav-list .current_page_item > a {
	color: var(--white);
}

.site-nav .nav-list a:hover::after,
.site-nav .nav-list .current-menu-item > a::after,
.site-nav .nav-list .current_page_item > a::after {
	width: 100%;
}

.site-header__actions {
	display: flex;
	align-items: center;
	gap: 14px;
}

.nav-toggle {
	display: none;
	width: 42px;
	height: 42px;
	padding: 11px 9px;
	background: transparent;
	border: 1px solid rgba(255, 255, 255, 0.24);
	cursor: pointer;
	flex-direction: column;
	justify-content: space-between;
}

.nav-toggle span:not(.sr-only) {
	display: block;
	width: 100%;
	height: 1.5px;
	background: var(--white);
	transition: transform 0.25s var(--ease), opacity 0.2s var(--ease);
}

/* --------------------------------------------------------------------------
   Hero
   -------------------------------------------------------------------------- */

.hero {
	position: relative;
	background: var(--ink);
	color: var(--white);
	padding: 168px 0 96px;
	overflow: hidden;
}

.hero::before {
	content: "";
	position: absolute;
	inset: 0;
	background-image:
		linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px),
		linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px);
	background-size: 84px 84px;
	mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.9), transparent 78%);
	pointer-events: none;
}

.hero::after {
	content: "";
	position: absolute;
	right: -12%;
	top: -30%;
	width: 62%;
	height: 130%;
	background: radial-gradient(circle at 50% 50%, rgba(23, 184, 144, 0.16), transparent 62%);
	pointer-events: none;
}

.hero__grid {
	position: relative;
	z-index: 2;
	display: grid;
	grid-template-columns: 1.05fr 0.95fr;
	gap: 56px;
	align-items: center;
}

.hero h1 {
	color: var(--white);
	margin-bottom: 22px;
}

.hero h1 em {
	font-style: normal;
	color: var(--accent);
}

.hero__lead {
	max-width: 540px;
	font-size: 1.06rem;
	line-height: 1.72;
	color: rgba(255, 255, 255, 0.68);
	margin-bottom: 34px;
}

.hero__actions {
	display: flex;
	flex-wrap: wrap;
	gap: 14px;
	margin-bottom: 44px;
}

.hero__meta {
	display: flex;
	flex-wrap: wrap;
	gap: 34px;
	padding-top: 26px;
	border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.hero__meta div {
	display: flex;
	flex-direction: column;
	gap: 4px;
}

.hero__meta strong {
	font-family: var(--font-display);
	font-size: 1.5rem;
	font-weight: 600;
	color: var(--white);
	line-height: 1;
}

.hero__meta span {
	font-size: 0.66rem;
	letter-spacing: 0.18em;
	text-transform: uppercase;
	color: rgba(255, 255, 255, 0.5);
}

.hero__art {
	position: relative;
	border: 1px solid rgba(255, 255, 255, 0.12);
	background: rgba(255, 255, 255, 0.02);
	padding: 14px;
}

.hero__art svg {
	width: 100%;
	height: auto;
}

.hero__art-cap {
	display: flex;
	justify-content: space-between;
	gap: 12px;
	padding: 12px 4px 2px;
	font-size: 0.62rem;
	letter-spacing: 0.18em;
	text-transform: uppercase;
	color: rgba(255, 255, 255, 0.4);
}

/* --------------------------------------------------------------------------
   Sections
   -------------------------------------------------------------------------- */

.section {
	padding: var(--section-y) 0;
}

.section--paper {
	background: var(--paper);
}

.section--dark {
	background: var(--ink);
	color: rgba(255, 255, 255, 0.72);
}

.section--dark h2,
.section--dark h3,
.section--dark h4 {
	color: var(--white);
}

.section--tight {
	padding-top: 0;
}

.section__foot {
	margin-top: 48px;
	display: flex;
	justify-content: center;
}

/* --------------------------------------------------------------------------
   Reveal animation
   -------------------------------------------------------------------------- */

.reveal {
	opacity: 0;
	transform: translateY(26px);
	transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}

.reveal.is-in {
	opacity: 1;
	transform: none;
}

@media (prefers-reduced-motion: reduce) {
	.reveal {
		opacity: 1;
		transform: none;
		transition: none;
	}
	html {
		scroll-behavior: auto;
	}
}
