:root {
  /* Minimal tokens used by this page */
  --line: #e5e7eb;
}

* { box-sizing: border-box; }

html,
body {
  margin: 0;
  padding: 0;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, Inter, Arial, Helvetica, sans-serif;
  background: #0b0f16;
  line-height: 1.6;
}

a {
  color: inherit;
  text-decoration: none;
}

.container {
  width: min(1200px, 92vw);
  margin: 0 auto;
}

/* =========================
   Buttons
   ========================= */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 44px;
  padding: 0 18px;
  border-radius: 999px;
  border: 1px solid #ffffff;
  background: #ffffff;
  color: #111111;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: transform 0.12s ease, box-shadow 0.18s ease, background-color 0.18s ease, color 0.18s ease;
}

.btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.28);
}

.btn:active {
  transform: translateY(0);
  box-shadow: none;
}

.btn.ghost {
  background: transparent;
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.6);
}

.btn.ghost:hover {
  background: rgba(255, 255, 255, 0.08);
}

/* =========================
   HERO SLIDER (video)
   ========================= */

.hero {
  position: relative;
  width: 100%;
  height: 100vh;
  min-height: 520px;
  overflow: hidden;
  background: #0b0f16;
}

.hero-full {
  padding: 0;
}

.hero-carousel {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  background-color: #0b0f16; /* avoid white flash */
  transition: opacity 0.7s ease;
}

.hero-slide.active {
  opacity: 1;
  pointer-events: auto;
  z-index: 1;
}

.hero-media {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transform: scale(1.03);
}

@keyframes heroZoom {
  from { transform: scale(1.03); }
  to   { transform: scale(1.10); }
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(70% 70% at 50% 40%, rgba(0, 0, 0, 0.15), rgba(0, 0, 0, 0.60)),
    linear-gradient(to bottom, rgba(0, 0, 0, 0.60), rgba(0, 0, 0, 0.25) 45%, rgba(0, 0, 0, 0.60));
}

/*
  Key change:
  - hero-content now fills the whole slide (inset:0)
  - texts stay centered
  - hero-actions is absolutely positioned by bottom, so it is ALWAYS in the same place across slides
*/
.hero-content {
  position: absolute;
  inset: 0;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 50px 24px 160px; /* reserve space for fixed CTA */
  text-align: center;
  color: #ffffff;
  z-index: 2;
}

.hero-content h1 {
  margin: 10px auto 10px;
  max-width: 760px;
  font-size: clamp(38px, 4.8vw, 64px);
  line-height: 1.08;
  letter-spacing: -0.02em;
  text-wrap: balance;
}

.hero-content h2 {
  margin: 30px auto 30px;
  max-width: 820px;
  font-size: clamp(18px, 2.4vw, 30px);
  line-height: 1.18;
  font-weight: 700;
  opacity: 0.92;
  text-wrap: balance;
}

.hero-content .muted,
.hero-content .muted_1,
.hero-content .muted_2 {
  margin: 0 auto 0;
  max-width: 640px;
  font-size: 20px;
  line-height: 1.7;
  opacity: 0.85;
}

.hero-content .kicker {
  display: inline-block;
  font-size: 20px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  opacity: 0.85;
  margin-bottom: 14px;
}

.hero-actions {
  position: absolute;
  left: 50%;
  bottom: 110px; /* consistent position across slides */
  transform: translateX(-50%);
  z-index: 3;

  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.hero-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 34px;
  height: 34px;
  border-radius: 999px;
  border: none;
  background: rgba(0, 0, 0, 0.45);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 3;
  transition: background 0.2s ease, transform 0.1s ease;
}

.hero-arrow.prev { left: 24px; }
.hero-arrow.next { right: 24px; }

.hero-arrow:hover {
  background: rgba(0, 0, 0, 0.75);
  transform: translateY(-50%) scale(1.04);
}

.hero-dots {
  position: absolute;
  left: 50%;
  bottom: 18px;
  transform: translateX(-50%);
  z-index: 3;
  display: flex;
  gap: 8px;
}

.hero-dots .dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  border: none;
  background: rgba(255, 255, 255, 0.55);
  cursor: pointer;
  transition: transform 0.18s ease, background 0.18s ease;
}

.hero-dots .dot.active {
  background: #ffffff;
  transform: scale(1.25);
}

@media (max-width: 980px) {
  .hero-arrow { display: none; }
}

@media (max-width: 768px) {
  .hero-content { padding-bottom: 170px; }
  .hero-actions { bottom: 120px; }
}

@media (max-width: 640px) {
  .hero-content { padding: 0 16px 180px; }
  .hero-content h1 { max-width: 22ch; }
}

/* =========================
   Footer (Clean enterprise layout)
   ========================= */

.site-footer{
  background: #181818;
  color: #ffffff;
  border-top: 1px solid rgba(255,255,255,.12);
  padding: 70px 0 26px;
}

.site-footer__inner{
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 34px;
}

/* brand block */
.site-footer__brand{
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  text-align: center;
}

