/* ============ Reset & Base ============ */
*,
*::before,
*::after {
  box-sizing: border-box;
}

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

body {
  margin: 0;
  background: var(--sand);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.7;
  min-height: 100vh;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 800;
  line-height: 1.2;
  color: var(--dark-green);
  margin: 0;
}

p {
  margin: 0;
}

ul, ol {
  margin: 0;
  padding: 0;
}

ul[class], ol[class] {
  list-style: none;
}

a {
  color: inherit;
  text-decoration: none;
}

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

button {
  font: inherit;
  cursor: pointer;
}

main {
  display: block;
}

::selection {
  background: var(--orange);
  color: #fff;
}

:focus-visible {
  outline: 3px solid var(--orange);
  outline-offset: 3px;
}

/* ============ CSS Variables ============ */
:root {
  --green: #2E6B4F;
  --orange: #E8782B;
  --deep-blue: #1B3B5B;
  --gold: #D4A545;
  --sand: #F5F1E8;
  --dark-green: #1A4D3C;
  --ink: #3A3A3A;
  --light-gray: #E0E0E0;
  --red: #C0392B;
  --link-blue: #3498DB;

  --font-heading: 'Noto Sans SC', 'PingFang SC', 'Microsoft YaHei', sans-serif;
  --font-body: 'Noto Serif SC', 'Source Han Serif SC', 'SimSun', serif;

  --header-height: 64px;
  --radius-lg: 24px;
  --radius-md: 16px;
  --radius-pill: 999px;
  --shadow-sm: 0 4px 16px rgba(46, 107, 79, 0.10);
  --shadow-lg: 0 16px 40px rgba(26, 77, 60, 0.16);
}

/* ============ Utility ============ */
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.container {
  width: min(100% - 2rem, 1200px);
  margin-inline: auto;
}

.site-main {
  min-height: 70vh;
  padding-top: var(--header-height);
  overflow: clip;
}

#main-content {
  scroll-margin-top: calc(var(--header-height) + 1rem);
}

/* ============ Buttons ============ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.625rem 1.25rem;
  border: 2px solid transparent;
  border-radius: var(--radius-md);
  font-family: var(--font-heading);
  font-size: 0.875rem;
  font-weight: 700;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.btn--accent {
  background: var(--orange);
  color: #fff;
}

.btn--accent:hover {
  background: #d3641a;
  transform: translateY(-2px);
}

.btn--ghost {
  background: transparent;
  color: var(--green);
  border-color: currentColor;
}

.btn--ghost:hover {
  background: rgba(46, 107, 79, 0.08);
}

.btn--pill {
  border-radius: var(--radius-pill);
}

.btn--small {
  padding: 0.375rem 0.875rem;
  font-size: 0.75rem;
}

/* ============ Brand ============ */
.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  text-decoration: none;
  flex-shrink: 0;
}

.brand__pulse {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  height: 22px;
}

.brand__pulse i {
  width: 3px;
  border-radius: 3px;
  background: var(--orange);
  height: 8px;
}

.brand__pulse i:nth-child(2) {
  height: 14px;
}

.brand__pulse i:nth-child(3) {
  height: 20px;
}

.brand__text {
  font-family: var(--font-heading);
  font-size: 1.125rem;
  font-weight: 800;
  letter-spacing: 0.01em;
  color: var(--green);
  white-space: nowrap;
}

.brand__text em {
  font-style: normal;
  font-weight: 900;
  color: var(--orange);
}

.brand--invert .brand__text {
  color: #fff;
}

.brand--invert .brand__text em {
  color: var(--gold);
}

.brand--invert .brand__pulse i {
  background: var(--gold);
}

/* ============ Site Header ============ */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: linear-gradient(to bottom, rgba(245, 241, 232, 0.78) 0%, rgba(245, 241, 232, 0) 100%);
  transition: background 0.32s ease, box-shadow 0.32s ease;
}

.site-header.is-scrolled {
  background: var(--green);
  box-shadow: 0 8px 24px rgba(26, 77, 60, 0.18);
}

.site-header__inner {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 1.25rem;
  width: min(100% - 2rem, 1200px);
  margin-inline: auto;
  min-height: var(--header-height);
}

.site-header__deco {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  border-bottom: 1px solid rgba(46, 107, 79, 0.12);
}

.site-header.is-scrolled .site-header__deco {
  border-bottom-color: rgba(255, 255, 255, 0.12);
}

.site-header__deco::before {
  content: '';
  position: absolute;
  right: -8%;
  top: 0;
  width: 26%;
  height: 100%;
  transform: skewX(-18deg);
  background: linear-gradient(to bottom, rgba(232, 120, 43, 0.08), rgba(212, 165, 69, 0.12));
}

.site-header__progress {
  position: absolute;
  left: 0;
  bottom: -2px;
  height: 3px;
  width: 0;
  background: var(--orange);
  border-radius: 0 3px 3px 0;
  z-index: 3;
  transition: width 0.1s linear;
}

