:root {
  --red: #c12a2f;
  --ink: #2a1f1c;
  --muted: #5c4a45;
  --font-sans: "Noto Sans HK", sans-serif;
  --max: 1110px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.66;
  background-color: #ffffff; /* Fallback: 填白色 */
    min-height: 100vh;
  /* 替換背景顏色為圖片 */
  background-image: url("./assets/background.webp");
  /* 自動填滿頁面並保持比例 */
  background-size: cover;
  background-repeat: repeat;
  background-position: top center;
  background-attachment: scroll;
  background-size: 100% auto;
}


img {
  max-width: 100%;
  height: auto;
  display: block;
}

h1, h2 {
  line-height: 1.2;
  font-weight: 700;
  margin: 0 0 0.75rem;
}

p {
  margin: 0 0 1rem;
}

.wrap {
  width: min(100% - 2rem, var(--max));
  margin-inline: auto;
}

/* 將 .hero 與 .footbanner 的樣式合併，共用置中與排版設定 */
.hero, 
.footbanner {
    display: flex;
    justify-content: center; /* 水平置中 */
    align-items: center;     /* 垂直置中 */
    width: 100%;             /* 確保佔滿滿版寬度 */
    padding: 20px 0;         /* 依需求調整上下間距 */
}

/* 內層 wrap 限制最大寬度並雙重保險置中 */
.hero .wrap, 
.footbanner .wrap {
    display: block;
    max-width: 100%;
    text-align: center;
}

/* 確保頭部與頁尾的 Banner 圖片都能自動縮放、不破版 */
.hero__banner, 
.footbanner__banner {
    display: inline-block;
    max-width: 100%;         /* 手機版自動等比例縮小，不超出螢幕 */
    height: auto;            /* 保持原始比例 */
}

.intro {
  text-align: center;
  padding: 1.5rem 0 3rem;
}

.intro__inner,
.section-image {
  max-width: 800px;
  margin-inline: auto;
}

.intro__headline {
  font-size: 26px;
  color: var(--ink);
  margin-bottom: 0.75rem;
}

.intro__headline span {
  display: inline-block;
  margin-top: 0.35rem;
  font-size: 0.72em;
  color: var(--muted);
}

.lead {
  font-size: 1.05rem;
  color: var(--muted);
  text-align: left;
  margin-bottom: 0;
}

/* 圖文 / 區塊圖切換：data-display="text" | "image" */
[data-display="text"] .content-image {
  display: none !important;
}

[data-display="image"] .content-text {
  display: none !important;
}

/* desktop / mobile 分圖（斷點 768） */
.img-desktop,
.img-mobile {
  width: 100%;
  margin-inline: auto;
}

@media (max-width: 768px) {
  .img-desktop {
    display: none !important;
  }
}

@media (min-width: 769px) {
  .img-mobile {
    display: none !important;
  }
}

.earlycheck,
.awareness,
.cast,
.org {
  padding: 4.5rem 0;
}

.awareness h2,
.cast h2,
.org h2 {
  font-size: 24px;
  text-align: center;
}

.awareness .table-scroll,
.cast .table-scroll {
  max-width: 800px;
  margin-inline: auto;
}

.cast .data-table {
  width: auto;
  margin-inline: auto;
}

.cast .data-table th,
.cast .data-table td {
  padding: 0.85rem 0.75rem;
}

.cast .data-table th {
  padding-right: 3rem;
  white-space: nowrap;
}

.cast .data-table td {
  padding-left: 0;
  white-space: nowrap;
}

.org .content-text > p {
  max-width: 800px;
  margin-inline: auto;
  margin-bottom: 0;
}

.support {
  margin-top: 2.5rem;
  padding: 1.5rem 0 3rem;
  width: 100%;
  text-align: right;
}

.support__label {
  letter-spacing: 0.18em;
  font-size: 0.78rem;
  font-weight: 700;
  opacity: 0.75;
}

.support img {
  margin-left: auto;
}

.table-scroll {
  margin-top: 1.5rem;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.98rem;
}

.data-table th,
.data-table td {
  padding: 0.85rem 1rem;
  text-align: left;
  vertical-align: top;
  border-bottom: 1px solid rgba(90, 40, 30, 0.12);
}

.data-table tbody th {
  font-weight: 700;
  white-space: nowrap;
}

.data-table tbody td {
  color: var(--muted);
}

.data-table tbody tr:last-child th,
.data-table tbody tr:last-child td {
  border-bottom: 0;
}

.cell-photo {
  width: 4.5rem;
  padding-right: 0.65rem !important;
  vertical-align: middle !important;
}

.cell-photo img {
  width: 3.75rem;
  height: 3.75rem;
  object-fit: contain;
  border-radius: 50%;
}

.cell-stack {
  vertical-align: middle !important;
}

.cell-stack p {
  margin: 0;
}

.cell-stack__title {
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 0.35rem;
}

.cell-stack__text {
  color: var(--muted);
}

.episode__link {
  display: block;
  color: inherit;
  text-decoration: none;
}

.episode__link:hover .episode__row,
.episode__link:focus-visible .episode__row {
  box-shadow: 0 8px 28px rgba(42, 31, 28, 0.14);
}

.episode__link:focus-visible {
  outline: 2px solid var(--red);
  outline-offset: 4px;
}

.episode {
  padding: 2.25rem 0;
}

.episode + .episode {
  padding-top: 1.25rem;
}

.episode__row {
  display: flex;
  flex-direction: column;
  background: #fff;
  box-shadow: 0 6px 22px rgba(42, 31, 28, 0.1);
}

@media (min-width: 768px) {
  .episode__row {
    flex-direction: row;
    align-items: stretch;
  }

  .episode__row .thumb {
    flex: 0 0 48%;
    max-width: 48%;
  }

  .episode__row .episode__copy {
    flex: 1;
    min-width: 0;
    border-left: 1px solid rgba(42, 31, 28, 0.08);
  }
}

.thumb {
  aspect-ratio: 16 / 9;
  width: 100%;
  overflow: hidden;
  background: #f5f5f5;
}

.thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.episode__copy {
  padding: 1.25rem 1.35rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

@media (max-width: 767px) {
  .episode__copy {
    border-top: 1px solid rgba(42, 31, 28, 0.08);
  }
}

.episode__copy h2 {
  font-size: 19px;
  line-height: 1.45;
  margin-bottom: 0.65rem;
}

.episode__copy p:last-child {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.7;
}

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

    /* 分隔線樣式*/
    .section-divider {
      border: 0;
      height: 1px;
      background-color: #d1b4d6;     /* 分隔線顏色，使用帶點粉紫的灰色配合主題 */
      max-width: 800px;             /* 限制最大寬度，與內容對齊 */
	  margin: 0 auto 20px auto;     /* 頂部 0, 左右 auto 置中, 底部 20px */
      opacity: 0.6;                 /* 讓線條看起來更柔和 */
    }

    /* 免責聲明文字樣式 */

	.disclaimer-text {
      max-width: 800px;
      margin: 0 auto 40px auto;     /* 水平置中 */
      padding-inline: 15px;         /* 手機版左右留點邊距 */          
    }
	
    .reference  {
      max-width: 800px;
      margin: 0 auto 40px auto;     /* 水平置中 */
      padding-inline: 15px;         /* 手機版左右留點邊距 */          
    }