@font-face {
  font-family: "HY LiangPin Xian Cu";
  src: url("./assets/Fonts/HYLiangPinXianCuJ.woff2") format("woff2");
  font-display: swap;
}

@font-face {
  font-family: "HY LiangPin Xian";
  src: url("./assets/Fonts/HYLiangPinXianJ.woff2") format("woff2");
  font-display: swap;
}

@font-face {
  font-family: "HY LeMiaoTi";
  src: url("./assets/Fonts/HYLeMiaoTiJ.woff2") format("woff2");
  font-display: swap;
}

:root {
  --hero-bg-image: url("./assets/hero-bg.png");
  --hero-overlay:
    linear-gradient(180deg, rgba(7, 15, 38, 0.15), rgba(8, 15, 34, 0.15)),
    radial-gradient(circle at 18% 18%, rgba(130, 207, 255, 0.18), transparent 28%),
    radial-gradient(circle at 82% 12%, rgba(114, 129, 255, 0.16), transparent 24%);
  --hero-overscan-top: 0px;
  --hero-overscan-bottom: 0px;
  --hero-text: rgba(255, 255, 255, 0.96);
  --hero-muted: rgba(255, 255, 255, 0.82);
  --glass-bg: rgba(255, 255, 255, 0.08);
  --glass-border: rgba(255, 255, 255, 0.2);
  --glass-hover: rgba(255, 255, 255, 0.14);
  --glass-inner: rgba(255, 255, 255, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  margin: 0;
  padding: 0;
  height: 100%;
  min-height: 100vh;
  min-height: 100svh;
  min-height: 100dvh;
  background-color: #09193f;
}

body {
  position: relative;
  margin: 0;
  padding: 0;
  min-height: 100vh;
  min-height: 100svh;
  min-height: 100dvh;
  font-family:
    "HarmonyOS Sans SC",
    "SF Pro Display",
    "PingFang SC",
    "Segoe UI",
    "Hiragino Sans GB",
    "Microsoft YaHei",
    sans-serif;
  background: #09193f;
  color: var(--hero-text);
  overscroll-behavior: none;
  overflow-x: hidden;
  isolation: isolate;
}

body::before {
  content: "";
  position: fixed;
  top: calc(-1 * var(--hero-overscan-top));
  left: 0;
  right: 0;
  bottom: calc(-1 * var(--hero-overscan-bottom));
  z-index: 0;
  background-image: var(--hero-bg-image);
  background-position: center center;
  background-size: cover;
  background-repeat: no-repeat;
  transform: scale(1.04) translateZ(0);
  transform-origin: center center;
  pointer-events: none;
  animation:
    blur-to-clear 2s cubic-bezier(0.62, 0.21, 0.25, 1) 0s 1 backwards,
    scale-in 1.5s cubic-bezier(0.62, 0.21, 0.25, 1) 0s 1 both;
}

body::after {
  content: "";
  position: fixed;
  top: calc(-1 * var(--hero-overscan-top));
  left: 0;
  right: 0;
  bottom: calc(-1 * var(--hero-overscan-bottom));
  z-index: 1;
  background: var(--hero-overlay);
  pointer-events: none;
}

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

#page-header {
  position: relative;
  width: 100%;
  height: 100vh;
  height: 100svh;
  height: 100dvh;
  min-height: 100vh;
  min-height: 100svh;
  min-height: 100dvh;
  overflow: hidden auto;
  background-color: transparent;
  z-index: 2;
}

.pl-container {
  display: none;
}

#site-info {
  position: relative;
  z-index: 2;
  min-height: 100svh;
  min-height: 100vh;
  min-height: 100dvh;
  width: min(calc(100% - 32px), 1000px);
  margin: 0 auto;
  padding-top: max(28px, env(safe-area-inset-top));
  padding-bottom: max(34px, env(safe-area-inset-bottom));
  padding-left: max(0px, env(safe-area-inset-left));
  padding-right: max(0px, env(safe-area-inset-right));
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  text-shadow: 0 2px 18px rgba(0, 0, 0, 0.22);
  animation: hero-content-in 900ms ease 250ms both;
}

.hero-kicker {
  font-family: "HY LiangPin Xian Cu", "HarmonyOS Sans SC", "PingFang SC", sans-serif;
  margin-bottom: 16px;
  color: var(--hero-muted);
  font-size: 0.86rem;
  text-transform: uppercase;
}

#site-title {
  position: relative;
  width: max-content;
  max-width: 100%;
  margin: 0 auto;
  font-family: "HY LiangPin Xian", "HarmonyOS Sans SC", "PingFang SC", sans-serif;
  font-size: 7.25rem;
  line-height: 1;
  letter-spacing: 0;
  font-weight: 850;
  color: rgba(255, 255, 255, 0);
  animation: show-text 1.5s linear 1s 1 both;
}

#site-title::after {
  content: "";
  position: absolute;
  top: 16px;
  left: 0;
  height: calc(100% - 22px);
  width: 110%;
  border-radius: 14px;
  animation:
    color-change 2s cubic-bezier(0.62, 0.21, 0.25, 1) 1.4s 1 both,
    swipe-box 2s cubic-bezier(0.62, 0.21, 0.25, 1) 1.4s 1 both;
}

#site-subtitle {
  position: relative;
  width: min(100%, 780px);
  margin: 24px auto 0;
  min-height: 58px;
  font-family: "HY LiangPin Xian", "HarmonyOS Sans SC", "PingFang SC", sans-serif;
  font-size: 1.55rem;
  line-height: 1.55;
  color: rgba(255, 255, 255, 0);
  animation: show-text 1.5s linear 1s 1 both;
  text-wrap: balance;
}

