/* ===== INTRO SECTION (Image + Text) ===== */
.intro {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--intro-gap);
  align-items: center;
}

.intro--reverse {
  direction: rtl;
}

.intro--reverse > * {
  direction: ltr;
}

.intro__image {
  /* 預設:gallery 版 intro (558x382),4 角圓角 */
  min-width: 0;
  border-radius: var(--radius-image);
}

.intro__content {
  min-width: 0;
}

.intro__image > img,
.intro__image > .gallery-main-wrap {
  border-radius: var(--radius-image);
  overflow: hidden;
  display: block;
}

.intro__image > img {
  width: 100%;
  height: 382px;
  object-fit: cover;
}

.intro__image .gallery-main-wrap {
  width: 100%;
  height: 382px;
}

.intro__image .gallery-main-wrap > img.gallery-main {
  width: 100%;
  height: 382px;
  object-fit: cover;
  display: block;
}

/* --tall 變體:Engineering / Manufacturing Services (golden ref, 無 gallery) */
.intro__image--tall {
  border-radius: var(--radius-image);
  overflow: hidden;
  aspect-ratio: 556 / 618;
}

.intro__image--tall > img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.intro__content h2,
.intro__content h3 {
  margin-bottom: var(--space-lg);
}

.intro__content p {
  color: var(--color-text-light);
  line-height: var(--line-height-loose);
}

.intro__content .btn {
  margin-top: var(--space-lg);
}

/* ===== ICON GRID ===== */
.icon-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--icon-grid-gap);
}

.icon-grid--2col {
  grid-template-columns: repeat(2, 1fr);
}

.icon-grid--4col {
  grid-template-columns: repeat(4, 200px);
  justify-content: center;
  gap: 60px 50px;
}

.icon-grid--4col .icon-card__icon {
  width: 64px;
  height: 64px;
}

.icon-grid--4col .icon-card__icon svg {
  width: 64px;
  height: 64px;
  stroke-width: 1.5;
}

.icon-grid--4col .icon-card__title {
  font-size: 18px;
}

.icon-grid-container {
  background: var(--color-primary-light);
  border-radius: var(--radius-card);
  padding: var(--icon-grid-padding);
}

/* Full-width blue patch variant (Solutions pages) */
.section--bluepatch-fullwidth {
  padding: 0;
}

.icon-grid-container--fullwidth {
  width: 100%;
  max-width: none;
  padding: 60px 0;
  border-radius: 0;
  margin-top: 0;
  background: var(--color-primary-light);
}

.icon-grid-container--fullwidth > .container {
  max-width: var(--container-max, 1200px);
  margin: 0 auto;
  padding: 0 var(--container-padding, 24px);
}

.icon-grid-container--fullwidth .section__title {
  margin-bottom: 40px;
  text-align: center;
}

.icon-card {
  text-align: center;
  padding: 0;
  display: flex;
  flex-direction: column;
  height: 100%;
}

.icon-card__icon {
  width: 94px;
  height: 94px;
  margin: 0 auto var(--space-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-icon);
}

/* About Us — People & Culture values: tighter gap + smaller icon gutter */
.icon-grid--about-values {
  --icon-grid-gap: 10px;
}
.icon-grid--about-values .icon-card__icon {
  margin: 0 auto var(--space-md);
}

