:root {
  --dark: #111;
  --text: #222;
  --muted: #666;
  --line: #e7e7e7;
  --gray: #f7f7f7;
  --white: #fff;
  --accent: #9d3f2f;
  --link: #1f5c99;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--white);
  color: var(--text);
  font-family: "Open Sans", "Helvetica Neue", Arial, "Noto Sans SC", "Microsoft YaHei", sans-serif;
  font-size: 15px;
  line-height: 1.75;
}

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

button {
  font: inherit;
}

.container {
  width: min(1140px, calc(100% - 32px));
  margin: 0 auto;
}

.row {
  display: flex;
  flex-wrap: wrap;
  margin: 0 -15px;
}

.col {
  padding: 0 15px;
}

.text-center {
  text-align: center;
}

.bg-gray {
  background: var(--gray);
}

.pt-100 {
  padding-top: 100px;
}

.pb-100 {
  padding-bottom: 100px;
}

.pb-70 {
  padding-bottom: 70px;
}

.pb-50 {
  padding-bottom: 50px;
}

.pt-50 {
  padding-top: 50px;
}

.navbar {
  position: fixed;
  inset: 0 0 auto;
  z-index: 50;
  padding: 22px 0;
  color: #fff;
  transition: background 180ms ease, padding 180ms ease, color 180ms ease, box-shadow 180ms ease;
}

.navbar.is-solid {
  padding: 12px 0;
  background: rgba(17, 17, 17, 0.94);
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.12);
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  border: 1px solid currentColor;
  border-radius: 50%;
  font-family: Raleway, Arial, sans-serif;
  font-size: 13px;
  font-weight: 800;
}

.navbar-collapse {
  display: flex;
  gap: 22px;
  align-items: center;
}

.navbar-nav {
  display: flex;
  gap: 28px;
  align-items: center;
  margin: 0;
  padding: 0;
  list-style: none;
}

.nav-link {
  position: relative;
  display: block;
  padding: 6px 0;
  color: inherit;
  font-family: Raleway, Arial, sans-serif;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0;
  text-transform: uppercase;
}

.nav-link::after {
  position: absolute;
  right: 0;
  bottom: 2px;
  left: 0;
  height: 1px;
  content: "";
  background: currentColor;
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 160ms ease, transform 160ms ease;
}

.nav-link:hover::after,
.nav-link.active::after {
  opacity: 1;
  transform: translateY(0);
}

.language-toggle {
  display: grid;
  grid-template-columns: repeat(2, auto);
  overflow: hidden;
  border: 1px solid currentColor;
  border-radius: 999px;
}

.language-toggle button {
  min-width: 38px;
  height: 30px;
  border: 0;
  background: transparent;
  color: inherit;
  cursor: pointer;
  font-size: 12px;
  font-weight: 800;
}

.language-toggle button.is-active {
  background: #fff;
  color: #111;
}

.navbar-toggler {
  display: none;
  width: 42px;
  height: 36px;
  padding: 0;
  border: 1px solid currentColor;
  border-radius: 4px;
  background: transparent;
  color: inherit;
}

.navbar-toggler span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 4px auto;
  background: currentColor;
}

.banner {
  position: relative;
  display: block;
  height: 100vh;
  min-height: 680px;
  overflow: hidden;
  color: #fff;
}

.banner-bg {
  position: absolute;
  top: -5%;
  left: -5%;
  width: 110%;
  height: 110%;
  object-fit: cover;
  transform: translate3d(calc(var(--mx, 0) * 1px), calc(var(--my, 0) * 1px), 0) scale(1.02);
  animation: banner-pan 30s ease-in-out infinite alternate;
}

.banner-motion {
  position: absolute;
  inset: 0;
  z-index: 1;
  width: 100%;
  height: 100%;
  opacity: 0.7;
  mix-blend-mode: screen;
  pointer-events: none;
}

.banner-overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  background:
    linear-gradient(90deg, rgba(0, 0, 0, 0.66), rgba(0, 0, 0, 0.28) 55%, rgba(0, 0, 0, 0.48)),
    linear-gradient(180deg, rgba(0, 0, 0, 0.22), rgba(0, 0, 0, 0.66));
}

.banner .container {
  position: relative;
  z-index: 3;
  height: 100%;
}

.banner-caption {
  position: absolute;
  top: 50%;
  left: 15px;
  width: min(930px, calc(100% - 30px));
  transform: translateY(-45%);
}

.banner-caption h1 {
  margin: 0;
  color: #fff;
  font-family: Raleway, Arial, sans-serif;
  font-size: 76px;
  font-weight: 800;
  line-height: 1.14;
  letter-spacing: 0;
}

.headline {
  margin: 28px 0 0;
  max-width: 850px;
  color: #fff;
  font-size: 26px;
  line-height: 1.55;
  overflow-wrap: break-word;
}

