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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  position: relative;
  font-family: "Noto Serif SC", "Songti SC", serif;
  font-size: 18px;
  line-height: 1.7;
  background: #000000;
  color: #f5f5f5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1,
h2,
h3,
h4,
h5 {
  font-family: "Montserrat Black", "Montserrat", "Noto Serif SC", "Source Han Serif SC", "Songti SC", sans-serif;
  font-weight: 900;
  line-height: 1.2;
  margin-top: 0;
}

p {
  margin-top: 0;
}

img,
video {
  max-width: 100%;
  height: auto;
}

a {
  color: inherit;
}

:focus-visible {
  outline: 3px solid #d4af37;
  outline-offset: 2px;
}

::selection {
  background: #d4af37;
  color: #000000;
}

/* variables */
:root {
  --dark-green: #0a3d2e;
  --gold: #d4af37;
  --black: #000000;
  --forest: #0f2a20;
  --text-light: #f5f5f5;
  --text-muted: #a8b8b0;
  --emerald: #2e8b57;
  --amber: #ffc107;
  --crimson: #dc143c;
  --gradient-gold-green: linear-gradient(135deg, #d4af37 0%, #0a3d2e 100%);
  --font-display: "Montserrat Black", "Montserrat", "Noto Serif SC", "Source Han Serif SC", "Songti SC", sans-serif;
  --font-body: "Noto Serif SC", "Songti SC", serif;
  --container: 1280px;
  --transition-base: 0.3s ease;
}

/* utilities */
.container {
  width: 100%;
  max-width: var(--container);
  margin-left: auto;
  margin-right: auto;
  padding-left: clamp(16px, 4vw, 40px);
  padding-right: clamp(16px, 4vw, 40px);
}

.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;
}

.text-muted {
  color: var(--text-muted);
}

/* skip link */
.skip-link {
  position: absolute;
  left: 12px;
  top: -56px;
  background: var(--gold);
  color: #000000;
  padding: 10px 18px;
  z-index: 1200;
  font-weight: 700;
  font-size: 14px;
  border-radius: 0 0 8px 8px;
  text-decoration: none;
  transition: top 0.2s ease;
}

.skip-link:focus-visible {
  top: 0;
}

/* scroll progress */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  width: 0;
  background: linear-gradient(90deg, var(--gold), var(--emerald));
  z-index: 1100;
  pointer-events: none;
}

/* buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 18px;
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 900;
  line-height: 1;
  text-decoration: none;
  border-radius: 6px;
  border: 1px solid transparent;
  cursor: pointer;
  white-space: nowrap;
  transition: background-color 0.25s ease, border-color 0.25s ease, transform 0.25s ease, box-shadow 0.25s ease;
}

.btn-primary {
  background: var(--gradient-gold-green);
  color: var(--text-light);
  border-color: rgba(212, 175, 55, 0.55);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(212, 175, 55, 0.22);
}

.btn-ghost {
  background: transparent;
  color: var(--gold);
  border-color: rgba(212, 175, 55, 0.4);
}

.btn-ghost:hover {
  background: rgba(212, 175, 55, 0.08);
  border-color: var(--gold);
}

/* header */
.site-header {
  background: #000000;
  border-bottom: 2px solid var(--dark-green);
  position: relative;
  z-index: 100;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding-top: 18px;
  padding-bottom: 16px;
}

.brand-lockup {
  display: flex;
  flex-direction: column;
  line-height: 1;
  text-decoration: none;
}

.brand-word {
  font-family: var(--font-display);
  font-size: clamp(32px, 5vw, 46px);
  font-weight: 900;
  color: var(--gold);
  letter-spacing: 0.04em;
  line-height: 1;
}

.brand-subtitle {
  font-size: 13px;
  color: var(--text-muted);
  letter-spacing: 0.45em;
  margin-top: 8px;
  line-height: 1;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 0;
  background: transparent;
  border: 1px solid rgba(212, 175, 55, 0.5);
  border-radius: 6px;
  cursor: pointer;
}