.site-header__actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-left: auto;
}

.site-header__login {
  padding: 0.5rem 1.25rem;
}

/* ============ Navigation ============ */
.site-nav {
  margin-left: 0.5rem;
}

.site-nav__list {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.site-nav__link {
  display: block;
  padding: 0.5rem 1rem;
  border-radius: var(--radius-pill);
  font-family: var(--font-heading);
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--green);
  transition: background 0.2s ease, color 0.2s ease;
}

.site-nav__link:hover {
  background: rgba(46, 107, 79, 0.10);
  color: var(--dark-green);
}

.site-nav__link[aria-current="page"] {
  background: var(--orange);
  color: #fff;
}

.site-header.is-scrolled .site-nav__link {
  color: rgba(255, 255, 255, 0.92);
}

.site-header.is-scrolled .site-nav__link:hover {
  background: rgba(255, 255, 255, 0.16);
  color: #fff;
}

.site-header.is-scrolled .site-nav__link[aria-current="page"] {
  background: var(--orange);
  color: #fff;
}

/* ============ Nav Toggle ============ */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 4px;
  width: 40px;
  height: 40px;
  padding: 8px;
  border: none;
  border-radius: var(--radius-md);
  background: transparent;
}

.nav-toggle__line {
  display: block;
  width: 20px;
  height: 2px;
  border-radius: 2px;
  background: var(--green);
  transition: transform 0.3s ease, opacity 0.3s ease, background 0.3s ease;
}

.site-header.is-scrolled .nav-toggle__line {
  background: #fff;
}

.nav-toggle[aria-expanded="true"] .nav-toggle__line:nth-child(1) {
  transform: translateY(6px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] .nav-toggle__line:nth-child(2) {
  opacity: 0;
}

.nav-toggle[aria-expanded="true"] .nav-toggle__line:nth-child(3) {
  transform: translateY(-6px) rotate(-45deg);
}

/* ============ Skip Link ============ */
.skip-link {
  position: absolute;
  left: 1rem;
  top: -4rem;
  z-index: 110;
  background: var(--orange);
  color: #fff;
  padding: 0.75rem 1.25rem;
  border-radius: var(--radius-pill);
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.875rem;
  transition: top 0.2s ease;
}

.skip-link:focus {
  top: 0.75rem;
}

/* ============ Site Footer ============ */
.site-footer {
  margin-top: 4rem;
  background: var(--dark-green);
  color: rgba(255, 255, 255, 0.78);
  border-radius: 28px 28px 0 0;
  overflow: hidden;
  position: relative;
}

.site-footer::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg, rgba(212, 165, 69, 0.10) 0%, transparent 42%);
  pointer-events: none;
}

.site-footer::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--orange), var(--gold), var(--green));
  pointer-events: none;
}

.site-footer__grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.3fr;
  gap: 2.5rem;
  padding: 3.5rem 0 3rem;
}

.site-footer__brand {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1rem;
}

.site-footer__trust {
  font-size: 0.875rem;
  line-height: 1.6;
  max-width: 24rem;
  color: rgba(255, 255, 255, 0.65);
}

.site-footer__col {
  min-width: 0;
}

.site-footer__heading {
  font-family: var(--font-heading);
  font-size: 0.875rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--gold);
  margin-bottom: 0.875rem;
}

.site-footer__list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.site-footer__list a {
  display: inline-block;
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.875rem;
  transition: color 0.2s ease, padding-left 0.2s ease;
}

.site-footer__list a:hover {
  color: #fff;
  padding-left: 0.25rem;
}

.site-footer__contact li {
  font-size: 0.875rem;
  line-height: 1.65;
}

.site-footer__bottom-inner {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.14);
  padding: 1.25rem 0;
}

.site-footer__copyright {
  font-size: 0.8125rem;
  color: rgba(255, 255, 255, 0.6);
}

.site-footer__icp {
  font-size: 0.8125rem;
  color: rgba(255, 255, 255, 0.45);
}

/* ============ Breadcrumbs ============ */
.breadcrumbs {
  padding: 1rem 0;
  font-size: 0.8125rem;
}

.breadcrumbs__list {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.375rem;
}

.breadcrumbs__item {
  display: inline-flex;
  align-items: center;
}

.breadcrumbs__item + .breadcrumbs__item::before {
  content: '/';
  margin-right: 0.375rem;
  color: var(--light-gray);
}

.breadcrumbs__link {
  color: var(--link-blue);
  text-decoration: none;
}

.breadcrumbs__link:hover {
  text-decoration: underline;
}

.breadcrumbs__item[aria-current="page"] {
  color: var(--ink);
}

