/* ========== 导航栏 ========== */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  padding-block: 28px;
  pointer-events: none;
}
.nav-inner {
  max-width: min(1320px, calc(100% - 56px));
  margin: 0 auto;
  padding-inline: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  pointer-events: auto;
}
.nav-logo {
  display: inline-flex;
  align-items: center;
  color: #2d2f37;
}
.nav-logo-mark {
  width: 92px;
  height: auto;
  fill: currentColor;
}
.nav-right {
  display: flex;
  align-items: center;
  gap: 40px;
}
.nav-links {
  display: flex;
  gap: 24px;
  align-items: center;
}
.nav-links a {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 0;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--color-text-soft);
  transition: color 0.3s var(--ease);
}
.nav-links a:hover {
  color: var(--color-text);
}
.nav-index {
  color: #f0a6c7;
  font-weight: 700;
}

.nav-discovery {
  min-height: 42px;
  padding: 12px 24px;
  border-radius: 0;
  border-color: #2e2f36;
  background: #2e2f36;
  color: #fff;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}
.nav-discovery:hover {
  background: #1f2026;
  border-color: #1f2026;
  color: #fff;
}

@media (max-width: 720px) {
  .nav-links {
    display: none;
  }

  .nav {
    padding-block: 18px;
  }

  .nav-inner {
    max-width: calc(100% - 28px);
  }

  .nav-right .button {
    display: none;
  }
}

/* ========== 第一屏：复刻 Franz Hero ========== */
.hero {
  position: relative;
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 112px 24px 72px;
  overflow: hidden;
  isolation: isolate;
  background: transparent;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0.58));
  z-index: 0;
}

@keyframes pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(91, 140, 0, 0.6);
  }
  70% {
    box-shadow: 0 0 0 10px rgba(91, 140, 0, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(91, 140, 0, 0);
  }
}

.hero-meta {
  position: absolute;
  bottom: 58px;
  z-index: 2;
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.6;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--color-text-mute);
}
.hero-meta--left {
  left: 32px;
}
.hero-meta--right {
  right: 32px;
  text-align: right;
}
.hero-meta-line {
  display: flex;
  align-items: center;
  gap: 10px;
}
.hero-meta-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #7bc27e;
  box-shadow: 0 0 0 0 rgba(91, 140, 0, 0.6);
  animation: pulse 2s infinite;
}

.hero-stage {
  display: none;
}

.hero-content {
  position: relative;
  z-index: 2;
  width: min(640px, calc(100vw - 48px));
  opacity: 1;
}

.hero-copy {
  position: relative;
  z-index: 10;
}

.hero-parallax-wrapper {
  position: absolute;
  left: -31rem;
  bottom: -4rem;
  z-index: 20;
  pointer-events: none;
  mix-blend-mode: hard-light;
}

.hero-parallax-float {
  will-change: transform;
}

.hero-parallax {
  position: relative;
  width: clamp(820px, 62vw, 1060px);
  transform-style: preserve-3d;
  will-change: transform;
  filter: drop-shadow(0 22px 40px rgba(27, 33, 44, 0.1));
}

.hero-portrait {
  display: block;
  width: 100%;
  height: auto;
  object-fit: cover;
  opacity: 0.9;
  filter: saturate(0.86) contrast(0.98) brightness(1.03);
  -webkit-mask-image: linear-gradient(
    to bottom,
    rgba(0, 0, 0, 1) 0%,
    rgba(0, 0, 0, 1) 78%,
    rgba(0, 0, 0, 0.96) 86%,
    rgba(0, 0, 0, 0.7) 92%,
    rgba(0, 0, 0, 0) 100%
  );
  mask-image: linear-gradient(
    to bottom,
    rgba(0, 0, 0, 1) 0%,
    rgba(0, 0, 0, 1) 78%,
    rgba(0, 0, 0, 0.96) 86%,
    rgba(0, 0, 0, 0.7) 92%,
    rgba(0, 0, 0, 0) 100%
  );
}

.hero-portrait-fade {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0));
  pointer-events: none;
}