.words-wrapper {
  position: relative;
  display: inline-block;
  min-width: 12ch;
  overflow: hidden;
  vertical-align: top;
}

.words-wrapper b {
  display: inline-block;
  white-space: nowrap;
  transition: opacity 280ms ease, transform 280ms ease;
}

.words-wrapper b.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.words-wrapper b.is-changing {
  opacity: 0;
  transform: translateY(10px);
}

.arrow {
  position: absolute;
  bottom: 66px;
  left: 82px;
  z-index: 3;
}

.arrow a {
  display: block;
  width: 30px;
  height: 30px;
  border-right: 6px solid #fff;
  border-bottom: 6px solid #fff;
  transform: rotate(45deg);
}

.heading h2,
.about-heading h2 {
  position: relative;
  margin: 0 0 44px;
  color: var(--text);
  font-family: Raleway, Arial, sans-serif;
  font-size: 34px;
  font-weight: 700;
}

.heading h2::after,
.about-heading h2::after {
  position: absolute;
  bottom: -16px;
  left: 50%;
  width: 54px;
  height: 2px;
  content: "";
  background: var(--accent);
  transform: translateX(-50%);
}

.about-heading h2::after {
  left: 0;
  transform: none;
}

.about-row {
  align-items: center;
}

.about-image-col {
  flex: 0 0 41.666%;
  max-width: 41.666%;
}

.about-content-col {
  flex: 0 0 58.333%;
  max-width: 58.333%;
}

.about-img {
  padding-right: 28px;
}

.portrait-photo {
  display: block;
  width: 100%;
  height: auto;
}

.about-content p {
  margin: 0 0 18px;
  color: #333;
  text-align: justify;
}

.about-actions {
  display: flex;
  gap: 24px;
  align-items: center;
  justify-content: space-between;
  margin-top: 32px;
}

.main-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 28px;
  border: 2px solid var(--accent);
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font-weight: 700;
  transition: background 160ms ease, color 160ms ease;
}

.main-btn:hover {
  background: transparent;
  color: var(--accent);
}

.social-icons {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: flex-end;
}

.social-icons a {
  color: var(--link);
  font-weight: 700;
}

.research-papers {
  display: grid;
  gap: 34px;
}

.research-paper-row {
  display: grid;
  grid-template-columns: minmax(240px, 34%) minmax(0, 1fr);
  gap: 34px;
  align-items: start;
}

.paper-thumbnail {
  overflow: hidden;
}

.paper-visual {
  display: grid;
  min-height: 190px;
  place-items: center;
  background:
    linear-gradient(135deg, rgba(17, 17, 17, 0.82), rgba(157, 63, 47, 0.52)),
    url("assets/hero-research-bg.png") center / cover;
  color: #fff;
  font-family: Raleway, Arial, sans-serif;
  font-size: 24px;
  font-weight: 800;
  text-align: center;
}

.zkml-visual {
  background:
    linear-gradient(135deg, rgba(19, 56, 78, 0.82), rgba(17, 17, 17, 0.52)),
    url("assets/hero-research-bg.png") center / cover;
}

.platform-visual {
  background:
    linear-gradient(135deg, rgba(24, 91, 85, 0.82), rgba(17, 17, 17, 0.52)),
    url("assets/hero-research-bg.png") center / cover;
}

.paper-info heading {
  display: inline;
  color: var(--link);
  font-size: 21px;
  font-weight: 700;
  line-height: 1.35;
}

.paper-info p {
  margin: 8px 0 0;
  color: #333;
}

.paper-info .authors {
  color: var(--muted);
}

.paper-links a {
  color: var(--link);
  font-weight: 700;
}

.publication-button,
.blog-button {
  margin-top: 42px;
}

.portfolio-filter ul {
  display: flex;
  gap: 24px;
  justify-content: center;
  margin: 0 0 34px;
  padding: 0;
  list-style: none;
}

.portfolio-filter li {
  cursor: pointer;
  color: var(--muted);
  font-weight: 700;
}

.portfolio-filter li.sel-item,
.portfolio-filter li:hover {
  color: var(--accent);
}

.portfolio-items {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 28px;
}

.item-content {
  position: relative;
  overflow: hidden;
}

.item-img {
  display: grid;
  min-height: 260px;
  place-items: center;
  background:
    linear-gradient(135deg, rgba(17, 17, 17, 0.68), rgba(157, 63, 47, 0.52)),
    url("assets/hero-research-bg.png") center / cover;
  color: #fff;
  font-family: Raleway, Arial, sans-serif;
  font-size: 28px;
  font-weight: 800;
}

.hainan-card {
  background:
    linear-gradient(135deg, rgba(24, 91, 85, 0.72), rgba(17, 17, 17, 0.5)),
    url("assets/hero-research-bg.png") center / cover;
}

.offshore-card {
  background:
    linear-gradient(135deg, rgba(34, 75, 130, 0.72), rgba(17, 17, 17, 0.5)),
    url("assets/hero-research-bg.png") center / cover;
}

