/* 全局樣式 */
body {
  font-family: Arial, sans-serif;
  margin: 0;
  padding: 0;
  text-align: center;
}

/* 設定頁面的容器寬度 */
.container {
  max-width: 1623px; /* 最大寬度設為 1623px */
  margin: 0 auto; /* 讓頁面居中 */
  padding: 0 15px; /* 加入內邊距避免內容貼邊 */
}

/* Header */
header {
  background-color: #f8f8f8;
  padding: 15px 0;
  border-bottom: 1px solid #ddd;
}

header .container {
  display: flex;
  justify-content: space-between; /* 讓 logo 和 menu 分居兩邊 */
  align-items: center; /* 垂直居中 */
}

/* Navigation Bar */
.top-bar {
  background-color: white;
  padding: 30px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
  border-bottom: 1px solid #ddd;
}

/* LOGO 置中 */
.logo {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
}

/* 左側 LOGO */
.logo img {
  max-width: 150px; /* 根據需要調整 Logo 大小 */
}

/* 右側 Menu */
.menu {
  display: flex;
  gap: 20px;
  align-items: center;
}
/* Menu 連結 */
.menu a {
  text-decoration: none;
  color: black;
  font-size: 14px;
  font-weight: bold;
}
/* 下拉選單 */
.dropdown {
  position: relative;
}
/* Hamburger Menu 按鈕 */
.hamburger-menu {
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
  position: absolute;
  left: 20px;
  top: 15px;
}

/* Mobile Menu (側邊選單) */
.mobile-menu {
  position: fixed;  
  top: 0;
  left: -100%;
  width: 250px;
  height: 100vh;
  background-color: white;
  box-shadow: 2px 0 5px rgba(0, 0, 0, 0.2);
  padding-top: 50px;
  transition: left 0.3s ease-in-out;
  z-index: 2;
}

/* Menu 選項 */
.mobile-nav {
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding: 20px;
}

.mobile-nav a {
  text-decoration: none;
  font-size: 16px;
  color: black;
  font-weight: bold;
  text-align: left; 
}

/* 關閉按鈕 */
.close-menu {
  position: absolute;
  top: 15px;
  right: 15px;
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
}

/* Lightbox 背景 */
.search-lightbox {
  display: none; /* 預設隱藏 */
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.6); /* 半透明背景 */
  z-index: 1000;
  /* display: flex; */
  align-items: center;
  justify-content: center;
}

/* Lightbox 內部框 */
.search-box {
  background: white;
  padding: 30px;
  width: 80%;
  max-width: 400px;
  border-radius: 10px;
  text-align: center;
  position: relative;
}

/* 關閉按鈕 */
.close-search {
  position: absolute;
  top: 10px;
  right: 15px;
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
}

/* 搜尋標題 */
.search-box h2 {
  font-size: 20px;
  margin-bottom: 15px;
}

/* 搜尋輸入框 & 放大鏡按鈕 */
.search-input-container {
  display: flex;
  justify-content: space-between;
  border: 1px solid #ccc;
  border-radius: 5px;
  overflow: hidden;
}

.search-input-container input {
  flex: 1;
  padding: 10px;
  border: none;
  font-size: 16px;
  outline: none;
}

.search-button {
  background-color: #c8a97e; /* 金色按鈕 */
  color: white;
  border: none;
  padding: 10px 15px;
  font-size: 18px;
  cursor: pointer;
}

.search-button:hover {
  background-color: #b08d64; /* 深金色 */
}

/* 確定按鈕 */
.confirm-button {
  background-color: #c8a97e; /* 金色 */
  color: white;
  border: none;
  padding: 12px;
  font-size: 16px;
  cursor: pointer;
  width: 100%;
  margin-top: 15px;
  border-radius: 5px;
}

.confirm-button:hover {
  background-color: #b08d64; /* 深金色 */
}

/* Lightbox 內的篩選條件 */
.filter-section {
  margin-top: 15px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  text-align: left;
}

/* 篩選標籤 */
.filter-section label {
  font-size: 14px;
  font-weight: bold;
  color: black;
}

/* 下拉式選單 */
.filter-section select {
  width: 100%;
  padding: 10px;
  border: 1px solid #ccc;
  border-radius: 5px;
  font-size: 14px;
}

.dropdown-content {
  display: none;
  position: absolute;
  background-color: white;
  min-width: 120px;
  box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.2);
  z-index: 1000;
  top: 100%;
  left: 0;
}

.dropdown-content a {
  display: block;
  padding: 8px 12px;
  color: black;
  text-decoration: none;
  font-size: 14px;
}

.dropdown-content a:hover {
  background-color: #f4f4f4;
}

/* 當鼠標懸停時顯示下拉選單 */
.dropdown:hover .dropdown-content {
  display: block;
}

/* 搜尋圖標 */
.search-icon {
  background: none;
  border: none;
  font-size: 20px;
  cursor: pointer;
  position: absolute;
  right: 20px;
  display: flex;
  align-items: center; /* 垂直置中 */
  height: 100%; /* 讓它填充導航欄高度 */
}


/* Small Screens */
@media (max-width: 768px) {
  header .container {
    flex-wrap: wrap;
  }

  header .menu {
    flex-wrap: wrap;
    gap: 10px;
  }
}
/*New Add Mar2025*/
/* 主標題 */
.suggested-title {
  font-size: 16px;
  margin-top: 20px;
  margin-bottom: 10px;
}