/* ============ Page Head ============ */
.page-head {
  background:
    radial-gradient(circle at 82% 16%, rgba(212, 165, 69, 0.13), transparent 45%),
    linear-gradient(115deg, var(--sand) 0%, #e5efe7 100%);
  padding: calc(var(--header-height) + 2.5rem) 0 2.25rem;
  border-bottom: 1px solid rgba(46, 107, 79, 0.12);
}

.page-head__title {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 900;
  letter-spacing: -0.02em;
  color: var(--dark-green);
}

.page-head__lead {
  margin-top: 0.5rem;
  font-size: 1.125rem;
  color: var(--green);
  max-width: 42rem;
}

/* ============ Sections ============ */
.section {
  padding: 4.5rem 0;
}

.section--tight {
  padding: 2.5rem 0;
}

.section-eyebrow {
  font-family: var(--font-heading);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--orange);
  margin-bottom: 0.5rem;
}

.section-title {
  font-family: var(--font-heading);
  font-size: clamp(1.5rem, 3.5vw, 2.5rem);
  font-weight: 800;
  line-height: 1.2;
  color: var(--dark-green);
}

.section-lead {
  margin-top: 0.75rem;
  font-size: 1rem;
  line-height: 1.7;
  color: var(--ink);
  max-width: 42rem;
}

/* ============ Grid ============ */
.grid {
  display: grid;
  gap: 1.5rem;
}

.grid--2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.grid--3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.grid--4 {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

/* ============ Card & Panel ============ */
.card {
  background: #fff;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  padding: 1.5rem;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

@media (hover: hover) {
  .card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
  }
}

.panel {
  background: var(--sand);
  border: 1px solid rgba(46, 107, 79, 0.16);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
}

.panel__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  font-family: var(--font-heading);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--orange);
}

.panel__value {
  font-family: var(--font-heading);
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--dark-green);
  margin-top: 0.25rem;
}

.panel__label {
  font-size: 0.875rem;
  color: var(--ink);
  margin-top: 0.375rem;
}

/* ============ Media / Image Container ============ */
.media {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: var(--light-gray);
  aspect-ratio: 16 / 9;
}

.media--portrait {
  aspect-ratio: 4 / 5;
}

.media--square {
  aspect-ratio: 1 / 1;
}

.media--tall {
  aspect-ratio: 3 / 4;
}

/* ============ Scroll Reveal ============ */
[data-reveal] {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

[data-reveal="left"] {
  transform: translateX(-24px);
}

[data-reveal="right"] {
  transform: translateX(24px);
}

[data-reveal].is-revealed {
  opacity: 1;
  transform: translateY(0) translateX(0);
}

/* ============ Responsive ============ */
@media (max-width: 991px) {
  .site-footer__grid {
    grid-template-columns: 1fr 1fr;
  }

  .grid--3,
  .grid--4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 767px) {
  :root {
    --header-height: 56px;
  }

  .site-header__inner {
    gap: 0.625rem;
    width: min(100% - 1.25rem, 1200px);
  }

  .brand__text {
    font-size: 1rem;
  }

  .brand__pulse {
    height: 18px;
  }

  .brand__pulse i:nth-child(3) {
    height: 16px;
  }

  .site-header__login {
    padding: 0.5rem 0.875rem;
    font-size: 0.75rem;
  }

  .nav-toggle {
    display: flex;
  }

  .site-nav {
    position: absolute;
    top: calc(var(--header-height) + 0.5rem);
    left: 1rem;
    right: 1rem;
    z-index: 98;
    background: var(--green);
    border-radius: 20px;
    box-shadow: 0 16px 32px rgba(26, 77, 60, 0.24);
    padding: 0.75rem;
    max-height: calc(100vh - var(--header-height) - 1rem);
    overflow-y: auto;
    visibility: hidden;
    opacity: 0;
    transform: translateY(-8px) scale(0.98);
    transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s ease;
  }

  .site-nav[data-open] {
    visibility: visible;
    opacity: 1;
    transform: translateY(0) scale(1);
  }

  .site-nav__list {
    flex-direction: column;
    align-items: stretch;
    gap: 0.25rem;
  }

  .site-nav__link {
    color: #fff;
    padding: 0.75rem 1rem;
    border-radius: 12px;
    font-size: 1rem;
  }

  .site-nav__link:hover {
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
  }

  .site-nav__link[aria-current="page"] {
    background: var(--orange);
    color: #fff;
  }

  .site-header.is-scrolled .site-nav__link {
    color: #fff;
  }

  .site-header.is-scrolled .site-nav__link:hover {
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
  }

  .site-header.is-scrolled .site-nav__link[aria-current="page"] {
    background: var(--orange);
    color: #fff;
  }

  .site-footer__grid {
    grid-template-columns: 1fr;
    gap: 2rem;
    padding: 2.5rem 0 2rem;
  }

  .site-footer__bottom-inner {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 575px) {
  .grid--2,
  .grid--3,
  .grid--4 {
    grid-template-columns: 1fr;
  }

  .section {
    padding: 3rem 0;
  }

  .site-header__deco::before {
    width: 40%;
  }
}

/* ============ Reduced Motion ============ */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }

  [data-reveal] {
    opacity: 1;
    transform: none;
  }

  .site-header__progress {
    transition: none;
  }
}
