/* =========================================
   首頁專用樣式：Hero 輪播 / 產業跑馬燈 / 核心優勢 / 製程總覽卡
   ========================================= */

/* 滿版實拍影片橫幅（首頁最上方，三語系皆有各自燒錄字幕的版本，不疊加額外文字/底色） */
.process-video-banner { width: 100%; overflow: hidden; background: #000; line-height: 0; }
.process-video-banner-el { width: 100%; display: block; aspect-ratio: 16 / 9; max-height: 640px; object-fit: cover; }
@media (max-width: 700px) { .process-video-banner-el { max-height: 380px; } }

.hero-slider { position: relative; width: 100%; height: 72vh; min-height: 460px; max-height: 720px; overflow: hidden; background: var(--brand-navy); }
.hero-track { display: flex; width: 100%; height: 100%; transition: transform 0.7s cubic-bezier(.65,0,.35,1); }
.hero-slide {
  flex: 0 0 100%;
  width: 100%; height: 100%;
  background-size: cover;
  background-position: center;
  display: flex; align-items: center; justify-content: center;
  position: relative;
}
.hero-slide::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(11,31,61,0.55) 0%, rgba(11,31,61,0.35) 50%, rgba(11,31,61,0.7) 100%);
}
/* 製程總覽這張圖已經自己在圖片左右六格標好製程名稱與底部成品照，不疊加任何文字/暗化 */
.hero-slide--flat::after { content: none; }
.hero-slide-content { position: relative; z-index: 2; max-width: 780px; padding: 20px; text-align: center; color: #fff; animation: fadeInUp 0.8s ease; }
.hero-slide-content h1 { color: #fff; font-size: 46px; margin-bottom: 18px; text-shadow: 0 2px 8px rgba(0,0,0,0.35); }
.hero-slide-content p { color: rgba(255,255,255,0.92); font-size: 19px; margin-bottom: 28px; text-shadow: 0 1px 6px rgba(0,0,0,0.3); }
.hero-sub-short { display: none; }

.hero-nav-btn {
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 44px; height: 44px; border-radius: 50%;
  background: rgba(255,255,255,0.15); border: 1px solid rgba(255,255,255,0.4); color: #fff;
  display: flex; align-items: center; justify-content: center;
  z-index: 3; transition: background var(--transition);
}
.hero-nav-btn:hover { background: rgba(255,255,255,0.3); }
.hero-prev { left: 20px; }
.hero-next { right: 20px; }

.hero-dots { position: absolute; bottom: 28px; left: 50%; transform: translateX(-50%); display: flex; align-items: center; gap: 8px; z-index: 3; }
.hero-dot { width: 9px; height: 9px; border-radius: 999px; background: rgba(255,255,255,0.45); border: none; padding: 0; transition: width var(--transition), background var(--transition); }
.hero-dot.active { width: 30px; background: rgba(255,255,255,0.95); }

@keyframes fadeInUp { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: translateY(0); } }

/* ---------- Industries marquee ---------- */
.marquee-section { padding: 44px 0; background: var(--white); border-bottom: 1px solid var(--border-color); text-align: center; }
.marquee-title { font-size: 14px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-muted); font-weight: 700; margin-bottom: 26px; }
.marquee-wrap { position: relative; overflow: hidden; }
.marquee-wrap::before, .marquee-wrap::after {
  content: ""; position: absolute; top: 0; width: 90px; height: 100%; z-index: 2;
}
.marquee-wrap::before { left: 0; background: linear-gradient(to right, #fff, rgba(255,255,255,0)); }
.marquee-wrap::after { right: 0; background: linear-gradient(to left, #fff, rgba(255,255,255,0)); }
.marquee-track { display: inline-flex; animation: marqueeScroll 26s linear infinite; }
.marquee-wrap:hover .marquee-track { animation-play-state: paused; }
.marquee-item {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 10px 34px; margin: 0 6px; flex-shrink: 0;
  font-weight: 700; color: var(--brand-navy); font-size: 15px;
  border: 1px solid var(--border-color); border-radius: 999px;
  white-space: nowrap;
}
@keyframes marqueeScroll { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* ---------- Vision tags (首頁「核心焦點」區塊) ---------- */
.vision-tags { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; margin-top: 30px; }
.vision-tag {
  padding: 10px 22px; border: 1.5px solid var(--brand-red); color: var(--brand-red);
  border-radius: 999px; font-weight: 600; font-size: 14px;
}

/* ---------- Feature grid ---------- */
.feature-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 26px; }
.feature-box {
  background: var(--white); border-top: 4px solid var(--brand-red);
  border-radius: var(--radius); box-shadow: var(--shadow-sm);
  padding: 30px 24px; transition: transform var(--transition), box-shadow var(--transition);
}
.feature-box:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); }
.feature-box .feature-num { font-size: 13px; font-weight: 800; color: var(--brand-red); letter-spacing: 0.08em; }
.feature-box h3 { font-size: 19px; margin: 10px 0 12px; }
.feature-box p { font-size: 14px; color: var(--text-muted); margin: 0; }

/* 深色版區塊底色（原本「為什麼選擇翰霖」跟「專業表面處理」對調用色，這個給前者） */
.section-dark { background: linear-gradient(135deg, var(--brand-navy) 0%, var(--brand-navy-light) 100%); }
.section-dark .section-title { color: #fff; }
.section-dark .section-subtitle { color: rgba(255,255,255,0.78); }

@media (max-width: 992px) {
  .hero-slider { height: 56vh; }
  .feature-grid { grid-template-columns: repeat(2, 1fr); }
  /* 手機版每張 slide 都不裁切：容器高度貼合「目前顯示中」那張圖片自己的比例（由 slider.js
     依 data-aspect 動態設定 --hero-aspect），而不是固定 56vh 硬裁或留白 */
  .hero-slide { background-size: contain; background-repeat: no-repeat; }
  .hero-slider.hero-slider--fit-active { height: auto; aspect-ratio: var(--hero-aspect, 16 / 9); min-height: 0; max-height: none; }
  /* 容器變矮之後（16:9 大約只剩不到螢幕寬度的一半高），文字疊加也要跟著縮小＋換成簡短說明，
     不然會被裁掉（見對話紀錄：完整版標題+說明+按鈕在這個高度會超出畫面） */
  .hero-slide-content { padding: 10px 16px; }
  .hero-slide-content h1 { font-size: 17px; margin-bottom: 6px; line-height: 1.3; }
  .hero-sub-full { display: none; }
  .hero-sub-short { display: block; font-size: 12.5px; margin-bottom: 10px; }
  .hero-slide-content .btn { padding: 7px 20px; font-size: 12.5px; }
}
@media (max-width: 600px) {
  .hero-nav-btn { display: none; }
  .feature-grid { grid-template-columns: 1fr; }
}
