:root {
  --bg-black: #080504;
  --bg-panel: #150f0c;
  --gold: #cda75b;
  --gold-light: #ecd18f;
  --red: #8a1f1f;
  --red-light: #c0392b;
  --text-main: #e9e2d3;
  --text-mute: #a8977d;
  --border-gold: rgba(205, 167, 91, 0.35);
  --header-h: 78px;
  --font-cn-serif: "Noto Serif TC", serif;
  --font-cn-sans: "Noto Sans TC", sans-serif;
  --font-en: "Cinzel", serif;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: var(--bg-black);
  color: var(--text-main);
  font-family: var(--font-cn-sans);
  line-height: 1.7;
}

img {max-width: 100%;display: block;margin: 0 auto;}
a { color: inherit; text-decoration: none; }

/* ===== 全站共用固定背景 ===== */
.mainBg {
  position: fixed;
  inset: 0;
  z-index: 0;
  background: url('../images/bg.jpg') no-repeat center center;
  background-size: cover;
  opacity: 0;
  animation: bgFadeIn 1.6s ease forwards;
}

/* ===== Logo / 右上角連結 ===== */
.logo {
  position: fixed;
  top: 18px;
  left: 24px;
  z-index: 20;
  width: 150px;
}
.links {
  position: fixed;
  top: 16px;
  right: 24px;
  z-index: 20;
  display: flex;
  gap: 10px;
}
.links a {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid var(--border-gold);
  background-color: rgba(8,5,4,.5);
  background-repeat: no-repeat;
  background-position: center;
  background-size: 18px;
  transition: all .25s ease;
}
.icon_home { background-image: url('../images/icon_home.png'); }
.icon_dl { background-image: url('../images/icon_download.png'); }
.icon_fb { background-image: url('../images/icon_fb.png'); }
.links a:hover { background-color: var(--gold); border-color: var(--gold); }

.nav-toggle {
  display: none;
  position: fixed;
  top: 16px;
  right: 24px;
  z-index: 25;
  flex-direction: column;
  gap: 5px;
  background: rgba(8,5,4,.6);
  border: 1px solid var(--border-gold);
  border-radius: 4px;
  cursor: pointer;
  padding: 10px 12px;
}
.nav-toggle span { width: 20px; height: 2px; background: var(--gold); display: block; }

