/*!
Theme Name: design_hu 2025
Theme URI: https://www.design-hu.com/
Author: design_hu by Peter Chen
Author URI: https://www.design-hu.com/
Description: Description
Version: 1.0.0
Tested up to: 6.0
Requires PHP: 8.0
*/

/* ================================================================= */
/* header 導航列 */
#webNavigation .designhuHeader {
  display: flex;
  gap: 32px;
  padding: 8px 0;
}
/* 確保父層 li 是相對定位 */
.designhuHeader li {
  position: relative;
}
/* 隱藏子選單 */
.designhuHeader .sub-menu {
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  opacity: 0;
  visibility: hidden; /* 讓元素徹底「不可見」且不參與交互 */
  pointer-events: none; /* 讓滑鼠點不到、碰不到它 */

  transition: all 0.3s ease;
  padding-top: 1rem;
  background: transparent; /* 背景由 ::before 處理 */
  width: 12rem;
  z-index: 50;
  display: flex;
  flex-direction: column;
  border-radius: 0.75rem;
  overflow: hidden;
}
.designhuHeader .sub-menu::before {
  content: "";
  position: absolute;
  top: 1rem;
  left: 0;
  right: 0;
  bottom: 0;
  /* width: 100%;
  height: calc(100% - 1rem); */
  background: #ffffff;
  border-radius: 0.75rem;
  border: 1px solid #f1f5f9;
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
  z-index: -1;
  overflow: hidden;
}
/* 頂部漸層線 (利用偽元素實作) */
.designhuHeader .sub-menu::after {
  content: "";
  position: absolute;
  top: 1rem;
  left: 2px;
  width: calc(100% - 5px);
  height: 4px;
  background: linear-gradient(to right, #0055a5, #ef4444);
  z-index: 1;
  border-radius: 0.75rem 0.75rem 0 0;
}
/* 子選單項目的樣式 */
.designhuHeader .sub-menu li a {
  display: flex;
  align-items: center;
  padding: 12px 20px;
  white-space: nowrap;
  font-size: 0.875rem;
  line-height: 1.25rem;
  font-weight: 500;
  transition: all 0.2s ease;
}
.designhuHeader .sub-menu li:first-child {
  margin-top: 0.5rem;
}
.designhuHeader .sub-menu li:last-child {
  margin-bottom: 0.5rem; /* py-2 的補償 */
}
/* 麵包屑 */
@media (max-width: 1024px) {
  .bread {
    padding: 8px 20px;
  }
}
@media (min-width: 1280px) {
  .bread {
    padding: 8px 0px;
  }
}
@media (min-width: 1920px) {
  .bread {
    padding: 8px 150px;
  }
}
.bread {
  margin-bottom: 60px;
}

/* 隱私權政策 */
.entry-content {
  padding: 100px 40px 40px 40px;
  line-height: 2;
}
/* 隱私權政策 ======= */

/* --- 匯集頁 pagination 樣式 ---  */
.page-numbers {
  width: 30px;
  height: 30px;
  text-align: center;
  display: inline-flex;
  align-items: center;
  justify-content: center;

  border: 1px solid #f2f2f2;
  color: #4d4d4d;
  line-height: 120%;
  font-weight: 500;
}
/* 當前頁 */
.page-numbers.current {
  background-color: #1a1a1a;
  color: #ffffff;
  font-weight: 600;
}
.prev,
.next {
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: white;
  border: 1px solid #f2f2f2;
}

.hu-pagination .page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.hu-pagination .page-numbers.disabled {
  pointer-events: none;
  background-color: #0551a31a;
  opacity: 0.6;
  border: 1px solid #f2f2f2;
}
/* --- 匯集頁 pagination 樣式 end --- */

/* --- header 手機版漢堡線 --- */
.hamberger .line {
  display: block;
  width: 28px;
  height: 2px;
  background-color: #475569;
  border-radius: 100px;
  transition: all 0.3s ease;
}

/* active 時變成 X */
.hamberger.active .top {
  transform: translateY(11px) rotate(45deg);
}

.hamberger.active .middle {
  opacity: 0;
}

.hamberger.active .bottom {
  transform: translateY(-11px) rotate(-45deg);
}
/* --- header 手機版漢堡線 end--- */

/* --- header 手機版選單 --- */
.web_nav_m.open {
  transform: translateX(0);
  opacity: 1;
}

/* 手機選單背景模糊 */
.menu-backdrop {
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  background: rgba(0, 0, 0, 0.4); /* 背景遮罩 */
}
/* 建築工程類 - 代理原廠品牌卡片 */
.brand-card {
  filter: grayscale(100%) opacity(70%);
  transition: all 0.4s ease;
}
/* 公司組織圖 */
/* 股東會 */
.org-node-top {
  display: inline-block;
  background-color: white;
  border: 1px solid #e3000f;
  border-top: 4px solid #e3000f;
  border-radius: 0.5rem;
  padding: 1rem 1.5rem;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  font-weight: 700;
  color: #1e293b;
  min-width: 140px;
  position: relative;
  z-index: 10;
  transition: all 0.3s;
}
.org-node {
  display: inline-block;
  background-color: white;
  border: 1px solid #e2e8f0;
  border-top: 4px solid #0055a5;
  border-radius: 0.5rem;
  padding: 1rem 1.5rem;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  font-weight: 700;
  color: #1e293b;
  min-width: 140px;
  position: relative;
  z-index: 10;
  transition: all 0.3s;
}
.org-tree ul {
  padding-top: 20px;
  position: relative;
  transition: all 0.5s;
  display: flex;
  justify-content: center;
}
.org-tree ul ul::before {
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  border-left: 2px solid #cbd5e1;
  width: 0;
  height: 20px;
  transform: translateX(-1px);
}
.staff-node {
  position: absolute;
  left: calc(50% + 100px);
  top: 50%;
  transform: translateY(-50%);
  background-color: #f8fafc;
  border-top: 4px solid #64748b;
}
/* 此 ul 裡唯一的 li */
.org-tree li:only-child {
  padding-top: 0;
}
.org-tree li {
  text-align: center;
  list-style-type: none;
  position: relative;
  padding: 20px 10px 0 10px;
  transition: all 0.5s;
}
.org-tree li:first-child::before,
.org-tree li:last-child::after {
  border: 0 none;
}
.org-tree li:first-child::after {
  border-radius: 5px 0 0 0;
}
.org-tree li:last-child::before {
  border-right: 2px solid #cbd5e1;
  border-radius: 0 5px 0 0;
}
.org-tree li::after {
  right: auto;
  left: 50%;
  border-left: 2px solid #cbd5e1;
}
.org-tree li::before,
.org-tree li::after {
  content: "";
  position: absolute;
  top: 0;
  right: 50%;
  border-top: 2px solid #cbd5e1;
  width: 50%;
  height: 20px;
}
.staff-branch {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 100px;
  border-top: 2px dashed #94a3b8;
  z-index: 0;
}
/* .vertical-sub-list {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-top: 20px;
  position: relative;
}
.vertical-node {
  background: white;
  border: 1px solid #e2e8f0;
  border-left: 4px solid #0055a5;
  padding: 0.5rem 1rem;
  margin-bottom: 10px;
  border-radius: 0.25rem;
  font-size: 0.875rem;
  font-weight: 500;
  position: relative;
  z-index: 1;
  width: 120px;
}
.vertical-sub-list::before {
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  width: 2px;
  height: 100%;
  background-color: #cbd5e1;
  transform: translateX(-1px);
  z-index: 0;
} */
/* 公司組織圖 end ＝＝＝＝＝ */
/* 全站hover 效果===== */
@media (min-width: 1024px) {
  /* header 選單 */
  .designhuHeader .menu-item a:hover {
    color: #0055a5;
  }
  .designhuHeader .sub-menu li a:hover {
    color: #0055a5;
    background-color: #f8fafc;
  }
  /* Hover 時顯示子選單 */
  .designhuHeader li:hover > .sub-menu {
    opacity: 1;
    visibility: visible; /* 恢復可見 */
    pointer-events: auto; /* 恢復可點擊、可觸碰 */
    transform: translateX(-50%) translateY(0px);
  }
  /* 建築工程類 - 代理原廠品牌卡片 */
  .brand-card:hover {
    filter: grayscale(0%) opacity(100%);
    transform: translateY(-5px);
    box-shadow: 0 10px 25px -5px rgba(0, 85, 165, 0.15);
    border-color: #0055a5;
  }
  /* 電子應用類 - 產品卡片 */
  .category-card:hover .icon-wrapper {
    background-color: #0055a5;
    color: #ffffff;
    transform: scale(1.1);
  }
  .category-card:hover {
    border-color: #0055a5;
    box-shadow: 0 10px 25px -5px rgba(0, 85, 165, 0.15);
  }
  /* 公司組織 */
  .org-node:hover {
    border-top-color: #e3000f;
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
  }
  .org-node-top:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
  }
  /* 公司簡介 - 核心價值 */
  .value-card:hover .icon-box {
    background-color: #e3000f;
    color: white;
    transform: scale(1.1);
  }
  /* 首頁 banner 跑馬燈 */
  .brand-carousel-track:hover {
    animation-play-state: paused;
  }
}
/* 全站hover 效果===== */
/* 首頁 banner 跑馬燈 */
.brand-carousel-container {
  overflow: hidden;
  -webkit-mask-image: linear-gradient(
    to right,
    transparent,
    black 5%,
    black 95%,
    transparent
  );
  mask-image: linear-gradient(
    to right,
    transparent,
    black 5%,
    black 95%,
    transparent
  );
  padding: 1rem 0 2rem 0;
}
.brand-carousel-track {
  display: flex;
  width: max-content;
  animation: scrollBrands 25s linear infinite;
}
@keyframes scrollBrands {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(-50%);
  }
}
.brand-card-item {
  width: 180px;
  margin-right: 1rem;
}
@media (min-width: 768px) {
  .brand-card-item {
    width: 200px;
    margin-right: 1.5rem;
  }
}
/* 首頁 banner 跑馬燈 ＝＝＝*/
.tech-grid {
  background-image: linear-gradient(
      to right,
      rgba(255, 255, 255, 0.05) 1px,
      transparent 1px
    ),
    linear-gradient(to bottom, rgba(255, 255, 255, 0.05) 1px, transparent 1px);
  background-size: 40px 40px;
}
/* 單頁切換系統樣式 */
.page-view {
  display: none;
  opacity: 0;
  transition: opacity 0.4s ease-in-out;
}
.page-view.active {
  display: block;
  opacity: 1;
  animation: slideUp 0.5s ease-out;
}
@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
/* 隱藏滾動條但保持可滾動 */
.no-scrollbar::-webkit-scrollbar {
  display: none;
}
.no-scrollbar {
  -ms-overflow-style: none;
  scrollbar-width: none;
}

/* 投資人專區 左側選單 Tab 選中狀態樣式 */
.ir-tab-btn.active {
  background-color: #0055a5 !important;
  color: white !important;
  box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1);
  cursor: default;
}

/* 控制箭頭顯示：
   1. 在 .active 狀態下的箭頭強制顯示 (opacity-100)
   2. 在 hover 狀態下也顯示 (透過 Tailwind 的 group-hover 處理)
*/
.ir-tab-btn.active svg {
  opacity: 1 !important;
}

/* 電子應用 核心遮罩樣式 */
.icon-mask {
  /* 確保容器大小與設定一致 */
  display: inline-block;
  /* 使用 mask 控制圖案 */
  -webkit-mask-size: contain;
  mask-size: contain;
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
  -webkit-mask-position: center;
  mask-position: center;
  /* 圖案最後呈現的顏色 */
  background-color: currentColor;
}