#site-subtitle::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  margin: auto;
  width: 0;
  height: 100%;
  border-radius: 12px;
  animation:
    color-change 2s cubic-bezier(0.62, 0.21, 0.25, 1) 1.4s 1 both,
    swipe-box-2 2s cubic-bezier(0.62, 0.21, 0.25, 1) 1.4s 1 both;
}

.typed-cursor {
  display: inline-block;
  width: 0.08em;
  height: 1em;
  margin-left: 0.12em;
  vertical-align: -0.1em;
  background: rgba(255, 255, 255, 0.9);
  animation: typed-blink 0.7s infinite;
}

.hero-description {
  width: min(90%, 42rem);
  margin: 20px auto 0;
  font-family: "HY LiangPin Xian", "HarmonyOS Sans SC", "PingFang SC", sans-serif;
  color: var(--hero-muted);
  line-height: 1.9;
  font-size: 1.05rem;
  text-wrap: balance;
}

.hero-links {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 16px;
  margin-top: 34px;
  animation: hero-links-in 800ms ease 1.35s both;
}

.glass-link {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  contain: paint;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 142px;
  min-height: 52px;
  padding: 0 24px;
  border-radius: 999px;
  color: white;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.04)),
    var(--glass-bg);
  border: 1px solid var(--glass-border);
  backdrop-filter: blur(14px) saturate(1.1);
  -webkit-backdrop-filter: blur(14px) saturate(1.1);
  box-shadow:
    inset 0 1px 0 var(--glass-inner),
    inset 0 -1px 0 rgba(255, 255, 255, 0.04),
    0 10px 28px rgba(0, 0, 0, 0.12);
  font-family: "HY LiangPin Xian", "HarmonyOS Sans SC", "PingFang SC", sans-serif;
  font-size: 1.04rem;
  font-weight: 650;
  transform: translateZ(0);
  -webkit-mask-image: -webkit-radial-gradient(white, black);
  transition:
    transform 200ms ease,
    background 200ms ease,
    border-color 200ms ease,
    box-shadow 200ms ease;
}

.glass-link::before {
  content: "";
  position: absolute;
  inset: 1px;
  z-index: -1;
  border-radius: inherit;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.12), transparent 54%),
    radial-gradient(circle at 28% 18%, rgba(255, 255, 255, 0.12), transparent 32%);
  opacity: 0.46;
  transition: opacity 200ms ease;
  pointer-events: none;
}

.glass-link::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -2;
  border-radius: inherit;
  background: rgba(9, 25, 63, 0.1);
  pointer-events: none;
}

.glass-link:hover {
  transform: translateY(-2px);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0.06)),
    var(--glass-hover);
  border-color: rgba(255, 255, 255, 0.3);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.16),
    inset 0 -1px 0 rgba(255, 255, 255, 0.05),
    0 14px 32px rgba(0, 0, 0, 0.14);
}

.glass-link:hover::before {
  opacity: 1;
}

.glass-link:focus-visible {
  outline: 2px solid rgba(255, 255, 255, 0.8);
  outline-offset: 4px;
}

@keyframes blur-to-clear {
  0% { filter: blur(50px); opacity: 1; }
  100% { filter: blur(0); opacity: 1; }
}

@keyframes scale-in {
  0% { transform: scale(1.2) translateZ(0); opacity: 0; }
  100% { transform: scale(1) translateZ(0); opacity: 1; }
}

@keyframes color-change {
  0% { background: white; }
  100% { background: #2f68ff; }
}

@keyframes swipe-box {
  0% { left: 0; width: 0; }
  50% { left: 0; width: 100%; }
  100% { left: 100%; width: 0; }
}

@keyframes swipe-box-2 {
  0% { left: 0; width: 0; }
  50% { left: 0; width: 72%; }
  100% { left: 0; width: 0; }
}

@keyframes show-text {
  0% {
    color: rgba(255, 255, 255, 0);
    text-shadow: transparent 2px 3px 10px;
  }
  81% { color: rgba(255, 255, 255, 0); }
  100% { color: white; }
}

@keyframes typed-blink {
  50% { opacity: 0; }
}

@keyframes hero-content-in {
  0% {
    opacity: 0;
    transform: translateY(12px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes hero-links-in {
  0% {
    opacity: 0;
    transform: translateY(10px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 860px) {
  :root {
    --hero-overscan-top: 64px;
    --hero-overscan-bottom: 120px;
  }

  #page-header {
    height: 100vh;
    height: 100svh;
    height: 100dvh;
  }

  body::before {
    transform: scale(1.08) translateZ(0);
  }

  #site-info {
    width: min(calc(100% - 24px), 1000px);
  }

  #site-title {
    font-size: 5.25rem;
  }

  #site-title::after {
    top: 11px;
  }
}

@media (max-width: 560px) {
  :root {
    --hero-overscan-top: 84px;
    --hero-overscan-bottom: 156px;
  }

  body::before {
    transform: scale(1.12) translateZ(0);
  }

  #site-subtitle {
    min-height: 88px;
    font-size: 1.22rem;
  }

  .hero-description {
    width: 100%;
    font-size: 1rem;
    margin-top: 14px;
  }

  .hero-links {
    flex-direction: column;
    align-items: stretch;
    width: min(76vw, 340px);
    gap: 14px;
    margin-top: 30px;
  }

  .glass-link {
    width: 100%;
    min-height: 54px;
    font-size: 1.08rem;
  }
}

@supports (-webkit-touch-callout: none) {
  @media (max-width: 860px) {
    :root {
      --hero-overscan-top: 88px;
      --hero-overscan-bottom: 168px;
    }
  }

  @media (max-width: 560px) {
    :root {
      --hero-overscan-top: 108px;
      --hero-overscan-bottom: 220px;
    }
  }
}