.site-footer__logo{
  width: 100px;
  height: auto;
  display: block;
}

.site-footer__brandtext{ line-height: 1.1; }

.site-footer__brandcn{
  font-weight: 700;
  letter-spacing: .06em;
  font-size: 16px;
}

.site-footer__branden{
  font-weight: 700;
  letter-spacing: .08em;
  font-size: 13px;
  margin-top: 6px;
  color: rgba(255, 255, 255, 0.65);
}

/* --- NEW GRID: 2 rows + map fixed on the right --- */
.site-footer__grid{
  width: min(1100px, 100%);
  display: grid;
  grid-template-columns: 1fr 1fr 1.15fr;
  grid-template-areas:
    "addrCn addrEn map"
    "contact contact map";
  gap: 18px;
  align-items: stretch;
}

/* cards */
.site-footer__col,
.map-container{
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(255,255,255,.10);
  border-radius: 16px;
  padding: 18px 18px;
}

/* place items without touching HTML */
.site-footer__grid > .site-footer__col:nth-child(1){ grid-area: addrCn; }
.site-footer__grid > .site-footer__col:nth-child(2){ grid-area: addrEn; }
.site-footer__grid > .map-container{ grid-area: map; }
.site-footer__grid > .site-footer__col:last-child{ grid-area: contact; }

.site-footer__col{
  display: flex;
  flex-direction: column;
  gap: 10px;
  font-size: 13px;
  line-height: 1.8;
  text-align: left;
}

/* labels + values */
.site-footer__label{
  font-weight: 700;
  color: #ffffff;
  white-space: nowrap;
  letter-spacing: .02em;
}

.site-footer__value,
.site-footer__value-1{
  color: rgba(255, 255, 255, 0.70);
}

.site-footer__row{
  display: grid;
  grid-template-columns: 110px 1fr;
  gap: 10px;
  align-items: baseline;
}

.site-footer__value a,
.site-footer__value-1 a{
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid transparent;
}

.site-footer__value a:hover,
.site-footer__value-1 a:hover{
  color: #ffffff;
  border-bottom-color: rgba(255,255,255,.55);
}

/* map */
.map-container{
  overflow: hidden;
  padding: 0;
}

.map-container iframe{
  width: 100%;
  height: 100%;
  min-height: 220px;
  border: 0;
  display: block;
  filter: grayscale(0.15) contrast(1.05) brightness(0.95);
}

/* copyright */
.site-footer__copyright{
  margin-top: 8px;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.55);
  text-align: center;
}

/* responsive */
@media (max-width: 980px){
  .site-footer__grid{
    grid-template-columns: 1fr;
    grid-template-areas:
      "map"
      "addrCn"
      "addrEn"
      "contact";
  }

  .site-footer__col{ text-align: center; }
  .site-footer__row{
    grid-template-columns: auto auto;
    justify-content: center;
  }

  .map-container iframe{
    min-height: 240px;
  }
}


/* =====================================================
   Android TV / Large Screen HERO FIX
   Only applies to very large screens (TV / 4K)
   ===================================================== */
@media (min-width: 1600px) {

  /* Hero 區域高度穩定（TV 比 100vh 穩） */
  .hero {
    height: 100svh;
    min-height: 100svh;
  }

  /* 解除父層鎖寬，避免整坨偏移 */
  .hero-content {
    width: 100%;
    max-width: none;
    padding-left: 6vw;   /* overscan safe area */
    padding-right: 6vw;
    padding-bottom: 18vh;
    align-items: center;
    text-align: center;
  }

  /* 所有文字容器：用 vw + 上限，避免直排 */
  .hero-content .kicker,
  .hero-content h1,
  .hero-content h2,
  .hero-content .muted {
    width: min(1200px, 88vw);
    max-width: none;
    margin-left: auto;
    margin-right: auto;
    text-align: center;
  }

  /* 主標題（中文） */
  .hero-content h1 {
    font-size: clamp(44px, 4.2vw, 78px);
    line-height: 1.18;
    letter-spacing: 0.04em;
    word-break: keep-all;
  }

  /* 英文副標 */
  .hero-content h2 {
    font-size: clamp(18px, 1.8vw, 34px);
    line-height: 1.25;
    letter-spacing: 0.06em;
    word-break: keep-all;
  }

  /* 說明文字 */
  .hero-content .muted {
    font-size: clamp(14px, 1.2vw, 18px);
    line-height: 1.6;
    max-width: 1000px;
  }

  /* CTA 按鈕：往內縮，避開 TV 邊緣 */
  .hero-actions {
    bottom: 9vh;
    left: 50%;
    transform: translateX(-50%);
  }

  /* 輪播圓點：避免跑到下一區 */
  .hero-dots {
    bottom: 3.5vh;
  }

  /* 左右箭頭：TV overscan 安全距離 */
  .hero-arrow.prev {
    left: 4vw;
  }
  .hero-arrow.next {
    right: 4vw;
  }
}