.hero-text {
  font-size: clamp(18px, 2vw, 28px);
  color: #5b6471;
  letter-spacing: -0.02em;
  text-align: center;
}

.hero-chip {
  position: relative;
  display: inline-block;
  margin-inline: 6px;
  color: #fff;
}

.hero-chip::before {
  content: "";
  position: absolute;
  inset: -0.08em -0.22em;
  background: #f72886;
  transform: skewY(-3deg);
}

.hero-chip span {
  position: relative;
  z-index: 1;
  display: block;
}

.hero-title {
  position: relative;
  z-index: 2;
  margin-top: 16px;
  font-family: var(--font-type);
  font-size: clamp(70px, 15vw, 200px);
  line-height: 0.9;
  letter-spacing: normal;
  color: #2d2f37;
  text-transform: uppercase;
  white-space: nowrap;
  text-align: center;
  overflow: visible;
}

.hero-title-line {
  display: block;
  overflow: visible;
}

.hero-subtitle {
  margin-top: 16px;
  font-size: clamp(18px, 1.75vw, 24px);
  line-height: 1.5;
  color: #596273;
  text-align: center;
  text-shadow: 0 1px 8px rgba(255, 255, 255, 0.8);
}

.hero-actions {
  position: relative;
  z-index: 30;
  margin-top: 48px;
  display: flex;
  justify-content: center;
}

.hero-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: #2d2f37;
  text-shadow: 0 1px 8px rgba(255, 255, 255, 0.8);
}
.hero-link:hover {
  color: var(--color-accent);
}

.hero-scroll-anchor {
  position: absolute;
  bottom: 48px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
}
.hero-scroll-chevron {
  width: 24px;
  height: 24px;
  border-right: 3px solid #23252b;
  border-bottom: 3px solid #23252b;
  transform: rotate(45deg);
  animation: bounceDown 2s ease-in-out infinite;
}

@keyframes bounceDown {
  0%, 100% {
    transform: rotate(45deg) translate(0, 0);
  }
  50% {
    transform: rotate(45deg) translate(8px, 8px);
  }
}

@media (max-width: 960px) {
  .hero {
    padding-top: 132px;
    padding-bottom: 96px;
  }

  .hero-meta {
    position: relative;
    bottom: auto;
    text-align: center;
    margin-top: 18px;
  }

  .hero-meta--left,
  .hero-meta--right {
    left: auto;
    right: auto;
  }

  .hero-content {
    width: min(100%, 720px);
  }

  .hero-parallax-wrapper {
    position: relative;
    left: auto;
    bottom: auto;
    width: fit-content;
    margin: 0 auto 28px;
    mix-blend-mode: normal;
  }

  .hero-parallax {
    width: min(80vw, 560px);
  }

  .hero-title {
    white-space: normal;
  }
}

@media (max-width: 640px) {
  .hero {
    padding-inline: 18px;
  }

  .hero-parallax {
    width: min(94vw, 430px);
  }

  .hero-text {
    font-size: 16px;
  }

  .hero-title {
    font-size: clamp(64px, 20vw, 120px);
  }

  .hero-meta {
    display: none;
  }

  .hero-scroll-anchor {
    bottom: 28px;
  }
}

/* ========== 第二屏：3D 轮播独占（严格对齐原站 img-carousel 源码） ========== */
.carousel-section {
  position: relative;
  width: 100%;
  height: 100vh;
  overflow: hidden;
  background: transparent;
}

/* 与第一屏 .hero::before 一致的半透明白色渐变，
   把 body 的 #dddddd 圆点冲淡，使第二屏观感与第一/三屏统一。
   仅作为背景层（z-index:0），轮播在 z-index:1 之上，互不影响。 */
.carousel-section::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0.58));
  pointer-events: none;
}

/* 对应原站 .img-carousel__wrap */
.carousel-wrap {
  position: relative;
  z-index: 1;
  justify-content: center;
  align-items: center;
  width: 100%;
  height: 100%;
  display: flex;
  cursor: grab;
  user-select: none;
  -webkit-user-select: none;
}
.carousel-wrap:active {
  cursor: grabbing;
}