.icon-card__icon svg {
  width: 48px;
  height: 48px;
  stroke: var(--color-icon);
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.icon-card__title {
  font-size: var(--font-size-h3);
  font-weight: var(--font-weight-bold);
  margin-bottom: 16px;
  min-height: 1em;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  text-align: center;
}

/* Title-row modifiers: align titles that wrap across a row */
.icon-grid--title-2row .icon-card__title,
.icon-grid--title-2row .icon-card--boxed .icon-card__title {
  min-height: 2em;
}

.icon-grid--title-3row .icon-card__title,
.icon-grid--title-3row .icon-card--boxed .icon-card__title {
  min-height: 3em;
}

.icon-card__desc {
  font-size: var(--font-size-body);
  color: var(--color-text-light);
  line-height: var(--line-height-body);
  flex-grow: 1;
}

/* Icon card boxed variant */
.icon-grid--boxed {
  gap: 74px 30px;
  justify-items: center;
  align-items: stretch;
}

.icon-card--boxed {
  background: #FFFFFF;
  border-radius: 15px;
  box-shadow: 8px 13px 25.6px rgba(0, 0, 0, 0.1);
  padding: 40px 30px;
  max-width: 300px;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  gap: 20px;
}

.icon-card--boxed .icon-card__icon {
  margin: 0;
  flex-shrink: 0;
}

.icon-card--boxed .icon-card__title {
  font-family: 'Heebo', sans-serif;
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 0;
  min-height: 1em;
  flex-shrink: 0;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  text-align: center;
}

.icon-card--boxed .icon-card__desc {
  font-family: 'Heebo', sans-serif;
  font-size: 20px;
  font-weight: 400;
  line-height: 29px;
  margin-bottom: 0;
  flex: 1;
}

/* Icon card boxed 4-column variant */
.icon-grid--4col.icon-grid--boxed {
  grid-template-columns: repeat(4, 1fr);
  gap: 40px 24px;
}

.icon-grid--4col.icon-grid--boxed .icon-card__icon {
  width: 94px;
  height: 94px;
}

.icon-grid--4col.icon-grid--boxed .icon-card__icon svg {
  width: 48px;
  height: 48px;
  stroke-width: 2;
}

.icon-grid--4col.icon-grid--boxed .icon-card__desc {
  font-size: 16px;
}

/* ===== GALLERY ===== */
.gallery-main,
.zigzag__image img.gallery-main {
  width: 100%;
  height: 378px;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease, opacity 0.4s ease;
}

.intro__image img.gallery-main {
  /* intro 區大圖由 .intro__image > img 規則控制(382px) */
  transition: transform 0.4s ease, opacity 0.4s ease;
}

.gallery {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 24px;
  min-width: 0;
}

.gallery__track {
  display: flex;
  gap: 10px;
  overflow: hidden;
  transition: transform 0.3s ease;
  min-width: 0;
  flex: 1;
}

.gallery__thumb {
  width: 152px;
  height: 102px;
  object-fit: cover;
  border-radius: 5px;
  cursor: pointer;
  flex-shrink: 0;
  transition: opacity 0.3s ease;
}

.gallery__thumb:hover {
  opacity: 0.7;
}

.gallery__thumb--active {
  opacity: 0.5;
}

.gallery__arrow {
  flex-shrink: 0;
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
}

/* ===== GALLERY MAIN WRAP ===== */
.gallery-main-wrap {
  overflow: hidden;
  position: relative;
}

/* ===== GALLERY LIGHTBOX ===== */
.gallery-lightbox {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(0, 0, 0, 0.85);
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.gallery-lightbox__img {
  max-width: 90vw;
  max-height: 90vh;
  object-fit: contain;
  border-radius: 8px;
}

.gallery-lightbox__close {
  position: absolute;
  top: 20px;
  right: 30px;
  font-size: 40px;
  color: #fff;
  background: none;
  border: none;
  cursor: pointer;
  z-index: 10000;
}

/* ===== ZIGZAG ===== */
.zigzag {
  display: flex;
  flex-direction: column;
  gap: var(--zigzag-row-gap);
  padding: 0 10px;
}

.zigzag__item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: var(--zigzag-gap);
  align-items: center;
}

.zigzag__item:nth-child(even) {
  direction: rtl;
}

.zigzag__item:nth-child(even) > * {
  direction: ltr;
}

.zigzag__image {
  border-radius: var(--radius-image);
  overflow: hidden;
  width: 100%;
  height: 378px;
}

.zigzag__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

.zigzag__content {
  padding-left: 25px;
  padding-right: 5px;
}

.zigzag__content h3 {
  margin-bottom: var(--space-md);
  font-size: var(--font-size-h3);
}

.zigzag__content p {
  font-size: var(--font-size-body);
  color: var(--color-text-light);
  line-height: var(--line-height-body);
}

/* ===== STATS ===== */
.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--grid-gap);
  text-align: center;
}

.stats--8 {
  grid-template-columns: repeat(4, 1fr);
}

.stat__number {
  font-size: var(--font-size-4xl);
  font-weight: var(--font-weight-bold);
  color: var(--color-accent-red);
  line-height: 1;
  margin-bottom: var(--space-xs);
}

.stat__label {
  font-size: var(--font-size-sm);
  color: var(--color-text-light);
}

/* ===== FEATURE CARDS ===== */
.feature-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--grid-gap);
}

.feature-cards--2x3 {
  grid-template-columns: repeat(3, 1fr);
}

.feature-card {
  background-color: var(--color-white);
  border-radius: var(--radius-md);
  padding: var(--space-xl);
  box-shadow: var(--shadow-sm);
  transition: box-shadow var(--transition-base), transform var(--transition-base);
  text-align: center;
}

.feature-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.feature-card__icon {
  width: 56px;
  height: 56px;
  margin: 0 auto var(--space-md);
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--color-icon);
  border-radius: var(--radius-md);
  color: var(--color-icon);
}

