/* =========================================================
   康達藥業官方網站 全站公共樣式
   主色：#009d82（可在此統一調整全站配色）
   依賴：Bootstrap 5.3 + Bootstrap Icons
   ========================================================= */

/* ---------- 全局變量 ---------- */
:root {
  --brand: #035d4d;            /* 品牌主色 */
  --brand-dark: #007a66;       /* 主色加深（hover） */
  --brand-light: #e8f6f3;      /* 主色淺底 */
  --navy: #1f2d3d;             /* 深色文字 */
  --body: #5a6672;             /* 正文灰 */
  --bg-light: #f6f9f8;         /* 淺灰背景 */
  --line: #e6edeb;             /* 邊框色 */
  --footer-bg: #123c34;        /* 頁腳底色 */
  --footer-text: #b9cdc8;
  --bs-primary: var(--brand);
}

/* ---------- 基礎 ---------- */
html { scroll-behavior: smooth; }
body {
  font-family: "Microsoft JhengHei", "PingFang TC", "Noto Sans TC", "Source Han Sans TC", -apple-system, "Segoe UI", Arial, sans-serif;
  color: var(--body);
  font-size: 15px;
  line-height: 1.8;
}
a { color: var(--brand); text-decoration: none; transition: color .2s; }
a:hover { color: var(--brand-dark); }
h1, h2, h3, h4, h5, h6 { color: var(--navy); font-weight: 700; }
img { max-width: 100%; }
section { scroll-margin-top: 90px; }

.text-brand { color: var(--brand) !important; }
.bg-brand { background-color: var(--brand) !important; }

/* =========================================================
   頂部信息欄（電話 / 郵箱 / 多語言）
   ========================================================= */
.topbar {
  background: var(--navy);
  color: rgba(255,255,255,.85);
  font-size: 13px;
  position: relative;
  z-index: 1040; /* 高於主導航，避免多語言下拉被蓋住 */
}
.topbar a { color: rgba(255,255,255,.85); }
.topbar a:hover { color: #fff; }
.topbar .bi { color: var(--brand); margin-right: 4px; }
.lang-dropdown .dropdown-toggle {
  color: #fff;
  background: rgba(255,255,255,.12);
  border: 1px solid rgba(255,255,255,.35);
  font-size: 13px;
  padding: 4px 14px;
  border-radius: 20px;
  transition: all .2s;
}
.lang-dropdown .dropdown-toggle:hover { background: var(--brand); border-color: var(--brand); }
.lang-dropdown .dropdown-toggle::after {
  display: inline-block;
  margin-left: 4px;
  vertical-align: middle;
}
.lang-dropdown .dropdown-toggle img,
.lang-dropdown .dropdown-item img {
  width: 20px; height: 15px;
  object-fit: cover;
  border-radius: 2px;
  box-shadow: 0 1px 3px rgba(0,0,0,.25);
}
.lang-dropdown .dropdown-menu {
  min-width: 160px;
  font-size: 13px;
  border: 1px solid var(--line);
  box-shadow: 0 6px 20px rgba(31,45,61,.15);
  padding: 6px 0;
}
.lang-dropdown .dropdown-item { padding: 8px 16px; color: var(--navy); font-weight: 500; }
.lang-dropdown .dropdown-item:hover { background: var(--brand-light); color: var(--brand); }

/* =========================================================
   主導航
   ========================================================= */
.main-header {
  background: #fff;
  box-shadow: 0 2px 12px rgba(31,45,61,.06);
  position: sticky;
  top: 0;
  z-index: 1030;
}
.navbar { padding: 0; }
.navbar-brand { padding: 8px 0; }
.navbar-brand img { height: 46px; width: auto; display: block; }

.navbar .nav-link {
  color: var(--navy);
  font-weight: 600;
  font-size: 15.5px;
  padding: 22px 16px !important;
  letter-spacing: .5px;
  position: relative;
}
.navbar .nav-link:hover,
.navbar .nav-link.active { color: var(--brand); }
/* 下劃線指示：貼在文字底部，居中展開 */
.navbar .nav-link::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 14px;
  transform: translateX(-50%);
  height: 3px;
  width: 0;
  background: var(--brand);
  transition: width .25s;
  border-radius: 2px;
}
.navbar .nav-link:hover::after,
.navbar .nav-link.active::after { width: 24px; }