/* ===== Fullpage 結構 ===== */
.main_wrap {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100vh;
  overflow: hidden;
}
.swiper-container {
  width: 100%;
  height: 100%;
  overflow: hidden;
}
.swiper-container .swiper-wrapper .swiper-slide {
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
/* footer 是獨立的矮 slide,不強制 100vh,靠 slidesPerView:'auto' +
   一般 slide 位移特效,捲到底時自然露在最後一頁下方(跟參考的倒數頁面
   做法一致) */
.swiper-container .swiper-wrapper .footer.swiper-slide {
  height: auto;
  align-items: flex-end;
}

/* 切頁動態:改回 Swiper 預設的 slide 位移特效(js/main.js 沒有再設定
   effect,slidesPerView 改回 'auto'),每頁(含 footer)照原本 CSS 高度
   往上位移,不用額外的 transition/animation */

/* ===== Hero ===== */
/* hero 滑走時淡出:純 CSS,靠 Swiper 自動切換的 swiper-slide-active
   class 來觸發 opacity transition,不用改 Swiper 設定 */
.home.swiper-slide {
  background: #000;
  opacity: 1;
  transform: scale(1);
  transition: all 1.2s ease;
}
.home.swiper-slide:not(.swiper-slide-active) {
  opacity: 0;
  transform: scale(1.5);
}

/* UPDATE01~04 不再各自帶自己的背景圖。.mainBg 本身就是 position:fixed,
   一直固定在畫面上;slide 本身是透明的,切頁時只有內容用 transform 位移,
   背景全程不動(background-attachment:fixed 用在有 transform 的元素上
   不會生效,所以改成讓 slide 保持透明、直接透出底下固定的 .mainBg) */
.hero-content { position: relative; width: 100%; height: 100%; }
.hero-video {
  position: absolute;
  inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: center 20%;
}
/* 手機版 hero 疊圖,預設隱藏,在 600px 以下的斷點才顯示(見下方 media query) */
.hero-bg-m,
.hero-logo-m,
.hero-slogan-m {
  display: none;
  pointer-events: none;
}

/* ===== Update slides (page01~04) ===== */
.update-inner {
  width: 100%;
  max-width: 1180px;
  padding: 40px 32px;
  margin: 0 auto;
  text-align: center;
  transform: translateX(30px);
}
.content_container {
  width: 100%;
  /* max-width: 820px; */
  height: 540px;
  margin: 24px auto 0;
  overflow-y: auto;
  padding: 0 30px;
  scrollbar-width: thin;
  scrollbar-color: var(--gold) transparent;
}
.content_container::-webkit-scrollbar { width: 5px; }
.content_container::-webkit-scrollbar-thumb { background: var(--border-gold); border-radius: 3px; }

.eyebrow {
  font-family: var(--font-en);
  color: var(--red-light);
  letter-spacing: .3em;
  font-size: 13px;
  margin: 0 0 8px;
  display: none;
}
.section-title {
  margin: 0 0 16px;
}
.section-title img {
  height: clamp(40px, 6vw, 64px);
  width: auto;
  margin: 0 auto;
}
.section-subtitle p { margin: 0; font-size: clamp(13px, 1.5vw, 16px); color: var(--text-main); }
.section-note {
  color: #ff6150;
  font-size: 16px;
  margin: 12px auto 0;
  line-height: 1.8;
}

.ui-panel {
  margin: 18px auto 0;
}
.ui-panel img {border-radius: 3px;width: 82%;margin-bottom: 20px;}
.ui-panel.two-up { display: flex; gap: 8px; }
.ui-panel.two-up img { width: 50%; }

/* Section01 單欄置中 */
.ui-panel {max-width: 100%;}
.more-hint, .more-link {margin-top: 20px;color: var(--text-mute);font-size: 16px;}
.more-link a {
  display: inline-block;
  padding: 8px 24px;
  border: 1px solid var(--gold);
  border-radius: 2px;
  color: var(--gold-light);
  letter-spacing: .1em;
  font-size: 13px;
  transition: all .25s ease;
}
.more-link a:hover { background: var(--gold); color: var(--bg-black); }

/* 子區塊(恆星神力/朝聖者的祭壇 內的兩個小節),直向堆疊 */
.sub-block { margin-top: 28px; }
.sub-block h3 {
  font-family: var(--font-cn-serif);
  color: var(--gold);
  font-size: 24px;
  margin: 0 0 10px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border-gold);
}
.sub-block .ui-panel { max-width: 460px; margin: 0 auto; }
.sub-block p { font-size: 13px; color: var(--text-mute); margin: 10px auto 0; max-width: 500px; line-height: 1.7; }

.text-block h3 {
  font-family: var(--font-cn-serif);
  color: var(--gold);
  font-size: 28px;
  margin: 30px 0 8px;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--border-gold);
}
.text-block p {color: #ffe5bd;font-size: 16px;margin: 0;}
.feature-list {list-style: none;margin: 0;padding: 0;display: flex;flex-direction: column;gap: 8px;}
.feature-list li {
  color: #ffe5bd;
  text-align: left;
  line-height: 1.6;
  padding-left: 16px;
  position: relative;
}
.feature-list li::before {
  content: "◆";
  position: absolute;
  left: 0;
  top: 6px;
  color: #ffe5bd;
  font-size: 9px;
}

/* ===== Side nav (Swiper pagination) ===== */
#sideNav.nav {
  position: fixed !important;
  left: 32px !important;
  right: auto !important;
  top: 50% !important;
  transform: translateY(-50%) !important;
  z-index: 20;
  display: flex;
  flex-direction: column;
  gap: 16px;
  width: auto;
}
/* 側邊選單項目改用美術提供的 btn0X.png / btn0X_on.png 圖檔(文字已經
   畫在圖上),off/on 疊在一起用 opacity 切換,不用另外刻文字樣式 */
.nav .swiper-pagination-bullet,
.nav .link_btn {
  position: relative;
  width: auto;
  height: auto;
  margin: 0 !important;
  border-radius: 0;
  background: none;
  opacity: 1;
  display: block;
  cursor: pointer;
  animation: navFadeIn .6s ease forwards;
}
.nav .swiper-pagination-bullet img,
.nav .link_btn img {
  display: block;
  height: 50px;
  width: auto;
}
.nav .swiper-pagination-bullet .btn-on,
.nav .link_btn .btn-on {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity .25s ease;
}
.nav .swiper-pagination-bullet:hover .btn-on,
.nav .swiper-pagination-bullet-active .btn-on,
.nav .link_btn:hover .btn-on { opacity: 1; }