/*End modify Mar2025*/

/* 關鍵字鏈接 */
.keywords-container {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 20px;
}

.keywords-container a {
  text-decoration: none;
  color: #007bff;
  font-size: 16px;
  line-height: 20px;
}

.keywords-container a:hover {
  text-decoration: underline;
}

/* 篩選條件 */
.criteria {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 15px;
  margin: 20px 0;
}

.criteria select {
  padding: 8px;
  font-size: 14px;
  border: 1px solid #ccc;
  border-radius: 5px;
}

@media screen and (max-width: 768px) {
  .criteria {
      display: none !important;
  }
}

/* 篩選條件標籤 */
.applied-filters {
  text-align: center; /* 讓篩選條件置中 */
  margin-top: 20px;
}

#active-filters {
  display: inline-flex;  /* 讓內容在容器內置中 */
  flex-wrap: wrap;       /* 內容過多時換行 */
  gap: 10px;             /* 間距 */
  justify-content: center; /* 內容居中 */
  margin-top: 10px;
  padding: 0;
}
.filter-tag {
  border: 1px solid #c8a97e;  /* 邊框顏色 */
  padding: 10px 15px;          /* 內邊距 */
  border-radius: 5px;         /* 圓角邊框 */
  background-color: #fff;     /* 背景顏色 */
  color: #a57c50;             /* 文字顏色 */
  font-weight: bold;
  display: flex;
  align-items: center;
  cursor: pointer;
  position: relative;         /* 讓下方的分隔線定位 */
}

/* 添加底部的金色橫線 */
.filter-tag::after {
  content: "";               
  position: absolute;
  left: 0;
  bottom: -5px;               /* 橫線距離標籤的距離 */
  width: 100%;
  height: 2px;                /* 橫線的厚度 */
  background-color: #c8a97e;  /* 金色 */
}

.filter-tag .close-btn {
  margin-left: 8px;
  font-size: 16px;
  font-weight: bold;
  color: #a57c50;
  cursor: pointer;
}

.filter-tag:hover {
  background-color: #f5f5f5;
}
.remove-filter{
  background: none;
  border: none;
  margin-left: 6px;
  cursor: pointer;
  padding: 0 4px;
  color: #666;
}
.remove-filter:hover {
  color: #ff0000;
}

.clear-all {
  border: 1px solid #999;
  color: #555;
  background-color: #eee;
  padding: 5px 15px;
  border-radius: 5px;
}

.clear-all:hover {
  background-color: #ddd;
}

/* 當沒有篩選條件時的訊息樣式 */
.no-filters {
  font-size: 16px;
  color: #888;
  font-style: italic;
}


/* 搜尋區域 */
.search-bar {
  margin: 20px auto;
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  max-width: 400px;
  position: relative;
}

.search-bar input {
  width: 100%;
  padding: 10px;
  font-size: 14px;
  border: 1px solid #ccc;
  border-radius: 5px 0 0 5px;
}

.search-bar button {
  padding: 10px;
  font-size: 14px;
  background-color: #007bff;
  color: #fff;
  border: none;
  border-radius: 0 5px 5px 0;
  cursor: pointer;
}

.search-bar button:hover {
  background-color: #0056b3;
}

/* Footer 主容器 */
.site-footer {
  background-color: #000;
  color: #fff;
  padding: 20px 0;
  font-size: 14px;
}

/* 桌面版：Footer 內容水平對齊 */
.footer-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* 第一行：社交媒體圖標（桌面版 & 手機版） */
.footer-social {
  display: flex;
  justify-content: center; /* Centers the icons horizontally */
  align-items: center; /* Centers the icons vertically */
  gap: 15px; /* Adds spacing between icons */
  margin-top: 10px; /* Adjust spacing from other elements */
}

.footer-social a img {
  width: 24px;  /* 圖標大小 */
  
  transition: opacity 0.3s;
}

.footer-social a:hover img {
  opacity: 0.7;
}

/* 第二行：版權聲明（桌面版 & 手機版置中） */
.footer-copyright {
  text-align: center;
  flex-grow: 1;
  margin: 10px 0;
}

.footer-copyright a {
  color: #fff;
  text-decoration: none;
}

.footer-copyright a:hover {
  text-decoration: underline;
}

/* 第三行：連結（桌面版 & 手機版置中） */
.footer-links {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 15px;
}

.footer-links a {
  color: #fff;
  text-decoration: none;
  font-size: 14px;
}

.footer-links a:hover {
  text-decoration: underline;
}

/* 響應式設計（手機版） */
@media (max-width: 768px) {
  .footer-container {
      display: flex;
      flex-direction: column;
      align-items: center;
      text-align: center;
  }

  /* 第一行：社交媒體圖標靠左 */
  .footer-social {
      width: 100%;
      justify-content: flex-start;
      padding-left: 20px;
      justify-content: center; /* Centers the icons horizontally */
      align-items: center; /* Centers the icons vertically */
  }

  /* 第二行：版權聲明 */
  .footer-copyright {
      width: 100%;
      text-align: center;
      margin-top: 10px;
  }

  /* 第三行：其他連結 */
  .footer-links {
      width: 100%;
      text-align: center;
      justify-content: center;
      margin-top: 10px;
  }
}