.feature-card__icon svg {
  width: 28px;
  height: 28px;
  stroke: var(--color-icon);
  fill: none;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.feature-card__title {
  font-size: var(--font-size-base);
  font-weight: var(--font-weight-semibold);
  margin-bottom: var(--space-sm);
}

.feature-card__desc {
  font-size: var(--font-size-sm);
  color: var(--color-text-light);
  margin-bottom: var(--space-md);
}

.feature-card__link {
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-semibold);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* ===== CERTIFICATE GRID ===== */
.cert-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--grid-gap-lg);
  text-align: center;
}

.cert-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-lg);
}

.cert-card__image {
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  width: 200px;
  height: 280px;
  background: #fff;
}

.cert-card__image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.cert-card__title {
  font-size: var(--font-size-lg);
  font-weight: var(--font-weight-bold);
}

.cert-card {
  cursor: pointer;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.cert-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg, 0 10px 30px rgba(0,0,0,0.15));
}

/* ===== LIGHTBOX ===== */
.lightbox {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(0, 0, 0, 0.85);
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.lightbox--active {
  display: flex;
}

.lightbox__img {
  max-width: 90vw;
  max-height: 90vh;
  object-fit: contain;
  border-radius: 8px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.lightbox__close {
  position: absolute;
  top: 20px;
  right: 30px;
  background: none;
  border: none;
  color: white;
  font-size: 48px;
  cursor: pointer;
  line-height: 1;
  z-index: 10000;
  transition: opacity 0.3s ease;
}

.lightbox__close:hover {
  opacity: 0.7;
}

/* ===== TIMELINE ===== */
.timeline {
  position: relative;
  padding: var(--space-xl) 0;
}

.timeline__track {
  display: flex;
  gap: var(--space-3xl);
  overflow-x: auto;
  padding-bottom: var(--space-xl);
  scrollbar-width: thin;
}

.timeline__item {
  flex: 0 0 280px;
  text-align: center;
}

.timeline__year {
  font-size: var(--font-size-2xl);
  font-weight: var(--font-weight-bold);
  color: var(--color-primary);
  margin-bottom: var(--space-sm);
}

.timeline__title {
  font-size: var(--font-size-base);
  font-weight: var(--font-weight-semibold);
  margin-bottom: var(--space-sm);
}

.timeline__desc {
  font-size: var(--font-size-sm);
  color: var(--color-text-light);
}

/* ===== VALUES LIST ===== */
.value-card__list {
  list-style: none;
  padding: 0;
  margin: 0;
  text-align: left;
}

.value-card__list li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: var(--font-size-sm);
  color: var(--color-text-light);
  padding: 6px 0;
}

.value-card__list li svg {
  flex-shrink: 0;
}

/* ===== VALUES HERO OVERLAY ===== */
.values-hero {
  background-size: cover;
  background-position: center;
  padding: 80px 0;
  position: relative;
}

.values-hero .container {
  max-width: 1200px;
  padding-left: 24px;
  padding-right: 24px;
}

.values-overlay {
  display: flex;
  gap: 30px;
  justify-content: center;
}

.values-overlay__card {
  width: 361px;
  flex-shrink: 0;
  height: 470px;
  background: #FFFFFF;
  border-radius: 15px;
  box-shadow: 8px 13px 25.6px rgba(0, 0, 0, 0.1);
  padding: 40px 30px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  overflow: hidden;
}

.values-overlay__icon {
  display: flex;
  align-items: center;
  justify-content: flex-start;
}

.values-overlay__icon svg {
  width: 80px;
  height: 80px;
}

.values-overlay__title {
  font-family: 'Heebo', sans-serif;
  font-size: 28px;
  font-weight: 700;
  line-height: 105.83%;
  text-align: left;
  color: #000000;
  margin-top: 10px;
}

.values-overlay__desc {
  font-family: 'Heebo', sans-serif;
  font-size: 16px;
  font-weight: 400;
  line-height: 24px;
  text-align: left;
  color: #333;
  margin-top: 12px;
}

.values-overlay__items {
  display: flex;
  flex-direction: column;
  gap: 35px;
  margin-top: 12px;
}

.values-overlay__items span {
  font-family: 'Heebo', sans-serif;
  font-size: 20px;
  font-weight: 700;
  text-align: left;
  color: #000;
}

/* ===== JOURNEY TIMELINE ===== */
.journey__dots-viewport {
  overflow-x: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.journey__dots-viewport::-webkit-scrollbar {
  display: none;
}

.journey__dots-row {
  display: flex;
  gap: 40px;
  align-items: flex-start;
  min-width: max-content;
  padding-bottom: 10px;
  position: relative;
}

.journey__dots-row::after {
  content: '';
  position: absolute;
  top: 55px;
  left: 0;
  right: 0;
  border-top: 2px dashed #D9D9D9;
  pointer-events: none;
}

.journey__dot {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  cursor: pointer;
  position: relative;
  z-index: 1;
  flex-shrink: 0;
}

.journey__dot-year {
  font-family: 'Inter', 'Heebo', sans-serif;
  font-size: 21px;
  font-weight: 700;
  color: #333;
}

.journey__dot-circle {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #EFFAFF;
  border: 2px solid #EFFAFF;
  transition: background 0.3s ease, border-color 0.3s ease;
}

.journey__dot--active .journey__dot-circle {
  background: #2AAAEC;
  border-color: #2AAAEC;
}

.journey__dot--active .journey__dot-year {
  color: #2AAAEC;
}

.journey__dot-label {
  font-family: 'Heebo', sans-serif;
  font-size: 20px;
  font-weight: 400;
  line-height: 29px;
  text-align: left;
  color: #000;
  width: 192px;
}

.journey__dot--active .journey__dot-label {
  font-weight: 700;
}

.journey__detail {
  margin-top: 50px;
  text-align: left;
  min-height: 130px;
}

.journey__detail-year {
  font-family: 'Heebo', sans-serif;
  font-size: 52px;
  font-weight: 700;
  color: #2AAAEC;
  line-height: 1;
  transition: opacity 0.3s ease;
}

.journey__detail-title {
  font-family: 'Heebo', sans-serif;
  font-size: 36px;
  font-weight: 700;
  color: #000;
  margin-top: 8px;
  transition: opacity 0.3s ease;
}

.journey__detail-desc {
  font-family: 'Heebo', sans-serif;
  font-size: 20px;
  font-weight: 400;
  color: #000000;
  margin-top: 16px;
  line-height: 1.6;
  max-width: 700px;
  min-height: 150px;
  transition: opacity 0.3s ease;
}

.journey__detail-desc ul {
  list-style: disc;
  padding-left: 20px;
  margin: 0;
}

.journey__detail-desc li {
  margin-bottom: 8px;
}

.journey__arrows {
  display: flex;
  gap: 100px;
  margin-bottom: 36px;
}

.journey__arrow {
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  line-height: 0;
}

.journey__arrow:hover path {
  stroke: #2AAAEC;
}

/* ===== PROCESS STEPS ===== */
.process-steps {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: var(--space-md);
  padding: var(--space-xl);
  background: linear-gradient(135deg, var(--color-primary), var(--color-primary-dark));
  border-radius: var(--radius-lg);
  flex-wrap: wrap;
}

.process-step {
  flex: 1;
  min-width: 120px;
  text-align: center;
  color: var(--color-white);
  position: relative;
  padding: 0 var(--space-sm);
}

.process-step__number {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-full);
  background-color: rgba(255,255,255,0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto var(--space-sm);
  font-weight: var(--font-weight-bold);
  font-size: var(--font-size-sm);
}

.process-step__title {
  font-size: var(--font-size-xs);
  font-weight: var(--font-weight-semibold);
  line-height: var(--line-height-tight);
}

.process-step::after {
  content: '';
  position: absolute;
  top: 18px;
  right: calc(-1 * var(--space-sm));
  width: var(--space-md);
  height: 2px;
  background-color: rgba(255,255,255,0.4);
}

.process-step:last-child::after {
  display: none;
}

/* ===== PROCESS ARROWS ===== */
.process-arrows {
  display: flex;
  justify-content: center;
  margin-top: 40px;
}

.process-arrow {
  position: relative;
  width: 226px;
  height: 153px;
  flex-shrink: 0;
  margin-left: -30px;
}

.process-arrow:first-child {
  margin-left: 0;
}

.process-arrow__bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.process-arrow__content {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  padding: 10px 30px 10px 50px;
  color: white;
  text-align: center;
}

.process-arrow__icon {
  width: 40px;
  height: 40px;
}

.process-arrow__label {
  font-size: 13px;
  font-weight: 700;
  margin-top: 12px;
  line-height: 1.3;
  min-height: 2.6em;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  text-align: center;
}

/* ===== VISION/MISSION/VALUES ===== */
.values-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--grid-gap);
}

