/* 保證整個畫面不會有水平滾動 */
html,
body {
  margin: 0;
  padding: 0;
  overflow-x: hidden; /* 禁止橫向滾動 */
  width: 100%;
}

.custom-navbar {
  background-color: #b02e21; /* 預設透明 */
}
/* ---------------------------------
   大Binner形象圖
---------------------------------- */

.big-binner {
  width: 100%;
  background-color: #b02e21;
  position: relative;
  overflow: hidden;
  padding-top: 0; /* 無需保留高度，讓圖片等比例顯示 */
  margin-top: 5vh;
}

/* 圖片維持等比例縮放 */
.big-binner-img {
  width: 100%;
  height: auto;
  display: block;
}

@media (max-width: 1440px) {
  .big-binner {
    margin-top: 8vh;
  }
}

@media (max-width: 1300px) {
  .big-binner {
    margin-top: 8.5vh;
  }
}

@media (max-width: 1024px) {
  .big-binner {
    margin-top: 5.5vh;
  }
}

@media (max-width: 768px) {
  .big-binner {
    margin-top: 4vh;
  }
}

/* ---------------------------------
   關於我們
---------------------------------- */

.about-content {
  background-color: #f4f0ee;
  padding-top: 60px;
  padding-bottom: 100px;
  background: #f4f0ee url("../img/background-index2.png") repeat;
  background-size: 50px 50px;
  position: relative;
  z-index: 3;
}

.about-header {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  width: 90%;
  padding: 0 0;
  margin: 0 auto 2rem;
  font-size: 2rem;
  font-weight: bold;
  text-align: center;
  color: #333;
}

.about-header::before,
.about-header::after {
  content: "";
  flex: 1;
  height: 1px;
  background-color: #333;
  opacity: 0.3;
}

.lamp-top {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 500px;
  z-index: 2;
  pointer-events: none;
}

.about-container {
  display: flex;
  gap: 60px;
  max-width: 1200px;
  margin: auto;
  padding: 40px 20px;
  z-index: 1;
  position: relative;
}

.about-left {
  flex: 1;
  max-width: 500px; /* ✅ 限制最大寬度 */
  margin-left: auto; /* ✅ 推向右邊（中間靠近） */
  font-size: 16px;
  line-height: 1.8;
}

.about-left h3 {
  font-size: 32px;
  margin-bottom: 20px;
  font-weight: 900;
}

.about-left p {
  font-size: 18px;
  margin-bottom: 20px;
  font-weight: 400;
}

