/* ========================================
    Global Styles & CSS Variables
    ======================================== */
:root {
  --primary-color: #0052a3;
  --secondary-color: #C20000;
  --text-dark: #333333;
  --text-light: #666666;
  --footer-bg: #232222;
  --transition: all 0.3s ease;
}

/* Reset & Base Styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Noto Sans TC', -apple-system, BlinkMacSystemFont, sans-serif;
  color: var(--text-dark);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

a {
  text-decoration: none;
  color: inherit;
  transition: var(--transition);
}

ul {
  list-style: none;
}

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

/* Smooth Scroll */
html {
  scroll-behavior: smooth;
}

/* Accessibility - Focus Styles */
a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--primary-color);
  outline-offset: 3px;
}

/* ========================================
  Main Content Styles
======================================== */
.main-content {
  flex: 1;
  width: 100%;
  margin: 0 auto;
  padding-top: 152px;
}

.page-title {
  padding-top: 80px;
  font-size: 36px;
  font-weight: 500;
  color: var(--text-dark);
  text-align: center;
}

.page-title::after {
  content: '';
  display: block;
  margin: 4px auto 0;
  width: 60px;
  height: 3px;
  background-color: var(--secondary-color);
}

/* Page Background Image */
.page-bg {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  pointer-events: none;
  z-index: -1;
}

.btn {
  display: block;
  width: 200px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  text-align: center;
  transition: var(--transition);
}

.more_btn {
  border: 1px solid var(--secondary-color);
  color: var(--secondary-color);
}

.more_btn:hover {
  background-color: var(--secondary-color);
  color: #fff;
}

@media screen and (max-width: 768px) {
  .more_btn {
    width: calc(100% - 80px);
    max-width: 400px;
  }
}

/* ========================================
   Common Swiper Pagination
   ======================================== */
.common-pagination {
  position: relative;
  margin-top: 30px;
}

.common-pagination .swiper-pagination-bullet {
  width: 10px;
  height: 10px;
  background: #ccc;
  opacity: 1;
  transition: all 0.3s ease;
}

.common-pagination .swiper-pagination-bullet-active {
  background: var(--text-dark);
  ;
  width: 10px;
}

@media screen and (max-width: 1024px) {
  .main-content {
    padding-top: 92px;
  }
}

@media screen and (max-width: 768px) {
  .main-content {
    padding-top: 70px;
  }
}

/* --- Hero Banner 全域元件 --- */
.hero-banner {
  /* 基礎佈局 */
  position: relative;
  /* 為了讓遮罩層定位 */
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  width: 100%;
  min-height: 480px;
  /* 設定最小高度，確保內容少時也有份量 */
  padding: 2rem 1rem;
  overflow: hidden;
  /* 防止視差圖片超出 */

  /* 文字設定 */
  color: #fff;
  text-align: center;

  /* 確保內容在遮罩層之上 */
  z-index: 1;
}

/* 背景圖片 (用於視差效果) */
.hero-banner__bg {
  position: absolute;
  top: -10%;
  /* 往上偏移，避免頂部空白 */
  left: 0;
  width: 100%;
  height: 120%;
  /* 額外高度供視差移動 */
  object-fit: cover;
  object-position: center;
  z-index: -2;
  /* 在遮罩層後面 */
  will-change: transform;
  /* GPU 加速 */
  pointer-events: none;
}

/* 黑色半透明遮罩 (關鍵優化：增加文字可讀性) */
.hero-banner::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.4);
  /* 40% 黑色遮罩，可依需求調整 */
  z-index: -1;
  /* 放在內容後面 */

  /* 如果希望圖片不要太黑，可以只加一點陰影，改用 backdrop-filter (選用) */
  /* backdrop-filter: brightness(0.8); */
}

/* 主標題 (Hero Title) */
.hero-banner__title {
  font-family: 'Antonio', sans-serif;
  font-size: 100px;
  font-weight: 600;
  line-height: 1.2;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

/* 副標題 (Hero Subtitle) */
.hero-banner__subtitle {
  font-size: 36px;
  font-weight: 700;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.3);
}

@media screen and (max-width: 768px) {
  .hero-banner__title {
    font-size: 80px;
  }
}

/* --- Select 下拉選單 --- */
.select-wrapper {
  position: relative;
  width: 200px;
  /* 可自訂寬度 */
}

.form-select {
  appearance: none;
  /* 移除瀏覽器預設的醜醜箭頭 */
  -webkit-appearance: none;
  width: 100%;
  padding: 10px 15px;
  padding-right: 30px;
  /* 右邊留空間給箭頭 */
  border: 1px solid #d1d5db;
  border-radius: 6px;
  background-color: white;
  font-size: 14px;
  color: #374151;
  cursor: pointer;
  outline: none;
  transition: border-color 0.2s;
}

.form-select:focus {
  border-color: #f5a623;
  /* Focus 時變成你的主題色 */
  box-shadow: 0 0 0 3px rgba(245, 166, 35, 0.1);
}

/* 自製一個 CSS 箭頭 */
.select-arrow {
  position: absolute;
  top: 50%;
  right: 12px;
  transform: translateY(-50%);
  width: 10px;
  height: 10px;
  background-image: url("data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22292.4%22%20height%3D%22292.4%22%3E%3Cpath%20fill%3D%22%23333%22%20d%3D%22M287%2069.4a17.6%2017.6%200%200%200-13-5.4H18.4c-5%200-9.3%201.8-12.9%205.4A17.6%2017.6%200%200%200%200%2082.2c0%205%201.8%209.3%205.4%2012.9l128%20127.9c3.6%203.6%207.8%205.4%2012.8%205.4s9.2-1.8%2012.8-5.4L287%2095c3.5-3.5%205.4-7.8%205.4-12.8%200-5-1.9-9.2-5.5-12.8z%22%2F%3E%3C%2Fsvg%3E");
  background-repeat: no-repeat;
  background-size: contain;
  pointer-events: none;
  /* 讓點擊箭頭也能觸發下拉 */
}