.cinda-card {
  background:
    linear-gradient(135deg, rgba(101, 64, 33, 0.72), rgba(17, 17, 17, 0.5)),
    url("assets/hero-research-bg.png") center / cover;
}

.opc-card {
  background:
    linear-gradient(135deg, rgba(77, 83, 25, 0.72), rgba(17, 17, 17, 0.5)),
    url("assets/hero-research-bg.png") center / cover;
}

.web3-card {
  background:
    linear-gradient(135deg, rgba(36, 70, 112, 0.76), rgba(28, 28, 28, 0.54)),
    url("assets/hero-research-bg.png") center / cover;
}

.prediction-card {
  background:
    linear-gradient(135deg, rgba(111, 41, 83, 0.74), rgba(24, 24, 24, 0.56)),
    url("assets/hero-research-bg.png") center / cover;
}

.item-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 24px;
  background: linear-gradient(180deg, transparent, rgba(0, 0, 0, 0.82));
  color: #fff;
  opacity: 0;
  transition: opacity 180ms ease;
}

.item-content:hover .item-overlay {
  opacity: 1;
}

.item-overlay h6 {
  margin: 0 0 8px;
  font-size: 19px;
}

.item-overlay p {
  margin: 0;
}

.blog-carousel {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 30px;
}

.blog-item {
  background: #fff;
}

.blog-image-link {
  display: block;
}

.blog-img {
  min-height: 210px;
  background:
    linear-gradient(135deg, rgba(17, 17, 17, 0.72), rgba(157, 63, 47, 0.5)),
    url("assets/hero-research-bg.png") center / cover;
}

.iching-blog {
  background:
    linear-gradient(135deg, rgba(17, 17, 17, 0.22), rgba(77, 83, 25, 0.12)),
    url("assets/plog-i-ching.jpg") center / cover;
}

.benchmark-blog {
  background:
    linear-gradient(135deg, rgba(19, 56, 78, 0.18), rgba(17, 17, 17, 0.12)),
    url("assets/plog-matrix.jpg") center / cover;
}

.hainan-blog {
  background:
    linear-gradient(135deg, rgba(0, 0, 0, 0.18), rgba(17, 17, 17, 0.1)),
    url("assets/plog-break-from-within.jpg") center / cover;
}

.blog-content {
  padding: 24px;
}

.blog-content h3 {
  margin: 0 0 12px;
  font-size: 20px;
  line-height: 1.35;
}

.blog-content p {
  margin: 0 0 18px;
  color: var(--muted);
}

.blog-meta {
  display: flex;
  gap: 12px;
  justify-content: space-between;
  color: var(--muted);
  font-size: 13px;
}

.blog-meta a {
  color: var(--link);
  font-weight: 700;
}

#footer {
  color: var(--muted);
}

.copy {
  margin: 0;
}

@keyframes banner-pan {
  from {
    object-position: 40% 48%;
  }

  to {
    object-position: 58% 54%;
  }
}

@media (max-width: 900px) {
  .navbar-toggler {
    z-index: 3;
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin-left: auto;
    background: rgba(0, 0, 0, 0.28);
  }

  .nav-container {
    flex-wrap: wrap;
  }

  .navbar-collapse {
    display: none;
    width: 100%;
    flex-direction: column;
    gap: 16px;
    align-items: flex-start;
    margin-top: 16px;
  }

  .navbar-collapse.is-open {
    display: flex;
  }

  .navbar-nav {
    width: 100%;
    flex-direction: column;
    gap: 10px;
    align-items: flex-start;
  }

  .banner-caption {
    right: auto;
    width: calc(100% - 30px);
  }

  .banner-caption h1 {
    font-size: 64px;
  }

  .headline {
    font-size: 22px;
  }

  .about-image-col,
  .about-content-col {
    flex: 0 0 100%;
    max-width: 100%;
  }

  .about-img {
    max-width: 360px;
    margin: 0 auto 36px;
    padding-right: 0;
  }

  .research-paper-row,
  .portfolio-items,
  .blog-carousel {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 560px) {
  .container {
    width: min(100% - 34px, 1140px);
  }

  .navbar {
    padding: 16px 0;
  }

  .banner {
    min-height: 760px;
  }

  .banner-caption h1 {
    font-size: 48px;
  }

  .headline {
    font-size: 19px;
  }

  .navbar-toggler span {
    margin: 3px auto;
  }

  .arrow {
    left: 34px;
  }

  .pt-100 {
    padding-top: 66px;
  }

  .pb-100 {
    padding-bottom: 66px;
  }

  .about-actions {
    align-items: flex-start;
    flex-direction: column;
  }

  .social-icons {
    justify-content: flex-start;
  }
}

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

  .banner-bg {
    animation: none;
  }

  .banner-motion {
    display: none;
  }
}