.value-card {
  background-color: var(--color-white);
  border-radius: var(--radius-md);
  padding: var(--space-2xl);
  box-shadow: var(--shadow-sm);
  text-align: center;
}

.value-card__icon {
  width: 56px;
  height: 56px;
  margin: 0 auto var(--space-lg);
  color: var(--color-primary);
  display: flex;
  align-items: center;
  justify-content: center;
}

.value-card__icon svg {
  width: 40px;
  height: 40px;
  stroke: var(--color-primary);
  fill: none;
  stroke-width: 1.5;
}

.value-card__title {
  font-size: var(--font-size-lg);
  font-weight: var(--font-weight-bold);
  margin-bottom: var(--space-md);
}

.value-card__desc {
  font-size: var(--font-size-sm);
  color: var(--color-text-light);
}

/* ===== MAP ===== */
.map-section {
  text-align: center;
}

.map-section img {
  max-width: 800px;
  margin: 0 auto;
  opacity: 0.8;
}

/* ===== PRODUCT CATEGORIES ===== */
.product-zigzag {
  display: flex;
  flex-direction: column;
  gap: var(--space-4xl);
}

.product-item {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-3xl);
  align-items: center;
}

.product-item:nth-child(even) {
  direction: rtl;
}

.product-item:nth-child(even) > * {
  direction: ltr;
}