/* TOP 按鈕(對應 hero slide 的 pagination bullet,獨立浮動在側邊選單下方) */
.nav .nav-top {
  position: fixed;
  left: 32px;
  bottom: -70px;
  width: 60px;
  height: 60px;
  background: url('../images/top.png') no-repeat center;
  background-size: contain;
  opacity: 0;
  pointer-events: none;
  transition: opacity .3s ease, filter .25s ease;
}
.nav .nav-top:hover { filter: brightness(1.3); }
.nav .nav-top.visible { opacity: 1; pointer-events: auto; }

@keyframes navFadeIn { from { opacity: 0; transform: translateX(-6px); } to { opacity: 1; transform: translateX(0); } }
@keyframes bgFadeIn { from { opacity: 0; } to { opacity: 1; } }

/* ===== Footer(排版比照 20260923_2026中秋頁面 的寫法:footer > .wrap >
   .footerbox 裡面用一列 flex space-evenly 排 .footer_logo / .copyright /
   .grade 三塊,不用 grid) ===== */
.footer.swiper-slide {
  position: relative;
  padding: 20px 0;
  color: var(--text-mute);
  font-size: 12px;
  text-align: center;
  letter-spacing: .2px;
  line-height: 18px;
  background: rgba(5,3,2,.55);
  border-top: 1px solid var(--border-gold);
}
.footer .wrap {width: 100%;max-width: 1200px;margin: 0 auto;}
.footerbox {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
}
.footer_logo {
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: center;
  gap: 14px;
}
.footer_logo img {max-width: 160px;}
.copyright { max-width: 460px; width: 100%; text-align: left; }
.copyright a {
  color: var(--gold);
  margin-right: 10px;
  text-decoration: underline;
  font-size: 13px;
}
.copyright a:hover { color: var(--gold-light); }
.copyright p {margin: 8px 0 0;color: #ab997b;line-height: 1.3;}
.grade {
  max-width: 440px;
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-around;
  gap: 12px;
}
.grade img {flex: none;}
.grade ul {list-style: none;text-align: left;/* margin: 0 0 0 10px; */padding: 0;font-size: 13px;color: #ab997b;line-height: 1.5;}

/* ===== Responsive ===== */
@media (max-width: 960px) {
  #sideNav.nav {
    display: none;
    left: 0 !important; right: 0 !important; top: var(--header-h) !important;
    transform: none !important;
    background: rgba(5,3,2,.97);
    padding: 20px 28px;
    border-bottom: 1px solid var(--border-gold);
    flex-direction: column;
    gap: 18px;
  }
  #sideNav.nav.open {
    display: flex;
    top: 0 !important;
    padding-top: calc(var(--header-h) + 20px);
  }
  .nav.open .nav-top { display: none; }
  .nav .nav-top { left: auto; right: 20px; bottom: 20px; }
  /* 手機版 header:logo 移到正中間,navToggle 移到左邊 */
  .logo { left: 50%; right: auto; transform: translateX(-50%); }
  .nav-toggle { display: flex; left: 24px; right: auto; }
  .update-inner {padding: 76px 20px 20px;transform: translateX(0);}
  .content_container { height: min(650px, calc(100vh - 220px)); }
  .footerbox { flex-direction: column; text-align: center; }
  .copyright { text-align: center; }
  .grade { flex-direction: column; }
}

@media (max-width: 600px) {
  .ui-panel.two-up { flex-direction: column; }
  .ui-panel.two-up img { width: 100%; }
  .logo { width: 110px; }

  /* hero 手機版:改用靜態圖 + logo/slogan 疊圖,排版比照設計稿 */
  .hero-video { display: none; }
  .hero-bg-m {
    display: block;
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center top;
  }
  .hero-logo-m {
    display: block;
    position: absolute;
    top: 6%;
    left: 50%;
    transform: translateX(-50%);
    width: 55%;
    max-width: 260px;
  }
  .hero-slogan-m {
    display: block;
    position: absolute;
    left: 6%;
    bottom: 9%;
    width: 82%;
    max-width: 360px;
  }
  /* hero 疊圖已經有自己的大 logo,常駐的小 logo 在 hero 這一頁先隱藏 */
  body.on-hero .logo { display: none; }
}