/* 对应原站 .img-carousel__list
   关键：font-size: 1vw，这样子元素的 em 单位都基于 1vw
   perspective: 90vw，width: 80vw，height: 100vh */
.carousel-list {
  z-index: 1;
  perspective: 90vw;
  perspective-origin: 50%;
  transform-style: preserve-3d;
  justify-content: center;
  align-items: center;
  width: 80vw;
  height: 100vh;
  margin: 0 auto;
  font-size: 1vw;
  display: flex;
  position: relative;
  --carousel-mobile-screen-height: 30em;
  --carousel-desktop-screen-height: 52em;
}

/* 对应原站 .img-carousel__panel
   纯定位载体：无背景/边框/阴影/padding
   left/top: 50% + JS 用 xPercent/yPercent: -50 居中（原站靠 flex static position，跨浏览器不可靠）
   height: 28em = 28vw（基于 list 的 font-size: 1vw） */
.carousel-panel {
  will-change: transform;
  backface-visibility: hidden;
  z-index: 0;
  justify-content: center;
  align-items: center;
  width: auto;
  height: 28em;
  display: flex;
  position: absolute;
  left: 50%;
  top: 50%;
  overflow: visible;
  transform-style: preserve-3d;
}

/* 对应原站 .img-carousel__item */
.carousel-item {
  height: 100%;
  width: auto;
  position: relative;
  overflow: visible;
  transform-style: preserve-3d;
}

/* 对应原站 .img-carousel__screen-group */
.carousel-screen-group {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5em;
  height: 100%;
  transform-style: preserve-3d;
  position: relative;
}

/* 恢复统一的 3D 空间基准，避免左右两侧出现不同层级感 */
.carousel-screen {
  object-fit: contain;
  height: 100%;
  width: auto;
  transform-style: preserve-3d;
  transition: filter 0.3s ease-out;
  transform: translateZ(4em);
  pointer-events: none;
  -webkit-user-drag: none;
}

/* 参考原站：单张桌面图在 3D 空间里略微后退，
   这样左右两侧时不会和手机组三联产生明显“断层” */
.carousel-screen-single-frame {
  /* height: 32em; */
  width: auto;
  border-radius: 15px;
  overflow: hidden;
  transform: translateZ(1.6em);
  transform-style: preserve-3d;
}

.carousel-screen--single {
  transform: none;
  height: 100%;
  width: auto;
  display: block;
}

/* 3 张手机图组 - 左侧：rotateY(-15deg) 往左倾
   iPhone 风格小圆角（约屏幕宽度 8%，手机图上约 24px） */
.carousel-screen--left {
  transform: rotateY(-15deg) translateZ(4em);
  transform-origin: right center;
  border-radius: 24px;
}

/* 3 张手机图组 - 中间：translateZ(4em) 凸出 */
.carousel-screen--center {
  transform: translateZ(4em);
  z-index: 2;
  border-radius: 24px;
}

/* 3 张手机图组 - 右侧：rotateY(15deg) 往右倾 */
.carousel-screen--right {
  transform: rotateY(15deg) translateZ(4em);
  transform-origin: left center;
  border-radius: 24px;
}

.carousel-hint {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--color-text-mute);
  display: flex;
  align-items: center;
  gap: 8px;
  z-index: 5;
  pointer-events: none;
}
.carousel-hint .arrow {
  color: var(--color-accent);
}

.carousel-section-eyebrow {
  position: absolute;
  top: 40px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 5;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--color-text-soft);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  pointer-events: none;
}
.carousel-section-eyebrow .accent {
  color: var(--color-accent);
}

/* 对应原站 mobile：max-width: 800px 时 list zoom: 200% */
@media only screen and (max-width: 800px) {
  .carousel-list {
    zoom: 200%;
  }
  @media (max-height: 400px) {
    .carousel-list {
      zoom: 100%;
    }
  }
}