.product-item__image {
  border-radius: var(--img-border-radius);
  overflow: hidden;
  aspect-ratio: var(--img-ratio-landscape);
}

.product-item__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.product-item__content h3 {
  margin-bottom: var(--space-md);
}

.product-item__content p {
  color: var(--color-text-light);
}

/* ===== HOME FACTORY / AERIAL ===== */
.factory-section {
  position: relative;
  overflow: hidden;
}

.factory-section__image {
  width: 100%;
}

.factory-section__image img {
  width: 100%;
  height: auto;
}

.factory-labels {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-md);
  margin-top: var(--space-xl);
}

.factory-label {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
  padding: var(--space-xs) var(--space-md);
  background-color: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-pill);
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-medium);
  color: var(--color-text);
  transition: all var(--transition-base);
}

.factory-label:hover {
  border-color: var(--color-primary);
  color: var(--color-primary);
}

/* ===== MANUFACTURING SUB-NAV ===== */
.mfg-subnav {
  display: flex;
  justify-content: center;
  margin-top: -75px;
  position: relative;
  z-index: 10;
  margin-bottom: 40px;
  padding: 0 24px;
}

.mfg-subnav__bar {
  display: flex;
  background: #EFFAFF;
  border-radius: 30px;
  box-shadow: 8px 13px 25.6px rgba(0,0,0,0.1);
  max-width: 1128px;
  width: 100%;
  overflow: hidden;
}

.mfg-subnav__tab {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 14px 10px;
  gap: 8px;
  text-decoration: none;
  color: #000;
  border-right: none;
  position: relative;
  transition: background var(--transition-fast), color var(--transition-fast);
}

.mfg-subnav__tab::after {
  content: '';
  position: absolute;
  right: 0;
  top: 15%;
  height: 70%;
  width: 1px;
  background: rgba(42,170,236,0.3);
}

.mfg-subnav__tab:last-child::after {
  display: none;
}

.mfg-subnav__tab:hover,
.mfg-subnav__tab--active {
  background: #2AAAEC;
  color: white;
}

.mfg-subnav__tab:hover .mfg-subnav__label,
.mfg-subnav__tab--active .mfg-subnav__label {
  color: white;
}

.mfg-subnav__tab:hover svg,
.mfg-subnav__tab--active svg {
  stroke: white;
}