.nav-toggle-line {
  display: block;
  width: 20px;
  height: 2px;
  margin: 0 auto;
  background: var(--gold);
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.nav-toggle[aria-expanded="true"] .nav-toggle-line:nth-child(1) {
  transform: translateY(7px) 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(-7px) rotate(-45deg);
}

.nav-scroller {
  background: var(--forest);
  border-top: 1px solid rgba(212, 175, 55, 0.3);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.nav-list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-link {
  display: inline-block;
  padding: 14px 16px;
  color: var(--text-light);
  font-size: 15px;
  font-weight: 600;
  font-family: var(--font-body);
  text-decoration: none;
  position: relative;
  transition: color 0.25s ease;
}

.nav-link::after {
  content: "";
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: 8px;
  height: 2px;
  background: var(--gold);
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 0.3s ease;
}

.nav-link:hover,
.nav-link:focus-visible,
.nav-link[aria-current="page"] {
  color: var(--gold);
}

.nav-link:hover::after,
.nav-link:focus-visible::after,
.nav-link[aria-current="page"]::after {
  transform: scaleX(1);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-left: auto;
}

/* mobile navigation */
@media (max-width: 920px) {
  .header-inner {
    padding-top: 12px;
    padding-bottom: 12px;
  }

  .nav-toggle {
    display: flex;
  }

  .nav-scroller {
    display: none;
    border-top: 1px solid var(--dark-green);
  }

  .nav-scroller[data-open] {
    display: block;
  }

  .nav-inner {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding-top: 8px;
    padding-bottom: 12px;
  }

  .nav-list {
    flex-direction: column;
    align-items: stretch;
  }

  .nav-item {
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  }

  .nav-link {
    display: block;
    padding: 14px 0;
  }

  .nav-link::after {
    left: 0;
    right: auto;
    width: 0;
    bottom: 0;
  }

  .nav-link:hover::after,
  .nav-link:focus-visible::after,
  .nav-link[aria-current="page"]::after {
    width: 100%;
    transform: scaleX(1);
  }

  .header-actions {
    margin-left: 0;
    padding-top: 16px;
  }

  .header-actions .btn {
    flex: 1;
  }
}

/* page shell */
.page-shell {
  min-height: 80vh;
}

/* section heading */
.section-heading {
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: var(--font-display);
  font-size: clamp(22px, 3vw, 28px);
  font-weight: 900;
  line-height: 1.2;
  margin: 0 0 24px;
}

.section-heading::before {
  content: "";
  flex: 0 0 auto;
  width: 8px;
  height: 32px;
  background: var(--gold);
  clip-path: polygon(0 0, 100% 10%, 100% 90%, 0 100%);
}

/* breadcrumb */
.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  list-style: none;
  margin: 0;
  padding: 16px 0;
  font-size: 14px;
  color: var(--text-muted);
}

.breadcrumb li {
  display: flex;
  align-items: center;
  gap: 6px;
}

.breadcrumb li + li::before {
  content: "›";
  color: var(--gold);
  font-weight: 900;
}

.breadcrumb a {
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.2s ease;
}

.breadcrumb a:hover {
  color: var(--gold);
}

.breadcrumb [aria-current="page"] {
  color: var(--text-light);
}

/* card */
.card {
  background: var(--forest);
  border: 1px solid rgba(212, 175, 55, 0.22);
  border-radius: 12px;
  padding: 28px;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 18px 36px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(212, 175, 55, 0.25);
  border-color: rgba(212, 175, 55, 0.5);
}

/* stat value */
.stat-value {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(36px, 6vw, 52px);
  color: var(--gold);
  line-height: 1;
  letter-spacing: 0.02em;
}

/* image placeholder base */
.image-placeholder {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 180px;
  aspect-ratio: 16 / 9;
  background: linear-gradient(135deg, var(--forest), var(--dark-green));
  border: 1px solid rgba(212, 175, 55, 0.28);
  border-radius: 10px;
  overflow: hidden;
}

.image-placeholder::after {
  content: "KAIYUN";
  font-family: var(--font-display);
  font-weight: 900;
  letter-spacing: 0.3em;
  color: rgba(212, 175, 55, 0.35);
  font-size: clamp(18px, 4vw, 32px);
  white-space: nowrap;
}

.image-placeholder.ratio-wide {
  aspect-ratio: 21 / 9;
}

.image-placeholder.ratio-square {
  aspect-ratio: 1 / 1;
}

.image-placeholder.ratio-portrait {
  aspect-ratio: 3 / 4;
}

/* reveal */
.js .reveal {
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.3s ease var(--reveal-delay, 0s), transform 0.3s ease var(--reveal-delay, 0s);
}

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

/* footer */
.site-footer {
  background: #000000;
  border-top: 3px solid var(--dark-green);
  position: relative;
}

.site-footer::before {
  content: "";
  display: block;
  height: 4px;
  background: linear-gradient(135deg, rgba(212, 175, 55, 0.9), rgba(14, 42, 32, 0.9));
}

.footer-top {
  display: grid;
  grid-template-columns: 1.4fr 0.8fr 0.8fr 1.1fr;
  gap: 48px 40px;
  padding-top: 56px;
  padding-bottom: 48px;
}

.footer-brand-word {
  font-family: var(--font-display);
  font-size: 36px;
  font-weight: 900;
  color: var(--gold);
  margin: 0 0 6px;
  line-height: 1;
}

.footer-brand-subtitle {
  margin: 0 0 20px;
  font-size: 13px;
  color: var(--text-muted);
  letter-spacing: 0.4em;
}

.footer-tagline {
  margin: 0 0 16px;
  color: var(--text-light);
  font-size: 16px;
  line-height: 1.6;
}

.footer-trust {
  margin: 0;
  color: var(--text-muted);
  font-size: 14px;
  line-height: 1.7;
}

.footer-heading {
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 900;
  color: var(--gold);
  border-bottom: 1px solid rgba(212, 175, 55, 0.3);
  padding-bottom: 10px;
  margin: 0 0 18px;
}

.footer-column-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.footer-column-list li {
  margin-bottom: 10px;
}

.footer-link {
  color: var(--text-muted);
  font-size: 15px;
  text-decoration: none;
  transition: color 0.2s ease;
}

.footer-link:hover,
.footer-link:focus-visible {
  color: var(--gold);
}

.footer-contact {
  color: var(--text-light);
  font-size: 15px;
  line-height: 1.5;
}

.footer-address {
  color: var(--text-muted);
  font-size: 14px;
  line-height: 1.5;
}

.footer-legal {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  background: #000000;
  padding: 18px 0;
}

.legal-inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  color: var(--text-muted);
}

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

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    transition-delay: 0s !important;
  }

  .js .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

/* responsive footer */
@media (max-width: 1000px) {
  .footer-top {
    grid-template-columns: 1fr 1fr;
    gap: 36px;
  }
}

@media (max-width: 640px) {
  .footer-top {
    grid-template-columns: 1fr;
    padding-top: 40px;
    padding-bottom: 32px;
  }

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