@font-face {
  font-family: 'ZQK';
  src: url('../fonts/ZQK_Scribbled.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
}
/* ========================【新增】加载页样式 ======================== */
.loading-screen {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-color: rgb(249, 229, 142); /* 和门票背景同色 */
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9999999; /* 最顶层 */
  transition: opacity 0.8s ease, visibility 0.8s ease;
}
/* 加载完成隐藏 */
.loading-screen.hidden {
  opacity: 0;
  visibility: hidden;
}
.loading-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
}
/* 你的动图尺寸，可自己改 */
.loading-gif {
  width: 120px;
  height: 120px;
  object-fit: contain;
}
.loading-text {
  font-size: 20px;
  font-family: "ZQK", serif;
  color: #1a1a1a;
  letter-spacing: 1px;
}
/* ======================== 【/新增】加载页样式 ======================== */

/* 你原来的所有 CSS 从这里开始往下不变 */
@import url("https://fonts.googleapis.com/css2?family=Cinzel:wght@500;700&family=Manrope:wght@400;500;700&display=swap");

@font-face {
  font-family: 'kids';
  src: url('../fonts/ButterflyKids-Regular.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
}

@font-face {
  font-family: 'finger';
  src: url('../fonts/FingerPaint-Regular.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
}
@font-face {
  font-family: 'inter';
  src: url('../fonts/Interlope-Regular.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
}

@font-face {
  font-family: 'medieval';
  src: url('../fonts/MedievalSharp.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
}

@font-face {
  font-family: 'waterfall';
  src: url('../fonts/Waterfall-Regular.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
}

@font-face {
  font-family: 'ZQK';
  src: url('../fonts/ZQK_Scribbled.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
}

:root {
  --bg-color: #d1cfc7;
  --paper-color: #fcfcfb;
  --ink-color: #1a1a1a;
  --accent-color: #e63946;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background-color: var(--bg-color);
  font-family: "Manrope", sans-serif;
  color: var(--ink-color);
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)' opacity='0.05'/%3E%3C/svg%3E");
  transition: background-color 1s ease;
}

.ambient-light {
  position: absolute;
  width: 50vw;
  height: 50vh;
  background: radial-gradient(
    circle,
    rgba(255, 255, 255, 0.4) 0%,
    transparent 60%
  );
  z-index: 0;
  pointer-events: none;
}

/* ========= 门票指向提示（第一个场景专用） ========= */
.ticket-guide {
  position: absolute;
  top: 15%;
  left: 50%;
  transform: translateX(-50%);
  text-align: center;
  z-index: 99999999;
  pointer-events: none;
  white-space: nowrap;
}

.ticket-guide p {
  font-size: 24px;
  font-family: "Cinzel", serif;
  color: #ffffff;
  font-weight: bold;
  margin-bottom: 12px;
  text-shadow: 0 2px 10px rgba(0,0,0,0.3);
}

/* 白色向下箭头 */
.arrow-down {
  width: 0;
  height: 0;
  border-left: 28px solid transparent;
  border-right: 28px solid transparent;
  border-top: 38px solid #ffffff;
  margin: 0 auto;
  animation: bounce 1.2s infinite ease-in-out;
  filter: drop-shadow(0 2px 6px rgba(0,0,0,0.2));
}

/* 箭头跳动动画 */
@keyframes bounce {
  0%, 100% { transform: translateY(0); }
  50%  { transform: translateY(12px); }
}

/* =========================================
   The Ticket Wrapper & Shadow Magic
   ========================================= */
.ticket-container {
  position: relative;
  z-index: 10;
  display: flex;
  gap: 0px;
  filter: drop-shadow(0 25px 45px rgba(0, 0, 0, 0.15))
    drop-shadow(0 4px 10px rgba(0, 0, 0, 0.05));
  transition: gap 0.6s cubic-bezier(0.34, 1.56, 0.64, 1), transform 0.4s ease;
  cursor: grab;
}

/* 🔥 修复：hover 后永久保持裂开，不再回弹合上 */
.ticket-container:hover,
.ticket-container.hold-open {
  gap: 24px;
  transform: translateY(-5px) scale(1.02);
}

.ticket-container:active {
  cursor: grabbing;
}

/* =========================================
   Main Ticket Anatomy
   ========================================= */
.ticket-main {
  position: relative;
  width: 380px;
  height: 270px;
  background: var(--paper-color);
  padding: 32px;
  border-radius: 24px 36px 36px 24px;

  @supports (corner-shape: bevel) {
    corner-shape: squircle scoop scoop squircle;
  }
}

.ticket-content {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 100%;
}

.ticket-header {
  display: flex;
  justify-content: space-between;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: #888;
}

.serial {
  color: var(--accent-color);
}

.title {
  font-family: "Cinzel", serif;
  font-size: 2.8rem;
  line-height: 1;
  font-weight: 700;
  letter-spacing: -1px;
  margin: 16px 0 8px;
}

.subtitle {
  font-size: 0.9rem;
  letter-spacing: 1px;
  color: #666;
}

.ticket-footer {
  display: flex;
  gap: 40px;
  border-top: 1px solid rgba(0, 0, 0, 0.1);
  padding-top: 16px;
}

.info-block {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.info-block .label {
  font-size: 0.65rem;
  color: #888;
  text-transform: uppercase;
  letter-spacing: 1px;
}
.info-block .value {
  font-size: 0.9rem;
  font-weight: 700;
}

.perforation-line {
  position: absolute;
  right: -2px;
  top: 40px;
  bottom: 40px;
  width: 4px;
  background-image: linear-gradient(
    to bottom,
    transparent 50%,
    rgba(0, 0, 0, 0.15) 50%
  );
  background-size: 100% 12px;
  transition: opacity 0.3s ease;
}

.ticket-container:hover .perforation-line {
  opacity: 0;
}

/* =========================================
   The Tear-Away Stub
   ========================================= */
.ticket-stub {
  position: relative;
  width: 140px;
  height: 270px;
  background: var(--paper-color);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 28px;
  padding: 32px 0;
  border-radius: 36px 24px 24px 36px;

  @supports (corner-shape: bevel) {
    corner-shape: scoop squircle squircle scoop;
  }
}

/* =========================================
   The Holographic Star Seal
   ========================================= */
.foil-seal {
  min-width: 48px;
  min-height: 48px;
  border-radius: 50%;

  @supports (corner-shape: bevel) {
    corner-shape: notch;
  }

  background: linear-gradient(
    135deg,
    #e0e0e0,
    #ffffff 40%,
    #a8a8a8 60%,
    #e0e0e0
  );
  background-size: 200% 200%;
  animation: shimmer 3s infinite linear;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

@keyframes shimmer {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}

/* Procedural Barcode - Fixed to draw vertically without transforms */
.barcode {
  width: 40px;
  height: 90px;
  background: repeating-linear-gradient(
    90deg,
    var(--ink-color),
    var(--ink-color) 2px,
    transparent 2px,
    transparent 4px,
    var(--ink-color) 4px,
    var(--ink-color) 5px,
    transparent 5px,
    transparent 8px
  );
  opacity: 0.8;
}

.stub-text {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 3px;
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  color: var(--accent-color);
}

/* =========================================
   整体退场动画
   ========================================= */
.exhibition-wrapper.fade-out {
  animation: allFadeUp 1.4s cubic-bezier(0.32, 1, 0.62, 1) forwards;
  pointer-events: none;
}
@keyframes allFadeUp {
  0% {
    opacity: 1;
    transform: translateY(0);
  }
  100% {
    opacity: 0;
    transform: translateY(-120px);
  }
}

body.fade-to-dark {
  background-color: #1a1a1a;
}

/* =========================================
   ✅ 天空 + 云朵样式（已完美整合）
   ========================================= */
.sky {
  width: 100vw;
  height: 100vh;
  position: fixed;
  top: 0;
  left: 0;
  overflow: hidden;
  background: #63adf2;
  opacity: 0;
  visibility: hidden;
  z-index: 1;
}

.sky {
  transition: opacity 1.2s ease; /* 加这一行 */
}

.sky.show {
  opacity: 1;
  visibility: visible;
}

/* 背景渐变 + 天空整体向上 */
.sky.fade-to-light {
  background: linear-gradient(to bottom, #63adf2 0%, #a8d8ff 100%);
  transition: background 2s ease;
}

/* 文字：向上淡出 */
.sky-center-text {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-family: "ZQK", serif;
  font-size: 6rem;
  line-height: 1;
  font-weight: 700;
  letter-spacing: -1px;
  color: #fff;
  white-space: nowrap;
  z-index: 10;
  opacity: 1;
  transition: all 2s cubic-bezier(0.2, 0.6, 0.2, 0.95);
}
.sky.fade-to-light .sky-center-text {
  opacity: 0;
  transform: translate(-50%, -140px);
}

/* 🔥 云朵：独立向上淡出，不影响飘动，不跳变 */
.cloud svg {
  transition: all 2s cubic-bezier(0.2, 0.6, 0.2, 0.95) !important;
}
.sky.fade-to-light .cloud svg {
  transform: translateY(-140px) !important;
  opacity: 0 !important;
}
/* =========================================
   星露谷官网（原版结构 + 清空内容 + 纯色底部）
========================================= */
@import url('https://fonts.googleapis.com/css2?family=Kelly+Slab&display=swap');

.final-scene {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  overflow-y: auto;
  background: #eddbad;
  z-index: 0;
  opacity: 0;
  visibility: hidden;
  transition: opacity 2.5s ease;
}
.final-scene.show {
  opacity: 1;
  visibility: visible;
  z-index: 100;
}

* {
    margin: 0;
    padding: 0;
    -webkit-box-sizing: border-box;
            box-sizing: border-box;
}
h1, h2, button {
    font-family: 'Kelly Slab', cursive;
    color: #441600;
}
h1 { font-size: 2.5rem; }
h2 { font-size: 1.7rem; }
label, p, a, select, input, textarea, span, legend {
    font-family: 'Kelly Slab', cursive;
    font-size: .9rem;
    color: #441600;
}
a { text-decoration: none; }
.input-style {
    width: 100%;
    padding: 5px;
    background-color: #FEFBCC;
    border: 3px outset #D57A05;
    border-radius: 5px;
    -webkit-box-shadow: -3px 3px 1px rgba(0, 0, 0, .2);
            box-shadow: -3px 3px 1px rgba(0, 0, 0, .2);
    margin-top: 3px;
    margin-bottom: 15px;
}
input:focus, textarea:focus { outline: none !important; }
.d-flex { display: -webkit-box; display: -ms-flexbox; display: flex; }
.justify-center { -webkit-box-pack: center; -ms-flex-pack: center; justify-content: center; }
.justify-between { -webkit-box-pack: justify; -ms-flex-pack: justify; justify-content: space-between; }
.align-center { -webkit-box-align: center; -ms-flex-align: center; align-items: center; }
.flex-col { -webkit-box-orient: vertical; -webkit-box-direction: normal; -ms-flex-direction: column; flex-direction: column; }
.flex-wrap { -ms-flex-wrap: wrap; flex-wrap: wrap; }
.w-100 { width: 100%; }
.mb-20 { margin-bottom: 20px; }

body {
  background-color: #FAE58D;
  min-height: 100vh;
  overflow-x: hidden;
}
main {
    height: 100%;
    overflow-x: hidden;
    overflow-y: visible;
}

/* Header */
header {
    z-index: 9999;
    position: fixed;
    top: 0;
    padding: 30px;
}
.logo-icon, .menu-icon {
    height: 40px;
    cursor: pointer;
}
.dropdown-nav {
    position: fixed;
    top: 77px;
    right: 30px;
    width: 200px;
    height: 60px;
    border: 10px solid #eddbad;
    border-radius: 10px;
    border-image: url(https://res.cloudinary.com/dqfgwgif9/image/upload/v1645661048/stardew-valley/border.png) 20 stretch;
    background-color: #eddbad;
    transition: height 300ms, opacity 300ms ease-in-out;
    overflow: hidden;
}
.dropdown-nav img { width: 30px; margin-right: 15px; }
.dropdown-nav a {
    font-size: 1.1rem;
    padding: 10px 12px;
    display: flex;
    align-items: center;
    text-shadow: 0px 2px 1px #d5864f;
}
.closed { height: 0; opacity: 0; visibility: hidden; }

/* Hero */
#hero {
    position: relative;
    width: 100vw;
    height: 110vh;
    min-height: 760px;
}

.hero-bg {
  z-index: -10 !important;
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 100vh;
  min-height: 700px;
  overflow: hidden;

  /* ========== 静态背景配置 ========== */
  background-image: url("../image/sky2.png"); /* 换成你静态图路径 */
  background-size: cover;       /* 铺满全屏 */
  background-position: center;  /* 居中 */
  background-repeat: no-repeat; /* 不重复平铺 */
}
/* .hero-bg {
  z-index: -10 !important;
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 100vh;
  min-height: 700px;
  overflow: hidden;
} */

/* ------------------------------
   核心：两张图叠在一起，同步滚动
------------------------------ */
/* .hero-bg::before,
.hero-bg::after {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-size: auto 100%;
  background-repeat: repeat-x;
  animation: bgScroll 90s linear infinite;
}

/* 图 1 */
/* .hero-bg::before {
  background-image: url("../image/background_ani_1.png");
  animation: bgScroll 300s linear infinite, flash1 0.5s step-end infinite;
} */

/* 图 2 */
/* .hero-bg::after {
  background-image: url("../image/background_ani_2.png");
  animation: bgScroll 300s linear infinite, flash2 0.5s step-end infinite;
} */

/* @keyframes bgScroll {
  0% { background-position: 0 center; }
  100% { background-position: -20000px center; }
} */

/* @keyframes flash1 {
  0%, 50%  { opacity: 1; }
  50.1%, 100% { opacity: 0; }
} */
/* @keyframes flash2 {
  0%, 50%  { opacity: 0; }
  50.1%, 100% { opacity: 1; }
}  */

#hero .hero-img {
    position: absolute;
    z-index: 2;
    bottom: 130px;
    left: 50%;
    transform: translateX(-50%);
    width: 100% !important;
    height: auto !important;
    max-height: 100% !important;
    object-fit: contain !important;
    object-position: center bottom !important;
}

#locations, #villagers, #map, .border, #contact {
  background: #eddbad;
  position: relative;
  z-index: 1;
}

/* ========= 底部纯色框（原版样式 100% 还原）========= */
#footerStyle {
    background-color: #65b3ff;
    padding: 30px 50px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}
#footerStyle > div > div > a > img { height: 30px; margin: 0 3px; }
#footerStyle > div > img:nth-child(1) { width: 170px; }
#footerStyle > div > img:nth-child(2) { width: 250px; }

@media only screen and (min-width: 1015px) {
    #footerStyle {
        flex-direction: row;
        justify-content: space-between;
    }
}

.page-title {
  position: absolute !important;
  top: 50% !important;
  left: 50% !important;
  width: 100% !important;
  transform: translate(-50%, -50%) !important;

  text-align: center !important;
  font-size: 200px !important;
  font-family: "ZQK", serif !important;
  font-weight: 900 !important;
  color: #FFFFFF !important;
  text-shadow:
    2px 2px 0 #333333,
   -2px 2px 0 #333333,
    2px -2px 0 #333333,
   -2px -2px 0 #333333;
  z-index: 99999999 !important;
  pointer-events: none !important;
}

/* ========== PORTFOLIO CONTENT - PIXEL STYLE ========== */
.portfolio-pixel {
  max-width: 1000px;
  margin: 120px auto 60px;
  padding: 0 20px;
  font-family: 'Kelly Slab', cursive;
  color: #441600;
  line-height: 1.6;
  position: relative !important;
  z-index: 2 !important;
}
.pixel-header {
  text-align: center;
  margin-bottom: 40px;
}
.pixel-header h1 {
  font-size: 2rem;
  color: #b4652c;
  margin-bottom: 8px;
  text-shadow: 2px 2px 0 #e4c49c;
}
.pixel-header p {
  font-size: 1rem;
  color: #7d4c2a;
}

/* 快速导航栏 */
.portfolio-nav {
  position: sticky;
  top: 20px;
  z-index: 100;
  display: flex;
  flex-wrap: nowrap;
  justify-content: center;
  gap: 4px;
  margin: 24px 0 40px;
  padding: 10px 16px;
  background: #f9f0dc;
  border: 3px outset #d4a373;
  border-radius: 8px;
  box-shadow: 3px 3px 0 rgba(0,0,0,0.1);
  overflow-x: auto;
  scrollbar-width: thin;
}
.portfolio-nav::-webkit-scrollbar {
  height: 6px;
}
.portfolio-nav::-webkit-scrollbar-thumb {
  background: #d4a373;
  border-radius: 3px;
}
.portfolio-nav .nav-item {
  flex-shrink: 0;
  display: inline-block;
  padding: 6px 14px;
  background: linear-gradient(to bottom, #fffbeb, #f5e6c8);
  border: 2px solid #d4a373;
  border-radius: 4px;
  font-family: 'Kelly Slab', cursive;
  font-size: 0.85rem;
  color: #441600;
  text-decoration: none;
  transition: all 0.15s ease;
  box-shadow: 2px 2px 0 rgba(0,0,0,0.1);
  white-space: nowrap;
}
.portfolio-nav .nav-item:hover {
  background: linear-gradient(to bottom, #fde68a, #facc15);
  transform: translateY(-2px);
  box-shadow: 3px 4px 0 rgba(0,0,0,0.15);
}
.portfolio-nav .nav-item:active {
  transform: translateY(0);
  box-shadow: 1px 1px 0 rgba(0,0,0,0.1);
}
@media (max-width: 768px) {
  .portfolio-nav {
    padding: 8px 12px;
  }
  .portfolio-nav .nav-item {
    font-size: 0.75rem;
    padding: 4px 10px;
  }
}

/* 卡片整体 */
.portfolio-section {
  margin-bottom: 50px;
}
.pixel-card {
  background: #fffbeb;
  border: 4px outset #d57a05;
  border-radius: 16px;
  padding: 28px;
  box-shadow: 6px 6px 0 rgba(0,0,0,0.15);
}
.pixel-title {
  font-size: 1.6rem;
  color: #b4652c;
  margin-bottom: 16px;
  border-bottom: 3px solid #d4a373;
  padding-bottom: 8px;
  display: inline-block;
}
.pixel-subtitle {
  font-size: 1.1rem;
  color: #8b522a;
  margin: 1.2rem 0 0.6rem;
  font-weight: bold;
}

/* 文本 */
.why-text {
  background: #f9f0dc;
  padding: 16px;
  border-radius: 12px;
  border: 2px solid #e4c49c;
}

/* 网格布局 */
.gap-grid,
.persona-row,
.evidence-grid,
.sketch-row {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin: 16px 0;
}
.paper-item,
.product-item,
.persona-card,
.alt-card {
  flex: 1;
  min-width: 260px;
  background: #f9f0dc;
  border: 2px solid #d4a373;
  border-radius: 12px;
  padding: 14px;
  box-shadow: 3px 3px 0 rgba(0,0,0,0.1);
}

/* 产品项特殊样式 - 确保整齐排列 */
.product-item {
  min-width: 280px;
  flex: 1 1 calc(50% - 16px);
}

/* 学术论文卡片特殊样式 */
.paper-item {
  min-width: 280px;
  flex: 1 1 calc(50% - 16px);
}

@media (max-width: 600px) {
  .paper-item,
  .product-item {
    flex: 1 1 100%;
  }
}
.persona-card h3 {
  margin-bottom: 6px;
}

/* 引用样式 */
.citation-mini {
  margin-top: 0.75rem;
  font-size: 0.75rem;
  border-top: 1px dashed #e4c49c;
  padding-top: 0.5rem;
}
.citation-mini a {
  color: #0366d6;
  text-decoration: none;
  word-break: break-all;
}
.citation-mini a:hover {
  text-decoration: underline;
}

/* 用户旅程图 */
.journey-pixel {
  background: #f9f0dc;
  border: 2px solid #d4a373;
  border-radius: 12px;
  padding: 16px;
  font-size: 0.9rem;
  line-height: 1.8;
}

/* 需求列表 */
.requirements-list ul {
  list-style: none;
  padding-left: 0;
}
.requirements-list ul li {
  background: #f9f0dc;
  border: 2px solid #d4a373;
  border-radius: 10px;
  padding: 12px 16px;
  margin-bottom: 12px;
  box-shadow: 2px 2px 0 rgba(0,0,0,0.1);
}

/* 标签 */
.badge-good,
.badge-miss {
  display: inline-block;
  padding: 3px 8px;
  border-radius: 6px;
  font-size: 0.85rem;
  margin: 2px 0;
}
.badge-good {
  background: #d1fae5;
  color: #065f46;
  border: 1px solid #10b981;
}
.badge-miss {
  background: #fee2e2;
  color: #991b1b;
  border: 1px solid #ef4444;
}

/* 图片网格 */
.evidence-grid,
.sketch-row {
  justify-content: center;
  gap: 12px;
}
.evidence-item img,
.sketch-row img {
  transition: transform 0.2s ease;
}
.evidence-item img:hover,
.sketch-row img:hover {
  transform: scale(1.05);
}

/* 按钮 */
.btn-pixel {
  background: #facc15;
  border: 3px outset #d97706;
  border-radius: 10px;
  padding: 10px 18px;
  font-family: 'Kelly Slab', cursive;
  font-size: 1rem;
  color: #441600;
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
  display: inline-block;
}
.btn-pixel:hover {
  background: #fde047;
  transform: translateY(-2px);
}

/* Figma 嵌入容器 */
.figma-embed-container {
  background: #f9f0dc;
  border: 2px solid #d4a373;
  border-radius: 16px;
  padding: 8px;
  margin: 16px 0;
  box-shadow: 4px 4px 0 rgba(0,0,0,0.1);
}

/* 架构图 */
.arch-img-wrapper {
  margin: 16px 0;
  text-align: center;
  
}

/* 架构图图片样式：你可以自由改大小 */
.arch-img {
  max-width: 100%;
  width: 50%;      /* 👈 你想改多大就改这里 */
  height: auto;
  border-radius: 8px;
  border: 3px solid #d4a373;
  cursor: pointer;   /* 鼠标放上去变小手 */
  transition: transform 0.2s;
}

/*  hover 轻微放大 */
.arch-img:hover {
  transform: scale(1.02);
}
/* 表格 */
.contrib-table {
  width: 100%;
  border-collapse: collapse;
  background: #fffbeb;
  margin: 16px 0;
  border-radius: 10px;
  overflow: hidden;
  border: 2px solid #d4a373;
}
.contrib-table th,
.contrib-table td {
  padding: 10px 12px;
  border: 1px solid #e4c49c;
  text-align: center;
}
.contrib-table th {
  background: #f9d59b;
}
@media (max-width: 768px) {
  .contrib-table {
    font-size: 0.8rem;
  }
  .contrib-table th,
  .contrib-table td {
    padding: 6px 8px;
  }
}

/* 底部 */
.portfolio-pixel footer {
  text-align: center;
  margin-top: 60px;
  padding: 20px;
  font-size: 0.95rem;
  color: #8b522a;
  border-top: 2px solid #d4a373;
}

/* 1. 修复门票居中 */
.exhibition-wrapper {
  width: 100vw;
  height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  position: fixed;
  top: 0;
  left: 0;

  overflow: visible !important;
}

/* 2. 修复最后场景：恢复纯色背景，关闭动画背景 */
.bg-mask {
  position: absolute;
  top: 85vh;
  left: 0;
  width: 100vw;
  height: 1225vh;
  background: rgb(255,241,210);
  z-index: 0;
  pointer-events: none;
}
/* 3. 底部 footer 只在最后场景显示，不会跑到第一页 */
#footerStyle {
  position: relative;
  z-index: 10;
}

.last_title {
  text-align: left !important;
  font-size: 100px !important;
  font-family: "ZQK", serif !important;
  font-weight: 900 !important;
  color: #FFFFFF !important;
  text-shadow:
    1px 1px 0 #333333,
   -1px 1px 0 #333333,
    1px -1px 0 #333333,
   -1px -1px 0 #333333;
  z-index: 99999999 !important;
  pointer-events: none !important;
  text-transform: none !important;
}

/* ============================== */
/* 左侧滚动进度条样式 - 移动端适配 */
/* ============================== */
.scroll-progress-bar {
  position: fixed;
  left: 0;
  top: 0;
  width: 6px;
  height: 100vh;
  background: rgba(0, 0, 0, 0.1);
  z-index: 99999;
  cursor: pointer;
  transition: width 0.3s ease;
}

.scroll-progress-bar:hover {
  width: 12px;
}

.scroll-progress-fill {
  width: 100%;
  height: 0%;
  background: linear-gradient(to bottom, #b4652c, #f59e0b, #b4652c);
  transition: height 0.1s ease-out;
  border-radius: 0 0 4px 0;
  box-shadow: 0 0 10px rgba(181, 102, 44, 0.5);
}

.scroll-progress-tooltip {
  position: fixed;
  left: 20px;
  top: 50%;
  transform: translateY(-50%) rotate(-90deg);
  background: #b4652c;
  color: #fff;
  padding: 6px 12px;
  border-radius: 6px;
  font-family: 'Kelly Slab', cursive;
  font-size: 0.8rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease, left 0.3s ease;
  white-space: nowrap;
  box-shadow: 2px 2px 8px rgba(0, 0, 0, 0.2);
}

.scroll-progress-bar:hover .scroll-progress-tooltip {
  opacity: 1;
}

/* ================================ */
/* 响应式设计 - 移动端全面适配 */
/* ================================ */

/* 基础移动端设置 */
@media (max-width: 768px) {
  html {
    font-size: 14px;
  }
  
  /* 修复 body 样式冲突 */
  body {
    overflow-x: hidden;
    overflow-y: auto;
  }
  
  /* 修复 exhibition-wrapper 移动端 */
  .exhibition-wrapper {
    width: 100vw;
    height: 100vh;
    height: 100dvh; /* 动态视口高度 */
    overflow: hidden;
    position: fixed;
    top: 0;
    left: 0;
    display: flex;
    justify-content: center;
    align-items: center;
  }
  
  /* 门票容器移动端适配 */
  .ticket-container {
    flex-direction: column;
    gap: 0;
    align-items: center;
    max-width: 100%;
    padding: 10px;
  }
  
  .ticket-main {
    width: 90vw;
    max-width: 300px;
    height: auto;
    min-height: 180px;
    padding: 20px;
    border-radius: 24px 24px 0 0;
  }
  
  .ticket-stub {
    width: 90vw;
    max-width: 300px;
    height: auto;
    min-height: 80px;
    flex-direction: row;
    padding: 16px;
    border-radius: 0 0 24px 24px;
  }
  
  .perforation-line {
    display: none;
  }
  
  .ticket-container:hover,
  .ticket-container.hold-open {
    gap: 0;
    transform: translateY(-5px) scale(1.02);
  }
  
  /* 门票内容 */
  .title {
    font-size: 1.6rem;
  }
  
  .ticket-footer {
    gap: 12px;
    flex-wrap: wrap;
  }
  
  .info-block .label {
    font-size: 0.6rem;
  }
  
  .info-block .value {
    font-size: 0.8rem;
  }
  
  .foil-seal {
    min-width: 32px;
    min-height: 32px;
  }
  
  .barcode {
    width: 24px;
    height: 40px;
  }
  
  .stub-text {
    font-size: 0.6rem;
    letter-spacing: 1px;
    writing-mode: horizontal-tb;
    transform: none;
  }
  
  /* 引导提示 */
  .ticket-guide {
    top: 8%;
  }
  
  .ticket-guide p {
    font-size: 16px;
  }
  
  .arrow-down {
    border-left-width: 18px;
    border-right-width: 18px;
    border-top-width: 26px;
  }
  
  /* 天空文字 */
  .sky-center-text {
    font-size: 2.5rem;
    padding: 0 20px;
    text-align: center;
    white-space: normal;
    width: 90%;
  }
  
  /* Hero 区域 */
  #hero {
    min-height: 100vh;
    min-height: 100dvh;
    height: auto;
  }
  
  .hero-img {
    width: 100% !important;
    max-width: 400px !important;
    bottom: 50px !important;
  }
  
  .page-title {
    font-size: 50px !important;
    padding: 0 10px;
  }
  
  /* Final scene */
  .final-scene {
    position: relative;
    width: 100%;
    min-height: 100vh;
    overflow-y: auto;
  }
  
  /* Footer */
  #footerStyle {
    padding: 20px;
    flex-direction: column;
    gap: 16px;
  }
  
  .last_title {
    font-size: 35px !important;
    text-align: center !important;
  }
  
  #footerStyle > div > img:nth-child(2) {
    width: 150px;
  }
  
  /* Portfolio 导航 */
  .portfolio-nav {
    padding: 8px 10px;
    gap: 3px;
    position: relative;
    top: 0;
  }
  
  .portfolio-nav .nav-item {
    font-size: 0.7rem;
    padding: 4px 8px;
  }
  
  /* Portfolio 卡片 */
  .portfolio-pixel {
    margin: 60px 10px 40px;
    padding: 0 10px;
  }
  
  .pixel-card {
    padding: 16px;
    border-radius: 12px;
  }
  
  .pixel-title {
    font-size: 1.2rem;
  }
  
  .pixel-subtitle {
    font-size: 0.9rem;
  }
  
  /* 图片网格 */
  .evidence-grid {
    gap: 8px;
    flex-wrap: wrap;
  }
  
  .evidence-item img {
    max-width: 100% !important;
    width: calc(50% - 4px) !important;
    height: auto !important;
    aspect-ratio: 3/2;
    object-fit: cover;
  }
  
  /* 贡献表格 */
  .contrib-table {
    font-size: 0.7rem;
    display: block;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  
  .contrib-table th,
  .contrib-table td {
    padding: 6px 4px;
    white-space: nowrap;
  }
  
  /* 下拉导航 */
  header {
    padding: 15px;
  }
  
  .dropdown-nav {
    right: 15px;
    top: 60px;
    width: 160px;
  }
  
  /* 背景遮罩 */
  .bg-mask {
    display: block !important;
    top: 90vh;     /* 手机端起始位置 */
    height: 1590vh;
  }
}

/* 手机小屏进一步调整 */
@media (max-width: 480px) {
  .ticket-main {
    width: 92vw;
    max-width: 280px;
    padding: 16px;
  }
  
  .ticket-stub {
    width: 92vw;
    max-width: 280px;
    padding: 12px;
  }
  
  .title {
    font-size: 1.4rem;
    margin: 10px 0 6px;
  }
  
  .subtitle {
    font-size: 0.75rem;
  }
  
  .ticket-footer {
    gap: 10px;
  }
  
  .箔片 {
    min-width: 28px;
    min-height: 28px;
  }
  
  .ticket-guide p {
    font-size: 14px;
  }
  
  .sky-center-text {
    font-size: 2rem;
  }
  
  .page-title {
    font-size: 40px !important;
  }
  
  /* Portfolio 进一步缩小 */
  .portfolio-nav .nav-item {
    font-size: 0.65rem;
    padding: 3px 6px;
  }
  
  .pixel-card {
    padding: 14px;
    border-width: 3px;
  }
  
  .pixel-title {
    font-size: 1.1rem;
  }
  
  .why-text {
    font-size: 0.85rem;
    padding: 12px;
  }
  
  /* 学术论文卡片 */
  .paper-item,
  .product-item {
    min-width: 100%;
    font-size: 0.85rem;
  }
  
  .badge-good,
  .badge-miss {
    font-size: 0.75rem;
    padding: 2px 6px;
    display: block;
    margin: 4px 0;
  }
  
  /* 草图行 */
  .sketch-row {
    flex-wrap: wrap;
  }
  
  .sketch-row img {
    max-width: 45% !important;
    height: auto !important;
  }
  
  .last_title {
    font-size: 28px !important;
  }
}

/* 横屏手机适配 */
@media (max-width: 850px) and (orientation: landscape) {
  .ticket-container {
    flex-direction: row;
    gap: 0;
  }
  
  .ticket-main {
    width: 45vw;
    max-width: 280px;
    height: auto;
    min-height: 150px;
  }
  
  .ticket-stub {
    width: 25vw;
    max-width: 120px;
    height: auto;
    min-height: 150px;
  }
  
  .sky-center-text {
    font-size: 2rem;
  }
  
  .page-title {
    font-size: 40px !important;
  }
  
  .last_title {
    font-size: 30px !important;
  }
  
  .ticket-guide {
    top: 5%;
  }
  
  .ticket-guide p {
    font-size: 14px;
  }
}