.mfg-subnav__icon {
  width: 88px;
  height: 88px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.mfg-subnav__icon svg {
  width: 48px;
  height: 48px;
  stroke: var(--color-icon);
  fill: none;
  stroke-width: 1.5;
}

.mfg-subnav__label {
  font-family: 'Heebo', sans-serif;
  font-size: 16px;
  font-weight: 700;
  text-align: center;
  line-height: 1.3;
  min-height: 2.6em;
  display: flex;
  align-items: flex-start;
  justify-content: center;
}

/* ===== HORIZONTAL FEATURE CARDS ===== */
.feature-cards--horizontal {
  grid-template-columns: repeat(2, 1fr);
  gap: 28px;
}

.feature-card--horizontal {
  display: flex;
  align-items: flex-start;
  gap: 38px;
  padding: 40px 30px;
  background: white;
  border-radius: 15px;
  box-shadow: 8px 13px 25.6px rgba(0,0,0,0.1);
  text-align: left;
}

.feature-card--horizontal:hover {
  transform: none;
}

.feature-card--horizontal .feature-card__icon {
  flex: 0 0 127px;
  width: 127px;
  height: 127px;
  margin: 0;
  border: none;
  border-radius: 0;
}

.feature-card--horizontal .feature-card__icon svg {
  width: 64px;
  height: 64px;
}

.feature-card--horizontal .feature-card__body {
  display: flex;
  flex-direction: column;
  gap: 14px;
  flex: 1;
  align-self: stretch;
}

.feature-card--horizontal .feature-card__desc {
  min-height: 4.5em;
  flex-grow: 1;
}

.feature-card--horizontal .feature-card__btn {
  margin-top: auto;
}

.feature-card__btn {
  width: 222px;
  height: 57px;
  border-radius: 71px;
  font-family: 'Heebo', sans-serif;
  font-size: 20px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 10px;
}

/* ===== SPOT MAP ===== */
.spot-map {
  position: relative;
  width: 100%;
  overflow: visible;
}

.spot-map__bg {
  width: 100%;
  height: auto;
  display: block;
}

.spot-map__spot {
  position: absolute;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  z-index: 2;
  transform: translate(-50%, -50%);
}

.spot-map__label {
  font-family: 'Heebo', sans-serif;
  font-size: 21px;
  font-weight: 700;
  color: #000;
  white-space: nowrap;
  pointer-events: none;
}

.spot-map__dot-svg {
  transition: transform 0.2s ease;
  flex-shrink: 0;
}

.spot-map__spot:hover .spot-map__dot-svg {
  transform: scale(1.15);
}

.spot-map__popup {
  display: none;
  position: absolute;
  bottom: calc(100% + 12px);
  left: 50%;
  transform: translateX(-50%);
  width: 240px;
  height: auto;
  background: #FFFFFF;
  border-radius: 10px;
  box-shadow: 8px 13px 25.6px rgba(0, 0, 0, 0.1);
  padding: 24px 18px;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  text-align: center;
  z-index: 10;
}

.spot-map__spot--open .spot-map__popup {
  display: flex;
}

/* Popup positioning for right-edge spots */
.spot-map__spot--right .spot-map__popup {
  left: auto;
  right: 50%;
  transform: translateX(50%);
}

/* Popup positioning for top-edge spots — show below */
.spot-map__spot--top .spot-map__popup {
  bottom: auto;
  top: calc(100% + 12px);
}

/* Popup offset-right for Manufacturing — shift popup right to avoid overlapping nearby spots */
.spot-map__spot--offset-right .spot-map__popup {
  left: 50%;
  right: auto;
  transform: translateX(-10%);
}

.spot-map__popup-title {
  font-family: 'Heebo', sans-serif;
  font-size: 18px;
  font-weight: 700;
  color: #000;
  margin: 0;
}

.spot-map__popup-desc {
  font-family: 'Heebo', sans-serif;
  font-size: 13px;
  font-weight: 400;
  color: #333;
  line-height: 1.5;
  margin: 0;
}

.spot-map__popup-icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.spot-map__popup-icon svg {
  width: 44px;
  height: 44px;
}

.spot-map__popup-btn {
  display: inline-block;
  background: #2AAAEC;
  border-radius: 71px;
  font-family: 'Heebo', sans-serif;
  font-size: 16px;
  font-weight: 700;
  color: #FFFFFF;
  padding: 8px 24px;
  text-decoration: none;
  transition: opacity 0.2s ease;
}

.spot-map__popup-btn:hover {
  opacity: 0.85;
}

/* ===== VIDEO COVER ===== */
.video-cover {
  position: relative;
  width: 100%;
  overflow: hidden;
}

.video-cover__video {
  width: 100%;
  height: 662px;
  object-fit: cover;
  display: block;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  .intro {
    grid-template-columns: 1fr;
  }

  .intro--reverse {
    direction: ltr;
  }

  .icon-grid {
    grid-template-columns: 1fr;
  }

  .icon-grid--4col {
    grid-template-columns: repeat(2, 1fr);
  }

  .zigzag__item {
    grid-template-columns: 1fr;
  }

  .zigzag__item:nth-child(even) {
    direction: ltr;
  }

  .stats {
    grid-template-columns: repeat(2, 1fr);
  }

  .stats--8 {
    grid-template-columns: repeat(2, 1fr);
  }

  .feature-cards {
    grid-template-columns: 1fr;
  }

  .feature-cards--horizontal {
    grid-template-columns: 1fr;
  }

  .feature-card--horizontal {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .feature-card--horizontal .feature-card__icon {
    flex: none;
  }

  .feature-card__btn {
    width: auto;
    align-self: center;
  }

  .mfg-subnav__bar {
    flex-wrap: wrap;
    border-radius: 15px;
  }

  .mfg-subnav__tab {
    flex: 0 0 33.33%;
    justify-content: flex-start;
  }

  .mfg-subnav__icon {
    width: 48px;
    height: 48px;
  }

  .mfg-subnav__icon svg {
    width: 28px;
    height: 28px;
  }

  .mfg-subnav__label {
    font-size: 12px;
    line-height: 14px;
    min-height: 28px;
  }

  .cert-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  /* cert-card__image is fixed 200×280 on desktop (Issue 1 fix). On narrow
     mobile two of those + gap exceed viewport — let the image scale down. */
  .cert-card__image {
    width: 100%;
    max-width: 200px;
    height: auto;
    aspect-ratio: 200 / 280;
  }

  /* Zigzag content on mobile contains a wide gallery (5 thumbs × 152px).
     Force min-width:0 so grid item shrinks; overflow:hidden clips the track. */
  .zigzag__item,
  .zigzag__content {
    min-width: 0;
  }
  .zigzag__content {
    overflow: hidden;
  }

  .values-grid {
    grid-template-columns: 1fr;
  }

  .product-item {
    grid-template-columns: 1fr;
  }

  .product-item:nth-child(even) {
    direction: ltr;
  }

  .process-steps {
    flex-direction: column;
    align-items: center;
  }

  .process-step::after {
    display: none;
  }

  .timeline__track {
    flex-direction: column;
    align-items: center;
  }

  .timeline__item {
    flex: none;
    width: 100%;
  }

  .spot-map__label {
    font-size: 14px;
    background: rgba(255, 255, 255, 0.8);
    padding: 2px 6px;
    border-radius: 4px;
  }

  .gallery__thumb {
    width: 100px;
    height: 67px;
  }

  .icon-grid--4col.icon-grid--boxed {
    grid-template-columns: 1fr;
  }

  .icon-grid-container {
    padding: 20px 16px !important;
  }

  .process-arrows {
    flex-direction: column;
    align-items: center;
    gap: 20px 0;
  }

  .process-arrow {
    width: 90%;
    max-width: 320px;
    height: 100px;
    margin-left: 0;
    margin-top: -18px;
  }

  .process-arrow:first-child {
    margin-top: 0;
    margin-left: 0;
  }

  .process-arrow__content {
    padding: 10px 30px 10px 40px;
  }

  .process-arrow__label {
    font-size: 11px;
    margin-top: 4px;
  }

  .process-arrow__icon {
    width: 30px;
    height: 30px;
  }

  /* QC / NPI process: 3-per-row grid on mobile */
  .process-arrows--grid {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    align-items: flex-start;
    gap: 20px 0;
  }

  .process-arrows--grid .process-arrow {
    width: 35%;
    max-width: none;
    height: 80px;
    margin-left: -2.5%;
    margin-top: 0;
  }

  .process-arrows--grid .process-arrow:first-child,
  .process-arrows--grid .process-arrow:nth-child(4) {
    margin-left: 0;
  }

  .process-arrows--grid .process-arrow:nth-child(n+4) {
    margin-top: 0;
  }

  .process-arrows--grid .process-arrow__content {
    padding: 6px 16px 6px 24px;
  }

  .process-arrows--grid .process-arrow__icon {
    width: 22px;
    height: 22px;
  }

  .process-arrows--grid .process-arrow__label {
    font-size: 12px;
    margin-top: 2px;
    line-height: 1.2;
  }

  /* Values overlay: vertical stack on mobile */
  .values-hero {
    padding: 40px 0;
    background-size: cover;
    background-position: center;
    height: auto;
  }

  .values-overlay {
    flex-direction: column;
    align-items: center;
    gap: 20px;
  }

  .values-overlay__card {
    width: 100%;
    height: auto;
    flex-shrink: 1;
    overflow: visible;
  }
}

/* 例外:原本明確 fill="none" 的子元素,hover 時也要改成填色 */
/* ===== values-overlay icon 同步處理 (About Us 頁) ===== */
.values-overlay__icon svg,
.values-overlay__icon svg * {
  transition: stroke 0.3s ease, fill 0.3s ease;
}

/* ===== SECTION TITLE → BLUE PATCH 間距加大 (3.3 / 4.3 / 5.1) ===== */
.section__title + .icon-grid-container,
.section__title + .icon-grid,
.icon-grid-container > .section__title {
  margin-top: 0;
}
.icon-grid-container {
  margin-top: 40px;
}

/* ===== LIGHTBOX STACK — side-by-side 兩張 cert (6.2) ===== */
.lightbox__stack {
  display: flex;
  gap: 20px;
  align-items: center;
  justify-content: center;
  max-width: 95vw;
  max-height: 90vh;
}
.lightbox__stack .lightbox__img {
  max-width: 45vw;
  max-height: 88vh;
  flex: 0 1 auto;
}
/* 單張時佔整個可視區 */
.lightbox__stack:has(.lightbox__img--extra[style*="display:none"]) .lightbox__img:first-child,
.lightbox__stack:has(.lightbox__img--extra[style*="display: none"]) .lightbox__img:first-child {
  max-width: 90vw;
}
/* RWD:窄螢幕改直向堆疊 */
@media (max-width: 900px) {
  .lightbox__stack {
    flex-direction: column;
    gap: 10px;
  }
  .lightbox__stack .lightbox__img {
    max-width: 88vw;
    max-height: 42vh;
  }
}

/* ===== Zigzag Album 變體(左側含 gallery 縮圖)=====
 * 當 .zigzag__content 內有 .gallery 時:
 *   - .zigzag__item align-items: stretch,讓兩側等高(378px)
 *   - .zigzag__content 撐滿,內部分兩區:
 *       上:text-group(h3 + p)垂直置中
 *       下:gallery 貼底
 * 當沒有 .gallery(單圖):維持 align-items: center(container 級)
 */
.zigzag__item:has(.zigzag__content .gallery) {
  align-items: stretch;
}

.zigzag__content:has(> .gallery) {
  display: flex;
  flex-direction: column;
  height: 378px;
}

/* 上半:h3 + p 組成一個彈性區,垂直置中 */
.zigzag__content:has(> .gallery) > :not(.gallery) {
  /* 所有非 gallery 的子元素聚集,靠 margin auto 頂下加推力 */
}

.zigzag__content:has(> .gallery) > h3:first-child {
  margin-top: auto;
}

.zigzag__content:has(> .gallery) > .gallery {
  margin-top: auto;
}

/* ===== VIDEO COVER FALLBACK PLACEHOLDER ===== */
.video-cover--fallback {
  background: #E8EBEF;
}

.video-cover__placeholder {
  width: 100%;
  height: 662px;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  background-color: #2A3540;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.video-cover__placeholder::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.35);
}

.video-cover__play-icon {
  position: relative;
  z-index: 1;
  width: 80px;
  height: 80px;
  cursor: default;
}

.video-cover__play-icon svg {
  width: 100%;
  height: 100%;
  filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.3));
}