/* 帶二級下拉的菜單項：下拉箭頭顯示在右側（側面），垂直居中 */
.navbar .nav-link.dropdown-toggle {
  padding-right: 30px !important;
}
/* 徹底停用 Bootstrap 默認的 inline 小三角，避免殘留在文字下方 */
.navbar .nav-link.dropdown-toggle::after {
  content: none;
  border: 0;
  margin: 0;
  display: none;
}
/* 自定義箭頭（::before），貼右側垂直居中 */
.navbar .nav-link.dropdown-toggle::before {
  content: "";
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  border-top: 5px solid currentColor;
  border-right: 5px solid transparent;
  border-left: 5px solid transparent;
  border-bottom: 0;
  transition: transform .2s;
}
/* 懸停展開 / 點擊展開時，箭頭旋轉朝上 */
.navbar .nav-item:hover > .nav-link.dropdown-toggle::before,
.navbar .nav-link.dropdown-toggle.show::before {
  transform: translateY(-50%) rotate(180deg);
}

/* 二級下拉：桌面懸停展開 */
@media (min-width: 992px) {
  .navbar .dropdown-menu {
    display: block;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all .22s ease;
    border: none;
    box-shadow: 0 12px 30px rgba(31,45,61,.12);
    border-top: 3px solid var(--brand);
    border-radius: 0 0 6px 6px;
    min-width: 200px;
    padding: 8px 0;
  }
  .navbar .nav-item:hover > .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
  }
  .navbar .dropdown-item {
    padding: 9px 20px;
    font-size: 14.5px;
    color: var(--navy);
  }
  .navbar .dropdown-item:hover { background: var(--brand-light); color: var(--brand); }
}
@media (max-width: 991.98px) {
  .navbar .nav-link { padding: 12px 8px !important; border-bottom: 1px solid var(--line); }
  .navbar .nav-link.dropdown-toggle { padding-right: 34px !important; }
  .navbar .nav-link::after { display: none; }
  .navbar .dropdown-menu { border-left: 3px solid var(--brand); background: #fafcfb; }
  .navbar-toggler { border: none; padding: 6px 10px; }
  .navbar-toggler:focus { box-shadow: none; }
}

/* 導航欄右側：搜索按鈕（點擊彈出搜索框） */
.header-search-btn {
  height: 40px;
  border: 2px solid var(--brand);
  border-radius: 22px;
  background: #fff;
  color: var(--brand);
  font-size: 14px;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0 18px;
  margin-right: 12px;
  cursor: pointer;
  transition: all .2s;
  letter-spacing: 1px;
}
.header-search-btn .bi { font-size: 15px; }
.header-search-btn:hover { background: var(--brand); color: #fff; box-shadow: 0 6px 16px rgba(0,157,130,.35); }
@media (max-width: 991.98px) {
  .header-search-btn { width: 38px; height: 38px; padding: 0; justify-content: center; border-radius: 50%; margin-right: 4px; }
  .header-search-btn span { display: none; }
}

/* =========================================================
   搜索彈出層
   ========================================================= */
.search-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15,35,30,.92);
  display: none;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  z-index: 2000;
  padding: 24px;
}
.search-overlay.show {
  display: flex;
  animation: searchFade .25s ease;
}
@keyframes searchFade {
  from { opacity: 0; }
  to { opacity: 1; }
}
.search-panel {
  display: flex;
  width: 100%;
  max-width: 660px;
  background: #fff;
  border-radius: 40px;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0,0,0,.45);
  animation: searchPop .3s ease;
}
@keyframes searchPop {
  from { transform: scale(.94); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}
.search-input {
  flex: 1;
  border: none;
  outline: none;
  padding: 16px 26px;
  font-size: 16px;
  background: transparent;
  min-width: 0;
}
.search-submit {
  background: var(--brand);
  color: #fff;
  border: none;
  width: 68px;
  font-size: 20px;
  cursor: pointer;
  transition: background .2s;
  flex-shrink: 0;
}
.search-submit:hover { background: var(--brand-dark); }
.search-close {
  position: absolute;
  top: 22px; right: 30px;
  background: none;
  border: none;
  color: #fff;
  font-size: 42px;
  cursor: pointer;
  line-height: 1;
  transition: color .2s;
}
.search-close:hover { color: var(--brand); transform: rotate(90deg); }
.search-hint {
  color: rgba(255,255,255,.75);
  margin-top: 22px;
  font-size: 14px;
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  justify-content: center;
}
.search-hint .hint-label { color: rgba(255,255,255,.5); margin-right: 4px; }
.search-hint a {
  color: rgba(255,255,255,.9);
  background: rgba(255,255,255,.12);
  border-radius: 20px;
  padding: 3px 14px;
  font-size: 13px;
  transition: all .2s;
}
.search-hint a:hover { background: var(--brand); color: #fff; }

/* =========================================================
   Banner 輪播（文字居中）
   ========================================================= */
.hero-carousel .carousel-item { height: 600px; }
.hero-carousel .carousel-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
/* 遮罩提升文字可讀性 */
.hero-carousel .carousel-item::after {
  content: "";
  position: absolute; inset: 0;
  background: rgba(15,35,30,.35);
}
.hero-carousel .carousel-caption {
  left: 0; right: 0; top: 0; bottom: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 0 20px;
  z-index: 2;
}
.hero-carousel .carousel-caption h2 {
  color: #fff;
  font-size: clamp(28px, 4.5vw, 52px);
  font-weight: 700;
  letter-spacing: 2px;
  margin-bottom: 16px;
  text-shadow: 0 2px 14px rgba(0,0,0,.35);
}
.hero-carousel .carousel-caption p {
  color: rgba(255,255,255,.92);
  font-size: clamp(14px, 1.8vw, 19px);
  max-width: 720px;
  margin: 0 auto 26px;
  letter-spacing: 1px;
}
.hero-carousel .carousel-caption .btn {
  border-radius: 30px;
  padding: 10px 34px;
  font-weight: 600;
  letter-spacing: 1px;
}
.hero-carousel .carousel-indicators { z-index: 3; }
.hero-carousel .carousel-indicators [data-bs-target] {
  width: 34px; height: 4px; border-radius: 2px;
}
.hero-carousel .carousel-control-prev, .hero-carousel .carousel-control-next { z-index: 3; }

@media (max-width: 991.98px) { .hero-carousel .carousel-item { height: 420px; } }
@media (max-width: 575.98px) { .hero-carousel .carousel-item { height: 320px; } }

/* =========================================================
   通用區塊標題
   ========================================================= */
.section-title { text-align: center; margin-bottom: 46px; }
.section-title .en {
  font-size: 13px;
  letter-spacing: 4px;
  color: var(--brand);
  text-transform: uppercase;
  display: block;
  margin-bottom: 6px;
}
.section-title h2 { font-size: 30px; margin-bottom: 10px; position: relative; }
.section-title h2::after {
  content: "";
  display: block;
  width: 52px; height: 3px;
  background: var(--brand);
  margin: 12px auto 0;
  border-radius: 2px;
}
.section-title p { max-width: 640px; margin: 0 auto; font-size: 14.5px; }

/* =========================================================
   首頁：企業簡介
   ========================================================= */
.intro-block { padding: 80px 0; }
.intro-block .img-wrap {
  position: relative;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 16px 40px rgba(31,45,61,.14);
}
.intro-block .img-wrap img { width: 100%; display: block; }
.intro-block .intro-title { font-size: 30px; margin-bottom: 14px; }
.intro-block .exp-badge {
  position: absolute;
  right: -14px; bottom: 24px;
  background: var(--brand);
  color: #fff;
  border-radius: 10px;
  padding: 14px 22px;
  text-align: center;
  box-shadow: 0 10px 24px rgba(0,157,130,.4);
}
.intro-block .exp-badge strong { font-size: 30px; line-height: 1.1; display: block; }
.intro-block .exp-badge span { font-size: 12.5px; letter-spacing: 1px; }
.intro-feature { display: flex; gap: 12px; margin-top: 18px; }
.intro-feature .bi {
  font-size: 26px;
  color: var(--brand);
  background: var(--brand-light);
  border-radius: 8px;
  width: 52px; height: 52px;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.intro-feature h5 { font-size: 16px; margin-bottom: 2px; }
.intro-feature p { font-size: 13.5px; margin: 0; }

/* =========================================================
   首頁：產品分類入口
   ========================================================= */
.cat-block { background: var(--bg-light); padding: 80px 0; }
.cat-card {
  display: block;
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(31,45,61,.07);
  transition: transform .25s, box-shadow .25s;
}
.cat-card:hover { transform: translateY(-6px); box-shadow: 0 16px 36px rgba(31,45,61,.14); }
.cat-card img { width: 100%; height: auto; object-fit: cover; }
.cat-card .cat-body { padding: 24px 28px 28px; text-align: center; }
.cat-card .cat-body h3 { font-size: 21px; margin-bottom: 8px; }
.cat-card .cat-body p { font-size: 13.5px; margin-bottom: 14px; }
.cat-card .more {
  color: var(--brand);
  font-weight: 600;
  font-size: 14px;
}
.cat-card .more .bi { transition: transform .2s; display: inline-block; }
.cat-card:hover .more .bi { transform: translateX(4px); }

/* =========================================================
   首頁：新聞滾動區
   ========================================================= */
.news-block { padding: 80px 0; }
.news-scroll {
  border: 1px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
}
.news-scroll-header {
  background: var(--brand);
  color: #fff;
  padding: 12px 22px;
  display: flex; align-items: center; justify-content: space-between;
}
.news-scroll-header strong { font-size: 16px; letter-spacing: 1px; }
.news-scroll-header a { color: rgba(255,255,255,.9); font-size: 13px; }
.news-scroll-list { max-height: 400px; overflow-y: auto; background: #fff; }
.news-scroll-list::-webkit-scrollbar { width: 6px; }
.news-scroll-list::-webkit-scrollbar-thumb { background: var(--line); border-radius: 3px; }
.news-scroll-item {
  display: flex; align-items: center; gap: 16px;
  padding: 15px 22px;
  border-bottom: 1px dashed var(--line);
  transition: background .2s;
}
.news-scroll-item:hover { background: var(--brand-light); }
.news-scroll-item .date {
  flex-shrink: 0;
  text-align: center;
  background: var(--brand-light);
  color: var(--brand);
  border-radius: 8px;
  padding: 4px 12px;
  font-size: 12px;
  line-height: 1.4;
}
.news-scroll-item .date strong { display: block; font-size: 17px; }
.news-scroll-item .title {
  color: var(--navy);
  font-size: 14.5px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.news-scroll-item:hover .title { color: var(--brand); }
.news-scroll-item .cat-tag {
  flex-shrink: 0;
  font-size: 12px;
  color: var(--brand);
  border: 1px solid var(--brand);
  border-radius: 20px;
  padding: 1px 10px;
}

/* 首頁新聞卡片（右側推薦） */
.news-card {
  display: block;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid var(--line);
  background: #fff;
  transition: transform .25s, box-shadow .25s;
  height: 100%;
}
.news-card:hover { transform: translateY(-5px); box-shadow: 0 12px 28px rgba(31,45,61,.12); }
.news-card img { width: 100%; height: auto; object-fit: cover; }
.news-card .news-card-body { padding: 18px 20px; }
.news-card h5 { font-size: 15.5px; margin-bottom: 8px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.news-card p { font-size: 13px; margin: 0; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.news-card .meta { font-size: 12.5px; color: #98a6b3; margin-top: 10px; }

/* =========================================================
   首頁：合作客戶
   ========================================================= */
.clients-block { background: var(--bg-light); padding: 80px 0; }
.client-logo {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 22px;
  display: flex; align-items: center; justify-content: center;
  transition: box-shadow .2s;
}
.client-logo img { max-height: 60px; width: auto; opacity: .75; transition: .25s; }
.client-logo:hover { box-shadow: 0 8px 20px rgba(31,45,61,.1); }
.client-logo:hover img { filter: none; opacity: 1; }

/* =========================================================
   內頁通用：麵包屑 + 頁面標題橫幅
   ========================================================= */
.page-banner {
  background: linear-gradient(100deg, #0e6b5a, var(--brand));
  color: #fff;
  padding: 54px 0;
  text-align: center;
}
.page-banner h1 {
  color: #fff;
  font-size: 32px;
  letter-spacing: 2px;
  margin-bottom: 6px;
}
.page-banner .breadcrumb {
  justify-content: center;
  margin: 0;
  background: transparent;
  font-size: 13.5px;
}
.page-banner .breadcrumb-item a, .page-banner .breadcrumb-item { color: rgba(255,255,255,.8); }
.page-banner .breadcrumb-item.active { color: #fff; }
.page-banner .breadcrumb-item + .breadcrumb-item::before { color: rgba(255,255,255,.5); }

/* 內頁主體佈局 */
.page-body { padding: 60px 0 80px; background: #fff; }

/* 內頁左側欄：頁面下滑時置頂固定（sticky），移動端還原普通流 */
.page-body .row > aside {
  position: sticky;
  top: 84px;
  align-self: flex-start;
}
@media (max-width: 991.98px) {
  .page-body .row > aside { position: static; }
}

/* 左側欄 */
.sub-nav { background: var(--bg-light); border-radius: 10px; overflow: hidden; }
.sub-nav .sub-nav-title {
  background: var(--brand);
  color: #fff;
  padding: 16px 22px;
  font-size: 17px;
  font-weight: 700;
  letter-spacing: 1px;
  display: flex; align-items: center; gap: 8px;
}
.sub-nav .sub-nav-title .bi { font-size: 20px; }
.sub-nav ul { list-style: none; margin: 0; padding: 8px 0; }
.sub-nav li a {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 11px 22px;
  color: var(--navy);
  font-size: 14.5px;
  border-left: 3px solid transparent;
  transition: all .2s;
}
.sub-nav li a:hover, .sub-nav li a.active {
  background: #fff;
  color: var(--brand);
  border-left-color: var(--brand);
  font-weight: 600;
}
.side-contact {
  margin-top: 24px;
  background: var(--brand);
  color: #fff;
  border-radius: 10px;
  padding: 24px;
}
.side-contact h5 { color: #fff; font-size: 16px; margin-bottom: 12px; }
.side-contact p { font-size: 13.5px; margin-bottom: 8px; }
.side-contact .bi { margin-right: 6px; }
.side-contact .btn {
  width: 100%;
  margin-top: 8px;
  background: #fff;
  color: var(--brand);
  border-radius: 30px;
  font-weight: 600;
}
.side-contact .btn:hover { background: var(--brand-light); }

/* 右側內容 */
.page-content { padding-left: 36px; }
.page-content .content-head {
  border-bottom: 2px solid var(--line);
  padding-bottom: 14px;
  margin-bottom: 26px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.page-content .content-head h2 { font-size: 24px; margin: 0; }
.page-content .content-head span { font-size: 13px; color: #98a6b3; }

/* 正文排版 */
.article-body h3 { font-size: 19px; margin: 28px 0 12px; padding-left: 12px; border-left: 4px solid var(--brand); }
.article-body p { margin-bottom: 14px; }
.article-body img.article-img {
  border-radius: 8px;
  margin: 14px 0;
  width: 100%;
}

/* =========================================================
   關於我們：企業文化 / 發展歷程 / 榮譽資質
   ========================================================= */
.culture-item { text-align: center; padding: 30px 22px; background: var(--bg-light); border-radius: 10px; height: 100%; transition: .25s; }
.culture-item:hover { background: var(--brand-light); transform: translateY(-4px); }
.culture-item .bi { font-size: 40px; color: var(--brand); }
.culture-item h4 { font-size: 17px; margin: 14px 0 8px; }
.culture-item p { font-size: 13.5px; margin: 0; }

.timeline { position: relative; padding-left: 30px; }
.timeline::before {
  content: "";
  position: absolute;
  left: 9px; top: 6px; bottom: 6px;
  width: 2px;
  background: var(--brand-light);
}
.timeline-item { position: relative; margin-bottom: 32px; }
.timeline-item::before {
  content: "";
  position: absolute;
  left: -30px; top: 8px;
  width: 16px; height: 16px;
  border-radius: 50%;
  background: #fff;
  border: 4px solid var(--brand);
}
.timeline-item h4 { font-size: 17px; margin-bottom: 4px; }
.timeline-item .year { color: var(--brand); font-weight: 700; font-size: 15px; }
.timeline-item p { font-size: 14px; margin: 0; }

/* 榮譽資質卡片（點擊放大） */
.honor-card {
  position: relative;
  cursor: zoom-in;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid var(--line);
  background: #fff;
  transition: transform .25s, box-shadow .25s;
}
.honor-card:hover { transform: translateY(-4px); box-shadow: 0 12px 26px rgba(31,45,61,.14); }
.honor-card img { width: 100%; height: auto; object-fit: cover; display: block; }
.honor-card .honor-name {
  padding: 12px 14px;
  font-size: 14px;
  font-weight: 600;
  color: var(--navy);
  text-align: center;
}
.honor-card .zoom-hint {
  position: absolute;
  top: 8px; right: 8px;
  background: rgba(0,0,0,.45);
  color: #fff;
  font-size: 12px;
  border-radius: 20px;
  padding: 3px 10px;
}

/* =========================================================
   產品中心
   ========================================================= */
.product-card {
  display: block;
  border: 1px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
  background: #fff;
  color: var(--body);
  transition: transform .25s, box-shadow .25s;
  height: 100%;
}
.product-card:hover { transform: translateY(-6px); box-shadow: 0 14px 30px rgba(31,45,61,.13); }
.product-card .product-img-wrap { position: relative; overflow: hidden; }
.product-card .product-img-wrap img { width: 100%; height: auto; object-fit: cover; transition: transform .35s; }
.product-card:hover .product-img-wrap img { transform: scale(1.06); }
.product-card .tag {
  position: absolute;
  top: 12px; left: 12px;
  background: var(--brand);
  color: #fff;
  font-size: 12px;
  border-radius: 20px;
  padding: 2px 12px;
}
.product-card .product-body { padding: 20px; }
.product-card .product-body h3 { font-size: 17px; margin-bottom: 8px; }
.product-card .product-body p { font-size: 13.5px; margin: 0 0 12px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.product-card .view-detail { font-size: 13.5px; font-weight: 600; color: var(--brand); }
.product-card .view-detail .bi { transition: transform .2s; display: inline-block; }
.product-card:hover .view-detail .bi { transform: translateX(4px); }

/* 產品詳情頁：圖片輪播 */
.product-gallery .carousel-item img { width: 100%; height: 420px; object-fit: cover; border-radius: 10px; }
.product-gallery .carousel-thumbs { display: flex; gap: 10px; margin-top: 12px; flex-wrap: wrap; }
.product-gallery .carousel-thumbs button {
  border: 2px solid transparent;
  border-radius: 6px;
  padding: 0;
  overflow: hidden;
  background: none;
  opacity: .6;
  transition: all .2s;
}
.product-gallery .carousel-thumbs button.active { border-color: var(--brand); opacity: 1; }
.product-gallery .carousel-thumbs img { width: 60px; height: 64px; object-fit: cover; }

/* 產品參數表 */
.spec-table { width: 100%; border-collapse: collapse; }
.spec-table th, .spec-table td {
  border: 1px solid var(--line);
  padding: 12px 16px;
  font-size: 14px;
  text-align: left;
}
.spec-table th { background: var(--bg-light); color: var(--navy); width: 150px; font-weight: 600; }

/* =========================================================
   新聞列表 / 詳情
   ========================================================= */
.news-list-item {
  display: flex;
  gap: 20px;
  padding: 20px 0;
  border-bottom: 1px dashed var(--line);
  transition: background .2s;
}
.news-list-item:hover { background: var(--bg-light); }
.news-list-item img {
  width: 220px;
  height: 140px;
  object-fit: cover;
  border-radius: 8px;
  flex-shrink: 0;
}
.news-list-item .news-info h3 { font-size: 17.5px; margin-bottom: 6px; }
.news-list-item .news-info h3 a { color: var(--navy); }
.news-list-item .news-info h3 a:hover { color: var(--brand); }
.news-list-item .news-info .desc { font-size: 13.5px; margin-bottom: 8px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.news-list-item .news-info .meta { font-size: 12.5px; color: #98a6b3; }
.news-list-item .news-info .meta .bi { margin-right: 3px; }
@media (max-width: 575.98px) {
  .news-list-item { flex-direction: column; }
  .news-list-item img { width: 100%; height: auto; }
}

/* 新聞詳情 */
.news-detail-title { font-size: 26px; margin-bottom: 14px; }
.news-detail-meta {
  padding: 12px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  font-size: 13px;
  color: #98a6b3;
  margin-bottom: 24px;
}
.news-detail-meta span { margin-right: 24px; }
.news-detail-body p { margin-bottom: 16px; }
.news-detail-body h3 { font-size: 18px; margin: 24px 0 12px; }
.news-pager {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  border-top: 1px solid var(--line);
  margin-top: 34px;
  padding-top: 18px;
  font-size: 14px;
  flex-wrap: wrap;
}

/* =========================================================
   客戶案例
   ========================================================= */
.case-card {
  display: block;
  border: 1px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
  background: #fff;
  height: 100%;
  color: var(--body);
  transition: transform .25s, box-shadow .25s;
}
.case-card:hover { transform: translateY(-5px); box-shadow: 0 14px 30px rgba(31,45,61,.12); }
.case-card img { width: 100%; height: 200px; object-fit: cover; }
.case-card .case-body { padding: 20px; }
.case-card .case-body h3 { font-size: 16.5px; margin-bottom: 8px; }
.case-card .case-body p { font-size: 13.5px; margin: 0 0 12px; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.case-card .view-detail { font-size: 13.5px; font-weight: 600; color: var(--brand); }
.case-card .view-detail .bi { transition: transform .2s; display: inline-block; }
.case-card:hover .view-detail .bi { transform: translateX(4px); }

/* =========================================================
   聯繫我們
   ========================================================= */
.contact-item {
  background: var(--bg-light);
  border-radius: 10px;
  padding: 26px 20px;
  text-align: center;
  height: 100%;
  transition: .25s;
}
.contact-item:hover { background: var(--brand-light); }
.contact-item .bi { font-size: 32px; color: var(--brand); }
.contact-item h4 { font-size: 15.5px; margin: 12px 0 6px; }
.contact-item p { font-size: 14px; margin: 0; color: var(--navy); }

.contact-form {
  background: var(--bg-light);
  border-radius: 12px;
  padding: 34px;
}
.contact-form label { font-size: 14px; font-weight: 600; color: var(--navy); }
.contact-form .form-control, .contact-form .form-select {
  border-color: var(--line);
  padding: 10px 14px;
  font-size: 14px;
}
.contact-form .form-control:focus { border-color: var(--brand); box-shadow: 0 0 0 .2rem rgba(0,157,130,.15); }
.contact-form .btn-submit {
  background: var(--brand);
  border: none;
  color: #fff;
  border-radius: 30px;
  padding: 11px 40px;
  font-weight: 600;
  letter-spacing: 2px;
}
.contact-form .btn-submit:hover { background: var(--brand-dark); }

.map-wrap { border-radius: 12px; overflow: hidden; border: 1px solid var(--line); }
.map-wrap iframe, .map-wrap img { width: 100%; height: 420px; object-fit: cover; display: block; }

/* 分支機構卡片 */
.branch-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 26px 24px;
  height: 100%;
  transition: box-shadow .25s, transform .25s;
}
.branch-card:hover { box-shadow: 0 10px 26px rgba(31,45,61,.12); transform: translateY(-4px); }
.branch-card h4 { font-size: 17px; margin-bottom: 14px; display: flex; align-items: center; gap: 8px; }
.branch-card h4 .bi { color: var(--brand); font-size: 22px; }
.branch-card p { font-size: 13.5px; margin-bottom: 8px; color: var(--body); }
.branch-card p .bi { color: var(--brand); margin-right: 6px; }
.branch-card a { color: var(--body); }
.branch-card a:hover { color: var(--brand); }

/* =========================================================
   頁腳
   ========================================================= */
.site-footer {
  background: var(--footer-bg);
  color: var(--footer-text);
  padding: 64px 0 0;
  font-size: 14px;
}
.site-footer h5 {
  color: #fff;
  font-size: 16.5px;
  margin-bottom: 20px;
  letter-spacing: 1px;
}
.site-footer h5::after {
  content: "";
  display: block;
  width: 30px; height: 2px;
  background: var(--brand);
  margin-top: 10px;
}
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer ul li { margin-bottom: 9px; }
.site-footer ul a { color: var(--footer-text); }
.site-footer ul a:hover { color: #fff; }
.footer-contact li { display: flex; gap: 10px; margin-bottom: 12px; }
.footer-contact .bi { color: var(--brand); font-size: 16px; margin-top: 3px; }
.footer-logo img { height: 46px; background: rgba(255,255,255,.12); border-radius: 6px; padding: 6px 12px; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.12);
  margin-top: 44px;
  padding: 18px 0;
  font-size: 13px;
  text-align: center;
}

.footer-bottom .container a{
    color: var(--footer-text);
}
/* ---------- 關注我們：社交圖標 + 二維碼彈層 ---------- */
.footer-social-title {
  color: #fff;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 1px;
  margin: 22px 0 14px;
}
.footer-social-title::after { display: none; } /* 不套用其他 h5 的下劃線裝飾 */
.social-list {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  list-style: none;
  padding: 0;
  margin: 0;
}
.social-item { position: relative; margin-bottom: 0 !important; }
.social-link {
  width: 35px; height: 35px;
  border-radius: 50%;
  background: rgba(255,255,255,.12);
  border: 1px solid rgba(255,255,255,.25);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--footer-text);
  transition: all .25s;
}
.social-link:hover,
.social-link:focus {
  background: var(--brand);
  border-color: var(--brand);
  color: #fff;
  transform: translateY(-3px);
}
/* 圖標本體：內聯 SVG，fill 跟隨文字顏色自動變色 */
.social-icon {
  width: 19px;
  height: 19px;
  display: block;
  fill: currentColor;
}

/* 二維碼彈層：滑鼠懸停 / 鍵盤聚焦時彈出 */
.qr-popup {
  position: absolute;
  left: 50%;
  bottom: calc(100% + 14px);
  transform: translateX(-50%) translateY(8px);
  width: 148px;
  background: #fff;
  border-radius: 10px;
  padding: 10px;
  text-align: center;
  box-shadow: 0 14px 34px rgba(0,0,0,.4);
  opacity: 0;
  visibility: hidden;
  transition: all .25s;
  z-index: 20;
}
.qr-popup::after {
  content: "";
  position: absolute;
  top: 100%; left: 50%;
  transform: translateX(-50%);
  border: 8px solid transparent;
  border-top-color: #fff;
}
.qr-popup img { width: 100%; display: block; border-radius: 6px; }
.qr-popup span {
  display: block;
  font-size: 12.5px;
  color: var(--navy);
  margin-top: 6px;
  font-weight: 600;
}
.social-item:hover .qr-popup,
.social-item:focus-within .qr-popup {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}
/* 手機端：二維碼居中彈出（附全屏遮罩效果） */
@media (max-width: 767.98px) {
  .qr-popup {
    position: fixed;
    left: 50%;
    top: 50%;
    bottom: auto;
    width: 200px;
    padding: 12px;
    transform: translate(-50%, -50%) scale(.9);
    box-shadow: 0 0 0 100vmax rgba(0,0,0,.65), 0 20px 50px rgba(0,0,0,.5);
  }
  .qr-popup::after { display: none; }
  .social-item:hover .qr-popup,
  .social-item:focus-within .qr-popup { transform: translate(-50%, -50%) scale(1); }
}

/* =========================================================
   榮譽資質 Lightbox（點擊放大）
   ========================================================= */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(10,20,17,.9);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 2000;
  cursor: zoom-out;
  padding: 24px;
}
.lightbox.show { display: flex; }
.lightbox img {
  max-width: 90vw;
  max-height: 86vh;
  border-radius: 8px;
  box-shadow: 0 20px 60px rgba(0,0,0,.5);
}
.lightbox .lightbox-close {
  position: absolute;
  top: 18px; right: 24px;
  color: #fff;
  font-size: 34px;
  background: none;
  border: none;
  cursor: pointer;
  line-height: 1;
}
.lightbox .lightbox-caption {
  position: absolute;
  bottom: 20px; left: 0; right: 0;
  text-align: center;
  color: rgba(255,255,255,.85);
  font-size: 14px;
}

/* =========================================================
   返回頂部
   ========================================================= */
.back-top {
  position: fixed;
  right: 22px; bottom: 26px;
  width: 44px; height: 44px;
  background: var(--brand);
  color: #fff;
  border: none;
  border-radius: 50%;
  font-size: 18px;
  display: none;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 20px rgba(0,157,130,.4);
  z-index: 999;
  cursor: pointer;
}
.back-top.show { display: flex; }
.back-top:hover { background: var(--brand-dark); }

/* =========================================================
   響應式微調
   ========================================================= */
@media (max-width: 991.98px) {
  .page-content { padding-left: 0; padding-top: 36px; }
  .intro-block, .cat-block, .news-block, .clients-block { padding: 54px 0; }
  .section-title h2 { font-size: 26px; }
  .product-gallery .carousel-item img { height: 320px; }
}
@media (max-width: 575.98px) {
  .page-banner { padding: 38px 0; }
  .page-banner h1 { font-size: 24px; }
  .contact-form { padding: 22px; }
  .footer-bottom { font-size: 12px; }
}