.about-info-list {
  margin-top: 30px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.info-item {
  display: flex;
  flex-direction: column;
}

.info-label {
  display: inline-block;
  background-color: #333333;
  color: white;
  font-weight: bold;
  padding: 6px 20px; /* ⬅️ 增加內距更像設計圖 */
  border-radius: 15px; /* ⬅️ 圓角 15px */
  font-size: 20px; /* ⬅️ 字體大小 */
  width: fit-content;
  margin-bottom: 8px; /* ⬅️ 與下方文字更合適間距 */
  line-height: 1.2;
}

.info-text {
  color: #333;
  font-size: 16px;
  line-height: 1.6;
}

.vr-button {
  margin-top: 20px;
  padding: 10px 20px;
  background-color: #ad2d24;
  color: white;
  border: none;
  border-radius: 40px;
  font-size: 36px;
  cursor: pointer;
}

.about-map-wrapper {
  flex: 1;
  position: relative;
  width: 100%;
  max-width: 600px;
  margin: auto;
}

.map-bg {
  width: 100%;
  display: block;
  border-radius: 10px;
}

.map-area {
  position: absolute;
  width: 20%;
  transition: transform 0.3s ease;
  transform-origin: center center;
  cursor: pointer;
}

.map-area:hover {
  transform: scale(1.12);
  z-index: 2;
}

/* ✅ 相對位置（百分比） */
.area-a {
  top: 33.5%;
  left: 12%;
  width: 35%;
}
.area-b {
  top: 25.3%;
  left: 66.5%;
  width: 25%;
}
.area-c {
  top: 46.8%;
  left: 8.35%;
  width: 40.3%;
}
.area-d {
  top: 75.1%;
  left: 51%;
  width: 23.5%;
}
.area-e {
  top: 32.7%;
  left: 50.5%;
  width: 41%;
}
.area-f {
  top: 75.3%;
  left: 23.5%;
  width: 27%;
}
.area-g {
  top: 20%;
  left: 65%;
  width: 26%;
}
.area-h {
  top: 25.3%;
  left: 40%;
  width: 27%;
}

/* ---------- 手機 RWD ---------- */
@media (max-width: 768px) {
  .vr-button {
    margin-top: 20px;
    padding: 10px 20px;
    border-radius: 40px;
    font-size: 24px;
  }

  .about-container {
    flex-direction: column;
    gap: 40px;
    align-items: center; /* ✅ 這行會讓左右區塊一起置中 */
  }

  .about-left,
  .about-map-wrapper {
    width: 100%;
    text-align: center;
    margin-left: 0 !important; /* ✅ 移除原有推右效果 */
  }

  .vr-button {
    margin-left: auto;
    margin-right: auto;
  }

  .map-area {
    width: 22%;
  }

  .info-label {
    /* 🧲 保證置中 */
    margin-left: auto;
    margin-right: auto;
    text-align: center;
  }

  .area-a {
    top: 33.5%;
    left: 12%;
    width: 35%;
  }
  .area-b {
    top: 25.3%;
    left: 66.5%;
    width: 25%;
  }
  .area-c {
    top: 46.8%;
    left: 8.35%;
    width: 40.3%;
  }
  .area-d {
    top: 75.1%;
    left: 51%;
    width: 23.5%;
  }
  .area-e {
    top: 32.7%;
    left: 50.5%;
    width: 41%;
  }
  .area-f {
    top: 75.3%;
    left: 23.5%;
    width: 27%;
  }
  .area-g {
    top: 20%;
    left: 65%;
    width: 26%;
  }
  .area-h {
    top: 25.3%;
    left: 40%;
    width: 27%;
  }
}

@media (max-width: 480px) {
  .lamp-top {
    width: 400px;
  }
}

@media (max-width: 400px) {
  .lamp-top {
    width: 350px;
  }
}

/* ---------------------------------
   共用區塊內容 Modal
---------------------------------- */
/* 🔲 Modal 外層遮罩區塊 */
.map-modal {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  background-color: rgba(0, 0, 0, 0.6);
  transition: opacity 0.3s ease;
}

.map-modal.show {
  display: flex;
}

/* 📦 Modal 白色主體卡片 */
.map-modal-content {
  position: relative;
  background-color: #fff;
  border-radius: 16px;
  max-width: 760px;
  width: 90%;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
  animation: fadeIn 0.3s ease;
}

/* 圖片區：允許縮放 */
.map-modal-img {
  flex-shrink: 1;
  flex-grow: 0;
  overflow: hidden;
}

/* 🔼 圖片上方區塊 */
.map-modal-img img {
  width: 100%;
  height: auto;
  object-fit: cover;
  display: block;
}

/* 📝 文字說明區塊 */
.map-modal-text {
  flex-grow: 1;
  overflow-y: auto;
  padding: 24px;
  color: #333;
}

.map-modal-text h4 {
  font-size: 14px;
  color: #555;
  margin-bottom: 6px;
  font-weight: 600;
}

.map-modal-text h3 {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 16px;
}

.map-modal-text p {
  font-size: 16px;
  line-height: 1.7;
  margin-bottom: 16px;
}

.map-modal-text ul {
  list-style: none;
  padding-left: 0;
  margin-bottom: 24px;
}

.map-modal-text ul li {
  font-size: 16px;
  margin-bottom: 6px;
  position: relative;
  padding-left: 1.2em;
}

.map-modal-text ul li::before {
  content: "•";
  position: absolute;
  left: 0;
  color: #333;
}

/* 📎 CTA 按鈕 */
.map-modal-btn {
  background-color: #333;
  color: white;
  border: none;
  padding: 12px 24px;
  font-size: 16px;
  width: 100%;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.2s ease;
}

.map-modal-btn:hover {
  background-color: #000;
}

/* ❌ 關閉按鈕 */
.map-modal-close {
  position: absolute;
  top: 16px;
  right: 20px;
  font-size: 28px;
  color: #aaa;
  border: none;
  background: transparent;
  cursor: pointer;
  z-index: 10;
  transition: color 0.2s ease;
}

.map-modal-close:hover {
  color: #000;
}

/* 📱 RWD 手機支援 */
@media (max-width: 768px) {
  .map-modal-content {
    width: 95%;
    border-radius: 12px;
  }

  .map-modal-text {
    padding: 18px;
  }

  .map-modal-btn {
    font-size: 15px;
    padding: 10px 20px;
  }
}

/* 💫 動畫 */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
/* ---------------------------------
   交通方式
---------------------------------- */
/* 🌐 區塊外觀 */
.traffic-content {
  background: #f4f0ee url("../img/background-index2.png") repeat;
  background-size: 50px 50px;
  padding: 40px 0;
  position: relative;
}

/* 📌 區塊標題 */
.traffic-header {
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 2rem;
  font-weight: bold;
  margin-bottom: 2rem;
  position: relative;
  width: 100%;
  text-align: center;
}

.traffic-header::before,
.traffic-header::after {
  content: "";
  flex: 1;
  height: 1px;
  background-color: #333;
  opacity: 0.3;
  margin: 0 12px;
}

/* 📦 內容容器 */
.traffic-container {
  display: flex;
  gap: 40px;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  align-items: flex-start;
}

.traffic-image {
  flex: 1;
  max-width: 600px;
}

.traffic-image img {
  width: 550px;
  border-radius: 12px;
  border: 4px solid #0193b9; /* 根據設計圖配色邊框 */
}

/* 右邊文字區 */
.traffic-info {
  flex: 2;
  font-size: 16px;
  color: #333;
  line-height: 1.7;
}

.traffic-block {
  margin-bottom: 24px;
}

.traffic-block h3 {
  font-size: 20px;
  font-weight: bold;
  margin-bottom: 10px;
  color: #222;
}

.traffic-block p {
  margin-bottom: 10px;
}

.traffic-block ul {
  padding-left: 1.5em;
  margin-bottom: 10px;
}

.traffic-block ul li {
  list-style: disc;
  margin-bottom: 4px;
}

@media (max-width: 850px) {
  .traffic-image img {
    width: 350px;
  }
}

/* 📱 RWD 手機板 */
@media (max-width: 768px) {
  .traffic-container {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .traffic-info {
    text-align: left;
  }

  .traffic-block {
    width: 100%;
  }

  .traffic-image img {
    width: 500px;
  }
}

@media (max-width: 480px) {
  .traffic-image img {
    width: 360px;
  }
}

@media (max-width: 400px) {
  .traffic-image img {
    width: 300px;
  }
}

/* ---------------------------------
   底部圖片
---------------------------------- */

.bottom-photo {
  position: relative;
  width: 100%;
  background: #f4f0ee url("../img/background-index2.png") repeat;
  background-size: 50px 50px;
  padding: 0;
  margin: 0;
  display: flex;
  justify-content: center;
  align-items: flex-end;
  overflow: hidden;
  z-index: 1;
}

.bottom-photo-img {
  width: 100%;
  height: 250px; /* ✅ 高度你可以自定，這裡是示範值 */
  object-fit: cover; /* ✅ 關鍵：裁切並填滿容器 */
  object-position: center; /* ✅ 關鍵：以圖片中心為裁切基準 */
  display: block;
}

.bottom-photo {
  padding-bottom: 0; /* 移除底部空間 */
  margin-bottom: 0;
}

@media (max-width: 768px) {
  .bottom-photo-img {
    height: 200px; /* ✅ 高度你可以自定，這裡是示範值 */
  }
}

@media (max-width: 480px) {
  .bottom-photo-img {
    height: 160px; /* ✅ 高度你可以自定，這裡是示範值 */
  }
}

@media (max-width: 400px) {
  .bottom-photo-img {
    height: 145px; /* ✅ 高度你可以自定，這裡是示範值 */
  }
}

/*  Google 翻譯切換按鈕  */
#translate-toggle-btn {
  position: fixed;
  bottom: 20px;
  left: 20px;
  width: 48px;
  height: 48px;
  border: none;
  border-radius: 50%;
  background-color: #333;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
  cursor: pointer;
  z-index: 9999;
  display: flex;
  justify-content: center;
  align-items: center;
}

#translate-toggle-btn img {
  width: 24px;
  height: 24px;
}

#google_translate_element {
  position: fixed;
  bottom: 80px; /* 調整這裡讓它浮在按鈕上面 */
  left: 20px;
  z-index: 99999;
  background: white;
  padding: 8px 12px;
  border-radius: 6px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.goog-te-gadget {
  font-family: inherit !important;
  font-size: 0 !important;
}

.goog-te-gadget .goog-te-combo {
  font-size: 14px !important;
}