@media (max-width: 768px) {
  .video-cover__placeholder {
    height: 360px;
  }
}

/* ===== VIDEO COVER - Hover Play Icon + Cursor ===== */
.video-cover {
  cursor: pointer;
  position: relative;
}

.video-cover__hover-icon {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 80px;
  height: 80px;
  z-index: 2;
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

.video-cover:hover .video-cover__hover-icon {
  opacity: 1;
}

.video-cover__hover-icon svg {
  width: 100%;
  height: 100%;
  filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.4));
}

/* ===== VIDEO LIGHTBOX ===== */
.video-lightbox {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 10000;
  background: rgba(0, 0, 0, 0.92);
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.video-lightbox--active {
  display: flex;
}

.video-lightbox__video {
  max-width: 92vw;
  max-height: 88vh;
  border-radius: 8px;
  box-shadow: 0 20px 80px rgba(0, 0, 0, 0.6);
  cursor: default;
  background: #000;
}

.video-lightbox__close {
  position: absolute;
  top: 20px;
  right: 30px;
  background: none;
  border: none;
  color: white;
  font-size: 48px;
  cursor: pointer;
  line-height: 1;
  z-index: 10001;
  transition: opacity 0.2s ease;
}

.video-lightbox__close:hover {
  opacity: 0.7;
}

/* ===== ICON CARD HOVER — 僅 scale 放大,禁止 fill/stroke 變色 ===== */
.icon-card__icon svg,
.icon-card__icon svg * {
  transition: transform 0.3s ease !important;
}

.icon-card__icon svg {
  transform-origin: center center;
}

.icon-card:hover .icon-card__icon svg {
  transform: scale(1.1) !important;
}

/* values-overlay (About Us) 同樣 */
.values-overlay__icon svg {
  transition: transform 0.3s ease !important;
  transform-origin: center center;
}

.values-overlay__card:hover .values-overlay__icon svg {
  transform: scale(1.1) !important;
}

/* ===== LEGAL PAGES (privacy / terms / disclaimer) ===== */
.legal-page {
  max-width: 1024px;
  margin: 0 auto;
  padding: 60px 20px;
}
.legal-page__effective-date {
  color: #666;
  font-size: 14px;
  margin-bottom: 24px;
}
.legal-page__intro {
  margin-bottom: 32px;
  line-height: 1.7;
  color: #333;
}
.legal-section {
  margin-bottom: 32px;
}
.legal-section__heading {
  font-size: 20px;
  font-weight: 700;
  color: #1a2c4e;
  margin-bottom: 12px;
}
.legal-section__body {
  line-height: 1.7;
  color: #333;
}
.legal-section__body ul {
  padding-left: 20px;
  margin: 8px 0;
}
.legal-section__body li {
  margin-bottom: 6px;
}
.legal-section__body a {
  color: #2AAAEC;
  text-decoration: underline;
}
@media (max-width: 768px) {
  .legal-page { padding: 40px 16px; }
  .legal-section__heading { font-size: 18px; }
}
